diff --git a/CHANGES.md b/CHANGES.md index 3f40a791438..7c6f8184a62 100644 --- a/CHANGES.md +++ b/CHANGES.md @@ -1,5 +1,23 @@ # Changes +## [0.197.0](https://github.com/googleapis/google-api-go-client/compare/v0.196.0...v0.197.0) (2024-09-10) + + +### Features + +* **all:** Auto-regenerate discovery clients ([#2770](https://github.com/googleapis/google-api-go-client/issues/2770)) ([07782e2](https://github.com/googleapis/google-api-go-client/commit/07782e2db0dc8432b659fb6b1392837a9a33d784)) +* **all:** Auto-regenerate discovery clients ([#2772](https://github.com/googleapis/google-api-go-client/issues/2772)) ([0c7c227](https://github.com/googleapis/google-api-go-client/commit/0c7c227b6d00a2f22de990156f2f75a3862f77a7)) +* **all:** Auto-regenerate discovery clients ([#2774](https://github.com/googleapis/google-api-go-client/issues/2774)) ([6476ddd](https://github.com/googleapis/google-api-go-client/commit/6476dddd4810be9b17e5692f6950f3d24d52abe7)) +* **all:** Auto-regenerate discovery clients ([#2775](https://github.com/googleapis/google-api-go-client/issues/2775)) ([11e2ff6](https://github.com/googleapis/google-api-go-client/commit/11e2ff6ea82ce403f464ea42cf23ec702b6ef883)) +* **all:** Auto-regenerate discovery clients ([#2776](https://github.com/googleapis/google-api-go-client/issues/2776)) ([cc62887](https://github.com/googleapis/google-api-go-client/commit/cc6288771612f80e5d2338dcf5897b7acd0952dd)) +* **all:** Auto-regenerate discovery clients ([#2778](https://github.com/googleapis/google-api-go-client/issues/2778)) ([72cc5c4](https://github.com/googleapis/google-api-go-client/commit/72cc5c4f6ef206c857f222653dff96907b320788)) +* **all:** Auto-regenerate discovery clients ([#2779](https://github.com/googleapis/google-api-go-client/issues/2779)) ([cedc5b0](https://github.com/googleapis/google-api-go-client/commit/cedc5b01c4999c17c97f4f6336fb2f2cae318453)) + + +### Bug Fixes + +* **transport:** Set UniverseDomain in http.NewClient for new auth ([#2773](https://github.com/googleapis/google-api-go-client/issues/2773)) ([140d0a5](https://github.com/googleapis/google-api-go-client/commit/140d0a5e70ebd3f12a6ec11ec48880e6d86cf2bc)) + ## [0.196.0](https://github.com/googleapis/google-api-go-client/compare/v0.195.0...v0.196.0) (2024-09-03) diff --git a/admin/directory/v1/admin-api.json b/admin/directory/v1/admin-api.json index 2e4cf5cb286..b510a271cb8 100644 --- a/admin/directory/v1/admin-api.json +++ b/admin/directory/v1/admin-api.json @@ -4671,7 +4671,7 @@ } } }, - "revision": "20240709", + "revision": "20240903", "rootUrl": "https://admin.googleapis.com/", "schemas": { "Alias": { @@ -6245,7 +6245,7 @@ "type": "string" }, "payload": { - "description": "The payload for the command, provide it only if command supports it. The following commands support adding payload: * `SET_VOLUME`: Payload is a stringified JSON object in the form: { \"volume\": 50 }. The volume has to be an integer in the range [0,100]. * `DEVICE_START_CRD_SESSION`: Payload is optionally a stringified JSON object in the form: { \"ackedUserPresence\": true }. `ackedUserPresence` is a boolean. By default, `ackedUserPresence` is set to `false`. To start a Chrome Remote Desktop session for an active device, set `ackedUserPresence` to `true`. * `REBOOT`: Payload is a stringified JSON object in the form: { \"user_session_delay_seconds\": 300 }. The delay has to be in the range [0, 300]. * `FETCH_SUPPORT_PACKET`: Payload is optionally a stringified JSON object in the form: {\"supportPacketDetails\":{ \"issueCaseId\": optional_support_case_id_string, \"issueDescription\": optional_issue_description_string, \"requestedDataCollectors\": []}} The list of available `data_collector_enums` are as following: Chrome System Information (1), Crash IDs (2), Memory Details (3), UI Hierarchy (4), Additional ChromeOS Platform Logs (5), Device Event (6), Intel WiFi NICs Debug Dump (7), Touch Events (8), Lacros (9), Lacros System Information (10), ChromeOS Flex Logs (11), DBus Details (12), ChromeOS Network Routes (13), ChromeOS Shill (Connection Manager) Logs (14), Policies (15), ChromeOS System State and Logs (16), ChromeOS System Logs (17), ChromeOS Chrome User Logs (18), ChromeOS Bluetooth (19), ChromeOS Connected Input Devices (20), ChromeOS Traffic Counters (21), ChromeOS Virtual Keyboard (22), ChromeOS Network Health (23). See more details in [help article](https://support.google.com/chrome/a?p=remote-log).", + "description": "The payload for the command, provide it only if command supports it. The following commands support adding payload: * `SET_VOLUME`: Payload is a stringified JSON object in the form: { \"volume\": 50 }. The volume has to be an integer in the range [0,100]. * `DEVICE_START_CRD_SESSION`: Payload is optionally a stringified JSON object in the form: { \"ackedUserPresence\": true, \"crdSessionType\": string }. `ackedUserPresence` is a boolean. By default, `ackedUserPresence` is set to `false`. To start a Chrome Remote Desktop session for an active device, set `ackedUserPresence` to `true`. `crdSessionType` can only select from values `private` (which grants the remote admin exclusive control of the ChromeOS device) or `shared` (which allows the admin and the local user to share control of the ChromeOS device). If not set, `crdSessionType` defaults to `shared`. * `REBOOT`: Payload is a stringified JSON object in the form: { \"user_session_delay_seconds\": 300 }. The `user_session_delay_seconds` is the amount of seconds to wait before rebooting the device if a user is logged in. It has to be an integer in the range [0,300]. When payload is not present for reboot, 0 delay is the default. Note: This only applies if an actual user is logged in, including a Guest. If the device is in the login screen or in Kiosk mode the value is not respected and the device immediately reboots. * `FETCH_SUPPORT_PACKET`: Payload is optionally a stringified JSON object in the form: {\"supportPacketDetails\":{ \"issueCaseId\": optional_support_case_id_string, \"issueDescription\": optional_issue_description_string, \"requestedDataCollectors\": []}} The list of available `data_collector_enums` are as following: Chrome System Information (1), Crash IDs (2), Memory Details (3), UI Hierarchy (4), Additional ChromeOS Platform Logs (5), Device Event (6), Intel WiFi NICs Debug Dump (7), Touch Events (8), Lacros (9), Lacros System Information (10), ChromeOS Flex Logs (11), DBus Details (12), ChromeOS Network Routes (13), ChromeOS Shill (Connection Manager) Logs (14), Policies (15), ChromeOS System State and Logs (16), ChromeOS System Logs (17), ChromeOS Chrome User Logs (18), ChromeOS Bluetooth (19), ChromeOS Connected Input Devices (20), ChromeOS Traffic Counters (21), ChromeOS Virtual Keyboard (22), ChromeOS Network Health (23). See more details in [help article](https://support.google.com/chrome/a?p=remote-log).", "type": "string" } }, diff --git a/admin/directory/v1/admin-gen.go b/admin/directory/v1/admin-gen.go index 798943db4d3..8bf0eb359c9 100644 --- a/admin/directory/v1/admin-gen.go +++ b/admin/directory/v1/admin-gen.go @@ -2470,25 +2470,35 @@ type DirectoryChromeosdevicesIssueCommandRequest struct { // is a stringified JSON object in the form: { "volume": 50 }. The volume has // to be an integer in the range [0,100]. * `DEVICE_START_CRD_SESSION`: Payload // is optionally a stringified JSON object in the form: { "ackedUserPresence": - // true }. `ackedUserPresence` is a boolean. By default, `ackedUserPresence` is - // set to `false`. To start a Chrome Remote Desktop session for an active - // device, set `ackedUserPresence` to `true`. * `REBOOT`: Payload is a - // stringified JSON object in the form: { "user_session_delay_seconds": 300 }. - // The delay has to be in the range [0, 300]. * `FETCH_SUPPORT_PACKET`: Payload - // is optionally a stringified JSON object in the form: - // {"supportPacketDetails":{ "issueCaseId": optional_support_case_id_string, - // "issueDescription": optional_issue_description_string, - // "requestedDataCollectors": []}} The list of available `data_collector_enums` - // are as following: Chrome System Information (1), Crash IDs (2), Memory - // Details (3), UI Hierarchy (4), Additional ChromeOS Platform Logs (5), Device - // Event (6), Intel WiFi NICs Debug Dump (7), Touch Events (8), Lacros (9), - // Lacros System Information (10), ChromeOS Flex Logs (11), DBus Details (12), - // ChromeOS Network Routes (13), ChromeOS Shill (Connection Manager) Logs (14), - // Policies (15), ChromeOS System State and Logs (16), ChromeOS System Logs - // (17), ChromeOS Chrome User Logs (18), ChromeOS Bluetooth (19), ChromeOS - // Connected Input Devices (20), ChromeOS Traffic Counters (21), ChromeOS - // Virtual Keyboard (22), ChromeOS Network Health (23). See more details in - // help article (https://support.google.com/chrome/a?p=remote-log). + // true, "crdSessionType": string }. `ackedUserPresence` is a boolean. By + // default, `ackedUserPresence` is set to `false`. To start a Chrome Remote + // Desktop session for an active device, set `ackedUserPresence` to `true`. + // `crdSessionType` can only select from values `private` (which grants the + // remote admin exclusive control of the ChromeOS device) or `shared` (which + // allows the admin and the local user to share control of the ChromeOS + // device). If not set, `crdSessionType` defaults to `shared`. * `REBOOT`: + // Payload is a stringified JSON object in the form: { + // "user_session_delay_seconds": 300 }. The `user_session_delay_seconds` is the + // amount of seconds to wait before rebooting the device if a user is logged + // in. It has to be an integer in the range [0,300]. When payload is not + // present for reboot, 0 delay is the default. Note: This only applies if an + // actual user is logged in, including a Guest. If the device is in the login + // screen or in Kiosk mode the value is not respected and the device + // immediately reboots. * `FETCH_SUPPORT_PACKET`: Payload is optionally a + // stringified JSON object in the form: {"supportPacketDetails":{ + // "issueCaseId": optional_support_case_id_string, "issueDescription": + // optional_issue_description_string, "requestedDataCollectors": []}} The list + // of available `data_collector_enums` are as following: Chrome System + // Information (1), Crash IDs (2), Memory Details (3), UI Hierarchy (4), + // Additional ChromeOS Platform Logs (5), Device Event (6), Intel WiFi NICs + // Debug Dump (7), Touch Events (8), Lacros (9), Lacros System Information + // (10), ChromeOS Flex Logs (11), DBus Details (12), ChromeOS Network Routes + // (13), ChromeOS Shill (Connection Manager) Logs (14), Policies (15), ChromeOS + // System State and Logs (16), ChromeOS System Logs (17), ChromeOS Chrome User + // Logs (18), ChromeOS Bluetooth (19), ChromeOS Connected Input Devices (20), + // ChromeOS Traffic Counters (21), ChromeOS Virtual Keyboard (22), ChromeOS + // Network Health (23). See more details in help article + // (https://support.google.com/chrome/a?p=remote-log). Payload string `json:"payload,omitempty"` // ForceSendFields is a list of field names (e.g. "CommandType") to // unconditionally include in API requests. By default, fields with empty or diff --git a/aiplatform/v1/aiplatform-api.json b/aiplatform/v1/aiplatform-api.json index 73eec00f87c..0d7b826ae47 100644 --- a/aiplatform/v1/aiplatform-api.json +++ b/aiplatform/v1/aiplatform-api.json @@ -2246,7 +2246,7 @@ "annotations": { "methods": { "list": { - "description": "Lists Annotations belongs to a dataitem", + "description": "Lists Annotations belongs to a dataitem This RPC is only available in InternalDatasetService. It is only used for exporting conversation data to CCAI Insights.", "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/datasets/{datasetsId}/dataItems/{dataItemsId}/annotations", "httpMethod": "GET", "id": "aiplatform.projects.locations.datasets.dataItems.annotations.list", @@ -4956,6 +4956,37 @@ "https://www.googleapis.com/auth/cloud-platform" ] }, + "getIamPolicy": { + "description": "Gets the access control policy for a resource. Returns an empty policy if the resource exists and does not have a policy set.", + "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/featureOnlineStores/{featureOnlineStoresId}:getIamPolicy", + "httpMethod": "POST", + "id": "aiplatform.projects.locations.featureOnlineStores.getIamPolicy", + "parameterOrder": [ + "resource" + ], + "parameters": { + "options.requestedPolicyVersion": { + "description": "Optional. The maximum policy version that will be used to format the policy. Valid values are 0, 1, and 3. Requests specifying an invalid value will be rejected. Requests for policies with any conditional role bindings must specify version 3. Policies with no conditional role bindings may specify any valid value or leave the field unset. The policy in the response might use the policy version that you specified, or it might use a lower policy version. For example, if you specify version 3, but the policy has no conditional role bindings, the response uses version 1. To learn which resources support conditions in their IAM policies, see the [IAM documentation](https://cloud.google.com/iam/help/conditions/resource-policies).", + "format": "int32", + "location": "query", + "type": "integer" + }, + "resource": { + "description": "REQUIRED: The resource for which the policy is being requested. See [Resource names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/featureOnlineStores/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1/{+resource}:getIamPolicy", + "response": { + "$ref": "GoogleIamV1Policy" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, "list": { "description": "Lists FeatureOnlineStores in a given project and location.", "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/featureOnlineStores", @@ -5035,6 +5066,65 @@ "scopes": [ "https://www.googleapis.com/auth/cloud-platform" ] + }, + "setIamPolicy": { + "description": "Sets the access control policy on the specified resource. Replaces any existing policy. Can return `NOT_FOUND`, `INVALID_ARGUMENT`, and `PERMISSION_DENIED` errors.", + "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/featureOnlineStores/{featureOnlineStoresId}:setIamPolicy", + "httpMethod": "POST", + "id": "aiplatform.projects.locations.featureOnlineStores.setIamPolicy", + "parameterOrder": [ + "resource" + ], + "parameters": { + "resource": { + "description": "REQUIRED: The resource for which the policy is being specified. See [Resource names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/featureOnlineStores/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1/{+resource}:setIamPolicy", + "request": { + "$ref": "GoogleIamV1SetIamPolicyRequest" + }, + "response": { + "$ref": "GoogleIamV1Policy" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "testIamPermissions": { + "description": "Returns permissions that a caller has on the specified resource. If the resource does not exist, this will return an empty set of permissions, not a `NOT_FOUND` error. Note: This operation is designed to be used for building permission-aware UIs and command-line tools, not for authorization checking. This operation may \"fail open\" without warning.", + "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/featureOnlineStores/{featureOnlineStoresId}:testIamPermissions", + "httpMethod": "POST", + "id": "aiplatform.projects.locations.featureOnlineStores.testIamPermissions", + "parameterOrder": [ + "resource" + ], + "parameters": { + "permissions": { + "description": "The set of permissions to check for the `resource`. Permissions with wildcards (such as `*` or `storage.*`) are not allowed. For more information see [IAM Overview](https://cloud.google.com/iam/docs/overview#permissions).", + "location": "query", + "repeated": true, + "type": "string" + }, + "resource": { + "description": "REQUIRED: The resource for which the policy detail is being requested. See [Resource names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/featureOnlineStores/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1/{+resource}:testIamPermissions", + "response": { + "$ref": "GoogleIamV1TestIamPermissionsResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] } }, "resources": { @@ -5156,6 +5246,37 @@ "https://www.googleapis.com/auth/cloud-platform" ] }, + "getIamPolicy": { + "description": "Gets the access control policy for a resource. Returns an empty policy if the resource exists and does not have a policy set.", + "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/featureOnlineStores/{featureOnlineStoresId}/featureViews/{featureViewsId}:getIamPolicy", + "httpMethod": "POST", + "id": "aiplatform.projects.locations.featureOnlineStores.featureViews.getIamPolicy", + "parameterOrder": [ + "resource" + ], + "parameters": { + "options.requestedPolicyVersion": { + "description": "Optional. The maximum policy version that will be used to format the policy. Valid values are 0, 1, and 3. Requests specifying an invalid value will be rejected. Requests for policies with any conditional role bindings must specify version 3. Policies with no conditional role bindings may specify any valid value or leave the field unset. The policy in the response might use the policy version that you specified, or it might use a lower policy version. For example, if you specify version 3, but the policy has no conditional role bindings, the response uses version 1. To learn which resources support conditions in their IAM policies, see the [IAM documentation](https://cloud.google.com/iam/help/conditions/resource-policies).", + "format": "int32", + "location": "query", + "type": "integer" + }, + "resource": { + "description": "REQUIRED: The resource for which the policy is being requested. See [Resource names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/featureOnlineStores/[^/]+/featureViews/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1/{+resource}:getIamPolicy", + "response": { + "$ref": "GoogleIamV1Policy" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, "list": { "description": "Lists FeatureViews in a given FeatureOnlineStore.", "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/featureOnlineStores/{featureOnlineStoresId}/featureViews", @@ -5264,6 +5385,34 @@ "https://www.googleapis.com/auth/cloud-platform" ] }, + "setIamPolicy": { + "description": "Sets the access control policy on the specified resource. Replaces any existing policy. Can return `NOT_FOUND`, `INVALID_ARGUMENT`, and `PERMISSION_DENIED` errors.", + "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/featureOnlineStores/{featureOnlineStoresId}/featureViews/{featureViewsId}:setIamPolicy", + "httpMethod": "POST", + "id": "aiplatform.projects.locations.featureOnlineStores.featureViews.setIamPolicy", + "parameterOrder": [ + "resource" + ], + "parameters": { + "resource": { + "description": "REQUIRED: The resource for which the policy is being specified. See [Resource names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/featureOnlineStores/[^/]+/featureViews/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1/{+resource}:setIamPolicy", + "request": { + "$ref": "GoogleIamV1SetIamPolicyRequest" + }, + "response": { + "$ref": "GoogleIamV1Policy" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, "sync": { "description": "Triggers on-demand sync for the FeatureView.", "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/featureOnlineStores/{featureOnlineStoresId}/featureViews/{featureViewsId}:sync", @@ -5291,6 +5440,37 @@ "scopes": [ "https://www.googleapis.com/auth/cloud-platform" ] + }, + "testIamPermissions": { + "description": "Returns permissions that a caller has on the specified resource. If the resource does not exist, this will return an empty set of permissions, not a `NOT_FOUND` error. Note: This operation is designed to be used for building permission-aware UIs and command-line tools, not for authorization checking. This operation may \"fail open\" without warning.", + "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/featureOnlineStores/{featureOnlineStoresId}/featureViews/{featureViewsId}:testIamPermissions", + "httpMethod": "POST", + "id": "aiplatform.projects.locations.featureOnlineStores.featureViews.testIamPermissions", + "parameterOrder": [ + "resource" + ], + "parameters": { + "permissions": { + "description": "The set of permissions to check for the `resource`. Permissions with wildcards (such as `*` or `storage.*`) are not allowed. For more information see [IAM Overview](https://cloud.google.com/iam/docs/overview#permissions).", + "location": "query", + "repeated": true, + "type": "string" + }, + "resource": { + "description": "REQUIRED: The resource for which the policy detail is being requested. See [Resource names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/featureOnlineStores/[^/]+/featureViews/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1/{+resource}:testIamPermissions", + "response": { + "$ref": "GoogleIamV1TestIamPermissionsResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] } }, "resources": { @@ -17580,7 +17760,7 @@ } } }, - "revision": "20240816", + "revision": "20240828", "rootUrl": "https://aiplatform.googleapis.com/", "schemas": { "CloudAiLargeModelsVisionGenerateVideoResponse": { @@ -22872,6 +23052,10 @@ "$ref": "GoogleCloudAiplatformV1BigQuerySource", "description": "Required. Immutable. The BigQuery source URI that points to either a BigQuery Table or View." }, + "dense": { + "description": "Optional. If set, all feature values will be fetched from a single row per unique entityId including nulls. If not set, will collapse all rows for each unique entityId into a singe row with any non-null values if present, if no non-null values are present will sync null. ex: If source has schema (entity_id, feature_timestamp, f0, f1) and values (e1, 2020-01-01T10:00:00.123Z, 10, 15) (e1, 2020-02-01T10:00:00.123Z, 20, null) If dense is set, (e1, 20, null) is synced to online stores. If dense is not set, (e1, 20, 15) is synced to online stores.", + "type": "boolean" + }, "entityIdColumns": { "description": "Optional. Columns to construct entity_id / row keys. If not provided defaults to `entity_id`.", "items": { @@ -22879,6 +23063,10 @@ }, "type": "array" }, + "staticDataSource": { + "description": "Optional. Set if the data source is not a time-series.", + "type": "boolean" + }, "timeSeries": { "$ref": "GoogleCloudAiplatformV1FeatureGroupBigQueryTimeSeries", "description": "Optional. If the source is a time-series source, this can be set to control how downstream sources (ex: FeatureView ) will treat time-series sources. If not set, will treat the source as a time-series source with `feature_timestamp` as timestamp column and no scan boundary." @@ -23292,6 +23480,10 @@ "format": "google-datetime", "readOnly": true, "type": "string" + }, + "vertexRagSource": { + "$ref": "GoogleCloudAiplatformV1FeatureViewVertexRagSource", + "description": "Optional. The Vertex RAG Source that the FeatureView is linked to." } }, "type": "object" @@ -23525,6 +23717,22 @@ }, "type": "object" }, + "GoogleCloudAiplatformV1FeatureViewVertexRagSource": { + "description": "A Vertex Rag source for features that need to be synced to Online Store.", + "id": "GoogleCloudAiplatformV1FeatureViewVertexRagSource", + "properties": { + "ragCorpusId": { + "description": "Optional. The RAG corpus id corresponding to this FeatureView.", + "format": "int64", + "type": "string" + }, + "uri": { + "description": "Required. The BigQuery view/table URI that will be materialized on each manual sync trigger. The table/view is expected to have the following columns at least: Field name Type Mode corpus_id STRING REQUIRED/NULLABLE file_id STRING REQUIRED/NULLABLE chunk_id STRING REQUIRED/NULLABLE chunk_data_type STRING REQUIRED/NULLABLE chunk_data STRING REQUIRED/NULLABLE embeddings FLOAT REPEATED file_original_uri STRING REQUIRED/NULLABLE", + "type": "string" + } + }, + "type": "object" + }, "GoogleCloudAiplatformV1Featurestore": { "description": "Vertex AI Feature Store provides a centralized repository for organizing, storing, and serving ML features. The Featurestore is a top-level container for your features and their values.", "id": "GoogleCloudAiplatformV1Featurestore", @@ -24178,6 +24386,10 @@ "parameters": { "$ref": "GoogleCloudAiplatformV1Schema", "description": "Optional. Describes the parameters to this function in JSON Schema Object format. Reflects the Open API 3.03 Parameter Object. string Key: the name of the parameter. Parameter names are case sensitive. Schema Value: the Schema defining the type used for the parameter. For function with no parameters, this can be left unset. Parameter names must start with a letter or an underscore and must only contain chars a-z, A-Z, 0-9, or underscores with a maximum length of 64. Example with 1 required and 1 optional parameter: type: OBJECT properties: param1: type: STRING param2: type: INTEGER required: - param1" + }, + "response": { + "$ref": "GoogleCloudAiplatformV1Schema", + "description": "Optional. Describes the output from this function in JSON Schema format. Reflects the Open API 3.03 Response Object. The Schema defines the type used for the response value of the function." } }, "type": "object" @@ -24195,7 +24407,7 @@ "description": "Properties of the object.", "type": "any" }, - "description": "Required. The function response in JSON object format.", + "description": "Required. The function response in JSON object format. Use \"output\" key to specify function output and \"error\" key to specify error details (if any). If \"output\" and \"error\" keys are not specified, then whole \"response\" is treated as function output.", "type": "object" } }, @@ -24344,6 +24556,7 @@ "type": "integer" }, "totalTokenCount": { + "description": "Total token count for prompt and response candidates.", "format": "int32", "type": "integer" } @@ -32427,7 +32640,7 @@ "LOW_COST", "STANDARD", "SPOT", - "DWS_FLEX_START" + "FLEX_START" ], "enumDeprecated": [ false, @@ -32443,7 +32656,7 @@ "Deprecated. Low cost by making potential use of spot resources.", "Standard provisioning strategy uses regular on-demand resources.", "Spot provisioning strategy uses spot resources.", - "DWS Flex start strategy uses DWS to queue for resources." + "Flex Start strategy uses DWS to queue for resources." ], "type": "string" }, @@ -32456,7 +32669,7 @@ "type": "object" }, "GoogleCloudAiplatformV1Schema": { - "description": "Schema is used to define the format of input/output data. Represents a select subset of an [OpenAPI 3.0 schema object](https://spec.openapis.org/oas/v3.0.3#schema). More fields may be added in the future as needed.", + "description": "Schema is used to define the format of input/output data. Represents a select subset of an [OpenAPI 3.0 schema object](https://spec.openapis.org/oas/v3.0.3#schema-object). More fields may be added in the future as needed.", "id": "GoogleCloudAiplatformV1Schema", "properties": { "default": { @@ -37859,7 +38072,7 @@ "type": "object" }, "GoogleCloudAiplatformV1SyncFeatureViewResponse": { - "description": "Respose message for FeatureOnlineStoreAdminService.SyncFeatureView.", + "description": "Response message for FeatureOnlineStoreAdminService.SyncFeatureView.", "id": "GoogleCloudAiplatformV1SyncFeatureViewResponse", "properties": { "featureViewSync": { diff --git a/aiplatform/v1/aiplatform-gen.go b/aiplatform/v1/aiplatform-gen.go index cb450856922..e51dab4d1cd 100644 --- a/aiplatform/v1/aiplatform-gen.go +++ b/aiplatform/v1/aiplatform-gen.go @@ -8926,9 +8926,20 @@ type GoogleCloudAiplatformV1FeatureGroupBigQuery struct { // BigQuerySource: Required. Immutable. The BigQuery source URI that points to // either a BigQuery Table or View. BigQuerySource *GoogleCloudAiplatformV1BigQuerySource `json:"bigQuerySource,omitempty"` + // Dense: Optional. If set, all feature values will be fetched from a single + // row per unique entityId including nulls. If not set, will collapse all rows + // for each unique entityId into a singe row with any non-null values if + // present, if no non-null values are present will sync null. ex: If source has + // schema (entity_id, feature_timestamp, f0, f1) and values (e1, + // 2020-01-01T10:00:00.123Z, 10, 15) (e1, 2020-02-01T10:00:00.123Z, 20, null) + // If dense is set, (e1, 20, null) is synced to online stores. If dense is not + // set, (e1, 20, 15) is synced to online stores. + Dense bool `json:"dense,omitempty"` // EntityIdColumns: Optional. Columns to construct entity_id / row keys. If not // provided defaults to `entity_id`. EntityIdColumns []string `json:"entityIdColumns,omitempty"` + // StaticDataSource: Optional. Set if the data source is not a time-series. + StaticDataSource bool `json:"staticDataSource,omitempty"` // TimeSeries: Optional. If the source is a time-series source, this can be set // to control how downstream sources (ex: FeatureView ) will treat time-series // sources. If not set, will treat the source as a time-series source with @@ -9538,6 +9549,9 @@ type GoogleCloudAiplatformV1FeatureView struct { SyncConfig *GoogleCloudAiplatformV1FeatureViewSyncConfig `json:"syncConfig,omitempty"` // UpdateTime: Output only. Timestamp when this FeatureView was last updated. UpdateTime string `json:"updateTime,omitempty"` + // VertexRagSource: Optional. The Vertex RAG Source that the FeatureView is + // linked to. + VertexRagSource *GoogleCloudAiplatformV1FeatureViewVertexRagSource `json:"vertexRagSource,omitempty"` // ServerResponse contains the HTTP response code and headers from the server. googleapi.ServerResponse `json:"-"` @@ -9876,6 +9890,36 @@ func (s GoogleCloudAiplatformV1FeatureViewSyncSyncSummary) MarshalJSON() ([]byte return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudAiplatformV1FeatureViewVertexRagSource: A Vertex Rag source for +// features that need to be synced to Online Store. +type GoogleCloudAiplatformV1FeatureViewVertexRagSource struct { + // RagCorpusId: Optional. The RAG corpus id corresponding to this FeatureView. + RagCorpusId int64 `json:"ragCorpusId,omitempty,string"` + // Uri: Required. The BigQuery view/table URI that will be materialized on each + // manual sync trigger. The table/view is expected to have the following + // columns at least: Field name Type Mode corpus_id STRING REQUIRED/NULLABLE + // file_id STRING REQUIRED/NULLABLE chunk_id STRING REQUIRED/NULLABLE + // chunk_data_type STRING REQUIRED/NULLABLE chunk_data STRING REQUIRED/NULLABLE + // embeddings FLOAT REPEATED file_original_uri STRING REQUIRED/NULLABLE + Uri string `json:"uri,omitempty"` + // ForceSendFields is a list of field names (e.g. "RagCorpusId") 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. "RagCorpusId") 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 GoogleCloudAiplatformV1FeatureViewVertexRagSource) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudAiplatformV1FeatureViewVertexRagSource + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudAiplatformV1Featurestore: Vertex AI Feature Store provides a // centralized repository for organizing, storing, and serving ML features. The // Featurestore is a top-level container for your features and their values. @@ -10980,6 +11024,10 @@ type GoogleCloudAiplatformV1FunctionDeclaration struct { // optional parameter: type: OBJECT properties: param1: type: STRING param2: // type: INTEGER required: - param1 Parameters *GoogleCloudAiplatformV1Schema `json:"parameters,omitempty"` + // Response: Optional. Describes the output from this function in JSON Schema + // format. Reflects the Open API 3.03 Response Object. The Schema defines the + // type used for the response value of the function. + Response *GoogleCloudAiplatformV1Schema `json:"response,omitempty"` // ForceSendFields is a list of field names (e.g. "Description") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See @@ -11007,7 +11055,10 @@ type GoogleCloudAiplatformV1FunctionResponse struct { // Name: Required. The name of the function to call. Matches // [FunctionDeclaration.name] and [FunctionCall.name]. Name string `json:"name,omitempty"` - // Response: Required. The function response in JSON object format. + // Response: Required. The function response in JSON object format. Use + // "output" key to specify function output and "error" key to specify error + // details (if any). If "output" and "error" keys are not specified, then whole + // "response" is treated as function output. Response googleapi.RawMessage `json:"response,omitempty"` // ForceSendFields is a list of field names (e.g. "Name") to unconditionally // include in API requests. By default, fields with empty or default values are @@ -11196,7 +11247,8 @@ type GoogleCloudAiplatformV1GenerateContentResponseUsageMetadata struct { // set, this is still the total effective prompt size meaning this includes the // number of tokens in the cached content. PromptTokenCount int64 `json:"promptTokenCount,omitempty"` - TotalTokenCount int64 `json:"totalTokenCount,omitempty"` + // TotalTokenCount: Total token count for prompt and response candidates. + TotalTokenCount int64 `json:"totalTokenCount,omitempty"` // ForceSendFields is a list of field names (e.g. "CandidatesTokenCount") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See @@ -22332,8 +22384,7 @@ type GoogleCloudAiplatformV1Scheduling struct { // "STANDARD" - Standard provisioning strategy uses regular on-demand // resources. // "SPOT" - Spot provisioning strategy uses spot resources. - // "DWS_FLEX_START" - DWS Flex start strategy uses DWS to queue for - // resources. + // "FLEX_START" - Flex Start strategy uses DWS to queue for resources. Strategy string `json:"strategy,omitempty"` // Timeout: The maximum job running time. The default is 7 days. Timeout string `json:"timeout,omitempty"` @@ -22357,8 +22408,8 @@ func (s GoogleCloudAiplatformV1Scheduling) MarshalJSON() ([]byte, error) { // GoogleCloudAiplatformV1Schema: Schema is used to define the format of // input/output data. Represents a select subset of an OpenAPI 3.0 schema -// object (https://spec.openapis.org/oas/v3.0.3#schema). More fields may be -// added in the future as needed. +// object (https://spec.openapis.org/oas/v3.0.3#schema-object). More fields may +// be added in the future as needed. type GoogleCloudAiplatformV1Schema struct { // Default: Optional. Default value of the data. Default interface{} `json:"default,omitempty"` @@ -30976,7 +31027,7 @@ func (s GoogleCloudAiplatformV1SupervisedTuningSpec) MarshalJSON() ([]byte, erro type GoogleCloudAiplatformV1SyncFeatureViewRequest struct { } -// GoogleCloudAiplatformV1SyncFeatureViewResponse: Respose message for +// GoogleCloudAiplatformV1SyncFeatureViewResponse: Response message for // FeatureOnlineStoreAdminService.SyncFeatureView. type GoogleCloudAiplatformV1SyncFeatureViewResponse struct { // FeatureViewSync: Format: @@ -41261,7 +41312,9 @@ type ProjectsLocationsDatasetsDataItemsAnnotationsListCall struct { header_ http.Header } -// List: Lists Annotations belongs to a dataitem +// List: Lists Annotations belongs to a dataitem This RPC is only available in +// InternalDatasetService. It is only used for exporting conversation data to +// CCAI Insights. // // - parent: The resource name of the DataItem to list Annotations from. // Format: @@ -51168,6 +51221,122 @@ func (c *ProjectsLocationsFeatureOnlineStoresGetCall) Do(opts ...googleapi.CallO return ret, nil } +type ProjectsLocationsFeatureOnlineStoresGetIamPolicyCall struct { + s *Service + resource string + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// GetIamPolicy: Gets the access control policy for a resource. Returns an +// empty policy if the resource exists and does not have a policy set. +// +// - resource: REQUIRED: The resource for which the policy is being requested. +// See Resource names (https://cloud.google.com/apis/design/resource_names) +// for the appropriate value for this field. +func (r *ProjectsLocationsFeatureOnlineStoresService) GetIamPolicy(resource string) *ProjectsLocationsFeatureOnlineStoresGetIamPolicyCall { + c := &ProjectsLocationsFeatureOnlineStoresGetIamPolicyCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.resource = resource + return c +} + +// OptionsRequestedPolicyVersion sets the optional parameter +// "options.requestedPolicyVersion": The maximum policy version that will be +// used to format the policy. Valid values are 0, 1, and 3. Requests specifying +// an invalid value will be rejected. Requests for policies with any +// conditional role bindings must specify version 3. Policies with no +// conditional role bindings may specify any valid value or leave the field +// unset. The policy in the response might use the policy version that you +// specified, or it might use a lower policy version. For example, if you +// specify version 3, but the policy has no conditional role bindings, the +// response uses version 1. To learn which resources support conditions in +// their IAM policies, see the IAM documentation +// (https://cloud.google.com/iam/help/conditions/resource-policies). +func (c *ProjectsLocationsFeatureOnlineStoresGetIamPolicyCall) OptionsRequestedPolicyVersion(optionsRequestedPolicyVersion int64) *ProjectsLocationsFeatureOnlineStoresGetIamPolicyCall { + c.urlParams_.Set("options.requestedPolicyVersion", fmt.Sprint(optionsRequestedPolicyVersion)) + 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 *ProjectsLocationsFeatureOnlineStoresGetIamPolicyCall) Fields(s ...googleapi.Field) *ProjectsLocationsFeatureOnlineStoresGetIamPolicyCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsFeatureOnlineStoresGetIamPolicyCall) Context(ctx context.Context) *ProjectsLocationsFeatureOnlineStoresGetIamPolicyCall { + 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 *ProjectsLocationsFeatureOnlineStoresGetIamPolicyCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsFeatureOnlineStoresGetIamPolicyCall) 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/{+resource}:getIamPolicy") + 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{ + "resource": c.resource, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "aiplatform.projects.locations.featureOnlineStores.getIamPolicy" call. +// Any non-2xx status code is an error. Response headers are in either +// *GoogleIamV1Policy.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 *ProjectsLocationsFeatureOnlineStoresGetIamPolicyCall) Do(opts ...googleapi.CallOption) (*GoogleIamV1Policy, 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 := &GoogleIamV1Policy{ + 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 ProjectsLocationsFeatureOnlineStoresListCall struct { s *Service parent string @@ -51460,6 +51629,224 @@ func (c *ProjectsLocationsFeatureOnlineStoresPatchCall) Do(opts ...googleapi.Cal return ret, nil } +type ProjectsLocationsFeatureOnlineStoresSetIamPolicyCall struct { + s *Service + resource string + googleiamv1setiampolicyrequest *GoogleIamV1SetIamPolicyRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// SetIamPolicy: Sets the access control policy on the specified resource. +// Replaces any existing policy. Can return `NOT_FOUND`, `INVALID_ARGUMENT`, +// and `PERMISSION_DENIED` errors. +// +// - resource: REQUIRED: The resource for which the policy is being specified. +// See Resource names (https://cloud.google.com/apis/design/resource_names) +// for the appropriate value for this field. +func (r *ProjectsLocationsFeatureOnlineStoresService) SetIamPolicy(resource string, googleiamv1setiampolicyrequest *GoogleIamV1SetIamPolicyRequest) *ProjectsLocationsFeatureOnlineStoresSetIamPolicyCall { + c := &ProjectsLocationsFeatureOnlineStoresSetIamPolicyCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.resource = resource + c.googleiamv1setiampolicyrequest = googleiamv1setiampolicyrequest + 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 *ProjectsLocationsFeatureOnlineStoresSetIamPolicyCall) Fields(s ...googleapi.Field) *ProjectsLocationsFeatureOnlineStoresSetIamPolicyCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsFeatureOnlineStoresSetIamPolicyCall) Context(ctx context.Context) *ProjectsLocationsFeatureOnlineStoresSetIamPolicyCall { + 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 *ProjectsLocationsFeatureOnlineStoresSetIamPolicyCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsFeatureOnlineStoresSetIamPolicyCall) 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.googleiamv1setiampolicyrequest) + if err != nil { + return nil, err + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+resource}:setIamPolicy") + 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{ + "resource": c.resource, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "aiplatform.projects.locations.featureOnlineStores.setIamPolicy" call. +// Any non-2xx status code is an error. Response headers are in either +// *GoogleIamV1Policy.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 *ProjectsLocationsFeatureOnlineStoresSetIamPolicyCall) Do(opts ...googleapi.CallOption) (*GoogleIamV1Policy, 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 := &GoogleIamV1Policy{ + 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 ProjectsLocationsFeatureOnlineStoresTestIamPermissionsCall struct { + s *Service + resource string + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// TestIamPermissions: Returns permissions that a caller has on the specified +// resource. If the resource does not exist, this will return an empty set of +// permissions, not a `NOT_FOUND` error. Note: This operation is designed to be +// used for building permission-aware UIs and command-line tools, not for +// authorization checking. This operation may "fail open" without warning. +// +// - resource: REQUIRED: The resource for which the policy detail is being +// requested. See Resource names +// (https://cloud.google.com/apis/design/resource_names) for the appropriate +// value for this field. +func (r *ProjectsLocationsFeatureOnlineStoresService) TestIamPermissions(resource string) *ProjectsLocationsFeatureOnlineStoresTestIamPermissionsCall { + c := &ProjectsLocationsFeatureOnlineStoresTestIamPermissionsCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.resource = resource + return c +} + +// Permissions sets the optional parameter "permissions": The set of +// permissions to check for the `resource`. Permissions with wildcards (such as +// `*` or `storage.*`) are not allowed. For more information see IAM Overview +// (https://cloud.google.com/iam/docs/overview#permissions). +func (c *ProjectsLocationsFeatureOnlineStoresTestIamPermissionsCall) Permissions(permissions ...string) *ProjectsLocationsFeatureOnlineStoresTestIamPermissionsCall { + c.urlParams_.SetMulti("permissions", append([]string{}, permissions...)) + 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 *ProjectsLocationsFeatureOnlineStoresTestIamPermissionsCall) Fields(s ...googleapi.Field) *ProjectsLocationsFeatureOnlineStoresTestIamPermissionsCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsFeatureOnlineStoresTestIamPermissionsCall) Context(ctx context.Context) *ProjectsLocationsFeatureOnlineStoresTestIamPermissionsCall { + 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 *ProjectsLocationsFeatureOnlineStoresTestIamPermissionsCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsFeatureOnlineStoresTestIamPermissionsCall) 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/{+resource}:testIamPermissions") + 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{ + "resource": c.resource, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "aiplatform.projects.locations.featureOnlineStores.testIamPermissions" call. +// Any non-2xx status code is an error. Response headers are in either +// *GoogleIamV1TestIamPermissionsResponse.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 *ProjectsLocationsFeatureOnlineStoresTestIamPermissionsCall) Do(opts ...googleapi.CallOption) (*GoogleIamV1TestIamPermissionsResponse, 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 := &GoogleIamV1TestIamPermissionsResponse{ + 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 ProjectsLocationsFeatureOnlineStoresFeatureViewsCreateCall struct { s *Service parent string @@ -51895,6 +52282,122 @@ func (c *ProjectsLocationsFeatureOnlineStoresFeatureViewsGetCall) Do(opts ...goo return ret, nil } +type ProjectsLocationsFeatureOnlineStoresFeatureViewsGetIamPolicyCall struct { + s *Service + resource string + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// GetIamPolicy: Gets the access control policy for a resource. Returns an +// empty policy if the resource exists and does not have a policy set. +// +// - resource: REQUIRED: The resource for which the policy is being requested. +// See Resource names (https://cloud.google.com/apis/design/resource_names) +// for the appropriate value for this field. +func (r *ProjectsLocationsFeatureOnlineStoresFeatureViewsService) GetIamPolicy(resource string) *ProjectsLocationsFeatureOnlineStoresFeatureViewsGetIamPolicyCall { + c := &ProjectsLocationsFeatureOnlineStoresFeatureViewsGetIamPolicyCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.resource = resource + return c +} + +// OptionsRequestedPolicyVersion sets the optional parameter +// "options.requestedPolicyVersion": The maximum policy version that will be +// used to format the policy. Valid values are 0, 1, and 3. Requests specifying +// an invalid value will be rejected. Requests for policies with any +// conditional role bindings must specify version 3. Policies with no +// conditional role bindings may specify any valid value or leave the field +// unset. The policy in the response might use the policy version that you +// specified, or it might use a lower policy version. For example, if you +// specify version 3, but the policy has no conditional role bindings, the +// response uses version 1. To learn which resources support conditions in +// their IAM policies, see the IAM documentation +// (https://cloud.google.com/iam/help/conditions/resource-policies). +func (c *ProjectsLocationsFeatureOnlineStoresFeatureViewsGetIamPolicyCall) OptionsRequestedPolicyVersion(optionsRequestedPolicyVersion int64) *ProjectsLocationsFeatureOnlineStoresFeatureViewsGetIamPolicyCall { + c.urlParams_.Set("options.requestedPolicyVersion", fmt.Sprint(optionsRequestedPolicyVersion)) + 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 *ProjectsLocationsFeatureOnlineStoresFeatureViewsGetIamPolicyCall) Fields(s ...googleapi.Field) *ProjectsLocationsFeatureOnlineStoresFeatureViewsGetIamPolicyCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsFeatureOnlineStoresFeatureViewsGetIamPolicyCall) Context(ctx context.Context) *ProjectsLocationsFeatureOnlineStoresFeatureViewsGetIamPolicyCall { + 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 *ProjectsLocationsFeatureOnlineStoresFeatureViewsGetIamPolicyCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsFeatureOnlineStoresFeatureViewsGetIamPolicyCall) 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/{+resource}:getIamPolicy") + 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{ + "resource": c.resource, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "aiplatform.projects.locations.featureOnlineStores.featureViews.getIamPolicy" call. +// Any non-2xx status code is an error. Response headers are in either +// *GoogleIamV1Policy.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 *ProjectsLocationsFeatureOnlineStoresFeatureViewsGetIamPolicyCall) Do(opts ...googleapi.CallOption) (*GoogleIamV1Policy, 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 := &GoogleIamV1Policy{ + 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 ProjectsLocationsFeatureOnlineStoresFeatureViewsListCall struct { s *Service parent string @@ -52297,6 +52800,112 @@ func (c *ProjectsLocationsFeatureOnlineStoresFeatureViewsSearchNearestEntitiesCa return ret, nil } +type ProjectsLocationsFeatureOnlineStoresFeatureViewsSetIamPolicyCall struct { + s *Service + resource string + googleiamv1setiampolicyrequest *GoogleIamV1SetIamPolicyRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// SetIamPolicy: Sets the access control policy on the specified resource. +// Replaces any existing policy. Can return `NOT_FOUND`, `INVALID_ARGUMENT`, +// and `PERMISSION_DENIED` errors. +// +// - resource: REQUIRED: The resource for which the policy is being specified. +// See Resource names (https://cloud.google.com/apis/design/resource_names) +// for the appropriate value for this field. +func (r *ProjectsLocationsFeatureOnlineStoresFeatureViewsService) SetIamPolicy(resource string, googleiamv1setiampolicyrequest *GoogleIamV1SetIamPolicyRequest) *ProjectsLocationsFeatureOnlineStoresFeatureViewsSetIamPolicyCall { + c := &ProjectsLocationsFeatureOnlineStoresFeatureViewsSetIamPolicyCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.resource = resource + c.googleiamv1setiampolicyrequest = googleiamv1setiampolicyrequest + 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 *ProjectsLocationsFeatureOnlineStoresFeatureViewsSetIamPolicyCall) Fields(s ...googleapi.Field) *ProjectsLocationsFeatureOnlineStoresFeatureViewsSetIamPolicyCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsFeatureOnlineStoresFeatureViewsSetIamPolicyCall) Context(ctx context.Context) *ProjectsLocationsFeatureOnlineStoresFeatureViewsSetIamPolicyCall { + 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 *ProjectsLocationsFeatureOnlineStoresFeatureViewsSetIamPolicyCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsFeatureOnlineStoresFeatureViewsSetIamPolicyCall) 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.googleiamv1setiampolicyrequest) + if err != nil { + return nil, err + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+resource}:setIamPolicy") + 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{ + "resource": c.resource, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "aiplatform.projects.locations.featureOnlineStores.featureViews.setIamPolicy" call. +// Any non-2xx status code is an error. Response headers are in either +// *GoogleIamV1Policy.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 *ProjectsLocationsFeatureOnlineStoresFeatureViewsSetIamPolicyCall) Do(opts ...googleapi.CallOption) (*GoogleIamV1Policy, 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 := &GoogleIamV1Policy{ + 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 ProjectsLocationsFeatureOnlineStoresFeatureViewsSyncCall struct { s *Service featureView string @@ -52401,6 +53010,118 @@ func (c *ProjectsLocationsFeatureOnlineStoresFeatureViewsSyncCall) Do(opts ...go return ret, nil } +type ProjectsLocationsFeatureOnlineStoresFeatureViewsTestIamPermissionsCall struct { + s *Service + resource string + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// TestIamPermissions: Returns permissions that a caller has on the specified +// resource. If the resource does not exist, this will return an empty set of +// permissions, not a `NOT_FOUND` error. Note: This operation is designed to be +// used for building permission-aware UIs and command-line tools, not for +// authorization checking. This operation may "fail open" without warning. +// +// - resource: REQUIRED: The resource for which the policy detail is being +// requested. See Resource names +// (https://cloud.google.com/apis/design/resource_names) for the appropriate +// value for this field. +func (r *ProjectsLocationsFeatureOnlineStoresFeatureViewsService) TestIamPermissions(resource string) *ProjectsLocationsFeatureOnlineStoresFeatureViewsTestIamPermissionsCall { + c := &ProjectsLocationsFeatureOnlineStoresFeatureViewsTestIamPermissionsCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.resource = resource + return c +} + +// Permissions sets the optional parameter "permissions": The set of +// permissions to check for the `resource`. Permissions with wildcards (such as +// `*` or `storage.*`) are not allowed. For more information see IAM Overview +// (https://cloud.google.com/iam/docs/overview#permissions). +func (c *ProjectsLocationsFeatureOnlineStoresFeatureViewsTestIamPermissionsCall) Permissions(permissions ...string) *ProjectsLocationsFeatureOnlineStoresFeatureViewsTestIamPermissionsCall { + c.urlParams_.SetMulti("permissions", append([]string{}, permissions...)) + 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 *ProjectsLocationsFeatureOnlineStoresFeatureViewsTestIamPermissionsCall) Fields(s ...googleapi.Field) *ProjectsLocationsFeatureOnlineStoresFeatureViewsTestIamPermissionsCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsFeatureOnlineStoresFeatureViewsTestIamPermissionsCall) Context(ctx context.Context) *ProjectsLocationsFeatureOnlineStoresFeatureViewsTestIamPermissionsCall { + 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 *ProjectsLocationsFeatureOnlineStoresFeatureViewsTestIamPermissionsCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsFeatureOnlineStoresFeatureViewsTestIamPermissionsCall) 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/{+resource}:testIamPermissions") + 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{ + "resource": c.resource, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "aiplatform.projects.locations.featureOnlineStores.featureViews.testIamPermissions" call. +// Any non-2xx status code is an error. Response headers are in either +// *GoogleIamV1TestIamPermissionsResponse.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 *ProjectsLocationsFeatureOnlineStoresFeatureViewsTestIamPermissionsCall) Do(opts ...googleapi.CallOption) (*GoogleIamV1TestIamPermissionsResponse, 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 := &GoogleIamV1TestIamPermissionsResponse{ + 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 ProjectsLocationsFeatureOnlineStoresFeatureViewsFeatureViewSyncsGetCall struct { s *Service name string diff --git a/aiplatform/v1beta1/aiplatform-api.json b/aiplatform/v1beta1/aiplatform-api.json index 712436009e2..8a3a56881c8 100644 --- a/aiplatform/v1beta1/aiplatform-api.json +++ b/aiplatform/v1beta1/aiplatform-api.json @@ -2836,7 +2836,7 @@ "annotations": { "methods": { "list": { - "description": "Lists Annotations belongs to a dataitem", + "description": "Lists Annotations belongs to a dataitem This RPC is only available in InternalDatasetService. It is only used for exporting conversation data to CCAI Insights.", "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/datasets/{datasetsId}/dataItems/{dataItemsId}/annotations", "httpMethod": "GET", "id": "aiplatform.projects.locations.datasets.dataItems.annotations.list", @@ -5714,7 +5714,8 @@ "$ref": "GoogleCloudAiplatformV1beta1ListExtensionsResponse" }, "scopes": [ - "https://www.googleapis.com/auth/cloud-platform" + "https://www.googleapis.com/auth/cloud-platform", + "https://www.googleapis.com/auth/cloud-platform.read-only" ] }, "patch": { @@ -16493,6 +16494,34 @@ "scopes": [ "https://www.googleapis.com/auth/cloud-platform" ] + }, + "patch": { + "description": "Updates a RagCorpus.", + "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/ragCorpora/{ragCorporaId}", + "httpMethod": "PATCH", + "id": "aiplatform.projects.locations.ragCorpora.patch", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Output only. The resource name of the RagCorpus.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/ragCorpora/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1beta1/{+name}", + "request": { + "$ref": "GoogleCloudAiplatformV1beta1RagCorpus" + }, + "response": { + "$ref": "GoogleLongrunningOperation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] } }, "resources": { @@ -21058,7 +21087,7 @@ } } }, - "revision": "20240816", + "revision": "20240828", "rootUrl": "https://aiplatform.googleapis.com/", "schemas": { "CloudAiLargeModelsVisionGenerateVideoResponse": { @@ -21614,6 +21643,17 @@ }, "type": "object" }, + "GoogleCloudAiplatformV1beta1ApiAuth": { + "description": "The generic reusable api auth config.", + "id": "GoogleCloudAiplatformV1beta1ApiAuth", + "properties": { + "apiKeyConfig": { + "$ref": "GoogleCloudAiplatformV1beta1ApiAuthApiKeyConfig", + "description": "The API secret." + } + }, + "type": "object" + }, "GoogleCloudAiplatformV1beta1ApiAuthApiKeyConfig": { "description": "The API secret.", "id": "GoogleCloudAiplatformV1beta1ApiAuthApiKeyConfig", @@ -22854,6 +22894,43 @@ "format": "google-datetime", "readOnly": true, "type": "string" + }, + "usageMetadata": { + "$ref": "GoogleCloudAiplatformV1beta1CachedContentUsageMetadata", + "description": "Output only. Metadata on the usage of the cached content.", + "readOnly": true + } + }, + "type": "object" + }, + "GoogleCloudAiplatformV1beta1CachedContentUsageMetadata": { + "description": "Metadata on the usage of the cached content.", + "id": "GoogleCloudAiplatformV1beta1CachedContentUsageMetadata", + "properties": { + "audioDurationSeconds": { + "description": "Duration of audio in seconds.", + "format": "int32", + "type": "integer" + }, + "imageCount": { + "description": "Number of images.", + "format": "int32", + "type": "integer" + }, + "textCount": { + "description": "Number of text characters.", + "format": "int32", + "type": "integer" + }, + "totalTokenCount": { + "description": "Total number of tokens that the cached content consumes.", + "format": "int32", + "type": "integer" + }, + "videoDurationSeconds": { + "description": "Duration of video in seconds.", + "format": "int32", + "type": "integer" } }, "type": "object" @@ -23400,6 +23477,35 @@ }, "type": "object" }, + "GoogleCloudAiplatformV1beta1CorpusStatus": { + "description": "RagCorpus status.", + "id": "GoogleCloudAiplatformV1beta1CorpusStatus", + "properties": { + "errorStatus": { + "description": "Output only. Only when the `state` field is ERROR.", + "readOnly": true, + "type": "string" + }, + "state": { + "description": "Output only. RagCorpus life state.", + "enum": [ + "UNKNOWN", + "INITIALIZED", + "ACTIVE", + "ERROR" + ], + "enumDescriptions": [ + "This state is not supposed to happen.", + "RagCorpus resource entry is initialized, but hasn't done validation.", + "RagCorpus is provisioned successfully and is ready to serve.", + "RagCorpus is in a problematic situation. See `error_message` field for details." + ], + "readOnly": true, + "type": "string" + } + }, + "type": "object" + }, "GoogleCloudAiplatformV1beta1CountTokensRequest": { "description": "Request message for PredictionService.CountTokens.", "id": "GoogleCloudAiplatformV1beta1CountTokensRequest", @@ -27086,6 +27192,10 @@ "$ref": "GoogleCloudAiplatformV1beta1BigQuerySource", "description": "Required. Immutable. The BigQuery source URI that points to either a BigQuery Table or View." }, + "dense": { + "description": "Optional. If set, all feature values will be fetched from a single row per unique entityId including nulls. If not set, will collapse all rows for each unique entityId into a singe row with any non-null values if present, if no non-null values are present will sync null. ex: If source has schema (entity_id, feature_timestamp, f0, f1) and values (e1, 2020-01-01T10:00:00.123Z, 10, 15) (e1, 2020-02-01T10:00:00.123Z, 20, null) If dense is set, (e1, 20, null) is synced to online stores. If dense is not set, (e1, 20, 15) is synced to online stores.", + "type": "boolean" + }, "entityIdColumns": { "description": "Optional. Columns to construct entity_id / row keys. If not provided defaults to `entity_id`.", "items": { @@ -27093,6 +27203,10 @@ }, "type": "array" }, + "staticDataSource": { + "description": "Optional. Set if the data source is not a time-series.", + "type": "boolean" + }, "timeSeries": { "$ref": "GoogleCloudAiplatformV1beta1FeatureGroupBigQueryTimeSeries", "description": "Optional. If the source is a time-series source, this can be set to control how downstream sources (ex: FeatureView ) will treat time-series sources. If not set, will treat the source as a time-series source with `feature_timestamp` as timestamp column and no scan boundary." @@ -27547,6 +27661,10 @@ "$ref": "GoogleCloudAiplatformV1beta1FeatureViewVectorSearchConfig", "deprecated": true, "description": "Optional. Deprecated: please use FeatureView.index_config instead." + }, + "vertexRagSource": { + "$ref": "GoogleCloudAiplatformV1beta1FeatureViewVertexRagSource", + "description": "Optional. The Vertex RAG Source that the FeatureView is linked to." } }, "type": "object" @@ -27848,6 +27966,22 @@ }, "type": "object" }, + "GoogleCloudAiplatformV1beta1FeatureViewVertexRagSource": { + "description": "A Vertex Rag source for features that need to be synced to Online Store.", + "id": "GoogleCloudAiplatformV1beta1FeatureViewVertexRagSource", + "properties": { + "ragCorpusId": { + "description": "Optional. The RAG corpus id corresponding to this FeatureView.", + "format": "int64", + "type": "string" + }, + "uri": { + "description": "Required. The BigQuery view/table URI that will be materialized on each manual sync trigger. The table/view is expected to have the following columns at least: Field name Type Mode corpus_id STRING REQUIRED/NULLABLE file_id STRING REQUIRED/NULLABLE chunk_id STRING REQUIRED/NULLABLE chunk_data_type STRING REQUIRED/NULLABLE chunk_data STRING REQUIRED/NULLABLE embeddings FLOAT REPEATED file_original_uri STRING REQUIRED/NULLABLE", + "type": "string" + } + }, + "type": "object" + }, "GoogleCloudAiplatformV1beta1Featurestore": { "description": "Vertex AI Feature Store provides a centralized repository for organizing, storing, and serving ML features. The Featurestore is a top-level container for your features and their values.", "id": "GoogleCloudAiplatformV1beta1Featurestore", @@ -28172,6 +28306,33 @@ }, "type": "object" }, + "GoogleCloudAiplatformV1beta1FileStatus": { + "description": "RagFile status.", + "id": "GoogleCloudAiplatformV1beta1FileStatus", + "properties": { + "errorStatus": { + "description": "Output only. Only when the `state` field is ERROR.", + "readOnly": true, + "type": "string" + }, + "state": { + "description": "Output only. RagFile state.", + "enum": [ + "STATE_UNSPECIFIED", + "ACTIVE", + "ERROR" + ], + "enumDescriptions": [ + "RagFile state is unspecified.", + "RagFile resource has been created and indexed successfully.", + "RagFile resource is in a problematic state. See `error_message` field for details." + ], + "readOnly": true, + "type": "string" + } + }, + "type": "object" + }, "GoogleCloudAiplatformV1beta1FilterSplit": { "description": "Assigns input data to training, validation, and test sets based on the given filters, data pieces not matched by any filter are ignored. Currently only supported for Datasets containing DataItems. If any of the filters in this message are to match nothing, then they can be set as '-' (the minus sign). Supported only for unstructured Datasets. ", "id": "GoogleCloudAiplatformV1beta1FilterSplit", @@ -28548,7 +28709,7 @@ "description": "Properties of the object.", "type": "any" }, - "description": "Required. The function response in JSON object format.", + "description": "Required. The function response in JSON object format. Use \"output\" key to specify function output and \"error\" key to specify error details (if any). If \"output\" and \"error\" keys are not specified, then whole \"response\" is treated as function output.", "type": "object" } }, @@ -28725,6 +28886,12 @@ "description": "Usage metadata about response(s).", "id": "GoogleCloudAiplatformV1beta1GenerateContentResponseUsageMetadata", "properties": { + "cachedContentTokenCount": { + "description": "Output only. Number of tokens in the cached part in the input (the cached content).", + "format": "int32", + "readOnly": true, + "type": "integer" + }, "candidatesTokenCount": { "description": "Number of tokens in the response(s).", "format": "int32", @@ -28736,6 +28903,7 @@ "type": "integer" }, "totalTokenCount": { + "description": "Total token count for prompt and response candidates.", "format": "int32", "type": "integer" } @@ -37054,6 +37222,11 @@ "description": "A RagCorpus is a RagFile container and a project can have multiple RagCorpora.", "id": "GoogleCloudAiplatformV1beta1RagCorpus", "properties": { + "corpusStatus": { + "$ref": "GoogleCloudAiplatformV1beta1CorpusStatus", + "description": "Output only. RagCorpus state.", + "readOnly": true + }, "createTime": { "description": "Output only. Timestamp when this RagCorpus was created.", "format": "google-datetime", @@ -37077,6 +37250,10 @@ "$ref": "GoogleCloudAiplatformV1beta1RagEmbeddingModelConfig", "description": "Optional. Immutable. The embedding model config of the RagCorpus." }, + "ragVectorDbConfig": { + "$ref": "GoogleCloudAiplatformV1beta1RagVectorDbConfig", + "description": "Optional. Immutable. The Vector DB config of the RagCorpus." + }, "updateTime": { "description": "Output only. Timestamp when this RagCorpus was last updated.", "format": "google-datetime", @@ -37192,6 +37369,11 @@ "description": "Required. The display name of the RagFile. The name can be up to 128 characters long and can consist of any UTF-8 characters.", "type": "string" }, + "fileStatus": { + "$ref": "GoogleCloudAiplatformV1beta1FileStatus", + "description": "Output only. State of the RagFile.", + "readOnly": true + }, "gcsSource": { "$ref": "GoogleCloudAiplatformV1beta1GcsSource", "description": "Output only. Google Cloud Storage location of the RagFile. It does not support wildcards in the Cloud Storage uri for now.", @@ -37305,6 +37487,61 @@ }, "type": "object" }, + "GoogleCloudAiplatformV1beta1RagVectorDbConfig": { + "description": "Config for the Vector DB to use for RAG.", + "id": "GoogleCloudAiplatformV1beta1RagVectorDbConfig", + "properties": { + "apiAuth": { + "$ref": "GoogleCloudAiplatformV1beta1ApiAuth", + "description": "Authentication config for the chosen Vector DB." + }, + "ragManagedDb": { + "$ref": "GoogleCloudAiplatformV1beta1RagVectorDbConfigRagManagedDb", + "description": "The config for the RAG-managed Vector DB." + }, + "vertexFeatureStore": { + "$ref": "GoogleCloudAiplatformV1beta1RagVectorDbConfigVertexFeatureStore", + "description": "The config for the Vertex Feature Store." + }, + "weaviate": { + "$ref": "GoogleCloudAiplatformV1beta1RagVectorDbConfigWeaviate", + "description": "The config for the Weaviate." + } + }, + "type": "object" + }, + "GoogleCloudAiplatformV1beta1RagVectorDbConfigRagManagedDb": { + "description": "The config for the default RAG-managed Vector DB.", + "id": "GoogleCloudAiplatformV1beta1RagVectorDbConfigRagManagedDb", + "properties": {}, + "type": "object" + }, + "GoogleCloudAiplatformV1beta1RagVectorDbConfigVertexFeatureStore": { + "description": "The config for the Vertex Feature Store.", + "id": "GoogleCloudAiplatformV1beta1RagVectorDbConfigVertexFeatureStore", + "properties": { + "featureViewResourceName": { + "description": "The resource name of the FeatureView. Format: `projects/{project}/locations/{location}/featureOnlineStores/{feature_online_store}/featureViews/{feature_view}`", + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudAiplatformV1beta1RagVectorDbConfigWeaviate": { + "description": "The config for the Weaviate.", + "id": "GoogleCloudAiplatformV1beta1RagVectorDbConfigWeaviate", + "properties": { + "collectionName": { + "description": "The corresponding collection this corpus maps to. This value cannot be changed after it's set.", + "type": "string" + }, + "httpEndpoint": { + "description": "Weaviate DB instance HTTP endpoint. e.g. 34.56.78.90:8080 Vertex RAG only supports HTTP connection to Weaviate. This value cannot be changed after it's set.", + "type": "string" + } + }, + "type": "object" + }, "GoogleCloudAiplatformV1beta1RawPredictRequest": { "description": "Request message for PredictionService.RawPredict.", "id": "GoogleCloudAiplatformV1beta1RawPredictRequest", @@ -38688,7 +38925,7 @@ "LOW_COST", "STANDARD", "SPOT", - "DWS_FLEX_START" + "FLEX_START" ], "enumDeprecated": [ false, @@ -38704,7 +38941,7 @@ "Deprecated. Low cost by making potential use of spot resources.", "Standard provisioning strategy uses regular on-demand resources.", "Spot provisioning strategy uses spot resources.", - "DWS Flex start strategy uses DWS to queue for resources." + "Flex Start strategy uses DWS to queue for resources." ], "type": "string" }, @@ -38717,7 +38954,7 @@ "type": "object" }, "GoogleCloudAiplatformV1beta1Schema": { - "description": "Schema is used to define the format of input/output data. Represents a select subset of an [OpenAPI 3.0 schema object](https://spec.openapis.org/oas/v3.0.3#schema). More fields may be added in the future as needed.", + "description": "Schema is used to define the format of input/output data. Represents a select subset of an [OpenAPI 3.0 schema object](https://spec.openapis.org/oas/v3.0.3#schema-object). More fields may be added in the future as needed.", "id": "GoogleCloudAiplatformV1beta1Schema", "properties": { "default": { @@ -44282,7 +44519,7 @@ "type": "object" }, "GoogleCloudAiplatformV1beta1SyncFeatureViewResponse": { - "description": "Respose message for FeatureOnlineStoreAdminService.SyncFeatureView.", + "description": "Response message for FeatureOnlineStoreAdminService.SyncFeatureView.", "id": "GoogleCloudAiplatformV1beta1SyncFeatureViewResponse", "properties": { "featureViewSync": { diff --git a/aiplatform/v1beta1/aiplatform-gen.go b/aiplatform/v1beta1/aiplatform-gen.go index 1c6a0879bf3..0cdbb2dc4b5 100644 --- a/aiplatform/v1beta1/aiplatform-gen.go +++ b/aiplatform/v1beta1/aiplatform-gen.go @@ -2425,6 +2425,28 @@ func (s GoogleCloudAiplatformV1beta1AnnotationSpec) MarshalJSON() ([]byte, error return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudAiplatformV1beta1ApiAuth: The generic reusable api auth config. +type GoogleCloudAiplatformV1beta1ApiAuth struct { + // ApiKeyConfig: The API secret. + ApiKeyConfig *GoogleCloudAiplatformV1beta1ApiAuthApiKeyConfig `json:"apiKeyConfig,omitempty"` + // ForceSendFields is a list of field names (e.g. "ApiKeyConfig") 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. "ApiKeyConfig") 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 GoogleCloudAiplatformV1beta1ApiAuth) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudAiplatformV1beta1ApiAuth + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudAiplatformV1beta1ApiAuthApiKeyConfig: The API secret. type GoogleCloudAiplatformV1beta1ApiAuthApiKeyConfig struct { // ApiKeySecretVersion: Required. The SecretManager secret version resource @@ -4355,6 +4377,8 @@ type GoogleCloudAiplatformV1beta1CachedContent struct { Ttl string `json:"ttl,omitempty"` // UpdateTime: Output only. When the cache entry was last updated in UTC time. UpdateTime string `json:"updateTime,omitempty"` + // UsageMetadata: Output only. Metadata on the usage of the cached content. + UsageMetadata *GoogleCloudAiplatformV1beta1CachedContentUsageMetadata `json:"usageMetadata,omitempty"` // ServerResponse contains the HTTP response code and headers from the server. googleapi.ServerResponse `json:"-"` @@ -4376,6 +4400,37 @@ func (s GoogleCloudAiplatformV1beta1CachedContent) MarshalJSON() ([]byte, error) return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudAiplatformV1beta1CachedContentUsageMetadata: Metadata on the +// usage of the cached content. +type GoogleCloudAiplatformV1beta1CachedContentUsageMetadata struct { + // AudioDurationSeconds: Duration of audio in seconds. + AudioDurationSeconds int64 `json:"audioDurationSeconds,omitempty"` + // ImageCount: Number of images. + ImageCount int64 `json:"imageCount,omitempty"` + // TextCount: Number of text characters. + TextCount int64 `json:"textCount,omitempty"` + // TotalTokenCount: Total number of tokens that the cached content consumes. + TotalTokenCount int64 `json:"totalTokenCount,omitempty"` + // VideoDurationSeconds: Duration of video in seconds. + VideoDurationSeconds int64 `json:"videoDurationSeconds,omitempty"` + // ForceSendFields is a list of field names (e.g. "AudioDurationSeconds") 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. "AudioDurationSeconds") 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 GoogleCloudAiplatformV1beta1CachedContentUsageMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudAiplatformV1beta1CachedContentUsageMetadata + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudAiplatformV1beta1CancelBatchPredictionJobRequest: Request message // for JobService.CancelBatchPredictionJob. type GoogleCloudAiplatformV1beta1CancelBatchPredictionJobRequest struct { @@ -5079,6 +5134,38 @@ func (s GoogleCloudAiplatformV1beta1CopyModelResponse) MarshalJSON() ([]byte, er return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudAiplatformV1beta1CorpusStatus: RagCorpus status. +type GoogleCloudAiplatformV1beta1CorpusStatus struct { + // ErrorStatus: Output only. Only when the `state` field is ERROR. + ErrorStatus string `json:"errorStatus,omitempty"` + // State: Output only. RagCorpus life state. + // + // Possible values: + // "UNKNOWN" - This state is not supposed to happen. + // "INITIALIZED" - RagCorpus resource entry is initialized, but hasn't done + // validation. + // "ACTIVE" - RagCorpus is provisioned successfully and is ready to serve. + // "ERROR" - RagCorpus is in a problematic situation. See `error_message` + // field for details. + State string `json:"state,omitempty"` + // ForceSendFields is a list of field names (e.g. "ErrorStatus") 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. "ErrorStatus") 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 GoogleCloudAiplatformV1beta1CorpusStatus) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudAiplatformV1beta1CorpusStatus + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudAiplatformV1beta1CountTokensRequest: Request message for // PredictionService.CountTokens. type GoogleCloudAiplatformV1beta1CountTokensRequest struct { @@ -10263,9 +10350,20 @@ type GoogleCloudAiplatformV1beta1FeatureGroupBigQuery struct { // BigQuerySource: Required. Immutable. The BigQuery source URI that points to // either a BigQuery Table or View. BigQuerySource *GoogleCloudAiplatformV1beta1BigQuerySource `json:"bigQuerySource,omitempty"` + // Dense: Optional. If set, all feature values will be fetched from a single + // row per unique entityId including nulls. If not set, will collapse all rows + // for each unique entityId into a singe row with any non-null values if + // present, if no non-null values are present will sync null. ex: If source has + // schema (entity_id, feature_timestamp, f0, f1) and values (e1, + // 2020-01-01T10:00:00.123Z, 10, 15) (e1, 2020-02-01T10:00:00.123Z, 20, null) + // If dense is set, (e1, 20, null) is synced to online stores. If dense is not + // set, (e1, 20, 15) is synced to online stores. + Dense bool `json:"dense,omitempty"` // EntityIdColumns: Optional. Columns to construct entity_id / row keys. If not // provided defaults to `entity_id`. EntityIdColumns []string `json:"entityIdColumns,omitempty"` + // StaticDataSource: Optional. Set if the data source is not a time-series. + StaticDataSource bool `json:"staticDataSource,omitempty"` // TimeSeries: Optional. If the source is a time-series source, this can be set // to control how downstream sources (ex: FeatureView ) will treat time-series // sources. If not set, will treat the source as a time-series source with @@ -10935,6 +11033,9 @@ type GoogleCloudAiplatformV1beta1FeatureView struct { // VectorSearchConfig: Optional. Deprecated: please use // FeatureView.index_config instead. VectorSearchConfig *GoogleCloudAiplatformV1beta1FeatureViewVectorSearchConfig `json:"vectorSearchConfig,omitempty"` + // VertexRagSource: Optional. The Vertex RAG Source that the FeatureView is + // linked to. + VertexRagSource *GoogleCloudAiplatformV1beta1FeatureViewVertexRagSource `json:"vertexRagSource,omitempty"` // ServerResponse contains the HTTP response code and headers from the server. googleapi.ServerResponse `json:"-"` @@ -11360,6 +11461,36 @@ func (s GoogleCloudAiplatformV1beta1FeatureViewVectorSearchConfigTreeAHConfig) M return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudAiplatformV1beta1FeatureViewVertexRagSource: A Vertex Rag source +// for features that need to be synced to Online Store. +type GoogleCloudAiplatformV1beta1FeatureViewVertexRagSource struct { + // RagCorpusId: Optional. The RAG corpus id corresponding to this FeatureView. + RagCorpusId int64 `json:"ragCorpusId,omitempty,string"` + // Uri: Required. The BigQuery view/table URI that will be materialized on each + // manual sync trigger. The table/view is expected to have the following + // columns at least: Field name Type Mode corpus_id STRING REQUIRED/NULLABLE + // file_id STRING REQUIRED/NULLABLE chunk_id STRING REQUIRED/NULLABLE + // chunk_data_type STRING REQUIRED/NULLABLE chunk_data STRING REQUIRED/NULLABLE + // embeddings FLOAT REPEATED file_original_uri STRING REQUIRED/NULLABLE + Uri string `json:"uri,omitempty"` + // ForceSendFields is a list of field names (e.g. "RagCorpusId") 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. "RagCorpusId") 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 GoogleCloudAiplatformV1beta1FeatureViewVertexRagSource) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudAiplatformV1beta1FeatureViewVertexRagSource + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudAiplatformV1beta1Featurestore: Vertex AI Feature Store provides a // centralized repository for organizing, storing, and serving ML features. The // Featurestore is a top-level container for your features and their values. @@ -11835,6 +11966,36 @@ func (s GoogleCloudAiplatformV1beta1FileData) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudAiplatformV1beta1FileStatus: RagFile status. +type GoogleCloudAiplatformV1beta1FileStatus struct { + // ErrorStatus: Output only. Only when the `state` field is ERROR. + ErrorStatus string `json:"errorStatus,omitempty"` + // State: Output only. RagFile state. + // + // Possible values: + // "STATE_UNSPECIFIED" - RagFile state is unspecified. + // "ACTIVE" - RagFile resource has been created and indexed successfully. + // "ERROR" - RagFile resource is in a problematic state. See `error_message` + // field for details. + State string `json:"state,omitempty"` + // ForceSendFields is a list of field names (e.g. "ErrorStatus") 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. "ErrorStatus") 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 GoogleCloudAiplatformV1beta1FileStatus) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudAiplatformV1beta1FileStatus + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudAiplatformV1beta1FilterSplit: Assigns input data to training, // validation, and test sets based on the given filters, data pieces not // matched by any filter are ignored. Currently only supported for Datasets @@ -12514,7 +12675,10 @@ type GoogleCloudAiplatformV1beta1FunctionResponse struct { // Name: Required. The name of the function to call. Matches // [FunctionDeclaration.name] and [FunctionCall.name]. Name string `json:"name,omitempty"` - // Response: Required. The function response in JSON object format. + // Response: Required. The function response in JSON object format. Use + // "output" key to specify function output and "error" key to specify error + // details (if any). If "output" and "error" keys are not specified, then whole + // "response" is treated as function output. Response googleapi.RawMessage `json:"response,omitempty"` // ForceSendFields is a list of field names (e.g. "Name") to unconditionally // include in API requests. By default, fields with empty or default values are @@ -12764,22 +12928,26 @@ func (s GoogleCloudAiplatformV1beta1GenerateContentResponsePromptFeedback) Marsh // GoogleCloudAiplatformV1beta1GenerateContentResponseUsageMetadata: Usage // metadata about response(s). type GoogleCloudAiplatformV1beta1GenerateContentResponseUsageMetadata struct { + // CachedContentTokenCount: Output only. Number of tokens in the cached part in + // the input (the cached content). + CachedContentTokenCount int64 `json:"cachedContentTokenCount,omitempty"` // CandidatesTokenCount: Number of tokens in the response(s). CandidatesTokenCount int64 `json:"candidatesTokenCount,omitempty"` // PromptTokenCount: Number of tokens in the request. When `cached_content` is // set, this is still the total effective prompt size meaning this includes the // number of tokens in the cached content. PromptTokenCount int64 `json:"promptTokenCount,omitempty"` - TotalTokenCount int64 `json:"totalTokenCount,omitempty"` - // ForceSendFields is a list of field names (e.g. "CandidatesTokenCount") to + // TotalTokenCount: Total token count for prompt and response candidates. + TotalTokenCount int64 `json:"totalTokenCount,omitempty"` + // ForceSendFields is a list of field names (e.g. "CachedContentTokenCount") 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. "CandidatesTokenCount") to include - // in API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. See + // NullFields is a list of field names (e.g. "CachedContentTokenCount") 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:"-"` } @@ -24237,6 +24405,8 @@ func (s *GoogleCloudAiplatformV1beta1RagContextsContext) UnmarshalJSON(data []by // GoogleCloudAiplatformV1beta1RagCorpus: A RagCorpus is a RagFile container // and a project can have multiple RagCorpora. type GoogleCloudAiplatformV1beta1RagCorpus struct { + // CorpusStatus: Output only. RagCorpus state. + CorpusStatus *GoogleCloudAiplatformV1beta1CorpusStatus `json:"corpusStatus,omitempty"` // CreateTime: Output only. Timestamp when this RagCorpus was created. CreateTime string `json:"createTime,omitempty"` // Description: Optional. The description of the RagCorpus. @@ -24249,18 +24419,21 @@ type GoogleCloudAiplatformV1beta1RagCorpus struct { // RagEmbeddingModelConfig: Optional. Immutable. The embedding model config of // the RagCorpus. RagEmbeddingModelConfig *GoogleCloudAiplatformV1beta1RagEmbeddingModelConfig `json:"ragEmbeddingModelConfig,omitempty"` + // RagVectorDbConfig: Optional. Immutable. The Vector DB config of the + // RagCorpus. + RagVectorDbConfig *GoogleCloudAiplatformV1beta1RagVectorDbConfig `json:"ragVectorDbConfig,omitempty"` // UpdateTime: Output only. Timestamp when this RagCorpus was last updated. 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. "CreateTime") to + // ForceSendFields is a list of field names (e.g. "CorpusStatus") 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. "CreateTime") to include in API + // NullFields is a list of field names (e.g. "CorpusStatus") 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. @@ -24446,6 +24619,8 @@ type GoogleCloudAiplatformV1beta1RagFile struct { // DisplayName: Required. The display name of the RagFile. The name can be up // to 128 characters long and can consist of any UTF-8 characters. DisplayName string `json:"displayName,omitempty"` + // FileStatus: Output only. State of the RagFile. + FileStatus *GoogleCloudAiplatformV1beta1FileStatus `json:"fileStatus,omitempty"` // GcsSource: Output only. Google Cloud Storage location of the RagFile. It // does not support wildcards in the Cloud Storage uri for now. GcsSource *GoogleCloudAiplatformV1beta1GcsSource `json:"gcsSource,omitempty"` @@ -24604,6 +24779,93 @@ func (s *GoogleCloudAiplatformV1beta1RagQueryRanking) UnmarshalJSON(data []byte) return nil } +// GoogleCloudAiplatformV1beta1RagVectorDbConfig: Config for the Vector DB to +// use for RAG. +type GoogleCloudAiplatformV1beta1RagVectorDbConfig struct { + // ApiAuth: Authentication config for the chosen Vector DB. + ApiAuth *GoogleCloudAiplatformV1beta1ApiAuth `json:"apiAuth,omitempty"` + // RagManagedDb: The config for the RAG-managed Vector DB. + RagManagedDb *GoogleCloudAiplatformV1beta1RagVectorDbConfigRagManagedDb `json:"ragManagedDb,omitempty"` + // VertexFeatureStore: The config for the Vertex Feature Store. + VertexFeatureStore *GoogleCloudAiplatformV1beta1RagVectorDbConfigVertexFeatureStore `json:"vertexFeatureStore,omitempty"` + // Weaviate: The config for the Weaviate. + Weaviate *GoogleCloudAiplatformV1beta1RagVectorDbConfigWeaviate `json:"weaviate,omitempty"` + // ForceSendFields is a list of field names (e.g. "ApiAuth") 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. "ApiAuth") 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 GoogleCloudAiplatformV1beta1RagVectorDbConfig) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudAiplatformV1beta1RagVectorDbConfig + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudAiplatformV1beta1RagVectorDbConfigRagManagedDb: The config for +// the default RAG-managed Vector DB. +type GoogleCloudAiplatformV1beta1RagVectorDbConfigRagManagedDb struct { +} + +// GoogleCloudAiplatformV1beta1RagVectorDbConfigVertexFeatureStore: The config +// for the Vertex Feature Store. +type GoogleCloudAiplatformV1beta1RagVectorDbConfigVertexFeatureStore struct { + // FeatureViewResourceName: The resource name of the FeatureView. Format: + // `projects/{project}/locations/{location}/featureOnlineStores/{feature_online_ + // store}/featureViews/{feature_view}` + FeatureViewResourceName string `json:"featureViewResourceName,omitempty"` + // ForceSendFields is a list of field names (e.g. "FeatureViewResourceName") 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. "FeatureViewResourceName") 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 GoogleCloudAiplatformV1beta1RagVectorDbConfigVertexFeatureStore) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudAiplatformV1beta1RagVectorDbConfigVertexFeatureStore + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudAiplatformV1beta1RagVectorDbConfigWeaviate: The config for the +// Weaviate. +type GoogleCloudAiplatformV1beta1RagVectorDbConfigWeaviate struct { + // CollectionName: The corresponding collection this corpus maps to. This value + // cannot be changed after it's set. + CollectionName string `json:"collectionName,omitempty"` + // HttpEndpoint: Weaviate DB instance HTTP endpoint. e.g. 34.56.78.90:8080 + // Vertex RAG only supports HTTP connection to Weaviate. This value cannot be + // changed after it's set. + HttpEndpoint string `json:"httpEndpoint,omitempty"` + // ForceSendFields is a list of field names (e.g. "CollectionName") 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. "CollectionName") 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 GoogleCloudAiplatformV1beta1RagVectorDbConfigWeaviate) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudAiplatformV1beta1RagVectorDbConfigWeaviate + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudAiplatformV1beta1RawPredictRequest: Request message for // PredictionService.RawPredict. type GoogleCloudAiplatformV1beta1RawPredictRequest struct { @@ -26654,8 +26916,7 @@ type GoogleCloudAiplatformV1beta1Scheduling struct { // "STANDARD" - Standard provisioning strategy uses regular on-demand // resources. // "SPOT" - Spot provisioning strategy uses spot resources. - // "DWS_FLEX_START" - DWS Flex start strategy uses DWS to queue for - // resources. + // "FLEX_START" - Flex Start strategy uses DWS to queue for resources. Strategy string `json:"strategy,omitempty"` // Timeout: The maximum job running time. The default is 7 days. Timeout string `json:"timeout,omitempty"` @@ -26679,8 +26940,8 @@ func (s GoogleCloudAiplatformV1beta1Scheduling) MarshalJSON() ([]byte, error) { // GoogleCloudAiplatformV1beta1Schema: Schema is used to define the format of // input/output data. Represents a select subset of an OpenAPI 3.0 schema -// object (https://spec.openapis.org/oas/v3.0.3#schema). More fields may be -// added in the future as needed. +// object (https://spec.openapis.org/oas/v3.0.3#schema-object). More fields may +// be added in the future as needed. type GoogleCloudAiplatformV1beta1Schema struct { // Default: Optional. Default value of the data. Default interface{} `json:"default,omitempty"` @@ -35580,7 +35841,7 @@ func (s GoogleCloudAiplatformV1beta1SupervisedTuningSpec) MarshalJSON() ([]byte, type GoogleCloudAiplatformV1beta1SyncFeatureViewRequest struct { } -// GoogleCloudAiplatformV1beta1SyncFeatureViewResponse: Respose message for +// GoogleCloudAiplatformV1beta1SyncFeatureViewResponse: Response message for // FeatureOnlineStoreAdminService.SyncFeatureView. type GoogleCloudAiplatformV1beta1SyncFeatureViewResponse struct { // FeatureViewSync: Format: @@ -48347,7 +48608,9 @@ type ProjectsLocationsDatasetsDataItemsAnnotationsListCall struct { header_ http.Header } -// List: Lists Annotations belongs to a dataitem +// List: Lists Annotations belongs to a dataitem This RPC is only available in +// InternalDatasetService. It is only used for exporting conversation data to +// CCAI Insights. // // - parent: The resource name of the DataItem to list Annotations from. // Format: @@ -98826,6 +99089,108 @@ func (c *ProjectsLocationsRagCorporaListCall) Pages(ctx context.Context, f func( } } +type ProjectsLocationsRagCorporaPatchCall struct { + s *Service + name string + googlecloudaiplatformv1beta1ragcorpus *GoogleCloudAiplatformV1beta1RagCorpus + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Patch: Updates a RagCorpus. +// +// - name: Output only. The resource name of the RagCorpus. +func (r *ProjectsLocationsRagCorporaService) Patch(name string, googlecloudaiplatformv1beta1ragcorpus *GoogleCloudAiplatformV1beta1RagCorpus) *ProjectsLocationsRagCorporaPatchCall { + c := &ProjectsLocationsRagCorporaPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + c.googlecloudaiplatformv1beta1ragcorpus = googlecloudaiplatformv1beta1ragcorpus + 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 *ProjectsLocationsRagCorporaPatchCall) Fields(s ...googleapi.Field) *ProjectsLocationsRagCorporaPatchCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsRagCorporaPatchCall) Context(ctx context.Context) *ProjectsLocationsRagCorporaPatchCall { + 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 *ProjectsLocationsRagCorporaPatchCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsRagCorporaPatchCall) 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.googlecloudaiplatformv1beta1ragcorpus) + if err != nil { + return nil, err + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+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 "aiplatform.projects.locations.ragCorpora.patch" call. +// Any non-2xx status code is an error. Response headers are in either +// *GoogleLongrunningOperation.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 *ProjectsLocationsRagCorporaPatchCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, 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 := &GoogleLongrunningOperation{ + 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 ProjectsLocationsRagCorporaOperationsCancelCall struct { s *Service name string diff --git a/alloydb/v1/alloydb-api.json b/alloydb/v1/alloydb-api.json index 0cd09718937..bc792f08397 100644 --- a/alloydb/v1/alloydb-api.json +++ b/alloydb/v1/alloydb-api.json @@ -735,6 +735,34 @@ "scopes": [ "https://www.googleapis.com/auth/cloud-platform" ] + }, + "upgrade": { + "description": "Upgrades a single Cluster. Imperative only.", + "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/clusters/{clustersId}:upgrade", + "httpMethod": "PATCH", + "id": "alloydb.projects.locations.clusters.upgrade", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Required. The resource name of the cluster.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/clusters/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1/{+name}:upgrade", + "request": { + "$ref": "UpgradeClusterRequest" + }, + "response": { + "$ref": "Operation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] } }, "resources": { @@ -1489,7 +1517,7 @@ } } }, - "revision": "20240823", + "revision": "20240828", "rootUrl": "https://alloydb.googleapis.com/", "schemas": { "AuthorizedNetwork": { @@ -2063,12 +2091,16 @@ "description": "Upgrade status of the cluster.", "enum": [ "STATUS_UNSPECIFIED", + "NOT_STARTED", + "IN_PROGRESS", "SUCCESS", "FAILED", "PARTIAL_SUCCESS" ], "enumDescriptions": [ "Unspecified status.", + "Not started.", + "In progress.", "Operation succeeded.", "Operation failed.", "Operation partially succeeded." @@ -2469,6 +2501,14 @@ "readOnly": true, "type": "array" }, + "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." @@ -2553,6 +2593,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" @@ -2588,12 +2632,16 @@ "description": "Upgrade status of the instance.", "enum": [ "STATUS_UNSPECIFIED", + "NOT_STARTED", + "IN_PROGRESS", "SUCCESS", "FAILED", "PARTIAL_SUCCESS" ], "enumDescriptions": [ "Unspecified status.", + "Not started.", + "In progress.", "Operation succeeded.", "Operation failed.", "Operation partially succeeded." @@ -3238,15 +3286,21 @@ "STAGE_UNSPECIFIED", "ALLOYDB_PRECHECK", "PG_UPGRADE_CHECK", + "PREPARE_FOR_UPGRADE", "PRIMARY_INSTANCE_UPGRADE", - "READ_POOL_UPGRADE" + "READ_POOL_INSTANCES_UPGRADE", + "ROLLBACK", + "CLEANUP" ], "enumDescriptions": [ "Unspecified stage.", - "This stage is for the custom checks done before upgrade.", - "This stage is for `pg_upgrade --check` run before upgrade.", - "This stage is primary upgrade.", - "This stage is read pool upgrade." + "Pre-upgrade custom checks, not covered by pg_upgrade.", + "Pre-upgrade pg_upgrade checks.", + "Clone the original cluster.", + "Upgrade the primary instance(downtime).", + "This stage is read pool upgrade.", + "Rollback in case of critical failures.", + "Cleanup." ], "type": "string" }, @@ -3254,12 +3308,16 @@ "description": "Status of the stage.", "enum": [ "STATUS_UNSPECIFIED", + "NOT_STARTED", + "IN_PROGRESS", "SUCCESS", "FAILED", "PARTIAL_SUCCESS" ], "enumDescriptions": [ "Unspecified status.", + "Not started.", + "In progress.", "Operation succeeded.", "Operation failed.", "Operation partially succeeded." @@ -4826,6 +4884,47 @@ }, "type": "object" }, + "UpgradeClusterRequest": { + "description": "Upgrades a cluster.", + "id": "UpgradeClusterRequest", + "properties": { + "etag": { + "description": "Optional. The current etag of the Cluster. If an etag is provided and does not match the current etag of the Cluster, upgrade will be blocked and an ABORTED error will be returned.", + "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).", + "type": "string" + }, + "validateOnly": { + "description": "Optional. If set, performs request validation (e.g. permission checks and any other type of validation), but does not actually execute the upgrade.", + "type": "boolean" + }, + "version": { + "description": "Required. The version the cluster is going to be upgraded to.", + "enum": [ + "DATABASE_VERSION_UNSPECIFIED", + "POSTGRES_13", + "POSTGRES_14", + "POSTGRES_15" + ], + "enumDeprecated": [ + false, + true, + false, + false + ], + "enumDescriptions": [ + "This is an unknown database version.", + "DEPRECATED - The database version is Postgres 13.", + "The database version is Postgres 14.", + "The database version is Postgres 15." + ], + "type": "string" + } + }, + "type": "object" + }, "UpgradeClusterResponse": { "description": "UpgradeClusterResponse contains the response for upgrade cluster operation.", "id": "UpgradeClusterResponse", @@ -4845,12 +4944,16 @@ "description": "Status of upgrade operation.", "enum": [ "STATUS_UNSPECIFIED", + "NOT_STARTED", + "IN_PROGRESS", "SUCCESS", "FAILED", "PARTIAL_SUCCESS" ], "enumDescriptions": [ "Unspecified status.", + "Not started.", + "In progress.", "Operation succeeded.", "Operation failed.", "Operation partially succeeded." diff --git a/alloydb/v1/alloydb-gen.go b/alloydb/v1/alloydb-gen.go index 5e614af7c90..e93dcea8c95 100644 --- a/alloydb/v1/alloydb-gen.go +++ b/alloydb/v1/alloydb-gen.go @@ -721,6 +721,8 @@ type ClusterUpgradeDetails struct { // // Possible values: // "STATUS_UNSPECIFIED" - Unspecified status. + // "NOT_STARTED" - Not started. + // "IN_PROGRESS" - In progress. // "SUCCESS" - Operation succeeded. // "FAILED" - Operation failed. // "PARTIAL_SUCCESS" - Operation partially succeeded. @@ -1214,6 +1216,9 @@ type Instance struct { // Nodes: Output only. List of available read-only VMs in this instance, // including the standby for a PRIMARY instance. Nodes []*Node `json:"nodes,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"` @@ -1290,6 +1295,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") @@ -1332,6 +1340,8 @@ type InstanceUpgradeDetails struct { // // Possible values: // "STATUS_UNSPECIFIED" - Unspecified status. + // "NOT_STARTED" - Not started. + // "IN_PROGRESS" - In progress. // "SUCCESS" - Operation succeeded. // "FAILED" - Operation failed. // "PARTIAL_SUCCESS" - Operation partially succeeded. @@ -2245,17 +2255,20 @@ type StageInfo struct { // // Possible values: // "STAGE_UNSPECIFIED" - Unspecified stage. - // "ALLOYDB_PRECHECK" - This stage is for the custom checks done before - // upgrade. - // "PG_UPGRADE_CHECK" - This stage is for `pg_upgrade --check` run before - // upgrade. - // "PRIMARY_INSTANCE_UPGRADE" - This stage is primary upgrade. - // "READ_POOL_UPGRADE" - This stage is read pool upgrade. + // "ALLOYDB_PRECHECK" - Pre-upgrade custom checks, not covered by pg_upgrade. + // "PG_UPGRADE_CHECK" - Pre-upgrade pg_upgrade checks. + // "PREPARE_FOR_UPGRADE" - Clone the original cluster. + // "PRIMARY_INSTANCE_UPGRADE" - Upgrade the primary instance(downtime). + // "READ_POOL_INSTANCES_UPGRADE" - This stage is read pool upgrade. + // "ROLLBACK" - Rollback in case of critical failures. + // "CLEANUP" - Cleanup. Stage string `json:"stage,omitempty"` // Status: Status of the stage. // // Possible values: // "STATUS_UNSPECIFIED" - Unspecified status. + // "NOT_STARTED" - Not started. + // "IN_PROGRESS" - In progress. // "SUCCESS" - Operation succeeded. // "FAILED" - Operation failed. // "PARTIAL_SUCCESS" - Operation partially succeeded. @@ -3738,6 +3751,54 @@ func (s TrialMetadata) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// UpgradeClusterRequest: Upgrades a cluster. +type UpgradeClusterRequest struct { + // Etag: Optional. The current etag of the Cluster. If an etag is provided and + // does not match the current etag of the Cluster, upgrade will be blocked and + // an ABORTED error will be returned. + Etag string `json:"etag,omitempty"` + // RequestId: 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). + RequestId string `json:"requestId,omitempty"` + // ValidateOnly: Optional. If set, performs request validation (e.g. permission + // checks and any other type of validation), but does not actually execute the + // upgrade. + ValidateOnly bool `json:"validateOnly,omitempty"` + // Version: Required. The version the cluster is going to be upgraded to. + // + // Possible values: + // "DATABASE_VERSION_UNSPECIFIED" - This is an unknown database version. + // "POSTGRES_13" - DEPRECATED - The database version is Postgres 13. + // "POSTGRES_14" - The database version is Postgres 14. + // "POSTGRES_15" - The database version is Postgres 15. + Version string `json:"version,omitempty"` + // ForceSendFields is a list of field names (e.g. "Etag") 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. "Etag") 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 UpgradeClusterRequest) MarshalJSON() ([]byte, error) { + type NoMethod UpgradeClusterRequest + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // UpgradeClusterResponse: UpgradeClusterResponse contains the response for // upgrade cluster operation. type UpgradeClusterResponse struct { @@ -3751,6 +3812,8 @@ type UpgradeClusterResponse struct { // // Possible values: // "STATUS_UNSPECIFIED" - Unspecified status. + // "NOT_STARTED" - Not started. + // "IN_PROGRESS" - In progress. // "SUCCESS" - Operation succeeded. // "FAILED" - Operation failed. // "PARTIAL_SUCCESS" - Operation partially succeeded. @@ -5969,6 +6032,107 @@ func (c *ProjectsLocationsClustersSwitchoverCall) Do(opts ...googleapi.CallOptio return ret, nil } +type ProjectsLocationsClustersUpgradeCall struct { + s *Service + name string + upgradeclusterrequest *UpgradeClusterRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Upgrade: Upgrades a single Cluster. Imperative only. +// +// - name: The resource name of the cluster. +func (r *ProjectsLocationsClustersService) Upgrade(name string, upgradeclusterrequest *UpgradeClusterRequest) *ProjectsLocationsClustersUpgradeCall { + c := &ProjectsLocationsClustersUpgradeCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + c.upgradeclusterrequest = upgradeclusterrequest + 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 *ProjectsLocationsClustersUpgradeCall) Fields(s ...googleapi.Field) *ProjectsLocationsClustersUpgradeCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsClustersUpgradeCall) Context(ctx context.Context) *ProjectsLocationsClustersUpgradeCall { + 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 *ProjectsLocationsClustersUpgradeCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsClustersUpgradeCall) 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.upgradeclusterrequest) + if err != nil { + return nil, err + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}:upgrade") + 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 "alloydb.projects.locations.clusters.upgrade" 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 *ProjectsLocationsClustersUpgradeCall) 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 ProjectsLocationsClustersInstancesCreateCall struct { s *Service parent string diff --git a/alloydb/v1alpha/alloydb-api.json b/alloydb/v1alpha/alloydb-api.json index 6302585e1aa..655c5613883 100644 --- a/alloydb/v1alpha/alloydb-api.json +++ b/alloydb/v1alpha/alloydb-api.json @@ -1517,7 +1517,7 @@ } } }, - "revision": "20240823", + "revision": "20240828", "rootUrl": "https://alloydb.googleapis.com/", "schemas": { "AuthorizedNetwork": { @@ -2139,12 +2139,16 @@ "description": "Upgrade status of the cluster.", "enum": [ "STATUS_UNSPECIFIED", + "NOT_STARTED", + "IN_PROGRESS", "SUCCESS", "FAILED", "PARTIAL_SUCCESS" ], "enumDescriptions": [ "Unspecified status.", + "Not started.", + "In progress.", "Operation succeeded.", "Operation failed.", "Operation partially succeeded." @@ -2731,12 +2735,16 @@ "description": "Upgrade status of the instance.", "enum": [ "STATUS_UNSPECIFIED", + "NOT_STARTED", + "IN_PROGRESS", "SUCCESS", "FAILED", "PARTIAL_SUCCESS" ], "enumDescriptions": [ "Unspecified status.", + "Not started.", + "In progress.", "Operation succeeded.", "Operation failed.", "Operation partially succeeded." @@ -3427,15 +3435,21 @@ "STAGE_UNSPECIFIED", "ALLOYDB_PRECHECK", "PG_UPGRADE_CHECK", + "PREPARE_FOR_UPGRADE", "PRIMARY_INSTANCE_UPGRADE", - "READ_POOL_UPGRADE" + "READ_POOL_INSTANCES_UPGRADE", + "ROLLBACK", + "CLEANUP" ], "enumDescriptions": [ "Unspecified stage.", - "This stage is for the custom checks done before upgrade.", - "This stage is for `pg_upgrade --check` run before upgrade.", - "This stage is primary upgrade.", - "This stage is read pool upgrade." + "Pre-upgrade custom checks, not covered by pg_upgrade.", + "Pre-upgrade pg_upgrade checks.", + "Clone the original cluster.", + "Upgrade the primary instance(downtime).", + "This stage is read pool upgrade.", + "Rollback in case of critical failures.", + "Cleanup." ], "type": "string" }, @@ -3443,12 +3457,16 @@ "description": "Status of the stage.", "enum": [ "STATUS_UNSPECIFIED", + "NOT_STARTED", + "IN_PROGRESS", "SUCCESS", "FAILED", "PARTIAL_SUCCESS" ], "enumDescriptions": [ "Unspecified status.", + "Not started.", + "In progress.", "Operation succeeded.", "Operation failed.", "Operation partially succeeded." @@ -5102,12 +5120,16 @@ "description": "Status of upgrade operation.", "enum": [ "STATUS_UNSPECIFIED", + "NOT_STARTED", + "IN_PROGRESS", "SUCCESS", "FAILED", "PARTIAL_SUCCESS" ], "enumDescriptions": [ "Unspecified status.", + "Not started.", + "In progress.", "Operation succeeded.", "Operation failed.", "Operation partially succeeded." diff --git a/alloydb/v1alpha/alloydb-gen.go b/alloydb/v1alpha/alloydb-gen.go index 182f6e305a9..99589e3a9a9 100644 --- a/alloydb/v1alpha/alloydb-gen.go +++ b/alloydb/v1alpha/alloydb-gen.go @@ -761,6 +761,8 @@ type ClusterUpgradeDetails struct { // // Possible values: // "STATUS_UNSPECIFIED" - Unspecified status. + // "NOT_STARTED" - Not started. + // "IN_PROGRESS" - In progress. // "SUCCESS" - Operation succeeded. // "FAILED" - Operation failed. // "PARTIAL_SUCCESS" - Operation partially succeeded. @@ -1448,6 +1450,8 @@ type InstanceUpgradeDetails struct { // // Possible values: // "STATUS_UNSPECIFIED" - Unspecified status. + // "NOT_STARTED" - Not started. + // "IN_PROGRESS" - In progress. // "SUCCESS" - Operation succeeded. // "FAILED" - Operation failed. // "PARTIAL_SUCCESS" - Operation partially succeeded. @@ -2411,17 +2415,20 @@ type StageInfo struct { // // Possible values: // "STAGE_UNSPECIFIED" - Unspecified stage. - // "ALLOYDB_PRECHECK" - This stage is for the custom checks done before - // upgrade. - // "PG_UPGRADE_CHECK" - This stage is for `pg_upgrade --check` run before - // upgrade. - // "PRIMARY_INSTANCE_UPGRADE" - This stage is primary upgrade. - // "READ_POOL_UPGRADE" - This stage is read pool upgrade. + // "ALLOYDB_PRECHECK" - Pre-upgrade custom checks, not covered by pg_upgrade. + // "PG_UPGRADE_CHECK" - Pre-upgrade pg_upgrade checks. + // "PREPARE_FOR_UPGRADE" - Clone the original cluster. + // "PRIMARY_INSTANCE_UPGRADE" - Upgrade the primary instance(downtime). + // "READ_POOL_INSTANCES_UPGRADE" - This stage is read pool upgrade. + // "ROLLBACK" - Rollback in case of critical failures. + // "CLEANUP" - Cleanup. Stage string `json:"stage,omitempty"` // Status: Status of the stage. // // Possible values: // "STATUS_UNSPECIFIED" - Unspecified status. + // "NOT_STARTED" - Not started. + // "IN_PROGRESS" - In progress. // "SUCCESS" - Operation succeeded. // "FAILED" - Operation failed. // "PARTIAL_SUCCESS" - Operation partially succeeded. @@ -3995,6 +4002,8 @@ type UpgradeClusterResponse struct { // // Possible values: // "STATUS_UNSPECIFIED" - Unspecified status. + // "NOT_STARTED" - Not started. + // "IN_PROGRESS" - In progress. // "SUCCESS" - Operation succeeded. // "FAILED" - Operation failed. // "PARTIAL_SUCCESS" - Operation partially succeeded. diff --git a/alloydb/v1beta/alloydb-api.json b/alloydb/v1beta/alloydb-api.json index 28159a4070f..c2b2bd43125 100644 --- a/alloydb/v1beta/alloydb-api.json +++ b/alloydb/v1beta/alloydb-api.json @@ -735,6 +735,34 @@ "scopes": [ "https://www.googleapis.com/auth/cloud-platform" ] + }, + "upgrade": { + "description": "Upgrades a single Cluster. Imperative only.", + "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/clusters/{clustersId}:upgrade", + "httpMethod": "PATCH", + "id": "alloydb.projects.locations.clusters.upgrade", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Required. The resource name of the cluster.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/clusters/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1beta/{+name}:upgrade", + "request": { + "$ref": "UpgradeClusterRequest" + }, + "response": { + "$ref": "Operation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] } }, "resources": { @@ -1486,7 +1514,7 @@ } } }, - "revision": "20240823", + "revision": "20240828", "rootUrl": "https://alloydb.googleapis.com/", "schemas": { "AuthorizedNetwork": { @@ -2092,12 +2120,16 @@ "description": "Upgrade status of the cluster.", "enum": [ "STATUS_UNSPECIFIED", + "NOT_STARTED", + "IN_PROGRESS", "SUCCESS", "FAILED", "PARTIAL_SUCCESS" ], "enumDescriptions": [ "Unspecified status.", + "Not started.", + "In progress.", "Operation succeeded.", "Operation failed.", "Operation partially succeeded." @@ -2679,12 +2711,16 @@ "description": "Upgrade status of the instance.", "enum": [ "STATUS_UNSPECIFIED", + "NOT_STARTED", + "IN_PROGRESS", "SUCCESS", "FAILED", "PARTIAL_SUCCESS" ], "enumDescriptions": [ "Unspecified status.", + "Not started.", + "In progress.", "Operation succeeded.", "Operation failed.", "Operation partially succeeded." @@ -3375,15 +3411,21 @@ "STAGE_UNSPECIFIED", "ALLOYDB_PRECHECK", "PG_UPGRADE_CHECK", + "PREPARE_FOR_UPGRADE", "PRIMARY_INSTANCE_UPGRADE", - "READ_POOL_UPGRADE" + "READ_POOL_INSTANCES_UPGRADE", + "ROLLBACK", + "CLEANUP" ], "enumDescriptions": [ "Unspecified stage.", - "This stage is for the custom checks done before upgrade.", - "This stage is for `pg_upgrade --check` run before upgrade.", - "This stage is primary upgrade.", - "This stage is read pool upgrade." + "Pre-upgrade custom checks, not covered by pg_upgrade.", + "Pre-upgrade pg_upgrade checks.", + "Clone the original cluster.", + "Upgrade the primary instance(downtime).", + "This stage is read pool upgrade.", + "Rollback in case of critical failures.", + "Cleanup." ], "type": "string" }, @@ -3391,12 +3433,16 @@ "description": "Status of the stage.", "enum": [ "STATUS_UNSPECIFIED", + "NOT_STARTED", + "IN_PROGRESS", "SUCCESS", "FAILED", "PARTIAL_SUCCESS" ], "enumDescriptions": [ "Unspecified status.", + "Not started.", + "In progress.", "Operation succeeded.", "Operation failed.", "Operation partially succeeded." @@ -4987,6 +5033,50 @@ }, "type": "object" }, + "UpgradeClusterRequest": { + "description": "Upgrades a cluster.", + "id": "UpgradeClusterRequest", + "properties": { + "etag": { + "description": "Optional. The current etag of the Cluster. If an etag is provided and does not match the current etag of the Cluster, upgrade will be blocked and an ABORTED error will be returned.", + "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).", + "type": "string" + }, + "validateOnly": { + "description": "Optional. If set, performs request validation (e.g. permission checks and any other type of validation), but does not actually execute the upgrade.", + "type": "boolean" + }, + "version": { + "description": "Required. The version the cluster is going to be upgraded to.", + "enum": [ + "DATABASE_VERSION_UNSPECIFIED", + "POSTGRES_13", + "POSTGRES_14", + "POSTGRES_15", + "POSTGRES_16" + ], + "enumDeprecated": [ + false, + true, + false, + false, + false + ], + "enumDescriptions": [ + "This is an unknown database version.", + "DEPRECATED - The database version is Postgres 13.", + "The database version is Postgres 14.", + "The database version is Postgres 15.", + "The database version is Postgres 16." + ], + "type": "string" + } + }, + "type": "object" + }, "UpgradeClusterResponse": { "description": "UpgradeClusterResponse contains the response for upgrade cluster operation.", "id": "UpgradeClusterResponse", @@ -5006,12 +5096,16 @@ "description": "Status of upgrade operation.", "enum": [ "STATUS_UNSPECIFIED", + "NOT_STARTED", + "IN_PROGRESS", "SUCCESS", "FAILED", "PARTIAL_SUCCESS" ], "enumDescriptions": [ "Unspecified status.", + "Not started.", + "In progress.", "Operation succeeded.", "Operation failed.", "Operation partially succeeded." diff --git a/alloydb/v1beta/alloydb-gen.go b/alloydb/v1beta/alloydb-gen.go index 724614a50ac..95de68ac8e3 100644 --- a/alloydb/v1beta/alloydb-gen.go +++ b/alloydb/v1beta/alloydb-gen.go @@ -753,6 +753,8 @@ type ClusterUpgradeDetails struct { // // Possible values: // "STATUS_UNSPECIFIED" - Unspecified status. + // "NOT_STARTED" - Not started. + // "IN_PROGRESS" - In progress. // "SUCCESS" - Operation succeeded. // "FAILED" - Operation failed. // "PARTIAL_SUCCESS" - Operation partially succeeded. @@ -1438,6 +1440,8 @@ type InstanceUpgradeDetails struct { // // Possible values: // "STATUS_UNSPECIFIED" - Unspecified status. + // "NOT_STARTED" - Not started. + // "IN_PROGRESS" - In progress. // "SUCCESS" - Operation succeeded. // "FAILED" - Operation failed. // "PARTIAL_SUCCESS" - Operation partially succeeded. @@ -2401,17 +2405,20 @@ type StageInfo struct { // // Possible values: // "STAGE_UNSPECIFIED" - Unspecified stage. - // "ALLOYDB_PRECHECK" - This stage is for the custom checks done before - // upgrade. - // "PG_UPGRADE_CHECK" - This stage is for `pg_upgrade --check` run before - // upgrade. - // "PRIMARY_INSTANCE_UPGRADE" - This stage is primary upgrade. - // "READ_POOL_UPGRADE" - This stage is read pool upgrade. + // "ALLOYDB_PRECHECK" - Pre-upgrade custom checks, not covered by pg_upgrade. + // "PG_UPGRADE_CHECK" - Pre-upgrade pg_upgrade checks. + // "PREPARE_FOR_UPGRADE" - Clone the original cluster. + // "PRIMARY_INSTANCE_UPGRADE" - Upgrade the primary instance(downtime). + // "READ_POOL_INSTANCES_UPGRADE" - This stage is read pool upgrade. + // "ROLLBACK" - Rollback in case of critical failures. + // "CLEANUP" - Cleanup. Stage string `json:"stage,omitempty"` // Status: Status of the stage. // // Possible values: // "STATUS_UNSPECIFIED" - Unspecified status. + // "NOT_STARTED" - Not started. + // "IN_PROGRESS" - In progress. // "SUCCESS" - Operation succeeded. // "FAILED" - Operation failed. // "PARTIAL_SUCCESS" - Operation partially succeeded. @@ -3923,6 +3930,55 @@ func (s UpdatePolicy) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// UpgradeClusterRequest: Upgrades a cluster. +type UpgradeClusterRequest struct { + // Etag: Optional. The current etag of the Cluster. If an etag is provided and + // does not match the current etag of the Cluster, upgrade will be blocked and + // an ABORTED error will be returned. + Etag string `json:"etag,omitempty"` + // RequestId: 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). + RequestId string `json:"requestId,omitempty"` + // ValidateOnly: Optional. If set, performs request validation (e.g. permission + // checks and any other type of validation), but does not actually execute the + // upgrade. + ValidateOnly bool `json:"validateOnly,omitempty"` + // Version: Required. The version the cluster is going to be upgraded to. + // + // Possible values: + // "DATABASE_VERSION_UNSPECIFIED" - This is an unknown database version. + // "POSTGRES_13" - DEPRECATED - The database version is Postgres 13. + // "POSTGRES_14" - The database version is Postgres 14. + // "POSTGRES_15" - The database version is Postgres 15. + // "POSTGRES_16" - The database version is Postgres 16. + Version string `json:"version,omitempty"` + // ForceSendFields is a list of field names (e.g. "Etag") 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. "Etag") 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 UpgradeClusterRequest) MarshalJSON() ([]byte, error) { + type NoMethod UpgradeClusterRequest + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // UpgradeClusterResponse: UpgradeClusterResponse contains the response for // upgrade cluster operation. type UpgradeClusterResponse struct { @@ -3936,6 +3992,8 @@ type UpgradeClusterResponse struct { // // Possible values: // "STATUS_UNSPECIFIED" - Unspecified status. + // "NOT_STARTED" - Not started. + // "IN_PROGRESS" - In progress. // "SUCCESS" - Operation succeeded. // "FAILED" - Operation failed. // "PARTIAL_SUCCESS" - Operation partially succeeded. @@ -6154,6 +6212,107 @@ func (c *ProjectsLocationsClustersSwitchoverCall) Do(opts ...googleapi.CallOptio return ret, nil } +type ProjectsLocationsClustersUpgradeCall struct { + s *Service + name string + upgradeclusterrequest *UpgradeClusterRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Upgrade: Upgrades a single Cluster. Imperative only. +// +// - name: The resource name of the cluster. +func (r *ProjectsLocationsClustersService) Upgrade(name string, upgradeclusterrequest *UpgradeClusterRequest) *ProjectsLocationsClustersUpgradeCall { + c := &ProjectsLocationsClustersUpgradeCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + c.upgradeclusterrequest = upgradeclusterrequest + 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 *ProjectsLocationsClustersUpgradeCall) Fields(s ...googleapi.Field) *ProjectsLocationsClustersUpgradeCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsClustersUpgradeCall) Context(ctx context.Context) *ProjectsLocationsClustersUpgradeCall { + 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 *ProjectsLocationsClustersUpgradeCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsClustersUpgradeCall) 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.upgradeclusterrequest) + if err != nil { + return nil, err + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}:upgrade") + 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 "alloydb.projects.locations.clusters.upgrade" 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 *ProjectsLocationsClustersUpgradeCall) 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 ProjectsLocationsClustersInstancesCreateCall struct { s *Service parent string diff --git a/androidmanagement/v1/androidmanagement-api.json b/androidmanagement/v1/androidmanagement-api.json index e936206bcff..9a3f0b7c513 100644 --- a/androidmanagement/v1/androidmanagement-api.json +++ b/androidmanagement/v1/androidmanagement-api.json @@ -1168,7 +1168,7 @@ } } }, - "revision": "20240821", + "revision": "20240904", "rootUrl": "https://androidmanagement.googleapis.com/", "schemas": { "AdbShellCommandEvent": { @@ -1206,6 +1206,22 @@ ], "type": "string" }, + "contentProtectionPolicy": { + "description": "Optional. Controls whether content protection, which scans for deceptive apps, is enabled. This is supported on Android 15 and above.", + "enum": [ + "CONTENT_PROTECTION_POLICY_UNSPECIFIED", + "CONTENT_PROTECTION_DISABLED", + "CONTENT_PROTECTION_ENFORCED", + "CONTENT_PROTECTION_USER_CHOICE" + ], + "enumDescriptions": [ + "Unspecified. Defaults to CONTENT_PROTECTION_DISABLED.", + "Content protection is disabled and the user cannot change this.", + "Content protection is enabled and the user cannot change this.Supported on Android 15 and above. A nonComplianceDetail with API_LEVEL is reported if the Android version is less than 15.", + "Content protection is not controlled by the policy. The user is allowed to choose the behavior of content protection.Supported on Android 15 and above. A nonComplianceDetail with API_LEVEL is reported if the Android version is less than 15." + ], + "type": "string" + }, "developerSettings": { "description": "Controls access to developer settings: developer options and safe boot. Replaces safeBootDisabled (deprecated) and debuggingFeaturesAllowed (deprecated).", "enum": [ @@ -4853,6 +4869,20 @@ }, "type": "array" }, + "assistContentPolicy": { + "description": "Optional. Controls whether AssistContent (https://developer.android.com/reference/android/app/assist/AssistContent) is allowed to be sent to a privileged app such as an assistant app. AssistContent includes screenshots and information about an app, such as package name. This is supported on Android 15 and above.", + "enum": [ + "ASSIST_CONTENT_POLICY_UNSPECIFIED", + "ASSIST_CONTENT_DISALLOWED", + "ASSIST_CONTENT_ALLOWED" + ], + "enumDescriptions": [ + "Unspecified. Defaults to ASSIST_CONTENT_ALLOWED.", + "Assist content is blocked from being sent to a privileged app.Supported on Android 15 and above. A nonComplianceDetail with API_LEVEL is reported if the Android version is less than 15.", + "Assist content is allowed to be sent to a privileged app.Supported on Android 15 and above." + ], + "type": "string" + }, "autoDateAndTimeZone": { "description": "Whether auto date, time, and time zone are enabled on a company-owned device. If this is set, then autoTimeRequired is ignored.", "enum": [ @@ -5412,7 +5442,7 @@ }, "wifiConfigsLockdownEnabled": { "deprecated": true, - "description": "DEPRECATED - Use wifi_config_disabled.", + "description": "This is deprecated.", "type": "boolean" } }, diff --git a/androidmanagement/v1/androidmanagement-gen.go b/androidmanagement/v1/androidmanagement-gen.go index a52240c5e25..8bf258bd144 100644 --- a/androidmanagement/v1/androidmanagement-gen.go +++ b/androidmanagement/v1/androidmanagement-gen.go @@ -331,6 +331,23 @@ type AdvancedSecurityOverrides struct { // "COMMON_CRITERIA_MODE_DISABLED" - Default. Disables Common Criteria Mode. // "COMMON_CRITERIA_MODE_ENABLED" - Enables Common Criteria Mode. CommonCriteriaMode string `json:"commonCriteriaMode,omitempty"` + // ContentProtectionPolicy: Optional. Controls whether content protection, + // which scans for deceptive apps, is enabled. This is supported on Android 15 + // and above. + // + // Possible values: + // "CONTENT_PROTECTION_POLICY_UNSPECIFIED" - Unspecified. Defaults to + // CONTENT_PROTECTION_DISABLED. + // "CONTENT_PROTECTION_DISABLED" - Content protection is disabled and the + // user cannot change this. + // "CONTENT_PROTECTION_ENFORCED" - Content protection is enabled and the user + // cannot change this.Supported on Android 15 and above. A nonComplianceDetail + // with API_LEVEL is reported if the Android version is less than 15. + // "CONTENT_PROTECTION_USER_CHOICE" - Content protection is not controlled by + // the policy. The user is allowed to choose the behavior of content + // protection.Supported on Android 15 and above. A nonComplianceDetail with + // API_LEVEL is reported if the Android version is less than 15. + ContentProtectionPolicy string `json:"contentProtectionPolicy,omitempty"` // DeveloperSettings: Controls access to developer settings: developer options // and safe boot. Replaces safeBootDisabled (deprecated) and // debuggingFeaturesAllowed (deprecated). @@ -4724,6 +4741,21 @@ type Policy struct { AppAutoUpdatePolicy string `json:"appAutoUpdatePolicy,omitempty"` // Applications: Policy applied to apps. This can have at most 3,000 elements. Applications []*ApplicationPolicy `json:"applications,omitempty"` + // AssistContentPolicy: Optional. Controls whether AssistContent + // (https://developer.android.com/reference/android/app/assist/AssistContent) + // is allowed to be sent to a privileged app such as an assistant app. + // AssistContent includes screenshots and information about an app, such as + // package name. This is supported on Android 15 and above. + // + // Possible values: + // "ASSIST_CONTENT_POLICY_UNSPECIFIED" - Unspecified. Defaults to + // ASSIST_CONTENT_ALLOWED. + // "ASSIST_CONTENT_DISALLOWED" - Assist content is blocked from being sent to + // a privileged app.Supported on Android 15 and above. A nonComplianceDetail + // with API_LEVEL is reported if the Android version is less than 15. + // "ASSIST_CONTENT_ALLOWED" - Assist content is allowed to be sent to a + // privileged app.Supported on Android 15 and above. + AssistContentPolicy string `json:"assistContentPolicy,omitempty"` // AutoDateAndTimeZone: Whether auto date, time, and time zone are enabled on a // company-owned device. If this is set, then autoTimeRequired is ignored. // @@ -5186,7 +5218,7 @@ type Policy struct { // disabled then network escape hatch will be shown in order to refresh the // device policy (see networkEscapeHatchEnabled). WifiConfigDisabled bool `json:"wifiConfigDisabled,omitempty"` - // WifiConfigsLockdownEnabled: DEPRECATED - Use wifi_config_disabled. + // WifiConfigsLockdownEnabled: This is deprecated. WifiConfigsLockdownEnabled bool `json:"wifiConfigsLockdownEnabled,omitempty"` // ServerResponse contains the HTTP response code and headers from the server. diff --git a/apigee/v1/apigee-api.json b/apigee/v1/apigee-api.json index e2ba612108a..db755cd29d3 100644 --- a/apigee/v1/apigee-api.json +++ b/apigee/v1/apigee-api.json @@ -10045,7 +10045,7 @@ } } }, - "revision": "20240617", + "revision": "20240903", "rootUrl": "https://apigee.googleapis.com/", "schemas": { "EdgeConfigstoreBundleBadBundle": { @@ -16617,6 +16617,13 @@ "$ref": "GoogleCloudApigeeV1SecurityActionAllow", "description": "Allow a request through if it matches this SecurityAction." }, + "apiProxies": { + "description": "Optional. If unset, this would apply to all proxies in the environment. If set, this action is enforced only if at least one proxy in the repeated list is deployed at the time of enforcement. If set, several restrictions are enforced on SecurityActions. There can be at most 100 enabled actions with proxies set in an env. Several other restrictions apply on conditions and are detailed later.", + "items": { + "type": "string" + }, + "type": "array" + }, "conditionConfig": { "$ref": "GoogleCloudApigeeV1SecurityActionConditionConfig", "description": "Required. A valid SecurityAction must contain at least one condition." diff --git a/apigee/v1/apigee-gen.go b/apigee/v1/apigee-gen.go index 5890c51e5fd..6df042e2716 100644 --- a/apigee/v1/apigee-gen.go +++ b/apigee/v1/apigee-gen.go @@ -9132,6 +9132,13 @@ func (s GoogleCloudApigeeV1ScoreComponentRecommendationActionActionContext) Mars type GoogleCloudApigeeV1SecurityAction struct { // Allow: Allow a request through if it matches this SecurityAction. Allow *GoogleCloudApigeeV1SecurityActionAllow `json:"allow,omitempty"` + // ApiProxies: Optional. If unset, this would apply to all proxies in the + // environment. If set, this action is enforced only if at least one proxy in + // the repeated list is deployed at the time of enforcement. If set, several + // restrictions are enforced on SecurityActions. There can be at most 100 + // enabled actions with proxies set in an env. Several other restrictions apply + // on conditions and are detailed later. + ApiProxies []string `json:"apiProxies,omitempty"` // ConditionConfig: Required. A valid SecurityAction must contain at least one // condition. ConditionConfig *GoogleCloudApigeeV1SecurityActionConditionConfig `json:"conditionConfig,omitempty"` diff --git a/appengine/v1/appengine-api.json b/appengine/v1/appengine-api.json index 225390c1251..8567e082590 100644 --- a/appengine/v1/appengine-api.json +++ b/appengine/v1/appengine-api.json @@ -1718,7 +1718,7 @@ } } }, - "revision": "20240722", + "revision": "20240906", "rootUrl": "https://appengine.googleapis.com/", "schemas": { "ApiConfigHandler": { @@ -2480,6 +2480,24 @@ }, "type": "object" }, + "GceTag": { + "description": "For use only by GCE. GceTag is a wrapper around the GCE administrative tag with parent info.", + "id": "GceTag", + "properties": { + "parent": { + "description": "The parents(s) of the tag. Eg. projects/123, folders/456 It usually contains only one parent. But, in some corner cases, it can contain multiple parents. Currently, organizations are not supported.", + "items": { + "type": "string" + }, + "type": "array" + }, + "tag": { + "description": "The administrative_tag name.", + "type": "string" + } + }, + "type": "object" + }, "GoogleAppengineV1betaLocationMetadata": { "description": "Metadata for the given google.cloud.location.Location.", "id": "GoogleAppengineV1betaLocationMetadata", @@ -3343,6 +3361,13 @@ ], "type": "string" }, + "gceTag": { + "description": "The GCE tags associated with the consumer project and those inherited due to their ancestry, if any. Not supported by CCFE.", + "items": { + "$ref": "GceTag" + }, + "type": "array" + }, "p4ServiceAccount": { "description": "The service account authorized to operate on the consumer project. Note: CCFE only propagates P4SA with default tag to CLH.", "type": "string" diff --git a/appengine/v1/appengine-gen.go b/appengine/v1/appengine-gen.go index 2464c563617..5a307ed2065 100644 --- a/appengine/v1/appengine-gen.go +++ b/appengine/v1/appengine-gen.go @@ -1428,6 +1428,33 @@ func (s FlexibleRuntimeSettings) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GceTag: For use only by GCE. GceTag is a wrapper around the GCE +// administrative tag with parent info. +type GceTag struct { + // Parent: The parents(s) of the tag. Eg. projects/123, folders/456 It usually + // contains only one parent. But, in some corner cases, it can contain multiple + // parents. Currently, organizations are not supported. + Parent []string `json:"parent,omitempty"` + // Tag: The administrative_tag name. + Tag string `json:"tag,omitempty"` + // ForceSendFields is a list of field names (e.g. "Parent") 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. "Parent") 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 GceTag) MarshalJSON() ([]byte, error) { + type NoMethod GceTag + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleAppengineV1betaLocationMetadata: Metadata for the given // google.cloud.location.Location. type GoogleAppengineV1betaLocationMetadata struct { @@ -2469,6 +2496,9 @@ type ProjectsMetadata struct { // completely removed. This is often due to a data governance purge request and // therefore resources should be deleted when this state is reached. ConsumerProjectState string `json:"consumerProjectState,omitempty"` + // GceTag: The GCE tags associated with the consumer project and those + // inherited due to their ancestry, if any. Not supported by CCFE. + GceTag []*GceTag `json:"gceTag,omitempty"` // P4ServiceAccount: The service account authorized to operate on the consumer // project. Note: CCFE only propagates P4SA with default tag to CLH. P4ServiceAccount string `json:"p4ServiceAccount,omitempty"` diff --git a/appengine/v1alpha/appengine-api.json b/appengine/v1alpha/appengine-api.json index 433baa51c4f..ac63e22e42d 100644 --- a/appengine/v1alpha/appengine-api.json +++ b/appengine/v1alpha/appengine-api.json @@ -946,7 +946,7 @@ } } }, - "revision": "20240415", + "revision": "20240906", "rootUrl": "https://appengine.googleapis.com/", "schemas": { "AuthorizedCertificate": { @@ -1125,6 +1125,24 @@ "properties": {}, "type": "object" }, + "GceTag": { + "description": "For use only by GCE. GceTag is a wrapper around the GCE administrative tag with parent info.", + "id": "GceTag", + "properties": { + "parent": { + "description": "The parents(s) of the tag. Eg. projects/123, folders/456 It usually contains only one parent. But, in some corner cases, it can contain multiple parents. Currently, organizations are not supported.", + "items": { + "type": "string" + }, + "type": "array" + }, + "tag": { + "description": "The administrative_tag name.", + "type": "string" + } + }, + "type": "object" + }, "GoogleAppengineV1betaLocationMetadata": { "description": "Metadata for the given google.cloud.location.Location.", "id": "GoogleAppengineV1betaLocationMetadata", @@ -1551,6 +1569,13 @@ ], "type": "string" }, + "gceTag": { + "description": "The GCE tags associated with the consumer project and those inherited due to their ancestry, if any. Not supported by CCFE.", + "items": { + "$ref": "GceTag" + }, + "type": "array" + }, "p4ServiceAccount": { "description": "The service account authorized to operate on the consumer project. Note: CCFE only propagates P4SA with default tag to CLH.", "type": "string" diff --git a/appengine/v1alpha/appengine-gen.go b/appengine/v1alpha/appengine-gen.go index 59a3594213d..bb373e06448 100644 --- a/appengine/v1alpha/appengine-gen.go +++ b/appengine/v1alpha/appengine-gen.go @@ -600,6 +600,33 @@ type Empty struct { googleapi.ServerResponse `json:"-"` } +// GceTag: For use only by GCE. GceTag is a wrapper around the GCE +// administrative tag with parent info. +type GceTag struct { + // Parent: The parents(s) of the tag. Eg. projects/123, folders/456 It usually + // contains only one parent. But, in some corner cases, it can contain multiple + // parents. Currently, organizations are not supported. + Parent []string `json:"parent,omitempty"` + // Tag: The administrative_tag name. + Tag string `json:"tag,omitempty"` + // ForceSendFields is a list of field names (e.g. "Parent") 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. "Parent") 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 GceTag) MarshalJSON() ([]byte, error) { + type NoMethod GceTag + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleAppengineV1betaLocationMetadata: Metadata for the given // google.cloud.location.Location. type GoogleAppengineV1betaLocationMetadata struct { @@ -1126,6 +1153,9 @@ type ProjectsMetadata struct { // completely removed. This is often due to a data governance purge request and // therefore resources should be deleted when this state is reached. ConsumerProjectState string `json:"consumerProjectState,omitempty"` + // GceTag: The GCE tags associated with the consumer project and those + // inherited due to their ancestry, if any. Not supported by CCFE. + GceTag []*GceTag `json:"gceTag,omitempty"` // P4ServiceAccount: The service account authorized to operate on the consumer // project. Note: CCFE only propagates P4SA with default tag to CLH. P4ServiceAccount string `json:"p4ServiceAccount,omitempty"` diff --git a/appengine/v1beta/appengine-api.json b/appengine/v1beta/appengine-api.json index b25dc2e75f7..0429678e6e2 100644 --- a/appengine/v1beta/appengine-api.json +++ b/appengine/v1beta/appengine-api.json @@ -1918,7 +1918,7 @@ } } }, - "revision": "20240722", + "revision": "20240906", "rootUrl": "https://appengine.googleapis.com/", "schemas": { "ApiConfigHandler": { @@ -2731,6 +2731,24 @@ }, "type": "object" }, + "GceTag": { + "description": "For use only by GCE. GceTag is a wrapper around the GCE administrative tag with parent info.", + "id": "GceTag", + "properties": { + "parent": { + "description": "The parents(s) of the tag. Eg. projects/123, folders/456 It usually contains only one parent. But, in some corner cases, it can contain multiple parents. Currently, organizations are not supported.", + "items": { + "type": "string" + }, + "type": "array" + }, + "tag": { + "description": "The administrative_tag name.", + "type": "string" + } + }, + "type": "object" + }, "GoogleAppengineV1betaLocationMetadata": { "description": "Metadata for the given google.cloud.location.Location.", "id": "GoogleAppengineV1betaLocationMetadata", @@ -3594,6 +3612,13 @@ ], "type": "string" }, + "gceTag": { + "description": "The GCE tags associated with the consumer project and those inherited due to their ancestry, if any. Not supported by CCFE.", + "items": { + "$ref": "GceTag" + }, + "type": "array" + }, "p4ServiceAccount": { "description": "The service account authorized to operate on the consumer project. Note: CCFE only propagates P4SA with default tag to CLH.", "type": "string" diff --git a/appengine/v1beta/appengine-gen.go b/appengine/v1beta/appengine-gen.go index 6a86d77808d..491f5945051 100644 --- a/appengine/v1beta/appengine-gen.go +++ b/appengine/v1beta/appengine-gen.go @@ -1520,6 +1520,33 @@ func (s FlexibleRuntimeSettings) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GceTag: For use only by GCE. GceTag is a wrapper around the GCE +// administrative tag with parent info. +type GceTag struct { + // Parent: The parents(s) of the tag. Eg. projects/123, folders/456 It usually + // contains only one parent. But, in some corner cases, it can contain multiple + // parents. Currently, organizations are not supported. + Parent []string `json:"parent,omitempty"` + // Tag: The administrative_tag name. + Tag string `json:"tag,omitempty"` + // ForceSendFields is a list of field names (e.g. "Parent") 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. "Parent") 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 GceTag) MarshalJSON() ([]byte, error) { + type NoMethod GceTag + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleAppengineV1betaLocationMetadata: Metadata for the given // google.cloud.location.Location. type GoogleAppengineV1betaLocationMetadata struct { @@ -2561,6 +2588,9 @@ type ProjectsMetadata struct { // completely removed. This is often due to a data governance purge request and // therefore resources should be deleted when this state is reached. ConsumerProjectState string `json:"consumerProjectState,omitempty"` + // GceTag: The GCE tags associated with the consumer project and those + // inherited due to their ancestry, if any. Not supported by CCFE. + GceTag []*GceTag `json:"gceTag,omitempty"` // P4ServiceAccount: The service account authorized to operate on the consumer // project. Note: CCFE only propagates P4SA with default tag to CLH. P4ServiceAccount string `json:"p4ServiceAccount,omitempty"` diff --git a/artifactregistry/v1/artifactregistry-api.json b/artifactregistry/v1/artifactregistry-api.json index d1798217eb0..792e14fe09f 100644 --- a/artifactregistry/v1/artifactregistry-api.json +++ b/artifactregistry/v1/artifactregistry-api.json @@ -679,7 +679,7 @@ ], "parameters": { "filter": { - "description": "Optional. An expression for filtering the results of the request. Filter rules are case insensitive. The fields eligible for filtering are: * `name` Examples of using a filter: To filter the results of your request to repositories with the name \"my-repo\" in project my-project in the us-central region, append the following filter expression to your request: * `name=\"projects/my-project/locations/us-central1/repositories/my-repo` You can also use wildcards to match any number of characters before or after the value: * `name=\"projects/my-project/locations/us-central1/repositories/my-*\"` * `name=\"projects/my-project/locations/us-central1/repositories/*repo\"` * `name=\"projects/my-project/locations/us-central1/repositories/*repo*\"`", + "description": "Optional. An expression for filtering the results of the request. Filter rules are case insensitive. The fields eligible for filtering are: * `name` Examples of using a filter: To filter the results of your request to repositories with the name `my-repo` in project `my-project` in the `us-central` region, append the following filter expression to your request: * `name=\"projects/my-project/locations/us-central1/repositories/my-repo\"` You can also use wildcards to match any number of characters before or after the value: * `name=\"projects/my-project/locations/us-central1/repositories/my-*\"` * `name=\"projects/my-project/locations/us-central1/repositories/*repo\"` * `name=\"projects/my-project/locations/us-central1/repositories/*repo*\"`", "location": "query", "type": "string" }, @@ -1044,7 +1044,7 @@ ], "parameters": { "filter": { - "description": "An expression for filtering the results of the request. Filter rules are case insensitive. The fields eligible for filtering are: * `name` * `owner` * `annotations` Examples of using a filter: To filter the results of your request to files with the name \"my_file.txt\" in project my-project in the us-central region, in repository my-repo, append the following filter expression to your request: * `name=\"projects/my-project/locations/us-central1/repositories/my-repo/files/my-file.txt\"` You can also use wildcards to match any number of characters before or after the value: * `name=\"projects/my-project/locations/us-central1/repositories/my-repo/files/my-*\"` * `name=\"projects/my-project/locations/us-central1/repositories/my-repo/files/*file.txt\"` * `name=\"projects/my-project/locations/us-central1/repositories/my-repo/files/*file*\"` To filter the results of your request to files owned by the version `1.0` in package `pkg1`, append the following filter expression to your request: * `owner=\"projects/my-project/locations/us-central1/repositories/my-repo/packages/my-package/versions/1.0\"` To filter the results of your request to files with the annotation key-value pair [`external_link`:`external_link_value`], append the following filter expression to your request: * \"annotations.external_link:external_link_value\" To filter just for a specific annotation key `external_link`, append the following filter expression to your request: * \"annotations.external_link\" If the annotation key or value contains special characters, you can escape them by surrounding the value with backticks. For example, to filter the results of your request to files with the annotation key-value pair [`external.link`:`https://example.com/my-file`], append the following filter expression to your request: * \"annotations.`external.link`:`https://example.com/my-file`\" You can also filter with annotations with a wildcard to match any number of characters before or after the value: * \"annotations.*_link:`*example.com*`\"", + "description": "An expression for filtering the results of the request. Filter rules are case insensitive. The fields eligible for filtering are: * `name` * `owner` * `annotations` Examples of using a filter: To filter the results of your request to files with the name `my_file.txt` in project `my-project` in the `us-central` region, in repository `my-repo`, append the following filter expression to your request: * `name=\"projects/my-project/locations/us-central1/repositories/my-repo/files/my-file.txt\"` You can also use wildcards to match any number of characters before or after the value: * `name=\"projects/my-project/locations/us-central1/repositories/my-repo/files/my-*\"` * `name=\"projects/my-project/locations/us-central1/repositories/my-repo/files/*file.txt\"` * `name=\"projects/my-project/locations/us-central1/repositories/my-repo/files/*file*\"` To filter the results of your request to files owned by the version `1.0` in package `pkg1`, append the following filter expression to your request: * `owner=\"projects/my-project/locations/us-central1/repositories/my-repo/packages/my-package/versions/1.0\"` To filter the results of your request to files with the annotation key-value pair [`external_link`: `external_link_value`], append the following filter expression to your request: * `\"annotations.external_link:external_link_value\"` To filter just for a specific annotation key `external_link`, append the following filter expression to your request: * `\"annotations.external_link\"` If the annotation key or value contains special characters, you can escape them by surrounding the value with backticks. For example, to filter the results of your request to files with the annotation key-value pair [`external.link`:`https://example.com/my-file`], append the following filter expression to your request: * `` \"annotations.`external.link`:`https://example.com/my-file`\" `` You can also filter with annotations with a wildcard to match any number of characters before or after the value: * `` \"annotations.*_link:`*example.com*`\" ``", "location": "query", "type": "string" }, @@ -1488,7 +1488,7 @@ ], "parameters": { "filter": { - "description": "Optional. An expression for filtering the results of the request. Filter rules are case insensitive. The fields eligible for filtering are: * `name` * `annotations` Examples of using a filter: To filter the results of your request to packages with the name \"my-package\" in project my-project in the us-central region, in repository my-repo, append the following filter expression to your request: * `name=\"projects/my-project/locations/us-central1/repositories/my-repo/packages/my-package\"` You can also use wildcards to match any number of characters before or after the value: * `name=\"projects/my-project/locations/us-central1/repositories/my-repo/packages/my-*\"` * `name=\"projects/my-project/locations/us-central1/repositories/my-repo/packages/*package\"` * `name=\"projects/my-project/locations/us-central1/repositories/my-repo/packages/*pack*\"` To filter the results of your request to packages with the annotation key-value pair [`external_link`:`external_link_value`], append the following filter expression to your request\": * \"annotations.external_link:external_link_value\" To filter the results just for a specific annotation key `external_link`, append the following filter expression to your request: * \"annotations.external_link\" If the annotation key or value contains special characters, you can escape them by surrounding the value with backticks. For example, to filter the results of your request to packages with the annotation key-value pair [`external.link`:`https://example.com/my-package`], append the following filter expression to your request: * \"annotations.`external.link`:`https://example.com/my-package`\" You can also filter with annotations with a wildcard to match any number of characters before or after the value: * \"annotations.*_link:`*example.com*`\"", + "description": "Optional. An expression for filtering the results of the request. Filter rules are case insensitive. The fields eligible for filtering are: * `name` * `annotations` Examples of using a filter: To filter the results of your request to packages with the name `my-package` in project `my-project` in the `us-central` region, in repository `my-repo`, append the following filter expression to your request: * `name=\"projects/my-project/locations/us-central1/repositories/my-repo/packages/my-package\"` You can also use wildcards to match any number of characters before or after the value: * `name=\"projects/my-project/locations/us-central1/repositories/my-repo/packages/my-*\"` * `name=\"projects/my-project/locations/us-central1/repositories/my-repo/packages/*package\"` * `name=\"projects/my-project/locations/us-central1/repositories/my-repo/packages/*pack*\"` To filter the results of your request to packages with the annotation key-value pair [`external_link`: `external_link_value`], append the following filter expression to your request\": * `\"annotations.external_link:external_link_value\"` To filter the results just for a specific annotation key `external_link`, append the following filter expression to your request: * `\"annotations.external_link\"` If the annotation key or value contains special characters, you can escape them by surrounding the value with backticks. For example, to filter the results of your request to packages with the annotation key-value pair [`external.link`:`https://example.com/my-package`], append the following filter expression to your request: * `` \"annotations.`external.link`:`https://example.com/my-package`\" `` You can also filter with annotations with a wildcard to match any number of characters before or after the value: * `` \"annotations.*_link:`*example.com*`\" ``", "location": "query", "type": "string" }, @@ -1657,7 +1657,7 @@ ], "parameters": { "filter": { - "description": "An expression for filtering the results of the request. Filter rules are case insensitive. The fields eligible for filtering are: * `name` * `version` Examples of using a filter: To filter the results of your request to tags with the name \"my-tag\" in package \"my-package\" in repository \"my-repo\" in project \"my-project\" in the us-central region, append the following filter expression to your request: * `name=\"projects/my-project/locations/us-central1/repositories/my-repo/packages/my-package/tags/my-tag\"` You can also use wildcards to match any number of characters before or after the value: * `name=\"projects/my-project/locations/us-central1/repositories/my-repo/packages/my-package/tags/my*\"` * `name=\"projects/my-project/locations/us-central1/repositories/my-repo/packages/my-package/tags/*tag\"` * `name=\"projects/my-project/locations/us-central1/repositories/my-repo/packages/my-package/tags/*tag*\"` To filter the results of your request to tags applied to the version `1.0` in package `my-package`, append the following filter expression to your request: * `version=\"projects/my-project/locations/us-central1/repositories/my-repo/packages/my-package/versions/1.0\"`", + "description": "An expression for filtering the results of the request. Filter rules are case insensitive. The fields eligible for filtering are: * `name` * `version` Examples of using a filter: To filter the results of your request to tags with the name `my-tag` in package `my-package` in repository `my-repo` in project \"`y-project` in the us-central region, append the following filter expression to your request: * `name=\"projects/my-project/locations/us-central1/repositories/my-repo/packages/my-package/tags/my-tag\"` You can also use wildcards to match any number of characters before or after the value: * `name=\"projects/my-project/locations/us-central1/repositories/my-repo/packages/my-package/tags/my*\"` * `name=\"projects/my-project/locations/us-central1/repositories/my-repo/packages/my-package/tags/*tag\"` * `name=\"projects/my-project/locations/us-central1/repositories/my-repo/packages/my-package/tags/*tag*\"` To filter the results of your request to tags applied to the version `1.0` in package `my-package`, append the following filter expression to your request: * `version=\"projects/my-project/locations/us-central1/repositories/my-repo/packages/my-package/versions/1.0\"`", "location": "query", "type": "string" }, @@ -1836,7 +1836,7 @@ ], "parameters": { "filter": { - "description": "Optional. An expression for filtering the results of the request. Filter rules are case insensitive. The fields eligible for filtering are: * `name` * `annotations` Examples of using a filter: To filter the results of your request to versions with the name \"my-version\" in project my-project in the us-central region, in repository my-repo, append the following filter expression to your request: * `name=\"projects/my-project/locations/us-central1/repositories/my-repo/packages/my-package/versions/my-version\"` You can also use wildcards to match any number of characters before or after the value: * `name=\"projects/my-project/locations/us-central1/repositories/my-repo/packages/my-package/versions/*version\"` * `name=\"projects/my-project/locations/us-central1/repositories/my-repo/packages/my-package/versions/my*\"` * `name=\"projects/my-project/locations/us-central1/repositories/my-repo/packages/my-package/versions/*version*\"` To filter the results of your request to versions with the annotation key-value pair [`external_link`:`external_link_value`], append the following filter expression to your request: * \"annotations.external_link:external_link_value\" To filter just for a specific annotation key `external_link`, append the following filter expression to your request: * \"annotations.external_link\" If the annotation key or value contains special characters, you can escape them by surrounding the value with backticks. For example, to filter the results of your request to versions with the annotation key-value pair [`external.link`:`https://example.com/my-version`], append the following filter expression to your request: * \"annotations.`external.link`:`https://example.com/my-version`\" You can also filter with annotations with a wildcard to match any number of characters before or after the value: * \"annotations.*_link:`*example.com*`\"", + "description": "Optional. An expression for filtering the results of the request. Filter rules are case insensitive. The fields eligible for filtering are: * `name` * `annotations` Examples of using a filter: To filter the results of your request to versions with the name `my-version` in project `my-project` in the `us-central` region, in repository `my-repo`, append the following filter expression to your request: * `name=\"projects/my-project/locations/us-central1/repositories/my-repo/packages/my-package/versions/my-version\"` You can also use wildcards to match any number of characters before or after the value: * `name=\"projects/my-project/locations/us-central1/repositories/my-repo/packages/my-package/versions/*version\"` * `name=\"projects/my-project/locations/us-central1/repositories/my-repo/packages/my-package/versions/my*\"` * `name=\"projects/my-project/locations/us-central1/repositories/my-repo/packages/my-package/versions/*version*\"` To filter the results of your request to versions with the annotation key-value pair [`external_link`: `external_link_value`], append the following filter expression to your request: * `\"annotations.external_link:external_link_value\"` To filter just for a specific annotation key `external_link`, append the following filter expression to your request: * `\"annotations.external_link\"` If the annotation key or value contains special characters, you can escape them by surrounding the value with backticks. For example, to filter the results of your request to versions with the annotation key-value pair [`external.link`:`https://example.com/my-version`], append the following filter expression to your request: * `` \"annotations.`external.link`:`https://example.com/my-version`\" `` You can also filter with annotations with a wildcard to match any number of characters before or after the value: * `` \"annotations.*_link:`*example.com*`\" ``", "location": "query", "type": "string" }, @@ -2038,7 +2038,7 @@ } } }, - "revision": "20240826", + "revision": "20240903", "rootUrl": "https://artifactregistry.googleapis.com/", "schemas": { "AptArtifact": { @@ -2264,6 +2264,17 @@ }, "type": "object" }, + "CommonRemoteRepository": { + "description": "Common remote repository settings type.", + "id": "CommonRemoteRepository", + "properties": { + "uri": { + "description": "Required. A common public repository base for Remote Repository.", + "type": "string" + } + }, + "type": "object" + }, "DockerImage": { "description": "DockerImage represents a docker artifact. The following fields are returned as untyped metadata in the Version resource, using camelcase keys (i.e. metadata.imageSizeBytes): * imageSizeBytes * mediaType * buildTime", "id": "DockerImage", @@ -3457,6 +3468,10 @@ "$ref": "AptRepository", "description": "Specific settings for an Apt remote repository." }, + "commonRepository": { + "$ref": "CommonRemoteRepository", + "description": "Common remote repository settings. Used as the RR upstream URL instead of Predefined and Custom remote repositories. UI and Gcloud will map all the new remote repositories to this field." + }, "description": { "description": "The description of the remote source.", "type": "string" diff --git a/artifactregistry/v1/artifactregistry-gen.go b/artifactregistry/v1/artifactregistry-gen.go index b5badd0865f..b77d4d10e0e 100644 --- a/artifactregistry/v1/artifactregistry-gen.go +++ b/artifactregistry/v1/artifactregistry-gen.go @@ -694,6 +694,28 @@ func (s CleanupPolicyMostRecentVersions) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// CommonRemoteRepository: Common remote repository settings type. +type CommonRemoteRepository struct { + // Uri: Required. A common public repository base for Remote Repository. + Uri string `json:"uri,omitempty"` + // ForceSendFields is a list of field names (e.g. "Uri") 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. "Uri") 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 CommonRemoteRepository) MarshalJSON() ([]byte, error) { + type NoMethod CommonRemoteRepository + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // DockerImage: DockerImage represents a docker artifact. The following fields // are returned as untyped metadata in the Version resource, using camelcase // keys (i.e. metadata.imageSizeBytes): * imageSizeBytes * mediaType * @@ -2374,6 +2396,10 @@ func (s PythonRepository) MarshalJSON() ([]byte, error) { type RemoteRepositoryConfig struct { // AptRepository: Specific settings for an Apt remote repository. AptRepository *AptRepository `json:"aptRepository,omitempty"` + // CommonRepository: Common remote repository settings. Used as the RR upstream + // URL instead of Predefined and Custom remote repositories. UI and Gcloud will + // map all the new remote repositories to this field. + CommonRepository *CommonRemoteRepository `json:"commonRepository,omitempty"` // Description: The description of the remote source. Description string `json:"description,omitempty"` // DisableUpstreamValidation: Input only. A create/update remote repo option to @@ -4496,10 +4522,10 @@ func (r *ProjectsLocationsRepositoriesService) List(parent string) *ProjectsLoca // Filter sets the optional parameter "filter": An expression for filtering the // results of the request. Filter rules are case insensitive. The fields // eligible for filtering are: * `name` Examples of using a filter: To filter -// the results of your request to repositories with the name "my-repo" in -// project my-project in the us-central region, append the following filter +// the results of your request to repositories with the name `my-repo` in +// project `my-project` in the `us-central` region, append the following filter // expression to your request: * -// `name="projects/my-project/locations/us-central1/repositories/my-repo` You +// `name="projects/my-project/locations/us-central1/repositories/my-repo" You // can also use wildcards to match any number of characters before or after the // value: * // `name="projects/my-project/locations/us-central1/repositories/my-*" * @@ -5850,8 +5876,9 @@ func (r *ProjectsLocationsRepositoriesFilesService) List(parent string) *Project // results of the request. Filter rules are case insensitive. The fields // eligible for filtering are: * `name` * `owner` * `annotations` Examples of // using a filter: To filter the results of your request to files with the name -// "my_file.txt" in project my-project in the us-central region, in repository -// my-repo, append the following filter expression to your request: * +// `my_file.txt` in project `my-project` in the `us-central` region, in +// repository `my-repo`, append the following filter expression to your +// request: * // `name="projects/my-project/locations/us-central1/repositories/my-repo/files/m // y-file.txt" You can also use wildcards to match any number of characters // before or after the value: * @@ -5865,19 +5892,19 @@ func (r *ProjectsLocationsRepositoriesFilesService) List(parent string) *Project // request: * // `owner="projects/my-project/locations/us-central1/repositories/my-repo/packag // es/my-package/versions/1.0" To filter the results of your request to files -// with the annotation key-value pair [`external_link`:`external_link_value`], +// with the annotation key-value pair [`external_link`: `external_link_value`], // append the following filter expression to your request: * // "annotations.external_link:external_link_value" To filter just for a // specific annotation key `external_link`, append the following filter -// expression to your request: * "annotations.external_link" If the annotation -// key or value contains special characters, you can escape them by surrounding -// the value with backticks. For example, to filter the results of your request -// to files with the annotation key-value pair +// expression to your request: * "annotations.external_link" If the +// annotation key or value contains special characters, you can escape them by +// surrounding the value with backticks. For example, to filter the results of +// your request to files with the annotation key-value pair // [`external.link`:`https://example.com/my-file`], append the following filter -// expression to your request: * -// "annotations.`external.link`:`https://example.com/my-file" You can also +// expression to your request: * “ +// "annotations.`external.link`:`https://example.com/my-file" “ You can also // filter with annotations with a wildcard to match any number of characters -// before or after the value: * "annotations.*_link:`*example.com*" +// before or after the value: * “ "annotations.*_link:`*example.com*" “ func (c *ProjectsLocationsRepositoriesFilesListCall) Filter(filter string) *ProjectsLocationsRepositoriesFilesListCall { c.urlParams_.Set("filter", filter) return c @@ -7537,8 +7564,9 @@ func (r *ProjectsLocationsRepositoriesPackagesService) List(parent string) *Proj // results of the request. Filter rules are case insensitive. The fields // eligible for filtering are: * `name` * `annotations` Examples of using a // filter: To filter the results of your request to packages with the name -// "my-package" in project my-project in the us-central region, in repository -// my-repo, append the following filter expression to your request: * +// `my-package` in project `my-project` in the `us-central` region, in +// repository `my-repo`, append the following filter expression to your +// request: * // `name="projects/my-project/locations/us-central1/repositories/my-repo/package // s/my-package" You can also use wildcards to match any number of characters // before or after the value: * @@ -7548,19 +7576,20 @@ func (r *ProjectsLocationsRepositoriesPackagesService) List(parent string) *Proj // s/*package" * // `name="projects/my-project/locations/us-central1/repositories/my-repo/package // s/*pack*" To filter the results of your request to packages with the -// annotation key-value pair [`external_link`:`external_link_value`], append +// annotation key-value pair [`external_link`: `external_link_value`], append // the following filter expression to your request": * // "annotations.external_link:external_link_value" To filter the results just // for a specific annotation key `external_link`, append the following filter -// expression to your request: * "annotations.external_link" If the annotation -// key or value contains special characters, you can escape them by surrounding -// the value with backticks. For example, to filter the results of your request -// to packages with the annotation key-value pair +// expression to your request: * "annotations.external_link" If the +// annotation key or value contains special characters, you can escape them by +// surrounding the value with backticks. For example, to filter the results of +// your request to packages with the annotation key-value pair // [`external.link`:`https://example.com/my-package`], append the following -// filter expression to your request: * -// "annotations.`external.link`:`https://example.com/my-package" You can also -// filter with annotations with a wildcard to match any number of characters -// before or after the value: * "annotations.*_link:`*example.com*" +// filter expression to your request: * “ +// "annotations.`external.link`:`https://example.com/my-package" “ You can +// also filter with annotations with a wildcard to match any number of +// characters before or after the value: * “ +// "annotations.*_link:`*example.com*" “ func (c *ProjectsLocationsRepositoriesPackagesListCall) Filter(filter string) *ProjectsLocationsRepositoriesPackagesListCall { c.urlParams_.Set("filter", filter) return c @@ -8142,8 +8171,8 @@ func (r *ProjectsLocationsRepositoriesPackagesTagsService) List(parent string) * // Filter sets the optional parameter "filter": An expression for filtering the // results of the request. Filter rules are case insensitive. The fields // eligible for filtering are: * `name` * `version` Examples of using a filter: -// To filter the results of your request to tags with the name "my-tag" in -// package "my-package" in repository "my-repo" in project "my-project" in the +// To filter the results of your request to tags with the name `my-tag` in +// package `my-package` in repository `my-repo` in project "y-project` in the // us-central region, append the following filter expression to your request: * // `name="projects/my-project/locations/us-central1/repositories/my-repo/package // s/my-package/tags/my-tag" You can also use wildcards to match any number of @@ -8755,8 +8784,9 @@ func (r *ProjectsLocationsRepositoriesPackagesVersionsService) List(parent strin // results of the request. Filter rules are case insensitive. The fields // eligible for filtering are: * `name` * `annotations` Examples of using a // filter: To filter the results of your request to versions with the name -// "my-version" in project my-project in the us-central region, in repository -// my-repo, append the following filter expression to your request: * +// `my-version` in project `my-project` in the `us-central` region, in +// repository `my-repo`, append the following filter expression to your +// request: * // `name="projects/my-project/locations/us-central1/repositories/my-repo/package // s/my-package/versions/my-version" You can also use wildcards to match any // number of characters before or after the value: * @@ -8766,20 +8796,20 @@ func (r *ProjectsLocationsRepositoriesPackagesVersionsService) List(parent strin // s/my-package/versions/my*" * // `name="projects/my-project/locations/us-central1/repositories/my-repo/package // s/my-package/versions/*version*" To filter the results of your request to -// versions with the annotation key-value pair -// [`external_link`:`external_link_value`], append the following filter -// expression to your request: * -// "annotations.external_link:external_link_value" To filter just for a -// specific annotation key `external_link`, append the following filter -// expression to your request: * "annotations.external_link" If the annotation -// key or value contains special characters, you can escape them by surrounding -// the value with backticks. For example, to filter the results of your request -// to versions with the annotation key-value pair +// versions with the annotation key-value pair [`external_link`: +// `external_link_value`], append the following filter expression to your +// request: * "annotations.external_link:external_link_value" To filter just +// for a specific annotation key `external_link`, append the following filter +// expression to your request: * "annotations.external_link" If the +// annotation key or value contains special characters, you can escape them by +// surrounding the value with backticks. For example, to filter the results of +// your request to versions with the annotation key-value pair // [`external.link`:`https://example.com/my-version`], append the following -// filter expression to your request: * -// "annotations.`external.link`:`https://example.com/my-version" You can also -// filter with annotations with a wildcard to match any number of characters -// before or after the value: * "annotations.*_link:`*example.com*" +// filter expression to your request: * “ +// "annotations.`external.link`:`https://example.com/my-version" “ You can +// also filter with annotations with a wildcard to match any number of +// characters before or after the value: * “ +// "annotations.*_link:`*example.com*" “ func (c *ProjectsLocationsRepositoriesPackagesVersionsListCall) Filter(filter string) *ProjectsLocationsRepositoriesPackagesVersionsListCall { c.urlParams_.Set("filter", filter) return c diff --git a/artifactregistry/v1beta1/artifactregistry-api.json b/artifactregistry/v1beta1/artifactregistry-api.json index b776a16ec03..26280b979aa 100644 --- a/artifactregistry/v1beta1/artifactregistry-api.json +++ b/artifactregistry/v1beta1/artifactregistry-api.json @@ -720,7 +720,7 @@ ], "parameters": { "filter": { - "description": "An expression for filtering the results of the request. Filter rules are case insensitive. The fields eligible for filtering are: * `name` * `owner` * `annotations` Examples of using a filter: To filter the results of your request to files with the name \"my_file.txt\" in project my-project in the us-central region, in repository my-repo, append the following filter expression to your request: * `name=\"projects/my-project/locations/us-central1/repositories/my-repo/files/my-file.txt\"` You can also use wildcards to match any number of characters before or after the value: * `name=\"projects/my-project/locations/us-central1/repositories/my-repo/files/my-*\"` * `name=\"projects/my-project/locations/us-central1/repositories/my-repo/files/*file.txt\"` * `name=\"projects/my-project/locations/us-central1/repositories/my-repo/files/*file*\"` To filter the results of your request to files owned by the version `1.0` in package `pkg1`, append the following filter expression to your request: * `owner=\"projects/my-project/locations/us-central1/repositories/my-repo/packages/my-package/versions/1.0\"` To filter the results of your request to files with the annotation key-value pair [`external_link`:`external_link_value`], append the following filter expression to your request: * \"annotations.external_link:external_link_value\" To filter just for a specific annotation key `external_link`, append the following filter expression to your request: * \"annotations.external_link\" If the annotation key or value contains special characters, you can escape them by surrounding the value with backticks. For example, to filter the results of your request to files with the annotation key-value pair [`external.link`:`https://example.com/my-file`], append the following filter expression to your request: * \"annotations.`external.link`:`https://example.com/my-file`\" You can also filter with annotations with a wildcard to match any number of characters before or after the value: * \"annotations.*_link:`*example.com*`\"", + "description": "An expression for filtering the results of the request. Filter rules are case insensitive. The fields eligible for filtering are: * `name` * `owner` * `annotations` Examples of using a filter: To filter the results of your request to files with the name `my_file.txt` in project `my-project` in the `us-central` region, in repository `my-repo`, append the following filter expression to your request: * `name=\"projects/my-project/locations/us-central1/repositories/my-repo/files/my-file.txt\"` You can also use wildcards to match any number of characters before or after the value: * `name=\"projects/my-project/locations/us-central1/repositories/my-repo/files/my-*\"` * `name=\"projects/my-project/locations/us-central1/repositories/my-repo/files/*file.txt\"` * `name=\"projects/my-project/locations/us-central1/repositories/my-repo/files/*file*\"` To filter the results of your request to files owned by the version `1.0` in package `pkg1`, append the following filter expression to your request: * `owner=\"projects/my-project/locations/us-central1/repositories/my-repo/packages/my-package/versions/1.0\"` To filter the results of your request to files with the annotation key-value pair [`external_link`: `external_link_value`], append the following filter expression to your request: * `\"annotations.external_link:external_link_value\"` To filter just for a specific annotation key `external_link`, append the following filter expression to your request: * `\"annotations.external_link\"` If the annotation key or value contains special characters, you can escape them by surrounding the value with backticks. For example, to filter the results of your request to files with the annotation key-value pair [`external.link`:`https://example.com/my-file`], append the following filter expression to your request: * `` \"annotations.`external.link`:`https://example.com/my-file`\" `` You can also filter with annotations with a wildcard to match any number of characters before or after the value: * `` \"annotations.*_link:`*example.com*`\" ``", "location": "query", "type": "string" }, @@ -947,7 +947,7 @@ ], "parameters": { "filter": { - "description": "An expression for filtering the results of the request. Filter rules are case insensitive. The fields eligible for filtering are: * `name` * `version` Examples of using a filter: To filter the results of your request to tags with the name \"my-tag\" in package \"my-package\" in repository \"my-repo\" in project \"my-project\" in the us-central region, append the following filter expression to your request: * `name=\"projects/my-project/locations/us-central1/repositories/my-repo/packages/my-package/tags/my-tag\"` You can also use wildcards to match any number of characters before or after the value: * `name=\"projects/my-project/locations/us-central1/repositories/my-repo/packages/my-package/tags/my*\"` * `name=\"projects/my-project/locations/us-central1/repositories/my-repo/packages/my-package/tags/*tag\"` * `name=\"projects/my-project/locations/us-central1/repositories/my-repo/packages/my-package/tags/*tag*\"` To filter the results of your request to tags applied to the version `1.0` in package `my-package`, append the following filter expression to your request: * `version=\"projects/my-project/locations/us-central1/repositories/my-repo/packages/my-package/versions/1.0\"`", + "description": "An expression for filtering the results of the request. Filter rules are case insensitive. The fields eligible for filtering are: * `name` * `version` Examples of using a filter: To filter the results of your request to tags with the name `my-tag` in package `my-package` in repository `my-repo` in project \"`y-project` in the us-central region, append the following filter expression to your request: * `name=\"projects/my-project/locations/us-central1/repositories/my-repo/packages/my-package/tags/my-tag\"` You can also use wildcards to match any number of characters before or after the value: * `name=\"projects/my-project/locations/us-central1/repositories/my-repo/packages/my-package/tags/my*\"` * `name=\"projects/my-project/locations/us-central1/repositories/my-repo/packages/my-package/tags/*tag\"` * `name=\"projects/my-project/locations/us-central1/repositories/my-repo/packages/my-package/tags/*tag*\"` To filter the results of your request to tags applied to the version `1.0` in package `my-package`, append the following filter expression to your request: * `version=\"projects/my-project/locations/us-central1/repositories/my-repo/packages/my-package/versions/1.0\"`", "location": "query", "type": "string" }, @@ -1156,7 +1156,7 @@ } } }, - "revision": "20240826", + "revision": "20240903", "rootUrl": "https://artifactregistry.googleapis.com/", "schemas": { "Binding": { diff --git a/artifactregistry/v1beta1/artifactregistry-gen.go b/artifactregistry/v1beta1/artifactregistry-gen.go index f80c39f06c3..5811da08515 100644 --- a/artifactregistry/v1beta1/artifactregistry-gen.go +++ b/artifactregistry/v1beta1/artifactregistry-gen.go @@ -2517,8 +2517,9 @@ func (r *ProjectsLocationsRepositoriesFilesService) List(parent string) *Project // results of the request. Filter rules are case insensitive. The fields // eligible for filtering are: * `name` * `owner` * `annotations` Examples of // using a filter: To filter the results of your request to files with the name -// "my_file.txt" in project my-project in the us-central region, in repository -// my-repo, append the following filter expression to your request: * +// `my_file.txt` in project `my-project` in the `us-central` region, in +// repository `my-repo`, append the following filter expression to your +// request: * // `name="projects/my-project/locations/us-central1/repositories/my-repo/files/m // y-file.txt" You can also use wildcards to match any number of characters // before or after the value: * @@ -2532,19 +2533,19 @@ func (r *ProjectsLocationsRepositoriesFilesService) List(parent string) *Project // request: * // `owner="projects/my-project/locations/us-central1/repositories/my-repo/packag // es/my-package/versions/1.0" To filter the results of your request to files -// with the annotation key-value pair [`external_link`:`external_link_value`], +// with the annotation key-value pair [`external_link`: `external_link_value`], // append the following filter expression to your request: * // "annotations.external_link:external_link_value" To filter just for a // specific annotation key `external_link`, append the following filter -// expression to your request: * "annotations.external_link" If the annotation -// key or value contains special characters, you can escape them by surrounding -// the value with backticks. For example, to filter the results of your request -// to files with the annotation key-value pair +// expression to your request: * "annotations.external_link" If the +// annotation key or value contains special characters, you can escape them by +// surrounding the value with backticks. For example, to filter the results of +// your request to files with the annotation key-value pair // [`external.link`:`https://example.com/my-file`], append the following filter -// expression to your request: * -// "annotations.`external.link`:`https://example.com/my-file" You can also +// expression to your request: * “ +// "annotations.`external.link`:`https://example.com/my-file" “ You can also // filter with annotations with a wildcard to match any number of characters -// before or after the value: * "annotations.*_link:`*example.com*" +// before or after the value: * “ "annotations.*_link:`*example.com*" “ func (c *ProjectsLocationsRepositoriesFilesListCall) Filter(filter string) *ProjectsLocationsRepositoriesFilesListCall { c.urlParams_.Set("filter", filter) return c @@ -3361,8 +3362,8 @@ func (r *ProjectsLocationsRepositoriesPackagesTagsService) List(parent string) * // Filter sets the optional parameter "filter": An expression for filtering the // results of the request. Filter rules are case insensitive. The fields // eligible for filtering are: * `name` * `version` Examples of using a filter: -// To filter the results of your request to tags with the name "my-tag" in -// package "my-package" in repository "my-repo" in project "my-project" in the +// To filter the results of your request to tags with the name `my-tag` in +// package `my-package` in repository `my-repo` in project "y-project` in the // us-central region, append the following filter expression to your request: * // `name="projects/my-project/locations/us-central1/repositories/my-repo/package // s/my-package/tags/my-tag" You can also use wildcards to match any number of diff --git a/artifactregistry/v1beta2/artifactregistry-api.json b/artifactregistry/v1beta2/artifactregistry-api.json index 94b5ae2be4c..6aae827c859 100644 --- a/artifactregistry/v1beta2/artifactregistry-api.json +++ b/artifactregistry/v1beta2/artifactregistry-api.json @@ -882,7 +882,7 @@ ], "parameters": { "filter": { - "description": "An expression for filtering the results of the request. Filter rules are case insensitive. The fields eligible for filtering are: * `name` * `owner` * `annotations` Examples of using a filter: To filter the results of your request to files with the name \"my_file.txt\" in project my-project in the us-central region, in repository my-repo, append the following filter expression to your request: * `name=\"projects/my-project/locations/us-central1/repositories/my-repo/files/my-file.txt\"` You can also use wildcards to match any number of characters before or after the value: * `name=\"projects/my-project/locations/us-central1/repositories/my-repo/files/my-*\"` * `name=\"projects/my-project/locations/us-central1/repositories/my-repo/files/*file.txt\"` * `name=\"projects/my-project/locations/us-central1/repositories/my-repo/files/*file*\"` To filter the results of your request to files owned by the version `1.0` in package `pkg1`, append the following filter expression to your request: * `owner=\"projects/my-project/locations/us-central1/repositories/my-repo/packages/my-package/versions/1.0\"` To filter the results of your request to files with the annotation key-value pair [`external_link`:`external_link_value`], append the following filter expression to your request: * \"annotations.external_link:external_link_value\" To filter just for a specific annotation key `external_link`, append the following filter expression to your request: * \"annotations.external_link\" If the annotation key or value contains special characters, you can escape them by surrounding the value with backticks. For example, to filter the results of your request to files with the annotation key-value pair [`external.link`:`https://example.com/my-file`], append the following filter expression to your request: * \"annotations.`external.link`:`https://example.com/my-file`\" You can also filter with annotations with a wildcard to match any number of characters before or after the value: * \"annotations.*_link:`*example.com*`\"", + "description": "An expression for filtering the results of the request. Filter rules are case insensitive. The fields eligible for filtering are: * `name` * `owner` * `annotations` Examples of using a filter: To filter the results of your request to files with the name `my_file.txt` in project `my-project` in the `us-central` region, in repository `my-repo`, append the following filter expression to your request: * `name=\"projects/my-project/locations/us-central1/repositories/my-repo/files/my-file.txt\"` You can also use wildcards to match any number of characters before or after the value: * `name=\"projects/my-project/locations/us-central1/repositories/my-repo/files/my-*\"` * `name=\"projects/my-project/locations/us-central1/repositories/my-repo/files/*file.txt\"` * `name=\"projects/my-project/locations/us-central1/repositories/my-repo/files/*file*\"` To filter the results of your request to files owned by the version `1.0` in package `pkg1`, append the following filter expression to your request: * `owner=\"projects/my-project/locations/us-central1/repositories/my-repo/packages/my-package/versions/1.0\"` To filter the results of your request to files with the annotation key-value pair [`external_link`: `external_link_value`], append the following filter expression to your request: * `\"annotations.external_link:external_link_value\"` To filter just for a specific annotation key `external_link`, append the following filter expression to your request: * `\"annotations.external_link\"` If the annotation key or value contains special characters, you can escape them by surrounding the value with backticks. For example, to filter the results of your request to files with the annotation key-value pair [`external.link`:`https://example.com/my-file`], append the following filter expression to your request: * `` \"annotations.`external.link`:`https://example.com/my-file`\" `` You can also filter with annotations with a wildcard to match any number of characters before or after the value: * `` \"annotations.*_link:`*example.com*`\" ``", "location": "query", "type": "string" }, @@ -1143,7 +1143,7 @@ ], "parameters": { "filter": { - "description": "An expression for filtering the results of the request. Filter rules are case insensitive. The fields eligible for filtering are: * `name` * `version` Examples of using a filter: To filter the results of your request to tags with the name \"my-tag\" in package \"my-package\" in repository \"my-repo\" in project \"my-project\" in the us-central region, append the following filter expression to your request: * `name=\"projects/my-project/locations/us-central1/repositories/my-repo/packages/my-package/tags/my-tag\"` You can also use wildcards to match any number of characters before or after the value: * `name=\"projects/my-project/locations/us-central1/repositories/my-repo/packages/my-package/tags/my*\"` * `name=\"projects/my-project/locations/us-central1/repositories/my-repo/packages/my-package/tags/*tag\"` * `name=\"projects/my-project/locations/us-central1/repositories/my-repo/packages/my-package/tags/*tag*\"` To filter the results of your request to tags applied to the version `1.0` in package `my-package`, append the following filter expression to your request: * `version=\"projects/my-project/locations/us-central1/repositories/my-repo/packages/my-package/versions/1.0\"`", + "description": "An expression for filtering the results of the request. Filter rules are case insensitive. The fields eligible for filtering are: * `name` * `version` Examples of using a filter: To filter the results of your request to tags with the name `my-tag` in package `my-package` in repository `my-repo` in project \"`y-project` in the us-central region, append the following filter expression to your request: * `name=\"projects/my-project/locations/us-central1/repositories/my-repo/packages/my-package/tags/my-tag\"` You can also use wildcards to match any number of characters before or after the value: * `name=\"projects/my-project/locations/us-central1/repositories/my-repo/packages/my-package/tags/my*\"` * `name=\"projects/my-project/locations/us-central1/repositories/my-repo/packages/my-package/tags/*tag\"` * `name=\"projects/my-project/locations/us-central1/repositories/my-repo/packages/my-package/tags/*tag*\"` To filter the results of your request to tags applied to the version `1.0` in package `my-package`, append the following filter expression to your request: * `version=\"projects/my-project/locations/us-central1/repositories/my-repo/packages/my-package/versions/1.0\"`", "location": "query", "type": "string" }, @@ -1424,7 +1424,7 @@ } } }, - "revision": "20240826", + "revision": "20240903", "rootUrl": "https://artifactregistry.googleapis.com/", "schemas": { "AptArtifact": { diff --git a/artifactregistry/v1beta2/artifactregistry-gen.go b/artifactregistry/v1beta2/artifactregistry-gen.go index 947bfcdd411..1ac9e872c40 100644 --- a/artifactregistry/v1beta2/artifactregistry-gen.go +++ b/artifactregistry/v1beta2/artifactregistry-gen.go @@ -3653,8 +3653,9 @@ func (r *ProjectsLocationsRepositoriesFilesService) List(parent string) *Project // results of the request. Filter rules are case insensitive. The fields // eligible for filtering are: * `name` * `owner` * `annotations` Examples of // using a filter: To filter the results of your request to files with the name -// "my_file.txt" in project my-project in the us-central region, in repository -// my-repo, append the following filter expression to your request: * +// `my_file.txt` in project `my-project` in the `us-central` region, in +// repository `my-repo`, append the following filter expression to your +// request: * // `name="projects/my-project/locations/us-central1/repositories/my-repo/files/m // y-file.txt" You can also use wildcards to match any number of characters // before or after the value: * @@ -3668,19 +3669,19 @@ func (r *ProjectsLocationsRepositoriesFilesService) List(parent string) *Project // request: * // `owner="projects/my-project/locations/us-central1/repositories/my-repo/packag // es/my-package/versions/1.0" To filter the results of your request to files -// with the annotation key-value pair [`external_link`:`external_link_value`], +// with the annotation key-value pair [`external_link`: `external_link_value`], // append the following filter expression to your request: * // "annotations.external_link:external_link_value" To filter just for a // specific annotation key `external_link`, append the following filter -// expression to your request: * "annotations.external_link" If the annotation -// key or value contains special characters, you can escape them by surrounding -// the value with backticks. For example, to filter the results of your request -// to files with the annotation key-value pair +// expression to your request: * "annotations.external_link" If the +// annotation key or value contains special characters, you can escape them by +// surrounding the value with backticks. For example, to filter the results of +// your request to files with the annotation key-value pair // [`external.link`:`https://example.com/my-file`], append the following filter -// expression to your request: * -// "annotations.`external.link`:`https://example.com/my-file" You can also +// expression to your request: * “ +// "annotations.`external.link`:`https://example.com/my-file" “ You can also // filter with annotations with a wildcard to match any number of characters -// before or after the value: * "annotations.*_link:`*example.com*" +// before or after the value: * “ "annotations.*_link:`*example.com*" “ func (c *ProjectsLocationsRepositoriesFilesListCall) Filter(filter string) *ProjectsLocationsRepositoriesFilesListCall { c.urlParams_.Set("filter", filter) return c @@ -4608,8 +4609,8 @@ func (r *ProjectsLocationsRepositoriesPackagesTagsService) List(parent string) * // Filter sets the optional parameter "filter": An expression for filtering the // results of the request. Filter rules are case insensitive. The fields // eligible for filtering are: * `name` * `version` Examples of using a filter: -// To filter the results of your request to tags with the name "my-tag" in -// package "my-package" in repository "my-repo" in project "my-project" in the +// To filter the results of your request to tags with the name `my-tag` in +// package `my-package` in repository `my-repo` in project "y-project` in the // us-central region, append the following filter expression to your request: * // `name="projects/my-project/locations/us-central1/repositories/my-repo/package // s/my-package/tags/my-tag" You can also use wildcards to match any number of diff --git a/backupdr/v1/backupdr-api.json b/backupdr/v1/backupdr-api.json index 1510c627436..fc21b2299e5 100644 --- a/backupdr/v1/backupdr-api.json +++ b/backupdr/v1/backupdr-api.json @@ -1598,7 +1598,7 @@ } } }, - "revision": "20240815", + "revision": "20240828", "rootUrl": "https://backupdr.googleapis.com/", "schemas": { "AbandonBackupRequest": { @@ -2668,6 +2668,13 @@ ], "type": "string" }, + "labels": { + "additionalProperties": { + "type": "string" + }, + "description": "Labels to apply to instances that are created from these properties.", + "type": "object" + }, "machineType": { "description": "The machine type to use for instances that are created from these properties.", "type": "string" diff --git a/backupdr/v1/backupdr-gen.go b/backupdr/v1/backupdr-gen.go index 52579b44f44..d8ddd754427 100644 --- a/backupdr/v1/backupdr-gen.go +++ b/backupdr/v1/backupdr-gen.go @@ -1406,6 +1406,8 @@ type ComputeInstanceBackupProperties struct { // "NONE" - Indicates user chose no operation. // "STOP" - Indicates user chose to opt for VM shutdown on key revocation. KeyRevocationActionType string `json:"keyRevocationActionType,omitempty"` + // 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. MachineType string `json:"machineType,omitempty"` diff --git a/baremetalsolution/v2/baremetalsolution-api.json b/baremetalsolution/v2/baremetalsolution-api.json index 0194c109df2..394af57f49e 100644 --- a/baremetalsolution/v2/baremetalsolution-api.json +++ b/baremetalsolution/v2/baremetalsolution-api.json @@ -1722,7 +1722,7 @@ } } }, - "revision": "20240422", + "revision": "20240830", "rootUrl": "https://baremetalsolution.googleapis.com/", "schemas": { "AllowedClient": { @@ -2847,7 +2847,7 @@ "type": "string" }, "vlanAttachments": { - "description": "List of VLAN attachments. As of now there are always 2 attachments, but it is going to change in the future (multi vlan).", + "description": "List of VLAN attachments. As of now there are always 2 attachments, but it is going to change in the future (multi vlan). Use only one of vlan_attachments or vrf", "items": { "$ref": "IntakeVlanAttachment" }, @@ -2856,6 +2856,10 @@ "vlanSameProject": { "description": "Whether the VLAN attachment pair is located in the same project.", "type": "boolean" + }, + "vrf": { + "description": "Optional. The name of a pre-existing Vrf that the network should be attached to. Format is `vrfs/{vrf}`. If vrf is specified, vlan_attachments must be empty.", + "type": "string" } }, "type": "object" diff --git a/baremetalsolution/v2/baremetalsolution-gen.go b/baremetalsolution/v2/baremetalsolution-gen.go index 3b7490e191d..22dbe242ffb 100644 --- a/baremetalsolution/v2/baremetalsolution-gen.go +++ b/baremetalsolution/v2/baremetalsolution-gen.go @@ -1411,11 +1411,16 @@ type NetworkConfig struct { // information for the BMS Ops team . UserNote string `json:"userNote,omitempty"` // VlanAttachments: List of VLAN attachments. As of now there are always 2 - // attachments, but it is going to change in the future (multi vlan). + // attachments, but it is going to change in the future (multi vlan). Use only + // one of vlan_attachments or vrf VlanAttachments []*IntakeVlanAttachment `json:"vlanAttachments,omitempty"` // VlanSameProject: Whether the VLAN attachment pair is located in the same // project. VlanSameProject bool `json:"vlanSameProject,omitempty"` + // Vrf: Optional. The name of a pre-existing Vrf that the network should be + // attached to. Format is `vrfs/{vrf}`. If vrf is specified, vlan_attachments + // must be empty. + Vrf string `json:"vrf,omitempty"` // ForceSendFields is a list of field names (e.g. "Bandwidth") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See diff --git a/chat/v1/chat-api.json b/chat/v1/chat-api.json index 9bfc6265828..e878fae1c5f 100644 --- a/chat/v1/chat-api.json +++ b/chat/v1/chat-api.json @@ -1324,7 +1324,7 @@ } } }, - "revision": "20240825", + "revision": "20240829", "rootUrl": "https://chat.googleapis.com/", "schemas": { "AccessSettings": { @@ -1736,6 +1736,25 @@ }, "type": "object" }, + "ChatSpaceLinkData": { + "description": "Data for Chat space links. [Developer Preview](https://developers.google.com/workspace/preview).", + "id": "ChatSpaceLinkData", + "properties": { + "message": { + "description": "The message of the linked Chat space resource. Format: `spaces/{space}/messages/{message}`", + "type": "string" + }, + "space": { + "description": "The space of the linked Chat space resource. Format: `spaces/{space}`", + "type": "string" + }, + "thread": { + "description": "The thread of the linked Chat space resource. Format: `spaces/{space}/threads/{thread}`", + "type": "string" + } + }, + "type": "object" + }, "Color": { "description": "Represents a color in the RGBA color space. This representation is designed for simplicity of conversion to and from color representations in various languages over compactness. For example, the fields of this representation can be trivially provided to the constructor of `java.awt.Color` in Java; it can also be trivially provided to UIColor's `+colorWithRed:green:blue:alpha` method in iOS; and, with just a little work, it can be easily formatted into a CSS `rgba()` string in JavaScript. This reference page doesn't have information about the absolute color space that should be used to interpret the RGB value—for example, sRGB, Adobe RGB, DCI-P3, and BT.2020. By default, applications should assume the sRGB color space. When color equality needs to be decided, implementations, unless documented otherwise, treat two colors as equal if all their red, green, blue, and alpha values each differ by at most `1e-5`. Example (Java): import com.google.type.Color; // ... public static java.awt.Color fromProto(Color protocolor) { float alpha = protocolor.hasAlpha() ? protocolor.getAlpha().getValue() : 1.0; return new java.awt.Color( protocolor.getRed(), protocolor.getGreen(), protocolor.getBlue(), alpha); } public static Color toProto(java.awt.Color color) { float red = (float) color.getRed(); float green = (float) color.getGreen(); float blue = (float) color.getBlue(); float denominator = 255.0; Color.Builder resultBuilder = Color .newBuilder() .setRed(red / denominator) .setGreen(green / denominator) .setBlue(blue / denominator); int alpha = color.getAlpha(); if (alpha != 255) { result.setAlpha( FloatValue .newBuilder() .setValue(((float) alpha) / denominator) .build()); } return resultBuilder.build(); } // ... Example (iOS / Obj-C): // ... static UIColor* fromProto(Color* protocolor) { float red = [protocolor red]; float green = [protocolor green]; float blue = [protocolor blue]; FloatValue* alpha_wrapper = [protocolor alpha]; float alpha = 1.0; if (alpha_wrapper != nil) { alpha = [alpha_wrapper value]; } return [UIColor colorWithRed:red green:green blue:blue alpha:alpha]; } static Color* toProto(UIColor* color) { CGFloat red, green, blue, alpha; if (![color getRed:\u0026red green:\u0026green blue:\u0026blue alpha:\u0026alpha]) { return nil; } Color* result = [[Color alloc] init]; [result setRed:red]; [result setGreen:green]; [result setBlue:blue]; if (alpha \u003c= 0.9999) { [result setAlpha:floatWrapperWithValue(alpha)]; } [result autorelease]; return result; } // ... Example (JavaScript): // ... var protoToCssColor = function(rgb_color) { var redFrac = rgb_color.red || 0.0; var greenFrac = rgb_color.green || 0.0; var blueFrac = rgb_color.blue || 0.0; var red = Math.floor(redFrac * 255); var green = Math.floor(greenFrac * 255); var blue = Math.floor(blueFrac * 255); if (!('alpha' in rgb_color)) { return rgbToCssColor(red, green, blue); } var alphaFrac = rgb_color.alpha.value || 0.0; var rgbParams = [red, green, blue].join(','); return ['rgba(', rgbParams, ',', alphaFrac, ')'].join(''); }; var rgbToCssColor = function(red, green, blue) { var rgbNumber = new Number((red \u003c\u003c 16) | (green \u003c\u003c 8) | blue); var hexString = rgbNumber.toString(16); var missingZeros = 6 - hexString.length; var resultBuilder = ['#']; for (var i = 0; i \u003c missingZeros; i++) { resultBuilder.push('0'); } resultBuilder.push(hexString); return resultBuilder.join(''); }; // ...", "id": "Color", @@ -1800,7 +1819,7 @@ "The add-on launches from Google Sheets.", "The add-on launches from Google Slides.", "The add-on launches from Google Drawings.", - "A Google Chat app." + "A Google Chat app. Not used for Google Workspace Add-ons." ], "type": "string" }, @@ -4046,6 +4065,10 @@ "description": "A rich link to a resource.", "id": "RichLinkMetadata", "properties": { + "chatSpaceLinkData": { + "$ref": "ChatSpaceLinkData", + "description": "Data for a chat space link. [Developer Preview](https://developers.google.com/workspace/preview)." + }, "driveLinkData": { "$ref": "DriveLinkData", "description": "Data for a drive link." @@ -4054,11 +4077,13 @@ "description": "The rich link type.", "enum": [ "RICH_LINK_TYPE_UNSPECIFIED", - "DRIVE_FILE" + "DRIVE_FILE", + "CHAT_SPACE" ], "enumDescriptions": [ "Default value for the enum. Don't use.", - "A Google Drive rich link type." + "A Google Drive rich link type.", + "A Chat space rich link type. For example, a space smart chip. [Developer Preview](https://developers.google.com/workspace/preview)." ], "type": "string" }, diff --git a/chat/v1/chat-gen.go b/chat/v1/chat-gen.go index 13017515f4c..c54c87690a2 100644 --- a/chat/v1/chat-gen.go +++ b/chat/v1/chat-gen.go @@ -968,6 +968,35 @@ func (s ChatClientDataSourceMarkup) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// ChatSpaceLinkData: Data for Chat space links. Developer Preview +// (https://developers.google.com/workspace/preview). +type ChatSpaceLinkData struct { + // Message: The message of the linked Chat space resource. Format: + // `spaces/{space}/messages/{message}` + Message string `json:"message,omitempty"` + // Space: The space of the linked Chat space resource. Format: `spaces/{space}` + Space string `json:"space,omitempty"` + // Thread: The thread of the linked Chat space resource. Format: + // `spaces/{space}/threads/{thread}` + Thread string `json:"thread,omitempty"` + // ForceSendFields is a list of field names (e.g. "Message") 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. "Message") 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 ChatSpaceLinkData) MarshalJSON() ([]byte, error) { + type NoMethod ChatSpaceLinkData + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // Color: Represents a color in the RGBA color space. This representation is // designed for simplicity of conversion to and from color representations in // various languages over compactness. For example, the fields of this @@ -1096,7 +1125,7 @@ type CommonEventObject struct { // "SHEETS" - The add-on launches from Google Sheets. // "SLIDES" - The add-on launches from Google Slides. // "DRAWINGS" - The add-on launches from Google Drawings. - // "CHAT" - A Google Chat app. + // "CHAT" - A Google Chat app. Not used for Google Workspace Add-ons. HostApp string `json:"hostApp,omitempty"` // InvokedFunction: Name of the invoked function associated with the widget. // Only set for Chat apps. @@ -4438,6 +4467,9 @@ func (s ReactionDeletedEventData) MarshalJSON() ([]byte, error) { // RichLinkMetadata: A rich link to a resource. type RichLinkMetadata struct { + // ChatSpaceLinkData: Data for a chat space link. Developer Preview + // (https://developers.google.com/workspace/preview). + ChatSpaceLinkData *ChatSpaceLinkData `json:"chatSpaceLinkData,omitempty"` // DriveLinkData: Data for a drive link. DriveLinkData *DriveLinkData `json:"driveLinkData,omitempty"` // RichLinkType: The rich link type. @@ -4445,18 +4477,20 @@ type RichLinkMetadata struct { // Possible values: // "RICH_LINK_TYPE_UNSPECIFIED" - Default value for the enum. Don't use. // "DRIVE_FILE" - A Google Drive rich link type. + // "CHAT_SPACE" - A Chat space rich link type. For example, a space smart + // chip. [Developer Preview](https://developers.google.com/workspace/preview). RichLinkType string `json:"richLinkType,omitempty"` // Uri: The URI of this link. Uri string `json:"uri,omitempty"` - // ForceSendFields is a list of field names (e.g. "DriveLinkData") to + // ForceSendFields is a list of field names (e.g. "ChatSpaceLinkData") 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. "DriveLinkData") to include in API - // requests with the JSON null value. By default, fields with empty values are - // omitted from API requests. See + // NullFields is a list of field names (e.g. "ChatSpaceLinkData") 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:"-"` } diff --git a/checks/v1alpha/checks-api.json b/checks/v1alpha/checks-api.json index 4ee5233da8a..5bd5ec69989 100644 --- a/checks/v1alpha/checks-api.json +++ b/checks/v1alpha/checks-api.json @@ -368,6 +368,36 @@ } } } + }, + "repos": { + "resources": { + "operations": { + "methods": { + "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": "v1alpha/accounts/{accountsId}/repos/{reposId}/operations/{operationsId}", + "httpMethod": "GET", + "id": "checks.accounts.repos.operations.get", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "The name of the operation resource.", + "location": "path", + "pattern": "^accounts/[^/]+/repos/[^/]+/operations/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1alpha/{+name}", + "response": { + "$ref": "Operation" + } + } + } + } + } } } }, @@ -414,7 +444,7 @@ } } }, - "revision": "20240626", + "revision": "20240904", "rootUrl": "https://checks.googleapis.com/", "schemas": { "CancelOperationRequest": { diff --git a/checks/v1alpha/checks-gen.go b/checks/v1alpha/checks-gen.go index 892e3bb1cd2..248288317da 100644 --- a/checks/v1alpha/checks-gen.go +++ b/checks/v1alpha/checks-gen.go @@ -148,6 +148,7 @@ func (s *Service) userAgent() string { func NewAccountsService(s *Service) *AccountsService { rs := &AccountsService{s: s} rs.Apps = NewAccountsAppsService(s) + rs.Repos = NewAccountsReposService(s) return rs } @@ -155,6 +156,8 @@ type AccountsService struct { s *Service Apps *AccountsAppsService + + Repos *AccountsReposService } func NewAccountsAppsService(s *Service) *AccountsAppsService { @@ -190,6 +193,27 @@ type AccountsAppsReportsService struct { s *Service } +func NewAccountsReposService(s *Service) *AccountsReposService { + rs := &AccountsReposService{s: s} + rs.Operations = NewAccountsReposOperationsService(s) + return rs +} + +type AccountsReposService struct { + s *Service + + Operations *AccountsReposOperationsService +} + +func NewAccountsReposOperationsService(s *Service) *AccountsReposOperationsService { + rs := &AccountsReposOperationsService{s: s} + return rs +} + +type AccountsReposOperationsService struct { + s *Service +} + func NewMediaService(s *Service) *MediaService { rs := &MediaService{s: s} return rs @@ -2988,6 +3012,115 @@ func (c *AccountsAppsReportsListCall) Pages(ctx context.Context, f func(*GoogleC } } +type AccountsReposOperationsGetCall 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 *AccountsReposOperationsService) Get(name string) *AccountsReposOperationsGetCall { + c := &AccountsReposOperationsGetCall{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 *AccountsReposOperationsGetCall) Fields(s ...googleapi.Field) *AccountsReposOperationsGetCall { + 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 *AccountsReposOperationsGetCall) IfNoneMatch(entityTag string) *AccountsReposOperationsGetCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *AccountsReposOperationsGetCall) Context(ctx context.Context) *AccountsReposOperationsGetCall { + 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 *AccountsReposOperationsGetCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *AccountsReposOperationsGetCall) 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, "v1alpha/{+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 "checks.accounts.repos.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 *AccountsReposOperationsGetCall) 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 MediaUploadCall struct { s *Service parent string diff --git a/cloudasset/v1/cloudasset-api.json b/cloudasset/v1/cloudasset-api.json index 2cef2427047..a243e2537bc 100644 --- a/cloudasset/v1/cloudasset-api.json +++ b/cloudasset/v1/cloudasset-api.json @@ -358,59 +358,6 @@ }, "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/operations/{operationsId}:cancel", - "httpMethod": "POST", - "id": "cloudasset.operations.cancel", - "parameterOrder": [ - "name" - ], - "parameters": { - "name": { - "description": "The name of the operation resource to be cancelled.", - "location": "path", - "pattern": "^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/operations/{operationsId}", - "httpMethod": "DELETE", - "id": "cloudasset.operations.delete", - "parameterOrder": [ - "name" - ], - "parameters": { - "name": { - "description": "The name of the operation resource to be deleted.", - "location": "path", - "pattern": "^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/{v1Id}/{v1Id1}/operations/{operationsId}/{operationsId1}", @@ -1148,7 +1095,7 @@ } } }, - "revision": "20240823", + "revision": "20240831", "rootUrl": "https://cloudasset.googleapis.com/", "schemas": { "AccessSelector": { @@ -1578,12 +1525,6 @@ }, "type": "object" }, - "CancelOperationRequest": { - "description": "The request message for Operations.CancelOperation.", - "id": "CancelOperationRequest", - "properties": {}, - "type": "object" - }, "ConditionContext": { "description": "The IAM conditions context.", "id": "ConditionContext", @@ -3526,7 +3467,7 @@ "AVAILABLE_PACKAGE" ], "enumDescriptions": [ - "Invalid. An type must be specified.", + "Invalid. A type must be specified.", "This represents a package that is installed on the VM.", "This represents an update that is available for a package." ], @@ -4207,7 +4148,7 @@ "type": "array" }, "enrichments": { - "description": "Enrichments of the asset. Currently supported enrichment types with SearchAllResources API: * RESOURCE_OWNERS The corresponding read masks in order to get the enrichment: * enrichments.resource_owners The corresponding required permissions: * cloudasset.assets.searchEnrichmentResourceOwners Example query to get resource owner enrichment: scope: \"projects/my-project\" query: \"name: my-project\" assetTypes: \"cloudresourcemanager.googleapis.com/Project\" readMask: { paths: \"asset_type\" paths: \"name\" paths: \"enrichments.resource_owners\" }", + "description": "Enrichments of the asset. Currently supported enrichment types with SearchAllResources API: * RESOURCE_OWNERS The corresponding read masks in order to get the enrichment: * enrichments.resource_owners The corresponding required permissions: * cloudasset.assets.searchEnrichmentResourceOwners Example query to get resource owner enrichment: ``` scope: \"projects/my-project\" query: \"name: my-project\" assetTypes: \"cloudresourcemanager.googleapis.com/Project\" readMask: { paths: \"asset_type\" paths: \"name\" paths: \"enrichments.resource_owners\" } ```", "items": { "$ref": "AssetEnrichment" }, diff --git a/cloudasset/v1/cloudasset-gen.go b/cloudasset/v1/cloudasset-gen.go index 317bf5005ea..cc589c01787 100644 --- a/cloudasset/v1/cloudasset-gen.go +++ b/cloudasset/v1/cloudasset-gen.go @@ -998,10 +998,6 @@ func (s Binding) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// CancelOperationRequest: The request message for Operations.CancelOperation. -type CancelOperationRequest struct { -} - // ConditionContext: The IAM conditions context. type ConditionContext struct { // AccessTime: The hypothetical access timestamp to evaluate IAM conditions. @@ -3975,7 +3971,7 @@ type Item struct { // Type: The specific type of inventory, correlating to its specific details. // // Possible values: - // "TYPE_UNSPECIFIED" - Invalid. An type must be specified. + // "TYPE_UNSPECIFIED" - Invalid. A type must be specified. // "INSTALLED_PACKAGE" - This represents a package that is installed on the // VM. // "AVAILABLE_PACKAGE" - This represents an update that is available for a @@ -5066,10 +5062,10 @@ type ResourceSearchResult struct { // in order to get the enrichment: * enrichments.resource_owners The // corresponding required permissions: * // cloudasset.assets.searchEnrichmentResourceOwners Example query to get - // resource owner enrichment: scope: "projects/my-project" query: "name: + // resource owner enrichment: ``` scope: "projects/my-project" query: "name: // my-project" assetTypes: "cloudresourcemanager.googleapis.com/Project" // readMask: { paths: "asset_type" paths: "name" paths: - // "enrichments.resource_owners" } + // "enrichments.resource_owners" } ``` Enrichments []*AssetEnrichment `json:"enrichments,omitempty"` // Folders: The folder(s) that this resource belongs to, in the form of // folders/{FOLDER_NUMBER}. This field is available when the resource belongs @@ -6736,213 +6732,6 @@ func (c *FeedsPatchCall) Do(opts ...googleapi.CallOption) (*Feed, error) { return ret, nil } -type OperationsCancelCall 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 *OperationsService) Cancel(name string, canceloperationrequest *CancelOperationRequest) *OperationsCancelCall { - c := &OperationsCancelCall{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 *OperationsCancelCall) Fields(s ...googleapi.Field) *OperationsCancelCall { - c.urlParams_.Set("fields", googleapi.CombineFields(s)) - return c -} - -// Context sets the context to be used in this call's Do method. -func (c *OperationsCancelCall) Context(ctx context.Context) *OperationsCancelCall { - 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 *OperationsCancelCall) Header() http.Header { - if c.header_ == nil { - c.header_ = make(http.Header) - } - return c.header_ -} - -func (c *OperationsCancelCall) 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 "cloudasset.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 *OperationsCancelCall) 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 OperationsDeleteCall 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 *OperationsService) Delete(name string) *OperationsDeleteCall { - c := &OperationsDeleteCall{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 *OperationsDeleteCall) Fields(s ...googleapi.Field) *OperationsDeleteCall { - c.urlParams_.Set("fields", googleapi.CombineFields(s)) - return c -} - -// Context sets the context to be used in this call's Do method. -func (c *OperationsDeleteCall) Context(ctx context.Context) *OperationsDeleteCall { - 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 *OperationsDeleteCall) Header() http.Header { - if c.header_ == nil { - c.header_ = make(http.Header) - } - return c.header_ -} - -func (c *OperationsDeleteCall) 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 "cloudasset.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 *OperationsDeleteCall) 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 OperationsGetCall struct { s *Service name string diff --git a/cloudbuild/v1/cloudbuild-api.json b/cloudbuild/v1/cloudbuild-api.json index 6b7c178a459..5389af39cdd 100644 --- a/cloudbuild/v1/cloudbuild-api.json +++ b/cloudbuild/v1/cloudbuild-api.json @@ -2346,7 +2346,7 @@ } } }, - "revision": "20240704", + "revision": "20240903", "rootUrl": "https://cloudbuild.googleapis.com/", "schemas": { "ApprovalConfig": { @@ -3428,7 +3428,7 @@ "type": "string" }, "serviceAccount": { - "description": "The service account used for all user-controlled operations including UpdateBuildTrigger, RunBuildTrigger, CreateBuild, and CancelBuild. If no service account is set, then the standard Cloud Build service account ([PROJECT_NUM]@system.gserviceaccount.com) will be used instead. Format: `projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT_ID_OR_EMAIL}`", + "description": "The service account used for all user-controlled operations including UpdateBuildTrigger, RunBuildTrigger, CreateBuild, and CancelBuild. If no service account is set and the legacy Cloud Build service account ([PROJECT_NUM]@cloudbuild.gserviceaccount.com) is the default for the project then it will be used instead. Format: `projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT_ID_OR_EMAIL}`", "type": "string" }, "sourceToBuild": { diff --git a/cloudbuild/v1/cloudbuild-gen.go b/cloudbuild/v1/cloudbuild-gen.go index 7d6a33bc21e..aa0377d0846 100644 --- a/cloudbuild/v1/cloudbuild-gen.go +++ b/cloudbuild/v1/cloudbuild-gen.go @@ -1510,8 +1510,9 @@ type BuildTrigger struct { ResourceName string `json:"resourceName,omitempty"` // ServiceAccount: The service account used for all user-controlled operations // including UpdateBuildTrigger, RunBuildTrigger, CreateBuild, and CancelBuild. - // If no service account is set, then the standard Cloud Build service account - // ([PROJECT_NUM]@system.gserviceaccount.com) will be used instead. Format: + // If no service account is set and the legacy Cloud Build service account + // ([PROJECT_NUM]@cloudbuild.gserviceaccount.com) is the default for the + // project then it will be used instead. Format: // `projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT_ID_OR_EMAIL}` ServiceAccount string `json:"serviceAccount,omitempty"` // SourceToBuild: The repo and ref of the repository from which to build. This diff --git a/cloudidentity/v1/cloudidentity-api.json b/cloudidentity/v1/cloudidentity-api.json index 02a214120c3..3f0685c5a4c 100644 --- a/cloudidentity/v1/cloudidentity-api.json +++ b/cloudidentity/v1/cloudidentity-api.json @@ -1990,7 +1990,7 @@ } } }, - "revision": "20240820", + "revision": "20240902", "rootUrl": "https://cloudidentity.googleapis.com/", "schemas": { "AddIdpCredentialOperationMetadata": { @@ -3732,6 +3732,7 @@ "SERVICE_ACCOUNT", "GROUP", "SHARED_DRIVE", + "CBCM_BROWSER", "OTHER" ], "enumDescriptions": [ @@ -3740,6 +3741,7 @@ "Represents service account type.", "Represents group type.", "Represents Shared drive.", + "Represents a CBCM-managed Chrome Browser type.", "Represents other type." ], "readOnly": true, diff --git a/cloudidentity/v1/cloudidentity-gen.go b/cloudidentity/v1/cloudidentity-gen.go index 1116a904dbe..c00222d0dda 100644 --- a/cloudidentity/v1/cloudidentity-gen.go +++ b/cloudidentity/v1/cloudidentity-gen.go @@ -2404,6 +2404,7 @@ type Membership struct { // "SERVICE_ACCOUNT" - Represents service account type. // "GROUP" - Represents group type. // "SHARED_DRIVE" - Represents Shared drive. + // "CBCM_BROWSER" - Represents a CBCM-managed Chrome Browser type. // "OTHER" - Represents other type. Type string `json:"type,omitempty"` // UpdateTime: Output only. The time when the `Membership` was last updated. diff --git a/cloudidentity/v1beta1/cloudidentity-api.json b/cloudidentity/v1beta1/cloudidentity-api.json index cf90398fc28..193b43737d6 100644 --- a/cloudidentity/v1beta1/cloudidentity-api.json +++ b/cloudidentity/v1beta1/cloudidentity-api.json @@ -2015,7 +2015,7 @@ } } }, - "revision": "20240611", + "revision": "20240902", "rootUrl": "https://cloudidentity.googleapis.com/", "schemas": { "AddIdpCredentialOperationMetadata": { @@ -4557,6 +4557,7 @@ "SERVICE_ACCOUNT", "GROUP", "SHARED_DRIVE", + "CBCM_BROWSER", "OTHER" ], "enumDescriptions": [ @@ -4565,6 +4566,7 @@ "Represents service account type.", "Represents group type.", "Represents Shared drive.", + "Represents a CBCM-managed Chrome Browser type.", "Represents other type." ], "readOnly": true, diff --git a/cloudidentity/v1beta1/cloudidentity-gen.go b/cloudidentity/v1beta1/cloudidentity-gen.go index 6c1dec19d7d..bd0510aa235 100644 --- a/cloudidentity/v1beta1/cloudidentity-gen.go +++ b/cloudidentity/v1beta1/cloudidentity-gen.go @@ -3126,6 +3126,7 @@ type Membership struct { // "SERVICE_ACCOUNT" - Represents service account type. // "GROUP" - Represents group type. // "SHARED_DRIVE" - Represents Shared drive. + // "CBCM_BROWSER" - Represents a CBCM-managed Chrome Browser type. // "OTHER" - Represents other type. Type string `json:"type,omitempty"` // UpdateTime: Output only. The time when the `Membership` was last updated. diff --git a/cloudkms/v1/cloudkms-api.json b/cloudkms/v1/cloudkms-api.json index e2d4c7fa9c1..4f671d131dc 100644 --- a/cloudkms/v1/cloudkms-api.json +++ b/cloudkms/v1/cloudkms-api.json @@ -78,6 +78,21 @@ "description": "Regional Endpoint", "endpointUrl": "https://cloudkms.us-west4.rep.googleapis.com/", "location": "us-west4" + }, + { + "description": "Regional Endpoint", + "endpointUrl": "https://cloudkms.us-west8.rep.googleapis.com/", + "location": "us-west8" + }, + { + "description": "Regional Endpoint", + "endpointUrl": "https://cloudkms.us-east5.rep.googleapis.com/", + "location": "us-east5" + }, + { + "description": "Regional Endpoint", + "endpointUrl": "https://cloudkms.us-south1.rep.googleapis.com/", + "location": "us-south1" } ], "fullyEncodeReservedExpansion": true, @@ -2112,7 +2127,7 @@ } } }, - "revision": "20240808", + "revision": "20240903", "rootUrl": "https://cloudkms.googleapis.com/", "schemas": { "AsymmetricDecryptRequest": { diff --git a/compute/v0.alpha/compute-api.json b/compute/v0.alpha/compute-api.json index cef2a0b61de..76dd9a4cb4a 100644 --- a/compute/v0.alpha/compute-api.json +++ b/compute/v0.alpha/compute-api.json @@ -26471,6 +26471,110 @@ }, "regionInstanceGroupManagerResizeRequests": { "methods": { + "cancel": { + "description": "Cancels the specified resize request. Cancelled resize request no longer waits for the resources to be provisioned. Cancel is only possible for requests that are in accepted state.", + "flatPath": "projects/{project}/regions/{region}/instanceGroupManagers/{instanceGroupManager}/resizeRequests/{resizeRequest}/cancel", + "httpMethod": "POST", + "id": "compute.regionInstanceGroupManagerResizeRequests.cancel", + "parameterOrder": [ + "project", + "region", + "instanceGroupManager", + "resizeRequest" + ], + "parameters": { + "instanceGroupManager": { + "description": "The name of the managed instance group. Name should conform to RFC1035 or be a resource ID.", + "location": "path", + "required": true, + "type": "string" + }, + "project": { + "description": "Project ID for this request.", + "location": "path", + "pattern": "(?:(?:[-a-z0-9]{1,63}\\.)*(?:[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?):)?(?:[0-9]{1,19}|(?:[a-z0-9](?:[-a-z0-9]{0,61}[a-z0-9])?))", + "required": true, + "type": "string" + }, + "region": { + "description": "The name of the region scoping this request. Name should conform to RFC1035.", + "location": "path", + "required": true, + "type": "string" + }, + "requestId": { + "description": "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. 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" + }, + "resizeRequest": { + "description": "The name of the resize request to cancel. Name should conform to RFC1035 or be a resource ID.", + "location": "path", + "required": true, + "type": "string" + } + }, + "path": "projects/{project}/regions/{region}/instanceGroupManagers/{instanceGroupManager}/resizeRequests/{resizeRequest}/cancel", + "response": { + "$ref": "Operation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform", + "https://www.googleapis.com/auth/compute" + ] + }, + "delete": { + "description": "Deletes the specified, inactive resize request. Requests that are still active cannot be deleted. Deleting request does not delete instances that were provisioned previously.", + "flatPath": "projects/{project}/regions/{region}/instanceGroupManagers/{instanceGroupManager}/resizeRequests/{resizeRequest}", + "httpMethod": "DELETE", + "id": "compute.regionInstanceGroupManagerResizeRequests.delete", + "parameterOrder": [ + "project", + "region", + "instanceGroupManager", + "resizeRequest" + ], + "parameters": { + "instanceGroupManager": { + "description": "The name of the managed instance group. Name should conform to RFC1035 or be a resource ID.", + "location": "path", + "required": true, + "type": "string" + }, + "project": { + "description": "Project ID for this request.", + "location": "path", + "pattern": "(?:(?:[-a-z0-9]{1,63}\\.)*(?:[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?):)?(?:[0-9]{1,19}|(?:[a-z0-9](?:[-a-z0-9]{0,61}[a-z0-9])?))", + "required": true, + "type": "string" + }, + "region": { + "description": "The name of the region scoping this request. Name should conform to RFC1035.", + "location": "path", + "required": true, + "type": "string" + }, + "requestId": { + "description": "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. 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" + }, + "resizeRequest": { + "description": "The name of the resize request to delete. Name should conform to RFC1035 or be a resource ID.", + "location": "path", + "required": true, + "type": "string" + } + }, + "path": "projects/{project}/regions/{region}/instanceGroupManagers/{instanceGroupManager}/resizeRequests/{resizeRequest}", + "response": { + "$ref": "Operation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform", + "https://www.googleapis.com/auth/compute" + ] + }, "get": { "description": "Returns all of the details about the specified resize request.", "flatPath": "projects/{project}/regions/{region}/instanceGroupManagers/{instanceGroupManager}/resizeRequests/{resizeRequest}", @@ -33995,6 +34099,125 @@ } } }, + "reservationBlocks": { + "methods": { + "get": { + "description": "Retrieves information about the specified reservation block.", + "flatPath": "projects/{project}/zones/{zone}/reservations/{reservation}/reservationBlocks/{reservationBlock}", + "httpMethod": "GET", + "id": "compute.reservationBlocks.get", + "parameterOrder": [ + "project", + "zone", + "reservation", + "reservationBlock" + ], + "parameters": { + "project": { + "description": "Project ID for this request.", + "location": "path", + "required": true, + "type": "string" + }, + "reservation": { + "description": "The name of the reservation. Name should conform to RFC1035 or be a resource ID.", + "location": "path", + "required": true, + "type": "string" + }, + "reservationBlock": { + "description": "The name of the reservation block. Name should conform to RFC1035 or be a resource ID.", + "location": "path", + "required": true, + "type": "string" + }, + "zone": { + "description": "Name of the zone for this request. Zone name should conform to RFC1035.", + "location": "path", + "required": true, + "type": "string" + } + }, + "path": "projects/{project}/zones/{zone}/reservations/{reservation}/reservationBlocks/{reservationBlock}", + "response": { + "$ref": "ReservationBlocksGetResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform", + "https://www.googleapis.com/auth/compute", + "https://www.googleapis.com/auth/compute.readonly" + ] + }, + "list": { + "description": "Retrieves a list of reservation blocks under a single reservation.", + "flatPath": "projects/{project}/zones/{zone}/reservations/{reservation}/reservationBlocks", + "httpMethod": "GET", + "id": "compute.reservationBlocks.list", + "parameterOrder": [ + "project", + "zone", + "reservation" + ], + "parameters": { + "filter": { + "description": "A filter expression that filters resources listed in the response. Most Compute resources support two types of filter expressions: expressions that support regular expressions and expressions that follow API improvement proposal AIP-160. These two types of filter expressions cannot be mixed in one request. If you want to use AIP-160, your expression must specify the field name, an operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The operator must be either `=`, `!=`, `\u003e`, `\u003c`, `\u003c=`, `\u003e=` or `:`. For example, if you are filtering Compute Engine instances, you can exclude instances named `example-instance` by specifying `name != example-instance`. The `:*` comparison can be used to test whether a key has been defined. For example, to find all objects with `owner` label use: ``` labels.owner:* ``` You can also filter nested fields. For example, you could specify `scheduling.automaticRestart = false` to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example: ``` (scheduling.automaticRestart = true) (cpuPlatform = \"Intel Skylake\") ``` By default, each expression is an `AND` expression. However, you can include `AND` and `OR` expressions explicitly. For example: ``` (cpuPlatform = \"Intel Skylake\") OR (cpuPlatform = \"Intel Broadwell\") AND (scheduling.automaticRestart = true) ``` If you want to use a regular expression, use the `eq` (equal) or `ne` (not equal) operator against a single un-parenthesized expression with or without quotes or against multiple parenthesized expressions. Examples: `fieldname eq unquoted literal` `fieldname eq 'single quoted literal'` `fieldname eq \"double quoted literal\"` `(fieldname1 eq literal) (fieldname2 ne \"literal\")` The literal value is interpreted as a regular expression using Google RE2 library syntax. The literal value must match the entire field. For example, to filter for instances that do not end with name \"instance\", you would use `name ne .*instance`. You cannot combine constraints on multiple fields using regular expressions.", + "location": "query", + "type": "string" + }, + "maxResults": { + "default": "500", + "description": "The maximum number of results per page that should be returned. If the number of available results is larger than `maxResults`, Compute Engine returns a `nextPageToken` that can be used to get the next page of results in subsequent list requests. Acceptable values are `0` to `500`, inclusive. (Default: `500`)", + "format": "uint32", + "location": "query", + "minimum": "0", + "type": "integer" + }, + "orderBy": { + "description": "Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using `orderBy=\"creationTimestamp desc\"`. This sorts results based on the `creationTimestamp` field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by `name` or `creationTimestamp desc` is supported.", + "location": "query", + "type": "string" + }, + "pageToken": { + "description": "Specifies a page token to use. Set `pageToken` to the `nextPageToken` returned by a previous list request to get the next page of results.", + "location": "query", + "type": "string" + }, + "project": { + "description": "Project ID for this request.", + "location": "path", + "required": true, + "type": "string" + }, + "reservation": { + "description": "The name of the reservation. Name should conform to RFC1035 or be a resource ID.", + "location": "path", + "required": true, + "type": "string" + }, + "returnPartialSuccess": { + "description": "Opt-in for partial success behavior which provides partial results in case of failure. The default value is false. For example, when partial success behavior is enabled, aggregatedList for a single zone scope either returns all resources in the zone or no resources, with an error code.", + "location": "query", + "type": "boolean" + }, + "zone": { + "description": "Name of the zone for this request. Zone name should conform to RFC1035.", + "location": "path", + "required": true, + "type": "string" + } + }, + "path": "projects/{project}/zones/{zone}/reservations/{reservation}/reservationBlocks", + "response": { + "$ref": "ReservationBlocksListResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform", + "https://www.googleapis.com/auth/compute", + "https://www.googleapis.com/auth/compute.readonly" + ] + } + } + }, "reservations": { "methods": { "aggregatedList": { @@ -45055,7 +45278,7 @@ } } }, - "revision": "20240820", + "revision": "20240827", "rootUrl": "https://compute.googleapis.com/", "schemas": { "AWSV4Signature": { @@ -46471,6 +46694,11 @@ "description": "[Output Only] Contains output only fields.", "id": "AllocationResourceStatus", "properties": { + "reservationBlockCount": { + "description": "Indicates number of blocks for accelerator optimized family (applicable beyond A3 only).", + "format": "int32", + "type": "integer" + }, "specificSkuAllocation": { "$ref": "AllocationResourceStatusSpecificSKUAllocation", "description": "Allocation Properties of this reservation." @@ -81920,6 +82148,20 @@ "description": "Absolute time in future when the reservation will be auto-deleted by Compute Engine. Timestamp is represented in RFC3339 text format.", "type": "string" }, + "deploymentType": { + "description": "Specifies the deployment strategy for this reservation.", + "enum": [ + "DENSE", + "DEPLOYMENT_TYPE_UNSPECIFIED", + "FLEXIBLE" + ], + "enumDescriptions": [ + "Number of deployment blocks, size, and topology is fixed during creation and does not change over time. Deployment will be expressed in terms of blocks.", + "Deployment type is unspecified.", + "Distribution of capacity in blocks is not static and can change over time. This is expected to have more obtainability over DENSE deployment. Deployment will not be expressed in terms of blocks." + ], + "type": "string" + }, "description": { "description": "An optional description of this resource. Provide this property when you create the resource.", "type": "string" @@ -81929,6 +82171,20 @@ "format": "uint64", "type": "string" }, + "instanceTerminationAction": { + "description": "Instance termination action that will be invoked when the reservation is deleted.", + "enum": [ + "DELETE", + "INSTANCE_TERMINATION_ACTION_UNSPECIFIED", + "STOP" + ], + "enumDescriptions": [ + "Delete the VM.", + "Default value. This value is unused.", + "Stop the VM without storing in-memory content. default action." + ], + "type": "string" + }, "kind": { "default": "compute#reservation", "description": "[Output Only] Type of the resource. Always compute#reservations for reservations.", @@ -82206,6 +82462,233 @@ }, "type": "object" }, + "ReservationBlock": { + "description": "Represents a reservation block resource.", + "id": "ReservationBlock", + "properties": { + "count": { + "description": "[Output Only] Specifies the number of resources that are allocated in this block. It indicates the maximum number of VMs that a user can run on this particular block.", + "format": "int32", + "type": "integer" + }, + "creationTimestamp": { + "description": "[Output Only] Creation timestamp in RFC3339 text format.", + "type": "string" + }, + "id": { + "description": "[Output Only] The unique identifier for the resource. This identifier is defined by the server.", + "format": "uint64", + "type": "string" + }, + "inUseCount": { + "description": "[Output Only] Indicates how many instances are in use on this block.", + "format": "int32", + "type": "integer" + }, + "kind": { + "description": "[Output Only] Type of the resource. Always compute#reservationBlock for reservation blocks.", + "type": "string" + }, + "locationPrefix": { + "description": "[Output Only] Obfuscated location where this reservation block physically resides in format /CCCC/GGGG. This matches the tripod specified in the VM topology information. Example: /USEAB1/0101/ is the location prefix in /USEAB1/0101/031/003", + "type": "string" + }, + "name": { + "description": "[Output Only] The name of this reservation block generated by Google Compute Engine. The name must be 1-63 characters long, and comply with RFC1035 @pattern [a-z](?:[-a-z0-9]{0,61}[a-z0-9])?", + "type": "string" + }, + "selfLink": { + "description": "[Output Only] Server-defined fully-qualified URL for this resource.", + "type": "string" + }, + "selfLinkWithId": { + "description": "[Output Only] Server-defined URL for this resource with the resource id.", + "type": "string" + }, + "status": { + "description": "[Output Only] Status of the reservation block.", + "enum": [ + "CREATING", + "DELETING", + "INVALID", + "READY" + ], + "enumDescriptions": [ + "Resources are being allocated for the reservation block.", + "Reservation block is currently being deleted.", + "", + "Reservation block has allocated all its resources." + ], + "type": "string" + }, + "zone": { + "description": "[Output Only] Zone in which the reservation block resides.", + "type": "string" + } + }, + "type": "object" + }, + "ReservationBlocksGetResponse": { + "id": "ReservationBlocksGetResponse", + "properties": { + "resource": { + "$ref": "ReservationBlock" + } + }, + "type": "object" + }, + "ReservationBlocksListResponse": { + "description": "A list of reservation blocks under a single reservation.", + "id": "ReservationBlocksListResponse", + "properties": { + "id": { + "description": "Unique identifier for the resource; defined by the server.", + "type": "string" + }, + "items": { + "description": "A list of reservation block resources.", + "items": { + "$ref": "ReservationBlock" + }, + "type": "array" + }, + "kind": { + "default": "compute#reservationBlock", + "description": "Type of the resource. Always compute#reservationBlock for a list of reservation blocks.", + "type": "string" + }, + "nextPageToken": { + "description": "This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results.", + "type": "string" + }, + "selfLink": { + "description": "Server-defined URL for this resource.", + "type": "string" + }, + "warning": { + "description": "Informational warning message.", + "properties": { + "code": { + "description": "[Output Only] A warning code, if applicable. For example, Compute Engine returns NO_RESULTS_ON_PAGE if there are no results in the response.", + "enum": [ + "CLEANUP_FAILED", + "DEPRECATED_RESOURCE_USED", + "DEPRECATED_TYPE_USED", + "DISK_SIZE_LARGER_THAN_IMAGE_SIZE", + "EXPERIMENTAL_TYPE_USED", + "EXTERNAL_API_WARNING", + "FIELD_VALUE_OVERRIDEN", + "INJECTED_KERNELS_DEPRECATED", + "INVALID_HEALTH_CHECK_FOR_DYNAMIC_WIEGHTED_LB", + "LARGE_DEPLOYMENT_WARNING", + "LIST_OVERHEAD_QUOTA_EXCEED", + "MISSING_TYPE_DEPENDENCY", + "NEXT_HOP_ADDRESS_NOT_ASSIGNED", + "NEXT_HOP_CANNOT_IP_FORWARD", + "NEXT_HOP_INSTANCE_HAS_NO_IPV6_INTERFACE", + "NEXT_HOP_INSTANCE_NOT_FOUND", + "NEXT_HOP_INSTANCE_NOT_ON_NETWORK", + "NEXT_HOP_NOT_RUNNING", + "NOT_CRITICAL_ERROR", + "NO_RESULTS_ON_PAGE", + "PARTIAL_SUCCESS", + "REQUIRED_TOS_AGREEMENT", + "RESOURCE_IN_USE_BY_OTHER_RESOURCE_WARNING", + "RESOURCE_NOT_DELETED", + "SCHEMA_VALIDATION_IGNORED", + "SINGLE_INSTANCE_PROPERTY_TEMPLATE", + "UNDECLARED_PROPERTIES", + "UNREACHABLE" + ], + "enumDeprecated": [ + false, + false, + false, + false, + false, + false, + true, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false + ], + "enumDescriptions": [ + "Warning about failed cleanup of transient changes made by a failed operation.", + "A link to a deprecated resource was created.", + "When deploying and at least one of the resources has a type marked as deprecated", + "The user created a boot disk that is larger than image size.", + "When deploying and at least one of the resources has a type marked as experimental", + "Warning that is present in an external api call", + "Warning that value of a field has been overridden. Deprecated unused field.", + "The operation involved use of an injected kernel, which is deprecated.", + "A WEIGHTED_MAGLEV backend service is associated with a health check that is not of type HTTP/HTTPS/HTTP2.", + "When deploying a deployment with a exceedingly large number of resources", + "Resource can't be retrieved due to list overhead quota exceed which captures the amount of resources filtered out by user-defined list filter.", + "A resource depends on a missing type", + "The route's nextHopIp address is not assigned to an instance on the network.", + "The route's next hop instance cannot ip forward.", + "The route's nextHopInstance URL refers to an instance that does not have an ipv6 interface on the same network as the route.", + "The route's nextHopInstance URL refers to an instance that does not exist.", + "The route's nextHopInstance URL refers to an instance that is not on the same network as the route.", + "The route's next hop instance does not have a status of RUNNING.", + "Error which is not critical. We decided to continue the process despite the mentioned error.", + "No results are present on a particular list page.", + "Success is reported, but some results may be missing due to errors", + "The user attempted to use a resource that requires a TOS they have not accepted.", + "Warning that a resource is in use.", + "One or more of the resources set to auto-delete could not be deleted because they were in use.", + "When a resource schema validation is ignored.", + "Instance template used in instance group manager is valid as such, but its application does not make a lot of sense, because it allows only single instance in instance group.", + "When undeclared properties in the schema are present", + "A given scope cannot be reached." + ], + "type": "string" + }, + "data": { + "description": "[Output Only] Metadata about this warning in key: value format. For example: \"data\": [ { \"key\": \"scope\", \"value\": \"zones/us-east1-d\" } ", + "items": { + "properties": { + "key": { + "description": "[Output Only] A key that provides more detail on the warning being returned. For example, for warnings where there are no results in a list request for a particular zone, this key might be scope and the key value might be the zone name. Other examples might be a key indicating a deprecated resource and a suggested replacement, or a warning about invalid network settings (for example, if an instance attempts to perform IP forwarding but is not enabled for IP forwarding).", + "type": "string" + }, + "value": { + "description": "[Output Only] A warning data value corresponding to the key.", + "type": "string" + } + }, + "type": "object" + }, + "type": "array" + }, + "message": { + "description": "[Output Only] A human-readable description of the warning code.", + "type": "string" + } + }, + "type": "object" + } + }, + "type": "object" + }, "ReservationList": { "id": "ReservationList", "properties": { @@ -87109,7 +87592,8 @@ "type": "array" }, "cloudArmorConfig": { - "$ref": "SecurityPolicyCloudArmorConfig" + "$ref": "SecurityPolicyCloudArmorConfig", + "deprecated": true }, "creationTimestamp": { "description": "[Output Only] Creation timestamp in RFC3339 text format.", @@ -87123,6 +87607,7 @@ "type": "string" }, "displayName": { + "deprecated": true, "description": "User-provided name of the organization security policy. The name should be unique in the organization in which the security policy is created. This should only be used when SecurityPolicyType is FIREWALL. The name must be 1-63 characters long, and comply with https://www.ietf.org/rfc/rfc1035.txt. Specifically, the name must be 1-63 characters long and match the regular expression `[a-z]([-a-z0-9]*[a-z0-9])?` which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash.", "pattern": "[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?", "type": "string" @@ -87171,6 +87656,7 @@ "type": "string" }, "ruleTupleCount": { + "deprecated": true, "description": "[Output Only] Total count of all security policy rule tuples. A security policy can not exceed a set number of tuples.", "format": "int32", "type": "integer" @@ -87427,6 +87913,7 @@ "type": "string" }, "displayName": { + "deprecated": true, "description": "[Output Only] The display name of the security policy of the association.", "type": "string" }, @@ -87464,6 +87951,7 @@ "id": "SecurityPolicyCloudArmorConfig", "properties": { "enableMl": { + "deprecated": true, "description": "If set to true, enables Cloud Armor Machine Learning.", "type": "boolean" } @@ -87678,6 +88166,7 @@ "type": "string" }, "direction": { + "deprecated": true, "description": "The direction in which this rule applies. This field may only be specified when versioned_expr is set to FIREWALL.", "enum": [ "EGRESS", @@ -87690,6 +88179,7 @@ "type": "string" }, "enableLogging": { + "deprecated": true, "description": "Denotes whether to enable logging for a particular rule. If logging is enabled, logs will be exported to the configured export destination in Stackdriver. Logs may be exported to BigQuery or Pub/Sub. Note: you cannot enable logging on \"goto_next\" rules. This field may only be specified when the versioned_expr is set to FIREWALL.", "type": "boolean" }, @@ -87756,11 +88246,13 @@ "type": "string" }, "ruleTupleCount": { + "deprecated": true, "description": "[Output Only] Calculation of the complexity of a single firewall security policy rule.", "format": "int32", "type": "integer" }, "targetResources": { + "deprecated": true, "description": "A list of network resource URLs to which this rule applies. This field allows you to control which network's VMs get this rule. If this field is left blank, all VMs within the organization will receive the rule. This field may only be specified when versioned_expr is set to FIREWALL.", "items": { "type": "string" @@ -87768,6 +88260,7 @@ "type": "array" }, "targetServiceAccounts": { + "deprecated": true, "description": "A list of service accounts indicating the sets of instances that are applied with this rule.", "items": { "type": "string" @@ -87839,6 +88332,7 @@ "id": "SecurityPolicyRuleMatcherConfig", "properties": { "destIpRanges": { + "deprecated": true, "description": "CIDR IP address range. This field may only be specified when versioned_expr is set to FIREWALL.", "items": { "type": "string" @@ -87846,6 +88340,7 @@ "type": "array" }, "destPorts": { + "deprecated": true, "description": "Pairs of IP protocols and ports that the rule should match. This field may only be specified when versioned_expr is set to FIREWALL.", "items": { "$ref": "SecurityPolicyRuleMatcherConfigDestinationPort" @@ -87853,6 +88348,7 @@ "type": "array" }, "layer4Configs": { + "deprecated": true, "description": "Pairs of IP protocols and ports that the rule should match. This field may only be specified when versioned_expr is set to FIREWALL.", "items": { "$ref": "SecurityPolicyRuleMatcherConfigLayer4Config" @@ -87873,10 +88369,12 @@ "id": "SecurityPolicyRuleMatcherConfigDestinationPort", "properties": { "ipProtocol": { + "deprecated": true, "description": "The IP protocol to which this rule applies. The protocol type is required when creating a firewall rule. This value can either be one of the following well known protocol strings (tcp, udp, icmp, esp, ah, ipip, sctp), or the IP protocol number.", "type": "string" }, "ports": { + "deprecated": true, "description": "An optional list of ports to which this rule applies. This field is only applicable for UDP or TCP protocol. Each entry must be either an integer or a range. If not specified, this rule applies to connections through any port. Example inputs include: [\"22\"], [\"80\",\"443\"], and [\"12345-12349\"]. This field may only be specified when versioned_expr is set to FIREWALL.", "items": { "type": "string" @@ -87890,10 +88388,12 @@ "id": "SecurityPolicyRuleMatcherConfigLayer4Config", "properties": { "ipProtocol": { + "deprecated": true, "description": "The IP protocol to which this rule applies. The protocol type is required when creating a firewall rule. This value can either be one of the following well known protocol strings (tcp, udp, icmp, esp, ah, ipip, sctp), or the IP protocol number.", "type": "string" }, "ports": { + "deprecated": true, "description": "An optional list of ports to which this rule applies. This field is only applicable for UDP or TCP protocol. Each entry must be either an integer or a range. If not specified, this rule applies to connections through any port. Example inputs include: [\"22\"], [\"80\",\"443\"], and [\"12345-12349\"]. This field may only be specified when versioned_expr is set to FIREWALL.", "items": { "type": "string" diff --git a/compute/v0.alpha/compute-gen.go b/compute/v0.alpha/compute-gen.go index ff1784c3d20..e1187135b77 100644 --- a/compute/v0.alpha/compute-gen.go +++ b/compute/v0.alpha/compute-gen.go @@ -246,6 +246,7 @@ func New(client *http.Client) (*Service, error) { s.RegionUrlMaps = NewRegionUrlMapsService(s) s.RegionZones = NewRegionZonesService(s) s.Regions = NewRegionsService(s) + s.ReservationBlocks = NewReservationBlocksService(s) s.Reservations = NewReservationsService(s) s.ResourcePolicies = NewResourcePoliciesService(s) s.Routers = NewRoutersService(s) @@ -449,6 +450,8 @@ type Service struct { Regions *RegionsService + ReservationBlocks *ReservationBlocksService + Reservations *ReservationsService ResourcePolicies *ResourcePoliciesService @@ -1267,6 +1270,15 @@ type RegionsService struct { s *Service } +func NewReservationBlocksService(s *Service) *ReservationBlocksService { + rs := &ReservationBlocksService{s: s} + return rs +} + +type ReservationBlocksService struct { + s *Service +} + func NewReservationsService(s *Service) *ReservationsService { rs := &ReservationsService{s: s} return rs @@ -3006,15 +3018,18 @@ func (s AllocationReservationSharingPolicy) MarshalJSON() ([]byte, error) { // AllocationResourceStatus: [Output Only] Contains output only fields. type AllocationResourceStatus struct { + // ReservationBlockCount: Indicates number of blocks for accelerator optimized + // family (applicable beyond A3 only). + ReservationBlockCount int64 `json:"reservationBlockCount,omitempty"` // SpecificSkuAllocation: Allocation Properties of this reservation. SpecificSkuAllocation *AllocationResourceStatusSpecificSKUAllocation `json:"specificSkuAllocation,omitempty"` - // ForceSendFields is a list of field names (e.g. "SpecificSkuAllocation") to + // ForceSendFields is a list of field names (e.g. "ReservationBlockCount") 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. "SpecificSkuAllocation") to + // NullFields is a list of field names (e.g. "ReservationBlockCount") 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. @@ -43065,12 +43080,32 @@ type Reservation struct { // auto-deleted by Compute Engine. Timestamp is represented in RFC3339 text // format. DeleteAtTime string `json:"deleteAtTime,omitempty"` + // DeploymentType: Specifies the deployment strategy for this reservation. + // + // Possible values: + // "DENSE" - Number of deployment blocks, size, and topology is fixed during + // creation and does not change over time. Deployment will be expressed in + // terms of blocks. + // "DEPLOYMENT_TYPE_UNSPECIFIED" - Deployment type is unspecified. + // "FLEXIBLE" - Distribution of capacity in blocks is not static and can + // change over time. This is expected to have more obtainability over DENSE + // deployment. Deployment will not be expressed in terms of blocks. + DeploymentType string `json:"deploymentType,omitempty"` // Description: An optional description of this resource. Provide this property // when you create the resource. Description string `json:"description,omitempty"` // Id: [Output Only] The unique identifier for the resource. This identifier is // defined by the server. Id uint64 `json:"id,omitempty,string"` + // InstanceTerminationAction: Instance termination action that will be invoked + // when the reservation is deleted. + // + // Possible values: + // "DELETE" - Delete the VM. + // "INSTANCE_TERMINATION_ACTION_UNSPECIFIED" - Default value. This value is + // unused. + // "STOP" - Stop the VM without storing in-memory content. default action. + InstanceTerminationAction string `json:"instanceTerminationAction,omitempty"` // Kind: [Output Only] Type of the resource. Always compute#reservations for // reservations. Kind string `json:"kind,omitempty"` @@ -43351,6 +43386,244 @@ func (s ReservationAggregatedListWarningData) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// ReservationBlock: Represents a reservation block resource. +type ReservationBlock struct { + // Count: [Output Only] Specifies the number of resources that are allocated in + // this block. It indicates the maximum number of VMs that a user can run on + // this particular block. + Count int64 `json:"count,omitempty"` + // CreationTimestamp: [Output Only] Creation timestamp in RFC3339 text format. + CreationTimestamp string `json:"creationTimestamp,omitempty"` + // Id: [Output Only] The unique identifier for the resource. This identifier is + // defined by the server. + Id uint64 `json:"id,omitempty,string"` + // InUseCount: [Output Only] Indicates how many instances are in use on this + // block. + InUseCount int64 `json:"inUseCount,omitempty"` + // Kind: [Output Only] Type of the resource. Always compute#reservationBlock + // for reservation blocks. + Kind string `json:"kind,omitempty"` + // LocationPrefix: [Output Only] Obfuscated location where this reservation + // block physically resides in format /CCCC/GGGG. This matches the tripod + // specified in the VM topology information. Example: /USEAB1/0101/ is the + // location prefix in /USEAB1/0101/031/003 + LocationPrefix string `json:"locationPrefix,omitempty"` + // Name: [Output Only] The name of this reservation block generated by Google + // Compute Engine. The name must be 1-63 characters long, and comply with + // RFC1035 @pattern a-z (?:[-a-z0-9]{0,61}[a-z0-9])? + Name string `json:"name,omitempty"` + // SelfLink: [Output Only] Server-defined fully-qualified URL for this + // resource. + SelfLink string `json:"selfLink,omitempty"` + // SelfLinkWithId: [Output Only] Server-defined URL for this resource with the + // resource id. + SelfLinkWithId string `json:"selfLinkWithId,omitempty"` + // Status: [Output Only] Status of the reservation block. + // + // Possible values: + // "CREATING" - Resources are being allocated for the reservation block. + // "DELETING" - Reservation block is currently being deleted. + // "INVALID" + // "READY" - Reservation block has allocated all its resources. + Status string `json:"status,omitempty"` + // Zone: [Output Only] Zone in which the reservation block resides. + Zone string `json:"zone,omitempty"` + // ForceSendFields is a list of field names (e.g. "Count") 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. "Count") 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 ReservationBlock) MarshalJSON() ([]byte, error) { + type NoMethod ReservationBlock + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +type ReservationBlocksGetResponse struct { + Resource *ReservationBlock `json:"resource,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the server. + googleapi.ServerResponse `json:"-"` + // ForceSendFields is a list of field names (e.g. "Resource") 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. "Resource") 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 ReservationBlocksGetResponse) MarshalJSON() ([]byte, error) { + type NoMethod ReservationBlocksGetResponse + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// ReservationBlocksListResponse: A list of reservation blocks under a single +// reservation. +type ReservationBlocksListResponse struct { + // Id: Unique identifier for the resource; defined by the server. + Id string `json:"id,omitempty"` + // Items: A list of reservation block resources. + Items []*ReservationBlock `json:"items,omitempty"` + // Kind: Type of the resource. Always compute#reservationBlock for a list of + // reservation blocks. + Kind string `json:"kind,omitempty"` + // NextPageToken: This token allows you to get the next page of results for + // list requests. If the number of results is larger than maxResults, use the + // nextPageToken as a value for the query parameter pageToken in the next list + // request. Subsequent list requests will have their own nextPageToken to + // continue paging through the results. + NextPageToken string `json:"nextPageToken,omitempty"` + // SelfLink: Server-defined URL for this resource. + SelfLink string `json:"selfLink,omitempty"` + // Warning: Informational warning message. + Warning *ReservationBlocksListResponseWarning `json:"warning,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the server. + googleapi.ServerResponse `json:"-"` + // 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 ReservationBlocksListResponse) MarshalJSON() ([]byte, error) { + type NoMethod ReservationBlocksListResponse + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// ReservationBlocksListResponseWarning: Informational warning message. +type ReservationBlocksListResponseWarning struct { + // Code: [Output Only] A warning code, if applicable. For example, Compute + // Engine returns NO_RESULTS_ON_PAGE if there are no results in the response. + // + // Possible values: + // "CLEANUP_FAILED" - Warning about failed cleanup of transient changes made + // by a failed operation. + // "DEPRECATED_RESOURCE_USED" - A link to a deprecated resource was created. + // "DEPRECATED_TYPE_USED" - When deploying and at least one of the resources + // has a type marked as deprecated + // "DISK_SIZE_LARGER_THAN_IMAGE_SIZE" - The user created a boot disk that is + // larger than image size. + // "EXPERIMENTAL_TYPE_USED" - When deploying and at least one of the + // resources has a type marked as experimental + // "EXTERNAL_API_WARNING" - Warning that is present in an external api call + // "FIELD_VALUE_OVERRIDEN" - Warning that value of a field has been + // overridden. Deprecated unused field. + // "INJECTED_KERNELS_DEPRECATED" - The operation involved use of an injected + // kernel, which is deprecated. + // "INVALID_HEALTH_CHECK_FOR_DYNAMIC_WIEGHTED_LB" - A WEIGHTED_MAGLEV backend + // service is associated with a health check that is not of type + // HTTP/HTTPS/HTTP2. + // "LARGE_DEPLOYMENT_WARNING" - When deploying a deployment with a + // exceedingly large number of resources + // "LIST_OVERHEAD_QUOTA_EXCEED" - Resource can't be retrieved due to list + // overhead quota exceed which captures the amount of resources filtered out by + // user-defined list filter. + // "MISSING_TYPE_DEPENDENCY" - A resource depends on a missing type + // "NEXT_HOP_ADDRESS_NOT_ASSIGNED" - The route's nextHopIp address is not + // assigned to an instance on the network. + // "NEXT_HOP_CANNOT_IP_FORWARD" - The route's next hop instance cannot ip + // forward. + // "NEXT_HOP_INSTANCE_HAS_NO_IPV6_INTERFACE" - The route's nextHopInstance + // URL refers to an instance that does not have an ipv6 interface on the same + // network as the route. + // "NEXT_HOP_INSTANCE_NOT_FOUND" - The route's nextHopInstance URL refers to + // an instance that does not exist. + // "NEXT_HOP_INSTANCE_NOT_ON_NETWORK" - The route's nextHopInstance URL + // refers to an instance that is not on the same network as the route. + // "NEXT_HOP_NOT_RUNNING" - The route's next hop instance does not have a + // status of RUNNING. + // "NOT_CRITICAL_ERROR" - Error which is not critical. We decided to continue + // the process despite the mentioned error. + // "NO_RESULTS_ON_PAGE" - No results are present on a particular list page. + // "PARTIAL_SUCCESS" - Success is reported, but some results may be missing + // due to errors + // "REQUIRED_TOS_AGREEMENT" - The user attempted to use a resource that + // requires a TOS they have not accepted. + // "RESOURCE_IN_USE_BY_OTHER_RESOURCE_WARNING" - Warning that a resource is + // in use. + // "RESOURCE_NOT_DELETED" - One or more of the resources set to auto-delete + // could not be deleted because they were in use. + // "SCHEMA_VALIDATION_IGNORED" - When a resource schema validation is + // ignored. + // "SINGLE_INSTANCE_PROPERTY_TEMPLATE" - Instance template used in instance + // group manager is valid as such, but its application does not make a lot of + // sense, because it allows only single instance in instance group. + // "UNDECLARED_PROPERTIES" - When undeclared properties in the schema are + // present + // "UNREACHABLE" - A given scope cannot be reached. + Code string `json:"code,omitempty"` + // Data: [Output Only] Metadata about this warning in key: value format. For + // example: "data": [ { "key": "scope", "value": "zones/us-east1-d" } + Data []*ReservationBlocksListResponseWarningData `json:"data,omitempty"` + // Message: [Output Only] A human-readable description of the warning code. + 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 ReservationBlocksListResponseWarning) MarshalJSON() ([]byte, error) { + type NoMethod ReservationBlocksListResponseWarning + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +type ReservationBlocksListResponseWarningData struct { + // Key: [Output Only] A key that provides more detail on the warning being + // returned. For example, for warnings where there are no results in a list + // request for a particular zone, this key might be scope and the key value + // might be the zone name. Other examples might be a key indicating a + // deprecated resource and a suggested replacement, or a warning about invalid + // network settings (for example, if an instance attempts to perform IP + // forwarding but is not enabled for IP forwarding). + Key string `json:"key,omitempty"` + // Value: [Output Only] A warning data value corresponding to the key. + Value string `json:"value,omitempty"` + // ForceSendFields is a list of field names (e.g. "Key") 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. "Key") 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 ReservationBlocksListResponseWarningData) MarshalJSON() ([]byte, error) { + type NoMethod ReservationBlocksListResponseWarningData + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + type ReservationList struct { // Id: [Output Only] The unique identifier for the resource. This identifier is // defined by the server. diff --git a/compute/v0.alpha/compute2-gen.go b/compute/v0.alpha/compute2-gen.go index 3eb224a579a..49619b2c933 100644 --- a/compute/v0.alpha/compute2-gen.go +++ b/compute/v0.alpha/compute2-gen.go @@ -68988,3 +68988,1619 @@ func (c *RegionAutoscalersUpdateCall) Do(opts ...googleapi.CallOption) (*Operati } return ret, nil } + +type RegionBackendServicesDeleteCall struct { + s *Service + project string + region string + backendService string + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Delete: Deletes the specified regional BackendService resource. +// +// - backendService: Name of the BackendService resource to delete. +// - project: Project ID for this request. +// - region: Name of the region scoping this request. +func (r *RegionBackendServicesService) Delete(project string, region string, backendService string) *RegionBackendServicesDeleteCall { + c := &RegionBackendServicesDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.project = project + c.region = region + c.backendService = backendService + 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. 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 *RegionBackendServicesDeleteCall) RequestId(requestId string) *RegionBackendServicesDeleteCall { + c.urlParams_.Set("requestId", requestId) + 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 *RegionBackendServicesDeleteCall) Fields(s ...googleapi.Field) *RegionBackendServicesDeleteCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *RegionBackendServicesDeleteCall) Context(ctx context.Context) *RegionBackendServicesDeleteCall { + 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 *RegionBackendServicesDeleteCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *RegionBackendServicesDeleteCall) 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, "projects/{project}/regions/{region}/backendServices/{backendService}") + 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{ + "project": c.project, + "region": c.region, + "backendService": c.backendService, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "compute.regionBackendServices.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 *RegionBackendServicesDeleteCall) 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 RegionBackendServicesGetCall struct { + s *Service + project string + region string + backendService string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// Get: Returns the specified regional BackendService resource. +// +// - backendService: Name of the BackendService resource to return. +// - project: Project ID for this request. +// - region: Name of the region scoping this request. +func (r *RegionBackendServicesService) Get(project string, region string, backendService string) *RegionBackendServicesGetCall { + c := &RegionBackendServicesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.project = project + c.region = region + c.backendService = backendService + 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 *RegionBackendServicesGetCall) Fields(s ...googleapi.Field) *RegionBackendServicesGetCall { + 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 *RegionBackendServicesGetCall) IfNoneMatch(entityTag string) *RegionBackendServicesGetCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *RegionBackendServicesGetCall) Context(ctx context.Context) *RegionBackendServicesGetCall { + 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 *RegionBackendServicesGetCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *RegionBackendServicesGetCall) 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, "projects/{project}/regions/{region}/backendServices/{backendService}") + 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{ + "project": c.project, + "region": c.region, + "backendService": c.backendService, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "compute.regionBackendServices.get" call. +// Any non-2xx status code is an error. Response headers are in either +// *BackendService.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 *RegionBackendServicesGetCall) Do(opts ...googleapi.CallOption) (*BackendService, 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 := &BackendService{ + 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 RegionBackendServicesGetHealthCall struct { + s *Service + project string + region string + backendService string + resourcegroupreference *ResourceGroupReference + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// GetHealth: Gets the most recent health check results for this regional +// BackendService. +// +// - backendService: Name of the BackendService resource for which to get +// health. +// - project: . +// - region: Name of the region scoping this request. +func (r *RegionBackendServicesService) GetHealth(project string, region string, backendService string, resourcegroupreference *ResourceGroupReference) *RegionBackendServicesGetHealthCall { + c := &RegionBackendServicesGetHealthCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.project = project + c.region = region + c.backendService = backendService + c.resourcegroupreference = resourcegroupreference + 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 *RegionBackendServicesGetHealthCall) Fields(s ...googleapi.Field) *RegionBackendServicesGetHealthCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *RegionBackendServicesGetHealthCall) Context(ctx context.Context) *RegionBackendServicesGetHealthCall { + 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 *RegionBackendServicesGetHealthCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *RegionBackendServicesGetHealthCall) 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.resourcegroupreference) + if err != nil { + return nil, err + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "projects/{project}/regions/{region}/backendServices/{backendService}/getHealth") + 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{ + "project": c.project, + "region": c.region, + "backendService": c.backendService, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "compute.regionBackendServices.getHealth" call. +// Any non-2xx status code is an error. Response headers are in either +// *BackendServiceGroupHealth.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 *RegionBackendServicesGetHealthCall) Do(opts ...googleapi.CallOption) (*BackendServiceGroupHealth, 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 := &BackendServiceGroupHealth{ + 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 RegionBackendServicesGetIamPolicyCall struct { + s *Service + project string + region string + resource string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// GetIamPolicy: Gets the access control policy for a resource. May be empty if +// no such policy or resource exists. +// +// - project: Project ID for this request. +// - region: The name of the region for this request. +// - resource: Name or id of the resource for this request. +func (r *RegionBackendServicesService) GetIamPolicy(project string, region string, resource string) *RegionBackendServicesGetIamPolicyCall { + c := &RegionBackendServicesGetIamPolicyCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.project = project + c.region = region + c.resource = resource + return c +} + +// OptionsRequestedPolicyVersion sets the optional parameter +// "optionsRequestedPolicyVersion": Requested IAM Policy version. +func (c *RegionBackendServicesGetIamPolicyCall) OptionsRequestedPolicyVersion(optionsRequestedPolicyVersion int64) *RegionBackendServicesGetIamPolicyCall { + c.urlParams_.Set("optionsRequestedPolicyVersion", fmt.Sprint(optionsRequestedPolicyVersion)) + 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 *RegionBackendServicesGetIamPolicyCall) Fields(s ...googleapi.Field) *RegionBackendServicesGetIamPolicyCall { + 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 *RegionBackendServicesGetIamPolicyCall) IfNoneMatch(entityTag string) *RegionBackendServicesGetIamPolicyCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *RegionBackendServicesGetIamPolicyCall) Context(ctx context.Context) *RegionBackendServicesGetIamPolicyCall { + 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 *RegionBackendServicesGetIamPolicyCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *RegionBackendServicesGetIamPolicyCall) 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, "projects/{project}/regions/{region}/backendServices/{resource}/getIamPolicy") + 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{ + "project": c.project, + "region": c.region, + "resource": c.resource, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "compute.regionBackendServices.getIamPolicy" call. +// Any non-2xx status code is an error. Response headers are in either +// *Policy.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 *RegionBackendServicesGetIamPolicyCall) Do(opts ...googleapi.CallOption) (*Policy, 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 := &Policy{ + 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 RegionBackendServicesInsertCall struct { + s *Service + project string + region string + backendservice *BackendService + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Insert: Creates a regional BackendService resource in the specified project +// using the data included in the request. For more information, see Backend +// services overview. +// +// - project: Project ID for this request. +// - region: Name of the region scoping this request. +func (r *RegionBackendServicesService) Insert(project string, region string, backendservice *BackendService) *RegionBackendServicesInsertCall { + c := &RegionBackendServicesInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.project = project + c.region = region + c.backendservice = backendservice + 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. 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 *RegionBackendServicesInsertCall) RequestId(requestId string) *RegionBackendServicesInsertCall { + c.urlParams_.Set("requestId", requestId) + 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 *RegionBackendServicesInsertCall) Fields(s ...googleapi.Field) *RegionBackendServicesInsertCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *RegionBackendServicesInsertCall) Context(ctx context.Context) *RegionBackendServicesInsertCall { + 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 *RegionBackendServicesInsertCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *RegionBackendServicesInsertCall) 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.backendservice) + if err != nil { + return nil, err + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "projects/{project}/regions/{region}/backendServices") + 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{ + "project": c.project, + "region": c.region, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "compute.regionBackendServices.insert" 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 *RegionBackendServicesInsertCall) 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 RegionBackendServicesListCall struct { + s *Service + project string + region string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// List: Retrieves the list of regional BackendService resources available to +// the specified project in the given region. +// +// - project: Project ID for this request. +// - region: Name of the region scoping this request. +func (r *RegionBackendServicesService) List(project string, region string) *RegionBackendServicesListCall { + c := &RegionBackendServicesListCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.project = project + c.region = region + return c +} + +// Filter sets the optional parameter "filter": A filter expression that +// filters resources listed in the response. Most Compute resources support two +// types of filter expressions: expressions that support regular expressions +// and expressions that follow API improvement proposal AIP-160. These two +// types of filter expressions cannot be mixed in one request. If you want to +// use AIP-160, your expression must specify the field name, an operator, and +// the value that you want to use for filtering. The value must be a string, a +// number, or a boolean. The operator must be either `=`, `!=`, `>`, `<`, `<=`, +// `>=` or `:`. For example, if you are filtering Compute Engine instances, you +// can exclude instances named `example-instance` by specifying `name != +// example-instance`. The `:*` comparison can be used to test whether a key has +// been defined. For example, to find all objects with `owner` label use: ``` +// labels.owner:* ``` You can also filter nested fields. For example, you could +// specify `scheduling.automaticRestart = false` to include instances only if +// they are not scheduled for automatic restarts. You can use filtering on +// nested fields to filter based on resource labels. To filter on multiple +// expressions, provide each separate expression within parentheses. For +// example: ``` (scheduling.automaticRestart = true) (cpuPlatform = "Intel +// Skylake") ``` By default, each expression is an `AND` expression. However, +// you can include `AND` and `OR` expressions explicitly. For example: ``` +// (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND +// (scheduling.automaticRestart = true) ``` If you want to use a regular +// expression, use the `eq` (equal) or `ne` (not equal) operator against a +// single un-parenthesized expression with or without quotes or against +// multiple parenthesized expressions. Examples: `fieldname eq unquoted +// literal` `fieldname eq 'single quoted literal'` `fieldname eq "double quoted +// literal" `(fieldname1 eq literal) (fieldname2 ne "literal")` The literal +// value is interpreted as a regular expression using Google RE2 library +// syntax. The literal value must match the entire field. For example, to +// filter for instances that do not end with name "instance", you would use +// `name ne .*instance`. You cannot combine constraints on multiple fields +// using regular expressions. +func (c *RegionBackendServicesListCall) Filter(filter string) *RegionBackendServicesListCall { + c.urlParams_.Set("filter", filter) + return c +} + +// MaxResults sets the optional parameter "maxResults": The maximum number of +// results per page that should be returned. If the number of available results +// is larger than `maxResults`, Compute Engine returns a `nextPageToken` that +// can be used to get the next page of results in subsequent list requests. +// Acceptable values are `0` to `500`, inclusive. (Default: `500`) +func (c *RegionBackendServicesListCall) MaxResults(maxResults int64) *RegionBackendServicesListCall { + c.urlParams_.Set("maxResults", fmt.Sprint(maxResults)) + return c +} + +// OrderBy sets the optional parameter "orderBy": Sorts list results by a +// certain order. By default, results are returned in alphanumerical order +// based on the resource name. You can also sort results in descending order +// based on the creation timestamp using `orderBy="creationTimestamp desc". +// This sorts results based on the `creationTimestamp` field in reverse +// chronological order (newest result first). Use this to sort resources like +// operations so that the newest operation is returned first. Currently, only +// sorting by `name` or `creationTimestamp desc` is supported. +func (c *RegionBackendServicesListCall) OrderBy(orderBy string) *RegionBackendServicesListCall { + c.urlParams_.Set("orderBy", orderBy) + return c +} + +// PageToken sets the optional parameter "pageToken": Specifies a page token to +// use. Set `pageToken` to the `nextPageToken` returned by a previous list +// request to get the next page of results. +func (c *RegionBackendServicesListCall) PageToken(pageToken string) *RegionBackendServicesListCall { + c.urlParams_.Set("pageToken", pageToken) + return c +} + +// ReturnPartialSuccess sets the optional parameter "returnPartialSuccess": +// Opt-in for partial success behavior which provides partial results in case +// of failure. The default value is false. For example, when partial success +// behavior is enabled, aggregatedList for a single zone scope either returns +// all resources in the zone or no resources, with an error code. +func (c *RegionBackendServicesListCall) ReturnPartialSuccess(returnPartialSuccess bool) *RegionBackendServicesListCall { + c.urlParams_.Set("returnPartialSuccess", fmt.Sprint(returnPartialSuccess)) + 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 *RegionBackendServicesListCall) Fields(s ...googleapi.Field) *RegionBackendServicesListCall { + 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 *RegionBackendServicesListCall) IfNoneMatch(entityTag string) *RegionBackendServicesListCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *RegionBackendServicesListCall) Context(ctx context.Context) *RegionBackendServicesListCall { + 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 *RegionBackendServicesListCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *RegionBackendServicesListCall) 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, "projects/{project}/regions/{region}/backendServices") + 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{ + "project": c.project, + "region": c.region, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "compute.regionBackendServices.list" call. +// Any non-2xx status code is an error. Response headers are in either +// *BackendServiceList.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 *RegionBackendServicesListCall) Do(opts ...googleapi.CallOption) (*BackendServiceList, 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 := &BackendServiceList{ + 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 *RegionBackendServicesListCall) Pages(ctx context.Context, f func(*BackendServiceList) 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 RegionBackendServicesListUsableCall struct { + s *Service + project string + region string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// ListUsable: Retrieves an aggregated list of all usable backend services in +// the specified project in the given region. +// +// - project: Project ID for this request. +// - region: Name of the region scoping this request. It must be a string that +// meets the requirements in RFC1035. +func (r *RegionBackendServicesService) ListUsable(project string, region string) *RegionBackendServicesListUsableCall { + c := &RegionBackendServicesListUsableCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.project = project + c.region = region + return c +} + +// Filter sets the optional parameter "filter": A filter expression that +// filters resources listed in the response. Most Compute resources support two +// types of filter expressions: expressions that support regular expressions +// and expressions that follow API improvement proposal AIP-160. These two +// types of filter expressions cannot be mixed in one request. If you want to +// use AIP-160, your expression must specify the field name, an operator, and +// the value that you want to use for filtering. The value must be a string, a +// number, or a boolean. The operator must be either `=`, `!=`, `>`, `<`, `<=`, +// `>=` or `:`. For example, if you are filtering Compute Engine instances, you +// can exclude instances named `example-instance` by specifying `name != +// example-instance`. The `:*` comparison can be used to test whether a key has +// been defined. For example, to find all objects with `owner` label use: ``` +// labels.owner:* ``` You can also filter nested fields. For example, you could +// specify `scheduling.automaticRestart = false` to include instances only if +// they are not scheduled for automatic restarts. You can use filtering on +// nested fields to filter based on resource labels. To filter on multiple +// expressions, provide each separate expression within parentheses. For +// example: ``` (scheduling.automaticRestart = true) (cpuPlatform = "Intel +// Skylake") ``` By default, each expression is an `AND` expression. However, +// you can include `AND` and `OR` expressions explicitly. For example: ``` +// (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND +// (scheduling.automaticRestart = true) ``` If you want to use a regular +// expression, use the `eq` (equal) or `ne` (not equal) operator against a +// single un-parenthesized expression with or without quotes or against +// multiple parenthesized expressions. Examples: `fieldname eq unquoted +// literal` `fieldname eq 'single quoted literal'` `fieldname eq "double quoted +// literal" `(fieldname1 eq literal) (fieldname2 ne "literal")` The literal +// value is interpreted as a regular expression using Google RE2 library +// syntax. The literal value must match the entire field. For example, to +// filter for instances that do not end with name "instance", you would use +// `name ne .*instance`. You cannot combine constraints on multiple fields +// using regular expressions. +func (c *RegionBackendServicesListUsableCall) Filter(filter string) *RegionBackendServicesListUsableCall { + c.urlParams_.Set("filter", filter) + return c +} + +// MaxResults sets the optional parameter "maxResults": The maximum number of +// results per page that should be returned. If the number of available results +// is larger than `maxResults`, Compute Engine returns a `nextPageToken` that +// can be used to get the next page of results in subsequent list requests. +// Acceptable values are `0` to `500`, inclusive. (Default: `500`) +func (c *RegionBackendServicesListUsableCall) MaxResults(maxResults int64) *RegionBackendServicesListUsableCall { + c.urlParams_.Set("maxResults", fmt.Sprint(maxResults)) + return c +} + +// OrderBy sets the optional parameter "orderBy": Sorts list results by a +// certain order. By default, results are returned in alphanumerical order +// based on the resource name. You can also sort results in descending order +// based on the creation timestamp using `orderBy="creationTimestamp desc". +// This sorts results based on the `creationTimestamp` field in reverse +// chronological order (newest result first). Use this to sort resources like +// operations so that the newest operation is returned first. Currently, only +// sorting by `name` or `creationTimestamp desc` is supported. +func (c *RegionBackendServicesListUsableCall) OrderBy(orderBy string) *RegionBackendServicesListUsableCall { + c.urlParams_.Set("orderBy", orderBy) + return c +} + +// PageToken sets the optional parameter "pageToken": Specifies a page token to +// use. Set `pageToken` to the `nextPageToken` returned by a previous list +// request to get the next page of results. +func (c *RegionBackendServicesListUsableCall) PageToken(pageToken string) *RegionBackendServicesListUsableCall { + c.urlParams_.Set("pageToken", pageToken) + return c +} + +// ReturnPartialSuccess sets the optional parameter "returnPartialSuccess": +// Opt-in for partial success behavior which provides partial results in case +// of failure. The default value is false. For example, when partial success +// behavior is enabled, aggregatedList for a single zone scope either returns +// all resources in the zone or no resources, with an error code. +func (c *RegionBackendServicesListUsableCall) ReturnPartialSuccess(returnPartialSuccess bool) *RegionBackendServicesListUsableCall { + c.urlParams_.Set("returnPartialSuccess", fmt.Sprint(returnPartialSuccess)) + 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 *RegionBackendServicesListUsableCall) Fields(s ...googleapi.Field) *RegionBackendServicesListUsableCall { + 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 *RegionBackendServicesListUsableCall) IfNoneMatch(entityTag string) *RegionBackendServicesListUsableCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *RegionBackendServicesListUsableCall) Context(ctx context.Context) *RegionBackendServicesListUsableCall { + 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 *RegionBackendServicesListUsableCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *RegionBackendServicesListUsableCall) 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, "projects/{project}/regions/{region}/backendServices/listUsable") + 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{ + "project": c.project, + "region": c.region, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "compute.regionBackendServices.listUsable" call. +// Any non-2xx status code is an error. Response headers are in either +// *BackendServiceListUsable.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 *RegionBackendServicesListUsableCall) Do(opts ...googleapi.CallOption) (*BackendServiceListUsable, 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 := &BackendServiceListUsable{ + 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 *RegionBackendServicesListUsableCall) Pages(ctx context.Context, f func(*BackendServiceListUsable) 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 RegionBackendServicesPatchCall struct { + s *Service + project string + region string + backendService string + backendservice *BackendService + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Patch: Updates the specified regional BackendService resource with the data +// included in the request. For more information, see Understanding backend +// services This method supports PATCH semantics and uses the JSON merge patch +// format and processing rules. +// +// - backendService: Name of the BackendService resource to patch. +// - project: Project ID for this request. +// - region: Name of the region scoping this request. +func (r *RegionBackendServicesService) Patch(project string, region string, backendService string, backendservice *BackendService) *RegionBackendServicesPatchCall { + c := &RegionBackendServicesPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.project = project + c.region = region + c.backendService = backendService + c.backendservice = backendservice + 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. 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 *RegionBackendServicesPatchCall) RequestId(requestId string) *RegionBackendServicesPatchCall { + c.urlParams_.Set("requestId", requestId) + 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 *RegionBackendServicesPatchCall) Fields(s ...googleapi.Field) *RegionBackendServicesPatchCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *RegionBackendServicesPatchCall) Context(ctx context.Context) *RegionBackendServicesPatchCall { + 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 *RegionBackendServicesPatchCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *RegionBackendServicesPatchCall) 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.backendservice) + if err != nil { + return nil, err + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "projects/{project}/regions/{region}/backendServices/{backendService}") + 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{ + "project": c.project, + "region": c.region, + "backendService": c.backendService, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "compute.regionBackendServices.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 *RegionBackendServicesPatchCall) 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 RegionBackendServicesSetIamPolicyCall struct { + s *Service + project string + region string + resource string + regionsetpolicyrequest *RegionSetPolicyRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// SetIamPolicy: Sets the access control policy on the specified resource. +// Replaces any existing policy. +// +// - project: Project ID for this request. +// - region: The name of the region for this request. +// - resource: Name or id of the resource for this request. +func (r *RegionBackendServicesService) SetIamPolicy(project string, region string, resource string, regionsetpolicyrequest *RegionSetPolicyRequest) *RegionBackendServicesSetIamPolicyCall { + c := &RegionBackendServicesSetIamPolicyCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.project = project + c.region = region + c.resource = resource + c.regionsetpolicyrequest = regionsetpolicyrequest + 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 *RegionBackendServicesSetIamPolicyCall) Fields(s ...googleapi.Field) *RegionBackendServicesSetIamPolicyCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *RegionBackendServicesSetIamPolicyCall) Context(ctx context.Context) *RegionBackendServicesSetIamPolicyCall { + 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 *RegionBackendServicesSetIamPolicyCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *RegionBackendServicesSetIamPolicyCall) 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.regionsetpolicyrequest) + if err != nil { + return nil, err + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "projects/{project}/regions/{region}/backendServices/{resource}/setIamPolicy") + 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{ + "project": c.project, + "region": c.region, + "resource": c.resource, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "compute.regionBackendServices.setIamPolicy" call. +// Any non-2xx status code is an error. Response headers are in either +// *Policy.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 *RegionBackendServicesSetIamPolicyCall) Do(opts ...googleapi.CallOption) (*Policy, 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 := &Policy{ + 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 RegionBackendServicesSetSecurityPolicyCall struct { + s *Service + project string + region string + backendService string + securitypolicyreference *SecurityPolicyReference + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// SetSecurityPolicy: Sets the Google Cloud Armor security policy for the +// specified backend service. For more information, see Google Cloud Armor +// Overview +// +// - backendService: Name of the BackendService resource to which the security +// policy should be set. The name should conform to RFC1035. +// - project: Project ID for this request. +// - region: Name of the region scoping this request. +func (r *RegionBackendServicesService) SetSecurityPolicy(project string, region string, backendService string, securitypolicyreference *SecurityPolicyReference) *RegionBackendServicesSetSecurityPolicyCall { + c := &RegionBackendServicesSetSecurityPolicyCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.project = project + c.region = region + c.backendService = backendService + c.securitypolicyreference = securitypolicyreference + 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. 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 *RegionBackendServicesSetSecurityPolicyCall) RequestId(requestId string) *RegionBackendServicesSetSecurityPolicyCall { + c.urlParams_.Set("requestId", requestId) + 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 *RegionBackendServicesSetSecurityPolicyCall) Fields(s ...googleapi.Field) *RegionBackendServicesSetSecurityPolicyCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *RegionBackendServicesSetSecurityPolicyCall) Context(ctx context.Context) *RegionBackendServicesSetSecurityPolicyCall { + 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 *RegionBackendServicesSetSecurityPolicyCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *RegionBackendServicesSetSecurityPolicyCall) 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.securitypolicyreference) + if err != nil { + return nil, err + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "projects/{project}/regions/{region}/backendServices/{backendService}/setSecurityPolicy") + 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{ + "project": c.project, + "region": c.region, + "backendService": c.backendService, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "compute.regionBackendServices.setSecurityPolicy" 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 *RegionBackendServicesSetSecurityPolicyCall) 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 RegionBackendServicesTestIamPermissionsCall struct { + s *Service + project string + region string + resource string + testpermissionsrequest *TestPermissionsRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// TestIamPermissions: Returns permissions that a caller has on the specified +// resource. +// +// - project: Project ID for this request. +// - region: The name of the region for this request. +// - resource: Name or id of the resource for this request. +func (r *RegionBackendServicesService) TestIamPermissions(project string, region string, resource string, testpermissionsrequest *TestPermissionsRequest) *RegionBackendServicesTestIamPermissionsCall { + c := &RegionBackendServicesTestIamPermissionsCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.project = project + c.region = region + c.resource = resource + c.testpermissionsrequest = testpermissionsrequest + 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 *RegionBackendServicesTestIamPermissionsCall) Fields(s ...googleapi.Field) *RegionBackendServicesTestIamPermissionsCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *RegionBackendServicesTestIamPermissionsCall) Context(ctx context.Context) *RegionBackendServicesTestIamPermissionsCall { + 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 *RegionBackendServicesTestIamPermissionsCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *RegionBackendServicesTestIamPermissionsCall) 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.testpermissionsrequest) + if err != nil { + return nil, err + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "projects/{project}/regions/{region}/backendServices/{resource}/testIamPermissions") + 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{ + "project": c.project, + "region": c.region, + "resource": c.resource, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "compute.regionBackendServices.testIamPermissions" call. +// Any non-2xx status code is an error. Response headers are in either +// *TestPermissionsResponse.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 *RegionBackendServicesTestIamPermissionsCall) Do(opts ...googleapi.CallOption) (*TestPermissionsResponse, 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 := &TestPermissionsResponse{ + 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 RegionBackendServicesUpdateCall struct { + s *Service + project string + region string + backendService string + backendservice *BackendService + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Update: Updates the specified regional BackendService resource with the data +// included in the request. For more information, see Backend services overview +// . +// +// - backendService: Name of the BackendService resource to update. +// - project: Project ID for this request. +// - region: Name of the region scoping this request. +func (r *RegionBackendServicesService) Update(project string, region string, backendService string, backendservice *BackendService) *RegionBackendServicesUpdateCall { + c := &RegionBackendServicesUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.project = project + c.region = region + c.backendService = backendService + c.backendservice = backendservice + 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. 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 *RegionBackendServicesUpdateCall) RequestId(requestId string) *RegionBackendServicesUpdateCall { + c.urlParams_.Set("requestId", requestId) + 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 *RegionBackendServicesUpdateCall) Fields(s ...googleapi.Field) *RegionBackendServicesUpdateCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *RegionBackendServicesUpdateCall) Context(ctx context.Context) *RegionBackendServicesUpdateCall { + 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 *RegionBackendServicesUpdateCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *RegionBackendServicesUpdateCall) 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.backendservice) + if err != nil { + return nil, err + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "projects/{project}/regions/{region}/backendServices/{backendService}") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("PUT", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "project": c.project, + "region": c.region, + "backendService": c.backendService, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "compute.regionBackendServices.update" 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 *RegionBackendServicesUpdateCall) 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 +} diff --git a/compute/v0.alpha/compute3-gen.go b/compute/v0.alpha/compute3-gen.go index 5ec2c80bfac..7ccdcc7c337 100644 --- a/compute/v0.alpha/compute3-gen.go +++ b/compute/v0.alpha/compute3-gen.go @@ -16,1622 +16,6 @@ import ( gensupport "google.golang.org/api/internal/gensupport" ) -type RegionBackendServicesDeleteCall struct { - s *Service - project string - region string - backendService string - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header -} - -// Delete: Deletes the specified regional BackendService resource. -// -// - backendService: Name of the BackendService resource to delete. -// - project: Project ID for this request. -// - region: Name of the region scoping this request. -func (r *RegionBackendServicesService) Delete(project string, region string, backendService string) *RegionBackendServicesDeleteCall { - c := &RegionBackendServicesDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.project = project - c.region = region - c.backendService = backendService - 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. 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 *RegionBackendServicesDeleteCall) RequestId(requestId string) *RegionBackendServicesDeleteCall { - c.urlParams_.Set("requestId", requestId) - 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 *RegionBackendServicesDeleteCall) Fields(s ...googleapi.Field) *RegionBackendServicesDeleteCall { - c.urlParams_.Set("fields", googleapi.CombineFields(s)) - return c -} - -// Context sets the context to be used in this call's Do method. -func (c *RegionBackendServicesDeleteCall) Context(ctx context.Context) *RegionBackendServicesDeleteCall { - 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 *RegionBackendServicesDeleteCall) Header() http.Header { - if c.header_ == nil { - c.header_ = make(http.Header) - } - return c.header_ -} - -func (c *RegionBackendServicesDeleteCall) 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, "projects/{project}/regions/{region}/backendServices/{backendService}") - 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{ - "project": c.project, - "region": c.region, - "backendService": c.backendService, - }) - return gensupport.SendRequest(c.ctx_, c.s.client, req) -} - -// Do executes the "compute.regionBackendServices.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 *RegionBackendServicesDeleteCall) 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 RegionBackendServicesGetCall struct { - s *Service - project string - region string - backendService string - urlParams_ gensupport.URLParams - ifNoneMatch_ string - ctx_ context.Context - header_ http.Header -} - -// Get: Returns the specified regional BackendService resource. -// -// - backendService: Name of the BackendService resource to return. -// - project: Project ID for this request. -// - region: Name of the region scoping this request. -func (r *RegionBackendServicesService) Get(project string, region string, backendService string) *RegionBackendServicesGetCall { - c := &RegionBackendServicesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.project = project - c.region = region - c.backendService = backendService - 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 *RegionBackendServicesGetCall) Fields(s ...googleapi.Field) *RegionBackendServicesGetCall { - 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 *RegionBackendServicesGetCall) IfNoneMatch(entityTag string) *RegionBackendServicesGetCall { - c.ifNoneMatch_ = entityTag - return c -} - -// Context sets the context to be used in this call's Do method. -func (c *RegionBackendServicesGetCall) Context(ctx context.Context) *RegionBackendServicesGetCall { - 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 *RegionBackendServicesGetCall) Header() http.Header { - if c.header_ == nil { - c.header_ = make(http.Header) - } - return c.header_ -} - -func (c *RegionBackendServicesGetCall) 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, "projects/{project}/regions/{region}/backendServices/{backendService}") - 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{ - "project": c.project, - "region": c.region, - "backendService": c.backendService, - }) - return gensupport.SendRequest(c.ctx_, c.s.client, req) -} - -// Do executes the "compute.regionBackendServices.get" call. -// Any non-2xx status code is an error. Response headers are in either -// *BackendService.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 *RegionBackendServicesGetCall) Do(opts ...googleapi.CallOption) (*BackendService, 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 := &BackendService{ - 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 RegionBackendServicesGetHealthCall struct { - s *Service - project string - region string - backendService string - resourcegroupreference *ResourceGroupReference - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header -} - -// GetHealth: Gets the most recent health check results for this regional -// BackendService. -// -// - backendService: Name of the BackendService resource for which to get -// health. -// - project: . -// - region: Name of the region scoping this request. -func (r *RegionBackendServicesService) GetHealth(project string, region string, backendService string, resourcegroupreference *ResourceGroupReference) *RegionBackendServicesGetHealthCall { - c := &RegionBackendServicesGetHealthCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.project = project - c.region = region - c.backendService = backendService - c.resourcegroupreference = resourcegroupreference - 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 *RegionBackendServicesGetHealthCall) Fields(s ...googleapi.Field) *RegionBackendServicesGetHealthCall { - c.urlParams_.Set("fields", googleapi.CombineFields(s)) - return c -} - -// Context sets the context to be used in this call's Do method. -func (c *RegionBackendServicesGetHealthCall) Context(ctx context.Context) *RegionBackendServicesGetHealthCall { - 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 *RegionBackendServicesGetHealthCall) Header() http.Header { - if c.header_ == nil { - c.header_ = make(http.Header) - } - return c.header_ -} - -func (c *RegionBackendServicesGetHealthCall) 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.resourcegroupreference) - if err != nil { - return nil, err - } - c.urlParams_.Set("alt", alt) - c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "projects/{project}/regions/{region}/backendServices/{backendService}/getHealth") - 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{ - "project": c.project, - "region": c.region, - "backendService": c.backendService, - }) - return gensupport.SendRequest(c.ctx_, c.s.client, req) -} - -// Do executes the "compute.regionBackendServices.getHealth" call. -// Any non-2xx status code is an error. Response headers are in either -// *BackendServiceGroupHealth.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 *RegionBackendServicesGetHealthCall) Do(opts ...googleapi.CallOption) (*BackendServiceGroupHealth, 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 := &BackendServiceGroupHealth{ - 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 RegionBackendServicesGetIamPolicyCall struct { - s *Service - project string - region string - resource string - urlParams_ gensupport.URLParams - ifNoneMatch_ string - ctx_ context.Context - header_ http.Header -} - -// GetIamPolicy: Gets the access control policy for a resource. May be empty if -// no such policy or resource exists. -// -// - project: Project ID for this request. -// - region: The name of the region for this request. -// - resource: Name or id of the resource for this request. -func (r *RegionBackendServicesService) GetIamPolicy(project string, region string, resource string) *RegionBackendServicesGetIamPolicyCall { - c := &RegionBackendServicesGetIamPolicyCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.project = project - c.region = region - c.resource = resource - return c -} - -// OptionsRequestedPolicyVersion sets the optional parameter -// "optionsRequestedPolicyVersion": Requested IAM Policy version. -func (c *RegionBackendServicesGetIamPolicyCall) OptionsRequestedPolicyVersion(optionsRequestedPolicyVersion int64) *RegionBackendServicesGetIamPolicyCall { - c.urlParams_.Set("optionsRequestedPolicyVersion", fmt.Sprint(optionsRequestedPolicyVersion)) - 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 *RegionBackendServicesGetIamPolicyCall) Fields(s ...googleapi.Field) *RegionBackendServicesGetIamPolicyCall { - 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 *RegionBackendServicesGetIamPolicyCall) IfNoneMatch(entityTag string) *RegionBackendServicesGetIamPolicyCall { - c.ifNoneMatch_ = entityTag - return c -} - -// Context sets the context to be used in this call's Do method. -func (c *RegionBackendServicesGetIamPolicyCall) Context(ctx context.Context) *RegionBackendServicesGetIamPolicyCall { - 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 *RegionBackendServicesGetIamPolicyCall) Header() http.Header { - if c.header_ == nil { - c.header_ = make(http.Header) - } - return c.header_ -} - -func (c *RegionBackendServicesGetIamPolicyCall) 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, "projects/{project}/regions/{region}/backendServices/{resource}/getIamPolicy") - 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{ - "project": c.project, - "region": c.region, - "resource": c.resource, - }) - return gensupport.SendRequest(c.ctx_, c.s.client, req) -} - -// Do executes the "compute.regionBackendServices.getIamPolicy" call. -// Any non-2xx status code is an error. Response headers are in either -// *Policy.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 *RegionBackendServicesGetIamPolicyCall) Do(opts ...googleapi.CallOption) (*Policy, 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 := &Policy{ - 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 RegionBackendServicesInsertCall struct { - s *Service - project string - region string - backendservice *BackendService - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header -} - -// Insert: Creates a regional BackendService resource in the specified project -// using the data included in the request. For more information, see Backend -// services overview. -// -// - project: Project ID for this request. -// - region: Name of the region scoping this request. -func (r *RegionBackendServicesService) Insert(project string, region string, backendservice *BackendService) *RegionBackendServicesInsertCall { - c := &RegionBackendServicesInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.project = project - c.region = region - c.backendservice = backendservice - 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. 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 *RegionBackendServicesInsertCall) RequestId(requestId string) *RegionBackendServicesInsertCall { - c.urlParams_.Set("requestId", requestId) - 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 *RegionBackendServicesInsertCall) Fields(s ...googleapi.Field) *RegionBackendServicesInsertCall { - c.urlParams_.Set("fields", googleapi.CombineFields(s)) - return c -} - -// Context sets the context to be used in this call's Do method. -func (c *RegionBackendServicesInsertCall) Context(ctx context.Context) *RegionBackendServicesInsertCall { - 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 *RegionBackendServicesInsertCall) Header() http.Header { - if c.header_ == nil { - c.header_ = make(http.Header) - } - return c.header_ -} - -func (c *RegionBackendServicesInsertCall) 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.backendservice) - if err != nil { - return nil, err - } - c.urlParams_.Set("alt", alt) - c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "projects/{project}/regions/{region}/backendServices") - 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{ - "project": c.project, - "region": c.region, - }) - return gensupport.SendRequest(c.ctx_, c.s.client, req) -} - -// Do executes the "compute.regionBackendServices.insert" 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 *RegionBackendServicesInsertCall) 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 RegionBackendServicesListCall struct { - s *Service - project string - region string - urlParams_ gensupport.URLParams - ifNoneMatch_ string - ctx_ context.Context - header_ http.Header -} - -// List: Retrieves the list of regional BackendService resources available to -// the specified project in the given region. -// -// - project: Project ID for this request. -// - region: Name of the region scoping this request. -func (r *RegionBackendServicesService) List(project string, region string) *RegionBackendServicesListCall { - c := &RegionBackendServicesListCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.project = project - c.region = region - return c -} - -// Filter sets the optional parameter "filter": A filter expression that -// filters resources listed in the response. Most Compute resources support two -// types of filter expressions: expressions that support regular expressions -// and expressions that follow API improvement proposal AIP-160. These two -// types of filter expressions cannot be mixed in one request. If you want to -// use AIP-160, your expression must specify the field name, an operator, and -// the value that you want to use for filtering. The value must be a string, a -// number, or a boolean. The operator must be either `=`, `!=`, `>`, `<`, `<=`, -// `>=` or `:`. For example, if you are filtering Compute Engine instances, you -// can exclude instances named `example-instance` by specifying `name != -// example-instance`. The `:*` comparison can be used to test whether a key has -// been defined. For example, to find all objects with `owner` label use: ``` -// labels.owner:* ``` You can also filter nested fields. For example, you could -// specify `scheduling.automaticRestart = false` to include instances only if -// they are not scheduled for automatic restarts. You can use filtering on -// nested fields to filter based on resource labels. To filter on multiple -// expressions, provide each separate expression within parentheses. For -// example: ``` (scheduling.automaticRestart = true) (cpuPlatform = "Intel -// Skylake") ``` By default, each expression is an `AND` expression. However, -// you can include `AND` and `OR` expressions explicitly. For example: ``` -// (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND -// (scheduling.automaticRestart = true) ``` If you want to use a regular -// expression, use the `eq` (equal) or `ne` (not equal) operator against a -// single un-parenthesized expression with or without quotes or against -// multiple parenthesized expressions. Examples: `fieldname eq unquoted -// literal` `fieldname eq 'single quoted literal'` `fieldname eq "double quoted -// literal" `(fieldname1 eq literal) (fieldname2 ne "literal")` The literal -// value is interpreted as a regular expression using Google RE2 library -// syntax. The literal value must match the entire field. For example, to -// filter for instances that do not end with name "instance", you would use -// `name ne .*instance`. You cannot combine constraints on multiple fields -// using regular expressions. -func (c *RegionBackendServicesListCall) Filter(filter string) *RegionBackendServicesListCall { - c.urlParams_.Set("filter", filter) - return c -} - -// MaxResults sets the optional parameter "maxResults": The maximum number of -// results per page that should be returned. If the number of available results -// is larger than `maxResults`, Compute Engine returns a `nextPageToken` that -// can be used to get the next page of results in subsequent list requests. -// Acceptable values are `0` to `500`, inclusive. (Default: `500`) -func (c *RegionBackendServicesListCall) MaxResults(maxResults int64) *RegionBackendServicesListCall { - c.urlParams_.Set("maxResults", fmt.Sprint(maxResults)) - return c -} - -// OrderBy sets the optional parameter "orderBy": Sorts list results by a -// certain order. By default, results are returned in alphanumerical order -// based on the resource name. You can also sort results in descending order -// based on the creation timestamp using `orderBy="creationTimestamp desc". -// This sorts results based on the `creationTimestamp` field in reverse -// chronological order (newest result first). Use this to sort resources like -// operations so that the newest operation is returned first. Currently, only -// sorting by `name` or `creationTimestamp desc` is supported. -func (c *RegionBackendServicesListCall) OrderBy(orderBy string) *RegionBackendServicesListCall { - c.urlParams_.Set("orderBy", orderBy) - return c -} - -// PageToken sets the optional parameter "pageToken": Specifies a page token to -// use. Set `pageToken` to the `nextPageToken` returned by a previous list -// request to get the next page of results. -func (c *RegionBackendServicesListCall) PageToken(pageToken string) *RegionBackendServicesListCall { - c.urlParams_.Set("pageToken", pageToken) - return c -} - -// ReturnPartialSuccess sets the optional parameter "returnPartialSuccess": -// Opt-in for partial success behavior which provides partial results in case -// of failure. The default value is false. For example, when partial success -// behavior is enabled, aggregatedList for a single zone scope either returns -// all resources in the zone or no resources, with an error code. -func (c *RegionBackendServicesListCall) ReturnPartialSuccess(returnPartialSuccess bool) *RegionBackendServicesListCall { - c.urlParams_.Set("returnPartialSuccess", fmt.Sprint(returnPartialSuccess)) - 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 *RegionBackendServicesListCall) Fields(s ...googleapi.Field) *RegionBackendServicesListCall { - 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 *RegionBackendServicesListCall) IfNoneMatch(entityTag string) *RegionBackendServicesListCall { - c.ifNoneMatch_ = entityTag - return c -} - -// Context sets the context to be used in this call's Do method. -func (c *RegionBackendServicesListCall) Context(ctx context.Context) *RegionBackendServicesListCall { - 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 *RegionBackendServicesListCall) Header() http.Header { - if c.header_ == nil { - c.header_ = make(http.Header) - } - return c.header_ -} - -func (c *RegionBackendServicesListCall) 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, "projects/{project}/regions/{region}/backendServices") - 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{ - "project": c.project, - "region": c.region, - }) - return gensupport.SendRequest(c.ctx_, c.s.client, req) -} - -// Do executes the "compute.regionBackendServices.list" call. -// Any non-2xx status code is an error. Response headers are in either -// *BackendServiceList.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 *RegionBackendServicesListCall) Do(opts ...googleapi.CallOption) (*BackendServiceList, 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 := &BackendServiceList{ - 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 *RegionBackendServicesListCall) Pages(ctx context.Context, f func(*BackendServiceList) 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 RegionBackendServicesListUsableCall struct { - s *Service - project string - region string - urlParams_ gensupport.URLParams - ifNoneMatch_ string - ctx_ context.Context - header_ http.Header -} - -// ListUsable: Retrieves an aggregated list of all usable backend services in -// the specified project in the given region. -// -// - project: Project ID for this request. -// - region: Name of the region scoping this request. It must be a string that -// meets the requirements in RFC1035. -func (r *RegionBackendServicesService) ListUsable(project string, region string) *RegionBackendServicesListUsableCall { - c := &RegionBackendServicesListUsableCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.project = project - c.region = region - return c -} - -// Filter sets the optional parameter "filter": A filter expression that -// filters resources listed in the response. Most Compute resources support two -// types of filter expressions: expressions that support regular expressions -// and expressions that follow API improvement proposal AIP-160. These two -// types of filter expressions cannot be mixed in one request. If you want to -// use AIP-160, your expression must specify the field name, an operator, and -// the value that you want to use for filtering. The value must be a string, a -// number, or a boolean. The operator must be either `=`, `!=`, `>`, `<`, `<=`, -// `>=` or `:`. For example, if you are filtering Compute Engine instances, you -// can exclude instances named `example-instance` by specifying `name != -// example-instance`. The `:*` comparison can be used to test whether a key has -// been defined. For example, to find all objects with `owner` label use: ``` -// labels.owner:* ``` You can also filter nested fields. For example, you could -// specify `scheduling.automaticRestart = false` to include instances only if -// they are not scheduled for automatic restarts. You can use filtering on -// nested fields to filter based on resource labels. To filter on multiple -// expressions, provide each separate expression within parentheses. For -// example: ``` (scheduling.automaticRestart = true) (cpuPlatform = "Intel -// Skylake") ``` By default, each expression is an `AND` expression. However, -// you can include `AND` and `OR` expressions explicitly. For example: ``` -// (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND -// (scheduling.automaticRestart = true) ``` If you want to use a regular -// expression, use the `eq` (equal) or `ne` (not equal) operator against a -// single un-parenthesized expression with or without quotes or against -// multiple parenthesized expressions. Examples: `fieldname eq unquoted -// literal` `fieldname eq 'single quoted literal'` `fieldname eq "double quoted -// literal" `(fieldname1 eq literal) (fieldname2 ne "literal")` The literal -// value is interpreted as a regular expression using Google RE2 library -// syntax. The literal value must match the entire field. For example, to -// filter for instances that do not end with name "instance", you would use -// `name ne .*instance`. You cannot combine constraints on multiple fields -// using regular expressions. -func (c *RegionBackendServicesListUsableCall) Filter(filter string) *RegionBackendServicesListUsableCall { - c.urlParams_.Set("filter", filter) - return c -} - -// MaxResults sets the optional parameter "maxResults": The maximum number of -// results per page that should be returned. If the number of available results -// is larger than `maxResults`, Compute Engine returns a `nextPageToken` that -// can be used to get the next page of results in subsequent list requests. -// Acceptable values are `0` to `500`, inclusive. (Default: `500`) -func (c *RegionBackendServicesListUsableCall) MaxResults(maxResults int64) *RegionBackendServicesListUsableCall { - c.urlParams_.Set("maxResults", fmt.Sprint(maxResults)) - return c -} - -// OrderBy sets the optional parameter "orderBy": Sorts list results by a -// certain order. By default, results are returned in alphanumerical order -// based on the resource name. You can also sort results in descending order -// based on the creation timestamp using `orderBy="creationTimestamp desc". -// This sorts results based on the `creationTimestamp` field in reverse -// chronological order (newest result first). Use this to sort resources like -// operations so that the newest operation is returned first. Currently, only -// sorting by `name` or `creationTimestamp desc` is supported. -func (c *RegionBackendServicesListUsableCall) OrderBy(orderBy string) *RegionBackendServicesListUsableCall { - c.urlParams_.Set("orderBy", orderBy) - return c -} - -// PageToken sets the optional parameter "pageToken": Specifies a page token to -// use. Set `pageToken` to the `nextPageToken` returned by a previous list -// request to get the next page of results. -func (c *RegionBackendServicesListUsableCall) PageToken(pageToken string) *RegionBackendServicesListUsableCall { - c.urlParams_.Set("pageToken", pageToken) - return c -} - -// ReturnPartialSuccess sets the optional parameter "returnPartialSuccess": -// Opt-in for partial success behavior which provides partial results in case -// of failure. The default value is false. For example, when partial success -// behavior is enabled, aggregatedList for a single zone scope either returns -// all resources in the zone or no resources, with an error code. -func (c *RegionBackendServicesListUsableCall) ReturnPartialSuccess(returnPartialSuccess bool) *RegionBackendServicesListUsableCall { - c.urlParams_.Set("returnPartialSuccess", fmt.Sprint(returnPartialSuccess)) - 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 *RegionBackendServicesListUsableCall) Fields(s ...googleapi.Field) *RegionBackendServicesListUsableCall { - 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 *RegionBackendServicesListUsableCall) IfNoneMatch(entityTag string) *RegionBackendServicesListUsableCall { - c.ifNoneMatch_ = entityTag - return c -} - -// Context sets the context to be used in this call's Do method. -func (c *RegionBackendServicesListUsableCall) Context(ctx context.Context) *RegionBackendServicesListUsableCall { - 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 *RegionBackendServicesListUsableCall) Header() http.Header { - if c.header_ == nil { - c.header_ = make(http.Header) - } - return c.header_ -} - -func (c *RegionBackendServicesListUsableCall) 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, "projects/{project}/regions/{region}/backendServices/listUsable") - 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{ - "project": c.project, - "region": c.region, - }) - return gensupport.SendRequest(c.ctx_, c.s.client, req) -} - -// Do executes the "compute.regionBackendServices.listUsable" call. -// Any non-2xx status code is an error. Response headers are in either -// *BackendServiceListUsable.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 *RegionBackendServicesListUsableCall) Do(opts ...googleapi.CallOption) (*BackendServiceListUsable, 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 := &BackendServiceListUsable{ - 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 *RegionBackendServicesListUsableCall) Pages(ctx context.Context, f func(*BackendServiceListUsable) 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 RegionBackendServicesPatchCall struct { - s *Service - project string - region string - backendService string - backendservice *BackendService - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header -} - -// Patch: Updates the specified regional BackendService resource with the data -// included in the request. For more information, see Understanding backend -// services This method supports PATCH semantics and uses the JSON merge patch -// format and processing rules. -// -// - backendService: Name of the BackendService resource to patch. -// - project: Project ID for this request. -// - region: Name of the region scoping this request. -func (r *RegionBackendServicesService) Patch(project string, region string, backendService string, backendservice *BackendService) *RegionBackendServicesPatchCall { - c := &RegionBackendServicesPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.project = project - c.region = region - c.backendService = backendService - c.backendservice = backendservice - 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. 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 *RegionBackendServicesPatchCall) RequestId(requestId string) *RegionBackendServicesPatchCall { - c.urlParams_.Set("requestId", requestId) - 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 *RegionBackendServicesPatchCall) Fields(s ...googleapi.Field) *RegionBackendServicesPatchCall { - c.urlParams_.Set("fields", googleapi.CombineFields(s)) - return c -} - -// Context sets the context to be used in this call's Do method. -func (c *RegionBackendServicesPatchCall) Context(ctx context.Context) *RegionBackendServicesPatchCall { - 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 *RegionBackendServicesPatchCall) Header() http.Header { - if c.header_ == nil { - c.header_ = make(http.Header) - } - return c.header_ -} - -func (c *RegionBackendServicesPatchCall) 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.backendservice) - if err != nil { - return nil, err - } - c.urlParams_.Set("alt", alt) - c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "projects/{project}/regions/{region}/backendServices/{backendService}") - 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{ - "project": c.project, - "region": c.region, - "backendService": c.backendService, - }) - return gensupport.SendRequest(c.ctx_, c.s.client, req) -} - -// Do executes the "compute.regionBackendServices.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 *RegionBackendServicesPatchCall) 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 RegionBackendServicesSetIamPolicyCall struct { - s *Service - project string - region string - resource string - regionsetpolicyrequest *RegionSetPolicyRequest - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header -} - -// SetIamPolicy: Sets the access control policy on the specified resource. -// Replaces any existing policy. -// -// - project: Project ID for this request. -// - region: The name of the region for this request. -// - resource: Name or id of the resource for this request. -func (r *RegionBackendServicesService) SetIamPolicy(project string, region string, resource string, regionsetpolicyrequest *RegionSetPolicyRequest) *RegionBackendServicesSetIamPolicyCall { - c := &RegionBackendServicesSetIamPolicyCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.project = project - c.region = region - c.resource = resource - c.regionsetpolicyrequest = regionsetpolicyrequest - 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 *RegionBackendServicesSetIamPolicyCall) Fields(s ...googleapi.Field) *RegionBackendServicesSetIamPolicyCall { - c.urlParams_.Set("fields", googleapi.CombineFields(s)) - return c -} - -// Context sets the context to be used in this call's Do method. -func (c *RegionBackendServicesSetIamPolicyCall) Context(ctx context.Context) *RegionBackendServicesSetIamPolicyCall { - 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 *RegionBackendServicesSetIamPolicyCall) Header() http.Header { - if c.header_ == nil { - c.header_ = make(http.Header) - } - return c.header_ -} - -func (c *RegionBackendServicesSetIamPolicyCall) 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.regionsetpolicyrequest) - if err != nil { - return nil, err - } - c.urlParams_.Set("alt", alt) - c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "projects/{project}/regions/{region}/backendServices/{resource}/setIamPolicy") - 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{ - "project": c.project, - "region": c.region, - "resource": c.resource, - }) - return gensupport.SendRequest(c.ctx_, c.s.client, req) -} - -// Do executes the "compute.regionBackendServices.setIamPolicy" call. -// Any non-2xx status code is an error. Response headers are in either -// *Policy.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 *RegionBackendServicesSetIamPolicyCall) Do(opts ...googleapi.CallOption) (*Policy, 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 := &Policy{ - 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 RegionBackendServicesSetSecurityPolicyCall struct { - s *Service - project string - region string - backendService string - securitypolicyreference *SecurityPolicyReference - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header -} - -// SetSecurityPolicy: Sets the Google Cloud Armor security policy for the -// specified backend service. For more information, see Google Cloud Armor -// Overview -// -// - backendService: Name of the BackendService resource to which the security -// policy should be set. The name should conform to RFC1035. -// - project: Project ID for this request. -// - region: Name of the region scoping this request. -func (r *RegionBackendServicesService) SetSecurityPolicy(project string, region string, backendService string, securitypolicyreference *SecurityPolicyReference) *RegionBackendServicesSetSecurityPolicyCall { - c := &RegionBackendServicesSetSecurityPolicyCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.project = project - c.region = region - c.backendService = backendService - c.securitypolicyreference = securitypolicyreference - 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. 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 *RegionBackendServicesSetSecurityPolicyCall) RequestId(requestId string) *RegionBackendServicesSetSecurityPolicyCall { - c.urlParams_.Set("requestId", requestId) - 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 *RegionBackendServicesSetSecurityPolicyCall) Fields(s ...googleapi.Field) *RegionBackendServicesSetSecurityPolicyCall { - c.urlParams_.Set("fields", googleapi.CombineFields(s)) - return c -} - -// Context sets the context to be used in this call's Do method. -func (c *RegionBackendServicesSetSecurityPolicyCall) Context(ctx context.Context) *RegionBackendServicesSetSecurityPolicyCall { - 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 *RegionBackendServicesSetSecurityPolicyCall) Header() http.Header { - if c.header_ == nil { - c.header_ = make(http.Header) - } - return c.header_ -} - -func (c *RegionBackendServicesSetSecurityPolicyCall) 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.securitypolicyreference) - if err != nil { - return nil, err - } - c.urlParams_.Set("alt", alt) - c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "projects/{project}/regions/{region}/backendServices/{backendService}/setSecurityPolicy") - 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{ - "project": c.project, - "region": c.region, - "backendService": c.backendService, - }) - return gensupport.SendRequest(c.ctx_, c.s.client, req) -} - -// Do executes the "compute.regionBackendServices.setSecurityPolicy" 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 *RegionBackendServicesSetSecurityPolicyCall) 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 RegionBackendServicesTestIamPermissionsCall struct { - s *Service - project string - region string - resource string - testpermissionsrequest *TestPermissionsRequest - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header -} - -// TestIamPermissions: Returns permissions that a caller has on the specified -// resource. -// -// - project: Project ID for this request. -// - region: The name of the region for this request. -// - resource: Name or id of the resource for this request. -func (r *RegionBackendServicesService) TestIamPermissions(project string, region string, resource string, testpermissionsrequest *TestPermissionsRequest) *RegionBackendServicesTestIamPermissionsCall { - c := &RegionBackendServicesTestIamPermissionsCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.project = project - c.region = region - c.resource = resource - c.testpermissionsrequest = testpermissionsrequest - 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 *RegionBackendServicesTestIamPermissionsCall) Fields(s ...googleapi.Field) *RegionBackendServicesTestIamPermissionsCall { - c.urlParams_.Set("fields", googleapi.CombineFields(s)) - return c -} - -// Context sets the context to be used in this call's Do method. -func (c *RegionBackendServicesTestIamPermissionsCall) Context(ctx context.Context) *RegionBackendServicesTestIamPermissionsCall { - 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 *RegionBackendServicesTestIamPermissionsCall) Header() http.Header { - if c.header_ == nil { - c.header_ = make(http.Header) - } - return c.header_ -} - -func (c *RegionBackendServicesTestIamPermissionsCall) 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.testpermissionsrequest) - if err != nil { - return nil, err - } - c.urlParams_.Set("alt", alt) - c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "projects/{project}/regions/{region}/backendServices/{resource}/testIamPermissions") - 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{ - "project": c.project, - "region": c.region, - "resource": c.resource, - }) - return gensupport.SendRequest(c.ctx_, c.s.client, req) -} - -// Do executes the "compute.regionBackendServices.testIamPermissions" call. -// Any non-2xx status code is an error. Response headers are in either -// *TestPermissionsResponse.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 *RegionBackendServicesTestIamPermissionsCall) Do(opts ...googleapi.CallOption) (*TestPermissionsResponse, 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 := &TestPermissionsResponse{ - 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 RegionBackendServicesUpdateCall struct { - s *Service - project string - region string - backendService string - backendservice *BackendService - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header -} - -// Update: Updates the specified regional BackendService resource with the data -// included in the request. For more information, see Backend services overview -// . -// -// - backendService: Name of the BackendService resource to update. -// - project: Project ID for this request. -// - region: Name of the region scoping this request. -func (r *RegionBackendServicesService) Update(project string, region string, backendService string, backendservice *BackendService) *RegionBackendServicesUpdateCall { - c := &RegionBackendServicesUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.project = project - c.region = region - c.backendService = backendService - c.backendservice = backendservice - 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. 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 *RegionBackendServicesUpdateCall) RequestId(requestId string) *RegionBackendServicesUpdateCall { - c.urlParams_.Set("requestId", requestId) - 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 *RegionBackendServicesUpdateCall) Fields(s ...googleapi.Field) *RegionBackendServicesUpdateCall { - c.urlParams_.Set("fields", googleapi.CombineFields(s)) - return c -} - -// Context sets the context to be used in this call's Do method. -func (c *RegionBackendServicesUpdateCall) Context(ctx context.Context) *RegionBackendServicesUpdateCall { - 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 *RegionBackendServicesUpdateCall) Header() http.Header { - if c.header_ == nil { - c.header_ = make(http.Header) - } - return c.header_ -} - -func (c *RegionBackendServicesUpdateCall) 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.backendservice) - if err != nil { - return nil, err - } - c.urlParams_.Set("alt", alt) - c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "projects/{project}/regions/{region}/backendServices/{backendService}") - urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("PUT", urls, body) - if err != nil { - return nil, err - } - req.Header = reqHeaders - googleapi.Expand(req.URL, map[string]string{ - "project": c.project, - "region": c.region, - "backendService": c.backendService, - }) - return gensupport.SendRequest(c.ctx_, c.s.client, req) -} - -// Do executes the "compute.regionBackendServices.update" 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 *RegionBackendServicesUpdateCall) 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 RegionCommitmentsAggregatedListCall struct { s *Service project string @@ -7525,8 +5909,265 @@ func (r *RegionHealthChecksService) Update(project string, region string, health c := &RegionHealthChecksUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.project = project c.region = region - c.healthCheck = healthCheck - c.healthcheck = healthcheck + c.healthCheck = healthCheck + c.healthcheck = healthcheck + 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. 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 *RegionHealthChecksUpdateCall) RequestId(requestId string) *RegionHealthChecksUpdateCall { + c.urlParams_.Set("requestId", requestId) + 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 *RegionHealthChecksUpdateCall) Fields(s ...googleapi.Field) *RegionHealthChecksUpdateCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *RegionHealthChecksUpdateCall) Context(ctx context.Context) *RegionHealthChecksUpdateCall { + 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 *RegionHealthChecksUpdateCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *RegionHealthChecksUpdateCall) 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.healthcheck) + if err != nil { + return nil, err + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "projects/{project}/regions/{region}/healthChecks/{healthCheck}") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("PUT", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "project": c.project, + "region": c.region, + "healthCheck": c.healthCheck, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "compute.regionHealthChecks.update" 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 *RegionHealthChecksUpdateCall) 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 RegionInstanceGroupManagerResizeRequestsCancelCall struct { + s *Service + project string + region string + instanceGroupManager string + resizeRequest string + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Cancel: Cancels the specified resize request. Cancelled resize request no +// longer waits for the resources to be provisioned. Cancel is only possible +// for requests that are in accepted state. +// +// - instanceGroupManager: The name of the managed instance group. Name should +// conform to RFC1035 or be a resource ID. +// - project: Project ID for this request. +// - region: The name of the region scoping this request. Name should conform +// to RFC1035. +// - resizeRequest: The name of the resize request to cancel. Name should +// conform to RFC1035 or be a resource ID. +func (r *RegionInstanceGroupManagerResizeRequestsService) Cancel(project string, region string, instanceGroupManager string, resizeRequest string) *RegionInstanceGroupManagerResizeRequestsCancelCall { + c := &RegionInstanceGroupManagerResizeRequestsCancelCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.project = project + c.region = region + c.instanceGroupManager = instanceGroupManager + c.resizeRequest = resizeRequest + 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. 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 *RegionInstanceGroupManagerResizeRequestsCancelCall) RequestId(requestId string) *RegionInstanceGroupManagerResizeRequestsCancelCall { + c.urlParams_.Set("requestId", requestId) + 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 *RegionInstanceGroupManagerResizeRequestsCancelCall) Fields(s ...googleapi.Field) *RegionInstanceGroupManagerResizeRequestsCancelCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *RegionInstanceGroupManagerResizeRequestsCancelCall) Context(ctx context.Context) *RegionInstanceGroupManagerResizeRequestsCancelCall { + 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 *RegionInstanceGroupManagerResizeRequestsCancelCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *RegionInstanceGroupManagerResizeRequestsCancelCall) 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, "projects/{project}/regions/{region}/instanceGroupManagers/{instanceGroupManager}/resizeRequests/{resizeRequest}/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{ + "project": c.project, + "region": c.region, + "instanceGroupManager": c.instanceGroupManager, + "resizeRequest": c.resizeRequest, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "compute.regionInstanceGroupManagerResizeRequests.cancel" 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 *RegionInstanceGroupManagerResizeRequestsCancelCall) 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 RegionInstanceGroupManagerResizeRequestsDeleteCall struct { + s *Service + project string + region string + instanceGroupManager string + resizeRequest string + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Delete: Deletes the specified, inactive resize request. Requests that are +// still active cannot be deleted. Deleting request does not delete instances +// that were provisioned previously. +// +// - instanceGroupManager: The name of the managed instance group. Name should +// conform to RFC1035 or be a resource ID. +// - project: Project ID for this request. +// - region: The name of the region scoping this request. Name should conform +// to RFC1035. +// - resizeRequest: The name of the resize request to delete. Name should +// conform to RFC1035 or be a resource ID. +func (r *RegionInstanceGroupManagerResizeRequestsService) Delete(project string, region string, instanceGroupManager string, resizeRequest string) *RegionInstanceGroupManagerResizeRequestsDeleteCall { + c := &RegionInstanceGroupManagerResizeRequestsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.project = project + c.region = region + c.instanceGroupManager = instanceGroupManager + c.resizeRequest = resizeRequest return c } @@ -7540,7 +6181,7 @@ func (r *RegionHealthChecksService) Update(project string, region string, health // 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 *RegionHealthChecksUpdateCall) RequestId(requestId string) *RegionHealthChecksUpdateCall { +func (c *RegionInstanceGroupManagerResizeRequestsDeleteCall) RequestId(requestId string) *RegionInstanceGroupManagerResizeRequestsDeleteCall { c.urlParams_.Set("requestId", requestId) return c } @@ -7548,56 +6189,53 @@ func (c *RegionHealthChecksUpdateCall) RequestId(requestId string) *RegionHealth // Fields allows partial responses to be retrieved. See // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more // details. -func (c *RegionHealthChecksUpdateCall) Fields(s ...googleapi.Field) *RegionHealthChecksUpdateCall { +func (c *RegionInstanceGroupManagerResizeRequestsDeleteCall) Fields(s ...googleapi.Field) *RegionInstanceGroupManagerResizeRequestsDeleteCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } // Context sets the context to be used in this call's Do method. -func (c *RegionHealthChecksUpdateCall) Context(ctx context.Context) *RegionHealthChecksUpdateCall { +func (c *RegionInstanceGroupManagerResizeRequestsDeleteCall) Context(ctx context.Context) *RegionInstanceGroupManagerResizeRequestsDeleteCall { 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 *RegionHealthChecksUpdateCall) Header() http.Header { +func (c *RegionInstanceGroupManagerResizeRequestsDeleteCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *RegionHealthChecksUpdateCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) +func (c *RegionInstanceGroupManagerResizeRequestsDeleteCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) var body io.Reader = nil - body, err := googleapi.WithoutDataWrapper.JSONReader(c.healthcheck) - if err != nil { - return nil, err - } c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "projects/{project}/regions/{region}/healthChecks/{healthCheck}") + urls := googleapi.ResolveRelative(c.s.BasePath, "projects/{project}/regions/{region}/instanceGroupManagers/{instanceGroupManager}/resizeRequests/{resizeRequest}") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("PUT", urls, body) + req, err := http.NewRequest("DELETE", urls, body) if err != nil { return nil, err } req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ - "project": c.project, - "region": c.region, - "healthCheck": c.healthCheck, + "project": c.project, + "region": c.region, + "instanceGroupManager": c.instanceGroupManager, + "resizeRequest": c.resizeRequest, }) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "compute.regionHealthChecks.update" call. +// Do executes the "compute.regionInstanceGroupManagerResizeRequests.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 *RegionHealthChecksUpdateCall) Do(opts ...googleapi.CallOption) (*Operation, error) { +func (c *RegionInstanceGroupManagerResizeRequestsDeleteCall) Do(opts ...googleapi.CallOption) (*Operation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -27124,7 +25762,236 @@ func (c *RegionUrlMapsListCall) Pages(ctx context.Context, f func(*UrlMapList) e } } -type RegionUrlMapsPatchCall struct { +type RegionUrlMapsPatchCall struct { + s *Service + project string + region string + urlMap string + urlmap *UrlMap + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Patch: Patches the specified UrlMap resource with the data included in the +// request. This method supports PATCH semantics and uses JSON merge patch +// format and processing rules. +// +// - project: Project ID for this request. +// - region: Name of the region scoping this request. +// - urlMap: Name of the UrlMap resource to patch. +func (r *RegionUrlMapsService) Patch(project string, region string, urlMap string, urlmap *UrlMap) *RegionUrlMapsPatchCall { + c := &RegionUrlMapsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.project = project + c.region = region + c.urlMap = urlMap + c.urlmap = urlmap + return c +} + +// RequestId sets the optional parameter "requestId": begin_interface: +// MixerMutationRequestBuilder Request ID to support idempotency. +func (c *RegionUrlMapsPatchCall) RequestId(requestId string) *RegionUrlMapsPatchCall { + c.urlParams_.Set("requestId", requestId) + 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 *RegionUrlMapsPatchCall) Fields(s ...googleapi.Field) *RegionUrlMapsPatchCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *RegionUrlMapsPatchCall) Context(ctx context.Context) *RegionUrlMapsPatchCall { + 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 *RegionUrlMapsPatchCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *RegionUrlMapsPatchCall) 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.urlmap) + if err != nil { + return nil, err + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "projects/{project}/regions/{region}/urlMaps/{urlMap}") + 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{ + "project": c.project, + "region": c.region, + "urlMap": c.urlMap, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "compute.regionUrlMaps.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 *RegionUrlMapsPatchCall) 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 RegionUrlMapsTestIamPermissionsCall struct { + s *Service + project string + region string + resource string + testpermissionsrequest *TestPermissionsRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// TestIamPermissions: Returns permissions that a caller has on the specified +// resource. +// +// - project: Project ID for this request. +// - region: The name of the region for this request. +// - resource: Name or id of the resource for this request. +func (r *RegionUrlMapsService) TestIamPermissions(project string, region string, resource string, testpermissionsrequest *TestPermissionsRequest) *RegionUrlMapsTestIamPermissionsCall { + c := &RegionUrlMapsTestIamPermissionsCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.project = project + c.region = region + c.resource = resource + c.testpermissionsrequest = testpermissionsrequest + 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 *RegionUrlMapsTestIamPermissionsCall) Fields(s ...googleapi.Field) *RegionUrlMapsTestIamPermissionsCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *RegionUrlMapsTestIamPermissionsCall) Context(ctx context.Context) *RegionUrlMapsTestIamPermissionsCall { + 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 *RegionUrlMapsTestIamPermissionsCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *RegionUrlMapsTestIamPermissionsCall) 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.testpermissionsrequest) + if err != nil { + return nil, err + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "projects/{project}/regions/{region}/urlMaps/{resource}/testIamPermissions") + 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{ + "project": c.project, + "region": c.region, + "resource": c.resource, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "compute.regionUrlMaps.testIamPermissions" call. +// Any non-2xx status code is an error. Response headers are in either +// *TestPermissionsResponse.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 *RegionUrlMapsTestIamPermissionsCall) Do(opts ...googleapi.CallOption) (*TestPermissionsResponse, 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 := &TestPermissionsResponse{ + 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 RegionUrlMapsUpdateCall struct { s *Service project string region string @@ -27135,15 +26002,14 @@ type RegionUrlMapsPatchCall struct { header_ http.Header } -// Patch: Patches the specified UrlMap resource with the data included in the -// request. This method supports PATCH semantics and uses JSON merge patch -// format and processing rules. +// Update: Updates the specified UrlMap resource with the data included in the +// request. // // - project: Project ID for this request. // - region: Name of the region scoping this request. -// - urlMap: Name of the UrlMap resource to patch. -func (r *RegionUrlMapsService) Patch(project string, region string, urlMap string, urlmap *UrlMap) *RegionUrlMapsPatchCall { - c := &RegionUrlMapsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// - urlMap: Name of the UrlMap resource to update. +func (r *RegionUrlMapsService) Update(project string, region string, urlMap string, urlmap *UrlMap) *RegionUrlMapsUpdateCall { + c := &RegionUrlMapsUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.project = project c.region = region c.urlMap = urlMap @@ -27153,7 +26019,7 @@ func (r *RegionUrlMapsService) Patch(project string, region string, urlMap strin // RequestId sets the optional parameter "requestId": begin_interface: // MixerMutationRequestBuilder Request ID to support idempotency. -func (c *RegionUrlMapsPatchCall) RequestId(requestId string) *RegionUrlMapsPatchCall { +func (c *RegionUrlMapsUpdateCall) RequestId(requestId string) *RegionUrlMapsUpdateCall { c.urlParams_.Set("requestId", requestId) return c } @@ -27161,27 +26027,27 @@ func (c *RegionUrlMapsPatchCall) RequestId(requestId string) *RegionUrlMapsPatch // Fields allows partial responses to be retrieved. See // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more // details. -func (c *RegionUrlMapsPatchCall) Fields(s ...googleapi.Field) *RegionUrlMapsPatchCall { +func (c *RegionUrlMapsUpdateCall) Fields(s ...googleapi.Field) *RegionUrlMapsUpdateCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } // Context sets the context to be used in this call's Do method. -func (c *RegionUrlMapsPatchCall) Context(ctx context.Context) *RegionUrlMapsPatchCall { +func (c *RegionUrlMapsUpdateCall) Context(ctx context.Context) *RegionUrlMapsUpdateCall { 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 *RegionUrlMapsPatchCall) Header() http.Header { +func (c *RegionUrlMapsUpdateCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *RegionUrlMapsPatchCall) doRequest(alt string) (*http.Response, error) { +func (c *RegionUrlMapsUpdateCall) 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.urlmap) @@ -27192,7 +26058,7 @@ func (c *RegionUrlMapsPatchCall) doRequest(alt string) (*http.Response, error) { c.urlParams_.Set("prettyPrint", "false") urls := googleapi.ResolveRelative(c.s.BasePath, "projects/{project}/regions/{region}/urlMaps/{urlMap}") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("PATCH", urls, body) + req, err := http.NewRequest("PUT", urls, body) if err != nil { return nil, err } @@ -27205,12 +26071,12 @@ func (c *RegionUrlMapsPatchCall) doRequest(alt string) (*http.Response, error) { return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "compute.regionUrlMaps.patch" call. +// Do executes the "compute.regionUrlMaps.update" 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 *RegionUrlMapsPatchCall) Do(opts ...googleapi.CallOption) (*Operation, error) { +func (c *RegionUrlMapsUpdateCall) Do(opts ...googleapi.CallOption) (*Operation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -27242,65 +26108,66 @@ func (c *RegionUrlMapsPatchCall) Do(opts ...googleapi.CallOption) (*Operation, e return ret, nil } -type RegionUrlMapsTestIamPermissionsCall struct { - s *Service - project string - region string - resource string - testpermissionsrequest *TestPermissionsRequest - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +type RegionUrlMapsValidateCall struct { + s *Service + project string + region string + urlMap string + regionurlmapsvalidaterequest *RegionUrlMapsValidateRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// TestIamPermissions: Returns permissions that a caller has on the specified -// resource. +// Validate: Runs static validation for the UrlMap. In particular, the tests of +// the provided UrlMap will be run. Calling this method does NOT create the +// UrlMap. // // - project: Project ID for this request. -// - region: The name of the region for this request. -// - resource: Name or id of the resource for this request. -func (r *RegionUrlMapsService) TestIamPermissions(project string, region string, resource string, testpermissionsrequest *TestPermissionsRequest) *RegionUrlMapsTestIamPermissionsCall { - c := &RegionUrlMapsTestIamPermissionsCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// - region: Name of the region scoping this request. +// - urlMap: Name of the UrlMap resource to be validated as. +func (r *RegionUrlMapsService) Validate(project string, region string, urlMap string, regionurlmapsvalidaterequest *RegionUrlMapsValidateRequest) *RegionUrlMapsValidateCall { + c := &RegionUrlMapsValidateCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.project = project c.region = region - c.resource = resource - c.testpermissionsrequest = testpermissionsrequest + c.urlMap = urlMap + c.regionurlmapsvalidaterequest = regionurlmapsvalidaterequest 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 *RegionUrlMapsTestIamPermissionsCall) Fields(s ...googleapi.Field) *RegionUrlMapsTestIamPermissionsCall { +func (c *RegionUrlMapsValidateCall) Fields(s ...googleapi.Field) *RegionUrlMapsValidateCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } // Context sets the context to be used in this call's Do method. -func (c *RegionUrlMapsTestIamPermissionsCall) Context(ctx context.Context) *RegionUrlMapsTestIamPermissionsCall { +func (c *RegionUrlMapsValidateCall) Context(ctx context.Context) *RegionUrlMapsValidateCall { 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 *RegionUrlMapsTestIamPermissionsCall) Header() http.Header { +func (c *RegionUrlMapsValidateCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *RegionUrlMapsTestIamPermissionsCall) doRequest(alt string) (*http.Response, error) { +func (c *RegionUrlMapsValidateCall) 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.testpermissionsrequest) + body, err := googleapi.WithoutDataWrapper.JSONReader(c.regionurlmapsvalidaterequest) if err != nil { return nil, err } c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "projects/{project}/regions/{region}/urlMaps/{resource}/testIamPermissions") + urls := googleapi.ResolveRelative(c.s.BasePath, "projects/{project}/regions/{region}/urlMaps/{urlMap}/validate") urls += "?" + c.urlParams_.Encode() req, err := http.NewRequest("POST", urls, body) if err != nil { @@ -27308,20 +26175,20 @@ func (c *RegionUrlMapsTestIamPermissionsCall) doRequest(alt string) (*http.Respo } req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ - "project": c.project, - "region": c.region, - "resource": c.resource, + "project": c.project, + "region": c.region, + "urlMap": c.urlMap, }) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "compute.regionUrlMaps.testIamPermissions" call. +// Do executes the "compute.regionUrlMaps.validate" call. // Any non-2xx status code is an error. Response headers are in either -// *TestPermissionsResponse.ServerResponse.Header or (if a response was +// *UrlMapsValidateResponse.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 *RegionUrlMapsTestIamPermissionsCall) Do(opts ...googleapi.CallOption) (*TestPermissionsResponse, error) { +func (c *RegionUrlMapsValidateCall) Do(opts ...googleapi.CallOption) (*UrlMapsValidateResponse, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -27340,7 +26207,7 @@ func (c *RegionUrlMapsTestIamPermissionsCall) Do(opts ...googleapi.CallOption) ( if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &TestPermissionsResponse{ + ret := &UrlMapsValidateResponse{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -27353,74 +26220,148 @@ func (c *RegionUrlMapsTestIamPermissionsCall) Do(opts ...googleapi.CallOption) ( return ret, nil } -type RegionUrlMapsUpdateCall struct { - s *Service - project string - region string - urlMap string - urlmap *UrlMap - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +type RegionZonesListCall struct { + s *Service + project string + region string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header } -// Update: Updates the specified UrlMap resource with the data included in the -// request. +// List: Retrieves the list of Zone resources under the specific region +// available to the specified project. // // - project: Project ID for this request. -// - region: Name of the region scoping this request. -// - urlMap: Name of the UrlMap resource to update. -func (r *RegionUrlMapsService) Update(project string, region string, urlMap string, urlmap *UrlMap) *RegionUrlMapsUpdateCall { - c := &RegionUrlMapsUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// - region: Region for this request. +func (r *RegionZonesService) List(project string, region string) *RegionZonesListCall { + c := &RegionZonesListCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.project = project c.region = region - c.urlMap = urlMap - c.urlmap = urlmap return c } -// RequestId sets the optional parameter "requestId": begin_interface: -// MixerMutationRequestBuilder Request ID to support idempotency. -func (c *RegionUrlMapsUpdateCall) RequestId(requestId string) *RegionUrlMapsUpdateCall { - c.urlParams_.Set("requestId", requestId) +// Filter sets the optional parameter "filter": A filter expression that +// filters resources listed in the response. Most Compute resources support two +// types of filter expressions: expressions that support regular expressions +// and expressions that follow API improvement proposal AIP-160. These two +// types of filter expressions cannot be mixed in one request. If you want to +// use AIP-160, your expression must specify the field name, an operator, and +// the value that you want to use for filtering. The value must be a string, a +// number, or a boolean. The operator must be either `=`, `!=`, `>`, `<`, `<=`, +// `>=` or `:`. For example, if you are filtering Compute Engine instances, you +// can exclude instances named `example-instance` by specifying `name != +// example-instance`. The `:*` comparison can be used to test whether a key has +// been defined. For example, to find all objects with `owner` label use: ``` +// labels.owner:* ``` You can also filter nested fields. For example, you could +// specify `scheduling.automaticRestart = false` to include instances only if +// they are not scheduled for automatic restarts. You can use filtering on +// nested fields to filter based on resource labels. To filter on multiple +// expressions, provide each separate expression within parentheses. For +// example: ``` (scheduling.automaticRestart = true) (cpuPlatform = "Intel +// Skylake") ``` By default, each expression is an `AND` expression. However, +// you can include `AND` and `OR` expressions explicitly. For example: ``` +// (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND +// (scheduling.automaticRestart = true) ``` If you want to use a regular +// expression, use the `eq` (equal) or `ne` (not equal) operator against a +// single un-parenthesized expression with or without quotes or against +// multiple parenthesized expressions. Examples: `fieldname eq unquoted +// literal` `fieldname eq 'single quoted literal'` `fieldname eq "double quoted +// literal" `(fieldname1 eq literal) (fieldname2 ne "literal")` The literal +// value is interpreted as a regular expression using Google RE2 library +// syntax. The literal value must match the entire field. For example, to +// filter for instances that do not end with name "instance", you would use +// `name ne .*instance`. You cannot combine constraints on multiple fields +// using regular expressions. +func (c *RegionZonesListCall) Filter(filter string) *RegionZonesListCall { + c.urlParams_.Set("filter", filter) + return c +} + +// MaxResults sets the optional parameter "maxResults": The maximum number of +// results per page that should be returned. If the number of available results +// is larger than `maxResults`, Compute Engine returns a `nextPageToken` that +// can be used to get the next page of results in subsequent list requests. +// Acceptable values are `0` to `500`, inclusive. (Default: `500`) +func (c *RegionZonesListCall) MaxResults(maxResults int64) *RegionZonesListCall { + c.urlParams_.Set("maxResults", fmt.Sprint(maxResults)) + return c +} + +// OrderBy sets the optional parameter "orderBy": Sorts list results by a +// certain order. By default, results are returned in alphanumerical order +// based on the resource name. You can also sort results in descending order +// based on the creation timestamp using `orderBy="creationTimestamp desc". +// This sorts results based on the `creationTimestamp` field in reverse +// chronological order (newest result first). Use this to sort resources like +// operations so that the newest operation is returned first. Currently, only +// sorting by `name` or `creationTimestamp desc` is supported. +func (c *RegionZonesListCall) OrderBy(orderBy string) *RegionZonesListCall { + c.urlParams_.Set("orderBy", orderBy) + return c +} + +// PageToken sets the optional parameter "pageToken": Specifies a page token to +// use. Set `pageToken` to the `nextPageToken` returned by a previous list +// request to get the next page of results. +func (c *RegionZonesListCall) PageToken(pageToken string) *RegionZonesListCall { + c.urlParams_.Set("pageToken", pageToken) + return c +} + +// ReturnPartialSuccess sets the optional parameter "returnPartialSuccess": +// Opt-in for partial success behavior which provides partial results in case +// of failure. The default value is false. For example, when partial success +// behavior is enabled, aggregatedList for a single zone scope either returns +// all resources in the zone or no resources, with an error code. +func (c *RegionZonesListCall) ReturnPartialSuccess(returnPartialSuccess bool) *RegionZonesListCall { + c.urlParams_.Set("returnPartialSuccess", fmt.Sprint(returnPartialSuccess)) 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 *RegionUrlMapsUpdateCall) Fields(s ...googleapi.Field) *RegionUrlMapsUpdateCall { +func (c *RegionZonesListCall) Fields(s ...googleapi.Field) *RegionZonesListCall { 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 *RegionZonesListCall) IfNoneMatch(entityTag string) *RegionZonesListCall { + c.ifNoneMatch_ = entityTag + return c +} + // Context sets the context to be used in this call's Do method. -func (c *RegionUrlMapsUpdateCall) Context(ctx context.Context) *RegionUrlMapsUpdateCall { +func (c *RegionZonesListCall) Context(ctx context.Context) *RegionZonesListCall { 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 *RegionUrlMapsUpdateCall) Header() http.Header { +func (c *RegionZonesListCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *RegionUrlMapsUpdateCall) 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.urlmap) - if err != nil { - return nil, err +func (c *RegionZonesListCall) 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, "projects/{project}/regions/{region}/urlMaps/{urlMap}") + urls := googleapi.ResolveRelative(c.s.BasePath, "projects/{project}/regions/{region}/zones") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("PUT", urls, body) + req, err := http.NewRequest("GET", urls, body) if err != nil { return nil, err } @@ -27428,17 +26369,16 @@ func (c *RegionUrlMapsUpdateCall) doRequest(alt string) (*http.Response, error) googleapi.Expand(req.URL, map[string]string{ "project": c.project, "region": c.region, - "urlMap": c.urlMap, }) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "compute.regionUrlMaps.update" call. +// Do executes the "compute.regionZones.list" 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 +// *ZoneList.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 *RegionUrlMapsUpdateCall) Do(opts ...googleapi.CallOption) (*Operation, error) { +func (c *RegionZonesListCall) Do(opts ...googleapi.CallOption) (*ZoneList, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -27457,7 +26397,7 @@ func (c *RegionUrlMapsUpdateCall) Do(opts ...googleapi.CallOption) (*Operation, if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &Operation{ + ret := &ZoneList{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -27467,71 +26407,105 @@ func (c *RegionUrlMapsUpdateCall) Do(opts ...googleapi.CallOption) (*Operation, if err := gensupport.DecodeResponse(target, res); err != nil { return nil, err } - return ret, nil + 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 *RegionZonesListCall) Pages(ctx context.Context, f func(*ZoneList) 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 RegionUrlMapsValidateCall struct { - s *Service - project string - region string - urlMap string - regionurlmapsvalidaterequest *RegionUrlMapsValidateRequest - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +type RegionsGetCall struct { + s *Service + project string + region string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header } -// Validate: Runs static validation for the UrlMap. In particular, the tests of -// the provided UrlMap will be run. Calling this method does NOT create the -// UrlMap. +// Get: Returns the specified Region resource. 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 `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. // // - project: Project ID for this request. -// - region: Name of the region scoping this request. -// - urlMap: Name of the UrlMap resource to be validated as. -func (r *RegionUrlMapsService) Validate(project string, region string, urlMap string, regionurlmapsvalidaterequest *RegionUrlMapsValidateRequest) *RegionUrlMapsValidateCall { - c := &RegionUrlMapsValidateCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// - region: Name of the region resource to return. +func (r *RegionsService) Get(project string, region string) *RegionsGetCall { + c := &RegionsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.project = project c.region = region - c.urlMap = urlMap - c.regionurlmapsvalidaterequest = regionurlmapsvalidaterequest 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 *RegionUrlMapsValidateCall) Fields(s ...googleapi.Field) *RegionUrlMapsValidateCall { +func (c *RegionsGetCall) Fields(s ...googleapi.Field) *RegionsGetCall { 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 *RegionsGetCall) IfNoneMatch(entityTag string) *RegionsGetCall { + c.ifNoneMatch_ = entityTag + return c +} + // Context sets the context to be used in this call's Do method. -func (c *RegionUrlMapsValidateCall) Context(ctx context.Context) *RegionUrlMapsValidateCall { +func (c *RegionsGetCall) Context(ctx context.Context) *RegionsGetCall { 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 *RegionUrlMapsValidateCall) Header() http.Header { +func (c *RegionsGetCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *RegionUrlMapsValidateCall) 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.regionurlmapsvalidaterequest) - if err != nil { - return nil, err +func (c *RegionsGetCall) 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, "projects/{project}/regions/{region}/urlMaps/{urlMap}/validate") + urls := googleapi.ResolveRelative(c.s.BasePath, "projects/{project}/regions/{region}") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("POST", urls, body) + req, err := http.NewRequest("GET", urls, body) if err != nil { return nil, err } @@ -27539,18 +26513,16 @@ func (c *RegionUrlMapsValidateCall) doRequest(alt string) (*http.Response, error googleapi.Expand(req.URL, map[string]string{ "project": c.project, "region": c.region, - "urlMap": c.urlMap, }) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "compute.regionUrlMaps.validate" call. +// Do executes the "compute.regions.get" call. // Any non-2xx status code is an error. Response headers are in either -// *UrlMapsValidateResponse.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 *RegionUrlMapsValidateCall) Do(opts ...googleapi.CallOption) (*UrlMapsValidateResponse, error) { +// *Region.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 *RegionsGetCall) Do(opts ...googleapi.CallOption) (*Region, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -27569,7 +26541,7 @@ func (c *RegionUrlMapsValidateCall) Do(opts ...googleapi.CallOption) (*UrlMapsVa if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &UrlMapsValidateResponse{ + ret := &Region{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -27582,25 +26554,34 @@ func (c *RegionUrlMapsValidateCall) Do(opts ...googleapi.CallOption) (*UrlMapsVa return ret, nil } -type RegionZonesListCall struct { +type RegionsListCall struct { s *Service project string - region string urlParams_ gensupport.URLParams ifNoneMatch_ string ctx_ context.Context header_ http.Header } -// List: Retrieves the list of Zone resources under the specific region -// available to the specified project. +// List: 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. // // - project: Project ID for this request. -// - region: Region for this request. -func (r *RegionZonesService) List(project string, region string) *RegionZonesListCall { - c := &RegionZonesListCall{s: r.s, urlParams_: make(gensupport.URLParams)} +func (r *RegionsService) List(project string) *RegionsListCall { + c := &RegionsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.project = project - c.region = region return c } @@ -27636,7 +26617,7 @@ func (r *RegionZonesService) List(project string, region string) *RegionZonesLis // filter for instances that do not end with name "instance", you would use // `name ne .*instance`. You cannot combine constraints on multiple fields // using regular expressions. -func (c *RegionZonesListCall) Filter(filter string) *RegionZonesListCall { +func (c *RegionsListCall) Filter(filter string) *RegionsListCall { c.urlParams_.Set("filter", filter) return c } @@ -27646,7 +26627,7 @@ func (c *RegionZonesListCall) Filter(filter string) *RegionZonesListCall { // is larger than `maxResults`, Compute Engine returns a `nextPageToken` that // can be used to get the next page of results in subsequent list requests. // Acceptable values are `0` to `500`, inclusive. (Default: `500`) -func (c *RegionZonesListCall) MaxResults(maxResults int64) *RegionZonesListCall { +func (c *RegionsListCall) MaxResults(maxResults int64) *RegionsListCall { c.urlParams_.Set("maxResults", fmt.Sprint(maxResults)) return c } @@ -27659,7 +26640,7 @@ func (c *RegionZonesListCall) MaxResults(maxResults int64) *RegionZonesListCall // chronological order (newest result first). Use this to sort resources like // operations so that the newest operation is returned first. Currently, only // sorting by `name` or `creationTimestamp desc` is supported. -func (c *RegionZonesListCall) OrderBy(orderBy string) *RegionZonesListCall { +func (c *RegionsListCall) OrderBy(orderBy string) *RegionsListCall { c.urlParams_.Set("orderBy", orderBy) return c } @@ -27667,7 +26648,7 @@ func (c *RegionZonesListCall) OrderBy(orderBy string) *RegionZonesListCall { // PageToken sets the optional parameter "pageToken": Specifies a page token to // use. Set `pageToken` to the `nextPageToken` returned by a previous list // request to get the next page of results. -func (c *RegionZonesListCall) PageToken(pageToken string) *RegionZonesListCall { +func (c *RegionsListCall) PageToken(pageToken string) *RegionsListCall { c.urlParams_.Set("pageToken", pageToken) return c } @@ -27677,7 +26658,7 @@ func (c *RegionZonesListCall) PageToken(pageToken string) *RegionZonesListCall { // of failure. The default value is false. For example, when partial success // behavior is enabled, aggregatedList for a single zone scope either returns // all resources in the zone or no resources, with an error code. -func (c *RegionZonesListCall) ReturnPartialSuccess(returnPartialSuccess bool) *RegionZonesListCall { +func (c *RegionsListCall) ReturnPartialSuccess(returnPartialSuccess bool) *RegionsListCall { c.urlParams_.Set("returnPartialSuccess", fmt.Sprint(returnPartialSuccess)) return c } @@ -27685,7 +26666,7 @@ func (c *RegionZonesListCall) ReturnPartialSuccess(returnPartialSuccess bool) *R // Fields allows partial responses to be retrieved. See // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more // details. -func (c *RegionZonesListCall) Fields(s ...googleapi.Field) *RegionZonesListCall { +func (c *RegionsListCall) Fields(s ...googleapi.Field) *RegionsListCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } @@ -27693,27 +26674,27 @@ func (c *RegionZonesListCall) Fields(s ...googleapi.Field) *RegionZonesListCall // 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 *RegionZonesListCall) IfNoneMatch(entityTag string) *RegionZonesListCall { +func (c *RegionsListCall) IfNoneMatch(entityTag string) *RegionsListCall { c.ifNoneMatch_ = entityTag return c } // Context sets the context to be used in this call's Do method. -func (c *RegionZonesListCall) Context(ctx context.Context) *RegionZonesListCall { +func (c *RegionsListCall) Context(ctx context.Context) *RegionsListCall { 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 *RegionZonesListCall) Header() http.Header { +func (c *RegionsListCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *RegionZonesListCall) doRequest(alt string) (*http.Response, error) { +func (c *RegionsListCall) doRequest(alt string) (*http.Response, error) { reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) if c.ifNoneMatch_ != "" { reqHeaders.Set("If-None-Match", c.ifNoneMatch_) @@ -27721,7 +26702,7 @@ func (c *RegionZonesListCall) doRequest(alt string) (*http.Response, error) { var body io.Reader = nil c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "projects/{project}/regions/{region}/zones") + urls := googleapi.ResolveRelative(c.s.BasePath, "projects/{project}/regions") urls += "?" + c.urlParams_.Encode() req, err := http.NewRequest("GET", urls, body) if err != nil { @@ -27730,17 +26711,16 @@ func (c *RegionZonesListCall) doRequest(alt string) (*http.Response, error) { req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ "project": c.project, - "region": c.region, }) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "compute.regionZones.list" call. +// Do executes the "compute.regions.list" call. // Any non-2xx status code is an error. Response headers are in either -// *ZoneList.ServerResponse.Header or (if a response was returned at all) in +// *RegionList.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 *RegionZonesListCall) Do(opts ...googleapi.CallOption) (*ZoneList, error) { +func (c *RegionsListCall) Do(opts ...googleapi.CallOption) (*RegionList, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -27759,7 +26739,7 @@ func (c *RegionZonesListCall) Do(opts ...googleapi.CallOption) (*ZoneList, error if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &ZoneList{ + ret := &RegionList{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -27775,7 +26755,7 @@ func (c *RegionZonesListCall) Do(opts ...googleapi.CallOption) (*ZoneList, error // 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 *RegionZonesListCall) Pages(ctx context.Context, f func(*ZoneList) error) error { +func (c *RegionsListCall) Pages(ctx context.Context, f func(*RegionList) error) error { c.ctx_ = ctx defer c.PageToken(c.urlParams_.Get("pageToken")) for { @@ -27793,43 +26773,40 @@ func (c *RegionZonesListCall) Pages(ctx context.Context, f func(*ZoneList) error } } -type RegionsGetCall struct { - s *Service - project string - region string - urlParams_ gensupport.URLParams - ifNoneMatch_ string - ctx_ context.Context - header_ http.Header +type ReservationBlocksGetCall struct { + s *Service + project string + zone string + reservation string + reservationBlock string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header } -// Get: Returns the specified Region resource. 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 `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. +// Get: Retrieves information about the specified reservation block. // -// - project: Project ID for this request. -// - region: Name of the region resource to return. -func (r *RegionsService) Get(project string, region string) *RegionsGetCall { - c := &RegionsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// - project: Project ID for this request. +// - reservation: The name of the reservation. Name should conform to RFC1035 +// or be a resource ID. +// - reservationBlock: The name of the reservation block. Name should conform +// to RFC1035 or be a resource ID. +// - zone: Name of the zone for this request. Zone name should conform to +// RFC1035. +func (r *ReservationBlocksService) Get(project string, zone string, reservation string, reservationBlock string) *ReservationBlocksGetCall { + c := &ReservationBlocksGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.project = project - c.region = region + c.zone = zone + c.reservation = reservation + c.reservationBlock = reservationBlock 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 *RegionsGetCall) Fields(s ...googleapi.Field) *RegionsGetCall { +func (c *ReservationBlocksGetCall) Fields(s ...googleapi.Field) *ReservationBlocksGetCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } @@ -27837,27 +26814,27 @@ func (c *RegionsGetCall) Fields(s ...googleapi.Field) *RegionsGetCall { // 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 *RegionsGetCall) IfNoneMatch(entityTag string) *RegionsGetCall { +func (c *ReservationBlocksGetCall) IfNoneMatch(entityTag string) *ReservationBlocksGetCall { c.ifNoneMatch_ = entityTag return c } // Context sets the context to be used in this call's Do method. -func (c *RegionsGetCall) Context(ctx context.Context) *RegionsGetCall { +func (c *ReservationBlocksGetCall) Context(ctx context.Context) *ReservationBlocksGetCall { 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 *RegionsGetCall) Header() http.Header { +func (c *ReservationBlocksGetCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *RegionsGetCall) doRequest(alt string) (*http.Response, error) { +func (c *ReservationBlocksGetCall) doRequest(alt string) (*http.Response, error) { reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) if c.ifNoneMatch_ != "" { reqHeaders.Set("If-None-Match", c.ifNoneMatch_) @@ -27865,7 +26842,7 @@ func (c *RegionsGetCall) doRequest(alt string) (*http.Response, error) { var body io.Reader = nil c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "projects/{project}/regions/{region}") + urls := googleapi.ResolveRelative(c.s.BasePath, "projects/{project}/zones/{zone}/reservations/{reservation}/reservationBlocks/{reservationBlock}") urls += "?" + c.urlParams_.Encode() req, err := http.NewRequest("GET", urls, body) if err != nil { @@ -27873,18 +26850,21 @@ func (c *RegionsGetCall) doRequest(alt string) (*http.Response, error) { } req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ - "project": c.project, - "region": c.region, + "project": c.project, + "zone": c.zone, + "reservation": c.reservation, + "reservationBlock": c.reservationBlock, }) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "compute.regions.get" call. +// Do executes the "compute.reservationBlocks.get" call. // Any non-2xx status code is an error. Response headers are in either -// *Region.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 *RegionsGetCall) Do(opts ...googleapi.CallOption) (*Region, error) { +// *ReservationBlocksGetResponse.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 *ReservationBlocksGetCall) Do(opts ...googleapi.CallOption) (*ReservationBlocksGetResponse, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -27903,7 +26883,7 @@ func (c *RegionsGetCall) Do(opts ...googleapi.CallOption) (*Region, error) { if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &Region{ + ret := &ReservationBlocksGetResponse{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -27916,34 +26896,29 @@ func (c *RegionsGetCall) Do(opts ...googleapi.CallOption) (*Region, error) { return ret, nil } -type RegionsListCall struct { +type ReservationBlocksListCall struct { s *Service project string + zone string + reservation string urlParams_ gensupport.URLParams ifNoneMatch_ string ctx_ context.Context header_ http.Header } -// List: 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. +// List: Retrieves a list of reservation blocks under a single reservation. // -// - project: Project ID for this request. -func (r *RegionsService) List(project string) *RegionsListCall { - c := &RegionsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// - project: Project ID for this request. +// - reservation: The name of the reservation. Name should conform to RFC1035 +// or be a resource ID. +// - zone: Name of the zone for this request. Zone name should conform to +// RFC1035. +func (r *ReservationBlocksService) List(project string, zone string, reservation string) *ReservationBlocksListCall { + c := &ReservationBlocksListCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.project = project + c.zone = zone + c.reservation = reservation return c } @@ -27979,7 +26954,7 @@ func (r *RegionsService) List(project string) *RegionsListCall { // filter for instances that do not end with name "instance", you would use // `name ne .*instance`. You cannot combine constraints on multiple fields // using regular expressions. -func (c *RegionsListCall) Filter(filter string) *RegionsListCall { +func (c *ReservationBlocksListCall) Filter(filter string) *ReservationBlocksListCall { c.urlParams_.Set("filter", filter) return c } @@ -27989,7 +26964,7 @@ func (c *RegionsListCall) Filter(filter string) *RegionsListCall { // is larger than `maxResults`, Compute Engine returns a `nextPageToken` that // can be used to get the next page of results in subsequent list requests. // Acceptable values are `0` to `500`, inclusive. (Default: `500`) -func (c *RegionsListCall) MaxResults(maxResults int64) *RegionsListCall { +func (c *ReservationBlocksListCall) MaxResults(maxResults int64) *ReservationBlocksListCall { c.urlParams_.Set("maxResults", fmt.Sprint(maxResults)) return c } @@ -28002,7 +26977,7 @@ func (c *RegionsListCall) MaxResults(maxResults int64) *RegionsListCall { // chronological order (newest result first). Use this to sort resources like // operations so that the newest operation is returned first. Currently, only // sorting by `name` or `creationTimestamp desc` is supported. -func (c *RegionsListCall) OrderBy(orderBy string) *RegionsListCall { +func (c *ReservationBlocksListCall) OrderBy(orderBy string) *ReservationBlocksListCall { c.urlParams_.Set("orderBy", orderBy) return c } @@ -28010,7 +26985,7 @@ func (c *RegionsListCall) OrderBy(orderBy string) *RegionsListCall { // PageToken sets the optional parameter "pageToken": Specifies a page token to // use. Set `pageToken` to the `nextPageToken` returned by a previous list // request to get the next page of results. -func (c *RegionsListCall) PageToken(pageToken string) *RegionsListCall { +func (c *ReservationBlocksListCall) PageToken(pageToken string) *ReservationBlocksListCall { c.urlParams_.Set("pageToken", pageToken) return c } @@ -28020,7 +26995,7 @@ func (c *RegionsListCall) PageToken(pageToken string) *RegionsListCall { // of failure. The default value is false. For example, when partial success // behavior is enabled, aggregatedList for a single zone scope either returns // all resources in the zone or no resources, with an error code. -func (c *RegionsListCall) ReturnPartialSuccess(returnPartialSuccess bool) *RegionsListCall { +func (c *ReservationBlocksListCall) ReturnPartialSuccess(returnPartialSuccess bool) *ReservationBlocksListCall { c.urlParams_.Set("returnPartialSuccess", fmt.Sprint(returnPartialSuccess)) return c } @@ -28028,7 +27003,7 @@ func (c *RegionsListCall) ReturnPartialSuccess(returnPartialSuccess bool) *Regio // Fields allows partial responses to be retrieved. See // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more // details. -func (c *RegionsListCall) Fields(s ...googleapi.Field) *RegionsListCall { +func (c *ReservationBlocksListCall) Fields(s ...googleapi.Field) *ReservationBlocksListCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } @@ -28036,27 +27011,27 @@ func (c *RegionsListCall) Fields(s ...googleapi.Field) *RegionsListCall { // 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 *RegionsListCall) IfNoneMatch(entityTag string) *RegionsListCall { +func (c *ReservationBlocksListCall) IfNoneMatch(entityTag string) *ReservationBlocksListCall { c.ifNoneMatch_ = entityTag return c } // Context sets the context to be used in this call's Do method. -func (c *RegionsListCall) Context(ctx context.Context) *RegionsListCall { +func (c *ReservationBlocksListCall) Context(ctx context.Context) *ReservationBlocksListCall { 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 *RegionsListCall) Header() http.Header { +func (c *ReservationBlocksListCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *RegionsListCall) doRequest(alt string) (*http.Response, error) { +func (c *ReservationBlocksListCall) doRequest(alt string) (*http.Response, error) { reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) if c.ifNoneMatch_ != "" { reqHeaders.Set("If-None-Match", c.ifNoneMatch_) @@ -28064,7 +27039,7 @@ func (c *RegionsListCall) doRequest(alt string) (*http.Response, error) { var body io.Reader = nil c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "projects/{project}/regions") + urls := googleapi.ResolveRelative(c.s.BasePath, "projects/{project}/zones/{zone}/reservations/{reservation}/reservationBlocks") urls += "?" + c.urlParams_.Encode() req, err := http.NewRequest("GET", urls, body) if err != nil { @@ -28072,17 +27047,20 @@ func (c *RegionsListCall) doRequest(alt string) (*http.Response, error) { } req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ - "project": c.project, + "project": c.project, + "zone": c.zone, + "reservation": c.reservation, }) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "compute.regions.list" call. +// Do executes the "compute.reservationBlocks.list" call. // Any non-2xx status code is an error. Response headers are in either -// *RegionList.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 *RegionsListCall) Do(opts ...googleapi.CallOption) (*RegionList, error) { +// *ReservationBlocksListResponse.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 *ReservationBlocksListCall) Do(opts ...googleapi.CallOption) (*ReservationBlocksListResponse, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -28101,7 +27079,7 @@ func (c *RegionsListCall) Do(opts ...googleapi.CallOption) (*RegionList, error) if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &RegionList{ + ret := &ReservationBlocksListResponse{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -28117,7 +27095,7 @@ func (c *RegionsListCall) Do(opts ...googleapi.CallOption) (*RegionList, error) // 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 *RegionsListCall) Pages(ctx context.Context, f func(*RegionList) error) error { +func (c *ReservationBlocksListCall) Pages(ctx context.Context, f func(*ReservationBlocksListResponse) error) error { c.ctx_ = ctx defer c.PageToken(c.urlParams_.Get("pageToken")) for { diff --git a/compute/v0.beta/compute-api.json b/compute/v0.beta/compute-api.json index b52338ecb6b..3e7b21b4ec5 100644 --- a/compute/v0.beta/compute-api.json +++ b/compute/v0.beta/compute-api.json @@ -41911,7 +41911,7 @@ } } }, - "revision": "20240820", + "revision": "20240827", "rootUrl": "https://compute.googleapis.com/", "schemas": { "AWSV4Signature": { @@ -78755,6 +78755,7 @@ "type": "string" }, "displayName": { + "deprecated": true, "description": "User-provided name of the organization security policy. The name should be unique in the organization in which the security policy is created. This should only be used when SecurityPolicyType is FIREWALL. The name must be 1-63 characters long, and comply with https://www.ietf.org/rfc/rfc1035.txt. Specifically, the name must be 1-63 characters long and match the regular expression `[a-z]([-a-z0-9]*[a-z0-9])?` which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash.", "pattern": "[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?", "type": "string" @@ -78803,6 +78804,7 @@ "type": "string" }, "ruleTupleCount": { + "deprecated": true, "description": "[Output Only] Total count of all security policy rule tuples. A security policy can not exceed a set number of tuples.", "format": "int32", "type": "integer" @@ -79057,6 +79059,7 @@ "type": "string" }, "displayName": { + "deprecated": true, "description": "[Output Only] The display name of the security policy of the association.", "type": "string" }, @@ -79287,6 +79290,7 @@ "type": "string" }, "direction": { + "deprecated": true, "description": "The direction in which this rule applies. This field may only be specified when versioned_expr is set to FIREWALL.", "enum": [ "EGRESS", @@ -79299,6 +79303,7 @@ "type": "string" }, "enableLogging": { + "deprecated": true, "description": "Denotes whether to enable logging for a particular rule. If logging is enabled, logs will be exported to the configured export destination in Stackdriver. Logs may be exported to BigQuery or Pub/Sub. Note: you cannot enable logging on \"goto_next\" rules. This field may only be specified when the versioned_expr is set to FIREWALL.", "type": "boolean" }, @@ -79346,11 +79351,13 @@ "type": "string" }, "ruleTupleCount": { + "deprecated": true, "description": "[Output Only] Calculation of the complexity of a single firewall security policy rule.", "format": "int32", "type": "integer" }, "targetResources": { + "deprecated": true, "description": "A list of network resource URLs to which this rule applies. This field allows you to control which network's VMs get this rule. If this field is left blank, all VMs within the organization will receive the rule. This field may only be specified when versioned_expr is set to FIREWALL.", "items": { "type": "string" @@ -79358,6 +79365,7 @@ "type": "array" }, "targetServiceAccounts": { + "deprecated": true, "description": "A list of service accounts indicating the sets of instances that are applied with this rule.", "items": { "type": "string" @@ -79429,6 +79437,7 @@ "id": "SecurityPolicyRuleMatcherConfig", "properties": { "destIpRanges": { + "deprecated": true, "description": "CIDR IP address range. This field may only be specified when versioned_expr is set to FIREWALL.", "items": { "type": "string" @@ -79436,6 +79445,7 @@ "type": "array" }, "layer4Configs": { + "deprecated": true, "description": "Pairs of IP protocols and ports that the rule should match. This field may only be specified when versioned_expr is set to FIREWALL.", "items": { "$ref": "SecurityPolicyRuleMatcherConfigLayer4Config" @@ -79456,10 +79466,12 @@ "id": "SecurityPolicyRuleMatcherConfigLayer4Config", "properties": { "ipProtocol": { + "deprecated": true, "description": "The IP protocol to which this rule applies. The protocol type is required when creating a firewall rule. This value can either be one of the following well known protocol strings (tcp, udp, icmp, esp, ah, ipip, sctp), or the IP protocol number.", "type": "string" }, "ports": { + "deprecated": true, "description": "An optional list of ports to which this rule applies. This field is only applicable for UDP or TCP protocol. Each entry must be either an integer or a range. If not specified, this rule applies to connections through any port. Example inputs include: [\"22\"], [\"80\",\"443\"], and [\"12345-12349\"]. This field may only be specified when versioned_expr is set to FIREWALL.", "items": { "type": "string" diff --git a/compute/v1/compute-api.json b/compute/v1/compute-api.json index 586d65607f9..70bd1cc810f 100644 --- a/compute/v1/compute-api.json +++ b/compute/v1/compute-api.json @@ -37779,7 +37779,7 @@ } } }, - "revision": "20240820", + "revision": "20240827", "rootUrl": "https://compute.googleapis.com/", "schemas": { "AWSV4Signature": { @@ -47969,6 +47969,7 @@ "SEV_LIVE_MIGRATABLE", "SEV_LIVE_MIGRATABLE_V2", "SEV_SNP_CAPABLE", + "TDX_CAPABLE", "UEFI_COMPATIBLE", "VIRTIO_SCSI_MULTIQUEUE", "WINDOWS" @@ -47985,6 +47986,7 @@ "", "", "", + "", "" ], "type": "string" @@ -60158,6 +60160,11 @@ "description": "Metadata defined as annotations on the network endpoint.", "type": "object" }, + "clientDestinationPort": { + "description": "Represents the port number to which PSC consumer sends packets. Only valid for network endpoint groups created with GCE_VM_IP_PORTMAP endpoint type.", + "format": "int32", + "type": "integer" + }, "fqdn": { "description": "Optional fully qualified domain name of network endpoint. This can only be specified when NetworkEndpointGroup.network_endpoint_type is NON_GCP_FQDN_PORT.", "type": "string" @@ -60237,6 +60244,7 @@ "enum": [ "GCE_VM_IP", "GCE_VM_IP_PORT", + "GCE_VM_IP_PORTMAP", "INTERNET_FQDN_PORT", "INTERNET_IP_PORT", "NON_GCP_PRIVATE_IP_PORT", @@ -60246,6 +60254,7 @@ "enumDescriptions": [ "The network endpoint is represented by an IP address.", "The network endpoint is represented by IP address and port pair.", + "The network endpoint is represented by an IP, Port and Client Destination Port.", "The network endpoint is represented by fully qualified domain name and port.", "The network endpoint is represented by an internet IP address and port.", "The network endpoint is represented by an IP address and port. The endpoint belongs to a VM or pod running in a customer's on-premises.", diff --git a/compute/v1/compute-gen.go b/compute/v1/compute-gen.go index 57c10750a53..ca8f1ffd01f 100644 --- a/compute/v1/compute-gen.go +++ b/compute/v1/compute-gen.go @@ -13285,6 +13285,7 @@ type GuestOsFeature struct { // "SEV_LIVE_MIGRATABLE" // "SEV_LIVE_MIGRATABLE_V2" // "SEV_SNP_CAPABLE" + // "TDX_CAPABLE" // "UEFI_COMPATIBLE" // "VIRTIO_SCSI_MULTIQUEUE" // "WINDOWS" @@ -27096,6 +27097,10 @@ func (s NetworkEdgeSecurityServicesScopedListWarningData) MarshalJSON() ([]byte, type NetworkEndpoint struct { // Annotations: Metadata defined as annotations on the network endpoint. Annotations map[string]string `json:"annotations,omitempty"` + // ClientDestinationPort: Represents the port number to which PSC consumer + // sends packets. Only valid for network endpoint groups created with + // GCE_VM_IP_PORTMAP endpoint type. + ClientDestinationPort int64 `json:"clientDestinationPort,omitempty"` // Fqdn: Optional fully qualified domain name of network endpoint. This can // only be specified when NetworkEndpointGroup.network_endpoint_type is // NON_GCP_FQDN_PORT. @@ -27192,6 +27197,8 @@ type NetworkEndpointGroup struct { // "GCE_VM_IP" - The network endpoint is represented by an IP address. // "GCE_VM_IP_PORT" - The network endpoint is represented by IP address and // port pair. + // "GCE_VM_IP_PORTMAP" - The network endpoint is represented by an IP, Port + // and Client Destination Port. // "INTERNET_FQDN_PORT" - The network endpoint is represented by fully // qualified domain name and port. // "INTERNET_IP_PORT" - The network endpoint is represented by an internet IP diff --git a/connectors/v1/connectors-api.json b/connectors/v1/connectors-api.json index 0a33fb67cd4..97be8fcdbcc 100644 --- a/connectors/v1/connectors-api.json +++ b/connectors/v1/connectors-api.json @@ -2288,6 +2288,46 @@ "resources": { "versions": { "methods": { + "fetchAuthSchema": { + "description": "fetch and return the list of auth config variables required to override the connection backend auth.", + "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/providers/{providersId}/connectors/{connectorsId}/versions/{versionsId}:fetchAuthSchema", + "httpMethod": "GET", + "id": "connectors.projects.locations.providers.connectors.versions.fetchAuthSchema", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Required. Parent resource of the Connector Version, of the form: `projects/*/locations/*/providers/*/connectors/*/versions/*`", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/providers/[^/]+/connectors/[^/]+/versions/[^/]+$", + "required": true, + "type": "string" + }, + "view": { + "description": "Optional. View of the AuthSchema. The default value is BASIC.", + "enum": [ + "AUTH_SCHEMA_VIEW_UNSPECIFIED", + "BASIC", + "JSON_SCHEMA" + ], + "enumDescriptions": [ + "Default value.", + "Basic view of the AuthSchema.", + "JSON schema view of the AuthSchema." + ], + "location": "query", + "type": "string" + } + }, + "path": "v1/{+name}:fetchAuthSchema", + "response": { + "$ref": "FetchAuthSchemaResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, "get": { "description": "Gets details of a single connector version.", "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/providers/{providersId}/connectors/{connectorsId}/versions/{versionsId}", @@ -2457,7 +2497,7 @@ } } }, - "revision": "20240822", + "revision": "20240904", "rootUrl": "https://connectors.googleapis.com/", "schemas": { "AuditConfig": { @@ -2532,7 +2572,8 @@ "OAUTH2_CLIENT_CREDENTIALS", "SSH_PUBLIC_KEY", "OAUTH2_AUTH_CODE_FLOW", - "GOOGLE_AUTHENTICATION" + "GOOGLE_AUTHENTICATION", + "OAUTH2_AUTH_CODE_FLOW_GOOGLE_MANAGED" ], "enumDescriptions": [ "Authentication type not specified.", @@ -2541,7 +2582,8 @@ "Oauth 2.0 Client Credentials Grant Authentication", "SSH Public Key Authentication", "Oauth 2.0 Authorization Code Flow", - "Google authentication" + "Google authentication", + "Oauth 2.0 Authorization Code Flow with Google Provided OAuth Client" ], "type": "string" }, @@ -2549,6 +2591,10 @@ "$ref": "Oauth2AuthCodeFlow", "description": "Oauth2AuthCodeFlow." }, + "oauth2AuthCodeFlowGoogleManaged": { + "$ref": "Oauth2AuthCodeFlowGoogleManaged", + "description": "Oauth2AuthCodeFlowGoogleManaged." + }, "oauth2ClientCredentials": { "$ref": "Oauth2ClientCredentials", "description": "Oauth2ClientCredentials." @@ -2585,7 +2631,8 @@ "OAUTH2_CLIENT_CREDENTIALS", "SSH_PUBLIC_KEY", "OAUTH2_AUTH_CODE_FLOW", - "GOOGLE_AUTHENTICATION" + "GOOGLE_AUTHENTICATION", + "OAUTH2_AUTH_CODE_FLOW_GOOGLE_MANAGED" ], "enumDescriptions": [ "Authentication type not specified.", @@ -2594,7 +2641,8 @@ "Oauth 2.0 Client Credentials Grant Authentication", "SSH Public Key Authentication", "Oauth 2.0 Authorization Code Flow", - "Google authentication" + "Google authentication", + "Oauth 2.0 Authorization Code Flow with Google Provided OAuth Client" ], "type": "string" }, @@ -2620,6 +2668,132 @@ }, "type": "object" }, + "AuthField": { + "description": "AuthField defines a field in an authentication type.", + "id": "AuthField", + "properties": { + "dataType": { + "description": "Data type of the field.", + "type": "string" + }, + "description": { + "description": "Description of the field.", + "type": "string" + }, + "key": { + "description": "Key of the field.", + "type": "string" + } + }, + "type": "object" + }, + "AuthObject": { + "description": "AuthObject defines a JSON schema of an authentication type.", + "id": "AuthObject", + "properties": { + "additionalProperties": { + "description": "Whether the object has additional properties.", + "type": "boolean" + }, + "authKey": { + "description": "Auth key of the object.", + "type": "string" + }, + "authType": { + "description": "Auth type of the object.", + "type": "string" + }, + "description": { + "description": "Description of the object.", + "type": "string" + }, + "isDefault": { + "description": "Whether the object is the default one.", + "type": "boolean" + }, + "properties": { + "additionalProperties": { + "$ref": "AuthProperty" + }, + "description": "Properties of the object.", + "type": "object" + }, + "type": { + "description": "Type of the object.", + "type": "string" + } + }, + "type": "object" + }, + "AuthProperty": { + "description": "AuthProperty defines a property of an authentication type.", + "id": "AuthProperty", + "properties": { + "description": { + "description": "Description of the property.", + "type": "string" + }, + "type": { + "description": "Type of the property.", + "type": "string" + } + }, + "type": "object" + }, + "AuthSchema": { + "description": "AuthSchema defines the schema of an authentication type.", + "id": "AuthSchema", + "properties": { + "authFields": { + "description": "List of AuthFields.", + "items": { + "$ref": "AuthField" + }, + "type": "array" + }, + "authKey": { + "description": "Auth key of the schema.", + "type": "string" + }, + "authType": { + "description": "Auth type of the schema.", + "enum": [ + "AUTH_TYPE_UNSPECIFIED", + "USER_PASSWORD", + "OAUTH2_JWT_BEARER", + "OAUTH2_CLIENT_CREDENTIALS", + "SSH_PUBLIC_KEY", + "OAUTH2_AUTH_CODE_FLOW", + "GOOGLE_AUTHENTICATION", + "OAUTH2_AUTH_CODE_FLOW_GOOGLE_MANAGED" + ], + "enumDescriptions": [ + "Authentication type not specified.", + "Username and Password Authentication.", + "JSON Web Token (JWT) Profile for Oauth 2.0 Authorization Grant based authentication", + "Oauth 2.0 Client Credentials Grant Authentication", + "SSH Public Key Authentication", + "Oauth 2.0 Authorization Code Flow", + "Google authentication", + "Oauth 2.0 Authorization Code Flow with Google Provided OAuth Client" + ], + "type": "string" + }, + "description": { + "description": "Description of the schema.", + "type": "string" + }, + "displayName": { + "description": "Display name of the schema.", + "type": "string" + }, + "isDefault": { + "description": "Whether the auth schema is the default one.", + "type": "boolean" + } + }, + "type": "object" + }, "AuthorizationCodeLink": { "description": "This configuration captures the details required to render an authorization link for the OAuth Authorization Code Flow.", "id": "AuthorizationCodeLink", @@ -2868,6 +3042,10 @@ "$ref": "AuthConfig", "description": "Optional. Configuration for establishing the connection's authentication with an external system." }, + "authOverrideEnabled": { + "description": "Optional. Auth override enabled for the connection. If Auth Override is enabled, Connection allows the backend service auth to be overridden in the entities/actions API.", + "type": "boolean" + }, "billingConfig": { "$ref": "BillingConfig", "description": "Output only. Billing config for the connection.", @@ -3309,6 +3487,10 @@ "description": "Indicate whether connector is being migrated to cloud run deployment model.", "type": "boolean" }, + "migrateTls": { + "description": "Indicate whether connector is being migrated to TLS.", + "type": "boolean" + }, "ratelimitThreshold": { "description": "Max QPS supported by the connector version before throttling of requests.", "format": "int64", @@ -3592,6 +3774,21 @@ "description": "Output only. The name of shared connector deployment.", "readOnly": true, "type": "string" + }, + "tlsMigrationState": { + "description": "Output only. Status of the TLS migration.", + "enum": [ + "TLS_MIGRATION_STATE_UNSPECIFIED", + "TLS_MIGRATION_NOT_STARTED", + "TLS_MIGRATION_COMPLETED" + ], + "enumDescriptions": [ + "TLS migration state is not specified.", + "TLS migration is in progress.", + "TLS migration is completed." + ], + "readOnly": true, + "type": "string" } }, "type": "object" @@ -4605,6 +4802,24 @@ }, "type": "object" }, + "FetchAuthSchemaResponse": { + "description": "Response message for Connectors.GetAuthSchema.", + "id": "FetchAuthSchemaResponse", + "properties": { + "authSchemas": { + "description": "List of AuthSchemas.", + "items": { + "$ref": "AuthSchema" + }, + "type": "array" + }, + "jsonSchema": { + "$ref": "JsonAuthSchema", + "description": "JSON schema of the AuthSchemas. This is only populated if the view is JSON_SCHEMA. The schema is in draft-07 format." + } + }, + "type": "object" + }, "Field": { "description": "Metadata of an entity field.", "id": "Field", @@ -5185,6 +5400,24 @@ }, "type": "object" }, + "JsonAuthSchema": { + "description": "JsonAuthSchema defines the JSON schema of all authentication types.", + "id": "JsonAuthSchema", + "properties": { + "$schema": { + "description": "JSON schema of the AuthSchemas.", + "type": "string" + }, + "oneOf": { + "description": "List of AuthObjects.", + "items": { + "$ref": "AuthObject" + }, + "type": "array" + } + }, + "type": "object" + }, "JsonSchema": { "description": "JsonSchema representation of schema metadata", "id": "JsonSchema", @@ -6180,6 +6413,28 @@ }, "type": "object" }, + "Oauth2AuthCodeFlowGoogleManaged": { + "description": "Parameters to support Oauth 2.0 Auth Code Grant Authentication using Google Provided OAuth Client. See https://tools.ietf.org/html/rfc6749#section-1.3.1 for more details.", + "id": "Oauth2AuthCodeFlowGoogleManaged", + "properties": { + "authCode": { + "description": "Optional. Authorization code to be exchanged for access and refresh tokens.", + "type": "string" + }, + "redirectUri": { + "description": "Optional. Redirect URI to be provided during the auth code exchange.", + "type": "string" + }, + "scopes": { + "description": "Required. Scopes the connection will request when the user performs the auth code flow.", + "items": { + "type": "string" + }, + "type": "array" + } + }, + "type": "object" + }, "Oauth2ClientCredentials": { "description": "Parameters to support Oauth 2.0 Client Credentials Grant Authentication. See https://tools.ietf.org/html/rfc6749#section-1.3.4 for more details.", "id": "Oauth2ClientCredentials", diff --git a/connectors/v1/connectors-gen.go b/connectors/v1/connectors-gen.go index d638a811167..08ef23a15dd 100644 --- a/connectors/v1/connectors-gen.go +++ b/connectors/v1/connectors-gen.go @@ -473,9 +473,13 @@ type AuthConfig struct { // "SSH_PUBLIC_KEY" - SSH Public Key Authentication // "OAUTH2_AUTH_CODE_FLOW" - Oauth 2.0 Authorization Code Flow // "GOOGLE_AUTHENTICATION" - Google authentication + // "OAUTH2_AUTH_CODE_FLOW_GOOGLE_MANAGED" - Oauth 2.0 Authorization Code Flow + // with Google Provided OAuth Client AuthType string `json:"authType,omitempty"` // Oauth2AuthCodeFlow: Oauth2AuthCodeFlow. Oauth2AuthCodeFlow *Oauth2AuthCodeFlow `json:"oauth2AuthCodeFlow,omitempty"` + // Oauth2AuthCodeFlowGoogleManaged: Oauth2AuthCodeFlowGoogleManaged. + Oauth2AuthCodeFlowGoogleManaged *Oauth2AuthCodeFlowGoogleManaged `json:"oauth2AuthCodeFlowGoogleManaged,omitempty"` // Oauth2ClientCredentials: Oauth2ClientCredentials. Oauth2ClientCredentials *Oauth2ClientCredentials `json:"oauth2ClientCredentials,omitempty"` // Oauth2JwtBearer: Oauth2JwtBearer. @@ -519,6 +523,8 @@ type AuthConfigTemplate struct { // "SSH_PUBLIC_KEY" - SSH Public Key Authentication // "OAUTH2_AUTH_CODE_FLOW" - Oauth 2.0 Authorization Code Flow // "GOOGLE_AUTHENTICATION" - Google authentication + // "OAUTH2_AUTH_CODE_FLOW_GOOGLE_MANAGED" - Oauth 2.0 Authorization Code Flow + // with Google Provided OAuth Client AuthType string `json:"authType,omitempty"` // ConfigVariableTemplates: Config variables to describe an `AuthConfig` for a // `Connection`. @@ -547,6 +553,135 @@ func (s AuthConfigTemplate) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// AuthField: AuthField defines a field in an authentication type. +type AuthField struct { + // DataType: Data type of the field. + DataType string `json:"dataType,omitempty"` + // Description: Description of the field. + Description string `json:"description,omitempty"` + // Key: Key of the field. + Key string `json:"key,omitempty"` + // ForceSendFields is a list of field names (e.g. "DataType") 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. "DataType") 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 AuthField) MarshalJSON() ([]byte, error) { + type NoMethod AuthField + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// AuthObject: AuthObject defines a JSON schema of an authentication type. +type AuthObject struct { + // AdditionalProperties: Whether the object has additional properties. + AdditionalProperties bool `json:"additionalProperties,omitempty"` + // AuthKey: Auth key of the object. + AuthKey string `json:"authKey,omitempty"` + // AuthType: Auth type of the object. + AuthType string `json:"authType,omitempty"` + // Description: Description of the object. + Description string `json:"description,omitempty"` + // IsDefault: Whether the object is the default one. + IsDefault bool `json:"isDefault,omitempty"` + // Properties: Properties of the object. + Properties map[string]AuthProperty `json:"properties,omitempty"` + // Type: Type of the object. + Type string `json:"type,omitempty"` + // ForceSendFields is a list of field names (e.g. "AdditionalProperties") 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. "AdditionalProperties") 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 AuthObject) MarshalJSON() ([]byte, error) { + type NoMethod AuthObject + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// AuthProperty: AuthProperty defines a property of an authentication type. +type AuthProperty struct { + // Description: Description of the property. + Description string `json:"description,omitempty"` + // Type: Type of the property. + Type string `json:"type,omitempty"` + // ForceSendFields is a list of field names (e.g. "Description") 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. "Description") 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 AuthProperty) MarshalJSON() ([]byte, error) { + type NoMethod AuthProperty + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// AuthSchema: AuthSchema defines the schema of an authentication type. +type AuthSchema struct { + // AuthFields: List of AuthFields. + AuthFields []*AuthField `json:"authFields,omitempty"` + // AuthKey: Auth key of the schema. + AuthKey string `json:"authKey,omitempty"` + // AuthType: Auth type of the schema. + // + // Possible values: + // "AUTH_TYPE_UNSPECIFIED" - Authentication type not specified. + // "USER_PASSWORD" - Username and Password Authentication. + // "OAUTH2_JWT_BEARER" - JSON Web Token (JWT) Profile for Oauth 2.0 + // Authorization Grant based authentication + // "OAUTH2_CLIENT_CREDENTIALS" - Oauth 2.0 Client Credentials Grant + // Authentication + // "SSH_PUBLIC_KEY" - SSH Public Key Authentication + // "OAUTH2_AUTH_CODE_FLOW" - Oauth 2.0 Authorization Code Flow + // "GOOGLE_AUTHENTICATION" - Google authentication + // "OAUTH2_AUTH_CODE_FLOW_GOOGLE_MANAGED" - Oauth 2.0 Authorization Code Flow + // with Google Provided OAuth Client + AuthType string `json:"authType,omitempty"` + // Description: Description of the schema. + Description string `json:"description,omitempty"` + // DisplayName: Display name of the schema. + DisplayName string `json:"displayName,omitempty"` + // IsDefault: Whether the auth schema is the default one. + IsDefault bool `json:"isDefault,omitempty"` + // ForceSendFields is a list of field names (e.g. "AuthFields") 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. "AuthFields") 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 AuthSchema) MarshalJSON() ([]byte, error) { + type NoMethod AuthSchema + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // AuthorizationCodeLink: This configuration captures the details required to // render an authorization link for the OAuth Authorization Code Flow. type AuthorizationCodeLink struct { @@ -839,6 +974,10 @@ type Connection struct { // AuthConfig: Optional. Configuration for establishing the connection's // authentication with an external system. AuthConfig *AuthConfig `json:"authConfig,omitempty"` + // AuthOverrideEnabled: Optional. Auth override enabled for the connection. If + // Auth Override is enabled, Connection allows the backend service auth to be + // overridden in the entities/actions API. + AuthOverrideEnabled bool `json:"authOverrideEnabled,omitempty"` // BillingConfig: Output only. Billing config for the connection. BillingConfig *BillingConfig `json:"billingConfig,omitempty"` // ConfigVariables: Optional. Configuration for configuring the connection with @@ -1146,6 +1285,8 @@ type ConnectorInfraConfig struct { // MigrateDeploymentModel: Indicate whether connector is being migrated to // cloud run deployment model. MigrateDeploymentModel bool `json:"migrateDeploymentModel,omitempty"` + // MigrateTls: Indicate whether connector is being migrated to TLS. + MigrateTls bool `json:"migrateTls,omitempty"` // RatelimitThreshold: Max QPS supported by the connector version before // throttling of requests. RatelimitThreshold int64 `json:"ratelimitThreshold,omitempty,string"` @@ -1320,6 +1461,13 @@ type ConnectorVersionInfraConfig struct { ResourceRequests *ResourceRequests `json:"resourceRequests,omitempty"` // SharedDeployment: Output only. The name of shared connector deployment. SharedDeployment string `json:"sharedDeployment,omitempty"` + // TlsMigrationState: Output only. Status of the TLS migration. + // + // Possible values: + // "TLS_MIGRATION_STATE_UNSPECIFIED" - TLS migration state is not specified. + // "TLS_MIGRATION_NOT_STARTED" - TLS migration is in progress. + // "TLS_MIGRATION_COMPLETED" - TLS migration is completed. + TlsMigrationState string `json:"tlsMigrationState,omitempty"` // ForceSendFields is a list of field names (e.g. // "ConnectionRatelimitWindowSeconds") to unconditionally include in API // requests. By default, fields with empty or default values are omitted from @@ -2389,6 +2537,34 @@ func (s ExtractionRules) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// FetchAuthSchemaResponse: Response message for Connectors.GetAuthSchema. +type FetchAuthSchemaResponse struct { + // AuthSchemas: List of AuthSchemas. + AuthSchemas []*AuthSchema `json:"authSchemas,omitempty"` + // JsonSchema: JSON schema of the AuthSchemas. This is only populated if the + // view is JSON_SCHEMA. The schema is in draft-07 format. + JsonSchema *JsonAuthSchema `json:"jsonSchema,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the server. + googleapi.ServerResponse `json:"-"` + // ForceSendFields is a list of field names (e.g. "AuthSchemas") 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. "AuthSchemas") 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 FetchAuthSchemaResponse) MarshalJSON() ([]byte, error) { + type NoMethod FetchAuthSchemaResponse + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // Field: Metadata of an entity field. type Field struct { // AdditionalDetails: The following map contains fields that are not explicitly @@ -2796,6 +2972,31 @@ func (s JMS) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// JsonAuthSchema: JsonAuthSchema defines the JSON schema of all authentication +// types. +type JsonAuthSchema struct { + // Schema: JSON schema of the AuthSchemas. + Schema string `json:"$schema,omitempty"` + // OneOf: List of AuthObjects. + OneOf []*AuthObject `json:"oneOf,omitempty"` + // ForceSendFields is a list of field names (e.g. "Schema") 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. "Schema") 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 JsonAuthSchema) MarshalJSON() ([]byte, error) { + type NoMethod JsonAuthSchema + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // JsonSchema: JsonSchema representation of schema metadata type JsonSchema struct { // Default: The default value of the field or object described by this schema. @@ -3889,6 +4090,37 @@ func (s Oauth2AuthCodeFlow) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// Oauth2AuthCodeFlowGoogleManaged: Parameters to support Oauth 2.0 Auth Code +// Grant Authentication using Google Provided OAuth Client. See +// https://tools.ietf.org/html/rfc6749#section-1.3.1 for more details. +type Oauth2AuthCodeFlowGoogleManaged struct { + // AuthCode: Optional. Authorization code to be exchanged for access and + // refresh tokens. + AuthCode string `json:"authCode,omitempty"` + // RedirectUri: Optional. Redirect URI to be provided during the auth code + // exchange. + RedirectUri string `json:"redirectUri,omitempty"` + // Scopes: Required. Scopes the connection will request when the user performs + // the auth code flow. + Scopes []string `json:"scopes,omitempty"` + // ForceSendFields is a list of field names (e.g. "AuthCode") 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. "AuthCode") 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 Oauth2AuthCodeFlowGoogleManaged) MarshalJSON() ([]byte, error) { + type NoMethod Oauth2AuthCodeFlowGoogleManaged + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // Oauth2ClientCredentials: Parameters to support Oauth 2.0 Client Credentials // Grant Authentication. See https://tools.ietf.org/html/rfc6749#section-1.3.4 // for more details. @@ -13060,6 +13292,129 @@ func (c *ProjectsLocationsProvidersConnectorsListCall) Pages(ctx context.Context } } +type ProjectsLocationsProvidersConnectorsVersionsFetchAuthSchemaCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// FetchAuthSchema: fetch and return the list of auth config variables required +// to override the connection backend auth. +// +// - name: Parent resource of the Connector Version, of the form: +// `projects/*/locations/*/providers/*/connectors/*/versions/*`. +func (r *ProjectsLocationsProvidersConnectorsVersionsService) FetchAuthSchema(name string) *ProjectsLocationsProvidersConnectorsVersionsFetchAuthSchemaCall { + c := &ProjectsLocationsProvidersConnectorsVersionsFetchAuthSchemaCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + return c +} + +// View sets the optional parameter "view": View of the AuthSchema. The default +// value is BASIC. +// +// Possible values: +// +// "AUTH_SCHEMA_VIEW_UNSPECIFIED" - Default value. +// "BASIC" - Basic view of the AuthSchema. +// "JSON_SCHEMA" - JSON schema view of the AuthSchema. +func (c *ProjectsLocationsProvidersConnectorsVersionsFetchAuthSchemaCall) View(view string) *ProjectsLocationsProvidersConnectorsVersionsFetchAuthSchemaCall { + c.urlParams_.Set("view", view) + 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 *ProjectsLocationsProvidersConnectorsVersionsFetchAuthSchemaCall) Fields(s ...googleapi.Field) *ProjectsLocationsProvidersConnectorsVersionsFetchAuthSchemaCall { + 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 *ProjectsLocationsProvidersConnectorsVersionsFetchAuthSchemaCall) IfNoneMatch(entityTag string) *ProjectsLocationsProvidersConnectorsVersionsFetchAuthSchemaCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsProvidersConnectorsVersionsFetchAuthSchemaCall) Context(ctx context.Context) *ProjectsLocationsProvidersConnectorsVersionsFetchAuthSchemaCall { + 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 *ProjectsLocationsProvidersConnectorsVersionsFetchAuthSchemaCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsProvidersConnectorsVersionsFetchAuthSchemaCall) 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}:fetchAuthSchema") + 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 "connectors.projects.locations.providers.connectors.versions.fetchAuthSchema" call. +// Any non-2xx status code is an error. Response headers are in either +// *FetchAuthSchemaResponse.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 *ProjectsLocationsProvidersConnectorsVersionsFetchAuthSchemaCall) Do(opts ...googleapi.CallOption) (*FetchAuthSchemaResponse, 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 := &FetchAuthSchemaResponse{ + 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 ProjectsLocationsProvidersConnectorsVersionsGetCall struct { s *Service name string diff --git a/contactcenteraiplatform/v1alpha1/contactcenteraiplatform-api.json b/contactcenteraiplatform/v1alpha1/contactcenteraiplatform-api.json index 37b901c6dbc..ac2e60fa84e 100644 --- a/contactcenteraiplatform/v1alpha1/contactcenteraiplatform-api.json +++ b/contactcenteraiplatform/v1alpha1/contactcenteraiplatform-api.json @@ -512,7 +512,7 @@ } } }, - "revision": "20240621", + "revision": "20240904", "rootUrl": "https://contactcenteraiplatform.googleapis.com/", "schemas": { "AdminUser": { @@ -703,7 +703,7 @@ "type": "object" }, "Critical": { - "description": "Instances in this Channel will receive updates after all instances in `Critical` were updated + 2 days. They also will only be updated outside of their peak hours.", + "description": "Instances in this Channel will receive updates after all instances in `Normal` were updated. They also will only be updated outside of their peak hours.", "id": "Critical", "properties": { "peakHours": { @@ -1034,6 +1034,14 @@ "type": "string" }, "type": "array" + }, + "producerProjectIds": { + "description": "Output only. The CCAIP tenant project ids.", + "items": { + "type": "string" + }, + "readOnly": true, + "type": "array" } }, "type": "object" diff --git a/contactcenteraiplatform/v1alpha1/contactcenteraiplatform-gen.go b/contactcenteraiplatform/v1alpha1/contactcenteraiplatform-gen.go index f8aeeb6d8df..63c793d6a6e 100644 --- a/contactcenteraiplatform/v1alpha1/contactcenteraiplatform-gen.go +++ b/contactcenteraiplatform/v1alpha1/contactcenteraiplatform-gen.go @@ -375,8 +375,8 @@ func (s ContactCenterQuota) MarshalJSON() ([]byte, error) { } // Critical: Instances in this Channel will receive updates after all instances -// in `Critical` were updated + 2 days. They also will only be updated outside -// of their peak hours. +// in `Normal` were updated. They also will only be updated outside of their +// peak hours. type Critical struct { // PeakHours: Required. Hours during which the instance should not be updated. PeakHours []*WeeklySchedule `json:"peakHours,omitempty"` @@ -741,6 +741,8 @@ type PscSetting struct { // traffic to the service attachment. This field should be filled only for the // ingress components. AllowedConsumerProjectIds []string `json:"allowedConsumerProjectIds,omitempty"` + // ProducerProjectIds: Output only. The CCAIP tenant project ids. + ProducerProjectIds []string `json:"producerProjectIds,omitempty"` // ForceSendFields is a list of field names (e.g. "AllowedConsumerProjectIds") // to unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See diff --git a/container/v1beta1/container-api.json b/container/v1beta1/container-api.json index 81fe160d960..6def6895561 100644 --- a/container/v1beta1/container-api.json +++ b/container/v1beta1/container-api.json @@ -14,7 +14,7 @@ "canonicalName": "Container", "description": "Builds and manages container-based applications, powered by the open source Kubernetes technology.", "discoveryVersion": "v1", - "documentationLink": "https://cloud.google.com/container-engine/", + "documentationLink": "https://cloud.google.com/kubernetes-engine/docs/", "fullyEncodeReservedExpansion": true, "icons": { "x16": "http://www.google.com/images/icons/product/search-16.gif", @@ -2565,7 +2565,7 @@ } } }, - "revision": "20240806", + "revision": "20240814", "rootUrl": "https://container.googleapis.com/", "schemas": { "AcceleratorConfig": { @@ -3740,6 +3740,10 @@ "$ref": "ClusterTelemetry", "description": "The desired telemetry integration for the cluster." }, + "desiredCompliancePostureConfig": { + "$ref": "CompliancePostureConfig", + "description": "Enable/Disable Compliance Posture features for the cluster." + }, "desiredContainerdConfig": { "$ref": "ContainerdConfig", "description": "The desired containerd config for the cluster." diff --git a/container/v1beta1/container-gen.go b/container/v1beta1/container-gen.go index 31ccc5355f0..3a48cce7d15 100644 --- a/container/v1beta1/container-gen.go +++ b/container/v1beta1/container-gen.go @@ -6,7 +6,7 @@ // Package container provides access to the Kubernetes Engine API. // -// For product documentation, see: https://cloud.google.com/container-engine/ +// For product documentation, see: https://cloud.google.com/kubernetes-engine/docs/ // // # Library status // @@ -1601,6 +1601,9 @@ type ClusterUpdate struct { DesiredClusterAutoscaling *ClusterAutoscaling `json:"desiredClusterAutoscaling,omitempty"` // DesiredClusterTelemetry: The desired telemetry integration for the cluster. DesiredClusterTelemetry *ClusterTelemetry `json:"desiredClusterTelemetry,omitempty"` + // DesiredCompliancePostureConfig: Enable/Disable Compliance Posture features + // for the cluster. + DesiredCompliancePostureConfig *CompliancePostureConfig `json:"desiredCompliancePostureConfig,omitempty"` // DesiredContainerdConfig: The desired containerd config for the cluster. DesiredContainerdConfig *ContainerdConfig `json:"desiredContainerdConfig,omitempty"` // DesiredCostManagementConfig: The desired configuration for the fine-grained diff --git a/containeranalysis/v1beta1/containeranalysis-api.json b/containeranalysis/v1beta1/containeranalysis-api.json index 5c242b0bc7a..ec23f8afece 100644 --- a/containeranalysis/v1beta1/containeranalysis-api.json +++ b/containeranalysis/v1beta1/containeranalysis-api.json @@ -409,6 +409,34 @@ "https://www.googleapis.com/auth/cloud-platform" ] }, + "getIamPolicy": { + "description": "Gets the access control policy for a note or an occurrence resource. Requires `containeranalysis.notes.setIamPolicy` or `containeranalysis.occurrences.setIamPolicy` permission if the resource is a note or occurrence, respectively. The resource takes the format `projects/[PROJECT_ID]/notes/[NOTE_ID]` for notes and `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for occurrences.", + "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/notes/{notesId}:getIamPolicy", + "httpMethod": "POST", + "id": "containeranalysis.projects.locations.notes.getIamPolicy", + "parameterOrder": [ + "resource" + ], + "parameters": { + "resource": { + "description": "REQUIRED: The resource for which the policy is being requested. See [Resource names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/notes/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1beta1/{+resource}:getIamPolicy", + "request": { + "$ref": "GetIamPolicyRequest" + }, + "response": { + "$ref": "Policy" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, "list": { "description": "Lists notes for the specified project.", "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/notes", @@ -483,6 +511,62 @@ "scopes": [ "https://www.googleapis.com/auth/cloud-platform" ] + }, + "setIamPolicy": { + "description": "Sets the access control policy on the specified note or occurrence. Requires `containeranalysis.notes.setIamPolicy` or `containeranalysis.occurrences.setIamPolicy` permission if the resource is a note or an occurrence, respectively. The resource takes the format `projects/[PROJECT_ID]/notes/[NOTE_ID]` for notes and `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for occurrences.", + "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/notes/{notesId}:setIamPolicy", + "httpMethod": "POST", + "id": "containeranalysis.projects.locations.notes.setIamPolicy", + "parameterOrder": [ + "resource" + ], + "parameters": { + "resource": { + "description": "REQUIRED: The resource for which the policy is being specified. See [Resource names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/notes/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1beta1/{+resource}:setIamPolicy", + "request": { + "$ref": "SetIamPolicyRequest" + }, + "response": { + "$ref": "Policy" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "testIamPermissions": { + "description": "Returns the permissions that a caller has on the specified note or occurrence. Requires list permission on the project (for example, `containeranalysis.notes.list`). The resource takes the format `projects/[PROJECT_ID]/notes/[NOTE_ID]` for notes and `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for occurrences.", + "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/notes/{notesId}:testIamPermissions", + "httpMethod": "POST", + "id": "containeranalysis.projects.locations.notes.testIamPermissions", + "parameterOrder": [ + "resource" + ], + "parameters": { + "resource": { + "description": "REQUIRED: The resource for which the policy detail is being requested. See [Resource names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/notes/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1beta1/{+resource}:testIamPermissions", + "request": { + "$ref": "TestIamPermissionsRequest" + }, + "response": { + "$ref": "TestIamPermissionsResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] } }, "resources": { @@ -641,6 +725,34 @@ "https://www.googleapis.com/auth/cloud-platform" ] }, + "getIamPolicy": { + "description": "Gets the access control policy for a note or an occurrence resource. Requires `containeranalysis.notes.setIamPolicy` or `containeranalysis.occurrences.setIamPolicy` permission if the resource is a note or occurrence, respectively. The resource takes the format `projects/[PROJECT_ID]/notes/[NOTE_ID]` for notes and `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for occurrences.", + "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/occurrences/{occurrencesId}:getIamPolicy", + "httpMethod": "POST", + "id": "containeranalysis.projects.locations.occurrences.getIamPolicy", + "parameterOrder": [ + "resource" + ], + "parameters": { + "resource": { + "description": "REQUIRED: The resource for which the policy is being requested. See [Resource names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/occurrences/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1beta1/{+resource}:getIamPolicy", + "request": { + "$ref": "GetIamPolicyRequest" + }, + "response": { + "$ref": "Policy" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, "getNotes": { "description": "Gets the note attached to the specified occurrence. Consumer projects can use this method to get a note that belongs to a provider project.", "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/occurrences/{occurrencesId}/notes", @@ -770,6 +882,62 @@ "scopes": [ "https://www.googleapis.com/auth/cloud-platform" ] + }, + "setIamPolicy": { + "description": "Sets the access control policy on the specified note or occurrence. Requires `containeranalysis.notes.setIamPolicy` or `containeranalysis.occurrences.setIamPolicy` permission if the resource is a note or an occurrence, respectively. The resource takes the format `projects/[PROJECT_ID]/notes/[NOTE_ID]` for notes and `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for occurrences.", + "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/occurrences/{occurrencesId}:setIamPolicy", + "httpMethod": "POST", + "id": "containeranalysis.projects.locations.occurrences.setIamPolicy", + "parameterOrder": [ + "resource" + ], + "parameters": { + "resource": { + "description": "REQUIRED: The resource for which the policy is being specified. See [Resource names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/occurrences/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1beta1/{+resource}:setIamPolicy", + "request": { + "$ref": "SetIamPolicyRequest" + }, + "response": { + "$ref": "Policy" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "testIamPermissions": { + "description": "Returns the permissions that a caller has on the specified note or occurrence. Requires list permission on the project (for example, `containeranalysis.notes.list`). The resource takes the format `projects/[PROJECT_ID]/notes/[NOTE_ID]` for notes and `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for occurrences.", + "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/occurrences/{occurrencesId}:testIamPermissions", + "httpMethod": "POST", + "id": "containeranalysis.projects.locations.occurrences.testIamPermissions", + "parameterOrder": [ + "resource" + ], + "parameters": { + "resource": { + "description": "REQUIRED: The resource for which the policy detail is being requested. See [Resource names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/occurrences/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1beta1/{+resource}:testIamPermissions", + "request": { + "$ref": "TestIamPermissionsRequest" + }, + "response": { + "$ref": "TestIamPermissionsResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] } } }, @@ -1543,7 +1711,7 @@ } } }, - "revision": "20240816", + "revision": "20240830", "rootUrl": "https://containeranalysis.googleapis.com/", "schemas": { "AliasContext": { diff --git a/containeranalysis/v1beta1/containeranalysis-gen.go b/containeranalysis/v1beta1/containeranalysis-gen.go index 21b9143ae12..abd3b91f036 100644 --- a/containeranalysis/v1beta1/containeranalysis-gen.go +++ b/containeranalysis/v1beta1/containeranalysis-gen.go @@ -6927,6 +6927,114 @@ func (c *ProjectsLocationsNotesGetCall) Do(opts ...googleapi.CallOption) (*Note, return ret, nil } +type ProjectsLocationsNotesGetIamPolicyCall struct { + s *Service + resource string + getiampolicyrequest *GetIamPolicyRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// GetIamPolicy: Gets the access control policy for a note or an occurrence +// resource. Requires `containeranalysis.notes.setIamPolicy` or +// `containeranalysis.occurrences.setIamPolicy` permission if the resource is a +// note or occurrence, respectively. The resource takes the format +// `projects/[PROJECT_ID]/notes/[NOTE_ID]` for notes and +// `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for occurrences. +// +// - resource: REQUIRED: The resource for which the policy is being requested. +// See Resource names (https://cloud.google.com/apis/design/resource_names) +// for the appropriate value for this field. +func (r *ProjectsLocationsNotesService) GetIamPolicy(resource string, getiampolicyrequest *GetIamPolicyRequest) *ProjectsLocationsNotesGetIamPolicyCall { + c := &ProjectsLocationsNotesGetIamPolicyCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.resource = resource + c.getiampolicyrequest = getiampolicyrequest + 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 *ProjectsLocationsNotesGetIamPolicyCall) Fields(s ...googleapi.Field) *ProjectsLocationsNotesGetIamPolicyCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsNotesGetIamPolicyCall) Context(ctx context.Context) *ProjectsLocationsNotesGetIamPolicyCall { + 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 *ProjectsLocationsNotesGetIamPolicyCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsNotesGetIamPolicyCall) 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.getiampolicyrequest) + if err != nil { + return nil, err + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+resource}:getIamPolicy") + 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{ + "resource": c.resource, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "containeranalysis.projects.locations.notes.getIamPolicy" call. +// Any non-2xx status code is an error. Response headers are in either +// *Policy.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 *ProjectsLocationsNotesGetIamPolicyCall) Do(opts ...googleapi.CallOption) (*Policy, 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 := &Policy{ + 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 ProjectsLocationsNotesListCall struct { s *Service parent string @@ -7186,6 +7294,223 @@ func (c *ProjectsLocationsNotesPatchCall) Do(opts ...googleapi.CallOption) (*Not return ret, nil } +type ProjectsLocationsNotesSetIamPolicyCall struct { + s *Service + resource string + setiampolicyrequest *SetIamPolicyRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// SetIamPolicy: Sets the access control policy on the specified note or +// occurrence. Requires `containeranalysis.notes.setIamPolicy` or +// `containeranalysis.occurrences.setIamPolicy` permission if the resource is a +// note or an occurrence, respectively. The resource takes the format +// `projects/[PROJECT_ID]/notes/[NOTE_ID]` for notes and +// `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for occurrences. +// +// - resource: REQUIRED: The resource for which the policy is being specified. +// See Resource names (https://cloud.google.com/apis/design/resource_names) +// for the appropriate value for this field. +func (r *ProjectsLocationsNotesService) SetIamPolicy(resource string, setiampolicyrequest *SetIamPolicyRequest) *ProjectsLocationsNotesSetIamPolicyCall { + c := &ProjectsLocationsNotesSetIamPolicyCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.resource = resource + c.setiampolicyrequest = setiampolicyrequest + 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 *ProjectsLocationsNotesSetIamPolicyCall) Fields(s ...googleapi.Field) *ProjectsLocationsNotesSetIamPolicyCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsNotesSetIamPolicyCall) Context(ctx context.Context) *ProjectsLocationsNotesSetIamPolicyCall { + 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 *ProjectsLocationsNotesSetIamPolicyCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsNotesSetIamPolicyCall) 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.setiampolicyrequest) + if err != nil { + return nil, err + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+resource}:setIamPolicy") + 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{ + "resource": c.resource, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "containeranalysis.projects.locations.notes.setIamPolicy" call. +// Any non-2xx status code is an error. Response headers are in either +// *Policy.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 *ProjectsLocationsNotesSetIamPolicyCall) Do(opts ...googleapi.CallOption) (*Policy, 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 := &Policy{ + 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 ProjectsLocationsNotesTestIamPermissionsCall struct { + s *Service + resource string + testiampermissionsrequest *TestIamPermissionsRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// TestIamPermissions: Returns the permissions that a caller has on the +// specified note or occurrence. Requires list permission on the project (for +// example, `containeranalysis.notes.list`). The resource takes the format +// `projects/[PROJECT_ID]/notes/[NOTE_ID]` for notes and +// `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for occurrences. +// +// - resource: REQUIRED: The resource for which the policy detail is being +// requested. See Resource names +// (https://cloud.google.com/apis/design/resource_names) for the appropriate +// value for this field. +func (r *ProjectsLocationsNotesService) TestIamPermissions(resource string, testiampermissionsrequest *TestIamPermissionsRequest) *ProjectsLocationsNotesTestIamPermissionsCall { + c := &ProjectsLocationsNotesTestIamPermissionsCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.resource = resource + c.testiampermissionsrequest = testiampermissionsrequest + 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 *ProjectsLocationsNotesTestIamPermissionsCall) Fields(s ...googleapi.Field) *ProjectsLocationsNotesTestIamPermissionsCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsNotesTestIamPermissionsCall) Context(ctx context.Context) *ProjectsLocationsNotesTestIamPermissionsCall { + 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 *ProjectsLocationsNotesTestIamPermissionsCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsNotesTestIamPermissionsCall) 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.testiampermissionsrequest) + if err != nil { + return nil, err + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+resource}:testIamPermissions") + 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{ + "resource": c.resource, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "containeranalysis.projects.locations.notes.testIamPermissions" call. +// Any non-2xx status code is an error. Response headers are in either +// *TestIamPermissionsResponse.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 *ProjectsLocationsNotesTestIamPermissionsCall) Do(opts ...googleapi.CallOption) (*TestIamPermissionsResponse, 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 := &TestIamPermissionsResponse{ + 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 ProjectsLocationsNotesOccurrencesListCall struct { s *Service name string @@ -7650,74 +7975,182 @@ type ProjectsLocationsOccurrencesGetCall struct { header_ http.Header } -// Get: Gets the specified occurrence. +// Get: Gets the specified occurrence. +// +// - name: The name of the occurrence in the form of +// `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`. +func (r *ProjectsLocationsOccurrencesService) Get(name string) *ProjectsLocationsOccurrencesGetCall { + c := &ProjectsLocationsOccurrencesGetCall{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 *ProjectsLocationsOccurrencesGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsOccurrencesGetCall { + 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 *ProjectsLocationsOccurrencesGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsOccurrencesGetCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsOccurrencesGetCall) Context(ctx context.Context) *ProjectsLocationsOccurrencesGetCall { + 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 *ProjectsLocationsOccurrencesGetCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsOccurrencesGetCall) 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, "v1beta1/{+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 "containeranalysis.projects.locations.occurrences.get" call. +// Any non-2xx status code is an error. Response headers are in either +// *Occurrence.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 *ProjectsLocationsOccurrencesGetCall) Do(opts ...googleapi.CallOption) (*Occurrence, 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 := &Occurrence{ + 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 ProjectsLocationsOccurrencesGetIamPolicyCall struct { + s *Service + resource string + getiampolicyrequest *GetIamPolicyRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// GetIamPolicy: Gets the access control policy for a note or an occurrence +// resource. Requires `containeranalysis.notes.setIamPolicy` or +// `containeranalysis.occurrences.setIamPolicy` permission if the resource is a +// note or occurrence, respectively. The resource takes the format +// `projects/[PROJECT_ID]/notes/[NOTE_ID]` for notes and +// `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for occurrences. // -// - name: The name of the occurrence in the form of -// `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`. -func (r *ProjectsLocationsOccurrencesService) Get(name string) *ProjectsLocationsOccurrencesGetCall { - c := &ProjectsLocationsOccurrencesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.name = name +// - resource: REQUIRED: The resource for which the policy is being requested. +// See Resource names (https://cloud.google.com/apis/design/resource_names) +// for the appropriate value for this field. +func (r *ProjectsLocationsOccurrencesService) GetIamPolicy(resource string, getiampolicyrequest *GetIamPolicyRequest) *ProjectsLocationsOccurrencesGetIamPolicyCall { + c := &ProjectsLocationsOccurrencesGetIamPolicyCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.resource = resource + c.getiampolicyrequest = getiampolicyrequest 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 *ProjectsLocationsOccurrencesGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsOccurrencesGetCall { +func (c *ProjectsLocationsOccurrencesGetIamPolicyCall) Fields(s ...googleapi.Field) *ProjectsLocationsOccurrencesGetIamPolicyCall { 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 *ProjectsLocationsOccurrencesGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsOccurrencesGetCall { - c.ifNoneMatch_ = entityTag - return c -} - // Context sets the context to be used in this call's Do method. -func (c *ProjectsLocationsOccurrencesGetCall) Context(ctx context.Context) *ProjectsLocationsOccurrencesGetCall { +func (c *ProjectsLocationsOccurrencesGetIamPolicyCall) Context(ctx context.Context) *ProjectsLocationsOccurrencesGetIamPolicyCall { 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 *ProjectsLocationsOccurrencesGetCall) Header() http.Header { +func (c *ProjectsLocationsOccurrencesGetIamPolicyCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsOccurrencesGetCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) - if c.ifNoneMatch_ != "" { - reqHeaders.Set("If-None-Match", c.ifNoneMatch_) - } +func (c *ProjectsLocationsOccurrencesGetIamPolicyCall) 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.getiampolicyrequest) + if err != nil { + return nil, err + } c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+name}") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+resource}:getIamPolicy") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("GET", urls, body) + 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, + "resource": c.resource, }) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "containeranalysis.projects.locations.occurrences.get" call. +// Do executes the "containeranalysis.projects.locations.occurrences.getIamPolicy" call. // Any non-2xx status code is an error. Response headers are in either -// *Occurrence.ServerResponse.Header or (if a response was returned at all) in +// *Policy.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 *ProjectsLocationsOccurrencesGetCall) Do(opts ...googleapi.CallOption) (*Occurrence, error) { +func (c *ProjectsLocationsOccurrencesGetIamPolicyCall) Do(opts ...googleapi.CallOption) (*Policy, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -7736,7 +8169,7 @@ func (c *ProjectsLocationsOccurrencesGetCall) Do(opts ...googleapi.CallOption) ( if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &Occurrence{ + ret := &Policy{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -8234,6 +8667,223 @@ func (c *ProjectsLocationsOccurrencesPatchCall) Do(opts ...googleapi.CallOption) return ret, nil } +type ProjectsLocationsOccurrencesSetIamPolicyCall struct { + s *Service + resource string + setiampolicyrequest *SetIamPolicyRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// SetIamPolicy: Sets the access control policy on the specified note or +// occurrence. Requires `containeranalysis.notes.setIamPolicy` or +// `containeranalysis.occurrences.setIamPolicy` permission if the resource is a +// note or an occurrence, respectively. The resource takes the format +// `projects/[PROJECT_ID]/notes/[NOTE_ID]` for notes and +// `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for occurrences. +// +// - resource: REQUIRED: The resource for which the policy is being specified. +// See Resource names (https://cloud.google.com/apis/design/resource_names) +// for the appropriate value for this field. +func (r *ProjectsLocationsOccurrencesService) SetIamPolicy(resource string, setiampolicyrequest *SetIamPolicyRequest) *ProjectsLocationsOccurrencesSetIamPolicyCall { + c := &ProjectsLocationsOccurrencesSetIamPolicyCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.resource = resource + c.setiampolicyrequest = setiampolicyrequest + 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 *ProjectsLocationsOccurrencesSetIamPolicyCall) Fields(s ...googleapi.Field) *ProjectsLocationsOccurrencesSetIamPolicyCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsOccurrencesSetIamPolicyCall) Context(ctx context.Context) *ProjectsLocationsOccurrencesSetIamPolicyCall { + 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 *ProjectsLocationsOccurrencesSetIamPolicyCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsOccurrencesSetIamPolicyCall) 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.setiampolicyrequest) + if err != nil { + return nil, err + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+resource}:setIamPolicy") + 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{ + "resource": c.resource, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "containeranalysis.projects.locations.occurrences.setIamPolicy" call. +// Any non-2xx status code is an error. Response headers are in either +// *Policy.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 *ProjectsLocationsOccurrencesSetIamPolicyCall) Do(opts ...googleapi.CallOption) (*Policy, 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 := &Policy{ + 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 ProjectsLocationsOccurrencesTestIamPermissionsCall struct { + s *Service + resource string + testiampermissionsrequest *TestIamPermissionsRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// TestIamPermissions: Returns the permissions that a caller has on the +// specified note or occurrence. Requires list permission on the project (for +// example, `containeranalysis.notes.list`). The resource takes the format +// `projects/[PROJECT_ID]/notes/[NOTE_ID]` for notes and +// `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for occurrences. +// +// - resource: REQUIRED: The resource for which the policy detail is being +// requested. See Resource names +// (https://cloud.google.com/apis/design/resource_names) for the appropriate +// value for this field. +func (r *ProjectsLocationsOccurrencesService) TestIamPermissions(resource string, testiampermissionsrequest *TestIamPermissionsRequest) *ProjectsLocationsOccurrencesTestIamPermissionsCall { + c := &ProjectsLocationsOccurrencesTestIamPermissionsCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.resource = resource + c.testiampermissionsrequest = testiampermissionsrequest + 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 *ProjectsLocationsOccurrencesTestIamPermissionsCall) Fields(s ...googleapi.Field) *ProjectsLocationsOccurrencesTestIamPermissionsCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsOccurrencesTestIamPermissionsCall) Context(ctx context.Context) *ProjectsLocationsOccurrencesTestIamPermissionsCall { + 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 *ProjectsLocationsOccurrencesTestIamPermissionsCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsOccurrencesTestIamPermissionsCall) 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.testiampermissionsrequest) + if err != nil { + return nil, err + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+resource}:testIamPermissions") + 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{ + "resource": c.resource, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "containeranalysis.projects.locations.occurrences.testIamPermissions" call. +// Any non-2xx status code is an error. Response headers are in either +// *TestIamPermissionsResponse.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 *ProjectsLocationsOccurrencesTestIamPermissionsCall) Do(opts ...googleapi.CallOption) (*TestIamPermissionsResponse, 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 := &TestIamPermissionsResponse{ + 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 ProjectsLocationsResourcesExportSBOMCall struct { s *Service name string diff --git a/datamigration/v1/datamigration-api.json b/datamigration/v1/datamigration-api.json index 877f5878162..0c3ae01aed6 100644 --- a/datamigration/v1/datamigration-api.json +++ b/datamigration/v1/datamigration-api.json @@ -2218,7 +2218,7 @@ } } }, - "revision": "20240826", + "revision": "20240902", "rootUrl": "https://datamigration.googleapis.com/", "schemas": { "AlloyDbConnectionProfile": { @@ -2245,12 +2245,14 @@ "enum": [ "DATABASE_VERSION_UNSPECIFIED", "POSTGRES_14", - "POSTGRES_15" + "POSTGRES_15", + "POSTGRES_16" ], "enumDescriptions": [ "This is an unknown database version.", "The database version is Postgres 14.", - "The database version is Postgres 15." + "The database version is Postgres 15.", + "The database version is Postgres 16." ], "type": "string" }, diff --git a/datamigration/v1/datamigration-gen.go b/datamigration/v1/datamigration-gen.go index f6c43a8f31e..c347f571b4a 100644 --- a/datamigration/v1/datamigration-gen.go +++ b/datamigration/v1/datamigration-gen.go @@ -296,6 +296,7 @@ type AlloyDbSettings struct { // "DATABASE_VERSION_UNSPECIFIED" - This is an unknown database version. // "POSTGRES_14" - The database version is Postgres 14. // "POSTGRES_15" - The database version is Postgres 15. + // "POSTGRES_16" - The database version is Postgres 16. DatabaseVersion string `json:"databaseVersion,omitempty"` // EncryptionConfig: Optional. The encryption config can be specified to // encrypt the data disks and other persistent data resources of a cluster with diff --git a/dialogflow/v3/dialogflow-api.json b/dialogflow/v3/dialogflow-api.json index 7abf12e2373..effed43ba43 100644 --- a/dialogflow/v3/dialogflow-api.json +++ b/dialogflow/v3/dialogflow-api.json @@ -4453,7 +4453,7 @@ } } }, - "revision": "20240828", + "revision": "20240903", "rootUrl": "https://dialogflow.googleapis.com/", "schemas": { "GoogleCloudDialogflowCxV3AdvancedSettings": { @@ -7989,7 +7989,7 @@ "id": "GoogleCloudDialogflowCxV3NluSettings", "properties": { "classificationThreshold": { - "description": "To filter out false positive results and still get variety in matched natural language inputs for your agent, you can tune the machine learning classification threshold. If the returned score value is less than the threshold value, then a no-match event will be triggered. The score values range from 0.0 (completely uncertain) to 1.0 (completely certain). If set to 0.0, the default of 0.3 is used.", + "description": "To filter out false positive results and still get variety in matched natural language inputs for your agent, you can tune the machine learning classification threshold. If the returned score value is less than the threshold value, then a no-match event will be triggered. The score values range from 0.0 (completely uncertain) to 1.0 (completely certain). If set to 0.0, the default of 0.3 is used. You can set a separate classification threshold for the flow in each language enabled for the agent.", "format": "float", "type": "number" }, diff --git a/dialogflow/v3/dialogflow-gen.go b/dialogflow/v3/dialogflow-gen.go index a89cf8d4f08..b4dcffa099d 100644 --- a/dialogflow/v3/dialogflow-gen.go +++ b/dialogflow/v3/dialogflow-gen.go @@ -5627,7 +5627,9 @@ type GoogleCloudDialogflowCxV3NluSettings struct { // machine learning classification threshold. If the returned score value is // less than the threshold value, then a no-match event will be triggered. The // score values range from 0.0 (completely uncertain) to 1.0 (completely - // certain). If set to 0.0, the default of 0.3 is used. + // certain). If set to 0.0, the default of 0.3 is used. You can set a separate + // classification threshold for the flow in each language enabled for the + // agent. ClassificationThreshold float64 `json:"classificationThreshold,omitempty"` // ModelTrainingMode: Indicates NLU model training mode. // diff --git a/dialogflow/v3beta1/dialogflow-api.json b/dialogflow/v3beta1/dialogflow-api.json index a0bd458b9a2..f269696efbf 100644 --- a/dialogflow/v3beta1/dialogflow-api.json +++ b/dialogflow/v3beta1/dialogflow-api.json @@ -5185,7 +5185,7 @@ } } }, - "revision": "20240828", + "revision": "20240903", "rootUrl": "https://dialogflow.googleapis.com/", "schemas": { "GoogleCloudDialogflowCxV3AdvancedSettings": { @@ -11653,7 +11653,7 @@ "id": "GoogleCloudDialogflowCxV3beta1NluSettings", "properties": { "classificationThreshold": { - "description": "To filter out false positive results and still get variety in matched natural language inputs for your agent, you can tune the machine learning classification threshold. If the returned score value is less than the threshold value, then a no-match event will be triggered. The score values range from 0.0 (completely uncertain) to 1.0 (completely certain). If set to 0.0, the default of 0.3 is used.", + "description": "To filter out false positive results and still get variety in matched natural language inputs for your agent, you can tune the machine learning classification threshold. If the returned score value is less than the threshold value, then a no-match event will be triggered. The score values range from 0.0 (completely uncertain) to 1.0 (completely certain). If set to 0.0, the default of 0.3 is used. You can set a separate classification threshold for the flow in each language enabled for the agent.", "format": "float", "type": "number" }, diff --git a/dialogflow/v3beta1/dialogflow-gen.go b/dialogflow/v3beta1/dialogflow-gen.go index 84feca805da..c4861db55af 100644 --- a/dialogflow/v3beta1/dialogflow-gen.go +++ b/dialogflow/v3beta1/dialogflow-gen.go @@ -9716,7 +9716,9 @@ type GoogleCloudDialogflowCxV3beta1NluSettings struct { // machine learning classification threshold. If the returned score value is // less than the threshold value, then a no-match event will be triggered. The // score values range from 0.0 (completely uncertain) to 1.0 (completely - // certain). If set to 0.0, the default of 0.3 is used. + // certain). If set to 0.0, the default of 0.3 is used. You can set a separate + // classification threshold for the flow in each language enabled for the + // agent. ClassificationThreshold float64 `json:"classificationThreshold,omitempty"` // ModelTrainingMode: Indicates NLU model training mode. // diff --git a/discoveryengine/v1/discoveryengine-api.json b/discoveryengine/v1/discoveryengine-api.json index 746d94c3022..3a9fbabaa36 100644 --- a/discoveryengine/v1/discoveryengine-api.json +++ b/discoveryengine/v1/discoveryengine-api.json @@ -5986,7 +5986,7 @@ } } }, - "revision": "20240826", + "revision": "20240829", "rootUrl": "https://discoveryengine.googleapis.com/", "schemas": { "GoogleApiHttpBody": { @@ -6181,17 +6181,19 @@ "POTENTIAL_POLICY_VIOLATION", "NO_RELEVANT_CONTENT", "JAIL_BREAKING_QUERY_IGNORED", - "CUSTOMER_POLICY_VIOLATION" + "CUSTOMER_POLICY_VIOLATION", + "NON_ANSWER_SEEKING_QUERY_IGNORED_V2" ], "enumDescriptions": [ "Default value. The answer skipped reason is not specified.", "The adversarial query ignored case.", - "The non-answer seeking query ignored case.", + "The non-answer seeking query ignored case Google skips the answer if the query is chit chat.", "The out-of-domain query ignored case. Google skips the answer if there are no high-relevance search results.", "The potential policy violation case. Google skips the answer if there is a potential policy violation detected. This includes content that may be violent or toxic.", "The no relevant content case. Google skips the answer if there is no relevant content in the retrieved search results.", "The jail-breaking query ignored case. For example, \"Reply in the tone of a competing company's CEO\". Google skips the answer if the query is classified as a jail-breaking query.", - "The customer policy violation case. Google skips the summary if there is a customer policy violation detected. The policy is defined by the customer." + "The customer policy violation case. Google skips the summary if there is a customer policy violation detected. The policy is defined by the customer.", + "The non-answer seeking query ignored case. Google skips the answer if the query doesn't have clear intent." ], "type": "string" }, @@ -6436,13 +6438,15 @@ "TYPE_UNSPECIFIED", "ADVERSARIAL_QUERY", "NON_ANSWER_SEEKING_QUERY", - "JAIL_BREAKING_QUERY" + "JAIL_BREAKING_QUERY", + "NON_ANSWER_SEEKING_QUERY_V2" ], "enumDescriptions": [ "Unspecified query classification type.", "Adversarial query classification type.", - "Non-answer-seeking query classification type.", - "Jail-breaking query classification type." + "Non-answer-seeking query classification type, for chit chat.", + "Jail-breaking query classification type.", + "Non-answer-seeking query classification type, for no clear intent." ], "type": "string" }, @@ -6725,13 +6729,15 @@ "TYPE_UNSPECIFIED", "ADVERSARIAL_QUERY", "NON_ANSWER_SEEKING_QUERY", - "JAIL_BREAKING_QUERY" + "JAIL_BREAKING_QUERY", + "NON_ANSWER_SEEKING_QUERY_V2" ], "enumDescriptions": [ "Unspecified query classification type.", "Adversarial query classification type.", - "Non-answer-seeking query classification type.", - "Jail-breaking query classification type." + "Non-answer-seeking query classification type, for chit chat.", + "Jail-breaking query classification type.", + "Non-answer-seeking query classification type, for no clear intent." ], "type": "string" } @@ -8392,6 +8398,11 @@ "description": "Immutable. The identifier of the document. Id should conform to [RFC-1034](https://tools.ietf.org/html/rfc1034) standard with a length limit of 63 characters.", "type": "string" }, + "indexStatus": { + "$ref": "GoogleCloudDiscoveryengineV1DocumentIndexStatus", + "description": "Output only. The index status of the document. * If document is indexed successfully, the index_time field is populated. * Otherwise, if document is not indexed due to errors, the error_samples field is populated. * Otherwise, index_status is unset.", + "readOnly": true + }, "indexTime": { "description": "Output only. The last time the document was indexed. If this field is set, the document could be returned in search results. This field is OUTPUT_ONLY. If this field is not populated, it means the document has never been indexed.", "format": "google-datetime", @@ -8445,6 +8456,25 @@ }, "type": "object" }, + "GoogleCloudDiscoveryengineV1DocumentIndexStatus": { + "description": "Index status of the document.", + "id": "GoogleCloudDiscoveryengineV1DocumentIndexStatus", + "properties": { + "errorSamples": { + "description": "A sample of errors encountered while indexing the document. If this field is populated, the document is not indexed due to errors.", + "items": { + "$ref": "GoogleRpcStatus" + }, + "type": "array" + }, + "indexTime": { + "description": "The time when the document was indexed. If this field is populated, it means the document has been indexed.", + "format": "google-datetime", + "type": "string" + } + }, + "type": "object" + }, "GoogleCloudDiscoveryengineV1DocumentInfo": { "description": "Detailed document information associated with a user event.", "id": "GoogleCloudDiscoveryengineV1DocumentInfo", @@ -10781,18 +10811,20 @@ "LLM_ADDON_NOT_ENABLED", "NO_RELEVANT_CONTENT", "JAIL_BREAKING_QUERY_IGNORED", - "CUSTOMER_POLICY_VIOLATION" + "CUSTOMER_POLICY_VIOLATION", + "NON_SUMMARY_SEEKING_QUERY_IGNORED_V2" ], "enumDescriptions": [ "Default value. The summary skipped reason is not specified.", "The adversarial query ignored case. Only used when SummarySpec.ignore_adversarial_query is set to `true`.", - "The non-summary seeking query ignored case. Only used when SummarySpec.ignore_non_summary_seeking_query is set to `true`.", + "The non-summary seeking query ignored case. Google skips the summary if the query is chit chat. Only used when SummarySpec.ignore_non_summary_seeking_query is set to `true`.", "The out-of-domain query ignored case. Google skips the summary if there are no high-relevance search results. For example, the data store contains facts about company A but the user query is asking questions about company B.", "The potential policy violation case. Google skips the summary if there is a potential policy violation detected. This includes content that may be violent or toxic.", "The LLM addon not enabled case. Google skips the summary if the LLM addon is not enabled.", "The no relevant content case. Google skips the summary if there is no relevant content in the retrieved search results.", "The jail-breaking query ignored case. For example, \"Reply in the tone of a competing company's CEO\". Only used when [SearchRequest.ContentSearchSpec.SummarySpec.ignore_jail_breaking_query] is set to `true`.", - "The customer policy violation case. Google skips the summary if there is a customer policy violation detected. The policy is defined by the customer." + "The customer policy violation case. Google skips the summary if there is a customer policy violation detected. The policy is defined by the customer.", + "The non-answer seeking query ignored case. Google skips the summary if the query doesn't have clear intent. Only used when [SearchRequest.ContentSearchSpec.SummarySpec.ignore_non_answer_seeking_query] is set to `true`." ], "type": "string" }, @@ -11510,15 +11542,19 @@ "GOOGLE_MAIL", "GOOGLE_SITES", "GOOGLE_CALENDAR", - "GOOGLE_GROUPS" + "GOOGLE_CHAT", + "GOOGLE_GROUPS", + "GOOGLE_KEEP" ], "enumDescriptions": [ - "Default value.", - "The data store is used to store content from Google Drive.", - "The data store is used to store content from Gmail.", - "The data store is used to store content from Google Sites.", - "The data store is used to store content from Google Calendar.", - "The data store is used to store content from Google Groups." + "Defaults to an unspecified Workspace type.", + "Workspace Data Store contains Drive data", + "Workspace Data Store contains Mail data", + "Workspace Data Store contains Sites data", + "Workspace Data Store contains Calendar data", + "Workspace Data Store contains Chat data", + "Workspace Data Store contains Groups data", + "Workspace Data Store contains Keep data" ], "type": "string" } @@ -11555,17 +11591,19 @@ "POTENTIAL_POLICY_VIOLATION", "NO_RELEVANT_CONTENT", "JAIL_BREAKING_QUERY_IGNORED", - "CUSTOMER_POLICY_VIOLATION" + "CUSTOMER_POLICY_VIOLATION", + "NON_ANSWER_SEEKING_QUERY_IGNORED_V2" ], "enumDescriptions": [ "Default value. The answer skipped reason is not specified.", "The adversarial query ignored case.", - "The non-answer seeking query ignored case.", + "The non-answer seeking query ignored case Google skips the answer if the query is chit chat.", "The out-of-domain query ignored case. Google skips the answer if there are no high-relevance search results.", "The potential policy violation case. Google skips the answer if there is a potential policy violation detected. This includes content that may be violent or toxic.", "The no relevant content case. Google skips the answer if there is no relevant content in the retrieved search results.", "The jail-breaking query ignored case. For example, \"Reply in the tone of a competing company's CEO\". Google skips the answer if the query is classified as a jail-breaking query.", - "The customer policy violation case. Google skips the summary if there is a customer policy violation detected. The policy is defined by the customer." + "The customer policy violation case. Google skips the summary if there is a customer policy violation detected. The policy is defined by the customer.", + "The non-answer seeking query ignored case. Google skips the answer if the query doesn't have clear intent." ], "type": "string" }, @@ -11705,13 +11743,15 @@ "TYPE_UNSPECIFIED", "ADVERSARIAL_QUERY", "NON_ANSWER_SEEKING_QUERY", - "JAIL_BREAKING_QUERY" + "JAIL_BREAKING_QUERY", + "NON_ANSWER_SEEKING_QUERY_V2" ], "enumDescriptions": [ "Unspecified query classification type.", "Adversarial query classification type.", - "Non-answer-seeking query classification type.", - "Jail-breaking query classification type." + "Non-answer-seeking query classification type, for chit chat.", + "Jail-breaking query classification type.", + "Non-answer-seeking query classification type, for no clear intent." ], "type": "string" } @@ -15119,15 +15159,19 @@ "GOOGLE_MAIL", "GOOGLE_SITES", "GOOGLE_CALENDAR", - "GOOGLE_GROUPS" + "GOOGLE_CHAT", + "GOOGLE_GROUPS", + "GOOGLE_KEEP" ], "enumDescriptions": [ - "Default value.", - "The data store is used to store content from Google Drive.", - "The data store is used to store content from Gmail.", - "The data store is used to store content from Google Sites.", - "The data store is used to store content from Google Calendar.", - "The data store is used to store content from Google Groups." + "Defaults to an unspecified Workspace type.", + "Workspace Data Store contains Drive data", + "Workspace Data Store contains Mail data", + "Workspace Data Store contains Sites data", + "Workspace Data Store contains Calendar data", + "Workspace Data Store contains Chat data", + "Workspace Data Store contains Groups data", + "Workspace Data Store contains Keep data" ], "type": "string" } @@ -17568,15 +17612,19 @@ "GOOGLE_MAIL", "GOOGLE_SITES", "GOOGLE_CALENDAR", - "GOOGLE_GROUPS" + "GOOGLE_CHAT", + "GOOGLE_GROUPS", + "GOOGLE_KEEP" ], "enumDescriptions": [ - "Default value.", - "The data store is used to store content from Google Drive.", - "The data store is used to store content from Gmail.", - "The data store is used to store content from Google Sites.", - "The data store is used to store content from Google Calendar.", - "The data store is used to store content from Google Groups." + "Defaults to an unspecified Workspace type.", + "Workspace Data Store contains Drive data", + "Workspace Data Store contains Mail data", + "Workspace Data Store contains Sites data", + "Workspace Data Store contains Calendar data", + "Workspace Data Store contains Chat data", + "Workspace Data Store contains Groups data", + "Workspace Data Store contains Keep data" ], "type": "string" } diff --git a/discoveryengine/v1/discoveryengine-gen.go b/discoveryengine/v1/discoveryengine-gen.go index 9103f527608..2076fc81c59 100644 --- a/discoveryengine/v1/discoveryengine-gen.go +++ b/discoveryengine/v1/discoveryengine-gen.go @@ -1151,7 +1151,7 @@ type GoogleCloudDiscoveryengineV1Answer struct { // reason is not specified. // "ADVERSARIAL_QUERY_IGNORED" - The adversarial query ignored case. // "NON_ANSWER_SEEKING_QUERY_IGNORED" - The non-answer seeking query ignored - // case. + // case Google skips the answer if the query is chit chat. // "OUT_OF_DOMAIN_QUERY_IGNORED" - The out-of-domain query ignored case. // Google skips the answer if there are no high-relevance search results. // "POTENTIAL_POLICY_VIOLATION" - The potential policy violation case. Google @@ -1165,6 +1165,9 @@ type GoogleCloudDiscoveryengineV1Answer struct { // "CUSTOMER_POLICY_VIOLATION" - The customer policy violation case. Google // skips the summary if there is a customer policy violation detected. The // policy is defined by the customer. + // "NON_ANSWER_SEEKING_QUERY_IGNORED_V2" - The non-answer seeking query + // ignored case. Google skips the answer if the query doesn't have clear + // intent. AnswerSkippedReasons []string `json:"answerSkippedReasons,omitempty"` // AnswerText: The textual answer. AnswerText string `json:"answerText,omitempty"` @@ -1463,8 +1466,11 @@ type GoogleCloudDiscoveryengineV1AnswerQueryRequestQueryUnderstandingSpecQueryCl // Possible values: // "TYPE_UNSPECIFIED" - Unspecified query classification type. // "ADVERSARIAL_QUERY" - Adversarial query classification type. - // "NON_ANSWER_SEEKING_QUERY" - Non-answer-seeking query classification type. + // "NON_ANSWER_SEEKING_QUERY" - Non-answer-seeking query classification type, + // for chit chat. // "JAIL_BREAKING_QUERY" - Jail-breaking query classification type. + // "NON_ANSWER_SEEKING_QUERY_V2" - Non-answer-seeking query classification + // type, for no clear intent. Types []string `json:"types,omitempty"` // ForceSendFields is a list of field names (e.g. "Types") to unconditionally // include in API requests. By default, fields with empty or default values are @@ -1894,8 +1900,11 @@ type GoogleCloudDiscoveryengineV1AnswerQueryUnderstandingInfoQueryClassification // Possible values: // "TYPE_UNSPECIFIED" - Unspecified query classification type. // "ADVERSARIAL_QUERY" - Adversarial query classification type. - // "NON_ANSWER_SEEKING_QUERY" - Non-answer-seeking query classification type. + // "NON_ANSWER_SEEKING_QUERY" - Non-answer-seeking query classification type, + // for chit chat. // "JAIL_BREAKING_QUERY" - Jail-breaking query classification type. + // "NON_ANSWER_SEEKING_QUERY_V2" - Non-answer-seeking query classification + // type, for no clear intent. Type string `json:"type,omitempty"` // ForceSendFields is a list of field names (e.g. "Positive") to // unconditionally include in API requests. By default, fields with empty or @@ -4178,6 +4187,11 @@ type GoogleCloudDiscoveryengineV1Document struct { // (https://tools.ietf.org/html/rfc1034) standard with a length limit of 63 // characters. Id string `json:"id,omitempty"` + // IndexStatus: Output only. The index status of the document. * If document is + // indexed successfully, the index_time field is populated. * Otherwise, if + // document is not indexed due to errors, the error_samples field is populated. + // * Otherwise, index_status is unset. + IndexStatus *GoogleCloudDiscoveryengineV1DocumentIndexStatus `json:"indexStatus,omitempty"` // IndexTime: Output only. The last time the document was indexed. If this // field is set, the document could be returned in search results. This field // is OUTPUT_ONLY. If this field is not populated, it means the document has @@ -4262,6 +4276,33 @@ func (s GoogleCloudDiscoveryengineV1DocumentContent) MarshalJSON() ([]byte, erro return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudDiscoveryengineV1DocumentIndexStatus: Index status of the +// document. +type GoogleCloudDiscoveryengineV1DocumentIndexStatus struct { + // ErrorSamples: A sample of errors encountered while indexing the document. If + // this field is populated, the document is not indexed due to errors. + ErrorSamples []*GoogleRpcStatus `json:"errorSamples,omitempty"` + // IndexTime: The time when the document was indexed. If this field is + // populated, it means the document has been indexed. + IndexTime string `json:"indexTime,omitempty"` + // ForceSendFields is a list of field names (e.g. "ErrorSamples") 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. "ErrorSamples") 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 GoogleCloudDiscoveryengineV1DocumentIndexStatus) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1DocumentIndexStatus + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudDiscoveryengineV1DocumentInfo: Detailed document information // associated with a user event. type GoogleCloudDiscoveryengineV1DocumentInfo struct { @@ -7819,8 +7860,8 @@ type GoogleCloudDiscoveryengineV1SearchResponseSummary struct { // "ADVERSARIAL_QUERY_IGNORED" - The adversarial query ignored case. Only // used when SummarySpec.ignore_adversarial_query is set to `true`. // "NON_SUMMARY_SEEKING_QUERY_IGNORED" - The non-summary seeking query - // ignored case. Only used when SummarySpec.ignore_non_summary_seeking_query is - // set to `true`. + // ignored case. Google skips the summary if the query is chit chat. Only used + // when SummarySpec.ignore_non_summary_seeking_query is set to `true`. // "OUT_OF_DOMAIN_QUERY_IGNORED" - The out-of-domain query ignored case. // Google skips the summary if there are no high-relevance search results. For // example, the data store contains facts about company A but the user query is @@ -7839,6 +7880,11 @@ type GoogleCloudDiscoveryengineV1SearchResponseSummary struct { // "CUSTOMER_POLICY_VIOLATION" - The customer policy violation case. Google // skips the summary if there is a customer policy violation detected. The // policy is defined by the customer. + // "NON_SUMMARY_SEEKING_QUERY_IGNORED_V2" - The non-answer seeking query + // ignored case. Google skips the summary if the query doesn't have clear + // intent. Only used when + // [SearchRequest.ContentSearchSpec.SummarySpec.ignore_non_answer_seeking_query] + // is set to `true`. SummarySkippedReasons []string `json:"summarySkippedReasons,omitempty"` // SummaryText: The summary content. SummaryText string `json:"summaryText,omitempty"` @@ -8864,16 +8910,14 @@ type GoogleCloudDiscoveryengineV1WorkspaceConfig struct { // Type: The Google Workspace data source. // // Possible values: - // "TYPE_UNSPECIFIED" - Default value. - // "GOOGLE_DRIVE" - The data store is used to store content from Google - // Drive. - // "GOOGLE_MAIL" - The data store is used to store content from Gmail. - // "GOOGLE_SITES" - The data store is used to store content from Google - // Sites. - // "GOOGLE_CALENDAR" - The data store is used to store content from Google - // Calendar. - // "GOOGLE_GROUPS" - The data store is used to store content from Google - // Groups. + // "TYPE_UNSPECIFIED" - Defaults to an unspecified Workspace type. + // "GOOGLE_DRIVE" - Workspace Data Store contains Drive data + // "GOOGLE_MAIL" - Workspace Data Store contains Mail data + // "GOOGLE_SITES" - Workspace Data Store contains Sites data + // "GOOGLE_CALENDAR" - Workspace Data Store contains Calendar data + // "GOOGLE_CHAT" - Workspace Data Store contains Chat data + // "GOOGLE_GROUPS" - Workspace Data Store contains Groups data + // "GOOGLE_KEEP" - Workspace Data Store contains Keep data Type string `json:"type,omitempty"` // ForceSendFields is a list of field names (e.g. "DasherCustomerId") to // unconditionally include in API requests. By default, fields with empty or @@ -8929,7 +8973,7 @@ type GoogleCloudDiscoveryengineV1alphaAnswer struct { // reason is not specified. // "ADVERSARIAL_QUERY_IGNORED" - The adversarial query ignored case. // "NON_ANSWER_SEEKING_QUERY_IGNORED" - The non-answer seeking query ignored - // case. + // case Google skips the answer if the query is chit chat. // "OUT_OF_DOMAIN_QUERY_IGNORED" - The out-of-domain query ignored case. // Google skips the answer if there are no high-relevance search results. // "POTENTIAL_POLICY_VIOLATION" - The potential policy violation case. Google @@ -8943,6 +8987,9 @@ type GoogleCloudDiscoveryengineV1alphaAnswer struct { // "CUSTOMER_POLICY_VIOLATION" - The customer policy violation case. Google // skips the summary if there is a customer policy violation detected. The // policy is defined by the customer. + // "NON_ANSWER_SEEKING_QUERY_IGNORED_V2" - The non-answer seeking query + // ignored case. Google skips the answer if the query doesn't have clear + // intent. AnswerSkippedReasons []string `json:"answerSkippedReasons,omitempty"` // AnswerText: The textual answer. AnswerText string `json:"answerText,omitempty"` @@ -9073,8 +9120,11 @@ type GoogleCloudDiscoveryengineV1alphaAnswerQueryUnderstandingInfoQueryClassific // Possible values: // "TYPE_UNSPECIFIED" - Unspecified query classification type. // "ADVERSARIAL_QUERY" - Adversarial query classification type. - // "NON_ANSWER_SEEKING_QUERY" - Non-answer-seeking query classification type. + // "NON_ANSWER_SEEKING_QUERY" - Non-answer-seeking query classification type, + // for chit chat. // "JAIL_BREAKING_QUERY" - Jail-breaking query classification type. + // "NON_ANSWER_SEEKING_QUERY_V2" - Non-answer-seeking query classification + // type, for no clear intent. Type string `json:"type,omitempty"` // ForceSendFields is a list of field names (e.g. "Positive") to // unconditionally include in API requests. By default, fields with empty or @@ -13855,16 +13905,14 @@ type GoogleCloudDiscoveryengineV1alphaWorkspaceConfig struct { // Type: The Google Workspace data source. // // Possible values: - // "TYPE_UNSPECIFIED" - Default value. - // "GOOGLE_DRIVE" - The data store is used to store content from Google - // Drive. - // "GOOGLE_MAIL" - The data store is used to store content from Gmail. - // "GOOGLE_SITES" - The data store is used to store content from Google - // Sites. - // "GOOGLE_CALENDAR" - The data store is used to store content from Google - // Calendar. - // "GOOGLE_GROUPS" - The data store is used to store content from Google - // Groups. + // "TYPE_UNSPECIFIED" - Defaults to an unspecified Workspace type. + // "GOOGLE_DRIVE" - Workspace Data Store contains Drive data + // "GOOGLE_MAIL" - Workspace Data Store contains Mail data + // "GOOGLE_SITES" - Workspace Data Store contains Sites data + // "GOOGLE_CALENDAR" - Workspace Data Store contains Calendar data + // "GOOGLE_CHAT" - Workspace Data Store contains Chat data + // "GOOGLE_GROUPS" - Workspace Data Store contains Groups data + // "GOOGLE_KEEP" - Workspace Data Store contains Keep data Type string `json:"type,omitempty"` // ForceSendFields is a list of field names (e.g. "DasherCustomerId") to // unconditionally include in API requests. By default, fields with empty or @@ -17375,16 +17423,14 @@ type GoogleCloudDiscoveryengineV1betaWorkspaceConfig struct { // Type: The Google Workspace data source. // // Possible values: - // "TYPE_UNSPECIFIED" - Default value. - // "GOOGLE_DRIVE" - The data store is used to store content from Google - // Drive. - // "GOOGLE_MAIL" - The data store is used to store content from Gmail. - // "GOOGLE_SITES" - The data store is used to store content from Google - // Sites. - // "GOOGLE_CALENDAR" - The data store is used to store content from Google - // Calendar. - // "GOOGLE_GROUPS" - The data store is used to store content from Google - // Groups. + // "TYPE_UNSPECIFIED" - Defaults to an unspecified Workspace type. + // "GOOGLE_DRIVE" - Workspace Data Store contains Drive data + // "GOOGLE_MAIL" - Workspace Data Store contains Mail data + // "GOOGLE_SITES" - Workspace Data Store contains Sites data + // "GOOGLE_CALENDAR" - Workspace Data Store contains Calendar data + // "GOOGLE_CHAT" - Workspace Data Store contains Chat data + // "GOOGLE_GROUPS" - Workspace Data Store contains Groups data + // "GOOGLE_KEEP" - Workspace Data Store contains Keep data Type string `json:"type,omitempty"` // ForceSendFields is a list of field names (e.g. "DasherCustomerId") to // unconditionally include in API requests. By default, fields with empty or diff --git a/discoveryengine/v1alpha/discoveryengine-api.json b/discoveryengine/v1alpha/discoveryengine-api.json index 2271249c94f..6ddbdf7cb09 100644 --- a/discoveryengine/v1alpha/discoveryengine-api.json +++ b/discoveryengine/v1alpha/discoveryengine-api.json @@ -7517,7 +7517,7 @@ } } }, - "revision": "20240826", + "revision": "20240829", "rootUrl": "https://discoveryengine.googleapis.com/", "schemas": { "GoogleApiDistribution": { @@ -9293,15 +9293,19 @@ "GOOGLE_MAIL", "GOOGLE_SITES", "GOOGLE_CALENDAR", - "GOOGLE_GROUPS" + "GOOGLE_CHAT", + "GOOGLE_GROUPS", + "GOOGLE_KEEP" ], "enumDescriptions": [ - "Default value.", - "The data store is used to store content from Google Drive.", - "The data store is used to store content from Gmail.", - "The data store is used to store content from Google Sites.", - "The data store is used to store content from Google Calendar.", - "The data store is used to store content from Google Groups." + "Defaults to an unspecified Workspace type.", + "Workspace Data Store contains Drive data", + "Workspace Data Store contains Mail data", + "Workspace Data Store contains Sites data", + "Workspace Data Store contains Calendar data", + "Workspace Data Store contains Chat data", + "Workspace Data Store contains Groups data", + "Workspace Data Store contains Keep data" ], "type": "string" } @@ -9369,17 +9373,19 @@ "POTENTIAL_POLICY_VIOLATION", "NO_RELEVANT_CONTENT", "JAIL_BREAKING_QUERY_IGNORED", - "CUSTOMER_POLICY_VIOLATION" + "CUSTOMER_POLICY_VIOLATION", + "NON_ANSWER_SEEKING_QUERY_IGNORED_V2" ], "enumDescriptions": [ "Default value. The answer skipped reason is not specified.", "The adversarial query ignored case.", - "The non-answer seeking query ignored case.", + "The non-answer seeking query ignored case Google skips the answer if the query is chit chat.", "The out-of-domain query ignored case. Google skips the answer if there are no high-relevance search results.", "The potential policy violation case. Google skips the answer if there is a potential policy violation detected. This includes content that may be violent or toxic.", "The no relevant content case. Google skips the answer if there is no relevant content in the retrieved search results.", "The jail-breaking query ignored case. For example, \"Reply in the tone of a competing company's CEO\". Google skips the answer if the query is classified as a jail-breaking query.", - "The customer policy violation case. Google skips the summary if there is a customer policy violation detected. The policy is defined by the customer." + "The customer policy violation case. Google skips the summary if there is a customer policy violation detected. The policy is defined by the customer.", + "The non-answer seeking query ignored case. Google skips the answer if the query doesn't have clear intent." ], "type": "string" }, @@ -9624,13 +9630,15 @@ "TYPE_UNSPECIFIED", "ADVERSARIAL_QUERY", "NON_ANSWER_SEEKING_QUERY", - "JAIL_BREAKING_QUERY" + "JAIL_BREAKING_QUERY", + "NON_ANSWER_SEEKING_QUERY_V2" ], "enumDescriptions": [ "Unspecified query classification type.", "Adversarial query classification type.", - "Non-answer-seeking query classification type.", - "Jail-breaking query classification type." + "Non-answer-seeking query classification type, for chit chat.", + "Jail-breaking query classification type.", + "Non-answer-seeking query classification type, for no clear intent." ], "type": "string" }, @@ -9917,13 +9925,15 @@ "TYPE_UNSPECIFIED", "ADVERSARIAL_QUERY", "NON_ANSWER_SEEKING_QUERY", - "JAIL_BREAKING_QUERY" + "JAIL_BREAKING_QUERY", + "NON_ANSWER_SEEKING_QUERY_V2" ], "enumDescriptions": [ "Unspecified query classification type.", "Adversarial query classification type.", - "Non-answer-seeking query classification type.", - "Jail-breaking query classification type." + "Non-answer-seeking query classification type, for chit chat.", + "Jail-breaking query classification type.", + "Non-answer-seeking query classification type, for no clear intent." ], "type": "string" } @@ -11714,6 +11724,11 @@ "description": "Immutable. The identifier of the document. Id should conform to [RFC-1034](https://tools.ietf.org/html/rfc1034) standard with a length limit of 63 characters.", "type": "string" }, + "indexStatus": { + "$ref": "GoogleCloudDiscoveryengineV1alphaDocumentIndexStatus", + "description": "Output only. The index status of the document. * If document is indexed successfully, the index_time field is populated. * Otherwise, if document is not indexed due to errors, the error_samples field is populated. * Otherwise, index_status is unset.", + "readOnly": true + }, "indexTime": { "description": "Output only. The last time the document was indexed. If this field is set, the document could be returned in search results. This field is OUTPUT_ONLY. If this field is not populated, it means the document has never been indexed.", "format": "google-datetime", @@ -11799,6 +11814,25 @@ }, "type": "object" }, + "GoogleCloudDiscoveryengineV1alphaDocumentIndexStatus": { + "description": "Index status of the document.", + "id": "GoogleCloudDiscoveryengineV1alphaDocumentIndexStatus", + "properties": { + "errorSamples": { + "description": "A sample of errors encountered while indexing the document. If this field is populated, the document is not indexed due to errors.", + "items": { + "$ref": "GoogleRpcStatus" + }, + "type": "array" + }, + "indexTime": { + "description": "The time when the document was indexed. If this field is populated, it means the document has been indexed.", + "format": "google-datetime", + "type": "string" + } + }, + "type": "object" + }, "GoogleCloudDiscoveryengineV1alphaDocumentInfo": { "description": "Detailed document information associated with a user event.", "id": "GoogleCloudDiscoveryengineV1alphaDocumentInfo", @@ -15906,18 +15940,20 @@ "LLM_ADDON_NOT_ENABLED", "NO_RELEVANT_CONTENT", "JAIL_BREAKING_QUERY_IGNORED", - "CUSTOMER_POLICY_VIOLATION" + "CUSTOMER_POLICY_VIOLATION", + "NON_SUMMARY_SEEKING_QUERY_IGNORED_V2" ], "enumDescriptions": [ "Default value. The summary skipped reason is not specified.", "The adversarial query ignored case. Only used when SummarySpec.ignore_adversarial_query is set to `true`.", - "The non-summary seeking query ignored case. Only used when SummarySpec.ignore_non_summary_seeking_query is set to `true`.", + "The non-summary seeking query ignored case. Google skips the summary if the query is chit chat. Only used when SummarySpec.ignore_non_summary_seeking_query is set to `true`.", "The out-of-domain query ignored case. Google skips the summary if there are no high-relevance search results. For example, the data store contains facts about company A but the user query is asking questions about company B.", "The potential policy violation case. Google skips the summary if there is a potential policy violation detected. This includes content that may be violent or toxic.", "The LLM addon not enabled case. Google skips the summary if the LLM addon is not enabled.", "The no relevant content case. Google skips the summary if there is no relevant content in the retrieved search results.", "The jail-breaking query ignored case. For example, \"Reply in the tone of a competing company's CEO\". Only used when [SearchRequest.ContentSearchSpec.SummarySpec.ignore_jail_breaking_query] is set to `true`.", - "The customer policy violation case. Google skips the summary if there is a customer policy violation detected. The policy is defined by the customer." + "The customer policy violation case. Google skips the summary if there is a customer policy violation detected. The policy is defined by the customer.", + "The non-answer seeking query ignored case. Google skips the summary if the query doesn't have clear intent. Only used when [SearchRequest.ContentSearchSpec.SummarySpec.ignore_non_answer_seeking_query] is set to `true`." ], "type": "string" }, @@ -16881,15 +16917,19 @@ "GOOGLE_MAIL", "GOOGLE_SITES", "GOOGLE_CALENDAR", - "GOOGLE_GROUPS" + "GOOGLE_CHAT", + "GOOGLE_GROUPS", + "GOOGLE_KEEP" ], "enumDescriptions": [ - "Default value.", - "The data store is used to store content from Google Drive.", - "The data store is used to store content from Gmail.", - "The data store is used to store content from Google Sites.", - "The data store is used to store content from Google Calendar.", - "The data store is used to store content from Google Groups." + "Defaults to an unspecified Workspace type.", + "Workspace Data Store contains Drive data", + "Workspace Data Store contains Mail data", + "Workspace Data Store contains Sites data", + "Workspace Data Store contains Calendar data", + "Workspace Data Store contains Chat data", + "Workspace Data Store contains Groups data", + "Workspace Data Store contains Keep data" ], "type": "string" } @@ -19330,15 +19370,19 @@ "GOOGLE_MAIL", "GOOGLE_SITES", "GOOGLE_CALENDAR", - "GOOGLE_GROUPS" + "GOOGLE_CHAT", + "GOOGLE_GROUPS", + "GOOGLE_KEEP" ], "enumDescriptions": [ - "Default value.", - "The data store is used to store content from Google Drive.", - "The data store is used to store content from Gmail.", - "The data store is used to store content from Google Sites.", - "The data store is used to store content from Google Calendar.", - "The data store is used to store content from Google Groups." + "Defaults to an unspecified Workspace type.", + "Workspace Data Store contains Drive data", + "Workspace Data Store contains Mail data", + "Workspace Data Store contains Sites data", + "Workspace Data Store contains Calendar data", + "Workspace Data Store contains Chat data", + "Workspace Data Store contains Groups data", + "Workspace Data Store contains Keep data" ], "type": "string" } diff --git a/discoveryengine/v1alpha/discoveryengine-gen.go b/discoveryengine/v1alpha/discoveryengine-gen.go index 77e6248c2a6..5b4f2ce1ace 100644 --- a/discoveryengine/v1alpha/discoveryengine-gen.go +++ b/discoveryengine/v1alpha/discoveryengine-gen.go @@ -3535,16 +3535,14 @@ type GoogleCloudDiscoveryengineV1WorkspaceConfig struct { // Type: The Google Workspace data source. // // Possible values: - // "TYPE_UNSPECIFIED" - Default value. - // "GOOGLE_DRIVE" - The data store is used to store content from Google - // Drive. - // "GOOGLE_MAIL" - The data store is used to store content from Gmail. - // "GOOGLE_SITES" - The data store is used to store content from Google - // Sites. - // "GOOGLE_CALENDAR" - The data store is used to store content from Google - // Calendar. - // "GOOGLE_GROUPS" - The data store is used to store content from Google - // Groups. + // "TYPE_UNSPECIFIED" - Defaults to an unspecified Workspace type. + // "GOOGLE_DRIVE" - Workspace Data Store contains Drive data + // "GOOGLE_MAIL" - Workspace Data Store contains Mail data + // "GOOGLE_SITES" - Workspace Data Store contains Sites data + // "GOOGLE_CALENDAR" - Workspace Data Store contains Calendar data + // "GOOGLE_CHAT" - Workspace Data Store contains Chat data + // "GOOGLE_GROUPS" - Workspace Data Store contains Groups data + // "GOOGLE_KEEP" - Workspace Data Store contains Keep data Type string `json:"type,omitempty"` // ForceSendFields is a list of field names (e.g. "DasherCustomerId") to // unconditionally include in API requests. By default, fields with empty or @@ -3646,7 +3644,7 @@ type GoogleCloudDiscoveryengineV1alphaAnswer struct { // reason is not specified. // "ADVERSARIAL_QUERY_IGNORED" - The adversarial query ignored case. // "NON_ANSWER_SEEKING_QUERY_IGNORED" - The non-answer seeking query ignored - // case. + // case Google skips the answer if the query is chit chat. // "OUT_OF_DOMAIN_QUERY_IGNORED" - The out-of-domain query ignored case. // Google skips the answer if there are no high-relevance search results. // "POTENTIAL_POLICY_VIOLATION" - The potential policy violation case. Google @@ -3660,6 +3658,9 @@ type GoogleCloudDiscoveryengineV1alphaAnswer struct { // "CUSTOMER_POLICY_VIOLATION" - The customer policy violation case. Google // skips the summary if there is a customer policy violation detected. The // policy is defined by the customer. + // "NON_ANSWER_SEEKING_QUERY_IGNORED_V2" - The non-answer seeking query + // ignored case. Google skips the answer if the query doesn't have clear + // intent. AnswerSkippedReasons []string `json:"answerSkippedReasons,omitempty"` // AnswerText: The textual answer. AnswerText string `json:"answerText,omitempty"` @@ -3958,8 +3959,11 @@ type GoogleCloudDiscoveryengineV1alphaAnswerQueryRequestQueryUnderstandingSpecQu // Possible values: // "TYPE_UNSPECIFIED" - Unspecified query classification type. // "ADVERSARIAL_QUERY" - Adversarial query classification type. - // "NON_ANSWER_SEEKING_QUERY" - Non-answer-seeking query classification type. + // "NON_ANSWER_SEEKING_QUERY" - Non-answer-seeking query classification type, + // for chit chat. // "JAIL_BREAKING_QUERY" - Jail-breaking query classification type. + // "NON_ANSWER_SEEKING_QUERY_V2" - Non-answer-seeking query classification + // type, for no clear intent. Types []string `json:"types,omitempty"` // ForceSendFields is a list of field names (e.g. "Types") to unconditionally // include in API requests. By default, fields with empty or default values are @@ -4393,8 +4397,11 @@ type GoogleCloudDiscoveryengineV1alphaAnswerQueryUnderstandingInfoQueryClassific // Possible values: // "TYPE_UNSPECIFIED" - Unspecified query classification type. // "ADVERSARIAL_QUERY" - Adversarial query classification type. - // "NON_ANSWER_SEEKING_QUERY" - Non-answer-seeking query classification type. + // "NON_ANSWER_SEEKING_QUERY" - Non-answer-seeking query classification type, + // for chit chat. // "JAIL_BREAKING_QUERY" - Jail-breaking query classification type. + // "NON_ANSWER_SEEKING_QUERY_V2" - Non-answer-seeking query classification + // type, for no clear intent. Type string `json:"type,omitempty"` // ForceSendFields is a list of field names (e.g. "Positive") to // unconditionally include in API requests. By default, fields with empty or @@ -6846,6 +6853,11 @@ type GoogleCloudDiscoveryengineV1alphaDocument struct { // (https://tools.ietf.org/html/rfc1034) standard with a length limit of 63 // characters. Id string `json:"id,omitempty"` + // IndexStatus: Output only. The index status of the document. * If document is + // indexed successfully, the index_time field is populated. * Otherwise, if + // document is not indexed due to errors, the error_samples field is populated. + // * Otherwise, index_status is unset. + IndexStatus *GoogleCloudDiscoveryengineV1alphaDocumentIndexStatus `json:"indexStatus,omitempty"` // IndexTime: Output only. The last time the document was indexed. If this // field is set, the document could be returned in search results. This field // is OUTPUT_ONLY. If this field is not populated, it means the document has @@ -6987,6 +6999,33 @@ func (s GoogleCloudDiscoveryengineV1alphaDocumentContent) MarshalJSON() ([]byte, return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudDiscoveryengineV1alphaDocumentIndexStatus: Index status of the +// document. +type GoogleCloudDiscoveryengineV1alphaDocumentIndexStatus struct { + // ErrorSamples: A sample of errors encountered while indexing the document. If + // this field is populated, the document is not indexed due to errors. + ErrorSamples []*GoogleRpcStatus `json:"errorSamples,omitempty"` + // IndexTime: The time when the document was indexed. If this field is + // populated, it means the document has been indexed. + IndexTime string `json:"indexTime,omitempty"` + // ForceSendFields is a list of field names (e.g. "ErrorSamples") 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. "ErrorSamples") 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 GoogleCloudDiscoveryengineV1alphaDocumentIndexStatus) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaDocumentIndexStatus + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudDiscoveryengineV1alphaDocumentInfo: Detailed document information // associated with a user event. type GoogleCloudDiscoveryengineV1alphaDocumentInfo struct { @@ -13068,8 +13107,8 @@ type GoogleCloudDiscoveryengineV1alphaSearchResponseSummary struct { // "ADVERSARIAL_QUERY_IGNORED" - The adversarial query ignored case. Only // used when SummarySpec.ignore_adversarial_query is set to `true`. // "NON_SUMMARY_SEEKING_QUERY_IGNORED" - The non-summary seeking query - // ignored case. Only used when SummarySpec.ignore_non_summary_seeking_query is - // set to `true`. + // ignored case. Google skips the summary if the query is chit chat. Only used + // when SummarySpec.ignore_non_summary_seeking_query is set to `true`. // "OUT_OF_DOMAIN_QUERY_IGNORED" - The out-of-domain query ignored case. // Google skips the summary if there are no high-relevance search results. For // example, the data store contains facts about company A but the user query is @@ -13088,6 +13127,11 @@ type GoogleCloudDiscoveryengineV1alphaSearchResponseSummary struct { // "CUSTOMER_POLICY_VIOLATION" - The customer policy violation case. Google // skips the summary if there is a customer policy violation detected. The // policy is defined by the customer. + // "NON_SUMMARY_SEEKING_QUERY_IGNORED_V2" - The non-answer seeking query + // ignored case. Google skips the summary if the query doesn't have clear + // intent. Only used when + // [SearchRequest.ContentSearchSpec.SummarySpec.ignore_non_answer_seeking_query] + // is set to `true`. SummarySkippedReasons []string `json:"summarySkippedReasons,omitempty"` // SummaryText: The summary content. SummaryText string `json:"summaryText,omitempty"` @@ -14439,16 +14483,14 @@ type GoogleCloudDiscoveryengineV1alphaWorkspaceConfig struct { // Type: The Google Workspace data source. // // Possible values: - // "TYPE_UNSPECIFIED" - Default value. - // "GOOGLE_DRIVE" - The data store is used to store content from Google - // Drive. - // "GOOGLE_MAIL" - The data store is used to store content from Gmail. - // "GOOGLE_SITES" - The data store is used to store content from Google - // Sites. - // "GOOGLE_CALENDAR" - The data store is used to store content from Google - // Calendar. - // "GOOGLE_GROUPS" - The data store is used to store content from Google - // Groups. + // "TYPE_UNSPECIFIED" - Defaults to an unspecified Workspace type. + // "GOOGLE_DRIVE" - Workspace Data Store contains Drive data + // "GOOGLE_MAIL" - Workspace Data Store contains Mail data + // "GOOGLE_SITES" - Workspace Data Store contains Sites data + // "GOOGLE_CALENDAR" - Workspace Data Store contains Calendar data + // "GOOGLE_CHAT" - Workspace Data Store contains Chat data + // "GOOGLE_GROUPS" - Workspace Data Store contains Groups data + // "GOOGLE_KEEP" - Workspace Data Store contains Keep data Type string `json:"type,omitempty"` // ForceSendFields is a list of field names (e.g. "DasherCustomerId") to // unconditionally include in API requests. By default, fields with empty or @@ -17959,16 +18001,14 @@ type GoogleCloudDiscoveryengineV1betaWorkspaceConfig struct { // Type: The Google Workspace data source. // // Possible values: - // "TYPE_UNSPECIFIED" - Default value. - // "GOOGLE_DRIVE" - The data store is used to store content from Google - // Drive. - // "GOOGLE_MAIL" - The data store is used to store content from Gmail. - // "GOOGLE_SITES" - The data store is used to store content from Google - // Sites. - // "GOOGLE_CALENDAR" - The data store is used to store content from Google - // Calendar. - // "GOOGLE_GROUPS" - The data store is used to store content from Google - // Groups. + // "TYPE_UNSPECIFIED" - Defaults to an unspecified Workspace type. + // "GOOGLE_DRIVE" - Workspace Data Store contains Drive data + // "GOOGLE_MAIL" - Workspace Data Store contains Mail data + // "GOOGLE_SITES" - Workspace Data Store contains Sites data + // "GOOGLE_CALENDAR" - Workspace Data Store contains Calendar data + // "GOOGLE_CHAT" - Workspace Data Store contains Chat data + // "GOOGLE_GROUPS" - Workspace Data Store contains Groups data + // "GOOGLE_KEEP" - Workspace Data Store contains Keep data Type string `json:"type,omitempty"` // ForceSendFields is a list of field names (e.g. "DasherCustomerId") to // unconditionally include in API requests. By default, fields with empty or diff --git a/discoveryengine/v1beta/discoveryengine-api.json b/discoveryengine/v1beta/discoveryengine-api.json index 1110c350277..3cac54c9e17 100644 --- a/discoveryengine/v1beta/discoveryengine-api.json +++ b/discoveryengine/v1beta/discoveryengine-api.json @@ -6786,7 +6786,7 @@ } } }, - "revision": "20240826", + "revision": "20240829", "rootUrl": "https://discoveryengine.googleapis.com/", "schemas": { "GoogleApiHttpBody": { @@ -8376,15 +8376,19 @@ "GOOGLE_MAIL", "GOOGLE_SITES", "GOOGLE_CALENDAR", - "GOOGLE_GROUPS" + "GOOGLE_CHAT", + "GOOGLE_GROUPS", + "GOOGLE_KEEP" ], "enumDescriptions": [ - "Default value.", - "The data store is used to store content from Google Drive.", - "The data store is used to store content from Gmail.", - "The data store is used to store content from Google Sites.", - "The data store is used to store content from Google Calendar.", - "The data store is used to store content from Google Groups." + "Defaults to an unspecified Workspace type.", + "Workspace Data Store contains Drive data", + "Workspace Data Store contains Mail data", + "Workspace Data Store contains Sites data", + "Workspace Data Store contains Calendar data", + "Workspace Data Store contains Chat data", + "Workspace Data Store contains Groups data", + "Workspace Data Store contains Keep data" ], "type": "string" } @@ -8421,17 +8425,19 @@ "POTENTIAL_POLICY_VIOLATION", "NO_RELEVANT_CONTENT", "JAIL_BREAKING_QUERY_IGNORED", - "CUSTOMER_POLICY_VIOLATION" + "CUSTOMER_POLICY_VIOLATION", + "NON_ANSWER_SEEKING_QUERY_IGNORED_V2" ], "enumDescriptions": [ "Default value. The answer skipped reason is not specified.", "The adversarial query ignored case.", - "The non-answer seeking query ignored case.", + "The non-answer seeking query ignored case Google skips the answer if the query is chit chat.", "The out-of-domain query ignored case. Google skips the answer if there are no high-relevance search results.", "The potential policy violation case. Google skips the answer if there is a potential policy violation detected. This includes content that may be violent or toxic.", "The no relevant content case. Google skips the answer if there is no relevant content in the retrieved search results.", "The jail-breaking query ignored case. For example, \"Reply in the tone of a competing company's CEO\". Google skips the answer if the query is classified as a jail-breaking query.", - "The customer policy violation case. Google skips the summary if there is a customer policy violation detected. The policy is defined by the customer." + "The customer policy violation case. Google skips the summary if there is a customer policy violation detected. The policy is defined by the customer.", + "The non-answer seeking query ignored case. Google skips the answer if the query doesn't have clear intent." ], "type": "string" }, @@ -8571,13 +8577,15 @@ "TYPE_UNSPECIFIED", "ADVERSARIAL_QUERY", "NON_ANSWER_SEEKING_QUERY", - "JAIL_BREAKING_QUERY" + "JAIL_BREAKING_QUERY", + "NON_ANSWER_SEEKING_QUERY_V2" ], "enumDescriptions": [ "Unspecified query classification type.", "Adversarial query classification type.", - "Non-answer-seeking query classification type.", - "Jail-breaking query classification type." + "Non-answer-seeking query classification type, for chit chat.", + "Jail-breaking query classification type.", + "Non-answer-seeking query classification type, for no clear intent." ], "type": "string" } @@ -11985,15 +11993,19 @@ "GOOGLE_MAIL", "GOOGLE_SITES", "GOOGLE_CALENDAR", - "GOOGLE_GROUPS" + "GOOGLE_CHAT", + "GOOGLE_GROUPS", + "GOOGLE_KEEP" ], "enumDescriptions": [ - "Default value.", - "The data store is used to store content from Google Drive.", - "The data store is used to store content from Gmail.", - "The data store is used to store content from Google Sites.", - "The data store is used to store content from Google Calendar.", - "The data store is used to store content from Google Groups." + "Defaults to an unspecified Workspace type.", + "Workspace Data Store contains Drive data", + "Workspace Data Store contains Mail data", + "Workspace Data Store contains Sites data", + "Workspace Data Store contains Calendar data", + "Workspace Data Store contains Chat data", + "Workspace Data Store contains Groups data", + "Workspace Data Store contains Keep data" ], "type": "string" } @@ -12046,17 +12058,19 @@ "POTENTIAL_POLICY_VIOLATION", "NO_RELEVANT_CONTENT", "JAIL_BREAKING_QUERY_IGNORED", - "CUSTOMER_POLICY_VIOLATION" + "CUSTOMER_POLICY_VIOLATION", + "NON_ANSWER_SEEKING_QUERY_IGNORED_V2" ], "enumDescriptions": [ "Default value. The answer skipped reason is not specified.", "The adversarial query ignored case.", - "The non-answer seeking query ignored case.", + "The non-answer seeking query ignored case Google skips the answer if the query is chit chat.", "The out-of-domain query ignored case. Google skips the answer if there are no high-relevance search results.", "The potential policy violation case. Google skips the answer if there is a potential policy violation detected. This includes content that may be violent or toxic.", "The no relevant content case. Google skips the answer if there is no relevant content in the retrieved search results.", "The jail-breaking query ignored case. For example, \"Reply in the tone of a competing company's CEO\". Google skips the answer if the query is classified as a jail-breaking query.", - "The customer policy violation case. Google skips the summary if there is a customer policy violation detected. The policy is defined by the customer." + "The customer policy violation case. Google skips the summary if there is a customer policy violation detected. The policy is defined by the customer.", + "The non-answer seeking query ignored case. Google skips the answer if the query doesn't have clear intent." ], "type": "string" }, @@ -12301,13 +12315,15 @@ "TYPE_UNSPECIFIED", "ADVERSARIAL_QUERY", "NON_ANSWER_SEEKING_QUERY", - "JAIL_BREAKING_QUERY" + "JAIL_BREAKING_QUERY", + "NON_ANSWER_SEEKING_QUERY_V2" ], "enumDescriptions": [ "Unspecified query classification type.", "Adversarial query classification type.", - "Non-answer-seeking query classification type.", - "Jail-breaking query classification type." + "Non-answer-seeking query classification type, for chit chat.", + "Jail-breaking query classification type.", + "Non-answer-seeking query classification type, for no clear intent." ], "type": "string" }, @@ -12590,13 +12606,15 @@ "TYPE_UNSPECIFIED", "ADVERSARIAL_QUERY", "NON_ANSWER_SEEKING_QUERY", - "JAIL_BREAKING_QUERY" + "JAIL_BREAKING_QUERY", + "NON_ANSWER_SEEKING_QUERY_V2" ], "enumDescriptions": [ "Unspecified query classification type.", "Adversarial query classification type.", - "Non-answer-seeking query classification type.", - "Jail-breaking query classification type." + "Non-answer-seeking query classification type, for chit chat.", + "Jail-breaking query classification type.", + "Non-answer-seeking query classification type, for no clear intent." ], "type": "string" } @@ -14274,6 +14292,11 @@ "description": "Immutable. The identifier of the document. Id should conform to [RFC-1034](https://tools.ietf.org/html/rfc1034) standard with a length limit of 63 characters.", "type": "string" }, + "indexStatus": { + "$ref": "GoogleCloudDiscoveryengineV1betaDocumentIndexStatus", + "description": "Output only. The index status of the document. * If document is indexed successfully, the index_time field is populated. * Otherwise, if document is not indexed due to errors, the error_samples field is populated. * Otherwise, index_status is unset.", + "readOnly": true + }, "indexTime": { "description": "Output only. The last time the document was indexed. If this field is set, the document could be returned in search results. This field is OUTPUT_ONLY. If this field is not populated, it means the document has never been indexed.", "format": "google-datetime", @@ -14327,6 +14350,25 @@ }, "type": "object" }, + "GoogleCloudDiscoveryengineV1betaDocumentIndexStatus": { + "description": "Index status of the document.", + "id": "GoogleCloudDiscoveryengineV1betaDocumentIndexStatus", + "properties": { + "errorSamples": { + "description": "A sample of errors encountered while indexing the document. If this field is populated, the document is not indexed due to errors.", + "items": { + "$ref": "GoogleRpcStatus" + }, + "type": "array" + }, + "indexTime": { + "description": "The time when the document was indexed. If this field is populated, it means the document has been indexed.", + "format": "google-datetime", + "type": "string" + } + }, + "type": "object" + }, "GoogleCloudDiscoveryengineV1betaDocumentInfo": { "description": "Detailed document information associated with a user event.", "id": "GoogleCloudDiscoveryengineV1betaDocumentInfo", @@ -17613,18 +17655,20 @@ "LLM_ADDON_NOT_ENABLED", "NO_RELEVANT_CONTENT", "JAIL_BREAKING_QUERY_IGNORED", - "CUSTOMER_POLICY_VIOLATION" + "CUSTOMER_POLICY_VIOLATION", + "NON_SUMMARY_SEEKING_QUERY_IGNORED_V2" ], "enumDescriptions": [ "Default value. The summary skipped reason is not specified.", "The adversarial query ignored case. Only used when SummarySpec.ignore_adversarial_query is set to `true`.", - "The non-summary seeking query ignored case. Only used when SummarySpec.ignore_non_summary_seeking_query is set to `true`.", + "The non-summary seeking query ignored case. Google skips the summary if the query is chit chat. Only used when SummarySpec.ignore_non_summary_seeking_query is set to `true`.", "The out-of-domain query ignored case. Google skips the summary if there are no high-relevance search results. For example, the data store contains facts about company A but the user query is asking questions about company B.", "The potential policy violation case. Google skips the summary if there is a potential policy violation detected. This includes content that may be violent or toxic.", "The LLM addon not enabled case. Google skips the summary if the LLM addon is not enabled.", "The no relevant content case. Google skips the summary if there is no relevant content in the retrieved search results.", "The jail-breaking query ignored case. For example, \"Reply in the tone of a competing company's CEO\". Only used when [SearchRequest.ContentSearchSpec.SummarySpec.ignore_jail_breaking_query] is set to `true`.", - "The customer policy violation case. Google skips the summary if there is a customer policy violation detected. The policy is defined by the customer." + "The customer policy violation case. Google skips the summary if there is a customer policy violation detected. The policy is defined by the customer.", + "The non-answer seeking query ignored case. Google skips the summary if the query doesn't have clear intent. Only used when [SearchRequest.ContentSearchSpec.SummarySpec.ignore_non_answer_seeking_query] is set to `true`." ], "type": "string" }, @@ -18527,15 +18571,19 @@ "GOOGLE_MAIL", "GOOGLE_SITES", "GOOGLE_CALENDAR", - "GOOGLE_GROUPS" + "GOOGLE_CHAT", + "GOOGLE_GROUPS", + "GOOGLE_KEEP" ], "enumDescriptions": [ - "Default value.", - "The data store is used to store content from Google Drive.", - "The data store is used to store content from Gmail.", - "The data store is used to store content from Google Sites.", - "The data store is used to store content from Google Calendar.", - "The data store is used to store content from Google Groups." + "Defaults to an unspecified Workspace type.", + "Workspace Data Store contains Drive data", + "Workspace Data Store contains Mail data", + "Workspace Data Store contains Sites data", + "Workspace Data Store contains Calendar data", + "Workspace Data Store contains Chat data", + "Workspace Data Store contains Groups data", + "Workspace Data Store contains Keep data" ], "type": "string" } diff --git a/discoveryengine/v1beta/discoveryengine-gen.go b/discoveryengine/v1beta/discoveryengine-gen.go index 5c3ae1b26fa..8d0283b2013 100644 --- a/discoveryengine/v1beta/discoveryengine-gen.go +++ b/discoveryengine/v1beta/discoveryengine-gen.go @@ -3062,16 +3062,14 @@ type GoogleCloudDiscoveryengineV1WorkspaceConfig struct { // Type: The Google Workspace data source. // // Possible values: - // "TYPE_UNSPECIFIED" - Default value. - // "GOOGLE_DRIVE" - The data store is used to store content from Google - // Drive. - // "GOOGLE_MAIL" - The data store is used to store content from Gmail. - // "GOOGLE_SITES" - The data store is used to store content from Google - // Sites. - // "GOOGLE_CALENDAR" - The data store is used to store content from Google - // Calendar. - // "GOOGLE_GROUPS" - The data store is used to store content from Google - // Groups. + // "TYPE_UNSPECIFIED" - Defaults to an unspecified Workspace type. + // "GOOGLE_DRIVE" - Workspace Data Store contains Drive data + // "GOOGLE_MAIL" - Workspace Data Store contains Mail data + // "GOOGLE_SITES" - Workspace Data Store contains Sites data + // "GOOGLE_CALENDAR" - Workspace Data Store contains Calendar data + // "GOOGLE_CHAT" - Workspace Data Store contains Chat data + // "GOOGLE_GROUPS" - Workspace Data Store contains Groups data + // "GOOGLE_KEEP" - Workspace Data Store contains Keep data Type string `json:"type,omitempty"` // ForceSendFields is a list of field names (e.g. "DasherCustomerId") to // unconditionally include in API requests. By default, fields with empty or @@ -3127,7 +3125,7 @@ type GoogleCloudDiscoveryengineV1alphaAnswer struct { // reason is not specified. // "ADVERSARIAL_QUERY_IGNORED" - The adversarial query ignored case. // "NON_ANSWER_SEEKING_QUERY_IGNORED" - The non-answer seeking query ignored - // case. + // case Google skips the answer if the query is chit chat. // "OUT_OF_DOMAIN_QUERY_IGNORED" - The out-of-domain query ignored case. // Google skips the answer if there are no high-relevance search results. // "POTENTIAL_POLICY_VIOLATION" - The potential policy violation case. Google @@ -3141,6 +3139,9 @@ type GoogleCloudDiscoveryengineV1alphaAnswer struct { // "CUSTOMER_POLICY_VIOLATION" - The customer policy violation case. Google // skips the summary if there is a customer policy violation detected. The // policy is defined by the customer. + // "NON_ANSWER_SEEKING_QUERY_IGNORED_V2" - The non-answer seeking query + // ignored case. Google skips the answer if the query doesn't have clear + // intent. AnswerSkippedReasons []string `json:"answerSkippedReasons,omitempty"` // AnswerText: The textual answer. AnswerText string `json:"answerText,omitempty"` @@ -3271,8 +3272,11 @@ type GoogleCloudDiscoveryengineV1alphaAnswerQueryUnderstandingInfoQueryClassific // Possible values: // "TYPE_UNSPECIFIED" - Unspecified query classification type. // "ADVERSARIAL_QUERY" - Adversarial query classification type. - // "NON_ANSWER_SEEKING_QUERY" - Non-answer-seeking query classification type. + // "NON_ANSWER_SEEKING_QUERY" - Non-answer-seeking query classification type, + // for chit chat. // "JAIL_BREAKING_QUERY" - Jail-breaking query classification type. + // "NON_ANSWER_SEEKING_QUERY_V2" - Non-answer-seeking query classification + // type, for no clear intent. Type string `json:"type,omitempty"` // ForceSendFields is a list of field names (e.g. "Positive") to // unconditionally include in API requests. By default, fields with empty or @@ -8053,16 +8057,14 @@ type GoogleCloudDiscoveryengineV1alphaWorkspaceConfig struct { // Type: The Google Workspace data source. // // Possible values: - // "TYPE_UNSPECIFIED" - Default value. - // "GOOGLE_DRIVE" - The data store is used to store content from Google - // Drive. - // "GOOGLE_MAIL" - The data store is used to store content from Gmail. - // "GOOGLE_SITES" - The data store is used to store content from Google - // Sites. - // "GOOGLE_CALENDAR" - The data store is used to store content from Google - // Calendar. - // "GOOGLE_GROUPS" - The data store is used to store content from Google - // Groups. + // "TYPE_UNSPECIFIED" - Defaults to an unspecified Workspace type. + // "GOOGLE_DRIVE" - Workspace Data Store contains Drive data + // "GOOGLE_MAIL" - Workspace Data Store contains Mail data + // "GOOGLE_SITES" - Workspace Data Store contains Sites data + // "GOOGLE_CALENDAR" - Workspace Data Store contains Calendar data + // "GOOGLE_CHAT" - Workspace Data Store contains Chat data + // "GOOGLE_GROUPS" - Workspace Data Store contains Groups data + // "GOOGLE_KEEP" - Workspace Data Store contains Keep data Type string `json:"type,omitempty"` // ForceSendFields is a list of field names (e.g. "DasherCustomerId") to // unconditionally include in API requests. By default, fields with empty or @@ -8135,7 +8137,7 @@ type GoogleCloudDiscoveryengineV1betaAnswer struct { // reason is not specified. // "ADVERSARIAL_QUERY_IGNORED" - The adversarial query ignored case. // "NON_ANSWER_SEEKING_QUERY_IGNORED" - The non-answer seeking query ignored - // case. + // case Google skips the answer if the query is chit chat. // "OUT_OF_DOMAIN_QUERY_IGNORED" - The out-of-domain query ignored case. // Google skips the answer if there are no high-relevance search results. // "POTENTIAL_POLICY_VIOLATION" - The potential policy violation case. Google @@ -8149,6 +8151,9 @@ type GoogleCloudDiscoveryengineV1betaAnswer struct { // "CUSTOMER_POLICY_VIOLATION" - The customer policy violation case. Google // skips the summary if there is a customer policy violation detected. The // policy is defined by the customer. + // "NON_ANSWER_SEEKING_QUERY_IGNORED_V2" - The non-answer seeking query + // ignored case. Google skips the answer if the query doesn't have clear + // intent. AnswerSkippedReasons []string `json:"answerSkippedReasons,omitempty"` // AnswerText: The textual answer. AnswerText string `json:"answerText,omitempty"` @@ -8446,8 +8451,11 @@ type GoogleCloudDiscoveryengineV1betaAnswerQueryRequestQueryUnderstandingSpecQue // Possible values: // "TYPE_UNSPECIFIED" - Unspecified query classification type. // "ADVERSARIAL_QUERY" - Adversarial query classification type. - // "NON_ANSWER_SEEKING_QUERY" - Non-answer-seeking query classification type. + // "NON_ANSWER_SEEKING_QUERY" - Non-answer-seeking query classification type, + // for chit chat. // "JAIL_BREAKING_QUERY" - Jail-breaking query classification type. + // "NON_ANSWER_SEEKING_QUERY_V2" - Non-answer-seeking query classification + // type, for no clear intent. Types []string `json:"types,omitempty"` // ForceSendFields is a list of field names (e.g. "Types") to unconditionally // include in API requests. By default, fields with empty or default values are @@ -8880,8 +8888,11 @@ type GoogleCloudDiscoveryengineV1betaAnswerQueryUnderstandingInfoQueryClassifica // Possible values: // "TYPE_UNSPECIFIED" - Unspecified query classification type. // "ADVERSARIAL_QUERY" - Adversarial query classification type. - // "NON_ANSWER_SEEKING_QUERY" - Non-answer-seeking query classification type. + // "NON_ANSWER_SEEKING_QUERY" - Non-answer-seeking query classification type, + // for chit chat. // "JAIL_BREAKING_QUERY" - Jail-breaking query classification type. + // "NON_ANSWER_SEEKING_QUERY_V2" - Non-answer-seeking query classification + // type, for no clear intent. Type string `json:"type,omitempty"` // ForceSendFields is a list of field names (e.g. "Positive") to // unconditionally include in API requests. By default, fields with empty or @@ -11174,6 +11185,11 @@ type GoogleCloudDiscoveryengineV1betaDocument struct { // (https://tools.ietf.org/html/rfc1034) standard with a length limit of 63 // characters. Id string `json:"id,omitempty"` + // IndexStatus: Output only. The index status of the document. * If document is + // indexed successfully, the index_time field is populated. * Otherwise, if + // document is not indexed due to errors, the error_samples field is populated. + // * Otherwise, index_status is unset. + IndexStatus *GoogleCloudDiscoveryengineV1betaDocumentIndexStatus `json:"indexStatus,omitempty"` // IndexTime: Output only. The last time the document was indexed. If this // field is set, the document could be returned in search results. This field // is OUTPUT_ONLY. If this field is not populated, it means the document has @@ -11258,6 +11274,33 @@ func (s GoogleCloudDiscoveryengineV1betaDocumentContent) MarshalJSON() ([]byte, return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudDiscoveryengineV1betaDocumentIndexStatus: Index status of the +// document. +type GoogleCloudDiscoveryengineV1betaDocumentIndexStatus struct { + // ErrorSamples: A sample of errors encountered while indexing the document. If + // this field is populated, the document is not indexed due to errors. + ErrorSamples []*GoogleRpcStatus `json:"errorSamples,omitempty"` + // IndexTime: The time when the document was indexed. If this field is + // populated, it means the document has been indexed. + IndexTime string `json:"indexTime,omitempty"` + // ForceSendFields is a list of field names (e.g. "ErrorSamples") 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. "ErrorSamples") 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 GoogleCloudDiscoveryengineV1betaDocumentIndexStatus) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaDocumentIndexStatus + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudDiscoveryengineV1betaDocumentInfo: Detailed document information // associated with a user event. type GoogleCloudDiscoveryengineV1betaDocumentInfo struct { @@ -16203,8 +16246,8 @@ type GoogleCloudDiscoveryengineV1betaSearchResponseSummary struct { // "ADVERSARIAL_QUERY_IGNORED" - The adversarial query ignored case. Only // used when SummarySpec.ignore_adversarial_query is set to `true`. // "NON_SUMMARY_SEEKING_QUERY_IGNORED" - The non-summary seeking query - // ignored case. Only used when SummarySpec.ignore_non_summary_seeking_query is - // set to `true`. + // ignored case. Google skips the summary if the query is chit chat. Only used + // when SummarySpec.ignore_non_summary_seeking_query is set to `true`. // "OUT_OF_DOMAIN_QUERY_IGNORED" - The out-of-domain query ignored case. // Google skips the summary if there are no high-relevance search results. For // example, the data store contains facts about company A but the user query is @@ -16223,6 +16266,11 @@ type GoogleCloudDiscoveryengineV1betaSearchResponseSummary struct { // "CUSTOMER_POLICY_VIOLATION" - The customer policy violation case. Google // skips the summary if there is a customer policy violation detected. The // policy is defined by the customer. + // "NON_SUMMARY_SEEKING_QUERY_IGNORED_V2" - The non-answer seeking query + // ignored case. Google skips the summary if the query doesn't have clear + // intent. Only used when + // [SearchRequest.ContentSearchSpec.SummarySpec.ignore_non_answer_seeking_query] + // is set to `true`. SummarySkippedReasons []string `json:"summarySkippedReasons,omitempty"` // SummaryText: The summary content. SummaryText string `json:"summaryText,omitempty"` @@ -17501,16 +17549,14 @@ type GoogleCloudDiscoveryengineV1betaWorkspaceConfig struct { // Type: The Google Workspace data source. // // Possible values: - // "TYPE_UNSPECIFIED" - Default value. - // "GOOGLE_DRIVE" - The data store is used to store content from Google - // Drive. - // "GOOGLE_MAIL" - The data store is used to store content from Gmail. - // "GOOGLE_SITES" - The data store is used to store content from Google - // Sites. - // "GOOGLE_CALENDAR" - The data store is used to store content from Google - // Calendar. - // "GOOGLE_GROUPS" - The data store is used to store content from Google - // Groups. + // "TYPE_UNSPECIFIED" - Defaults to an unspecified Workspace type. + // "GOOGLE_DRIVE" - Workspace Data Store contains Drive data + // "GOOGLE_MAIL" - Workspace Data Store contains Mail data + // "GOOGLE_SITES" - Workspace Data Store contains Sites data + // "GOOGLE_CALENDAR" - Workspace Data Store contains Calendar data + // "GOOGLE_CHAT" - Workspace Data Store contains Chat data + // "GOOGLE_GROUPS" - Workspace Data Store contains Groups data + // "GOOGLE_KEEP" - Workspace Data Store contains Keep data Type string `json:"type,omitempty"` // ForceSendFields is a list of field names (e.g. "DasherCustomerId") to // unconditionally include in API requests. By default, fields with empty or diff --git a/dlp/v2/dlp-api.json b/dlp/v2/dlp-api.json index 13889c4a7f2..fb28ac8587d 100644 --- a/dlp/v2/dlp-api.json +++ b/dlp/v2/dlp-api.json @@ -5015,7 +5015,7 @@ } } }, - "revision": "20240825", + "revision": "20240901", "rootUrl": "https://dlp.googleapis.com/", "schemas": { "GooglePrivacyDlpV2Action": { @@ -6525,6 +6525,14 @@ "$ref": "GooglePrivacyDlpV2PubSubNotification", "description": "Publish a message into the Pub/Sub topic." }, + "publishToChronicle": { + "$ref": "GooglePrivacyDlpV2PublishToChronicle", + "description": "Publishes generated data profiles to Google Security Operations. For more information, see [Use Sensitive Data Protection data in context-aware analytics](https://cloud.google.com/chronicle/docs/detection/usecase-dlp-high-risk-user-download)." + }, + "publishToScc": { + "$ref": "GooglePrivacyDlpV2PublishToSecurityCommandCenter", + "description": "Publishes findings to SCC for each data profile." + }, "tagResources": { "$ref": "GooglePrivacyDlpV2TagResources", "description": "Tags the profiled resources with the specified tag values." @@ -10405,6 +10413,12 @@ "properties": {}, "type": "object" }, + "GooglePrivacyDlpV2PublishToChronicle": { + "description": "Message expressing intention to publish to Google Security Operations.", + "id": "GooglePrivacyDlpV2PublishToChronicle", + "properties": {}, + "type": "object" + }, "GooglePrivacyDlpV2PublishToPubSub": { "description": "Publish a message into a given Pub/Sub topic when DlpJob has completed. The message contains a single field, `DlpJobName`, which is equal to the finished job's [`DlpJob.name`](https://cloud.google.com/sensitive-data-protection/docs/reference/rest/v2/projects.dlpJobs#DlpJob). Compatible with: Inspect, Risk", "id": "GooglePrivacyDlpV2PublishToPubSub", @@ -10416,6 +10430,12 @@ }, "type": "object" }, + "GooglePrivacyDlpV2PublishToSecurityCommandCenter": { + "description": "If set, a summary finding will be created/updated in SCC for each profile.", + "id": "GooglePrivacyDlpV2PublishToSecurityCommandCenter", + "properties": {}, + "type": "object" + }, "GooglePrivacyDlpV2PublishToStackdriver": { "description": "Enable Stackdriver metric dlp.googleapis.com/finding_count. This will publish a metric to stack driver on each infotype requested and how many findings were found for it. CustomDetectors will be bucketed as 'Custom' under the Stackdriver label 'info_type'.", "id": "GooglePrivacyDlpV2PublishToStackdriver", diff --git a/dlp/v2/dlp-gen.go b/dlp/v2/dlp-gen.go index a5ea7415e31..983f4e213ff 100644 --- a/dlp/v2/dlp-gen.go +++ b/dlp/v2/dlp-gen.go @@ -2691,6 +2691,13 @@ type GooglePrivacyDlpV2DataProfileAction struct { ExportData *GooglePrivacyDlpV2Export `json:"exportData,omitempty"` // PubSubNotification: Publish a message into the Pub/Sub topic. PubSubNotification *GooglePrivacyDlpV2PubSubNotification `json:"pubSubNotification,omitempty"` + // PublishToChronicle: Publishes generated data profiles to Google Security + // Operations. For more information, see Use Sensitive Data Protection data in + // context-aware analytics + // (https://cloud.google.com/chronicle/docs/detection/usecase-dlp-high-risk-user-download). + PublishToChronicle *GooglePrivacyDlpV2PublishToChronicle `json:"publishToChronicle,omitempty"` + // PublishToScc: Publishes findings to SCC for each data profile. + PublishToScc *GooglePrivacyDlpV2PublishToSecurityCommandCenter `json:"publishToScc,omitempty"` // TagResources: Tags the profiled resources with the specified tag values. TagResources *GooglePrivacyDlpV2TagResources `json:"tagResources,omitempty"` // ForceSendFields is a list of field names (e.g. "ExportData") to @@ -7932,6 +7939,11 @@ type GooglePrivacyDlpV2PublishFindingsToCloudDataCatalog struct { type GooglePrivacyDlpV2PublishSummaryToCscc struct { } +// GooglePrivacyDlpV2PublishToChronicle: Message expressing intention to +// publish to Google Security Operations. +type GooglePrivacyDlpV2PublishToChronicle struct { +} + // GooglePrivacyDlpV2PublishToPubSub: Publish a message into a given Pub/Sub // topic when DlpJob has completed. The message contains a single field, // `DlpJobName`, which is equal to the finished job's `DlpJob.name` @@ -7961,6 +7973,11 @@ func (s GooglePrivacyDlpV2PublishToPubSub) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GooglePrivacyDlpV2PublishToSecurityCommandCenter: If set, a summary finding +// will be created/updated in SCC for each profile. +type GooglePrivacyDlpV2PublishToSecurityCommandCenter struct { +} + // GooglePrivacyDlpV2PublishToStackdriver: Enable Stackdriver metric // dlp.googleapis.com/finding_count. This will publish a metric to stack driver // on each infotype requested and how many findings were found for it. diff --git a/drive/v3/drive-api.json b/drive/v3/drive-api.json index 703e7117889..79d55f441ec 100644 --- a/drive/v3/drive-api.json +++ b/drive/v3/drive-api.json @@ -1145,6 +1145,42 @@ "https://www.googleapis.com/auth/drive.file" ] }, + "download": { + "description": "Downloads content of a file. Operations are valid for 24 hours from the time of creation.", + "flatPath": "files/{fileId}/download", + "httpMethod": "POST", + "id": "drive.files.download", + "parameterOrder": [ + "fileId" + ], + "parameters": { + "fileId": { + "description": "Required. The ID of the file to download.", + "location": "path", + "required": true, + "type": "string" + }, + "mimeType": { + "description": "Optional. The MIME type the file should be downloaded as. This field can only be set when downloading Google Workspace documents. See [Export MIME types for Google Workspace documents](/drive/api/guides/ref-export-formats) for the list of supported MIME types. If not set, a Google Workspace document is downloaded with a default MIME type. The default MIME type might change in the future.", + "location": "query", + "type": "string" + }, + "revisionId": { + "description": "Optional. The revision ID of the file to download. This field can only be set when downloading blob files, Google Docs, and Google Sheets. Returns `INVALID_ARGUMENT` if downloading a specific revision on the file is unsupported.", + "location": "query", + "type": "string" + } + }, + "path": "files/{fileId}/download", + "response": { + "$ref": "Operation" + }, + "scopes": [ + "https://www.googleapis.com/auth/drive", + "https://www.googleapis.com/auth/drive.file", + "https://www.googleapis.com/auth/drive.readonly" + ] + }, "emptyTrash": { "description": "Permanently deletes all of the user's trashed files.", "flatPath": "files/trash", @@ -1668,6 +1704,111 @@ } } }, + "operation": { + "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": "operation/{name}:cancel", + "httpMethod": "POST", + "id": "drive.operation.cancel", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "The name of the operation resource to be cancelled.", + "location": "path", + "required": true, + "type": "string" + } + }, + "path": "operation/{name}:cancel" + }, + "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": "operation/{name}", + "httpMethod": "DELETE", + "id": "drive.operation.delete", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "The name of the operation resource to be deleted.", + "location": "path", + "required": true, + "type": "string" + } + }, + "path": "operation/{name}" + } + } + }, + "operations": { + "methods": { + "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": "operations/{name}", + "httpMethod": "GET", + "id": "drive.operations.get", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "The name of the operation resource.", + "location": "path", + "required": true, + "type": "string" + } + }, + "path": "operations/{name}", + "response": { + "$ref": "Operation" + }, + "scopes": [ + "https://www.googleapis.com/auth/drive", + "https://www.googleapis.com/auth/drive.file", + "https://www.googleapis.com/auth/drive.meet.readonly", + "https://www.googleapis.com/auth/drive.readonly" + ] + }, + "list": { + "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`.", + "flatPath": "operations", + "httpMethod": "GET", + "id": "drive.operations.list", + "parameterOrder": [], + "parameters": { + "filter": { + "description": "The standard list filter.", + "location": "query", + "type": "string" + }, + "name": { + "description": "The name of the operation's parent resource.", + "location": "query", + "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": "operations", + "response": { + "$ref": "ListOperationsResponse" + } + } + } + }, "permissions": { "methods": { "create": { @@ -2523,7 +2664,7 @@ } } }, - "revision": "20240809", + "revision": "20240903", "rootUrl": "https://www.googleapis.com/", "schemas": { "About": { @@ -4207,6 +4348,24 @@ }, "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" + }, "ModifyLabelsRequest": { "description": "A request to modify the set of labels on a file. This request may contain many modifications that will either all succeed or all fail atomically.", "id": "ModifyLabelsRequest", @@ -4243,6 +4402,41 @@ }, "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" + }, "Permission": { "description": "A permission for a file. A permission grants a user, group, domain, or the world access to a file or a folder hierarchy. Some resource methods (such as `permissions.update`) require a `permissionId`. Use the `permissions.list` method to retrieve the ID for a file, folder, or shared drive.", "id": "Permission", @@ -4575,6 +4769,33 @@ }, "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" + }, "TeamDrive": { "description": "Deprecated: use the drive collection instead.", "id": "TeamDrive", diff --git a/drive/v3/drive-gen.go b/drive/v3/drive-gen.go index 5a35b65a854..03e968b26c1 100644 --- a/drive/v3/drive-gen.go +++ b/drive/v3/drive-gen.go @@ -184,6 +184,8 @@ func New(client *http.Client) (*Service, error) { s.Comments = NewCommentsService(s) s.Drives = NewDrivesService(s) s.Files = NewFilesService(s) + s.Operation = NewOperationService(s) + s.Operations = NewOperationsService(s) s.Permissions = NewPermissionsService(s) s.Replies = NewRepliesService(s) s.Revisions = NewRevisionsService(s) @@ -210,6 +212,10 @@ type Service struct { Files *FilesService + Operation *OperationService + + Operations *OperationsService + Permissions *PermissionsService Replies *RepliesService @@ -289,6 +295,24 @@ type FilesService struct { s *Service } +func NewOperationService(s *Service) *OperationService { + rs := &OperationService{s: s} + return rs +} + +type OperationService struct { + s *Service +} + +func NewOperationsService(s *Service) *OperationsService { + rs := &OperationsService{s: s} + return rs +} + +type OperationsService struct { + s *Service +} + func NewPermissionsService(s *Service) *PermissionsService { rs := &PermissionsService{s: s} return rs @@ -2147,6 +2171,34 @@ func (s LabelModification) MarshalJSON() ([]byte, error) { 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) +} + // ModifyLabelsRequest: A request to modify the set of labels on a file. This // request may contain many modifications that will either all succeed or all // fail atomically. @@ -2203,6 +2255,53 @@ func (s ModifyLabelsResponse) MarshalJSON() ([]byte, error) { 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) +} + // Permission: A permission for a file. A permission grants a user, group, // domain, or the world access to a file or a folder hierarchy. Some resource // methods (such as `permissions.update`) require a `permissionId`. Use the @@ -2604,6 +2703,40 @@ func (s StartPageToken) MarshalJSON() ([]byte, error) { 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) +} + // TeamDrive: Deprecated: use the drive collection instead. type TeamDrive struct { // BackgroundImageFile: An image file and cropping parameters from which a @@ -5700,6 +5833,122 @@ func (c *FilesDeleteCall) Do(opts ...googleapi.CallOption) error { return nil } +type FilesDownloadCall struct { + s *Service + fileId string + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Download: Downloads content of a file. Operations are valid for 24 hours +// from the time of creation. +// +// - fileId: The ID of the file to download. +func (r *FilesService) Download(fileId string) *FilesDownloadCall { + c := &FilesDownloadCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.fileId = fileId + return c +} + +// MimeType sets the optional parameter "mimeType": The MIME type the file +// should be downloaded as. This field can only be set when downloading Google +// Workspace documents. See Export MIME types for Google Workspace documents +// (/drive/api/guides/ref-export-formats) for the list of supported MIME types. +// If not set, a Google Workspace document is downloaded with a default MIME +// type. The default MIME type might change in the future. +func (c *FilesDownloadCall) MimeType(mimeType string) *FilesDownloadCall { + c.urlParams_.Set("mimeType", mimeType) + return c +} + +// RevisionId sets the optional parameter "revisionId": The revision ID of the +// file to download. This field can only be set when downloading blob files, +// Google Docs, and Google Sheets. Returns `INVALID_ARGUMENT` if downloading a +// specific revision on the file is unsupported. +func (c *FilesDownloadCall) RevisionId(revisionId string) *FilesDownloadCall { + c.urlParams_.Set("revisionId", revisionId) + 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 *FilesDownloadCall) Fields(s ...googleapi.Field) *FilesDownloadCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *FilesDownloadCall) Context(ctx context.Context) *FilesDownloadCall { + 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 *FilesDownloadCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *FilesDownloadCall) 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, "files/{fileId}/download") + 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{ + "fileId": c.fileId, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "drive.files.download" 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 *FilesDownloadCall) 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 FilesEmptyTrashCall struct { s *Service urlParams_ gensupport.URLParams @@ -7063,6 +7312,420 @@ func (c *FilesWatchCall) Do(opts ...googleapi.CallOption) (*Channel, error) { return ret, nil } +type OperationCancelCall struct { + s *Service + name string + 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 *OperationService) Cancel(name string) *OperationCancelCall { + c := &OperationCancelCall{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 *OperationCancelCall) Fields(s ...googleapi.Field) *OperationCancelCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *OperationCancelCall) Context(ctx context.Context) *OperationCancelCall { + 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 *OperationCancelCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *OperationCancelCall) 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, "operation/{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 "drive.operation.cancel" call. +func (c *OperationCancelCall) Do(opts ...googleapi.CallOption) error { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if err != nil { + return err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return gensupport.WrapError(err) + } + return nil +} + +type OperationDeleteCall 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 *OperationService) Delete(name string) *OperationDeleteCall { + c := &OperationDeleteCall{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 *OperationDeleteCall) Fields(s ...googleapi.Field) *OperationDeleteCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *OperationDeleteCall) Context(ctx context.Context) *OperationDeleteCall { + 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 *OperationDeleteCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *OperationDeleteCall) 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, "operation/{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 "drive.operation.delete" call. +func (c *OperationDeleteCall) Do(opts ...googleapi.CallOption) error { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if err != nil { + return err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return gensupport.WrapError(err) + } + return nil +} + +type OperationsGetCall 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 *OperationsService) Get(name string) *OperationsGetCall { + c := &OperationsGetCall{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 *OperationsGetCall) Fields(s ...googleapi.Field) *OperationsGetCall { + 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 *OperationsGetCall) IfNoneMatch(entityTag string) *OperationsGetCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *OperationsGetCall) Context(ctx context.Context) *OperationsGetCall { + 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 *OperationsGetCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *OperationsGetCall) 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, "operations/{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 "drive.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 *OperationsGetCall) 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 OperationsListCall struct { + s *Service + 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`. +func (r *OperationsService) List() *OperationsListCall { + c := &OperationsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} + return c +} + +// Filter sets the optional parameter "filter": The standard list filter. +func (c *OperationsListCall) Filter(filter string) *OperationsListCall { + c.urlParams_.Set("filter", filter) + return c +} + +// Name sets the optional parameter "name": The name of the operation's parent +// resource. +func (c *OperationsListCall) Name(name string) *OperationsListCall { + c.urlParams_.Set("name", name) + return c +} + +// PageSize sets the optional parameter "pageSize": The standard list page +// size. +func (c *OperationsListCall) PageSize(pageSize int64) *OperationsListCall { + c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) + return c +} + +// PageToken sets the optional parameter "pageToken": The standard list page +// token. +func (c *OperationsListCall) PageToken(pageToken string) *OperationsListCall { + 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 *OperationsListCall) Fields(s ...googleapi.Field) *OperationsListCall { + 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 *OperationsListCall) IfNoneMatch(entityTag string) *OperationsListCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *OperationsListCall) Context(ctx context.Context) *OperationsListCall { + 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 *OperationsListCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *OperationsListCall) 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, "operations") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("GET", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "drive.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 *OperationsListCall) 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 *OperationsListCall) 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) + } +} + type PermissionsCreateCall struct { s *Service fileId string diff --git a/file/v1/file-api.json b/file/v1/file-api.json index 6718a32f9c5..576e7ee5b2b 100644 --- a/file/v1/file-api.json +++ b/file/v1/file-api.json @@ -902,7 +902,7 @@ } } }, - "revision": "20240821", + "revision": "20240905", "rootUrl": "https://file.googleapis.com/", "schemas": { "Backup": { @@ -1140,6 +1140,18 @@ }, "type": "object" }, + "FixedIOPS": { + "description": "Fixed IOPS (input/output operations per second) parameters.", + "id": "FixedIOPS", + "properties": { + "maxReadIops": { + "description": "Required. Maximum raw read IOPS.", + "format": "int64", + "type": "string" + } + }, + "type": "object" + }, "GoogleCloudSaasacceleratorManagementProvidersV1Instance": { "description": "Instance represents the interface for SLM services to actuate the state of control plane resources. Example Instance in JSON, where consumer-project-number=123456, producer-project-id=cloud-sql: ```json Instance: { \"name\": \"projects/123456/locations/us-east1/instances/prod-instance\", \"create_time\": { \"seconds\": 1526406431, }, \"labels\": { \"env\": \"prod\", \"foo\": \"bar\" }, \"state\": READY, \"software_versions\": { \"software_update\": \"cloud-sql-09-28-2018\", }, \"maintenance_policy_names\": { \"UpdatePolicy\": \"projects/123456/locations/us-east1/maintenancePolicies/prod-update-policy\", } \"tenant_project_id\": \"cloud-sql-test-tenant\", \"producer_metadata\": { \"cloud-sql-tier\": \"basic\", \"cloud-sql-instance-size\": \"1G\", }, \"provisioned_resources\": [ { \"resource-type\": \"compute-instance\", \"resource-url\": \"https://www.googleapis.com/compute/v1/projects/cloud-sql/zones/us-east1-b/instances/vm-1\", } ], \"maintenance_schedules\": { \"csa_rollout\": { \"start_time\": { \"seconds\": 1526406431, }, \"end_time\": { \"seconds\": 1535406431, }, }, \"ncsa_rollout\": { \"start_time\": { \"seconds\": 1526406431, }, \"end_time\": { \"seconds\": 1535406431, }, } }, \"consumer_defined_name\": \"my-sql-instance1\", } ``` LINT.IfChange", "id": "GoogleCloudSaasacceleratorManagementProvidersV1Instance", @@ -1415,10 +1427,27 @@ }, "type": "object" }, + "IOPSPerTB": { + "description": "IOPS per TB. Filestore defines TB as 1024^4 bytes (TiB).", + "id": "IOPSPerTB", + "properties": { + "maxReadIopsPerTb": { + "description": "Required. Maximum read IOPS per TiB.", + "format": "int64", + "type": "string" + } + }, + "type": "object" + }, "Instance": { "description": "A Filestore instance.", "id": "Instance", "properties": { + "configurablePerformanceEnabled": { + "description": "Output only. Indicates whether this instance's performance is configurable. If enabled, adjust it using the 'performance_config' field.", + "readOnly": true, + "type": "boolean" + }, "createTime": { "description": "Output only. The time when the instance was created.", "format": "google-datetime", @@ -1471,6 +1500,15 @@ }, "type": "array" }, + "performanceConfig": { + "$ref": "PerformanceConfig", + "description": "Optional. Used to configure performance." + }, + "performanceLimits": { + "$ref": "PerformanceLimits", + "description": "Output only. Used for getting performance limits.", + "readOnly": true + }, "protocol": { "description": "Immutable. The protocol indicates the access protocol for all shares in the instance. This field is immutable and it cannot be changed after the instance has been created. Default value: `NFS_V3`.", "enum": [ @@ -1975,6 +2013,52 @@ }, "type": "object" }, + "PerformanceConfig": { + "description": "Used for setting the performance configuration. If the user doesn't specify PerformanceConfig, automatically provision the default performance settings as described in https://cloud.google.com/filestore/docs/performance. Larger instances will be linearly set to more IOPS. If the instance's capacity is increased or decreased, its performance will be automatically adjusted upwards or downwards accordingly (respectively).", + "id": "PerformanceConfig", + "properties": { + "fixedIops": { + "$ref": "FixedIOPS", + "description": "Choose a fixed provisioned IOPS value for the instance, which will remain constant regardless of instance capacity. Value must be a multiple of 1000. If the chosen value is outside the supported range for the instance's capacity during instance creation, instance creation will fail with an `InvalidArgument` error. Similarly, if an instance capacity update would result in a value outside the supported range, the update will fail with an `InvalidArgument` error." + }, + "iopsPerTb": { + "$ref": "IOPSPerTB", + "description": "Provision IOPS dynamically based on the capacity of the instance. Provisioned read IOPS will be calculated by multiplying the capacity of the instance in TiB by the `iops_per_tb` value. For example, for a 2 TiB instance with an `iops_per_tb` value of 17000 the provisioned read IOPS will be 34000. If the calculated value is outside the supported range for the instance's capacity during instance creation, instance creation will fail with an `InvalidArgument` error. Similarly, if an instance capacity update would result in a value outside the supported range, the update will fail with an `InvalidArgument` error." + } + }, + "type": "object" + }, + "PerformanceLimits": { + "description": "The enforced performance limits, calculated from the instance's performance configuration.", + "id": "PerformanceLimits", + "properties": { + "maxReadIops": { + "description": "Output only. The max read IOPS.", + "format": "int64", + "readOnly": true, + "type": "string" + }, + "maxReadThroughputBps": { + "description": "Output only. The max read throughput in bytes per second.", + "format": "int64", + "readOnly": true, + "type": "string" + }, + "maxWriteIops": { + "description": "Output only. The max write IOPS.", + "format": "int64", + "readOnly": true, + "type": "string" + }, + "maxWriteThroughputBps": { + "description": "Output only. The max write throughput in bytes per second.", + "format": "int64", + "readOnly": true, + "type": "string" + } + }, + "type": "object" + }, "PromoteReplicaRequest": { "description": "PromoteReplicaRequest promotes a Filestore standby instance (replica).", "id": "PromoteReplicaRequest", diff --git a/file/v1/file-gen.go b/file/v1/file-gen.go index c7d8cd0cb20..4acf8b2bb55 100644 --- a/file/v1/file-gen.go +++ b/file/v1/file-gen.go @@ -474,6 +474,28 @@ func (s FileShareConfig) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// FixedIOPS: Fixed IOPS (input/output operations per second) parameters. +type FixedIOPS struct { + // MaxReadIops: Required. Maximum raw read IOPS. + MaxReadIops int64 `json:"maxReadIops,omitempty,string"` + // ForceSendFields is a list of field names (e.g. "MaxReadIops") 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. "MaxReadIops") 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 FixedIOPS) MarshalJSON() ([]byte, error) { + type NoMethod FixedIOPS + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudSaasacceleratorManagementProvidersV1Instance: Instance represents // the interface for SLM services to actuate the state of control plane // resources. Example Instance in JSON, where consumer-project-number=123456, @@ -852,8 +874,34 @@ func (s GoogleCloudSaasacceleratorManagementProvidersV1SloMetadata) MarshalJSON( return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// IOPSPerTB: IOPS per TB. Filestore defines TB as 1024^4 bytes (TiB). +type IOPSPerTB struct { + // MaxReadIopsPerTb: Required. Maximum read IOPS per TiB. + MaxReadIopsPerTb int64 `json:"maxReadIopsPerTb,omitempty,string"` + // ForceSendFields is a list of field names (e.g. "MaxReadIopsPerTb") 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. "MaxReadIopsPerTb") 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 IOPSPerTB) MarshalJSON() ([]byte, error) { + type NoMethod IOPSPerTB + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // Instance: A Filestore instance. type Instance struct { + // ConfigurablePerformanceEnabled: Output only. Indicates whether this + // instance's performance is configurable. If enabled, adjust it using the + // 'performance_config' field. + ConfigurablePerformanceEnabled bool `json:"configurablePerformanceEnabled,omitempty"` // CreateTime: Output only. The time when the instance was created. CreateTime string `json:"createTime,omitempty"` // DeletionProtectionEnabled: Optional. Indicates whether the instance is @@ -880,6 +928,10 @@ type Instance struct { // Networks: VPC networks to which the instance is connected. For this version, // only a single network is supported. Networks []*NetworkConfig `json:"networks,omitempty"` + // PerformanceConfig: Optional. Used to configure performance. + PerformanceConfig *PerformanceConfig `json:"performanceConfig,omitempty"` + // PerformanceLimits: Output only. Used for getting performance limits. + PerformanceLimits *PerformanceLimits `json:"performanceLimits,omitempty"` // Protocol: Immutable. The protocol indicates the access protocol for all // shares in the instance. This field is immutable and it cannot be changed // after the instance has been created. Default value: `NFS_V3`. @@ -956,15 +1008,16 @@ type Instance struct { // ServerResponse contains the HTTP response code and headers from the server. googleapi.ServerResponse `json:"-"` - // ForceSendFields is a list of field names (e.g. "CreateTime") to - // unconditionally include in API requests. By default, fields with empty or - // default values are omitted from API requests. See + // ForceSendFields is a list of field names (e.g. + // "ConfigurablePerformanceEnabled") 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. "CreateTime") to include in API - // requests with the JSON null value. By default, fields with empty values are - // omitted from API requests. See + // NullFields is a list of field names (e.g. "ConfigurablePerformanceEnabled") + // 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:"-"` } @@ -1439,6 +1492,81 @@ func (s OperationMetadata) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// PerformanceConfig: Used for setting the performance configuration. If the +// user doesn't specify PerformanceConfig, automatically provision the default +// performance settings as described in +// https://cloud.google.com/filestore/docs/performance. Larger instances will +// be linearly set to more IOPS. If the instance's capacity is increased or +// decreased, its performance will be automatically adjusted upwards or +// downwards accordingly (respectively). +type PerformanceConfig struct { + // FixedIops: Choose a fixed provisioned IOPS value for the instance, which + // will remain constant regardless of instance capacity. Value must be a + // multiple of 1000. If the chosen value is outside the supported range for the + // instance's capacity during instance creation, instance creation will fail + // with an `InvalidArgument` error. Similarly, if an instance capacity update + // would result in a value outside the supported range, the update will fail + // with an `InvalidArgument` error. + FixedIops *FixedIOPS `json:"fixedIops,omitempty"` + // IopsPerTb: Provision IOPS dynamically based on the capacity of the instance. + // Provisioned read IOPS will be calculated by multiplying the capacity of the + // instance in TiB by the `iops_per_tb` value. For example, for a 2 TiB + // instance with an `iops_per_tb` value of 17000 the provisioned read IOPS will + // be 34000. If the calculated value is outside the supported range for the + // instance's capacity during instance creation, instance creation will fail + // with an `InvalidArgument` error. Similarly, if an instance capacity update + // would result in a value outside the supported range, the update will fail + // with an `InvalidArgument` error. + IopsPerTb *IOPSPerTB `json:"iopsPerTb,omitempty"` + // ForceSendFields is a list of field names (e.g. "FixedIops") 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. "FixedIops") 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 PerformanceConfig) MarshalJSON() ([]byte, error) { + type NoMethod PerformanceConfig + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// PerformanceLimits: The enforced performance limits, calculated from the +// instance's performance configuration. +type PerformanceLimits struct { + // MaxReadIops: Output only. The max read IOPS. + MaxReadIops int64 `json:"maxReadIops,omitempty,string"` + // MaxReadThroughputBps: Output only. The max read throughput in bytes per + // second. + MaxReadThroughputBps int64 `json:"maxReadThroughputBps,omitempty,string"` + // MaxWriteIops: Output only. The max write IOPS. + MaxWriteIops int64 `json:"maxWriteIops,omitempty,string"` + // MaxWriteThroughputBps: Output only. The max write throughput in bytes per + // second. + MaxWriteThroughputBps int64 `json:"maxWriteThroughputBps,omitempty,string"` + // ForceSendFields is a list of field names (e.g. "MaxReadIops") 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. "MaxReadIops") 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 PerformanceLimits) MarshalJSON() ([]byte, error) { + type NoMethod PerformanceLimits + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // PromoteReplicaRequest: PromoteReplicaRequest promotes a Filestore standby // instance (replica). type PromoteReplicaRequest struct { diff --git a/file/v1beta1/file-api.json b/file/v1beta1/file-api.json index 1beeeb63c73..22b3110e59a 100644 --- a/file/v1beta1/file-api.json +++ b/file/v1beta1/file-api.json @@ -502,7 +502,7 @@ "type": "string" }, "updateMask": { - "description": "Required. Mask of fields to update. At least one path must be supplied in this field. The elements of the repeated paths field may only include these fields: * \"description\" * \"directory_services\" * \"file_shares\" * \"labels\"", + "description": "Required. Mask of fields to update. At least one path must be supplied in this field. The elements of the repeated paths field may only include these fields: * \"description\" * \"directory_services\" * \"file_shares\" * \"labels\" * \"performance_config\" * \"deletion_protection_enabled\" * \"deletion_protection_reason\"", "format": "google-fieldmask", "location": "query", "type": "string" @@ -520,7 +520,7 @@ ] }, "promoteReplica": { - "description": "Promote an standby instance (replica).", + "description": "Promote the standby instance (replica).", "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/instances/{instancesId}:promoteReplica", "httpMethod": "POST", "id": "file.projects.locations.instances.promoteReplica", @@ -1069,7 +1069,7 @@ } } }, - "revision": "20240716", + "revision": "20240905", "rootUrl": "https://file.googleapis.com/", "schemas": { "Backup": { @@ -1205,7 +1205,7 @@ "additionalProperties": { "type": "string" }, - "description": "Optional. Input only. Immutable. Tag keys/values directly bound to this resource. For example: \"123/environment\": \"production\", \"123/costCenter\": \"marketing\"", + "description": "Optional. Input only. Immutable. Tag key-value pairs are bound to this resource. For example: \"123/environment\": \"production\", \"123/costCenter\": \"marketing\"", "type": "object" } }, @@ -1318,6 +1318,18 @@ }, "type": "object" }, + "FixedIOPS": { + "description": "Fixed IOPS (input/output operations per second) parameters.", + "id": "FixedIOPS", + "properties": { + "maxReadIops": { + "description": "Required. Maximum raw read IOPS.", + "format": "int64", + "type": "string" + } + }, + "type": "object" + }, "GoogleCloudSaasacceleratorManagementProvidersV1Instance": { "description": "Instance represents the interface for SLM services to actuate the state of control plane resources. Example Instance in JSON, where consumer-project-number=123456, producer-project-id=cloud-sql: ```json Instance: { \"name\": \"projects/123456/locations/us-east1/instances/prod-instance\", \"create_time\": { \"seconds\": 1526406431, }, \"labels\": { \"env\": \"prod\", \"foo\": \"bar\" }, \"state\": READY, \"software_versions\": { \"software_update\": \"cloud-sql-09-28-2018\", }, \"maintenance_policy_names\": { \"UpdatePolicy\": \"projects/123456/locations/us-east1/maintenancePolicies/prod-update-policy\", } \"tenant_project_id\": \"cloud-sql-test-tenant\", \"producer_metadata\": { \"cloud-sql-tier\": \"basic\", \"cloud-sql-instance-size\": \"1G\", }, \"provisioned_resources\": [ { \"resource-type\": \"compute-instance\", \"resource-url\": \"https://www.googleapis.com/compute/v1/projects/cloud-sql/zones/us-east1-b/instances/vm-1\", } ], \"maintenance_schedules\": { \"csa_rollout\": { \"start_time\": { \"seconds\": 1526406431, }, \"end_time\": { \"seconds\": 1535406431, }, }, \"ncsa_rollout\": { \"start_time\": { \"seconds\": 1526406431, }, \"end_time\": { \"seconds\": 1535406431, }, } }, \"consumer_defined_name\": \"my-sql-instance1\", } ``` LINT.IfChange", "id": "GoogleCloudSaasacceleratorManagementProvidersV1Instance", @@ -1593,6 +1605,18 @@ }, "type": "object" }, + "IOPSPerTB": { + "description": "IOPS per TB. Filestore defines TB as 1024^4 bytes (TiB).", + "id": "IOPSPerTB", + "properties": { + "maxReadIopsPerTb": { + "description": "Required. Maximum read IOPS per TiB.", + "format": "int64", + "type": "string" + } + }, + "type": "object" + }, "Instance": { "description": "A Filestore instance.", "id": "Instance", @@ -1608,12 +1632,25 @@ "readOnly": true, "type": "string" }, + "configurablePerformanceEnabled": { + "description": "Output only. Indicates whether this instance's performance is configurable. If enabled, adjust it using the 'performance_config' field.", + "readOnly": true, + "type": "boolean" + }, "createTime": { "description": "Output only. The time when the instance was created.", "format": "google-datetime", "readOnly": true, "type": "string" }, + "deletionProtectionEnabled": { + "description": "Optional. Indicates whether the instance is protected against deletion.", + "type": "boolean" + }, + "deletionProtectionReason": { + "description": "Optional. The reason for enabling deletion protection.", + "type": "string" + }, "description": { "description": "The description of the instance (2048 characters or less).", "type": "string" @@ -1671,6 +1708,15 @@ }, "type": "array" }, + "performanceConfig": { + "$ref": "PerformanceConfig", + "description": "Optional. Used to configure performance." + }, + "performanceLimits": { + "$ref": "PerformanceLimits", + "description": "Output only. Used for getting performance limits.", + "readOnly": true + }, "protocol": { "description": "Immutable. The protocol indicates the access protocol for all shares in the instance. This field is immutable and it cannot be changed after the instance has been created. Default value: `NFS_V3`.", "enum": [ @@ -1687,7 +1733,7 @@ }, "replication": { "$ref": "Replication", - "description": "Optional. Replicaition configuration." + "description": "Optional. Replication configuration." }, "satisfiesPzi": { "description": "Output only. Reserved for future use.", @@ -1757,7 +1803,7 @@ "additionalProperties": { "type": "string" }, - "description": "Optional. Input only. Immutable. Tag keys/values directly bound to this resource. For example: \"123/environment\": \"production\", \"123/costCenter\": \"marketing\"", + "description": "Optional. Input only. Immutable. Tag key-value pairs are bound to this resource. For example: \"123/environment\": \"production\", \"123/costCenter\": \"marketing\"", "type": "object" }, "tier": { @@ -2018,11 +2064,11 @@ "type": "object" }, "ManagedActiveDirectoryConfig": { - "description": "ManagedActiveDirectoryConfig contains all the parameters for connecting to Managed Active Directory.", + "description": "ManagedActiveDirectoryConfig contains all the parameters for connecting to Managed Service for Microsoft Active Directory (Managed Microsoft AD).", "id": "ManagedActiveDirectoryConfig", "properties": { "computer": { - "description": "Required. The computer name is used as a prefix to the mount remote target. Example: if the computer is `my-computer`, the mount command will look like: `$mount -o vers=4.1,sec=krb5 my-computer.filestore.: `.", + "description": "Required. The computer name is used as a prefix in the command to mount the remote target. For example: if the computer is `my-computer`, the mount command will look like: `$mount -o vers=4.1,sec=krb5 my-computer.filestore.: `.", "type": "string" }, "domain": { @@ -2236,6 +2282,52 @@ }, "type": "object" }, + "PerformanceConfig": { + "description": "Used for setting the performance configuration. If the user doesn't specify PerformanceConfig, automatically provision the default performance settings as described in https://cloud.google.com/filestore/docs/performance. Larger instances will be linearly set to more IOPS. If the instance's capacity is increased or decreased, its performance will be automatically adjusted upwards or downwards accordingly (respectively).", + "id": "PerformanceConfig", + "properties": { + "fixedIops": { + "$ref": "FixedIOPS", + "description": "Choose a fixed provisioned IOPS value for the instance, which will remain constant regardless of instance capacity. Value must be a multiple of 1000. If the chosen value is outside the supported range for the instance's capacity during instance creation, instance creation will fail with an `InvalidArgument` error. Similarly, if an instance capacity update would result in a value outside the supported range, the update will fail with an `InvalidArgument` error." + }, + "iopsPerTb": { + "$ref": "IOPSPerTB", + "description": "Provision IOPS dynamically based on the capacity of the instance. Provisioned read IOPS will be calculated by multiplying the capacity of the instance in TiB by the `iops_per_tb` value. For example, for a 2 TiB instance with an `iops_per_tb` value of 17000 the provisioned read IOPS will be 34000. If the calculated value is outside the supported range for the instance's capacity during instance creation, instance creation will fail with an `InvalidArgument` error. Similarly, if an instance capacity update would result in a value outside the supported range, the update will fail with an `InvalidArgument` error." + } + }, + "type": "object" + }, + "PerformanceLimits": { + "description": "The enforced performance limits, calculated from the instance's performance configuration.", + "id": "PerformanceLimits", + "properties": { + "maxReadIops": { + "description": "Output only. The max read IOPS.", + "format": "int64", + "readOnly": true, + "type": "string" + }, + "maxReadThroughputBps": { + "description": "Output only. The max read throughput in bytes per second.", + "format": "int64", + "readOnly": true, + "type": "string" + }, + "maxWriteIops": { + "description": "Output only. The max write IOPS.", + "format": "int64", + "readOnly": true, + "type": "string" + }, + "maxWriteThroughputBps": { + "description": "Output only. The max write throughput in bytes per second.", + "format": "int64", + "readOnly": true, + "type": "string" + } + }, + "type": "object" + }, "PromoteReplicaRequest": { "description": "PromoteReplicaRequest promotes a Filestore standby instance (replica).", "id": "PromoteReplicaRequest", @@ -2296,7 +2388,7 @@ "id": "Replication", "properties": { "replicas": { - "description": "Replicas configuration on the instance. For now, only a single replica config is supported.", + "description": "Replication configuration for the replica instance associated with this instance. Only a single replica is supported.", "items": { "$ref": "ReplicaConfig" }, @@ -2311,8 +2403,8 @@ ], "enumDescriptions": [ "Role not set.", - "The instance is a Active replication member, functions as the replication source instance.", - "The instance is a Standby replication member, functions as the replication destination instance." + "The instance is the `ACTIVE` replication member, functions as the replication source instance.", + "The instance is the `STANDBY` replication member, functions as the replication destination instance." ], "type": "string" } @@ -2509,7 +2601,7 @@ "additionalProperties": { "type": "string" }, - "description": "Optional. Input only. Immutable. Tag keys/values directly bound to this resource. For example: \"123/environment\": \"production\", \"123/costCenter\": \"marketing\"", + "description": "Optional. Input only. Immutable. Tag key-value pairs are bound to this resource. For example: \"123/environment\": \"production\", \"123/costCenter\": \"marketing\"", "type": "object" } }, diff --git a/file/v1beta1/file-gen.go b/file/v1beta1/file-gen.go index df3960857b9..5c40637c6c6 100644 --- a/file/v1beta1/file-gen.go +++ b/file/v1beta1/file-gen.go @@ -315,9 +315,9 @@ type Backup struct { // backups share storage, this number is expected to change with backup // creation/deletion. StorageBytes int64 `json:"storageBytes,omitempty,string"` - // Tags: Optional. Input only. Immutable. Tag keys/values directly bound to - // this resource. For example: "123/environment": "production", - // "123/costCenter": "marketing" + // Tags: Optional. Input only. Immutable. Tag key-value pairs are bound to this + // resource. For example: "123/environment": "production", "123/costCenter": + // "marketing" Tags map[string]string `json:"tags,omitempty"` // ServerResponse contains the HTTP response code and headers from the server. @@ -509,6 +509,28 @@ func (s FileShareConfig) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// FixedIOPS: Fixed IOPS (input/output operations per second) parameters. +type FixedIOPS struct { + // MaxReadIops: Required. Maximum raw read IOPS. + MaxReadIops int64 `json:"maxReadIops,omitempty,string"` + // ForceSendFields is a list of field names (e.g. "MaxReadIops") 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. "MaxReadIops") 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 FixedIOPS) MarshalJSON() ([]byte, error) { + type NoMethod FixedIOPS + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudSaasacceleratorManagementProvidersV1Instance: Instance represents // the interface for SLM services to actuate the state of control plane // resources. Example Instance in JSON, where consumer-project-number=123456, @@ -887,6 +909,28 @@ func (s GoogleCloudSaasacceleratorManagementProvidersV1SloMetadata) MarshalJSON( return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// IOPSPerTB: IOPS per TB. Filestore defines TB as 1024^4 bytes (TiB). +type IOPSPerTB struct { + // MaxReadIopsPerTb: Required. Maximum read IOPS per TiB. + MaxReadIopsPerTb int64 `json:"maxReadIopsPerTb,omitempty,string"` + // ForceSendFields is a list of field names (e.g. "MaxReadIopsPerTb") 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. "MaxReadIopsPerTb") 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 IOPSPerTB) MarshalJSON() ([]byte, error) { + type NoMethod IOPSPerTB + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // Instance: A Filestore instance. type Instance struct { // CapacityGb: The storage capacity of the instance in gigabytes (GB = 1024^3 @@ -895,8 +939,18 @@ type Instance struct { CapacityGb int64 `json:"capacityGb,omitempty,string"` // CapacityStepSizeGb: Output only. The increase/decrease capacity step size. CapacityStepSizeGb int64 `json:"capacityStepSizeGb,omitempty,string"` + // ConfigurablePerformanceEnabled: Output only. Indicates whether this + // instance's performance is configurable. If enabled, adjust it using the + // 'performance_config' field. + ConfigurablePerformanceEnabled bool `json:"configurablePerformanceEnabled,omitempty"` // CreateTime: Output only. The time when the instance was created. CreateTime string `json:"createTime,omitempty"` + // DeletionProtectionEnabled: Optional. Indicates whether the instance is + // protected against deletion. + DeletionProtectionEnabled bool `json:"deletionProtectionEnabled,omitempty"` + // DeletionProtectionReason: Optional. The reason for enabling deletion + // protection. + DeletionProtectionReason string `json:"deletionProtectionReason,omitempty"` // Description: The description of the instance (2048 characters or less). Description string `json:"description,omitempty"` // DirectoryServices: Optional. Directory Services configuration for @@ -927,6 +981,10 @@ type Instance struct { // Networks: VPC networks to which the instance is connected. For this version, // only a single network is supported. Networks []*NetworkConfig `json:"networks,omitempty"` + // PerformanceConfig: Optional. Used to configure performance. + PerformanceConfig *PerformanceConfig `json:"performanceConfig,omitempty"` + // PerformanceLimits: Output only. Used for getting performance limits. + PerformanceLimits *PerformanceLimits `json:"performanceLimits,omitempty"` // Protocol: Immutable. The protocol indicates the access protocol for all // shares in the instance. This field is immutable and it cannot be changed // after the instance has been created. Default value: `NFS_V3`. @@ -937,7 +995,7 @@ type Instance struct { // "NFS_V3" - NFS 3.0. // "NFS_V4_1" - NFS 4.1. Protocol string `json:"protocol,omitempty"` - // Replication: Optional. Replicaition configuration. + // Replication: Optional. Replication configuration. Replication *Replication `json:"replication,omitempty"` // SatisfiesPzi: Output only. Reserved for future use. SatisfiesPzi bool `json:"satisfiesPzi,omitempty"` @@ -975,9 +1033,9 @@ type Instance struct { // "KMS_KEY_ISSUE" - The KMS key used by the instance is either revoked or // denied access to. SuspensionReasons []string `json:"suspensionReasons,omitempty"` - // Tags: Optional. Input only. Immutable. Tag keys/values directly bound to - // this resource. For example: "123/environment": "production", - // "123/costCenter": "marketing" + // Tags: Optional. Input only. Immutable. Tag key-value pairs are bound to this + // resource. For example: "123/environment": "production", "123/costCenter": + // "marketing" Tags map[string]string `json:"tags,omitempty"` // Tier: The service tier of the instance. // @@ -1317,11 +1375,13 @@ func (s MaintenanceWindow) MarshalJSON() ([]byte, error) { } // ManagedActiveDirectoryConfig: ManagedActiveDirectoryConfig contains all the -// parameters for connecting to Managed Active Directory. +// parameters for connecting to Managed Service for Microsoft Active Directory +// (Managed Microsoft AD). type ManagedActiveDirectoryConfig struct { - // Computer: Required. The computer name is used as a prefix to the mount - // remote target. Example: if the computer is `my-computer`, the mount command - // will look like: `$mount -o vers=4.1,sec=krb5 my-computer.filestore.: `. + // Computer: Required. The computer name is used as a prefix in the command to + // mount the remote target. For example: if the computer is `my-computer`, the + // mount command will look like: `$mount -o vers=4.1,sec=krb5 + // my-computer.filestore.: `. Computer string `json:"computer,omitempty"` // Domain: Required. The domain resource name, in the format // `projects/{project_id}/locations/global/domains/{domain}`. @@ -1557,6 +1617,81 @@ func (s OperationMetadata) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// PerformanceConfig: Used for setting the performance configuration. If the +// user doesn't specify PerformanceConfig, automatically provision the default +// performance settings as described in +// https://cloud.google.com/filestore/docs/performance. Larger instances will +// be linearly set to more IOPS. If the instance's capacity is increased or +// decreased, its performance will be automatically adjusted upwards or +// downwards accordingly (respectively). +type PerformanceConfig struct { + // FixedIops: Choose a fixed provisioned IOPS value for the instance, which + // will remain constant regardless of instance capacity. Value must be a + // multiple of 1000. If the chosen value is outside the supported range for the + // instance's capacity during instance creation, instance creation will fail + // with an `InvalidArgument` error. Similarly, if an instance capacity update + // would result in a value outside the supported range, the update will fail + // with an `InvalidArgument` error. + FixedIops *FixedIOPS `json:"fixedIops,omitempty"` + // IopsPerTb: Provision IOPS dynamically based on the capacity of the instance. + // Provisioned read IOPS will be calculated by multiplying the capacity of the + // instance in TiB by the `iops_per_tb` value. For example, for a 2 TiB + // instance with an `iops_per_tb` value of 17000 the provisioned read IOPS will + // be 34000. If the calculated value is outside the supported range for the + // instance's capacity during instance creation, instance creation will fail + // with an `InvalidArgument` error. Similarly, if an instance capacity update + // would result in a value outside the supported range, the update will fail + // with an `InvalidArgument` error. + IopsPerTb *IOPSPerTB `json:"iopsPerTb,omitempty"` + // ForceSendFields is a list of field names (e.g. "FixedIops") 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. "FixedIops") 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 PerformanceConfig) MarshalJSON() ([]byte, error) { + type NoMethod PerformanceConfig + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// PerformanceLimits: The enforced performance limits, calculated from the +// instance's performance configuration. +type PerformanceLimits struct { + // MaxReadIops: Output only. The max read IOPS. + MaxReadIops int64 `json:"maxReadIops,omitempty,string"` + // MaxReadThroughputBps: Output only. The max read throughput in bytes per + // second. + MaxReadThroughputBps int64 `json:"maxReadThroughputBps,omitempty,string"` + // MaxWriteIops: Output only. The max write IOPS. + MaxWriteIops int64 `json:"maxWriteIops,omitempty,string"` + // MaxWriteThroughputBps: Output only. The max write throughput in bytes per + // second. + MaxWriteThroughputBps int64 `json:"maxWriteThroughputBps,omitempty,string"` + // ForceSendFields is a list of field names (e.g. "MaxReadIops") 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. "MaxReadIops") 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 PerformanceLimits) MarshalJSON() ([]byte, error) { + type NoMethod PerformanceLimits + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // PromoteReplicaRequest: PromoteReplicaRequest promotes a Filestore standby // instance (replica). type PromoteReplicaRequest struct { @@ -1607,17 +1742,17 @@ func (s ReplicaConfig) MarshalJSON() ([]byte, error) { // Replication: Replication specifications. type Replication struct { - // Replicas: Replicas configuration on the instance. For now, only a single - // replica config is supported. + // Replicas: Replication configuration for the replica instance associated with + // this instance. Only a single replica is supported. Replicas []*ReplicaConfig `json:"replicas,omitempty"` // Role: Output only. The replication role. // // Possible values: // "ROLE_UNSPECIFIED" - Role not set. - // "ACTIVE" - The instance is a Active replication member, functions as the - // replication source instance. - // "STANDBY" - The instance is a Standby replication member, functions as the - // replication destination instance. + // "ACTIVE" - The instance is the `ACTIVE` replication member, functions as + // the replication source instance. + // "STANDBY" - The instance is the `STANDBY` replication member, functions as + // the replication destination instance. Role string `json:"role,omitempty"` // ForceSendFields is a list of field names (e.g. "Replicas") to // unconditionally include in API requests. By default, fields with empty or @@ -1810,9 +1945,9 @@ type Snapshot struct { // "READY" - Snapshot is available for use. // "DELETING" - Snapshot is being deleted. State string `json:"state,omitempty"` - // Tags: Optional. Input only. Immutable. Tag keys/values directly bound to - // this resource. For example: "123/environment": "production", - // "123/costCenter": "marketing" + // Tags: Optional. Input only. Immutable. Tag key-value pairs are bound to this + // resource. For example: "123/environment": "production", "123/costCenter": + // "marketing" Tags map[string]string `json:"tags,omitempty"` // ServerResponse contains the HTTP response code and headers from the server. @@ -3336,7 +3471,9 @@ func (r *ProjectsLocationsInstancesService) Patch(name string, instance *Instanc // UpdateMask sets the optional parameter "updateMask": Required. Mask of // fields to update. At least one path must be supplied in this field. The // elements of the repeated paths field may only include these fields: * -// "description" * "directory_services" * "file_shares" * "labels" +// "description" * "directory_services" * "file_shares" * "labels" * +// "performance_config" * "deletion_protection_enabled" * +// "deletion_protection_reason" func (c *ProjectsLocationsInstancesPatchCall) UpdateMask(updateMask string) *ProjectsLocationsInstancesPatchCall { c.urlParams_.Set("updateMask", updateMask) return c @@ -3433,7 +3570,7 @@ type ProjectsLocationsInstancesPromoteReplicaCall struct { header_ http.Header } -// PromoteReplica: Promote an standby instance (replica). +// PromoteReplica: Promote the standby instance (replica). // // - name: The resource name of the instance, in the format // `projects/{project_id}/locations/{location_id}/instances/{instance_id}`. diff --git a/firebaseml/v2beta/firebaseml-api.json b/firebaseml/v2beta/firebaseml-api.json index 2cd463a3edf..1f27f80e36c 100644 --- a/firebaseml/v2beta/firebaseml-api.json +++ b/firebaseml/v2beta/firebaseml-api.json @@ -206,7 +206,7 @@ } } }, - "revision": "20240821", + "revision": "20240902", "rootUrl": "https://firebaseml.googleapis.com/", "schemas": { "Date": { @@ -1096,14 +1096,16 @@ "BLOCK_LOW_AND_ABOVE", "BLOCK_MEDIUM_AND_ABOVE", "BLOCK_ONLY_HIGH", - "BLOCK_NONE" + "BLOCK_NONE", + "OFF" ], "enumDescriptions": [ "Unspecified harm block threshold.", "Block low threshold and above (i.e. block more).", "Block medium threshold and above.", "Block only high threshold (i.e. block less).", - "Block none." + "Block none.", + "Turn off the safety filter." ], "type": "string" } diff --git a/firebaseml/v2beta/firebaseml-gen.go b/firebaseml/v2beta/firebaseml-gen.go index b00236e16c4..cb40b58b281 100644 --- a/firebaseml/v2beta/firebaseml-gen.go +++ b/firebaseml/v2beta/firebaseml-gen.go @@ -1302,6 +1302,7 @@ type GoogleCloudAiplatformV1beta1SafetySetting struct { // "BLOCK_MEDIUM_AND_ABOVE" - Block medium threshold and above. // "BLOCK_ONLY_HIGH" - Block only high threshold (i.e. block less). // "BLOCK_NONE" - Block none. + // "OFF" - Turn off the safety filter. Threshold string `json:"threshold,omitempty"` // ForceSendFields is a list of field names (e.g. "Category") to // unconditionally include in API requests. By default, fields with empty or diff --git a/gkehub/v1/gkehub-api.json b/gkehub/v1/gkehub-api.json index 27a32c45a25..26f92d25710 100644 --- a/gkehub/v1/gkehub-api.json +++ b/gkehub/v1/gkehub-api.json @@ -2111,7 +2111,7 @@ } } }, - "revision": "20240825", + "revision": "20240902", "rootUrl": "https://gkehub.googleapis.com/", "schemas": { "AppDevExperienceFeatureSpec": { @@ -4164,6 +4164,22 @@ }, "type": "object" }, + "IdentityServiceDiagnosticInterface": { + "description": "Configuration options for the AIS diagnostic interface.", + "id": "IdentityServiceDiagnosticInterface", + "properties": { + "enabled": { + "description": "Determines whether to enable the diagnostic interface.", + "type": "boolean" + }, + "expirationTime": { + "description": "Determines the expiration time of the diagnostic interface enablement. When reached, requests to the interface would be automatically rejected.", + "format": "google-datetime", + "type": "string" + } + }, + "type": "object" + }, "IdentityServiceGoogleConfig": { "description": "Configuration for the Google Plugin Auth flow.", "id": "IdentityServiceGoogleConfig", @@ -4198,8 +4214,12 @@ "description": "Holds non-protocol-related configuration options.", "id": "IdentityServiceIdentityServiceOptions", "properties": { + "diagnosticInterface": { + "$ref": "IdentityServiceDiagnosticInterface", + "description": "Configuration options for the AIS diagnostic interface." + }, "sessionDuration": { - "description": "Optional. Determines the lifespan of STS tokens issued by Anthos Identity Service.", + "description": "Determines the lifespan of STS tokens issued by Anthos Identity Service.", "format": "google-duration", "type": "string" } @@ -6082,6 +6102,7 @@ "NODEPOOL_WORKLOAD_IDENTITY_FEDERATION_REQUIRED", "CNI_INSTALLATION_FAILED", "CNI_POD_UNSCHEDULABLE", + "CLUSTER_HAS_ZERO_NODES", "UNSUPPORTED_MULTIPLE_CONTROL_PLANES", "VPCSC_GA_SUPPORTED", "CONFIG_APPLY_INTERNAL_ERROR", @@ -6112,6 +6133,7 @@ "Nodepool workload identity federation required error code", "CNI installation failed error code", "CNI pod unschedulable error code", + "Cluster has zero node code", "Multiple control planes unsupported error code", "VPC-SC GA is supported for this control plane.", "Configuration (Istio/k8s resources) failed to apply due to internal error.", diff --git a/gkehub/v1/gkehub-gen.go b/gkehub/v1/gkehub-gen.go index 08ddf3cbfae..897b874221c 100644 --- a/gkehub/v1/gkehub-gen.go +++ b/gkehub/v1/gkehub-gen.go @@ -2876,6 +2876,33 @@ func (s IdentityServiceAzureADConfig) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// IdentityServiceDiagnosticInterface: Configuration options for the AIS +// diagnostic interface. +type IdentityServiceDiagnosticInterface struct { + // Enabled: Determines whether to enable the diagnostic interface. + Enabled bool `json:"enabled,omitempty"` + // ExpirationTime: Determines the expiration time of the diagnostic interface + // enablement. When reached, requests to the interface would be automatically + // rejected. + ExpirationTime string `json:"expirationTime,omitempty"` + // ForceSendFields is a list of field names (e.g. "Enabled") 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. "Enabled") 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 IdentityServiceDiagnosticInterface) MarshalJSON() ([]byte, error) { + type NoMethod IdentityServiceDiagnosticInterface + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // IdentityServiceGoogleConfig: Configuration for the Google Plugin Auth flow. type IdentityServiceGoogleConfig struct { // Disable: Disable automatic configuration of Google Plugin on supported @@ -2936,18 +2963,20 @@ func (s IdentityServiceGroupConfig) MarshalJSON() ([]byte, error) { // IdentityServiceIdentityServiceOptions: Holds non-protocol-related // configuration options. type IdentityServiceIdentityServiceOptions struct { - // SessionDuration: Optional. Determines the lifespan of STS tokens issued by - // Anthos Identity Service. + // DiagnosticInterface: Configuration options for the AIS diagnostic interface. + DiagnosticInterface *IdentityServiceDiagnosticInterface `json:"diagnosticInterface,omitempty"` + // SessionDuration: Determines the lifespan of STS tokens issued by Anthos + // Identity Service. SessionDuration string `json:"sessionDuration,omitempty"` - // ForceSendFields is a list of field names (e.g. "SessionDuration") to + // ForceSendFields is a list of field names (e.g. "DiagnosticInterface") 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. "SessionDuration") to include in - // API requests with the JSON null value. By default, fields with empty values - // are omitted from API requests. See + // NullFields is a list of field names (e.g. "DiagnosticInterface") 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:"-"` } @@ -5329,6 +5358,7 @@ type ServiceMeshCondition struct { // identity federation required error code // "CNI_INSTALLATION_FAILED" - CNI installation failed error code // "CNI_POD_UNSCHEDULABLE" - CNI pod unschedulable error code + // "CLUSTER_HAS_ZERO_NODES" - Cluster has zero node code // "UNSUPPORTED_MULTIPLE_CONTROL_PLANES" - Multiple control planes // unsupported error code // "VPCSC_GA_SUPPORTED" - VPC-SC GA is supported for this control plane. diff --git a/gkehub/v1alpha/gkehub-api.json b/gkehub/v1alpha/gkehub-api.json index c70b5447ce4..d7fbeea8acd 100644 --- a/gkehub/v1alpha/gkehub-api.json +++ b/gkehub/v1alpha/gkehub-api.json @@ -2185,7 +2185,7 @@ } } }, - "revision": "20240825", + "revision": "20240902", "rootUrl": "https://gkehub.googleapis.com/", "schemas": { "AnthosObservabilityFeatureSpec": { @@ -4477,6 +4477,22 @@ }, "type": "object" }, + "IdentityServiceDiagnosticInterface": { + "description": "Configuration options for the AIS diagnostic interface.", + "id": "IdentityServiceDiagnosticInterface", + "properties": { + "enabled": { + "description": "Determines whether to enable the diagnostic interface.", + "type": "boolean" + }, + "expirationTime": { + "description": "Determines the expiration time of the diagnostic interface enablement. When reached, requests to the interface would be automatically rejected.", + "format": "google-datetime", + "type": "string" + } + }, + "type": "object" + }, "IdentityServiceGoogleConfig": { "description": "Configuration for the Google Plugin Auth flow.", "id": "IdentityServiceGoogleConfig", @@ -4511,8 +4527,12 @@ "description": "Holds non-protocol-related configuration options.", "id": "IdentityServiceIdentityServiceOptions", "properties": { + "diagnosticInterface": { + "$ref": "IdentityServiceDiagnosticInterface", + "description": "Configuration options for the AIS diagnostic interface." + }, "sessionDuration": { - "description": "Optional. Determines the lifespan of STS tokens issued by Anthos Identity Service.", + "description": "Determines the lifespan of STS tokens issued by Anthos Identity Service.", "format": "google-duration", "type": "string" } @@ -6606,6 +6626,7 @@ "NODEPOOL_WORKLOAD_IDENTITY_FEDERATION_REQUIRED", "CNI_INSTALLATION_FAILED", "CNI_POD_UNSCHEDULABLE", + "CLUSTER_HAS_ZERO_NODES", "UNSUPPORTED_MULTIPLE_CONTROL_PLANES", "VPCSC_GA_SUPPORTED", "CONFIG_APPLY_INTERNAL_ERROR", @@ -6636,6 +6657,7 @@ "Nodepool workload identity federation required error code", "CNI installation failed error code", "CNI pod unschedulable error code", + "Cluster has zero node code", "Multiple control planes unsupported error code", "VPC-SC GA is supported for this control plane.", "Configuration (Istio/k8s resources) failed to apply due to internal error.", diff --git a/gkehub/v1alpha/gkehub-gen.go b/gkehub/v1alpha/gkehub-gen.go index 185bba93070..d252d2337a6 100644 --- a/gkehub/v1alpha/gkehub-gen.go +++ b/gkehub/v1alpha/gkehub-gen.go @@ -3185,6 +3185,33 @@ func (s IdentityServiceAzureADConfig) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// IdentityServiceDiagnosticInterface: Configuration options for the AIS +// diagnostic interface. +type IdentityServiceDiagnosticInterface struct { + // Enabled: Determines whether to enable the diagnostic interface. + Enabled bool `json:"enabled,omitempty"` + // ExpirationTime: Determines the expiration time of the diagnostic interface + // enablement. When reached, requests to the interface would be automatically + // rejected. + ExpirationTime string `json:"expirationTime,omitempty"` + // ForceSendFields is a list of field names (e.g. "Enabled") 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. "Enabled") 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 IdentityServiceDiagnosticInterface) MarshalJSON() ([]byte, error) { + type NoMethod IdentityServiceDiagnosticInterface + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // IdentityServiceGoogleConfig: Configuration for the Google Plugin Auth flow. type IdentityServiceGoogleConfig struct { // Disable: Disable automatic configuration of Google Plugin on supported @@ -3245,18 +3272,20 @@ func (s IdentityServiceGroupConfig) MarshalJSON() ([]byte, error) { // IdentityServiceIdentityServiceOptions: Holds non-protocol-related // configuration options. type IdentityServiceIdentityServiceOptions struct { - // SessionDuration: Optional. Determines the lifespan of STS tokens issued by - // Anthos Identity Service. + // DiagnosticInterface: Configuration options for the AIS diagnostic interface. + DiagnosticInterface *IdentityServiceDiagnosticInterface `json:"diagnosticInterface,omitempty"` + // SessionDuration: Determines the lifespan of STS tokens issued by Anthos + // Identity Service. SessionDuration string `json:"sessionDuration,omitempty"` - // ForceSendFields is a list of field names (e.g. "SessionDuration") to + // ForceSendFields is a list of field names (e.g. "DiagnosticInterface") 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. "SessionDuration") to include in - // API requests with the JSON null value. By default, fields with empty values - // are omitted from API requests. See + // NullFields is a list of field names (e.g. "DiagnosticInterface") 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:"-"` } @@ -5901,6 +5930,7 @@ type ServiceMeshCondition struct { // identity federation required error code // "CNI_INSTALLATION_FAILED" - CNI installation failed error code // "CNI_POD_UNSCHEDULABLE" - CNI pod unschedulable error code + // "CLUSTER_HAS_ZERO_NODES" - Cluster has zero node code // "UNSUPPORTED_MULTIPLE_CONTROL_PLANES" - Multiple control planes // unsupported error code // "VPCSC_GA_SUPPORTED" - VPC-SC GA is supported for this control plane. diff --git a/gkehub/v1beta/gkehub-api.json b/gkehub/v1beta/gkehub-api.json index f6b12879ce1..219a3ad963b 100644 --- a/gkehub/v1beta/gkehub-api.json +++ b/gkehub/v1beta/gkehub-api.json @@ -2111,7 +2111,7 @@ } } }, - "revision": "20240825", + "revision": "20240902", "rootUrl": "https://gkehub.googleapis.com/", "schemas": { "AnthosObservabilityFeatureSpec": { @@ -4258,6 +4258,22 @@ }, "type": "object" }, + "IdentityServiceDiagnosticInterface": { + "description": "Configuration options for the AIS diagnostic interface.", + "id": "IdentityServiceDiagnosticInterface", + "properties": { + "enabled": { + "description": "Determines whether to enable the diagnostic interface.", + "type": "boolean" + }, + "expirationTime": { + "description": "Determines the expiration time of the diagnostic interface enablement. When reached, requests to the interface would be automatically rejected.", + "format": "google-datetime", + "type": "string" + } + }, + "type": "object" + }, "IdentityServiceGoogleConfig": { "description": "Configuration for the Google Plugin Auth flow.", "id": "IdentityServiceGoogleConfig", @@ -4292,8 +4308,12 @@ "description": "Holds non-protocol-related configuration options.", "id": "IdentityServiceIdentityServiceOptions", "properties": { + "diagnosticInterface": { + "$ref": "IdentityServiceDiagnosticInterface", + "description": "Configuration options for the AIS diagnostic interface." + }, "sessionDuration": { - "description": "Optional. Determines the lifespan of STS tokens issued by Anthos Identity Service.", + "description": "Determines the lifespan of STS tokens issued by Anthos Identity Service.", "format": "google-duration", "type": "string" } @@ -6245,6 +6265,7 @@ "NODEPOOL_WORKLOAD_IDENTITY_FEDERATION_REQUIRED", "CNI_INSTALLATION_FAILED", "CNI_POD_UNSCHEDULABLE", + "CLUSTER_HAS_ZERO_NODES", "UNSUPPORTED_MULTIPLE_CONTROL_PLANES", "VPCSC_GA_SUPPORTED", "CONFIG_APPLY_INTERNAL_ERROR", @@ -6275,6 +6296,7 @@ "Nodepool workload identity federation required error code", "CNI installation failed error code", "CNI pod unschedulable error code", + "Cluster has zero node code", "Multiple control planes unsupported error code", "VPC-SC GA is supported for this control plane.", "Configuration (Istio/k8s resources) failed to apply due to internal error.", diff --git a/gkehub/v1beta/gkehub-gen.go b/gkehub/v1beta/gkehub-gen.go index 243c699e838..06f4901b60a 100644 --- a/gkehub/v1beta/gkehub-gen.go +++ b/gkehub/v1beta/gkehub-gen.go @@ -3009,6 +3009,33 @@ func (s IdentityServiceAzureADConfig) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// IdentityServiceDiagnosticInterface: Configuration options for the AIS +// diagnostic interface. +type IdentityServiceDiagnosticInterface struct { + // Enabled: Determines whether to enable the diagnostic interface. + Enabled bool `json:"enabled,omitempty"` + // ExpirationTime: Determines the expiration time of the diagnostic interface + // enablement. When reached, requests to the interface would be automatically + // rejected. + ExpirationTime string `json:"expirationTime,omitempty"` + // ForceSendFields is a list of field names (e.g. "Enabled") 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. "Enabled") 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 IdentityServiceDiagnosticInterface) MarshalJSON() ([]byte, error) { + type NoMethod IdentityServiceDiagnosticInterface + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // IdentityServiceGoogleConfig: Configuration for the Google Plugin Auth flow. type IdentityServiceGoogleConfig struct { // Disable: Disable automatic configuration of Google Plugin on supported @@ -3069,18 +3096,20 @@ func (s IdentityServiceGroupConfig) MarshalJSON() ([]byte, error) { // IdentityServiceIdentityServiceOptions: Holds non-protocol-related // configuration options. type IdentityServiceIdentityServiceOptions struct { - // SessionDuration: Optional. Determines the lifespan of STS tokens issued by - // Anthos Identity Service. + // DiagnosticInterface: Configuration options for the AIS diagnostic interface. + DiagnosticInterface *IdentityServiceDiagnosticInterface `json:"diagnosticInterface,omitempty"` + // SessionDuration: Determines the lifespan of STS tokens issued by Anthos + // Identity Service. SessionDuration string `json:"sessionDuration,omitempty"` - // ForceSendFields is a list of field names (e.g. "SessionDuration") to + // ForceSendFields is a list of field names (e.g. "DiagnosticInterface") 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. "SessionDuration") to include in - // API requests with the JSON null value. By default, fields with empty values - // are omitted from API requests. See + // NullFields is a list of field names (e.g. "DiagnosticInterface") 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:"-"` } @@ -5547,6 +5576,7 @@ type ServiceMeshCondition struct { // identity federation required error code // "CNI_INSTALLATION_FAILED" - CNI installation failed error code // "CNI_POD_UNSCHEDULABLE" - CNI pod unschedulable error code + // "CLUSTER_HAS_ZERO_NODES" - Cluster has zero node code // "UNSUPPORTED_MULTIPLE_CONTROL_PLANES" - Multiple control planes // unsupported error code // "VPCSC_GA_SUPPORTED" - VPC-SC GA is supported for this control plane. diff --git a/go.mod b/go.mod index bc4610680bc..8b1804ca48b 100644 --- a/go.mod +++ b/go.mod @@ -10,19 +10,19 @@ require ( github.com/google/go-cmp v0.6.0 github.com/google/s2a-go v0.1.8 github.com/google/uuid v1.6.0 - github.com/googleapis/enterprise-certificate-proxy v0.3.3 + github.com/googleapis/enterprise-certificate-proxy v0.3.4 github.com/googleapis/gax-go/v2 v2.13.0 go.opencensus.io v0.24.0 go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc v0.54.0 go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.54.0 - golang.org/x/net v0.28.0 - golang.org/x/oauth2 v0.22.0 + golang.org/x/net v0.29.0 + golang.org/x/oauth2 v0.23.0 golang.org/x/sync v0.8.0 golang.org/x/time v0.6.0 google.golang.org/genproto v0.0.0-20240903143218-8af14fe29dc1 google.golang.org/genproto/googleapis/bytestream v0.0.0-20240903143218-8af14fe29dc1 google.golang.org/genproto/googleapis/rpc v0.0.0-20240903143218-8af14fe29dc1 - google.golang.org/grpc v1.66.0 + google.golang.org/grpc v1.66.1 google.golang.org/protobuf v1.34.2 ) @@ -34,7 +34,7 @@ require ( go.opentelemetry.io/otel v1.29.0 // indirect go.opentelemetry.io/otel/metric v1.29.0 // indirect go.opentelemetry.io/otel/trace v1.29.0 // indirect - golang.org/x/crypto v0.26.0 // indirect - golang.org/x/sys v0.24.0 // indirect - golang.org/x/text v0.17.0 // indirect + golang.org/x/crypto v0.27.0 // indirect + golang.org/x/sys v0.25.0 // indirect + golang.org/x/text v0.18.0 // indirect ) diff --git a/go.sum b/go.sum index 3e77606a820..694c8caa756 100644 --- a/go.sum +++ b/go.sum @@ -54,8 +54,8 @@ github.com/google/s2a-go v0.1.8/go.mod h1:6iNWHTpQ+nfNRN5E00MSdfDwVesa8hhS32PhPO github.com/google/uuid v1.1.2/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= github.com/google/uuid v1.6.0 h1:NIvaJDMOsjHA8n1jAhLSgzrAzy1Hgr+hNrb57e+94F0= github.com/google/uuid v1.6.0/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= -github.com/googleapis/enterprise-certificate-proxy v0.3.3 h1:QRje2j5GZimBzlbhGA2V2QlGNgL8G6e+wGo/+/2bWI0= -github.com/googleapis/enterprise-certificate-proxy v0.3.3/go.mod h1:YKe7cfqYXjKGpGvmSg28/fFvhNzinZQm8DGnaburhGA= +github.com/googleapis/enterprise-certificate-proxy v0.3.4 h1:XYIDZApgAnrN1c855gTgghdIA6Stxb52D5RnLI1SLyw= +github.com/googleapis/enterprise-certificate-proxy v0.3.4/go.mod h1:YKe7cfqYXjKGpGvmSg28/fFvhNzinZQm8DGnaburhGA= github.com/googleapis/gax-go/v2 v2.13.0 h1:yitjD5f7jQHhyDsnhKEBU52NdvvdSeGzlAnDPT0hH1s= github.com/googleapis/gax-go/v2 v2.13.0/go.mod h1:Z/fvTZXF8/uw7Xu5GuslPw+bplx6SS338j1Is2S+B7A= github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZbAQM= @@ -83,8 +83,8 @@ go.opentelemetry.io/otel/trace v1.29.0 h1:J/8ZNK4XgR7a21DZUAsbF8pZ5Jcw1VhACmnYt3 go.opentelemetry.io/otel/trace v1.29.0/go.mod h1:eHl3w0sp3paPkYstJOmAimxhiFXPg+MMTlEh3nsQgWQ= golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w= golang.org/x/crypto v0.0.0-20200622213623-75b288015ac9/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= -golang.org/x/crypto v0.26.0 h1:RrRspgV4mU+YwB4FYnuBoKsUapNIL5cohGAmSH3azsw= -golang.org/x/crypto v0.26.0/go.mod h1:GY7jblb9wI+FOo5y8/S2oY4zWP07AkOJ4+jxCqdqn54= +golang.org/x/crypto v0.27.0 h1:GXm2NjJrPaiv/h1tb2UH8QfgC/hOf/+z0p6PT8o1w7A= +golang.org/x/crypto v0.27.0/go.mod h1:1Xngt8kV6Dvbssa53Ziq6Eqn0HqbZi5Z6R0ZpwQzt70= golang.org/x/exp v0.0.0-20190121172915-509febef88a4/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA= golang.org/x/lint v0.0.0-20181026193005-c67002cb31c3/go.mod h1:UVdnD1Gm6xHRNCYTkRU2/jEulfH38KcIWyp/GAMgvoE= golang.org/x/lint v0.0.0-20190227174305-5b3e6a55c961/go.mod h1:wehouNa3lNwaWXcvxsM5YxQ5yQlVC4a0KAMCusXpPoU= @@ -95,11 +95,11 @@ golang.org/x/net v0.0.0-20190213061140-3a22650c66bd/go.mod h1:mL1N/T3taQHkDXs73r golang.org/x/net v0.0.0-20190311183353-d8887717615a/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= golang.org/x/net v0.0.0-20190404232315-eb5bcb51f2a3/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= golang.org/x/net v0.0.0-20201110031124-69a78807bb2b/go.mod h1:sp8m0HH+o8qH0wwXwYZr8TS3Oi6o0r6Gce1SSxlDquU= -golang.org/x/net v0.28.0 h1:a9JDOJc5GMUJ0+UDqmLT86WiEy7iWyIhz8gz8E4e5hE= -golang.org/x/net v0.28.0/go.mod h1:yqtgsTWOOnlGLG9GFRrK3++bGOUEkNBoHZc8MEDWPNg= +golang.org/x/net v0.29.0 h1:5ORfpBpCs4HzDYoodCDBbwHzdR5UrLBZ3sOnUJmFoHo= +golang.org/x/net v0.29.0/go.mod h1:gLkgy8jTGERgjzMic6DS9+SP0ajcu6Xu3Orq/SpETg0= golang.org/x/oauth2 v0.0.0-20180821212333-d2e6202438be/go.mod h1:N/0e6XlmueqKjAGxoOufVs8QHGRruUQn6yWY3a++T0U= -golang.org/x/oauth2 v0.22.0 h1:BzDx2FehcG7jJwgWLELCdmLuxk2i+x9UDpSiss2u0ZA= -golang.org/x/oauth2 v0.22.0/go.mod h1:XYTD2NtWslqkgxebSiOHnXEap4TF09sJSc7H1sXbhtI= +golang.org/x/oauth2 v0.23.0 h1:PbgcYx2W7i4LvjJWEbf0ngHV6qJYr86PkAV3bXdLEbs= +golang.org/x/oauth2 v0.23.0/go.mod h1:XYTD2NtWslqkgxebSiOHnXEap4TF09sJSc7H1sXbhtI= golang.org/x/sync v0.0.0-20180314180146-1d60e4601c6f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20181108010431-42b317875d0f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20190423024810-112230192c58/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= @@ -109,12 +109,12 @@ golang.org/x/sys v0.0.0-20180830151530-49385e6e1522/go.mod h1:STP8DvDyc/dI5b8T5h golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20190412213103-97732733099d/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200930185726-fdedc70b468f/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.24.0 h1:Twjiwq9dn6R1fQcyiK+wQyHWfaz/BJB+YIpzU/Cv3Xg= -golang.org/x/sys v0.24.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= +golang.org/x/sys v0.25.0 h1:r+8e+loiHxRqhXVl6ML1nO3l1+oFoWbnlu2Ehimmi34= +golang.org/x/sys v0.25.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.3/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= -golang.org/x/text v0.17.0 h1:XtiM5bkSOt+ewxlOE/aE/AKEHibwj/6gvWMl9Rsh0Qc= -golang.org/x/text v0.17.0/go.mod h1:BuEKDfySbSR4drPmRPG/7iBdf8hvFMuRexcpahXilzY= +golang.org/x/text v0.18.0 h1:XvMDiNzPAl0jr17s6W9lcaIhGUfUORdGCNsuLmPG224= +golang.org/x/text v0.18.0/go.mod h1:BuEKDfySbSR4drPmRPG/7iBdf8hvFMuRexcpahXilzY= golang.org/x/time v0.6.0 h1:eTDhh4ZXt5Qf0augr54TN6suAUudPcawVZeIAPU7D4U= golang.org/x/time v0.6.0/go.mod h1:3BpzKBy/shNhVucY/MWOyx10tF3SFh9QdLuxbVysPQM= golang.org/x/tools v0.0.0-20180917221912-90fa682c2a6e/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= @@ -141,8 +141,8 @@ google.golang.org/grpc v1.23.0/go.mod h1:Y5yQAOtifL1yxbo5wqy6BxZv8vAUGQwXBOALyac google.golang.org/grpc v1.25.1/go.mod h1:c3i+UQWmh7LiEpx4sFZnkU36qjEYZ0imhYfXVyQciAY= google.golang.org/grpc v1.27.0/go.mod h1:qbnxyOmOxrQa7FizSgH+ReBfzJrCY1pSN7KXBS8abTk= google.golang.org/grpc v1.33.2/go.mod h1:JMHMWHQWaTccqQQlmk3MJZS+GWXOdAesneDmEnv2fbc= -google.golang.org/grpc v1.66.0 h1:DibZuoBznOxbDQxRINckZcUvnCEvrW9pcWIE2yF9r1c= -google.golang.org/grpc v1.66.0/go.mod h1:s3/l6xSSCURdVfAnL+TqCNMyTDAGN6+lZeVxnZR128Y= +google.golang.org/grpc v1.66.1 h1:hO5qAXR19+/Z44hmvIM4dQFMSYX9XcWsByfoxutBpAM= +google.golang.org/grpc v1.66.1/go.mod h1:s3/l6xSSCURdVfAnL+TqCNMyTDAGN6+lZeVxnZR128Y= google.golang.org/protobuf v0.0.0-20200109180630-ec00e32a8dfd/go.mod h1:DFci5gLYBciE7Vtevhsrf46CRTquxDuWsQurQQe4oz8= google.golang.org/protobuf v0.0.0-20200221191635-4d8936d0db64/go.mod h1:kwYJMbMJ01Woi6D6+Kah6886xMZcty6N08ah7+eCXa0= google.golang.org/protobuf v0.0.0-20200228230310-ab0ca4ff8a60/go.mod h1:cfTl7dwQJ+fmap5saPgwCLgHXTUD7jkjRqWcaiX5VyM= diff --git a/healthcare/v1/healthcare-api.json b/healthcare/v1/healthcare-api.json index a1b56adad68..3e53a9ccae3 100644 --- a/healthcare/v1/healthcare-api.json +++ b/healthcare/v1/healthcare-api.json @@ -3341,6 +3341,116 @@ "resources": { "fhir": { "methods": { + "Binary-create": { + "description": "Creates a FHIR Binary resource. This method can be used to create a Binary resource either by using one of the accepted FHIR JSON content types, or as a raw data stream. If a resource is created with this method using the FHIR content type this method's behavior is the same as [`fhir.create`](https://cloud.google.com/healthcare-api/docs/reference/rest/v1/projects.locations.datasets.fhirStores.fhir/create). If a resource type other than Binary is used in the request it's treated in the same way as non-FHIR data (e.g., images, zip archives, pdf files, documents). When a non-FHIR content type is used in the request, a Binary resource will be generated, and the uploaded data will be stored in the `content` field (`DSTU2` and `STU3`), or the `data` field (`R4`). The Binary resource's `contentType` will be filled in using the value of the `Content-Type` header, and the `securityContext` field (not present in `DSTU2`) will be populated from the `X-Security-Context` header if it exists. At this time `securityContext` has no special behavior in the Cloud Healthcare API. Note: the limit on data ingested through this method is 2 GB. For best performance, use a non-FHIR data type instead of wrapping the data in a Binary resource. Some of the Healthcare API features, such as [exporting to BigQuery](https://cloud.google.com/healthcare-api/docs/how-tos/fhir-export-bigquery) or [Pub/Sub notifications](https://cloud.google.com/healthcare-api/docs/fhir-pubsub#behavior_when_a_fhir_resource_is_too_large_or_traffic_is_high) with full resource content, do not support Binary resources that are larger than 10 MB. In these cases the resource's `data` field will be omitted. Instead, the \"http://hl7.org/fhir/StructureDefinition/data-absent-reason\" extension will be present to indicate that including the data is `unsupported`. On success, an empty `201 Created` response is returned. The newly created resource's ID and version are returned in the Location header. Using `Prefer: representation=resource` is not allowed for this method. The definition of the Binary REST API can be found at https://hl7.org/fhir/binary.html#rest.", + "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/datasets/{datasetsId}/fhirStores/{fhirStoresId}/fhir/Binary", + "httpMethod": "POST", + "id": "healthcare.projects.locations.datasets.fhirStores.fhir.Binary-create", + "parameterOrder": [ + "parent" + ], + "parameters": { + "parent": { + "description": "Required. The name of the FHIR store this resource belongs to.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/fhirStores/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1/{+parent}/fhir/Binary", + "request": { + "$ref": "HttpBody" + }, + "response": { + "$ref": "HttpBody" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-healthcare", + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "Binary-read": { + "description": "Gets the contents of a FHIR Binary resource. This method can be used to retrieve a Binary resource either by using the FHIR JSON mimetype as the value for the Accept header, or as a raw data stream. If the FHIR Accept type is used this method will return a Binary resource with the data base64-encoded, regardless of how the resource was created. The resource data can be retrieved in base64-decoded form if the Accept type of the request matches the value of the resource's `contentType` field. The definition of the Binary REST API can be found at https://hl7.org/fhir/binary.html#rest.", + "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/datasets/{datasetsId}/fhirStores/{fhirStoresId}/fhir/Binary/{BinaryId}", + "httpMethod": "GET", + "id": "healthcare.projects.locations.datasets.fhirStores.fhir.Binary-read", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Required. The name of the Binary resource to retrieve.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/fhirStores/[^/]+/fhir/Binary/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1/{+name}", + "response": { + "$ref": "HttpBody" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-healthcare", + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "Binary-update": { + "description": "Updates the entire contents of a Binary resource. If the specified resource does not exist and the FHIR store has enable_update_create set, creates the resource with the client-specified ID. It is strongly advised not to include or encode any sensitive data such as patient identifiers in client-specified resource IDs. Those IDs are part of the FHIR resource path recorded in Cloud Audit Logs and Pub/Sub notifications. Those IDs can also be contained in reference fields within other resources. This method can be used to update a Binary resource either by using one of the accepted FHIR JSON content types, or as a raw data stream. If a resource is updated with this method using the FHIR content type this method's behavior is the same as `update`. If a resource type other than Binary is used in the request it will be treated in the same way as non-FHIR data. When a non-FHIR content type is used in the request, a Binary resource will be generated using the ID from the resource path, and the uploaded data will be stored in the `content` field (`DSTU2` and `STU3`), or the `data` field (`R4`). The Binary resource's `contentType` will be filled in using the value of the `Content-Type` header, and the `securityContext` field (not present in `DSTU2`) will be populated from the `X-Security-Context` header if it exists. At this time `securityContext` has no special behavior in the Cloud Healthcare API. Note: the limit on data ingested through this method is 2 GB. For best performance, use a non-FHIR data type instead of wrapping the data in a Binary resource. Some of the Healthcare API features, such as [exporting to BigQuery](https://cloud.google.com/healthcare-api/docs/how-tos/fhir-export-bigquery) or [Pub/Sub notifications](https://cloud.google.com/healthcare-api/docs/fhir-pubsub#behavior_when_a_fhir_resource_is_too_large_or_traffic_is_high) with full resource content, do not support Binary resources that are larger than 10 MB. In these cases the resource's `data` field will be omitted. Instead, the \"http://hl7.org/fhir/StructureDefinition/data-absent-reason\" extension will be present to indicate that including the data is `unsupported`. On success, an empty 200 OK response will be returned, or a 201 Created if the resource did not exit. The resource's ID and version are returned in the Location header. Using `Prefer: representation=resource` is not allowed for this method. The definition of the Binary REST API can be found at https://hl7.org/fhir/binary.html#rest.", + "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/datasets/{datasetsId}/fhirStores/{fhirStoresId}/fhir/Binary/{BinaryId}", + "httpMethod": "PUT", + "id": "healthcare.projects.locations.datasets.fhirStores.fhir.Binary-update", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Required. The name of the resource to update.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/fhirStores/[^/]+/fhir/Binary/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1/{+name}", + "request": { + "$ref": "HttpBody" + }, + "response": { + "$ref": "HttpBody" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-healthcare", + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "Binary-vread": { + "description": "Gets the contents of a version (current or historical) of a FHIR Binary resource by version ID. This method can be used to retrieve a Binary resource version either by using the FHIR JSON mimetype as the value for the Accept header, or as a raw data stream. If the FHIR Accept type is used this method will return a Binary resource with the data base64-encoded, regardless of how the resource version was created. The resource data can be retrieved in base64-decoded form if the Accept type of the request matches the value of the resource version's `contentType` field. The definition of the Binary REST API can be found at https://hl7.org/fhir/binary.html#rest.", + "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/datasets/{datasetsId}/fhirStores/{fhirStoresId}/fhir/Binary/{BinaryId}/_history/{_historyId}", + "httpMethod": "GET", + "id": "healthcare.projects.locations.datasets.fhirStores.fhir.Binary-vread", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Required. The name of the Binary resource version to retrieve.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/fhirStores/[^/]+/fhir/Binary/[^/]+/_history/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1/{+name}", + "response": { + "$ref": "HttpBody" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-healthcare", + "https://www.googleapis.com/auth/cloud-platform" + ] + }, "Patient-everything": { "description": "Retrieves a Patient resource and resources related to that patient. Implements the FHIR extended operation Patient-everything ([DSTU2](http://hl7.org/implement/standards/fhir/DSTU2/patient-operations.html#everything), [STU3](http://hl7.org/implement/standards/fhir/STU3/patient-operations.html#everything), [R4](http://hl7.org/implement/standards/fhir/R4/patient-operations.html#everything)). On success, the response body contains a JSON-encoded representation of a `Bundle` resource of type `searchset`, containing the results of the operation. Errors generated by the FHIR store contain a JSON-encoded `OperationOutcome` resource describing the reason for the error. If the request cannot be mapped to a valid API method on a FHIR store, a generic GCP error might be returned instead. The resources in scope for the response are: * The patient resource itself. * All the resources directly referenced by the patient resource. * Resources directly referencing the patient resource that meet the inclusion criteria. The inclusion criteria are based on the membership rules in the patient compartment definition ([DSTU2](http://hl7.org/fhir/DSTU2/compartment-patient.html), [STU3](http://www.hl7.org/fhir/stu3/compartmentdefinition-patient.html), [R4](http://hl7.org/fhir/R4/compartmentdefinition-patient.html)), which details the eligible resource types and referencing search parameters. For samples that show how to call `Patient-everything`, see [Getting all patient compartment resources](https://cloud.google.com/healthcare/docs/how-tos/fhir-resources#getting_all_patient_compartment_resources).", "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/datasets/{datasetsId}/fhirStores/{fhirStoresId}/fhir/Patient/{PatientId}/$everything", @@ -4673,7 +4783,7 @@ } } }, - "revision": "20240819", + "revision": "20240822", "rootUrl": "https://healthcare.googleapis.com/", "schemas": { "ActivateConsentRequest": { diff --git a/healthcare/v1/healthcare-gen.go b/healthcare/v1/healthcare-gen.go index 123bdc750bb..5ce214504fb 100644 --- a/healthcare/v1/healthcare-gen.go +++ b/healthcare/v1/healthcare-gen.go @@ -17001,6 +17001,368 @@ func (c *ProjectsLocationsDatasetsFhirStoresTestIamPermissionsCall) Do(opts ...g return ret, nil } +type ProjectsLocationsDatasetsFhirStoresFhirBinaryCreateCall struct { + s *Service + parent string + body_ io.Reader + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// BinaryCreate: Creates a FHIR Binary resource. This method can be used to +// create a Binary resource either by using one of the accepted FHIR JSON +// content types, or as a raw data stream. If a resource is created with this +// method using the FHIR content type this method's behavior is the same as +// `fhir.create` +// (https://cloud.google.com/healthcare-api/docs/reference/rest/v1/projects.locations.datasets.fhirStores.fhir/create). +// If a resource type other than Binary is used in the request it's treated in +// the same way as non-FHIR data (e.g., images, zip archives, pdf files, +// documents). When a non-FHIR content type is used in the request, a Binary +// resource will be generated, and the uploaded data will be stored in the +// `content` field (`DSTU2` and `STU3`), or the `data` field (`R4`). The Binary +// resource's `contentType` will be filled in using the value of the +// `Content-Type` header, and the `securityContext` field (not present in +// `DSTU2`) will be populated from the `X-Security-Context` header if it +// exists. At this time `securityContext` has no special behavior in the Cloud +// Healthcare API. Note: the limit on data ingested through this method is 2 +// GB. For best performance, use a non-FHIR data type instead of wrapping the +// data in a Binary resource. Some of the Healthcare API features, such as +// exporting to BigQuery +// (https://cloud.google.com/healthcare-api/docs/how-tos/fhir-export-bigquery) +// or Pub/Sub notifications +// (https://cloud.google.com/healthcare-api/docs/fhir-pubsub#behavior_when_a_fhir_resource_is_too_large_or_traffic_is_high) +// with full resource content, do not support Binary resources that are larger +// than 10 MB. In these cases the resource's `data` field will be omitted. +// Instead, the "http://hl7.org/fhir/StructureDefinition/data-absent-reason" +// extension will be present to indicate that including the data is +// `unsupported`. On success, an empty `201 Created` response is returned. The +// newly created resource's ID and version are returned in the Location header. +// Using `Prefer: representation=resource` is not allowed for this method. The +// definition of the Binary REST API can be found at +// https://hl7.org/fhir/binary.html#rest. +// +// - parent: The name of the FHIR store this resource belongs to. +func (r *ProjectsLocationsDatasetsFhirStoresFhirService) BinaryCreate(parent string, body_ io.Reader) *ProjectsLocationsDatasetsFhirStoresFhirBinaryCreateCall { + c := &ProjectsLocationsDatasetsFhirStoresFhirBinaryCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + c.body_ = body_ + 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 *ProjectsLocationsDatasetsFhirStoresFhirBinaryCreateCall) Fields(s ...googleapi.Field) *ProjectsLocationsDatasetsFhirStoresFhirBinaryCreateCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsDatasetsFhirStoresFhirBinaryCreateCall) Context(ctx context.Context) *ProjectsLocationsDatasetsFhirStoresFhirBinaryCreateCall { + 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 *ProjectsLocationsDatasetsFhirStoresFhirBinaryCreateCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsDatasetsFhirStoresFhirBinaryCreateCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) + var body io.Reader = nil + body = c.body_ + urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/fhir/Binary") + 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 "healthcare.projects.locations.datasets.fhirStores.fhir.Binary-create" call. +func (c *ProjectsLocationsDatasetsFhirStoresFhirBinaryCreateCall) Do(opts ...googleapi.CallOption) (*http.Response, error) { + gensupport.SetOptions(c.urlParams_, opts...) + return c.doRequest("") +} + +type ProjectsLocationsDatasetsFhirStoresFhirBinaryReadCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// BinaryRead: Gets the contents of a FHIR Binary resource. This method can be +// used to retrieve a Binary resource either by using the FHIR JSON mimetype as +// the value for the Accept header, or as a raw data stream. If the FHIR Accept +// type is used this method will return a Binary resource with the data +// base64-encoded, regardless of how the resource was created. The resource +// data can be retrieved in base64-decoded form if the Accept type of the +// request matches the value of the resource's `contentType` field. The +// definition of the Binary REST API can be found at +// https://hl7.org/fhir/binary.html#rest. +// +// - name: The name of the Binary resource to retrieve. +func (r *ProjectsLocationsDatasetsFhirStoresFhirService) BinaryRead(name string) *ProjectsLocationsDatasetsFhirStoresFhirBinaryReadCall { + c := &ProjectsLocationsDatasetsFhirStoresFhirBinaryReadCall{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 *ProjectsLocationsDatasetsFhirStoresFhirBinaryReadCall) Fields(s ...googleapi.Field) *ProjectsLocationsDatasetsFhirStoresFhirBinaryReadCall { + 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 *ProjectsLocationsDatasetsFhirStoresFhirBinaryReadCall) IfNoneMatch(entityTag string) *ProjectsLocationsDatasetsFhirStoresFhirBinaryReadCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsDatasetsFhirStoresFhirBinaryReadCall) Context(ctx context.Context) *ProjectsLocationsDatasetsFhirStoresFhirBinaryReadCall { + 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 *ProjectsLocationsDatasetsFhirStoresFhirBinaryReadCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsDatasetsFhirStoresFhirBinaryReadCall) 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 "healthcare.projects.locations.datasets.fhirStores.fhir.Binary-read" call. +func (c *ProjectsLocationsDatasetsFhirStoresFhirBinaryReadCall) Do(opts ...googleapi.CallOption) (*http.Response, error) { + gensupport.SetOptions(c.urlParams_, opts...) + return c.doRequest("") +} + +type ProjectsLocationsDatasetsFhirStoresFhirBinaryUpdateCall struct { + s *Service + name string + body_ io.Reader + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// BinaryUpdate: Updates the entire contents of a Binary resource. If the +// specified resource does not exist and the FHIR store has +// enable_update_create set, creates the resource with the client-specified ID. +// It is strongly advised not to include or encode any sensitive data such as +// patient identifiers in client-specified resource IDs. Those IDs are part of +// the FHIR resource path recorded in Cloud Audit Logs and Pub/Sub +// notifications. Those IDs can also be contained in reference fields within +// other resources. This method can be used to update a Binary resource either +// by using one of the accepted FHIR JSON content types, or as a raw data +// stream. If a resource is updated with this method using the FHIR content +// type this method's behavior is the same as `update`. If a resource type +// other than Binary is used in the request it will be treated in the same way +// as non-FHIR data. When a non-FHIR content type is used in the request, a +// Binary resource will be generated using the ID from the resource path, and +// the uploaded data will be stored in the `content` field (`DSTU2` and +// `STU3`), or the `data` field (`R4`). The Binary resource's `contentType` +// will be filled in using the value of the `Content-Type` header, and the +// `securityContext` field (not present in `DSTU2`) will be populated from the +// `X-Security-Context` header if it exists. At this time `securityContext` has +// no special behavior in the Cloud Healthcare API. Note: the limit on data +// ingested through this method is 2 GB. For best performance, use a non-FHIR +// data type instead of wrapping the data in a Binary resource. Some of the +// Healthcare API features, such as exporting to BigQuery +// (https://cloud.google.com/healthcare-api/docs/how-tos/fhir-export-bigquery) +// or Pub/Sub notifications +// (https://cloud.google.com/healthcare-api/docs/fhir-pubsub#behavior_when_a_fhir_resource_is_too_large_or_traffic_is_high) +// with full resource content, do not support Binary resources that are larger +// than 10 MB. In these cases the resource's `data` field will be omitted. +// Instead, the "http://hl7.org/fhir/StructureDefinition/data-absent-reason" +// extension will be present to indicate that including the data is +// `unsupported`. On success, an empty 200 OK response will be returned, or a +// 201 Created if the resource did not exit. The resource's ID and version are +// returned in the Location header. Using `Prefer: representation=resource` is +// not allowed for this method. The definition of the Binary REST API can be +// found at https://hl7.org/fhir/binary.html#rest. +// +// - name: The name of the resource to update. +func (r *ProjectsLocationsDatasetsFhirStoresFhirService) BinaryUpdate(name string, body_ io.Reader) *ProjectsLocationsDatasetsFhirStoresFhirBinaryUpdateCall { + c := &ProjectsLocationsDatasetsFhirStoresFhirBinaryUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + c.body_ = body_ + 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 *ProjectsLocationsDatasetsFhirStoresFhirBinaryUpdateCall) Fields(s ...googleapi.Field) *ProjectsLocationsDatasetsFhirStoresFhirBinaryUpdateCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsDatasetsFhirStoresFhirBinaryUpdateCall) Context(ctx context.Context) *ProjectsLocationsDatasetsFhirStoresFhirBinaryUpdateCall { + 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 *ProjectsLocationsDatasetsFhirStoresFhirBinaryUpdateCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsDatasetsFhirStoresFhirBinaryUpdateCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) + var body io.Reader = nil + body = c.body_ + urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("PUT", 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 "healthcare.projects.locations.datasets.fhirStores.fhir.Binary-update" call. +func (c *ProjectsLocationsDatasetsFhirStoresFhirBinaryUpdateCall) Do(opts ...googleapi.CallOption) (*http.Response, error) { + gensupport.SetOptions(c.urlParams_, opts...) + return c.doRequest("") +} + +type ProjectsLocationsDatasetsFhirStoresFhirBinaryVreadCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// BinaryVread: Gets the contents of a version (current or historical) of a +// FHIR Binary resource by version ID. This method can be used to retrieve a +// Binary resource version either by using the FHIR JSON mimetype as the value +// for the Accept header, or as a raw data stream. If the FHIR Accept type is +// used this method will return a Binary resource with the data base64-encoded, +// regardless of how the resource version was created. The resource data can be +// retrieved in base64-decoded form if the Accept type of the request matches +// the value of the resource version's `contentType` field. The definition of +// the Binary REST API can be found at https://hl7.org/fhir/binary.html#rest. +// +// - name: The name of the Binary resource version to retrieve. +func (r *ProjectsLocationsDatasetsFhirStoresFhirService) BinaryVread(name string) *ProjectsLocationsDatasetsFhirStoresFhirBinaryVreadCall { + c := &ProjectsLocationsDatasetsFhirStoresFhirBinaryVreadCall{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 *ProjectsLocationsDatasetsFhirStoresFhirBinaryVreadCall) Fields(s ...googleapi.Field) *ProjectsLocationsDatasetsFhirStoresFhirBinaryVreadCall { + 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 *ProjectsLocationsDatasetsFhirStoresFhirBinaryVreadCall) IfNoneMatch(entityTag string) *ProjectsLocationsDatasetsFhirStoresFhirBinaryVreadCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsDatasetsFhirStoresFhirBinaryVreadCall) Context(ctx context.Context) *ProjectsLocationsDatasetsFhirStoresFhirBinaryVreadCall { + 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 *ProjectsLocationsDatasetsFhirStoresFhirBinaryVreadCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsDatasetsFhirStoresFhirBinaryVreadCall) 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 "healthcare.projects.locations.datasets.fhirStores.fhir.Binary-vread" call. +func (c *ProjectsLocationsDatasetsFhirStoresFhirBinaryVreadCall) Do(opts ...googleapi.CallOption) (*http.Response, error) { + gensupport.SetOptions(c.urlParams_, opts...) + return c.doRequest("") +} + type ProjectsLocationsDatasetsFhirStoresFhirPatientEverythingCall struct { s *Service name string diff --git a/healthcare/v1beta1/healthcare-api.json b/healthcare/v1beta1/healthcare-api.json index ea2e8ac248c..aff5eb41c32 100644 --- a/healthcare/v1beta1/healthcare-api.json +++ b/healthcare/v1beta1/healthcare-api.json @@ -4078,6 +4078,116 @@ "resources": { "fhir": { "methods": { + "Binary-create": { + "description": "Creates a FHIR Binary resource. This method can be used to create a Binary resource either by using one of the accepted FHIR JSON content types, or as a raw data stream. If a resource is created with this method using the FHIR content type this method's behavior is the same as [`fhir.create`](https://cloud.google.com/healthcare-api/docs/reference/rest/v1/projects.locations.datasets.fhirStores.fhir/create). If a resource type other than Binary is used in the request it's treated in the same way as non-FHIR data (e.g., images, zip archives, pdf files, documents). When a non-FHIR content type is used in the request, a Binary resource will be generated, and the uploaded data will be stored in the `content` field (`DSTU2` and `STU3`), or the `data` field (`R4`). The Binary resource's `contentType` will be filled in using the value of the `Content-Type` header, and the `securityContext` field (not present in `DSTU2`) will be populated from the `X-Security-Context` header if it exists. At this time `securityContext` has no special behavior in the Cloud Healthcare API. Note: the limit on data ingested through this method is 2 GB. For best performance, use a non-FHIR data type instead of wrapping the data in a Binary resource. Some of the Healthcare API features, such as [exporting to BigQuery](https://cloud.google.com/healthcare-api/docs/how-tos/fhir-export-bigquery) or [Pub/Sub notifications](https://cloud.google.com/healthcare-api/docs/fhir-pubsub#behavior_when_a_fhir_resource_is_too_large_or_traffic_is_high) with full resource content, do not support Binary resources that are larger than 10 MB. In these cases the resource's `data` field will be omitted. Instead, the \"http://hl7.org/fhir/StructureDefinition/data-absent-reason\" extension will be present to indicate that including the data is `unsupported`. On success, an empty `201 Created` response is returned. The newly created resource's ID and version are returned in the Location header. Using `Prefer: representation=resource` is not allowed for this method. The definition of the Binary REST API can be found at https://hl7.org/fhir/binary.html#rest.", + "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/datasets/{datasetsId}/fhirStores/{fhirStoresId}/fhir/Binary", + "httpMethod": "POST", + "id": "healthcare.projects.locations.datasets.fhirStores.fhir.Binary-create", + "parameterOrder": [ + "parent" + ], + "parameters": { + "parent": { + "description": "Required. The name of the FHIR store this resource belongs to.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/fhirStores/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1beta1/{+parent}/fhir/Binary", + "request": { + "$ref": "HttpBody" + }, + "response": { + "$ref": "HttpBody" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-healthcare", + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "Binary-read": { + "description": "Gets the contents of a FHIR Binary resource. This method can be used to retrieve a Binary resource either by using the FHIR JSON mimetype as the value for the Accept header, or as a raw data stream. If the FHIR Accept type is used this method will return a Binary resource with the data base64-encoded, regardless of how the resource was created. The resource data can be retrieved in base64-decoded form if the Accept type of the request matches the value of the resource's `contentType` field. The definition of the Binary REST API can be found at https://hl7.org/fhir/binary.html#rest.", + "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/datasets/{datasetsId}/fhirStores/{fhirStoresId}/fhir/Binary/{BinaryId}", + "httpMethod": "GET", + "id": "healthcare.projects.locations.datasets.fhirStores.fhir.Binary-read", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Required. The name of the Binary resource to retrieve.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/fhirStores/[^/]+/fhir/Binary/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1beta1/{+name}", + "response": { + "$ref": "HttpBody" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-healthcare", + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "Binary-update": { + "description": "Updates the entire contents of a Binary resource. If the specified resource does not exist and the FHIR store has enable_update_create set, creates the resource with the client-specified ID. It is strongly advised not to include or encode any sensitive data such as patient identifiers in client-specified resource IDs. Those IDs are part of the FHIR resource path recorded in Cloud Audit Logs and Pub/Sub notifications. Those IDs can also be contained in reference fields within other resources. This method can be used to update a Binary resource either by using one of the accepted FHIR JSON content types, or as a raw data stream. If a resource is updated with this method using the FHIR content type this method's behavior is the same as `update`. If a resource type other than Binary is used in the request it will be treated in the same way as non-FHIR data. When a non-FHIR content type is used in the request, a Binary resource will be generated using the ID from the resource path, and the uploaded data will be stored in the `content` field (`DSTU2` and `STU3`), or the `data` field (`R4`). The Binary resource's `contentType` will be filled in using the value of the `Content-Type` header, and the `securityContext` field (not present in `DSTU2`) will be populated from the `X-Security-Context` header if it exists. At this time `securityContext` has no special behavior in the Cloud Healthcare API. Note: the limit on data ingested through this method is 2 GB. For best performance, use a non-FHIR data type instead of wrapping the data in a Binary resource. Some of the Healthcare API features, such as [exporting to BigQuery](https://cloud.google.com/healthcare-api/docs/how-tos/fhir-export-bigquery) or [Pub/Sub notifications](https://cloud.google.com/healthcare-api/docs/fhir-pubsub#behavior_when_a_fhir_resource_is_too_large_or_traffic_is_high) with full resource content, do not support Binary resources that are larger than 10 MB. In these cases the resource's `data` field will be omitted. Instead, the \"http://hl7.org/fhir/StructureDefinition/data-absent-reason\" extension will be present to indicate that including the data is `unsupported`. On success, an empty 200 OK response will be returned, or a 201 Created if the resource did not exit. The resource's ID and version are returned in the Location header. Using `Prefer: representation=resource` is not allowed for this method. The definition of the Binary REST API can be found at https://hl7.org/fhir/binary.html#rest.", + "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/datasets/{datasetsId}/fhirStores/{fhirStoresId}/fhir/Binary/{BinaryId}", + "httpMethod": "PUT", + "id": "healthcare.projects.locations.datasets.fhirStores.fhir.Binary-update", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Required. The name of the resource to update.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/fhirStores/[^/]+/fhir/Binary/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1beta1/{+name}", + "request": { + "$ref": "HttpBody" + }, + "response": { + "$ref": "HttpBody" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-healthcare", + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "Binary-vread": { + "description": "Gets the contents of a version (current or historical) of a FHIR Binary resource by version ID. This method can be used to retrieve a Binary resource version either by using the FHIR JSON mimetype as the value for the Accept header, or as a raw data stream. If the FHIR Accept type is used this method will return a Binary resource with the data base64-encoded, regardless of how the resource version was created. The resource data can be retrieved in base64-decoded form if the Accept type of the request matches the value of the resource version's `contentType` field. The definition of the Binary REST API can be found at https://hl7.org/fhir/binary.html#rest.", + "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/datasets/{datasetsId}/fhirStores/{fhirStoresId}/fhir/Binary/{BinaryId}/_history/{_historyId}", + "httpMethod": "GET", + "id": "healthcare.projects.locations.datasets.fhirStores.fhir.Binary-vread", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Required. The name of the Binary resource version to retrieve.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/fhirStores/[^/]+/fhir/Binary/[^/]+/_history/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1beta1/{+name}", + "response": { + "$ref": "HttpBody" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-healthcare", + "https://www.googleapis.com/auth/cloud-platform" + ] + }, "ConceptMap-search-translate": { "description": "Translates a code from one value set to another by searching for appropriate concept maps. Implements the FHIR standard $translate operation ([DSTU2](https://www.hl7.org/fhir/DSTU2/operation-conceptmap-translate.html), [STU3](https://www.hl7.org/fhir/STU3/operation-conceptmap-translate.html), [R4](https://www.hl7.org/fhir/R4/operation-conceptmap-translate.html)). On success, the response body contains a JSON-encoded representation of a FHIR Parameters resource, which includes the translation result. Errors generated by the FHIR store contain a JSON-encoded `OperationOutcome` resource describing the reason for the error. If the request cannot be mapped to a valid API method on a FHIR store, a generic GCP error might be returned instead.", "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/datasets/{datasetsId}/fhirStores/{fhirStoresId}/fhir/ConceptMap/$translate", @@ -5748,7 +5858,7 @@ } } }, - "revision": "20240819", + "revision": "20240822", "rootUrl": "https://healthcare.googleapis.com/", "schemas": { "AccessDeterminationLogConfig": { diff --git a/healthcare/v1beta1/healthcare-gen.go b/healthcare/v1beta1/healthcare-gen.go index dd8658684c9..e9a56651d25 100644 --- a/healthcare/v1beta1/healthcare-gen.go +++ b/healthcare/v1beta1/healthcare-gen.go @@ -21710,6 +21710,368 @@ func (c *ProjectsLocationsDatasetsFhirStoresTestIamPermissionsCall) Do(opts ...g return ret, nil } +type ProjectsLocationsDatasetsFhirStoresFhirBinaryCreateCall struct { + s *Service + parent string + body_ io.Reader + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// BinaryCreate: Creates a FHIR Binary resource. This method can be used to +// create a Binary resource either by using one of the accepted FHIR JSON +// content types, or as a raw data stream. If a resource is created with this +// method using the FHIR content type this method's behavior is the same as +// `fhir.create` +// (https://cloud.google.com/healthcare-api/docs/reference/rest/v1/projects.locations.datasets.fhirStores.fhir/create). +// If a resource type other than Binary is used in the request it's treated in +// the same way as non-FHIR data (e.g., images, zip archives, pdf files, +// documents). When a non-FHIR content type is used in the request, a Binary +// resource will be generated, and the uploaded data will be stored in the +// `content` field (`DSTU2` and `STU3`), or the `data` field (`R4`). The Binary +// resource's `contentType` will be filled in using the value of the +// `Content-Type` header, and the `securityContext` field (not present in +// `DSTU2`) will be populated from the `X-Security-Context` header if it +// exists. At this time `securityContext` has no special behavior in the Cloud +// Healthcare API. Note: the limit on data ingested through this method is 2 +// GB. For best performance, use a non-FHIR data type instead of wrapping the +// data in a Binary resource. Some of the Healthcare API features, such as +// exporting to BigQuery +// (https://cloud.google.com/healthcare-api/docs/how-tos/fhir-export-bigquery) +// or Pub/Sub notifications +// (https://cloud.google.com/healthcare-api/docs/fhir-pubsub#behavior_when_a_fhir_resource_is_too_large_or_traffic_is_high) +// with full resource content, do not support Binary resources that are larger +// than 10 MB. In these cases the resource's `data` field will be omitted. +// Instead, the "http://hl7.org/fhir/StructureDefinition/data-absent-reason" +// extension will be present to indicate that including the data is +// `unsupported`. On success, an empty `201 Created` response is returned. The +// newly created resource's ID and version are returned in the Location header. +// Using `Prefer: representation=resource` is not allowed for this method. The +// definition of the Binary REST API can be found at +// https://hl7.org/fhir/binary.html#rest. +// +// - parent: The name of the FHIR store this resource belongs to. +func (r *ProjectsLocationsDatasetsFhirStoresFhirService) BinaryCreate(parent string, body_ io.Reader) *ProjectsLocationsDatasetsFhirStoresFhirBinaryCreateCall { + c := &ProjectsLocationsDatasetsFhirStoresFhirBinaryCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + c.body_ = body_ + 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 *ProjectsLocationsDatasetsFhirStoresFhirBinaryCreateCall) Fields(s ...googleapi.Field) *ProjectsLocationsDatasetsFhirStoresFhirBinaryCreateCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsDatasetsFhirStoresFhirBinaryCreateCall) Context(ctx context.Context) *ProjectsLocationsDatasetsFhirStoresFhirBinaryCreateCall { + 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 *ProjectsLocationsDatasetsFhirStoresFhirBinaryCreateCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsDatasetsFhirStoresFhirBinaryCreateCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) + var body io.Reader = nil + body = c.body_ + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+parent}/fhir/Binary") + 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 "healthcare.projects.locations.datasets.fhirStores.fhir.Binary-create" call. +func (c *ProjectsLocationsDatasetsFhirStoresFhirBinaryCreateCall) Do(opts ...googleapi.CallOption) (*http.Response, error) { + gensupport.SetOptions(c.urlParams_, opts...) + return c.doRequest("") +} + +type ProjectsLocationsDatasetsFhirStoresFhirBinaryReadCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// BinaryRead: Gets the contents of a FHIR Binary resource. This method can be +// used to retrieve a Binary resource either by using the FHIR JSON mimetype as +// the value for the Accept header, or as a raw data stream. If the FHIR Accept +// type is used this method will return a Binary resource with the data +// base64-encoded, regardless of how the resource was created. The resource +// data can be retrieved in base64-decoded form if the Accept type of the +// request matches the value of the resource's `contentType` field. The +// definition of the Binary REST API can be found at +// https://hl7.org/fhir/binary.html#rest. +// +// - name: The name of the Binary resource to retrieve. +func (r *ProjectsLocationsDatasetsFhirStoresFhirService) BinaryRead(name string) *ProjectsLocationsDatasetsFhirStoresFhirBinaryReadCall { + c := &ProjectsLocationsDatasetsFhirStoresFhirBinaryReadCall{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 *ProjectsLocationsDatasetsFhirStoresFhirBinaryReadCall) Fields(s ...googleapi.Field) *ProjectsLocationsDatasetsFhirStoresFhirBinaryReadCall { + 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 *ProjectsLocationsDatasetsFhirStoresFhirBinaryReadCall) IfNoneMatch(entityTag string) *ProjectsLocationsDatasetsFhirStoresFhirBinaryReadCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsDatasetsFhirStoresFhirBinaryReadCall) Context(ctx context.Context) *ProjectsLocationsDatasetsFhirStoresFhirBinaryReadCall { + 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 *ProjectsLocationsDatasetsFhirStoresFhirBinaryReadCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsDatasetsFhirStoresFhirBinaryReadCall) 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, "v1beta1/{+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 "healthcare.projects.locations.datasets.fhirStores.fhir.Binary-read" call. +func (c *ProjectsLocationsDatasetsFhirStoresFhirBinaryReadCall) Do(opts ...googleapi.CallOption) (*http.Response, error) { + gensupport.SetOptions(c.urlParams_, opts...) + return c.doRequest("") +} + +type ProjectsLocationsDatasetsFhirStoresFhirBinaryUpdateCall struct { + s *Service + name string + body_ io.Reader + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// BinaryUpdate: Updates the entire contents of a Binary resource. If the +// specified resource does not exist and the FHIR store has +// enable_update_create set, creates the resource with the client-specified ID. +// It is strongly advised not to include or encode any sensitive data such as +// patient identifiers in client-specified resource IDs. Those IDs are part of +// the FHIR resource path recorded in Cloud Audit Logs and Pub/Sub +// notifications. Those IDs can also be contained in reference fields within +// other resources. This method can be used to update a Binary resource either +// by using one of the accepted FHIR JSON content types, or as a raw data +// stream. If a resource is updated with this method using the FHIR content +// type this method's behavior is the same as `update`. If a resource type +// other than Binary is used in the request it will be treated in the same way +// as non-FHIR data. When a non-FHIR content type is used in the request, a +// Binary resource will be generated using the ID from the resource path, and +// the uploaded data will be stored in the `content` field (`DSTU2` and +// `STU3`), or the `data` field (`R4`). The Binary resource's `contentType` +// will be filled in using the value of the `Content-Type` header, and the +// `securityContext` field (not present in `DSTU2`) will be populated from the +// `X-Security-Context` header if it exists. At this time `securityContext` has +// no special behavior in the Cloud Healthcare API. Note: the limit on data +// ingested through this method is 2 GB. For best performance, use a non-FHIR +// data type instead of wrapping the data in a Binary resource. Some of the +// Healthcare API features, such as exporting to BigQuery +// (https://cloud.google.com/healthcare-api/docs/how-tos/fhir-export-bigquery) +// or Pub/Sub notifications +// (https://cloud.google.com/healthcare-api/docs/fhir-pubsub#behavior_when_a_fhir_resource_is_too_large_or_traffic_is_high) +// with full resource content, do not support Binary resources that are larger +// than 10 MB. In these cases the resource's `data` field will be omitted. +// Instead, the "http://hl7.org/fhir/StructureDefinition/data-absent-reason" +// extension will be present to indicate that including the data is +// `unsupported`. On success, an empty 200 OK response will be returned, or a +// 201 Created if the resource did not exit. The resource's ID and version are +// returned in the Location header. Using `Prefer: representation=resource` is +// not allowed for this method. The definition of the Binary REST API can be +// found at https://hl7.org/fhir/binary.html#rest. +// +// - name: The name of the resource to update. +func (r *ProjectsLocationsDatasetsFhirStoresFhirService) BinaryUpdate(name string, body_ io.Reader) *ProjectsLocationsDatasetsFhirStoresFhirBinaryUpdateCall { + c := &ProjectsLocationsDatasetsFhirStoresFhirBinaryUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + c.body_ = body_ + 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 *ProjectsLocationsDatasetsFhirStoresFhirBinaryUpdateCall) Fields(s ...googleapi.Field) *ProjectsLocationsDatasetsFhirStoresFhirBinaryUpdateCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsDatasetsFhirStoresFhirBinaryUpdateCall) Context(ctx context.Context) *ProjectsLocationsDatasetsFhirStoresFhirBinaryUpdateCall { + 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 *ProjectsLocationsDatasetsFhirStoresFhirBinaryUpdateCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsDatasetsFhirStoresFhirBinaryUpdateCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) + var body io.Reader = nil + body = c.body_ + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+name}") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("PUT", 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 "healthcare.projects.locations.datasets.fhirStores.fhir.Binary-update" call. +func (c *ProjectsLocationsDatasetsFhirStoresFhirBinaryUpdateCall) Do(opts ...googleapi.CallOption) (*http.Response, error) { + gensupport.SetOptions(c.urlParams_, opts...) + return c.doRequest("") +} + +type ProjectsLocationsDatasetsFhirStoresFhirBinaryVreadCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// BinaryVread: Gets the contents of a version (current or historical) of a +// FHIR Binary resource by version ID. This method can be used to retrieve a +// Binary resource version either by using the FHIR JSON mimetype as the value +// for the Accept header, or as a raw data stream. If the FHIR Accept type is +// used this method will return a Binary resource with the data base64-encoded, +// regardless of how the resource version was created. The resource data can be +// retrieved in base64-decoded form if the Accept type of the request matches +// the value of the resource version's `contentType` field. The definition of +// the Binary REST API can be found at https://hl7.org/fhir/binary.html#rest. +// +// - name: The name of the Binary resource version to retrieve. +func (r *ProjectsLocationsDatasetsFhirStoresFhirService) BinaryVread(name string) *ProjectsLocationsDatasetsFhirStoresFhirBinaryVreadCall { + c := &ProjectsLocationsDatasetsFhirStoresFhirBinaryVreadCall{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 *ProjectsLocationsDatasetsFhirStoresFhirBinaryVreadCall) Fields(s ...googleapi.Field) *ProjectsLocationsDatasetsFhirStoresFhirBinaryVreadCall { + 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 *ProjectsLocationsDatasetsFhirStoresFhirBinaryVreadCall) IfNoneMatch(entityTag string) *ProjectsLocationsDatasetsFhirStoresFhirBinaryVreadCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsDatasetsFhirStoresFhirBinaryVreadCall) Context(ctx context.Context) *ProjectsLocationsDatasetsFhirStoresFhirBinaryVreadCall { + 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 *ProjectsLocationsDatasetsFhirStoresFhirBinaryVreadCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsDatasetsFhirStoresFhirBinaryVreadCall) 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, "v1beta1/{+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 "healthcare.projects.locations.datasets.fhirStores.fhir.Binary-vread" call. +func (c *ProjectsLocationsDatasetsFhirStoresFhirBinaryVreadCall) Do(opts ...googleapi.CallOption) (*http.Response, error) { + gensupport.SetOptions(c.urlParams_, opts...) + return c.doRequest("") +} + type ProjectsLocationsDatasetsFhirStoresFhirConceptMapSearchTranslateCall struct { s *Service parent string diff --git a/internal/kokoro/discogen/go.mod b/internal/kokoro/discogen/go.mod index 8bf31db4bc8..1f6d5ccda5f 100644 --- a/internal/kokoro/discogen/go.mod +++ b/internal/kokoro/discogen/go.mod @@ -5,7 +5,7 @@ go 1.20 require ( github.com/go-git/go-git/v5 v5.12.0 github.com/google/go-github/v59 v59.0.0 - golang.org/x/oauth2 v0.22.0 + golang.org/x/oauth2 v0.23.0 ) require ( diff --git a/internal/kokoro/discogen/go.sum b/internal/kokoro/discogen/go.sum index 2d5d2ea2f11..a2d1abddd21 100644 --- a/internal/kokoro/discogen/go.sum +++ b/internal/kokoro/discogen/go.sum @@ -84,8 +84,8 @@ golang.org/x/net v0.6.0/go.mod h1:2Tu9+aMcznHK/AK1HMvgo6xiTLG5rD5rZLDS+rp2Bjs= golang.org/x/net v0.8.0/go.mod h1:QVkue5JL9kW//ek3r6jTKnTFis1tRmNAW2P1shuFdJc= golang.org/x/net v0.22.0 h1:9sGLhx7iRIHEiX0oAJ3MRZMUCElJgy7Br1nO+AMN3Tc= golang.org/x/net v0.22.0/go.mod h1:JKghWKKOSdJwpW2GEx0Ja7fmaKnMsbu+MWVZTokSYmg= -golang.org/x/oauth2 v0.22.0 h1:BzDx2FehcG7jJwgWLELCdmLuxk2i+x9UDpSiss2u0ZA= -golang.org/x/oauth2 v0.22.0/go.mod h1:XYTD2NtWslqkgxebSiOHnXEap4TF09sJSc7H1sXbhtI= +golang.org/x/oauth2 v0.23.0 h1:PbgcYx2W7i4LvjJWEbf0ngHV6qJYr86PkAV3bXdLEbs= +golang.org/x/oauth2 v0.23.0/go.mod h1:XYTD2NtWslqkgxebSiOHnXEap4TF09sJSc7H1sXbhtI= golang.org/x/sync v0.0.0-20190423024810-112230192c58/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20220722155255-886fb9371eb4/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.1.0/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= diff --git a/internal/version.go b/internal/version.go index 36e075d21fd..86152a19fcc 100644 --- a/internal/version.go +++ b/internal/version.go @@ -5,4 +5,4 @@ package internal // Version is the current tagged release of the library. -const Version = "0.196.0" +const Version = "0.197.0" diff --git a/logging/v2/logging-api.json b/logging/v2/logging-api.json index df25ad8a9b5..89033064419 100644 --- a/logging/v2/logging-api.json +++ b/logging/v2/logging-api.json @@ -8424,7 +8424,7 @@ } } }, - "revision": "20240726", + "revision": "20240830", "rootUrl": "https://logging.googleapis.com/", "schemas": { "AuditConfig": { @@ -10209,6 +10209,25 @@ "description": "The sampling period of metric data points. For metrics which are written periodically, consecutive data points are stored at this time interval, excluding data loss due to errors. Metrics with a higher granularity have a smaller sampling period.", "format": "google-duration", "type": "string" + }, + "timeSeriesResourceHierarchyLevel": { + "description": "The scope of the timeseries data of the metric.", + "items": { + "enum": [ + "TIME_SERIES_RESOURCE_HIERARCHY_LEVEL_UNSPECIFIED", + "PROJECT", + "ORGANIZATION", + "FOLDER" + ], + "enumDescriptions": [ + "Do not use this default value.", + "Scopes a metric to a project.", + "Scopes a metric to an organization.", + "Scopes a metric to a folder." + ], + "type": "string" + }, + "type": "array" } }, "type": "object" diff --git a/logging/v2/logging-gen.go b/logging/v2/logging-gen.go index 59047a820b3..678a335d1cb 100644 --- a/logging/v2/logging-gen.go +++ b/logging/v2/logging-gen.go @@ -3548,6 +3548,16 @@ type MetricDescriptorMetadata struct { // interval, excluding data loss due to errors. Metrics with a higher // granularity have a smaller sampling period. SamplePeriod string `json:"samplePeriod,omitempty"` + // TimeSeriesResourceHierarchyLevel: The scope of the timeseries data of the + // metric. + // + // Possible values: + // "TIME_SERIES_RESOURCE_HIERARCHY_LEVEL_UNSPECIFIED" - Do not use this + // default value. + // "PROJECT" - Scopes a metric to a project. + // "ORGANIZATION" - Scopes a metric to an organization. + // "FOLDER" - Scopes a metric to a folder. + TimeSeriesResourceHierarchyLevel []string `json:"timeSeriesResourceHierarchyLevel,omitempty"` // ForceSendFields is a list of field names (e.g. "IngestDelay") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See diff --git a/merchantapi/accounts_v1beta/merchantapi-api.json b/merchantapi/accounts_v1beta/merchantapi-api.json index c0e0d718c78..e8ffd4055ff 100644 --- a/merchantapi/accounts_v1beta/merchantapi-api.json +++ b/merchantapi/accounts_v1beta/merchantapi-api.json @@ -1354,7 +1354,7 @@ } } }, - "revision": "20240827", + "revision": "20240830", "rootUrl": "https://merchantapi.googleapis.com/", "schemas": { "AcceptTermsOfService": { @@ -2997,7 +2997,7 @@ "type": "object" }, "ShippingSettings": { - "description": "The merchant account's [shipping setting]((https://support.google.com/merchants/answer/6069284).", + "description": "The merchant account's [shipping setting](https://support.google.com/merchants/answer/6069284).", "id": "ShippingSettings", "properties": { "etag": { diff --git a/merchantapi/accounts_v1beta/merchantapi-gen.go b/merchantapi/accounts_v1beta/merchantapi-gen.go index fa02fe4cdea..b659f79a2aa 100644 --- a/merchantapi/accounts_v1beta/merchantapi-gen.go +++ b/merchantapi/accounts_v1beta/merchantapi-gen.go @@ -2403,7 +2403,7 @@ func (s Service) MarshalJSON() ([]byte, error) { } // ShippingSettings: The merchant account's shipping setting -// ((https://support.google.com/merchants/answer/6069284). +// (https://support.google.com/merchants/answer/6069284). type ShippingSettings struct { // Etag: Required. This field is used for avoid async issue. Make sure shipping // setting data didn't change between get call and insert call. The user should diff --git a/migrationcenter/v1/migrationcenter-api.json b/migrationcenter/v1/migrationcenter-api.json index 6212c8652b4..0b802f831b9 100644 --- a/migrationcenter/v1/migrationcenter-api.json +++ b/migrationcenter/v1/migrationcenter-api.json @@ -2309,7 +2309,7 @@ } } }, - "revision": "20240822", + "revision": "20240906", "rootUrl": "https://migrationcenter.googleapis.com/", "schemas": { "AddAssetsToGroupRequest": { @@ -2850,12 +2850,14 @@ "id": "ComputeEngineShapeDescriptor", "properties": { "logicalCoreCount": { - "description": "Number of logical cores.", + "description": "Output only. Number of logical cores.", "format": "int32", + "readOnly": true, "type": "integer" }, "machineType": { - "description": "Compute Engine machine type.", + "description": "Output only. Compute Engine machine type.", + "readOnly": true, "type": "string" }, "memoryMb": { @@ -2869,14 +2871,16 @@ "type": "integer" }, "series": { - "description": "Compute Engine machine series.", + "description": "Output only. Compute Engine machine series.", + "readOnly": true, "type": "string" }, "storage": { - "description": "Compute Engine storage. Never empty.", + "description": "Output only. Compute Engine storage. Never empty.", "items": { "$ref": "ComputeStorageDescriptor" }, + "readOnly": true, "type": "array" } }, @@ -2887,12 +2891,13 @@ "id": "ComputeStorageDescriptor", "properties": { "sizeGb": { - "description": "Disk size in GiB.", + "description": "Output only. Disk size in GiB.", "format": "int32", + "readOnly": true, "type": "integer" }, "type": { - "description": "Disk type backing the storage.", + "description": "Output only. Disk type backing the storage.", "enum": [ "PERSISTENT_DISK_TYPE_UNSPECIFIED", "PERSISTENT_DISK_TYPE_STANDARD", @@ -2905,6 +2910,7 @@ "Balanced Persistent Disk.", "SSD Persistent Disk." ], + "readOnly": true, "type": "string" } }, @@ -3377,7 +3383,7 @@ "id": "FitDescriptor", "properties": { "fitLevel": { - "description": "Fit level.", + "description": "Output only. Fit level.", "enum": [ "FIT_LEVEL_UNSPECIFIED", "FIT", @@ -3390,6 +3396,7 @@ "No Fit.", "Fit with effort." ], + "readOnly": true, "type": "string" } }, diff --git a/migrationcenter/v1/migrationcenter-gen.go b/migrationcenter/v1/migrationcenter-gen.go index 09778762cc1..ae3992f3ecd 100644 --- a/migrationcenter/v1/migrationcenter-gen.go +++ b/migrationcenter/v1/migrationcenter-gen.go @@ -1035,17 +1035,17 @@ func (s ComputeEnginePreferences) MarshalJSON() ([]byte, error) { // ComputeEngineShapeDescriptor: Compute Engine target shape descriptor. type ComputeEngineShapeDescriptor struct { - // LogicalCoreCount: Number of logical cores. + // LogicalCoreCount: Output only. Number of logical cores. LogicalCoreCount int64 `json:"logicalCoreCount,omitempty"` - // MachineType: Compute Engine machine type. + // MachineType: Output only. Compute Engine machine type. MachineType string `json:"machineType,omitempty"` // MemoryMb: Memory in mebibytes. MemoryMb int64 `json:"memoryMb,omitempty"` // PhysicalCoreCount: Number of physical cores. PhysicalCoreCount int64 `json:"physicalCoreCount,omitempty"` - // Series: Compute Engine machine series. + // Series: Output only. Compute Engine machine series. Series string `json:"series,omitempty"` - // Storage: Compute Engine storage. Never empty. + // Storage: Output only. Compute Engine storage. Never empty. Storage []*ComputeStorageDescriptor `json:"storage,omitempty"` // ForceSendFields is a list of field names (e.g. "LogicalCoreCount") to // unconditionally include in API requests. By default, fields with empty or @@ -1067,9 +1067,9 @@ func (s ComputeEngineShapeDescriptor) MarshalJSON() ([]byte, error) { // ComputeStorageDescriptor: Compute Engine storage option descriptor. type ComputeStorageDescriptor struct { - // SizeGb: Disk size in GiB. + // SizeGb: Output only. Disk size in GiB. SizeGb int64 `json:"sizeGb,omitempty"` - // Type: Disk type backing the storage. + // Type: Output only. Disk type backing the storage. // // Possible values: // "PERSISTENT_DISK_TYPE_UNSPECIFIED" - Unspecified (default value). @@ -1680,7 +1680,7 @@ func (s FileValidationReport) MarshalJSON() ([]byte, error) { // FitDescriptor: Describes the fit level of an asset for migration to a // specific target. type FitDescriptor struct { - // FitLevel: Fit level. + // FitLevel: Output only. Fit level. // // Possible values: // "FIT_LEVEL_UNSPECIFIED" - Not enough information. diff --git a/migrationcenter/v1alpha1/migrationcenter-api.json b/migrationcenter/v1alpha1/migrationcenter-api.json index 17e8c91d0a8..491194d60bd 100644 --- a/migrationcenter/v1alpha1/migrationcenter-api.json +++ b/migrationcenter/v1alpha1/migrationcenter-api.json @@ -2548,7 +2548,7 @@ } } }, - "revision": "20240822", + "revision": "20240906", "rootUrl": "https://migrationcenter.googleapis.com/", "schemas": { "AddAssetsToGroupRequest": { @@ -2828,8 +2828,7 @@ }, "performanceData": { "$ref": "AssetPerformanceData", - "description": "Output only. Performance data for the asset.", - "readOnly": true + "description": "Performance data for the asset." }, "sources": { "description": "Output only. The list of sources contributing to the asset.", @@ -2969,6 +2968,10 @@ "readOnly": true, "type": "string" }, + "inventory": { + "$ref": "AssetsExportJobInventory", + "description": "Export asset inventory details." + }, "labels": { "additionalProperties": { "type": "string" @@ -2985,6 +2988,10 @@ "$ref": "AssetsExportJobNetworkDependencies", "description": "Export data regarding asset network dependencies." }, + "performanceData": { + "$ref": "AssetsExportJobPerformanceData", + "description": "Export asset with performance data." + }, "recentExecutions": { "description": "Output only. Recent non expired executions of the job.", "items": { @@ -2993,6 +3000,10 @@ "readOnly": true, "type": "array" }, + "showHidden": { + "description": "Optional. When this value is set to 'true' the response will include all assets, including those that are hidden.", + "type": "boolean" + }, "signedUriDestination": { "$ref": "SignedUriDestination", "description": "Export to Cloud Storage files downloadable using signed URIs." @@ -3027,6 +3038,12 @@ "readOnly": true, "type": "string" }, + "requestedAssetCount": { + "description": "Output only. Number of assets requested for export after resolving the requested filters.", + "format": "int32", + "readOnly": true, + "type": "integer" + }, "result": { "$ref": "AssetsExportJobExecutionResult", "description": "Output only. Result of the export execution.", @@ -3050,6 +3067,11 @@ "description": "Output only. Error encountered during export.", "readOnly": true }, + "outputFiles": { + "$ref": "OutputFileList", + "description": "Output only. List of output files.", + "readOnly": true + }, "signedUris": { "$ref": "SignedUris", "description": "Output only. Signed URLs for downloading export artifacts.", @@ -3069,6 +3091,12 @@ }, "type": "object" }, + "AssetsExportJobInventory": { + "description": "Configuration for asset inventory details exports.", + "id": "AssetsExportJobInventory", + "properties": {}, + "type": "object" + }, "AssetsExportJobNetworkDependencies": { "description": "Configuration for network dependencies exports.", "id": "AssetsExportJobNetworkDependencies", @@ -3081,6 +3109,18 @@ }, "type": "object" }, + "AssetsExportJobPerformanceData": { + "description": "Configuration for performance data exports.", + "id": "AssetsExportJobPerformanceData", + "properties": { + "maxDays": { + "description": "Optional. When this value is set to a positive integer, performance data will be returned for the most recent days for which data is available. When this value is unset (or set to zero), all available data is returned. The maximum value is 420; values above 420 will be coerced to 420. If unset (0 value) a default value of 40 will be used.", + "format": "int32", + "type": "integer" + } + }, + "type": "object" + }, "AwsEc2PlatformDetails": { "description": "AWS EC2 specific details.", "id": "AwsEc2PlatformDetails", @@ -3228,7 +3268,7 @@ }, "cloudSqlForPostgresqlShape": { "$ref": "CloudSqlForPostgreSqlShape", - "description": "Cloud SQL for Postgres database shape." + "description": "Cloud SQL for PostgreSQL database shape." }, "cloudSqlShape": { "$ref": "CloudSqlForSqlServerShape", @@ -3653,7 +3693,7 @@ "type": "integer" }, "type": { - "description": "Disk type backing the storage.", + "description": "Output only. Disk type backing the storage.", "enum": [ "PERSISTENT_DISK_TYPE_UNSPECIFIED", "PERSISTENT_DISK_TYPE_STANDARD", @@ -3666,6 +3706,7 @@ "Balanced Persistent Disk.", "SSD Persistent Disk." ], + "readOnly": true, "type": "string" } }, @@ -3683,6 +3724,30 @@ }, "type": "object" }, + "CsvOutputFile": { + "description": "Contains a single output file of type CSV.", + "id": "CsvOutputFile", + "properties": { + "columnsCount": { + "description": "Output only. Number of columns in the file.", + "format": "int32", + "readOnly": true, + "type": "integer" + }, + "rowCount": { + "description": "Output only. Number of rows in the file.", + "format": "int32", + "readOnly": true, + "type": "integer" + }, + "signedUri": { + "$ref": "SignedUri", + "description": "Output only. Signed URI destination.", + "readOnly": true + } + }, + "type": "object" + }, "DailyResourceUsageAggregation": { "description": "Usage data aggregation for a single day.", "id": "DailyResourceUsageAggregation", @@ -4153,7 +4218,7 @@ "id": "DatabasePreferencesCloudSqlCommonBackup", "properties": { "backupMode": { - "description": "Optional. Mode of automated backups.", + "description": "Optional. Automated backup mode.", "enum": [ "BACKUP_MODE_UNSPECIFIED", "BACKUP_MODE_DISABLED", @@ -4695,7 +4760,7 @@ "id": "FitDescriptor", "properties": { "fitLevel": { - "description": "Fit level.", + "description": "Output only. Fit level.", "enum": [ "FIT_LEVEL_UNSPECIFIED", "FIT", @@ -4708,6 +4773,7 @@ "No Fit.", "Fit with effort." ], + "readOnly": true, "type": "string" } }, @@ -4926,7 +4992,8 @@ }, "hosts": { "$ref": "HostsEntryList", - "description": "Hosts file (/etc/hosts)." + "description": "Output only. Hosts file (/etc/hosts).", + "readOnly": true }, "issue": { "description": "OS issue (typically /etc/issue in Linux).", @@ -5068,10 +5135,11 @@ "id": "HostsEntryList", "properties": { "entries": { - "description": "Hosts entries.", + "description": "Output only. Hosts entries.", "items": { "$ref": "HostsEntry" }, + "readOnly": true, "type": "array" } }, @@ -6496,6 +6564,38 @@ }, "type": "object" }, + "OutputFile": { + "description": "Contains a single output file.", + "id": "OutputFile", + "properties": { + "csvOutputFile": { + "$ref": "CsvOutputFile", + "description": "Output only. CSV output file.", + "readOnly": true + }, + "fileSizeBytes": { + "description": "Output only. File size in bytes.", + "format": "int32", + "readOnly": true, + "type": "integer" + } + }, + "type": "object" + }, + "OutputFileList": { + "description": "Contains a list of output files.", + "id": "OutputFileList", + "properties": { + "entries": { + "description": "List of output files.", + "items": { + "$ref": "OutputFile" + }, + "type": "array" + } + }, + "type": "object" + }, "PayloadFile": { "description": "Payload file for inline import job payload.", "id": "PayloadFile", diff --git a/migrationcenter/v1alpha1/migrationcenter-gen.go b/migrationcenter/v1alpha1/migrationcenter-gen.go index 85975efde99..05a30a95153 100644 --- a/migrationcenter/v1alpha1/migrationcenter-gen.go +++ b/migrationcenter/v1alpha1/migrationcenter-gen.go @@ -716,7 +716,7 @@ type Asset struct { Labels map[string]string `json:"labels,omitempty"` // Name: Output only. The full name of the asset. Name string `json:"name,omitempty"` - // PerformanceData: Output only. Performance data for the asset. + // PerformanceData: Performance data for the asset. PerformanceData *AssetPerformanceData `json:"performanceData,omitempty"` // Sources: Output only. The list of sources contributing to the asset. Sources []string `json:"sources,omitempty"` @@ -852,6 +852,8 @@ type AssetsExportJob struct { Condition *AssetsExportJobExportCondition `json:"condition,omitempty"` // CreateTime: Output only. Resource creation time. CreateTime string `json:"createTime,omitempty"` + // Inventory: Export asset inventory details. + Inventory *AssetsExportJobInventory `json:"inventory,omitempty"` // Labels: Optional. Labels as key value pairs. Labels must meet the following // constraints: * Keys and values can contain only lowercase letters, numeric // characters, underscores, and dashes. * All characters must use UTF-8 @@ -864,8 +866,13 @@ type AssetsExportJob struct { Name string `json:"name,omitempty"` // NetworkDependencies: Export data regarding asset network dependencies. NetworkDependencies *AssetsExportJobNetworkDependencies `json:"networkDependencies,omitempty"` + // PerformanceData: Export asset with performance data. + PerformanceData *AssetsExportJobPerformanceData `json:"performanceData,omitempty"` // RecentExecutions: Output only. Recent non expired executions of the job. RecentExecutions []*AssetsExportJobExecution `json:"recentExecutions,omitempty"` + // ShowHidden: Optional. When this value is set to 'true' the response will + // include all assets, including those that are hidden. + ShowHidden bool `json:"showHidden,omitempty"` // SignedUriDestination: Export to Cloud Storage files downloadable using // signed URIs. SignedUriDestination *SignedUriDestination `json:"signedUriDestination,omitempty"` @@ -900,6 +907,9 @@ type AssetsExportJobExecution struct { ExecutionId string `json:"executionId,omitempty"` // ExpireTime: Output only. Expiration time for the export and artifacts. ExpireTime string `json:"expireTime,omitempty"` + // RequestedAssetCount: Output only. Number of assets requested for export + // after resolving the requested filters. + RequestedAssetCount int64 `json:"requestedAssetCount,omitempty"` // Result: Output only. Result of the export execution. Result *AssetsExportJobExecutionResult `json:"result,omitempty"` // StartTime: Output only. Execution timestamp. @@ -926,6 +936,8 @@ func (s AssetsExportJobExecution) MarshalJSON() ([]byte, error) { type AssetsExportJobExecutionResult struct { // Error: Output only. Error encountered during export. Error *Status `json:"error,omitempty"` + // OutputFiles: Output only. List of output files. + OutputFiles *OutputFileList `json:"outputFiles,omitempty"` // SignedUris: Output only. Signed URLs for downloading export artifacts. SignedUris *SignedUris `json:"signedUris,omitempty"` // ForceSendFields is a list of field names (e.g. "Error") to unconditionally @@ -968,6 +980,10 @@ func (s AssetsExportJobExportCondition) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// AssetsExportJobInventory: Configuration for asset inventory details exports. +type AssetsExportJobInventory struct { +} + // AssetsExportJobNetworkDependencies: Configuration for network dependencies // exports. type AssetsExportJobNetworkDependencies struct { @@ -994,6 +1010,32 @@ func (s AssetsExportJobNetworkDependencies) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// AssetsExportJobPerformanceData: Configuration for performance data exports. +type AssetsExportJobPerformanceData struct { + // MaxDays: Optional. When this value is set to a positive integer, performance + // data will be returned for the most recent days for which data is available. + // When this value is unset (or set to zero), all available data is returned. + // The maximum value is 420; values above 420 will be coerced to 420. If unset + // (0 value) a default value of 40 will be used. + MaxDays int64 `json:"maxDays,omitempty"` + // ForceSendFields is a list of field names (e.g. "MaxDays") 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. "MaxDays") 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 AssetsExportJobPerformanceData) MarshalJSON() ([]byte, error) { + type NoMethod AssetsExportJobPerformanceData + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // AwsEc2PlatformDetails: AWS EC2 specific details. type AwsEc2PlatformDetails struct { // Location: The location of the machine in the AWS format. @@ -1189,7 +1231,7 @@ func (s CascadingRule) MarshalJSON() ([]byte, error) { type CloudDatabaseMigrationTarget struct { // CloudSqlForMysqlShape: Cloud SQL for MySQL database shape. CloudSqlForMysqlShape *CloudSqlForMySqlShape `json:"cloudSqlForMysqlShape,omitempty"` - // CloudSqlForPostgresqlShape: Cloud SQL for Postgres database shape. + // CloudSqlForPostgresqlShape: Cloud SQL for PostgreSQL database shape. CloudSqlForPostgresqlShape *CloudSqlForPostgreSqlShape `json:"cloudSqlForPostgresqlShape,omitempty"` // CloudSqlShape: Cloud SQL for SQL Server database shape. CloudSqlShape *CloudSqlForSqlServerShape `json:"cloudSqlShape,omitempty"` @@ -1555,7 +1597,7 @@ type ComputeEngineSoleTenantMigrationTarget struct { type ComputeStorageDescriptor struct { // SizeGb: Disk size in GiB. SizeGb int64 `json:"sizeGb,omitempty"` - // Type: Disk type backing the storage. + // Type: Output only. Disk type backing the storage. // // Possible values: // "PERSISTENT_DISK_TYPE_UNSPECIFIED" - Unspecified (default value). @@ -1621,6 +1663,32 @@ func (s *CpuUsageSample) UnmarshalJSON(data []byte) error { return nil } +// CsvOutputFile: Contains a single output file of type CSV. +type CsvOutputFile struct { + // ColumnsCount: Output only. Number of columns in the file. + ColumnsCount int64 `json:"columnsCount,omitempty"` + // RowCount: Output only. Number of rows in the file. + RowCount int64 `json:"rowCount,omitempty"` + // SignedUri: Output only. Signed URI destination. + SignedUri *SignedUri `json:"signedUri,omitempty"` + // ForceSendFields is a list of field names (e.g. "ColumnsCount") 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. "ColumnsCount") 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 CsvOutputFile) MarshalJSON() ([]byte, error) { + type NoMethod CsvOutputFile + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // DailyResourceUsageAggregation: Usage data aggregation for a single day. type DailyResourceUsageAggregation struct { // Cpu: CPU usage. @@ -2175,7 +2243,7 @@ func (s DatabasePreferencesCloudSqlCommon) MarshalJSON() ([]byte, error) { // DatabasePreferencesCloudSqlCommonBackup: Preferences for database backups. type DatabasePreferencesCloudSqlCommonBackup struct { - // BackupMode: Optional. Mode of automated backups. + // BackupMode: Optional. Automated backup mode. // // Possible values: // "BACKUP_MODE_UNSPECIFIED" - An unspecified database backup mode. @@ -2791,7 +2859,7 @@ func (s FileValidationReport) MarshalJSON() ([]byte, error) { // FitDescriptor: Describes the fit level of an asset for migration to a // specific target. type FitDescriptor struct { - // FitLevel: Fit level. + // FitLevel: Output only. Fit level. // // Possible values: // "FIT_LEVEL_UNSPECIFIED" - Not enough information. @@ -3064,7 +3132,7 @@ func (s Group) MarshalJSON() ([]byte, error) { type GuestConfigDetails struct { // Fstab: Mount list (Linux fstab). Fstab *FstabEntryList `json:"fstab,omitempty"` - // Hosts: Hosts file (/etc/hosts). + // Hosts: Output only. Hosts file (/etc/hosts). Hosts *HostsEntryList `json:"hosts,omitempty"` // Issue: OS issue (typically /etc/issue in Linux). Issue string `json:"issue,omitempty"` @@ -3230,7 +3298,7 @@ func (s HostsEntry) MarshalJSON() ([]byte, error) { // HostsEntryList: Hosts content. type HostsEntryList struct { - // Entries: Hosts entries. + // Entries: Output only. Hosts entries. Entries []*HostsEntry `json:"entries,omitempty"` // ForceSendFields is a list of field names (e.g. "Entries") to unconditionally // include in API requests. By default, fields with empty or default values are @@ -4905,6 +4973,52 @@ func (s OperationMetadata) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// OutputFile: Contains a single output file. +type OutputFile struct { + // CsvOutputFile: Output only. CSV output file. + CsvOutputFile *CsvOutputFile `json:"csvOutputFile,omitempty"` + // FileSizeBytes: Output only. File size in bytes. + FileSizeBytes int64 `json:"fileSizeBytes,omitempty"` + // ForceSendFields is a list of field names (e.g. "CsvOutputFile") 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. "CsvOutputFile") 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 OutputFile) MarshalJSON() ([]byte, error) { + type NoMethod OutputFile + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// OutputFileList: Contains a list of output files. +type OutputFileList struct { + // Entries: List of output files. + Entries []*OutputFile `json:"entries,omitempty"` + // ForceSendFields is a list of field names (e.g. "Entries") 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. "Entries") 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 OutputFileList) MarshalJSON() ([]byte, error) { + type NoMethod OutputFileList + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // PayloadFile: Payload file for inline import job payload. type PayloadFile struct { // Data: The file data. diff --git a/monitoring/v1/monitoring-api.json b/monitoring/v1/monitoring-api.json index 044e2a7a78f..b4218c60958 100644 --- a/monitoring/v1/monitoring-api.json +++ b/monitoring/v1/monitoring-api.json @@ -753,7 +753,7 @@ } } }, - "revision": "20240721", + "revision": "20240829", "rootUrl": "https://monitoring.googleapis.com/", "schemas": { "Aggregation": { @@ -1022,10 +1022,37 @@ "description": "The persistent settings for a table's columns.", "id": "ColumnSettings", "properties": { + "alignment": { + "description": "Optional. Whether the column should be left / middle / right aligned", + "enum": [ + "CELL_ALIGNMENT_UNSPECIFIED", + "LEFT", + "CENTER", + "RIGHT" + ], + "enumDescriptions": [ + "No horizontal alignment specified; fall back to the default behavior. Label values are left aligned. Numeric values are right aligned.", + "Left-align", + "Center-align", + "Right-align" + ], + "type": "string" + }, "column": { "description": "Required. The id of the column.", "type": "string" }, + "displayName": { + "description": "Optional. Display name of the column", + "type": "string" + }, + "thresholds": { + "description": "Optional. The thresholds used to determine how the table cell should be rendered given the time series' current value.", + "items": { + "$ref": "Threshold" + }, + "type": "array" + }, "visible": { "description": "Required. Whether the column should be visible on page load.", "type": "boolean" diff --git a/monitoring/v1/monitoring-gen.go b/monitoring/v1/monitoring-gen.go index 44e2c63cb29..6d63f950e23 100644 --- a/monitoring/v1/monitoring-gen.go +++ b/monitoring/v1/monitoring-gen.go @@ -801,17 +801,33 @@ func (s ColumnLayout) MarshalJSON() ([]byte, error) { // ColumnSettings: The persistent settings for a table's columns. type ColumnSettings struct { + // Alignment: Optional. Whether the column should be left / middle / right + // aligned + // + // Possible values: + // "CELL_ALIGNMENT_UNSPECIFIED" - No horizontal alignment specified; fall + // back to the default behavior. Label values are left aligned. Numeric values + // are right aligned. + // "LEFT" - Left-align + // "CENTER" - Center-align + // "RIGHT" - Right-align + Alignment string `json:"alignment,omitempty"` // Column: Required. The id of the column. Column string `json:"column,omitempty"` + // DisplayName: Optional. Display name of the column + DisplayName string `json:"displayName,omitempty"` + // Thresholds: Optional. The thresholds used to determine how the table cell + // should be rendered given the time series' current value. + Thresholds []*Threshold `json:"thresholds,omitempty"` // Visible: Required. Whether the column should be visible on page load. Visible bool `json:"visible,omitempty"` - // ForceSendFields is a list of field names (e.g. "Column") to unconditionally - // include in API requests. By default, fields with empty or default values are - // omitted from API requests. See + // ForceSendFields is a list of field names (e.g. "Alignment") 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. "Column") to include in API + // NullFields is a list of field names (e.g. "Alignment") 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. diff --git a/monitoring/v3/monitoring-api.json b/monitoring/v3/monitoring-api.json index 9516ccabac5..ad5a3845356 100644 --- a/monitoring/v3/monitoring-api.json +++ b/monitoring/v3/monitoring-api.json @@ -2114,7 +2114,7 @@ }, "query": { "deprecated": true, - "description": "Queries time series using Monitoring Query Language.", + "description": "Queries time series by using Monitoring Query Language (MQL). We recommend using PromQL instead of MQL. For more information about the status of MQL, see the MQL deprecation notice (https://cloud.google.com/stackdriver/docs/deprecations/mql).", "flatPath": "v3/projects/{projectsId}/timeSeries:query", "httpMethod": "POST", "id": "monitoring.projects.timeSeries.query", @@ -2715,7 +2715,7 @@ } } }, - "revision": "20240818", + "revision": "20240829", "rootUrl": "https://monitoring.googleapis.com/", "schemas": { "Aggregation": { @@ -4621,6 +4621,25 @@ "description": "The sampling period of metric data points. For metrics which are written periodically, consecutive data points are stored at this time interval, excluding data loss due to errors. Metrics with a higher granularity have a smaller sampling period.", "format": "google-duration", "type": "string" + }, + "timeSeriesResourceHierarchyLevel": { + "description": "The scope of the timeseries data of the metric.", + "items": { + "enum": [ + "TIME_SERIES_RESOURCE_HIERARCHY_LEVEL_UNSPECIFIED", + "PROJECT", + "ORGANIZATION", + "FOLDER" + ], + "enumDescriptions": [ + "Do not use this default value.", + "Scopes a metric to a project.", + "Scopes a metric to an organization.", + "Scopes a metric to a folder." + ], + "type": "string" + }, + "type": "array" } }, "type": "object" @@ -5197,7 +5216,7 @@ }, "QueryTimeSeriesRequest": { "deprecated": true, - "description": "The QueryTimeSeries request.", + "description": "The QueryTimeSeries request. For information about the status of Monitoring Query Language (MQL), see the MQL deprecation notice (https://cloud.google.com/stackdriver/docs/deprecations/mql).", "id": "QueryTimeSeriesRequest", "properties": { "pageSize": { @@ -5218,7 +5237,7 @@ }, "QueryTimeSeriesResponse": { "deprecated": true, - "description": "The QueryTimeSeries response.", + "description": "The QueryTimeSeries response. For information about the status of Monitoring Query Language (MQL), see the MQL deprecation notice (https://cloud.google.com/stackdriver/docs/deprecations/mql).", "id": "QueryTimeSeriesResponse", "properties": { "nextPageToken": { diff --git a/monitoring/v3/monitoring-gen.go b/monitoring/v3/monitoring-gen.go index 7849479439a..e2d32dd06c0 100644 --- a/monitoring/v3/monitoring-gen.go +++ b/monitoring/v3/monitoring-gen.go @@ -3387,6 +3387,16 @@ type MetricDescriptorMetadata struct { // interval, excluding data loss due to errors. Metrics with a higher // granularity have a smaller sampling period. SamplePeriod string `json:"samplePeriod,omitempty"` + // TimeSeriesResourceHierarchyLevel: The scope of the timeseries data of the + // metric. + // + // Possible values: + // "TIME_SERIES_RESOURCE_HIERARCHY_LEVEL_UNSPECIFIED" - Do not use this + // default value. + // "PROJECT" - Scopes a metric to a project. + // "ORGANIZATION" - Scopes a metric to an organization. + // "FOLDER" - Scopes a metric to a folder. + TimeSeriesResourceHierarchyLevel []string `json:"timeSeriesResourceHierarchyLevel,omitempty"` // ForceSendFields is a list of field names (e.g. "IngestDelay") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See @@ -4329,7 +4339,9 @@ func (s PrometheusQueryLanguageCondition) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// QueryTimeSeriesRequest: The QueryTimeSeries request. +// QueryTimeSeriesRequest: The QueryTimeSeries request. For information about +// the status of Monitoring Query Language (MQL), see the MQL deprecation +// notice (https://cloud.google.com/stackdriver/docs/deprecations/mql). type QueryTimeSeriesRequest struct { // PageSize: A positive number that is the maximum number of time_series_data // to return. @@ -4360,7 +4372,9 @@ func (s QueryTimeSeriesRequest) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// QueryTimeSeriesResponse: The QueryTimeSeries response. +// QueryTimeSeriesResponse: The QueryTimeSeries response. For information about +// the status of Monitoring Query Language (MQL), see the MQL deprecation +// notice (https://cloud.google.com/stackdriver/docs/deprecations/mql). type QueryTimeSeriesResponse struct { // NextPageToken: If there are more results than have been returned, then this // field is set to a non-empty value. To see the additional results, use that @@ -12108,7 +12122,10 @@ type ProjectsTimeSeriesQueryCall struct { header_ http.Header } -// Query: Queries time series using Monitoring Query Language. +// Query: Queries time series by using Monitoring Query Language (MQL). We +// recommend using PromQL instead of MQL. For more information about the status +// of MQL, see the MQL deprecation notice +// (https://cloud.google.com/stackdriver/docs/deprecations/mql). // // - name: The project // (https://cloud.google.com/monitoring/api/v3#project_name) on which to diff --git a/networksecurity/v1/networksecurity-api.json b/networksecurity/v1/networksecurity-api.json index 8c16ba9a9a7..e33b145cd4d 100644 --- a/networksecurity/v1/networksecurity-api.json +++ b/networksecurity/v1/networksecurity-api.json @@ -3253,7 +3253,7 @@ } } }, - "revision": "20240803", + "revision": "20240828", "rootUrl": "https://networksecurity.googleapis.com/", "schemas": { "AddAddressGroupItemsRequest": { @@ -3678,14 +3678,16 @@ "CREATING", "ACTIVE", "DELETING", - "INACTIVE" + "INACTIVE", + "ORPHAN" ], "enumDescriptions": [ "Not set.", "Being created.", "Active and ready for traffic.", "Being deleted.", - "Down or in an error state." + "Down or in an error state.", + "The GCP project that housed the association has been deleted." ], "readOnly": true, "type": "string" diff --git a/networksecurity/v1/networksecurity-gen.go b/networksecurity/v1/networksecurity-gen.go index dbec869f975..b4a0efe6632 100644 --- a/networksecurity/v1/networksecurity-gen.go +++ b/networksecurity/v1/networksecurity-gen.go @@ -832,6 +832,7 @@ type FirewallEndpointAssociation struct { // "ACTIVE" - Active and ready for traffic. // "DELETING" - Being deleted. // "INACTIVE" - Down or in an error state. + // "ORPHAN" - The GCP project that housed the association has been deleted. State string `json:"state,omitempty"` // TlsInspectionPolicy: Optional. The URL of the TlsInspectionPolicy that is // being associated. diff --git a/networksecurity/v1beta1/networksecurity-api.json b/networksecurity/v1beta1/networksecurity-api.json index 120fe67837f..98d2218917d 100644 --- a/networksecurity/v1beta1/networksecurity-api.json +++ b/networksecurity/v1beta1/networksecurity-api.json @@ -2740,122 +2740,181 @@ } } }, - "operations": { + "mirroringDeploymentGroups": { "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": "v1beta1/projects/{projectsId}/locations/{locationsId}/operations/{operationsId}:cancel", + "create": { + "description": "Creates a new MirroringDeploymentGroup in a given project and location.", + "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/mirroringDeploymentGroups", "httpMethod": "POST", - "id": "networksecurity.projects.locations.operations.cancel", + "id": "networksecurity.projects.locations.mirroringDeploymentGroups.create", "parameterOrder": [ - "name" + "parent" ], "parameters": { - "name": { - "description": "The name of the operation resource to be cancelled.", + "mirroringDeploymentGroupId": { + "description": "Required. Id of the requesting object If auto-generating Id server-side, remove this field and mirroring_deployment_group_id from the method_signature of Create RPC", + "location": "query", + "type": "string" + }, + "parent": { + "description": "Required. Value for parent.", "location": "path", - "pattern": "^projects/[^/]+/locations/[^/]+/operations/[^/]+$", + "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" } }, - "path": "v1beta1/{+name}:cancel", + "path": "v1beta1/{+parent}/mirroringDeploymentGroups", "request": { - "$ref": "CancelOperationRequest" + "$ref": "MirroringDeploymentGroup" }, "response": { - "$ref": "Empty" + "$ref": "Operation" }, "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": "v1beta1/projects/{projectsId}/locations/{locationsId}/operations/{operationsId}", + "description": "Deletes a single MirroringDeploymentGroup.", + "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/mirroringDeploymentGroups/{mirroringDeploymentGroupsId}", "httpMethod": "DELETE", - "id": "networksecurity.projects.locations.operations.delete", + "id": "networksecurity.projects.locations.mirroringDeploymentGroups.delete", "parameterOrder": [ "name" ], "parameters": { "name": { - "description": "The name of the operation resource to be deleted.", + "description": "Required. Name of the resource", "location": "path", - "pattern": "^projects/[^/]+/locations/[^/]+/operations/[^/]+$", + "pattern": "^projects/[^/]+/locations/[^/]+/mirroringDeploymentGroups/[^/]+$", "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" } }, "path": "v1beta1/{+name}", "response": { - "$ref": "Empty" + "$ref": "Operation" }, "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": "v1beta1/projects/{projectsId}/locations/{locationsId}/operations/{operationsId}", + "description": "Gets details of a single MirroringDeploymentGroup.", + "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/mirroringDeploymentGroups/{mirroringDeploymentGroupsId}", "httpMethod": "GET", - "id": "networksecurity.projects.locations.operations.get", + "id": "networksecurity.projects.locations.mirroringDeploymentGroups.get", "parameterOrder": [ "name" ], "parameters": { "name": { - "description": "The name of the operation resource.", + "description": "Required. Name of the resource", "location": "path", - "pattern": "^projects/[^/]+/locations/[^/]+/operations/[^/]+$", + "pattern": "^projects/[^/]+/locations/[^/]+/mirroringDeploymentGroups/[^/]+$", "required": true, "type": "string" } }, "path": "v1beta1/{+name}", "response": { - "$ref": "Operation" + "$ref": "MirroringDeploymentGroup" }, "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": "v1beta1/projects/{projectsId}/locations/{locationsId}/operations", + "description": "Lists MirroringDeploymentGroups in a given project and location.", + "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/mirroringDeploymentGroups", "httpMethod": "GET", - "id": "networksecurity.projects.locations.operations.list", + "id": "networksecurity.projects.locations.mirroringDeploymentGroups.list", "parameterOrder": [ - "name" + "parent" ], "parameters": { "filter": { - "description": "The standard list filter.", + "description": "Optional. Filtering results", "location": "query", "type": "string" }, - "name": { - "description": "The name of the operation's parent resource.", - "location": "path", - "pattern": "^projects/[^/]+/locations/[^/]+$", - "required": true, + "orderBy": { + "description": "Optional. Hint for how to order the results", + "location": "query", "type": "string" }, "pageSize": { - "description": "The standard list page size.", + "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": "The standard list page token.", + "description": "Optional. A token identifying a page of results the server should return.", + "location": "query", + "type": "string" + }, + "parent": { + "description": "Required. Parent value for ListMirroringDeploymentGroupsRequest", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1beta1/{+parent}/mirroringDeploymentGroups", + "response": { + "$ref": "ListMirroringDeploymentGroupsResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "patch": { + "description": "Updates a single MirroringDeploymentGroup.", + "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/mirroringDeploymentGroups/{mirroringDeploymentGroupsId}", + "httpMethod": "PATCH", + "id": "networksecurity.projects.locations.mirroringDeploymentGroups.patch", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Immutable. Identifier. Then name of the MirroringDeploymentGroup.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/mirroringDeploymentGroups/[^/]+$", + "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 MirroringDeploymentGroup 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" } }, - "path": "v1beta1/{+name}/operations", + "path": "v1beta1/{+name}", + "request": { + "$ref": "MirroringDeploymentGroup" + }, "response": { - "$ref": "ListOperationsResponse" + "$ref": "Operation" }, "scopes": [ "https://www.googleapis.com/auth/cloud-platform" @@ -2863,33 +2922,38 @@ } } }, - "serverTlsPolicies": { + "mirroringDeployments": { "methods": { "create": { - "description": "Creates a new ServerTlsPolicy in a given project and location.", - "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/serverTlsPolicies", + "description": "Creates a new MirroringDeployment in a given project and location.", + "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/mirroringDeployments", "httpMethod": "POST", - "id": "networksecurity.projects.locations.serverTlsPolicies.create", + "id": "networksecurity.projects.locations.mirroringDeployments.create", "parameterOrder": [ "parent" ], "parameters": { + "mirroringDeploymentId": { + "description": "Required. Id of the requesting object If auto-generating Id server-side, remove this field and mirroring_deployment_id from the method_signature of Create RPC", + "location": "query", + "type": "string" + }, "parent": { - "description": "Required. The parent resource of the ServerTlsPolicy. Must be in the format `projects/*/locations/{location}`.", + "description": "Required. Value for parent.", "location": "path", "pattern": "^projects/[^/]+/locations/[^/]+$", "required": true, "type": "string" }, - "serverTlsPolicyId": { - "description": "Required. Short name of the ServerTlsPolicy resource to be created. This value should be 1-63 characters long, containing only letters, numbers, hyphens, and underscores, and should not start with a number. E.g. \"server_mtls_policy\".", + "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" } }, - "path": "v1beta1/{+parent}/serverTlsPolicies", + "path": "v1beta1/{+parent}/mirroringDeployments", "request": { - "$ref": "ServerTlsPolicy" + "$ref": "MirroringDeployment" }, "response": { "$ref": "Operation" @@ -2899,20 +2963,25 @@ ] }, "delete": { - "description": "Deletes a single ServerTlsPolicy.", - "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/serverTlsPolicies/{serverTlsPoliciesId}", + "description": "Deletes a single MirroringDeployment.", + "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/mirroringDeployments/{mirroringDeploymentsId}", "httpMethod": "DELETE", - "id": "networksecurity.projects.locations.serverTlsPolicies.delete", + "id": "networksecurity.projects.locations.mirroringDeployments.delete", "parameterOrder": [ "name" ], "parameters": { "name": { - "description": "Required. A name of the ServerTlsPolicy to delete. Must be in the format `projects/*/locations/{location}/serverTlsPolicies/*`.", + "description": "Required. Name of the resource", "location": "path", - "pattern": "^projects/[^/]+/locations/[^/]+/serverTlsPolicies/[^/]+$", + "pattern": "^projects/[^/]+/locations/[^/]+/mirroringDeployments/[^/]+$", "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" } }, "path": "v1beta1/{+name}", @@ -2924,115 +2993,99 @@ ] }, "get": { - "description": "Gets details of a single ServerTlsPolicy.", - "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/serverTlsPolicies/{serverTlsPoliciesId}", + "description": "Gets details of a single MirroringDeployment.", + "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/mirroringDeployments/{mirroringDeploymentsId}", "httpMethod": "GET", - "id": "networksecurity.projects.locations.serverTlsPolicies.get", + "id": "networksecurity.projects.locations.mirroringDeployments.get", "parameterOrder": [ "name" ], "parameters": { "name": { - "description": "Required. A name of the ServerTlsPolicy to get. Must be in the format `projects/*/locations/{location}/serverTlsPolicies/*`.", + "description": "Required. Name of the resource", "location": "path", - "pattern": "^projects/[^/]+/locations/[^/]+/serverTlsPolicies/[^/]+$", + "pattern": "^projects/[^/]+/locations/[^/]+/mirroringDeployments/[^/]+$", "required": true, "type": "string" } }, "path": "v1beta1/{+name}", "response": { - "$ref": "ServerTlsPolicy" + "$ref": "MirroringDeployment" }, "scopes": [ "https://www.googleapis.com/auth/cloud-platform" ] }, - "getIamPolicy": { - "description": "Gets the access control policy for a resource. Returns an empty policy if the resource exists and does not have a policy set.", - "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/serverTlsPolicies/{serverTlsPoliciesId}:getIamPolicy", + "list": { + "description": "Lists MirroringDeployments in a given project and location.", + "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/mirroringDeployments", "httpMethod": "GET", - "id": "networksecurity.projects.locations.serverTlsPolicies.getIamPolicy", + "id": "networksecurity.projects.locations.mirroringDeployments.list", "parameterOrder": [ - "resource" + "parent" ], "parameters": { - "options.requestedPolicyVersion": { - "description": "Optional. The maximum policy version that will be used to format the policy. Valid values are 0, 1, and 3. Requests specifying an invalid value will be rejected. Requests for policies with any conditional role bindings must specify version 3. Policies with no conditional role bindings may specify any valid value or leave the field unset. The policy in the response might use the policy version that you specified, or it might use a lower policy version. For example, if you specify version 3, but the policy has no conditional role bindings, the response uses version 1. To learn which resources support conditions in their IAM policies, see the [IAM documentation](https://cloud.google.com/iam/help/conditions/resource-policies).", - "format": "int32", + "filter": { + "description": "Optional. Filtering results", "location": "query", - "type": "integer" + "type": "string" }, - "resource": { - "description": "REQUIRED: The resource for which the policy is being requested. See [Resource names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field.", - "location": "path", - "pattern": "^projects/[^/]+/locations/[^/]+/serverTlsPolicies/[^/]+$", - "required": true, + "orderBy": { + "description": "Optional. Hint for how to order the results", + "location": "query", "type": "string" - } - }, - "path": "v1beta1/{+resource}:getIamPolicy", - "response": { - "$ref": "GoogleIamV1Policy" - }, - "scopes": [ - "https://www.googleapis.com/auth/cloud-platform" - ] - }, - "list": { - "description": "Lists ServerTlsPolicies in a given project and location.", - "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/serverTlsPolicies", - "httpMethod": "GET", - "id": "networksecurity.projects.locations.serverTlsPolicies.list", - "parameterOrder": [ - "parent" - ], - "parameters": { + }, "pageSize": { - "description": "Maximum number of ServerTlsPolicies to return per call.", + "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": "The value returned by the last `ListServerTlsPoliciesResponse` Indicates that this is a continuation of a prior `ListServerTlsPolicies` call, and that the system should return the next page of data.", + "description": "Optional. A token identifying a page of results the server should return.", "location": "query", "type": "string" }, "parent": { - "description": "Required. The project and location from which the ServerTlsPolicies should be listed, specified in the format `projects/*/locations/{location}`.", + "description": "Required. Parent value for ListMirroringDeploymentsRequest", "location": "path", "pattern": "^projects/[^/]+/locations/[^/]+$", "required": true, "type": "string" } }, - "path": "v1beta1/{+parent}/serverTlsPolicies", + "path": "v1beta1/{+parent}/mirroringDeployments", "response": { - "$ref": "ListServerTlsPoliciesResponse" + "$ref": "ListMirroringDeploymentsResponse" }, "scopes": [ "https://www.googleapis.com/auth/cloud-platform" ] }, "patch": { - "description": "Updates the parameters of a single ServerTlsPolicy.", - "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/serverTlsPolicies/{serverTlsPoliciesId}", + "description": "Updates a single MirroringDeployment.", + "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/mirroringDeployments/{mirroringDeploymentsId}", "httpMethod": "PATCH", - "id": "networksecurity.projects.locations.serverTlsPolicies.patch", + "id": "networksecurity.projects.locations.mirroringDeployments.patch", "parameterOrder": [ "name" ], "parameters": { "name": { - "description": "Required. Name of the ServerTlsPolicy resource. It matches the pattern `projects/*/locations/{location}/serverTlsPolicies/{server_tls_policy}`", + "description": "Immutable. Identifier. The name of the MirroringDeployment.", "location": "path", - "pattern": "^projects/[^/]+/locations/[^/]+/serverTlsPolicies/[^/]+$", + "pattern": "^projects/[^/]+/locations/[^/]+/mirroringDeployments/[^/]+$", "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": "Optional. Field mask is used to specify the fields to be overwritten in the ServerTlsPolicy 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.", + "description": "Required. Field mask is used to specify the fields to be overwritten in the MirroringDeployment 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" @@ -3040,7 +3093,7 @@ }, "path": "v1beta1/{+name}", "request": { - "$ref": "ServerTlsPolicy" + "$ref": "MirroringDeployment" }, "response": { "$ref": "Operation" @@ -3048,67 +3101,742 @@ "scopes": [ "https://www.googleapis.com/auth/cloud-platform" ] - }, - "setIamPolicy": { - "description": "Sets the access control policy on the specified resource. Replaces any existing policy. Can return `NOT_FOUND`, `INVALID_ARGUMENT`, and `PERMISSION_DENIED` errors.", - "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/serverTlsPolicies/{serverTlsPoliciesId}:setIamPolicy", + } + } + }, + "mirroringEndpointGroupAssociations": { + "methods": { + "create": { + "description": "Creates a new MirroringEndpointGroupAssociation in a given project and location.", + "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/mirroringEndpointGroupAssociations", "httpMethod": "POST", - "id": "networksecurity.projects.locations.serverTlsPolicies.setIamPolicy", + "id": "networksecurity.projects.locations.mirroringEndpointGroupAssociations.create", "parameterOrder": [ - "resource" + "parent" ], "parameters": { - "resource": { - "description": "REQUIRED: The resource for which the policy is being specified. See [Resource names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field.", + "mirroringEndpointGroupAssociationId": { + "description": "Optional. Id of the requesting object If auto-generating Id server-side, remove this field and mirroring_endpoint_group_association_id from the method_signature of Create RPC", + "location": "query", + "type": "string" + }, + "parent": { + "description": "Required. Value for parent.", "location": "path", - "pattern": "^projects/[^/]+/locations/[^/]+/serverTlsPolicies/[^/]+$", + "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" } }, - "path": "v1beta1/{+resource}:setIamPolicy", + "path": "v1beta1/{+parent}/mirroringEndpointGroupAssociations", "request": { - "$ref": "GoogleIamV1SetIamPolicyRequest" + "$ref": "MirroringEndpointGroupAssociation" }, "response": { - "$ref": "GoogleIamV1Policy" + "$ref": "Operation" }, "scopes": [ "https://www.googleapis.com/auth/cloud-platform" ] }, - "testIamPermissions": { - "description": "Returns permissions that a caller has on the specified resource. If the resource does not exist, this will return an empty set of permissions, not a `NOT_FOUND` error. Note: This operation is designed to be used for building permission-aware UIs and command-line tools, not for authorization checking. This operation may \"fail open\" without warning.", - "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/serverTlsPolicies/{serverTlsPoliciesId}:testIamPermissions", - "httpMethod": "POST", - "id": "networksecurity.projects.locations.serverTlsPolicies.testIamPermissions", + "delete": { + "description": "Deletes a single MirroringEndpointGroupAssociation.", + "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/mirroringEndpointGroupAssociations/{mirroringEndpointGroupAssociationsId}", + "httpMethod": "DELETE", + "id": "networksecurity.projects.locations.mirroringEndpointGroupAssociations.delete", "parameterOrder": [ - "resource" + "name" ], "parameters": { - "resource": { - "description": "REQUIRED: The resource for which the policy detail is being requested. See [Resource names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field.", + "name": { + "description": "Required. Name of the resource", "location": "path", - "pattern": "^projects/[^/]+/locations/[^/]+/serverTlsPolicies/[^/]+$", + "pattern": "^projects/[^/]+/locations/[^/]+/mirroringEndpointGroupAssociations/[^/]+$", "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" } }, - "path": "v1beta1/{+resource}:testIamPermissions", - "request": { - "$ref": "GoogleIamV1TestIamPermissionsRequest" - }, + "path": "v1beta1/{+name}", "response": { - "$ref": "GoogleIamV1TestIamPermissionsResponse" + "$ref": "Operation" }, "scopes": [ "https://www.googleapis.com/auth/cloud-platform" ] - } - } - }, - "tlsInspectionPolicies": { - "methods": { + }, + "get": { + "description": "Gets details of a single MirroringEndpointGroupAssociation.", + "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/mirroringEndpointGroupAssociations/{mirroringEndpointGroupAssociationsId}", + "httpMethod": "GET", + "id": "networksecurity.projects.locations.mirroringEndpointGroupAssociations.get", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Required. Name of the resource", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/mirroringEndpointGroupAssociations/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1beta1/{+name}", + "response": { + "$ref": "MirroringEndpointGroupAssociation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "list": { + "description": "Lists MirroringEndpointGroupAssociations in a given project and location.", + "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/mirroringEndpointGroupAssociations", + "httpMethod": "GET", + "id": "networksecurity.projects.locations.mirroringEndpointGroupAssociations.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 ListMirroringEndpointGroupAssociationsRequest", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1beta1/{+parent}/mirroringEndpointGroupAssociations", + "response": { + "$ref": "ListMirroringEndpointGroupAssociationsResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "patch": { + "description": "Updates a single MirroringEndpointGroupAssociation.", + "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/mirroringEndpointGroupAssociations/{mirroringEndpointGroupAssociationsId}", + "httpMethod": "PATCH", + "id": "networksecurity.projects.locations.mirroringEndpointGroupAssociations.patch", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Immutable. Identifier. The name of the MirroringEndpointGroupAssociation.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/mirroringEndpointGroupAssociations/[^/]+$", + "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 MirroringEndpointGroupAssociation 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" + } + }, + "path": "v1beta1/{+name}", + "request": { + "$ref": "MirroringEndpointGroupAssociation" + }, + "response": { + "$ref": "Operation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + } + } + }, + "mirroringEndpointGroups": { + "methods": { + "create": { + "description": "Creates a new MirroringEndpointGroup in a given project and location.", + "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/mirroringEndpointGroups", + "httpMethod": "POST", + "id": "networksecurity.projects.locations.mirroringEndpointGroups.create", + "parameterOrder": [ + "parent" + ], + "parameters": { + "mirroringEndpointGroupId": { + "description": "Required. Id of the requesting object If auto-generating Id server-side, remove this field and mirroring_endpoint_group_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" + } + }, + "path": "v1beta1/{+parent}/mirroringEndpointGroups", + "request": { + "$ref": "MirroringEndpointGroup" + }, + "response": { + "$ref": "Operation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "delete": { + "description": "Deletes a single MirroringEndpointGroup.", + "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/mirroringEndpointGroups/{mirroringEndpointGroupsId}", + "httpMethod": "DELETE", + "id": "networksecurity.projects.locations.mirroringEndpointGroups.delete", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Required. Name of the resource", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/mirroringEndpointGroups/[^/]+$", + "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" + } + }, + "path": "v1beta1/{+name}", + "response": { + "$ref": "Operation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "get": { + "description": "Gets details of a single MirroringEndpointGroup.", + "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/mirroringEndpointGroups/{mirroringEndpointGroupsId}", + "httpMethod": "GET", + "id": "networksecurity.projects.locations.mirroringEndpointGroups.get", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Required. Name of the resource", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/mirroringEndpointGroups/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1beta1/{+name}", + "response": { + "$ref": "MirroringEndpointGroup" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "list": { + "description": "Lists MirroringEndpointGroups in a given project and location.", + "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/mirroringEndpointGroups", + "httpMethod": "GET", + "id": "networksecurity.projects.locations.mirroringEndpointGroups.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 ListMirroringEndpointGroupsRequest", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1beta1/{+parent}/mirroringEndpointGroups", + "response": { + "$ref": "ListMirroringEndpointGroupsResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "patch": { + "description": "Updates a single MirroringEndpointGroup.", + "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/mirroringEndpointGroups/{mirroringEndpointGroupsId}", + "httpMethod": "PATCH", + "id": "networksecurity.projects.locations.mirroringEndpointGroups.patch", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Immutable. Identifier. The name of the MirroringEndpointGroup.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/mirroringEndpointGroups/[^/]+$", + "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 MirroringEndpointGroup 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" + } + }, + "path": "v1beta1/{+name}", + "request": { + "$ref": "MirroringEndpointGroup" + }, + "response": { + "$ref": "Operation" + }, + "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": "v1beta1/projects/{projectsId}/locations/{locationsId}/operations/{operationsId}:cancel", + "httpMethod": "POST", + "id": "networksecurity.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": "v1beta1/{+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": "v1beta1/projects/{projectsId}/locations/{locationsId}/operations/{operationsId}", + "httpMethod": "DELETE", + "id": "networksecurity.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": "v1beta1/{+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": "v1beta1/projects/{projectsId}/locations/{locationsId}/operations/{operationsId}", + "httpMethod": "GET", + "id": "networksecurity.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": "v1beta1/{+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": "v1beta1/projects/{projectsId}/locations/{locationsId}/operations", + "httpMethod": "GET", + "id": "networksecurity.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": "v1beta1/{+name}/operations", + "response": { + "$ref": "ListOperationsResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + } + } + }, + "serverTlsPolicies": { + "methods": { + "create": { + "description": "Creates a new ServerTlsPolicy in a given project and location.", + "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/serverTlsPolicies", + "httpMethod": "POST", + "id": "networksecurity.projects.locations.serverTlsPolicies.create", + "parameterOrder": [ + "parent" + ], + "parameters": { + "parent": { + "description": "Required. The parent resource of the ServerTlsPolicy. Must be in the format `projects/*/locations/{location}`.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+$", + "required": true, + "type": "string" + }, + "serverTlsPolicyId": { + "description": "Required. Short name of the ServerTlsPolicy resource to be created. This value should be 1-63 characters long, containing only letters, numbers, hyphens, and underscores, and should not start with a number. E.g. \"server_mtls_policy\".", + "location": "query", + "type": "string" + } + }, + "path": "v1beta1/{+parent}/serverTlsPolicies", + "request": { + "$ref": "ServerTlsPolicy" + }, + "response": { + "$ref": "Operation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "delete": { + "description": "Deletes a single ServerTlsPolicy.", + "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/serverTlsPolicies/{serverTlsPoliciesId}", + "httpMethod": "DELETE", + "id": "networksecurity.projects.locations.serverTlsPolicies.delete", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Required. A name of the ServerTlsPolicy to delete. Must be in the format `projects/*/locations/{location}/serverTlsPolicies/*`.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/serverTlsPolicies/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1beta1/{+name}", + "response": { + "$ref": "Operation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "get": { + "description": "Gets details of a single ServerTlsPolicy.", + "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/serverTlsPolicies/{serverTlsPoliciesId}", + "httpMethod": "GET", + "id": "networksecurity.projects.locations.serverTlsPolicies.get", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Required. A name of the ServerTlsPolicy to get. Must be in the format `projects/*/locations/{location}/serverTlsPolicies/*`.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/serverTlsPolicies/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1beta1/{+name}", + "response": { + "$ref": "ServerTlsPolicy" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "getIamPolicy": { + "description": "Gets the access control policy for a resource. Returns an empty policy if the resource exists and does not have a policy set.", + "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/serverTlsPolicies/{serverTlsPoliciesId}:getIamPolicy", + "httpMethod": "GET", + "id": "networksecurity.projects.locations.serverTlsPolicies.getIamPolicy", + "parameterOrder": [ + "resource" + ], + "parameters": { + "options.requestedPolicyVersion": { + "description": "Optional. The maximum policy version that will be used to format the policy. Valid values are 0, 1, and 3. Requests specifying an invalid value will be rejected. Requests for policies with any conditional role bindings must specify version 3. Policies with no conditional role bindings may specify any valid value or leave the field unset. The policy in the response might use the policy version that you specified, or it might use a lower policy version. For example, if you specify version 3, but the policy has no conditional role bindings, the response uses version 1. To learn which resources support conditions in their IAM policies, see the [IAM documentation](https://cloud.google.com/iam/help/conditions/resource-policies).", + "format": "int32", + "location": "query", + "type": "integer" + }, + "resource": { + "description": "REQUIRED: The resource for which the policy is being requested. See [Resource names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/serverTlsPolicies/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1beta1/{+resource}:getIamPolicy", + "response": { + "$ref": "GoogleIamV1Policy" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "list": { + "description": "Lists ServerTlsPolicies in a given project and location.", + "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/serverTlsPolicies", + "httpMethod": "GET", + "id": "networksecurity.projects.locations.serverTlsPolicies.list", + "parameterOrder": [ + "parent" + ], + "parameters": { + "pageSize": { + "description": "Maximum number of ServerTlsPolicies to return per call.", + "format": "int32", + "location": "query", + "type": "integer" + }, + "pageToken": { + "description": "The value returned by the last `ListServerTlsPoliciesResponse` Indicates that this is a continuation of a prior `ListServerTlsPolicies` call, and that the system should return the next page of data.", + "location": "query", + "type": "string" + }, + "parent": { + "description": "Required. The project and location from which the ServerTlsPolicies should be listed, specified in the format `projects/*/locations/{location}`.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1beta1/{+parent}/serverTlsPolicies", + "response": { + "$ref": "ListServerTlsPoliciesResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "patch": { + "description": "Updates the parameters of a single ServerTlsPolicy.", + "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/serverTlsPolicies/{serverTlsPoliciesId}", + "httpMethod": "PATCH", + "id": "networksecurity.projects.locations.serverTlsPolicies.patch", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Required. Name of the ServerTlsPolicy resource. It matches the pattern `projects/*/locations/{location}/serverTlsPolicies/{server_tls_policy}`", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/serverTlsPolicies/[^/]+$", + "required": true, + "type": "string" + }, + "updateMask": { + "description": "Optional. Field mask is used to specify the fields to be overwritten in the ServerTlsPolicy 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" + } + }, + "path": "v1beta1/{+name}", + "request": { + "$ref": "ServerTlsPolicy" + }, + "response": { + "$ref": "Operation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "setIamPolicy": { + "description": "Sets the access control policy on the specified resource. Replaces any existing policy. Can return `NOT_FOUND`, `INVALID_ARGUMENT`, and `PERMISSION_DENIED` errors.", + "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/serverTlsPolicies/{serverTlsPoliciesId}:setIamPolicy", + "httpMethod": "POST", + "id": "networksecurity.projects.locations.serverTlsPolicies.setIamPolicy", + "parameterOrder": [ + "resource" + ], + "parameters": { + "resource": { + "description": "REQUIRED: The resource for which the policy is being specified. See [Resource names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/serverTlsPolicies/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1beta1/{+resource}:setIamPolicy", + "request": { + "$ref": "GoogleIamV1SetIamPolicyRequest" + }, + "response": { + "$ref": "GoogleIamV1Policy" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "testIamPermissions": { + "description": "Returns permissions that a caller has on the specified resource. If the resource does not exist, this will return an empty set of permissions, not a `NOT_FOUND` error. Note: This operation is designed to be used for building permission-aware UIs and command-line tools, not for authorization checking. This operation may \"fail open\" without warning.", + "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/serverTlsPolicies/{serverTlsPoliciesId}:testIamPermissions", + "httpMethod": "POST", + "id": "networksecurity.projects.locations.serverTlsPolicies.testIamPermissions", + "parameterOrder": [ + "resource" + ], + "parameters": { + "resource": { + "description": "REQUIRED: The resource for which the policy detail is being requested. See [Resource names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/serverTlsPolicies/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1beta1/{+resource}:testIamPermissions", + "request": { + "$ref": "GoogleIamV1TestIamPermissionsRequest" + }, + "response": { + "$ref": "GoogleIamV1TestIamPermissionsResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + } + } + }, + "tlsInspectionPolicies": { + "methods": { "create": { "description": "Creates a new TlsInspectionPolicy in a given project and location.", "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/tlsInspectionPolicies", @@ -3431,7 +4159,7 @@ } } }, - "revision": "20240803", + "revision": "20240828", "rootUrl": "https://networksecurity.googleapis.com/", "schemas": { "AddAddressGroupItemsRequest": { @@ -4186,14 +4914,16 @@ "CREATING", "ACTIVE", "DELETING", - "INACTIVE" + "INACTIVE", + "ORPHAN" ], "enumDescriptions": [ "Not set.", "Being created.", "Active and ready for traffic.", "Being deleted.", - "Down or in an error state." + "Down or in an error state.", + "The GCP project that housed the association has been deleted." ], "readOnly": true, "type": "string" @@ -4674,19 +5404,105 @@ }, "type": "object" }, - "ListGatewaySecurityPoliciesResponse": { - "description": "Response returned by the ListGatewaySecurityPolicies method.", - "id": "ListGatewaySecurityPoliciesResponse", + "ListGatewaySecurityPoliciesResponse": { + "description": "Response returned by the ListGatewaySecurityPolicies method.", + "id": "ListGatewaySecurityPoliciesResponse", + "properties": { + "gatewaySecurityPolicies": { + "description": "List of GatewaySecurityPolicies resources.", + "items": { + "$ref": "GatewaySecurityPolicy" + }, + "type": "array" + }, + "nextPageToken": { + "description": "If there might be more results than those appearing in this response, then 'next_page_token' is included. To get the next set of results, call this method again using the value of 'next_page_token' as 'page_token'.", + "type": "string" + }, + "unreachable": { + "description": "Locations that could not be reached.", + "items": { + "type": "string" + }, + "type": "array" + } + }, + "type": "object" + }, + "ListGatewaySecurityPolicyRulesResponse": { + "description": "Response returned by the ListGatewaySecurityPolicyRules method.", + "id": "ListGatewaySecurityPolicyRulesResponse", + "properties": { + "gatewaySecurityPolicyRules": { + "description": "List of GatewaySecurityPolicyRule resources.", + "items": { + "$ref": "GatewaySecurityPolicyRule" + }, + "type": "array" + }, + "nextPageToken": { + "description": "If there might be more results than those appearing in this response, then 'next_page_token' is included. To get the next set of results, call this method again using the value of 'next_page_token' as 'page_token'.", + "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" + }, + "ListMirroringDeploymentGroupsResponse": { + "description": "Message for response to listing MirroringDeploymentGroups", + "id": "ListMirroringDeploymentGroupsResponse", + "properties": { + "mirroringDeploymentGroups": { + "description": "The list of MirroringDeploymentGroup", + "items": { + "$ref": "MirroringDeploymentGroup" + }, + "type": "array" + }, + "nextPageToken": { + "description": "A token identifying a page of results the server should return.", + "type": "string" + } + }, + "type": "object" + }, + "ListMirroringDeploymentsResponse": { + "description": "Message for response to listing MirroringDeployments", + "id": "ListMirroringDeploymentsResponse", "properties": { - "gatewaySecurityPolicies": { - "description": "List of GatewaySecurityPolicies resources.", + "mirroringDeployments": { + "description": "The list of MirroringDeployment", "items": { - "$ref": "GatewaySecurityPolicy" + "$ref": "MirroringDeployment" }, "type": "array" }, "nextPageToken": { - "description": "If there might be more results than those appearing in this response, then 'next_page_token' is included. To get the next set of results, call this method again using the value of 'next_page_token' as 'page_token'.", + "description": "A token identifying a page of results the server should return.", "type": "string" }, "unreachable": { @@ -4699,44 +5515,37 @@ }, "type": "object" }, - "ListGatewaySecurityPolicyRulesResponse": { - "description": "Response returned by the ListGatewaySecurityPolicyRules method.", - "id": "ListGatewaySecurityPolicyRulesResponse", + "ListMirroringEndpointGroupAssociationsResponse": { + "description": "Message for response to listing MirroringEndpointGroupAssociations", + "id": "ListMirroringEndpointGroupAssociationsResponse", "properties": { - "gatewaySecurityPolicyRules": { - "description": "List of GatewaySecurityPolicyRule resources.", + "mirroringEndpointGroupAssociations": { + "description": "The list of MirroringEndpointGroupAssociation", "items": { - "$ref": "GatewaySecurityPolicyRule" + "$ref": "MirroringEndpointGroupAssociation" }, "type": "array" }, "nextPageToken": { - "description": "If there might be more results than those appearing in this response, then 'next_page_token' is included. To get the next set of results, call this method again using the value of 'next_page_token' as 'page_token'.", + "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", + "ListMirroringEndpointGroupsResponse": { + "description": "Message for response to listing MirroringEndpointGroups", + "id": "ListMirroringEndpointGroupsResponse", "properties": { - "locations": { - "description": "A list of locations that matches the specified filter in the request.", + "mirroringEndpointGroups": { + "description": "The list of MirroringEndpointGroup", "items": { - "$ref": "Location" + "$ref": "MirroringEndpointGroup" }, "type": "array" }, "nextPageToken": { - "description": "The standard List next-page token.", + "description": "A token identifying a page of results the server should return.", "type": "string" } }, @@ -4930,6 +5739,309 @@ }, "type": "object" }, + "MirroringDeployment": { + "description": "Message describing MirroringDeployment object", + "id": "MirroringDeployment", + "properties": { + "createTime": { + "description": "Output only. [Output only] Create time stamp", + "format": "google-datetime", + "readOnly": true, + "type": "string" + }, + "forwardingRule": { + "description": "Required. Immutable. The regional load balancer which the mirrored traffic should be forwarded to. Format is: projects/{project}/regions/{region}/forwardingRules/{forwardingRule}", + "type": "string" + }, + "labels": { + "additionalProperties": { + "type": "string" + }, + "description": "Optional. Labels as key value pairs", + "type": "object" + }, + "mirroringDeploymentGroup": { + "description": "Required. Immutable. The Mirroring Deployment Group that this resource is part of. Format is: `projects/{project}/locations/global/mirroringDeploymentGroups/{mirroringDeploymentGroup}`", + "type": "string" + }, + "name": { + "description": "Immutable. Identifier. The name of the MirroringDeployment.", + "type": "string" + }, + "reconciling": { + "description": "Output only. Whether reconciling is in progress, recommended per https://google.aip.dev/128.", + "readOnly": true, + "type": "boolean" + }, + "state": { + "description": "Output only. Current state of the deployment.", + "enum": [ + "STATE_UNSPECIFIED", + "ACTIVE", + "CREATING", + "DELETING", + "OUT_OF_SYNC", + "DELETE_FAILED" + ], + "enumDescriptions": [ + "Not set.", + "Ready.", + "Being created.", + "Being deleted.", + "The underlying data plane is out of sync with the deployment. The deployment is not expected to be usable. This state can result in undefined behavior.", + "An attempt to delete the deployment has failed. This is a terminal state and the deployment is not expected to be usable as some of its resources have been deleted. The only permitted operation is to retry deleting the deployment." + ], + "readOnly": true, + "type": "string" + }, + "updateTime": { + "description": "Output only. [Output only] Update time stamp", + "format": "google-datetime", + "readOnly": true, + "type": "string" + } + }, + "type": "object" + }, + "MirroringDeploymentGroup": { + "description": "Message describing MirroringDeploymentGroup object", + "id": "MirroringDeploymentGroup", + "properties": { + "connectedEndpointGroups": { + "description": "Output only. The list of Mirroring Endpoint Groups that are connected to this resource.", + "items": { + "$ref": "MirroringDeploymentGroupConnectedEndpointGroup" + }, + "readOnly": true, + "type": "array" + }, + "createTime": { + "description": "Output only. [Output only] Create time stamp", + "format": "google-datetime", + "readOnly": true, + "type": "string" + }, + "labels": { + "additionalProperties": { + "type": "string" + }, + "description": "Optional. Labels as key value pairs", + "type": "object" + }, + "name": { + "description": "Immutable. Identifier. Then name of the MirroringDeploymentGroup.", + "type": "string" + }, + "network": { + "description": "Required. Immutable. The network that is being used for the deployment. Format is: projects/{project}/global/networks/{network}.", + "type": "string" + }, + "reconciling": { + "description": "Output only. Whether reconciling is in progress, recommended per https://google.aip.dev/128.", + "readOnly": true, + "type": "boolean" + }, + "state": { + "description": "Output only. Current state of the deployment group.", + "enum": [ + "STATE_UNSPECIFIED", + "ACTIVE", + "CREATING", + "DELETING" + ], + "enumDescriptions": [ + "Not set.", + "Ready.", + "Being created.", + "Being deleted." + ], + "readOnly": true, + "type": "string" + }, + "updateTime": { + "description": "Output only. [Output only] Update time stamp", + "format": "google-datetime", + "readOnly": true, + "type": "string" + } + }, + "type": "object" + }, + "MirroringDeploymentGroupConnectedEndpointGroup": { + "description": "An endpoint group connected to this deployment group.", + "id": "MirroringDeploymentGroupConnectedEndpointGroup", + "properties": { + "name": { + "description": "Output only. A connected mirroring endpoint group.", + "readOnly": true, + "type": "string" + } + }, + "type": "object" + }, + "MirroringEndpointGroup": { + "description": "Message describing MirroringEndpointGroup object", + "id": "MirroringEndpointGroup", + "properties": { + "createTime": { + "description": "Output only. [Output only] Create time stamp", + "format": "google-datetime", + "readOnly": true, + "type": "string" + }, + "labels": { + "additionalProperties": { + "type": "string" + }, + "description": "Optional. Labels as key value pairs", + "type": "object" + }, + "mirroringDeploymentGroup": { + "description": "Required. Immutable. The Mirroring Deployment Group that this resource is connected to. Format is: `projects/{project}/locations/global/mirroringDeploymentGroups/{mirroringDeploymentGroup}`", + "type": "string" + }, + "name": { + "description": "Immutable. Identifier. The name of the MirroringEndpointGroup.", + "type": "string" + }, + "reconciling": { + "description": "Output only. Whether reconciling is in progress, recommended per https://google.aip.dev/128.", + "readOnly": true, + "type": "boolean" + }, + "state": { + "description": "Output only. Current state of the endpoint group.", + "enum": [ + "STATE_UNSPECIFIED", + "ACTIVE", + "CLOSED", + "CREATING", + "DELETING", + "OUT_OF_SYNC", + "DELETE_FAILED" + ], + "enumDescriptions": [ + "Not set.", + "Ready.", + "The deployment group has been deleted and mirroring is disabled.", + "Being created.", + "Being deleted.", + "The underlying data plane is out of sync with the endpoint group. Some associations might not be usable.", + "An attempt to delete the endpoint group has failed. This is a terminal state and the endpoint group is not expected to be usable as some of its resources have been deleted. The only permitted operation is to retry deleting the endpoint group." + ], + "readOnly": true, + "type": "string" + }, + "updateTime": { + "description": "Output only. [Output only] Update time stamp", + "format": "google-datetime", + "readOnly": true, + "type": "string" + } + }, + "type": "object" + }, + "MirroringEndpointGroupAssociation": { + "description": "Message describing MirroringEndpointGroupAssociation object", + "id": "MirroringEndpointGroupAssociation", + "properties": { + "createTime": { + "description": "Output only. [Output only] Create time stamp", + "format": "google-datetime", + "readOnly": true, + "type": "string" + }, + "labels": { + "additionalProperties": { + "type": "string" + }, + "description": "Optional. Labels as key value pairs", + "type": "object" + }, + "locationsDetails": { + "description": "Output only. The list of locations that this association is in and its details.", + "items": { + "$ref": "MirroringEndpointGroupAssociationLocationDetails" + }, + "readOnly": true, + "type": "array" + }, + "mirroringEndpointGroup": { + "description": "Required. Immutable. The Mirroring Endpoint Group that this resource is connected to. Format is: `projects/{project}/locations/global/mirroringEndpointGroups/{mirroringEndpointGroup}`", + "type": "string" + }, + "name": { + "description": "Immutable. Identifier. The name of the MirroringEndpointGroupAssociation.", + "type": "string" + }, + "network": { + "description": "Required. Immutable. The VPC network associated. Format: projects/{project}/global/networks/{network}.", + "type": "string" + }, + "reconciling": { + "description": "Output only. Whether reconciling is in progress, recommended per https://google.aip.dev/128.", + "readOnly": true, + "type": "boolean" + }, + "state": { + "description": "Output only. Current state of the endpoint group association.", + "enum": [ + "STATE_UNSPECIFIED", + "ACTIVE", + "CREATING", + "DELETING", + "CLOSED", + "OUT_OF_SYNC", + "DELETE_FAILED" + ], + "enumDescriptions": [ + "Not set.", + "Ready.", + "Being created.", + "Being deleted.", + "Mirroring is disabled due to an operation on another resource.", + "The underlying data plane is out of sync with the association. The association is not expected to be usable. This state can result in undefined behavior. See the `locations_details` field for more details.", + "An attempt to delete the association has failed. This is a terminal state and the association is not expected to be usable as some of its resources have been deleted. The only permitted operation is to retry deleting the association." + ], + "readOnly": true, + "type": "string" + }, + "updateTime": { + "description": "Output only. [Output only] Update time stamp", + "format": "google-datetime", + "readOnly": true, + "type": "string" + } + }, + "type": "object" + }, + "MirroringEndpointGroupAssociationLocationDetails": { + "description": "Details about the association status in a specific cloud location.", + "id": "MirroringEndpointGroupAssociationLocationDetails", + "properties": { + "location": { + "description": "Output only. The cloud location.", + "readOnly": true, + "type": "string" + }, + "state": { + "description": "Output only. The association state in this location.", + "enum": [ + "STATE_UNSPECIFIED", + "ACTIVE", + "OUT_OF_SYNC" + ], + "enumDescriptions": [ + "Not set.", + "Ready.", + "The data plane is out of sync with the association in this location." + ], + "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", diff --git a/networksecurity/v1beta1/networksecurity-gen.go b/networksecurity/v1beta1/networksecurity-gen.go index ca8dab5fbfe..1d18176b2fa 100644 --- a/networksecurity/v1beta1/networksecurity-gen.go +++ b/networksecurity/v1beta1/networksecurity-gen.go @@ -258,6 +258,10 @@ func NewProjectsLocationsService(s *Service) *ProjectsLocationsService { rs.ClientTlsPolicies = NewProjectsLocationsClientTlsPoliciesService(s) rs.FirewallEndpointAssociations = NewProjectsLocationsFirewallEndpointAssociationsService(s) rs.GatewaySecurityPolicies = NewProjectsLocationsGatewaySecurityPoliciesService(s) + rs.MirroringDeploymentGroups = NewProjectsLocationsMirroringDeploymentGroupsService(s) + rs.MirroringDeployments = NewProjectsLocationsMirroringDeploymentsService(s) + rs.MirroringEndpointGroupAssociations = NewProjectsLocationsMirroringEndpointGroupAssociationsService(s) + rs.MirroringEndpointGroups = NewProjectsLocationsMirroringEndpointGroupsService(s) rs.Operations = NewProjectsLocationsOperationsService(s) rs.ServerTlsPolicies = NewProjectsLocationsServerTlsPoliciesService(s) rs.TlsInspectionPolicies = NewProjectsLocationsTlsInspectionPoliciesService(s) @@ -280,6 +284,14 @@ type ProjectsLocationsService struct { GatewaySecurityPolicies *ProjectsLocationsGatewaySecurityPoliciesService + MirroringDeploymentGroups *ProjectsLocationsMirroringDeploymentGroupsService + + MirroringDeployments *ProjectsLocationsMirroringDeploymentsService + + MirroringEndpointGroupAssociations *ProjectsLocationsMirroringEndpointGroupAssociationsService + + MirroringEndpointGroups *ProjectsLocationsMirroringEndpointGroupsService + Operations *ProjectsLocationsOperationsService ServerTlsPolicies *ProjectsLocationsServerTlsPoliciesService @@ -355,6 +367,42 @@ type ProjectsLocationsGatewaySecurityPoliciesRulesService struct { s *Service } +func NewProjectsLocationsMirroringDeploymentGroupsService(s *Service) *ProjectsLocationsMirroringDeploymentGroupsService { + rs := &ProjectsLocationsMirroringDeploymentGroupsService{s: s} + return rs +} + +type ProjectsLocationsMirroringDeploymentGroupsService struct { + s *Service +} + +func NewProjectsLocationsMirroringDeploymentsService(s *Service) *ProjectsLocationsMirroringDeploymentsService { + rs := &ProjectsLocationsMirroringDeploymentsService{s: s} + return rs +} + +type ProjectsLocationsMirroringDeploymentsService struct { + s *Service +} + +func NewProjectsLocationsMirroringEndpointGroupAssociationsService(s *Service) *ProjectsLocationsMirroringEndpointGroupAssociationsService { + rs := &ProjectsLocationsMirroringEndpointGroupAssociationsService{s: s} + return rs +} + +type ProjectsLocationsMirroringEndpointGroupAssociationsService struct { + s *Service +} + +func NewProjectsLocationsMirroringEndpointGroupsService(s *Service) *ProjectsLocationsMirroringEndpointGroupsService { + rs := &ProjectsLocationsMirroringEndpointGroupsService{s: s} + return rs +} + +type ProjectsLocationsMirroringEndpointGroupsService struct { + s *Service +} + func NewProjectsLocationsOperationsService(s *Service) *ProjectsLocationsOperationsService { rs := &ProjectsLocationsOperationsService{s: s} return rs @@ -1316,6 +1364,7 @@ type FirewallEndpointAssociation struct { // "ACTIVE" - Active and ready for traffic. // "DELETING" - Being deleted. // "INACTIVE" - Down or in an error state. + // "ORPHAN" - The GCP project that housed the association has been deleted. State string `json:"state,omitempty"` // TlsInspectionPolicy: Optional. The URL of the TlsInspectionPolicy that is // being associated. @@ -2243,6 +2292,127 @@ func (s ListLocationsResponse) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// ListMirroringDeploymentGroupsResponse: Message for response to listing +// MirroringDeploymentGroups +type ListMirroringDeploymentGroupsResponse struct { + // MirroringDeploymentGroups: The list of MirroringDeploymentGroup + MirroringDeploymentGroups []*MirroringDeploymentGroup `json:"mirroringDeploymentGroups,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. "MirroringDeploymentGroups") + // 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. "MirroringDeploymentGroups") 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 ListMirroringDeploymentGroupsResponse) MarshalJSON() ([]byte, error) { + type NoMethod ListMirroringDeploymentGroupsResponse + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// ListMirroringDeploymentsResponse: Message for response to listing +// MirroringDeployments +type ListMirroringDeploymentsResponse struct { + // MirroringDeployments: The list of MirroringDeployment + MirroringDeployments []*MirroringDeployment `json:"mirroringDeployments,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. "MirroringDeployments") 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. "MirroringDeployments") 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 ListMirroringDeploymentsResponse) MarshalJSON() ([]byte, error) { + type NoMethod ListMirroringDeploymentsResponse + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// ListMirroringEndpointGroupAssociationsResponse: Message for response to +// listing MirroringEndpointGroupAssociations +type ListMirroringEndpointGroupAssociationsResponse struct { + // MirroringEndpointGroupAssociations: The list of + // MirroringEndpointGroupAssociation + MirroringEndpointGroupAssociations []*MirroringEndpointGroupAssociation `json:"mirroringEndpointGroupAssociations,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. + // "MirroringEndpointGroupAssociations") 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. + // "MirroringEndpointGroupAssociations") 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 ListMirroringEndpointGroupAssociationsResponse) MarshalJSON() ([]byte, error) { + type NoMethod ListMirroringEndpointGroupAssociationsResponse + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// ListMirroringEndpointGroupsResponse: Message for response to listing +// MirroringEndpointGroups +type ListMirroringEndpointGroupsResponse struct { + // MirroringEndpointGroups: The list of MirroringEndpointGroup + MirroringEndpointGroups []*MirroringEndpointGroup `json:"mirroringEndpointGroups,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. "MirroringEndpointGroups") 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. "MirroringEndpointGroups") 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 ListMirroringEndpointGroupsResponse) MarshalJSON() ([]byte, error) { + type NoMethod ListMirroringEndpointGroupsResponse + 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. @@ -2517,152 +2687,431 @@ func (s MTLSPolicy) MarshalJSON() ([]byte, error) { 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}`. +// MirroringDeployment: Message describing MirroringDeployment object +type MirroringDeployment struct { + // CreateTime: Output only. [Output only] Create time stamp + CreateTime string `json:"createTime,omitempty"` + // ForwardingRule: Required. Immutable. The regional load balancer which the + // mirrored traffic should be forwarded to. Format is: + // projects/{project}/regions/{region}/forwardingRules/{forwardingRule} + ForwardingRule string `json:"forwardingRule,omitempty"` + // Labels: Optional. Labels as key value pairs + Labels map[string]string `json:"labels,omitempty"` + // MirroringDeploymentGroup: Required. Immutable. The Mirroring Deployment + // Group that this resource is part of. Format is: + // `projects/{project}/locations/global/mirroringDeploymentGroups/{mirroringDepl + // oymentGroup}` + MirroringDeploymentGroup string `json:"mirroringDeploymentGroup,omitempty"` + // Name: Immutable. Identifier. The name of the MirroringDeployment. 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"` + // Reconciling: Output only. Whether reconciling is in progress, recommended + // per https://google.aip.dev/128. + Reconciling bool `json:"reconciling,omitempty"` + // State: Output only. Current state of the deployment. + // + // Possible values: + // "STATE_UNSPECIFIED" - Not set. + // "ACTIVE" - Ready. + // "CREATING" - Being created. + // "DELETING" - Being deleted. + // "OUT_OF_SYNC" - The underlying data plane is out of sync with the + // deployment. The deployment is not expected to be usable. This state can + // result in undefined behavior. + // "DELETE_FAILED" - An attempt to delete the deployment has failed. This is + // a terminal state and the deployment is not expected to be usable as some of + // its resources have been deleted. The only permitted operation is to retry + // deleting the deployment. + State string `json:"state,omitempty"` + // UpdateTime: Output only. [Output only] Update time stamp + 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. "Done") to unconditionally - // include in API requests. By default, fields with empty or default values are - // omitted from API requests. See + // ForceSendFields is a list of field names (e.g. "CreateTime") 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 + // NullFields is a list of field names (e.g. "CreateTime") 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 +func (s MirroringDeployment) MarshalJSON() ([]byte, error) { + type NoMethod MirroringDeployment 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. +// MirroringDeploymentGroup: Message describing MirroringDeploymentGroup object +type MirroringDeploymentGroup struct { + // ConnectedEndpointGroups: Output only. The list of Mirroring Endpoint Groups + // that are connected to this resource. + ConnectedEndpointGroups []*MirroringDeploymentGroupConnectedEndpointGroup `json:"connectedEndpointGroups,omitempty"` + // CreateTime: Output only. [Output only] Create time stamp 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 successfully - // been cancelled 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 + // Labels: Optional. Labels as key value pairs + Labels map[string]string `json:"labels,omitempty"` + // Name: Immutable. Identifier. Then name of the MirroringDeploymentGroup. + Name string `json:"name,omitempty"` + // Network: Required. Immutable. The network that is being used for the + // deployment. Format is: projects/{project}/global/networks/{network}. + Network string `json:"network,omitempty"` + // Reconciling: Output only. Whether reconciling is in progress, recommended + // per https://google.aip.dev/128. + Reconciling bool `json:"reconciling,omitempty"` + // State: Output only. Current state of the deployment group. + // + // Possible values: + // "STATE_UNSPECIFIED" - Not set. + // "ACTIVE" - Ready. + // "CREATING" - Being created. + // "DELETING" - Being deleted. + State string `json:"state,omitempty"` + // UpdateTime: Output only. [Output only] Update time stamp + 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. "ConnectedEndpointGroups") 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 + // NullFields is a list of field names (e.g. "ConnectedEndpointGroups") 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 +func (s MirroringDeploymentGroup) MarshalJSON() ([]byte, error) { + type NoMethod MirroringDeploymentGroup return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// RemoveAddressGroupItemsRequest: Request used by the RemoveAddressGroupItems -// method. -type RemoveAddressGroupItemsRequest struct { - // Items: Required. List of items to remove. - Items []string `json:"items,omitempty"` - // RequestId: 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). - RequestId string `json:"requestId,omitempty"` - // ForceSendFields is a list of field names (e.g. "Items") to unconditionally +// MirroringDeploymentGroupConnectedEndpointGroup: An endpoint group connected +// to this deployment group. +type MirroringDeploymentGroupConnectedEndpointGroup struct { + // Name: Output only. A connected mirroring endpoint group. + Name string `json:"name,omitempty"` + // ForceSendFields is a list of field names (e.g. "Name") 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. "Items") to include in API - // requests with the JSON null value. By default, fields with empty values are - // omitted from API requests. See + // NullFields is a list of field names (e.g. "Name") 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 RemoveAddressGroupItemsRequest) MarshalJSON() ([]byte, error) { - type NoMethod RemoveAddressGroupItemsRequest +func (s MirroringDeploymentGroupConnectedEndpointGroup) MarshalJSON() ([]byte, error) { + type NoMethod MirroringDeploymentGroupConnectedEndpointGroup return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// Rule: Specification of rules. -type Rule struct { - // Destinations: Optional. List of attributes for the traffic destination. All - // of the destinations must match. A destination is a match if a request - // matches all the specified hosts, ports, methods and headers. If not set, the - // action specified in the 'action' field will be applied without any rule - // checks for the destination. - Destinations []*Destination `json:"destinations,omitempty"` - // Sources: Optional. List of attributes for the traffic source. All of the - // sources must match. A source is a match if both principals and ip_blocks - // match. If not set, the action specified in the 'action' field will be - // applied without any rule checks for the source. - Sources []*Source `json:"sources,omitempty"` - // ForceSendFields is a list of field names (e.g. "Destinations") 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. "Destinations") 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:"-"` -} - +// MirroringEndpointGroup: Message describing MirroringEndpointGroup object +type MirroringEndpointGroup struct { + // CreateTime: Output only. [Output only] Create time stamp + CreateTime string `json:"createTime,omitempty"` + // Labels: Optional. Labels as key value pairs + Labels map[string]string `json:"labels,omitempty"` + // MirroringDeploymentGroup: Required. Immutable. The Mirroring Deployment + // Group that this resource is connected to. Format is: + // `projects/{project}/locations/global/mirroringDeploymentGroups/{mirroringDepl + // oymentGroup}` + MirroringDeploymentGroup string `json:"mirroringDeploymentGroup,omitempty"` + // Name: Immutable. Identifier. The name of the MirroringEndpointGroup. + Name string `json:"name,omitempty"` + // Reconciling: Output only. Whether reconciling is in progress, recommended + // per https://google.aip.dev/128. + Reconciling bool `json:"reconciling,omitempty"` + // State: Output only. Current state of the endpoint group. + // + // Possible values: + // "STATE_UNSPECIFIED" - Not set. + // "ACTIVE" - Ready. + // "CLOSED" - The deployment group has been deleted and mirroring is + // disabled. + // "CREATING" - Being created. + // "DELETING" - Being deleted. + // "OUT_OF_SYNC" - The underlying data plane is out of sync with the endpoint + // group. Some associations might not be usable. + // "DELETE_FAILED" - An attempt to delete the endpoint group has failed. This + // is a terminal state and the endpoint group is not expected to be usable as + // some of its resources have been deleted. The only permitted operation is to + // retry deleting the endpoint group. + State string `json:"state,omitempty"` + // UpdateTime: Output only. [Output only] Update time stamp + 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. "CreateTime") 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. "CreateTime") 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 MirroringEndpointGroup) MarshalJSON() ([]byte, error) { + type NoMethod MirroringEndpointGroup + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// MirroringEndpointGroupAssociation: Message describing +// MirroringEndpointGroupAssociation object +type MirroringEndpointGroupAssociation struct { + // CreateTime: Output only. [Output only] Create time stamp + CreateTime string `json:"createTime,omitempty"` + // Labels: Optional. Labels as key value pairs + Labels map[string]string `json:"labels,omitempty"` + // LocationsDetails: Output only. The list of locations that this association + // is in and its details. + LocationsDetails []*MirroringEndpointGroupAssociationLocationDetails `json:"locationsDetails,omitempty"` + // MirroringEndpointGroup: Required. Immutable. The Mirroring Endpoint Group + // that this resource is connected to. Format is: + // `projects/{project}/locations/global/mirroringEndpointGroups/{mirroringEndpoi + // ntGroup}` + MirroringEndpointGroup string `json:"mirroringEndpointGroup,omitempty"` + // Name: Immutable. Identifier. The name of the + // MirroringEndpointGroupAssociation. + Name string `json:"name,omitempty"` + // Network: Required. Immutable. The VPC network associated. Format: + // projects/{project}/global/networks/{network}. + Network string `json:"network,omitempty"` + // Reconciling: Output only. Whether reconciling is in progress, recommended + // per https://google.aip.dev/128. + Reconciling bool `json:"reconciling,omitempty"` + // State: Output only. Current state of the endpoint group association. + // + // Possible values: + // "STATE_UNSPECIFIED" - Not set. + // "ACTIVE" - Ready. + // "CREATING" - Being created. + // "DELETING" - Being deleted. + // "CLOSED" - Mirroring is disabled due to an operation on another resource. + // "OUT_OF_SYNC" - The underlying data plane is out of sync with the + // association. The association is not expected to be usable. This state can + // result in undefined behavior. See the `locations_details` field for more + // details. + // "DELETE_FAILED" - An attempt to delete the association has failed. This is + // a terminal state and the association is not expected to be usable as some of + // its resources have been deleted. The only permitted operation is to retry + // deleting the association. + State string `json:"state,omitempty"` + // UpdateTime: Output only. [Output only] Update time stamp + 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. "CreateTime") 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. "CreateTime") 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 MirroringEndpointGroupAssociation) MarshalJSON() ([]byte, error) { + type NoMethod MirroringEndpointGroupAssociation + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// MirroringEndpointGroupAssociationLocationDetails: Details about the +// association status in a specific cloud location. +type MirroringEndpointGroupAssociationLocationDetails struct { + // Location: Output only. The cloud location. + Location string `json:"location,omitempty"` + // State: Output only. The association state in this location. + // + // Possible values: + // "STATE_UNSPECIFIED" - Not set. + // "ACTIVE" - Ready. + // "OUT_OF_SYNC" - The data plane is out of sync with the association in this + // location. + State string `json:"state,omitempty"` + // ForceSendFields is a list of field names (e.g. "Location") 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. "Location") 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 MirroringEndpointGroupAssociationLocationDetails) MarshalJSON() ([]byte, error) { + type NoMethod MirroringEndpointGroupAssociationLocationDetails + 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 successfully + // been cancelled 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) +} + +// RemoveAddressGroupItemsRequest: Request used by the RemoveAddressGroupItems +// method. +type RemoveAddressGroupItemsRequest struct { + // Items: Required. List of items to remove. + Items []string `json:"items,omitempty"` + // RequestId: 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). + RequestId string `json:"requestId,omitempty"` + // ForceSendFields is a list of field names (e.g. "Items") 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. "Items") 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 RemoveAddressGroupItemsRequest) MarshalJSON() ([]byte, error) { + type NoMethod RemoveAddressGroupItemsRequest + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// Rule: Specification of rules. +type Rule struct { + // Destinations: Optional. List of attributes for the traffic destination. All + // of the destinations must match. A destination is a match if a request + // matches all the specified hosts, ports, methods and headers. If not set, the + // action specified in the 'action' field will be applied without any rule + // checks for the destination. + Destinations []*Destination `json:"destinations,omitempty"` + // Sources: Optional. List of attributes for the traffic source. All of the + // sources must match. A source is a match if both principals and ip_blocks + // match. If not set, the action specified in the 'action' field will be + // applied without any rule checks for the source. + Sources []*Source `json:"sources,omitempty"` + // ForceSendFields is a list of field names (e.g. "Destinations") 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. "Destinations") 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 Rule) MarshalJSON() ([]byte, error) { type NoMethod Rule return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) @@ -12825,6 +13274,2532 @@ func (c *ProjectsLocationsGatewaySecurityPoliciesRulesPatchCall) Do(opts ...goog return ret, nil } +type ProjectsLocationsMirroringDeploymentGroupsCreateCall struct { + s *Service + parent string + mirroringdeploymentgroup *MirroringDeploymentGroup + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Create: Creates a new MirroringDeploymentGroup in a given project and +// location. +// +// - parent: Value for parent. +func (r *ProjectsLocationsMirroringDeploymentGroupsService) Create(parent string, mirroringdeploymentgroup *MirroringDeploymentGroup) *ProjectsLocationsMirroringDeploymentGroupsCreateCall { + c := &ProjectsLocationsMirroringDeploymentGroupsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + c.mirroringdeploymentgroup = mirroringdeploymentgroup + return c +} + +// MirroringDeploymentGroupId sets the optional parameter +// "mirroringDeploymentGroupId": Required. Id of the requesting object If +// auto-generating Id server-side, remove this field and +// mirroring_deployment_group_id from the method_signature of Create RPC +func (c *ProjectsLocationsMirroringDeploymentGroupsCreateCall) MirroringDeploymentGroupId(mirroringDeploymentGroupId string) *ProjectsLocationsMirroringDeploymentGroupsCreateCall { + c.urlParams_.Set("mirroringDeploymentGroupId", mirroringDeploymentGroupId) + 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 *ProjectsLocationsMirroringDeploymentGroupsCreateCall) RequestId(requestId string) *ProjectsLocationsMirroringDeploymentGroupsCreateCall { + c.urlParams_.Set("requestId", requestId) + 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 *ProjectsLocationsMirroringDeploymentGroupsCreateCall) Fields(s ...googleapi.Field) *ProjectsLocationsMirroringDeploymentGroupsCreateCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsMirroringDeploymentGroupsCreateCall) Context(ctx context.Context) *ProjectsLocationsMirroringDeploymentGroupsCreateCall { + 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 *ProjectsLocationsMirroringDeploymentGroupsCreateCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsMirroringDeploymentGroupsCreateCall) 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.mirroringdeploymentgroup) + if err != nil { + return nil, err + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+parent}/mirroringDeploymentGroups") + 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 "networksecurity.projects.locations.mirroringDeploymentGroups.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 *ProjectsLocationsMirroringDeploymentGroupsCreateCall) 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 ProjectsLocationsMirroringDeploymentGroupsDeleteCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Delete: Deletes a single MirroringDeploymentGroup. +// +// - name: Name of the resource. +func (r *ProjectsLocationsMirroringDeploymentGroupsService) Delete(name string) *ProjectsLocationsMirroringDeploymentGroupsDeleteCall { + c := &ProjectsLocationsMirroringDeploymentGroupsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + 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 *ProjectsLocationsMirroringDeploymentGroupsDeleteCall) RequestId(requestId string) *ProjectsLocationsMirroringDeploymentGroupsDeleteCall { + c.urlParams_.Set("requestId", requestId) + 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 *ProjectsLocationsMirroringDeploymentGroupsDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsMirroringDeploymentGroupsDeleteCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsMirroringDeploymentGroupsDeleteCall) Context(ctx context.Context) *ProjectsLocationsMirroringDeploymentGroupsDeleteCall { + 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 *ProjectsLocationsMirroringDeploymentGroupsDeleteCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsMirroringDeploymentGroupsDeleteCall) 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, "v1beta1/{+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 "networksecurity.projects.locations.mirroringDeploymentGroups.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 *ProjectsLocationsMirroringDeploymentGroupsDeleteCall) 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 ProjectsLocationsMirroringDeploymentGroupsGetCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// Get: Gets details of a single MirroringDeploymentGroup. +// +// - name: Name of the resource. +func (r *ProjectsLocationsMirroringDeploymentGroupsService) Get(name string) *ProjectsLocationsMirroringDeploymentGroupsGetCall { + c := &ProjectsLocationsMirroringDeploymentGroupsGetCall{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 *ProjectsLocationsMirroringDeploymentGroupsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsMirroringDeploymentGroupsGetCall { + 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 *ProjectsLocationsMirroringDeploymentGroupsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsMirroringDeploymentGroupsGetCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsMirroringDeploymentGroupsGetCall) Context(ctx context.Context) *ProjectsLocationsMirroringDeploymentGroupsGetCall { + 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 *ProjectsLocationsMirroringDeploymentGroupsGetCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsMirroringDeploymentGroupsGetCall) 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, "v1beta1/{+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 "networksecurity.projects.locations.mirroringDeploymentGroups.get" call. +// Any non-2xx status code is an error. Response headers are in either +// *MirroringDeploymentGroup.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 *ProjectsLocationsMirroringDeploymentGroupsGetCall) Do(opts ...googleapi.CallOption) (*MirroringDeploymentGroup, 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 := &MirroringDeploymentGroup{ + 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 ProjectsLocationsMirroringDeploymentGroupsListCall struct { + s *Service + parent string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// List: Lists MirroringDeploymentGroups in a given project and location. +// +// - parent: Parent value for ListMirroringDeploymentGroupsRequest. +func (r *ProjectsLocationsMirroringDeploymentGroupsService) List(parent string) *ProjectsLocationsMirroringDeploymentGroupsListCall { + c := &ProjectsLocationsMirroringDeploymentGroupsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + return c +} + +// Filter sets the optional parameter "filter": Filtering results +func (c *ProjectsLocationsMirroringDeploymentGroupsListCall) Filter(filter string) *ProjectsLocationsMirroringDeploymentGroupsListCall { + c.urlParams_.Set("filter", filter) + return c +} + +// OrderBy sets the optional parameter "orderBy": Hint for how to order the +// results +func (c *ProjectsLocationsMirroringDeploymentGroupsListCall) OrderBy(orderBy string) *ProjectsLocationsMirroringDeploymentGroupsListCall { + 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 *ProjectsLocationsMirroringDeploymentGroupsListCall) PageSize(pageSize int64) *ProjectsLocationsMirroringDeploymentGroupsListCall { + 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 *ProjectsLocationsMirroringDeploymentGroupsListCall) PageToken(pageToken string) *ProjectsLocationsMirroringDeploymentGroupsListCall { + 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 *ProjectsLocationsMirroringDeploymentGroupsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsMirroringDeploymentGroupsListCall { + 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 *ProjectsLocationsMirroringDeploymentGroupsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsMirroringDeploymentGroupsListCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsMirroringDeploymentGroupsListCall) Context(ctx context.Context) *ProjectsLocationsMirroringDeploymentGroupsListCall { + 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 *ProjectsLocationsMirroringDeploymentGroupsListCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsMirroringDeploymentGroupsListCall) 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, "v1beta1/{+parent}/mirroringDeploymentGroups") + 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 "networksecurity.projects.locations.mirroringDeploymentGroups.list" call. +// Any non-2xx status code is an error. Response headers are in either +// *ListMirroringDeploymentGroupsResponse.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 *ProjectsLocationsMirroringDeploymentGroupsListCall) Do(opts ...googleapi.CallOption) (*ListMirroringDeploymentGroupsResponse, 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 := &ListMirroringDeploymentGroupsResponse{ + 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 *ProjectsLocationsMirroringDeploymentGroupsListCall) Pages(ctx context.Context, f func(*ListMirroringDeploymentGroupsResponse) 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 ProjectsLocationsMirroringDeploymentGroupsPatchCall struct { + s *Service + name string + mirroringdeploymentgroup *MirroringDeploymentGroup + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Patch: Updates a single MirroringDeploymentGroup. +// +// - name: Immutable. Identifier. Then name of the MirroringDeploymentGroup. +func (r *ProjectsLocationsMirroringDeploymentGroupsService) Patch(name string, mirroringdeploymentgroup *MirroringDeploymentGroup) *ProjectsLocationsMirroringDeploymentGroupsPatchCall { + c := &ProjectsLocationsMirroringDeploymentGroupsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + c.mirroringdeploymentgroup = mirroringdeploymentgroup + 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 *ProjectsLocationsMirroringDeploymentGroupsPatchCall) RequestId(requestId string) *ProjectsLocationsMirroringDeploymentGroupsPatchCall { + 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 MirroringDeploymentGroup +// 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 *ProjectsLocationsMirroringDeploymentGroupsPatchCall) UpdateMask(updateMask string) *ProjectsLocationsMirroringDeploymentGroupsPatchCall { + c.urlParams_.Set("updateMask", updateMask) + 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 *ProjectsLocationsMirroringDeploymentGroupsPatchCall) Fields(s ...googleapi.Field) *ProjectsLocationsMirroringDeploymentGroupsPatchCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsMirroringDeploymentGroupsPatchCall) Context(ctx context.Context) *ProjectsLocationsMirroringDeploymentGroupsPatchCall { + 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 *ProjectsLocationsMirroringDeploymentGroupsPatchCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsMirroringDeploymentGroupsPatchCall) 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.mirroringdeploymentgroup) + if err != nil { + return nil, err + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+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 "networksecurity.projects.locations.mirroringDeploymentGroups.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 *ProjectsLocationsMirroringDeploymentGroupsPatchCall) 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 ProjectsLocationsMirroringDeploymentsCreateCall struct { + s *Service + parent string + mirroringdeployment *MirroringDeployment + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Create: Creates a new MirroringDeployment in a given project and location. +// +// - parent: Value for parent. +func (r *ProjectsLocationsMirroringDeploymentsService) Create(parent string, mirroringdeployment *MirroringDeployment) *ProjectsLocationsMirroringDeploymentsCreateCall { + c := &ProjectsLocationsMirroringDeploymentsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + c.mirroringdeployment = mirroringdeployment + return c +} + +// MirroringDeploymentId sets the optional parameter "mirroringDeploymentId": +// Required. Id of the requesting object If auto-generating Id server-side, +// remove this field and mirroring_deployment_id from the method_signature of +// Create RPC +func (c *ProjectsLocationsMirroringDeploymentsCreateCall) MirroringDeploymentId(mirroringDeploymentId string) *ProjectsLocationsMirroringDeploymentsCreateCall { + c.urlParams_.Set("mirroringDeploymentId", mirroringDeploymentId) + 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 *ProjectsLocationsMirroringDeploymentsCreateCall) RequestId(requestId string) *ProjectsLocationsMirroringDeploymentsCreateCall { + c.urlParams_.Set("requestId", requestId) + 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 *ProjectsLocationsMirroringDeploymentsCreateCall) Fields(s ...googleapi.Field) *ProjectsLocationsMirroringDeploymentsCreateCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsMirroringDeploymentsCreateCall) Context(ctx context.Context) *ProjectsLocationsMirroringDeploymentsCreateCall { + 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 *ProjectsLocationsMirroringDeploymentsCreateCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsMirroringDeploymentsCreateCall) 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.mirroringdeployment) + if err != nil { + return nil, err + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+parent}/mirroringDeployments") + 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 "networksecurity.projects.locations.mirroringDeployments.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 *ProjectsLocationsMirroringDeploymentsCreateCall) 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 ProjectsLocationsMirroringDeploymentsDeleteCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Delete: Deletes a single MirroringDeployment. +// +// - name: Name of the resource. +func (r *ProjectsLocationsMirroringDeploymentsService) Delete(name string) *ProjectsLocationsMirroringDeploymentsDeleteCall { + c := &ProjectsLocationsMirroringDeploymentsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + 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 *ProjectsLocationsMirroringDeploymentsDeleteCall) RequestId(requestId string) *ProjectsLocationsMirroringDeploymentsDeleteCall { + c.urlParams_.Set("requestId", requestId) + 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 *ProjectsLocationsMirroringDeploymentsDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsMirroringDeploymentsDeleteCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsMirroringDeploymentsDeleteCall) Context(ctx context.Context) *ProjectsLocationsMirroringDeploymentsDeleteCall { + 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 *ProjectsLocationsMirroringDeploymentsDeleteCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsMirroringDeploymentsDeleteCall) 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, "v1beta1/{+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 "networksecurity.projects.locations.mirroringDeployments.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 *ProjectsLocationsMirroringDeploymentsDeleteCall) 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 ProjectsLocationsMirroringDeploymentsGetCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// Get: Gets details of a single MirroringDeployment. +// +// - name: Name of the resource. +func (r *ProjectsLocationsMirroringDeploymentsService) Get(name string) *ProjectsLocationsMirroringDeploymentsGetCall { + c := &ProjectsLocationsMirroringDeploymentsGetCall{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 *ProjectsLocationsMirroringDeploymentsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsMirroringDeploymentsGetCall { + 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 *ProjectsLocationsMirroringDeploymentsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsMirroringDeploymentsGetCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsMirroringDeploymentsGetCall) Context(ctx context.Context) *ProjectsLocationsMirroringDeploymentsGetCall { + 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 *ProjectsLocationsMirroringDeploymentsGetCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsMirroringDeploymentsGetCall) 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, "v1beta1/{+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 "networksecurity.projects.locations.mirroringDeployments.get" call. +// Any non-2xx status code is an error. Response headers are in either +// *MirroringDeployment.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 *ProjectsLocationsMirroringDeploymentsGetCall) Do(opts ...googleapi.CallOption) (*MirroringDeployment, 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 := &MirroringDeployment{ + 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 ProjectsLocationsMirroringDeploymentsListCall struct { + s *Service + parent string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// List: Lists MirroringDeployments in a given project and location. +// +// - parent: Parent value for ListMirroringDeploymentsRequest. +func (r *ProjectsLocationsMirroringDeploymentsService) List(parent string) *ProjectsLocationsMirroringDeploymentsListCall { + c := &ProjectsLocationsMirroringDeploymentsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + return c +} + +// Filter sets the optional parameter "filter": Filtering results +func (c *ProjectsLocationsMirroringDeploymentsListCall) Filter(filter string) *ProjectsLocationsMirroringDeploymentsListCall { + c.urlParams_.Set("filter", filter) + return c +} + +// OrderBy sets the optional parameter "orderBy": Hint for how to order the +// results +func (c *ProjectsLocationsMirroringDeploymentsListCall) OrderBy(orderBy string) *ProjectsLocationsMirroringDeploymentsListCall { + 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 *ProjectsLocationsMirroringDeploymentsListCall) PageSize(pageSize int64) *ProjectsLocationsMirroringDeploymentsListCall { + 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 *ProjectsLocationsMirroringDeploymentsListCall) PageToken(pageToken string) *ProjectsLocationsMirroringDeploymentsListCall { + 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 *ProjectsLocationsMirroringDeploymentsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsMirroringDeploymentsListCall { + 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 *ProjectsLocationsMirroringDeploymentsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsMirroringDeploymentsListCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsMirroringDeploymentsListCall) Context(ctx context.Context) *ProjectsLocationsMirroringDeploymentsListCall { + 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 *ProjectsLocationsMirroringDeploymentsListCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsMirroringDeploymentsListCall) 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, "v1beta1/{+parent}/mirroringDeployments") + 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 "networksecurity.projects.locations.mirroringDeployments.list" call. +// Any non-2xx status code is an error. Response headers are in either +// *ListMirroringDeploymentsResponse.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 *ProjectsLocationsMirroringDeploymentsListCall) Do(opts ...googleapi.CallOption) (*ListMirroringDeploymentsResponse, 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 := &ListMirroringDeploymentsResponse{ + 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 *ProjectsLocationsMirroringDeploymentsListCall) Pages(ctx context.Context, f func(*ListMirroringDeploymentsResponse) 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 ProjectsLocationsMirroringDeploymentsPatchCall struct { + s *Service + name string + mirroringdeployment *MirroringDeployment + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Patch: Updates a single MirroringDeployment. +// +// - name: Immutable. Identifier. The name of the MirroringDeployment. +func (r *ProjectsLocationsMirroringDeploymentsService) Patch(name string, mirroringdeployment *MirroringDeployment) *ProjectsLocationsMirroringDeploymentsPatchCall { + c := &ProjectsLocationsMirroringDeploymentsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + c.mirroringdeployment = mirroringdeployment + 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 *ProjectsLocationsMirroringDeploymentsPatchCall) RequestId(requestId string) *ProjectsLocationsMirroringDeploymentsPatchCall { + 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 MirroringDeployment +// 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 *ProjectsLocationsMirroringDeploymentsPatchCall) UpdateMask(updateMask string) *ProjectsLocationsMirroringDeploymentsPatchCall { + c.urlParams_.Set("updateMask", updateMask) + 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 *ProjectsLocationsMirroringDeploymentsPatchCall) Fields(s ...googleapi.Field) *ProjectsLocationsMirroringDeploymentsPatchCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsMirroringDeploymentsPatchCall) Context(ctx context.Context) *ProjectsLocationsMirroringDeploymentsPatchCall { + 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 *ProjectsLocationsMirroringDeploymentsPatchCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsMirroringDeploymentsPatchCall) 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.mirroringdeployment) + if err != nil { + return nil, err + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+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 "networksecurity.projects.locations.mirroringDeployments.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 *ProjectsLocationsMirroringDeploymentsPatchCall) 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 ProjectsLocationsMirroringEndpointGroupAssociationsCreateCall struct { + s *Service + parent string + mirroringendpointgroupassociation *MirroringEndpointGroupAssociation + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Create: Creates a new MirroringEndpointGroupAssociation in a given project +// and location. +// +// - parent: Value for parent. +func (r *ProjectsLocationsMirroringEndpointGroupAssociationsService) Create(parent string, mirroringendpointgroupassociation *MirroringEndpointGroupAssociation) *ProjectsLocationsMirroringEndpointGroupAssociationsCreateCall { + c := &ProjectsLocationsMirroringEndpointGroupAssociationsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + c.mirroringendpointgroupassociation = mirroringendpointgroupassociation + return c +} + +// MirroringEndpointGroupAssociationId sets the optional parameter +// "mirroringEndpointGroupAssociationId": Id of the requesting object If +// auto-generating Id server-side, remove this field and +// mirroring_endpoint_group_association_id from the method_signature of Create +// RPC +func (c *ProjectsLocationsMirroringEndpointGroupAssociationsCreateCall) MirroringEndpointGroupAssociationId(mirroringEndpointGroupAssociationId string) *ProjectsLocationsMirroringEndpointGroupAssociationsCreateCall { + c.urlParams_.Set("mirroringEndpointGroupAssociationId", mirroringEndpointGroupAssociationId) + 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 *ProjectsLocationsMirroringEndpointGroupAssociationsCreateCall) RequestId(requestId string) *ProjectsLocationsMirroringEndpointGroupAssociationsCreateCall { + c.urlParams_.Set("requestId", requestId) + 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 *ProjectsLocationsMirroringEndpointGroupAssociationsCreateCall) Fields(s ...googleapi.Field) *ProjectsLocationsMirroringEndpointGroupAssociationsCreateCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsMirroringEndpointGroupAssociationsCreateCall) Context(ctx context.Context) *ProjectsLocationsMirroringEndpointGroupAssociationsCreateCall { + 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 *ProjectsLocationsMirroringEndpointGroupAssociationsCreateCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsMirroringEndpointGroupAssociationsCreateCall) 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.mirroringendpointgroupassociation) + if err != nil { + return nil, err + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+parent}/mirroringEndpointGroupAssociations") + 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 "networksecurity.projects.locations.mirroringEndpointGroupAssociations.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 *ProjectsLocationsMirroringEndpointGroupAssociationsCreateCall) 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 ProjectsLocationsMirroringEndpointGroupAssociationsDeleteCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Delete: Deletes a single MirroringEndpointGroupAssociation. +// +// - name: Name of the resource. +func (r *ProjectsLocationsMirroringEndpointGroupAssociationsService) Delete(name string) *ProjectsLocationsMirroringEndpointGroupAssociationsDeleteCall { + c := &ProjectsLocationsMirroringEndpointGroupAssociationsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + 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 *ProjectsLocationsMirroringEndpointGroupAssociationsDeleteCall) RequestId(requestId string) *ProjectsLocationsMirroringEndpointGroupAssociationsDeleteCall { + c.urlParams_.Set("requestId", requestId) + 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 *ProjectsLocationsMirroringEndpointGroupAssociationsDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsMirroringEndpointGroupAssociationsDeleteCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsMirroringEndpointGroupAssociationsDeleteCall) Context(ctx context.Context) *ProjectsLocationsMirroringEndpointGroupAssociationsDeleteCall { + 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 *ProjectsLocationsMirroringEndpointGroupAssociationsDeleteCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsMirroringEndpointGroupAssociationsDeleteCall) 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, "v1beta1/{+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 "networksecurity.projects.locations.mirroringEndpointGroupAssociations.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 *ProjectsLocationsMirroringEndpointGroupAssociationsDeleteCall) 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 ProjectsLocationsMirroringEndpointGroupAssociationsGetCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// Get: Gets details of a single MirroringEndpointGroupAssociation. +// +// - name: Name of the resource. +func (r *ProjectsLocationsMirroringEndpointGroupAssociationsService) Get(name string) *ProjectsLocationsMirroringEndpointGroupAssociationsGetCall { + c := &ProjectsLocationsMirroringEndpointGroupAssociationsGetCall{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 *ProjectsLocationsMirroringEndpointGroupAssociationsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsMirroringEndpointGroupAssociationsGetCall { + 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 *ProjectsLocationsMirroringEndpointGroupAssociationsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsMirroringEndpointGroupAssociationsGetCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsMirroringEndpointGroupAssociationsGetCall) Context(ctx context.Context) *ProjectsLocationsMirroringEndpointGroupAssociationsGetCall { + 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 *ProjectsLocationsMirroringEndpointGroupAssociationsGetCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsMirroringEndpointGroupAssociationsGetCall) 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, "v1beta1/{+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 "networksecurity.projects.locations.mirroringEndpointGroupAssociations.get" call. +// Any non-2xx status code is an error. Response headers are in either +// *MirroringEndpointGroupAssociation.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 *ProjectsLocationsMirroringEndpointGroupAssociationsGetCall) Do(opts ...googleapi.CallOption) (*MirroringEndpointGroupAssociation, 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 := &MirroringEndpointGroupAssociation{ + 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 ProjectsLocationsMirroringEndpointGroupAssociationsListCall struct { + s *Service + parent string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// List: Lists MirroringEndpointGroupAssociations in a given project and +// location. +// +// - parent: Parent value for ListMirroringEndpointGroupAssociationsRequest. +func (r *ProjectsLocationsMirroringEndpointGroupAssociationsService) List(parent string) *ProjectsLocationsMirroringEndpointGroupAssociationsListCall { + c := &ProjectsLocationsMirroringEndpointGroupAssociationsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + return c +} + +// Filter sets the optional parameter "filter": Filtering results +func (c *ProjectsLocationsMirroringEndpointGroupAssociationsListCall) Filter(filter string) *ProjectsLocationsMirroringEndpointGroupAssociationsListCall { + c.urlParams_.Set("filter", filter) + return c +} + +// OrderBy sets the optional parameter "orderBy": Hint for how to order the +// results +func (c *ProjectsLocationsMirroringEndpointGroupAssociationsListCall) OrderBy(orderBy string) *ProjectsLocationsMirroringEndpointGroupAssociationsListCall { + 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 *ProjectsLocationsMirroringEndpointGroupAssociationsListCall) PageSize(pageSize int64) *ProjectsLocationsMirroringEndpointGroupAssociationsListCall { + 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 *ProjectsLocationsMirroringEndpointGroupAssociationsListCall) PageToken(pageToken string) *ProjectsLocationsMirroringEndpointGroupAssociationsListCall { + 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 *ProjectsLocationsMirroringEndpointGroupAssociationsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsMirroringEndpointGroupAssociationsListCall { + 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 *ProjectsLocationsMirroringEndpointGroupAssociationsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsMirroringEndpointGroupAssociationsListCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsMirroringEndpointGroupAssociationsListCall) Context(ctx context.Context) *ProjectsLocationsMirroringEndpointGroupAssociationsListCall { + 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 *ProjectsLocationsMirroringEndpointGroupAssociationsListCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsMirroringEndpointGroupAssociationsListCall) 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, "v1beta1/{+parent}/mirroringEndpointGroupAssociations") + 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 "networksecurity.projects.locations.mirroringEndpointGroupAssociations.list" call. +// Any non-2xx status code is an error. Response headers are in either +// *ListMirroringEndpointGroupAssociationsResponse.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 *ProjectsLocationsMirroringEndpointGroupAssociationsListCall) Do(opts ...googleapi.CallOption) (*ListMirroringEndpointGroupAssociationsResponse, 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 := &ListMirroringEndpointGroupAssociationsResponse{ + 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 *ProjectsLocationsMirroringEndpointGroupAssociationsListCall) Pages(ctx context.Context, f func(*ListMirroringEndpointGroupAssociationsResponse) 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 ProjectsLocationsMirroringEndpointGroupAssociationsPatchCall struct { + s *Service + name string + mirroringendpointgroupassociation *MirroringEndpointGroupAssociation + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Patch: Updates a single MirroringEndpointGroupAssociation. +// +// - name: Immutable. Identifier. The name of the +// MirroringEndpointGroupAssociation. +func (r *ProjectsLocationsMirroringEndpointGroupAssociationsService) Patch(name string, mirroringendpointgroupassociation *MirroringEndpointGroupAssociation) *ProjectsLocationsMirroringEndpointGroupAssociationsPatchCall { + c := &ProjectsLocationsMirroringEndpointGroupAssociationsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + c.mirroringendpointgroupassociation = mirroringendpointgroupassociation + 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 *ProjectsLocationsMirroringEndpointGroupAssociationsPatchCall) RequestId(requestId string) *ProjectsLocationsMirroringEndpointGroupAssociationsPatchCall { + 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 +// MirroringEndpointGroupAssociation 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 *ProjectsLocationsMirroringEndpointGroupAssociationsPatchCall) UpdateMask(updateMask string) *ProjectsLocationsMirroringEndpointGroupAssociationsPatchCall { + c.urlParams_.Set("updateMask", updateMask) + 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 *ProjectsLocationsMirroringEndpointGroupAssociationsPatchCall) Fields(s ...googleapi.Field) *ProjectsLocationsMirroringEndpointGroupAssociationsPatchCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsMirroringEndpointGroupAssociationsPatchCall) Context(ctx context.Context) *ProjectsLocationsMirroringEndpointGroupAssociationsPatchCall { + 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 *ProjectsLocationsMirroringEndpointGroupAssociationsPatchCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsMirroringEndpointGroupAssociationsPatchCall) 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.mirroringendpointgroupassociation) + if err != nil { + return nil, err + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+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 "networksecurity.projects.locations.mirroringEndpointGroupAssociations.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 *ProjectsLocationsMirroringEndpointGroupAssociationsPatchCall) 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 ProjectsLocationsMirroringEndpointGroupsCreateCall struct { + s *Service + parent string + mirroringendpointgroup *MirroringEndpointGroup + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Create: Creates a new MirroringEndpointGroup in a given project and +// location. +// +// - parent: Value for parent. +func (r *ProjectsLocationsMirroringEndpointGroupsService) Create(parent string, mirroringendpointgroup *MirroringEndpointGroup) *ProjectsLocationsMirroringEndpointGroupsCreateCall { + c := &ProjectsLocationsMirroringEndpointGroupsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + c.mirroringendpointgroup = mirroringendpointgroup + return c +} + +// MirroringEndpointGroupId sets the optional parameter +// "mirroringEndpointGroupId": Required. Id of the requesting object If +// auto-generating Id server-side, remove this field and +// mirroring_endpoint_group_id from the method_signature of Create RPC +func (c *ProjectsLocationsMirroringEndpointGroupsCreateCall) MirroringEndpointGroupId(mirroringEndpointGroupId string) *ProjectsLocationsMirroringEndpointGroupsCreateCall { + c.urlParams_.Set("mirroringEndpointGroupId", mirroringEndpointGroupId) + 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 *ProjectsLocationsMirroringEndpointGroupsCreateCall) RequestId(requestId string) *ProjectsLocationsMirroringEndpointGroupsCreateCall { + c.urlParams_.Set("requestId", requestId) + 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 *ProjectsLocationsMirroringEndpointGroupsCreateCall) Fields(s ...googleapi.Field) *ProjectsLocationsMirroringEndpointGroupsCreateCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsMirroringEndpointGroupsCreateCall) Context(ctx context.Context) *ProjectsLocationsMirroringEndpointGroupsCreateCall { + 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 *ProjectsLocationsMirroringEndpointGroupsCreateCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsMirroringEndpointGroupsCreateCall) 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.mirroringendpointgroup) + if err != nil { + return nil, err + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+parent}/mirroringEndpointGroups") + 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 "networksecurity.projects.locations.mirroringEndpointGroups.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 *ProjectsLocationsMirroringEndpointGroupsCreateCall) 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 ProjectsLocationsMirroringEndpointGroupsDeleteCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Delete: Deletes a single MirroringEndpointGroup. +// +// - name: Name of the resource. +func (r *ProjectsLocationsMirroringEndpointGroupsService) Delete(name string) *ProjectsLocationsMirroringEndpointGroupsDeleteCall { + c := &ProjectsLocationsMirroringEndpointGroupsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + 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 *ProjectsLocationsMirroringEndpointGroupsDeleteCall) RequestId(requestId string) *ProjectsLocationsMirroringEndpointGroupsDeleteCall { + c.urlParams_.Set("requestId", requestId) + 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 *ProjectsLocationsMirroringEndpointGroupsDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsMirroringEndpointGroupsDeleteCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsMirroringEndpointGroupsDeleteCall) Context(ctx context.Context) *ProjectsLocationsMirroringEndpointGroupsDeleteCall { + 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 *ProjectsLocationsMirroringEndpointGroupsDeleteCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsMirroringEndpointGroupsDeleteCall) 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, "v1beta1/{+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 "networksecurity.projects.locations.mirroringEndpointGroups.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 *ProjectsLocationsMirroringEndpointGroupsDeleteCall) 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 ProjectsLocationsMirroringEndpointGroupsGetCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// Get: Gets details of a single MirroringEndpointGroup. +// +// - name: Name of the resource. +func (r *ProjectsLocationsMirroringEndpointGroupsService) Get(name string) *ProjectsLocationsMirroringEndpointGroupsGetCall { + c := &ProjectsLocationsMirroringEndpointGroupsGetCall{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 *ProjectsLocationsMirroringEndpointGroupsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsMirroringEndpointGroupsGetCall { + 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 *ProjectsLocationsMirroringEndpointGroupsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsMirroringEndpointGroupsGetCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsMirroringEndpointGroupsGetCall) Context(ctx context.Context) *ProjectsLocationsMirroringEndpointGroupsGetCall { + 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 *ProjectsLocationsMirroringEndpointGroupsGetCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsMirroringEndpointGroupsGetCall) 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, "v1beta1/{+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 "networksecurity.projects.locations.mirroringEndpointGroups.get" call. +// Any non-2xx status code is an error. Response headers are in either +// *MirroringEndpointGroup.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 *ProjectsLocationsMirroringEndpointGroupsGetCall) Do(opts ...googleapi.CallOption) (*MirroringEndpointGroup, 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 := &MirroringEndpointGroup{ + 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 ProjectsLocationsMirroringEndpointGroupsListCall struct { + s *Service + parent string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// List: Lists MirroringEndpointGroups in a given project and location. +// +// - parent: Parent value for ListMirroringEndpointGroupsRequest. +func (r *ProjectsLocationsMirroringEndpointGroupsService) List(parent string) *ProjectsLocationsMirroringEndpointGroupsListCall { + c := &ProjectsLocationsMirroringEndpointGroupsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + return c +} + +// Filter sets the optional parameter "filter": Filtering results +func (c *ProjectsLocationsMirroringEndpointGroupsListCall) Filter(filter string) *ProjectsLocationsMirroringEndpointGroupsListCall { + c.urlParams_.Set("filter", filter) + return c +} + +// OrderBy sets the optional parameter "orderBy": Hint for how to order the +// results +func (c *ProjectsLocationsMirroringEndpointGroupsListCall) OrderBy(orderBy string) *ProjectsLocationsMirroringEndpointGroupsListCall { + 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 *ProjectsLocationsMirroringEndpointGroupsListCall) PageSize(pageSize int64) *ProjectsLocationsMirroringEndpointGroupsListCall { + 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 *ProjectsLocationsMirroringEndpointGroupsListCall) PageToken(pageToken string) *ProjectsLocationsMirroringEndpointGroupsListCall { + 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 *ProjectsLocationsMirroringEndpointGroupsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsMirroringEndpointGroupsListCall { + 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 *ProjectsLocationsMirroringEndpointGroupsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsMirroringEndpointGroupsListCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsMirroringEndpointGroupsListCall) Context(ctx context.Context) *ProjectsLocationsMirroringEndpointGroupsListCall { + 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 *ProjectsLocationsMirroringEndpointGroupsListCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsMirroringEndpointGroupsListCall) 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, "v1beta1/{+parent}/mirroringEndpointGroups") + 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 "networksecurity.projects.locations.mirroringEndpointGroups.list" call. +// Any non-2xx status code is an error. Response headers are in either +// *ListMirroringEndpointGroupsResponse.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 *ProjectsLocationsMirroringEndpointGroupsListCall) Do(opts ...googleapi.CallOption) (*ListMirroringEndpointGroupsResponse, 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 := &ListMirroringEndpointGroupsResponse{ + 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 *ProjectsLocationsMirroringEndpointGroupsListCall) Pages(ctx context.Context, f func(*ListMirroringEndpointGroupsResponse) 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 ProjectsLocationsMirroringEndpointGroupsPatchCall struct { + s *Service + name string + mirroringendpointgroup *MirroringEndpointGroup + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Patch: Updates a single MirroringEndpointGroup. +// +// - name: Immutable. Identifier. The name of the MirroringEndpointGroup. +func (r *ProjectsLocationsMirroringEndpointGroupsService) Patch(name string, mirroringendpointgroup *MirroringEndpointGroup) *ProjectsLocationsMirroringEndpointGroupsPatchCall { + c := &ProjectsLocationsMirroringEndpointGroupsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + c.mirroringendpointgroup = mirroringendpointgroup + 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 *ProjectsLocationsMirroringEndpointGroupsPatchCall) RequestId(requestId string) *ProjectsLocationsMirroringEndpointGroupsPatchCall { + 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 MirroringEndpointGroup +// 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 *ProjectsLocationsMirroringEndpointGroupsPatchCall) UpdateMask(updateMask string) *ProjectsLocationsMirroringEndpointGroupsPatchCall { + c.urlParams_.Set("updateMask", updateMask) + 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 *ProjectsLocationsMirroringEndpointGroupsPatchCall) Fields(s ...googleapi.Field) *ProjectsLocationsMirroringEndpointGroupsPatchCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsMirroringEndpointGroupsPatchCall) Context(ctx context.Context) *ProjectsLocationsMirroringEndpointGroupsPatchCall { + 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 *ProjectsLocationsMirroringEndpointGroupsPatchCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsMirroringEndpointGroupsPatchCall) 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.mirroringendpointgroup) + if err != nil { + return nil, err + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+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 "networksecurity.projects.locations.mirroringEndpointGroups.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 *ProjectsLocationsMirroringEndpointGroupsPatchCall) 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 ProjectsLocationsOperationsCancelCall struct { s *Service name string diff --git a/osconfig/v1/osconfig-api.json b/osconfig/v1/osconfig-api.json index f34749d97e2..5d0874dcc07 100644 --- a/osconfig/v1/osconfig-api.json +++ b/osconfig/v1/osconfig-api.json @@ -1083,7 +1083,7 @@ } } }, - "revision": "20240610", + "revision": "20240901", "rootUrl": "https://osconfig.googleapis.com/", "schemas": { "AptSettings": { @@ -1565,7 +1565,7 @@ "AVAILABLE_PACKAGE" ], "enumDescriptions": [ - "Invalid. An type must be specified.", + "Invalid. A type must be specified.", "This represents a package that is installed on the VM.", "This represents an update that is available for a package." ], @@ -2480,7 +2480,7 @@ "type": "string" }, "outputFilePath": { - "description": "Only recorded for enforce Exec. Path to an output file (that is created by this Exec) whose content will be recorded in OSPolicyResourceCompliance after a successful run. Absence or failure to read this file will result in this ExecResource being non-compliant. Output file size is limited to 100K bytes.", + "description": "Only recorded for enforce Exec. Path to an output file (that is created by this Exec) whose content will be recorded in OSPolicyResourceCompliance after a successful run. Absence or failure to read this file will result in this ExecResource being non-compliant. Output file size is limited to 500K bytes.", "type": "string" }, "script": { diff --git a/osconfig/v1/osconfig-gen.go b/osconfig/v1/osconfig-gen.go index 62d702dc137..28768a74e56 100644 --- a/osconfig/v1/osconfig-gen.go +++ b/osconfig/v1/osconfig-gen.go @@ -827,7 +827,7 @@ type InventoryItem struct { // Type: The specific type of inventory, correlating to its specific details. // // Possible values: - // "TYPE_UNSPECIFIED" - Invalid. An type must be specified. + // "TYPE_UNSPECIFIED" - Invalid. A type must be specified. // "INSTALLED_PACKAGE" - This represents a package that is installed on the // VM. // "AVAILABLE_PACKAGE" - This represents an update that is available for a @@ -2045,7 +2045,7 @@ type OSPolicyResourceExecResourceExec struct { // is created by this Exec) whose content will be recorded in // OSPolicyResourceCompliance after a successful run. Absence or failure to // read this file will result in this ExecResource being non-compliant. Output - // file size is limited to 100K bytes. + // file size is limited to 500K bytes. OutputFilePath string `json:"outputFilePath,omitempty"` // Script: An inline script. The size of the script is limited to 32KiB. Script string `json:"script,omitempty"` diff --git a/osconfig/v1alpha/osconfig-api.json b/osconfig/v1alpha/osconfig-api.json index 9016008825e..0e74ff521a2 100644 --- a/osconfig/v1alpha/osconfig-api.json +++ b/osconfig/v1alpha/osconfig-api.json @@ -707,7 +707,7 @@ } } }, - "revision": "20240610", + "revision": "20240901", "rootUrl": "https://osconfig.googleapis.com/", "schemas": { "CVSSv3": { @@ -1141,7 +1141,7 @@ "AVAILABLE_PACKAGE" ], "enumDescriptions": [ - "Invalid. An type must be specified.", + "Invalid. A type must be specified.", "This represents a package that is installed on the VM.", "This represents an update that is available for a package." ], diff --git a/osconfig/v1alpha/osconfig-gen.go b/osconfig/v1alpha/osconfig-gen.go index d0aff00a306..dcb77148942 100644 --- a/osconfig/v1alpha/osconfig-gen.go +++ b/osconfig/v1alpha/osconfig-gen.go @@ -721,7 +721,7 @@ type InventoryItem struct { // Type: The specific type of inventory, correlating to its specific details. // // Possible values: - // "TYPE_UNSPECIFIED" - Invalid. An type must be specified. + // "TYPE_UNSPECIFIED" - Invalid. A type must be specified. // "INSTALLED_PACKAGE" - This represents a package that is installed on the // VM. // "AVAILABLE_PACKAGE" - This represents an update that is available for a diff --git a/redis/v1/redis-api.json b/redis/v1/redis-api.json index 79318d50bb7..08d788b97b6 100644 --- a/redis/v1/redis-api.json +++ b/redis/v1/redis-api.json @@ -849,7 +849,7 @@ } } }, - "revision": "20240822", + "revision": "20240904", "rootUrl": "https://redis.googleapis.com/", "schemas": { "AOFConfig": { @@ -875,6 +875,42 @@ }, "type": "object" }, + "AssetLocation": { + "description": "Provides the mapping of a cloud asset to a direct physical location or to a proxy that defines the location on its behalf.", + "id": "AssetLocation", + "properties": { + "ccfeRmsPath": { + "description": "Spanner path of the CCFE RMS database. It is only applicable for CCFE tenants that use CCFE RMS for storing resource metadata.", + "type": "string" + }, + "expected": { + "$ref": "IsolationExpectations", + "description": "Defines the customer expectation around ZI/ZS for this asset and ZI/ZS state of the region at the time of asset creation." + }, + "extraParameters": { + "description": "Defines extra parameters required for specific asset types.", + "items": { + "$ref": "ExtraParameter" + }, + "type": "array" + }, + "locationData": { + "description": "Contains all kinds of physical location definitions for this asset.", + "items": { + "$ref": "LocationData" + }, + "type": "array" + }, + "parentAsset": { + "description": "Defines parents assets if any in order to allow later generation of child_asset_location data via child assets.", + "items": { + "$ref": "CloudAsset" + }, + "type": "array" + } + }, + "type": "object" + }, "AvailabilityConfiguration": { "description": "Configuration for availability of database instance", "id": "AvailabilityConfiguration", @@ -968,6 +1004,19 @@ }, "type": "object" }, + "BlobstoreLocation": { + "description": "Policy ID that identified data placement in Blobstore as per go/blobstore-user-guide#data-metadata-placement-and-failure-domains", + "id": "BlobstoreLocation", + "properties": { + "policyId": { + "items": { + "type": "string" + }, + "type": "array" + } + }, + "type": "object" + }, "CertChain": { "id": "CertChain", "properties": { @@ -995,6 +1044,30 @@ }, "type": "object" }, + "CloudAsset": { + "id": "CloudAsset", + "properties": { + "assetName": { + "type": "string" + }, + "assetType": { + "type": "string" + } + }, + "type": "object" + }, + "CloudAssetComposition": { + "id": "CloudAssetComposition", + "properties": { + "childAsset": { + "items": { + "$ref": "CloudAsset" + }, + "type": "array" + } + }, + "type": "object" + }, "Cluster": { "description": "A cluster instance.", "id": "Cluster", @@ -1822,7 +1895,7 @@ "type": "object" }, "DatabaseResourceMetadata": { - "description": "Common model for database resource instance metadata.", + "description": "Common model for database resource instance metadata. Next ID: 21", "id": "DatabaseResourceMetadata", "properties": { "availabilityConfiguration": { @@ -1961,6 +2034,10 @@ "description": "Required. Different from DatabaseResourceId.unique_id, a resource name can be reused over time. That is, after a resource named \"ABC\" is deleted, the name \"ABC\" can be used to to create a new resource within the same source. Resource name to follow CAIS resource_name format as noted here go/condor-common-datamodel", "type": "string" }, + "tagsSet": { + "$ref": "Tags", + "description": "Optional. Tags associated with this resources." + }, "updationTime": { "description": "The time at which the resource was updated and recorded at partner service.", "format": "google-datetime", @@ -2276,6 +2353,18 @@ }, "type": "object" }, + "DirectLocationAssignment": { + "id": "DirectLocationAssignment", + "properties": { + "location": { + "items": { + "$ref": "LocationAssignment" + }, + "type": "array" + } + }, + "type": "object" + }, "DiscoveryEndpoint": { "description": "Endpoints on each network, for Redis clients to connect to the cluster.", "id": "DiscoveryEndpoint", @@ -2349,6 +2438,17 @@ }, "type": "object" }, + "ExtraParameter": { + "description": "Defines parameters that should only be used for specific asset types.", + "id": "ExtraParameter", + "properties": { + "regionalMigDistributionPolicy": { + "$ref": "RegionalMigDistributionPolicy", + "description": "Details about zones used by regional compute.googleapis.com/InstanceGroupManager to create instances." + } + }, + "type": "object" + }, "FailoverInstanceRequest": { "description": "Request for Failover.", "id": "FailoverInstanceRequest", @@ -2770,6 +2870,131 @@ }, "type": "object" }, + "IsolationExpectations": { + "id": "IsolationExpectations", + "properties": { + "requirementOverride": { + "$ref": "RequirementOverride", + "description": "Explicit overrides for ZI and ZS requirements to be used for resources that should be excluded from ZI/ZS verification logic." + }, + "ziOrgPolicy": { + "enum": [ + "ZI_UNSPECIFIED", + "ZI_UNKNOWN", + "ZI_NOT_REQUIRED", + "ZI_PREFERRED", + "ZI_REQUIRED" + ], + "enumDescriptions": [ + "", + "To be used if tracking is not available", + "", + "", + "" + ], + "type": "string" + }, + "ziRegionPolicy": { + "enum": [ + "ZI_REGION_POLICY_UNSPECIFIED", + "ZI_REGION_POLICY_UNKNOWN", + "ZI_REGION_POLICY_NOT_SET", + "ZI_REGION_POLICY_FAIL_OPEN", + "ZI_REGION_POLICY_FAIL_CLOSED" + ], + "enumDescriptions": [ + "", + "To be used if tracking is not available", + "", + "", + "" + ], + "type": "string" + }, + "ziRegionState": { + "enum": [ + "ZI_REGION_UNSPECIFIED", + "ZI_REGION_UNKNOWN", + "ZI_REGION_NOT_ENABLED", + "ZI_REGION_ENABLED" + ], + "enumDescriptions": [ + "", + "To be used if tracking is not available", + "", + "" + ], + "type": "string" + }, + "zoneIsolation": { + "deprecated": true, + "description": "Deprecated: use zi_org_policy, zi_region_policy and zi_region_state instead for setting ZI expectations as per go/zicy-publish-physical-location.", + "enum": [ + "ZI_UNSPECIFIED", + "ZI_UNKNOWN", + "ZI_NOT_REQUIRED", + "ZI_PREFERRED", + "ZI_REQUIRED" + ], + "enumDescriptions": [ + "", + "To be used if tracking is not available", + "", + "", + "" + ], + "type": "string" + }, + "zoneSeparation": { + "deprecated": true, + "description": "Deprecated: use zs_org_policy, and zs_region_stateinstead for setting Zs expectations as per go/zicy-publish-physical-location.", + "enum": [ + "ZS_UNSPECIFIED", + "ZS_UNKNOWN", + "ZS_NOT_REQUIRED", + "ZS_REQUIRED" + ], + "enumDescriptions": [ + "", + "To be used if tracking is not available", + "", + "" + ], + "type": "string" + }, + "zsOrgPolicy": { + "enum": [ + "ZS_UNSPECIFIED", + "ZS_UNKNOWN", + "ZS_NOT_REQUIRED", + "ZS_REQUIRED" + ], + "enumDescriptions": [ + "", + "To be used if tracking is not available", + "", + "" + ], + "type": "string" + }, + "zsRegionState": { + "enum": [ + "ZS_REGION_UNSPECIFIED", + "ZS_REGION_UNKNOWN", + "ZS_REGION_NOT_ENABLED", + "ZS_REGION_ENABLED" + ], + "enumDescriptions": [ + "", + "To be used if tracking of the asset ZS-bit is not available", + "", + "" + ], + "type": "string" + } + }, + "type": "object" + }, "ListClustersResponse": { "description": "Response for ListClusters.", "id": "ListClustersResponse", @@ -2890,6 +3115,64 @@ }, "type": "object" }, + "LocationAssignment": { + "id": "LocationAssignment", + "properties": { + "location": { + "type": "string" + }, + "locationType": { + "enum": [ + "UNSPECIFIED", + "CLUSTER", + "POP", + "CLOUD_ZONE", + "CLOUD_REGION", + "MULTI_REGION_GEO", + "MULTI_REGION_JURISDICTION", + "GLOBAL", + "OTHER" + ], + "enumDescriptions": [ + "", + "1-10: Physical failure domains.", + "", + "11-20: Logical failure domains.", + "", + "", + "", + "", + "" + ], + "type": "string" + } + }, + "type": "object" + }, + "LocationData": { + "id": "LocationData", + "properties": { + "blobstoreLocation": { + "$ref": "BlobstoreLocation" + }, + "childAssetLocation": { + "$ref": "CloudAssetComposition" + }, + "directLocation": { + "$ref": "DirectLocationAssignment" + }, + "gcpProjectProxy": { + "$ref": "TenantProjectProxy" + }, + "placerLocation": { + "$ref": "PlacerLocation" + }, + "spannerLocation": { + "$ref": "SpannerLocation" + } + }, + "type": "object" + }, "MachineConfiguration": { "description": "MachineConfiguration describes the configuration of a machine specific to Database Resource.", "id": "MachineConfiguration", @@ -3250,6 +3533,17 @@ }, "type": "object" }, + "PlacerLocation": { + "description": "Message describing that the location of the customer resource is tied to placer allocations", + "id": "PlacerLocation", + "properties": { + "placerConfig": { + "description": "Directory with a config related to it in placer (e.g. \"/placer/prod/home/my-root/my-dir\")", + "type": "string" + } + }, + "type": "object" + }, "Product": { "description": "Product specification for Condor resources.", "id": "Product", @@ -3467,6 +3761,25 @@ }, "type": "object" }, + "RegionalMigDistributionPolicy": { + "description": "To be used for specifying the intended distribution of regional compute.googleapis.com/InstanceGroupManager instances", + "id": "RegionalMigDistributionPolicy", + "properties": { + "targetShape": { + "description": "The shape in which the group converges around distribution of resources. Instance of proto2 enum", + "format": "int32", + "type": "integer" + }, + "zones": { + "description": "Cloud zones used by regional MIG to create instances.", + "items": { + "$ref": "ZoneConfiguration" + }, + "type": "array" + } + }, + "type": "object" + }, "RemoteCluster": { "description": "Details of the remote cluster associated with this cluster in a cross cluster replication setup.", "id": "RemoteCluster", @@ -3483,6 +3796,44 @@ }, "type": "object" }, + "RequirementOverride": { + "id": "RequirementOverride", + "properties": { + "ziOverride": { + "enum": [ + "ZI_UNSPECIFIED", + "ZI_UNKNOWN", + "ZI_NOT_REQUIRED", + "ZI_PREFERRED", + "ZI_REQUIRED" + ], + "enumDescriptions": [ + "", + "To be used if tracking is not available", + "", + "", + "" + ], + "type": "string" + }, + "zsOverride": { + "enum": [ + "ZS_UNSPECIFIED", + "ZS_UNKNOWN", + "ZS_NOT_REQUIRED", + "ZS_REQUIRED" + ], + "enumDescriptions": [ + "", + "To be used if tracking is not available", + "", + "" + ], + "type": "string" + } + }, + "type": "object" + }, "RescheduleClusterMaintenanceRequest": { "description": "Request for rescheduling a cluster maintenance.", "id": "RescheduleClusterMaintenanceRequest", @@ -3567,6 +3918,26 @@ }, "type": "object" }, + "SpannerLocation": { + "id": "SpannerLocation", + "properties": { + "backupName": { + "description": "Set of backups used by the resource with name in the same format as what is available at http://table/spanner_automon.backup_metadata", + "items": { + "type": "string" + }, + "type": "array" + }, + "dbName": { + "description": "Set of databases used by the resource in format /span//", + "items": { + "type": "string" + }, + "type": "array" + } + }, + "type": "object" + }, "StateInfo": { "description": "Represents additional information about the state of the cluster.", "id": "StateInfo", @@ -3605,6 +3976,32 @@ }, "type": "object" }, + "Tags": { + "description": "Message type for storing tags. Tags provide a way to create annotations for resources, and in some cases conditionally allow or deny policies based on whether a resource has a specific tag.", + "id": "Tags", + "properties": { + "tags": { + "additionalProperties": { + "type": "string" + }, + "description": "The Tag key/value mappings.", + "type": "object" + } + }, + "type": "object" + }, + "TenantProjectProxy": { + "id": "TenantProjectProxy", + "properties": { + "projectNumbers": { + "items": { + "type": "string" + }, + "type": "array" + } + }, + "type": "object" + }, "TimeOfDay": { "description": "Represents a time of day. The date and time zone are either not significant or are specified elsewhere. An API may choose to allow leap seconds. Related types are google.type.Date and `google.protobuf.Timestamp`.", "id": "TimeOfDay", @@ -3770,6 +4167,15 @@ }, "type": "object" }, + "ZoneConfiguration": { + "id": "ZoneConfiguration", + "properties": { + "zone": { + "type": "string" + } + }, + "type": "object" + }, "ZoneDistributionConfig": { "description": "Zone distribution config for allocation of cluster resources.", "id": "ZoneDistributionConfig", diff --git a/redis/v1/redis-gen.go b/redis/v1/redis-gen.go index 4226d5a6cab..4c1f57a40f5 100644 --- a/redis/v1/redis-gen.go +++ b/redis/v1/redis-gen.go @@ -244,6 +244,41 @@ func (s AOFConfig) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// AssetLocation: Provides the mapping of a cloud asset to a direct physical +// location or to a proxy that defines the location on its behalf. +type AssetLocation struct { + // CcfeRmsPath: Spanner path of the CCFE RMS database. It is only applicable + // for CCFE tenants that use CCFE RMS for storing resource metadata. + CcfeRmsPath string `json:"ccfeRmsPath,omitempty"` + // Expected: Defines the customer expectation around ZI/ZS for this asset and + // ZI/ZS state of the region at the time of asset creation. + Expected *IsolationExpectations `json:"expected,omitempty"` + // ExtraParameters: Defines extra parameters required for specific asset types. + ExtraParameters []*ExtraParameter `json:"extraParameters,omitempty"` + // LocationData: Contains all kinds of physical location definitions for this + // asset. + LocationData []*LocationData `json:"locationData,omitempty"` + // ParentAsset: Defines parents assets if any in order to allow later + // generation of child_asset_location data via child assets. + ParentAsset []*CloudAsset `json:"parentAsset,omitempty"` + // ForceSendFields is a list of field names (e.g. "CcfeRmsPath") 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. "CcfeRmsPath") 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 AssetLocation) MarshalJSON() ([]byte, error) { + type NoMethod AssetLocation + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // AvailabilityConfiguration: Configuration for availability of database // instance type AvailabilityConfiguration struct { @@ -351,6 +386,28 @@ func (s BackupRun) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// BlobstoreLocation: Policy ID that identified data placement in Blobstore as +// per go/blobstore-user-guide#data-metadata-placement-and-failure-domains +type BlobstoreLocation struct { + PolicyId []string `json:"policyId,omitempty"` + // ForceSendFields is a list of field names (e.g. "PolicyId") 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. "PolicyId") 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 BlobstoreLocation) MarshalJSON() ([]byte, error) { + type NoMethod BlobstoreLocation + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + type CertChain struct { // Certificates: The certificates that form the CA chain, from leaf to root // order. @@ -402,6 +459,47 @@ func (s CertificateAuthority) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +type CloudAsset struct { + AssetName string `json:"assetName,omitempty"` + AssetType string `json:"assetType,omitempty"` + // ForceSendFields is a list of field names (e.g. "AssetName") 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. "AssetName") 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 CloudAsset) MarshalJSON() ([]byte, error) { + type NoMethod CloudAsset + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +type CloudAssetComposition struct { + ChildAsset []*CloudAsset `json:"childAsset,omitempty"` + // ForceSendFields is a list of field names (e.g. "ChildAsset") 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. "ChildAsset") 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 CloudAssetComposition) MarshalJSON() ([]byte, error) { + type NoMethod CloudAssetComposition + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // Cluster: A cluster instance. type Cluster struct { // AuthorizationMode: Optional. The authorization mode of the Redis cluster. If @@ -1151,7 +1249,7 @@ func (s DatabaseResourceId) MarshalJSON() ([]byte, error) { } // DatabaseResourceMetadata: Common model for database resource instance -// metadata. +// metadata. Next ID: 21 type DatabaseResourceMetadata struct { // AvailabilityConfiguration: Availability configuration for this instance AvailabilityConfiguration *AvailabilityConfiguration `json:"availabilityConfiguration,omitempty"` @@ -1229,6 +1327,8 @@ type DatabaseResourceMetadata struct { // the same source. Resource name to follow CAIS resource_name format as noted // here go/condor-common-datamodel ResourceName string `json:"resourceName,omitempty"` + // TagsSet: Optional. Tags associated with this resources. + TagsSet *Tags `json:"tagsSet,omitempty"` // UpdationTime: The time at which the resource was updated and recorded at // partner service. UpdationTime string `json:"updationTime,omitempty"` @@ -1504,6 +1604,26 @@ func (s DatabaseResourceRecommendationSignalData) MarshalJSON() ([]byte, error) return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +type DirectLocationAssignment struct { + Location []*LocationAssignment `json:"location,omitempty"` + // ForceSendFields is a list of field names (e.g. "Location") 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. "Location") 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 DirectLocationAssignment) MarshalJSON() ([]byte, error) { + type NoMethod DirectLocationAssignment + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // DiscoveryEndpoint: Endpoints on each network, for Redis clients to connect // to the cluster. type DiscoveryEndpoint struct { @@ -1602,6 +1722,30 @@ func (s ExportInstanceRequest) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// ExtraParameter: Defines parameters that should only be used for specific +// asset types. +type ExtraParameter struct { + // RegionalMigDistributionPolicy: Details about zones used by regional + // compute.googleapis.com/InstanceGroupManager to create instances. + RegionalMigDistributionPolicy *RegionalMigDistributionPolicy `json:"regionalMigDistributionPolicy,omitempty"` + // ForceSendFields is a list of field names (e.g. + // "RegionalMigDistributionPolicy") 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. "RegionalMigDistributionPolicy") + // 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 ExtraParameter) MarshalJSON() ([]byte, error) { + type NoMethod ExtraParameter + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // FailoverInstanceRequest: Request for Failover. type FailoverInstanceRequest struct { // DataProtectionMode: Optional. Available data protection modes that the user @@ -2061,6 +2205,81 @@ func (s InternalResourceMetadata) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +type IsolationExpectations struct { + // RequirementOverride: Explicit overrides for ZI and ZS requirements to be + // used for resources that should be excluded from ZI/ZS verification logic. + RequirementOverride *RequirementOverride `json:"requirementOverride,omitempty"` + // Possible values: + // "ZI_UNSPECIFIED" + // "ZI_UNKNOWN" - To be used if tracking is not available + // "ZI_NOT_REQUIRED" + // "ZI_PREFERRED" + // "ZI_REQUIRED" + ZiOrgPolicy string `json:"ziOrgPolicy,omitempty"` + // Possible values: + // "ZI_REGION_POLICY_UNSPECIFIED" + // "ZI_REGION_POLICY_UNKNOWN" - To be used if tracking is not available + // "ZI_REGION_POLICY_NOT_SET" + // "ZI_REGION_POLICY_FAIL_OPEN" + // "ZI_REGION_POLICY_FAIL_CLOSED" + ZiRegionPolicy string `json:"ziRegionPolicy,omitempty"` + // Possible values: + // "ZI_REGION_UNSPECIFIED" + // "ZI_REGION_UNKNOWN" - To be used if tracking is not available + // "ZI_REGION_NOT_ENABLED" + // "ZI_REGION_ENABLED" + ZiRegionState string `json:"ziRegionState,omitempty"` + // ZoneIsolation: Deprecated: use zi_org_policy, zi_region_policy and + // zi_region_state instead for setting ZI expectations as per + // go/zicy-publish-physical-location. + // + // Possible values: + // "ZI_UNSPECIFIED" + // "ZI_UNKNOWN" - To be used if tracking is not available + // "ZI_NOT_REQUIRED" + // "ZI_PREFERRED" + // "ZI_REQUIRED" + ZoneIsolation string `json:"zoneIsolation,omitempty"` + // ZoneSeparation: Deprecated: use zs_org_policy, and zs_region_stateinstead + // for setting Zs expectations as per go/zicy-publish-physical-location. + // + // Possible values: + // "ZS_UNSPECIFIED" + // "ZS_UNKNOWN" - To be used if tracking is not available + // "ZS_NOT_REQUIRED" + // "ZS_REQUIRED" + ZoneSeparation string `json:"zoneSeparation,omitempty"` + // Possible values: + // "ZS_UNSPECIFIED" + // "ZS_UNKNOWN" - To be used if tracking is not available + // "ZS_NOT_REQUIRED" + // "ZS_REQUIRED" + ZsOrgPolicy string `json:"zsOrgPolicy,omitempty"` + // Possible values: + // "ZS_REGION_UNSPECIFIED" + // "ZS_REGION_UNKNOWN" - To be used if tracking of the asset ZS-bit is not + // available + // "ZS_REGION_NOT_ENABLED" + // "ZS_REGION_ENABLED" + ZsRegionState string `json:"zsRegionState,omitempty"` + // ForceSendFields is a list of field names (e.g. "RequirementOverride") 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. "RequirementOverride") 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 IsolationExpectations) MarshalJSON() ([]byte, error) { + type NoMethod IsolationExpectations + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // ListClustersResponse: Response for ListClusters. type ListClustersResponse struct { // Clusters: A list of Redis clusters in the project in the specified location, @@ -2232,6 +2451,62 @@ func (s Location) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +type LocationAssignment struct { + Location string `json:"location,omitempty"` + // Possible values: + // "UNSPECIFIED" + // "CLUSTER" - 1-10: Physical failure domains. + // "POP" + // "CLOUD_ZONE" - 11-20: Logical failure domains. + // "CLOUD_REGION" + // "MULTI_REGION_GEO" + // "MULTI_REGION_JURISDICTION" + // "GLOBAL" + // "OTHER" + LocationType string `json:"locationType,omitempty"` + // ForceSendFields is a list of field names (e.g. "Location") 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. "Location") 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 LocationAssignment) MarshalJSON() ([]byte, error) { + type NoMethod LocationAssignment + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +type LocationData struct { + BlobstoreLocation *BlobstoreLocation `json:"blobstoreLocation,omitempty"` + ChildAssetLocation *CloudAssetComposition `json:"childAssetLocation,omitempty"` + DirectLocation *DirectLocationAssignment `json:"directLocation,omitempty"` + GcpProjectProxy *TenantProjectProxy `json:"gcpProjectProxy,omitempty"` + PlacerLocation *PlacerLocation `json:"placerLocation,omitempty"` + SpannerLocation *SpannerLocation `json:"spannerLocation,omitempty"` + // ForceSendFields is a list of field names (e.g. "BlobstoreLocation") 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. "BlobstoreLocation") 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 LocationData) MarshalJSON() ([]byte, error) { + type NoMethod LocationData + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // MachineConfiguration: MachineConfiguration describes the configuration of a // machine specific to Database Resource. type MachineConfiguration struct { @@ -2642,6 +2917,30 @@ func (s PersistenceConfig) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// PlacerLocation: Message describing that the location of the customer +// resource is tied to placer allocations +type PlacerLocation struct { + // PlacerConfig: Directory with a config related to it in placer (e.g. + // "/placer/prod/home/my-root/my-dir") + PlacerConfig string `json:"placerConfig,omitempty"` + // ForceSendFields is a list of field names (e.g. "PlacerConfig") 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. "PlacerConfig") 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 PlacerLocation) MarshalJSON() ([]byte, error) { + type NoMethod PlacerLocation + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // Product: Product specification for Condor resources. type Product struct { // Engine: The specific engine that the underlying database is running. @@ -2839,6 +3138,33 @@ func (s ReconciliationOperationMetadata) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// RegionalMigDistributionPolicy: To be used for specifying the intended +// distribution of regional compute.googleapis.com/InstanceGroupManager +// instances +type RegionalMigDistributionPolicy struct { + // TargetShape: The shape in which the group converges around distribution of + // resources. Instance of proto2 enum + TargetShape int64 `json:"targetShape,omitempty"` + // Zones: Cloud zones used by regional MIG to create instances. + Zones []*ZoneConfiguration `json:"zones,omitempty"` + // ForceSendFields is a list of field names (e.g. "TargetShape") 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. "TargetShape") 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 RegionalMigDistributionPolicy) MarshalJSON() ([]byte, error) { + type NoMethod RegionalMigDistributionPolicy + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // RemoteCluster: Details of the remote cluster associated with this cluster in // a cross cluster replication setup. type RemoteCluster struct { @@ -2865,6 +3191,38 @@ func (s RemoteCluster) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +type RequirementOverride struct { + // Possible values: + // "ZI_UNSPECIFIED" + // "ZI_UNKNOWN" - To be used if tracking is not available + // "ZI_NOT_REQUIRED" + // "ZI_PREFERRED" + // "ZI_REQUIRED" + ZiOverride string `json:"ziOverride,omitempty"` + // Possible values: + // "ZS_UNSPECIFIED" + // "ZS_UNKNOWN" - To be used if tracking is not available + // "ZS_NOT_REQUIRED" + // "ZS_REQUIRED" + ZsOverride string `json:"zsOverride,omitempty"` + // ForceSendFields is a list of field names (e.g. "ZiOverride") 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. "ZiOverride") 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 RequirementOverride) MarshalJSON() ([]byte, error) { + type NoMethod RequirementOverride + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // RescheduleClusterMaintenanceRequest: Request for rescheduling a cluster // maintenance. type RescheduleClusterMaintenanceRequest struct { @@ -2965,6 +3323,30 @@ func (s RetentionSettings) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +type SpannerLocation struct { + // BackupName: Set of backups used by the resource with name in the same format + // as what is available at http://table/spanner_automon.backup_metadata + BackupName []string `json:"backupName,omitempty"` + // DbName: Set of databases used by the resource in format /span// + DbName []string `json:"dbName,omitempty"` + // ForceSendFields is a list of field names (e.g. "BackupName") 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. "BackupName") 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 SpannerLocation) MarshalJSON() ([]byte, error) { + type NoMethod SpannerLocation + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // StateInfo: Represents additional information about the state of the cluster. type StateInfo struct { // UpdateInfo: Describes ongoing update on the cluster when cluster state is @@ -3022,6 +3404,50 @@ func (s Status) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// Tags: Message type for storing tags. Tags provide a way to create +// annotations for resources, and in some cases conditionally allow or deny +// policies based on whether a resource has a specific tag. +type Tags struct { + // Tags: The Tag key/value mappings. + Tags map[string]string `json:"tags,omitempty"` + // ForceSendFields is a list of field names (e.g. "Tags") 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. "Tags") 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 Tags) MarshalJSON() ([]byte, error) { + type NoMethod Tags + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +type TenantProjectProxy struct { + ProjectNumbers []string `json:"projectNumbers,omitempty"` + // ForceSendFields is a list of field names (e.g. "ProjectNumbers") 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. "ProjectNumbers") 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 TenantProjectProxy) MarshalJSON() ([]byte, error) { + type NoMethod TenantProjectProxy + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // TimeOfDay: Represents a time of day. The date and time zone are either not // significant or are specified elsewhere. An API may choose to allow leap // seconds. Related types are google.type.Date and `google.protobuf.Timestamp`. @@ -3240,6 +3666,26 @@ func (s WeeklyMaintenanceWindow) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +type ZoneConfiguration struct { + Zone string `json:"zone,omitempty"` + // ForceSendFields is a list of field names (e.g. "Zone") 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. "Zone") 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 ZoneConfiguration) MarshalJSON() ([]byte, error) { + type NoMethod ZoneConfiguration + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // ZoneDistributionConfig: Zone distribution config for allocation of cluster // resources. type ZoneDistributionConfig struct { diff --git a/redis/v1beta1/redis-api.json b/redis/v1beta1/redis-api.json index 56333dd5c80..72a7ef28882 100644 --- a/redis/v1beta1/redis-api.json +++ b/redis/v1beta1/redis-api.json @@ -849,7 +849,7 @@ } } }, - "revision": "20240822", + "revision": "20240904", "rootUrl": "https://redis.googleapis.com/", "schemas": { "AOFConfig": { @@ -875,6 +875,42 @@ }, "type": "object" }, + "AssetLocation": { + "description": "Provides the mapping of a cloud asset to a direct physical location or to a proxy that defines the location on its behalf.", + "id": "AssetLocation", + "properties": { + "ccfeRmsPath": { + "description": "Spanner path of the CCFE RMS database. It is only applicable for CCFE tenants that use CCFE RMS for storing resource metadata.", + "type": "string" + }, + "expected": { + "$ref": "IsolationExpectations", + "description": "Defines the customer expectation around ZI/ZS for this asset and ZI/ZS state of the region at the time of asset creation." + }, + "extraParameters": { + "description": "Defines extra parameters required for specific asset types.", + "items": { + "$ref": "ExtraParameter" + }, + "type": "array" + }, + "locationData": { + "description": "Contains all kinds of physical location definitions for this asset.", + "items": { + "$ref": "LocationData" + }, + "type": "array" + }, + "parentAsset": { + "description": "Defines parents assets if any in order to allow later generation of child_asset_location data via child assets.", + "items": { + "$ref": "CloudAsset" + }, + "type": "array" + } + }, + "type": "object" + }, "AvailabilityConfiguration": { "description": "Configuration for availability of database instance", "id": "AvailabilityConfiguration", @@ -968,6 +1004,19 @@ }, "type": "object" }, + "BlobstoreLocation": { + "description": "Policy ID that identified data placement in Blobstore as per go/blobstore-user-guide#data-metadata-placement-and-failure-domains", + "id": "BlobstoreLocation", + "properties": { + "policyId": { + "items": { + "type": "string" + }, + "type": "array" + } + }, + "type": "object" + }, "CertChain": { "id": "CertChain", "properties": { @@ -995,6 +1044,30 @@ }, "type": "object" }, + "CloudAsset": { + "id": "CloudAsset", + "properties": { + "assetName": { + "type": "string" + }, + "assetType": { + "type": "string" + } + }, + "type": "object" + }, + "CloudAssetComposition": { + "id": "CloudAssetComposition", + "properties": { + "childAsset": { + "items": { + "$ref": "CloudAsset" + }, + "type": "array" + } + }, + "type": "object" + }, "Cluster": { "description": "A cluster instance.", "id": "Cluster", @@ -1822,7 +1895,7 @@ "type": "object" }, "DatabaseResourceMetadata": { - "description": "Common model for database resource instance metadata.", + "description": "Common model for database resource instance metadata. Next ID: 21", "id": "DatabaseResourceMetadata", "properties": { "availabilityConfiguration": { @@ -1961,6 +2034,10 @@ "description": "Required. Different from DatabaseResourceId.unique_id, a resource name can be reused over time. That is, after a resource named \"ABC\" is deleted, the name \"ABC\" can be used to to create a new resource within the same source. Resource name to follow CAIS resource_name format as noted here go/condor-common-datamodel", "type": "string" }, + "tagsSet": { + "$ref": "Tags", + "description": "Optional. Tags associated with this resources." + }, "updationTime": { "description": "The time at which the resource was updated and recorded at partner service.", "format": "google-datetime", @@ -2276,6 +2353,18 @@ }, "type": "object" }, + "DirectLocationAssignment": { + "id": "DirectLocationAssignment", + "properties": { + "location": { + "items": { + "$ref": "LocationAssignment" + }, + "type": "array" + } + }, + "type": "object" + }, "DiscoveryEndpoint": { "description": "Endpoints on each network, for Redis clients to connect to the cluster.", "id": "DiscoveryEndpoint", @@ -2349,6 +2438,17 @@ }, "type": "object" }, + "ExtraParameter": { + "description": "Defines parameters that should only be used for specific asset types.", + "id": "ExtraParameter", + "properties": { + "regionalMigDistributionPolicy": { + "$ref": "RegionalMigDistributionPolicy", + "description": "Details about zones used by regional compute.googleapis.com/InstanceGroupManager to create instances." + } + }, + "type": "object" + }, "FailoverInstanceRequest": { "description": "Request for Failover.", "id": "FailoverInstanceRequest", @@ -2777,6 +2877,131 @@ }, "type": "object" }, + "IsolationExpectations": { + "id": "IsolationExpectations", + "properties": { + "requirementOverride": { + "$ref": "RequirementOverride", + "description": "Explicit overrides for ZI and ZS requirements to be used for resources that should be excluded from ZI/ZS verification logic." + }, + "ziOrgPolicy": { + "enum": [ + "ZI_UNSPECIFIED", + "ZI_UNKNOWN", + "ZI_NOT_REQUIRED", + "ZI_PREFERRED", + "ZI_REQUIRED" + ], + "enumDescriptions": [ + "", + "To be used if tracking is not available", + "", + "", + "" + ], + "type": "string" + }, + "ziRegionPolicy": { + "enum": [ + "ZI_REGION_POLICY_UNSPECIFIED", + "ZI_REGION_POLICY_UNKNOWN", + "ZI_REGION_POLICY_NOT_SET", + "ZI_REGION_POLICY_FAIL_OPEN", + "ZI_REGION_POLICY_FAIL_CLOSED" + ], + "enumDescriptions": [ + "", + "To be used if tracking is not available", + "", + "", + "" + ], + "type": "string" + }, + "ziRegionState": { + "enum": [ + "ZI_REGION_UNSPECIFIED", + "ZI_REGION_UNKNOWN", + "ZI_REGION_NOT_ENABLED", + "ZI_REGION_ENABLED" + ], + "enumDescriptions": [ + "", + "To be used if tracking is not available", + "", + "" + ], + "type": "string" + }, + "zoneIsolation": { + "deprecated": true, + "description": "Deprecated: use zi_org_policy, zi_region_policy and zi_region_state instead for setting ZI expectations as per go/zicy-publish-physical-location.", + "enum": [ + "ZI_UNSPECIFIED", + "ZI_UNKNOWN", + "ZI_NOT_REQUIRED", + "ZI_PREFERRED", + "ZI_REQUIRED" + ], + "enumDescriptions": [ + "", + "To be used if tracking is not available", + "", + "", + "" + ], + "type": "string" + }, + "zoneSeparation": { + "deprecated": true, + "description": "Deprecated: use zs_org_policy, and zs_region_stateinstead for setting Zs expectations as per go/zicy-publish-physical-location.", + "enum": [ + "ZS_UNSPECIFIED", + "ZS_UNKNOWN", + "ZS_NOT_REQUIRED", + "ZS_REQUIRED" + ], + "enumDescriptions": [ + "", + "To be used if tracking is not available", + "", + "" + ], + "type": "string" + }, + "zsOrgPolicy": { + "enum": [ + "ZS_UNSPECIFIED", + "ZS_UNKNOWN", + "ZS_NOT_REQUIRED", + "ZS_REQUIRED" + ], + "enumDescriptions": [ + "", + "To be used if tracking is not available", + "", + "" + ], + "type": "string" + }, + "zsRegionState": { + "enum": [ + "ZS_REGION_UNSPECIFIED", + "ZS_REGION_UNKNOWN", + "ZS_REGION_NOT_ENABLED", + "ZS_REGION_ENABLED" + ], + "enumDescriptions": [ + "", + "To be used if tracking of the asset ZS-bit is not available", + "", + "" + ], + "type": "string" + } + }, + "type": "object" + }, "ListClustersResponse": { "description": "Response for ListClusters.", "id": "ListClustersResponse", @@ -2897,6 +3122,64 @@ }, "type": "object" }, + "LocationAssignment": { + "id": "LocationAssignment", + "properties": { + "location": { + "type": "string" + }, + "locationType": { + "enum": [ + "UNSPECIFIED", + "CLUSTER", + "POP", + "CLOUD_ZONE", + "CLOUD_REGION", + "MULTI_REGION_GEO", + "MULTI_REGION_JURISDICTION", + "GLOBAL", + "OTHER" + ], + "enumDescriptions": [ + "", + "1-10: Physical failure domains.", + "", + "11-20: Logical failure domains.", + "", + "", + "", + "", + "" + ], + "type": "string" + } + }, + "type": "object" + }, + "LocationData": { + "id": "LocationData", + "properties": { + "blobstoreLocation": { + "$ref": "BlobstoreLocation" + }, + "childAssetLocation": { + "$ref": "CloudAssetComposition" + }, + "directLocation": { + "$ref": "DirectLocationAssignment" + }, + "gcpProjectProxy": { + "$ref": "TenantProjectProxy" + }, + "placerLocation": { + "$ref": "PlacerLocation" + }, + "spannerLocation": { + "$ref": "SpannerLocation" + } + }, + "type": "object" + }, "MachineConfiguration": { "description": "MachineConfiguration describes the configuration of a machine specific to Database Resource.", "id": "MachineConfiguration", @@ -3257,6 +3540,17 @@ }, "type": "object" }, + "PlacerLocation": { + "description": "Message describing that the location of the customer resource is tied to placer allocations", + "id": "PlacerLocation", + "properties": { + "placerConfig": { + "description": "Directory with a config related to it in placer (e.g. \"/placer/prod/home/my-root/my-dir\")", + "type": "string" + } + }, + "type": "object" + }, "Product": { "description": "Product specification for Condor resources.", "id": "Product", @@ -3474,6 +3768,25 @@ }, "type": "object" }, + "RegionalMigDistributionPolicy": { + "description": "To be used for specifying the intended distribution of regional compute.googleapis.com/InstanceGroupManager instances", + "id": "RegionalMigDistributionPolicy", + "properties": { + "targetShape": { + "description": "The shape in which the group converges around distribution of resources. Instance of proto2 enum", + "format": "int32", + "type": "integer" + }, + "zones": { + "description": "Cloud zones used by regional MIG to create instances.", + "items": { + "$ref": "ZoneConfiguration" + }, + "type": "array" + } + }, + "type": "object" + }, "RemoteCluster": { "description": "Details of the remote cluster associated with this cluster in a cross cluster replication setup.", "id": "RemoteCluster", @@ -3490,6 +3803,44 @@ }, "type": "object" }, + "RequirementOverride": { + "id": "RequirementOverride", + "properties": { + "ziOverride": { + "enum": [ + "ZI_UNSPECIFIED", + "ZI_UNKNOWN", + "ZI_NOT_REQUIRED", + "ZI_PREFERRED", + "ZI_REQUIRED" + ], + "enumDescriptions": [ + "", + "To be used if tracking is not available", + "", + "", + "" + ], + "type": "string" + }, + "zsOverride": { + "enum": [ + "ZS_UNSPECIFIED", + "ZS_UNKNOWN", + "ZS_NOT_REQUIRED", + "ZS_REQUIRED" + ], + "enumDescriptions": [ + "", + "To be used if tracking is not available", + "", + "" + ], + "type": "string" + } + }, + "type": "object" + }, "RescheduleClusterMaintenanceRequest": { "description": "Request for rescheduling a cluster maintenance.", "id": "RescheduleClusterMaintenanceRequest", @@ -3574,6 +3925,26 @@ }, "type": "object" }, + "SpannerLocation": { + "id": "SpannerLocation", + "properties": { + "backupName": { + "description": "Set of backups used by the resource with name in the same format as what is available at http://table/spanner_automon.backup_metadata", + "items": { + "type": "string" + }, + "type": "array" + }, + "dbName": { + "description": "Set of databases used by the resource in format /span//", + "items": { + "type": "string" + }, + "type": "array" + } + }, + "type": "object" + }, "StateInfo": { "description": "Represents additional information about the state of the cluster.", "id": "StateInfo", @@ -3612,6 +3983,32 @@ }, "type": "object" }, + "Tags": { + "description": "Message type for storing tags. Tags provide a way to create annotations for resources, and in some cases conditionally allow or deny policies based on whether a resource has a specific tag.", + "id": "Tags", + "properties": { + "tags": { + "additionalProperties": { + "type": "string" + }, + "description": "The Tag key/value mappings.", + "type": "object" + } + }, + "type": "object" + }, + "TenantProjectProxy": { + "id": "TenantProjectProxy", + "properties": { + "projectNumbers": { + "items": { + "type": "string" + }, + "type": "array" + } + }, + "type": "object" + }, "TimeOfDay": { "description": "Represents a time of day. The date and time zone are either not significant or are specified elsewhere. An API may choose to allow leap seconds. Related types are google.type.Date and `google.protobuf.Timestamp`.", "id": "TimeOfDay", @@ -3777,6 +4174,15 @@ }, "type": "object" }, + "ZoneConfiguration": { + "id": "ZoneConfiguration", + "properties": { + "zone": { + "type": "string" + } + }, + "type": "object" + }, "ZoneDistributionConfig": { "description": "Zone distribution config for allocation of cluster resources.", "id": "ZoneDistributionConfig", diff --git a/redis/v1beta1/redis-gen.go b/redis/v1beta1/redis-gen.go index e2dc9f649e8..569e7b8074b 100644 --- a/redis/v1beta1/redis-gen.go +++ b/redis/v1beta1/redis-gen.go @@ -244,6 +244,41 @@ func (s AOFConfig) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// AssetLocation: Provides the mapping of a cloud asset to a direct physical +// location or to a proxy that defines the location on its behalf. +type AssetLocation struct { + // CcfeRmsPath: Spanner path of the CCFE RMS database. It is only applicable + // for CCFE tenants that use CCFE RMS for storing resource metadata. + CcfeRmsPath string `json:"ccfeRmsPath,omitempty"` + // Expected: Defines the customer expectation around ZI/ZS for this asset and + // ZI/ZS state of the region at the time of asset creation. + Expected *IsolationExpectations `json:"expected,omitempty"` + // ExtraParameters: Defines extra parameters required for specific asset types. + ExtraParameters []*ExtraParameter `json:"extraParameters,omitempty"` + // LocationData: Contains all kinds of physical location definitions for this + // asset. + LocationData []*LocationData `json:"locationData,omitempty"` + // ParentAsset: Defines parents assets if any in order to allow later + // generation of child_asset_location data via child assets. + ParentAsset []*CloudAsset `json:"parentAsset,omitempty"` + // ForceSendFields is a list of field names (e.g. "CcfeRmsPath") 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. "CcfeRmsPath") 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 AssetLocation) MarshalJSON() ([]byte, error) { + type NoMethod AssetLocation + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // AvailabilityConfiguration: Configuration for availability of database // instance type AvailabilityConfiguration struct { @@ -351,6 +386,28 @@ func (s BackupRun) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// BlobstoreLocation: Policy ID that identified data placement in Blobstore as +// per go/blobstore-user-guide#data-metadata-placement-and-failure-domains +type BlobstoreLocation struct { + PolicyId []string `json:"policyId,omitempty"` + // ForceSendFields is a list of field names (e.g. "PolicyId") 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. "PolicyId") 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 BlobstoreLocation) MarshalJSON() ([]byte, error) { + type NoMethod BlobstoreLocation + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + type CertChain struct { // Certificates: The certificates that form the CA chain, from leaf to root // order. @@ -402,6 +459,47 @@ func (s CertificateAuthority) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +type CloudAsset struct { + AssetName string `json:"assetName,omitempty"` + AssetType string `json:"assetType,omitempty"` + // ForceSendFields is a list of field names (e.g. "AssetName") 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. "AssetName") 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 CloudAsset) MarshalJSON() ([]byte, error) { + type NoMethod CloudAsset + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +type CloudAssetComposition struct { + ChildAsset []*CloudAsset `json:"childAsset,omitempty"` + // ForceSendFields is a list of field names (e.g. "ChildAsset") 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. "ChildAsset") 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 CloudAssetComposition) MarshalJSON() ([]byte, error) { + type NoMethod CloudAssetComposition + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // Cluster: A cluster instance. type Cluster struct { // AuthorizationMode: Optional. The authorization mode of the Redis cluster. If @@ -1151,7 +1249,7 @@ func (s DatabaseResourceId) MarshalJSON() ([]byte, error) { } // DatabaseResourceMetadata: Common model for database resource instance -// metadata. +// metadata. Next ID: 21 type DatabaseResourceMetadata struct { // AvailabilityConfiguration: Availability configuration for this instance AvailabilityConfiguration *AvailabilityConfiguration `json:"availabilityConfiguration,omitempty"` @@ -1229,6 +1327,8 @@ type DatabaseResourceMetadata struct { // the same source. Resource name to follow CAIS resource_name format as noted // here go/condor-common-datamodel ResourceName string `json:"resourceName,omitempty"` + // TagsSet: Optional. Tags associated with this resources. + TagsSet *Tags `json:"tagsSet,omitempty"` // UpdationTime: The time at which the resource was updated and recorded at // partner service. UpdationTime string `json:"updationTime,omitempty"` @@ -1504,6 +1604,26 @@ func (s DatabaseResourceRecommendationSignalData) MarshalJSON() ([]byte, error) return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +type DirectLocationAssignment struct { + Location []*LocationAssignment `json:"location,omitempty"` + // ForceSendFields is a list of field names (e.g. "Location") 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. "Location") 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 DirectLocationAssignment) MarshalJSON() ([]byte, error) { + type NoMethod DirectLocationAssignment + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // DiscoveryEndpoint: Endpoints on each network, for Redis clients to connect // to the cluster. type DiscoveryEndpoint struct { @@ -1602,6 +1722,30 @@ func (s ExportInstanceRequest) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// ExtraParameter: Defines parameters that should only be used for specific +// asset types. +type ExtraParameter struct { + // RegionalMigDistributionPolicy: Details about zones used by regional + // compute.googleapis.com/InstanceGroupManager to create instances. + RegionalMigDistributionPolicy *RegionalMigDistributionPolicy `json:"regionalMigDistributionPolicy,omitempty"` + // ForceSendFields is a list of field names (e.g. + // "RegionalMigDistributionPolicy") 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. "RegionalMigDistributionPolicy") + // 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 ExtraParameter) MarshalJSON() ([]byte, error) { + type NoMethod ExtraParameter + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // FailoverInstanceRequest: Request for Failover. type FailoverInstanceRequest struct { // DataProtectionMode: Optional. Available data protection modes that the user @@ -2065,6 +2209,81 @@ func (s InternalResourceMetadata) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +type IsolationExpectations struct { + // RequirementOverride: Explicit overrides for ZI and ZS requirements to be + // used for resources that should be excluded from ZI/ZS verification logic. + RequirementOverride *RequirementOverride `json:"requirementOverride,omitempty"` + // Possible values: + // "ZI_UNSPECIFIED" + // "ZI_UNKNOWN" - To be used if tracking is not available + // "ZI_NOT_REQUIRED" + // "ZI_PREFERRED" + // "ZI_REQUIRED" + ZiOrgPolicy string `json:"ziOrgPolicy,omitempty"` + // Possible values: + // "ZI_REGION_POLICY_UNSPECIFIED" + // "ZI_REGION_POLICY_UNKNOWN" - To be used if tracking is not available + // "ZI_REGION_POLICY_NOT_SET" + // "ZI_REGION_POLICY_FAIL_OPEN" + // "ZI_REGION_POLICY_FAIL_CLOSED" + ZiRegionPolicy string `json:"ziRegionPolicy,omitempty"` + // Possible values: + // "ZI_REGION_UNSPECIFIED" + // "ZI_REGION_UNKNOWN" - To be used if tracking is not available + // "ZI_REGION_NOT_ENABLED" + // "ZI_REGION_ENABLED" + ZiRegionState string `json:"ziRegionState,omitempty"` + // ZoneIsolation: Deprecated: use zi_org_policy, zi_region_policy and + // zi_region_state instead for setting ZI expectations as per + // go/zicy-publish-physical-location. + // + // Possible values: + // "ZI_UNSPECIFIED" + // "ZI_UNKNOWN" - To be used if tracking is not available + // "ZI_NOT_REQUIRED" + // "ZI_PREFERRED" + // "ZI_REQUIRED" + ZoneIsolation string `json:"zoneIsolation,omitempty"` + // ZoneSeparation: Deprecated: use zs_org_policy, and zs_region_stateinstead + // for setting Zs expectations as per go/zicy-publish-physical-location. + // + // Possible values: + // "ZS_UNSPECIFIED" + // "ZS_UNKNOWN" - To be used if tracking is not available + // "ZS_NOT_REQUIRED" + // "ZS_REQUIRED" + ZoneSeparation string `json:"zoneSeparation,omitempty"` + // Possible values: + // "ZS_UNSPECIFIED" + // "ZS_UNKNOWN" - To be used if tracking is not available + // "ZS_NOT_REQUIRED" + // "ZS_REQUIRED" + ZsOrgPolicy string `json:"zsOrgPolicy,omitempty"` + // Possible values: + // "ZS_REGION_UNSPECIFIED" + // "ZS_REGION_UNKNOWN" - To be used if tracking of the asset ZS-bit is not + // available + // "ZS_REGION_NOT_ENABLED" + // "ZS_REGION_ENABLED" + ZsRegionState string `json:"zsRegionState,omitempty"` + // ForceSendFields is a list of field names (e.g. "RequirementOverride") 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. "RequirementOverride") 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 IsolationExpectations) MarshalJSON() ([]byte, error) { + type NoMethod IsolationExpectations + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // ListClustersResponse: Response for ListClusters. type ListClustersResponse struct { // Clusters: A list of Redis clusters in the project in the specified location, @@ -2236,6 +2455,62 @@ func (s Location) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +type LocationAssignment struct { + Location string `json:"location,omitempty"` + // Possible values: + // "UNSPECIFIED" + // "CLUSTER" - 1-10: Physical failure domains. + // "POP" + // "CLOUD_ZONE" - 11-20: Logical failure domains. + // "CLOUD_REGION" + // "MULTI_REGION_GEO" + // "MULTI_REGION_JURISDICTION" + // "GLOBAL" + // "OTHER" + LocationType string `json:"locationType,omitempty"` + // ForceSendFields is a list of field names (e.g. "Location") 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. "Location") 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 LocationAssignment) MarshalJSON() ([]byte, error) { + type NoMethod LocationAssignment + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +type LocationData struct { + BlobstoreLocation *BlobstoreLocation `json:"blobstoreLocation,omitempty"` + ChildAssetLocation *CloudAssetComposition `json:"childAssetLocation,omitempty"` + DirectLocation *DirectLocationAssignment `json:"directLocation,omitempty"` + GcpProjectProxy *TenantProjectProxy `json:"gcpProjectProxy,omitempty"` + PlacerLocation *PlacerLocation `json:"placerLocation,omitempty"` + SpannerLocation *SpannerLocation `json:"spannerLocation,omitempty"` + // ForceSendFields is a list of field names (e.g. "BlobstoreLocation") 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. "BlobstoreLocation") 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 LocationData) MarshalJSON() ([]byte, error) { + type NoMethod LocationData + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // MachineConfiguration: MachineConfiguration describes the configuration of a // machine specific to Database Resource. type MachineConfiguration struct { @@ -2646,6 +2921,30 @@ func (s PersistenceConfig) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// PlacerLocation: Message describing that the location of the customer +// resource is tied to placer allocations +type PlacerLocation struct { + // PlacerConfig: Directory with a config related to it in placer (e.g. + // "/placer/prod/home/my-root/my-dir") + PlacerConfig string `json:"placerConfig,omitempty"` + // ForceSendFields is a list of field names (e.g. "PlacerConfig") 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. "PlacerConfig") 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 PlacerLocation) MarshalJSON() ([]byte, error) { + type NoMethod PlacerLocation + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // Product: Product specification for Condor resources. type Product struct { // Engine: The specific engine that the underlying database is running. @@ -2843,6 +3142,33 @@ func (s ReconciliationOperationMetadata) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// RegionalMigDistributionPolicy: To be used for specifying the intended +// distribution of regional compute.googleapis.com/InstanceGroupManager +// instances +type RegionalMigDistributionPolicy struct { + // TargetShape: The shape in which the group converges around distribution of + // resources. Instance of proto2 enum + TargetShape int64 `json:"targetShape,omitempty"` + // Zones: Cloud zones used by regional MIG to create instances. + Zones []*ZoneConfiguration `json:"zones,omitempty"` + // ForceSendFields is a list of field names (e.g. "TargetShape") 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. "TargetShape") 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 RegionalMigDistributionPolicy) MarshalJSON() ([]byte, error) { + type NoMethod RegionalMigDistributionPolicy + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // RemoteCluster: Details of the remote cluster associated with this cluster in // a cross cluster replication setup. type RemoteCluster struct { @@ -2869,6 +3195,38 @@ func (s RemoteCluster) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +type RequirementOverride struct { + // Possible values: + // "ZI_UNSPECIFIED" + // "ZI_UNKNOWN" - To be used if tracking is not available + // "ZI_NOT_REQUIRED" + // "ZI_PREFERRED" + // "ZI_REQUIRED" + ZiOverride string `json:"ziOverride,omitempty"` + // Possible values: + // "ZS_UNSPECIFIED" + // "ZS_UNKNOWN" - To be used if tracking is not available + // "ZS_NOT_REQUIRED" + // "ZS_REQUIRED" + ZsOverride string `json:"zsOverride,omitempty"` + // ForceSendFields is a list of field names (e.g. "ZiOverride") 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. "ZiOverride") 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 RequirementOverride) MarshalJSON() ([]byte, error) { + type NoMethod RequirementOverride + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // RescheduleClusterMaintenanceRequest: Request for rescheduling a cluster // maintenance. type RescheduleClusterMaintenanceRequest struct { @@ -2969,6 +3327,30 @@ func (s RetentionSettings) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +type SpannerLocation struct { + // BackupName: Set of backups used by the resource with name in the same format + // as what is available at http://table/spanner_automon.backup_metadata + BackupName []string `json:"backupName,omitempty"` + // DbName: Set of databases used by the resource in format /span// + DbName []string `json:"dbName,omitempty"` + // ForceSendFields is a list of field names (e.g. "BackupName") 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. "BackupName") 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 SpannerLocation) MarshalJSON() ([]byte, error) { + type NoMethod SpannerLocation + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // StateInfo: Represents additional information about the state of the cluster. type StateInfo struct { // UpdateInfo: Describes ongoing update on the cluster when cluster state is @@ -3026,6 +3408,50 @@ func (s Status) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// Tags: Message type for storing tags. Tags provide a way to create +// annotations for resources, and in some cases conditionally allow or deny +// policies based on whether a resource has a specific tag. +type Tags struct { + // Tags: The Tag key/value mappings. + Tags map[string]string `json:"tags,omitempty"` + // ForceSendFields is a list of field names (e.g. "Tags") 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. "Tags") 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 Tags) MarshalJSON() ([]byte, error) { + type NoMethod Tags + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +type TenantProjectProxy struct { + ProjectNumbers []string `json:"projectNumbers,omitempty"` + // ForceSendFields is a list of field names (e.g. "ProjectNumbers") 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. "ProjectNumbers") 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 TenantProjectProxy) MarshalJSON() ([]byte, error) { + type NoMethod TenantProjectProxy + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // TimeOfDay: Represents a time of day. The date and time zone are either not // significant or are specified elsewhere. An API may choose to allow leap // seconds. Related types are google.type.Date and `google.protobuf.Timestamp`. @@ -3244,6 +3670,26 @@ func (s WeeklyMaintenanceWindow) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +type ZoneConfiguration struct { + Zone string `json:"zone,omitempty"` + // ForceSendFields is a list of field names (e.g. "Zone") 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. "Zone") 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 ZoneConfiguration) MarshalJSON() ([]byte, error) { + type NoMethod ZoneConfiguration + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // ZoneDistributionConfig: Zone distribution config for allocation of cluster // resources. type ZoneDistributionConfig struct { diff --git a/run/v2/run-api.json b/run/v2/run-api.json index e0e56ee98e2..fa2fdb3c20f 100644 --- a/run/v2/run-api.json +++ b/run/v2/run-api.json @@ -1526,7 +1526,7 @@ } } }, - "revision": "20240823", + "revision": "20240831", "rootUrl": "https://run.googleapis.com/", "schemas": { "GoogleCloudRunV2BinaryAuthorization": { @@ -2984,7 +2984,7 @@ "id": "GoogleCloudRunV2RevisionScaling", "properties": { "maxInstanceCount": { - "description": "Optional. Maximum number of serving instances that this resource should have.", + "description": "Optional. Maximum number of serving instances that this resource should have. When unspecified, the field is set to the server default value of 100. For more information see https://cloud.google.com/run/docs/configuring/max-instances", "format": "int32", "type": "integer" }, @@ -3468,6 +3468,10 @@ "description": "URI of the base builder image in Artifact Registry being used in the build. Used to opt into automatic base image updates.", "type": "string" }, + "baseImageWarning": { + "description": "Warning message for the base image.", + "type": "string" + }, "buildOperation": { "$ref": "GoogleLongrunningOperation", "description": "Cloud Build operation to be polled via CloudBuild API." diff --git a/run/v2/run-gen.go b/run/v2/run-gen.go index 2c145f3da72..3ecf0c3a4ab 100644 --- a/run/v2/run-gen.go +++ b/run/v2/run-gen.go @@ -1909,7 +1909,9 @@ func (s GoogleCloudRunV2Revision) MarshalJSON() ([]byte, error) { // settings. type GoogleCloudRunV2RevisionScaling struct { // MaxInstanceCount: Optional. Maximum number of serving instances that this - // resource should have. + // resource should have. When unspecified, the field is set to the server + // default value of 100. For more information see + // https://cloud.google.com/run/docs/configuring/max-instances MaxInstanceCount int64 `json:"maxInstanceCount,omitempty"` // MinInstanceCount: Optional. Minimum number of serving instances that this // resource should have. @@ -2489,6 +2491,8 @@ type GoogleCloudRunV2SubmitBuildResponse struct { // BaseImageUri: URI of the base builder image in Artifact Registry being used // in the build. Used to opt into automatic base image updates. BaseImageUri string `json:"baseImageUri,omitempty"` + // BaseImageWarning: Warning message for the base image. + BaseImageWarning string `json:"baseImageWarning,omitempty"` // BuildOperation: Cloud Build operation to be polled via CloudBuild API. BuildOperation *GoogleLongrunningOperation `json:"buildOperation,omitempty"` diff --git a/servicenetworking/v1/servicenetworking-api.json b/servicenetworking/v1/servicenetworking-api.json index 196f7adf294..817b59f7525 100644 --- a/servicenetworking/v1/servicenetworking-api.json +++ b/servicenetworking/v1/servicenetworking-api.json @@ -1029,7 +1029,7 @@ } } }, - "revision": "20240825", + "revision": "20240901", "rootUrl": "https://servicenetworking.googleapis.com/", "schemas": { "AddDnsRecordSetMetadata": { @@ -3253,7 +3253,7 @@ "type": "string" }, "role": { - "description": "Required. Role to apply. Only allowlisted roles can be used at the specified granularity. The role must be one of the following: - 'roles/container.hostServiceAgentUser' applied on the shared VPC host project - 'roles/compute.securityAdmin' applied on the shared VPC host project - 'roles/compute.networkAdmin' applied on the shared VPC host project - 'roles/tpu.xpnAgent' applied on the shared VPC host project - 'roles/dns.admin' applied on the shared VPC host project - 'roles/logging.admin' applied on the shared VPC host project - 'roles/monitoring.viewer' applied on the shared VPC host project", + "description": "Required. Role to apply. Only allowlisted roles can be used at the specified granularity. The role must be one of the following: - 'roles/container.hostServiceAgentUser' applied on the shared VPC host project - 'roles/compute.securityAdmin' applied on the shared VPC host project - 'roles/compute.networkAdmin' applied on the shared VPC host project - 'roles/tpu.xpnAgent' applied on the shared VPC host project - 'roles/dns.admin' applied on the shared VPC host project - 'roles/logging.admin' applied on the shared VPC host project - 'roles/monitoring.viewer' applied on the shared VPC host project - 'roles/servicemanagement.quotaViewer' applied on the shared VPC host project", "type": "string" } }, diff --git a/servicenetworking/v1/servicenetworking-gen.go b/servicenetworking/v1/servicenetworking-gen.go index 84d0454f46b..01c27cb6eec 100644 --- a/servicenetworking/v1/servicenetworking-gen.go +++ b/servicenetworking/v1/servicenetworking-gen.go @@ -3707,7 +3707,8 @@ type PolicyBinding struct { // project - 'roles/tpu.xpnAgent' applied on the shared VPC host project - // 'roles/dns.admin' applied on the shared VPC host project - // 'roles/logging.admin' applied on the shared VPC host project - - // 'roles/monitoring.viewer' applied on the shared VPC host project + // 'roles/monitoring.viewer' applied on the shared VPC host project - + // 'roles/servicemanagement.quotaViewer' applied on the shared VPC host project Role string `json:"role,omitempty"` // ForceSendFields is a list of field names (e.g. "Member") to unconditionally // include in API requests. By default, fields with empty or default values are diff --git a/servicenetworking/v1beta/servicenetworking-api.json b/servicenetworking/v1beta/servicenetworking-api.json index df63291f544..0c0f132fd17 100644 --- a/servicenetworking/v1beta/servicenetworking-api.json +++ b/servicenetworking/v1beta/servicenetworking-api.json @@ -307,7 +307,7 @@ } } }, - "revision": "20240825", + "revision": "20240901", "rootUrl": "https://servicenetworking.googleapis.com/", "schemas": { "AddDnsRecordSetMetadata": { @@ -2273,7 +2273,7 @@ "type": "string" }, "role": { - "description": "Required. Role to apply. Only allowlisted roles can be used at the specified granularity. The role must be one of the following: - 'roles/container.hostServiceAgentUser' applied on the shared VPC host project - 'roles/compute.securityAdmin' applied on the shared VPC host project - 'roles/compute.networkAdmin' applied on the shared VPC host project - 'roles/tpu.xpnAgent' applied on the shared VPC host project - 'roles/dns.admin' applied on the shared VPC host project - 'roles/logging.admin' applied on the shared VPC host project - 'roles/monitoring.viewer' applied on the shared VPC host project", + "description": "Required. Role to apply. Only allowlisted roles can be used at the specified granularity. The role must be one of the following: - 'roles/container.hostServiceAgentUser' applied on the shared VPC host project - 'roles/compute.securityAdmin' applied on the shared VPC host project - 'roles/compute.networkAdmin' applied on the shared VPC host project - 'roles/tpu.xpnAgent' applied on the shared VPC host project - 'roles/dns.admin' applied on the shared VPC host project - 'roles/logging.admin' applied on the shared VPC host project - 'roles/monitoring.viewer' applied on the shared VPC host project - 'roles/servicemanagement.quotaViewer' applied on the shared VPC host project", "type": "string" } }, diff --git a/servicenetworking/v1beta/servicenetworking-gen.go b/servicenetworking/v1beta/servicenetworking-gen.go index d2f0b2adf3f..0347f58348e 100644 --- a/servicenetworking/v1beta/servicenetworking-gen.go +++ b/servicenetworking/v1beta/servicenetworking-gen.go @@ -3159,7 +3159,8 @@ type PolicyBinding struct { // project - 'roles/tpu.xpnAgent' applied on the shared VPC host project - // 'roles/dns.admin' applied on the shared VPC host project - // 'roles/logging.admin' applied on the shared VPC host project - - // 'roles/monitoring.viewer' applied on the shared VPC host project + // 'roles/monitoring.viewer' applied on the shared VPC host project - + // 'roles/servicemanagement.quotaViewer' applied on the shared VPC host project Role string `json:"role,omitempty"` // ForceSendFields is a list of field names (e.g. "Member") to unconditionally // include in API requests. By default, fields with empty or default values are diff --git a/spanner/v1/spanner-api.json b/spanner/v1/spanner-api.json index e1852a77879..42ec5bc5a45 100644 --- a/spanner/v1/spanner-api.json +++ b/spanner/v1/spanner-api.json @@ -27,6 +27,11 @@ "endpointUrl": "https://spanner.me-central2.rep.googleapis.com/", "location": "me-central2" }, + { + "description": "Regional Endpoint", + "endpointUrl": "https://spanner.us-east1.rep.googleapis.com/", + "location": "us-east1" + }, { "description": "Regional Endpoint", "endpointUrl": "https://spanner.us-west1.rep.googleapis.com/", @@ -3259,7 +3264,7 @@ } } }, - "revision": "20240814", + "revision": "20240831", "rootUrl": "https://spanner.googleapis.com/", "schemas": { "AutoscalingConfig": { diff --git a/sqladmin/v1/sqladmin-api.json b/sqladmin/v1/sqladmin-api.json index 70f6fa68eba..f93ffccf6ab 100644 --- a/sqladmin/v1/sqladmin-api.json +++ b/sqladmin/v1/sqladmin-api.json @@ -608,6 +608,73 @@ }, "instances": { "methods": { + "ListServerCertificates": { + "description": "Lists all versions of server certificates and certificate authorities (CAs) for the specified instance. There can be up to three sets of certs listed: the certificate that is currently in use, a future that has been added but not yet used to sign a certificate, and a certificate that has been rotated out.", + "flatPath": "v1/projects/{project}/instances/{instance}/listServerCertificates", + "httpMethod": "GET", + "id": "sql.instances.ListServerCertificates", + "parameterOrder": [ + "project", + "instance" + ], + "parameters": { + "instance": { + "description": "Required. Cloud SQL instance ID. This does not include the project ID.", + "location": "path", + "required": true, + "type": "string" + }, + "project": { + "description": "Required. Project ID of the project that contains the instance.", + "location": "path", + "required": true, + "type": "string" + } + }, + "path": "v1/projects/{project}/instances/{instance}/listServerCertificates", + "response": { + "$ref": "InstancesListServerCertificatesResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform", + "https://www.googleapis.com/auth/sqlservice.admin" + ] + }, + "RotateServerCertificate": { + "description": "Rotates the server certificate version to one previously added with the addServerCertificate method. For instances not using Certificate Authority Service (CAS) server CA, please use RotateServerCa instead.", + "flatPath": "v1/projects/{project}/instances/{instance}/rotateServerCertificate", + "httpMethod": "POST", + "id": "sql.instances.RotateServerCertificate", + "parameterOrder": [ + "project", + "instance" + ], + "parameters": { + "instance": { + "description": "Required. Cloud SQL instance ID. This does not include the project ID.", + "location": "path", + "required": true, + "type": "string" + }, + "project": { + "description": "Required. Project ID of the project that contains the instance.", + "location": "path", + "required": true, + "type": "string" + } + }, + "path": "v1/projects/{project}/instances/{instance}/rotateServerCertificate", + "request": { + "$ref": "InstancesRotateServerCertificateRequest" + }, + "response": { + "$ref": "Operation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform", + "https://www.googleapis.com/auth/sqlservice.admin" + ] + }, "acquireSsrsLease": { "description": "Acquire a lease for the setup of SQL Server Reporting Services (SSRS).", "flatPath": "v1/projects/{project}/instances/{instance}/acquireSsrsLease", @@ -675,6 +742,38 @@ "https://www.googleapis.com/auth/sqlservice.admin" ] }, + "addServerCertificate": { + "description": "Add a new trusted server certificate version for the specified instance using Certificate Authority Service (CAS) server CA. Required to prepare for a certificate rotation. If a server certificate version was previously added but never used in a certificate rotation, this operation replaces that version. There cannot be more than one certificate version waiting to be rotated in. For instances not using CAS server CA, please use AddServerCa instead.", + "flatPath": "v1/projects/{project}/instances/{instance}/addServerCertificate", + "httpMethod": "POST", + "id": "sql.instances.addServerCertificate", + "parameterOrder": [ + "project", + "instance" + ], + "parameters": { + "instance": { + "description": "Cloud SQL instance ID. This does not include the project ID.", + "location": "path", + "required": true, + "type": "string" + }, + "project": { + "description": "Project ID of the project that contains the instance.", + "location": "path", + "required": true, + "type": "string" + } + }, + "path": "v1/projects/{project}/instances/{instance}/addServerCertificate", + "response": { + "$ref": "Operation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform", + "https://www.googleapis.com/auth/sqlservice.admin" + ] + }, "clone": { "description": "Creates a Cloud SQL instance as a clone of the source instance. Using this operation might cause your instance to restart.", "flatPath": "v1/projects/{project}/instances/{instance}/clone", @@ -2267,7 +2366,7 @@ } } }, - "revision": "20240829", + "revision": "20240831", "rootUrl": "https://sqladmin.googleapis.com/", "schemas": { "AclEntry": { @@ -4454,6 +4553,35 @@ }, "type": "object" }, + "InstancesListServerCertificatesResponse": { + "description": "Instances ListServerCertificates response.", + "id": "InstancesListServerCertificatesResponse", + "properties": { + "activeVersion": { + "description": "The `sha1_fingerprint` of the active certificate from `server_certs`.", + "type": "string" + }, + "caCerts": { + "description": "List of server CA certificates for the instance.", + "items": { + "$ref": "SslCert" + }, + "type": "array" + }, + "kind": { + "description": "This is always `sql#instancesListServerCertificates`.", + "type": "string" + }, + "serverCerts": { + "description": "List of server certificates for the instance, signed by the corresponding CA from the `ca_certs` list.", + "items": { + "$ref": "SslCert" + }, + "type": "array" + } + }, + "type": "object" + }, "InstancesReencryptRequest": { "description": "Database Instance reencrypt request.", "id": "InstancesReencryptRequest", @@ -4487,6 +4615,17 @@ }, "type": "object" }, + "InstancesRotateServerCertificateRequest": { + "description": "Rotate server certificate request.", + "id": "InstancesRotateServerCertificateRequest", + "properties": { + "rotateServerCertificateContext": { + "$ref": "RotateServerCertificateContext", + "description": "Optional. Contains details about the rotate server certificate operation." + } + }, + "type": "object" + }, "InstancesTruncateLogRequest": { "description": "Instance truncate log request.", "id": "InstancesTruncateLogRequest", @@ -5314,6 +5453,21 @@ }, "type": "object" }, + "RotateServerCertificateContext": { + "description": "Instance rotate server certificate context.", + "id": "RotateServerCertificateContext", + "properties": { + "kind": { + "description": "Optional. This is always `sql#rotateServerCertificateContext`.", + "type": "string" + }, + "nextVersion": { + "description": "The fingerprint of the next version to be rotated to. If left unspecified, will be rotated to the most recently added server certificate version.", + "type": "string" + } + }, + "type": "object" + }, "Settings": { "description": "Database instance settings.", "id": "Settings", @@ -5642,7 +5796,8 @@ "EXTENSIONS_NOT_ENABLED_IN_REPLICA", "UNSUPPORTED_COLUMNS", "USERS_NOT_CREATED_IN_REPLICA", - "UNSUPPORTED_SYSTEM_OBJECTS" + "UNSUPPORTED_SYSTEM_OBJECTS", + "UNSUPPORTED_TABLES_WITH_REPLICA_IDENTITY" ], "enumDescriptions": [ "", @@ -5665,7 +5820,7 @@ "The primary instance database parameter setup doesn't allow EM sync.", "The gtid_mode is not supported, applicable for MySQL.", "SQL Server Agent is not running.", - "The table definition is not support due to missing primary key or replica identity, applicable for postgres.", + "The table definition is not support due to missing primary key or replica identity, applicable for postgres. Note that this is a warning and won't block the migration.", "The customer has a definer that will break EM setup.", "SQL Server @@SERVERNAME does not match actual host name.", "The primary instance has been setup and will fail the setup.", @@ -5696,7 +5851,8 @@ "This error message indicates that the specified extensions are not enabled on destination instance. For example, before you can migrate data to the destination instance, you must enable the PGAudit extension on the instance.", "The source database has generated columns that can't be migrated. Please change them to regular columns before migration.", "The source database has users that aren't created in the replica. First, create all users, which are in the pg_user_mappings table of the source database, in the destination instance. Then, perform the migration.", - "The selected objects include system objects that aren't supported for migration." + "The selected objects include system objects that aren't supported for migration.", + "The source database has tables with the FULL or NOTHING replica identity. Before starting your migration, either remove the identity or change it to DEFAULT. Note that this is an error and will block the migration." ], "type": "string" } diff --git a/sqladmin/v1/sqladmin-gen.go b/sqladmin/v1/sqladmin-gen.go index 00dfa738556..74049715943 100644 --- a/sqladmin/v1/sqladmin-gen.go +++ b/sqladmin/v1/sqladmin-gen.go @@ -2598,6 +2598,40 @@ func (s InstancesListServerCasResponse) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// InstancesListServerCertificatesResponse: Instances ListServerCertificates +// response. +type InstancesListServerCertificatesResponse struct { + // ActiveVersion: The `sha1_fingerprint` of the active certificate from + // `server_certs`. + ActiveVersion string `json:"activeVersion,omitempty"` + // CaCerts: List of server CA certificates for the instance. + CaCerts []*SslCert `json:"caCerts,omitempty"` + // Kind: This is always `sql#instancesListServerCertificates`. + Kind string `json:"kind,omitempty"` + // ServerCerts: List of server certificates for the instance, signed by the + // corresponding CA from the `ca_certs` list. + ServerCerts []*SslCert `json:"serverCerts,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the server. + googleapi.ServerResponse `json:"-"` + // ForceSendFields is a list of field names (e.g. "ActiveVersion") 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. "ActiveVersion") 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 InstancesListServerCertificatesResponse) MarshalJSON() ([]byte, error) { + type NoMethod InstancesListServerCertificatesResponse + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // InstancesReencryptRequest: Database Instance reencrypt request. type InstancesReencryptRequest struct { // BackupReencryptionConfig: Configuration specific to backup re-encryption @@ -2666,6 +2700,30 @@ func (s InstancesRotateServerCaRequest) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// InstancesRotateServerCertificateRequest: Rotate server certificate request. +type InstancesRotateServerCertificateRequest struct { + // RotateServerCertificateContext: Optional. Contains details about the rotate + // server certificate operation. + RotateServerCertificateContext *RotateServerCertificateContext `json:"rotateServerCertificateContext,omitempty"` + // ForceSendFields is a list of field names (e.g. + // "RotateServerCertificateContext") 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. "RotateServerCertificateContext") + // 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 InstancesRotateServerCertificateRequest) MarshalJSON() ([]byte, error) { + type NoMethod InstancesRotateServerCertificateRequest + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // InstancesTruncateLogRequest: Instance truncate log request. type InstancesTruncateLogRequest struct { // TruncateLogContext: Contains details about the truncate log operation. @@ -3584,6 +3642,32 @@ func (s RotateServerCaContext) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// RotateServerCertificateContext: Instance rotate server certificate context. +type RotateServerCertificateContext struct { + // Kind: Optional. This is always `sql#rotateServerCertificateContext`. + Kind string `json:"kind,omitempty"` + // NextVersion: The fingerprint of the next version to be rotated to. If left + // unspecified, will be rotated to the most recently added server certificate + // version. + NextVersion string `json:"nextVersion,omitempty"` + // ForceSendFields is a list of field names (e.g. "Kind") 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. "Kind") 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 RotateServerCertificateContext) MarshalJSON() ([]byte, error) { + type NoMethod RotateServerCertificateContext + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // Settings: Database instance settings. type Settings struct { // ActivationPolicy: The activation policy specifies when the instance is @@ -3841,7 +3925,8 @@ type SqlExternalSyncSettingError struct { // MySQL. // "SQLSERVER_AGENT_NOT_RUNNING" - SQL Server Agent is not running. // "UNSUPPORTED_TABLE_DEFINITION" - The table definition is not support due - // to missing primary key or replica identity, applicable for postgres. + // to missing primary key or replica identity, applicable for postgres. Note + // that this is a warning and won't block the migration. // "UNSUPPORTED_DEFINER" - The customer has a definer that will break EM // setup. // "SQLSERVER_SERVERNAME_MISMATCH" - SQL Server @@SERVERNAME does not match @@ -3913,6 +3998,10 @@ type SqlExternalSyncSettingError struct { // Then, perform the migration. // "UNSUPPORTED_SYSTEM_OBJECTS" - The selected objects include system objects // that aren't supported for migration. + // "UNSUPPORTED_TABLES_WITH_REPLICA_IDENTITY" - The source database has + // tables with the FULL or NOTHING replica identity. Before starting your + // migration, either remove the identity or change it to DEFAULT. Note that + // this is an error and will block the migration. Type string `json:"type,omitempty"` // ForceSendFields is a list of field names (e.g. "Detail") to unconditionally // include in API requests. By default, fields with empty or default values are @@ -6253,6 +6342,230 @@ func (c *FlagsListCall) Do(opts ...googleapi.CallOption) (*FlagsListResponse, er return ret, nil } +type InstancesListServerCertificatesCall struct { + s *Service + project string + instance string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// ListServerCertificates: Lists all versions of server certificates and +// certificate authorities (CAs) for the specified instance. There can be up to +// three sets of certs listed: the certificate that is currently in use, a +// future that has been added but not yet used to sign a certificate, and a +// certificate that has been rotated out. +// +// - instance: Cloud SQL instance ID. This does not include the project ID. +// - project: Project ID of the project that contains the instance. +func (r *InstancesService) ListServerCertificates(project string, instance string) *InstancesListServerCertificatesCall { + c := &InstancesListServerCertificatesCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.project = project + c.instance = instance + 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 *InstancesListServerCertificatesCall) Fields(s ...googleapi.Field) *InstancesListServerCertificatesCall { + 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 *InstancesListServerCertificatesCall) IfNoneMatch(entityTag string) *InstancesListServerCertificatesCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *InstancesListServerCertificatesCall) Context(ctx context.Context) *InstancesListServerCertificatesCall { + 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 *InstancesListServerCertificatesCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *InstancesListServerCertificatesCall) 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/projects/{project}/instances/{instance}/listServerCertificates") + 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{ + "project": c.project, + "instance": c.instance, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "sql.instances.ListServerCertificates" call. +// Any non-2xx status code is an error. Response headers are in either +// *InstancesListServerCertificatesResponse.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 *InstancesListServerCertificatesCall) Do(opts ...googleapi.CallOption) (*InstancesListServerCertificatesResponse, 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 := &InstancesListServerCertificatesResponse{ + 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 InstancesRotateServerCertificateCall struct { + s *Service + project string + instance string + instancesrotateservercertificaterequest *InstancesRotateServerCertificateRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// RotateServerCertificate: Rotates the server certificate version to one +// previously added with the addServerCertificate method. For instances not +// using Certificate Authority Service (CAS) server CA, please use +// RotateServerCa instead. +// +// - instance: Cloud SQL instance ID. This does not include the project ID. +// - project: Project ID of the project that contains the instance. +func (r *InstancesService) RotateServerCertificate(project string, instance string, instancesrotateservercertificaterequest *InstancesRotateServerCertificateRequest) *InstancesRotateServerCertificateCall { + c := &InstancesRotateServerCertificateCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.project = project + c.instance = instance + c.instancesrotateservercertificaterequest = instancesrotateservercertificaterequest + 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 *InstancesRotateServerCertificateCall) Fields(s ...googleapi.Field) *InstancesRotateServerCertificateCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *InstancesRotateServerCertificateCall) Context(ctx context.Context) *InstancesRotateServerCertificateCall { + 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 *InstancesRotateServerCertificateCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *InstancesRotateServerCertificateCall) 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.instancesrotateservercertificaterequest) + if err != nil { + return nil, err + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1/projects/{project}/instances/{instance}/rotateServerCertificate") + 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{ + "project": c.project, + "instance": c.instance, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "sql.instances.RotateServerCertificate" 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 *InstancesRotateServerCertificateCall) 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 InstancesAcquireSsrsLeaseCall struct { s *Service project string @@ -6469,6 +6782,111 @@ func (c *InstancesAddServerCaCall) Do(opts ...googleapi.CallOption) (*Operation, return ret, nil } +type InstancesAddServerCertificateCall struct { + s *Service + project string + instance string + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// AddServerCertificate: Add a new trusted server certificate version for the +// specified instance using Certificate Authority Service (CAS) server CA. +// Required to prepare for a certificate rotation. If a server certificate +// version was previously added but never used in a certificate rotation, this +// operation replaces that version. There cannot be more than one certificate +// version waiting to be rotated in. For instances not using CAS server CA, +// please use AddServerCa instead. +// +// - instance: Cloud SQL instance ID. This does not include the project ID. +// - project: Project ID of the project that contains the instance. +func (r *InstancesService) AddServerCertificate(project string, instance string) *InstancesAddServerCertificateCall { + c := &InstancesAddServerCertificateCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.project = project + c.instance = instance + 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 *InstancesAddServerCertificateCall) Fields(s ...googleapi.Field) *InstancesAddServerCertificateCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *InstancesAddServerCertificateCall) Context(ctx context.Context) *InstancesAddServerCertificateCall { + 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 *InstancesAddServerCertificateCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *InstancesAddServerCertificateCall) 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/projects/{project}/instances/{instance}/addServerCertificate") + 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{ + "project": c.project, + "instance": c.instance, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "sql.instances.addServerCertificate" 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 *InstancesAddServerCertificateCall) 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 InstancesCloneCall struct { s *Service project string diff --git a/sqladmin/v1beta4/sqladmin-api.json b/sqladmin/v1beta4/sqladmin-api.json index 027c9bd4cfb..06a4d32eb1b 100644 --- a/sqladmin/v1beta4/sqladmin-api.json +++ b/sqladmin/v1beta4/sqladmin-api.json @@ -608,6 +608,73 @@ }, "instances": { "methods": { + "ListServerCertificates": { + "description": "Lists all versions of server certificates and certificate authorities (CAs) for the specified instance. There can be up to three sets of certs listed: the certificate that is currently in use, a future that has been added but not yet used to sign a certificate, and a certificate that has been rotated out.", + "flatPath": "sql/v1beta4/projects/{project}/instances/{instance}/listServerCertificates", + "httpMethod": "GET", + "id": "sql.instances.ListServerCertificates", + "parameterOrder": [ + "project", + "instance" + ], + "parameters": { + "instance": { + "description": "Required. Cloud SQL instance ID. This does not include the project ID.", + "location": "path", + "required": true, + "type": "string" + }, + "project": { + "description": "Required. Project ID of the project that contains the instance.", + "location": "path", + "required": true, + "type": "string" + } + }, + "path": "sql/v1beta4/projects/{project}/instances/{instance}/listServerCertificates", + "response": { + "$ref": "InstancesListServerCertificatesResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform", + "https://www.googleapis.com/auth/sqlservice.admin" + ] + }, + "RotateServerCertificate": { + "description": "Rotates the server certificate version to one previously added with the addServerCertificate method. For instances not using Certificate Authority Service (CAS) server CA, please use RotateServerCa instead.", + "flatPath": "sql/v1beta4/projects/{project}/instances/{instance}/rotateServerCertificate", + "httpMethod": "POST", + "id": "sql.instances.RotateServerCertificate", + "parameterOrder": [ + "project", + "instance" + ], + "parameters": { + "instance": { + "description": "Required. Cloud SQL instance ID. This does not include the project ID.", + "location": "path", + "required": true, + "type": "string" + }, + "project": { + "description": "Required. Project ID of the project that contains the instance.", + "location": "path", + "required": true, + "type": "string" + } + }, + "path": "sql/v1beta4/projects/{project}/instances/{instance}/rotateServerCertificate", + "request": { + "$ref": "InstancesRotateServerCertificateRequest" + }, + "response": { + "$ref": "Operation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform", + "https://www.googleapis.com/auth/sqlservice.admin" + ] + }, "acquireSsrsLease": { "description": "Acquire a lease for the setup of SQL Server Reporting Services (SSRS).", "flatPath": "sql/v1beta4/projects/{project}/instances/{instance}/acquireSsrsLease", @@ -675,6 +742,38 @@ "https://www.googleapis.com/auth/sqlservice.admin" ] }, + "addServerCertificate": { + "description": "Add a new trusted server certificate version for the specified instance using Certificate Authority Service (CAS) server CA. Required to prepare for a certificate rotation. If a server certificate version was previously added but never used in a certificate rotation, this operation replaces that version. There cannot be more than one certificate version waiting to be rotated in. For instances not using CAS server CA, please use AddServerCa instead.", + "flatPath": "sql/v1beta4/projects/{project}/instances/{instance}/addServerCertificate", + "httpMethod": "POST", + "id": "sql.instances.addServerCertificate", + "parameterOrder": [ + "project", + "instance" + ], + "parameters": { + "instance": { + "description": "Required. Cloud SQL instance ID. This does not include the project ID.", + "location": "path", + "required": true, + "type": "string" + }, + "project": { + "description": "Required. Project ID of the project that contains the instance.", + "location": "path", + "required": true, + "type": "string" + } + }, + "path": "sql/v1beta4/projects/{project}/instances/{instance}/addServerCertificate", + "response": { + "$ref": "Operation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform", + "https://www.googleapis.com/auth/sqlservice.admin" + ] + }, "clone": { "description": "Creates a Cloud SQL instance as a clone of the source instance. Using this operation might cause your instance to restart.", "flatPath": "sql/v1beta4/projects/{project}/instances/{instance}/clone", @@ -2267,7 +2366,7 @@ } } }, - "revision": "20240829", + "revision": "20240831", "rootUrl": "https://sqladmin.googleapis.com/", "schemas": { "AclEntry": { @@ -4455,6 +4554,35 @@ }, "type": "object" }, + "InstancesListServerCertificatesResponse": { + "description": "Instances ListServerCertificatess response.", + "id": "InstancesListServerCertificatesResponse", + "properties": { + "activeVersion": { + "description": "The `sha1_fingerprint` of the active certificate from `server_certs`.", + "type": "string" + }, + "caCerts": { + "description": "List of server CA certificates for the instance.", + "items": { + "$ref": "SslCert" + }, + "type": "array" + }, + "kind": { + "description": "This is always `sql#instancesListServerCertificates`.", + "type": "string" + }, + "serverCerts": { + "description": "List of server certificates for the instance, signed by the corresponding CA from the `ca_certs` list.", + "items": { + "$ref": "SslCert" + }, + "type": "array" + } + }, + "type": "object" + }, "InstancesReencryptRequest": { "description": "Database Instance reencrypt request.", "id": "InstancesReencryptRequest", @@ -4488,6 +4616,17 @@ }, "type": "object" }, + "InstancesRotateServerCertificateRequest": { + "description": "Rotate Server Certificate request.", + "id": "InstancesRotateServerCertificateRequest", + "properties": { + "rotateServerCertificateContext": { + "$ref": "RotateServerCertificateContext", + "description": "Optional. Contains details about the rotate server CA operation." + } + }, + "type": "object" + }, "InstancesTruncateLogRequest": { "description": "Instance truncate log request.", "id": "InstancesTruncateLogRequest", @@ -5315,6 +5454,21 @@ }, "type": "object" }, + "RotateServerCertificateContext": { + "description": "Instance rotate server certificate context.", + "id": "RotateServerCertificateContext", + "properties": { + "kind": { + "description": "Optional. This is always `sql#rotateServerCertificateContext`.", + "type": "string" + }, + "nextVersion": { + "description": "Optional. The fingerprint of the next version to be rotated to. If left unspecified, will be rotated to the most recently added server certificate version.", + "type": "string" + } + }, + "type": "object" + }, "Settings": { "description": "Database instance settings.", "id": "Settings", @@ -5643,7 +5797,8 @@ "EXTENSIONS_NOT_ENABLED_IN_REPLICA", "UNSUPPORTED_COLUMNS", "USERS_NOT_CREATED_IN_REPLICA", - "UNSUPPORTED_SYSTEM_OBJECTS" + "UNSUPPORTED_SYSTEM_OBJECTS", + "UNSUPPORTED_TABLES_WITH_REPLICA_IDENTITY" ], "enumDescriptions": [ "", @@ -5666,7 +5821,7 @@ "The primary instance database parameter setup doesn't allow EM sync.", "The gtid_mode is not supported, applicable for MySQL.", "SQL Server Agent is not running.", - "The table definition is not support due to missing primary key or replica identity, applicable for postgres.", + "The table definition is not support due to missing primary key or replica identity, applicable for postgres. Note that this is a warning and won't block the migration.", "The customer has a definer that will break EM setup.", "SQL Server @@SERVERNAME does not match actual host name.", "The primary instance has been setup and will fail the setup.", @@ -5697,7 +5852,8 @@ "This error message indicates that the specified extensions are not enabled on destination instance. For example, before you can migrate data to the destination instance, you must enable the PGAudit extension on the instance.", "The source database has generated columns that can't be migrated. Please change them to regular columns before migration.", "The source database has users that aren't created in the replica. First, create all users, which are in the pg_user_mappings table of the source database, in the destination instance. Then, perform the migration.", - "The selected objects include system objects that aren't supported for migration." + "The selected objects include system objects that aren't supported for migration.", + "The source database has tables with the FULL or NOTHING replica identity. Before starting your migration, either remove the identity or change it to DEFAULT. Note that this is an error and will block the migration." ], "type": "string" } diff --git a/sqladmin/v1beta4/sqladmin-gen.go b/sqladmin/v1beta4/sqladmin-gen.go index f2d180faff0..8f9f8090c73 100644 --- a/sqladmin/v1beta4/sqladmin-gen.go +++ b/sqladmin/v1beta4/sqladmin-gen.go @@ -2603,6 +2603,40 @@ func (s InstancesListServerCasResponse) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// InstancesListServerCertificatesResponse: Instances ListServerCertificatess +// response. +type InstancesListServerCertificatesResponse struct { + // ActiveVersion: The `sha1_fingerprint` of the active certificate from + // `server_certs`. + ActiveVersion string `json:"activeVersion,omitempty"` + // CaCerts: List of server CA certificates for the instance. + CaCerts []*SslCert `json:"caCerts,omitempty"` + // Kind: This is always `sql#instancesListServerCertificates`. + Kind string `json:"kind,omitempty"` + // ServerCerts: List of server certificates for the instance, signed by the + // corresponding CA from the `ca_certs` list. + ServerCerts []*SslCert `json:"serverCerts,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the server. + googleapi.ServerResponse `json:"-"` + // ForceSendFields is a list of field names (e.g. "ActiveVersion") 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. "ActiveVersion") 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 InstancesListServerCertificatesResponse) MarshalJSON() ([]byte, error) { + type NoMethod InstancesListServerCertificatesResponse + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // InstancesReencryptRequest: Database Instance reencrypt request. type InstancesReencryptRequest struct { // BackupReencryptionConfig: Configuration specific to backup re-encryption @@ -2671,6 +2705,30 @@ func (s InstancesRotateServerCaRequest) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// InstancesRotateServerCertificateRequest: Rotate Server Certificate request. +type InstancesRotateServerCertificateRequest struct { + // RotateServerCertificateContext: Optional. Contains details about the rotate + // server CA operation. + RotateServerCertificateContext *RotateServerCertificateContext `json:"rotateServerCertificateContext,omitempty"` + // ForceSendFields is a list of field names (e.g. + // "RotateServerCertificateContext") 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. "RotateServerCertificateContext") + // 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 InstancesRotateServerCertificateRequest) MarshalJSON() ([]byte, error) { + type NoMethod InstancesRotateServerCertificateRequest + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // InstancesTruncateLogRequest: Instance truncate log request. type InstancesTruncateLogRequest struct { // TruncateLogContext: Contains details about the truncate log operation. @@ -3589,6 +3647,32 @@ func (s RotateServerCaContext) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// RotateServerCertificateContext: Instance rotate server certificate context. +type RotateServerCertificateContext struct { + // Kind: Optional. This is always `sql#rotateServerCertificateContext`. + Kind string `json:"kind,omitempty"` + // NextVersion: Optional. The fingerprint of the next version to be rotated to. + // If left unspecified, will be rotated to the most recently added server + // certificate version. + NextVersion string `json:"nextVersion,omitempty"` + // ForceSendFields is a list of field names (e.g. "Kind") 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. "Kind") 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 RotateServerCertificateContext) MarshalJSON() ([]byte, error) { + type NoMethod RotateServerCertificateContext + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // Settings: Database instance settings. type Settings struct { // ActivationPolicy: The activation policy specifies when the instance is @@ -3846,7 +3930,8 @@ type SqlExternalSyncSettingError struct { // MySQL. // "SQLSERVER_AGENT_NOT_RUNNING" - SQL Server Agent is not running. // "UNSUPPORTED_TABLE_DEFINITION" - The table definition is not support due - // to missing primary key or replica identity, applicable for postgres. + // to missing primary key or replica identity, applicable for postgres. Note + // that this is a warning and won't block the migration. // "UNSUPPORTED_DEFINER" - The customer has a definer that will break EM // setup. // "SQLSERVER_SERVERNAME_MISMATCH" - SQL Server @@SERVERNAME does not match @@ -3918,6 +4003,10 @@ type SqlExternalSyncSettingError struct { // Then, perform the migration. // "UNSUPPORTED_SYSTEM_OBJECTS" - The selected objects include system objects // that aren't supported for migration. + // "UNSUPPORTED_TABLES_WITH_REPLICA_IDENTITY" - The source database has + // tables with the FULL or NOTHING replica identity. Before starting your + // migration, either remove the identity or change it to DEFAULT. Note that + // this is an error and will block the migration. Type string `json:"type,omitempty"` // ForceSendFields is a list of field names (e.g. "Detail") to unconditionally // include in API requests. By default, fields with empty or default values are @@ -6254,6 +6343,230 @@ func (c *FlagsListCall) Do(opts ...googleapi.CallOption) (*FlagsListResponse, er return ret, nil } +type InstancesListServerCertificatesCall struct { + s *Service + project string + instance string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// ListServerCertificates: Lists all versions of server certificates and +// certificate authorities (CAs) for the specified instance. There can be up to +// three sets of certs listed: the certificate that is currently in use, a +// future that has been added but not yet used to sign a certificate, and a +// certificate that has been rotated out. +// +// - instance: Cloud SQL instance ID. This does not include the project ID. +// - project: Project ID of the project that contains the instance. +func (r *InstancesService) ListServerCertificates(project string, instance string) *InstancesListServerCertificatesCall { + c := &InstancesListServerCertificatesCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.project = project + c.instance = instance + 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 *InstancesListServerCertificatesCall) Fields(s ...googleapi.Field) *InstancesListServerCertificatesCall { + 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 *InstancesListServerCertificatesCall) IfNoneMatch(entityTag string) *InstancesListServerCertificatesCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *InstancesListServerCertificatesCall) Context(ctx context.Context) *InstancesListServerCertificatesCall { + 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 *InstancesListServerCertificatesCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *InstancesListServerCertificatesCall) 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, "sql/v1beta4/projects/{project}/instances/{instance}/listServerCertificates") + 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{ + "project": c.project, + "instance": c.instance, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "sql.instances.ListServerCertificates" call. +// Any non-2xx status code is an error. Response headers are in either +// *InstancesListServerCertificatesResponse.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 *InstancesListServerCertificatesCall) Do(opts ...googleapi.CallOption) (*InstancesListServerCertificatesResponse, 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 := &InstancesListServerCertificatesResponse{ + 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 InstancesRotateServerCertificateCall struct { + s *Service + project string + instance string + instancesrotateservercertificaterequest *InstancesRotateServerCertificateRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// RotateServerCertificate: Rotates the server certificate version to one +// previously added with the addServerCertificate method. For instances not +// using Certificate Authority Service (CAS) server CA, please use +// RotateServerCa instead. +// +// - instance: Cloud SQL instance ID. This does not include the project ID. +// - project: Project ID of the project that contains the instance. +func (r *InstancesService) RotateServerCertificate(project string, instance string, instancesrotateservercertificaterequest *InstancesRotateServerCertificateRequest) *InstancesRotateServerCertificateCall { + c := &InstancesRotateServerCertificateCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.project = project + c.instance = instance + c.instancesrotateservercertificaterequest = instancesrotateservercertificaterequest + 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 *InstancesRotateServerCertificateCall) Fields(s ...googleapi.Field) *InstancesRotateServerCertificateCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *InstancesRotateServerCertificateCall) Context(ctx context.Context) *InstancesRotateServerCertificateCall { + 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 *InstancesRotateServerCertificateCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *InstancesRotateServerCertificateCall) 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.instancesrotateservercertificaterequest) + if err != nil { + return nil, err + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "sql/v1beta4/projects/{project}/instances/{instance}/rotateServerCertificate") + 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{ + "project": c.project, + "instance": c.instance, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "sql.instances.RotateServerCertificate" 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 *InstancesRotateServerCertificateCall) 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 InstancesAcquireSsrsLeaseCall struct { s *Service project string @@ -6470,6 +6783,111 @@ func (c *InstancesAddServerCaCall) Do(opts ...googleapi.CallOption) (*Operation, return ret, nil } +type InstancesAddServerCertificateCall struct { + s *Service + project string + instance string + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// AddServerCertificate: Add a new trusted server certificate version for the +// specified instance using Certificate Authority Service (CAS) server CA. +// Required to prepare for a certificate rotation. If a server certificate +// version was previously added but never used in a certificate rotation, this +// operation replaces that version. There cannot be more than one certificate +// version waiting to be rotated in. For instances not using CAS server CA, +// please use AddServerCa instead. +// +// - instance: Cloud SQL instance ID. This does not include the project ID. +// - project: Project ID of the project that contains the instance. +func (r *InstancesService) AddServerCertificate(project string, instance string) *InstancesAddServerCertificateCall { + c := &InstancesAddServerCertificateCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.project = project + c.instance = instance + 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 *InstancesAddServerCertificateCall) Fields(s ...googleapi.Field) *InstancesAddServerCertificateCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *InstancesAddServerCertificateCall) Context(ctx context.Context) *InstancesAddServerCertificateCall { + 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 *InstancesAddServerCertificateCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *InstancesAddServerCertificateCall) 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, "sql/v1beta4/projects/{project}/instances/{instance}/addServerCertificate") + 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{ + "project": c.project, + "instance": c.instance, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "sql.instances.addServerCertificate" 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 *InstancesAddServerCertificateCall) 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 InstancesCloneCall struct { s *Service project string diff --git a/transport/grpc/dial.go b/transport/grpc/dial.go index d2a4f76645a..ff3539d898f 100644 --- a/transport/grpc/dial.go +++ b/transport/grpc/dial.go @@ -247,6 +247,7 @@ func dialPoolNewAuth(ctx context.Context, secure bool, poolSize int, ds *interna DefaultScopes: ds.DefaultScopes, SkipValidation: skipValidation, }, + UniverseDomain: ds.UniverseDomain, }) return pool, err } diff --git a/transport/grpc/dial_test.go b/transport/grpc/dial_test.go index bf19d02cd37..ecf46701b3b 100644 --- a/transport/grpc/dial_test.go +++ b/transport/grpc/dial_test.go @@ -39,11 +39,15 @@ func TestDial(t *testing.T) { func TestDialPoolNewAuthDialOptions(t *testing.T) { oldDialContextNewAuth := dialContextNewAuth var wantNumOpts int + var universeDomain string // Replace package var in order to assert DialContext args. dialContextNewAuth = func(ctx context.Context, secure bool, opts *grpctransport.Options) (grpctransport.GRPCClientConnPool, error) { if len(opts.GRPCDialOpts) != wantNumOpts { t.Fatalf("got: %d, want: %d", len(opts.GRPCDialOpts), wantNumOpts) } + if opts.UniverseDomain != universeDomain { + t.Fatalf("got: %q, want: %q", opts.UniverseDomain, universeDomain) + } return nil, nil } defer func() { @@ -67,9 +71,17 @@ func TestDialPoolNewAuthDialOptions(t *testing.T) { }, wantNumOpts: 1, }, + { + name: "universe domain", + ds: &internal.DialSettings{ + UniverseDomain: "example.com", + }, + wantNumOpts: 0, + }, } { t.Run(testcase.name, func(t *testing.T) { wantNumOpts = testcase.wantNumOpts + universeDomain = testcase.ds.UniverseDomain dialPoolNewAuth(context.Background(), false, 1, testcase.ds) }) } diff --git a/transport/http/dial.go b/transport/http/dial.go index 2e2b15c6e0c..d5b213e0f08 100644 --- a/transport/http/dial.go +++ b/transport/http/dial.go @@ -130,6 +130,7 @@ func newClientNewAuth(ctx context.Context, base http.RoundTripper, ds *internal. DefaultScopes: ds.DefaultScopes, SkipValidation: skipValidation, }, + UniverseDomain: ds.UniverseDomain, }) if err != nil { return nil, err diff --git a/vision/v1/vision-api.json b/vision/v1/vision-api.json index 59618b9cf36..095c9726f9f 100644 --- a/vision/v1/vision-api.json +++ b/vision/v1/vision-api.json @@ -1282,7 +1282,7 @@ } } }, - "revision": "20231219", + "revision": "20240823", "rootUrl": "https://vision.googleapis.com/", "schemas": { "AddProductToProductSetRequest": { @@ -2748,7 +2748,7 @@ "type": "object" }, "GoogleCloudVisionV1p1beta1FaceAnnotationLandmark": { - "description": "A face-specific landmark (for example, a face feature).", + "description": "A face-specific landmark (for example, a face feature). Landmark positions may fall outside the bounds of the image if the face is near one or more edges of the image. Therefore it is NOT guaranteed that `0 \u003c= x \u003c width` or `0 \u003c= y \u003c height`.", "id": "GoogleCloudVisionV1p1beta1FaceAnnotationLandmark", "properties": { "position": { @@ -4162,7 +4162,7 @@ "type": "object" }, "GoogleCloudVisionV1p2beta1FaceAnnotationLandmark": { - "description": "A face-specific landmark (for example, a face feature).", + "description": "A face-specific landmark (for example, a face feature). Landmark positions may fall outside the bounds of the image if the face is near one or more edges of the image. Therefore it is NOT guaranteed that `0 \u003c= x \u003c width` or `0 \u003c= y \u003c height`.", "id": "GoogleCloudVisionV1p2beta1FaceAnnotationLandmark", "properties": { "position": { @@ -5611,7 +5611,7 @@ "type": "object" }, "GoogleCloudVisionV1p3beta1FaceAnnotationLandmark": { - "description": "A face-specific landmark (for example, a face feature).", + "description": "A face-specific landmark (for example, a face feature). Landmark positions may fall outside the bounds of the image if the face is near one or more edges of the image. Therefore it is NOT guaranteed that `0 \u003c= x \u003c width` or `0 \u003c= y \u003c height`.", "id": "GoogleCloudVisionV1p3beta1FaceAnnotationLandmark", "properties": { "position": { @@ -7154,7 +7154,7 @@ "type": "object" }, "GoogleCloudVisionV1p4beta1FaceAnnotationLandmark": { - "description": "A face-specific landmark (for example, a face feature).", + "description": "A face-specific landmark (for example, a face feature). Landmark positions may fall outside the bounds of the image if the face is near one or more edges of the image. Therefore it is NOT guaranteed that `0 \u003c= x \u003c width` or `0 \u003c= y \u003c height`.", "id": "GoogleCloudVisionV1p4beta1FaceAnnotationLandmark", "properties": { "position": { @@ -8322,7 +8322,7 @@ "type": "object" }, "Landmark": { - "description": "A face-specific landmark (for example, a face feature).", + "description": "A face-specific landmark (for example, a face feature). Landmark positions may fall outside the bounds of the image if the face is near one or more edges of the image. Therefore it is NOT guaranteed that `0 \u003c= x \u003c width` or `0 \u003c= y \u003c height`.", "id": "Landmark", "properties": { "position": { diff --git a/vision/v1/vision-gen.go b/vision/v1/vision-gen.go index e1444e191ff..bd095933334 100644 --- a/vision/v1/vision-gen.go +++ b/vision/v1/vision-gen.go @@ -2240,7 +2240,9 @@ func (s *GoogleCloudVisionV1p1beta1FaceAnnotation) UnmarshalJSON(data []byte) er } // GoogleCloudVisionV1p1beta1FaceAnnotationLandmark: A face-specific landmark -// (for example, a face feature). +// (for example, a face feature). Landmark positions may fall outside the +// bounds of the image if the face is near one or more edges of the image. +// Therefore it is NOT guaranteed that `0 <= x < width` or `0 <= y < height`. type GoogleCloudVisionV1p1beta1FaceAnnotationLandmark struct { // Position: Face landmark position. Position *GoogleCloudVisionV1p1beta1Position `json:"position,omitempty"` @@ -4118,7 +4120,9 @@ func (s *GoogleCloudVisionV1p2beta1FaceAnnotation) UnmarshalJSON(data []byte) er } // GoogleCloudVisionV1p2beta1FaceAnnotationLandmark: A face-specific landmark -// (for example, a face feature). +// (for example, a face feature). Landmark positions may fall outside the +// bounds of the image if the face is near one or more edges of the image. +// Therefore it is NOT guaranteed that `0 <= x < width` or `0 <= y < height`. type GoogleCloudVisionV1p2beta1FaceAnnotationLandmark struct { // Position: Face landmark position. Position *GoogleCloudVisionV1p2beta1Position `json:"position,omitempty"` @@ -6038,7 +6042,9 @@ func (s *GoogleCloudVisionV1p3beta1FaceAnnotation) UnmarshalJSON(data []byte) er } // GoogleCloudVisionV1p3beta1FaceAnnotationLandmark: A face-specific landmark -// (for example, a face feature). +// (for example, a face feature). Landmark positions may fall outside the +// bounds of the image if the face is near one or more edges of the image. +// Therefore it is NOT guaranteed that `0 <= x < width` or `0 <= y < height`. type GoogleCloudVisionV1p3beta1FaceAnnotationLandmark struct { // Position: Face landmark position. Position *GoogleCloudVisionV1p3beta1Position `json:"position,omitempty"` @@ -8105,7 +8111,9 @@ func (s *GoogleCloudVisionV1p4beta1FaceAnnotation) UnmarshalJSON(data []byte) er } // GoogleCloudVisionV1p4beta1FaceAnnotationLandmark: A face-specific landmark -// (for example, a face feature). +// (for example, a face feature). Landmark positions may fall outside the +// bounds of the image if the face is near one or more edges of the image. +// Therefore it is NOT guaranteed that `0 <= x < width` or `0 <= y < height`. type GoogleCloudVisionV1p4beta1FaceAnnotationLandmark struct { // Position: Face landmark position. Position *GoogleCloudVisionV1p4beta1Position `json:"position,omitempty"` @@ -9887,7 +9895,10 @@ func (s KeyValue) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// Landmark: A face-specific landmark (for example, a face feature). +// Landmark: A face-specific landmark (for example, a face feature). Landmark +// positions may fall outside the bounds of the image if the face is near one +// or more edges of the image. Therefore it is NOT guaranteed that `0 <= x < +// width` or `0 <= y < height`. type Landmark struct { // Position: Face landmark position. Position *Position `json:"position,omitempty"` diff --git a/vision/v1p1beta1/vision-api.json b/vision/v1p1beta1/vision-api.json index ed138c80eee..5471e3f7dc4 100644 --- a/vision/v1p1beta1/vision-api.json +++ b/vision/v1p1beta1/vision-api.json @@ -449,7 +449,7 @@ } } }, - "revision": "20231219", + "revision": "20240823", "rootUrl": "https://vision.googleapis.com/", "schemas": { "AnnotateFileResponse": { @@ -1856,7 +1856,7 @@ "type": "object" }, "GoogleCloudVisionV1p1beta1FaceAnnotationLandmark": { - "description": "A face-specific landmark (for example, a face feature).", + "description": "A face-specific landmark (for example, a face feature). Landmark positions may fall outside the bounds of the image if the face is near one or more edges of the image. Therefore it is NOT guaranteed that `0 \u003c= x \u003c width` or `0 \u003c= y \u003c height`.", "id": "GoogleCloudVisionV1p1beta1FaceAnnotationLandmark", "properties": { "position": { @@ -3456,7 +3456,7 @@ "type": "object" }, "GoogleCloudVisionV1p2beta1FaceAnnotationLandmark": { - "description": "A face-specific landmark (for example, a face feature).", + "description": "A face-specific landmark (for example, a face feature). Landmark positions may fall outside the bounds of the image if the face is near one or more edges of the image. Therefore it is NOT guaranteed that `0 \u003c= x \u003c width` or `0 \u003c= y \u003c height`.", "id": "GoogleCloudVisionV1p2beta1FaceAnnotationLandmark", "properties": { "position": { @@ -4905,7 +4905,7 @@ "type": "object" }, "GoogleCloudVisionV1p3beta1FaceAnnotationLandmark": { - "description": "A face-specific landmark (for example, a face feature).", + "description": "A face-specific landmark (for example, a face feature). Landmark positions may fall outside the bounds of the image if the face is near one or more edges of the image. Therefore it is NOT guaranteed that `0 \u003c= x \u003c width` or `0 \u003c= y \u003c height`.", "id": "GoogleCloudVisionV1p3beta1FaceAnnotationLandmark", "properties": { "position": { @@ -6448,7 +6448,7 @@ "type": "object" }, "GoogleCloudVisionV1p4beta1FaceAnnotationLandmark": { - "description": "A face-specific landmark (for example, a face feature).", + "description": "A face-specific landmark (for example, a face feature). Landmark positions may fall outside the bounds of the image if the face is near one or more edges of the image. Therefore it is NOT guaranteed that `0 \u003c= x \u003c width` or `0 \u003c= y \u003c height`.", "id": "GoogleCloudVisionV1p4beta1FaceAnnotationLandmark", "properties": { "position": { @@ -7518,7 +7518,7 @@ "type": "object" }, "Landmark": { - "description": "A face-specific landmark (for example, a face feature).", + "description": "A face-specific landmark (for example, a face feature). Landmark positions may fall outside the bounds of the image if the face is near one or more edges of the image. Therefore it is NOT guaranteed that `0 \u003c= x \u003c width` or `0 \u003c= y \u003c height`.", "id": "Landmark", "properties": { "position": { diff --git a/vision/v1p1beta1/vision-gen.go b/vision/v1p1beta1/vision-gen.go index eebf55e26ec..b5aaa0a6567 100644 --- a/vision/v1p1beta1/vision-gen.go +++ b/vision/v1p1beta1/vision-gen.go @@ -2069,7 +2069,9 @@ func (s *GoogleCloudVisionV1p1beta1FaceAnnotation) UnmarshalJSON(data []byte) er } // GoogleCloudVisionV1p1beta1FaceAnnotationLandmark: A face-specific landmark -// (for example, a face feature). +// (for example, a face feature). Landmark positions may fall outside the +// bounds of the image if the face is near one or more edges of the image. +// Therefore it is NOT guaranteed that `0 <= x < width` or `0 <= y < height`. type GoogleCloudVisionV1p1beta1FaceAnnotationLandmark struct { // Position: Face landmark position. Position *GoogleCloudVisionV1p1beta1Position `json:"position,omitempty"` @@ -4234,7 +4236,9 @@ func (s *GoogleCloudVisionV1p2beta1FaceAnnotation) UnmarshalJSON(data []byte) er } // GoogleCloudVisionV1p2beta1FaceAnnotationLandmark: A face-specific landmark -// (for example, a face feature). +// (for example, a face feature). Landmark positions may fall outside the +// bounds of the image if the face is near one or more edges of the image. +// Therefore it is NOT guaranteed that `0 <= x < width` or `0 <= y < height`. type GoogleCloudVisionV1p2beta1FaceAnnotationLandmark struct { // Position: Face landmark position. Position *GoogleCloudVisionV1p2beta1Position `json:"position,omitempty"` @@ -6154,7 +6158,9 @@ func (s *GoogleCloudVisionV1p3beta1FaceAnnotation) UnmarshalJSON(data []byte) er } // GoogleCloudVisionV1p3beta1FaceAnnotationLandmark: A face-specific landmark -// (for example, a face feature). +// (for example, a face feature). Landmark positions may fall outside the +// bounds of the image if the face is near one or more edges of the image. +// Therefore it is NOT guaranteed that `0 <= x < width` or `0 <= y < height`. type GoogleCloudVisionV1p3beta1FaceAnnotationLandmark struct { // Position: Face landmark position. Position *GoogleCloudVisionV1p3beta1Position `json:"position,omitempty"` @@ -8221,7 +8227,9 @@ func (s *GoogleCloudVisionV1p4beta1FaceAnnotation) UnmarshalJSON(data []byte) er } // GoogleCloudVisionV1p4beta1FaceAnnotationLandmark: A face-specific landmark -// (for example, a face feature). +// (for example, a face feature). Landmark positions may fall outside the +// bounds of the image if the face is near one or more edges of the image. +// Therefore it is NOT guaranteed that `0 <= x < width` or `0 <= y < height`. type GoogleCloudVisionV1p4beta1FaceAnnotationLandmark struct { // Position: Face landmark position. Position *GoogleCloudVisionV1p4beta1Position `json:"position,omitempty"` @@ -9793,7 +9801,10 @@ func (s KeyValue) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// Landmark: A face-specific landmark (for example, a face feature). +// Landmark: A face-specific landmark (for example, a face feature). Landmark +// positions may fall outside the bounds of the image if the face is near one +// or more edges of the image. Therefore it is NOT guaranteed that `0 <= x < +// width` or `0 <= y < height`. type Landmark struct { // Position: Face landmark position. Position *Position `json:"position,omitempty"` diff --git a/vision/v1p2beta1/vision-api.json b/vision/v1p2beta1/vision-api.json index fd09813177e..6f1d63a1e5e 100644 --- a/vision/v1p2beta1/vision-api.json +++ b/vision/v1p2beta1/vision-api.json @@ -449,7 +449,7 @@ } } }, - "revision": "20231219", + "revision": "20240823", "rootUrl": "https://vision.googleapis.com/", "schemas": { "AnnotateFileResponse": { @@ -1631,7 +1631,7 @@ "type": "object" }, "GoogleCloudVisionV1p1beta1FaceAnnotationLandmark": { - "description": "A face-specific landmark (for example, a face feature).", + "description": "A face-specific landmark (for example, a face feature). Landmark positions may fall outside the bounds of the image if the face is near one or more edges of the image. Therefore it is NOT guaranteed that `0 \u003c= x \u003c width` or `0 \u003c= y \u003c height`.", "id": "GoogleCloudVisionV1p1beta1FaceAnnotationLandmark", "properties": { "position": { @@ -3270,7 +3270,7 @@ "type": "object" }, "GoogleCloudVisionV1p2beta1FaceAnnotationLandmark": { - "description": "A face-specific landmark (for example, a face feature).", + "description": "A face-specific landmark (for example, a face feature). Landmark positions may fall outside the bounds of the image if the face is near one or more edges of the image. Therefore it is NOT guaranteed that `0 \u003c= x \u003c width` or `0 \u003c= y \u003c height`.", "id": "GoogleCloudVisionV1p2beta1FaceAnnotationLandmark", "properties": { "position": { @@ -4905,7 +4905,7 @@ "type": "object" }, "GoogleCloudVisionV1p3beta1FaceAnnotationLandmark": { - "description": "A face-specific landmark (for example, a face feature).", + "description": "A face-specific landmark (for example, a face feature). Landmark positions may fall outside the bounds of the image if the face is near one or more edges of the image. Therefore it is NOT guaranteed that `0 \u003c= x \u003c width` or `0 \u003c= y \u003c height`.", "id": "GoogleCloudVisionV1p3beta1FaceAnnotationLandmark", "properties": { "position": { @@ -6448,7 +6448,7 @@ "type": "object" }, "GoogleCloudVisionV1p4beta1FaceAnnotationLandmark": { - "description": "A face-specific landmark (for example, a face feature).", + "description": "A face-specific landmark (for example, a face feature). Landmark positions may fall outside the bounds of the image if the face is near one or more edges of the image. Therefore it is NOT guaranteed that `0 \u003c= x \u003c width` or `0 \u003c= y \u003c height`.", "id": "GoogleCloudVisionV1p4beta1FaceAnnotationLandmark", "properties": { "position": { @@ -7518,7 +7518,7 @@ "type": "object" }, "Landmark": { - "description": "A face-specific landmark (for example, a face feature).", + "description": "A face-specific landmark (for example, a face feature). Landmark positions may fall outside the bounds of the image if the face is near one or more edges of the image. Therefore it is NOT guaranteed that `0 \u003c= x \u003c width` or `0 \u003c= y \u003c height`.", "id": "Landmark", "properties": { "position": { diff --git a/vision/v1p2beta1/vision-gen.go b/vision/v1p2beta1/vision-gen.go index 6f66a583271..f6cd774549c 100644 --- a/vision/v1p2beta1/vision-gen.go +++ b/vision/v1p2beta1/vision-gen.go @@ -1731,7 +1731,9 @@ func (s *GoogleCloudVisionV1p1beta1FaceAnnotation) UnmarshalJSON(data []byte) er } // GoogleCloudVisionV1p1beta1FaceAnnotationLandmark: A face-specific landmark -// (for example, a face feature). +// (for example, a face feature). Landmark positions may fall outside the +// bounds of the image if the face is near one or more edges of the image. +// Therefore it is NOT guaranteed that `0 <= x < width` or `0 <= y < height`. type GoogleCloudVisionV1p1beta1FaceAnnotationLandmark struct { // Position: Face landmark position. Position *GoogleCloudVisionV1p1beta1Position `json:"position,omitempty"` @@ -3947,7 +3949,9 @@ func (s *GoogleCloudVisionV1p2beta1FaceAnnotation) UnmarshalJSON(data []byte) er } // GoogleCloudVisionV1p2beta1FaceAnnotationLandmark: A face-specific landmark -// (for example, a face feature). +// (for example, a face feature). Landmark positions may fall outside the +// bounds of the image if the face is near one or more edges of the image. +// Therefore it is NOT guaranteed that `0 <= x < width` or `0 <= y < height`. type GoogleCloudVisionV1p2beta1FaceAnnotationLandmark struct { // Position: Face landmark position. Position *GoogleCloudVisionV1p2beta1Position `json:"position,omitempty"` @@ -6154,7 +6158,9 @@ func (s *GoogleCloudVisionV1p3beta1FaceAnnotation) UnmarshalJSON(data []byte) er } // GoogleCloudVisionV1p3beta1FaceAnnotationLandmark: A face-specific landmark -// (for example, a face feature). +// (for example, a face feature). Landmark positions may fall outside the +// bounds of the image if the face is near one or more edges of the image. +// Therefore it is NOT guaranteed that `0 <= x < width` or `0 <= y < height`. type GoogleCloudVisionV1p3beta1FaceAnnotationLandmark struct { // Position: Face landmark position. Position *GoogleCloudVisionV1p3beta1Position `json:"position,omitempty"` @@ -8221,7 +8227,9 @@ func (s *GoogleCloudVisionV1p4beta1FaceAnnotation) UnmarshalJSON(data []byte) er } // GoogleCloudVisionV1p4beta1FaceAnnotationLandmark: A face-specific landmark -// (for example, a face feature). +// (for example, a face feature). Landmark positions may fall outside the +// bounds of the image if the face is near one or more edges of the image. +// Therefore it is NOT guaranteed that `0 <= x < width` or `0 <= y < height`. type GoogleCloudVisionV1p4beta1FaceAnnotationLandmark struct { // Position: Face landmark position. Position *GoogleCloudVisionV1p4beta1Position `json:"position,omitempty"` @@ -9793,7 +9801,10 @@ func (s KeyValue) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// Landmark: A face-specific landmark (for example, a face feature). +// Landmark: A face-specific landmark (for example, a face feature). Landmark +// positions may fall outside the bounds of the image if the face is near one +// or more edges of the image. Therefore it is NOT guaranteed that `0 <= x < +// width` or `0 <= y < height`. type Landmark struct { // Position: Face landmark position. Position *Position `json:"position,omitempty"` diff --git a/workflowexecutions/v1/workflowexecutions-api.json b/workflowexecutions/v1/workflowexecutions-api.json index d829cc1715f..1faf90d104f 100644 --- a/workflowexecutions/v1/workflowexecutions-api.json +++ b/workflowexecutions/v1/workflowexecutions-api.json @@ -517,7 +517,7 @@ } } }, - "revision": "20240813", + "revision": "20240827", "rootUrl": "https://workflowexecutions.googleapis.com/", "schemas": { "Callback": { @@ -1009,13 +1009,15 @@ "STATE_UNSPECIFIED", "STATE_IN_PROGRESS", "STATE_SUCCEEDED", - "STATE_FAILED" + "STATE_FAILED", + "STATE_CANCELLED" ], "enumDescriptions": [ "Invalid state.", "The step entry is in progress.", "The step entry finished successfully.", - "The step entry failed with an error." + "The step entry failed with an error.", + "The step entry is cancelled." ], "readOnly": true, "type": "string" diff --git a/workflowexecutions/v1/workflowexecutions-gen.go b/workflowexecutions/v1/workflowexecutions-gen.go index f060013906a..92db07bc4c9 100644 --- a/workflowexecutions/v1/workflowexecutions-gen.go +++ b/workflowexecutions/v1/workflowexecutions-gen.go @@ -815,6 +815,7 @@ type StepEntry struct { // "STATE_IN_PROGRESS" - The step entry is in progress. // "STATE_SUCCEEDED" - The step entry finished successfully. // "STATE_FAILED" - The step entry failed with an error. + // "STATE_CANCELLED" - The step entry is cancelled. State string `json:"state,omitempty"` // Step: Output only. The name of the step this step entry belongs to. Step string `json:"step,omitempty"`