From 2c204857ee78454d1e2cafb5df2bc3720fc0afbc Mon Sep 17 00:00:00 2001 From: Yoshi Automation Bot Date: Wed, 23 Jul 2025 00:38:26 -0700 Subject: [PATCH 01/10] feat(all): auto-regenerate discovery clients (#3241) --- aiplatform/v1/aiplatform-api.json | 36 +- aiplatform/v1/aiplatform-gen.go | 53 +- aiplatform/v1beta1/aiplatform-api.json | 119 +- aiplatform/v1beta1/aiplatform-gen.go | 311 +- androidpublisher/v3/androidpublisher-api.json | 1916 +- androidpublisher/v3/androidpublisher-gen.go | 14898 ++++++++++------ chat/v1/chat-api.json | 10 +- chat/v1/chat-gen.go | 22 +- firebaseml/v2beta/firebaseml-api.json | 70 +- firebaseml/v2beta/firebaseml-gen.go | 103 +- homegraph/v1/homegraph-api.json | 4 +- homegraph/v1/homegraph-gen.go | 4 +- iam/v1/iam-api.json | 525 +- iam/v1/iam-gen.go | 1619 ++ .../accounts_v1beta/merchantapi-api.json | 64 +- .../accounts_v1beta/merchantapi-gen.go | 240 +- .../datasources_v1beta/merchantapi-api.json | 4 +- .../datasources_v1beta/merchantapi-gen.go | 5 +- .../inventories_v1beta/merchantapi-api.json | 4 +- networksecurity/v1/networksecurity-api.json | 44 +- networksecurity/v1/networksecurity-gen.go | 71 +- retail/v2/retail-api.json | 45 +- retail/v2/retail-gen.go | 38 + retail/v2alpha/retail-api.json | 119 +- retail/v2alpha/retail-gen.go | 96 + retail/v2beta/retail-api.json | 51 +- retail/v2beta/retail-gen.go | 41 + searchads360/v0/searchads360-api.json | 42 +- searchads360/v0/searchads360-gen.go | 29 +- .../v1/serviceconsumermanagement-api.json | 6 +- .../v1/serviceconsumermanagement-gen.go | 7 + .../serviceconsumermanagement-api.json | 6 +- .../v1beta1/serviceconsumermanagement-gen.go | 7 + serviceusage/v1/serviceusage-api.json | 6 +- serviceusage/v1/serviceusage-gen.go | 7 + serviceusage/v1beta1/serviceusage-api.json | 6 +- serviceusage/v1beta1/serviceusage-gen.go | 7 + storage/v1/storage-api.json | 73 +- storage/v1/storage-gen.go | 140 +- 39 files changed, 14914 insertions(+), 5934 deletions(-) diff --git a/aiplatform/v1/aiplatform-api.json b/aiplatform/v1/aiplatform-api.json index 4940f3a0b9a..cb995136acb 100644 --- a/aiplatform/v1/aiplatform-api.json +++ b/aiplatform/v1/aiplatform-api.json @@ -4543,6 +4543,11 @@ "location": "query", "type": "string" }, + "gdcZone": { + "description": "Optional. Configures the Google Distributed Cloud (GDC) environment for online prediction. Only set this field when the Endpoint is to be deployed in a GDC environment.", + "location": "query", + "type": "string" + }, "orderBy": { "description": "A comma-separated list of fields to order by, sorted in ascending order. Use \"desc\" after a field name for descending. Supported fields: * `display_name` * `create_time` * `update_time` Example: `display_name, create_time desc`.", "location": "query", @@ -4582,7 +4587,7 @@ ] }, "mutateDeployedModel": { - "description": "Updates an existing deployed model. Updatable fields include `min_replica_count`, `max_replica_count`, `autoscaling_metric_specs`, `disable_container_logging` (v1 only), and `enable_container_logging` (v1beta1 only).", + "description": "Updates an existing deployed model. Updatable fields include `min_replica_count`, `max_replica_count`, `required_replica_count`, `autoscaling_metric_specs`, `disable_container_logging` (v1 only), and `enable_container_logging` (v1beta1 only).", "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/endpoints/{endpointsId}:mutateDeployedModel", "httpMethod": "POST", "id": "aiplatform.projects.locations.endpoints.mutateDeployedModel", @@ -20253,7 +20258,7 @@ } } }, - "revision": "20250711", + "revision": "20250715", "rootUrl": "https://aiplatform.googleapis.com/", "schemas": { "CloudAiLargeModelsVisionGenerateVideoResponse": { @@ -24410,6 +24415,10 @@ "modelDisplayName": { "description": "Optional. The user-specified display name of the uploaded model. If not set, a default name will be used.", "type": "string" + }, + "modelUserId": { + "description": "Optional. The ID to use for the uploaded Model, which will become the final component of the model resource name. When not provided, Vertex AI will generate a value for this ID. When Model Registry model is provided, this field will be ignored. This value may be up to 63 characters, and valid characters are `[a-z0-9_-]`. The first character cannot be a number or hyphen.", + "type": "string" } }, "type": "object" @@ -24608,6 +24617,10 @@ "$ref": "GoogleCloudAiplatformV1FasterDeploymentConfig", "description": "Configuration for faster model deployment." }, + "gdcConnectedModel": { + "description": "GDC pretrained / Gemini model name. The model name is a plain model name, e.g. gemini-1.5-flash-002.", + "type": "string" + }, "id": { "description": "Immutable. The ID of the DeployedModel. If not provided upon deployment, Vertex AI will generate a value for this ID. This value should be 1-10 characters, and valid characters are `/[0-9]/`.", "type": "string" @@ -24960,6 +24973,10 @@ "description": "Used to perform consistent read-modify-write updates. If not set, a blind \"overwrite\" update happens.", "type": "string" }, + "gdcConfig": { + "$ref": "GoogleCloudAiplatformV1GdcConfig", + "description": "Configures the Google Distributed Cloud (GDC) environment for online prediction. Only set this field when the Endpoint is to be deployed in a GDC environment." + }, "genAiAdvancedFeaturesConfig": { "$ref": "GoogleCloudAiplatformV1GenAiAdvancedFeaturesConfig", "description": "Optional. Configuration for GenAiAdvancedFeatures. If the endpoint is serving GenAI models, advanced features like native RAG integration can be configured. Currently, only Model Garden models are supported." @@ -28374,6 +28391,17 @@ }, "type": "object" }, + "GoogleCloudAiplatformV1GdcConfig": { + "description": "Google Distributed Cloud (GDC) config.", + "id": "GoogleCloudAiplatformV1GdcConfig", + "properties": { + "zone": { + "description": "GDC zone. A cluster will be designated for the Vertex AI workload in this zone.", + "type": "string" + } + }, + "type": "object" + }, "GoogleCloudAiplatformV1GenAiAdvancedFeaturesConfig": { "description": "Configuration for GenAiAdvancedFeatures.", "id": "GoogleCloudAiplatformV1GenAiAdvancedFeaturesConfig", @@ -33045,7 +33073,7 @@ "properties": { "deployedModel": { "$ref": "GoogleCloudAiplatformV1DeployedModel", - "description": "Required. The DeployedModel to be mutated within the Endpoint. Only the following fields can be mutated: * `min_replica_count` in either DedicatedResources or AutomaticResources * `max_replica_count` in either DedicatedResources or AutomaticResources * autoscaling_metric_specs * `disable_container_logging` (v1 only) * `enable_container_logging` (v1beta1 only)" + "description": "Required. The DeployedModel to be mutated within the Endpoint. Only the following fields can be mutated: * `min_replica_count` in either DedicatedResources or AutomaticResources * `max_replica_count` in either DedicatedResources or AutomaticResources * `required_replica_count` in DedicatedResources * autoscaling_metric_specs * `disable_container_logging` (v1 only) * `enable_container_logging` (v1beta1 only)" }, "updateMask": { "description": "Required. The update mask applies to the resource. See google.protobuf.FieldMask.", @@ -44628,7 +44656,7 @@ "type": "string" }, "learningRateMultiplier": { - "description": "Optional. Multiplier for adjusting the default learning rate. Mutually exclusive with `learning_rate`.", + "description": "Optional. Multiplier for adjusting the default learning rate. Mutually exclusive with `learning_rate`. This feature is only available for 1P models.", "format": "double", "type": "number" } diff --git a/aiplatform/v1/aiplatform-gen.go b/aiplatform/v1/aiplatform-gen.go index 07f5617f5f1..3fdb3a9299f 100644 --- a/aiplatform/v1/aiplatform-gen.go +++ b/aiplatform/v1/aiplatform-gen.go @@ -7547,6 +7547,13 @@ type GoogleCloudAiplatformV1DeployRequestModelConfig struct { // ModelDisplayName: Optional. The user-specified display name of the uploaded // model. If not set, a default name will be used. ModelDisplayName string `json:"modelDisplayName,omitempty"` + // ModelUserId: Optional. The ID to use for the uploaded Model, which will + // become the final component of the model resource name. When not provided, + // Vertex AI will generate a value for this ID. When Model Registry model is + // provided, this field will be ignored. This value may be up to 63 characters, + // and valid characters are `[a-z0-9_-]`. The first character cannot be a + // number or hyphen. + ModelUserId string `json:"modelUserId,omitempty"` // ForceSendFields is a list of field names (e.g. "AcceptEula") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See @@ -7835,6 +7842,9 @@ type GoogleCloudAiplatformV1DeployedModel struct { ExplanationSpec *GoogleCloudAiplatformV1ExplanationSpec `json:"explanationSpec,omitempty"` // FasterDeploymentConfig: Configuration for faster model deployment. FasterDeploymentConfig *GoogleCloudAiplatformV1FasterDeploymentConfig `json:"fasterDeploymentConfig,omitempty"` + // GdcConnectedModel: GDC pretrained / Gemini model name. The model name is a + // plain model name, e.g. gemini-1.5-flash-002. + GdcConnectedModel string `json:"gdcConnectedModel,omitempty"` // Id: Immutable. The ID of the DeployedModel. If not provided upon deployment, // Vertex AI will generate a value for this ID. This value should be 1-10 // characters, and valid characters are `/[0-9]/`. @@ -8350,6 +8360,10 @@ type GoogleCloudAiplatformV1Endpoint struct { // Etag: Used to perform consistent read-modify-write updates. If not set, a // blind "overwrite" update happens. Etag string `json:"etag,omitempty"` + // GdcConfig: Configures the Google Distributed Cloud (GDC) environment for + // online prediction. Only set this field when the Endpoint is to be deployed + // in a GDC environment. + GdcConfig *GoogleCloudAiplatformV1GdcConfig `json:"gdcConfig,omitempty"` // GenAiAdvancedFeaturesConfig: Optional. Configuration for // GenAiAdvancedFeatures. If the endpoint is serving GenAI models, advanced // features like native RAG integration can be configured. Currently, only @@ -13229,6 +13243,29 @@ func (s GoogleCloudAiplatformV1GcsSource) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudAiplatformV1GdcConfig: Google Distributed Cloud (GDC) config. +type GoogleCloudAiplatformV1GdcConfig struct { + // Zone: GDC zone. A cluster will be designated for the Vertex AI workload in + // this zone. + 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 GoogleCloudAiplatformV1GdcConfig) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudAiplatformV1GdcConfig + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudAiplatformV1GenAiAdvancedFeaturesConfig: Configuration for // GenAiAdvancedFeatures. type GoogleCloudAiplatformV1GenAiAdvancedFeaturesConfig struct { @@ -19642,7 +19679,8 @@ type GoogleCloudAiplatformV1MutateDeployedModelRequest struct { // DeployedModel: Required. The DeployedModel to be mutated within the // Endpoint. Only the following fields can be mutated: * `min_replica_count` in // either DedicatedResources or AutomaticResources * `max_replica_count` in - // either DedicatedResources or AutomaticResources * autoscaling_metric_specs * + // either DedicatedResources or AutomaticResources * `required_replica_count` + // in DedicatedResources * autoscaling_metric_specs * // `disable_container_logging` (v1 only) * `enable_container_logging` (v1beta1 // only) DeployedModel *GoogleCloudAiplatformV1DeployedModel `json:"deployedModel,omitempty"` @@ -36612,7 +36650,8 @@ type GoogleCloudAiplatformV1SupervisedHyperParameters struct { // entire training dataset during training. EpochCount int64 `json:"epochCount,omitempty,string"` // LearningRateMultiplier: Optional. Multiplier for adjusting the default - // learning rate. Mutually exclusive with `learning_rate`. + // learning rate. Mutually exclusive with `learning_rate`. This feature is only + // available for 1P models. LearningRateMultiplier float64 `json:"learningRateMultiplier,omitempty"` // ForceSendFields is a list of field names (e.g. "AdapterSize") to // unconditionally include in API requests. By default, fields with empty or @@ -57016,6 +57055,14 @@ func (c *ProjectsLocationsEndpointsListCall) Filter(filter string) *ProjectsLoca return c } +// GdcZone sets the optional parameter "gdcZone": Configures the Google +// Distributed Cloud (GDC) environment for online prediction. Only set this +// field when the Endpoint is to be deployed in a GDC environment. +func (c *ProjectsLocationsEndpointsListCall) GdcZone(gdcZone string) *ProjectsLocationsEndpointsListCall { + c.urlParams_.Set("gdcZone", gdcZone) + return c +} + // OrderBy sets the optional parameter "orderBy": A comma-separated list of // fields to order by, sorted in ascending order. Use "desc" after a field name // for descending. Supported fields: * `display_name` * `create_time` * @@ -57170,7 +57217,7 @@ type ProjectsLocationsEndpointsMutateDeployedModelCall struct { } // MutateDeployedModel: Updates an existing deployed model. Updatable fields -// include `min_replica_count`, `max_replica_count`, +// include `min_replica_count`, `max_replica_count`, `required_replica_count`, // `autoscaling_metric_specs`, `disable_container_logging` (v1 only), and // `enable_container_logging` (v1beta1 only). // diff --git a/aiplatform/v1beta1/aiplatform-api.json b/aiplatform/v1beta1/aiplatform-api.json index 2b143a01385..ca87593bf5a 100644 --- a/aiplatform/v1beta1/aiplatform-api.json +++ b/aiplatform/v1beta1/aiplatform-api.json @@ -1070,6 +1070,31 @@ }, "projects": { "methods": { + "fetchPublisherModelConfig": { + "description": "Fetches the configs of publisher models.", + "flatPath": "v1beta1/projects/{projectsId}:fetchPublisherModelConfig", + "httpMethod": "GET", + "id": "aiplatform.projects.fetchPublisherModelConfig", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Required. The name of the publisher model, in the format of `projects/{project}/locations/{location}/publishers/{publisher}/models/{model}`.", + "location": "path", + "pattern": "^projects/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1beta1/{+name}:fetchPublisherModelConfig", + "response": { + "$ref": "GoogleCloudAiplatformV1beta1PublisherModelConfig" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, "getCacheConfig": { "description": "Gets a GenAI cache config.", "flatPath": "v1beta1/projects/{projectsId}/cacheConfig", @@ -1095,6 +1120,34 @@ "https://www.googleapis.com/auth/cloud-platform" ] }, + "setPublisherModelConfig": { + "description": "Sets (creates or updates) configs of publisher models. For example, sets the request/response logging config.", + "flatPath": "v1beta1/projects/{projectsId}:setPublisherModelConfig", + "httpMethod": "POST", + "id": "aiplatform.projects.setPublisherModelConfig", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Required. The name of the publisher model, in the format of `projects/{project}/locations/{location}/publishers/{publisher}/models/{model}`.", + "location": "path", + "pattern": "^projects/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1beta1/{+name}:setPublisherModelConfig", + "request": { + "$ref": "GoogleCloudAiplatformV1beta1SetPublisherModelConfigRequest" + }, + "response": { + "$ref": "GoogleLongrunningOperation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, "updateCacheConfig": { "description": "Updates a cache config.", "flatPath": "v1beta1/projects/{projectsId}/cacheConfig", @@ -5126,6 +5179,11 @@ "location": "query", "type": "string" }, + "gdcZone": { + "description": "Optional. Configures the Google Distributed Cloud (GDC) environment for online prediction. Only set this field when the Endpoint is to be deployed in a GDC environment.", + "location": "query", + "type": "string" + }, "pageSize": { "description": "Optional. The standard list page size.", "format": "int32", @@ -5160,7 +5218,7 @@ ] }, "mutateDeployedModel": { - "description": "Updates an existing deployed model. Updatable fields include `min_replica_count`, `max_replica_count`, `autoscaling_metric_specs`, `disable_container_logging` (v1 only), and `enable_container_logging` (v1beta1 only).", + "description": "Updates an existing deployed model. Updatable fields include `min_replica_count`, `max_replica_count`, `required_replica_count`, `autoscaling_metric_specs`, `disable_container_logging` (v1 only), and `enable_container_logging` (v1beta1 only).", "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/endpoints/{endpointsId}:mutateDeployedModel", "httpMethod": "POST", "id": "aiplatform.projects.locations.endpoints.mutateDeployedModel", @@ -25262,7 +25320,7 @@ } } }, - "revision": "20250711", + "revision": "20250715", "rootUrl": "https://aiplatform.googleapis.com/", "schemas": { "CloudAiLargeModelsVisionGenerateVideoResponse": { @@ -29768,6 +29826,10 @@ "description": "Request message for ModelGardenService.Deploy.", "id": "GoogleCloudAiplatformV1beta1DeployRequest", "properties": { + "customModel": { + "$ref": "GoogleCloudAiplatformV1beta1DeployRequestCustomModel", + "description": "The custom model to deploy from a Google Cloud Storage URI." + }, "deployConfig": { "$ref": "GoogleCloudAiplatformV1beta1DeployRequestDeployConfig", "description": "Optional. The deploy config to use for the deployment. If not specified, the default deploy config will be used." @@ -29791,6 +29853,22 @@ }, "type": "object" }, + "GoogleCloudAiplatformV1beta1DeployRequestCustomModel": { + "description": "The custom model to deploy from model weights in a Google Cloud Storage URI or Model Registry model.", + "id": "GoogleCloudAiplatformV1beta1DeployRequestCustomModel", + "properties": { + "gcsUri": { + "description": "Immutable. The Google Cloud Storage URI of the custom model, storing weights and config files (which can be used to infer the base model).", + "type": "string" + }, + "modelId": { + "deprecated": true, + "description": "Optional. Deprecated. Use ModelConfig.model_user_id instead.", + "type": "string" + } + }, + "type": "object" + }, "GoogleCloudAiplatformV1beta1DeployRequestDeployConfig": { "description": "The deploy config to use for the deployment.", "id": "GoogleCloudAiplatformV1beta1DeployRequestDeployConfig", @@ -29851,6 +29929,10 @@ "modelDisplayName": { "description": "Optional. The user-specified display name of the uploaded model. If not set, a default name will be used.", "type": "string" + }, + "modelUserId": { + "description": "Optional. The ID to use for the uploaded Model, which will become the final component of the model resource name. When not provided, Vertex AI will generate a value for this ID. When Model Registry model is provided, this field will be ignored. This value may be up to 63 characters, and valid characters are `[a-z0-9_-]`. The first character cannot be a number or hyphen.", + "type": "string" } }, "type": "object" @@ -30038,6 +30120,10 @@ "$ref": "GoogleCloudAiplatformV1beta1FasterDeploymentConfig", "description": "Configuration for faster model deployment." }, + "gdcConnectedModel": { + "description": "GDC pretrained / Gemini model name. The model name is a plain model name, e.g. gemini-1.5-flash-002.", + "type": "string" + }, "id": { "description": "Immutable. The ID of the DeployedModel. If not provided upon deployment, Vertex AI will generate a value for this ID. This value should be 1-10 characters, and valid characters are `/[0-9]/`.", "type": "string" @@ -30483,6 +30569,10 @@ "description": "Used to perform consistent read-modify-write updates. If not set, a blind \"overwrite\" update happens.", "type": "string" }, + "gdcConfig": { + "$ref": "GoogleCloudAiplatformV1beta1GdcConfig", + "description": "Configures the Google Distributed Cloud (GDC) environment for online prediction. Only set this field when the Endpoint is to be deployed in a GDC environment." + }, "genAiAdvancedFeaturesConfig": { "$ref": "GoogleCloudAiplatformV1beta1GenAiAdvancedFeaturesConfig", "description": "Optional. Configuration for GenAiAdvancedFeatures. If the endpoint is serving GenAI models, advanced features like native RAG integration can be configured. Currently, only Model Garden models are supported." @@ -34787,6 +34877,17 @@ }, "type": "object" }, + "GoogleCloudAiplatformV1beta1GdcConfig": { + "description": "Google Distributed Cloud (GDC) config.", + "id": "GoogleCloudAiplatformV1beta1GdcConfig", + "properties": { + "zone": { + "description": "GDC zone. A cluster will be designated for the Vertex AI workload in this zone.", + "type": "string" + } + }, + "type": "object" + }, "GoogleCloudAiplatformV1beta1GeminiExample": { "description": "Format for Gemini examples used for Vertex Multimodal datasets.", "id": "GoogleCloudAiplatformV1beta1GeminiExample", @@ -40896,7 +40997,7 @@ "properties": { "deployedModel": { "$ref": "GoogleCloudAiplatformV1beta1DeployedModel", - "description": "Required. The DeployedModel to be mutated within the Endpoint. Only the following fields can be mutated: * `min_replica_count` in either DedicatedResources or AutomaticResources * `max_replica_count` in either DedicatedResources or AutomaticResources * autoscaling_metric_specs * `disable_container_logging` (v1 only) * `enable_container_logging` (v1beta1 only)" + "description": "Required. The DeployedModel to be mutated within the Endpoint. Only the following fields can be mutated: * `min_replica_count` in either DedicatedResources or AutomaticResources * `max_replica_count` in either DedicatedResources or AutomaticResources * `required_replica_count` in DedicatedResources * autoscaling_metric_specs * `disable_container_logging` (v1 only) * `enable_container_logging` (v1beta1 only)" }, "updateMask": { "description": "Required. The update mask applies to the resource. See google.protobuf.FieldMask.", @@ -52408,6 +52509,11 @@ "description": "Optional. The display name of the session.", "type": "string" }, + "expireTime": { + "description": "Optional. Timestamp of when this session is considered expired. This is *always* provided on output, regardless of what was sent on input.", + "format": "google-datetime", + "type": "string" + }, "name": { "description": "Identifier. The resource name of the session. Format: 'projects/{project}/locations/{location}/reasoningEngines/{reasoning_engine}/sessions/{session}'.", "type": "string" @@ -52420,6 +52526,11 @@ "description": "Optional. Session specific memory which stores key conversation points.", "type": "object" }, + "ttl": { + "description": "Optional. Input only. The TTL for this session.", + "format": "google-duration", + "type": "string" + }, "updateTime": { "description": "Output only. Timestamp when the session was updated.", "format": "google-datetime", @@ -53946,7 +54057,7 @@ "type": "string" }, "learningRateMultiplier": { - "description": "Optional. Multiplier for adjusting the default learning rate. Mutually exclusive with `learning_rate`.", + "description": "Optional. Multiplier for adjusting the default learning rate. Mutually exclusive with `learning_rate`. This feature is only available for 1P models.", "format": "double", "type": "number" } diff --git a/aiplatform/v1beta1/aiplatform-gen.go b/aiplatform/v1beta1/aiplatform-gen.go index 1a4dd20ae25..a066b7c2d63 100644 --- a/aiplatform/v1beta1/aiplatform-gen.go +++ b/aiplatform/v1beta1/aiplatform-gen.go @@ -8571,6 +8571,8 @@ func (s GoogleCloudAiplatformV1beta1DeployPublisherModelRequest) MarshalJSON() ( // GoogleCloudAiplatformV1beta1DeployRequest: Request message for // ModelGardenService.Deploy. type GoogleCloudAiplatformV1beta1DeployRequest struct { + // CustomModel: The custom model to deploy from a Google Cloud Storage URI. + CustomModel *GoogleCloudAiplatformV1beta1DeployRequestCustomModel `json:"customModel,omitempty"` // DeployConfig: Optional. The deploy config to use for the deployment. If not // specified, the default deploy config will be used. DeployConfig *GoogleCloudAiplatformV1beta1DeployRequestDeployConfig `json:"deployConfig,omitempty"` @@ -8587,13 +8589,13 @@ type GoogleCloudAiplatformV1beta1DeployRequest struct { // `publishers/{publisher}/models/{publisher_model}@{version_id}`, or // `publishers/hf-{hugging-face-author}/models/{hugging-face-model-name}@001`. PublisherModelName string `json:"publisherModelName,omitempty"` - // ForceSendFields is a list of field names (e.g. "DeployConfig") to + // ForceSendFields is a list of field names (e.g. "CustomModel") 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. "DeployConfig") to include in API + // NullFields is a list of field names (e.g. "CustomModel") 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. @@ -8605,6 +8607,33 @@ func (s GoogleCloudAiplatformV1beta1DeployRequest) MarshalJSON() ([]byte, error) return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudAiplatformV1beta1DeployRequestCustomModel: The custom model to +// deploy from model weights in a Google Cloud Storage URI or Model Registry +// model. +type GoogleCloudAiplatformV1beta1DeployRequestCustomModel struct { + // GcsUri: Immutable. The Google Cloud Storage URI of the custom model, storing + // weights and config files (which can be used to infer the base model). + GcsUri string `json:"gcsUri,omitempty"` + // ModelId: Optional. Deprecated. Use ModelConfig.model_user_id instead. + ModelId string `json:"modelId,omitempty"` + // ForceSendFields is a list of field names (e.g. "GcsUri") 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. "GcsUri") 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 GoogleCloudAiplatformV1beta1DeployRequestCustomModel) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudAiplatformV1beta1DeployRequestCustomModel + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudAiplatformV1beta1DeployRequestDeployConfig: The deploy config to // use for the deployment. type GoogleCloudAiplatformV1beta1DeployRequestDeployConfig struct { @@ -8686,6 +8715,13 @@ type GoogleCloudAiplatformV1beta1DeployRequestModelConfig struct { // ModelDisplayName: Optional. The user-specified display name of the uploaded // model. If not set, a default name will be used. ModelDisplayName string `json:"modelDisplayName,omitempty"` + // ModelUserId: Optional. The ID to use for the uploaded Model, which will + // become the final component of the model resource name. When not provided, + // Vertex AI will generate a value for this ID. When Model Registry model is + // provided, this field will be ignored. This value may be up to 63 characters, + // and valid characters are `[a-z0-9_-]`. The first character cannot be a + // number or hyphen. + ModelUserId string `json:"modelUserId,omitempty"` // ForceSendFields is a list of field names (e.g. "AcceptEula") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See @@ -8964,6 +9000,9 @@ type GoogleCloudAiplatformV1beta1DeployedModel struct { ExplanationSpec *GoogleCloudAiplatformV1beta1ExplanationSpec `json:"explanationSpec,omitempty"` // FasterDeploymentConfig: Configuration for faster model deployment. FasterDeploymentConfig *GoogleCloudAiplatformV1beta1FasterDeploymentConfig `json:"fasterDeploymentConfig,omitempty"` + // GdcConnectedModel: GDC pretrained / Gemini model name. The model name is a + // plain model name, e.g. gemini-1.5-flash-002. + GdcConnectedModel string `json:"gdcConnectedModel,omitempty"` // Id: Immutable. The ID of the DeployedModel. If not provided upon deployment, // Vertex AI will generate a value for this ID. This value should be 1-10 // characters, and valid characters are `/[0-9]/`. @@ -9600,6 +9639,10 @@ type GoogleCloudAiplatformV1beta1Endpoint struct { // Etag: Used to perform consistent read-modify-write updates. If not set, a // blind "overwrite" update happens. Etag string `json:"etag,omitempty"` + // GdcConfig: Configures the Google Distributed Cloud (GDC) environment for + // online prediction. Only set this field when the Endpoint is to be deployed + // in a GDC environment. + GdcConfig *GoogleCloudAiplatformV1beta1GdcConfig `json:"gdcConfig,omitempty"` // GenAiAdvancedFeaturesConfig: Optional. Configuration for // GenAiAdvancedFeatures. If the endpoint is serving GenAI models, advanced // features like native RAG integration can be configured. Currently, only @@ -15664,6 +15707,30 @@ func (s GoogleCloudAiplatformV1beta1GcsSource) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudAiplatformV1beta1GdcConfig: Google Distributed Cloud (GDC) +// config. +type GoogleCloudAiplatformV1beta1GdcConfig struct { + // Zone: GDC zone. A cluster will be designated for the Vertex AI workload in + // this zone. + 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 GoogleCloudAiplatformV1beta1GdcConfig) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudAiplatformV1beta1GdcConfig + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudAiplatformV1beta1GeminiExample: Format for Gemini examples used // for Vertex Multimodal datasets. type GoogleCloudAiplatformV1beta1GeminiExample struct { @@ -24150,7 +24217,8 @@ type GoogleCloudAiplatformV1beta1MutateDeployedModelRequest struct { // DeployedModel: Required. The DeployedModel to be mutated within the // Endpoint. Only the following fields can be mutated: * `min_replica_count` in // either DedicatedResources or AutomaticResources * `max_replica_count` in - // either DedicatedResources or AutomaticResources * autoscaling_metric_specs * + // either DedicatedResources or AutomaticResources * `required_replica_count` + // in DedicatedResources * autoscaling_metric_specs * // `disable_container_logging` (v1 only) * `enable_container_logging` (v1beta1 // only) DeployedModel *GoogleCloudAiplatformV1beta1DeployedModel `json:"deployedModel,omitempty"` @@ -40947,6 +41015,9 @@ type GoogleCloudAiplatformV1beta1Session struct { CreateTime string `json:"createTime,omitempty"` // DisplayName: Optional. The display name of the session. DisplayName string `json:"displayName,omitempty"` + // ExpireTime: Optional. Timestamp of when this session is considered expired. + // This is *always* provided on output, regardless of what was sent on input. + ExpireTime string `json:"expireTime,omitempty"` // Name: Identifier. The resource name of the session. Format: // 'projects/{project}/locations/{location}/reasoningEngines/{reasoning_engine}/ // sessions/{session}'. @@ -40954,6 +41025,8 @@ type GoogleCloudAiplatformV1beta1Session struct { // SessionState: Optional. Session specific memory which stores key // conversation points. SessionState googleapi.RawMessage `json:"sessionState,omitempty"` + // Ttl: Optional. Input only. The TTL for this session. + Ttl string `json:"ttl,omitempty"` // UpdateTime: Output only. Timestamp when the session was updated. UpdateTime string `json:"updateTime,omitempty"` // UserId: Required. Immutable. String id provided by the user @@ -43281,7 +43354,8 @@ type GoogleCloudAiplatformV1beta1SupervisedHyperParameters struct { // entire training dataset during training. EpochCount int64 `json:"epochCount,omitempty,string"` // LearningRateMultiplier: Optional. Multiplier for adjusting the default - // learning rate. Mutually exclusive with `learning_rate`. + // learning rate. Mutually exclusive with `learning_rate`. This feature is only + // available for 1P models. LearningRateMultiplier float64 `json:"learningRateMultiplier,omitempty"` // ForceSendFields is a list of field names (e.g. "AdapterSize") to // unconditionally include in API requests. By default, fields with empty or @@ -51134,6 +51208,118 @@ func (c *MediaUploadCall) Do(opts ...googleapi.CallOption) (*GoogleCloudAiplatfo return ret, nil } +type ProjectsFetchPublisherModelConfigCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// FetchPublisherModelConfig: Fetches the configs of publisher models. +// +// - name: The name of the publisher model, in the format of +// `projects/{project}/locations/{location}/publishers/{publisher}/models/{mod +// el}`. +func (r *ProjectsService) FetchPublisherModelConfig(name string) *ProjectsFetchPublisherModelConfigCall { + c := &ProjectsFetchPublisherModelConfigCall{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 *ProjectsFetchPublisherModelConfigCall) Fields(s ...googleapi.Field) *ProjectsFetchPublisherModelConfigCall { + 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 *ProjectsFetchPublisherModelConfigCall) IfNoneMatch(entityTag string) *ProjectsFetchPublisherModelConfigCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsFetchPublisherModelConfigCall) Context(ctx context.Context) *ProjectsFetchPublisherModelConfigCall { + 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 *ProjectsFetchPublisherModelConfigCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsFetchPublisherModelConfigCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+name}:fetchPublisherModelConfig") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("GET", urls, nil) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "name": c.name, + }) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "aiplatform.projects.fetchPublisherModelConfig", "request", internallog.HTTPRequest(req, nil)) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "aiplatform.projects.fetchPublisherModelConfig" call. +// Any non-2xx status code is an error. Response headers are in either +// *GoogleCloudAiplatformV1beta1PublisherModelConfig.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 *ProjectsFetchPublisherModelConfigCall) Do(opts ...googleapi.CallOption) (*GoogleCloudAiplatformV1beta1PublisherModelConfig, 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 := &GoogleCloudAiplatformV1beta1PublisherModelConfig{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + b, err := gensupport.DecodeResponseBytes(target, res) + if err != nil { + return nil, err + } + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "aiplatform.projects.fetchPublisherModelConfig", "response", internallog.HTTPResponse(res, b)) + return ret, nil +} + type ProjectsGetCacheConfigCall struct { s *Service name string @@ -51245,6 +51431,113 @@ func (c *ProjectsGetCacheConfigCall) Do(opts ...googleapi.CallOption) (*GoogleCl return ret, nil } +type ProjectsSetPublisherModelConfigCall struct { + s *Service + name string + googlecloudaiplatformv1beta1setpublishermodelconfigrequest *GoogleCloudAiplatformV1beta1SetPublisherModelConfigRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// SetPublisherModelConfig: Sets (creates or updates) configs of publisher +// models. For example, sets the request/response logging config. +// +// - name: The name of the publisher model, in the format of +// `projects/{project}/locations/{location}/publishers/{publisher}/models/{mod +// el}`. +func (r *ProjectsService) SetPublisherModelConfig(name string, googlecloudaiplatformv1beta1setpublishermodelconfigrequest *GoogleCloudAiplatformV1beta1SetPublisherModelConfigRequest) *ProjectsSetPublisherModelConfigCall { + c := &ProjectsSetPublisherModelConfigCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + c.googlecloudaiplatformv1beta1setpublishermodelconfigrequest = googlecloudaiplatformv1beta1setpublishermodelconfigrequest + 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 *ProjectsSetPublisherModelConfigCall) Fields(s ...googleapi.Field) *ProjectsSetPublisherModelConfigCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsSetPublisherModelConfigCall) Context(ctx context.Context) *ProjectsSetPublisherModelConfigCall { + 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 *ProjectsSetPublisherModelConfigCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsSetPublisherModelConfigCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) + body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.googlecloudaiplatformv1beta1setpublishermodelconfigrequest) + if err != nil { + return nil, err + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+name}:setPublisherModelConfig") + 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, + }) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "aiplatform.projects.setPublisherModelConfig", "request", internallog.HTTPRequest(req, body.Bytes())) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "aiplatform.projects.setPublisherModelConfig" 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 *ProjectsSetPublisherModelConfigCall) 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 + b, err := gensupport.DecodeResponseBytes(target, res) + if err != nil { + return nil, err + } + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "aiplatform.projects.setPublisherModelConfig", "response", internallog.HTTPResponse(res, b)) + return ret, nil +} + type ProjectsUpdateCacheConfigCall struct { s *Service name string @@ -66191,6 +66484,14 @@ func (c *ProjectsLocationsEndpointsListCall) Filter(filter string) *ProjectsLoca return c } +// GdcZone sets the optional parameter "gdcZone": Configures the Google +// Distributed Cloud (GDC) environment for online prediction. Only set this +// field when the Endpoint is to be deployed in a GDC environment. +func (c *ProjectsLocationsEndpointsListCall) GdcZone(gdcZone string) *ProjectsLocationsEndpointsListCall { + c.urlParams_.Set("gdcZone", gdcZone) + return c +} + // PageSize sets the optional parameter "pageSize": The standard list page // size. func (c *ProjectsLocationsEndpointsListCall) PageSize(pageSize int64) *ProjectsLocationsEndpointsListCall { @@ -66336,7 +66637,7 @@ type ProjectsLocationsEndpointsMutateDeployedModelCall struct { } // MutateDeployedModel: Updates an existing deployed model. Updatable fields -// include `min_replica_count`, `max_replica_count`, +// include `min_replica_count`, `max_replica_count`, `required_replica_count`, // `autoscaling_metric_specs`, `disable_container_logging` (v1 only), and // `enable_container_logging` (v1beta1 only). // diff --git a/androidpublisher/v3/androidpublisher-api.json b/androidpublisher/v3/androidpublisher-api.json index 1d749b530a8..ed40c60f397 100644 --- a/androidpublisher/v3/androidpublisher-api.json +++ b/androidpublisher/v3/androidpublisher-api.json @@ -2791,6 +2791,696 @@ } }, "resources": { + "onetimeproducts": { + "methods": { + "batchDelete": { + "description": "Deletes one or more one-time products.", + "flatPath": "androidpublisher/v3/applications/{packageName}/oneTimeProducts:batchDelete", + "httpMethod": "POST", + "id": "androidpublisher.monetization.onetimeproducts.batchDelete", + "parameterOrder": [ + "packageName" + ], + "parameters": { + "packageName": { + "description": "Required. The parent app (package name) for which the one-time products should be deleted. Must be equal to the package_name field on all the OneTimeProduct resources.", + "location": "path", + "required": true, + "type": "string" + } + }, + "path": "androidpublisher/v3/applications/{packageName}/oneTimeProducts:batchDelete", + "request": { + "$ref": "BatchDeleteOneTimeProductsRequest" + }, + "scopes": [ + "https://www.googleapis.com/auth/androidpublisher" + ] + }, + "batchGet": { + "description": "Reads one or more one-time products.", + "flatPath": "androidpublisher/v3/applications/{packageName}/oneTimeProducts:batchGet", + "httpMethod": "GET", + "id": "androidpublisher.monetization.onetimeproducts.batchGet", + "parameterOrder": [ + "packageName" + ], + "parameters": { + "packageName": { + "description": "Required. The parent app (package name) for which the products should be retrieved. Must be equal to the package_name field on all requests.", + "location": "path", + "required": true, + "type": "string" + }, + "productIds": { + "description": "Required. A list of up to 100 product IDs to retrieve. All IDs must be different.", + "location": "query", + "repeated": true, + "type": "string" + } + }, + "path": "androidpublisher/v3/applications/{packageName}/oneTimeProducts:batchGet", + "response": { + "$ref": "BatchGetOneTimeProductsResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/androidpublisher" + ] + }, + "batchUpdate": { + "description": "Creates or updates one or more one-time products.", + "flatPath": "androidpublisher/v3/applications/{packageName}/oneTimeProducts:batchUpdate", + "httpMethod": "POST", + "id": "androidpublisher.monetization.onetimeproducts.batchUpdate", + "parameterOrder": [ + "packageName" + ], + "parameters": { + "packageName": { + "description": "Required. The parent app (package name) for which the one-time products should be updated. Must be equal to the package_name field on all the OneTimeProduct resources.", + "location": "path", + "required": true, + "type": "string" + } + }, + "path": "androidpublisher/v3/applications/{packageName}/oneTimeProducts:batchUpdate", + "request": { + "$ref": "BatchUpdateOneTimeProductsRequest" + }, + "response": { + "$ref": "BatchUpdateOneTimeProductsResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/androidpublisher" + ] + }, + "delete": { + "description": "Deletes a one-time product.", + "flatPath": "androidpublisher/v3/applications/{packageName}/oneTimeProducts/{productId}", + "httpMethod": "DELETE", + "id": "androidpublisher.monetization.onetimeproducts.delete", + "parameterOrder": [ + "packageName", + "productId" + ], + "parameters": { + "latencyTolerance": { + "description": "Optional. The latency tolerance for the propagation of this product update. Defaults to latency-sensitive.", + "enum": [ + "PRODUCT_UPDATE_LATENCY_TOLERANCE_UNSPECIFIED", + "PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_SENSITIVE", + "PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_TOLERANT" + ], + "enumDescriptions": [ + "Defaults to PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_SENSITIVE.", + "The update will propagate to clients within several minutes on average and up to a few hours in rare cases. Throughput is limited to 7,200 updates per app per hour.", + "The update will propagate to clients within 24 hours. Supports high throughput of up to 720,000 updates per app per hour using batch modification methods." + ], + "location": "query", + "type": "string" + }, + "packageName": { + "description": "Required. The parent app (package name) of the one-time product to delete.", + "location": "path", + "required": true, + "type": "string" + }, + "productId": { + "description": "Required. The one-time product ID of the one-time product to delete.", + "location": "path", + "required": true, + "type": "string" + } + }, + "path": "androidpublisher/v3/applications/{packageName}/oneTimeProducts/{productId}", + "scopes": [ + "https://www.googleapis.com/auth/androidpublisher" + ] + }, + "get": { + "description": "Reads a single one-time product.", + "flatPath": "androidpublisher/v3/applications/{packageName}/oneTimeProducts/{productId}", + "httpMethod": "GET", + "id": "androidpublisher.monetization.onetimeproducts.get", + "parameterOrder": [ + "packageName", + "productId" + ], + "parameters": { + "packageName": { + "description": "Required. The parent app (package name) of the product to retrieve.", + "location": "path", + "required": true, + "type": "string" + }, + "productId": { + "description": "Required. The product ID of the product to retrieve.", + "location": "path", + "required": true, + "type": "string" + } + }, + "path": "androidpublisher/v3/applications/{packageName}/oneTimeProducts/{productId}", + "response": { + "$ref": "OneTimeProduct" + }, + "scopes": [ + "https://www.googleapis.com/auth/androidpublisher" + ] + }, + "list": { + "description": "Lists all one-time products under a given app.", + "flatPath": "androidpublisher/v3/applications/{packageName}/oneTimeProducts", + "httpMethod": "GET", + "id": "androidpublisher.monetization.onetimeproducts.list", + "parameterOrder": [ + "packageName" + ], + "parameters": { + "packageName": { + "description": "Required. The parent app (package name) for which the one-time product should be read.", + "location": "path", + "required": true, + "type": "string" + }, + "pageSize": { + "description": "Optional. The maximum number of one-time product to return. The service may return fewer than this value. If unspecified, at most 50 one-time products will be returned. The maximum value is 1000; values above 1000 will be coerced to 1000.", + "format": "int32", + "location": "query", + "type": "integer" + }, + "pageToken": { + "description": "Optional. A page token, received from a previous `ListOneTimeProducts` call. Provide this to retrieve the subsequent page. When paginating, all other parameters provided to `ListOneTimeProducts` must match the call that provided the page token.", + "location": "query", + "type": "string" + } + }, + "path": "androidpublisher/v3/applications/{packageName}/oneTimeProducts", + "response": { + "$ref": "ListOneTimeProductsResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/androidpublisher" + ] + }, + "patch": { + "description": "Creates or updates a one-time product.", + "flatPath": "androidpublisher/v3/applications/{packageName}/onetimeproducts/{productId}", + "httpMethod": "PATCH", + "id": "androidpublisher.monetization.onetimeproducts.patch", + "parameterOrder": [ + "packageName", + "productId" + ], + "parameters": { + "allowMissing": { + "description": "Optional. If set to true, and the one-time product with the given package_name and product_id doesn't exist, the one-time product will be created. If a new one-time product is created, update_mask is ignored.", + "location": "query", + "type": "boolean" + }, + "latencyTolerance": { + "description": "Optional. The latency tolerance for the propagation of this product upsert. Defaults to latency-sensitive.", + "enum": [ + "PRODUCT_UPDATE_LATENCY_TOLERANCE_UNSPECIFIED", + "PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_SENSITIVE", + "PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_TOLERANT" + ], + "enumDescriptions": [ + "Defaults to PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_SENSITIVE.", + "The update will propagate to clients within several minutes on average and up to a few hours in rare cases. Throughput is limited to 7,200 updates per app per hour.", + "The update will propagate to clients within 24 hours. Supports high throughput of up to 720,000 updates per app per hour using batch modification methods." + ], + "location": "query", + "type": "string" + }, + "packageName": { + "description": "Required. Immutable. Package name of the parent app.", + "location": "path", + "required": true, + "type": "string" + }, + "productId": { + "description": "Required. Immutable. Unique product ID of the product. Unique within the parent app. Product IDs must start with a number or lowercase letter, and can contain numbers (0-9), lowercase letters (a-z), underscores (_), and periods (.).", + "location": "path", + "required": true, + "type": "string" + }, + "regionsVersion.version": { + "description": "Required. A string representing the version of available regions being used for the specified resource. Regional prices and latest supported version for the resource have to be specified according to the information published in [this article](https://support.google.com/googleplay/android-developer/answer/10532353). Each time the supported locations substantially change, the version will be incremented. Using this field will ensure that creating and updating the resource with an older region's version and set of regional prices and currencies will succeed even though a new version is available.", + "location": "query", + "type": "string" + }, + "updateMask": { + "description": "Required. The list of fields to be updated.", + "format": "google-fieldmask", + "location": "query", + "type": "string" + } + }, + "path": "androidpublisher/v3/applications/{packageName}/onetimeproducts/{productId}", + "request": { + "$ref": "OneTimeProduct" + }, + "response": { + "$ref": "OneTimeProduct" + }, + "scopes": [ + "https://www.googleapis.com/auth/androidpublisher" + ] + } + }, + "resources": { + "purchaseOptions": { + "methods": { + "batchDelete": { + "description": "Deletes purchase options across one or multiple one-time products. By default this operation will fail if there are any existing offers under the deleted purchase options. Use the force parameter to override the default behavior.", + "flatPath": "androidpublisher/v3/applications/{packageName}/oneTimeProducts/{productId}/purchaseOptions:batchDelete", + "httpMethod": "POST", + "id": "androidpublisher.monetization.onetimeproducts.purchaseOptions.batchDelete", + "parameterOrder": [ + "packageName", + "productId" + ], + "parameters": { + "packageName": { + "description": "Required. The parent app (package name) of the purchase options to delete.", + "location": "path", + "required": true, + "type": "string" + }, + "productId": { + "description": "Required. The product ID of the parent one-time product, if all purchase options to delete belong to the same one-time product. If this batch delete spans multiple one-time products, set this field to \"-\".", + "location": "path", + "required": true, + "type": "string" + } + }, + "path": "androidpublisher/v3/applications/{packageName}/oneTimeProducts/{productId}/purchaseOptions:batchDelete", + "request": { + "$ref": "BatchDeletePurchaseOptionsRequest" + }, + "scopes": [ + "https://www.googleapis.com/auth/androidpublisher" + ] + }, + "batchUpdateStates": { + "description": "Activates or deactivates purchase options across one or multiple one-time products.", + "flatPath": "androidpublisher/v3/applications/{packageName}/oneTimeProducts/{productId}/purchaseOptions:batchUpdateStates", + "httpMethod": "POST", + "id": "androidpublisher.monetization.onetimeproducts.purchaseOptions.batchUpdateStates", + "parameterOrder": [ + "packageName", + "productId" + ], + "parameters": { + "packageName": { + "description": "Required. The parent app (package name) of the updated purchase options.", + "location": "path", + "required": true, + "type": "string" + }, + "productId": { + "description": "Required. The product ID of the parent one-time product, if all updated purchase options belong to the same one-time product. If this batch update spans multiple one-time products, set this field to \"-\".", + "location": "path", + "required": true, + "type": "string" + } + }, + "path": "androidpublisher/v3/applications/{packageName}/oneTimeProducts/{productId}/purchaseOptions:batchUpdateStates", + "request": { + "$ref": "BatchUpdatePurchaseOptionStatesRequest" + }, + "response": { + "$ref": "BatchUpdatePurchaseOptionStatesResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/androidpublisher" + ] + } + }, + "resources": { + "offers": { + "methods": { + "activate": { + "description": "Activates a one-time product offer.", + "flatPath": "androidpublisher/v3/applications/{packageName}/oneTimeProducts/{productId}/purchaseOptions/{purchaseOptionId}/offers/{offerId}:activate", + "httpMethod": "POST", + "id": "androidpublisher.monetization.onetimeproducts.purchaseOptions.offers.activate", + "parameterOrder": [ + "packageName", + "productId", + "purchaseOptionId", + "offerId" + ], + "parameters": { + "offerId": { + "description": "Required. The offer ID of the offer to activate.", + "location": "path", + "required": true, + "type": "string" + }, + "packageName": { + "description": "Required. The parent app (package name) of the offer to activate.", + "location": "path", + "required": true, + "type": "string" + }, + "productId": { + "description": "Required. The parent one-time product (ID) of the offer to activate.", + "location": "path", + "required": true, + "type": "string" + }, + "purchaseOptionId": { + "description": "Required. The parent purchase option (ID) of the offer to activate.", + "location": "path", + "required": true, + "type": "string" + } + }, + "path": "androidpublisher/v3/applications/{packageName}/oneTimeProducts/{productId}/purchaseOptions/{purchaseOptionId}/offers/{offerId}:activate", + "request": { + "$ref": "ActivateOneTimeProductOfferRequest" + }, + "response": { + "$ref": "OneTimeProductOffer" + }, + "scopes": [ + "https://www.googleapis.com/auth/androidpublisher" + ] + }, + "batchDelete": { + "description": "Deletes one or more one-time product offers.", + "flatPath": "androidpublisher/v3/applications/{packageName}/oneTimeProducts/{productId}/purchaseOptions/{purchaseOptionId}/offers:batchDelete", + "httpMethod": "POST", + "id": "androidpublisher.monetization.onetimeproducts.purchaseOptions.offers.batchDelete", + "parameterOrder": [ + "packageName", + "productId", + "purchaseOptionId" + ], + "parameters": { + "packageName": { + "description": "Required. The parent app (package name) of the offers to delete. Must be equal to the package_name field on all the OneTimeProductOffer resources.", + "location": "path", + "required": true, + "type": "string" + }, + "productId": { + "description": "Required. The product ID of the parent one-time product, if all offers to delete belong to the same product. If this request spans multiple one-time products, set this field to \"-\".", + "location": "path", + "required": true, + "type": "string" + }, + "purchaseOptionId": { + "description": "Required. The parent purchase option (ID) for which the offers should be deleted. May be specified as '-' to update offers from multiple purchase options.", + "location": "path", + "required": true, + "type": "string" + } + }, + "path": "androidpublisher/v3/applications/{packageName}/oneTimeProducts/{productId}/purchaseOptions/{purchaseOptionId}/offers:batchDelete", + "request": { + "$ref": "BatchDeleteOneTimeProductOffersRequest" + }, + "scopes": [ + "https://www.googleapis.com/auth/androidpublisher" + ] + }, + "batchGet": { + "description": "Reads one or more one-time product offers.", + "flatPath": "androidpublisher/v3/applications/{packageName}/oneTimeProducts/{productId}/purchaseOptions/{purchaseOptionId}/offers:batchGet", + "httpMethod": "POST", + "id": "androidpublisher.monetization.onetimeproducts.purchaseOptions.offers.batchGet", + "parameterOrder": [ + "packageName", + "productId", + "purchaseOptionId" + ], + "parameters": { + "packageName": { + "description": "Required. The parent app (package name) of the updated offers. Must be equal to the package_name field on all the updated OneTimeProductOffer resources.", + "location": "path", + "required": true, + "type": "string" + }, + "productId": { + "description": "Required. The product ID of the parent one-time product, if all updated offers belong to the same product. If this request spans multiple one-time products, set this field to \"-\".", + "location": "path", + "required": true, + "type": "string" + }, + "purchaseOptionId": { + "description": "Required. The parent purchase option (ID) for which the offers should be updated. May be specified as '-' to update offers from multiple purchase options.", + "location": "path", + "required": true, + "type": "string" + } + }, + "path": "androidpublisher/v3/applications/{packageName}/oneTimeProducts/{productId}/purchaseOptions/{purchaseOptionId}/offers:batchGet", + "request": { + "$ref": "BatchGetOneTimeProductOffersRequest" + }, + "response": { + "$ref": "BatchGetOneTimeProductOffersResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/androidpublisher" + ] + }, + "batchUpdate": { + "description": "Creates or updates one or more one-time product offers.", + "flatPath": "androidpublisher/v3/applications/{packageName}/oneTimeProducts/{productId}/purchaseOptions/{purchaseOptionId}/offers:batchUpdate", + "httpMethod": "POST", + "id": "androidpublisher.monetization.onetimeproducts.purchaseOptions.offers.batchUpdate", + "parameterOrder": [ + "packageName", + "productId", + "purchaseOptionId" + ], + "parameters": { + "packageName": { + "description": "Required. The parent app (package name) of the updated offers. Must be equal to the package_name field on all the updated OneTimeProductOffer resources.", + "location": "path", + "required": true, + "type": "string" + }, + "productId": { + "description": "Required. The product ID of the parent one-time product, if all updated offers belong to the same product. If this request spans multiple one-time products, set this field to \"-\".", + "location": "path", + "required": true, + "type": "string" + }, + "purchaseOptionId": { + "description": "Required. The parent purchase option (ID) for which the offers should be updated. May be specified as '-' to update offers from multiple purchase options.", + "location": "path", + "required": true, + "type": "string" + } + }, + "path": "androidpublisher/v3/applications/{packageName}/oneTimeProducts/{productId}/purchaseOptions/{purchaseOptionId}/offers:batchUpdate", + "request": { + "$ref": "BatchUpdateOneTimeProductOffersRequest" + }, + "response": { + "$ref": "BatchUpdateOneTimeProductOffersResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/androidpublisher" + ] + }, + "batchUpdateStates": { + "description": "Updates a batch of one-time product offer states.", + "flatPath": "androidpublisher/v3/applications/{packageName}/oneTimeProducts/{productId}/purchaseOptions/{purchaseOptionId}/offers:batchUpdateStates", + "httpMethod": "POST", + "id": "androidpublisher.monetization.onetimeproducts.purchaseOptions.offers.batchUpdateStates", + "parameterOrder": [ + "packageName", + "productId", + "purchaseOptionId" + ], + "parameters": { + "packageName": { + "description": "Required. The parent app (package name) of the updated one-time product offers.", + "location": "path", + "required": true, + "type": "string" + }, + "productId": { + "description": "Required. The product ID of the parent one-time product, if all updated offers belong to the same one-time product. If this batch update spans multiple one-time products, set this field to \"-\".", + "location": "path", + "required": true, + "type": "string" + }, + "purchaseOptionId": { + "description": "Required. The purchase option ID of the parent purchase option, if all updated offers belong to the same purchase option. If this batch update spans multiple purchase options, set this field to \"-\".", + "location": "path", + "required": true, + "type": "string" + } + }, + "path": "androidpublisher/v3/applications/{packageName}/oneTimeProducts/{productId}/purchaseOptions/{purchaseOptionId}/offers:batchUpdateStates", + "request": { + "$ref": "BatchUpdateOneTimeProductOfferStatesRequest" + }, + "response": { + "$ref": "BatchUpdateOneTimeProductOfferStatesResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/androidpublisher" + ] + }, + "cancel": { + "description": "Cancels a one-time product offer.", + "flatPath": "androidpublisher/v3/applications/{packageName}/oneTimeProducts/{productId}/purchaseOptions/{purchaseOptionId}/offers/{offerId}:cancel", + "httpMethod": "POST", + "id": "androidpublisher.monetization.onetimeproducts.purchaseOptions.offers.cancel", + "parameterOrder": [ + "packageName", + "productId", + "purchaseOptionId", + "offerId" + ], + "parameters": { + "offerId": { + "description": "Required. The offer ID of the offer to cancel.", + "location": "path", + "required": true, + "type": "string" + }, + "packageName": { + "description": "Required. The parent app (package name) of the offer to cancel.", + "location": "path", + "required": true, + "type": "string" + }, + "productId": { + "description": "Required. The parent one-time product (ID) of the offer to cancel.", + "location": "path", + "required": true, + "type": "string" + }, + "purchaseOptionId": { + "description": "Required. The parent purchase option (ID) of the offer to cancel.", + "location": "path", + "required": true, + "type": "string" + } + }, + "path": "androidpublisher/v3/applications/{packageName}/oneTimeProducts/{productId}/purchaseOptions/{purchaseOptionId}/offers/{offerId}:cancel", + "request": { + "$ref": "CancelOneTimeProductOfferRequest" + }, + "response": { + "$ref": "OneTimeProductOffer" + }, + "scopes": [ + "https://www.googleapis.com/auth/androidpublisher" + ] + }, + "deactivate": { + "description": "Deactivates a one-time product offer.", + "flatPath": "androidpublisher/v3/applications/{packageName}/oneTimeProducts/{productId}/purchaseOptions/{purchaseOptionId}/offers/{offerId}:deactivate", + "httpMethod": "POST", + "id": "androidpublisher.monetization.onetimeproducts.purchaseOptions.offers.deactivate", + "parameterOrder": [ + "packageName", + "productId", + "purchaseOptionId", + "offerId" + ], + "parameters": { + "offerId": { + "description": "Required. The offer ID of the offer to deactivate.", + "location": "path", + "required": true, + "type": "string" + }, + "packageName": { + "description": "Required. The parent app (package name) of the offer to deactivate.", + "location": "path", + "required": true, + "type": "string" + }, + "productId": { + "description": "Required. The parent one-time product (ID) of the offer to deactivate.", + "location": "path", + "required": true, + "type": "string" + }, + "purchaseOptionId": { + "description": "Required. The parent purchase option (ID) of the offer to deactivate.", + "location": "path", + "required": true, + "type": "string" + } + }, + "path": "androidpublisher/v3/applications/{packageName}/oneTimeProducts/{productId}/purchaseOptions/{purchaseOptionId}/offers/{offerId}:deactivate", + "request": { + "$ref": "DeactivateOneTimeProductOfferRequest" + }, + "response": { + "$ref": "OneTimeProductOffer" + }, + "scopes": [ + "https://www.googleapis.com/auth/androidpublisher" + ] + }, + "list": { + "description": "Lists all offers under a given app, product, or purchase option.", + "flatPath": "androidpublisher/v3/applications/{packageName}/oneTimeProducts/{productId}/purchaseOptions/{purchaseOptionId}/offers", + "httpMethod": "GET", + "id": "androidpublisher.monetization.onetimeproducts.purchaseOptions.offers.list", + "parameterOrder": [ + "packageName", + "productId", + "purchaseOptionId" + ], + "parameters": { + "packageName": { + "description": "Required. The parent app (package name) for which the offers should be read.", + "location": "path", + "required": true, + "type": "string" + }, + "pageSize": { + "description": "Optional. The maximum number of offers to return. The service may return fewer than this value. If unspecified, at most 50 offers will be returned. The maximum value is 1000; values above 1000 will be coerced to 1000.", + "format": "int32", + "location": "query", + "type": "integer" + }, + "pageToken": { + "description": "Optional. A page token, received from a previous `ListOneTimeProductsOffers` call. Provide this to retrieve the subsequent page. When paginating, product_id, package_name and purchase_option_id provided to `ListOneTimeProductsOffersRequest` must match the call that provided the page token.", + "location": "query", + "type": "string" + }, + "productId": { + "description": "Required. The parent one-time product (ID) for which the offers should be read. May be specified as '-' to read all offers under an app.", + "location": "path", + "required": true, + "type": "string" + }, + "purchaseOptionId": { + "description": "Required. The parent purchase option (ID) for which the offers should be read. May be specified as '-' to read all offers under a one-time product or an app. Must be specified as '-' if product_id is specified as '-'.", + "location": "path", + "required": true, + "type": "string" + } + }, + "path": "androidpublisher/v3/applications/{packageName}/oneTimeProducts/{productId}/purchaseOptions/{purchaseOptionId}/offers", + "response": { + "$ref": "ListOneTimeProductOffersResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/androidpublisher" + ] + } + } + } + } + } + } + }, "subscriptions": { "methods": { "archive": { @@ -4831,7 +5521,7 @@ } } }, - "revision": "20250710", + "revision": "20250719", "rootUrl": "https://androidpublisher.googleapis.com/", "schemas": { "Abi": { @@ -4928,6 +5618,76 @@ }, "type": "object" }, + "ActivateOneTimeProductOfferRequest": { + "description": "Request message for ActivateOneTimeProductOffer.", + "id": "ActivateOneTimeProductOfferRequest", + "properties": { + "latencyTolerance": { + "description": "Optional. The latency tolerance for the propagation of this update. Defaults to latency-sensitive.", + "enum": [ + "PRODUCT_UPDATE_LATENCY_TOLERANCE_UNSPECIFIED", + "PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_SENSITIVE", + "PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_TOLERANT" + ], + "enumDescriptions": [ + "Defaults to PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_SENSITIVE.", + "The update will propagate to clients within several minutes on average and up to a few hours in rare cases. Throughput is limited to 7,200 updates per app per hour.", + "The update will propagate to clients within 24 hours. Supports high throughput of up to 720,000 updates per app per hour using batch modification methods." + ], + "type": "string" + }, + "offerId": { + "description": "Required. The offer ID of the offer to activate.", + "type": "string" + }, + "packageName": { + "description": "Required. The parent app (package name) of the offer to activate.", + "type": "string" + }, + "productId": { + "description": "Required. The parent one-time product (ID) of the offer to activate.", + "type": "string" + }, + "purchaseOptionId": { + "description": "Required. The parent purchase option (ID) of the offer to activate.", + "type": "string" + } + }, + "type": "object" + }, + "ActivatePurchaseOptionRequest": { + "description": "Request message for UpdatePurchaseOptionState.", + "id": "ActivatePurchaseOptionRequest", + "properties": { + "latencyTolerance": { + "description": "Optional. The latency tolerance for the propagation of this product update. Defaults to latency-sensitive.", + "enum": [ + "PRODUCT_UPDATE_LATENCY_TOLERANCE_UNSPECIFIED", + "PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_SENSITIVE", + "PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_TOLERANT" + ], + "enumDescriptions": [ + "Defaults to PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_SENSITIVE.", + "The update will propagate to clients within several minutes on average and up to a few hours in rare cases. Throughput is limited to 7,200 updates per app per hour.", + "The update will propagate to clients within 24 hours. Supports high throughput of up to 720,000 updates per app per hour using batch modification methods." + ], + "type": "string" + }, + "packageName": { + "description": "Required. The parent app (package name) of the purchase option to activate.", + "type": "string" + }, + "productId": { + "description": "Required. The parent one-time product (ID) of the purchase option to activate.", + "type": "string" + }, + "purchaseOptionId": { + "description": "Required. The purchase option ID of the purchase option to activate.", + "type": "string" + } + }, + "type": "object" + }, "ActivateSubscriptionOfferRequest": { "description": "Request message for ActivateSubscriptionOffer.", "id": "ActivateSubscriptionOfferRequest", @@ -5479,6 +6239,90 @@ }, "type": "object" }, + "BatchDeleteOneTimeProductOffersRequest": { + "description": "Request message for BatchDeleteOneTimeProductOffers.", + "id": "BatchDeleteOneTimeProductOffersRequest", + "properties": { + "requests": { + "description": "Required. A list of update requests of up to 100 elements. All requests must correspond to different offers.", + "items": { + "$ref": "DeleteOneTimeProductOfferRequest" + }, + "type": "array" + } + }, + "type": "object" + }, + "BatchDeleteOneTimeProductsRequest": { + "description": "Request message for BatchDeleteOneTimeProduct.", + "id": "BatchDeleteOneTimeProductsRequest", + "properties": { + "requests": { + "description": "Required. A list of delete requests of up to 100 elements. All requests must delete different one-time products.", + "items": { + "$ref": "DeleteOneTimeProductRequest" + }, + "type": "array" + } + }, + "type": "object" + }, + "BatchDeletePurchaseOptionsRequest": { + "description": "Request message for BatchDeletePurchaseOption.", + "id": "BatchDeletePurchaseOptionsRequest", + "properties": { + "requests": { + "description": "Required. A list of delete requests of up to 100 elements. All requests must delete purchase options from different one-time products.", + "items": { + "$ref": "DeletePurchaseOptionRequest" + }, + "type": "array" + } + }, + "type": "object" + }, + "BatchGetOneTimeProductOffersRequest": { + "description": "Request message for the BatchGetOneTimeProductOffers endpoint.", + "id": "BatchGetOneTimeProductOffersRequest", + "properties": { + "requests": { + "description": "Required. A list of get requests of up to 100 elements. All requests must retrieve different offers.", + "items": { + "$ref": "GetOneTimeProductOfferRequest" + }, + "type": "array" + } + }, + "type": "object" + }, + "BatchGetOneTimeProductOffersResponse": { + "description": "Response message for the BatchGetOneTimeProductOffers endpoint.", + "id": "BatchGetOneTimeProductOffersResponse", + "properties": { + "oneTimeProductOffers": { + "description": "The list of updated one-time product offers, in the same order as the request.", + "items": { + "$ref": "OneTimeProductOffer" + }, + "type": "array" + } + }, + "type": "object" + }, + "BatchGetOneTimeProductsResponse": { + "description": "Response message for the BatchGetOneTimeProducts endpoint.", + "id": "BatchGetOneTimeProductsResponse", + "properties": { + "oneTimeProducts": { + "description": "The list of requested one-time products, in the same order as the request.", + "items": { + "$ref": "OneTimeProduct" + }, + "type": "array" + } + }, + "type": "object" + }, "BatchGetOrdersResponse": { "description": "Response for the orders.batchGet API.", "id": "BatchGetOrdersResponse", @@ -5590,6 +6434,118 @@ }, "type": "object" }, + "BatchUpdateOneTimeProductOfferStatesRequest": { + "description": "Request message for BatchUpdateOneTimeProductOfferStates.", + "id": "BatchUpdateOneTimeProductOfferStatesRequest", + "properties": { + "requests": { + "description": "Required. The update request list of up to 100 elements. All requests must update different offers.", + "items": { + "$ref": "UpdateOneTimeProductOfferStateRequest" + }, + "type": "array" + } + }, + "type": "object" + }, + "BatchUpdateOneTimeProductOfferStatesResponse": { + "description": "Response message for BatchUpdateOneTimeProductOfferStates.", + "id": "BatchUpdateOneTimeProductOfferStatesResponse", + "properties": { + "oneTimeProductOffers": { + "description": "The updated one-time product offers list, in the same order as the request.", + "items": { + "$ref": "OneTimeProductOffer" + }, + "type": "array" + } + }, + "type": "object" + }, + "BatchUpdateOneTimeProductOffersRequest": { + "description": "Request message for BatchUpdateOneTimeProductOffers.", + "id": "BatchUpdateOneTimeProductOffersRequest", + "properties": { + "requests": { + "description": "Required. A list of update requests of up to 100 elements. All requests must update different offers.", + "items": { + "$ref": "UpdateOneTimeProductOfferRequest" + }, + "type": "array" + } + }, + "type": "object" + }, + "BatchUpdateOneTimeProductOffersResponse": { + "description": "Response message for BatchUpdateOneTimeProductOffers.", + "id": "BatchUpdateOneTimeProductOffersResponse", + "properties": { + "oneTimeProductOffers": { + "description": "The list of updated one-time product offers, in the same order as the request.", + "items": { + "$ref": "OneTimeProductOffer" + }, + "type": "array" + } + }, + "type": "object" + }, + "BatchUpdateOneTimeProductsRequest": { + "description": "Request message for BatchUpdateOneTimeProduct.", + "id": "BatchUpdateOneTimeProductsRequest", + "properties": { + "requests": { + "description": "Required. A list of update requests of up to 100 elements. All requests must update different one-time products.", + "items": { + "$ref": "UpdateOneTimeProductRequest" + }, + "type": "array" + } + }, + "type": "object" + }, + "BatchUpdateOneTimeProductsResponse": { + "description": "Response message for BatchUpdateOneTimeProduct.", + "id": "BatchUpdateOneTimeProductsResponse", + "properties": { + "oneTimeProducts": { + "description": "The list of updated one-time products list, in the same order as the request.", + "items": { + "$ref": "OneTimeProduct" + }, + "type": "array" + } + }, + "type": "object" + }, + "BatchUpdatePurchaseOptionStatesRequest": { + "description": "Request message for BatchUpdatePurchaseOptionStates.", + "id": "BatchUpdatePurchaseOptionStatesRequest", + "properties": { + "requests": { + "description": "Required. The update request list of up to 100 elements. All requests must update different purchase options.", + "items": { + "$ref": "UpdatePurchaseOptionStateRequest" + }, + "type": "array" + } + }, + "type": "object" + }, + "BatchUpdatePurchaseOptionStatesResponse": { + "description": "Response message for BatchUpdatePurchaseOptionStates.", + "id": "BatchUpdatePurchaseOptionStatesResponse", + "properties": { + "oneTimeProducts": { + "description": "The list of updated one-time products. This list will match the requests one to one, in the same order.", + "items": { + "$ref": "OneTimeProduct" + }, + "type": "array" + } + }, + "type": "object" + }, "BatchUpdateSubscriptionOfferStatesRequest": { "description": "Request message for BatchUpdateSubscriptionOfferStates.", "id": "BatchUpdateSubscriptionOfferStatesRequest", @@ -5743,6 +6699,43 @@ "properties": {}, "type": "object" }, + "CancelOneTimeProductOfferRequest": { + "description": "Request message for CancelOneTimeProductOffer.", + "id": "CancelOneTimeProductOfferRequest", + "properties": { + "latencyTolerance": { + "description": "Optional. The latency tolerance for the propagation of this update. Defaults to latency-sensitive.", + "enum": [ + "PRODUCT_UPDATE_LATENCY_TOLERANCE_UNSPECIFIED", + "PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_SENSITIVE", + "PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_TOLERANT" + ], + "enumDescriptions": [ + "Defaults to PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_SENSITIVE.", + "The update will propagate to clients within several minutes on average and up to a few hours in rare cases. Throughput is limited to 7,200 updates per app per hour.", + "The update will propagate to clients within 24 hours. Supports high throughput of up to 720,000 updates per app per hour using batch modification methods." + ], + "type": "string" + }, + "offerId": { + "description": "Required. The offer ID of the offer to cancel.", + "type": "string" + }, + "packageName": { + "description": "Required. The parent app (package name) of the offer to cancel.", + "type": "string" + }, + "productId": { + "description": "Required. The parent one-time product (ID) of the offer to cancel.", + "type": "string" + }, + "purchaseOptionId": { + "description": "Required. The parent purchase option (ID) of the offer to cancel.", + "type": "string" + } + }, + "type": "object" + }, "CancelSurveyResult": { "description": "Result of the cancel survey when the subscription was canceled by the user.", "id": "CancelSurveyResult", @@ -5957,6 +6950,76 @@ }, "type": "object" }, + "DeactivateOneTimeProductOfferRequest": { + "description": "Request message for DeactivateOneTimeProductOffer.", + "id": "DeactivateOneTimeProductOfferRequest", + "properties": { + "latencyTolerance": { + "description": "Optional. The latency tolerance for the propagation of this update. Defaults to latency-sensitive.", + "enum": [ + "PRODUCT_UPDATE_LATENCY_TOLERANCE_UNSPECIFIED", + "PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_SENSITIVE", + "PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_TOLERANT" + ], + "enumDescriptions": [ + "Defaults to PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_SENSITIVE.", + "The update will propagate to clients within several minutes on average and up to a few hours in rare cases. Throughput is limited to 7,200 updates per app per hour.", + "The update will propagate to clients within 24 hours. Supports high throughput of up to 720,000 updates per app per hour using batch modification methods." + ], + "type": "string" + }, + "offerId": { + "description": "Required. The offer ID of the offer to deactivate.", + "type": "string" + }, + "packageName": { + "description": "Required. The parent app (package name) of the offer to deactivate.", + "type": "string" + }, + "productId": { + "description": "Required. The parent one-time product (ID) of the offer to deactivate.", + "type": "string" + }, + "purchaseOptionId": { + "description": "Required. The parent purchase option (ID) of the offer to deactivate.", + "type": "string" + } + }, + "type": "object" + }, + "DeactivatePurchaseOptionRequest": { + "description": "Request message for UpdatePurchaseOptionState.", + "id": "DeactivatePurchaseOptionRequest", + "properties": { + "latencyTolerance": { + "description": "Optional. The latency tolerance for the propagation of this product update. Defaults to latency-sensitive.", + "enum": [ + "PRODUCT_UPDATE_LATENCY_TOLERANCE_UNSPECIFIED", + "PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_SENSITIVE", + "PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_TOLERANT" + ], + "enumDescriptions": [ + "Defaults to PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_SENSITIVE.", + "The update will propagate to clients within several minutes on average and up to a few hours in rare cases. Throughput is limited to 7,200 updates per app per hour.", + "The update will propagate to clients within 24 hours. Supports high throughput of up to 720,000 updates per app per hour using batch modification methods." + ], + "type": "string" + }, + "packageName": { + "description": "Required. The parent app (package name) of the purchase option to deactivate.", + "type": "string" + }, + "productId": { + "description": "Required. The parent one-time product (ID) of the purchase option to deactivate.", + "type": "string" + }, + "purchaseOptionId": { + "description": "Required. The purchase option ID of the purchase option to deactivate.", + "type": "string" + } + }, + "type": "object" + }, "DeactivateSubscriptionOfferRequest": { "description": "Request message for DeactivateSubscriptionOffer.", "id": "DeactivateSubscriptionOfferRequest", @@ -6005,6 +7068,109 @@ }, "type": "object" }, + "DeleteOneTimeProductOfferRequest": { + "description": "Request message for deleting an one-time product offer.", + "id": "DeleteOneTimeProductOfferRequest", + "properties": { + "latencyTolerance": { + "description": "Optional. The latency tolerance for the propagation of this product update. Defaults to latency-sensitive.", + "enum": [ + "PRODUCT_UPDATE_LATENCY_TOLERANCE_UNSPECIFIED", + "PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_SENSITIVE", + "PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_TOLERANT" + ], + "enumDescriptions": [ + "Defaults to PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_SENSITIVE.", + "The update will propagate to clients within several minutes on average and up to a few hours in rare cases. Throughput is limited to 7,200 updates per app per hour.", + "The update will propagate to clients within 24 hours. Supports high throughput of up to 720,000 updates per app per hour using batch modification methods." + ], + "type": "string" + }, + "offerId": { + "description": "Required. The unique offer ID of the offer to delete.", + "type": "string" + }, + "packageName": { + "description": "Required. The parent app (package name) of the offer to delete.", + "type": "string" + }, + "productId": { + "description": "Required. The parent one-time product (ID) of the offer to delete.", + "type": "string" + }, + "purchaseOptionId": { + "description": "Required. The parent purchase option (ID) of the offer to delete.", + "type": "string" + } + }, + "type": "object" + }, + "DeleteOneTimeProductRequest": { + "description": "Request message for deleting a one-time product.", + "id": "DeleteOneTimeProductRequest", + "properties": { + "latencyTolerance": { + "description": "Optional. The latency tolerance for the propagation of this product update. Defaults to latency-sensitive.", + "enum": [ + "PRODUCT_UPDATE_LATENCY_TOLERANCE_UNSPECIFIED", + "PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_SENSITIVE", + "PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_TOLERANT" + ], + "enumDescriptions": [ + "Defaults to PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_SENSITIVE.", + "The update will propagate to clients within several minutes on average and up to a few hours in rare cases. Throughput is limited to 7,200 updates per app per hour.", + "The update will propagate to clients within 24 hours. Supports high throughput of up to 720,000 updates per app per hour using batch modification methods." + ], + "type": "string" + }, + "packageName": { + "description": "Required. The parent app (package name) of the one-time product to delete.", + "type": "string" + }, + "productId": { + "description": "Required. The one-time product ID of the one-time product to delete.", + "type": "string" + } + }, + "type": "object" + }, + "DeletePurchaseOptionRequest": { + "description": "Request message for deleting a purchase option.", + "id": "DeletePurchaseOptionRequest", + "properties": { + "force": { + "description": "Optional. This field has no effect for purchase options with no offers under them. For purchase options with associated offers: * If `force` is set to false (default), an error will be returned. * If `force` is set to true, any associated offers under the purchase option will be deleted.", + "type": "boolean" + }, + "latencyTolerance": { + "description": "Optional. The latency tolerance for the propagation of this product update. Defaults to latency-sensitive.", + "enum": [ + "PRODUCT_UPDATE_LATENCY_TOLERANCE_UNSPECIFIED", + "PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_SENSITIVE", + "PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_TOLERANT" + ], + "enumDescriptions": [ + "Defaults to PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_SENSITIVE.", + "The update will propagate to clients within several minutes on average and up to a few hours in rare cases. Throughput is limited to 7,200 updates per app per hour.", + "The update will propagate to clients within 24 hours. Supports high throughput of up to 720,000 updates per app per hour using batch modification methods." + ], + "type": "string" + }, + "packageName": { + "description": "Required. The parent app (package name) of the purchase option to delete.", + "type": "string" + }, + "productId": { + "description": "Required. The parent one-time product (ID) of the purchase option to delete.", + "type": "string" + }, + "purchaseOptionId": { + "description": "Required. The purchase option ID of the purchase option to delete.", + "type": "string" + } + }, + "type": "object" + }, "DeobfuscationFile": { "description": "Represents a deobfuscation file.", "id": "DeobfuscationFile", @@ -6776,6 +7942,29 @@ }, "type": "object" }, + "GetOneTimeProductOfferRequest": { + "description": "Request message for GetOneTimeProductOffers.", + "id": "GetOneTimeProductOfferRequest", + "properties": { + "offerId": { + "description": "Required. The unique offer ID of the offer to get.", + "type": "string" + }, + "packageName": { + "description": "Required. The parent app (package name) of the offer to get.", + "type": "string" + }, + "productId": { + "description": "Required. The parent one-time product (ID) of the offer to get.", + "type": "string" + }, + "purchaseOptionId": { + "description": "Required. The parent purchase option (ID) of the offer to get.", + "type": "string" + } + }, + "type": "object" + }, "GetSubscriptionOfferRequest": { "description": "Request message for GetSubscriptionOffer.", "id": "GetSubscriptionOfferRequest", @@ -7422,6 +8611,42 @@ }, "type": "object" }, + "ListOneTimeProductOffersResponse": { + "description": "Response message for ListOneTimeProductOffers.", + "id": "ListOneTimeProductOffersResponse", + "properties": { + "nextPageToken": { + "description": "A token, which can be sent as `page_token` to retrieve the next page. If this field is omitted, there are no subsequent pages.", + "type": "string" + }, + "oneTimeProductOffers": { + "description": "The one_time_product offers from the specified request.", + "items": { + "$ref": "OneTimeProductOffer" + }, + "type": "array" + } + }, + "type": "object" + }, + "ListOneTimeProductsResponse": { + "description": "Response message for ListOneTimeProducts.", + "id": "ListOneTimeProductsResponse", + "properties": { + "nextPageToken": { + "description": "A token, which can be sent as `page_token` to retrieve the next page. If this field is omitted, there are no subsequent pages.", + "type": "string" + }, + "oneTimeProducts": { + "description": "The one-time products from the specified app.", + "items": { + "$ref": "OneTimeProduct" + }, + "type": "array" + } + }, + "type": "object" + }, "ListSubscriptionOffersResponse": { "description": "Response message for ListSubscriptionOffers.", "id": "ListSubscriptionOffersResponse", @@ -7711,87 +8936,494 @@ }, "type": "object" }, - "MultiAbi": { - "description": "Represents a list of ABIs.", - "id": "MultiAbi", + "MultiAbi": { + "description": "Represents a list of ABIs.", + "id": "MultiAbi", + "properties": { + "abi": { + "description": "A list of targeted ABIs, as represented by the Android Platform", + "items": { + "$ref": "Abi" + }, + "type": "array" + } + }, + "type": "object" + }, + "MultiAbiTargeting": { + "description": "Targeting based on multiple abis.", + "id": "MultiAbiTargeting", + "properties": { + "alternatives": { + "description": "Targeting of other sibling directories that were in the Bundle. For main splits this is targeting of other main splits.", + "items": { + "$ref": "MultiAbi" + }, + "type": "array" + }, + "value": { + "description": "Value of a multi abi.", + "items": { + "$ref": "MultiAbi" + }, + "type": "array" + } + }, + "type": "object" + }, + "OfferDetails": { + "description": "Offer details information related to a purchase line item.", + "id": "OfferDetails", + "properties": { + "basePlanId": { + "description": "The base plan ID. Present for all base plan and offers.", + "type": "string" + }, + "offerId": { + "description": "The offer ID. Only present for discounted offers.", + "type": "string" + }, + "offerTags": { + "description": "The latest offer tags associated with the offer. It includes tags inherited from the base plan.", + "items": { + "type": "string" + }, + "type": "array" + } + }, + "type": "object" + }, + "OfferTag": { + "description": "Represents a custom tag specified for a product offer.", + "id": "OfferTag", + "properties": { + "tag": { + "description": "Must conform with RFC-1034. That is, this string can only contain lower-case letters (a-z), numbers (0-9), and hyphens (-), and be at most 20 characters.", + "type": "string" + } + }, + "type": "object" + }, + "OneTimeCode": { + "description": "A single use promotion code.", + "id": "OneTimeCode", + "properties": {}, + "type": "object" + }, + "OneTimeExternalTransaction": { + "description": "Represents a one-time transaction.", + "id": "OneTimeExternalTransaction", + "properties": { + "externalTransactionToken": { + "description": "Input only. Provided during the call to Create. Retrieved from the client when the alternative billing flow is launched.", + "type": "string" + } + }, + "type": "object" + }, + "OneTimeProduct": { + "description": "A single one-time product for an app.", + "id": "OneTimeProduct", + "properties": { + "listings": { + "description": "Required. Set of localized title and description data. Must not have duplicate entries with the same language_code.", + "items": { + "$ref": "OneTimeProductListing" + }, + "type": "array" + }, + "offerTags": { + "description": "Optional. List of up to 20 custom tags specified for this one-time product, and returned to the app through the billing library. Purchase options and offers for this product will also receive these tags in the billing library.", + "items": { + "$ref": "OfferTag" + }, + "type": "array" + }, + "packageName": { + "description": "Required. Immutable. Package name of the parent app.", + "type": "string" + }, + "productId": { + "description": "Required. Immutable. Unique product ID of the product. Unique within the parent app. Product IDs must start with a number or lowercase letter, and can contain numbers (0-9), lowercase letters (a-z), underscores (_), and periods (.).", + "type": "string" + }, + "purchaseOptions": { + "description": "Required. The set of purchase options for this one-time product.", + "items": { + "$ref": "OneTimeProductPurchaseOption" + }, + "type": "array" + }, + "regionsVersion": { + "$ref": "RegionsVersion", + "description": "Output only. The version of the regions configuration that was used to generate the one-time product.", + "readOnly": true + }, + "restrictedPaymentCountries": { + "$ref": "RestrictedPaymentCountries", + "description": "Optional. Countries where the purchase of this one-time product is restricted to payment methods registered in the same country. If empty, no payment location restrictions are imposed." + }, + "taxAndComplianceSettings": { + "$ref": "OneTimeProductTaxAndComplianceSettings", + "description": "Details about taxes and legal compliance." + } + }, + "type": "object" + }, + "OneTimeProductBuyPurchaseOption": { + "description": "A purchase option that can be bought.", + "id": "OneTimeProductBuyPurchaseOption", + "properties": { + "legacyCompatible": { + "description": "Optional. Whether this purchase option will be available in legacy PBL flows that do not support one-time products model. Up to one \"buy\" purchase option can be marked as backwards compatible.", + "type": "boolean" + }, + "multiQuantityEnabled": { + "description": "Optional. Whether this purchase option allows multi-quantity. Multi-quantity allows buyer to purchase more than one item in a single checkout.", + "type": "boolean" + } + }, + "type": "object" + }, + "OneTimeProductDiscountedOffer": { + "description": "Configuration specific to discounted offers.", + "id": "OneTimeProductDiscountedOffer", + "properties": { + "endTime": { + "description": "Time when the offer will stop being available.", + "format": "google-datetime", + "type": "string" + }, + "redemptionLimit": { + "description": "Optional. The number of times this offer can be redeemed. If unset or set to 0, allows for unlimited offer redemptions. Otherwise must be a number between 1 and 50 inclusive.", + "format": "int64", + "type": "string" + }, + "startTime": { + "description": "Time when the offer will start being available.", + "format": "google-datetime", + "type": "string" + } + }, + "type": "object" + }, + "OneTimeProductListing": { + "description": "Regional store listing for a one-time product.", + "id": "OneTimeProductListing", + "properties": { + "description": { + "description": "Required. The description of this product in the language of this listing. The maximum length is 200 characters.", + "type": "string" + }, + "languageCode": { + "description": "Required. The language of this listing, as defined by BCP-47, e.g., \"en-US\".", + "type": "string" + }, + "title": { + "description": "Required. The title of this product in the language of this listing. The maximum length is 55 characters.", + "type": "string" + } + }, + "type": "object" + }, + "OneTimeProductOffer": { + "description": "A single offer for a one-time product.", + "id": "OneTimeProductOffer", + "properties": { + "discountedOffer": { + "$ref": "OneTimeProductDiscountedOffer", + "description": "A discounted offer." + }, + "offerId": { + "description": "Required. Immutable. The ID of this product offer. Must be unique within the purchase option. It must start with a number or lower-case letter, and can only contain lower-case letters (a-z), numbers (0-9), and hyphens (-). The maximum length is 63 characters.", + "type": "string" + }, + "offerTags": { + "description": "Optional. List of up to 20 custom tags specified for this offer, and returned to the app through the billing library.", + "items": { + "$ref": "OfferTag" + }, + "type": "array" + }, + "packageName": { + "description": "Required. Immutable. The package name of the app the parent product belongs to.", + "type": "string" + }, + "preOrderOffer": { + "$ref": "OneTimeProductPreOrderOffer", + "description": "A pre-order offer." + }, + "productId": { + "description": "Required. Immutable. The ID of the parent product this offer belongs to.", + "type": "string" + }, + "purchaseOptionId": { + "description": "Required. Immutable. The ID of the purchase option to which this offer is an extension.", + "type": "string" + }, + "regionalPricingAndAvailabilityConfigs": { + "description": "Set of regional pricing and availability information for this offer. Must not have duplicate entries with the same region_code.", + "items": { + "$ref": "OneTimeProductOfferRegionalPricingAndAvailabilityConfig" + }, + "type": "array" + }, + "regionsVersion": { + "$ref": "RegionsVersion", + "description": "Output only. The version of the regions configuration that was used to generate the one-time product offer.", + "readOnly": true + }, + "state": { + "description": "Output only. The current state of this offer. This field cannot be changed by updating the resource. Use the dedicated endpoints instead.", + "enum": [ + "STATE_UNSPECIFIED", + "DRAFT", + "ACTIVE", + "CANCELLED", + "INACTIVE" + ], + "enumDescriptions": [ + "Default value, should never be used.", + "The offer is not and has never been available to users.", + "The offer is available to users, as long as its conditions are met.", + "This state is specific to pre-orders. The offer is cancelled and not available to users. All pending orders related to this offer were cancelled.", + "This state is specific to discounted offers. The offer is no longer available to users." + ], + "readOnly": true, + "type": "string" + } + }, + "type": "object" + }, + "OneTimeProductOfferNoPriceOverrideOptions": { + "description": "Options for one-time product offers without a regional price override.", + "id": "OneTimeProductOfferNoPriceOverrideOptions", + "properties": {}, + "type": "object" + }, + "OneTimeProductOfferRegionalPricingAndAvailabilityConfig": { + "description": "Regional pricing and availability configuration for a one-time product offer.", + "id": "OneTimeProductOfferRegionalPricingAndAvailabilityConfig", + "properties": { + "absoluteDiscount": { + "$ref": "Money", + "description": "The absolute value of the discount that is subtracted from the purchase option price. It should be between 0 and the purchase option price." + }, + "availability": { + "description": "Required. The availability for this region.", + "enum": [ + "AVAILABILITY_UNSPECIFIED", + "AVAILABLE", + "NO_LONGER_AVAILABLE" + ], + "enumDescriptions": [ + "Unspecified availability. Must not be used.", + "The offer is available to users.", + "The offer is no longer available to users. This value can only be used if the availability was previously set as AVAILABLE." + ], + "type": "string" + }, + "noOverride": { + "$ref": "OneTimeProductOfferNoPriceOverrideOptions", + "description": "The price defined in the purchase option for this region will be used." + }, + "regionCode": { + "description": "Required. Region code this configuration applies to, as defined by ISO 3166-2, e.g., \"US\".", + "type": "string" + }, + "relativeDiscount": { + "description": "The fraction of the purchase option price that the user pays for this offer. For example, if the purchase option price for this region is $12, then a 50% discount would correspond to a price of $6. The discount must be specified as a fraction strictly larger than 0 and strictly smaller than 1. The resulting price will be rounded to the nearest billable unit (e.g. cents for USD). The relative discount is considered invalid if the discounted price ends up being smaller than the minimum price allowed in this region.", + "format": "double", + "type": "number" + } + }, + "type": "object" + }, + "OneTimeProductPreOrderOffer": { + "description": "Configuration specific to pre-order offers.", + "id": "OneTimeProductPreOrderOffer", "properties": { - "abi": { - "description": "A list of targeted ABIs, as represented by the Android Platform", - "items": { - "$ref": "Abi" - }, - "type": "array" + "endTime": { + "description": "Required. Time when the pre-order will stop being available.", + "format": "google-datetime", + "type": "string" + }, + "priceChangeBehavior": { + "description": "Required. Immutable. Specifies how price changes affect pre-existing pre-orders.", + "enum": [ + "PRE_ORDER_PRICE_CHANGE_BEHAVIOR_UNSPECIFIED", + "PRE_ORDER_PRICE_CHANGE_BEHAVIOR_TWO_POINT_LOWEST", + "PRE_ORDER_PRICE_CHANGE_BEHAVIOR_NEW_ORDERS_ONLY" + ], + "enumDescriptions": [ + "Unspecified price change behavior. Must not be used.", + "The buyer gets charged the minimum between the initial price at the time of pre-order and the final offer price on the release date.", + "The buyer gets the same price as the one they pre-ordered, regardless of any price changes that may have happened after the pre-order." + ], + "type": "string" + }, + "releaseTime": { + "description": "Required. Time on which the product associated with the pre-order will be released and the pre-order orders fulfilled.", + "format": "google-datetime", + "type": "string" + }, + "startTime": { + "description": "Required. Time when the pre-order will start being available.", + "format": "google-datetime", + "type": "string" } }, "type": "object" }, - "MultiAbiTargeting": { - "description": "Targeting based on multiple abis.", - "id": "MultiAbiTargeting", + "OneTimeProductPurchaseOption": { + "description": "A single purchase option for a one-time product.", + "id": "OneTimeProductPurchaseOption", "properties": { - "alternatives": { - "description": "Targeting of other sibling directories that were in the Bundle. For main splits this is targeting of other main splits.", + "buyOption": { + "$ref": "OneTimeProductBuyPurchaseOption", + "description": "A purchase option that can be bought." + }, + "newRegionsConfig": { + "$ref": "OneTimeProductPurchaseOptionNewRegionsConfig", + "description": "Pricing information for any new locations Play may launch in the future. If omitted, the purchase option will not be automatically available in any new locations Play may launch in the future." + }, + "offerTags": { + "description": "Optional. List of up to 20 custom tags specified for this purchase option, and returned to the app through the billing library. Offers for this purchase option will also receive these tags in the billing library.", "items": { - "$ref": "MultiAbi" + "$ref": "OfferTag" }, "type": "array" }, - "value": { - "description": "Value of a multi abi.", + "purchaseOptionId": { + "description": "Required. Immutable. The unique identifier of this purchase option. Must be unique within the one-time product. It must start with a number or lower-case letter, and can only contain lower-case letters (a-z), numbers (0-9), and hyphens (-). The maximum length is 63 characters.", + "type": "string" + }, + "regionalPricingAndAvailabilityConfigs": { + "description": "Regional pricing and availability information for this purchase option.", "items": { - "$ref": "MultiAbi" + "$ref": "OneTimeProductPurchaseOptionRegionalPricingAndAvailabilityConfig" }, "type": "array" + }, + "rentOption": { + "$ref": "OneTimeProductRentPurchaseOption", + "description": "A purchase option that can be rented." + }, + "state": { + "description": "Output only. The state of the purchase option, i.e., whether it's active. This field cannot be changed by updating the resource. Use the dedicated endpoints instead.", + "enum": [ + "STATE_UNSPECIFIED", + "DRAFT", + "ACTIVE", + "INACTIVE", + "INACTIVE_PUBLISHED" + ], + "enumDescriptions": [ + "Default value, should never be used.", + "The purchase option is not and has never been available to users.", + "The purchase option is available to users.", + "The purchase option is not available to users anymore.", + "The purchase option is not available for purchase anymore, but we continue to expose its offer via the Play Billing Library for backwards compatibility. Only automatically migrated purchase options can be in this state." + ], + "readOnly": true, + "type": "string" + }, + "taxAndComplianceSettings": { + "$ref": "PurchaseOptionTaxAndComplianceSettings", + "description": "Optional. Details about taxes and legal compliance." } }, "type": "object" }, - "OfferDetails": { - "description": "Offer details information related to a purchase line item.", - "id": "OfferDetails", + "OneTimeProductPurchaseOptionNewRegionsConfig": { + "description": "Pricing information for any new regions Play may launch in the future.", + "id": "OneTimeProductPurchaseOptionNewRegionsConfig", "properties": { - "basePlanId": { - "description": "The base plan ID. Present for all base plan and offers.", + "availability": { + "description": "Required. The regional availability for the new regions config. When set to AVAILABLE, the pricing information will be used for any new regions Play may launch in the future.", + "enum": [ + "AVAILABILITY_UNSPECIFIED", + "AVAILABLE", + "NO_LONGER_AVAILABLE" + ], + "enumDescriptions": [ + "Unspecified availability. Must not be used.", + "The config will be used for any new regions Play may launch in the future.", + "The config is not available anymore and will not be used for any new regions Play may launch in the future. This value can only be used if the availability was previously set as AVAILABLE." + ], "type": "string" }, - "offerId": { - "description": "The offer ID. Only present for discounted offers.", - "type": "string" + "eurPrice": { + "$ref": "Money", + "description": "Required. Price in EUR to use for any new regions Play may launch in." }, - "offerTags": { - "description": "The latest offer tags associated with the offer. It includes tags inherited from the base plan.", - "items": { - "type": "string" - }, - "type": "array" + "usdPrice": { + "$ref": "Money", + "description": "Required. Price in USD to use for any new regions Play may launch in." } }, "type": "object" }, - "OfferTag": { - "description": "Represents a custom tag specified for a product offer.", - "id": "OfferTag", + "OneTimeProductPurchaseOptionRegionalPricingAndAvailabilityConfig": { + "description": "Regional pricing and availability configuration for a purchase option.", + "id": "OneTimeProductPurchaseOptionRegionalPricingAndAvailabilityConfig", "properties": { - "tag": { - "description": "Must conform with RFC-1034. That is, this string can only contain lower-case letters (a-z), numbers (0-9), and hyphens (-), and be at most 20 characters.", + "availability": { + "description": "The availability of the purchase option.", + "enum": [ + "AVAILABILITY_UNSPECIFIED", + "AVAILABLE", + "NO_LONGER_AVAILABLE", + "AVAILABLE_IF_RELEASED" + ], + "enumDescriptions": [ + "Unspecified availability. Must not be used.", + "The purchase option is available to users.", + "The purchase option is no longer available to users. This value can only be used if the availability was previously set as AVAILABLE.", + "The purchase option is initially unavailable, but made available via a released pre-order offer." + ], + "type": "string" + }, + "price": { + "$ref": "Money", + "description": "The price of the purchase option in the specified region. Must be set in the currency that is linked to the specified region." + }, + "regionCode": { + "description": "Required. Region code this configuration applies to, as defined by ISO 3166-2, e.g., \"US\".", "type": "string" } }, "type": "object" }, - "OneTimeCode": { - "description": "A single use promotion code.", - "id": "OneTimeCode", - "properties": {}, + "OneTimeProductRentPurchaseOption": { + "description": "A purchase option that can be rented.", + "id": "OneTimeProductRentPurchaseOption", + "properties": { + "expirationPeriod": { + "description": "Optional. The amount of time the user has after starting consuming the entitlement before it is revoked. Specified in ISO 8601 format.", + "type": "string" + }, + "rentalPeriod": { + "description": "Required. The amount of time a user has the entitlement for. Starts at purchase flow completion. Specified in ISO 8601 format.", + "type": "string" + } + }, "type": "object" }, - "OneTimeExternalTransaction": { - "description": "Represents a one-time transaction.", - "id": "OneTimeExternalTransaction", + "OneTimeProductTaxAndComplianceSettings": { + "description": "Details about taxation, Google Play policy and legal compliance for one-time products.", + "id": "OneTimeProductTaxAndComplianceSettings", "properties": { - "externalTransactionToken": { - "description": "Input only. Provided during the call to Create. Retrieved from the client when the alternative billing flow is launched.", - "type": "string" + "isTokenizedDigitalAsset": { + "description": "Whether this one-time product is declared as a product representing a tokenized digital asset.", + "type": "boolean" + }, + "regionalTaxConfigs": { + "description": "Regional tax configuration.", + "items": { + "$ref": "RegionalTaxConfig" + }, + "type": "array" } }, "type": "object" @@ -8422,6 +10054,27 @@ }, "type": "object" }, + "PurchaseOptionTaxAndComplianceSettings": { + "description": "Details about taxation, Google Play policy and legal compliance for one-time product purchase options.", + "id": "PurchaseOptionTaxAndComplianceSettings", + "properties": { + "withdrawalRightType": { + "description": "Optional. Digital content or service classification for products distributed to users in eligible regions. If unset, it defaults to `WITHDRAWAL_RIGHT_DIGITAL_CONTENT`. Refer to the [Help Center article](https://support.google.com/googleplay/android-developer/answer/10463498) for more information.", + "enum": [ + "WITHDRAWAL_RIGHT_TYPE_UNSPECIFIED", + "WITHDRAWAL_RIGHT_DIGITAL_CONTENT", + "WITHDRAWAL_RIGHT_SERVICE" + ], + "enumDescriptions": [ + "", + "", + "" + ], + "type": "string" + } + }, + "type": "object" + }, "PurchaseStateContext": { "description": "Context about the purchase state.", "id": "PurchaseStateContext", @@ -8646,6 +10299,63 @@ "properties": {}, "type": "object" }, + "RegionalTaxConfig": { + "description": "Details about taxation in a given geographical region.", + "id": "RegionalTaxConfig", + "properties": { + "eligibleForStreamingServiceTaxRate": { + "description": "You must tell us if your app contains streaming products to correctly charge US state and local sales tax. Field only supported in the United States.", + "type": "boolean" + }, + "regionCode": { + "description": "Required. Region code this configuration applies to, as defined by ISO 3166-2, e.g. \"US\".", + "type": "string" + }, + "streamingTaxType": { + "description": "To collect communications or amusement taxes in the United States, choose the appropriate tax category. [Learn more](https://support.google.com/googleplay/android-developer/answer/10463498#streaming_tax).", + "enum": [ + "STREAMING_TAX_TYPE_UNSPECIFIED", + "STREAMING_TAX_TYPE_TELCO_VIDEO_RENTAL", + "STREAMING_TAX_TYPE_TELCO_VIDEO_SALES", + "STREAMING_TAX_TYPE_TELCO_VIDEO_MULTI_CHANNEL", + "STREAMING_TAX_TYPE_TELCO_AUDIO_RENTAL", + "STREAMING_TAX_TYPE_TELCO_AUDIO_SALES", + "STREAMING_TAX_TYPE_TELCO_AUDIO_MULTI_CHANNEL" + ], + "enumDescriptions": [ + "No telecommunications tax collected.", + "US-specific telecommunications tax tier for video streaming, on demand, rentals / subscriptions / pay-per-view.", + "US-specific telecommunications tax tier for video streaming of pre-recorded content like movies, tv shows.", + "US-specific telecommunications tax tier for video streaming of multi-channel programming.", + "US-specific telecommunications tax tier for audio streaming, rental / subscription.", + "US-specific telecommunications tax tier for audio streaming, sale / permanent download.", + "US-specific telecommunications tax tier for multi channel audio streaming like radio." + ], + "type": "string" + }, + "taxTier": { + "description": "Tax tier to specify reduced tax rate. Developers who sell digital news, magazines, newspapers, books, or audiobooks in various regions may be eligible for reduced tax rates. [Learn more](https://support.google.com/googleplay/android-developer/answer/10463498).", + "enum": [ + "TAX_TIER_UNSPECIFIED", + "TAX_TIER_BOOKS_1", + "TAX_TIER_NEWS_1", + "TAX_TIER_NEWS_2", + "TAX_TIER_MUSIC_OR_AUDIO_1", + "TAX_TIER_LIVE_OR_BROADCAST_1" + ], + "enumDescriptions": [ + "", + "", + "", + "", + "", + "" + ], + "type": "string" + } + }, + "type": "object" + }, "RegionalTaxRateInfo": { "description": "Specified details about taxation in a given geographical region.", "id": "RegionalTaxRateInfo", @@ -10277,6 +11987,116 @@ }, "type": "object" }, + "UpdateOneTimeProductOfferRequest": { + "description": "Request message for UpdateOneTimeProductOffer.", + "id": "UpdateOneTimeProductOfferRequest", + "properties": { + "allowMissing": { + "description": "Optional. If set to true, and the offer with the given package_name, product_id, purchase_option_id and offer_id doesn't exist, an offer will be created. If a new offer is created, the update_mask is ignored.", + "type": "boolean" + }, + "latencyTolerance": { + "description": "Optional. The latency tolerance for the propagation of this offer update. Defaults to latency-sensitive.", + "enum": [ + "PRODUCT_UPDATE_LATENCY_TOLERANCE_UNSPECIFIED", + "PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_SENSITIVE", + "PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_TOLERANT" + ], + "enumDescriptions": [ + "Defaults to PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_SENSITIVE.", + "The update will propagate to clients within several minutes on average and up to a few hours in rare cases. Throughput is limited to 7,200 updates per app per hour.", + "The update will propagate to clients within 24 hours. Supports high throughput of up to 720,000 updates per app per hour using batch modification methods." + ], + "type": "string" + }, + "oneTimeProductOffer": { + "$ref": "OneTimeProductOffer", + "description": "Required. The one-time product offer to update." + }, + "regionsVersion": { + "$ref": "RegionsVersion", + "description": "Required. The version of the available regions being used for the offer." + }, + "updateMask": { + "description": "Required. The list of fields to be updated.", + "format": "google-fieldmask", + "type": "string" + } + }, + "type": "object" + }, + "UpdateOneTimeProductOfferStateRequest": { + "description": "Request message to update the state of a one-time product offer.", + "id": "UpdateOneTimeProductOfferStateRequest", + "properties": { + "activateOneTimeProductOfferRequest": { + "$ref": "ActivateOneTimeProductOfferRequest", + "description": "Activates an offer. Once activated, the offer is available to users, as long as its conditions are met." + }, + "cancelOneTimeProductOfferRequest": { + "$ref": "CancelOneTimeProductOfferRequest", + "description": "Cancels an offer. Once cancelled, the offer is not available to users. Any pending orders related to this offer will be cancelled. This state transition is specific to pre-orders." + }, + "deactivateOneTimeProductOfferRequest": { + "$ref": "DeactivateOneTimeProductOfferRequest", + "description": "Deactivates an offer. Once deactivated, the offer is no longer available to users. This state transition is specific to discounted offers." + } + }, + "type": "object" + }, + "UpdateOneTimeProductRequest": { + "description": "Request message for UpdateOneTimeProduct.", + "id": "UpdateOneTimeProductRequest", + "properties": { + "allowMissing": { + "description": "Optional. If set to true, and the one-time product with the given package_name and product_id doesn't exist, the one-time product will be created. If a new one-time product is created, update_mask is ignored.", + "type": "boolean" + }, + "latencyTolerance": { + "description": "Optional. The latency tolerance for the propagation of this product upsert. Defaults to latency-sensitive.", + "enum": [ + "PRODUCT_UPDATE_LATENCY_TOLERANCE_UNSPECIFIED", + "PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_SENSITIVE", + "PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_TOLERANT" + ], + "enumDescriptions": [ + "Defaults to PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_SENSITIVE.", + "The update will propagate to clients within several minutes on average and up to a few hours in rare cases. Throughput is limited to 7,200 updates per app per hour.", + "The update will propagate to clients within 24 hours. Supports high throughput of up to 720,000 updates per app per hour using batch modification methods." + ], + "type": "string" + }, + "oneTimeProduct": { + "$ref": "OneTimeProduct", + "description": "Required. The one-time product to upsert." + }, + "regionsVersion": { + "$ref": "RegionsVersion", + "description": "Required. The version of the available regions being used for the one-time product." + }, + "updateMask": { + "description": "Required. The list of fields to be updated.", + "format": "google-fieldmask", + "type": "string" + } + }, + "type": "object" + }, + "UpdatePurchaseOptionStateRequest": { + "description": "Request message to update the state of a one-time product purchase option.", + "id": "UpdatePurchaseOptionStateRequest", + "properties": { + "activatePurchaseOptionRequest": { + "$ref": "ActivatePurchaseOptionRequest", + "description": "Activates a purchase option. Once activated, the purchase option will be available." + }, + "deactivatePurchaseOptionRequest": { + "$ref": "DeactivatePurchaseOptionRequest", + "description": "Deactivates a purchase option. Once deactivated, the purchase option will become unavailable." + } + }, + "type": "object" + }, "UpdateSubscriptionOfferRequest": { "description": "Request message for UpdateSubscriptionOffer.", "id": "UpdateSubscriptionOfferRequest", diff --git a/androidpublisher/v3/androidpublisher-gen.go b/androidpublisher/v3/androidpublisher-gen.go index 783d84468dc..a2b312edfff 100644 --- a/androidpublisher/v3/androidpublisher-gen.go +++ b/androidpublisher/v3/androidpublisher-gen.go @@ -398,6 +398,7 @@ type InternalappsharingartifactsService struct { func NewMonetizationService(s *Service) *MonetizationService { rs := &MonetizationService{s: s} + rs.Onetimeproducts = NewMonetizationOnetimeproductsService(s) rs.Subscriptions = NewMonetizationSubscriptionsService(s) return rs } @@ -405,9 +406,44 @@ func NewMonetizationService(s *Service) *MonetizationService { type MonetizationService struct { s *Service + Onetimeproducts *MonetizationOnetimeproductsService + Subscriptions *MonetizationSubscriptionsService } +func NewMonetizationOnetimeproductsService(s *Service) *MonetizationOnetimeproductsService { + rs := &MonetizationOnetimeproductsService{s: s} + rs.PurchaseOptions = NewMonetizationOnetimeproductsPurchaseOptionsService(s) + return rs +} + +type MonetizationOnetimeproductsService struct { + s *Service + + PurchaseOptions *MonetizationOnetimeproductsPurchaseOptionsService +} + +func NewMonetizationOnetimeproductsPurchaseOptionsService(s *Service) *MonetizationOnetimeproductsPurchaseOptionsService { + rs := &MonetizationOnetimeproductsPurchaseOptionsService{s: s} + rs.Offers = NewMonetizationOnetimeproductsPurchaseOptionsOffersService(s) + return rs +} + +type MonetizationOnetimeproductsPurchaseOptionsService struct { + s *Service + + Offers *MonetizationOnetimeproductsPurchaseOptionsOffersService +} + +func NewMonetizationOnetimeproductsPurchaseOptionsOffersService(s *Service) *MonetizationOnetimeproductsPurchaseOptionsOffersService { + rs := &MonetizationOnetimeproductsPurchaseOptionsOffersService{s: s} + return rs +} + +type MonetizationOnetimeproductsPurchaseOptionsOffersService struct { + s *Service +} + func NewMonetizationSubscriptionsService(s *Service) *MonetizationSubscriptionsService { rs := &MonetizationSubscriptionsService{s: s} rs.BasePlans = NewMonetizationSubscriptionsBasePlansService(s) @@ -679,6 +715,94 @@ func (s ActivateBasePlanRequest) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// ActivateOneTimeProductOfferRequest: Request message for +// ActivateOneTimeProductOffer. +type ActivateOneTimeProductOfferRequest struct { + // LatencyTolerance: Optional. The latency tolerance for the propagation of + // this update. Defaults to latency-sensitive. + // + // Possible values: + // "PRODUCT_UPDATE_LATENCY_TOLERANCE_UNSPECIFIED" - Defaults to + // PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_SENSITIVE. + // "PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_SENSITIVE" - The update will + // propagate to clients within several minutes on average and up to a few hours + // in rare cases. Throughput is limited to 7,200 updates per app per hour. + // "PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_TOLERANT" - The update will + // propagate to clients within 24 hours. Supports high throughput of up to + // 720,000 updates per app per hour using batch modification methods. + LatencyTolerance string `json:"latencyTolerance,omitempty"` + // OfferId: Required. The offer ID of the offer to activate. + OfferId string `json:"offerId,omitempty"` + // PackageName: Required. The parent app (package name) of the offer to + // activate. + PackageName string `json:"packageName,omitempty"` + // ProductId: Required. The parent one-time product (ID) of the offer to + // activate. + ProductId string `json:"productId,omitempty"` + // PurchaseOptionId: Required. The parent purchase option (ID) of the offer to + // activate. + PurchaseOptionId string `json:"purchaseOptionId,omitempty"` + // ForceSendFields is a list of field names (e.g. "LatencyTolerance") 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. "LatencyTolerance") 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 ActivateOneTimeProductOfferRequest) MarshalJSON() ([]byte, error) { + type NoMethod ActivateOneTimeProductOfferRequest + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// ActivatePurchaseOptionRequest: Request message for +// UpdatePurchaseOptionState. +type ActivatePurchaseOptionRequest struct { + // LatencyTolerance: Optional. The latency tolerance for the propagation of + // this product update. Defaults to latency-sensitive. + // + // Possible values: + // "PRODUCT_UPDATE_LATENCY_TOLERANCE_UNSPECIFIED" - Defaults to + // PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_SENSITIVE. + // "PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_SENSITIVE" - The update will + // propagate to clients within several minutes on average and up to a few hours + // in rare cases. Throughput is limited to 7,200 updates per app per hour. + // "PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_TOLERANT" - The update will + // propagate to clients within 24 hours. Supports high throughput of up to + // 720,000 updates per app per hour using batch modification methods. + LatencyTolerance string `json:"latencyTolerance,omitempty"` + // PackageName: Required. The parent app (package name) of the purchase option + // to activate. + PackageName string `json:"packageName,omitempty"` + // ProductId: Required. The parent one-time product (ID) of the purchase option + // to activate. + ProductId string `json:"productId,omitempty"` + // PurchaseOptionId: Required. The purchase option ID of the purchase option to + // activate. + PurchaseOptionId string `json:"purchaseOptionId,omitempty"` + // ForceSendFields is a list of field names (e.g. "LatencyTolerance") 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. "LatencyTolerance") 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 ActivatePurchaseOptionRequest) MarshalJSON() ([]byte, error) { + type NoMethod ActivatePurchaseOptionRequest + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // ActivateSubscriptionOfferRequest: Request message for // ActivateSubscriptionOffer. type ActivateSubscriptionOfferRequest struct { @@ -1410,6 +1534,156 @@ func (s BasePlan) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// BatchDeleteOneTimeProductOffersRequest: Request message for +// BatchDeleteOneTimeProductOffers. +type BatchDeleteOneTimeProductOffersRequest struct { + // Requests: Required. A list of update requests of up to 100 elements. All + // requests must correspond to different offers. + Requests []*DeleteOneTimeProductOfferRequest `json:"requests,omitempty"` + // ForceSendFields is a list of field names (e.g. "Requests") 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. "Requests") 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 BatchDeleteOneTimeProductOffersRequest) MarshalJSON() ([]byte, error) { + type NoMethod BatchDeleteOneTimeProductOffersRequest + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// BatchDeleteOneTimeProductsRequest: Request message for +// BatchDeleteOneTimeProduct. +type BatchDeleteOneTimeProductsRequest struct { + // Requests: Required. A list of delete requests of up to 100 elements. All + // requests must delete different one-time products. + Requests []*DeleteOneTimeProductRequest `json:"requests,omitempty"` + // ForceSendFields is a list of field names (e.g. "Requests") 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. "Requests") 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 BatchDeleteOneTimeProductsRequest) MarshalJSON() ([]byte, error) { + type NoMethod BatchDeleteOneTimeProductsRequest + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// BatchDeletePurchaseOptionsRequest: Request message for +// BatchDeletePurchaseOption. +type BatchDeletePurchaseOptionsRequest struct { + // Requests: Required. A list of delete requests of up to 100 elements. All + // requests must delete purchase options from different one-time products. + Requests []*DeletePurchaseOptionRequest `json:"requests,omitempty"` + // ForceSendFields is a list of field names (e.g. "Requests") 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. "Requests") 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 BatchDeletePurchaseOptionsRequest) MarshalJSON() ([]byte, error) { + type NoMethod BatchDeletePurchaseOptionsRequest + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// BatchGetOneTimeProductOffersRequest: Request message for the +// BatchGetOneTimeProductOffers endpoint. +type BatchGetOneTimeProductOffersRequest struct { + // Requests: Required. A list of get requests of up to 100 elements. All + // requests must retrieve different offers. + Requests []*GetOneTimeProductOfferRequest `json:"requests,omitempty"` + // ForceSendFields is a list of field names (e.g. "Requests") 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. "Requests") 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 BatchGetOneTimeProductOffersRequest) MarshalJSON() ([]byte, error) { + type NoMethod BatchGetOneTimeProductOffersRequest + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// BatchGetOneTimeProductOffersResponse: Response message for the +// BatchGetOneTimeProductOffers endpoint. +type BatchGetOneTimeProductOffersResponse struct { + // OneTimeProductOffers: The list of updated one-time product offers, in the + // same order as the request. + OneTimeProductOffers []*OneTimeProductOffer `json:"oneTimeProductOffers,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the server. + googleapi.ServerResponse `json:"-"` + // ForceSendFields is a list of field names (e.g. "OneTimeProductOffers") 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. "OneTimeProductOffers") 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 BatchGetOneTimeProductOffersResponse) MarshalJSON() ([]byte, error) { + type NoMethod BatchGetOneTimeProductOffersResponse + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// BatchGetOneTimeProductsResponse: Response message for the +// BatchGetOneTimeProducts endpoint. +type BatchGetOneTimeProductsResponse struct { + // OneTimeProducts: The list of requested one-time products, in the same order + // as the request. + OneTimeProducts []*OneTimeProduct `json:"oneTimeProducts,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the server. + googleapi.ServerResponse `json:"-"` + // ForceSendFields is a list of field names (e.g. "OneTimeProducts") 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. "OneTimeProducts") 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 BatchGetOneTimeProductsResponse) MarshalJSON() ([]byte, error) { + type NoMethod BatchGetOneTimeProductsResponse + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // BatchGetOrdersResponse: Response for the orders.batchGet API. type BatchGetOrdersResponse struct { // Orders: Details for the requested order IDs. @@ -1613,12 +1887,12 @@ func (s BatchUpdateBasePlanStatesResponse) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// BatchUpdateSubscriptionOfferStatesRequest: Request message for -// BatchUpdateSubscriptionOfferStates. -type BatchUpdateSubscriptionOfferStatesRequest struct { +// BatchUpdateOneTimeProductOfferStatesRequest: Request message for +// BatchUpdateOneTimeProductOfferStates. +type BatchUpdateOneTimeProductOfferStatesRequest struct { // Requests: Required. The update request list of up to 100 elements. All // requests must update different offers. - Requests []*UpdateSubscriptionOfferStateRequest `json:"requests,omitempty"` + Requests []*UpdateOneTimeProductOfferStateRequest `json:"requests,omitempty"` // ForceSendFields is a list of field names (e.g. "Requests") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See @@ -1632,43 +1906,44 @@ type BatchUpdateSubscriptionOfferStatesRequest struct { NullFields []string `json:"-"` } -func (s BatchUpdateSubscriptionOfferStatesRequest) MarshalJSON() ([]byte, error) { - type NoMethod BatchUpdateSubscriptionOfferStatesRequest +func (s BatchUpdateOneTimeProductOfferStatesRequest) MarshalJSON() ([]byte, error) { + type NoMethod BatchUpdateOneTimeProductOfferStatesRequest return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// BatchUpdateSubscriptionOfferStatesResponse: Response message for -// BatchUpdateSubscriptionOfferStates. -type BatchUpdateSubscriptionOfferStatesResponse struct { - // SubscriptionOffers: The updated subscription offers list. - SubscriptionOffers []*SubscriptionOffer `json:"subscriptionOffers,omitempty"` +// BatchUpdateOneTimeProductOfferStatesResponse: Response message for +// BatchUpdateOneTimeProductOfferStates. +type BatchUpdateOneTimeProductOfferStatesResponse struct { + // OneTimeProductOffers: The updated one-time product offers list, in the same + // order as the request. + OneTimeProductOffers []*OneTimeProductOffer `json:"oneTimeProductOffers,omitempty"` // ServerResponse contains the HTTP response code and headers from the server. googleapi.ServerResponse `json:"-"` - // ForceSendFields is a list of field names (e.g. "SubscriptionOffers") to + // ForceSendFields is a list of field names (e.g. "OneTimeProductOffers") 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. "SubscriptionOffers") to include + // NullFields is a list of field names (e.g. "OneTimeProductOffers") 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 BatchUpdateSubscriptionOfferStatesResponse) MarshalJSON() ([]byte, error) { - type NoMethod BatchUpdateSubscriptionOfferStatesResponse +func (s BatchUpdateOneTimeProductOfferStatesResponse) MarshalJSON() ([]byte, error) { + type NoMethod BatchUpdateOneTimeProductOfferStatesResponse return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// BatchUpdateSubscriptionOffersRequest: Request message for -// BatchUpdateSubscriptionOffers. -type BatchUpdateSubscriptionOffersRequest struct { +// BatchUpdateOneTimeProductOffersRequest: Request message for +// BatchUpdateOneTimeProductOffers. +type BatchUpdateOneTimeProductOffersRequest struct { // Requests: Required. A list of update requests of up to 100 elements. All - // requests must update different subscription offers. - Requests []*UpdateSubscriptionOfferRequest `json:"requests,omitempty"` + // requests must update different offers. + Requests []*UpdateOneTimeProductOfferRequest `json:"requests,omitempty"` // ForceSendFields is a list of field names (e.g. "Requests") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See @@ -1682,43 +1957,44 @@ type BatchUpdateSubscriptionOffersRequest struct { NullFields []string `json:"-"` } -func (s BatchUpdateSubscriptionOffersRequest) MarshalJSON() ([]byte, error) { - type NoMethod BatchUpdateSubscriptionOffersRequest +func (s BatchUpdateOneTimeProductOffersRequest) MarshalJSON() ([]byte, error) { + type NoMethod BatchUpdateOneTimeProductOffersRequest return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// BatchUpdateSubscriptionOffersResponse: Response message for -// BatchUpdateSubscriptionOffers. -type BatchUpdateSubscriptionOffersResponse struct { - // SubscriptionOffers: The updated subscription offers list. - SubscriptionOffers []*SubscriptionOffer `json:"subscriptionOffers,omitempty"` +// BatchUpdateOneTimeProductOffersResponse: Response message for +// BatchUpdateOneTimeProductOffers. +type BatchUpdateOneTimeProductOffersResponse struct { + // OneTimeProductOffers: The list of updated one-time product offers, in the + // same order as the request. + OneTimeProductOffers []*OneTimeProductOffer `json:"oneTimeProductOffers,omitempty"` // ServerResponse contains the HTTP response code and headers from the server. googleapi.ServerResponse `json:"-"` - // ForceSendFields is a list of field names (e.g. "SubscriptionOffers") to + // ForceSendFields is a list of field names (e.g. "OneTimeProductOffers") 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. "SubscriptionOffers") to include + // NullFields is a list of field names (e.g. "OneTimeProductOffers") 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 BatchUpdateSubscriptionOffersResponse) MarshalJSON() ([]byte, error) { - type NoMethod BatchUpdateSubscriptionOffersResponse +func (s BatchUpdateOneTimeProductOffersResponse) MarshalJSON() ([]byte, error) { + type NoMethod BatchUpdateOneTimeProductOffersResponse return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// BatchUpdateSubscriptionsRequest: Request message for -// BatchUpdateSubscription. -type BatchUpdateSubscriptionsRequest struct { +// BatchUpdateOneTimeProductsRequest: Request message for +// BatchUpdateOneTimeProduct. +type BatchUpdateOneTimeProductsRequest struct { // Requests: Required. A list of update requests of up to 100 elements. All - // requests must update different subscriptions. - Requests []*UpdateSubscriptionRequest `json:"requests,omitempty"` + // requests must update different one-time products. + Requests []*UpdateOneTimeProductRequest `json:"requests,omitempty"` // ForceSendFields is a list of field names (e.g. "Requests") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See @@ -1732,34 +2008,236 @@ type BatchUpdateSubscriptionsRequest struct { NullFields []string `json:"-"` } -func (s BatchUpdateSubscriptionsRequest) MarshalJSON() ([]byte, error) { - type NoMethod BatchUpdateSubscriptionsRequest +func (s BatchUpdateOneTimeProductsRequest) MarshalJSON() ([]byte, error) { + type NoMethod BatchUpdateOneTimeProductsRequest return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// BatchUpdateSubscriptionsResponse: Response message for -// BatchUpdateSubscription. -type BatchUpdateSubscriptionsResponse struct { - // Subscriptions: The updated subscriptions list. - Subscriptions []*Subscription `json:"subscriptions,omitempty"` +// BatchUpdateOneTimeProductsResponse: Response message for +// BatchUpdateOneTimeProduct. +type BatchUpdateOneTimeProductsResponse struct { + // OneTimeProducts: The list of updated one-time products list, in the same + // order as the request. + OneTimeProducts []*OneTimeProduct `json:"oneTimeProducts,omitempty"` // ServerResponse contains the HTTP response code and headers from the server. googleapi.ServerResponse `json:"-"` - // ForceSendFields is a list of field names (e.g. "Subscriptions") to + // ForceSendFields is a list of field names (e.g. "OneTimeProducts") 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. "Subscriptions") to include in API + // NullFields is a list of field names (e.g. "OneTimeProducts") 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 BatchUpdateOneTimeProductsResponse) MarshalJSON() ([]byte, error) { + type NoMethod BatchUpdateOneTimeProductsResponse + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// BatchUpdatePurchaseOptionStatesRequest: Request message for +// BatchUpdatePurchaseOptionStates. +type BatchUpdatePurchaseOptionStatesRequest struct { + // Requests: Required. The update request list of up to 100 elements. All + // requests must update different purchase options. + Requests []*UpdatePurchaseOptionStateRequest `json:"requests,omitempty"` + // ForceSendFields is a list of field names (e.g. "Requests") 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. "Requests") 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 BatchUpdateSubscriptionsResponse) MarshalJSON() ([]byte, error) { - type NoMethod BatchUpdateSubscriptionsResponse +func (s BatchUpdatePurchaseOptionStatesRequest) MarshalJSON() ([]byte, error) { + type NoMethod BatchUpdatePurchaseOptionStatesRequest + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// BatchUpdatePurchaseOptionStatesResponse: Response message for +// BatchUpdatePurchaseOptionStates. +type BatchUpdatePurchaseOptionStatesResponse struct { + // OneTimeProducts: The list of updated one-time products. This list will match + // the requests one to one, in the same order. + OneTimeProducts []*OneTimeProduct `json:"oneTimeProducts,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the server. + googleapi.ServerResponse `json:"-"` + // ForceSendFields is a list of field names (e.g. "OneTimeProducts") 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. "OneTimeProducts") 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 BatchUpdatePurchaseOptionStatesResponse) MarshalJSON() ([]byte, error) { + type NoMethod BatchUpdatePurchaseOptionStatesResponse + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// BatchUpdateSubscriptionOfferStatesRequest: Request message for +// BatchUpdateSubscriptionOfferStates. +type BatchUpdateSubscriptionOfferStatesRequest struct { + // Requests: Required. The update request list of up to 100 elements. All + // requests must update different offers. + Requests []*UpdateSubscriptionOfferStateRequest `json:"requests,omitempty"` + // ForceSendFields is a list of field names (e.g. "Requests") 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. "Requests") 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 BatchUpdateSubscriptionOfferStatesRequest) MarshalJSON() ([]byte, error) { + type NoMethod BatchUpdateSubscriptionOfferStatesRequest + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// BatchUpdateSubscriptionOfferStatesResponse: Response message for +// BatchUpdateSubscriptionOfferStates. +type BatchUpdateSubscriptionOfferStatesResponse struct { + // SubscriptionOffers: The updated subscription offers list. + SubscriptionOffers []*SubscriptionOffer `json:"subscriptionOffers,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the server. + googleapi.ServerResponse `json:"-"` + // ForceSendFields is a list of field names (e.g. "SubscriptionOffers") 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. "SubscriptionOffers") 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 BatchUpdateSubscriptionOfferStatesResponse) MarshalJSON() ([]byte, error) { + type NoMethod BatchUpdateSubscriptionOfferStatesResponse + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// BatchUpdateSubscriptionOffersRequest: Request message for +// BatchUpdateSubscriptionOffers. +type BatchUpdateSubscriptionOffersRequest struct { + // Requests: Required. A list of update requests of up to 100 elements. All + // requests must update different subscription offers. + Requests []*UpdateSubscriptionOfferRequest `json:"requests,omitempty"` + // ForceSendFields is a list of field names (e.g. "Requests") 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. "Requests") 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 BatchUpdateSubscriptionOffersRequest) MarshalJSON() ([]byte, error) { + type NoMethod BatchUpdateSubscriptionOffersRequest + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// BatchUpdateSubscriptionOffersResponse: Response message for +// BatchUpdateSubscriptionOffers. +type BatchUpdateSubscriptionOffersResponse struct { + // SubscriptionOffers: The updated subscription offers list. + SubscriptionOffers []*SubscriptionOffer `json:"subscriptionOffers,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the server. + googleapi.ServerResponse `json:"-"` + // ForceSendFields is a list of field names (e.g. "SubscriptionOffers") 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. "SubscriptionOffers") 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 BatchUpdateSubscriptionOffersResponse) MarshalJSON() ([]byte, error) { + type NoMethod BatchUpdateSubscriptionOffersResponse + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// BatchUpdateSubscriptionsRequest: Request message for +// BatchUpdateSubscription. +type BatchUpdateSubscriptionsRequest struct { + // Requests: Required. A list of update requests of up to 100 elements. All + // requests must update different subscriptions. + Requests []*UpdateSubscriptionRequest `json:"requests,omitempty"` + // ForceSendFields is a list of field names (e.g. "Requests") 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. "Requests") 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 BatchUpdateSubscriptionsRequest) MarshalJSON() ([]byte, error) { + type NoMethod BatchUpdateSubscriptionsRequest + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// BatchUpdateSubscriptionsResponse: Response message for +// BatchUpdateSubscription. +type BatchUpdateSubscriptionsResponse struct { + // Subscriptions: The updated subscriptions list. + Subscriptions []*Subscription `json:"subscriptions,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the server. + googleapi.ServerResponse `json:"-"` + // ForceSendFields is a list of field names (e.g. "Subscriptions") 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. "Subscriptions") 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 BatchUpdateSubscriptionsResponse) MarshalJSON() ([]byte, error) { + type NoMethod BatchUpdateSubscriptionsResponse return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } @@ -1863,6 +2341,50 @@ type CancelAppRecoveryResponse struct { googleapi.ServerResponse `json:"-"` } +// CancelOneTimeProductOfferRequest: Request message for +// CancelOneTimeProductOffer. +type CancelOneTimeProductOfferRequest struct { + // LatencyTolerance: Optional. The latency tolerance for the propagation of + // this update. Defaults to latency-sensitive. + // + // Possible values: + // "PRODUCT_UPDATE_LATENCY_TOLERANCE_UNSPECIFIED" - Defaults to + // PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_SENSITIVE. + // "PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_SENSITIVE" - The update will + // propagate to clients within several minutes on average and up to a few hours + // in rare cases. Throughput is limited to 7,200 updates per app per hour. + // "PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_TOLERANT" - The update will + // propagate to clients within 24 hours. Supports high throughput of up to + // 720,000 updates per app per hour using batch modification methods. + LatencyTolerance string `json:"latencyTolerance,omitempty"` + // OfferId: Required. The offer ID of the offer to cancel. + OfferId string `json:"offerId,omitempty"` + // PackageName: Required. The parent app (package name) of the offer to cancel. + PackageName string `json:"packageName,omitempty"` + // ProductId: Required. The parent one-time product (ID) of the offer to + // cancel. + ProductId string `json:"productId,omitempty"` + // PurchaseOptionId: Required. The parent purchase option (ID) of the offer to + // cancel. + PurchaseOptionId string `json:"purchaseOptionId,omitempty"` + // ForceSendFields is a list of field names (e.g. "LatencyTolerance") 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. "LatencyTolerance") 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 CancelOneTimeProductOfferRequest) MarshalJSON() ([]byte, error) { + type NoMethod CancelOneTimeProductOfferRequest + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // CancelSurveyResult: Result of the cancel survey when the subscription was // canceled by the user. type CancelSurveyResult struct { @@ -2175,13 +2697,11 @@ func (s DeactivateBasePlanRequest) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// DeactivateSubscriptionOfferRequest: Request message for -// DeactivateSubscriptionOffer. -type DeactivateSubscriptionOfferRequest struct { - // BasePlanId: Required. The parent base plan (ID) of the offer to deactivate. - BasePlanId string `json:"basePlanId,omitempty"` +// DeactivateOneTimeProductOfferRequest: Request message for +// DeactivateOneTimeProductOffer. +type DeactivateOneTimeProductOfferRequest struct { // LatencyTolerance: Optional. The latency tolerance for the propagation of - // this product update. Defaults to latency-sensitive. + // this update. Defaults to latency-sensitive. // // Possible values: // "PRODUCT_UPDATE_LATENCY_TOLERANCE_UNSPECIFIED" - Defaults to @@ -2193,62 +2713,283 @@ type DeactivateSubscriptionOfferRequest struct { // propagate to clients within 24 hours. Supports high throughput of up to // 720,000 updates per app per hour using batch modification methods. LatencyTolerance string `json:"latencyTolerance,omitempty"` - // OfferId: Required. The unique offer ID of the offer to deactivate. + // OfferId: Required. The offer ID of the offer to deactivate. OfferId string `json:"offerId,omitempty"` // PackageName: Required. The parent app (package name) of the offer to // deactivate. PackageName string `json:"packageName,omitempty"` - // ProductId: Required. The parent subscription (ID) of the offer to + // ProductId: Required. The parent one-time product (ID) of the offer to // deactivate. ProductId string `json:"productId,omitempty"` - // ForceSendFields is a list of field names (e.g. "BasePlanId") to + // PurchaseOptionId: Required. The parent purchase option (ID) of the offer to + // deactivate. + PurchaseOptionId string `json:"purchaseOptionId,omitempty"` + // ForceSendFields is a list of field names (e.g. "LatencyTolerance") 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. "BasePlanId") 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. "LatencyTolerance") 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 DeactivateSubscriptionOfferRequest) MarshalJSON() ([]byte, error) { - type NoMethod DeactivateSubscriptionOfferRequest +func (s DeactivateOneTimeProductOfferRequest) MarshalJSON() ([]byte, error) { + type NoMethod DeactivateOneTimeProductOfferRequest return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// DeferredItemReplacement: Information related to deferred item replacement. -type DeferredItemReplacement struct { - // ProductId: The product_id going to replace the existing product_id. +// DeactivatePurchaseOptionRequest: Request message for +// UpdatePurchaseOptionState. +type DeactivatePurchaseOptionRequest struct { + // LatencyTolerance: Optional. The latency tolerance for the propagation of + // this product update. Defaults to latency-sensitive. + // + // Possible values: + // "PRODUCT_UPDATE_LATENCY_TOLERANCE_UNSPECIFIED" - Defaults to + // PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_SENSITIVE. + // "PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_SENSITIVE" - The update will + // propagate to clients within several minutes on average and up to a few hours + // in rare cases. Throughput is limited to 7,200 updates per app per hour. + // "PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_TOLERANT" - The update will + // propagate to clients within 24 hours. Supports high throughput of up to + // 720,000 updates per app per hour using batch modification methods. + LatencyTolerance string `json:"latencyTolerance,omitempty"` + // PackageName: Required. The parent app (package name) of the purchase option + // to deactivate. + PackageName string `json:"packageName,omitempty"` + // ProductId: Required. The parent one-time product (ID) of the purchase option + // to deactivate. ProductId string `json:"productId,omitempty"` - // ForceSendFields is a list of field names (e.g. "ProductId") to + // PurchaseOptionId: Required. The purchase option ID of the purchase option to + // deactivate. + PurchaseOptionId string `json:"purchaseOptionId,omitempty"` + // ForceSendFields is a list of field names (e.g. "LatencyTolerance") 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. "ProductId") 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. "LatencyTolerance") 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 DeferredItemReplacement) MarshalJSON() ([]byte, error) { - type NoMethod DeferredItemReplacement +func (s DeactivatePurchaseOptionRequest) MarshalJSON() ([]byte, error) { + type NoMethod DeactivatePurchaseOptionRequest return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// DeobfuscationFile: Represents a deobfuscation file. -type DeobfuscationFile struct { - // SymbolType: The type of the deobfuscation file. - // - // Possible values: - // "deobfuscationFileTypeUnspecified" - Unspecified deobfuscation file type. - // "proguard" - Proguard deobfuscation file type. - // "nativeCode" - Native debugging symbols file type. +// DeactivateSubscriptionOfferRequest: Request message for +// DeactivateSubscriptionOffer. +type DeactivateSubscriptionOfferRequest struct { + // BasePlanId: Required. The parent base plan (ID) of the offer to deactivate. + BasePlanId string `json:"basePlanId,omitempty"` + // LatencyTolerance: Optional. The latency tolerance for the propagation of + // this product update. Defaults to latency-sensitive. + // + // Possible values: + // "PRODUCT_UPDATE_LATENCY_TOLERANCE_UNSPECIFIED" - Defaults to + // PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_SENSITIVE. + // "PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_SENSITIVE" - The update will + // propagate to clients within several minutes on average and up to a few hours + // in rare cases. Throughput is limited to 7,200 updates per app per hour. + // "PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_TOLERANT" - The update will + // propagate to clients within 24 hours. Supports high throughput of up to + // 720,000 updates per app per hour using batch modification methods. + LatencyTolerance string `json:"latencyTolerance,omitempty"` + // OfferId: Required. The unique offer ID of the offer to deactivate. + OfferId string `json:"offerId,omitempty"` + // PackageName: Required. The parent app (package name) of the offer to + // deactivate. + PackageName string `json:"packageName,omitempty"` + // ProductId: Required. The parent subscription (ID) of the offer to + // deactivate. + ProductId string `json:"productId,omitempty"` + // ForceSendFields is a list of field names (e.g. "BasePlanId") 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. "BasePlanId") 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 DeactivateSubscriptionOfferRequest) MarshalJSON() ([]byte, error) { + type NoMethod DeactivateSubscriptionOfferRequest + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// DeferredItemReplacement: Information related to deferred item replacement. +type DeferredItemReplacement struct { + // ProductId: The product_id going to replace the existing product_id. + ProductId string `json:"productId,omitempty"` + // ForceSendFields is a list of field names (e.g. "ProductId") 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. "ProductId") 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 DeferredItemReplacement) MarshalJSON() ([]byte, error) { + type NoMethod DeferredItemReplacement + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// DeleteOneTimeProductOfferRequest: Request message for deleting an one-time +// product offer. +type DeleteOneTimeProductOfferRequest struct { + // LatencyTolerance: Optional. The latency tolerance for the propagation of + // this product update. Defaults to latency-sensitive. + // + // Possible values: + // "PRODUCT_UPDATE_LATENCY_TOLERANCE_UNSPECIFIED" - Defaults to + // PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_SENSITIVE. + // "PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_SENSITIVE" - The update will + // propagate to clients within several minutes on average and up to a few hours + // in rare cases. Throughput is limited to 7,200 updates per app per hour. + // "PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_TOLERANT" - The update will + // propagate to clients within 24 hours. Supports high throughput of up to + // 720,000 updates per app per hour using batch modification methods. + LatencyTolerance string `json:"latencyTolerance,omitempty"` + // OfferId: Required. The unique offer ID of the offer to delete. + OfferId string `json:"offerId,omitempty"` + // PackageName: Required. The parent app (package name) of the offer to delete. + PackageName string `json:"packageName,omitempty"` + // ProductId: Required. The parent one-time product (ID) of the offer to + // delete. + ProductId string `json:"productId,omitempty"` + // PurchaseOptionId: Required. The parent purchase option (ID) of the offer to + // delete. + PurchaseOptionId string `json:"purchaseOptionId,omitempty"` + // ForceSendFields is a list of field names (e.g. "LatencyTolerance") 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. "LatencyTolerance") 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 DeleteOneTimeProductOfferRequest) MarshalJSON() ([]byte, error) { + type NoMethod DeleteOneTimeProductOfferRequest + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// DeleteOneTimeProductRequest: Request message for deleting a one-time +// product. +type DeleteOneTimeProductRequest struct { + // LatencyTolerance: Optional. The latency tolerance for the propagation of + // this product update. Defaults to latency-sensitive. + // + // Possible values: + // "PRODUCT_UPDATE_LATENCY_TOLERANCE_UNSPECIFIED" - Defaults to + // PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_SENSITIVE. + // "PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_SENSITIVE" - The update will + // propagate to clients within several minutes on average and up to a few hours + // in rare cases. Throughput is limited to 7,200 updates per app per hour. + // "PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_TOLERANT" - The update will + // propagate to clients within 24 hours. Supports high throughput of up to + // 720,000 updates per app per hour using batch modification methods. + LatencyTolerance string `json:"latencyTolerance,omitempty"` + // PackageName: Required. The parent app (package name) of the one-time product + // to delete. + PackageName string `json:"packageName,omitempty"` + // ProductId: Required. The one-time product ID of the one-time product to + // delete. + ProductId string `json:"productId,omitempty"` + // ForceSendFields is a list of field names (e.g. "LatencyTolerance") 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. "LatencyTolerance") 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 DeleteOneTimeProductRequest) MarshalJSON() ([]byte, error) { + type NoMethod DeleteOneTimeProductRequest + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// DeletePurchaseOptionRequest: Request message for deleting a purchase option. +type DeletePurchaseOptionRequest struct { + // Force: Optional. This field has no effect for purchase options with no + // offers under them. For purchase options with associated offers: * If `force` + // is set to false (default), an error will be returned. * If `force` is set to + // true, any associated offers under the purchase option will be deleted. + Force bool `json:"force,omitempty"` + // LatencyTolerance: Optional. The latency tolerance for the propagation of + // this product update. Defaults to latency-sensitive. + // + // Possible values: + // "PRODUCT_UPDATE_LATENCY_TOLERANCE_UNSPECIFIED" - Defaults to + // PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_SENSITIVE. + // "PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_SENSITIVE" - The update will + // propagate to clients within several minutes on average and up to a few hours + // in rare cases. Throughput is limited to 7,200 updates per app per hour. + // "PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_TOLERANT" - The update will + // propagate to clients within 24 hours. Supports high throughput of up to + // 720,000 updates per app per hour using batch modification methods. + LatencyTolerance string `json:"latencyTolerance,omitempty"` + // PackageName: Required. The parent app (package name) of the purchase option + // to delete. + PackageName string `json:"packageName,omitempty"` + // ProductId: Required. The parent one-time product (ID) of the purchase option + // to delete. + ProductId string `json:"productId,omitempty"` + // PurchaseOptionId: Required. The purchase option ID of the purchase option to + // delete. + PurchaseOptionId string `json:"purchaseOptionId,omitempty"` + // ForceSendFields is a list of field names (e.g. "Force") 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. "Force") 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 DeletePurchaseOptionRequest) MarshalJSON() ([]byte, error) { + type NoMethod DeletePurchaseOptionRequest + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// DeobfuscationFile: Represents a deobfuscation file. +type DeobfuscationFile struct { + // SymbolType: The type of the deobfuscation file. + // + // Possible values: + // "deobfuscationFileTypeUnspecified" - Unspecified deobfuscation file type. + // "proguard" - Proguard deobfuscation file type. + // "nativeCode" - Native debugging symbols file type. SymbolType string `json:"symbolType,omitempty"` // ForceSendFields is a list of field names (e.g. "SymbolType") to // unconditionally include in API requests. By default, fields with empty or @@ -3180,6 +3921,35 @@ func (s GeneratedUniversalApk) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GetOneTimeProductOfferRequest: Request message for GetOneTimeProductOffers. +type GetOneTimeProductOfferRequest struct { + // OfferId: Required. The unique offer ID of the offer to get. + OfferId string `json:"offerId,omitempty"` + // PackageName: Required. The parent app (package name) of the offer to get. + PackageName string `json:"packageName,omitempty"` + // ProductId: Required. The parent one-time product (ID) of the offer to get. + ProductId string `json:"productId,omitempty"` + // PurchaseOptionId: Required. The parent purchase option (ID) of the offer to + // get. + PurchaseOptionId string `json:"purchaseOptionId,omitempty"` + // ForceSendFields is a list of field names (e.g. "OfferId") 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. "OfferId") 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 GetOneTimeProductOfferRequest) MarshalJSON() ([]byte, error) { + type NoMethod GetOneTimeProductOfferRequest + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GetSubscriptionOfferRequest: Request message for GetSubscriptionOffer. type GetSubscriptionOfferRequest struct { // BasePlanId: Required. The parent base plan (ID) of the offer to get. @@ -3982,6 +4752,64 @@ func (s ListDeviceTierConfigsResponse) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// ListOneTimeProductOffersResponse: Response message for +// ListOneTimeProductOffers. +type ListOneTimeProductOffersResponse struct { + // NextPageToken: A token, which can be sent as `page_token` to retrieve the + // next page. If this field is omitted, there are no subsequent pages. + NextPageToken string `json:"nextPageToken,omitempty"` + // OneTimeProductOffers: The one_time_product offers from the specified + // request. + OneTimeProductOffers []*OneTimeProductOffer `json:"oneTimeProductOffers,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 ListOneTimeProductOffersResponse) MarshalJSON() ([]byte, error) { + type NoMethod ListOneTimeProductOffersResponse + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// ListOneTimeProductsResponse: Response message for ListOneTimeProducts. +type ListOneTimeProductsResponse struct { + // NextPageToken: A token, which can be sent as `page_token` to retrieve the + // next page. If this field is omitted, there are no subsequent pages. + NextPageToken string `json:"nextPageToken,omitempty"` + // OneTimeProducts: The one-time products from the specified app. + OneTimeProducts []*OneTimeProduct `json:"oneTimeProducts,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 ListOneTimeProductsResponse) MarshalJSON() ([]byte, error) { + type NoMethod ListOneTimeProductsResponse + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // ListSubscriptionOffersResponse: Response message for ListSubscriptionOffers. type ListSubscriptionOffersResponse struct { // NextPageToken: A token, which can be sent as `page_token` to retrieve the @@ -4474,283 +5302,261 @@ func (s OneTimeExternalTransaction) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// OneTimePurchaseDetails: Details of a one-time purchase. -type OneTimePurchaseDetails struct { - // OfferId: The offer ID of the one-time purchase offer. - OfferId string `json:"offerId,omitempty"` - // PurchaseOptionId: ID of the purchase option. This field is set for both - // purchase options and variant offers. For purchase options, this ID - // identifies the purchase option itself. For variant offers, this ID refers to - // the associated purchase option, and in conjunction with offer_id it - // identifies the variant offer. - PurchaseOptionId string `json:"purchaseOptionId,omitempty"` - // Quantity: The number of items purchased (for multi-quantity item purchases). - Quantity int64 `json:"quantity,omitempty"` - // RentalDetails: The details of a rent purchase. Only set if it is a rent - // purchase. - RentalDetails *RentalDetails `json:"rentalDetails,omitempty"` - // ForceSendFields is a list of field names (e.g. "OfferId") 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. "OfferId") 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 OneTimePurchaseDetails) MarshalJSON() ([]byte, error) { - type NoMethod OneTimePurchaseDetails - return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) -} - -// Order: The Order resource encapsulates comprehensive information about a -// transaction made on Google Play. It includes a variety of attributes that -// provide details about the order itself, the products purchased, and the -// history of events related to the order. The Orders APIs provide real-time -// access to your order data within the Google Play ecosystem. You can retrieve -// detailed information and metadata for both one-time and recurring orders, -// including transaction details like charges, taxes, and refunds, as well as -// metadata such as pricing phases for subscriptions. The Orders APIs let you -// automate tasks related to order management, reducing the need for manual -// checks via the Play Developer Console. The following are some of the use -// cases for this API: + Real-time order data retrieval - Get order details and -// metadata immediately after a purchase using an order ID. + Order update -// synchronization - Periodically sync order updates to maintain an up-to-date -// record of order information. Note: + The Orders API calls count towards your -// Play Developer API quota, which defaults to 200K daily, and may be -// insufficient to sync extensive order histories. + A maximum of 1000 orders -// can be retrieved per call. Using larger page sizes is recommended to -// minimize quota usage. Check your quota in the Cloud Console and request more -// if required. -type Order struct { - // BuyerAddress: Address information for the customer, for use in tax - // computation. When Google is the Merchant of Record for the order, only - // country is shown. - BuyerAddress *BuyerAddress `json:"buyerAddress,omitempty"` - // CreateTime: The time when the order was created. - CreateTime string `json:"createTime,omitempty"` - // DeveloperRevenueInBuyerCurrency: Your revenue for this order in the buyer's - // currency, including deductions of partial refunds, taxes and fees. Google - // deducts standard transaction and third party fees from each sale, including - // VAT in some regions. - DeveloperRevenueInBuyerCurrency *Money `json:"developerRevenueInBuyerCurrency,omitempty"` - // LastEventTime: The time of the last event that occurred on the order. - LastEventTime string `json:"lastEventTime,omitempty"` - // LineItems: The individual line items making up this order. - LineItems []*LineItem `json:"lineItems,omitempty"` - // OrderDetails: Detailed information about the order at creation time. - OrderDetails *OrderDetails `json:"orderDetails,omitempty"` - // OrderHistory: Details about events which modified the order. - OrderHistory *OrderHistory `json:"orderHistory,omitempty"` - // OrderId: The order ID. - OrderId string `json:"orderId,omitempty"` - // PointsDetails: Play points applied to the order, including offer - // information, discount rate and point values. - PointsDetails *PointsDetails `json:"pointsDetails,omitempty"` - // PurchaseToken: The token provided to the user's device when the subscription - // or item was purchased. - PurchaseToken string `json:"purchaseToken,omitempty"` - // State: The state of the order. - // - // Possible values: - // "STATE_UNSPECIFIED" - State unspecified. This value is not used. - // "PENDING" - Order has been created and is waiting to be processed. - // "PROCESSED" - Order has been successfully processed. - // "CANCELED" - Order was canceled before being processed. - // "PENDING_REFUND" - Requested refund is waiting to be processed. - // "PARTIALLY_REFUNDED" - Part of the order amount was refunded. - // "REFUNDED" - The full order amount was refunded. - State string `json:"state,omitempty"` - // Tax: The total tax paid as a part of this order. - Tax *Money `json:"tax,omitempty"` - // Total: The final amount paid by the customer, taking into account discounts - // and taxes. - Total *Money `json:"total,omitempty"` +// OneTimeProduct: A single one-time product for an app. +type OneTimeProduct struct { + // Listings: Required. Set of localized title and description data. Must not + // have duplicate entries with the same language_code. + Listings []*OneTimeProductListing `json:"listings,omitempty"` + // OfferTags: Optional. List of up to 20 custom tags specified for this + // one-time product, and returned to the app through the billing library. + // Purchase options and offers for this product will also receive these tags in + // the billing library. + OfferTags []*OfferTag `json:"offerTags,omitempty"` + // PackageName: Required. Immutable. Package name of the parent app. + PackageName string `json:"packageName,omitempty"` + // ProductId: Required. Immutable. Unique product ID of the product. Unique + // within the parent app. Product IDs must start with a number or lowercase + // letter, and can contain numbers (0-9), lowercase letters (a-z), underscores + // (_), and periods (.). + ProductId string `json:"productId,omitempty"` + // PurchaseOptions: Required. The set of purchase options for this one-time + // product. + PurchaseOptions []*OneTimeProductPurchaseOption `json:"purchaseOptions,omitempty"` + // RegionsVersion: Output only. The version of the regions configuration that + // was used to generate the one-time product. + RegionsVersion *RegionsVersion `json:"regionsVersion,omitempty"` + // RestrictedPaymentCountries: Optional. Countries where the purchase of this + // one-time product is restricted to payment methods registered in the same + // country. If empty, no payment location restrictions are imposed. + RestrictedPaymentCountries *RestrictedPaymentCountries `json:"restrictedPaymentCountries,omitempty"` + // TaxAndComplianceSettings: Details about taxes and legal compliance. + TaxAndComplianceSettings *OneTimeProductTaxAndComplianceSettings `json:"taxAndComplianceSettings,omitempty"` // ServerResponse contains the HTTP response code and headers from the server. googleapi.ServerResponse `json:"-"` - // ForceSendFields is a list of field names (e.g. "BuyerAddress") to + // ForceSendFields is a list of field names (e.g. "Listings") 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. "BuyerAddress") to include in API + // NullFields is a list of field names (e.g. "Listings") 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 Order) MarshalJSON() ([]byte, error) { - type NoMethod Order +func (s OneTimeProduct) MarshalJSON() ([]byte, error) { + type NoMethod OneTimeProduct return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// OrderDetails: Detailed information about the order at creation time. -type OrderDetails struct { - // TaxInclusive: Indicates whether the listed price was tax inclusive or not. - TaxInclusive bool `json:"taxInclusive,omitempty"` - // ForceSendFields is a list of field names (e.g. "TaxInclusive") to +// OneTimeProductBuyPurchaseOption: A purchase option that can be bought. +type OneTimeProductBuyPurchaseOption struct { + // LegacyCompatible: Optional. Whether this purchase option will be available + // in legacy PBL flows that do not support one-time products model. Up to one + // "buy" purchase option can be marked as backwards compatible. + LegacyCompatible bool `json:"legacyCompatible,omitempty"` + // MultiQuantityEnabled: Optional. Whether this purchase option allows + // multi-quantity. Multi-quantity allows buyer to purchase more than one item + // in a single checkout. + MultiQuantityEnabled bool `json:"multiQuantityEnabled,omitempty"` + // ForceSendFields is a list of field names (e.g. "LegacyCompatible") 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. "TaxInclusive") 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. "LegacyCompatible") 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 OrderDetails) MarshalJSON() ([]byte, error) { - type NoMethod OrderDetails +func (s OneTimeProductBuyPurchaseOption) MarshalJSON() ([]byte, error) { + type NoMethod OneTimeProductBuyPurchaseOption return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// OrderHistory: Details about events which modified the order. -type OrderHistory struct { - // CancellationEvent: Details of when the order was canceled. - CancellationEvent *CancellationEvent `json:"cancellationEvent,omitempty"` - // PartialRefundEvents: Details of the partial refund events for this order. - PartialRefundEvents []*PartialRefundEvent `json:"partialRefundEvents,omitempty"` - // ProcessedEvent: Details of when the order was processed. - ProcessedEvent *ProcessedEvent `json:"processedEvent,omitempty"` - // RefundEvent: Details of when the order was fully refunded. - RefundEvent *RefundEvent `json:"refundEvent,omitempty"` - // ForceSendFields is a list of field names (e.g. "CancellationEvent") to - // unconditionally include in API requests. By default, fields with empty or - // default values are omitted from API requests. See +// OneTimeProductDiscountedOffer: Configuration specific to discounted offers. +type OneTimeProductDiscountedOffer struct { + // EndTime: Time when the offer will stop being available. + EndTime string `json:"endTime,omitempty"` + // RedemptionLimit: Optional. The number of times this offer can be redeemed. + // If unset or set to 0, allows for unlimited offer redemptions. Otherwise must + // be a number between 1 and 50 inclusive. + RedemptionLimit int64 `json:"redemptionLimit,omitempty,string"` + // StartTime: Time when the offer will start being available. + StartTime string `json:"startTime,omitempty"` + // ForceSendFields is a list of field names (e.g. "EndTime") 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. "CancellationEvent") 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. "EndTime") 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 OrderHistory) MarshalJSON() ([]byte, error) { - type NoMethod OrderHistory +func (s OneTimeProductDiscountedOffer) MarshalJSON() ([]byte, error) { + type NoMethod OneTimeProductDiscountedOffer return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// OtherRecurringProduct: Details of a recurring external transaction product -// which doesn't belong to any other more specific category. -type OtherRecurringProduct struct { -} - -// OtherRegionsBasePlanConfig: Pricing information for any new locations Play -// may launch in. -type OtherRegionsBasePlanConfig struct { - // EurPrice: Required. Price in EUR to use for any new locations Play may - // launch in. - EurPrice *Money `json:"eurPrice,omitempty"` - // NewSubscriberAvailability: Whether the base plan is available for new - // subscribers in any new locations Play may launch in. If not specified, this - // will default to false. - NewSubscriberAvailability bool `json:"newSubscriberAvailability,omitempty"` - // UsdPrice: Required. Price in USD to use for any new locations Play may - // launch in. - UsdPrice *Money `json:"usdPrice,omitempty"` - // ForceSendFields is a list of field names (e.g. "EurPrice") to +// OneTimeProductListing: Regional store listing for a one-time product. +type OneTimeProductListing struct { + // Description: Required. The description of this product in the language of + // this listing. The maximum length is 200 characters. + Description string `json:"description,omitempty"` + // LanguageCode: Required. The language of this listing, as defined by BCP-47, + // e.g., "en-US". + LanguageCode string `json:"languageCode,omitempty"` + // Title: Required. The title of this product in the language of this listing. + // The maximum length is 55 characters. + Title string `json:"title,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. "EurPrice") to include in API + // 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 OtherRegionsBasePlanConfig) MarshalJSON() ([]byte, error) { - type NoMethod OtherRegionsBasePlanConfig +func (s OneTimeProductListing) MarshalJSON() ([]byte, error) { + type NoMethod OneTimeProductListing return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// OtherRegionsSubscriptionOfferConfig: Configuration for any new locations -// Play may launch in specified on a subscription offer. -type OtherRegionsSubscriptionOfferConfig struct { - // OtherRegionsNewSubscriberAvailability: Whether the subscription offer in any - // new locations Play may launch in the future. If not specified, this will - // default to false. - OtherRegionsNewSubscriberAvailability bool `json:"otherRegionsNewSubscriberAvailability,omitempty"` - // ForceSendFields is a list of field names (e.g. - // "OtherRegionsNewSubscriberAvailability") to unconditionally include in API - // requests. By default, fields with empty or default values are omitted from - // API requests. See +// OneTimeProductOffer: A single offer for a one-time product. +type OneTimeProductOffer struct { + // DiscountedOffer: A discounted offer. + DiscountedOffer *OneTimeProductDiscountedOffer `json:"discountedOffer,omitempty"` + // OfferId: Required. Immutable. The ID of this product offer. Must be unique + // within the purchase option. It must start with a number or lower-case + // letter, and can only contain lower-case letters (a-z), numbers (0-9), and + // hyphens (-). The maximum length is 63 characters. + OfferId string `json:"offerId,omitempty"` + // OfferTags: Optional. List of up to 20 custom tags specified for this offer, + // and returned to the app through the billing library. + OfferTags []*OfferTag `json:"offerTags,omitempty"` + // PackageName: Required. Immutable. The package name of the app the parent + // product belongs to. + PackageName string `json:"packageName,omitempty"` + // PreOrderOffer: A pre-order offer. + PreOrderOffer *OneTimeProductPreOrderOffer `json:"preOrderOffer,omitempty"` + // ProductId: Required. Immutable. The ID of the parent product this offer + // belongs to. + ProductId string `json:"productId,omitempty"` + // PurchaseOptionId: Required. Immutable. The ID of the purchase option to + // which this offer is an extension. + PurchaseOptionId string `json:"purchaseOptionId,omitempty"` + // RegionalPricingAndAvailabilityConfigs: Set of regional pricing and + // availability information for this offer. Must not have duplicate entries + // with the same region_code. + RegionalPricingAndAvailabilityConfigs []*OneTimeProductOfferRegionalPricingAndAvailabilityConfig `json:"regionalPricingAndAvailabilityConfigs,omitempty"` + // RegionsVersion: Output only. The version of the regions configuration that + // was used to generate the one-time product offer. + RegionsVersion *RegionsVersion `json:"regionsVersion,omitempty"` + // State: Output only. The current state of this offer. This field cannot be + // changed by updating the resource. Use the dedicated endpoints instead. + // + // Possible values: + // "STATE_UNSPECIFIED" - Default value, should never be used. + // "DRAFT" - The offer is not and has never been available to users. + // "ACTIVE" - The offer is available to users, as long as its conditions are + // met. + // "CANCELLED" - This state is specific to pre-orders. The offer is cancelled + // and not available to users. All pending orders related to this offer were + // cancelled. + // "INACTIVE" - This state is specific to discounted offers. The offer is no + // longer available to users. + State string `json:"state,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the server. + googleapi.ServerResponse `json:"-"` + // ForceSendFields is a list of field names (e.g. "DiscountedOffer") 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. - // "OtherRegionsNewSubscriberAvailability") 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 is a list of field names (e.g. "DiscountedOffer") 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 OtherRegionsSubscriptionOfferConfig) MarshalJSON() ([]byte, error) { - type NoMethod OtherRegionsSubscriptionOfferConfig +func (s OneTimeProductOffer) MarshalJSON() ([]byte, error) { + type NoMethod OneTimeProductOffer return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// OtherRegionsSubscriptionOfferPhaseConfig: Configuration for any new -// locations Play may launch in for a single offer phase. -type OtherRegionsSubscriptionOfferPhaseConfig struct { - // AbsoluteDiscounts: The absolute amount of money subtracted from the base - // plan price prorated over the phase duration that the user pays for this - // offer phase. For example, if the base plan price for this region is $12 for - // a period of 1 year, then a $1 absolute discount for a phase of a duration of - // 3 months would correspond to a price of $2. The resulting price may not be - // smaller than the minimum price allowed for any new locations Play may launch - // in. - AbsoluteDiscounts *OtherRegionsSubscriptionOfferPhasePrices `json:"absoluteDiscounts,omitempty"` - // Free: Set to specify this offer is free to obtain. - Free *OtherRegionsSubscriptionOfferPhaseFreePriceOverride `json:"free,omitempty"` - // OtherRegionsPrices: The absolute price the user pays for this offer phase. - // The price must not be smaller than the minimum price allowed for any new - // locations Play may launch in. - OtherRegionsPrices *OtherRegionsSubscriptionOfferPhasePrices `json:"otherRegionsPrices,omitempty"` - // RelativeDiscount: The fraction of the base plan price prorated over the - // phase duration that the user pays for this offer phase. For example, if the - // base plan price for this region is $12 for a period of 1 year, then a 50% - // discount for a phase of a duration of 3 months would correspond to a price - // of $1.50. The discount must be specified as a fraction strictly larger than - // 0 and strictly smaller than 1. The resulting price will be rounded to the - // nearest billable unit (e.g. cents for USD). The relative discount is - // considered invalid if the discounted price ends up being smaller than the - // minimum price allowed in any new locations Play may launch in. +// OneTimeProductOfferNoPriceOverrideOptions: Options for one-time product +// offers without a regional price override. +type OneTimeProductOfferNoPriceOverrideOptions struct { +} + +// OneTimeProductOfferRegionalPricingAndAvailabilityConfig: Regional pricing +// and availability configuration for a one-time product offer. +type OneTimeProductOfferRegionalPricingAndAvailabilityConfig struct { + // AbsoluteDiscount: The absolute value of the discount that is subtracted from + // the purchase option price. It should be between 0 and the purchase option + // price. + AbsoluteDiscount *Money `json:"absoluteDiscount,omitempty"` + // Availability: Required. The availability for this region. + // + // Possible values: + // "AVAILABILITY_UNSPECIFIED" - Unspecified availability. Must not be used. + // "AVAILABLE" - The offer is available to users. + // "NO_LONGER_AVAILABLE" - The offer is no longer available to users. This + // value can only be used if the availability was previously set as AVAILABLE. + Availability string `json:"availability,omitempty"` + // NoOverride: The price defined in the purchase option for this region will be + // used. + NoOverride *OneTimeProductOfferNoPriceOverrideOptions `json:"noOverride,omitempty"` + // RegionCode: Required. Region code this configuration applies to, as defined + // by ISO 3166-2, e.g., "US". + RegionCode string `json:"regionCode,omitempty"` + // RelativeDiscount: The fraction of the purchase option price that the user + // pays for this offer. For example, if the purchase option price for this + // region is $12, then a 50% discount would correspond to a price of $6. The + // discount must be specified as a fraction strictly larger than 0 and strictly + // smaller than 1. The resulting price will be rounded to the nearest billable + // unit (e.g. cents for USD). The relative discount is considered invalid if + // the discounted price ends up being smaller than the minimum price allowed in + // this region. RelativeDiscount float64 `json:"relativeDiscount,omitempty"` - // ForceSendFields is a list of field names (e.g. "AbsoluteDiscounts") to + // ForceSendFields is a list of field names (e.g. "AbsoluteDiscount") 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. "AbsoluteDiscounts") to include in + // NullFields is a list of field names (e.g. "AbsoluteDiscount") 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 OtherRegionsSubscriptionOfferPhaseConfig) MarshalJSON() ([]byte, error) { - type NoMethod OtherRegionsSubscriptionOfferPhaseConfig +func (s OneTimeProductOfferRegionalPricingAndAvailabilityConfig) MarshalJSON() ([]byte, error) { + type NoMethod OneTimeProductOfferRegionalPricingAndAvailabilityConfig return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -func (s *OtherRegionsSubscriptionOfferPhaseConfig) UnmarshalJSON(data []byte) error { - type NoMethod OtherRegionsSubscriptionOfferPhaseConfig +func (s *OneTimeProductOfferRegionalPricingAndAvailabilityConfig) UnmarshalJSON(data []byte) error { + type NoMethod OneTimeProductOfferRegionalPricingAndAvailabilityConfig var s1 struct { RelativeDiscount gensupport.JSONFloat64 `json:"relativeDiscount"` *NoMethod @@ -4763,3585 +5569,3642 @@ func (s *OtherRegionsSubscriptionOfferPhaseConfig) UnmarshalJSON(data []byte) er return nil } -// OtherRegionsSubscriptionOfferPhaseFreePriceOverride: Represents the free -// price override configuration for any new locations Play may launch for a -// single offer phase. -type OtherRegionsSubscriptionOfferPhaseFreePriceOverride struct { -} - -// OtherRegionsSubscriptionOfferPhasePrices: Pricing information for any new -// locations Play may launch in. -type OtherRegionsSubscriptionOfferPhasePrices struct { - // EurPrice: Required. Price in EUR to use for any new locations Play may - // launch in. - EurPrice *Money `json:"eurPrice,omitempty"` - // UsdPrice: Required. Price in USD to use for any new locations Play may - // launch in. - UsdPrice *Money `json:"usdPrice,omitempty"` - // ForceSendFields is a list of field names (e.g. "EurPrice") to - // unconditionally include in API requests. By default, fields with empty or - // default values are omitted from API requests. See +// OneTimeProductPreOrderOffer: Configuration specific to pre-order offers. +type OneTimeProductPreOrderOffer struct { + // EndTime: Required. Time when the pre-order will stop being available. + EndTime string `json:"endTime,omitempty"` + // PriceChangeBehavior: Required. Immutable. Specifies how price changes affect + // pre-existing pre-orders. + // + // Possible values: + // "PRE_ORDER_PRICE_CHANGE_BEHAVIOR_UNSPECIFIED" - Unspecified price change + // behavior. Must not be used. + // "PRE_ORDER_PRICE_CHANGE_BEHAVIOR_TWO_POINT_LOWEST" - The buyer gets + // charged the minimum between the initial price at the time of pre-order and + // the final offer price on the release date. + // "PRE_ORDER_PRICE_CHANGE_BEHAVIOR_NEW_ORDERS_ONLY" - The buyer gets the + // same price as the one they pre-ordered, regardless of any price changes that + // may have happened after the pre-order. + PriceChangeBehavior string `json:"priceChangeBehavior,omitempty"` + // ReleaseTime: Required. Time on which the product associated with the + // pre-order will be released and the pre-order orders fulfilled. + ReleaseTime string `json:"releaseTime,omitempty"` + // StartTime: Required. Time when the pre-order will start being available. + StartTime string `json:"startTime,omitempty"` + // ForceSendFields is a list of field names (e.g. "EndTime") 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. "EurPrice") to include in API + // NullFields is a list of field names (e.g. "EndTime") 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 OtherRegionsSubscriptionOfferPhasePrices) MarshalJSON() ([]byte, error) { - type NoMethod OtherRegionsSubscriptionOfferPhasePrices +func (s OneTimeProductPreOrderOffer) MarshalJSON() ([]byte, error) { + type NoMethod OneTimeProductPreOrderOffer return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// PageInfo: Information about the current page. List operations that supports -// paging return only one "page" of results. This protocol buffer message -// describes the page that has been returned. -type PageInfo struct { - // ResultPerPage: Maximum number of results returned in one page. ! The number - // of results included in the API response. - ResultPerPage int64 `json:"resultPerPage,omitempty"` - // StartIndex: Index of the first result returned in the current page. - StartIndex int64 `json:"startIndex,omitempty"` - // TotalResults: Total number of results available on the backend ! The total - // number of results in the result set. - TotalResults int64 `json:"totalResults,omitempty"` - // ForceSendFields is a list of field names (e.g. "ResultPerPage") to +// OneTimeProductPurchaseOption: A single purchase option for a one-time +// product. +type OneTimeProductPurchaseOption struct { + // BuyOption: A purchase option that can be bought. + BuyOption *OneTimeProductBuyPurchaseOption `json:"buyOption,omitempty"` + // NewRegionsConfig: Pricing information for any new locations Play may launch + // in the future. If omitted, the purchase option will not be automatically + // available in any new locations Play may launch in the future. + NewRegionsConfig *OneTimeProductPurchaseOptionNewRegionsConfig `json:"newRegionsConfig,omitempty"` + // OfferTags: Optional. List of up to 20 custom tags specified for this + // purchase option, and returned to the app through the billing library. Offers + // for this purchase option will also receive these tags in the billing + // library. + OfferTags []*OfferTag `json:"offerTags,omitempty"` + // PurchaseOptionId: Required. Immutable. The unique identifier of this + // purchase option. Must be unique within the one-time product. It must start + // with a number or lower-case letter, and can only contain lower-case letters + // (a-z), numbers (0-9), and hyphens (-). The maximum length is 63 characters. + PurchaseOptionId string `json:"purchaseOptionId,omitempty"` + // RegionalPricingAndAvailabilityConfigs: Regional pricing and availability + // information for this purchase option. + RegionalPricingAndAvailabilityConfigs []*OneTimeProductPurchaseOptionRegionalPricingAndAvailabilityConfig `json:"regionalPricingAndAvailabilityConfigs,omitempty"` + // RentOption: A purchase option that can be rented. + RentOption *OneTimeProductRentPurchaseOption `json:"rentOption,omitempty"` + // State: Output only. The state of the purchase option, i.e., whether it's + // active. This field cannot be changed by updating the resource. Use the + // dedicated endpoints instead. + // + // Possible values: + // "STATE_UNSPECIFIED" - Default value, should never be used. + // "DRAFT" - The purchase option is not and has never been available to + // users. + // "ACTIVE" - The purchase option is available to users. + // "INACTIVE" - The purchase option is not available to users anymore. + // "INACTIVE_PUBLISHED" - The purchase option is not available for purchase + // anymore, but we continue to expose its offer via the Play Billing Library + // for backwards compatibility. Only automatically migrated purchase options + // can be in this state. + State string `json:"state,omitempty"` + // TaxAndComplianceSettings: Optional. Details about taxes and legal + // compliance. + TaxAndComplianceSettings *PurchaseOptionTaxAndComplianceSettings `json:"taxAndComplianceSettings,omitempty"` + // ForceSendFields is a list of field names (e.g. "BuyOption") 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. "ResultPerPage") to include in API + // NullFields is a list of field names (e.g. "BuyOption") 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 PageInfo) MarshalJSON() ([]byte, error) { - type NoMethod PageInfo +func (s OneTimeProductPurchaseOption) MarshalJSON() ([]byte, error) { + type NoMethod OneTimeProductPurchaseOption return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// PaidAppDetails: Details of a paid app purchase. -type PaidAppDetails struct { -} - -// PartialRefund: A partial refund of a transaction. -type PartialRefund struct { - // RefundId: Required. A unique id distinguishing this partial refund. If the - // refund is successful, subsequent refunds with the same id will fail. Must be - // unique across refunds for one individual transaction. - RefundId string `json:"refundId,omitempty"` - // RefundPreTaxAmount: Required. The pre-tax amount of the partial refund. - // Should be less than the remaining pre-tax amount of the transaction. - RefundPreTaxAmount *Price `json:"refundPreTaxAmount,omitempty"` - // ForceSendFields is a list of field names (e.g. "RefundId") to +// OneTimeProductPurchaseOptionNewRegionsConfig: Pricing information for any +// new regions Play may launch in the future. +type OneTimeProductPurchaseOptionNewRegionsConfig struct { + // Availability: Required. The regional availability for the new regions + // config. When set to AVAILABLE, the pricing information will be used for any + // new regions Play may launch in the future. + // + // Possible values: + // "AVAILABILITY_UNSPECIFIED" - Unspecified availability. Must not be used. + // "AVAILABLE" - The config will be used for any new regions Play may launch + // in the future. + // "NO_LONGER_AVAILABLE" - The config is not available anymore and will not + // be used for any new regions Play may launch in the future. This value can + // only be used if the availability was previously set as AVAILABLE. + Availability string `json:"availability,omitempty"` + // EurPrice: Required. Price in EUR to use for any new regions Play may launch + // in. + EurPrice *Money `json:"eurPrice,omitempty"` + // UsdPrice: Required. Price in USD to use for any new regions Play may launch + // in. + UsdPrice *Money `json:"usdPrice,omitempty"` + // ForceSendFields is a list of field names (e.g. "Availability") 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. "RefundId") to include in API + // NullFields is a list of field names (e.g. "Availability") 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 PartialRefund) MarshalJSON() ([]byte, error) { - type NoMethod PartialRefund +func (s OneTimeProductPurchaseOptionNewRegionsConfig) MarshalJSON() ([]byte, error) { + type NoMethod OneTimeProductPurchaseOptionNewRegionsConfig return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// PartialRefundEvent: Details of the partial refund events for this order. -type PartialRefundEvent struct { - // CreateTime: The time when the partial refund was created. - CreateTime string `json:"createTime,omitempty"` - // ProcessTime: The time when the partial refund was processed. - ProcessTime string `json:"processTime,omitempty"` - // RefundDetails: Details for the partial refund. - RefundDetails *RefundDetails `json:"refundDetails,omitempty"` - // State: The state of the partial refund. +// OneTimeProductPurchaseOptionRegionalPricingAndAvailabilityConfig: Regional +// pricing and availability configuration for a purchase option. +type OneTimeProductPurchaseOptionRegionalPricingAndAvailabilityConfig struct { + // Availability: The availability of the purchase option. // // Possible values: - // "STATE_UNSPECIFIED" - State unspecified. This value is not used. - // "PENDING" - The partial refund has been created, but not yet processed. - // "PROCESSED_SUCCESSFULLY" - The partial refund was processed successfully. - State string `json:"state,omitempty"` - // ForceSendFields is a list of field names (e.g. "CreateTime") to + // "AVAILABILITY_UNSPECIFIED" - Unspecified availability. Must not be used. + // "AVAILABLE" - The purchase option is available to users. + // "NO_LONGER_AVAILABLE" - The purchase option is no longer available to + // users. This value can only be used if the availability was previously set as + // AVAILABLE. + // "AVAILABLE_IF_RELEASED" - The purchase option is initially unavailable, + // but made available via a released pre-order offer. + Availability string `json:"availability,omitempty"` + // Price: The price of the purchase option in the specified region. Must be set + // in the currency that is linked to the specified region. + Price *Money `json:"price,omitempty"` + // RegionCode: Required. Region code this configuration applies to, as defined + // by ISO 3166-2, e.g., "US". + RegionCode string `json:"regionCode,omitempty"` + // ForceSendFields is a list of field names (e.g. "Availability") 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. "Availability") 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 PartialRefundEvent) MarshalJSON() ([]byte, error) { - type NoMethod PartialRefundEvent +func (s OneTimeProductPurchaseOptionRegionalPricingAndAvailabilityConfig) MarshalJSON() ([]byte, error) { + type NoMethod OneTimeProductPurchaseOptionRegionalPricingAndAvailabilityConfig return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// PausedStateContext: Information specific to a subscription in paused state. -type PausedStateContext struct { - // AutoResumeTime: Time at which the subscription will be automatically - // resumed. - AutoResumeTime string `json:"autoResumeTime,omitempty"` - // ForceSendFields is a list of field names (e.g. "AutoResumeTime") to +// OneTimeProductRentPurchaseOption: A purchase option that can be rented. +type OneTimeProductRentPurchaseOption struct { + // ExpirationPeriod: Optional. The amount of time the user has after starting + // consuming the entitlement before it is revoked. Specified in ISO 8601 + // format. + ExpirationPeriod string `json:"expirationPeriod,omitempty"` + // RentalPeriod: Required. The amount of time a user has the entitlement for. + // Starts at purchase flow completion. Specified in ISO 8601 format. + RentalPeriod string `json:"rentalPeriod,omitempty"` + // ForceSendFields is a list of field names (e.g. "ExpirationPeriod") 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. "AutoResumeTime") to include in + // NullFields is a list of field names (e.g. "ExpirationPeriod") 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 PausedStateContext) MarshalJSON() ([]byte, error) { - type NoMethod PausedStateContext +func (s OneTimeProductRentPurchaseOption) MarshalJSON() ([]byte, error) { + type NoMethod OneTimeProductRentPurchaseOption return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// PendingCancellation: This is an indicator of whether there is a pending -// cancellation on the virtual installment plan. The cancellation will happen -// only after the user finished all committed payments. -type PendingCancellation struct { -} - -// PointsDetails: Details relating to any Play Points applied to an order. -type PointsDetails struct { - // PointsCouponValue: The monetary value of a Play Points coupon. This is the - // discount the coupon provides, which may not be the total amount. Only set - // when Play Points coupons have been used. E.g. for a 100 points for $2 - // coupon, this is $2. - PointsCouponValue *Money `json:"pointsCouponValue,omitempty"` - // PointsDiscountRateMicros: The percentage rate which the Play Points - // promotion reduces the cost by. E.g. for a 100 points for $2 coupon, this is - // 500,000. Since $2 has an estimate of 200 points, but the actual Points - // required, 100, is 50% of this, and 50% in micros is 500,000. Between 0 and - // 1,000,000. - PointsDiscountRateMicros int64 `json:"pointsDiscountRateMicros,omitempty,string"` - // PointsOfferId: ID unique to the play points offer in use for this order. - PointsOfferId string `json:"pointsOfferId,omitempty"` - // PointsSpent: The number of Play Points applied in this order. E.g. for a 100 - // points for $2 coupon, this is 100. For coupon stacked with base offer, this - // is the total points spent across both. - PointsSpent int64 `json:"pointsSpent,omitempty,string"` - // ForceSendFields is a list of field names (e.g. "PointsCouponValue") to +// OneTimeProductTaxAndComplianceSettings: Details about taxation, Google Play +// policy and legal compliance for one-time products. +type OneTimeProductTaxAndComplianceSettings struct { + // IsTokenizedDigitalAsset: Whether this one-time product is declared as a + // product representing a tokenized digital asset. + IsTokenizedDigitalAsset bool `json:"isTokenizedDigitalAsset,omitempty"` + // RegionalTaxConfigs: Regional tax configuration. + RegionalTaxConfigs []*RegionalTaxConfig `json:"regionalTaxConfigs,omitempty"` + // ForceSendFields is a list of field names (e.g. "IsTokenizedDigitalAsset") 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. "PointsCouponValue") 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. "IsTokenizedDigitalAsset") 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 PointsDetails) MarshalJSON() ([]byte, error) { - type NoMethod PointsDetails +func (s OneTimeProductTaxAndComplianceSettings) MarshalJSON() ([]byte, error) { + type NoMethod OneTimeProductTaxAndComplianceSettings return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// PrepaidBasePlanType: Represents a base plan that does not automatically -// renew at the end of the base plan, and must be manually renewed by the user. -type PrepaidBasePlanType struct { - // BillingPeriodDuration: Required. Immutable. Subscription period, specified - // in ISO 8601 format. For a list of acceptable billing periods, refer to the - // help center. The duration is immutable after the base plan is created. - BillingPeriodDuration string `json:"billingPeriodDuration,omitempty"` - // TimeExtension: Whether users should be able to extend this prepaid base plan - // in Google Play surfaces. Defaults to TIME_EXTENSION_ACTIVE if not specified. - // - // Possible values: - // "TIME_EXTENSION_UNSPECIFIED" - Unspecified state. - // "TIME_EXTENSION_ACTIVE" - Time extension is active. Users are allowed to - // top-up or extend their prepaid plan. - // "TIME_EXTENSION_INACTIVE" - Time extension is inactive. Users cannot - // top-up or extend their prepaid plan. - TimeExtension string `json:"timeExtension,omitempty"` - // ForceSendFields is a list of field names (e.g. "BillingPeriodDuration") to - // unconditionally include in API requests. By default, fields with empty or - // default values are omitted from API requests. See +// OneTimePurchaseDetails: Details of a one-time purchase. +type OneTimePurchaseDetails struct { + // OfferId: The offer ID of the one-time purchase offer. + OfferId string `json:"offerId,omitempty"` + // PurchaseOptionId: ID of the purchase option. This field is set for both + // purchase options and variant offers. For purchase options, this ID + // identifies the purchase option itself. For variant offers, this ID refers to + // the associated purchase option, and in conjunction with offer_id it + // identifies the variant offer. + PurchaseOptionId string `json:"purchaseOptionId,omitempty"` + // Quantity: The number of items purchased (for multi-quantity item purchases). + Quantity int64 `json:"quantity,omitempty"` + // RentalDetails: The details of a rent purchase. Only set if it is a rent + // purchase. + RentalDetails *RentalDetails `json:"rentalDetails,omitempty"` + // ForceSendFields is a list of field names (e.g. "OfferId") 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. "BillingPeriodDuration") 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. "OfferId") 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 PrepaidBasePlanType) MarshalJSON() ([]byte, error) { - type NoMethod PrepaidBasePlanType +func (s OneTimePurchaseDetails) MarshalJSON() ([]byte, error) { + type NoMethod OneTimePurchaseDetails return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// PrepaidPlan: Information related to a prepaid plan. -type PrepaidPlan struct { - // AllowExtendAfterTime: If present, this is the time after which top up - // purchases are allowed for the prepaid plan. Will not be present for expired - // prepaid plans. - AllowExtendAfterTime string `json:"allowExtendAfterTime,omitempty"` - // ForceSendFields is a list of field names (e.g. "AllowExtendAfterTime") to +// Order: The Order resource encapsulates comprehensive information about a +// transaction made on Google Play. It includes a variety of attributes that +// provide details about the order itself, the products purchased, and the +// history of events related to the order. The Orders APIs provide real-time +// access to your order data within the Google Play ecosystem. You can retrieve +// detailed information and metadata for both one-time and recurring orders, +// including transaction details like charges, taxes, and refunds, as well as +// metadata such as pricing phases for subscriptions. The Orders APIs let you +// automate tasks related to order management, reducing the need for manual +// checks via the Play Developer Console. The following are some of the use +// cases for this API: + Real-time order data retrieval - Get order details and +// metadata immediately after a purchase using an order ID. + Order update +// synchronization - Periodically sync order updates to maintain an up-to-date +// record of order information. Note: + The Orders API calls count towards your +// Play Developer API quota, which defaults to 200K daily, and may be +// insufficient to sync extensive order histories. + A maximum of 1000 orders +// can be retrieved per call. Using larger page sizes is recommended to +// minimize quota usage. Check your quota in the Cloud Console and request more +// if required. +type Order struct { + // BuyerAddress: Address information for the customer, for use in tax + // computation. When Google is the Merchant of Record for the order, only + // country is shown. + BuyerAddress *BuyerAddress `json:"buyerAddress,omitempty"` + // CreateTime: The time when the order was created. + CreateTime string `json:"createTime,omitempty"` + // DeveloperRevenueInBuyerCurrency: Your revenue for this order in the buyer's + // currency, including deductions of partial refunds, taxes and fees. Google + // deducts standard transaction and third party fees from each sale, including + // VAT in some regions. + DeveloperRevenueInBuyerCurrency *Money `json:"developerRevenueInBuyerCurrency,omitempty"` + // LastEventTime: The time of the last event that occurred on the order. + LastEventTime string `json:"lastEventTime,omitempty"` + // LineItems: The individual line items making up this order. + LineItems []*LineItem `json:"lineItems,omitempty"` + // OrderDetails: Detailed information about the order at creation time. + OrderDetails *OrderDetails `json:"orderDetails,omitempty"` + // OrderHistory: Details about events which modified the order. + OrderHistory *OrderHistory `json:"orderHistory,omitempty"` + // OrderId: The order ID. + OrderId string `json:"orderId,omitempty"` + // PointsDetails: Play points applied to the order, including offer + // information, discount rate and point values. + PointsDetails *PointsDetails `json:"pointsDetails,omitempty"` + // PurchaseToken: The token provided to the user's device when the subscription + // or item was purchased. + PurchaseToken string `json:"purchaseToken,omitempty"` + // State: The state of the order. + // + // Possible values: + // "STATE_UNSPECIFIED" - State unspecified. This value is not used. + // "PENDING" - Order has been created and is waiting to be processed. + // "PROCESSED" - Order has been successfully processed. + // "CANCELED" - Order was canceled before being processed. + // "PENDING_REFUND" - Requested refund is waiting to be processed. + // "PARTIALLY_REFUNDED" - Part of the order amount was refunded. + // "REFUNDED" - The full order amount was refunded. + State string `json:"state,omitempty"` + // Tax: The total tax paid as a part of this order. + Tax *Money `json:"tax,omitempty"` + // Total: The final amount paid by the customer, taking into account discounts + // and taxes. + Total *Money `json:"total,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the server. + googleapi.ServerResponse `json:"-"` + // ForceSendFields is a list of field names (e.g. "BuyerAddress") 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. "AllowExtendAfterTime") 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. "BuyerAddress") 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 PrepaidPlan) MarshalJSON() ([]byte, error) { - type NoMethod PrepaidPlan +func (s Order) MarshalJSON() ([]byte, error) { + type NoMethod Order return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// Price: Definition of a price, i.e. currency and units. -type Price struct { - // Currency: 3 letter Currency code, as defined by ISO 4217. See - // java/com/google/common/money/CurrencyCode.java - Currency string `json:"currency,omitempty"` - // PriceMicros: Price in 1/million of the currency base unit, represented as a - // string. - PriceMicros string `json:"priceMicros,omitempty"` - // ForceSendFields is a list of field names (e.g. "Currency") to +// OrderDetails: Detailed information about the order at creation time. +type OrderDetails struct { + // TaxInclusive: Indicates whether the listed price was tax inclusive or not. + TaxInclusive bool `json:"taxInclusive,omitempty"` + // ForceSendFields is a list of field names (e.g. "TaxInclusive") 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. "Currency") to include in API + // NullFields is a list of field names (e.g. "TaxInclusive") 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 Price) MarshalJSON() ([]byte, error) { - type NoMethod Price +func (s OrderDetails) MarshalJSON() ([]byte, error) { + type NoMethod OrderDetails return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// ProcessedEvent: Details of when the order was processed. -type ProcessedEvent struct { - // EventTime: The time when the order was processed. - EventTime string `json:"eventTime,omitempty"` - // ForceSendFields is a list of field names (e.g. "EventTime") to +// OrderHistory: Details about events which modified the order. +type OrderHistory struct { + // CancellationEvent: Details of when the order was canceled. + CancellationEvent *CancellationEvent `json:"cancellationEvent,omitempty"` + // PartialRefundEvents: Details of the partial refund events for this order. + PartialRefundEvents []*PartialRefundEvent `json:"partialRefundEvents,omitempty"` + // ProcessedEvent: Details of when the order was processed. + ProcessedEvent *ProcessedEvent `json:"processedEvent,omitempty"` + // RefundEvent: Details of when the order was fully refunded. + RefundEvent *RefundEvent `json:"refundEvent,omitempty"` + // ForceSendFields is a list of field names (e.g. "CancellationEvent") 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. "EventTime") 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. "CancellationEvent") 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 ProcessedEvent) MarshalJSON() ([]byte, error) { - type NoMethod ProcessedEvent +func (s OrderHistory) MarshalJSON() ([]byte, error) { + type NoMethod OrderHistory return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// ProductLineItem: Contains item-level info for a ProductPurchaseV2. -type ProductLineItem struct { - // ProductId: The purchased product ID (for example, 'monthly001'). - ProductId string `json:"productId,omitempty"` - // ProductOfferDetails: The offer details for this item. - ProductOfferDetails *ProductOfferDetails `json:"productOfferDetails,omitempty"` - // ForceSendFields is a list of field names (e.g. "ProductId") to +// OtherRecurringProduct: Details of a recurring external transaction product +// which doesn't belong to any other more specific category. +type OtherRecurringProduct struct { +} + +// OtherRegionsBasePlanConfig: Pricing information for any new locations Play +// may launch in. +type OtherRegionsBasePlanConfig struct { + // EurPrice: Required. Price in EUR to use for any new locations Play may + // launch in. + EurPrice *Money `json:"eurPrice,omitempty"` + // NewSubscriberAvailability: Whether the base plan is available for new + // subscribers in any new locations Play may launch in. If not specified, this + // will default to false. + NewSubscriberAvailability bool `json:"newSubscriberAvailability,omitempty"` + // UsdPrice: Required. Price in USD to use for any new locations Play may + // launch in. + UsdPrice *Money `json:"usdPrice,omitempty"` + // ForceSendFields is a list of field names (e.g. "EurPrice") 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. "ProductId") to include in API + // NullFields is a list of field names (e.g. "EurPrice") 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 ProductLineItem) MarshalJSON() ([]byte, error) { - type NoMethod ProductLineItem +func (s OtherRegionsBasePlanConfig) MarshalJSON() ([]byte, error) { + type NoMethod OtherRegionsBasePlanConfig return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// ProductOfferDetails: Offer details information related to a purchase line -// item. -type ProductOfferDetails struct { - // ConsumptionState: Output only. The consumption state of the purchase. - // - // Possible values: - // "CONSUMPTION_STATE_UNSPECIFIED" - Consumption state unspecified. This - // value should never be set. - // "CONSUMPTION_STATE_YET_TO_BE_CONSUMED" - Yet to be consumed. - // "CONSUMPTION_STATE_CONSUMED" - Consumed already. - ConsumptionState string `json:"consumptionState,omitempty"` - // OfferId: The offer ID. Only present for offers. - OfferId string `json:"offerId,omitempty"` - // OfferTags: The latest offer tags associated with the offer. It includes tags - // inherited from the purchase option. - OfferTags []string `json:"offerTags,omitempty"` - // OfferToken: The per-transaction offer token used to make this purchase line - // item. - OfferToken string `json:"offerToken,omitempty"` - // PurchaseOptionId: The purchase option ID. - PurchaseOptionId string `json:"purchaseOptionId,omitempty"` - // Quantity: The quantity associated with the purchase of the inapp product. - Quantity int64 `json:"quantity,omitempty"` - // RefundableQuantity: The quantity eligible for refund, i.e. quantity that - // hasn't been refunded. The value reflects quantity-based partial refunds and - // full refunds. - RefundableQuantity int64 `json:"refundableQuantity,omitempty"` - // RentOfferDetails: Offer details about rent offers. This will only be set for - // rental line items. - RentOfferDetails *RentOfferDetails `json:"rentOfferDetails,omitempty"` - // ForceSendFields is a list of field names (e.g. "ConsumptionState") to +// OtherRegionsSubscriptionOfferConfig: Configuration for any new locations +// Play may launch in specified on a subscription offer. +type OtherRegionsSubscriptionOfferConfig struct { + // OtherRegionsNewSubscriberAvailability: Whether the subscription offer in any + // new locations Play may launch in the future. If not specified, this will + // default to false. + OtherRegionsNewSubscriberAvailability bool `json:"otherRegionsNewSubscriberAvailability,omitempty"` + // ForceSendFields is a list of field names (e.g. + // "OtherRegionsNewSubscriberAvailability") 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. + // "OtherRegionsNewSubscriberAvailability") 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 OtherRegionsSubscriptionOfferConfig) MarshalJSON() ([]byte, error) { + type NoMethod OtherRegionsSubscriptionOfferConfig + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// OtherRegionsSubscriptionOfferPhaseConfig: Configuration for any new +// locations Play may launch in for a single offer phase. +type OtherRegionsSubscriptionOfferPhaseConfig struct { + // AbsoluteDiscounts: The absolute amount of money subtracted from the base + // plan price prorated over the phase duration that the user pays for this + // offer phase. For example, if the base plan price for this region is $12 for + // a period of 1 year, then a $1 absolute discount for a phase of a duration of + // 3 months would correspond to a price of $2. The resulting price may not be + // smaller than the minimum price allowed for any new locations Play may launch + // in. + AbsoluteDiscounts *OtherRegionsSubscriptionOfferPhasePrices `json:"absoluteDiscounts,omitempty"` + // Free: Set to specify this offer is free to obtain. + Free *OtherRegionsSubscriptionOfferPhaseFreePriceOverride `json:"free,omitempty"` + // OtherRegionsPrices: The absolute price the user pays for this offer phase. + // The price must not be smaller than the minimum price allowed for any new + // locations Play may launch in. + OtherRegionsPrices *OtherRegionsSubscriptionOfferPhasePrices `json:"otherRegionsPrices,omitempty"` + // RelativeDiscount: The fraction of the base plan price prorated over the + // phase duration that the user pays for this offer phase. For example, if the + // base plan price for this region is $12 for a period of 1 year, then a 50% + // discount for a phase of a duration of 3 months would correspond to a price + // of $1.50. The discount must be specified as a fraction strictly larger than + // 0 and strictly smaller than 1. The resulting price will be rounded to the + // nearest billable unit (e.g. cents for USD). The relative discount is + // considered invalid if the discounted price ends up being smaller than the + // minimum price allowed in any new locations Play may launch in. + RelativeDiscount float64 `json:"relativeDiscount,omitempty"` + // ForceSendFields is a list of field names (e.g. "AbsoluteDiscounts") 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. "ConsumptionState") to include in + // NullFields is a list of field names (e.g. "AbsoluteDiscounts") 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 ProductOfferDetails) MarshalJSON() ([]byte, error) { - type NoMethod ProductOfferDetails +func (s OtherRegionsSubscriptionOfferPhaseConfig) MarshalJSON() ([]byte, error) { + type NoMethod OtherRegionsSubscriptionOfferPhaseConfig return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// ProductPurchase: A ProductPurchase resource indicates the status of a user's -// inapp product purchase. -type ProductPurchase struct { - // AcknowledgementState: The acknowledgement state of the inapp product. - // Possible values are: 0. Yet to be acknowledged 1. Acknowledged - AcknowledgementState int64 `json:"acknowledgementState,omitempty"` - // ConsumptionState: The consumption state of the inapp product. Possible - // values are: 0. Yet to be consumed 1. Consumed - ConsumptionState int64 `json:"consumptionState,omitempty"` - // DeveloperPayload: A developer-specified string that contains supplemental - // information about an order. - DeveloperPayload string `json:"developerPayload,omitempty"` - // Kind: This kind represents an inappPurchase object in the androidpublisher - // service. - Kind string `json:"kind,omitempty"` - // ObfuscatedExternalAccountId: An obfuscated version of the id that is - // uniquely associated with the user's account in your app. Only present if - // specified using - // https://developer.android.com/reference/com/android/billingclient/api/BillingFlowParams.Builder#setobfuscatedaccountid - // when the purchase was made. - ObfuscatedExternalAccountId string `json:"obfuscatedExternalAccountId,omitempty"` - // ObfuscatedExternalProfileId: An obfuscated version of the id that is - // uniquely associated with the user's profile in your app. Only present if - // specified using - // https://developer.android.com/reference/com/android/billingclient/api/BillingFlowParams.Builder#setobfuscatedprofileid - // when the purchase was made. - ObfuscatedExternalProfileId string `json:"obfuscatedExternalProfileId,omitempty"` - // OrderId: The order id associated with the purchase of the inapp product. - OrderId string `json:"orderId,omitempty"` - // ProductId: The inapp product SKU. May not be present. - ProductId string `json:"productId,omitempty"` - // PurchaseState: The purchase state of the order. Possible values are: 0. - // Purchased 1. Canceled 2. Pending - PurchaseState int64 `json:"purchaseState,omitempty"` - // PurchaseTimeMillis: The time the product was purchased, in milliseconds - // since the epoch (Jan 1, 1970). - PurchaseTimeMillis int64 `json:"purchaseTimeMillis,omitempty,string"` - // PurchaseToken: The purchase token generated to identify this purchase. May - // not be present. - PurchaseToken string `json:"purchaseToken,omitempty"` - // PurchaseType: The type of purchase of the inapp product. This field is only - // set if this purchase was not made using the standard in-app billing flow. - // Possible values are: 0. Test (i.e. purchased from a license testing account) - // 1. Promo (i.e. purchased using a promo code). Does not include Play Points - // purchases. 2. Rewarded (i.e. from watching a video ad instead of paying) - PurchaseType *int64 `json:"purchaseType,omitempty"` - // Quantity: The quantity associated with the purchase of the inapp product. If - // not present, the quantity is 1. - Quantity int64 `json:"quantity,omitempty"` - // RefundableQuantity: The quantity eligible for refund, i.e. quantity that - // hasn't been refunded. The value reflects quantity-based partial refunds and - // full refunds. - RefundableQuantity int64 `json:"refundableQuantity,omitempty"` - // RegionCode: ISO 3166-1 alpha-2 billing region code of the user at the time - // the product was granted. - RegionCode string `json:"regionCode,omitempty"` +func (s *OtherRegionsSubscriptionOfferPhaseConfig) UnmarshalJSON(data []byte) error { + type NoMethod OtherRegionsSubscriptionOfferPhaseConfig + var s1 struct { + RelativeDiscount gensupport.JSONFloat64 `json:"relativeDiscount"` + *NoMethod + } + s1.NoMethod = (*NoMethod)(s) + if err := json.Unmarshal(data, &s1); err != nil { + return err + } + s.RelativeDiscount = float64(s1.RelativeDiscount) + return nil +} - // ServerResponse contains the HTTP response code and headers from the server. - googleapi.ServerResponse `json:"-"` - // ForceSendFields is a list of field names (e.g. "AcknowledgementState") to +// OtherRegionsSubscriptionOfferPhaseFreePriceOverride: Represents the free +// price override configuration for any new locations Play may launch for a +// single offer phase. +type OtherRegionsSubscriptionOfferPhaseFreePriceOverride struct { +} + +// OtherRegionsSubscriptionOfferPhasePrices: Pricing information for any new +// locations Play may launch in. +type OtherRegionsSubscriptionOfferPhasePrices struct { + // EurPrice: Required. Price in EUR to use for any new locations Play may + // launch in. + EurPrice *Money `json:"eurPrice,omitempty"` + // UsdPrice: Required. Price in USD to use for any new locations Play may + // launch in. + UsdPrice *Money `json:"usdPrice,omitempty"` + // ForceSendFields is a list of field names (e.g. "EurPrice") 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. "AcknowledgementState") 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. "EurPrice") 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 ProductPurchase) MarshalJSON() ([]byte, error) { - type NoMethod ProductPurchase +func (s OtherRegionsSubscriptionOfferPhasePrices) MarshalJSON() ([]byte, error) { + type NoMethod OtherRegionsSubscriptionOfferPhasePrices return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// ProductPurchaseV2: A ProductPurchaseV2 resource indicates the status of a -// user's inapp product purchase. -type ProductPurchaseV2 struct { - // AcknowledgementState: Output only. The acknowledgement state of the - // purchase. - // - // Possible values: - // "ACKNOWLEDGEMENT_STATE_UNSPECIFIED" - Unspecified acknowledgement state. - // "ACKNOWLEDGEMENT_STATE_PENDING" - The purchase is not acknowledged yet. - // "ACKNOWLEDGEMENT_STATE_ACKNOWLEDGED" - The purchase is acknowledged. - AcknowledgementState string `json:"acknowledgementState,omitempty"` - // Kind: This kind represents a ProductPurchaseV2 object in the - // androidpublisher service. - Kind string `json:"kind,omitempty"` - // ObfuscatedExternalAccountId: An obfuscated version of the id that is - // uniquely associated with the user's account in your app. Only present if - // specified using - // https://developer.android.com/reference/com/android/billingclient/api/BillingFlowParams.Builder#setobfuscatedaccountid - // when the purchase was made. - ObfuscatedExternalAccountId string `json:"obfuscatedExternalAccountId,omitempty"` - // ObfuscatedExternalProfileId: An obfuscated version of the id that is - // uniquely associated with the user's profile in your app. Only present if - // specified using - // https://developer.android.com/reference/com/android/billingclient/api/BillingFlowParams.Builder#setobfuscatedprofileid - // when the purchase was made. - ObfuscatedExternalProfileId string `json:"obfuscatedExternalProfileId,omitempty"` - // OrderId: The order id associated with the purchase of the inapp product. May - // not be set if there is no order associated with the purchase. - OrderId string `json:"orderId,omitempty"` - // ProductLineItem: Contains item-level info for a ProductPurchaseV2. - ProductLineItem []*ProductLineItem `json:"productLineItem,omitempty"` - // PurchaseCompletionTime: The time when the purchase was successful, i.e., - // when the PurchaseState has changed to PURCHASED. This field will not be - // present until the payment is complete. For example, if the user initiated a - // pending transaction - // (https://developer.android.com/google/play/billing/integrate#pending), this - // field will not be populated until the user successfully completes the steps - // required to complete the transaction. - PurchaseCompletionTime string `json:"purchaseCompletionTime,omitempty"` - // PurchaseStateContext: Information about the purchase state of the purchase. - PurchaseStateContext *PurchaseStateContext `json:"purchaseStateContext,omitempty"` - // RegionCode: ISO 3166-1 alpha-2 billing region code of the user at the time - // the product was granted. - RegionCode string `json:"regionCode,omitempty"` - // TestPurchaseContext: Information related to test purchases. This will only - // be set for test purchases. - TestPurchaseContext *TestPurchaseContext `json:"testPurchaseContext,omitempty"` - - // ServerResponse contains the HTTP response code and headers from the server. - googleapi.ServerResponse `json:"-"` - // ForceSendFields is a list of field names (e.g. "AcknowledgementState") to +// PageInfo: Information about the current page. List operations that supports +// paging return only one "page" of results. This protocol buffer message +// describes the page that has been returned. +type PageInfo struct { + // ResultPerPage: Maximum number of results returned in one page. ! The number + // of results included in the API response. + ResultPerPage int64 `json:"resultPerPage,omitempty"` + // StartIndex: Index of the first result returned in the current page. + StartIndex int64 `json:"startIndex,omitempty"` + // TotalResults: Total number of results available on the backend ! The total + // number of results in the result set. + TotalResults int64 `json:"totalResults,omitempty"` + // ForceSendFields is a list of field names (e.g. "ResultPerPage") 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. "AcknowledgementState") 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. "ResultPerPage") 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 ProductPurchaseV2) MarshalJSON() ([]byte, error) { - type NoMethod ProductPurchaseV2 +func (s PageInfo) MarshalJSON() ([]byte, error) { + type NoMethod PageInfo return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// ProductPurchasesAcknowledgeRequest: Request for the -// product.purchases.acknowledge API. -type ProductPurchasesAcknowledgeRequest struct { - // DeveloperPayload: Payload to attach to the purchase. - DeveloperPayload string `json:"developerPayload,omitempty"` - // ForceSendFields is a list of field names (e.g. "DeveloperPayload") to +// PaidAppDetails: Details of a paid app purchase. +type PaidAppDetails struct { +} + +// PartialRefund: A partial refund of a transaction. +type PartialRefund struct { + // RefundId: Required. A unique id distinguishing this partial refund. If the + // refund is successful, subsequent refunds with the same id will fail. Must be + // unique across refunds for one individual transaction. + RefundId string `json:"refundId,omitempty"` + // RefundPreTaxAmount: Required. The pre-tax amount of the partial refund. + // Should be less than the remaining pre-tax amount of the transaction. + RefundPreTaxAmount *Price `json:"refundPreTaxAmount,omitempty"` + // ForceSendFields is a list of field names (e.g. "RefundId") 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. "DeveloperPayload") 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. "RefundId") 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 ProductPurchasesAcknowledgeRequest) MarshalJSON() ([]byte, error) { - type NoMethod ProductPurchasesAcknowledgeRequest +func (s PartialRefund) MarshalJSON() ([]byte, error) { + type NoMethod PartialRefund return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// PurchaseStateContext: Context about the purchase state. -type PurchaseStateContext struct { - // PurchaseState: Output only. The purchase state of the purchase. +// PartialRefundEvent: Details of the partial refund events for this order. +type PartialRefundEvent struct { + // CreateTime: The time when the partial refund was created. + CreateTime string `json:"createTime,omitempty"` + // ProcessTime: The time when the partial refund was processed. + ProcessTime string `json:"processTime,omitempty"` + // RefundDetails: Details for the partial refund. + RefundDetails *RefundDetails `json:"refundDetails,omitempty"` + // State: The state of the partial refund. // // Possible values: - // "PURCHASE_STATE_UNSPECIFIED" - Purchase state unspecified. This value - // should never be set. - // "PURCHASED" - Purchased successfully. - // "CANCELLED" - Purchase canceled. - // "PENDING" - The purchase is in a pending state and has not yet been - // completed. For more information on handling pending purchases, see - // https://developer.android.com/google/play/billing/integrate#pending. - PurchaseState string `json:"purchaseState,omitempty"` - // ForceSendFields is a list of field names (e.g. "PurchaseState") to + // "STATE_UNSPECIFIED" - State unspecified. This value is not used. + // "PENDING" - The partial refund has been created, but not yet processed. + // "PROCESSED_SUCCESSFULLY" - The partial refund was processed successfully. + State string `json:"state,omitempty"` + // 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. "PurchaseState") to include in API + // 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 PurchaseStateContext) MarshalJSON() ([]byte, error) { - type NoMethod PurchaseStateContext +func (s PartialRefundEvent) MarshalJSON() ([]byte, error) { + type NoMethod PartialRefundEvent return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// RecurringExternalTransaction: Represents a transaction that is part of a -// recurring series of payments. This can be a subscription or a one-time -// product with multiple payments (such as preorder). -type RecurringExternalTransaction struct { - // ExternalSubscription: Details of an external subscription. - ExternalSubscription *ExternalSubscription `json:"externalSubscription,omitempty"` - // ExternalTransactionToken: Input only. Provided during the call to Create. - // Retrieved from the client when the alternative billing flow is launched. - // Required only for the initial purchase. - ExternalTransactionToken string `json:"externalTransactionToken,omitempty"` - // InitialExternalTransactionId: The external transaction id of the first - // transaction of this recurring series of transactions. For example, for a - // subscription this would be the transaction id of the first payment. Required - // when creating recurring external transactions. - InitialExternalTransactionId string `json:"initialExternalTransactionId,omitempty"` - // MigratedTransactionProgram: Input only. Provided during the call to Create. - // Must only be used when migrating a subscription from manual monthly - // reporting to automated reporting. - // - // Possible values: - // "EXTERNAL_TRANSACTION_PROGRAM_UNSPECIFIED" - Unspecified transaction - // program. Not used. - // "USER_CHOICE_BILLING" - User choice billing, where a user may choose - // between Google Play Billing developer-managed billing. - // "ALTERNATIVE_BILLING_ONLY" - Alternative billing only, where users may - // only use developer-manager billing. - MigratedTransactionProgram string `json:"migratedTransactionProgram,omitempty"` - // OtherRecurringProduct: Details of a recurring external transaction product - // which doesn't belong to any other specific category. - OtherRecurringProduct *OtherRecurringProduct `json:"otherRecurringProduct,omitempty"` - // ForceSendFields is a list of field names (e.g. "ExternalSubscription") to +// PausedStateContext: Information specific to a subscription in paused state. +type PausedStateContext struct { + // AutoResumeTime: Time at which the subscription will be automatically + // resumed. + AutoResumeTime string `json:"autoResumeTime,omitempty"` + // ForceSendFields is a list of field names (e.g. "AutoResumeTime") 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. "ExternalSubscription") 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. "AutoResumeTime") 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 RecurringExternalTransaction) MarshalJSON() ([]byte, error) { - type NoMethod RecurringExternalTransaction +func (s PausedStateContext) MarshalJSON() ([]byte, error) { + type NoMethod PausedStateContext return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// RefundDetails: Details for a partial or full refund. -type RefundDetails struct { - // Tax: The amount of tax refunded. - Tax *Money `json:"tax,omitempty"` - // Total: The total amount refunded, including tax. - Total *Money `json:"total,omitempty"` - // ForceSendFields is a list of field names (e.g. "Tax") 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. "Tax") 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 RefundDetails) MarshalJSON() ([]byte, error) { - type NoMethod RefundDetails - return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +// PendingCancellation: This is an indicator of whether there is a pending +// cancellation on the virtual installment plan. The cancellation will happen +// only after the user finished all committed payments. +type PendingCancellation struct { } -// RefundEvent: Details of when the order was fully refunded. -type RefundEvent struct { - // EventTime: The time when the order was fully refunded. - EventTime string `json:"eventTime,omitempty"` - // RefundDetails: Details for the full refund. - RefundDetails *RefundDetails `json:"refundDetails,omitempty"` - // RefundReason: The reason the order was refunded. - // - // Possible values: - // "REFUND_REASON_UNSPECIFIED" - Refund reason unspecified. This value is not - // used. - // "OTHER" - The order was refunded for a reason other than the listed - // reasons here. - // "CHARGEBACK" - The order was charged back. - RefundReason string `json:"refundReason,omitempty"` - // ForceSendFields is a list of field names (e.g. "EventTime") to +// PointsDetails: Details relating to any Play Points applied to an order. +type PointsDetails struct { + // PointsCouponValue: The monetary value of a Play Points coupon. This is the + // discount the coupon provides, which may not be the total amount. Only set + // when Play Points coupons have been used. E.g. for a 100 points for $2 + // coupon, this is $2. + PointsCouponValue *Money `json:"pointsCouponValue,omitempty"` + // PointsDiscountRateMicros: The percentage rate which the Play Points + // promotion reduces the cost by. E.g. for a 100 points for $2 coupon, this is + // 500,000. Since $2 has an estimate of 200 points, but the actual Points + // required, 100, is 50% of this, and 50% in micros is 500,000. Between 0 and + // 1,000,000. + PointsDiscountRateMicros int64 `json:"pointsDiscountRateMicros,omitempty,string"` + // PointsOfferId: ID unique to the play points offer in use for this order. + PointsOfferId string `json:"pointsOfferId,omitempty"` + // PointsSpent: The number of Play Points applied in this order. E.g. for a 100 + // points for $2 coupon, this is 100. For coupon stacked with base offer, this + // is the total points spent across both. + PointsSpent int64 `json:"pointsSpent,omitempty,string"` + // ForceSendFields is a list of field names (e.g. "PointsCouponValue") 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. "EventTime") 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. "PointsCouponValue") 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 RefundEvent) MarshalJSON() ([]byte, error) { - type NoMethod RefundEvent +func (s PointsDetails) MarshalJSON() ([]byte, error) { + type NoMethod PointsDetails return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// RefundExternalTransactionRequest: A request to refund an existing external -// transaction. -type RefundExternalTransactionRequest struct { - // FullRefund: A full-amount refund. - FullRefund *FullRefund `json:"fullRefund,omitempty"` - // PartialRefund: A partial refund. - PartialRefund *PartialRefund `json:"partialRefund,omitempty"` - // RefundTime: Required. The time that the transaction was refunded. - RefundTime string `json:"refundTime,omitempty"` - // ForceSendFields is a list of field names (e.g. "FullRefund") to +// PrepaidBasePlanType: Represents a base plan that does not automatically +// renew at the end of the base plan, and must be manually renewed by the user. +type PrepaidBasePlanType struct { + // BillingPeriodDuration: Required. Immutable. Subscription period, specified + // in ISO 8601 format. For a list of acceptable billing periods, refer to the + // help center. The duration is immutable after the base plan is created. + BillingPeriodDuration string `json:"billingPeriodDuration,omitempty"` + // TimeExtension: Whether users should be able to extend this prepaid base plan + // in Google Play surfaces. Defaults to TIME_EXTENSION_ACTIVE if not specified. + // + // Possible values: + // "TIME_EXTENSION_UNSPECIFIED" - Unspecified state. + // "TIME_EXTENSION_ACTIVE" - Time extension is active. Users are allowed to + // top-up or extend their prepaid plan. + // "TIME_EXTENSION_INACTIVE" - Time extension is inactive. Users cannot + // top-up or extend their prepaid plan. + TimeExtension string `json:"timeExtension,omitempty"` + // ForceSendFields is a list of field names (e.g. "BillingPeriodDuration") 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. "FullRefund") 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. "BillingPeriodDuration") 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 RefundExternalTransactionRequest) MarshalJSON() ([]byte, error) { - type NoMethod RefundExternalTransactionRequest +func (s PrepaidBasePlanType) MarshalJSON() ([]byte, error) { + type NoMethod PrepaidBasePlanType return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// RegionalBasePlanConfig: Configuration for a base plan specific to a region. -type RegionalBasePlanConfig struct { - // NewSubscriberAvailability: Whether the base plan in the specified region is - // available for new subscribers. Existing subscribers will not have their - // subscription canceled if this value is set to false. If not specified, this - // will default to false. - NewSubscriberAvailability bool `json:"newSubscriberAvailability,omitempty"` - // Price: The price of the base plan in the specified region. Must be set if - // the base plan is available to new subscribers. Must be set in the currency - // that is linked to the specified region. - Price *Money `json:"price,omitempty"` - // RegionCode: Required. Region code this configuration applies to, as defined - // by ISO 3166-2, e.g. "US". - RegionCode string `json:"regionCode,omitempty"` - // ForceSendFields is a list of field names (e.g. "NewSubscriberAvailability") - // to unconditionally include in API requests. By default, fields with empty or +// PrepaidPlan: Information related to a prepaid plan. +type PrepaidPlan struct { + // AllowExtendAfterTime: If present, this is the time after which top up + // purchases are allowed for the prepaid plan. Will not be present for expired + // prepaid plans. + AllowExtendAfterTime string `json:"allowExtendAfterTime,omitempty"` + // ForceSendFields is a list of field names (e.g. "AllowExtendAfterTime") 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. "NewSubscriberAvailability") 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. "AllowExtendAfterTime") 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 RegionalBasePlanConfig) MarshalJSON() ([]byte, error) { - type NoMethod RegionalBasePlanConfig +func (s PrepaidPlan) MarshalJSON() ([]byte, error) { + type NoMethod PrepaidPlan return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// RegionalPriceMigrationConfig: Configuration for migration of a legacy price -// cohort. -type RegionalPriceMigrationConfig struct { - // OldestAllowedPriceVersionTime: Required. Subscribers in all legacy price - // cohorts before this time will be migrated to the current price. Subscribers - // in any newer price cohorts are unaffected. Affected subscribers will receive - // one or more notifications from Google Play about the price change. Price - // decreases occur at the subscriber's next billing date. Price increases occur - // at the subscriber's next billing date following a notification period that - // varies by region and price increase type. - OldestAllowedPriceVersionTime string `json:"oldestAllowedPriceVersionTime,omitempty"` - // PriceIncreaseType: Optional. The requested type of price increase - // - // Possible values: - // "PRICE_INCREASE_TYPE_UNSPECIFIED" - Unspecified state. - // "PRICE_INCREASE_TYPE_OPT_IN" - Subscribers must accept the price increase - // or their subscription is canceled. - // "PRICE_INCREASE_TYPE_OPT_OUT" - Subscribers are notified but do not have - // to accept the price increase. Opt-out price increases not meeting regional, - // frequency, and amount limits will proceed as opt-in price increase. The - // first opt-out price increase for each app must be initiated in the Google - // Play Console. - PriceIncreaseType string `json:"priceIncreaseType,omitempty"` - // RegionCode: Required. Region code this configuration applies to, as defined - // by ISO 3166-2, e.g. "US". - RegionCode string `json:"regionCode,omitempty"` - // ForceSendFields is a list of field names (e.g. - // "OldestAllowedPriceVersionTime") 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. +// Price: Definition of a price, i.e. currency and units. +type Price struct { + // Currency: 3 letter Currency code, as defined by ISO 4217. See + // java/com/google/common/money/CurrencyCode.java + Currency string `json:"currency,omitempty"` + // PriceMicros: Price in 1/million of the currency base unit, represented as a + // string. + PriceMicros string `json:"priceMicros,omitempty"` + // ForceSendFields is a list of field names (e.g. "Currency") 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. "OldestAllowedPriceVersionTime") - // 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. "Currency") 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 RegionalPriceMigrationConfig) MarshalJSON() ([]byte, error) { - type NoMethod RegionalPriceMigrationConfig +func (s Price) MarshalJSON() ([]byte, error) { + type NoMethod Price return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// RegionalSubscriptionOfferConfig: Configuration for a subscription offer in a -// single region. -type RegionalSubscriptionOfferConfig struct { - // NewSubscriberAvailability: Whether the subscription offer in the specified - // region is available for new subscribers. Existing subscribers will not have - // their subscription cancelled if this value is set to false. If not - // specified, this will default to false. - NewSubscriberAvailability bool `json:"newSubscriberAvailability,omitempty"` - // RegionCode: Required. Immutable. Region code this configuration applies to, - // as defined by ISO 3166-2, e.g. "US". - RegionCode string `json:"regionCode,omitempty"` - // ForceSendFields is a list of field names (e.g. "NewSubscriberAvailability") - // to unconditionally include in API requests. By default, fields with empty or +// ProcessedEvent: Details of when the order was processed. +type ProcessedEvent struct { + // EventTime: The time when the order was processed. + EventTime string `json:"eventTime,omitempty"` + // ForceSendFields is a list of field names (e.g. "EventTime") 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. "NewSubscriberAvailability") 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. "EventTime") 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 RegionalSubscriptionOfferConfig) MarshalJSON() ([]byte, error) { - type NoMethod RegionalSubscriptionOfferConfig +func (s ProcessedEvent) MarshalJSON() ([]byte, error) { + type NoMethod ProcessedEvent return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// RegionalSubscriptionOfferPhaseConfig: Configuration for a single phase of a -// subscription offer in a single region. -type RegionalSubscriptionOfferPhaseConfig struct { - // AbsoluteDiscount: The absolute amount of money subtracted from the base plan - // price prorated over the phase duration that the user pays for this offer - // phase. For example, if the base plan price for this region is $12 for a - // period of 1 year, then a $1 absolute discount for a phase of a duration of 3 - // months would correspond to a price of $2. The resulting price may not be - // smaller than the minimum price allowed for this region. - AbsoluteDiscount *Money `json:"absoluteDiscount,omitempty"` - // Free: Set to specify this offer is free to obtain. - Free *RegionalSubscriptionOfferPhaseFreePriceOverride `json:"free,omitempty"` - // Price: The absolute price the user pays for this offer phase. The price must - // not be smaller than the minimum price allowed for this region. - Price *Money `json:"price,omitempty"` - // RegionCode: Required. Immutable. The region to which this config applies. - RegionCode string `json:"regionCode,omitempty"` - // RelativeDiscount: The fraction of the base plan price prorated over the - // phase duration that the user pays for this offer phase. For example, if the - // base plan price for this region is $12 for a period of 1 year, then a 50% - // discount for a phase of a duration of 3 months would correspond to a price - // of $1.50. The discount must be specified as a fraction strictly larger than - // 0 and strictly smaller than 1. The resulting price will be rounded to the - // nearest billable unit (e.g. cents for USD). The relative discount is - // considered invalid if the discounted price ends up being smaller than the - // minimum price allowed in this region. - RelativeDiscount float64 `json:"relativeDiscount,omitempty"` - // ForceSendFields is a list of field names (e.g. "AbsoluteDiscount") to +// ProductLineItem: Contains item-level info for a ProductPurchaseV2. +type ProductLineItem struct { + // ProductId: The purchased product ID (for example, 'monthly001'). + ProductId string `json:"productId,omitempty"` + // ProductOfferDetails: The offer details for this item. + ProductOfferDetails *ProductOfferDetails `json:"productOfferDetails,omitempty"` + // ForceSendFields is a list of field names (e.g. "ProductId") 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. "AbsoluteDiscount") 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. "ProductId") 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 RegionalSubscriptionOfferPhaseConfig) MarshalJSON() ([]byte, error) { - type NoMethod RegionalSubscriptionOfferPhaseConfig +func (s ProductLineItem) MarshalJSON() ([]byte, error) { + type NoMethod ProductLineItem return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -func (s *RegionalSubscriptionOfferPhaseConfig) UnmarshalJSON(data []byte) error { - type NoMethod RegionalSubscriptionOfferPhaseConfig - var s1 struct { - RelativeDiscount gensupport.JSONFloat64 `json:"relativeDiscount"` - *NoMethod - } - s1.NoMethod = (*NoMethod)(s) - if err := json.Unmarshal(data, &s1); err != nil { - return err - } - s.RelativeDiscount = float64(s1.RelativeDiscount) - return nil +// ProductOfferDetails: Offer details information related to a purchase line +// item. +type ProductOfferDetails struct { + // ConsumptionState: Output only. The consumption state of the purchase. + // + // Possible values: + // "CONSUMPTION_STATE_UNSPECIFIED" - Consumption state unspecified. This + // value should never be set. + // "CONSUMPTION_STATE_YET_TO_BE_CONSUMED" - Yet to be consumed. + // "CONSUMPTION_STATE_CONSUMED" - Consumed already. + ConsumptionState string `json:"consumptionState,omitempty"` + // OfferId: The offer ID. Only present for offers. + OfferId string `json:"offerId,omitempty"` + // OfferTags: The latest offer tags associated with the offer. It includes tags + // inherited from the purchase option. + OfferTags []string `json:"offerTags,omitempty"` + // OfferToken: The per-transaction offer token used to make this purchase line + // item. + OfferToken string `json:"offerToken,omitempty"` + // PurchaseOptionId: The purchase option ID. + PurchaseOptionId string `json:"purchaseOptionId,omitempty"` + // Quantity: The quantity associated with the purchase of the inapp product. + Quantity int64 `json:"quantity,omitempty"` + // RefundableQuantity: The quantity eligible for refund, i.e. quantity that + // hasn't been refunded. The value reflects quantity-based partial refunds and + // full refunds. + RefundableQuantity int64 `json:"refundableQuantity,omitempty"` + // RentOfferDetails: Offer details about rent offers. This will only be set for + // rental line items. + RentOfferDetails *RentOfferDetails `json:"rentOfferDetails,omitempty"` + // ForceSendFields is a list of field names (e.g. "ConsumptionState") 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. "ConsumptionState") 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:"-"` } -// RegionalSubscriptionOfferPhaseFreePriceOverride: Represents the free price -// override configuration for a single phase of a subscription offer -type RegionalSubscriptionOfferPhaseFreePriceOverride struct { +func (s ProductOfferDetails) MarshalJSON() ([]byte, error) { + type NoMethod ProductOfferDetails + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// RegionalTaxRateInfo: Specified details about taxation in a given -// geographical region. -type RegionalTaxRateInfo struct { - // EligibleForStreamingServiceTaxRate: You must tell us if your app contains - // streaming products to correctly charge US state and local sales tax. Field - // only supported in the United States. - EligibleForStreamingServiceTaxRate bool `json:"eligibleForStreamingServiceTaxRate,omitempty"` - // StreamingTaxType: To collect communications or amusement taxes in the United - // States, choose the appropriate tax category. Learn more - // (https://support.google.com/googleplay/android-developer/answer/10463498#streaming_tax). - // - // Possible values: - // "STREAMING_TAX_TYPE_UNSPECIFIED" - No telecommunications tax collected. - // "STREAMING_TAX_TYPE_TELCO_VIDEO_RENTAL" - US-specific telecommunications - // tax tier for video streaming, on demand, rentals / subscriptions / - // pay-per-view. - // "STREAMING_TAX_TYPE_TELCO_VIDEO_SALES" - US-specific telecommunications - // tax tier for video streaming of pre-recorded content like movies, tv shows. - // "STREAMING_TAX_TYPE_TELCO_VIDEO_MULTI_CHANNEL" - US-specific - // telecommunications tax tier for video streaming of multi-channel - // programming. - // "STREAMING_TAX_TYPE_TELCO_AUDIO_RENTAL" - US-specific telecommunications - // tax tier for audio streaming, rental / subscription. - // "STREAMING_TAX_TYPE_TELCO_AUDIO_SALES" - US-specific telecommunications - // tax tier for audio streaming, sale / permanent download. - // "STREAMING_TAX_TYPE_TELCO_AUDIO_MULTI_CHANNEL" - US-specific - // telecommunications tax tier for multi channel audio streaming like radio. - StreamingTaxType string `json:"streamingTaxType,omitempty"` - // TaxTier: Tax tier to specify reduced tax rate. Developers who sell digital - // news, magazines, newspapers, books, or audiobooks in various regions may be - // eligible for reduced tax rates. Learn more - // (https://support.google.com/googleplay/android-developer/answer/10463498). - // - // Possible values: - // "TAX_TIER_UNSPECIFIED" - // "TAX_TIER_BOOKS_1" - // "TAX_TIER_NEWS_1" - // "TAX_TIER_NEWS_2" - // "TAX_TIER_MUSIC_OR_AUDIO_1" - // "TAX_TIER_LIVE_OR_BROADCAST_1" - TaxTier string `json:"taxTier,omitempty"` - // ForceSendFields is a list of field names (e.g. - // "EligibleForStreamingServiceTaxRate") to unconditionally include in API - // requests. By default, fields with empty or default values are omitted from - // API requests. See +// ProductPurchase: A ProductPurchase resource indicates the status of a user's +// inapp product purchase. +type ProductPurchase struct { + // AcknowledgementState: The acknowledgement state of the inapp product. + // Possible values are: 0. Yet to be acknowledged 1. Acknowledged + AcknowledgementState int64 `json:"acknowledgementState,omitempty"` + // ConsumptionState: The consumption state of the inapp product. Possible + // values are: 0. Yet to be consumed 1. Consumed + ConsumptionState int64 `json:"consumptionState,omitempty"` + // DeveloperPayload: A developer-specified string that contains supplemental + // information about an order. + DeveloperPayload string `json:"developerPayload,omitempty"` + // Kind: This kind represents an inappPurchase object in the androidpublisher + // service. + Kind string `json:"kind,omitempty"` + // ObfuscatedExternalAccountId: An obfuscated version of the id that is + // uniquely associated with the user's account in your app. Only present if + // specified using + // https://developer.android.com/reference/com/android/billingclient/api/BillingFlowParams.Builder#setobfuscatedaccountid + // when the purchase was made. + ObfuscatedExternalAccountId string `json:"obfuscatedExternalAccountId,omitempty"` + // ObfuscatedExternalProfileId: An obfuscated version of the id that is + // uniquely associated with the user's profile in your app. Only present if + // specified using + // https://developer.android.com/reference/com/android/billingclient/api/BillingFlowParams.Builder#setobfuscatedprofileid + // when the purchase was made. + ObfuscatedExternalProfileId string `json:"obfuscatedExternalProfileId,omitempty"` + // OrderId: The order id associated with the purchase of the inapp product. + OrderId string `json:"orderId,omitempty"` + // ProductId: The inapp product SKU. May not be present. + ProductId string `json:"productId,omitempty"` + // PurchaseState: The purchase state of the order. Possible values are: 0. + // Purchased 1. Canceled 2. Pending + PurchaseState int64 `json:"purchaseState,omitempty"` + // PurchaseTimeMillis: The time the product was purchased, in milliseconds + // since the epoch (Jan 1, 1970). + PurchaseTimeMillis int64 `json:"purchaseTimeMillis,omitempty,string"` + // PurchaseToken: The purchase token generated to identify this purchase. May + // not be present. + PurchaseToken string `json:"purchaseToken,omitempty"` + // PurchaseType: The type of purchase of the inapp product. This field is only + // set if this purchase was not made using the standard in-app billing flow. + // Possible values are: 0. Test (i.e. purchased from a license testing account) + // 1. Promo (i.e. purchased using a promo code). Does not include Play Points + // purchases. 2. Rewarded (i.e. from watching a video ad instead of paying) + PurchaseType *int64 `json:"purchaseType,omitempty"` + // Quantity: The quantity associated with the purchase of the inapp product. If + // not present, the quantity is 1. + Quantity int64 `json:"quantity,omitempty"` + // RefundableQuantity: The quantity eligible for refund, i.e. quantity that + // hasn't been refunded. The value reflects quantity-based partial refunds and + // full refunds. + RefundableQuantity int64 `json:"refundableQuantity,omitempty"` + // RegionCode: ISO 3166-1 alpha-2 billing region code of the user at the time + // the product was granted. + RegionCode string `json:"regionCode,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the server. + googleapi.ServerResponse `json:"-"` + // ForceSendFields is a list of field names (e.g. "AcknowledgementState") 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. - // "EligibleForStreamingServiceTaxRate") 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 is a list of field names (e.g. "AcknowledgementState") 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 RegionalTaxRateInfo) MarshalJSON() ([]byte, error) { - type NoMethod RegionalTaxRateInfo +func (s ProductPurchase) MarshalJSON() ([]byte, error) { + type NoMethod ProductPurchase return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// Regions: Region targeting data for app recovery action targeting. -type Regions struct { - // RegionCode: Regions targeted by the recovery action. Region codes are ISO - // 3166 Alpha-2 country codes. For example, US stands for United States of - // America. See https://www.iso.org/iso-3166-country-codes.html for the - // complete list of country codes. - RegionCode []string `json:"regionCode,omitempty"` - // ForceSendFields is a list of field names (e.g. "RegionCode") to +// ProductPurchaseV2: A ProductPurchaseV2 resource indicates the status of a +// user's inapp product purchase. +type ProductPurchaseV2 struct { + // AcknowledgementState: Output only. The acknowledgement state of the + // purchase. + // + // Possible values: + // "ACKNOWLEDGEMENT_STATE_UNSPECIFIED" - Unspecified acknowledgement state. + // "ACKNOWLEDGEMENT_STATE_PENDING" - The purchase is not acknowledged yet. + // "ACKNOWLEDGEMENT_STATE_ACKNOWLEDGED" - The purchase is acknowledged. + AcknowledgementState string `json:"acknowledgementState,omitempty"` + // Kind: This kind represents a ProductPurchaseV2 object in the + // androidpublisher service. + Kind string `json:"kind,omitempty"` + // ObfuscatedExternalAccountId: An obfuscated version of the id that is + // uniquely associated with the user's account in your app. Only present if + // specified using + // https://developer.android.com/reference/com/android/billingclient/api/BillingFlowParams.Builder#setobfuscatedaccountid + // when the purchase was made. + ObfuscatedExternalAccountId string `json:"obfuscatedExternalAccountId,omitempty"` + // ObfuscatedExternalProfileId: An obfuscated version of the id that is + // uniquely associated with the user's profile in your app. Only present if + // specified using + // https://developer.android.com/reference/com/android/billingclient/api/BillingFlowParams.Builder#setobfuscatedprofileid + // when the purchase was made. + ObfuscatedExternalProfileId string `json:"obfuscatedExternalProfileId,omitempty"` + // OrderId: The order id associated with the purchase of the inapp product. May + // not be set if there is no order associated with the purchase. + OrderId string `json:"orderId,omitempty"` + // ProductLineItem: Contains item-level info for a ProductPurchaseV2. + ProductLineItem []*ProductLineItem `json:"productLineItem,omitempty"` + // PurchaseCompletionTime: The time when the purchase was successful, i.e., + // when the PurchaseState has changed to PURCHASED. This field will not be + // present until the payment is complete. For example, if the user initiated a + // pending transaction + // (https://developer.android.com/google/play/billing/integrate#pending), this + // field will not be populated until the user successfully completes the steps + // required to complete the transaction. + PurchaseCompletionTime string `json:"purchaseCompletionTime,omitempty"` + // PurchaseStateContext: Information about the purchase state of the purchase. + PurchaseStateContext *PurchaseStateContext `json:"purchaseStateContext,omitempty"` + // RegionCode: ISO 3166-1 alpha-2 billing region code of the user at the time + // the product was granted. + RegionCode string `json:"regionCode,omitempty"` + // TestPurchaseContext: Information related to test purchases. This will only + // be set for test purchases. + TestPurchaseContext *TestPurchaseContext `json:"testPurchaseContext,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the server. + googleapi.ServerResponse `json:"-"` + // ForceSendFields is a list of field names (e.g. "AcknowledgementState") 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. "RegionCode") 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. "AcknowledgementState") 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 Regions) MarshalJSON() ([]byte, error) { - type NoMethod Regions +func (s ProductPurchaseV2) MarshalJSON() ([]byte, error) { + type NoMethod ProductPurchaseV2 return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// RegionsVersion: The version of the available regions being used for the -// specified resource. -type RegionsVersion struct { - // Version: Required. A string representing the version of available regions - // being used for the specified resource. Regional prices and latest supported - // version for the resource have to be specified according to the information - // published in this article - // (https://support.google.com/googleplay/android-developer/answer/10532353). - // Each time the supported locations substantially change, the version will be - // incremented. Using this field will ensure that creating and updating the - // resource with an older region's version and set of regional prices and - // currencies will succeed even though a new version is available. - Version string `json:"version,omitempty"` - // ForceSendFields is a list of field names (e.g. "Version") to unconditionally - // include in API requests. By default, fields with empty or default values are - // omitted from API requests. See +// ProductPurchasesAcknowledgeRequest: Request for the +// product.purchases.acknowledge API. +type ProductPurchasesAcknowledgeRequest struct { + // DeveloperPayload: Payload to attach to the purchase. + DeveloperPayload string `json:"developerPayload,omitempty"` + // ForceSendFields is a list of field names (e.g. "DeveloperPayload") 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. "Version") 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. "DeveloperPayload") 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 RegionsVersion) MarshalJSON() ([]byte, error) { - type NoMethod RegionsVersion +func (s ProductPurchasesAcknowledgeRequest) MarshalJSON() ([]byte, error) { + type NoMethod ProductPurchasesAcknowledgeRequest return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// RemoteInAppUpdate: Object representation for Remote in-app update action -// type. -type RemoteInAppUpdate struct { - // IsRemoteInAppUpdateRequested: Required. Set to true if Remote In-App Update - // action type is needed. - IsRemoteInAppUpdateRequested bool `json:"isRemoteInAppUpdateRequested,omitempty"` - // ForceSendFields is a list of field names (e.g. - // "IsRemoteInAppUpdateRequested") 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. +// PurchaseOptionTaxAndComplianceSettings: Details about taxation, Google Play +// policy and legal compliance for one-time product purchase options. +type PurchaseOptionTaxAndComplianceSettings struct { + // WithdrawalRightType: Optional. Digital content or service classification for + // products distributed to users in eligible regions. If unset, it defaults to + // `WITHDRAWAL_RIGHT_DIGITAL_CONTENT`. Refer to the Help Center article + // (https://support.google.com/googleplay/android-developer/answer/10463498) + // for more information. + // + // Possible values: + // "WITHDRAWAL_RIGHT_TYPE_UNSPECIFIED" + // "WITHDRAWAL_RIGHT_DIGITAL_CONTENT" + // "WITHDRAWAL_RIGHT_SERVICE" + WithdrawalRightType string `json:"withdrawalRightType,omitempty"` + // ForceSendFields is a list of field names (e.g. "WithdrawalRightType") 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. "IsRemoteInAppUpdateRequested") 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. "WithdrawalRightType") 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 RemoteInAppUpdate) MarshalJSON() ([]byte, error) { - type NoMethod RemoteInAppUpdate +func (s PurchaseOptionTaxAndComplianceSettings) MarshalJSON() ([]byte, error) { + type NoMethod PurchaseOptionTaxAndComplianceSettings return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// RemoteInAppUpdateData: Data related to Remote In-App Update action such as -// recovered user count, affected user count etc. -type RemoteInAppUpdateData struct { - // RemoteAppUpdateDataPerBundle: Data related to the recovery action at bundle - // level. - RemoteAppUpdateDataPerBundle []*RemoteInAppUpdateDataPerBundle `json:"remoteAppUpdateDataPerBundle,omitempty"` - // ForceSendFields is a list of field names (e.g. - // "RemoteAppUpdateDataPerBundle") 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. "RemoteAppUpdateDataPerBundle") 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 RemoteInAppUpdateData) MarshalJSON() ([]byte, error) { - type NoMethod RemoteInAppUpdateData - return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) -} - -// RemoteInAppUpdateDataPerBundle: Data related to the recovery action at -// bundle level. -type RemoteInAppUpdateDataPerBundle struct { - // RecoveredDeviceCount: Total number of devices which have been rescued. - RecoveredDeviceCount int64 `json:"recoveredDeviceCount,omitempty,string"` - // TotalDeviceCount: Total number of devices affected by this recovery action - // associated with bundle of the app. - TotalDeviceCount int64 `json:"totalDeviceCount,omitempty,string"` - // VersionCode: Version Code corresponding to the target bundle. - VersionCode int64 `json:"versionCode,omitempty,string"` - // ForceSendFields is a list of field names (e.g. "RecoveredDeviceCount") to +// PurchaseStateContext: Context about the purchase state. +type PurchaseStateContext struct { + // PurchaseState: Output only. The purchase state of the purchase. + // + // Possible values: + // "PURCHASE_STATE_UNSPECIFIED" - Purchase state unspecified. This value + // should never be set. + // "PURCHASED" - Purchased successfully. + // "CANCELLED" - Purchase canceled. + // "PENDING" - The purchase is in a pending state and has not yet been + // completed. For more information on handling pending purchases, see + // https://developer.android.com/google/play/billing/integrate#pending. + PurchaseState string `json:"purchaseState,omitempty"` + // ForceSendFields is a list of field names (e.g. "PurchaseState") 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. "RecoveredDeviceCount") 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. "PurchaseState") 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 RemoteInAppUpdateDataPerBundle) MarshalJSON() ([]byte, error) { - type NoMethod RemoteInAppUpdateDataPerBundle +func (s PurchaseStateContext) MarshalJSON() ([]byte, error) { + type NoMethod PurchaseStateContext return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// RentOfferDetails: Offer details information related to a rental line item. -type RentOfferDetails struct { -} - -// RentalDetails: Details of a rental purchase. -type RentalDetails struct { -} - -// ReplacementCancellation: Information specific to cancellations caused by -// subscription replacement. -type ReplacementCancellation struct { -} - -// RestrictedPaymentCountries: Countries where the purchase of this product is -// restricted to payment methods registered in the same country. If empty, no -// payment location restrictions are imposed. -type RestrictedPaymentCountries struct { - // RegionCodes: Required. Region codes to impose payment restrictions on, as - // defined by ISO 3166-2, e.g. "US". - RegionCodes []string `json:"regionCodes,omitempty"` - // ForceSendFields is a list of field names (e.g. "RegionCodes") to +// RecurringExternalTransaction: Represents a transaction that is part of a +// recurring series of payments. This can be a subscription or a one-time +// product with multiple payments (such as preorder). +type RecurringExternalTransaction struct { + // ExternalSubscription: Details of an external subscription. + ExternalSubscription *ExternalSubscription `json:"externalSubscription,omitempty"` + // ExternalTransactionToken: Input only. Provided during the call to Create. + // Retrieved from the client when the alternative billing flow is launched. + // Required only for the initial purchase. + ExternalTransactionToken string `json:"externalTransactionToken,omitempty"` + // InitialExternalTransactionId: The external transaction id of the first + // transaction of this recurring series of transactions. For example, for a + // subscription this would be the transaction id of the first payment. Required + // when creating recurring external transactions. + InitialExternalTransactionId string `json:"initialExternalTransactionId,omitempty"` + // MigratedTransactionProgram: Input only. Provided during the call to Create. + // Must only be used when migrating a subscription from manual monthly + // reporting to automated reporting. + // + // Possible values: + // "EXTERNAL_TRANSACTION_PROGRAM_UNSPECIFIED" - Unspecified transaction + // program. Not used. + // "USER_CHOICE_BILLING" - User choice billing, where a user may choose + // between Google Play Billing developer-managed billing. + // "ALTERNATIVE_BILLING_ONLY" - Alternative billing only, where users may + // only use developer-manager billing. + MigratedTransactionProgram string `json:"migratedTransactionProgram,omitempty"` + // OtherRecurringProduct: Details of a recurring external transaction product + // which doesn't belong to any other specific category. + OtherRecurringProduct *OtherRecurringProduct `json:"otherRecurringProduct,omitempty"` + // ForceSendFields is a list of field names (e.g. "ExternalSubscription") 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. "RegionCodes") 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. "ExternalSubscription") 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 RestrictedPaymentCountries) MarshalJSON() ([]byte, error) { - type NoMethod RestrictedPaymentCountries +func (s RecurringExternalTransaction) MarshalJSON() ([]byte, error) { + type NoMethod RecurringExternalTransaction return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// Review: An Android app review. -type Review struct { - // AuthorName: The name of the user who wrote the review. - AuthorName string `json:"authorName,omitempty"` - // Comments: A repeated field containing comments for the review. - Comments []*Comment `json:"comments,omitempty"` - // ReviewId: Unique identifier for this review. - ReviewId string `json:"reviewId,omitempty"` - - // ServerResponse contains the HTTP response code and headers from the server. - googleapi.ServerResponse `json:"-"` - // ForceSendFields is a list of field names (e.g. "AuthorName") to - // unconditionally include in API requests. By default, fields with empty or - // default values are omitted from API requests. See +// RefundDetails: Details for a partial or full refund. +type RefundDetails struct { + // Tax: The amount of tax refunded. + Tax *Money `json:"tax,omitempty"` + // Total: The total amount refunded, including tax. + Total *Money `json:"total,omitempty"` + // ForceSendFields is a list of field names (e.g. "Tax") 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. "AuthorName") 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. "Tax") 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 Review) MarshalJSON() ([]byte, error) { - type NoMethod Review +func (s RefundDetails) MarshalJSON() ([]byte, error) { + type NoMethod RefundDetails return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// ReviewReplyResult: The result of replying/updating a reply to review. -type ReviewReplyResult struct { - // LastEdited: The time at which the reply took effect. - LastEdited *Timestamp `json:"lastEdited,omitempty"` - // ReplyText: The reply text that was applied. - ReplyText string `json:"replyText,omitempty"` - // ForceSendFields is a list of field names (e.g. "LastEdited") to +// RefundEvent: Details of when the order was fully refunded. +type RefundEvent struct { + // EventTime: The time when the order was fully refunded. + EventTime string `json:"eventTime,omitempty"` + // RefundDetails: Details for the full refund. + RefundDetails *RefundDetails `json:"refundDetails,omitempty"` + // RefundReason: The reason the order was refunded. + // + // Possible values: + // "REFUND_REASON_UNSPECIFIED" - Refund reason unspecified. This value is not + // used. + // "OTHER" - The order was refunded for a reason other than the listed + // reasons here. + // "CHARGEBACK" - The order was charged back. + RefundReason string `json:"refundReason,omitempty"` + // ForceSendFields is a list of field names (e.g. "EventTime") 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. "LastEdited") to include in API + // NullFields is a list of field names (e.g. "EventTime") 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 ReviewReplyResult) MarshalJSON() ([]byte, error) { - type NoMethod ReviewReplyResult +func (s RefundEvent) MarshalJSON() ([]byte, error) { + type NoMethod RefundEvent return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// ReviewsListResponse: Response listing reviews. -type ReviewsListResponse struct { - // PageInfo: Information about the current page. - PageInfo *PageInfo `json:"pageInfo,omitempty"` - // Reviews: List of reviews. - Reviews []*Review `json:"reviews,omitempty"` - // TokenPagination: Pagination token, to handle a number of products that is - // over one page. - TokenPagination *TokenPagination `json:"tokenPagination,omitempty"` - - // ServerResponse contains the HTTP response code and headers from the server. - googleapi.ServerResponse `json:"-"` - // ForceSendFields is a list of field names (e.g. "PageInfo") to +// RefundExternalTransactionRequest: A request to refund an existing external +// transaction. +type RefundExternalTransactionRequest struct { + // FullRefund: A full-amount refund. + FullRefund *FullRefund `json:"fullRefund,omitempty"` + // PartialRefund: A partial refund. + PartialRefund *PartialRefund `json:"partialRefund,omitempty"` + // RefundTime: Required. The time that the transaction was refunded. + RefundTime string `json:"refundTime,omitempty"` + // ForceSendFields is a list of field names (e.g. "FullRefund") 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. "PageInfo") to include in API + // NullFields is a list of field names (e.g. "FullRefund") 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 ReviewsListResponse) MarshalJSON() ([]byte, error) { - type NoMethod ReviewsListResponse +func (s RefundExternalTransactionRequest) MarshalJSON() ([]byte, error) { + type NoMethod RefundExternalTransactionRequest return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// ReviewsReplyRequest: Request to reply to review or update existing reply. -type ReviewsReplyRequest struct { - // ReplyText: The text to set as the reply. Replies of more than approximately - // 350 characters will be rejected. HTML tags will be stripped. - ReplyText string `json:"replyText,omitempty"` - // ForceSendFields is a list of field names (e.g. "ReplyText") to - // unconditionally include in API requests. By default, fields with empty or +// RegionalBasePlanConfig: Configuration for a base plan specific to a region. +type RegionalBasePlanConfig struct { + // NewSubscriberAvailability: Whether the base plan in the specified region is + // available for new subscribers. Existing subscribers will not have their + // subscription canceled if this value is set to false. If not specified, this + // will default to false. + NewSubscriberAvailability bool `json:"newSubscriberAvailability,omitempty"` + // Price: The price of the base plan in the specified region. Must be set if + // the base plan is available to new subscribers. Must be set in the currency + // that is linked to the specified region. + Price *Money `json:"price,omitempty"` + // RegionCode: Required. Region code this configuration applies to, as defined + // by ISO 3166-2, e.g. "US". + RegionCode string `json:"regionCode,omitempty"` + // ForceSendFields is a list of field names (e.g. "NewSubscriberAvailability") + // 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. "ReplyText") 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. "NewSubscriberAvailability") 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 ReviewsReplyRequest) MarshalJSON() ([]byte, error) { - type NoMethod ReviewsReplyRequest +func (s RegionalBasePlanConfig) MarshalJSON() ([]byte, error) { + type NoMethod RegionalBasePlanConfig return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// ReviewsReplyResponse: Response on status of replying to a review. -type ReviewsReplyResponse struct { - // Result: The result of replying/updating a reply to review. - Result *ReviewReplyResult `json:"result,omitempty"` - - // ServerResponse contains the HTTP response code and headers from the server. - googleapi.ServerResponse `json:"-"` - // ForceSendFields is a list of field names (e.g. "Result") 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. "Result") 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 ReviewsReplyResponse) MarshalJSON() ([]byte, error) { - type NoMethod ReviewsReplyResponse - return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) -} - -// RevocationContext: Revocation context of the -// purchases.subscriptionsv2.revoke API. -type RevocationContext struct { - // FullRefund: Optional. Used when users should be refunded the full amount of - // latest charge on each item in the subscription. - FullRefund *RevocationContextFullRefund `json:"fullRefund,omitempty"` - // ItemBasedRefund: Optional. Used when a specific item should be refunded in a - // subscription with add-on items. - ItemBasedRefund *RevocationContextItemBasedRefund `json:"itemBasedRefund,omitempty"` - // ProratedRefund: Optional. Used when users should be refunded a prorated - // amount they paid for their subscription based on the amount of time - // remaining in a subscription. - ProratedRefund *RevocationContextProratedRefund `json:"proratedRefund,omitempty"` - // ForceSendFields is a list of field names (e.g. "FullRefund") 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. +// RegionalPriceMigrationConfig: Configuration for migration of a legacy price +// cohort. +type RegionalPriceMigrationConfig struct { + // OldestAllowedPriceVersionTime: Required. Subscribers in all legacy price + // cohorts before this time will be migrated to the current price. Subscribers + // in any newer price cohorts are unaffected. Affected subscribers will receive + // one or more notifications from Google Play about the price change. Price + // decreases occur at the subscriber's next billing date. Price increases occur + // at the subscriber's next billing date following a notification period that + // varies by region and price increase type. + OldestAllowedPriceVersionTime string `json:"oldestAllowedPriceVersionTime,omitempty"` + // PriceIncreaseType: Optional. The requested type of price increase + // + // Possible values: + // "PRICE_INCREASE_TYPE_UNSPECIFIED" - Unspecified state. + // "PRICE_INCREASE_TYPE_OPT_IN" - Subscribers must accept the price increase + // or their subscription is canceled. + // "PRICE_INCREASE_TYPE_OPT_OUT" - Subscribers are notified but do not have + // to accept the price increase. Opt-out price increases not meeting regional, + // frequency, and amount limits will proceed as opt-in price increase. The + // first opt-out price increase for each app must be initiated in the Google + // Play Console. + PriceIncreaseType string `json:"priceIncreaseType,omitempty"` + // RegionCode: Required. Region code this configuration applies to, as defined + // by ISO 3166-2, e.g. "US". + RegionCode string `json:"regionCode,omitempty"` + // ForceSendFields is a list of field names (e.g. + // "OldestAllowedPriceVersionTime") 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. "FullRefund") 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. "OldestAllowedPriceVersionTime") + // 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 RevocationContext) MarshalJSON() ([]byte, error) { - type NoMethod RevocationContext +func (s RegionalPriceMigrationConfig) MarshalJSON() ([]byte, error) { + type NoMethod RegionalPriceMigrationConfig return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// RevocationContextFullRefund: Used to determine if the refund type in the -// RevocationContext is a full refund. -type RevocationContextFullRefund struct { -} - -// RevocationContextItemBasedRefund: Used to determine what specific item to -// revoke in a subscription with multiple items. -type RevocationContextItemBasedRefund struct { - // ProductId: Required. If the subscription is a subscription with add-ons, the - // product id of the subscription item to revoke. - ProductId string `json:"productId,omitempty"` - // ForceSendFields is a list of field names (e.g. "ProductId") to - // unconditionally include in API requests. By default, fields with empty or +// RegionalSubscriptionOfferConfig: Configuration for a subscription offer in a +// single region. +type RegionalSubscriptionOfferConfig struct { + // NewSubscriberAvailability: Whether the subscription offer in the specified + // region is available for new subscribers. Existing subscribers will not have + // their subscription cancelled if this value is set to false. If not + // specified, this will default to false. + NewSubscriberAvailability bool `json:"newSubscriberAvailability,omitempty"` + // RegionCode: Required. Immutable. Region code this configuration applies to, + // as defined by ISO 3166-2, e.g. "US". + RegionCode string `json:"regionCode,omitempty"` + // ForceSendFields is a list of field names (e.g. "NewSubscriberAvailability") + // 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. "ProductId") 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. "NewSubscriberAvailability") 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 RevocationContextItemBasedRefund) MarshalJSON() ([]byte, error) { - type NoMethod RevocationContextItemBasedRefund +func (s RegionalSubscriptionOfferConfig) MarshalJSON() ([]byte, error) { + type NoMethod RegionalSubscriptionOfferConfig return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// RevocationContextProratedRefund: Used to determine if the refund type in the -// RevocationContext is a prorated refund. -type RevocationContextProratedRefund struct { -} - -// RevokeSubscriptionPurchaseRequest: Request for the -// purchases.subscriptionsv2.revoke API. -type RevokeSubscriptionPurchaseRequest struct { - // RevocationContext: Required. Additional details around the subscription - // revocation. - RevocationContext *RevocationContext `json:"revocationContext,omitempty"` - // ForceSendFields is a list of field names (e.g. "RevocationContext") to +// RegionalSubscriptionOfferPhaseConfig: Configuration for a single phase of a +// subscription offer in a single region. +type RegionalSubscriptionOfferPhaseConfig struct { + // AbsoluteDiscount: The absolute amount of money subtracted from the base plan + // price prorated over the phase duration that the user pays for this offer + // phase. For example, if the base plan price for this region is $12 for a + // period of 1 year, then a $1 absolute discount for a phase of a duration of 3 + // months would correspond to a price of $2. The resulting price may not be + // smaller than the minimum price allowed for this region. + AbsoluteDiscount *Money `json:"absoluteDiscount,omitempty"` + // Free: Set to specify this offer is free to obtain. + Free *RegionalSubscriptionOfferPhaseFreePriceOverride `json:"free,omitempty"` + // Price: The absolute price the user pays for this offer phase. The price must + // not be smaller than the minimum price allowed for this region. + Price *Money `json:"price,omitempty"` + // RegionCode: Required. Immutable. The region to which this config applies. + RegionCode string `json:"regionCode,omitempty"` + // RelativeDiscount: The fraction of the base plan price prorated over the + // phase duration that the user pays for this offer phase. For example, if the + // base plan price for this region is $12 for a period of 1 year, then a 50% + // discount for a phase of a duration of 3 months would correspond to a price + // of $1.50. The discount must be specified as a fraction strictly larger than + // 0 and strictly smaller than 1. The resulting price will be rounded to the + // nearest billable unit (e.g. cents for USD). The relative discount is + // considered invalid if the discounted price ends up being smaller than the + // minimum price allowed in this region. + RelativeDiscount float64 `json:"relativeDiscount,omitempty"` + // ForceSendFields is a list of field names (e.g. "AbsoluteDiscount") 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. "RevocationContext") to include in + // NullFields is a list of field names (e.g. "AbsoluteDiscount") 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 RevokeSubscriptionPurchaseRequest) MarshalJSON() ([]byte, error) { - type NoMethod RevokeSubscriptionPurchaseRequest +func (s RegionalSubscriptionOfferPhaseConfig) MarshalJSON() ([]byte, error) { + type NoMethod RegionalSubscriptionOfferPhaseConfig return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// RevokeSubscriptionPurchaseResponse: Response for the -// purchases.subscriptionsv2.revoke API. -type RevokeSubscriptionPurchaseResponse struct { - // ServerResponse contains the HTTP response code and headers from the server. - googleapi.ServerResponse `json:"-"` +func (s *RegionalSubscriptionOfferPhaseConfig) UnmarshalJSON(data []byte) error { + type NoMethod RegionalSubscriptionOfferPhaseConfig + var s1 struct { + RelativeDiscount gensupport.JSONFloat64 `json:"relativeDiscount"` + *NoMethod + } + s1.NoMethod = (*NoMethod)(s) + if err := json.Unmarshal(data, &s1); err != nil { + return err + } + s.RelativeDiscount = float64(s1.RelativeDiscount) + return nil } -// SafetyLabelsUpdateRequest: Request to update Safety Labels of an app. -type SafetyLabelsUpdateRequest struct { - // SafetyLabels: Required. Contents of the CSV file containing Data Safety - // responses. For the format of this file, see the Help Center documentation at - // https://support.google.com/googleplay/android-developer/answer/10787469?#zippy=%2Cunderstand-the-csv-format - // To download an up to date template, follow the steps at - // https://support.google.com/googleplay/android-developer/answer/10787469?#zippy=%2Cexport-to-a-csv-file - SafetyLabels string `json:"safetyLabels,omitempty"` - // ForceSendFields is a list of field names (e.g. "SafetyLabels") to - // unconditionally include in API requests. By default, fields with empty or - // default values are omitted from API requests. See +// RegionalSubscriptionOfferPhaseFreePriceOverride: Represents the free price +// override configuration for a single phase of a subscription offer +type RegionalSubscriptionOfferPhaseFreePriceOverride struct { +} + +// RegionalTaxConfig: Details about taxation in a given geographical region. +type RegionalTaxConfig struct { + // EligibleForStreamingServiceTaxRate: You must tell us if your app contains + // streaming products to correctly charge US state and local sales tax. Field + // only supported in the United States. + EligibleForStreamingServiceTaxRate bool `json:"eligibleForStreamingServiceTaxRate,omitempty"` + // RegionCode: Required. Region code this configuration applies to, as defined + // by ISO 3166-2, e.g. "US". + RegionCode string `json:"regionCode,omitempty"` + // StreamingTaxType: To collect communications or amusement taxes in the United + // States, choose the appropriate tax category. Learn more + // (https://support.google.com/googleplay/android-developer/answer/10463498#streaming_tax). + // + // Possible values: + // "STREAMING_TAX_TYPE_UNSPECIFIED" - No telecommunications tax collected. + // "STREAMING_TAX_TYPE_TELCO_VIDEO_RENTAL" - US-specific telecommunications + // tax tier for video streaming, on demand, rentals / subscriptions / + // pay-per-view. + // "STREAMING_TAX_TYPE_TELCO_VIDEO_SALES" - US-specific telecommunications + // tax tier for video streaming of pre-recorded content like movies, tv shows. + // "STREAMING_TAX_TYPE_TELCO_VIDEO_MULTI_CHANNEL" - US-specific + // telecommunications tax tier for video streaming of multi-channel + // programming. + // "STREAMING_TAX_TYPE_TELCO_AUDIO_RENTAL" - US-specific telecommunications + // tax tier for audio streaming, rental / subscription. + // "STREAMING_TAX_TYPE_TELCO_AUDIO_SALES" - US-specific telecommunications + // tax tier for audio streaming, sale / permanent download. + // "STREAMING_TAX_TYPE_TELCO_AUDIO_MULTI_CHANNEL" - US-specific + // telecommunications tax tier for multi channel audio streaming like radio. + StreamingTaxType string `json:"streamingTaxType,omitempty"` + // TaxTier: Tax tier to specify reduced tax rate. Developers who sell digital + // news, magazines, newspapers, books, or audiobooks in various regions may be + // eligible for reduced tax rates. Learn more + // (https://support.google.com/googleplay/android-developer/answer/10463498). + // + // Possible values: + // "TAX_TIER_UNSPECIFIED" + // "TAX_TIER_BOOKS_1" + // "TAX_TIER_NEWS_1" + // "TAX_TIER_NEWS_2" + // "TAX_TIER_MUSIC_OR_AUDIO_1" + // "TAX_TIER_LIVE_OR_BROADCAST_1" + TaxTier string `json:"taxTier,omitempty"` + // ForceSendFields is a list of field names (e.g. + // "EligibleForStreamingServiceTaxRate") 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. "SafetyLabels") 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 is a list of field names (e.g. + // "EligibleForStreamingServiceTaxRate") 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 SafetyLabelsUpdateRequest) MarshalJSON() ([]byte, error) { - type NoMethod SafetyLabelsUpdateRequest +func (s RegionalTaxConfig) MarshalJSON() ([]byte, error) { + type NoMethod RegionalTaxConfig return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// SafetyLabelsUpdateResponse: Response for SafetyLabelsUpdate rpc. -type SafetyLabelsUpdateResponse struct { - // ServerResponse contains the HTTP response code and headers from the server. - googleapi.ServerResponse `json:"-"` -} - -// ScreenDensity: Represents a screen density. -type ScreenDensity struct { - // DensityAlias: Alias for a screen density. - // - // Possible values: - // "DENSITY_UNSPECIFIED" - Unspecified screen density. - // "NODPI" - NODPI screen density. - // "LDPI" - LDPI screen density. - // "MDPI" - MDPI screen density. - // "TVDPI" - TVDPI screen density. - // "HDPI" - HDPI screen density. - // "XHDPI" - XHDPI screen density. - // "XXHDPI" - XXHDPI screen density. - // "XXXHDPI" - XXXHDPI screen density. - DensityAlias string `json:"densityAlias,omitempty"` - // DensityDpi: Value for density dpi. - DensityDpi int64 `json:"densityDpi,omitempty"` - // ForceSendFields is a list of field names (e.g. "DensityAlias") to - // unconditionally include in API requests. By default, fields with empty or - // default values are omitted from API requests. See +// RegionalTaxRateInfo: Specified details about taxation in a given +// geographical region. +type RegionalTaxRateInfo struct { + // EligibleForStreamingServiceTaxRate: You must tell us if your app contains + // streaming products to correctly charge US state and local sales tax. Field + // only supported in the United States. + EligibleForStreamingServiceTaxRate bool `json:"eligibleForStreamingServiceTaxRate,omitempty"` + // StreamingTaxType: To collect communications or amusement taxes in the United + // States, choose the appropriate tax category. Learn more + // (https://support.google.com/googleplay/android-developer/answer/10463498#streaming_tax). + // + // Possible values: + // "STREAMING_TAX_TYPE_UNSPECIFIED" - No telecommunications tax collected. + // "STREAMING_TAX_TYPE_TELCO_VIDEO_RENTAL" - US-specific telecommunications + // tax tier for video streaming, on demand, rentals / subscriptions / + // pay-per-view. + // "STREAMING_TAX_TYPE_TELCO_VIDEO_SALES" - US-specific telecommunications + // tax tier for video streaming of pre-recorded content like movies, tv shows. + // "STREAMING_TAX_TYPE_TELCO_VIDEO_MULTI_CHANNEL" - US-specific + // telecommunications tax tier for video streaming of multi-channel + // programming. + // "STREAMING_TAX_TYPE_TELCO_AUDIO_RENTAL" - US-specific telecommunications + // tax tier for audio streaming, rental / subscription. + // "STREAMING_TAX_TYPE_TELCO_AUDIO_SALES" - US-specific telecommunications + // tax tier for audio streaming, sale / permanent download. + // "STREAMING_TAX_TYPE_TELCO_AUDIO_MULTI_CHANNEL" - US-specific + // telecommunications tax tier for multi channel audio streaming like radio. + StreamingTaxType string `json:"streamingTaxType,omitempty"` + // TaxTier: Tax tier to specify reduced tax rate. Developers who sell digital + // news, magazines, newspapers, books, or audiobooks in various regions may be + // eligible for reduced tax rates. Learn more + // (https://support.google.com/googleplay/android-developer/answer/10463498). + // + // Possible values: + // "TAX_TIER_UNSPECIFIED" + // "TAX_TIER_BOOKS_1" + // "TAX_TIER_NEWS_1" + // "TAX_TIER_NEWS_2" + // "TAX_TIER_MUSIC_OR_AUDIO_1" + // "TAX_TIER_LIVE_OR_BROADCAST_1" + TaxTier string `json:"taxTier,omitempty"` + // ForceSendFields is a list of field names (e.g. + // "EligibleForStreamingServiceTaxRate") 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. "DensityAlias") 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 is a list of field names (e.g. + // "EligibleForStreamingServiceTaxRate") 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 ScreenDensity) MarshalJSON() ([]byte, error) { - type NoMethod ScreenDensity +func (s RegionalTaxRateInfo) MarshalJSON() ([]byte, error) { + type NoMethod RegionalTaxRateInfo return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// ScreenDensityTargeting: Targeting based on screen density. -type ScreenDensityTargeting struct { - // Alternatives: Targeting of other sibling directories that were in the - // Bundle. For main splits this is targeting of other main splits. - Alternatives []*ScreenDensity `json:"alternatives,omitempty"` - // Value: Value of a screen density. - Value []*ScreenDensity `json:"value,omitempty"` - // ForceSendFields is a list of field names (e.g. "Alternatives") to +// Regions: Region targeting data for app recovery action targeting. +type Regions struct { + // RegionCode: Regions targeted by the recovery action. Region codes are ISO + // 3166 Alpha-2 country codes. For example, US stands for United States of + // America. See https://www.iso.org/iso-3166-country-codes.html for the + // complete list of country codes. + RegionCode []string `json:"regionCode,omitempty"` + // ForceSendFields is a list of field names (e.g. "RegionCode") 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. "Alternatives") to include in API + // NullFields is a list of field names (e.g. "RegionCode") 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 ScreenDensityTargeting) MarshalJSON() ([]byte, error) { - type NoMethod ScreenDensityTargeting +func (s Regions) MarshalJSON() ([]byte, error) { + type NoMethod Regions return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// SdkVersion: Represents an sdk version. -type SdkVersion struct { - // Min: Inclusive minimum value of an sdk version. - Min int64 `json:"min,omitempty"` - // ForceSendFields is a list of field names (e.g. "Min") to unconditionally +// RegionsVersion: The version of the available regions being used for the +// specified resource. +type RegionsVersion struct { + // Version: Required. A string representing the version of available regions + // being used for the specified resource. Regional prices and latest supported + // version for the resource have to be specified according to the information + // published in this article + // (https://support.google.com/googleplay/android-developer/answer/10532353). + // Each time the supported locations substantially change, the version will be + // incremented. Using this field will ensure that creating and updating the + // resource with an older region's version and set of regional prices and + // currencies will succeed even though a new version is available. + Version string `json:"version,omitempty"` + // ForceSendFields is a list of field names (e.g. "Version") 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. "Min") 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. "Version") 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 SdkVersion) MarshalJSON() ([]byte, error) { - type NoMethod SdkVersion +func (s RegionsVersion) MarshalJSON() ([]byte, error) { + type NoMethod RegionsVersion return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// SdkVersionTargeting: Targeting based on sdk version. -type SdkVersionTargeting struct { - // Alternatives: Targeting of other sibling directories that were in the - // Bundle. For main splits this is targeting of other main splits. - Alternatives []*SdkVersion `json:"alternatives,omitempty"` - // Value: Value of an sdk version. - Value []*SdkVersion `json:"value,omitempty"` - // ForceSendFields is a list of field names (e.g. "Alternatives") to +// RemoteInAppUpdate: Object representation for Remote in-app update action +// type. +type RemoteInAppUpdate struct { + // IsRemoteInAppUpdateRequested: Required. Set to true if Remote In-App Update + // action type is needed. + IsRemoteInAppUpdateRequested bool `json:"isRemoteInAppUpdateRequested,omitempty"` + // ForceSendFields is a list of field names (e.g. + // "IsRemoteInAppUpdateRequested") 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. "IsRemoteInAppUpdateRequested") 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 RemoteInAppUpdate) MarshalJSON() ([]byte, error) { + type NoMethod RemoteInAppUpdate + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// RemoteInAppUpdateData: Data related to Remote In-App Update action such as +// recovered user count, affected user count etc. +type RemoteInAppUpdateData struct { + // RemoteAppUpdateDataPerBundle: Data related to the recovery action at bundle + // level. + RemoteAppUpdateDataPerBundle []*RemoteInAppUpdateDataPerBundle `json:"remoteAppUpdateDataPerBundle,omitempty"` + // ForceSendFields is a list of field names (e.g. + // "RemoteAppUpdateDataPerBundle") 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. "RemoteAppUpdateDataPerBundle") 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 RemoteInAppUpdateData) MarshalJSON() ([]byte, error) { + type NoMethod RemoteInAppUpdateData + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// RemoteInAppUpdateDataPerBundle: Data related to the recovery action at +// bundle level. +type RemoteInAppUpdateDataPerBundle struct { + // RecoveredDeviceCount: Total number of devices which have been rescued. + RecoveredDeviceCount int64 `json:"recoveredDeviceCount,omitempty,string"` + // TotalDeviceCount: Total number of devices affected by this recovery action + // associated with bundle of the app. + TotalDeviceCount int64 `json:"totalDeviceCount,omitempty,string"` + // VersionCode: Version Code corresponding to the target bundle. + VersionCode int64 `json:"versionCode,omitempty,string"` + // ForceSendFields is a list of field names (e.g. "RecoveredDeviceCount") 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. "Alternatives") 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. "RecoveredDeviceCount") 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 SdkVersionTargeting) MarshalJSON() ([]byte, error) { - type NoMethod SdkVersionTargeting +func (s RemoteInAppUpdateDataPerBundle) MarshalJSON() ([]byte, error) { + type NoMethod RemoteInAppUpdateDataPerBundle return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// SignupPromotion: The promotion applied on this item when purchased. -type SignupPromotion struct { - // OneTimeCode: A one-time code was applied. - OneTimeCode *OneTimeCode `json:"oneTimeCode,omitempty"` - // VanityCode: A vanity code was applied. - VanityCode *VanityCode `json:"vanityCode,omitempty"` - // ForceSendFields is a list of field names (e.g. "OneTimeCode") to +// RentOfferDetails: Offer details information related to a rental line item. +type RentOfferDetails struct { +} + +// RentalDetails: Details of a rental purchase. +type RentalDetails struct { +} + +// ReplacementCancellation: Information specific to cancellations caused by +// subscription replacement. +type ReplacementCancellation struct { +} + +// RestrictedPaymentCountries: Countries where the purchase of this product is +// restricted to payment methods registered in the same country. If empty, no +// payment location restrictions are imposed. +type RestrictedPaymentCountries struct { + // RegionCodes: Required. Region codes to impose payment restrictions on, as + // defined by ISO 3166-2, e.g. "US". + RegionCodes []string `json:"regionCodes,omitempty"` + // ForceSendFields is a list of field names (e.g. "RegionCodes") 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. "OneTimeCode") to include in API + // NullFields is a list of field names (e.g. "RegionCodes") 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 SignupPromotion) MarshalJSON() ([]byte, error) { - type NoMethod SignupPromotion +func (s RestrictedPaymentCountries) MarshalJSON() ([]byte, error) { + type NoMethod RestrictedPaymentCountries return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// SplitApkMetadata: Holds data specific to Split APKs. -type SplitApkMetadata struct { - // IsMasterSplit: Indicates whether this APK is the main split of the module. - IsMasterSplit bool `json:"isMasterSplit,omitempty"` - // SplitId: Id of the split. - SplitId string `json:"splitId,omitempty"` - // ForceSendFields is a list of field names (e.g. "IsMasterSplit") to +// Review: An Android app review. +type Review struct { + // AuthorName: The name of the user who wrote the review. + AuthorName string `json:"authorName,omitempty"` + // Comments: A repeated field containing comments for the review. + Comments []*Comment `json:"comments,omitempty"` + // ReviewId: Unique identifier for this review. + ReviewId string `json:"reviewId,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the server. + googleapi.ServerResponse `json:"-"` + // ForceSendFields is a list of field names (e.g. "AuthorName") 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. "IsMasterSplit") to include in API + // NullFields is a list of field names (e.g. "AuthorName") 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 SplitApkMetadata) MarshalJSON() ([]byte, error) { - type NoMethod SplitApkMetadata +func (s Review) MarshalJSON() ([]byte, error) { + type NoMethod Review return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// SplitApkVariant: Variant is a group of APKs that covers a part of the device -// configuration space. APKs from multiple variants are never combined on one -// device. -type SplitApkVariant struct { - // ApkSet: Set of APKs, one set per module. - ApkSet []*ApkSet `json:"apkSet,omitempty"` - // Targeting: Variant-level targeting. - Targeting *VariantTargeting `json:"targeting,omitempty"` - // VariantNumber: Number of the variant, starting at 0 (unless overridden). A - // device will receive APKs from the first variant that matches the device - // configuration, with higher variant numbers having priority over lower - // variant numbers. - VariantNumber int64 `json:"variantNumber,omitempty"` - // ForceSendFields is a list of field names (e.g. "ApkSet") to unconditionally - // include in API requests. By default, fields with empty or default values are - // omitted from API requests. See +// ReviewReplyResult: The result of replying/updating a reply to review. +type ReviewReplyResult struct { + // LastEdited: The time at which the reply took effect. + LastEdited *Timestamp `json:"lastEdited,omitempty"` + // ReplyText: The reply text that was applied. + ReplyText string `json:"replyText,omitempty"` + // ForceSendFields is a list of field names (e.g. "LastEdited") 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. "ApkSet") to include in API + // NullFields is a list of field names (e.g. "LastEdited") 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 SplitApkVariant) MarshalJSON() ([]byte, error) { - type NoMethod SplitApkVariant +func (s ReviewReplyResult) MarshalJSON() ([]byte, error) { + type NoMethod ReviewReplyResult return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// StandaloneApkMetadata: Holds data specific to Standalone APKs. -type StandaloneApkMetadata struct { - // FusedModuleName: Names of the modules fused in this standalone APK. - FusedModuleName []string `json:"fusedModuleName,omitempty"` - // ForceSendFields is a list of field names (e.g. "FusedModuleName") to +// ReviewsListResponse: Response listing reviews. +type ReviewsListResponse struct { + // PageInfo: Information about the current page. + PageInfo *PageInfo `json:"pageInfo,omitempty"` + // Reviews: List of reviews. + Reviews []*Review `json:"reviews,omitempty"` + // TokenPagination: Pagination token, to handle a number of products that is + // over one page. + TokenPagination *TokenPagination `json:"tokenPagination,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the server. + googleapi.ServerResponse `json:"-"` + // ForceSendFields is a list of field names (e.g. "PageInfo") 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. "FusedModuleName") 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. "PageInfo") 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 StandaloneApkMetadata) MarshalJSON() ([]byte, error) { - type NoMethod StandaloneApkMetadata +func (s ReviewsListResponse) MarshalJSON() ([]byte, error) { + type NoMethod ReviewsListResponse return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// SubscribeWithGoogleInfo: Information associated with purchases made with -// 'Subscribe with Google'. -type SubscribeWithGoogleInfo struct { - // EmailAddress: The email address of the user when the subscription was - // purchased. - EmailAddress string `json:"emailAddress,omitempty"` - // FamilyName: The family name of the user when the subscription was purchased. - FamilyName string `json:"familyName,omitempty"` - // GivenName: The given name of the user when the subscription was purchased. - GivenName string `json:"givenName,omitempty"` - // ProfileId: The Google profile id of the user when the subscription was - // purchased. - ProfileId string `json:"profileId,omitempty"` - // ProfileName: The profile name of the user when the subscription was - // purchased. - ProfileName string `json:"profileName,omitempty"` - // ForceSendFields is a list of field names (e.g. "EmailAddress") to +// ReviewsReplyRequest: Request to reply to review or update existing reply. +type ReviewsReplyRequest struct { + // ReplyText: The text to set as the reply. Replies of more than approximately + // 350 characters will be rejected. HTML tags will be stripped. + ReplyText string `json:"replyText,omitempty"` + // ForceSendFields is a list of field names (e.g. "ReplyText") 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. "EmailAddress") to include in API + // NullFields is a list of field names (e.g. "ReplyText") 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 SubscribeWithGoogleInfo) MarshalJSON() ([]byte, error) { - type NoMethod SubscribeWithGoogleInfo +func (s ReviewsReplyRequest) MarshalJSON() ([]byte, error) { + type NoMethod ReviewsReplyRequest return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// Subscription: A single subscription for an app. -type Subscription struct { - // Archived: Output only. Deprecated: subscription archiving is not supported. - Archived bool `json:"archived,omitempty"` - // BasePlans: The set of base plans for this subscription. Represents the - // prices and duration of the subscription if no other offers apply. - BasePlans []*BasePlan `json:"basePlans,omitempty"` - // Listings: Required. List of localized listings for this subscription. Must - // contain at least an entry for the default language of the parent app. - Listings []*SubscriptionListing `json:"listings,omitempty"` - // PackageName: Immutable. Package name of the parent app. - PackageName string `json:"packageName,omitempty"` - // ProductId: Immutable. Unique product ID of the product. Unique within the - // parent app. Product IDs must be composed of lower-case letters (a-z), - // numbers (0-9), underscores (_) and dots (.). It must start with a lower-case - // letter or number, and be between 1 and 40 (inclusive) characters in length. - ProductId string `json:"productId,omitempty"` - // RestrictedPaymentCountries: Optional. Countries where the purchase of this - // subscription is restricted to payment methods registered in the same - // country. If empty, no payment location restrictions are imposed. - RestrictedPaymentCountries *RestrictedPaymentCountries `json:"restrictedPaymentCountries,omitempty"` - // TaxAndComplianceSettings: Details about taxes and legal compliance. - TaxAndComplianceSettings *SubscriptionTaxAndComplianceSettings `json:"taxAndComplianceSettings,omitempty"` +// ReviewsReplyResponse: Response on status of replying to a review. +type ReviewsReplyResponse struct { + // Result: The result of replying/updating a reply to review. + Result *ReviewReplyResult `json:"result,omitempty"` // ServerResponse contains the HTTP response code and headers from the server. googleapi.ServerResponse `json:"-"` - // ForceSendFields is a list of field names (e.g. "Archived") 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. "Result") 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. "Archived") to include in API + // NullFields is a list of field names (e.g. "Result") 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 Subscription) MarshalJSON() ([]byte, error) { - type NoMethod Subscription +func (s ReviewsReplyResponse) MarshalJSON() ([]byte, error) { + type NoMethod ReviewsReplyResponse return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// SubscriptionCancelSurveyResult: Information provided by the user when they -// complete the subscription cancellation flow (cancellation reason survey). -type SubscriptionCancelSurveyResult struct { - // CancelSurveyReason: The cancellation reason the user chose in the survey. - // Possible values are: 0. Other 1. I don't use this service enough 2. - // Technical issues 3. Cost-related reasons 4. I found a better app - CancelSurveyReason int64 `json:"cancelSurveyReason,omitempty"` - // UserInputCancelReason: The customized input cancel reason from the user. - // Only present when cancelReason is 0. - UserInputCancelReason string `json:"userInputCancelReason,omitempty"` - // ForceSendFields is a list of field names (e.g. "CancelSurveyReason") to +// RevocationContext: Revocation context of the +// purchases.subscriptionsv2.revoke API. +type RevocationContext struct { + // FullRefund: Optional. Used when users should be refunded the full amount of + // latest charge on each item in the subscription. + FullRefund *RevocationContextFullRefund `json:"fullRefund,omitempty"` + // ItemBasedRefund: Optional. Used when a specific item should be refunded in a + // subscription with add-on items. + ItemBasedRefund *RevocationContextItemBasedRefund `json:"itemBasedRefund,omitempty"` + // ProratedRefund: Optional. Used when users should be refunded a prorated + // amount they paid for their subscription based on the amount of time + // remaining in a subscription. + ProratedRefund *RevocationContextProratedRefund `json:"proratedRefund,omitempty"` + // ForceSendFields is a list of field names (e.g. "FullRefund") 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. "CancelSurveyReason") 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. "FullRefund") 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 SubscriptionCancelSurveyResult) MarshalJSON() ([]byte, error) { - type NoMethod SubscriptionCancelSurveyResult +func (s RevocationContext) MarshalJSON() ([]byte, error) { + type NoMethod RevocationContext return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// SubscriptionDeferralInfo: A SubscriptionDeferralInfo contains the data -// needed to defer a subscription purchase to a future expiry time. -type SubscriptionDeferralInfo struct { - // DesiredExpiryTimeMillis: The desired next expiry time to assign to the - // subscription, in milliseconds since the Epoch. The given time must be - // later/greater than the current expiry time for the subscription. - DesiredExpiryTimeMillis int64 `json:"desiredExpiryTimeMillis,omitempty,string"` - // ExpectedExpiryTimeMillis: The expected expiry time for the subscription. If - // the current expiry time for the subscription is not the value specified - // here, the deferral will not occur. - ExpectedExpiryTimeMillis int64 `json:"expectedExpiryTimeMillis,omitempty,string"` - // ForceSendFields is a list of field names (e.g. "DesiredExpiryTimeMillis") to +// RevocationContextFullRefund: Used to determine if the refund type in the +// RevocationContext is a full refund. +type RevocationContextFullRefund struct { +} + +// RevocationContextItemBasedRefund: Used to determine what specific item to +// revoke in a subscription with multiple items. +type RevocationContextItemBasedRefund struct { + // ProductId: Required. If the subscription is a subscription with add-ons, the + // product id of the subscription item to revoke. + ProductId string `json:"productId,omitempty"` + // ForceSendFields is a list of field names (e.g. "ProductId") 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. "DesiredExpiryTimeMillis") 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. "ProductId") 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 SubscriptionDeferralInfo) MarshalJSON() ([]byte, error) { - type NoMethod SubscriptionDeferralInfo +func (s RevocationContextItemBasedRefund) MarshalJSON() ([]byte, error) { + type NoMethod RevocationContextItemBasedRefund return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// SubscriptionDetails: Details of a subscription purchase. -type SubscriptionDetails struct { - // BasePlanId: The base plan ID of the subscription. - BasePlanId string `json:"basePlanId,omitempty"` - // OfferId: The offer ID for the current subscription offer. - OfferId string `json:"offerId,omitempty"` - // OfferPhase: The pricing phase for the billing period funded by this order. - // - // Possible values: - // "OFFER_PHASE_UNSPECIFIED" - Offer phase unspecified. This value is not - // used. - // "BASE" - The order funds a base price period. - // "INTRODUCTORY" - The order funds an introductory pricing period. - // "FREE_TRIAL" - The order funds a free trial period. - OfferPhase string `json:"offerPhase,omitempty"` - // ServicePeriodEndTime: The end of the billing period funded by this order. - // This is a snapshot of the billing/service period end time at the moment the - // order was processed, and should be used only for accounting. To get the - // current end time of the subscription service period, use - // purchases.subscriptionsv2.get. - ServicePeriodEndTime string `json:"servicePeriodEndTime,omitempty"` - // ServicePeriodStartTime: The start of the billing period funded by this - // order. This is a snapshot of the billing/service period start time at the - // moment the order was processed, and should be used only for accounting. - ServicePeriodStartTime string `json:"servicePeriodStartTime,omitempty"` - // ForceSendFields is a list of field names (e.g. "BasePlanId") to +// RevocationContextProratedRefund: Used to determine if the refund type in the +// RevocationContext is a prorated refund. +type RevocationContextProratedRefund struct { +} + +// RevokeSubscriptionPurchaseRequest: Request for the +// purchases.subscriptionsv2.revoke API. +type RevokeSubscriptionPurchaseRequest struct { + // RevocationContext: Required. Additional details around the subscription + // revocation. + RevocationContext *RevocationContext `json:"revocationContext,omitempty"` + // ForceSendFields is a list of field names (e.g. "RevocationContext") 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. "BasePlanId") 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. "RevocationContext") 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 SubscriptionDetails) MarshalJSON() ([]byte, error) { - type NoMethod SubscriptionDetails +func (s RevokeSubscriptionPurchaseRequest) MarshalJSON() ([]byte, error) { + type NoMethod RevokeSubscriptionPurchaseRequest return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// SubscriptionItemPriceChangeDetails: Price change related information of a -// subscription item. -type SubscriptionItemPriceChangeDetails struct { - // ExpectedNewPriceChargeTime: The renewal time at which the price change will - // become effective for the user. This is subject to change(to a future time) - // due to cases where the renewal time shifts like pause. This field is only - // populated if the price change has not taken effect. - ExpectedNewPriceChargeTime string `json:"expectedNewPriceChargeTime,omitempty"` - // NewPrice: New recurring price for the subscription item. - NewPrice *Money `json:"newPrice,omitempty"` - // PriceChangeMode: Price change mode specifies how the subscription item price - // is changing. - // - // Possible values: - // "PRICE_CHANGE_MODE_UNSPECIFIED" - Price change mode unspecified. This - // value should never be set. - // "PRICE_DECREASE" - If the subscription price is decreasing. - // "PRICE_INCREASE" - If the subscription price is increasing and the user - // needs to accept it. - // "OPT_OUT_PRICE_INCREASE" - If the subscription price is increasing with - // opt out mode. - PriceChangeMode string `json:"priceChangeMode,omitempty"` - // PriceChangeState: State the price change is currently in. - // - // Possible values: - // "PRICE_CHANGE_STATE_UNSPECIFIED" - Price change state unspecified. This - // value should not be used. - // "OUTSTANDING" - Waiting for the user to agree for the price change. - // "CONFIRMED" - The price change is confirmed to happen for the user. - // "APPLIED" - The price change is applied, i.e. the user has started being - // charged the new price. - // "CANCELED" - The price change was canceled. - PriceChangeState string `json:"priceChangeState,omitempty"` - // ForceSendFields is a list of field names (e.g. "ExpectedNewPriceChargeTime") - // to unconditionally include in API requests. By default, fields with empty or +// RevokeSubscriptionPurchaseResponse: Response for the +// purchases.subscriptionsv2.revoke API. +type RevokeSubscriptionPurchaseResponse struct { + // ServerResponse contains the HTTP response code and headers from the server. + googleapi.ServerResponse `json:"-"` +} + +// SafetyLabelsUpdateRequest: Request to update Safety Labels of an app. +type SafetyLabelsUpdateRequest struct { + // SafetyLabels: Required. Contents of the CSV file containing Data Safety + // responses. For the format of this file, see the Help Center documentation at + // https://support.google.com/googleplay/android-developer/answer/10787469?#zippy=%2Cunderstand-the-csv-format + // To download an up to date template, follow the steps at + // https://support.google.com/googleplay/android-developer/answer/10787469?#zippy=%2Cexport-to-a-csv-file + SafetyLabels string `json:"safetyLabels,omitempty"` + // ForceSendFields is a list of field names (e.g. "SafetyLabels") 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. "ExpectedNewPriceChargeTime") 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. "SafetyLabels") 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 SubscriptionItemPriceChangeDetails) MarshalJSON() ([]byte, error) { - type NoMethod SubscriptionItemPriceChangeDetails +func (s SafetyLabelsUpdateRequest) MarshalJSON() ([]byte, error) { + type NoMethod SafetyLabelsUpdateRequest return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// SubscriptionListing: The consumer-visible metadata of a subscription. -type SubscriptionListing struct { - // Benefits: A list of benefits shown to the user on platforms such as the Play - // Store and in restoration flows in the language of this listing. Plain text. - // Ordered list of at most four benefits. - Benefits []string `json:"benefits,omitempty"` - // Description: The description of this subscription in the language of this - // listing. Maximum length - 80 characters. Plain text. - Description string `json:"description,omitempty"` - // LanguageCode: Required. The language of this listing, as defined by BCP-47, - // e.g. "en-US". - LanguageCode string `json:"languageCode,omitempty"` - // Title: Required. The title of this subscription in the language of this - // listing. Plain text. - Title string `json:"title,omitempty"` - // ForceSendFields is a list of field names (e.g. "Benefits") to +// SafetyLabelsUpdateResponse: Response for SafetyLabelsUpdate rpc. +type SafetyLabelsUpdateResponse struct { + // ServerResponse contains the HTTP response code and headers from the server. + googleapi.ServerResponse `json:"-"` +} + +// ScreenDensity: Represents a screen density. +type ScreenDensity struct { + // DensityAlias: Alias for a screen density. + // + // Possible values: + // "DENSITY_UNSPECIFIED" - Unspecified screen density. + // "NODPI" - NODPI screen density. + // "LDPI" - LDPI screen density. + // "MDPI" - MDPI screen density. + // "TVDPI" - TVDPI screen density. + // "HDPI" - HDPI screen density. + // "XHDPI" - XHDPI screen density. + // "XXHDPI" - XXHDPI screen density. + // "XXXHDPI" - XXXHDPI screen density. + DensityAlias string `json:"densityAlias,omitempty"` + // DensityDpi: Value for density dpi. + DensityDpi int64 `json:"densityDpi,omitempty"` + // ForceSendFields is a list of field names (e.g. "DensityAlias") 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. "Benefits") to include in API + // NullFields is a list of field names (e.g. "DensityAlias") 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 SubscriptionListing) MarshalJSON() ([]byte, error) { - type NoMethod SubscriptionListing +func (s ScreenDensity) MarshalJSON() ([]byte, error) { + type NoMethod ScreenDensity return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// SubscriptionOffer: A single, temporary offer -type SubscriptionOffer struct { - // BasePlanId: Required. Immutable. The ID of the base plan to which this offer - // is an extension. - BasePlanId string `json:"basePlanId,omitempty"` - // OfferId: Required. Immutable. Unique ID of this subscription offer. Must be - // unique within the base plan. - OfferId string `json:"offerId,omitempty"` - // OfferTags: List of up to 20 custom tags specified for this offer, and - // returned to the app through the billing library. - OfferTags []*OfferTag `json:"offerTags,omitempty"` - // OtherRegionsConfig: The configuration for any new locations Play may launch - // in the future. - OtherRegionsConfig *OtherRegionsSubscriptionOfferConfig `json:"otherRegionsConfig,omitempty"` - // PackageName: Required. Immutable. The package name of the app the parent - // subscription belongs to. - PackageName string `json:"packageName,omitempty"` - // Phases: Required. The phases of this subscription offer. Must contain at - // least one and at most two entries. Users will always receive all these - // phases in the specified order. - Phases []*SubscriptionOfferPhase `json:"phases,omitempty"` - // ProductId: Required. Immutable. The ID of the parent subscription this offer - // belongs to. - ProductId string `json:"productId,omitempty"` - // RegionalConfigs: Required. The region-specific configuration of this offer. - // Must contain at least one entry. - RegionalConfigs []*RegionalSubscriptionOfferConfig `json:"regionalConfigs,omitempty"` - // State: Output only. The current state of this offer. Can be changed using - // Activate and Deactivate actions. NB: the base plan state supersedes this - // state, so an active offer may not be available if the base plan is not - // active. - // - // Possible values: - // "STATE_UNSPECIFIED" - Default value, should never be used. - // "DRAFT" - The subscription offer is not and has never been available to - // users. - // "ACTIVE" - The subscription offer is available to new and existing users. - // "INACTIVE" - The subscription offer is not available to new users. - // Existing users retain access. - State string `json:"state,omitempty"` - // Targeting: The requirements that users need to fulfil to be eligible for - // this offer. Represents the requirements that Play will evaluate to decide - // whether an offer should be returned. Developers may further filter these - // offers themselves. - Targeting *SubscriptionOfferTargeting `json:"targeting,omitempty"` - - // ServerResponse contains the HTTP response code and headers from the server. - googleapi.ServerResponse `json:"-"` - // ForceSendFields is a list of field names (e.g. "BasePlanId") to +// ScreenDensityTargeting: Targeting based on screen density. +type ScreenDensityTargeting struct { + // Alternatives: Targeting of other sibling directories that were in the + // Bundle. For main splits this is targeting of other main splits. + Alternatives []*ScreenDensity `json:"alternatives,omitempty"` + // Value: Value of a screen density. + Value []*ScreenDensity `json:"value,omitempty"` + // ForceSendFields is a list of field names (e.g. "Alternatives") 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. "BasePlanId") to include in API + // NullFields is a list of field names (e.g. "Alternatives") 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 SubscriptionOffer) MarshalJSON() ([]byte, error) { - type NoMethod SubscriptionOffer +func (s ScreenDensityTargeting) MarshalJSON() ([]byte, error) { + type NoMethod ScreenDensityTargeting return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// SubscriptionOfferPhase: A single phase of a subscription offer. -type SubscriptionOfferPhase struct { - // Duration: Required. The duration of a single recurrence of this phase. - // Specified in ISO 8601 format. - Duration string `json:"duration,omitempty"` - // OtherRegionsConfig: Pricing information for any new locations Play may - // launch in. - OtherRegionsConfig *OtherRegionsSubscriptionOfferPhaseConfig `json:"otherRegionsConfig,omitempty"` - // RecurrenceCount: Required. The number of times this phase repeats. If this - // offer phase is not free, each recurrence charges the user the price of this - // offer phase. - RecurrenceCount int64 `json:"recurrenceCount,omitempty"` - // RegionalConfigs: Required. The region-specific configuration of this offer - // phase. This list must contain exactly one entry for each region for which - // the subscription offer has a regional config. - RegionalConfigs []*RegionalSubscriptionOfferPhaseConfig `json:"regionalConfigs,omitempty"` - // ForceSendFields is a list of field names (e.g. "Duration") to - // unconditionally include in API requests. By default, fields with empty or - // default values are omitted from API requests. See +// SdkVersion: Represents an sdk version. +type SdkVersion struct { + // Min: Inclusive minimum value of an sdk version. + Min int64 `json:"min,omitempty"` + // ForceSendFields is a list of field names (e.g. "Min") 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. "Duration") 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. "Min") 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 SubscriptionOfferPhase) MarshalJSON() ([]byte, error) { - type NoMethod SubscriptionOfferPhase +func (s SdkVersion) MarshalJSON() ([]byte, error) { + type NoMethod SdkVersion return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// SubscriptionOfferTargeting: Defines the rule a user needs to satisfy to -// receive this offer. -type SubscriptionOfferTargeting struct { - // AcquisitionRule: Offer targeting rule for new user acquisition. - AcquisitionRule *AcquisitionTargetingRule `json:"acquisitionRule,omitempty"` - // UpgradeRule: Offer targeting rule for upgrading users' existing plans. - UpgradeRule *UpgradeTargetingRule `json:"upgradeRule,omitempty"` - // ForceSendFields is a list of field names (e.g. "AcquisitionRule") to +// SdkVersionTargeting: Targeting based on sdk version. +type SdkVersionTargeting struct { + // Alternatives: Targeting of other sibling directories that were in the + // Bundle. For main splits this is targeting of other main splits. + Alternatives []*SdkVersion `json:"alternatives,omitempty"` + // Value: Value of an sdk version. + Value []*SdkVersion `json:"value,omitempty"` + // ForceSendFields is a list of field names (e.g. "Alternatives") 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. "AcquisitionRule") 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. "Alternatives") 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 SubscriptionOfferTargeting) MarshalJSON() ([]byte, error) { - type NoMethod SubscriptionOfferTargeting +func (s SdkVersionTargeting) MarshalJSON() ([]byte, error) { + type NoMethod SdkVersionTargeting return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// SubscriptionPriceChange: Contains the price change information for a -// subscription that can be used to control the user journey for the price -// change in the app. This can be in the form of seeking confirmation from the -// user or tailoring the experience for a successful conversion. -type SubscriptionPriceChange struct { - // NewPrice: The new price the subscription will renew with if the price change - // is accepted by the user. - NewPrice *Price `json:"newPrice,omitempty"` - // State: The current state of the price change. Possible values are: 0. - // Outstanding: State for a pending price change waiting for the user to agree. - // In this state, you can optionally seek confirmation from the user using the - // In-App API. 1. Accepted: State for an accepted price change that the - // subscription will renew with unless it's canceled. The price change takes - // effect on a future date when the subscription renews. Note that the change - // might not occur when the subscription is renewed next. - State int64 `json:"state,omitempty"` - // ForceSendFields is a list of field names (e.g. "NewPrice") to +// SignupPromotion: The promotion applied on this item when purchased. +type SignupPromotion struct { + // OneTimeCode: A one-time code was applied. + OneTimeCode *OneTimeCode `json:"oneTimeCode,omitempty"` + // VanityCode: A vanity code was applied. + VanityCode *VanityCode `json:"vanityCode,omitempty"` + // ForceSendFields is a list of field names (e.g. "OneTimeCode") 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. "NewPrice") to include in API + // NullFields is a list of field names (e.g. "OneTimeCode") 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 SubscriptionPriceChange) MarshalJSON() ([]byte, error) { - type NoMethod SubscriptionPriceChange +func (s SignupPromotion) MarshalJSON() ([]byte, error) { + type NoMethod SignupPromotion return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// SubscriptionPurchase: A SubscriptionPurchase resource indicates the status -// of a user's subscription purchase. -type SubscriptionPurchase struct { - // AcknowledgementState: The acknowledgement state of the subscription product. - // Possible values are: 0. Yet to be acknowledged 1. Acknowledged - AcknowledgementState int64 `json:"acknowledgementState,omitempty"` - // AutoRenewing: Whether the subscription will automatically be renewed when it - // reaches its current expiry time. - AutoRenewing bool `json:"autoRenewing,omitempty"` - // AutoResumeTimeMillis: Time at which the subscription will be automatically - // resumed, in milliseconds since the Epoch. Only present if the user has - // requested to pause the subscription. - AutoResumeTimeMillis int64 `json:"autoResumeTimeMillis,omitempty,string"` - // CancelReason: The reason why a subscription was canceled or is not - // auto-renewing. Possible values are: 0. User canceled the subscription 1. - // Subscription was canceled by the system, for example because of a billing - // problem 2. Subscription was replaced with a new subscription 3. Subscription - // was canceled by the developer - CancelReason int64 `json:"cancelReason,omitempty"` - // CancelSurveyResult: Information provided by the user when they complete the - // subscription cancellation flow (cancellation reason survey). - CancelSurveyResult *SubscriptionCancelSurveyResult `json:"cancelSurveyResult,omitempty"` - // CountryCode: ISO 3166-1 alpha-2 billing country/region code of the user at - // the time the subscription was granted. - CountryCode string `json:"countryCode,omitempty"` - // DeveloperPayload: A developer-specified string that contains supplemental - // information about an order. - DeveloperPayload string `json:"developerPayload,omitempty"` +// SplitApkMetadata: Holds data specific to Split APKs. +type SplitApkMetadata struct { + // IsMasterSplit: Indicates whether this APK is the main split of the module. + IsMasterSplit bool `json:"isMasterSplit,omitempty"` + // SplitId: Id of the split. + SplitId string `json:"splitId,omitempty"` + // ForceSendFields is a list of field names (e.g. "IsMasterSplit") 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. "IsMasterSplit") 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 SplitApkMetadata) MarshalJSON() ([]byte, error) { + type NoMethod SplitApkMetadata + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// SplitApkVariant: Variant is a group of APKs that covers a part of the device +// configuration space. APKs from multiple variants are never combined on one +// device. +type SplitApkVariant struct { + // ApkSet: Set of APKs, one set per module. + ApkSet []*ApkSet `json:"apkSet,omitempty"` + // Targeting: Variant-level targeting. + Targeting *VariantTargeting `json:"targeting,omitempty"` + // VariantNumber: Number of the variant, starting at 0 (unless overridden). A + // device will receive APKs from the first variant that matches the device + // configuration, with higher variant numbers having priority over lower + // variant numbers. + VariantNumber int64 `json:"variantNumber,omitempty"` + // ForceSendFields is a list of field names (e.g. "ApkSet") 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. "ApkSet") 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 SplitApkVariant) MarshalJSON() ([]byte, error) { + type NoMethod SplitApkVariant + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// StandaloneApkMetadata: Holds data specific to Standalone APKs. +type StandaloneApkMetadata struct { + // FusedModuleName: Names of the modules fused in this standalone APK. + FusedModuleName []string `json:"fusedModuleName,omitempty"` + // ForceSendFields is a list of field names (e.g. "FusedModuleName") 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. "FusedModuleName") 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 StandaloneApkMetadata) MarshalJSON() ([]byte, error) { + type NoMethod StandaloneApkMetadata + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// SubscribeWithGoogleInfo: Information associated with purchases made with +// 'Subscribe with Google'. +type SubscribeWithGoogleInfo struct { // EmailAddress: The email address of the user when the subscription was - // purchased. Only present for purchases made with 'Subscribe with Google'. + // purchased. EmailAddress string `json:"emailAddress,omitempty"` - // ExpiryTimeMillis: Time at which the subscription will expire, in - // milliseconds since the Epoch. - ExpiryTimeMillis int64 `json:"expiryTimeMillis,omitempty,string"` - // ExternalAccountId: User account identifier in the third-party service. Only - // present if account linking happened as part of the subscription purchase - // flow. - ExternalAccountId string `json:"externalAccountId,omitempty"` // FamilyName: The family name of the user when the subscription was purchased. - // Only present for purchases made with 'Subscribe with Google'. FamilyName string `json:"familyName,omitempty"` // GivenName: The given name of the user when the subscription was purchased. - // Only present for purchases made with 'Subscribe with Google'. GivenName string `json:"givenName,omitempty"` - // IntroductoryPriceInfo: Introductory price information of the subscription. - // This is only present when the subscription was purchased with an - // introductory price. This field does not indicate the subscription is - // currently in introductory price period. - IntroductoryPriceInfo *IntroductoryPriceInfo `json:"introductoryPriceInfo,omitempty"` - // Kind: This kind represents a subscriptionPurchase object in the - // androidpublisher service. - Kind string `json:"kind,omitempty"` - // LinkedPurchaseToken: The purchase token of the originating purchase if this - // subscription is one of the following: 0. Re-signup of a canceled but - // non-lapsed subscription 1. Upgrade/downgrade from a previous subscription - // For example, suppose a user originally signs up and you receive purchase - // token X, then the user cancels and goes through the resignup flow (before - // their subscription lapses) and you receive purchase token Y, and finally the - // user upgrades their subscription and you receive purchase token Z. If you - // call this API with purchase token Z, this field will be set to Y. If you - // call this API with purchase token Y, this field will be set to X. If you - // call this API with purchase token X, this field will not be set. - LinkedPurchaseToken string `json:"linkedPurchaseToken,omitempty"` - // ObfuscatedExternalAccountId: An obfuscated version of the id that is - // uniquely associated with the user's account in your app. Present for the - // following purchases: * If account linking happened as part of the - // subscription purchase flow. * It was specified using - // https://developer.android.com/reference/com/android/billingclient/api/BillingFlowParams.Builder#setobfuscatedaccountid - // when the purchase was made. - ObfuscatedExternalAccountId string `json:"obfuscatedExternalAccountId,omitempty"` - // ObfuscatedExternalProfileId: An obfuscated version of the id that is - // uniquely associated with the user's profile in your app. Only present if - // specified using - // https://developer.android.com/reference/com/android/billingclient/api/BillingFlowParams.Builder#setobfuscatedprofileid - // when the purchase was made. - ObfuscatedExternalProfileId string `json:"obfuscatedExternalProfileId,omitempty"` - // OrderId: The order id of the latest recurring order associated with the - // purchase of the subscription. If the subscription was canceled because - // payment was declined, this will be the order id from the payment declined - // order. - OrderId string `json:"orderId,omitempty"` - // PaymentState: The payment state of the subscription. Possible values are: 0. - // Payment pending 1. Payment received 2. Free trial 3. Pending deferred - // upgrade/downgrade Not present for canceled, expired subscriptions. - PaymentState *int64 `json:"paymentState,omitempty"` - // PriceAmountMicros: Price of the subscription, For tax exclusive countries, - // the price doesn't include tax. For tax inclusive countries, the price - // includes tax. Price is expressed in micro-units, where 1,000,000 micro-units - // represents one unit of the currency. For example, if the subscription price - // is €1.99, price_amount_micros is 1990000. - PriceAmountMicros int64 `json:"priceAmountMicros,omitempty,string"` - // PriceChange: The latest price change information available. This is present - // only when there is an upcoming price change for the subscription yet to be - // applied. Once the subscription renews with the new price or the subscription - // is canceled, no price change information will be returned. - PriceChange *SubscriptionPriceChange `json:"priceChange,omitempty"` - // PriceCurrencyCode: ISO 4217 currency code for the subscription price. For - // example, if the price is specified in British pounds sterling, - // price_currency_code is "GBP". - PriceCurrencyCode string `json:"priceCurrencyCode,omitempty"` // ProfileId: The Google profile id of the user when the subscription was - // purchased. Only present for purchases made with 'Subscribe with Google'. + // purchased. ProfileId string `json:"profileId,omitempty"` // ProfileName: The profile name of the user when the subscription was - // purchased. Only present for purchases made with 'Subscribe with Google'. - ProfileName string `json:"profileName,omitempty"` - // PromotionCode: The promotion code applied on this purchase. This field is - // only set if a vanity code promotion is applied when the subscription was // purchased. - PromotionCode string `json:"promotionCode,omitempty"` - // PromotionType: The type of promotion applied on this purchase. This field is - // only set if a promotion is applied when the subscription was purchased. - // Possible values are: 0. One time code 1. Vanity code - PromotionType int64 `json:"promotionType,omitempty"` - // PurchaseType: The type of purchase of the subscription. This field is only - // set if this purchase was not made using the standard in-app billing flow. - // Possible values are: 0. Test (i.e. purchased from a license testing account) - // 1. Promo (i.e. purchased using a promo code) - PurchaseType *int64 `json:"purchaseType,omitempty"` - // StartTimeMillis: Time at which the subscription was granted, in milliseconds - // since the Epoch. - StartTimeMillis int64 `json:"startTimeMillis,omitempty,string"` - // UserCancellationTimeMillis: The time at which the subscription was canceled - // by the user, in milliseconds since the epoch. Only present if cancelReason - // is 0. - UserCancellationTimeMillis int64 `json:"userCancellationTimeMillis,omitempty,string"` - - // ServerResponse contains the HTTP response code and headers from the server. - googleapi.ServerResponse `json:"-"` - // ForceSendFields is a list of field names (e.g. "AcknowledgementState") to + ProfileName string `json:"profileName,omitempty"` + // ForceSendFields is a list of field names (e.g. "EmailAddress") 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. "AcknowledgementState") 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. "EmailAddress") 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 SubscriptionPurchase) MarshalJSON() ([]byte, error) { - type NoMethod SubscriptionPurchase +func (s SubscribeWithGoogleInfo) MarshalJSON() ([]byte, error) { + type NoMethod SubscribeWithGoogleInfo return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// SubscriptionPurchaseLineItem: Item-level info for a subscription purchase. -type SubscriptionPurchaseLineItem struct { - // AutoRenewingPlan: The item is auto renewing. - AutoRenewingPlan *AutoRenewingPlan `json:"autoRenewingPlan,omitempty"` - // DeferredItemReplacement: Information for deferred item replacement. - DeferredItemReplacement *DeferredItemReplacement `json:"deferredItemReplacement,omitempty"` - // ExpiryTime: Time at which the subscription expired or will expire unless the - // access is extended (ex. renews). - ExpiryTime string `json:"expiryTime,omitempty"` - // LatestSuccessfulOrderId: The order id of the latest successful order - // associated with this item. Not present if the item is not owned by the user - // yet (e.g. the item being deferred replaced to). - LatestSuccessfulOrderId string `json:"latestSuccessfulOrderId,omitempty"` - // OfferDetails: The offer details for this item. - OfferDetails *OfferDetails `json:"offerDetails,omitempty"` - // PrepaidPlan: The item is prepaid. - PrepaidPlan *PrepaidPlan `json:"prepaidPlan,omitempty"` - // ProductId: The purchased product ID (for example, 'monthly001'). +// Subscription: A single subscription for an app. +type Subscription struct { + // Archived: Output only. Deprecated: subscription archiving is not supported. + Archived bool `json:"archived,omitempty"` + // BasePlans: The set of base plans for this subscription. Represents the + // prices and duration of the subscription if no other offers apply. + BasePlans []*BasePlan `json:"basePlans,omitempty"` + // Listings: Required. List of localized listings for this subscription. Must + // contain at least an entry for the default language of the parent app. + Listings []*SubscriptionListing `json:"listings,omitempty"` + // PackageName: Immutable. Package name of the parent app. + PackageName string `json:"packageName,omitempty"` + // ProductId: Immutable. Unique product ID of the product. Unique within the + // parent app. Product IDs must be composed of lower-case letters (a-z), + // numbers (0-9), underscores (_) and dots (.). It must start with a lower-case + // letter or number, and be between 1 and 40 (inclusive) characters in length. ProductId string `json:"productId,omitempty"` - // SignupPromotion: Promotion details about this item. Only set if a promotion - // was applied during signup. - SignupPromotion *SignupPromotion `json:"signupPromotion,omitempty"` - // ForceSendFields is a list of field names (e.g. "AutoRenewingPlan") to + // RestrictedPaymentCountries: Optional. Countries where the purchase of this + // subscription is restricted to payment methods registered in the same + // country. If empty, no payment location restrictions are imposed. + RestrictedPaymentCountries *RestrictedPaymentCountries `json:"restrictedPaymentCountries,omitempty"` + // TaxAndComplianceSettings: Details about taxes and legal compliance. + TaxAndComplianceSettings *SubscriptionTaxAndComplianceSettings `json:"taxAndComplianceSettings,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the server. + googleapi.ServerResponse `json:"-"` + // ForceSendFields is a list of field names (e.g. "Archived") 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. "AutoRenewingPlan") 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. "Archived") 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 SubscriptionPurchaseLineItem) MarshalJSON() ([]byte, error) { - type NoMethod SubscriptionPurchaseLineItem +func (s Subscription) MarshalJSON() ([]byte, error) { + type NoMethod Subscription return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// SubscriptionPurchaseV2: Indicates the status of a user's subscription -// purchase. -type SubscriptionPurchaseV2 struct { - // AcknowledgementState: The acknowledgement state of the subscription. - // - // Possible values: - // "ACKNOWLEDGEMENT_STATE_UNSPECIFIED" - Unspecified acknowledgement state. - // "ACKNOWLEDGEMENT_STATE_PENDING" - The subscription is not acknowledged - // yet. - // "ACKNOWLEDGEMENT_STATE_ACKNOWLEDGED" - The subscription is acknowledged. - AcknowledgementState string `json:"acknowledgementState,omitempty"` - // CanceledStateContext: Additional context around canceled subscriptions. Only - // present if the subscription currently has subscription_state - // SUBSCRIPTION_STATE_CANCELED or SUBSCRIPTION_STATE_EXPIRED. - CanceledStateContext *CanceledStateContext `json:"canceledStateContext,omitempty"` - // ExternalAccountIdentifiers: User account identifier in the third-party - // service. - ExternalAccountIdentifiers *ExternalAccountIdentifiers `json:"externalAccountIdentifiers,omitempty"` - // Kind: This kind represents a SubscriptionPurchaseV2 object in the - // androidpublisher service. - Kind string `json:"kind,omitempty"` - // LatestOrderId: Deprecated: Use line_items.latest_successful_order_id - // instead. The order id of the latest order associated with the purchase of - // the subscription. For autoRenewing subscription, this is the order id of - // signup order if it is not renewed yet, or the last recurring order id - // (success, pending, or declined order). For prepaid subscription, this is the - // order id associated with the queried purchase token. - LatestOrderId string `json:"latestOrderId,omitempty"` - // LineItems: Item-level info for a subscription purchase. The items in the - // same purchase should be either all with AutoRenewingPlan or all with - // PrepaidPlan. - LineItems []*SubscriptionPurchaseLineItem `json:"lineItems,omitempty"` - // LinkedPurchaseToken: The purchase token of the old subscription if this - // subscription is one of the following: * Re-signup of a canceled but - // non-lapsed subscription * Upgrade/downgrade from a previous subscription. * - // Convert from prepaid to auto renewing subscription. * Convert from an auto - // renewing subscription to prepaid. * Topup a prepaid subscription. - LinkedPurchaseToken string `json:"linkedPurchaseToken,omitempty"` - // PausedStateContext: Additional context around paused subscriptions. Only - // present if the subscription currently has subscription_state - // SUBSCRIPTION_STATE_PAUSED. - PausedStateContext *PausedStateContext `json:"pausedStateContext,omitempty"` - // RegionCode: ISO 3166-1 alpha-2 billing country/region code of the user at - // the time the subscription was granted. - RegionCode string `json:"regionCode,omitempty"` - // StartTime: Time at which the subscription was granted. Not set for pending - // subscriptions (subscription was created but awaiting payment during signup). - StartTime string `json:"startTime,omitempty"` - // SubscribeWithGoogleInfo: User profile associated with purchases made with - // 'Subscribe with Google'. - SubscribeWithGoogleInfo *SubscribeWithGoogleInfo `json:"subscribeWithGoogleInfo,omitempty"` - // SubscriptionState: The current state of the subscription. - // - // Possible values: - // "SUBSCRIPTION_STATE_UNSPECIFIED" - Unspecified subscription state. - // "SUBSCRIPTION_STATE_PENDING" - Subscription was created but awaiting - // payment during signup. In this state, all items are awaiting payment. - // "SUBSCRIPTION_STATE_ACTIVE" - Subscription is active. - (1) If the - // subscription is an auto renewing plan, at least one item is - // auto_renew_enabled and not expired. - (2) If the subscription is a prepaid - // plan, at least one item is not expired. - // "SUBSCRIPTION_STATE_PAUSED" - Subscription is paused. The state is only - // available when the subscription is an auto renewing plan. In this state, all - // items are in paused state. - // "SUBSCRIPTION_STATE_IN_GRACE_PERIOD" - Subscription is in grace period. - // The state is only available when the subscription is an auto renewing plan. - // In this state, all items are in grace period. - // "SUBSCRIPTION_STATE_ON_HOLD" - Subscription is on hold (suspended). The - // state is only available when the subscription is an auto renewing plan. In - // this state, all items are on hold. - // "SUBSCRIPTION_STATE_CANCELED" - Subscription is canceled but not expired - // yet. The state is only available when the subscription is an auto renewing - // plan. All items have auto_renew_enabled set to false. - // "SUBSCRIPTION_STATE_EXPIRED" - Subscription is expired. All items have - // expiry_time in the past. - // "SUBSCRIPTION_STATE_PENDING_PURCHASE_CANCELED" - Pending transaction for - // subscription is canceled. If this pending purchase was for an existing - // subscription, use linked_purchase_token to get the current state of that - // subscription. - SubscriptionState string `json:"subscriptionState,omitempty"` - // TestPurchase: Only present if this subscription purchase is a test purchase. - TestPurchase *TestPurchase `json:"testPurchase,omitempty"` - - // ServerResponse contains the HTTP response code and headers from the server. - googleapi.ServerResponse `json:"-"` - // ForceSendFields is a list of field names (e.g. "AcknowledgementState") to +// SubscriptionCancelSurveyResult: Information provided by the user when they +// complete the subscription cancellation flow (cancellation reason survey). +type SubscriptionCancelSurveyResult struct { + // CancelSurveyReason: The cancellation reason the user chose in the survey. + // Possible values are: 0. Other 1. I don't use this service enough 2. + // Technical issues 3. Cost-related reasons 4. I found a better app + CancelSurveyReason int64 `json:"cancelSurveyReason,omitempty"` + // UserInputCancelReason: The customized input cancel reason from the user. + // Only present when cancelReason is 0. + UserInputCancelReason string `json:"userInputCancelReason,omitempty"` + // ForceSendFields is a list of field names (e.g. "CancelSurveyReason") 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. "AcknowledgementState") to include + // NullFields is a list of field names (e.g. "CancelSurveyReason") 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 SubscriptionPurchaseV2) MarshalJSON() ([]byte, error) { - type NoMethod SubscriptionPurchaseV2 +func (s SubscriptionCancelSurveyResult) MarshalJSON() ([]byte, error) { + type NoMethod SubscriptionCancelSurveyResult return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// SubscriptionPurchasesAcknowledgeRequest: Request for the -// purchases.subscriptions.acknowledge API. -type SubscriptionPurchasesAcknowledgeRequest struct { - // DeveloperPayload: Payload to attach to the purchase. - DeveloperPayload string `json:"developerPayload,omitempty"` - // ForceSendFields is a list of field names (e.g. "DeveloperPayload") to +// SubscriptionDeferralInfo: A SubscriptionDeferralInfo contains the data +// needed to defer a subscription purchase to a future expiry time. +type SubscriptionDeferralInfo struct { + // DesiredExpiryTimeMillis: The desired next expiry time to assign to the + // subscription, in milliseconds since the Epoch. The given time must be + // later/greater than the current expiry time for the subscription. + DesiredExpiryTimeMillis int64 `json:"desiredExpiryTimeMillis,omitempty,string"` + // ExpectedExpiryTimeMillis: The expected expiry time for the subscription. If + // the current expiry time for the subscription is not the value specified + // here, the deferral will not occur. + ExpectedExpiryTimeMillis int64 `json:"expectedExpiryTimeMillis,omitempty,string"` + // ForceSendFields is a list of field names (e.g. "DesiredExpiryTimeMillis") 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. "DeveloperPayload") 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. "DesiredExpiryTimeMillis") 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 SubscriptionPurchasesAcknowledgeRequest) MarshalJSON() ([]byte, error) { - type NoMethod SubscriptionPurchasesAcknowledgeRequest +func (s SubscriptionDeferralInfo) MarshalJSON() ([]byte, error) { + type NoMethod SubscriptionDeferralInfo return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// SubscriptionPurchasesDeferRequest: Request for the -// purchases.subscriptions.defer API. -type SubscriptionPurchasesDeferRequest struct { - // DeferralInfo: The information about the new desired expiry time for the - // subscription. - DeferralInfo *SubscriptionDeferralInfo `json:"deferralInfo,omitempty"` - // ForceSendFields is a list of field names (e.g. "DeferralInfo") to +// SubscriptionDetails: Details of a subscription purchase. +type SubscriptionDetails struct { + // BasePlanId: The base plan ID of the subscription. + BasePlanId string `json:"basePlanId,omitempty"` + // OfferId: The offer ID for the current subscription offer. + OfferId string `json:"offerId,omitempty"` + // OfferPhase: The pricing phase for the billing period funded by this order. + // + // Possible values: + // "OFFER_PHASE_UNSPECIFIED" - Offer phase unspecified. This value is not + // used. + // "BASE" - The order funds a base price period. + // "INTRODUCTORY" - The order funds an introductory pricing period. + // "FREE_TRIAL" - The order funds a free trial period. + OfferPhase string `json:"offerPhase,omitempty"` + // ServicePeriodEndTime: The end of the billing period funded by this order. + // This is a snapshot of the billing/service period end time at the moment the + // order was processed, and should be used only for accounting. To get the + // current end time of the subscription service period, use + // purchases.subscriptionsv2.get. + ServicePeriodEndTime string `json:"servicePeriodEndTime,omitempty"` + // ServicePeriodStartTime: The start of the billing period funded by this + // order. This is a snapshot of the billing/service period start time at the + // moment the order was processed, and should be used only for accounting. + ServicePeriodStartTime string `json:"servicePeriodStartTime,omitempty"` + // ForceSendFields is a list of field names (e.g. "BasePlanId") 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. "DeferralInfo") to include in API + // NullFields is a list of field names (e.g. "BasePlanId") 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 SubscriptionPurchasesDeferRequest) MarshalJSON() ([]byte, error) { - type NoMethod SubscriptionPurchasesDeferRequest +func (s SubscriptionDetails) MarshalJSON() ([]byte, error) { + type NoMethod SubscriptionDetails return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// SubscriptionPurchasesDeferResponse: Response for the -// purchases.subscriptions.defer API. -type SubscriptionPurchasesDeferResponse struct { - // NewExpiryTimeMillis: The new expiry time for the subscription in - // milliseconds since the Epoch. - NewExpiryTimeMillis int64 `json:"newExpiryTimeMillis,omitempty,string"` - - // ServerResponse contains the HTTP response code and headers from the server. - googleapi.ServerResponse `json:"-"` - // ForceSendFields is a list of field names (e.g. "NewExpiryTimeMillis") to - // unconditionally include in API requests. By default, fields with empty or +// SubscriptionItemPriceChangeDetails: Price change related information of a +// subscription item. +type SubscriptionItemPriceChangeDetails struct { + // ExpectedNewPriceChargeTime: The renewal time at which the price change will + // become effective for the user. This is subject to change(to a future time) + // due to cases where the renewal time shifts like pause. This field is only + // populated if the price change has not taken effect. + ExpectedNewPriceChargeTime string `json:"expectedNewPriceChargeTime,omitempty"` + // NewPrice: New recurring price for the subscription item. + NewPrice *Money `json:"newPrice,omitempty"` + // PriceChangeMode: Price change mode specifies how the subscription item price + // is changing. + // + // Possible values: + // "PRICE_CHANGE_MODE_UNSPECIFIED" - Price change mode unspecified. This + // value should never be set. + // "PRICE_DECREASE" - If the subscription price is decreasing. + // "PRICE_INCREASE" - If the subscription price is increasing and the user + // needs to accept it. + // "OPT_OUT_PRICE_INCREASE" - If the subscription price is increasing with + // opt out mode. + PriceChangeMode string `json:"priceChangeMode,omitempty"` + // PriceChangeState: State the price change is currently in. + // + // Possible values: + // "PRICE_CHANGE_STATE_UNSPECIFIED" - Price change state unspecified. This + // value should not be used. + // "OUTSTANDING" - Waiting for the user to agree for the price change. + // "CONFIRMED" - The price change is confirmed to happen for the user. + // "APPLIED" - The price change is applied, i.e. the user has started being + // charged the new price. + // "CANCELED" - The price change was canceled. + PriceChangeState string `json:"priceChangeState,omitempty"` + // ForceSendFields is a list of field names (e.g. "ExpectedNewPriceChargeTime") + // 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. "NewExpiryTimeMillis") 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. "ExpectedNewPriceChargeTime") 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 SubscriptionPurchasesDeferResponse) MarshalJSON() ([]byte, error) { - type NoMethod SubscriptionPurchasesDeferResponse +func (s SubscriptionItemPriceChangeDetails) MarshalJSON() ([]byte, error) { + type NoMethod SubscriptionItemPriceChangeDetails return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// SubscriptionTaxAndComplianceSettings: Details about taxation, Google Play -// policy, and legal compliance for subscription products. -type SubscriptionTaxAndComplianceSettings struct { - // EeaWithdrawalRightType: Digital content or service classification for - // products distributed to users in the European Economic Area (EEA). The - // withdrawal regime under EEA consumer laws depends on this classification. - // Refer to the Help Center article - // (https://support.google.com/googleplay/android-developer/answer/10463498) - // for more information. - // - // Possible values: - // "WITHDRAWAL_RIGHT_TYPE_UNSPECIFIED" - // "WITHDRAWAL_RIGHT_DIGITAL_CONTENT" - // "WITHDRAWAL_RIGHT_SERVICE" - EeaWithdrawalRightType string `json:"eeaWithdrawalRightType,omitempty"` - // IsTokenizedDigitalAsset: Whether this subscription is declared as a product - // representing a tokenized digital asset. - IsTokenizedDigitalAsset bool `json:"isTokenizedDigitalAsset,omitempty"` - // TaxRateInfoByRegionCode: A mapping from region code to tax rate details. The - // keys are region codes as defined by Unicode's "CLDR". - TaxRateInfoByRegionCode map[string]RegionalTaxRateInfo `json:"taxRateInfoByRegionCode,omitempty"` - // ForceSendFields is a list of field names (e.g. "EeaWithdrawalRightType") to +// SubscriptionListing: The consumer-visible metadata of a subscription. +type SubscriptionListing struct { + // Benefits: A list of benefits shown to the user on platforms such as the Play + // Store and in restoration flows in the language of this listing. Plain text. + // Ordered list of at most four benefits. + Benefits []string `json:"benefits,omitempty"` + // Description: The description of this subscription in the language of this + // listing. Maximum length - 80 characters. Plain text. + Description string `json:"description,omitempty"` + // LanguageCode: Required. The language of this listing, as defined by BCP-47, + // e.g. "en-US". + LanguageCode string `json:"languageCode,omitempty"` + // Title: Required. The title of this subscription in the language of this + // listing. Plain text. + Title string `json:"title,omitempty"` + // ForceSendFields is a list of field names (e.g. "Benefits") 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. "EeaWithdrawalRightType") 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 SubscriptionTaxAndComplianceSettings) MarshalJSON() ([]byte, error) { - type NoMethod SubscriptionTaxAndComplianceSettings - return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) -} - -// SystemApkOptions: Options for system APKs. -type SystemApkOptions struct { - // Rotated: Whether to use the rotated key for signing the system APK. - Rotated bool `json:"rotated,omitempty"` - // UncompressedDexFiles: Whether system APK was generated with uncompressed dex - // files. - UncompressedDexFiles bool `json:"uncompressedDexFiles,omitempty"` - // UncompressedNativeLibraries: Whether system APK was generated with - // uncompressed native libraries. - UncompressedNativeLibraries bool `json:"uncompressedNativeLibraries,omitempty"` - // ForceSendFields is a list of field names (e.g. "Rotated") 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. "Rotated") to include in API + // NullFields is a list of field names (e.g. "Benefits") 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 SystemApkOptions) MarshalJSON() ([]byte, error) { - type NoMethod SystemApkOptions +func (s SubscriptionListing) MarshalJSON() ([]byte, error) { + type NoMethod SubscriptionListing return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// SystemApksListResponse: Response to list previously created system APK -// variants. -type SystemApksListResponse struct { - // Variants: All system APK variants created. - Variants []*Variant `json:"variants,omitempty"` +// SubscriptionOffer: A single, temporary offer +type SubscriptionOffer struct { + // BasePlanId: Required. Immutable. The ID of the base plan to which this offer + // is an extension. + BasePlanId string `json:"basePlanId,omitempty"` + // OfferId: Required. Immutable. Unique ID of this subscription offer. Must be + // unique within the base plan. + OfferId string `json:"offerId,omitempty"` + // OfferTags: List of up to 20 custom tags specified for this offer, and + // returned to the app through the billing library. + OfferTags []*OfferTag `json:"offerTags,omitempty"` + // OtherRegionsConfig: The configuration for any new locations Play may launch + // in the future. + OtherRegionsConfig *OtherRegionsSubscriptionOfferConfig `json:"otherRegionsConfig,omitempty"` + // PackageName: Required. Immutable. The package name of the app the parent + // subscription belongs to. + PackageName string `json:"packageName,omitempty"` + // Phases: Required. The phases of this subscription offer. Must contain at + // least one and at most two entries. Users will always receive all these + // phases in the specified order. + Phases []*SubscriptionOfferPhase `json:"phases,omitempty"` + // ProductId: Required. Immutable. The ID of the parent subscription this offer + // belongs to. + ProductId string `json:"productId,omitempty"` + // RegionalConfigs: Required. The region-specific configuration of this offer. + // Must contain at least one entry. + RegionalConfigs []*RegionalSubscriptionOfferConfig `json:"regionalConfigs,omitempty"` + // State: Output only. The current state of this offer. Can be changed using + // Activate and Deactivate actions. NB: the base plan state supersedes this + // state, so an active offer may not be available if the base plan is not + // active. + // + // Possible values: + // "STATE_UNSPECIFIED" - Default value, should never be used. + // "DRAFT" - The subscription offer is not and has never been available to + // users. + // "ACTIVE" - The subscription offer is available to new and existing users. + // "INACTIVE" - The subscription offer is not available to new users. + // Existing users retain access. + State string `json:"state,omitempty"` + // Targeting: The requirements that users need to fulfil to be eligible for + // this offer. Represents the requirements that Play will evaluate to decide + // whether an offer should be returned. Developers may further filter these + // offers themselves. + Targeting *SubscriptionOfferTargeting `json:"targeting,omitempty"` // ServerResponse contains the HTTP response code and headers from the server. googleapi.ServerResponse `json:"-"` - // ForceSendFields is a list of field names (e.g. "Variants") to + // ForceSendFields is a list of field names (e.g. "BasePlanId") 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. "Variants") to include in API + // NullFields is a list of field names (e.g. "BasePlanId") 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 SystemApksListResponse) MarshalJSON() ([]byte, error) { - type NoMethod SystemApksListResponse - return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) -} - -// SystemFeature: Representation of a system feature. -type SystemFeature struct { - // Name: The name of the feature. - 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. "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 SystemFeature) MarshalJSON() ([]byte, error) { - type NoMethod SystemFeature +func (s SubscriptionOffer) MarshalJSON() ([]byte, error) { + type NoMethod SubscriptionOffer return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// SystemInitiatedCancellation: Information specific to cancellations initiated -// by Google system. -type SystemInitiatedCancellation struct { -} - -// SystemOnChip: Representation of a System-on-Chip (SoC) of an Android device. -// Can be used to target S+ devices. -type SystemOnChip struct { - // Manufacturer: Required. The designer of the SoC, eg. "Google" Value of build - // property "ro.soc.manufacturer" - // https://developer.android.com/reference/android/os/Build#SOC_MANUFACTURER - // Required. - Manufacturer string `json:"manufacturer,omitempty"` - // Model: Required. The model of the SoC, eg. "Tensor" Value of build property - // "ro.soc.model" - // https://developer.android.com/reference/android/os/Build#SOC_MODEL Required. - Model string `json:"model,omitempty"` - // ForceSendFields is a list of field names (e.g. "Manufacturer") to +// SubscriptionOfferPhase: A single phase of a subscription offer. +type SubscriptionOfferPhase struct { + // Duration: Required. The duration of a single recurrence of this phase. + // Specified in ISO 8601 format. + Duration string `json:"duration,omitempty"` + // OtherRegionsConfig: Pricing information for any new locations Play may + // launch in. + OtherRegionsConfig *OtherRegionsSubscriptionOfferPhaseConfig `json:"otherRegionsConfig,omitempty"` + // RecurrenceCount: Required. The number of times this phase repeats. If this + // offer phase is not free, each recurrence charges the user the price of this + // offer phase. + RecurrenceCount int64 `json:"recurrenceCount,omitempty"` + // RegionalConfigs: Required. The region-specific configuration of this offer + // phase. This list must contain exactly one entry for each region for which + // the subscription offer has a regional config. + RegionalConfigs []*RegionalSubscriptionOfferPhaseConfig `json:"regionalConfigs,omitempty"` + // ForceSendFields is a list of field names (e.g. "Duration") 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. "Manufacturer") to include in API + // NullFields is a list of field names (e.g. "Duration") 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 SystemOnChip) MarshalJSON() ([]byte, error) { - type NoMethod SystemOnChip +func (s SubscriptionOfferPhase) MarshalJSON() ([]byte, error) { + type NoMethod SubscriptionOfferPhase return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// Targeting: Targeting details for a recovery action such as regions, android -// sdk levels, app versions etc. -type Targeting struct { - // AllUsers: All users are targeted. - AllUsers *AllUsers `json:"allUsers,omitempty"` - // AndroidSdks: Targeting is based on android api levels of devices. - AndroidSdks *AndroidSdks `json:"androidSdks,omitempty"` - // Regions: Targeting is based on the user account region. - Regions *Regions `json:"regions,omitempty"` - // VersionList: Target version codes as a list. - VersionList *AppVersionList `json:"versionList,omitempty"` - // VersionRange: Target version codes as a range. - VersionRange *AppVersionRange `json:"versionRange,omitempty"` - // ForceSendFields is a list of field names (e.g. "AllUsers") to +// SubscriptionOfferTargeting: Defines the rule a user needs to satisfy to +// receive this offer. +type SubscriptionOfferTargeting struct { + // AcquisitionRule: Offer targeting rule for new user acquisition. + AcquisitionRule *AcquisitionTargetingRule `json:"acquisitionRule,omitempty"` + // UpgradeRule: Offer targeting rule for upgrading users' existing plans. + UpgradeRule *UpgradeTargetingRule `json:"upgradeRule,omitempty"` + // ForceSendFields is a list of field names (e.g. "AcquisitionRule") 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. "AllUsers") 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. "AcquisitionRule") 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 Targeting) MarshalJSON() ([]byte, error) { - type NoMethod Targeting +func (s SubscriptionOfferTargeting) MarshalJSON() ([]byte, error) { + type NoMethod SubscriptionOfferTargeting return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// TargetingInfo: Targeting information about the generated apks. -type TargetingInfo struct { - // AssetSliceSet: List of created asset slices. - AssetSliceSet []*AssetSliceSet `json:"assetSliceSet,omitempty"` - // PackageName: The package name of this app. - PackageName string `json:"packageName,omitempty"` - // Variant: List of the created variants. - Variant []*SplitApkVariant `json:"variant,omitempty"` - // ForceSendFields is a list of field names (e.g. "AssetSliceSet") to +// SubscriptionPriceChange: Contains the price change information for a +// subscription that can be used to control the user journey for the price +// change in the app. This can be in the form of seeking confirmation from the +// user or tailoring the experience for a successful conversion. +type SubscriptionPriceChange struct { + // NewPrice: The new price the subscription will renew with if the price change + // is accepted by the user. + NewPrice *Price `json:"newPrice,omitempty"` + // State: The current state of the price change. Possible values are: 0. + // Outstanding: State for a pending price change waiting for the user to agree. + // In this state, you can optionally seek confirmation from the user using the + // In-App API. 1. Accepted: State for an accepted price change that the + // subscription will renew with unless it's canceled. The price change takes + // effect on a future date when the subscription renews. Note that the change + // might not occur when the subscription is renewed next. + State int64 `json:"state,omitempty"` + // ForceSendFields is a list of field names (e.g. "NewPrice") 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. "AssetSliceSet") to include in API + // NullFields is a list of field names (e.g. "NewPrice") 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 TargetingInfo) MarshalJSON() ([]byte, error) { - type NoMethod TargetingInfo +func (s SubscriptionPriceChange) MarshalJSON() ([]byte, error) { + type NoMethod SubscriptionPriceChange return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// TargetingRuleScope: Defines the scope of subscriptions which a targeting -// rule can match to target offers to users based on past or current -// entitlement. -type TargetingRuleScope struct { - // AnySubscriptionInApp: The scope of the current targeting rule is any - // subscription in the parent app. - AnySubscriptionInApp *TargetingRuleScopeAnySubscriptionInApp `json:"anySubscriptionInApp,omitempty"` - // SpecificSubscriptionInApp: The scope of the current targeting rule is the - // subscription with the specified subscription ID. Must be a subscription - // within the same parent app. - SpecificSubscriptionInApp string `json:"specificSubscriptionInApp,omitempty"` - // ThisSubscription: The scope of the current targeting rule is the - // subscription in which this offer is defined. - ThisSubscription *TargetingRuleScopeThisSubscription `json:"thisSubscription,omitempty"` - // ForceSendFields is a list of field names (e.g. "AnySubscriptionInApp") 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. "AnySubscriptionInApp") 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 TargetingRuleScope) MarshalJSON() ([]byte, error) { - type NoMethod TargetingRuleScope - return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) -} - -// TargetingRuleScopeAnySubscriptionInApp: Represents the targeting rule scope -// corresponding to any subscription in the parent app. -type TargetingRuleScopeAnySubscriptionInApp struct { -} - -// TargetingRuleScopeThisSubscription: Represents the targeting rule scope -// corresponding to the subscriptions in which this offer is defined. -type TargetingRuleScopeThisSubscription struct { -} +// SubscriptionPurchase: A SubscriptionPurchase resource indicates the status +// of a user's subscription purchase. +type SubscriptionPurchase struct { + // AcknowledgementState: The acknowledgement state of the subscription product. + // Possible values are: 0. Yet to be acknowledged 1. Acknowledged + AcknowledgementState int64 `json:"acknowledgementState,omitempty"` + // AutoRenewing: Whether the subscription will automatically be renewed when it + // reaches its current expiry time. + AutoRenewing bool `json:"autoRenewing,omitempty"` + // AutoResumeTimeMillis: Time at which the subscription will be automatically + // resumed, in milliseconds since the Epoch. Only present if the user has + // requested to pause the subscription. + AutoResumeTimeMillis int64 `json:"autoResumeTimeMillis,omitempty,string"` + // CancelReason: The reason why a subscription was canceled or is not + // auto-renewing. Possible values are: 0. User canceled the subscription 1. + // Subscription was canceled by the system, for example because of a billing + // problem 2. Subscription was replaced with a new subscription 3. Subscription + // was canceled by the developer + CancelReason int64 `json:"cancelReason,omitempty"` + // CancelSurveyResult: Information provided by the user when they complete the + // subscription cancellation flow (cancellation reason survey). + CancelSurveyResult *SubscriptionCancelSurveyResult `json:"cancelSurveyResult,omitempty"` + // CountryCode: ISO 3166-1 alpha-2 billing country/region code of the user at + // the time the subscription was granted. + CountryCode string `json:"countryCode,omitempty"` + // DeveloperPayload: A developer-specified string that contains supplemental + // information about an order. + DeveloperPayload string `json:"developerPayload,omitempty"` + // EmailAddress: The email address of the user when the subscription was + // purchased. Only present for purchases made with 'Subscribe with Google'. + EmailAddress string `json:"emailAddress,omitempty"` + // ExpiryTimeMillis: Time at which the subscription will expire, in + // milliseconds since the Epoch. + ExpiryTimeMillis int64 `json:"expiryTimeMillis,omitempty,string"` + // ExternalAccountId: User account identifier in the third-party service. Only + // present if account linking happened as part of the subscription purchase + // flow. + ExternalAccountId string `json:"externalAccountId,omitempty"` + // FamilyName: The family name of the user when the subscription was purchased. + // Only present for purchases made with 'Subscribe with Google'. + FamilyName string `json:"familyName,omitempty"` + // GivenName: The given name of the user when the subscription was purchased. + // Only present for purchases made with 'Subscribe with Google'. + GivenName string `json:"givenName,omitempty"` + // IntroductoryPriceInfo: Introductory price information of the subscription. + // This is only present when the subscription was purchased with an + // introductory price. This field does not indicate the subscription is + // currently in introductory price period. + IntroductoryPriceInfo *IntroductoryPriceInfo `json:"introductoryPriceInfo,omitempty"` + // Kind: This kind represents a subscriptionPurchase object in the + // androidpublisher service. + Kind string `json:"kind,omitempty"` + // LinkedPurchaseToken: The purchase token of the originating purchase if this + // subscription is one of the following: 0. Re-signup of a canceled but + // non-lapsed subscription 1. Upgrade/downgrade from a previous subscription + // For example, suppose a user originally signs up and you receive purchase + // token X, then the user cancels and goes through the resignup flow (before + // their subscription lapses) and you receive purchase token Y, and finally the + // user upgrades their subscription and you receive purchase token Z. If you + // call this API with purchase token Z, this field will be set to Y. If you + // call this API with purchase token Y, this field will be set to X. If you + // call this API with purchase token X, this field will not be set. + LinkedPurchaseToken string `json:"linkedPurchaseToken,omitempty"` + // ObfuscatedExternalAccountId: An obfuscated version of the id that is + // uniquely associated with the user's account in your app. Present for the + // following purchases: * If account linking happened as part of the + // subscription purchase flow. * It was specified using + // https://developer.android.com/reference/com/android/billingclient/api/BillingFlowParams.Builder#setobfuscatedaccountid + // when the purchase was made. + ObfuscatedExternalAccountId string `json:"obfuscatedExternalAccountId,omitempty"` + // ObfuscatedExternalProfileId: An obfuscated version of the id that is + // uniquely associated with the user's profile in your app. Only present if + // specified using + // https://developer.android.com/reference/com/android/billingclient/api/BillingFlowParams.Builder#setobfuscatedprofileid + // when the purchase was made. + ObfuscatedExternalProfileId string `json:"obfuscatedExternalProfileId,omitempty"` + // OrderId: The order id of the latest recurring order associated with the + // purchase of the subscription. If the subscription was canceled because + // payment was declined, this will be the order id from the payment declined + // order. + OrderId string `json:"orderId,omitempty"` + // PaymentState: The payment state of the subscription. Possible values are: 0. + // Payment pending 1. Payment received 2. Free trial 3. Pending deferred + // upgrade/downgrade Not present for canceled, expired subscriptions. + PaymentState *int64 `json:"paymentState,omitempty"` + // PriceAmountMicros: Price of the subscription, For tax exclusive countries, + // the price doesn't include tax. For tax inclusive countries, the price + // includes tax. Price is expressed in micro-units, where 1,000,000 micro-units + // represents one unit of the currency. For example, if the subscription price + // is €1.99, price_amount_micros is 1990000. + PriceAmountMicros int64 `json:"priceAmountMicros,omitempty,string"` + // PriceChange: The latest price change information available. This is present + // only when there is an upcoming price change for the subscription yet to be + // applied. Once the subscription renews with the new price or the subscription + // is canceled, no price change information will be returned. + PriceChange *SubscriptionPriceChange `json:"priceChange,omitempty"` + // PriceCurrencyCode: ISO 4217 currency code for the subscription price. For + // example, if the price is specified in British pounds sterling, + // price_currency_code is "GBP". + PriceCurrencyCode string `json:"priceCurrencyCode,omitempty"` + // ProfileId: The Google profile id of the user when the subscription was + // purchased. Only present for purchases made with 'Subscribe with Google'. + ProfileId string `json:"profileId,omitempty"` + // ProfileName: The profile name of the user when the subscription was + // purchased. Only present for purchases made with 'Subscribe with Google'. + ProfileName string `json:"profileName,omitempty"` + // PromotionCode: The promotion code applied on this purchase. This field is + // only set if a vanity code promotion is applied when the subscription was + // purchased. + PromotionCode string `json:"promotionCode,omitempty"` + // PromotionType: The type of promotion applied on this purchase. This field is + // only set if a promotion is applied when the subscription was purchased. + // Possible values are: 0. One time code 1. Vanity code + PromotionType int64 `json:"promotionType,omitempty"` + // PurchaseType: The type of purchase of the subscription. This field is only + // set if this purchase was not made using the standard in-app billing flow. + // Possible values are: 0. Test (i.e. purchased from a license testing account) + // 1. Promo (i.e. purchased using a promo code) + PurchaseType *int64 `json:"purchaseType,omitempty"` + // StartTimeMillis: Time at which the subscription was granted, in milliseconds + // since the Epoch. + StartTimeMillis int64 `json:"startTimeMillis,omitempty,string"` + // UserCancellationTimeMillis: The time at which the subscription was canceled + // by the user, in milliseconds since the epoch. Only present if cancelReason + // is 0. + UserCancellationTimeMillis int64 `json:"userCancellationTimeMillis,omitempty,string"` -// TargetingUpdate: Update type for targeting. Note it is always a subset -// Targeting. -type TargetingUpdate struct { - // AllUsers: All users are targeted. - AllUsers *AllUsers `json:"allUsers,omitempty"` - // AndroidSdks: Additional android sdk levels are targeted by the recovery - // action. - AndroidSdks *AndroidSdks `json:"androidSdks,omitempty"` - // Regions: Additional regions are targeted by the recovery action. - Regions *Regions `json:"regions,omitempty"` - // ForceSendFields is a list of field names (e.g. "AllUsers") to + // ServerResponse contains the HTTP response code and headers from the server. + googleapi.ServerResponse `json:"-"` + // ForceSendFields is a list of field names (e.g. "AcknowledgementState") 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. "AllUsers") 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 TargetingUpdate) MarshalJSON() ([]byte, error) { - type NoMethod TargetingUpdate - return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) -} - -// TestPurchase: Whether this subscription purchase is a test purchase. -type TestPurchase struct { -} - -// TestPurchaseContext: Context about a test purchase. -type TestPurchaseContext struct { - // FopType: The fop type of the test purchase. - // - // Possible values: - // "FOP_TYPE_UNSPECIFIED" - Fop type unspecified. This value should never be - // set. - // "TEST" - The purchase was made using a test card. - FopType string `json:"fopType,omitempty"` - // ForceSendFields is a list of field names (e.g. "FopType") 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. "FopType") 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. "AcknowledgementState") 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 TestPurchaseContext) MarshalJSON() ([]byte, error) { - type NoMethod TestPurchaseContext +func (s SubscriptionPurchase) MarshalJSON() ([]byte, error) { + type NoMethod SubscriptionPurchase return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// Testers: The testers of an app. The resource for TestersService. Note: while -// it is possible in the Play Console UI to add testers via email lists, email -// lists are not supported by this resource. -type Testers struct { - // GoogleGroups: All testing Google Groups, as email addresses. - GoogleGroups []string `json:"googleGroups,omitempty"` - - // ServerResponse contains the HTTP response code and headers from the server. - googleapi.ServerResponse `json:"-"` - // ForceSendFields is a list of field names (e.g. "GoogleGroups") to +// SubscriptionPurchaseLineItem: Item-level info for a subscription purchase. +type SubscriptionPurchaseLineItem struct { + // AutoRenewingPlan: The item is auto renewing. + AutoRenewingPlan *AutoRenewingPlan `json:"autoRenewingPlan,omitempty"` + // DeferredItemReplacement: Information for deferred item replacement. + DeferredItemReplacement *DeferredItemReplacement `json:"deferredItemReplacement,omitempty"` + // ExpiryTime: Time at which the subscription expired or will expire unless the + // access is extended (ex. renews). + ExpiryTime string `json:"expiryTime,omitempty"` + // LatestSuccessfulOrderId: The order id of the latest successful order + // associated with this item. Not present if the item is not owned by the user + // yet (e.g. the item being deferred replaced to). + LatestSuccessfulOrderId string `json:"latestSuccessfulOrderId,omitempty"` + // OfferDetails: The offer details for this item. + OfferDetails *OfferDetails `json:"offerDetails,omitempty"` + // PrepaidPlan: The item is prepaid. + PrepaidPlan *PrepaidPlan `json:"prepaidPlan,omitempty"` + // ProductId: The purchased product ID (for example, 'monthly001'). + ProductId string `json:"productId,omitempty"` + // SignupPromotion: Promotion details about this item. Only set if a promotion + // was applied during signup. + SignupPromotion *SignupPromotion `json:"signupPromotion,omitempty"` + // ForceSendFields is a list of field names (e.g. "AutoRenewingPlan") 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. "GoogleGroups") 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. "AutoRenewingPlan") 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 Testers) MarshalJSON() ([]byte, error) { - type NoMethod Testers +func (s SubscriptionPurchaseLineItem) MarshalJSON() ([]byte, error) { + type NoMethod SubscriptionPurchaseLineItem return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// TextureCompressionFormat: Represents texture compression format. -type TextureCompressionFormat struct { - // Alias: Alias for texture compression format. +// SubscriptionPurchaseV2: Indicates the status of a user's subscription +// purchase. +type SubscriptionPurchaseV2 struct { + // AcknowledgementState: The acknowledgement state of the subscription. // // Possible values: - // "UNSPECIFIED_TEXTURE_COMPRESSION_FORMAT" - Unspecified format. - // "ETC1_RGB8" - ETC1_RGB8 format. - // "PALETTED" - PALETTED format. - // "THREE_DC" - THREE_DC format. - // "ATC" - ATC format. - // "LATC" - LATC format. - // "DXT1" - DXT1 format. - // "S3TC" - S3TC format. - // "PVRTC" - PVRTC format. - // "ASTC" - ASTC format. - // "ETC2" - ETC2 format. - Alias string `json:"alias,omitempty"` - // ForceSendFields is a list of field names (e.g. "Alias") 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. "Alias") 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 TextureCompressionFormat) MarshalJSON() ([]byte, error) { - type NoMethod TextureCompressionFormat - return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) -} + // "ACKNOWLEDGEMENT_STATE_UNSPECIFIED" - Unspecified acknowledgement state. + // "ACKNOWLEDGEMENT_STATE_PENDING" - The subscription is not acknowledged + // yet. + // "ACKNOWLEDGEMENT_STATE_ACKNOWLEDGED" - The subscription is acknowledged. + AcknowledgementState string `json:"acknowledgementState,omitempty"` + // CanceledStateContext: Additional context around canceled subscriptions. Only + // present if the subscription currently has subscription_state + // SUBSCRIPTION_STATE_CANCELED or SUBSCRIPTION_STATE_EXPIRED. + CanceledStateContext *CanceledStateContext `json:"canceledStateContext,omitempty"` + // ExternalAccountIdentifiers: User account identifier in the third-party + // service. + ExternalAccountIdentifiers *ExternalAccountIdentifiers `json:"externalAccountIdentifiers,omitempty"` + // Kind: This kind represents a SubscriptionPurchaseV2 object in the + // androidpublisher service. + Kind string `json:"kind,omitempty"` + // LatestOrderId: Deprecated: Use line_items.latest_successful_order_id + // instead. The order id of the latest order associated with the purchase of + // the subscription. For autoRenewing subscription, this is the order id of + // signup order if it is not renewed yet, or the last recurring order id + // (success, pending, or declined order). For prepaid subscription, this is the + // order id associated with the queried purchase token. + LatestOrderId string `json:"latestOrderId,omitempty"` + // LineItems: Item-level info for a subscription purchase. The items in the + // same purchase should be either all with AutoRenewingPlan or all with + // PrepaidPlan. + LineItems []*SubscriptionPurchaseLineItem `json:"lineItems,omitempty"` + // LinkedPurchaseToken: The purchase token of the old subscription if this + // subscription is one of the following: * Re-signup of a canceled but + // non-lapsed subscription * Upgrade/downgrade from a previous subscription. * + // Convert from prepaid to auto renewing subscription. * Convert from an auto + // renewing subscription to prepaid. * Topup a prepaid subscription. + LinkedPurchaseToken string `json:"linkedPurchaseToken,omitempty"` + // PausedStateContext: Additional context around paused subscriptions. Only + // present if the subscription currently has subscription_state + // SUBSCRIPTION_STATE_PAUSED. + PausedStateContext *PausedStateContext `json:"pausedStateContext,omitempty"` + // RegionCode: ISO 3166-1 alpha-2 billing country/region code of the user at + // the time the subscription was granted. + RegionCode string `json:"regionCode,omitempty"` + // StartTime: Time at which the subscription was granted. Not set for pending + // subscriptions (subscription was created but awaiting payment during signup). + StartTime string `json:"startTime,omitempty"` + // SubscribeWithGoogleInfo: User profile associated with purchases made with + // 'Subscribe with Google'. + SubscribeWithGoogleInfo *SubscribeWithGoogleInfo `json:"subscribeWithGoogleInfo,omitempty"` + // SubscriptionState: The current state of the subscription. + // + // Possible values: + // "SUBSCRIPTION_STATE_UNSPECIFIED" - Unspecified subscription state. + // "SUBSCRIPTION_STATE_PENDING" - Subscription was created but awaiting + // payment during signup. In this state, all items are awaiting payment. + // "SUBSCRIPTION_STATE_ACTIVE" - Subscription is active. - (1) If the + // subscription is an auto renewing plan, at least one item is + // auto_renew_enabled and not expired. - (2) If the subscription is a prepaid + // plan, at least one item is not expired. + // "SUBSCRIPTION_STATE_PAUSED" - Subscription is paused. The state is only + // available when the subscription is an auto renewing plan. In this state, all + // items are in paused state. + // "SUBSCRIPTION_STATE_IN_GRACE_PERIOD" - Subscription is in grace period. + // The state is only available when the subscription is an auto renewing plan. + // In this state, all items are in grace period. + // "SUBSCRIPTION_STATE_ON_HOLD" - Subscription is on hold (suspended). The + // state is only available when the subscription is an auto renewing plan. In + // this state, all items are on hold. + // "SUBSCRIPTION_STATE_CANCELED" - Subscription is canceled but not expired + // yet. The state is only available when the subscription is an auto renewing + // plan. All items have auto_renew_enabled set to false. + // "SUBSCRIPTION_STATE_EXPIRED" - Subscription is expired. All items have + // expiry_time in the past. + // "SUBSCRIPTION_STATE_PENDING_PURCHASE_CANCELED" - Pending transaction for + // subscription is canceled. If this pending purchase was for an existing + // subscription, use linked_purchase_token to get the current state of that + // subscription. + SubscriptionState string `json:"subscriptionState,omitempty"` + // TestPurchase: Only present if this subscription purchase is a test purchase. + TestPurchase *TestPurchase `json:"testPurchase,omitempty"` -// TextureCompressionFormatTargeting: Targeting by a texture compression -// format. -type TextureCompressionFormatTargeting struct { - // Alternatives: List of alternative TCFs (TCFs targeted by the sibling - // splits). - Alternatives []*TextureCompressionFormat `json:"alternatives,omitempty"` - // Value: The list of targeted TCFs. Should not be empty. - Value []*TextureCompressionFormat `json:"value,omitempty"` - // ForceSendFields is a list of field names (e.g. "Alternatives") to + // ServerResponse contains the HTTP response code and headers from the server. + googleapi.ServerResponse `json:"-"` + // ForceSendFields is a list of field names (e.g. "AcknowledgementState") 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. "Alternatives") 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. "AcknowledgementState") 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 TextureCompressionFormatTargeting) MarshalJSON() ([]byte, error) { - type NoMethod TextureCompressionFormatTargeting +func (s SubscriptionPurchaseV2) MarshalJSON() ([]byte, error) { + type NoMethod SubscriptionPurchaseV2 return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// Timestamp: A Timestamp represents a point in time independent of any time -// zone or local calendar, encoded as a count of seconds and fractions of -// seconds at nanosecond resolution. The count is relative to an epoch at UTC -// midnight on January 1, 1970. -type Timestamp struct { - // Nanos: Non-negative fractions of a second at nanosecond resolution. Must be - // from 0 to 999,999,999 inclusive. - Nanos int64 `json:"nanos,omitempty"` - // Seconds: Represents seconds of UTC time since Unix epoch. - Seconds int64 `json:"seconds,omitempty,string"` - // ForceSendFields is a list of field names (e.g. "Nanos") to unconditionally - // include in API requests. By default, fields with empty or default values are - // omitted from API requests. See +// SubscriptionPurchasesAcknowledgeRequest: Request for the +// purchases.subscriptions.acknowledge API. +type SubscriptionPurchasesAcknowledgeRequest struct { + // DeveloperPayload: Payload to attach to the purchase. + DeveloperPayload string `json:"developerPayload,omitempty"` + // ForceSendFields is a list of field names (e.g. "DeveloperPayload") 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. "Nanos") 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. "DeveloperPayload") 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 Timestamp) MarshalJSON() ([]byte, error) { - type NoMethod Timestamp +func (s SubscriptionPurchasesAcknowledgeRequest) MarshalJSON() ([]byte, error) { + type NoMethod SubscriptionPurchasesAcknowledgeRequest return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// TokenPagination: Pagination information returned by a List operation when -// token pagination is enabled. List operations that supports paging return -// only one "page" of results. This protocol buffer message describes the page -// that has been returned. When using token pagination, clients should use the -// next/previous token to get another page of the result. The presence or -// absence of next/previous token indicates whether a next/previous page is -// available and provides a mean of accessing this page. ListRequest.page_token -// should be set to either next_page_token or previous_page_token to access -// another page. -type TokenPagination struct { - // NextPageToken: Tokens to pass to the standard list field 'page_token'. - // Whenever available, tokens are preferred over manipulating start_index. - NextPageToken string `json:"nextPageToken,omitempty"` - PreviousPageToken string `json:"previousPageToken,omitempty"` - // ForceSendFields is a list of field names (e.g. "NextPageToken") to +// SubscriptionPurchasesDeferRequest: Request for the +// purchases.subscriptions.defer API. +type SubscriptionPurchasesDeferRequest struct { + // DeferralInfo: The information about the new desired expiry time for the + // subscription. + DeferralInfo *SubscriptionDeferralInfo `json:"deferralInfo,omitempty"` + // ForceSendFields is a list of field names (e.g. "DeferralInfo") 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 + // NullFields is a list of field names (e.g. "DeferralInfo") 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 TokenPagination) MarshalJSON() ([]byte, error) { - type NoMethod TokenPagination +func (s SubscriptionPurchasesDeferRequest) MarshalJSON() ([]byte, error) { + type NoMethod SubscriptionPurchasesDeferRequest return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// Track: A track configuration. The resource for TracksService. -type Track struct { - // Releases: In a read request, represents all active releases in the track. In - // an update request, represents desired changes. - Releases []*TrackRelease `json:"releases,omitempty"` - // Track: Identifier of the track. Form factor tracks have a special prefix as - // an identifier, for example `wear:production`, `automotive:production`. More - // on track name - // (https://developers.google.com/android-publisher/tracks#ff-track-name) - Track string `json:"track,omitempty"` +// SubscriptionPurchasesDeferResponse: Response for the +// purchases.subscriptions.defer API. +type SubscriptionPurchasesDeferResponse struct { + // NewExpiryTimeMillis: The new expiry time for the subscription in + // milliseconds since the Epoch. + NewExpiryTimeMillis int64 `json:"newExpiryTimeMillis,omitempty,string"` // ServerResponse contains the HTTP response code and headers from the server. googleapi.ServerResponse `json:"-"` - // ForceSendFields is a list of field names (e.g. "Releases") to + // ForceSendFields is a list of field names (e.g. "NewExpiryTimeMillis") 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. "Releases") 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. "NewExpiryTimeMillis") 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 Track) MarshalJSON() ([]byte, error) { - type NoMethod Track +func (s SubscriptionPurchasesDeferResponse) MarshalJSON() ([]byte, error) { + type NoMethod SubscriptionPurchasesDeferResponse return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// TrackConfig: Configurations of the new track. -type TrackConfig struct { - // FormFactor: Required. Form factor of the new track. Defaults to the default - // track. - // - // Possible values: - // "FORM_FACTOR_UNSPECIFIED" - Fallback value, do not use. - // "DEFAULT" - Default track. - // "WEAR" - Wear form factor track. - // "AUTOMOTIVE" - Automotive form factor track. - FormFactor string `json:"formFactor,omitempty"` - // Track: Required. Identifier of the new track. For default tracks, this field - // consists of the track alias only. Form factor tracks have a special prefix - // as an identifier, for example `wear:production`, `automotive:production`. - // This prefix must match the value of the `form_factor` field, if it is not a - // default track. More on track name - // (https://developers.google.com/android-publisher/tracks#ff-track-name) - Track string `json:"track,omitempty"` - // Type: Required. Type of the new track. Currently, the only supported value - // is closedTesting. +// SubscriptionTaxAndComplianceSettings: Details about taxation, Google Play +// policy, and legal compliance for subscription products. +type SubscriptionTaxAndComplianceSettings struct { + // EeaWithdrawalRightType: Digital content or service classification for + // products distributed to users in the European Economic Area (EEA). The + // withdrawal regime under EEA consumer laws depends on this classification. + // Refer to the Help Center article + // (https://support.google.com/googleplay/android-developer/answer/10463498) + // for more information. // // Possible values: - // "TRACK_TYPE_UNSPECIFIED" - Fallback value, do not use. - // "CLOSED_TESTING" - Closed testing track. - Type string `json:"type,omitempty"` - // ForceSendFields is a list of field names (e.g. "FormFactor") to + // "WITHDRAWAL_RIGHT_TYPE_UNSPECIFIED" + // "WITHDRAWAL_RIGHT_DIGITAL_CONTENT" + // "WITHDRAWAL_RIGHT_SERVICE" + EeaWithdrawalRightType string `json:"eeaWithdrawalRightType,omitempty"` + // IsTokenizedDigitalAsset: Whether this subscription is declared as a product + // representing a tokenized digital asset. + IsTokenizedDigitalAsset bool `json:"isTokenizedDigitalAsset,omitempty"` + // TaxRateInfoByRegionCode: A mapping from region code to tax rate details. The + // keys are region codes as defined by Unicode's "CLDR". + TaxRateInfoByRegionCode map[string]RegionalTaxRateInfo `json:"taxRateInfoByRegionCode,omitempty"` + // ForceSendFields is a list of field names (e.g. "EeaWithdrawalRightType") 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. "FormFactor") to include in API + // NullFields is a list of field names (e.g. "EeaWithdrawalRightType") 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 SubscriptionTaxAndComplianceSettings) MarshalJSON() ([]byte, error) { + type NoMethod SubscriptionTaxAndComplianceSettings + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// SystemApkOptions: Options for system APKs. +type SystemApkOptions struct { + // Rotated: Whether to use the rotated key for signing the system APK. + Rotated bool `json:"rotated,omitempty"` + // UncompressedDexFiles: Whether system APK was generated with uncompressed dex + // files. + UncompressedDexFiles bool `json:"uncompressedDexFiles,omitempty"` + // UncompressedNativeLibraries: Whether system APK was generated with + // uncompressed native libraries. + UncompressedNativeLibraries bool `json:"uncompressedNativeLibraries,omitempty"` + // ForceSendFields is a list of field names (e.g. "Rotated") 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. "Rotated") 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 TrackConfig) MarshalJSON() ([]byte, error) { - type NoMethod TrackConfig +func (s SystemApkOptions) MarshalJSON() ([]byte, error) { + type NoMethod SystemApkOptions return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// TrackCountryAvailability: Resource for per-track country availability -// information. -type TrackCountryAvailability struct { - // Countries: A list of one or more countries where artifacts in this track are - // available. This list includes all countries that are targeted by the track, - // even if only specific carriers are targeted in that country. - Countries []*TrackTargetedCountry `json:"countries,omitempty"` - // RestOfWorld: Whether artifacts in this track are available to "rest of the - // world" countries. - RestOfWorld bool `json:"restOfWorld,omitempty"` - // SyncWithProduction: Whether this track's availability is synced with the - // default production track. See - // https://support.google.com/googleplay/android-developer/answer/7550024 for - // more information on syncing country availability with production. Note that - // if this is true, the returned "countries" and "rest_of_world" fields will - // reflect the values for the default production track. - SyncWithProduction bool `json:"syncWithProduction,omitempty"` +// SystemApksListResponse: Response to list previously created system APK +// variants. +type SystemApksListResponse struct { + // Variants: All system APK variants created. + Variants []*Variant `json:"variants,omitempty"` // ServerResponse contains the HTTP response code and headers from the server. googleapi.ServerResponse `json:"-"` - // ForceSendFields is a list of field names (e.g. "Countries") to + // ForceSendFields is a list of field names (e.g. "Variants") 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. "Countries") to include in API + // NullFields is a list of field names (e.g. "Variants") 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 TrackCountryAvailability) MarshalJSON() ([]byte, error) { - type NoMethod TrackCountryAvailability +func (s SystemApksListResponse) MarshalJSON() ([]byte, error) { + type NoMethod SystemApksListResponse return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// TrackRelease: A release within a track. -type TrackRelease struct { - // CountryTargeting: Restricts a release to a specific set of countries. - CountryTargeting *CountryTargeting `json:"countryTargeting,omitempty"` - // InAppUpdatePriority: In-app update priority of the release. All newly added - // APKs in the release will be considered at this priority. Can take values in - // the range [0, 5], with 5 the highest priority. Defaults to 0. - // in_app_update_priority can not be updated once the release is rolled out. - // See https://developer.android.com/guide/playcore/in-app-updates. - InAppUpdatePriority int64 `json:"inAppUpdatePriority,omitempty"` - // Name: The release name. Not required to be unique. If not set, the name is - // generated from the APK's version_name. If the release contains multiple - // APKs, the name is generated from the date. +// SystemFeature: Representation of a system feature. +type SystemFeature struct { + // Name: The name of the feature. Name string `json:"name,omitempty"` - // ReleaseNotes: A description of what is new in this release. - ReleaseNotes []*LocalizedText `json:"releaseNotes,omitempty"` - // Status: The status of the release. - // - // Possible values: - // "statusUnspecified" - Unspecified status. - // "draft" - The release's APKs are not being served to users. - // "inProgress" - The release's APKs are being served to a fraction of users, - // determined by 'user_fraction'. - // "halted" - The release's APKs will no longer be served to users. Users who - // already have these APKs are unaffected. - // "completed" - The release will have no further changes. Its APKs are being - // served to all users, unless they are eligible to APKs of a more recent - // release. - Status string `json:"status,omitempty"` - // UserFraction: Fraction of users who are eligible for a staged release. 0 < - // fraction < 1. Can only be set when status is "inProgress" or "halted". - UserFraction float64 `json:"userFraction,omitempty"` - // VersionCodes: Version codes of all APKs in the release. Must include version - // codes to retain from previous releases. - VersionCodes googleapi.Int64s `json:"versionCodes,omitempty"` - // ForceSendFields is a list of field names (e.g. "CountryTargeting") 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. "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. "CountryTargeting") 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 TrackRelease) MarshalJSON() ([]byte, error) { - type NoMethod TrackRelease +func (s SystemFeature) MarshalJSON() ([]byte, error) { + type NoMethod SystemFeature return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -func (s *TrackRelease) UnmarshalJSON(data []byte) error { - type NoMethod TrackRelease - var s1 struct { - UserFraction gensupport.JSONFloat64 `json:"userFraction"` - *NoMethod - } - s1.NoMethod = (*NoMethod)(s) - if err := json.Unmarshal(data, &s1); err != nil { - return err - } - s.UserFraction = float64(s1.UserFraction) - return nil +// SystemInitiatedCancellation: Information specific to cancellations initiated +// by Google system. +type SystemInitiatedCancellation struct { } -// TrackTargetedCountry: Representation of a single country where the contents -// of a track are available. -type TrackTargetedCountry struct { - // CountryCode: The country to target, as a two-letter CLDR code. - CountryCode string `json:"countryCode,omitempty"` - // ForceSendFields is a list of field names (e.g. "CountryCode") to +// SystemOnChip: Representation of a System-on-Chip (SoC) of an Android device. +// Can be used to target S+ devices. +type SystemOnChip struct { + // Manufacturer: Required. The designer of the SoC, eg. "Google" Value of build + // property "ro.soc.manufacturer" + // https://developer.android.com/reference/android/os/Build#SOC_MANUFACTURER + // Required. + Manufacturer string `json:"manufacturer,omitempty"` + // Model: Required. The model of the SoC, eg. "Tensor" Value of build property + // "ro.soc.model" + // https://developer.android.com/reference/android/os/Build#SOC_MODEL Required. + Model string `json:"model,omitempty"` + // ForceSendFields is a list of field names (e.g. "Manufacturer") 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. "CountryCode") to include in API + // NullFields is a list of field names (e.g. "Manufacturer") 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 TrackTargetedCountry) MarshalJSON() ([]byte, error) { - type NoMethod TrackTargetedCountry - return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) -} - -// TracksListResponse: Response listing all tracks. -type TracksListResponse struct { - // Kind: The kind of this response ("androidpublisher#tracksListResponse"). - Kind string `json:"kind,omitempty"` - // Tracks: All tracks (including tracks with no releases). - Tracks []*Track `json:"tracks,omitempty"` - - // ServerResponse contains the HTTP response code and headers from the server. - googleapi.ServerResponse `json:"-"` - // 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 TracksListResponse) MarshalJSON() ([]byte, error) { - type NoMethod TracksListResponse +func (s SystemOnChip) MarshalJSON() ([]byte, error) { + type NoMethod SystemOnChip return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// UpdateBasePlanStateRequest: Request message to update the state of a -// subscription base plan. -type UpdateBasePlanStateRequest struct { - // ActivateBasePlanRequest: Activates a base plan. Once activated, base plans - // will be available to new subscribers. - ActivateBasePlanRequest *ActivateBasePlanRequest `json:"activateBasePlanRequest,omitempty"` - // DeactivateBasePlanRequest: Deactivates a base plan. Once deactivated, the - // base plan will become unavailable to new subscribers, but existing - // subscribers will maintain their subscription - DeactivateBasePlanRequest *DeactivateBasePlanRequest `json:"deactivateBasePlanRequest,omitempty"` - // ForceSendFields is a list of field names (e.g. "ActivateBasePlanRequest") to +// Targeting: Targeting details for a recovery action such as regions, android +// sdk levels, app versions etc. +type Targeting struct { + // AllUsers: All users are targeted. + AllUsers *AllUsers `json:"allUsers,omitempty"` + // AndroidSdks: Targeting is based on android api levels of devices. + AndroidSdks *AndroidSdks `json:"androidSdks,omitempty"` + // Regions: Targeting is based on the user account region. + Regions *Regions `json:"regions,omitempty"` + // VersionList: Target version codes as a list. + VersionList *AppVersionList `json:"versionList,omitempty"` + // VersionRange: Target version codes as a range. + VersionRange *AppVersionRange `json:"versionRange,omitempty"` + // ForceSendFields is a list of field names (e.g. "AllUsers") 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. "ActivateBasePlanRequest") 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. "AllUsers") 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 UpdateBasePlanStateRequest) MarshalJSON() ([]byte, error) { - type NoMethod UpdateBasePlanStateRequest +func (s Targeting) MarshalJSON() ([]byte, error) { + type NoMethod Targeting return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// UpdateSubscriptionOfferRequest: Request message for UpdateSubscriptionOffer. -type UpdateSubscriptionOfferRequest struct { - // AllowMissing: Optional. If set to true, and the subscription offer with the - // given package_name, product_id, base_plan_id and offer_id doesn't exist, an - // offer will be created. If a new offer is created, update_mask is ignored. - AllowMissing bool `json:"allowMissing,omitempty"` - // LatencyTolerance: Optional. The latency tolerance for the propagation of - // this product update. Defaults to latency-sensitive. - // - // Possible values: - // "PRODUCT_UPDATE_LATENCY_TOLERANCE_UNSPECIFIED" - Defaults to - // PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_SENSITIVE. - // "PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_SENSITIVE" - The update will - // propagate to clients within several minutes on average and up to a few hours - // in rare cases. Throughput is limited to 7,200 updates per app per hour. - // "PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_TOLERANT" - The update will - // propagate to clients within 24 hours. Supports high throughput of up to - // 720,000 updates per app per hour using batch modification methods. - LatencyTolerance string `json:"latencyTolerance,omitempty"` - // RegionsVersion: Required. The version of the available regions being used - // for the subscription_offer. - RegionsVersion *RegionsVersion `json:"regionsVersion,omitempty"` - // SubscriptionOffer: Required. The subscription offer to update. - SubscriptionOffer *SubscriptionOffer `json:"subscriptionOffer,omitempty"` - // UpdateMask: Required. The list of fields to be updated. - UpdateMask string `json:"updateMask,omitempty"` - // ForceSendFields is a list of field names (e.g. "AllowMissing") to +// TargetingInfo: Targeting information about the generated apks. +type TargetingInfo struct { + // AssetSliceSet: List of created asset slices. + AssetSliceSet []*AssetSliceSet `json:"assetSliceSet,omitempty"` + // PackageName: The package name of this app. + PackageName string `json:"packageName,omitempty"` + // Variant: List of the created variants. + Variant []*SplitApkVariant `json:"variant,omitempty"` + // ForceSendFields is a list of field names (e.g. "AssetSliceSet") 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. "AllowMissing") to include in API + // NullFields is a list of field names (e.g. "AssetSliceSet") 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 UpdateSubscriptionOfferRequest) MarshalJSON() ([]byte, error) { - type NoMethod UpdateSubscriptionOfferRequest +func (s TargetingInfo) MarshalJSON() ([]byte, error) { + type NoMethod TargetingInfo return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// UpdateSubscriptionOfferStateRequest: Request message to update the state of -// a subscription offer. -type UpdateSubscriptionOfferStateRequest struct { - // ActivateSubscriptionOfferRequest: Activates an offer. Once activated, the - // offer will be available to new subscribers. - ActivateSubscriptionOfferRequest *ActivateSubscriptionOfferRequest `json:"activateSubscriptionOfferRequest,omitempty"` - // DeactivateSubscriptionOfferRequest: Deactivates an offer. Once deactivated, - // the offer will become unavailable to new subscribers, but existing - // subscribers will maintain their subscription - DeactivateSubscriptionOfferRequest *DeactivateSubscriptionOfferRequest `json:"deactivateSubscriptionOfferRequest,omitempty"` - // ForceSendFields is a list of field names (e.g. - // "ActivateSubscriptionOfferRequest") to unconditionally include in API - // requests. By default, fields with empty or default values are omitted from - // API requests. See +// TargetingRuleScope: Defines the scope of subscriptions which a targeting +// rule can match to target offers to users based on past or current +// entitlement. +type TargetingRuleScope struct { + // AnySubscriptionInApp: The scope of the current targeting rule is any + // subscription in the parent app. + AnySubscriptionInApp *TargetingRuleScopeAnySubscriptionInApp `json:"anySubscriptionInApp,omitempty"` + // SpecificSubscriptionInApp: The scope of the current targeting rule is the + // subscription with the specified subscription ID. Must be a subscription + // within the same parent app. + SpecificSubscriptionInApp string `json:"specificSubscriptionInApp,omitempty"` + // ThisSubscription: The scope of the current targeting rule is the + // subscription in which this offer is defined. + ThisSubscription *TargetingRuleScopeThisSubscription `json:"thisSubscription,omitempty"` + // ForceSendFields is a list of field names (e.g. "AnySubscriptionInApp") 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. - // "ActivateSubscriptionOfferRequest") 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 is a list of field names (e.g. "AnySubscriptionInApp") 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 UpdateSubscriptionOfferStateRequest) MarshalJSON() ([]byte, error) { - type NoMethod UpdateSubscriptionOfferStateRequest +func (s TargetingRuleScope) MarshalJSON() ([]byte, error) { + type NoMethod TargetingRuleScope return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// UpdateSubscriptionRequest: Request message for UpdateSubscription. -type UpdateSubscriptionRequest struct { - // AllowMissing: Optional. If set to true, and the subscription with the given - // package_name and product_id doesn't exist, the subscription will be created. - // If a new subscription is created, update_mask is ignored. - AllowMissing bool `json:"allowMissing,omitempty"` - // LatencyTolerance: Optional. The latency tolerance for the propagation of - // this product update. Defaults to latency-sensitive. - // - // Possible values: - // "PRODUCT_UPDATE_LATENCY_TOLERANCE_UNSPECIFIED" - Defaults to - // PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_SENSITIVE. - // "PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_SENSITIVE" - The update will - // propagate to clients within several minutes on average and up to a few hours - // in rare cases. Throughput is limited to 7,200 updates per app per hour. - // "PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_TOLERANT" - The update will - // propagate to clients within 24 hours. Supports high throughput of up to - // 720,000 updates per app per hour using batch modification methods. - LatencyTolerance string `json:"latencyTolerance,omitempty"` - // RegionsVersion: Required. The version of the available regions being used - // for the subscription. - RegionsVersion *RegionsVersion `json:"regionsVersion,omitempty"` - // Subscription: Required. The subscription to update. - Subscription *Subscription `json:"subscription,omitempty"` - // UpdateMask: Required. The list of fields to be updated. - UpdateMask string `json:"updateMask,omitempty"` - // ForceSendFields is a list of field names (e.g. "AllowMissing") to +// TargetingRuleScopeAnySubscriptionInApp: Represents the targeting rule scope +// corresponding to any subscription in the parent app. +type TargetingRuleScopeAnySubscriptionInApp struct { +} + +// TargetingRuleScopeThisSubscription: Represents the targeting rule scope +// corresponding to the subscriptions in which this offer is defined. +type TargetingRuleScopeThisSubscription struct { +} + +// TargetingUpdate: Update type for targeting. Note it is always a subset +// Targeting. +type TargetingUpdate struct { + // AllUsers: All users are targeted. + AllUsers *AllUsers `json:"allUsers,omitempty"` + // AndroidSdks: Additional android sdk levels are targeted by the recovery + // action. + AndroidSdks *AndroidSdks `json:"androidSdks,omitempty"` + // Regions: Additional regions are targeted by the recovery action. + Regions *Regions `json:"regions,omitempty"` + // ForceSendFields is a list of field names (e.g. "AllUsers") 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. "AllowMissing") to include in API + // NullFields is a list of field names (e.g. "AllUsers") 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 UpdateSubscriptionRequest) MarshalJSON() ([]byte, error) { - type NoMethod UpdateSubscriptionRequest +func (s TargetingUpdate) MarshalJSON() ([]byte, error) { + type NoMethod TargetingUpdate return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// UpgradeTargetingRule: Represents a targeting rule of the form: User -// currently has {scope} [with billing period {billing_period}]. -type UpgradeTargetingRule struct { - // BillingPeriodDuration: The specific billing period duration, specified in - // ISO 8601 format, that a user must be currently subscribed to to be eligible - // for this rule. If not specified, users subscribed to any billing period are - // matched. - BillingPeriodDuration string `json:"billingPeriodDuration,omitempty"` - // OncePerUser: Limit this offer to only once per user. If set to true, a user - // can never be eligible for this offer again if they ever subscribed to this - // offer. - OncePerUser bool `json:"oncePerUser,omitempty"` - // Scope: Required. The scope of subscriptions this rule considers. Only allows - // "this subscription" and "specific subscription in app". - Scope *TargetingRuleScope `json:"scope,omitempty"` - // ForceSendFields is a list of field names (e.g. "BillingPeriodDuration") to - // unconditionally include in API requests. By default, fields with empty or - // default values are omitted from API requests. See +// TestPurchase: Whether this subscription purchase is a test purchase. +type TestPurchase struct { +} + +// TestPurchaseContext: Context about a test purchase. +type TestPurchaseContext struct { + // FopType: The fop type of the test purchase. + // + // Possible values: + // "FOP_TYPE_UNSPECIFIED" - Fop type unspecified. This value should never be + // set. + // "TEST" - The purchase was made using a test card. + FopType string `json:"fopType,omitempty"` + // ForceSendFields is a list of field names (e.g. "FopType") 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. "BillingPeriodDuration") 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. "FopType") 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 UpgradeTargetingRule) MarshalJSON() ([]byte, error) { - type NoMethod UpgradeTargetingRule +func (s TestPurchaseContext) MarshalJSON() ([]byte, error) { + type NoMethod TestPurchaseContext return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// User: A user resource. -type User struct { - // AccessState: Output only. The state of the user's access to the Play - // Console. - // - // Possible values: - // "ACCESS_STATE_UNSPECIFIED" - Unknown or unspecified access state. - // "INVITED" - User is invited but has not yet accepted the invitation. - // "INVITATION_EXPIRED" - Invitation has expired. - // "ACCESS_GRANTED" - User has accepted an invitation and has access to the - // Play Console. - // "ACCESS_EXPIRED" - Account access has expired. - AccessState string `json:"accessState,omitempty"` - // DeveloperAccountPermissions: Permissions for the user which apply across the - // developer account. - // - // Possible values: - // "DEVELOPER_LEVEL_PERMISSION_UNSPECIFIED" - Unknown or unspecified - // permission. - // "CAN_SEE_ALL_APPS" - View app information and download bulk reports - // (read-only). Deprecated: Check CAN_VIEW_NON_FINANCIAL_DATA_GLOBAL. - // "CAN_VIEW_FINANCIAL_DATA_GLOBAL" - View financial data, orders, and - // cancellation survey responses. - // "CAN_MANAGE_PERMISSIONS_GLOBAL" - Admin (all permissions). - // "CAN_EDIT_GAMES_GLOBAL" - Edit Play Games Services projects. - // "CAN_PUBLISH_GAMES_GLOBAL" - Publish Play Games Services projects. - // "CAN_REPLY_TO_REVIEWS_GLOBAL" - Reply to reviews. - // "CAN_MANAGE_PUBLIC_APKS_GLOBAL" - Release to production, exclude devices, - // and use app signing by Google Play. - // "CAN_MANAGE_TRACK_APKS_GLOBAL" - Release to testing tracks. - // "CAN_MANAGE_TRACK_USERS_GLOBAL" - Manage testing tracks and edit tester - // lists. - // "CAN_MANAGE_PUBLIC_LISTING_GLOBAL" - Manage store presence. - // "CAN_MANAGE_DRAFT_APPS_GLOBAL" - Create, edit, and delete draft apps. - // "CAN_CREATE_MANAGED_PLAY_APPS_GLOBAL" - Create and publish private apps to - // your organization. - // "CAN_CHANGE_MANAGED_PLAY_SETTING_GLOBAL" - Choose whether apps are public, - // or only available to your organization. - // "CAN_MANAGE_ORDERS_GLOBAL" - Manage orders and subscriptions. - // "CAN_MANAGE_APP_CONTENT_GLOBAL" - Manage policy related pages on all apps - // for the developer. - // "CAN_VIEW_NON_FINANCIAL_DATA_GLOBAL" - View app information and download - // bulk reports (read-only). - // "CAN_VIEW_APP_QUALITY_GLOBAL" - View app quality information for all apps - // for the developer. - // "CAN_MANAGE_DEEPLINKS_GLOBAL" - Manage the deep links setup for all apps - // for the developer. - DeveloperAccountPermissions []string `json:"developerAccountPermissions,omitempty"` - // Email: Immutable. The user's email address. - Email string `json:"email,omitempty"` - // ExpirationTime: The time at which the user's access expires, if set. When - // setting this value, it must always be in the future. - ExpirationTime string `json:"expirationTime,omitempty"` - // Grants: Output only. Per-app permissions for the user. - Grants []*Grant `json:"grants,omitempty"` - // Name: Required. Resource name for this user, following the pattern - // "developers/{developer}/users/{email}". - Name string `json:"name,omitempty"` - // Partial: Output only. Whether there are more permissions for the user that - // are not represented here. This can happen if the caller does not have - // permission to manage all apps in the account. This is also `true` if this - // user is the account owner. If this field is `true`, it should be taken as a - // signal that this user cannot be fully managed via the API. That is, the API - // caller is not be able to manage all of the permissions this user holds, - // either because it doesn't know about them or because the user is the account - // owner. - Partial bool `json:"partial,omitempty"` +// Testers: The testers of an app. The resource for TestersService. Note: while +// it is possible in the Play Console UI to add testers via email lists, email +// lists are not supported by this resource. +type Testers struct { + // GoogleGroups: All testing Google Groups, as email addresses. + GoogleGroups []string `json:"googleGroups,omitempty"` // ServerResponse contains the HTTP response code and headers from the server. googleapi.ServerResponse `json:"-"` - // ForceSendFields is a list of field names (e.g. "AccessState") to + // ForceSendFields is a list of field names (e.g. "GoogleGroups") 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. "AccessState") to include in API + // NullFields is a list of field names (e.g. "GoogleGroups") 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 User) MarshalJSON() ([]byte, error) { - type NoMethod User +func (s Testers) MarshalJSON() ([]byte, error) { + type NoMethod Testers return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// UserComment: User entry from conversation between user and developer. -type UserComment struct { - // AndroidOsVersion: Integer Android SDK version of the user's device at the - // time the review was written, e.g. 23 is Marshmallow. May be absent. - AndroidOsVersion int64 `json:"androidOsVersion,omitempty"` - // AppVersionCode: Integer version code of the app as installed at the time the - // review was written. May be absent. - AppVersionCode int64 `json:"appVersionCode,omitempty"` - // AppVersionName: String version name of the app as installed at the time the - // review was written. May be absent. - AppVersionName string `json:"appVersionName,omitempty"` - // Device: Codename for the reviewer's device, e.g. klte, flounder. May be - // absent. - Device string `json:"device,omitempty"` - // DeviceMetadata: Information about the characteristics of the user's device. - DeviceMetadata *DeviceMetadata `json:"deviceMetadata,omitempty"` - // LastModified: The last time at which this comment was updated. - LastModified *Timestamp `json:"lastModified,omitempty"` - // OriginalText: Untranslated text of the review, where the review was - // translated. If the review was not translated this is left blank. - OriginalText string `json:"originalText,omitempty"` - // ReviewerLanguage: Language code for the reviewer. This is taken from the - // device settings so is not guaranteed to match the language the review is - // written in. May be absent. - ReviewerLanguage string `json:"reviewerLanguage,omitempty"` - // StarRating: The star rating associated with the review, from 1 to 5. - StarRating int64 `json:"starRating,omitempty"` - // Text: The content of the comment, i.e. review body. In some cases users have - // been able to write a review with separate title and body; in those cases the - // title and body are concatenated and separated by a tab character. - Text string `json:"text,omitempty"` - // ThumbsDownCount: Number of users who have given this review a thumbs down. - ThumbsDownCount int64 `json:"thumbsDownCount,omitempty"` - // ThumbsUpCount: Number of users who have given this review a thumbs up. - ThumbsUpCount int64 `json:"thumbsUpCount,omitempty"` - // ForceSendFields is a list of field names (e.g. "AndroidOsVersion") to - // unconditionally include in API requests. By default, fields with empty or - // default values are omitted from API requests. See +// TextureCompressionFormat: Represents texture compression format. +type TextureCompressionFormat struct { + // Alias: Alias for texture compression format. + // + // Possible values: + // "UNSPECIFIED_TEXTURE_COMPRESSION_FORMAT" - Unspecified format. + // "ETC1_RGB8" - ETC1_RGB8 format. + // "PALETTED" - PALETTED format. + // "THREE_DC" - THREE_DC format. + // "ATC" - ATC format. + // "LATC" - LATC format. + // "DXT1" - DXT1 format. + // "S3TC" - S3TC format. + // "PVRTC" - PVRTC format. + // "ASTC" - ASTC format. + // "ETC2" - ETC2 format. + Alias string `json:"alias,omitempty"` + // ForceSendFields is a list of field names (e.g. "Alias") 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. "AndroidOsVersion") 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. "Alias") 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 UserComment) MarshalJSON() ([]byte, error) { - type NoMethod UserComment +func (s TextureCompressionFormat) MarshalJSON() ([]byte, error) { + type NoMethod TextureCompressionFormat return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// UserCountriesTargeting: Describes an inclusive/exclusive list of country -// codes that module targets. -type UserCountriesTargeting struct { - // CountryCodes: List of country codes in the two-letter CLDR territory format. - CountryCodes []string `json:"countryCodes,omitempty"` - // Exclude: Indicates if the list above is exclusive. - Exclude bool `json:"exclude,omitempty"` - // ForceSendFields is a list of field names (e.g. "CountryCodes") to +// TextureCompressionFormatTargeting: Targeting by a texture compression +// format. +type TextureCompressionFormatTargeting struct { + // Alternatives: List of alternative TCFs (TCFs targeted by the sibling + // splits). + Alternatives []*TextureCompressionFormat `json:"alternatives,omitempty"` + // Value: The list of targeted TCFs. Should not be empty. + Value []*TextureCompressionFormat `json:"value,omitempty"` + // ForceSendFields is a list of field names (e.g. "Alternatives") 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. "CountryCodes") to include in API + // NullFields is a list of field names (e.g. "Alternatives") 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 UserCountriesTargeting) MarshalJSON() ([]byte, error) { - type NoMethod UserCountriesTargeting +func (s TextureCompressionFormatTargeting) MarshalJSON() ([]byte, error) { + type NoMethod TextureCompressionFormatTargeting return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// UserCountrySet: A set of user countries. A country set determines what -// variation of app content gets served to a specific location. -type UserCountrySet struct { - // CountryCodes: List of country codes representing countries. A Country code - // is represented in ISO 3166 alpha-2 format. For Example:- "IT" for Italy, - // "GE" for Georgia. - CountryCodes []string `json:"countryCodes,omitempty"` - // Name: Country set name. - Name string `json:"name,omitempty"` - // ForceSendFields is a list of field names (e.g. "CountryCodes") to - // unconditionally include in API requests. By default, fields with empty or - // default values are omitted from API requests. See +// Timestamp: A Timestamp represents a point in time independent of any time +// zone or local calendar, encoded as a count of seconds and fractions of +// seconds at nanosecond resolution. The count is relative to an epoch at UTC +// midnight on January 1, 1970. +type Timestamp struct { + // Nanos: Non-negative fractions of a second at nanosecond resolution. Must be + // from 0 to 999,999,999 inclusive. + Nanos int64 `json:"nanos,omitempty"` + // Seconds: Represents seconds of UTC time since Unix epoch. + Seconds int64 `json:"seconds,omitempty,string"` + // ForceSendFields is a list of field names (e.g. "Nanos") 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. "CountryCodes") to include in API + // NullFields is a list of field names (e.g. "Nanos") 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 UserCountrySet) MarshalJSON() ([]byte, error) { - type NoMethod UserCountrySet +func (s Timestamp) MarshalJSON() ([]byte, error) { + type NoMethod Timestamp return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// UserInitiatedCancellation: Information specific to cancellations initiated -// by users. -type UserInitiatedCancellation struct { - // CancelSurveyResult: Information provided by the user when they complete the - // subscription cancellation flow (cancellation reason survey). - CancelSurveyResult *CancelSurveyResult `json:"cancelSurveyResult,omitempty"` - // CancelTime: The time at which the subscription was canceled by the user. The - // user might still have access to the subscription after this time. Use - // line_items.expiry_time to determine if a user still has access. - CancelTime string `json:"cancelTime,omitempty"` - // ForceSendFields is a list of field names (e.g. "CancelSurveyResult") to +// TokenPagination: Pagination information returned by a List operation when +// token pagination is enabled. List operations that supports paging return +// only one "page" of results. This protocol buffer message describes the page +// that has been returned. When using token pagination, clients should use the +// next/previous token to get another page of the result. The presence or +// absence of next/previous token indicates whether a next/previous page is +// available and provides a mean of accessing this page. ListRequest.page_token +// should be set to either next_page_token or previous_page_token to access +// another page. +type TokenPagination struct { + // NextPageToken: Tokens to pass to the standard list field 'page_token'. + // Whenever available, tokens are preferred over manipulating start_index. + NextPageToken string `json:"nextPageToken,omitempty"` + PreviousPageToken string `json:"previousPageToken,omitempty"` + // 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. "CancelSurveyResult") 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. "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 UserInitiatedCancellation) MarshalJSON() ([]byte, error) { - type NoMethod UserInitiatedCancellation +func (s TokenPagination) MarshalJSON() ([]byte, error) { + type NoMethod TokenPagination return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// UsesPermission: A permission used by this APK. -type UsesPermission struct { - // MaxSdkVersion: Optionally, the maximum SDK version for which the permission - // is required. - MaxSdkVersion int64 `json:"maxSdkVersion,omitempty"` - // Name: The name of the permission requested. - Name string `json:"name,omitempty"` - // ForceSendFields is a list of field names (e.g. "MaxSdkVersion") to +// Track: A track configuration. The resource for TracksService. +type Track struct { + // Releases: In a read request, represents all active releases in the track. In + // an update request, represents desired changes. + Releases []*TrackRelease `json:"releases,omitempty"` + // Track: Identifier of the track. Form factor tracks have a special prefix as + // an identifier, for example `wear:production`, `automotive:production`. More + // on track name + // (https://developers.google.com/android-publisher/tracks#ff-track-name) + Track string `json:"track,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the server. + googleapi.ServerResponse `json:"-"` + // ForceSendFields is a list of field names (e.g. "Releases") 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. "MaxSdkVersion") to include in API + // NullFields is a list of field names (e.g. "Releases") 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 UsesPermission) MarshalJSON() ([]byte, error) { - type NoMethod UsesPermission +func (s Track) MarshalJSON() ([]byte, error) { + type NoMethod Track return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// VanityCode: A multiple use, predefined promotion code. -type VanityCode struct { - // PromotionCode: The promotion code. - PromotionCode string `json:"promotionCode,omitempty"` - // ForceSendFields is a list of field names (e.g. "PromotionCode") to +// TrackConfig: Configurations of the new track. +type TrackConfig struct { + // FormFactor: Required. Form factor of the new track. Defaults to the default + // track. + // + // Possible values: + // "FORM_FACTOR_UNSPECIFIED" - Fallback value, do not use. + // "DEFAULT" - Default track. + // "WEAR" - Wear form factor track. + // "AUTOMOTIVE" - Automotive form factor track. + FormFactor string `json:"formFactor,omitempty"` + // Track: Required. Identifier of the new track. For default tracks, this field + // consists of the track alias only. Form factor tracks have a special prefix + // as an identifier, for example `wear:production`, `automotive:production`. + // This prefix must match the value of the `form_factor` field, if it is not a + // default track. More on track name + // (https://developers.google.com/android-publisher/tracks#ff-track-name) + Track string `json:"track,omitempty"` + // Type: Required. Type of the new track. Currently, the only supported value + // is closedTesting. + // + // Possible values: + // "TRACK_TYPE_UNSPECIFIED" - Fallback value, do not use. + // "CLOSED_TESTING" - Closed testing track. + Type string `json:"type,omitempty"` + // ForceSendFields is a list of field names (e.g. "FormFactor") 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. "PromotionCode") to include in API + // NullFields is a list of field names (e.g. "FormFactor") 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 VanityCode) MarshalJSON() ([]byte, error) { - type NoMethod VanityCode +func (s TrackConfig) MarshalJSON() ([]byte, error) { + type NoMethod TrackConfig return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// Variant: APK that is suitable for inclusion in a system image. The resource -// of SystemApksService. -type Variant struct { - // DeviceSpec: The device spec used to generate the APK. - DeviceSpec *DeviceSpec `json:"deviceSpec,omitempty"` - // Options: Optional. Options applied to the generated APK. - Options *SystemApkOptions `json:"options,omitempty"` - // VariantId: Output only. The ID of a previously created system APK variant. - VariantId int64 `json:"variantId,omitempty"` +// TrackCountryAvailability: Resource for per-track country availability +// information. +type TrackCountryAvailability struct { + // Countries: A list of one or more countries where artifacts in this track are + // available. This list includes all countries that are targeted by the track, + // even if only specific carriers are targeted in that country. + Countries []*TrackTargetedCountry `json:"countries,omitempty"` + // RestOfWorld: Whether artifacts in this track are available to "rest of the + // world" countries. + RestOfWorld bool `json:"restOfWorld,omitempty"` + // SyncWithProduction: Whether this track's availability is synced with the + // default production track. See + // https://support.google.com/googleplay/android-developer/answer/7550024 for + // more information on syncing country availability with production. Note that + // if this is true, the returned "countries" and "rest_of_world" fields will + // reflect the values for the default production track. + SyncWithProduction bool `json:"syncWithProduction,omitempty"` // ServerResponse contains the HTTP response code and headers from the server. googleapi.ServerResponse `json:"-"` - // ForceSendFields is a list of field names (e.g. "DeviceSpec") to + // ForceSendFields is a list of field names (e.g. "Countries") 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. "DeviceSpec") to include in API + // NullFields is a list of field names (e.g. "Countries") 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 Variant) MarshalJSON() ([]byte, error) { - type NoMethod Variant +func (s TrackCountryAvailability) MarshalJSON() ([]byte, error) { + type NoMethod TrackCountryAvailability return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// VariantTargeting: Targeting on the level of variants. -type VariantTargeting struct { - // AbiTargeting: The abi that the variant targets - AbiTargeting *AbiTargeting `json:"abiTargeting,omitempty"` - // MultiAbiTargeting: Multi-api-level targeting - MultiAbiTargeting *MultiAbiTargeting `json:"multiAbiTargeting,omitempty"` - // ScreenDensityTargeting: The screen densities that this variant supports - ScreenDensityTargeting *ScreenDensityTargeting `json:"screenDensityTargeting,omitempty"` - // SdkVersionTargeting: The sdk version that the variant targets - SdkVersionTargeting *SdkVersionTargeting `json:"sdkVersionTargeting,omitempty"` - // TextureCompressionFormatTargeting: Texture-compression-format-level - // targeting - TextureCompressionFormatTargeting *TextureCompressionFormatTargeting `json:"textureCompressionFormatTargeting,omitempty"` - // ForceSendFields is a list of field names (e.g. "AbiTargeting") 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. "AbiTargeting") 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 VariantTargeting) MarshalJSON() ([]byte, error) { - type NoMethod VariantTargeting +// TrackRelease: A release within a track. +type TrackRelease struct { + // CountryTargeting: Restricts a release to a specific set of countries. + CountryTargeting *CountryTargeting `json:"countryTargeting,omitempty"` + // InAppUpdatePriority: In-app update priority of the release. All newly added + // APKs in the release will be considered at this priority. Can take values in + // the range [0, 5], with 5 the highest priority. Defaults to 0. + // in_app_update_priority can not be updated once the release is rolled out. + // See https://developer.android.com/guide/playcore/in-app-updates. + InAppUpdatePriority int64 `json:"inAppUpdatePriority,omitempty"` + // Name: The release name. Not required to be unique. If not set, the name is + // generated from the APK's version_name. If the release contains multiple + // APKs, the name is generated from the date. + Name string `json:"name,omitempty"` + // ReleaseNotes: A description of what is new in this release. + ReleaseNotes []*LocalizedText `json:"releaseNotes,omitempty"` + // Status: The status of the release. + // + // Possible values: + // "statusUnspecified" - Unspecified status. + // "draft" - The release's APKs are not being served to users. + // "inProgress" - The release's APKs are being served to a fraction of users, + // determined by 'user_fraction'. + // "halted" - The release's APKs will no longer be served to users. Users who + // already have these APKs are unaffected. + // "completed" - The release will have no further changes. Its APKs are being + // served to all users, unless they are eligible to APKs of a more recent + // release. + Status string `json:"status,omitempty"` + // UserFraction: Fraction of users who are eligible for a staged release. 0 < + // fraction < 1. Can only be set when status is "inProgress" or "halted". + UserFraction float64 `json:"userFraction,omitempty"` + // VersionCodes: Version codes of all APKs in the release. Must include version + // codes to retain from previous releases. + VersionCodes googleapi.Int64s `json:"versionCodes,omitempty"` + // ForceSendFields is a list of field names (e.g. "CountryTargeting") 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. "CountryTargeting") 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 TrackRelease) MarshalJSON() ([]byte, error) { + type NoMethod TrackRelease return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// VoidedPurchase: A VoidedPurchase resource indicates a purchase that was -// either canceled/refunded/charged-back. -type VoidedPurchase struct { - // Kind: This kind represents a voided purchase object in the androidpublisher - // service. +func (s *TrackRelease) UnmarshalJSON(data []byte) error { + type NoMethod TrackRelease + var s1 struct { + UserFraction gensupport.JSONFloat64 `json:"userFraction"` + *NoMethod + } + s1.NoMethod = (*NoMethod)(s) + if err := json.Unmarshal(data, &s1); err != nil { + return err + } + s.UserFraction = float64(s1.UserFraction) + return nil +} + +// TrackTargetedCountry: Representation of a single country where the contents +// of a track are available. +type TrackTargetedCountry struct { + // CountryCode: The country to target, as a two-letter CLDR code. + CountryCode string `json:"countryCode,omitempty"` + // ForceSendFields is a list of field names (e.g. "CountryCode") 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. "CountryCode") 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 TrackTargetedCountry) MarshalJSON() ([]byte, error) { + type NoMethod TrackTargetedCountry + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// TracksListResponse: Response listing all tracks. +type TracksListResponse struct { + // Kind: The kind of this response ("androidpublisher#tracksListResponse"). Kind string `json:"kind,omitempty"` - // OrderId: The order id which uniquely identifies a one-time purchase, - // subscription purchase, or subscription renewal. - OrderId string `json:"orderId,omitempty"` - // PurchaseTimeMillis: The time at which the purchase was made, in milliseconds - // since the epoch (Jan 1, 1970). - PurchaseTimeMillis int64 `json:"purchaseTimeMillis,omitempty,string"` - // PurchaseToken: The token which uniquely identifies a one-time purchase or - // subscription. To uniquely identify subscription renewals use order_id - // (available starting from version 3 of the API). - PurchaseToken string `json:"purchaseToken,omitempty"` - // VoidedQuantity: The voided quantity as the result of a quantity-based - // partial refund. Voided purchases of quantity-based partial refunds may only - // be returned when includeQuantityBasedPartialRefund is set to true. - VoidedQuantity int64 `json:"voidedQuantity,omitempty"` - // VoidedReason: The reason why the purchase was voided, possible values are: - // 0. Other 1. Remorse 2. Not_received 3. Defective 4. Accidental_purchase 5. - // Fraud 6. Friendly_fraud 7. Chargeback 8. Unacknowledged_purchase - VoidedReason int64 `json:"voidedReason,omitempty"` - // VoidedSource: The initiator of voided purchase, possible values are: 0. User - // 1. Developer 2. Google - VoidedSource int64 `json:"voidedSource,omitempty"` - // VoidedTimeMillis: The time at which the purchase was - // canceled/refunded/charged-back, in milliseconds since the epoch (Jan 1, - // 1970). - VoidedTimeMillis int64 `json:"voidedTimeMillis,omitempty,string"` + // Tracks: All tracks (including tracks with no releases). + Tracks []*Track `json:"tracks,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the server. + googleapi.ServerResponse `json:"-"` // 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 @@ -8355,90 +9218,2346 @@ type VoidedPurchase struct { NullFields []string `json:"-"` } -func (s VoidedPurchase) MarshalJSON() ([]byte, error) { - type NoMethod VoidedPurchase +func (s TracksListResponse) MarshalJSON() ([]byte, error) { + type NoMethod TracksListResponse return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// VoidedPurchasesListResponse: Response for the voidedpurchases.list API. -type VoidedPurchasesListResponse struct { - // PageInfo: General pagination information. - PageInfo *PageInfo `json:"pageInfo,omitempty"` - // TokenPagination: Pagination information for token pagination. - TokenPagination *TokenPagination `json:"tokenPagination,omitempty"` - VoidedPurchases []*VoidedPurchase `json:"voidedPurchases,omitempty"` +// UpdateBasePlanStateRequest: Request message to update the state of a +// subscription base plan. +type UpdateBasePlanStateRequest struct { + // ActivateBasePlanRequest: Activates a base plan. Once activated, base plans + // will be available to new subscribers. + ActivateBasePlanRequest *ActivateBasePlanRequest `json:"activateBasePlanRequest,omitempty"` + // DeactivateBasePlanRequest: Deactivates a base plan. Once deactivated, the + // base plan will become unavailable to new subscribers, but existing + // subscribers will maintain their subscription + DeactivateBasePlanRequest *DeactivateBasePlanRequest `json:"deactivateBasePlanRequest,omitempty"` + // ForceSendFields is a list of field names (e.g. "ActivateBasePlanRequest") 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. "ActivateBasePlanRequest") 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:"-"` +} - // ServerResponse contains the HTTP response code and headers from the server. - googleapi.ServerResponse `json:"-"` - // ForceSendFields is a list of field names (e.g. "PageInfo") to +func (s UpdateBasePlanStateRequest) MarshalJSON() ([]byte, error) { + type NoMethod UpdateBasePlanStateRequest + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// UpdateOneTimeProductOfferRequest: Request message for +// UpdateOneTimeProductOffer. +type UpdateOneTimeProductOfferRequest struct { + // AllowMissing: Optional. If set to true, and the offer with the given + // package_name, product_id, purchase_option_id and offer_id doesn't exist, an + // offer will be created. If a new offer is created, the update_mask is + // ignored. + AllowMissing bool `json:"allowMissing,omitempty"` + // LatencyTolerance: Optional. The latency tolerance for the propagation of + // this offer update. Defaults to latency-sensitive. + // + // Possible values: + // "PRODUCT_UPDATE_LATENCY_TOLERANCE_UNSPECIFIED" - Defaults to + // PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_SENSITIVE. + // "PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_SENSITIVE" - The update will + // propagate to clients within several minutes on average and up to a few hours + // in rare cases. Throughput is limited to 7,200 updates per app per hour. + // "PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_TOLERANT" - The update will + // propagate to clients within 24 hours. Supports high throughput of up to + // 720,000 updates per app per hour using batch modification methods. + LatencyTolerance string `json:"latencyTolerance,omitempty"` + // OneTimeProductOffer: Required. The one-time product offer to update. + OneTimeProductOffer *OneTimeProductOffer `json:"oneTimeProductOffer,omitempty"` + // RegionsVersion: Required. The version of the available regions being used + // for the offer. + RegionsVersion *RegionsVersion `json:"regionsVersion,omitempty"` + // UpdateMask: Required. The list of fields to be updated. + UpdateMask string `json:"updateMask,omitempty"` + // ForceSendFields is a list of field names (e.g. "AllowMissing") 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. "PageInfo") to include in API + // NullFields is a list of field names (e.g. "AllowMissing") 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 VoidedPurchasesListResponse) MarshalJSON() ([]byte, error) { - type NoMethod VoidedPurchasesListResponse +func (s UpdateOneTimeProductOfferRequest) MarshalJSON() ([]byte, error) { + type NoMethod UpdateOneTimeProductOfferRequest + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// UpdateOneTimeProductOfferStateRequest: Request message to update the state +// of a one-time product offer. +type UpdateOneTimeProductOfferStateRequest struct { + // ActivateOneTimeProductOfferRequest: Activates an offer. Once activated, the + // offer is available to users, as long as its conditions are met. + ActivateOneTimeProductOfferRequest *ActivateOneTimeProductOfferRequest `json:"activateOneTimeProductOfferRequest,omitempty"` + // CancelOneTimeProductOfferRequest: Cancels an offer. Once cancelled, the + // offer is not available to users. Any pending orders related to this offer + // will be cancelled. This state transition is specific to pre-orders. + CancelOneTimeProductOfferRequest *CancelOneTimeProductOfferRequest `json:"cancelOneTimeProductOfferRequest,omitempty"` + // DeactivateOneTimeProductOfferRequest: Deactivates an offer. Once + // deactivated, the offer is no longer available to users. This state + // transition is specific to discounted offers. + DeactivateOneTimeProductOfferRequest *DeactivateOneTimeProductOfferRequest `json:"deactivateOneTimeProductOfferRequest,omitempty"` + // ForceSendFields is a list of field names (e.g. + // "ActivateOneTimeProductOfferRequest") 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. + // "ActivateOneTimeProductOfferRequest") 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 UpdateOneTimeProductOfferStateRequest) MarshalJSON() ([]byte, error) { + type NoMethod UpdateOneTimeProductOfferStateRequest + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// UpdateOneTimeProductRequest: Request message for UpdateOneTimeProduct. +type UpdateOneTimeProductRequest struct { + // AllowMissing: Optional. If set to true, and the one-time product with the + // given package_name and product_id doesn't exist, the one-time product will + // be created. If a new one-time product is created, update_mask is ignored. + AllowMissing bool `json:"allowMissing,omitempty"` + // LatencyTolerance: Optional. The latency tolerance for the propagation of + // this product upsert. Defaults to latency-sensitive. + // + // Possible values: + // "PRODUCT_UPDATE_LATENCY_TOLERANCE_UNSPECIFIED" - Defaults to + // PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_SENSITIVE. + // "PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_SENSITIVE" - The update will + // propagate to clients within several minutes on average and up to a few hours + // in rare cases. Throughput is limited to 7,200 updates per app per hour. + // "PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_TOLERANT" - The update will + // propagate to clients within 24 hours. Supports high throughput of up to + // 720,000 updates per app per hour using batch modification methods. + LatencyTolerance string `json:"latencyTolerance,omitempty"` + // OneTimeProduct: Required. The one-time product to upsert. + OneTimeProduct *OneTimeProduct `json:"oneTimeProduct,omitempty"` + // RegionsVersion: Required. The version of the available regions being used + // for the one-time product. + RegionsVersion *RegionsVersion `json:"regionsVersion,omitempty"` + // UpdateMask: Required. The list of fields to be updated. + UpdateMask string `json:"updateMask,omitempty"` + // ForceSendFields is a list of field names (e.g. "AllowMissing") 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. "AllowMissing") 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 UpdateOneTimeProductRequest) MarshalJSON() ([]byte, error) { + type NoMethod UpdateOneTimeProductRequest + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// UpdatePurchaseOptionStateRequest: Request message to update the state of a +// one-time product purchase option. +type UpdatePurchaseOptionStateRequest struct { + // ActivatePurchaseOptionRequest: Activates a purchase option. Once activated, + // the purchase option will be available. + ActivatePurchaseOptionRequest *ActivatePurchaseOptionRequest `json:"activatePurchaseOptionRequest,omitempty"` + // DeactivatePurchaseOptionRequest: Deactivates a purchase option. Once + // deactivated, the purchase option will become unavailable. + DeactivatePurchaseOptionRequest *DeactivatePurchaseOptionRequest `json:"deactivatePurchaseOptionRequest,omitempty"` + // ForceSendFields is a list of field names (e.g. + // "ActivatePurchaseOptionRequest") 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. "ActivatePurchaseOptionRequest") + // 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 UpdatePurchaseOptionStateRequest) MarshalJSON() ([]byte, error) { + type NoMethod UpdatePurchaseOptionStateRequest return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -type ApplicationsDataSafetyCall struct { - s *Service - packageName string - safetylabelsupdaterequest *SafetyLabelsUpdateRequest - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +// UpdateSubscriptionOfferRequest: Request message for UpdateSubscriptionOffer. +type UpdateSubscriptionOfferRequest struct { + // AllowMissing: Optional. If set to true, and the subscription offer with the + // given package_name, product_id, base_plan_id and offer_id doesn't exist, an + // offer will be created. If a new offer is created, update_mask is ignored. + AllowMissing bool `json:"allowMissing,omitempty"` + // LatencyTolerance: Optional. The latency tolerance for the propagation of + // this product update. Defaults to latency-sensitive. + // + // Possible values: + // "PRODUCT_UPDATE_LATENCY_TOLERANCE_UNSPECIFIED" - Defaults to + // PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_SENSITIVE. + // "PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_SENSITIVE" - The update will + // propagate to clients within several minutes on average and up to a few hours + // in rare cases. Throughput is limited to 7,200 updates per app per hour. + // "PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_TOLERANT" - The update will + // propagate to clients within 24 hours. Supports high throughput of up to + // 720,000 updates per app per hour using batch modification methods. + LatencyTolerance string `json:"latencyTolerance,omitempty"` + // RegionsVersion: Required. The version of the available regions being used + // for the subscription_offer. + RegionsVersion *RegionsVersion `json:"regionsVersion,omitempty"` + // SubscriptionOffer: Required. The subscription offer to update. + SubscriptionOffer *SubscriptionOffer `json:"subscriptionOffer,omitempty"` + // UpdateMask: Required. The list of fields to be updated. + UpdateMask string `json:"updateMask,omitempty"` + // ForceSendFields is a list of field names (e.g. "AllowMissing") 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. "AllowMissing") 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 UpdateSubscriptionOfferRequest) MarshalJSON() ([]byte, error) { + type NoMethod UpdateSubscriptionOfferRequest + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// UpdateSubscriptionOfferStateRequest: Request message to update the state of +// a subscription offer. +type UpdateSubscriptionOfferStateRequest struct { + // ActivateSubscriptionOfferRequest: Activates an offer. Once activated, the + // offer will be available to new subscribers. + ActivateSubscriptionOfferRequest *ActivateSubscriptionOfferRequest `json:"activateSubscriptionOfferRequest,omitempty"` + // DeactivateSubscriptionOfferRequest: Deactivates an offer. Once deactivated, + // the offer will become unavailable to new subscribers, but existing + // subscribers will maintain their subscription + DeactivateSubscriptionOfferRequest *DeactivateSubscriptionOfferRequest `json:"deactivateSubscriptionOfferRequest,omitempty"` + // ForceSendFields is a list of field names (e.g. + // "ActivateSubscriptionOfferRequest") 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. + // "ActivateSubscriptionOfferRequest") 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 UpdateSubscriptionOfferStateRequest) MarshalJSON() ([]byte, error) { + type NoMethod UpdateSubscriptionOfferStateRequest + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// UpdateSubscriptionRequest: Request message for UpdateSubscription. +type UpdateSubscriptionRequest struct { + // AllowMissing: Optional. If set to true, and the subscription with the given + // package_name and product_id doesn't exist, the subscription will be created. + // If a new subscription is created, update_mask is ignored. + AllowMissing bool `json:"allowMissing,omitempty"` + // LatencyTolerance: Optional. The latency tolerance for the propagation of + // this product update. Defaults to latency-sensitive. + // + // Possible values: + // "PRODUCT_UPDATE_LATENCY_TOLERANCE_UNSPECIFIED" - Defaults to + // PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_SENSITIVE. + // "PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_SENSITIVE" - The update will + // propagate to clients within several minutes on average and up to a few hours + // in rare cases. Throughput is limited to 7,200 updates per app per hour. + // "PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_TOLERANT" - The update will + // propagate to clients within 24 hours. Supports high throughput of up to + // 720,000 updates per app per hour using batch modification methods. + LatencyTolerance string `json:"latencyTolerance,omitempty"` + // RegionsVersion: Required. The version of the available regions being used + // for the subscription. + RegionsVersion *RegionsVersion `json:"regionsVersion,omitempty"` + // Subscription: Required. The subscription to update. + Subscription *Subscription `json:"subscription,omitempty"` + // UpdateMask: Required. The list of fields to be updated. + UpdateMask string `json:"updateMask,omitempty"` + // ForceSendFields is a list of field names (e.g. "AllowMissing") 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. "AllowMissing") 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 UpdateSubscriptionRequest) MarshalJSON() ([]byte, error) { + type NoMethod UpdateSubscriptionRequest + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// UpgradeTargetingRule: Represents a targeting rule of the form: User +// currently has {scope} [with billing period {billing_period}]. +type UpgradeTargetingRule struct { + // BillingPeriodDuration: The specific billing period duration, specified in + // ISO 8601 format, that a user must be currently subscribed to to be eligible + // for this rule. If not specified, users subscribed to any billing period are + // matched. + BillingPeriodDuration string `json:"billingPeriodDuration,omitempty"` + // OncePerUser: Limit this offer to only once per user. If set to true, a user + // can never be eligible for this offer again if they ever subscribed to this + // offer. + OncePerUser bool `json:"oncePerUser,omitempty"` + // Scope: Required. The scope of subscriptions this rule considers. Only allows + // "this subscription" and "specific subscription in app". + Scope *TargetingRuleScope `json:"scope,omitempty"` + // ForceSendFields is a list of field names (e.g. "BillingPeriodDuration") 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. "BillingPeriodDuration") 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 UpgradeTargetingRule) MarshalJSON() ([]byte, error) { + type NoMethod UpgradeTargetingRule + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// User: A user resource. +type User struct { + // AccessState: Output only. The state of the user's access to the Play + // Console. + // + // Possible values: + // "ACCESS_STATE_UNSPECIFIED" - Unknown or unspecified access state. + // "INVITED" - User is invited but has not yet accepted the invitation. + // "INVITATION_EXPIRED" - Invitation has expired. + // "ACCESS_GRANTED" - User has accepted an invitation and has access to the + // Play Console. + // "ACCESS_EXPIRED" - Account access has expired. + AccessState string `json:"accessState,omitempty"` + // DeveloperAccountPermissions: Permissions for the user which apply across the + // developer account. + // + // Possible values: + // "DEVELOPER_LEVEL_PERMISSION_UNSPECIFIED" - Unknown or unspecified + // permission. + // "CAN_SEE_ALL_APPS" - View app information and download bulk reports + // (read-only). Deprecated: Check CAN_VIEW_NON_FINANCIAL_DATA_GLOBAL. + // "CAN_VIEW_FINANCIAL_DATA_GLOBAL" - View financial data, orders, and + // cancellation survey responses. + // "CAN_MANAGE_PERMISSIONS_GLOBAL" - Admin (all permissions). + // "CAN_EDIT_GAMES_GLOBAL" - Edit Play Games Services projects. + // "CAN_PUBLISH_GAMES_GLOBAL" - Publish Play Games Services projects. + // "CAN_REPLY_TO_REVIEWS_GLOBAL" - Reply to reviews. + // "CAN_MANAGE_PUBLIC_APKS_GLOBAL" - Release to production, exclude devices, + // and use app signing by Google Play. + // "CAN_MANAGE_TRACK_APKS_GLOBAL" - Release to testing tracks. + // "CAN_MANAGE_TRACK_USERS_GLOBAL" - Manage testing tracks and edit tester + // lists. + // "CAN_MANAGE_PUBLIC_LISTING_GLOBAL" - Manage store presence. + // "CAN_MANAGE_DRAFT_APPS_GLOBAL" - Create, edit, and delete draft apps. + // "CAN_CREATE_MANAGED_PLAY_APPS_GLOBAL" - Create and publish private apps to + // your organization. + // "CAN_CHANGE_MANAGED_PLAY_SETTING_GLOBAL" - Choose whether apps are public, + // or only available to your organization. + // "CAN_MANAGE_ORDERS_GLOBAL" - Manage orders and subscriptions. + // "CAN_MANAGE_APP_CONTENT_GLOBAL" - Manage policy related pages on all apps + // for the developer. + // "CAN_VIEW_NON_FINANCIAL_DATA_GLOBAL" - View app information and download + // bulk reports (read-only). + // "CAN_VIEW_APP_QUALITY_GLOBAL" - View app quality information for all apps + // for the developer. + // "CAN_MANAGE_DEEPLINKS_GLOBAL" - Manage the deep links setup for all apps + // for the developer. + DeveloperAccountPermissions []string `json:"developerAccountPermissions,omitempty"` + // Email: Immutable. The user's email address. + Email string `json:"email,omitempty"` + // ExpirationTime: The time at which the user's access expires, if set. When + // setting this value, it must always be in the future. + ExpirationTime string `json:"expirationTime,omitempty"` + // Grants: Output only. Per-app permissions for the user. + Grants []*Grant `json:"grants,omitempty"` + // Name: Required. Resource name for this user, following the pattern + // "developers/{developer}/users/{email}". + Name string `json:"name,omitempty"` + // Partial: Output only. Whether there are more permissions for the user that + // are not represented here. This can happen if the caller does not have + // permission to manage all apps in the account. This is also `true` if this + // user is the account owner. If this field is `true`, it should be taken as a + // signal that this user cannot be fully managed via the API. That is, the API + // caller is not be able to manage all of the permissions this user holds, + // either because it doesn't know about them or because the user is the account + // owner. + Partial bool `json:"partial,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the server. + googleapi.ServerResponse `json:"-"` + // ForceSendFields is a list of field names (e.g. "AccessState") 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. "AccessState") 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 User) MarshalJSON() ([]byte, error) { + type NoMethod User + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// UserComment: User entry from conversation between user and developer. +type UserComment struct { + // AndroidOsVersion: Integer Android SDK version of the user's device at the + // time the review was written, e.g. 23 is Marshmallow. May be absent. + AndroidOsVersion int64 `json:"androidOsVersion,omitempty"` + // AppVersionCode: Integer version code of the app as installed at the time the + // review was written. May be absent. + AppVersionCode int64 `json:"appVersionCode,omitempty"` + // AppVersionName: String version name of the app as installed at the time the + // review was written. May be absent. + AppVersionName string `json:"appVersionName,omitempty"` + // Device: Codename for the reviewer's device, e.g. klte, flounder. May be + // absent. + Device string `json:"device,omitempty"` + // DeviceMetadata: Information about the characteristics of the user's device. + DeviceMetadata *DeviceMetadata `json:"deviceMetadata,omitempty"` + // LastModified: The last time at which this comment was updated. + LastModified *Timestamp `json:"lastModified,omitempty"` + // OriginalText: Untranslated text of the review, where the review was + // translated. If the review was not translated this is left blank. + OriginalText string `json:"originalText,omitempty"` + // ReviewerLanguage: Language code for the reviewer. This is taken from the + // device settings so is not guaranteed to match the language the review is + // written in. May be absent. + ReviewerLanguage string `json:"reviewerLanguage,omitempty"` + // StarRating: The star rating associated with the review, from 1 to 5. + StarRating int64 `json:"starRating,omitempty"` + // Text: The content of the comment, i.e. review body. In some cases users have + // been able to write a review with separate title and body; in those cases the + // title and body are concatenated and separated by a tab character. + Text string `json:"text,omitempty"` + // ThumbsDownCount: Number of users who have given this review a thumbs down. + ThumbsDownCount int64 `json:"thumbsDownCount,omitempty"` + // ThumbsUpCount: Number of users who have given this review a thumbs up. + ThumbsUpCount int64 `json:"thumbsUpCount,omitempty"` + // ForceSendFields is a list of field names (e.g. "AndroidOsVersion") 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. "AndroidOsVersion") 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 UserComment) MarshalJSON() ([]byte, error) { + type NoMethod UserComment + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// UserCountriesTargeting: Describes an inclusive/exclusive list of country +// codes that module targets. +type UserCountriesTargeting struct { + // CountryCodes: List of country codes in the two-letter CLDR territory format. + CountryCodes []string `json:"countryCodes,omitempty"` + // Exclude: Indicates if the list above is exclusive. + Exclude bool `json:"exclude,omitempty"` + // ForceSendFields is a list of field names (e.g. "CountryCodes") 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. "CountryCodes") 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 UserCountriesTargeting) MarshalJSON() ([]byte, error) { + type NoMethod UserCountriesTargeting + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// UserCountrySet: A set of user countries. A country set determines what +// variation of app content gets served to a specific location. +type UserCountrySet struct { + // CountryCodes: List of country codes representing countries. A Country code + // is represented in ISO 3166 alpha-2 format. For Example:- "IT" for Italy, + // "GE" for Georgia. + CountryCodes []string `json:"countryCodes,omitempty"` + // Name: Country set name. + Name string `json:"name,omitempty"` + // ForceSendFields is a list of field names (e.g. "CountryCodes") 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. "CountryCodes") 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 UserCountrySet) MarshalJSON() ([]byte, error) { + type NoMethod UserCountrySet + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// UserInitiatedCancellation: Information specific to cancellations initiated +// by users. +type UserInitiatedCancellation struct { + // CancelSurveyResult: Information provided by the user when they complete the + // subscription cancellation flow (cancellation reason survey). + CancelSurveyResult *CancelSurveyResult `json:"cancelSurveyResult,omitempty"` + // CancelTime: The time at which the subscription was canceled by the user. The + // user might still have access to the subscription after this time. Use + // line_items.expiry_time to determine if a user still has access. + CancelTime string `json:"cancelTime,omitempty"` + // ForceSendFields is a list of field names (e.g. "CancelSurveyResult") 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. "CancelSurveyResult") 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 UserInitiatedCancellation) MarshalJSON() ([]byte, error) { + type NoMethod UserInitiatedCancellation + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// UsesPermission: A permission used by this APK. +type UsesPermission struct { + // MaxSdkVersion: Optionally, the maximum SDK version for which the permission + // is required. + MaxSdkVersion int64 `json:"maxSdkVersion,omitempty"` + // Name: The name of the permission requested. + Name string `json:"name,omitempty"` + // ForceSendFields is a list of field names (e.g. "MaxSdkVersion") 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. "MaxSdkVersion") 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 UsesPermission) MarshalJSON() ([]byte, error) { + type NoMethod UsesPermission + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// VanityCode: A multiple use, predefined promotion code. +type VanityCode struct { + // PromotionCode: The promotion code. + PromotionCode string `json:"promotionCode,omitempty"` + // ForceSendFields is a list of field names (e.g. "PromotionCode") 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. "PromotionCode") 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 VanityCode) MarshalJSON() ([]byte, error) { + type NoMethod VanityCode + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// Variant: APK that is suitable for inclusion in a system image. The resource +// of SystemApksService. +type Variant struct { + // DeviceSpec: The device spec used to generate the APK. + DeviceSpec *DeviceSpec `json:"deviceSpec,omitempty"` + // Options: Optional. Options applied to the generated APK. + Options *SystemApkOptions `json:"options,omitempty"` + // VariantId: Output only. The ID of a previously created system APK variant. + VariantId int64 `json:"variantId,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the server. + googleapi.ServerResponse `json:"-"` + // ForceSendFields is a list of field names (e.g. "DeviceSpec") 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. "DeviceSpec") 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 Variant) MarshalJSON() ([]byte, error) { + type NoMethod Variant + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// VariantTargeting: Targeting on the level of variants. +type VariantTargeting struct { + // AbiTargeting: The abi that the variant targets + AbiTargeting *AbiTargeting `json:"abiTargeting,omitempty"` + // MultiAbiTargeting: Multi-api-level targeting + MultiAbiTargeting *MultiAbiTargeting `json:"multiAbiTargeting,omitempty"` + // ScreenDensityTargeting: The screen densities that this variant supports + ScreenDensityTargeting *ScreenDensityTargeting `json:"screenDensityTargeting,omitempty"` + // SdkVersionTargeting: The sdk version that the variant targets + SdkVersionTargeting *SdkVersionTargeting `json:"sdkVersionTargeting,omitempty"` + // TextureCompressionFormatTargeting: Texture-compression-format-level + // targeting + TextureCompressionFormatTargeting *TextureCompressionFormatTargeting `json:"textureCompressionFormatTargeting,omitempty"` + // ForceSendFields is a list of field names (e.g. "AbiTargeting") 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. "AbiTargeting") 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 VariantTargeting) MarshalJSON() ([]byte, error) { + type NoMethod VariantTargeting + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// VoidedPurchase: A VoidedPurchase resource indicates a purchase that was +// either canceled/refunded/charged-back. +type VoidedPurchase struct { + // Kind: This kind represents a voided purchase object in the androidpublisher + // service. + Kind string `json:"kind,omitempty"` + // OrderId: The order id which uniquely identifies a one-time purchase, + // subscription purchase, or subscription renewal. + OrderId string `json:"orderId,omitempty"` + // PurchaseTimeMillis: The time at which the purchase was made, in milliseconds + // since the epoch (Jan 1, 1970). + PurchaseTimeMillis int64 `json:"purchaseTimeMillis,omitempty,string"` + // PurchaseToken: The token which uniquely identifies a one-time purchase or + // subscription. To uniquely identify subscription renewals use order_id + // (available starting from version 3 of the API). + PurchaseToken string `json:"purchaseToken,omitempty"` + // VoidedQuantity: The voided quantity as the result of a quantity-based + // partial refund. Voided purchases of quantity-based partial refunds may only + // be returned when includeQuantityBasedPartialRefund is set to true. + VoidedQuantity int64 `json:"voidedQuantity,omitempty"` + // VoidedReason: The reason why the purchase was voided, possible values are: + // 0. Other 1. Remorse 2. Not_received 3. Defective 4. Accidental_purchase 5. + // Fraud 6. Friendly_fraud 7. Chargeback 8. Unacknowledged_purchase + VoidedReason int64 `json:"voidedReason,omitempty"` + // VoidedSource: The initiator of voided purchase, possible values are: 0. User + // 1. Developer 2. Google + VoidedSource int64 `json:"voidedSource,omitempty"` + // VoidedTimeMillis: The time at which the purchase was + // canceled/refunded/charged-back, in milliseconds since the epoch (Jan 1, + // 1970). + VoidedTimeMillis int64 `json:"voidedTimeMillis,omitempty,string"` + // 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 VoidedPurchase) MarshalJSON() ([]byte, error) { + type NoMethod VoidedPurchase + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// VoidedPurchasesListResponse: Response for the voidedpurchases.list API. +type VoidedPurchasesListResponse struct { + // PageInfo: General pagination information. + PageInfo *PageInfo `json:"pageInfo,omitempty"` + // TokenPagination: Pagination information for token pagination. + TokenPagination *TokenPagination `json:"tokenPagination,omitempty"` + VoidedPurchases []*VoidedPurchase `json:"voidedPurchases,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the server. + googleapi.ServerResponse `json:"-"` + // ForceSendFields is a list of field names (e.g. "PageInfo") 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. "PageInfo") 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 VoidedPurchasesListResponse) MarshalJSON() ([]byte, error) { + type NoMethod VoidedPurchasesListResponse + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +type ApplicationsDataSafetyCall struct { + s *Service + packageName string + safetylabelsupdaterequest *SafetyLabelsUpdateRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// DataSafety: Writes the Safety Labels declaration of an app. +// +// - packageName: Package name of the app. +func (r *ApplicationsService) DataSafety(packageName string, safetylabelsupdaterequest *SafetyLabelsUpdateRequest) *ApplicationsDataSafetyCall { + c := &ApplicationsDataSafetyCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.packageName = packageName + c.safetylabelsupdaterequest = safetylabelsupdaterequest + 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 *ApplicationsDataSafetyCall) Fields(s ...googleapi.Field) *ApplicationsDataSafetyCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ApplicationsDataSafetyCall) Context(ctx context.Context) *ApplicationsDataSafetyCall { + 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 *ApplicationsDataSafetyCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ApplicationsDataSafetyCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) + body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.safetylabelsupdaterequest) + if err != nil { + return nil, err + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/dataSafety") + 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{ + "packageName": c.packageName, + }) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.applications.dataSafety", "request", internallog.HTTPRequest(req, body.Bytes())) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "androidpublisher.applications.dataSafety" call. +// Any non-2xx status code is an error. Response headers are in either +// *SafetyLabelsUpdateResponse.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 *ApplicationsDataSafetyCall) Do(opts ...googleapi.CallOption) (*SafetyLabelsUpdateResponse, 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 := &SafetyLabelsUpdateResponse{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + b, err := gensupport.DecodeResponseBytes(target, res) + if err != nil { + return nil, err + } + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.applications.dataSafety", "response", internallog.HTTPResponse(res, b)) + return ret, nil +} + +type ApplicationsDeviceTierConfigsCreateCall struct { + s *Service + packageName string + devicetierconfig *DeviceTierConfig + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Create: Creates a new device tier config for an app. +// +// - packageName: Package name of the app. +func (r *ApplicationsDeviceTierConfigsService) Create(packageName string, devicetierconfig *DeviceTierConfig) *ApplicationsDeviceTierConfigsCreateCall { + c := &ApplicationsDeviceTierConfigsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.packageName = packageName + c.devicetierconfig = devicetierconfig + return c +} + +// AllowUnknownDevices sets the optional parameter "allowUnknownDevices": +// Whether the service should accept device IDs that are unknown to Play's +// device catalog. +func (c *ApplicationsDeviceTierConfigsCreateCall) AllowUnknownDevices(allowUnknownDevices bool) *ApplicationsDeviceTierConfigsCreateCall { + c.urlParams_.Set("allowUnknownDevices", fmt.Sprint(allowUnknownDevices)) + 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 *ApplicationsDeviceTierConfigsCreateCall) Fields(s ...googleapi.Field) *ApplicationsDeviceTierConfigsCreateCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ApplicationsDeviceTierConfigsCreateCall) Context(ctx context.Context) *ApplicationsDeviceTierConfigsCreateCall { + 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 *ApplicationsDeviceTierConfigsCreateCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ApplicationsDeviceTierConfigsCreateCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) + body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.devicetierconfig) + if err != nil { + return nil, err + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/deviceTierConfigs") + 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{ + "packageName": c.packageName, + }) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.applications.deviceTierConfigs.create", "request", internallog.HTTPRequest(req, body.Bytes())) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "androidpublisher.applications.deviceTierConfigs.create" call. +// Any non-2xx status code is an error. Response headers are in either +// *DeviceTierConfig.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 *ApplicationsDeviceTierConfigsCreateCall) Do(opts ...googleapi.CallOption) (*DeviceTierConfig, 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 := &DeviceTierConfig{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + b, err := gensupport.DecodeResponseBytes(target, res) + if err != nil { + return nil, err + } + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.applications.deviceTierConfigs.create", "response", internallog.HTTPResponse(res, b)) + return ret, nil +} + +type ApplicationsDeviceTierConfigsGetCall struct { + s *Service + packageName string + deviceTierConfigId int64 + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// Get: Returns a particular device tier config. +// +// - deviceTierConfigId: Id of an existing device tier config. +// - packageName: Package name of the app. +func (r *ApplicationsDeviceTierConfigsService) Get(packageName string, deviceTierConfigId int64) *ApplicationsDeviceTierConfigsGetCall { + c := &ApplicationsDeviceTierConfigsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.packageName = packageName + c.deviceTierConfigId = deviceTierConfigId + 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 *ApplicationsDeviceTierConfigsGetCall) Fields(s ...googleapi.Field) *ApplicationsDeviceTierConfigsGetCall { + 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 *ApplicationsDeviceTierConfigsGetCall) IfNoneMatch(entityTag string) *ApplicationsDeviceTierConfigsGetCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ApplicationsDeviceTierConfigsGetCall) Context(ctx context.Context) *ApplicationsDeviceTierConfigsGetCall { + 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 *ApplicationsDeviceTierConfigsGetCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ApplicationsDeviceTierConfigsGetCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/deviceTierConfigs/{deviceTierConfigId}") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("GET", urls, nil) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "packageName": c.packageName, + "deviceTierConfigId": strconv.FormatInt(c.deviceTierConfigId, 10), + }) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.applications.deviceTierConfigs.get", "request", internallog.HTTPRequest(req, nil)) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "androidpublisher.applications.deviceTierConfigs.get" call. +// Any non-2xx status code is an error. Response headers are in either +// *DeviceTierConfig.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 *ApplicationsDeviceTierConfigsGetCall) Do(opts ...googleapi.CallOption) (*DeviceTierConfig, 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 := &DeviceTierConfig{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + b, err := gensupport.DecodeResponseBytes(target, res) + if err != nil { + return nil, err + } + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.applications.deviceTierConfigs.get", "response", internallog.HTTPResponse(res, b)) + return ret, nil +} + +type ApplicationsDeviceTierConfigsListCall struct { + s *Service + packageName string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// List: Returns created device tier configs, ordered by descending creation +// time. +// +// - packageName: Package name of the app. +func (r *ApplicationsDeviceTierConfigsService) List(packageName string) *ApplicationsDeviceTierConfigsListCall { + c := &ApplicationsDeviceTierConfigsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.packageName = packageName + return c +} + +// PageSize sets the optional parameter "pageSize": The maximum number of +// device tier configs to return. The service may return fewer than this value. +// If unspecified, at most 10 device tier configs will be returned. The maximum +// value for this field is 100; values above 100 will be coerced to 100. Device +// tier configs will be ordered by descending creation time. +func (c *ApplicationsDeviceTierConfigsListCall) PageSize(pageSize int64) *ApplicationsDeviceTierConfigsListCall { + c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) + return c +} + +// PageToken sets the optional parameter "pageToken": A page token, received +// from a previous `ListDeviceTierConfigs` call. Provide this to retrieve the +// subsequent page. +func (c *ApplicationsDeviceTierConfigsListCall) PageToken(pageToken string) *ApplicationsDeviceTierConfigsListCall { + 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 *ApplicationsDeviceTierConfigsListCall) Fields(s ...googleapi.Field) *ApplicationsDeviceTierConfigsListCall { + 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 *ApplicationsDeviceTierConfigsListCall) IfNoneMatch(entityTag string) *ApplicationsDeviceTierConfigsListCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ApplicationsDeviceTierConfigsListCall) Context(ctx context.Context) *ApplicationsDeviceTierConfigsListCall { + 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 *ApplicationsDeviceTierConfigsListCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ApplicationsDeviceTierConfigsListCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/deviceTierConfigs") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("GET", urls, nil) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "packageName": c.packageName, + }) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.applications.deviceTierConfigs.list", "request", internallog.HTTPRequest(req, nil)) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "androidpublisher.applications.deviceTierConfigs.list" call. +// Any non-2xx status code is an error. Response headers are in either +// *ListDeviceTierConfigsResponse.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 *ApplicationsDeviceTierConfigsListCall) Do(opts ...googleapi.CallOption) (*ListDeviceTierConfigsResponse, 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 := &ListDeviceTierConfigsResponse{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + b, err := gensupport.DecodeResponseBytes(target, res) + if err != nil { + return nil, err + } + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.applications.deviceTierConfigs.list", "response", internallog.HTTPResponse(res, b)) + 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 *ApplicationsDeviceTierConfigsListCall) Pages(ctx context.Context, f func(*ListDeviceTierConfigsResponse) 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 ApprecoveryAddTargetingCall struct { + s *Service + packageName string + appRecoveryId int64 + addtargetingrequest *AddTargetingRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// AddTargeting: Incrementally update targeting for a recovery action. Note +// that only the criteria selected during the creation of recovery action can +// be expanded. +// +// - appRecoveryId: ID corresponding to the app recovery action. +// - packageName: Package name of the app for which recovery action is to be +// updated. +func (r *ApprecoveryService) AddTargeting(packageName string, appRecoveryId int64, addtargetingrequest *AddTargetingRequest) *ApprecoveryAddTargetingCall { + c := &ApprecoveryAddTargetingCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.packageName = packageName + c.appRecoveryId = appRecoveryId + c.addtargetingrequest = addtargetingrequest + 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 *ApprecoveryAddTargetingCall) Fields(s ...googleapi.Field) *ApprecoveryAddTargetingCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ApprecoveryAddTargetingCall) Context(ctx context.Context) *ApprecoveryAddTargetingCall { + 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 *ApprecoveryAddTargetingCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ApprecoveryAddTargetingCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) + body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.addtargetingrequest) + if err != nil { + return nil, err + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/appRecoveries/{appRecoveryId}:addTargeting") + 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{ + "packageName": c.packageName, + "appRecoveryId": strconv.FormatInt(c.appRecoveryId, 10), + }) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.apprecovery.addTargeting", "request", internallog.HTTPRequest(req, body.Bytes())) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "androidpublisher.apprecovery.addTargeting" call. +// Any non-2xx status code is an error. Response headers are in either +// *AddTargetingResponse.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 *ApprecoveryAddTargetingCall) Do(opts ...googleapi.CallOption) (*AddTargetingResponse, 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 := &AddTargetingResponse{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + b, err := gensupport.DecodeResponseBytes(target, res) + if err != nil { + return nil, err + } + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.apprecovery.addTargeting", "response", internallog.HTTPResponse(res, b)) + return ret, nil +} + +type ApprecoveryCancelCall struct { + s *Service + packageName string + appRecoveryId int64 + cancelapprecoveryrequest *CancelAppRecoveryRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Cancel: Cancel an already executing app recovery action. Note that this +// action changes status of the recovery action to CANCELED. +// +// - appRecoveryId: ID corresponding to the app recovery action. +// - packageName: Package name of the app for which recovery action +// cancellation is requested. +func (r *ApprecoveryService) Cancel(packageName string, appRecoveryId int64, cancelapprecoveryrequest *CancelAppRecoveryRequest) *ApprecoveryCancelCall { + c := &ApprecoveryCancelCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.packageName = packageName + c.appRecoveryId = appRecoveryId + c.cancelapprecoveryrequest = cancelapprecoveryrequest + 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 *ApprecoveryCancelCall) Fields(s ...googleapi.Field) *ApprecoveryCancelCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ApprecoveryCancelCall) Context(ctx context.Context) *ApprecoveryCancelCall { + 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 *ApprecoveryCancelCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ApprecoveryCancelCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) + body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.cancelapprecoveryrequest) + if err != nil { + return nil, err + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/appRecoveries/{appRecoveryId}: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{ + "packageName": c.packageName, + "appRecoveryId": strconv.FormatInt(c.appRecoveryId, 10), + }) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.apprecovery.cancel", "request", internallog.HTTPRequest(req, body.Bytes())) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "androidpublisher.apprecovery.cancel" call. +// Any non-2xx status code is an error. Response headers are in either +// *CancelAppRecoveryResponse.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 *ApprecoveryCancelCall) Do(opts ...googleapi.CallOption) (*CancelAppRecoveryResponse, 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 := &CancelAppRecoveryResponse{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + b, err := gensupport.DecodeResponseBytes(target, res) + if err != nil { + return nil, err + } + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.apprecovery.cancel", "response", internallog.HTTPResponse(res, b)) + return ret, nil +} + +type ApprecoveryCreateCall struct { + s *Service + packageName string + createdraftapprecoveryrequest *CreateDraftAppRecoveryRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Create: Create an app recovery action with recovery status as DRAFT. Note +// that this action does not execute the recovery action. +// +// - packageName: Package name of the app on which recovery action is +// performed. +func (r *ApprecoveryService) Create(packageName string, createdraftapprecoveryrequest *CreateDraftAppRecoveryRequest) *ApprecoveryCreateCall { + c := &ApprecoveryCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.packageName = packageName + c.createdraftapprecoveryrequest = createdraftapprecoveryrequest + 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 *ApprecoveryCreateCall) Fields(s ...googleapi.Field) *ApprecoveryCreateCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ApprecoveryCreateCall) Context(ctx context.Context) *ApprecoveryCreateCall { + 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 *ApprecoveryCreateCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ApprecoveryCreateCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) + body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.createdraftapprecoveryrequest) + if err != nil { + return nil, err + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/appRecoveries") + 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{ + "packageName": c.packageName, + }) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.apprecovery.create", "request", internallog.HTTPRequest(req, body.Bytes())) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "androidpublisher.apprecovery.create" call. +// Any non-2xx status code is an error. Response headers are in either +// *AppRecoveryAction.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 *ApprecoveryCreateCall) Do(opts ...googleapi.CallOption) (*AppRecoveryAction, 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 := &AppRecoveryAction{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + b, err := gensupport.DecodeResponseBytes(target, res) + if err != nil { + return nil, err + } + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.apprecovery.create", "response", internallog.HTTPResponse(res, b)) + return ret, nil +} + +type ApprecoveryDeployCall struct { + s *Service + packageName string + appRecoveryId int64 + deployapprecoveryrequest *DeployAppRecoveryRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Deploy: Deploy an already created app recovery action with recovery status +// DRAFT. Note that this action activates the recovery action for all targeted +// users and changes its status to ACTIVE. +// +// - appRecoveryId: ID corresponding to the app recovery action to deploy. +// - packageName: Package name of the app for which recovery action is +// deployed. +func (r *ApprecoveryService) Deploy(packageName string, appRecoveryId int64, deployapprecoveryrequest *DeployAppRecoveryRequest) *ApprecoveryDeployCall { + c := &ApprecoveryDeployCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.packageName = packageName + c.appRecoveryId = appRecoveryId + c.deployapprecoveryrequest = deployapprecoveryrequest + 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 *ApprecoveryDeployCall) Fields(s ...googleapi.Field) *ApprecoveryDeployCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ApprecoveryDeployCall) Context(ctx context.Context) *ApprecoveryDeployCall { + 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 *ApprecoveryDeployCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ApprecoveryDeployCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) + body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.deployapprecoveryrequest) + if err != nil { + return nil, err + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/appRecoveries/{appRecoveryId}:deploy") + 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{ + "packageName": c.packageName, + "appRecoveryId": strconv.FormatInt(c.appRecoveryId, 10), + }) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.apprecovery.deploy", "request", internallog.HTTPRequest(req, body.Bytes())) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "androidpublisher.apprecovery.deploy" call. +// Any non-2xx status code is an error. Response headers are in either +// *DeployAppRecoveryResponse.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 *ApprecoveryDeployCall) Do(opts ...googleapi.CallOption) (*DeployAppRecoveryResponse, 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 := &DeployAppRecoveryResponse{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + b, err := gensupport.DecodeResponseBytes(target, res) + if err != nil { + return nil, err + } + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.apprecovery.deploy", "response", internallog.HTTPResponse(res, b)) + return ret, nil +} + +type ApprecoveryListCall struct { + s *Service + packageName string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// List: List all app recovery action resources associated with a particular +// package name and app version. +// +// - packageName: Package name of the app for which list of recovery actions is +// requested. +func (r *ApprecoveryService) List(packageName string) *ApprecoveryListCall { + c := &ApprecoveryListCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.packageName = packageName + return c +} + +// VersionCode sets the optional parameter "versionCode": Required. Version +// code targeted by the list of recovery actions. +func (c *ApprecoveryListCall) VersionCode(versionCode int64) *ApprecoveryListCall { + c.urlParams_.Set("versionCode", fmt.Sprint(versionCode)) + 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 *ApprecoveryListCall) Fields(s ...googleapi.Field) *ApprecoveryListCall { + 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 *ApprecoveryListCall) IfNoneMatch(entityTag string) *ApprecoveryListCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ApprecoveryListCall) Context(ctx context.Context) *ApprecoveryListCall { + 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 *ApprecoveryListCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ApprecoveryListCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/appRecoveries") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("GET", urls, nil) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "packageName": c.packageName, + }) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.apprecovery.list", "request", internallog.HTTPRequest(req, nil)) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "androidpublisher.apprecovery.list" call. +// Any non-2xx status code is an error. Response headers are in either +// *ListAppRecoveriesResponse.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 *ApprecoveryListCall) Do(opts ...googleapi.CallOption) (*ListAppRecoveriesResponse, 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 := &ListAppRecoveriesResponse{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + b, err := gensupport.DecodeResponseBytes(target, res) + if err != nil { + return nil, err + } + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.apprecovery.list", "response", internallog.HTTPResponse(res, b)) + return ret, nil +} + +type EditsCommitCall struct { + s *Service + packageName string + editId string + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Commit: Commits an app edit. +// +// - editId: Identifier of the edit. +// - packageName: Package name of the app. +func (r *EditsService) Commit(packageName string, editId string) *EditsCommitCall { + c := &EditsCommitCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.packageName = packageName + c.editId = editId + return c +} + +// ChangesNotSentForReview sets the optional parameter +// "changesNotSentForReview": When a rejection happens, the parameter will make +// sure that the changes in this edit won't be reviewed until they are +// explicitly sent for review from within the Google Play Console UI. These +// changes will be added to any other changes that are not yet sent for review. +func (c *EditsCommitCall) ChangesNotSentForReview(changesNotSentForReview bool) *EditsCommitCall { + c.urlParams_.Set("changesNotSentForReview", fmt.Sprint(changesNotSentForReview)) + 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 *EditsCommitCall) Fields(s ...googleapi.Field) *EditsCommitCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *EditsCommitCall) Context(ctx context.Context) *EditsCommitCall { + 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 *EditsCommitCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *EditsCommitCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}:commit") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("POST", urls, nil) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "packageName": c.packageName, + "editId": c.editId, + }) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.edits.commit", "request", internallog.HTTPRequest(req, nil)) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "androidpublisher.edits.commit" call. +// Any non-2xx status code is an error. Response headers are in either +// *AppEdit.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 *EditsCommitCall) Do(opts ...googleapi.CallOption) (*AppEdit, 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 := &AppEdit{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + b, err := gensupport.DecodeResponseBytes(target, res) + if err != nil { + return nil, err + } + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.edits.commit", "response", internallog.HTTPResponse(res, b)) + return ret, nil +} + +type EditsDeleteCall struct { + s *Service + packageName string + editId string + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Delete: Deletes an app edit. +// +// - editId: Identifier of the edit. +// - packageName: Package name of the app. +func (r *EditsService) Delete(packageName string, editId string) *EditsDeleteCall { + c := &EditsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.packageName = packageName + c.editId = editId + 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 *EditsDeleteCall) Fields(s ...googleapi.Field) *EditsDeleteCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *EditsDeleteCall) Context(ctx context.Context) *EditsDeleteCall { + 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 *EditsDeleteCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *EditsDeleteCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("DELETE", urls, nil) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "packageName": c.packageName, + "editId": c.editId, + }) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.edits.delete", "request", internallog.HTTPRequest(req, nil)) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "androidpublisher.edits.delete" call. +func (c *EditsDeleteCall) 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) + } + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.edits.delete", "response", internallog.HTTPResponse(res, nil)) + return nil +} + +type EditsGetCall struct { + s *Service + packageName string + editId string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// Get: Gets an app edit. +// +// - editId: Identifier of the edit. +// - packageName: Package name of the app. +func (r *EditsService) Get(packageName string, editId string) *EditsGetCall { + c := &EditsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.packageName = packageName + c.editId = editId + 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 *EditsGetCall) Fields(s ...googleapi.Field) *EditsGetCall { + 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 *EditsGetCall) IfNoneMatch(entityTag string) *EditsGetCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *EditsGetCall) Context(ctx context.Context) *EditsGetCall { + 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 *EditsGetCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *EditsGetCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("GET", urls, nil) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "packageName": c.packageName, + "editId": c.editId, + }) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.edits.get", "request", internallog.HTTPRequest(req, nil)) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "androidpublisher.edits.get" call. +// Any non-2xx status code is an error. Response headers are in either +// *AppEdit.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 *EditsGetCall) Do(opts ...googleapi.CallOption) (*AppEdit, 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 := &AppEdit{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + b, err := gensupport.DecodeResponseBytes(target, res) + if err != nil { + return nil, err + } + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.edits.get", "response", internallog.HTTPResponse(res, b)) + return ret, nil +} + +type EditsInsertCall struct { + s *Service + packageName string + appedit *AppEdit + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Insert: Creates a new edit for an app. +// +// - packageName: Package name of the app. +func (r *EditsService) Insert(packageName string, appedit *AppEdit) *EditsInsertCall { + c := &EditsInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.packageName = packageName + c.appedit = appedit + 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 *EditsInsertCall) Fields(s ...googleapi.Field) *EditsInsertCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *EditsInsertCall) Context(ctx context.Context) *EditsInsertCall { + 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 *EditsInsertCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *EditsInsertCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) + body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.appedit) + if err != nil { + return nil, err + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits") + 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{ + "packageName": c.packageName, + }) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.edits.insert", "request", internallog.HTTPRequest(req, body.Bytes())) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "androidpublisher.edits.insert" call. +// Any non-2xx status code is an error. Response headers are in either +// *AppEdit.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 *EditsInsertCall) Do(opts ...googleapi.CallOption) (*AppEdit, 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 := &AppEdit{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + b, err := gensupport.DecodeResponseBytes(target, res) + if err != nil { + return nil, err + } + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.edits.insert", "response", internallog.HTTPResponse(res, b)) + return ret, nil +} + +type EditsValidateCall struct { + s *Service + packageName string + editId string + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Validate: Validates an app edit. +// +// - editId: Identifier of the edit. +// - packageName: Package name of the app. +func (r *EditsService) Validate(packageName string, editId string) *EditsValidateCall { + c := &EditsValidateCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.packageName = packageName + c.editId = editId + 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 *EditsValidateCall) Fields(s ...googleapi.Field) *EditsValidateCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *EditsValidateCall) Context(ctx context.Context) *EditsValidateCall { + 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 *EditsValidateCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *EditsValidateCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}:validate") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("POST", urls, nil) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "packageName": c.packageName, + "editId": c.editId, + }) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.edits.validate", "request", internallog.HTTPRequest(req, nil)) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "androidpublisher.edits.validate" call. +// Any non-2xx status code is an error. Response headers are in either +// *AppEdit.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 *EditsValidateCall) Do(opts ...googleapi.CallOption) (*AppEdit, 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 := &AppEdit{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + b, err := gensupport.DecodeResponseBytes(target, res) + if err != nil { + return nil, err + } + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.edits.validate", "response", internallog.HTTPResponse(res, b)) + return ret, nil +} + +type EditsApksAddexternallyhostedCall struct { + s *Service + packageName string + editId string + apksaddexternallyhostedrequest *ApksAddExternallyHostedRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// DataSafety: Writes the Safety Labels declaration of an app. +// Addexternallyhosted: Creates a new APK without uploading the APK itself to +// Google Play, instead hosting the APK at a specified URL. This function is +// only available to organizations using Managed Play whose application is +// configured to restrict distribution to the organizations. // +// - editId: Identifier of the edit. // - packageName: Package name of the app. -func (r *ApplicationsService) DataSafety(packageName string, safetylabelsupdaterequest *SafetyLabelsUpdateRequest) *ApplicationsDataSafetyCall { - c := &ApplicationsDataSafetyCall{s: r.s, urlParams_: make(gensupport.URLParams)} +func (r *EditsApksService) Addexternallyhosted(packageName string, editId string, apksaddexternallyhostedrequest *ApksAddExternallyHostedRequest) *EditsApksAddexternallyhostedCall { + c := &EditsApksAddexternallyhostedCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.packageName = packageName - c.safetylabelsupdaterequest = safetylabelsupdaterequest + c.editId = editId + c.apksaddexternallyhostedrequest = apksaddexternallyhostedrequest 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 *ApplicationsDataSafetyCall) Fields(s ...googleapi.Field) *ApplicationsDataSafetyCall { +func (c *EditsApksAddexternallyhostedCall) Fields(s ...googleapi.Field) *EditsApksAddexternallyhostedCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } // Context sets the context to be used in this call's Do method. -func (c *ApplicationsDataSafetyCall) Context(ctx context.Context) *ApplicationsDataSafetyCall { +func (c *EditsApksAddexternallyhostedCall) Context(ctx context.Context) *EditsApksAddexternallyhostedCall { 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 *ApplicationsDataSafetyCall) Header() http.Header { +func (c *EditsApksAddexternallyhostedCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ApplicationsDataSafetyCall) doRequest(alt string) (*http.Response, error) { +func (c *EditsApksAddexternallyhostedCall) doRequest(alt string) (*http.Response, error) { reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) - body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.safetylabelsupdaterequest) + body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.apksaddexternallyhostedrequest) if err != nil { return nil, err } c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/dataSafety") + urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/apks/externallyHosted") urls += "?" + c.urlParams_.Encode() req, err := http.NewRequest("POST", urls, body) if err != nil { @@ -8447,18 +11566,19 @@ func (c *ApplicationsDataSafetyCall) doRequest(alt string) (*http.Response, erro req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ "packageName": c.packageName, + "editId": c.editId, }) - c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.applications.dataSafety", "request", internallog.HTTPRequest(req, body.Bytes())) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.edits.apks.addexternallyhosted", "request", internallog.HTTPRequest(req, body.Bytes())) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "androidpublisher.applications.dataSafety" call. +// Do executes the "androidpublisher.edits.apks.addexternallyhosted" call. // Any non-2xx status code is an error. Response headers are in either -// *SafetyLabelsUpdateResponse.ServerResponse.Header or (if a response was +// *ApksAddExternallyHostedResponse.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 *ApplicationsDataSafetyCall) Do(opts ...googleapi.CallOption) (*SafetyLabelsUpdateResponse, error) { +func (c *EditsApksAddexternallyhostedCall) Do(opts ...googleapi.CallOption) (*ApksAddExternallyHostedResponse, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -8477,7 +11597,7 @@ func (c *ApplicationsDataSafetyCall) Do(opts ...googleapi.CallOption) (*SafetyLa if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &SafetyLabelsUpdateResponse{ + ret := &ApksAddExternallyHostedResponse{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -8488,89 +11608,238 @@ func (c *ApplicationsDataSafetyCall) Do(opts ...googleapi.CallOption) (*SafetyLa if err != nil { return nil, err } - c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.applications.dataSafety", "response", internallog.HTTPResponse(res, b)) + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.edits.apks.addexternallyhosted", "response", internallog.HTTPResponse(res, b)) return ret, nil } -type ApplicationsDeviceTierConfigsCreateCall struct { - s *Service - packageName string - devicetierconfig *DeviceTierConfig - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +type EditsApksListCall struct { + s *Service + packageName string + editId string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header } -// Create: Creates a new device tier config for an app. +// List: Lists all current APKs of the app and edit. // +// - editId: Identifier of the edit. // - packageName: Package name of the app. -func (r *ApplicationsDeviceTierConfigsService) Create(packageName string, devicetierconfig *DeviceTierConfig) *ApplicationsDeviceTierConfigsCreateCall { - c := &ApplicationsDeviceTierConfigsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)} +func (r *EditsApksService) List(packageName string, editId string) *EditsApksListCall { + c := &EditsApksListCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.packageName = packageName - c.devicetierconfig = devicetierconfig + c.editId = editId return c } -// AllowUnknownDevices sets the optional parameter "allowUnknownDevices": -// Whether the service should accept device IDs that are unknown to Play's -// device catalog. -func (c *ApplicationsDeviceTierConfigsCreateCall) AllowUnknownDevices(allowUnknownDevices bool) *ApplicationsDeviceTierConfigsCreateCall { - c.urlParams_.Set("allowUnknownDevices", fmt.Sprint(allowUnknownDevices)) +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. +func (c *EditsApksListCall) Fields(s ...googleapi.Field) *EditsApksListCall { + 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 *EditsApksListCall) IfNoneMatch(entityTag string) *EditsApksListCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *EditsApksListCall) Context(ctx context.Context) *EditsApksListCall { + 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 *EditsApksListCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *EditsApksListCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/apks") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("GET", urls, nil) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "packageName": c.packageName, + "editId": c.editId, + }) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.edits.apks.list", "request", internallog.HTTPRequest(req, nil)) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "androidpublisher.edits.apks.list" call. +// Any non-2xx status code is an error. Response headers are in either +// *ApksListResponse.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 *EditsApksListCall) Do(opts ...googleapi.CallOption) (*ApksListResponse, 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 := &ApksListResponse{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + b, err := gensupport.DecodeResponseBytes(target, res) + if err != nil { + return nil, err + } + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.edits.apks.list", "response", internallog.HTTPResponse(res, b)) + return ret, nil +} + +type EditsApksUploadCall struct { + s *Service + packageName string + editId string + urlParams_ gensupport.URLParams + mediaInfo_ *gensupport.MediaInfo + ctx_ context.Context + header_ http.Header +} + +// Upload: Uploads an APK and adds to the current edit. +// +// - editId: Identifier of the edit. +// - packageName: Package name of the app. +func (r *EditsApksService) Upload(packageName string, editId string) *EditsApksUploadCall { + c := &EditsApksUploadCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.packageName = packageName + c.editId = editId + return c +} + +// Media specifies the media to upload in one or more chunks. The chunk size +// may be controlled by supplying a MediaOption generated by +// googleapi.ChunkSize. The chunk size defaults to +// googleapi.DefaultUploadChunkSize.The Content-Type header used in the upload +// request will be determined by sniffing the contents of r, unless a +// MediaOption generated by googleapi.ContentType is supplied. +// At most one of Media and ResumableMedia may be set. +func (c *EditsApksUploadCall) Media(r io.Reader, options ...googleapi.MediaOption) *EditsApksUploadCall { + c.mediaInfo_ = gensupport.NewInfoFromMedia(r, options) + return c +} + +// ResumableMedia specifies the media to upload in chunks and can be canceled +// with ctx. +// +// Deprecated: use Media instead. +// +// At most one of Media and ResumableMedia may be set. mediaType identifies the +// MIME media type of the upload, such as "image/png". If mediaType is "", it +// will be auto-detected. The provided ctx will supersede any context +// previously provided to the Context method. +func (c *EditsApksUploadCall) ResumableMedia(ctx context.Context, r io.ReaderAt, size int64, mediaType string) *EditsApksUploadCall { + c.ctx_ = ctx + c.mediaInfo_ = gensupport.NewInfoFromResumableMedia(r, size, mediaType) + return c +} + +// ProgressUpdater provides a callback function that will be called after every +// chunk. It should be a low-latency function in order to not slow down the +// upload operation. This should only be called when using ResumableMedia (as +// opposed to Media). +func (c *EditsApksUploadCall) ProgressUpdater(pu googleapi.ProgressUpdater) *EditsApksUploadCall { + c.mediaInfo_.SetProgressUpdater(pu) 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 *ApplicationsDeviceTierConfigsCreateCall) Fields(s ...googleapi.Field) *ApplicationsDeviceTierConfigsCreateCall { +func (c *EditsApksUploadCall) Fields(s ...googleapi.Field) *EditsApksUploadCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } // Context sets the context to be used in this call's Do method. -func (c *ApplicationsDeviceTierConfigsCreateCall) Context(ctx context.Context) *ApplicationsDeviceTierConfigsCreateCall { +// This context will supersede any context previously provided to the +// ResumableMedia method. +func (c *EditsApksUploadCall) Context(ctx context.Context) *EditsApksUploadCall { 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 *ApplicationsDeviceTierConfigsCreateCall) Header() http.Header { +func (c *EditsApksUploadCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ApplicationsDeviceTierConfigsCreateCall) doRequest(alt string) (*http.Response, error) { +func (c *EditsApksUploadCall) doRequest(alt string) (*http.Response, error) { reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) - body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.devicetierconfig) - if err != nil { - return nil, err - } c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/deviceTierConfigs") + urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/apks") + if c.mediaInfo_ != nil { + urls = googleapi.ResolveRelative(c.s.BasePath, "/upload/androidpublisher/v3/applications/{packageName}/edits/{editId}/apks") + c.urlParams_.Set("uploadType", c.mediaInfo_.UploadType()) + } + newBody, getBody, cleanup := c.mediaInfo_.UploadRequest(reqHeaders, nil) + defer cleanup() urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("POST", urls, body) + req, err := http.NewRequest("POST", urls, newBody) if err != nil { return nil, err } req.Header = reqHeaders + req.GetBody = getBody googleapi.Expand(req.URL, map[string]string{ "packageName": c.packageName, + "editId": c.editId, }) - c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.applications.deviceTierConfigs.create", "request", internallog.HTTPRequest(req, body.Bytes())) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.edits.apks.upload", "request", internallog.HTTPRequest(req, nil)) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "androidpublisher.applications.deviceTierConfigs.create" call. +// Do executes the "androidpublisher.edits.apks.upload" call. // Any non-2xx status code is an error. Response headers are in either -// *DeviceTierConfig.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 *ApplicationsDeviceTierConfigsCreateCall) Do(opts ...googleapi.CallOption) (*DeviceTierConfig, error) { +// *Apk.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 *EditsApksUploadCall) Do(opts ...googleapi.CallOption) (*Apk, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -8589,7 +11858,24 @@ func (c *ApplicationsDeviceTierConfigsCreateCall) Do(opts ...googleapi.CallOptio if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &DeviceTierConfig{ + rx := c.mediaInfo_.ResumableUpload(res.Header.Get("Location")) + if rx != nil { + rx.Client = c.s.client + rx.UserAgent = c.s.userAgent() + ctx := c.ctx_ + if ctx == nil { + ctx = context.TODO() + } + res, err = rx.Upload(ctx) + if err != nil { + return nil, err + } + defer res.Body.Close() + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + } + ret := &Apk{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -8600,35 +11886,35 @@ func (c *ApplicationsDeviceTierConfigsCreateCall) Do(opts ...googleapi.CallOptio if err != nil { return nil, err } - c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.applications.deviceTierConfigs.create", "response", internallog.HTTPResponse(res, b)) + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.edits.apks.upload", "response", internallog.HTTPResponse(res, b)) return ret, nil } -type ApplicationsDeviceTierConfigsGetCall struct { - s *Service - packageName string - deviceTierConfigId int64 - urlParams_ gensupport.URLParams - ifNoneMatch_ string - ctx_ context.Context - header_ http.Header +type EditsBundlesListCall struct { + s *Service + packageName string + editId string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header } -// Get: Returns a particular device tier config. +// List: Lists all current Android App Bundles of the app and edit. // -// - deviceTierConfigId: Id of an existing device tier config. +// - editId: Identifier of the edit. // - packageName: Package name of the app. -func (r *ApplicationsDeviceTierConfigsService) Get(packageName string, deviceTierConfigId int64) *ApplicationsDeviceTierConfigsGetCall { - c := &ApplicationsDeviceTierConfigsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} +func (r *EditsBundlesService) List(packageName string, editId string) *EditsBundlesListCall { + c := &EditsBundlesListCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.packageName = packageName - c.deviceTierConfigId = deviceTierConfigId + c.editId = editId 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 *ApplicationsDeviceTierConfigsGetCall) Fields(s ...googleapi.Field) *ApplicationsDeviceTierConfigsGetCall { +func (c *EditsBundlesListCall) Fields(s ...googleapi.Field) *EditsBundlesListCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } @@ -8636,34 +11922,34 @@ func (c *ApplicationsDeviceTierConfigsGetCall) Fields(s ...googleapi.Field) *App // 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 *ApplicationsDeviceTierConfigsGetCall) IfNoneMatch(entityTag string) *ApplicationsDeviceTierConfigsGetCall { +func (c *EditsBundlesListCall) IfNoneMatch(entityTag string) *EditsBundlesListCall { c.ifNoneMatch_ = entityTag return c } // Context sets the context to be used in this call's Do method. -func (c *ApplicationsDeviceTierConfigsGetCall) Context(ctx context.Context) *ApplicationsDeviceTierConfigsGetCall { +func (c *EditsBundlesListCall) Context(ctx context.Context) *EditsBundlesListCall { 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 *ApplicationsDeviceTierConfigsGetCall) Header() http.Header { +func (c *EditsBundlesListCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ApplicationsDeviceTierConfigsGetCall) doRequest(alt string) (*http.Response, error) { +func (c *EditsBundlesListCall) doRequest(alt string) (*http.Response, error) { reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) if c.ifNoneMatch_ != "" { reqHeaders.Set("If-None-Match", c.ifNoneMatch_) } c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/deviceTierConfigs/{deviceTierConfigId}") + urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/bundles") urls += "?" + c.urlParams_.Encode() req, err := http.NewRequest("GET", urls, nil) if err != nil { @@ -8671,20 +11957,20 @@ func (c *ApplicationsDeviceTierConfigsGetCall) doRequest(alt string) (*http.Resp } req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ - "packageName": c.packageName, - "deviceTierConfigId": strconv.FormatInt(c.deviceTierConfigId, 10), + "packageName": c.packageName, + "editId": c.editId, }) - c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.applications.deviceTierConfigs.get", "request", internallog.HTTPRequest(req, nil)) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.edits.bundles.list", "request", internallog.HTTPRequest(req, nil)) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "androidpublisher.applications.deviceTierConfigs.get" call. +// Do executes the "androidpublisher.edits.bundles.list" call. // Any non-2xx status code is an error. Response headers are in either -// *DeviceTierConfig.ServerResponse.Header or (if a response was returned at +// *BundlesListResponse.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 *ApplicationsDeviceTierConfigsGetCall) Do(opts ...googleapi.CallOption) (*DeviceTierConfig, error) { +func (c *EditsBundlesListCall) Do(opts ...googleapi.CallOption) (*BundlesListResponse, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -8703,7 +11989,7 @@ func (c *ApplicationsDeviceTierConfigsGetCall) Do(opts ...googleapi.CallOption) if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &DeviceTierConfig{ + ret := &BundlesListResponse{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -8714,125 +12000,181 @@ func (c *ApplicationsDeviceTierConfigsGetCall) Do(opts ...googleapi.CallOption) if err != nil { return nil, err } - c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.applications.deviceTierConfigs.get", "response", internallog.HTTPResponse(res, b)) + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.edits.bundles.list", "response", internallog.HTTPResponse(res, b)) return ret, nil } -type ApplicationsDeviceTierConfigsListCall struct { - s *Service - packageName string - urlParams_ gensupport.URLParams - ifNoneMatch_ string - ctx_ context.Context - header_ http.Header +type EditsBundlesUploadCall struct { + s *Service + packageName string + editId string + urlParams_ gensupport.URLParams + mediaInfo_ *gensupport.MediaInfo + ctx_ context.Context + header_ http.Header } -// List: Returns created device tier configs, ordered by descending creation -// time. +// Upload: Uploads a new Android App Bundle to this edit. If you are using the +// Google API client libraries, please increase the timeout of the http request +// before calling this endpoint (a timeout of 2 minutes is recommended). See +// Timeouts and Errors +// (https://developers.google.com/api-client-library/java/google-api-java-client/errors) +// for an example in java. // +// - editId: Identifier of the edit. // - packageName: Package name of the app. -func (r *ApplicationsDeviceTierConfigsService) List(packageName string) *ApplicationsDeviceTierConfigsListCall { - c := &ApplicationsDeviceTierConfigsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} +func (r *EditsBundlesService) Upload(packageName string, editId string) *EditsBundlesUploadCall { + c := &EditsBundlesUploadCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.packageName = packageName + c.editId = editId return c } -// PageSize sets the optional parameter "pageSize": The maximum number of -// device tier configs to return. The service may return fewer than this value. -// If unspecified, at most 10 device tier configs will be returned. The maximum -// value for this field is 100; values above 100 will be coerced to 100. Device -// tier configs will be ordered by descending creation time. -func (c *ApplicationsDeviceTierConfigsListCall) PageSize(pageSize int64) *ApplicationsDeviceTierConfigsListCall { - c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) +// AckBundleInstallationWarning sets the optional parameter +// "ackBundleInstallationWarning": Deprecated. The installation warning has +// been removed, it's not necessary to set this field anymore. +func (c *EditsBundlesUploadCall) AckBundleInstallationWarning(ackBundleInstallationWarning bool) *EditsBundlesUploadCall { + c.urlParams_.Set("ackBundleInstallationWarning", fmt.Sprint(ackBundleInstallationWarning)) return c } -// PageToken sets the optional parameter "pageToken": A page token, received -// from a previous `ListDeviceTierConfigs` call. Provide this to retrieve the -// subsequent page. -func (c *ApplicationsDeviceTierConfigsListCall) PageToken(pageToken string) *ApplicationsDeviceTierConfigsListCall { - c.urlParams_.Set("pageToken", pageToken) +// DeviceTierConfigId sets the optional parameter "deviceTierConfigId": Device +// tier config (DTC) to be used for generating deliverables (APKs). Contains id +// of the DTC or "LATEST" for last uploaded DTC. +func (c *EditsBundlesUploadCall) DeviceTierConfigId(deviceTierConfigId string) *EditsBundlesUploadCall { + c.urlParams_.Set("deviceTierConfigId", deviceTierConfigId) + return c +} + +// Media specifies the media to upload in one or more chunks. The chunk size +// may be controlled by supplying a MediaOption generated by +// googleapi.ChunkSize. The chunk size defaults to +// googleapi.DefaultUploadChunkSize.The Content-Type header used in the upload +// request will be determined by sniffing the contents of r, unless a +// MediaOption generated by googleapi.ContentType is supplied. +// At most one of Media and ResumableMedia may be set. +func (c *EditsBundlesUploadCall) Media(r io.Reader, options ...googleapi.MediaOption) *EditsBundlesUploadCall { + c.mediaInfo_ = gensupport.NewInfoFromMedia(r, options) + return c +} + +// ResumableMedia specifies the media to upload in chunks and can be canceled +// with ctx. +// +// Deprecated: use Media instead. +// +// At most one of Media and ResumableMedia may be set. mediaType identifies the +// MIME media type of the upload, such as "image/png". If mediaType is "", it +// will be auto-detected. The provided ctx will supersede any context +// previously provided to the Context method. +func (c *EditsBundlesUploadCall) ResumableMedia(ctx context.Context, r io.ReaderAt, size int64, mediaType string) *EditsBundlesUploadCall { + c.ctx_ = ctx + c.mediaInfo_ = gensupport.NewInfoFromResumableMedia(r, size, mediaType) + return c +} + +// ProgressUpdater provides a callback function that will be called after every +// chunk. It should be a low-latency function in order to not slow down the +// upload operation. This should only be called when using ResumableMedia (as +// opposed to Media). +func (c *EditsBundlesUploadCall) ProgressUpdater(pu googleapi.ProgressUpdater) *EditsBundlesUploadCall { + c.mediaInfo_.SetProgressUpdater(pu) 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 *ApplicationsDeviceTierConfigsListCall) Fields(s ...googleapi.Field) *ApplicationsDeviceTierConfigsListCall { +func (c *EditsBundlesUploadCall) Fields(s ...googleapi.Field) *EditsBundlesUploadCall { 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 *ApplicationsDeviceTierConfigsListCall) IfNoneMatch(entityTag string) *ApplicationsDeviceTierConfigsListCall { - c.ifNoneMatch_ = entityTag - return c -} - // Context sets the context to be used in this call's Do method. -func (c *ApplicationsDeviceTierConfigsListCall) Context(ctx context.Context) *ApplicationsDeviceTierConfigsListCall { +// This context will supersede any context previously provided to the +// ResumableMedia method. +func (c *EditsBundlesUploadCall) Context(ctx context.Context) *EditsBundlesUploadCall { 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 *ApplicationsDeviceTierConfigsListCall) Header() http.Header { +func (c *EditsBundlesUploadCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ApplicationsDeviceTierConfigsListCall) 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 *EditsBundlesUploadCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/deviceTierConfigs") + urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/bundles") + if c.mediaInfo_ != nil { + urls = googleapi.ResolveRelative(c.s.BasePath, "/upload/androidpublisher/v3/applications/{packageName}/edits/{editId}/bundles") + c.urlParams_.Set("uploadType", c.mediaInfo_.UploadType()) + } + newBody, getBody, cleanup := c.mediaInfo_.UploadRequest(reqHeaders, nil) + defer cleanup() urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("GET", urls, nil) + req, err := http.NewRequest("POST", urls, newBody) if err != nil { return nil, err } req.Header = reqHeaders + req.GetBody = getBody googleapi.Expand(req.URL, map[string]string{ "packageName": c.packageName, + "editId": c.editId, }) - c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.applications.deviceTierConfigs.list", "request", internallog.HTTPRequest(req, nil)) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.edits.bundles.upload", "request", internallog.HTTPRequest(req, nil)) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "androidpublisher.applications.deviceTierConfigs.list" call. +// Do executes the "androidpublisher.edits.bundles.upload" call. // Any non-2xx status code is an error. Response headers are in either -// *ListDeviceTierConfigsResponse.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 *ApplicationsDeviceTierConfigsListCall) Do(opts ...googleapi.CallOption) (*ListDeviceTierConfigsResponse, error) { +// *Bundle.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 *EditsBundlesUploadCall) Do(opts ...googleapi.CallOption) (*Bundle, 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 + 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) + } + rx := c.mediaInfo_.ResumableUpload(res.Header.Get("Location")) + if rx != nil { + rx.Client = c.s.client + rx.UserAgent = c.s.userAgent() + ctx := c.ctx_ + if ctx == nil { + ctx = context.TODO() + } + res, err = rx.Upload(ctx) + if err != nil { + return nil, err + } + defer res.Body.Close() + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } } - defer googleapi.CloseBody(res) - if err := googleapi.CheckResponse(res); err != nil { - return nil, gensupport.WrapError(err) - } - ret := &ListDeviceTierConfigsResponse{ + ret := &Bundle{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -8843,109 +12185,95 @@ func (c *ApplicationsDeviceTierConfigsListCall) Do(opts ...googleapi.CallOption) if err != nil { return nil, err } - c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.applications.deviceTierConfigs.list", "response", internallog.HTTPResponse(res, b)) + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.edits.bundles.upload", "response", internallog.HTTPResponse(res, b)) 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 *ApplicationsDeviceTierConfigsListCall) Pages(ctx context.Context, f func(*ListDeviceTierConfigsResponse) 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 ApprecoveryAddTargetingCall struct { - s *Service - packageName string - appRecoveryId int64 - addtargetingrequest *AddTargetingRequest - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +type EditsCountryavailabilityGetCall struct { + s *Service + packageName string + editId string + track string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header } -// AddTargeting: Incrementally update targeting for a recovery action. Note -// that only the criteria selected during the creation of recovery action can -// be expanded. +// Get: Gets country availability. // -// - appRecoveryId: ID corresponding to the app recovery action. -// - packageName: Package name of the app for which recovery action is to be -// updated. -func (r *ApprecoveryService) AddTargeting(packageName string, appRecoveryId int64, addtargetingrequest *AddTargetingRequest) *ApprecoveryAddTargetingCall { - c := &ApprecoveryAddTargetingCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// - editId: Identifier of the edit. +// - packageName: Package name of the app. +// - track: The track to read from. +func (r *EditsCountryavailabilityService) Get(packageName string, editId string, track string) *EditsCountryavailabilityGetCall { + c := &EditsCountryavailabilityGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.packageName = packageName - c.appRecoveryId = appRecoveryId - c.addtargetingrequest = addtargetingrequest + c.editId = editId + c.track = track 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 *ApprecoveryAddTargetingCall) Fields(s ...googleapi.Field) *ApprecoveryAddTargetingCall { +func (c *EditsCountryavailabilityGetCall) Fields(s ...googleapi.Field) *EditsCountryavailabilityGetCall { 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 *EditsCountryavailabilityGetCall) IfNoneMatch(entityTag string) *EditsCountryavailabilityGetCall { + c.ifNoneMatch_ = entityTag + return c +} + // Context sets the context to be used in this call's Do method. -func (c *ApprecoveryAddTargetingCall) Context(ctx context.Context) *ApprecoveryAddTargetingCall { +func (c *EditsCountryavailabilityGetCall) Context(ctx context.Context) *EditsCountryavailabilityGetCall { 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 *ApprecoveryAddTargetingCall) Header() http.Header { +func (c *EditsCountryavailabilityGetCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ApprecoveryAddTargetingCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) - body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.addtargetingrequest) - if err != nil { - return nil, err +func (c *EditsCountryavailabilityGetCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) } c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/appRecoveries/{appRecoveryId}:addTargeting") + urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/countryAvailability/{track}") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("POST", urls, body) + req, err := http.NewRequest("GET", urls, nil) if err != nil { return nil, err } req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ - "packageName": c.packageName, - "appRecoveryId": strconv.FormatInt(c.appRecoveryId, 10), + "packageName": c.packageName, + "editId": c.editId, + "track": c.track, }) - c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.apprecovery.addTargeting", "request", internallog.HTTPRequest(req, body.Bytes())) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.edits.countryavailability.get", "request", internallog.HTTPRequest(req, nil)) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "androidpublisher.apprecovery.addTargeting" call. +// Do executes the "androidpublisher.edits.countryavailability.get" call. // Any non-2xx status code is an error. Response headers are in either -// *AddTargetingResponse.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 *ApprecoveryAddTargetingCall) Do(opts ...googleapi.CallOption) (*AddTargetingResponse, error) { +// *TrackCountryAvailability.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 *EditsCountryavailabilityGetCall) Do(opts ...googleapi.CallOption) (*TrackCountryAvailability, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -8964,7 +12292,7 @@ func (c *ApprecoveryAddTargetingCall) Do(opts ...googleapi.CallOption) (*AddTarg if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &AddTargetingResponse{ + ret := &TrackCountryAvailability{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -8975,87 +12303,134 @@ func (c *ApprecoveryAddTargetingCall) Do(opts ...googleapi.CallOption) (*AddTarg if err != nil { return nil, err } - c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.apprecovery.addTargeting", "response", internallog.HTTPResponse(res, b)) + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.edits.countryavailability.get", "response", internallog.HTTPResponse(res, b)) return ret, nil } -type ApprecoveryCancelCall struct { - s *Service - packageName string - appRecoveryId int64 - cancelapprecoveryrequest *CancelAppRecoveryRequest - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +type EditsDeobfuscationfilesUploadCall struct { + s *Service + packageNameid string + editId string + apkVersionCode int64 + deobfuscationFileType string + urlParams_ gensupport.URLParams + mediaInfo_ *gensupport.MediaInfo + ctx_ context.Context + header_ http.Header } -// Cancel: Cancel an already executing app recovery action. Note that this -// action changes status of the recovery action to CANCELED. +// Upload: Uploads a new deobfuscation file and attaches to the specified APK. // -// - appRecoveryId: ID corresponding to the app recovery action. -// - packageName: Package name of the app for which recovery action -// cancellation is requested. -func (r *ApprecoveryService) Cancel(packageName string, appRecoveryId int64, cancelapprecoveryrequest *CancelAppRecoveryRequest) *ApprecoveryCancelCall { - c := &ApprecoveryCancelCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.packageName = packageName - c.appRecoveryId = appRecoveryId - c.cancelapprecoveryrequest = cancelapprecoveryrequest +// - apkVersionCode: The version code of the APK whose Deobfuscation File is +// being uploaded. +// - deobfuscationFileType: The type of the deobfuscation file. +// - editId: Unique identifier for this edit. +// - packageName: Unique identifier for the Android app. +func (r *EditsDeobfuscationfilesService) Upload(packageNameid string, editId string, apkVersionCode int64, deobfuscationFileType string) *EditsDeobfuscationfilesUploadCall { + c := &EditsDeobfuscationfilesUploadCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.packageNameid = packageNameid + c.editId = editId + c.apkVersionCode = apkVersionCode + c.deobfuscationFileType = deobfuscationFileType + return c +} + +// Media specifies the media to upload in one or more chunks. The chunk size +// may be controlled by supplying a MediaOption generated by +// googleapi.ChunkSize. The chunk size defaults to +// googleapi.DefaultUploadChunkSize.The Content-Type header used in the upload +// request will be determined by sniffing the contents of r, unless a +// MediaOption generated by googleapi.ContentType is supplied. +// At most one of Media and ResumableMedia may be set. +func (c *EditsDeobfuscationfilesUploadCall) Media(r io.Reader, options ...googleapi.MediaOption) *EditsDeobfuscationfilesUploadCall { + c.mediaInfo_ = gensupport.NewInfoFromMedia(r, options) + return c +} + +// ResumableMedia specifies the media to upload in chunks and can be canceled +// with ctx. +// +// Deprecated: use Media instead. +// +// At most one of Media and ResumableMedia may be set. mediaType identifies the +// MIME media type of the upload, such as "image/png". If mediaType is "", it +// will be auto-detected. The provided ctx will supersede any context +// previously provided to the Context method. +func (c *EditsDeobfuscationfilesUploadCall) ResumableMedia(ctx context.Context, r io.ReaderAt, size int64, mediaType string) *EditsDeobfuscationfilesUploadCall { + c.ctx_ = ctx + c.mediaInfo_ = gensupport.NewInfoFromResumableMedia(r, size, mediaType) + return c +} + +// ProgressUpdater provides a callback function that will be called after every +// chunk. It should be a low-latency function in order to not slow down the +// upload operation. This should only be called when using ResumableMedia (as +// opposed to Media). +func (c *EditsDeobfuscationfilesUploadCall) ProgressUpdater(pu googleapi.ProgressUpdater) *EditsDeobfuscationfilesUploadCall { + c.mediaInfo_.SetProgressUpdater(pu) 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 *ApprecoveryCancelCall) Fields(s ...googleapi.Field) *ApprecoveryCancelCall { +func (c *EditsDeobfuscationfilesUploadCall) Fields(s ...googleapi.Field) *EditsDeobfuscationfilesUploadCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } // Context sets the context to be used in this call's Do method. -func (c *ApprecoveryCancelCall) Context(ctx context.Context) *ApprecoveryCancelCall { +// This context will supersede any context previously provided to the +// ResumableMedia method. +func (c *EditsDeobfuscationfilesUploadCall) Context(ctx context.Context) *EditsDeobfuscationfilesUploadCall { 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 *ApprecoveryCancelCall) Header() http.Header { +func (c *EditsDeobfuscationfilesUploadCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ApprecoveryCancelCall) doRequest(alt string) (*http.Response, error) { +func (c *EditsDeobfuscationfilesUploadCall) doRequest(alt string) (*http.Response, error) { reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) - body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.cancelapprecoveryrequest) - if err != nil { - return nil, err - } c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/appRecoveries/{appRecoveryId}:cancel") + urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/apks/{apkVersionCode}/deobfuscationFiles/{deobfuscationFileType}") + if c.mediaInfo_ != nil { + urls = googleapi.ResolveRelative(c.s.BasePath, "/upload/androidpublisher/v3/applications/{packageName}/edits/{editId}/apks/{apkVersionCode}/deobfuscationFiles/{deobfuscationFileType}") + c.urlParams_.Set("uploadType", c.mediaInfo_.UploadType()) + } + newBody, getBody, cleanup := c.mediaInfo_.UploadRequest(reqHeaders, nil) + defer cleanup() urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("POST", urls, body) + req, err := http.NewRequest("POST", urls, newBody) if err != nil { return nil, err } req.Header = reqHeaders + req.GetBody = getBody googleapi.Expand(req.URL, map[string]string{ - "packageName": c.packageName, - "appRecoveryId": strconv.FormatInt(c.appRecoveryId, 10), + "packageName": c.packageNameid, + "editId": c.editId, + "apkVersionCode": strconv.FormatInt(c.apkVersionCode, 10), + "deobfuscationFileType": c.deobfuscationFileType, }) - c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.apprecovery.cancel", "request", internallog.HTTPRequest(req, body.Bytes())) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.edits.deobfuscationfiles.upload", "request", internallog.HTTPRequest(req, nil)) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "androidpublisher.apprecovery.cancel" call. +// Do executes the "androidpublisher.edits.deobfuscationfiles.upload" call. // Any non-2xx status code is an error. Response headers are in either -// *CancelAppRecoveryResponse.ServerResponse.Header or (if a response was -// returned at all) in error.(*googleapi.Error).Header. Use +// *DeobfuscationFilesUploadResponse.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 *ApprecoveryCancelCall) Do(opts ...googleapi.CallOption) (*CancelAppRecoveryResponse, error) { +func (c *EditsDeobfuscationfilesUploadCall) Do(opts ...googleapi.CallOption) (*DeobfuscationFilesUploadResponse, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -9074,7 +12449,24 @@ func (c *ApprecoveryCancelCall) Do(opts ...googleapi.CallOption) (*CancelAppReco if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &CancelAppRecoveryResponse{ + rx := c.mediaInfo_.ResumableUpload(res.Header.Get("Location")) + if rx != nil { + rx.Client = c.s.client + rx.UserAgent = c.s.userAgent() + ctx := c.ctx_ + if ctx == nil { + ctx = context.TODO() + } + res, err = rx.Upload(ctx) + if err != nil { + return nil, err + } + defer res.Body.Close() + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + } + ret := &DeobfuscationFilesUploadResponse{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -9085,83 +12477,90 @@ func (c *ApprecoveryCancelCall) Do(opts ...googleapi.CallOption) (*CancelAppReco if err != nil { return nil, err } - c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.apprecovery.cancel", "response", internallog.HTTPResponse(res, b)) + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.edits.deobfuscationfiles.upload", "response", internallog.HTTPResponse(res, b)) return ret, nil } -type ApprecoveryCreateCall struct { - s *Service - packageName string - createdraftapprecoveryrequest *CreateDraftAppRecoveryRequest - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +type EditsDetailsGetCall struct { + s *Service + packageName string + editId string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header } -// Create: Create an app recovery action with recovery status as DRAFT. Note -// that this action does not execute the recovery action. +// Get: Gets details of an app. // -// - packageName: Package name of the app on which recovery action is -// performed. -func (r *ApprecoveryService) Create(packageName string, createdraftapprecoveryrequest *CreateDraftAppRecoveryRequest) *ApprecoveryCreateCall { - c := &ApprecoveryCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// - editId: Identifier of the edit. +// - packageName: Package name of the app. +func (r *EditsDetailsService) Get(packageName string, editId string) *EditsDetailsGetCall { + c := &EditsDetailsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.packageName = packageName - c.createdraftapprecoveryrequest = createdraftapprecoveryrequest + c.editId = editId 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 *ApprecoveryCreateCall) Fields(s ...googleapi.Field) *ApprecoveryCreateCall { +func (c *EditsDetailsGetCall) Fields(s ...googleapi.Field) *EditsDetailsGetCall { 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 *EditsDetailsGetCall) IfNoneMatch(entityTag string) *EditsDetailsGetCall { + c.ifNoneMatch_ = entityTag + return c +} + // Context sets the context to be used in this call's Do method. -func (c *ApprecoveryCreateCall) Context(ctx context.Context) *ApprecoveryCreateCall { +func (c *EditsDetailsGetCall) Context(ctx context.Context) *EditsDetailsGetCall { 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 *ApprecoveryCreateCall) Header() http.Header { +func (c *EditsDetailsGetCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ApprecoveryCreateCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) - body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.createdraftapprecoveryrequest) - if err != nil { - return nil, err +func (c *EditsDetailsGetCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) } c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/appRecoveries") + urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/details") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("POST", urls, body) + req, err := http.NewRequest("GET", urls, nil) if err != nil { return nil, err } req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ "packageName": c.packageName, + "editId": c.editId, }) - c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.apprecovery.create", "request", internallog.HTTPRequest(req, body.Bytes())) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.edits.details.get", "request", internallog.HTTPRequest(req, nil)) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "androidpublisher.apprecovery.create" call. +// Do executes the "androidpublisher.edits.details.get" call. // Any non-2xx status code is an error. Response headers are in either -// *AppRecoveryAction.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 *ApprecoveryCreateCall) Do(opts ...googleapi.CallOption) (*AppRecoveryAction, error) { +// *AppDetails.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 *EditsDetailsGetCall) Do(opts ...googleapi.CallOption) (*AppDetails, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -9180,7 +12579,7 @@ func (c *ApprecoveryCreateCall) Do(opts ...googleapi.CallOption) (*AppRecoveryAc if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &AppRecoveryAction{ + ret := &AppDetails{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -9191,88 +12590,84 @@ func (c *ApprecoveryCreateCall) Do(opts ...googleapi.CallOption) (*AppRecoveryAc if err != nil { return nil, err } - c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.apprecovery.create", "response", internallog.HTTPResponse(res, b)) + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.edits.details.get", "response", internallog.HTTPResponse(res, b)) return ret, nil } -type ApprecoveryDeployCall struct { - s *Service - packageName string - appRecoveryId int64 - deployapprecoveryrequest *DeployAppRecoveryRequest - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +type EditsDetailsPatchCall struct { + s *Service + packageName string + editId string + appdetails *AppDetails + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// Deploy: Deploy an already created app recovery action with recovery status -// DRAFT. Note that this action activates the recovery action for all targeted -// users and changes its status to ACTIVE. +// Patch: Patches details of an app. // -// - appRecoveryId: ID corresponding to the app recovery action to deploy. -// - packageName: Package name of the app for which recovery action is -// deployed. -func (r *ApprecoveryService) Deploy(packageName string, appRecoveryId int64, deployapprecoveryrequest *DeployAppRecoveryRequest) *ApprecoveryDeployCall { - c := &ApprecoveryDeployCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// - editId: Identifier of the edit. +// - packageName: Package name of the app. +func (r *EditsDetailsService) Patch(packageName string, editId string, appdetails *AppDetails) *EditsDetailsPatchCall { + c := &EditsDetailsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.packageName = packageName - c.appRecoveryId = appRecoveryId - c.deployapprecoveryrequest = deployapprecoveryrequest + c.editId = editId + c.appdetails = appdetails 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 *ApprecoveryDeployCall) Fields(s ...googleapi.Field) *ApprecoveryDeployCall { +func (c *EditsDetailsPatchCall) Fields(s ...googleapi.Field) *EditsDetailsPatchCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } // Context sets the context to be used in this call's Do method. -func (c *ApprecoveryDeployCall) Context(ctx context.Context) *ApprecoveryDeployCall { +func (c *EditsDetailsPatchCall) Context(ctx context.Context) *EditsDetailsPatchCall { 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 *ApprecoveryDeployCall) Header() http.Header { +func (c *EditsDetailsPatchCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ApprecoveryDeployCall) doRequest(alt string) (*http.Response, error) { +func (c *EditsDetailsPatchCall) doRequest(alt string) (*http.Response, error) { reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) - body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.deployapprecoveryrequest) + body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.appdetails) if err != nil { return nil, err } c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/appRecoveries/{appRecoveryId}:deploy") + urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/details") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("POST", urls, body) + req, err := http.NewRequest("PATCH", urls, body) if err != nil { return nil, err } req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ - "packageName": c.packageName, - "appRecoveryId": strconv.FormatInt(c.appRecoveryId, 10), + "packageName": c.packageName, + "editId": c.editId, }) - c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.apprecovery.deploy", "request", internallog.HTTPRequest(req, body.Bytes())) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.edits.details.patch", "request", internallog.HTTPRequest(req, body.Bytes())) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "androidpublisher.apprecovery.deploy" call. +// Do executes the "androidpublisher.edits.details.patch" call. // Any non-2xx status code is an error. Response headers are in either -// *DeployAppRecoveryResponse.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 *ApprecoveryDeployCall) Do(opts ...googleapi.CallOption) (*DeployAppRecoveryResponse, error) { +// *AppDetails.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 *EditsDetailsPatchCall) Do(opts ...googleapi.CallOption) (*AppDetails, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -9291,7 +12686,7 @@ func (c *ApprecoveryDeployCall) Do(opts ...googleapi.CallOption) (*DeployAppReco if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &DeployAppRecoveryResponse{ + ret := &AppDetails{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -9302,96 +12697,84 @@ func (c *ApprecoveryDeployCall) Do(opts ...googleapi.CallOption) (*DeployAppReco if err != nil { return nil, err } - c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.apprecovery.deploy", "response", internallog.HTTPResponse(res, b)) + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.edits.details.patch", "response", internallog.HTTPResponse(res, b)) return ret, nil } -type ApprecoveryListCall struct { - s *Service - packageName string - urlParams_ gensupport.URLParams - ifNoneMatch_ string - ctx_ context.Context - header_ http.Header +type EditsDetailsUpdateCall struct { + s *Service + packageName string + editId string + appdetails *AppDetails + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// List: List all app recovery action resources associated with a particular -// package name and app version. +// Update: Updates details of an app. // -// - packageName: Package name of the app for which list of recovery actions is -// requested. -func (r *ApprecoveryService) List(packageName string) *ApprecoveryListCall { - c := &ApprecoveryListCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// - editId: Identifier of the edit. +// - packageName: Package name of the app. +func (r *EditsDetailsService) Update(packageName string, editId string, appdetails *AppDetails) *EditsDetailsUpdateCall { + c := &EditsDetailsUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.packageName = packageName - return c -} - -// VersionCode sets the optional parameter "versionCode": Required. Version -// code targeted by the list of recovery actions. -func (c *ApprecoveryListCall) VersionCode(versionCode int64) *ApprecoveryListCall { - c.urlParams_.Set("versionCode", fmt.Sprint(versionCode)) + c.editId = editId + c.appdetails = appdetails 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 *ApprecoveryListCall) Fields(s ...googleapi.Field) *ApprecoveryListCall { +func (c *EditsDetailsUpdateCall) Fields(s ...googleapi.Field) *EditsDetailsUpdateCall { 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 *ApprecoveryListCall) IfNoneMatch(entityTag string) *ApprecoveryListCall { - c.ifNoneMatch_ = entityTag - return c -} - // Context sets the context to be used in this call's Do method. -func (c *ApprecoveryListCall) Context(ctx context.Context) *ApprecoveryListCall { +func (c *EditsDetailsUpdateCall) Context(ctx context.Context) *EditsDetailsUpdateCall { 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 *ApprecoveryListCall) Header() http.Header { +func (c *EditsDetailsUpdateCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ApprecoveryListCall) 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 *EditsDetailsUpdateCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) + body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.appdetails) + if err != nil { + return nil, err } c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/appRecoveries") + urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/details") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("GET", urls, nil) + req, err := http.NewRequest("PUT", urls, body) if err != nil { return nil, err } req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ "packageName": c.packageName, + "editId": c.editId, }) - c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.apprecovery.list", "request", internallog.HTTPRequest(req, nil)) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.edits.details.update", "request", internallog.HTTPRequest(req, body.Bytes())) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "androidpublisher.apprecovery.list" call. +// Do executes the "androidpublisher.edits.details.update" call. // Any non-2xx status code is an error. Response headers are in either -// *ListAppRecoveriesResponse.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 *ApprecoveryListCall) Do(opts ...googleapi.CallOption) (*ListAppRecoveriesResponse, error) { +// *AppDetails.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 *EditsDetailsUpdateCall) Do(opts ...googleapi.CallOption) (*AppDetails, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -9410,7 +12793,7 @@ func (c *ApprecoveryListCall) Do(opts ...googleapi.CallOption) (*ListAppRecoveri if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &ListAppRecoveriesResponse{ + ret := &AppDetails{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -9421,88 +12804,100 @@ func (c *ApprecoveryListCall) Do(opts ...googleapi.CallOption) (*ListAppRecoveri if err != nil { return nil, err } - c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.apprecovery.list", "response", internallog.HTTPResponse(res, b)) + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.edits.details.update", "response", internallog.HTTPResponse(res, b)) return ret, nil } -type EditsCommitCall struct { - s *Service - packageName string - editId string - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +type EditsExpansionfilesGetCall struct { + s *Service + packageName string + editId string + apkVersionCode int64 + expansionFileType string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header } -// Commit: Commits an app edit. +// Get: Fetches the expansion file configuration for the specified APK. // -// - editId: Identifier of the edit. -// - packageName: Package name of the app. -func (r *EditsService) Commit(packageName string, editId string) *EditsCommitCall { - c := &EditsCommitCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// - apkVersionCode: The version code of the APK whose expansion file +// configuration is being read or modified. +// - editId: Identifier of the edit. +// - expansionFileType: The file type of the file configuration which is being +// read or modified. +// - packageName: Package name of the app. +func (r *EditsExpansionfilesService) Get(packageName string, editId string, apkVersionCode int64, expansionFileType string) *EditsExpansionfilesGetCall { + c := &EditsExpansionfilesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.packageName = packageName c.editId = editId - return c -} - -// ChangesNotSentForReview sets the optional parameter -// "changesNotSentForReview": When a rejection happens, the parameter will make -// sure that the changes in this edit won't be reviewed until they are -// explicitly sent for review from within the Google Play Console UI. These -// changes will be added to any other changes that are not yet sent for review. -func (c *EditsCommitCall) ChangesNotSentForReview(changesNotSentForReview bool) *EditsCommitCall { - c.urlParams_.Set("changesNotSentForReview", fmt.Sprint(changesNotSentForReview)) + c.apkVersionCode = apkVersionCode + c.expansionFileType = expansionFileType 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 *EditsCommitCall) Fields(s ...googleapi.Field) *EditsCommitCall { +func (c *EditsExpansionfilesGetCall) Fields(s ...googleapi.Field) *EditsExpansionfilesGetCall { 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 *EditsExpansionfilesGetCall) IfNoneMatch(entityTag string) *EditsExpansionfilesGetCall { + c.ifNoneMatch_ = entityTag + return c +} + // Context sets the context to be used in this call's Do method. -func (c *EditsCommitCall) Context(ctx context.Context) *EditsCommitCall { +func (c *EditsExpansionfilesGetCall) Context(ctx context.Context) *EditsExpansionfilesGetCall { 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 *EditsCommitCall) Header() http.Header { +func (c *EditsExpansionfilesGetCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *EditsCommitCall) doRequest(alt string) (*http.Response, error) { +func (c *EditsExpansionfilesGetCall) doRequest(alt string) (*http.Response, error) { reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) + } c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}:commit") + urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/apks/{apkVersionCode}/expansionFiles/{expansionFileType}") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("POST", urls, nil) + req, err := http.NewRequest("GET", urls, nil) if err != nil { return nil, err } req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ - "packageName": c.packageName, - "editId": c.editId, + "packageName": c.packageName, + "editId": c.editId, + "apkVersionCode": strconv.FormatInt(c.apkVersionCode, 10), + "expansionFileType": c.expansionFileType, }) - c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.edits.commit", "request", internallog.HTTPRequest(req, nil)) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.edits.expansionfiles.get", "request", internallog.HTTPRequest(req, nil)) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "androidpublisher.edits.commit" call. +// Do executes the "androidpublisher.edits.expansionfiles.get" call. // Any non-2xx status code is an error. Response headers are in either -// *AppEdit.ServerResponse.Header or (if a response was returned at all) in -// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// *ExpansionFile.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 *EditsCommitCall) Do(opts ...googleapi.CallOption) (*AppEdit, error) { +func (c *EditsExpansionfilesGetCall) Do(opts ...googleapi.CallOption) (*ExpansionFile, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -9521,7 +12916,7 @@ func (c *EditsCommitCall) Do(opts ...googleapi.CallOption) (*AppEdit, error) { if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &AppEdit{ + ret := &ExpansionFile{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -9532,167 +12927,213 @@ func (c *EditsCommitCall) Do(opts ...googleapi.CallOption) (*AppEdit, error) { if err != nil { return nil, err } - c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.edits.commit", "response", internallog.HTTPResponse(res, b)) + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.edits.expansionfiles.get", "response", internallog.HTTPResponse(res, b)) return ret, nil } -type EditsDeleteCall struct { - s *Service - packageName string - editId string - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +type EditsExpansionfilesPatchCall struct { + s *Service + packageName string + editId string + apkVersionCode int64 + expansionFileType string + expansionfile *ExpansionFile + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// Delete: Deletes an app edit. +// Patch: Patches the APK's expansion file configuration to reference another +// APK's expansion file. To add a new expansion file use the Upload method. // -// - editId: Identifier of the edit. -// - packageName: Package name of the app. -func (r *EditsService) Delete(packageName string, editId string) *EditsDeleteCall { - c := &EditsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// - apkVersionCode: The version code of the APK whose expansion file +// configuration is being read or modified. +// - editId: Identifier of the edit. +// - expansionFileType: The file type of the expansion file configuration which +// is being updated. +// - packageName: Package name of the app. +func (r *EditsExpansionfilesService) Patch(packageName string, editId string, apkVersionCode int64, expansionFileType string, expansionfile *ExpansionFile) *EditsExpansionfilesPatchCall { + c := &EditsExpansionfilesPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.packageName = packageName c.editId = editId + c.apkVersionCode = apkVersionCode + c.expansionFileType = expansionFileType + c.expansionfile = expansionfile 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 *EditsDeleteCall) Fields(s ...googleapi.Field) *EditsDeleteCall { +func (c *EditsExpansionfilesPatchCall) Fields(s ...googleapi.Field) *EditsExpansionfilesPatchCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } // Context sets the context to be used in this call's Do method. -func (c *EditsDeleteCall) Context(ctx context.Context) *EditsDeleteCall { +func (c *EditsExpansionfilesPatchCall) Context(ctx context.Context) *EditsExpansionfilesPatchCall { 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 *EditsDeleteCall) Header() http.Header { +func (c *EditsExpansionfilesPatchCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *EditsDeleteCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) +func (c *EditsExpansionfilesPatchCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) + body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.expansionfile) + if err != nil { + return nil, err + } c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}") + urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/apks/{apkVersionCode}/expansionFiles/{expansionFileType}") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("DELETE", urls, nil) + req, err := http.NewRequest("PATCH", urls, body) if err != nil { return nil, err } req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ - "packageName": c.packageName, - "editId": c.editId, + "packageName": c.packageName, + "editId": c.editId, + "apkVersionCode": strconv.FormatInt(c.apkVersionCode, 10), + "expansionFileType": c.expansionFileType, }) - c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.edits.delete", "request", internallog.HTTPRequest(req, nil)) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.edits.expansionfiles.patch", "request", internallog.HTTPRequest(req, body.Bytes())) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "androidpublisher.edits.delete" call. -func (c *EditsDeleteCall) Do(opts ...googleapi.CallOption) error { +// Do executes the "androidpublisher.edits.expansionfiles.patch" call. +// Any non-2xx status code is an error. Response headers are in either +// *ExpansionFile.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 *EditsExpansionfilesPatchCall) Do(opts ...googleapi.CallOption) (*ExpansionFile, 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 err + return nil, err } defer googleapi.CloseBody(res) if err := googleapi.CheckResponse(res); err != nil { - return gensupport.WrapError(err) + return nil, gensupport.WrapError(err) } - c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.edits.delete", "response", internallog.HTTPResponse(res, nil)) - return nil + ret := &ExpansionFile{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + b, err := gensupport.DecodeResponseBytes(target, res) + if err != nil { + return nil, err + } + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.edits.expansionfiles.patch", "response", internallog.HTTPResponse(res, b)) + return ret, nil } -type EditsGetCall struct { - s *Service - packageName string - editId string - urlParams_ gensupport.URLParams - ifNoneMatch_ string - ctx_ context.Context - header_ http.Header +type EditsExpansionfilesUpdateCall struct { + s *Service + packageName string + editId string + apkVersionCode int64 + expansionFileType string + expansionfile *ExpansionFile + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// Get: Gets an app edit. +// Update: Updates the APK's expansion file configuration to reference another +// APK's expansion file. To add a new expansion file use the Upload method. // -// - editId: Identifier of the edit. -// - packageName: Package name of the app. -func (r *EditsService) Get(packageName string, editId string) *EditsGetCall { - c := &EditsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// - apkVersionCode: The version code of the APK whose expansion file +// configuration is being read or modified. +// - editId: Identifier of the edit. +// - expansionFileType: The file type of the file configuration which is being +// read or modified. +// - packageName: Package name of the app. +func (r *EditsExpansionfilesService) Update(packageName string, editId string, apkVersionCode int64, expansionFileType string, expansionfile *ExpansionFile) *EditsExpansionfilesUpdateCall { + c := &EditsExpansionfilesUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.packageName = packageName c.editId = editId + c.apkVersionCode = apkVersionCode + c.expansionFileType = expansionFileType + c.expansionfile = expansionfile 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 *EditsGetCall) Fields(s ...googleapi.Field) *EditsGetCall { +func (c *EditsExpansionfilesUpdateCall) Fields(s ...googleapi.Field) *EditsExpansionfilesUpdateCall { 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 *EditsGetCall) IfNoneMatch(entityTag string) *EditsGetCall { - c.ifNoneMatch_ = entityTag - return c -} - // Context sets the context to be used in this call's Do method. -func (c *EditsGetCall) Context(ctx context.Context) *EditsGetCall { +func (c *EditsExpansionfilesUpdateCall) Context(ctx context.Context) *EditsExpansionfilesUpdateCall { 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 *EditsGetCall) Header() http.Header { +func (c *EditsExpansionfilesUpdateCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *EditsGetCall) 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 *EditsExpansionfilesUpdateCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) + body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.expansionfile) + if err != nil { + return nil, err } c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}") + urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/apks/{apkVersionCode}/expansionFiles/{expansionFileType}") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("GET", urls, nil) + req, err := http.NewRequest("PUT", urls, body) if err != nil { return nil, err } req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ - "packageName": c.packageName, - "editId": c.editId, + "packageName": c.packageName, + "editId": c.editId, + "apkVersionCode": strconv.FormatInt(c.apkVersionCode, 10), + "expansionFileType": c.expansionFileType, }) - c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.edits.get", "request", internallog.HTTPRequest(req, nil)) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.edits.expansionfiles.update", "request", internallog.HTTPRequest(req, body.Bytes())) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "androidpublisher.edits.get" call. +// Do executes the "androidpublisher.edits.expansionfiles.update" call. // Any non-2xx status code is an error. Response headers are in either -// *AppEdit.ServerResponse.Header or (if a response was returned at all) in -// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// *ExpansionFile.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 *EditsGetCall) Do(opts ...googleapi.CallOption) (*AppEdit, error) { +func (c *EditsExpansionfilesUpdateCall) Do(opts ...googleapi.CallOption) (*ExpansionFile, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -9711,7 +13152,7 @@ func (c *EditsGetCall) Do(opts ...googleapi.CallOption) (*AppEdit, error) { if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &AppEdit{ + ret := &ExpansionFile{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -9722,80 +13163,135 @@ func (c *EditsGetCall) Do(opts ...googleapi.CallOption) (*AppEdit, error) { if err != nil { return nil, err } - c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.edits.get", "response", internallog.HTTPResponse(res, b)) + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.edits.expansionfiles.update", "response", internallog.HTTPResponse(res, b)) return ret, nil } -type EditsInsertCall struct { - s *Service - packageName string - appedit *AppEdit - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +type EditsExpansionfilesUploadCall struct { + s *Service + packageName string + editId string + apkVersionCode int64 + expansionFileType string + urlParams_ gensupport.URLParams + mediaInfo_ *gensupport.MediaInfo + ctx_ context.Context + header_ http.Header +} + +// Upload: Uploads a new expansion file and attaches to the specified APK. +// +// - apkVersionCode: The version code of the APK whose expansion file +// configuration is being read or modified. +// - editId: Identifier of the edit. +// - expansionFileType: The file type of the expansion file configuration which +// is being updated. +// - packageName: Package name of the app. +func (r *EditsExpansionfilesService) Upload(packageName string, editId string, apkVersionCode int64, expansionFileType string) *EditsExpansionfilesUploadCall { + c := &EditsExpansionfilesUploadCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.packageName = packageName + c.editId = editId + c.apkVersionCode = apkVersionCode + c.expansionFileType = expansionFileType + return c +} + +// Media specifies the media to upload in one or more chunks. The chunk size +// may be controlled by supplying a MediaOption generated by +// googleapi.ChunkSize. The chunk size defaults to +// googleapi.DefaultUploadChunkSize.The Content-Type header used in the upload +// request will be determined by sniffing the contents of r, unless a +// MediaOption generated by googleapi.ContentType is supplied. +// At most one of Media and ResumableMedia may be set. +func (c *EditsExpansionfilesUploadCall) Media(r io.Reader, options ...googleapi.MediaOption) *EditsExpansionfilesUploadCall { + c.mediaInfo_ = gensupport.NewInfoFromMedia(r, options) + return c } -// Insert: Creates a new edit for an app. +// ResumableMedia specifies the media to upload in chunks and can be canceled +// with ctx. // -// - packageName: Package name of the app. -func (r *EditsService) Insert(packageName string, appedit *AppEdit) *EditsInsertCall { - c := &EditsInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.packageName = packageName - c.appedit = appedit +// Deprecated: use Media instead. +// +// At most one of Media and ResumableMedia may be set. mediaType identifies the +// MIME media type of the upload, such as "image/png". If mediaType is "", it +// will be auto-detected. The provided ctx will supersede any context +// previously provided to the Context method. +func (c *EditsExpansionfilesUploadCall) ResumableMedia(ctx context.Context, r io.ReaderAt, size int64, mediaType string) *EditsExpansionfilesUploadCall { + c.ctx_ = ctx + c.mediaInfo_ = gensupport.NewInfoFromResumableMedia(r, size, mediaType) + return c +} + +// ProgressUpdater provides a callback function that will be called after every +// chunk. It should be a low-latency function in order to not slow down the +// upload operation. This should only be called when using ResumableMedia (as +// opposed to Media). +func (c *EditsExpansionfilesUploadCall) ProgressUpdater(pu googleapi.ProgressUpdater) *EditsExpansionfilesUploadCall { + c.mediaInfo_.SetProgressUpdater(pu) 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 *EditsInsertCall) Fields(s ...googleapi.Field) *EditsInsertCall { +func (c *EditsExpansionfilesUploadCall) Fields(s ...googleapi.Field) *EditsExpansionfilesUploadCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } // Context sets the context to be used in this call's Do method. -func (c *EditsInsertCall) Context(ctx context.Context) *EditsInsertCall { +// This context will supersede any context previously provided to the +// ResumableMedia method. +func (c *EditsExpansionfilesUploadCall) Context(ctx context.Context) *EditsExpansionfilesUploadCall { 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 *EditsInsertCall) Header() http.Header { +func (c *EditsExpansionfilesUploadCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *EditsInsertCall) doRequest(alt string) (*http.Response, error) { +func (c *EditsExpansionfilesUploadCall) doRequest(alt string) (*http.Response, error) { reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) - body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.appedit) - if err != nil { - return nil, err - } c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits") + urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/apks/{apkVersionCode}/expansionFiles/{expansionFileType}") + if c.mediaInfo_ != nil { + urls = googleapi.ResolveRelative(c.s.BasePath, "/upload/androidpublisher/v3/applications/{packageName}/edits/{editId}/apks/{apkVersionCode}/expansionFiles/{expansionFileType}") + c.urlParams_.Set("uploadType", c.mediaInfo_.UploadType()) + } + newBody, getBody, cleanup := c.mediaInfo_.UploadRequest(reqHeaders, nil) + defer cleanup() urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("POST", urls, body) + req, err := http.NewRequest("POST", urls, newBody) if err != nil { return nil, err } req.Header = reqHeaders + req.GetBody = getBody googleapi.Expand(req.URL, map[string]string{ - "packageName": c.packageName, + "packageName": c.packageName, + "editId": c.editId, + "apkVersionCode": strconv.FormatInt(c.apkVersionCode, 10), + "expansionFileType": c.expansionFileType, }) - c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.edits.insert", "request", internallog.HTTPRequest(req, body.Bytes())) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.edits.expansionfiles.upload", "request", internallog.HTTPRequest(req, nil)) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "androidpublisher.edits.insert" call. +// Do executes the "androidpublisher.edits.expansionfiles.upload" call. // Any non-2xx status code is an error. Response headers are in either -// *AppEdit.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 *EditsInsertCall) Do(opts ...googleapi.CallOption) (*AppEdit, error) { +// *ExpansionFilesUploadResponse.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 *EditsExpansionfilesUploadCall) Do(opts ...googleapi.CallOption) (*ExpansionFilesUploadResponse, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -9814,7 +13310,24 @@ func (c *EditsInsertCall) Do(opts ...googleapi.CallOption) (*AppEdit, error) { if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &AppEdit{ + rx := c.mediaInfo_.ResumableUpload(res.Header.Get("Location")) + if rx != nil { + rx.Client = c.s.client + rx.UserAgent = c.s.userAgent() + ctx := c.ctx_ + if ctx == nil { + ctx = context.TODO() + } + res, err = rx.Upload(ctx) + if err != nil { + return nil, err + } + defer res.Body.Close() + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + } + ret := &ExpansionFilesUploadResponse{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -9825,60 +13338,71 @@ func (c *EditsInsertCall) Do(opts ...googleapi.CallOption) (*AppEdit, error) { if err != nil { return nil, err } - c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.edits.insert", "response", internallog.HTTPResponse(res, b)) + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.edits.expansionfiles.upload", "response", internallog.HTTPResponse(res, b)) return ret, nil } -type EditsValidateCall struct { +type EditsImagesDeleteCall struct { s *Service packageName string editId string + language string + imageType string + imageId string urlParams_ gensupport.URLParams ctx_ context.Context header_ http.Header } -// Validate: Validates an app edit. +// Delete: Deletes the image (specified by id) from the edit. // -// - editId: Identifier of the edit. -// - packageName: Package name of the app. -func (r *EditsService) Validate(packageName string, editId string) *EditsValidateCall { - c := &EditsValidateCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// - editId: Identifier of the edit. +// - imageId: Unique identifier an image within the set of images attached to +// this edit. +// - imageType: Type of the Image. +// - language: Language localization code (a BCP-47 language tag; for example, +// "de-AT" for Austrian German). +// - packageName: Package name of the app. +func (r *EditsImagesService) Delete(packageName string, editId string, language string, imageType string, imageId string) *EditsImagesDeleteCall { + c := &EditsImagesDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.packageName = packageName c.editId = editId + c.language = language + c.imageType = imageType + c.imageId = imageId 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 *EditsValidateCall) Fields(s ...googleapi.Field) *EditsValidateCall { +func (c *EditsImagesDeleteCall) Fields(s ...googleapi.Field) *EditsImagesDeleteCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } // Context sets the context to be used in this call's Do method. -func (c *EditsValidateCall) Context(ctx context.Context) *EditsValidateCall { +func (c *EditsImagesDeleteCall) Context(ctx context.Context) *EditsImagesDeleteCall { 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 *EditsValidateCall) Header() http.Header { +func (c *EditsImagesDeleteCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *EditsValidateCall) doRequest(alt string) (*http.Response, error) { +func (c *EditsImagesDeleteCall) doRequest(alt string) (*http.Response, error) { reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}:validate") + urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/listings/{language}/{imageType}/{imageId}") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("POST", urls, nil) + req, err := http.NewRequest("DELETE", urls, nil) if err != nil { return nil, err } @@ -9886,109 +13410,89 @@ func (c *EditsValidateCall) doRequest(alt string) (*http.Response, error) { googleapi.Expand(req.URL, map[string]string{ "packageName": c.packageName, "editId": c.editId, + "language": c.language, + "imageType": c.imageType, + "imageId": c.imageId, }) - c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.edits.validate", "request", internallog.HTTPRequest(req, nil)) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.edits.images.delete", "request", internallog.HTTPRequest(req, nil)) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "androidpublisher.edits.validate" call. -// Any non-2xx status code is an error. Response headers are in either -// *AppEdit.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 *EditsValidateCall) Do(opts ...googleapi.CallOption) (*AppEdit, error) { +// Do executes the "androidpublisher.edits.images.delete" call. +func (c *EditsImagesDeleteCall) Do(opts ...googleapi.CallOption) 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 + return err } defer googleapi.CloseBody(res) if err := googleapi.CheckResponse(res); err != nil { - return nil, gensupport.WrapError(err) - } - ret := &AppEdit{ - ServerResponse: googleapi.ServerResponse{ - Header: res.Header, - HTTPStatusCode: res.StatusCode, - }, - } - target := &ret - b, err := gensupport.DecodeResponseBytes(target, res) - if err != nil { - return nil, err + return gensupport.WrapError(err) } - c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.edits.validate", "response", internallog.HTTPResponse(res, b)) - return ret, nil + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.edits.images.delete", "response", internallog.HTTPResponse(res, nil)) + return nil } -type EditsApksAddexternallyhostedCall struct { - s *Service - packageName string - editId string - apksaddexternallyhostedrequest *ApksAddExternallyHostedRequest - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +type EditsImagesDeleteallCall struct { + s *Service + packageName string + editId string + language string + imageType string + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// Addexternallyhosted: Creates a new APK without uploading the APK itself to -// Google Play, instead hosting the APK at a specified URL. This function is -// only available to organizations using Managed Play whose application is -// configured to restrict distribution to the organizations. +// Deleteall: Deletes all images for the specified language and image type. +// Returns an empty response if no images are found. // -// - editId: Identifier of the edit. -// - packageName: Package name of the app. -func (r *EditsApksService) Addexternallyhosted(packageName string, editId string, apksaddexternallyhostedrequest *ApksAddExternallyHostedRequest) *EditsApksAddexternallyhostedCall { - c := &EditsApksAddexternallyhostedCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// - editId: Identifier of the edit. +// - imageType: Type of the Image. Providing an image type that refers to no +// images is a no-op. +// - language: Language localization code (a BCP-47 language tag; for example, +// "de-AT" for Austrian German). Providing a language that is not supported +// by the App is a no-op. +// - packageName: Package name of the app. +func (r *EditsImagesService) Deleteall(packageName string, editId string, language string, imageType string) *EditsImagesDeleteallCall { + c := &EditsImagesDeleteallCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.packageName = packageName c.editId = editId - c.apksaddexternallyhostedrequest = apksaddexternallyhostedrequest + c.language = language + c.imageType = imageType 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 *EditsApksAddexternallyhostedCall) Fields(s ...googleapi.Field) *EditsApksAddexternallyhostedCall { +func (c *EditsImagesDeleteallCall) Fields(s ...googleapi.Field) *EditsImagesDeleteallCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } // Context sets the context to be used in this call's Do method. -func (c *EditsApksAddexternallyhostedCall) Context(ctx context.Context) *EditsApksAddexternallyhostedCall { +func (c *EditsImagesDeleteallCall) Context(ctx context.Context) *EditsImagesDeleteallCall { 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 *EditsApksAddexternallyhostedCall) Header() http.Header { +func (c *EditsImagesDeleteallCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *EditsApksAddexternallyhostedCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) - body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.apksaddexternallyhostedrequest) - if err != nil { - return nil, err - } +func (c *EditsImagesDeleteallCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/apks/externallyHosted") + urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/listings/{language}/{imageType}") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("POST", urls, body) + req, err := http.NewRequest("DELETE", urls, nil) if err != nil { return nil, err } @@ -9996,18 +13500,20 @@ func (c *EditsApksAddexternallyhostedCall) doRequest(alt string) (*http.Response googleapi.Expand(req.URL, map[string]string{ "packageName": c.packageName, "editId": c.editId, + "language": c.language, + "imageType": c.imageType, }) - c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.edits.apks.addexternallyhosted", "request", internallog.HTTPRequest(req, body.Bytes())) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.edits.images.deleteall", "request", internallog.HTTPRequest(req, nil)) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "androidpublisher.edits.apks.addexternallyhosted" call. +// Do executes the "androidpublisher.edits.images.deleteall" call. // Any non-2xx status code is an error. Response headers are in either -// *ApksAddExternallyHostedResponse.ServerResponse.Header or (if a response was +// *ImagesDeleteAllResponse.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 *EditsApksAddexternallyhostedCall) Do(opts ...googleapi.CallOption) (*ApksAddExternallyHostedResponse, error) { +func (c *EditsImagesDeleteallCall) Do(opts ...googleapi.CallOption) (*ImagesDeleteAllResponse, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -10026,7 +13532,7 @@ func (c *EditsApksAddexternallyhostedCall) Do(opts ...googleapi.CallOption) (*Ap if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &ApksAddExternallyHostedResponse{ + ret := &ImagesDeleteAllResponse{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -10037,35 +13543,44 @@ func (c *EditsApksAddexternallyhostedCall) Do(opts ...googleapi.CallOption) (*Ap if err != nil { return nil, err } - c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.edits.apks.addexternallyhosted", "response", internallog.HTTPResponse(res, b)) + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.edits.images.deleteall", "response", internallog.HTTPResponse(res, b)) return ret, nil } -type EditsApksListCall struct { +type EditsImagesListCall struct { s *Service packageName string editId string + language string + imageType string urlParams_ gensupport.URLParams ifNoneMatch_ string ctx_ context.Context header_ http.Header } -// List: Lists all current APKs of the app and edit. +// List: Lists all images. The response may be empty. // -// - editId: Identifier of the edit. -// - packageName: Package name of the app. -func (r *EditsApksService) List(packageName string, editId string) *EditsApksListCall { - c := &EditsApksListCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// - editId: Identifier of the edit. +// - imageType: Type of the Image. Providing an image type that refers to no +// images will return an empty response. +// - language: Language localization code (a BCP-47 language tag; for example, +// "de-AT" for Austrian German). There must be a store listing for the +// specified language. +// - packageName: Package name of the app. +func (r *EditsImagesService) List(packageName string, editId string, language string, imageType string) *EditsImagesListCall { + c := &EditsImagesListCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.packageName = packageName c.editId = editId + c.language = language + c.imageType = imageType 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 *EditsApksListCall) Fields(s ...googleapi.Field) *EditsApksListCall { +func (c *EditsImagesListCall) Fields(s ...googleapi.Field) *EditsImagesListCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } @@ -10073,34 +13588,34 @@ func (c *EditsApksListCall) Fields(s ...googleapi.Field) *EditsApksListCall { // 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 *EditsApksListCall) IfNoneMatch(entityTag string) *EditsApksListCall { +func (c *EditsImagesListCall) IfNoneMatch(entityTag string) *EditsImagesListCall { c.ifNoneMatch_ = entityTag return c } // Context sets the context to be used in this call's Do method. -func (c *EditsApksListCall) Context(ctx context.Context) *EditsApksListCall { +func (c *EditsImagesListCall) Context(ctx context.Context) *EditsImagesListCall { 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 *EditsApksListCall) Header() http.Header { +func (c *EditsImagesListCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *EditsApksListCall) doRequest(alt string) (*http.Response, error) { +func (c *EditsImagesListCall) doRequest(alt string) (*http.Response, error) { reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) if c.ifNoneMatch_ != "" { reqHeaders.Set("If-None-Match", c.ifNoneMatch_) } c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/apks") + urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/listings/{language}/{imageType}") urls += "?" + c.urlParams_.Encode() req, err := http.NewRequest("GET", urls, nil) if err != nil { @@ -10110,18 +13625,20 @@ func (c *EditsApksListCall) doRequest(alt string) (*http.Response, error) { googleapi.Expand(req.URL, map[string]string{ "packageName": c.packageName, "editId": c.editId, + "language": c.language, + "imageType": c.imageType, }) - c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.edits.apks.list", "request", internallog.HTTPRequest(req, nil)) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.edits.images.list", "request", internallog.HTTPRequest(req, nil)) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "androidpublisher.edits.apks.list" call. +// Do executes the "androidpublisher.edits.images.list" call. // Any non-2xx status code is an error. Response headers are in either -// *ApksListResponse.ServerResponse.Header or (if a response was returned at +// *ImagesListResponse.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 *EditsApksListCall) Do(opts ...googleapi.CallOption) (*ApksListResponse, error) { +func (c *EditsImagesListCall) Do(opts ...googleapi.CallOption) (*ImagesListResponse, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -10140,7 +13657,7 @@ func (c *EditsApksListCall) Do(opts ...googleapi.CallOption) (*ApksListResponse, if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &ApksListResponse{ + ret := &ImagesListResponse{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -10151,28 +13668,37 @@ func (c *EditsApksListCall) Do(opts ...googleapi.CallOption) (*ApksListResponse, if err != nil { return nil, err } - c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.edits.apks.list", "response", internallog.HTTPResponse(res, b)) + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.edits.images.list", "response", internallog.HTTPResponse(res, b)) return ret, nil } -type EditsApksUploadCall struct { +type EditsImagesUploadCall struct { s *Service packageName string editId string + language string + imageType string urlParams_ gensupport.URLParams mediaInfo_ *gensupport.MediaInfo ctx_ context.Context header_ http.Header } -// Upload: Uploads an APK and adds to the current edit. +// Upload: Uploads an image of the specified language and image type, and adds +// to the edit. // -// - editId: Identifier of the edit. -// - packageName: Package name of the app. -func (r *EditsApksService) Upload(packageName string, editId string) *EditsApksUploadCall { - c := &EditsApksUploadCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// - editId: Identifier of the edit. +// - imageType: Type of the Image. +// - language: Language localization code (a BCP-47 language tag; for example, +// "de-AT" for Austrian German). Providing a language that is not supported +// by the App is a no-op. +// - packageName: Package name of the app. +func (r *EditsImagesService) Upload(packageName string, editId string, language string, imageType string) *EditsImagesUploadCall { + c := &EditsImagesUploadCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.packageName = packageName c.editId = editId + c.language = language + c.imageType = imageType return c } @@ -10183,7 +13709,7 @@ func (r *EditsApksService) Upload(packageName string, editId string) *EditsApksU // request will be determined by sniffing the contents of r, unless a // MediaOption generated by googleapi.ContentType is supplied. // At most one of Media and ResumableMedia may be set. -func (c *EditsApksUploadCall) Media(r io.Reader, options ...googleapi.MediaOption) *EditsApksUploadCall { +func (c *EditsImagesUploadCall) Media(r io.Reader, options ...googleapi.MediaOption) *EditsImagesUploadCall { c.mediaInfo_ = gensupport.NewInfoFromMedia(r, options) return c } @@ -10197,7 +13723,7 @@ func (c *EditsApksUploadCall) Media(r io.Reader, options ...googleapi.MediaOptio // MIME media type of the upload, such as "image/png". If mediaType is "", it // will be auto-detected. The provided ctx will supersede any context // previously provided to the Context method. -func (c *EditsApksUploadCall) ResumableMedia(ctx context.Context, r io.ReaderAt, size int64, mediaType string) *EditsApksUploadCall { +func (c *EditsImagesUploadCall) ResumableMedia(ctx context.Context, r io.ReaderAt, size int64, mediaType string) *EditsImagesUploadCall { c.ctx_ = ctx c.mediaInfo_ = gensupport.NewInfoFromResumableMedia(r, size, mediaType) return c @@ -10207,7 +13733,7 @@ func (c *EditsApksUploadCall) ResumableMedia(ctx context.Context, r io.ReaderAt, // chunk. It should be a low-latency function in order to not slow down the // upload operation. This should only be called when using ResumableMedia (as // opposed to Media). -func (c *EditsApksUploadCall) ProgressUpdater(pu googleapi.ProgressUpdater) *EditsApksUploadCall { +func (c *EditsImagesUploadCall) ProgressUpdater(pu googleapi.ProgressUpdater) *EditsImagesUploadCall { c.mediaInfo_.SetProgressUpdater(pu) return c } @@ -10215,7 +13741,7 @@ func (c *EditsApksUploadCall) ProgressUpdater(pu googleapi.ProgressUpdater) *Edi // Fields allows partial responses to be retrieved. See // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more // details. -func (c *EditsApksUploadCall) Fields(s ...googleapi.Field) *EditsApksUploadCall { +func (c *EditsImagesUploadCall) Fields(s ...googleapi.Field) *EditsImagesUploadCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } @@ -10223,27 +13749,27 @@ func (c *EditsApksUploadCall) Fields(s ...googleapi.Field) *EditsApksUploadCall // Context sets the context to be used in this call's Do method. // This context will supersede any context previously provided to the // ResumableMedia method. -func (c *EditsApksUploadCall) Context(ctx context.Context) *EditsApksUploadCall { +func (c *EditsImagesUploadCall) Context(ctx context.Context) *EditsImagesUploadCall { 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 *EditsApksUploadCall) Header() http.Header { +func (c *EditsImagesUploadCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *EditsApksUploadCall) doRequest(alt string) (*http.Response, error) { +func (c *EditsImagesUploadCall) doRequest(alt string) (*http.Response, error) { reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/apks") + urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/listings/{language}/{imageType}") if c.mediaInfo_ != nil { - urls = googleapi.ResolveRelative(c.s.BasePath, "/upload/androidpublisher/v3/applications/{packageName}/edits/{editId}/apks") + urls = googleapi.ResolveRelative(c.s.BasePath, "/upload/androidpublisher/v3/applications/{packageName}/edits/{editId}/listings/{language}/{imageType}") c.urlParams_.Set("uploadType", c.mediaInfo_.UploadType()) } newBody, getBody, cleanup := c.mediaInfo_.UploadRequest(reqHeaders, nil) @@ -10258,17 +13784,20 @@ func (c *EditsApksUploadCall) doRequest(alt string) (*http.Response, error) { googleapi.Expand(req.URL, map[string]string{ "packageName": c.packageName, "editId": c.editId, + "language": c.language, + "imageType": c.imageType, }) - c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.edits.apks.upload", "request", internallog.HTTPRequest(req, nil)) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.edits.images.upload", "request", internallog.HTTPRequest(req, nil)) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "androidpublisher.edits.apks.upload" call. +// Do executes the "androidpublisher.edits.images.upload" call. // Any non-2xx status code is an error. Response headers are in either -// *Apk.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 *EditsApksUploadCall) Do(opts ...googleapi.CallOption) (*Apk, error) { +// *ImagesUploadResponse.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 *EditsImagesUploadCall) Do(opts ...googleapi.CallOption) (*ImagesUploadResponse, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -10304,7 +13833,7 @@ func (c *EditsApksUploadCall) Do(opts ...googleapi.CallOption) (*Apk, error) { return nil, gensupport.WrapError(err) } } - ret := &Apk{ + ret := &ImagesUploadResponse{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -10313,37 +13842,200 @@ func (c *EditsApksUploadCall) Do(opts ...googleapi.CallOption) (*Apk, error) { target := &ret b, err := gensupport.DecodeResponseBytes(target, res) if err != nil { - return nil, err + return nil, err + } + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.edits.images.upload", "response", internallog.HTTPResponse(res, b)) + return ret, nil +} + +type EditsListingsDeleteCall struct { + s *Service + packageName string + editId string + language string + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Delete: Deletes a localized store listing. +// +// - editId: Identifier of the edit. +// - language: Language localization code (a BCP-47 language tag; for example, +// "de-AT" for Austrian German). +// - packageName: Package name of the app. +func (r *EditsListingsService) Delete(packageName string, editId string, language string) *EditsListingsDeleteCall { + c := &EditsListingsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.packageName = packageName + c.editId = editId + c.language = language + 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 *EditsListingsDeleteCall) Fields(s ...googleapi.Field) *EditsListingsDeleteCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *EditsListingsDeleteCall) Context(ctx context.Context) *EditsListingsDeleteCall { + 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 *EditsListingsDeleteCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *EditsListingsDeleteCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/listings/{language}") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("DELETE", urls, nil) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "packageName": c.packageName, + "editId": c.editId, + "language": c.language, + }) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.edits.listings.delete", "request", internallog.HTTPRequest(req, nil)) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "androidpublisher.edits.listings.delete" call. +func (c *EditsListingsDeleteCall) 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) + } + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.edits.listings.delete", "response", internallog.HTTPResponse(res, nil)) + return nil +} + +type EditsListingsDeleteallCall struct { + s *Service + packageName string + editId string + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Deleteall: Deletes all store listings. +// +// - editId: Identifier of the edit. +// - packageName: Package name of the app. +func (r *EditsListingsService) Deleteall(packageName string, editId string) *EditsListingsDeleteallCall { + c := &EditsListingsDeleteallCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.packageName = packageName + c.editId = editId + 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 *EditsListingsDeleteallCall) Fields(s ...googleapi.Field) *EditsListingsDeleteallCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *EditsListingsDeleteallCall) Context(ctx context.Context) *EditsListingsDeleteallCall { + 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 *EditsListingsDeleteallCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *EditsListingsDeleteallCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/listings") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("DELETE", urls, nil) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "packageName": c.packageName, + "editId": c.editId, + }) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.edits.listings.deleteall", "request", internallog.HTTPRequest(req, nil)) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "androidpublisher.edits.listings.deleteall" call. +func (c *EditsListingsDeleteallCall) Do(opts ...googleapi.CallOption) error { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if err != nil { + return err } - c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.edits.apks.upload", "response", internallog.HTTPResponse(res, b)) - return ret, nil + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return gensupport.WrapError(err) + } + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.edits.listings.deleteall", "response", internallog.HTTPResponse(res, nil)) + return nil } -type EditsBundlesListCall struct { +type EditsListingsGetCall struct { s *Service packageName string editId string + language string urlParams_ gensupport.URLParams ifNoneMatch_ string ctx_ context.Context header_ http.Header } -// List: Lists all current Android App Bundles of the app and edit. +// Get: Gets a localized store listing. // -// - editId: Identifier of the edit. -// - packageName: Package name of the app. -func (r *EditsBundlesService) List(packageName string, editId string) *EditsBundlesListCall { - c := &EditsBundlesListCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// - editId: Identifier of the edit. +// - language: Language localization code (a BCP-47 language tag; for example, +// "de-AT" for Austrian German). +// - packageName: Package name of the app. +func (r *EditsListingsService) Get(packageName string, editId string, language string) *EditsListingsGetCall { + c := &EditsListingsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.packageName = packageName c.editId = editId + c.language = language 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 *EditsBundlesListCall) Fields(s ...googleapi.Field) *EditsBundlesListCall { +func (c *EditsListingsGetCall) Fields(s ...googleapi.Field) *EditsListingsGetCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } @@ -10351,34 +14043,34 @@ func (c *EditsBundlesListCall) Fields(s ...googleapi.Field) *EditsBundlesListCal // 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 *EditsBundlesListCall) IfNoneMatch(entityTag string) *EditsBundlesListCall { +func (c *EditsListingsGetCall) IfNoneMatch(entityTag string) *EditsListingsGetCall { c.ifNoneMatch_ = entityTag return c } // Context sets the context to be used in this call's Do method. -func (c *EditsBundlesListCall) Context(ctx context.Context) *EditsBundlesListCall { +func (c *EditsListingsGetCall) Context(ctx context.Context) *EditsListingsGetCall { 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 *EditsBundlesListCall) Header() http.Header { +func (c *EditsListingsGetCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *EditsBundlesListCall) doRequest(alt string) (*http.Response, error) { +func (c *EditsListingsGetCall) doRequest(alt string) (*http.Response, error) { reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) if c.ifNoneMatch_ != "" { reqHeaders.Set("If-None-Match", c.ifNoneMatch_) } c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/bundles") + urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/listings/{language}") urls += "?" + c.urlParams_.Encode() req, err := http.NewRequest("GET", urls, nil) if err != nil { @@ -10388,18 +14080,18 @@ func (c *EditsBundlesListCall) doRequest(alt string) (*http.Response, error) { googleapi.Expand(req.URL, map[string]string{ "packageName": c.packageName, "editId": c.editId, + "language": c.language, }) - c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.edits.bundles.list", "request", internallog.HTTPRequest(req, nil)) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.edits.listings.get", "request", internallog.HTTPRequest(req, nil)) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "androidpublisher.edits.bundles.list" call. +// Do executes the "androidpublisher.edits.listings.get" call. // Any non-2xx status code is an error. Response headers are in either -// *BundlesListResponse.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 *EditsBundlesListCall) Do(opts ...googleapi.CallOption) (*BundlesListResponse, error) { +// *Listing.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 *EditsListingsGetCall) Do(opts ...googleapi.CallOption) (*Listing, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -10418,7 +14110,7 @@ func (c *EditsBundlesListCall) Do(opts ...googleapi.CallOption) (*BundlesListRes if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &BundlesListResponse{ + ret := &Listing{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -10429,145 +14121,91 @@ func (c *EditsBundlesListCall) Do(opts ...googleapi.CallOption) (*BundlesListRes if err != nil { return nil, err } - c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.edits.bundles.list", "response", internallog.HTTPResponse(res, b)) + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.edits.listings.get", "response", internallog.HTTPResponse(res, b)) return ret, nil } -type EditsBundlesUploadCall struct { - s *Service - packageName string - editId string - urlParams_ gensupport.URLParams - mediaInfo_ *gensupport.MediaInfo - ctx_ context.Context - header_ http.Header +type EditsListingsListCall struct { + s *Service + packageName string + editId string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header } -// Upload: Uploads a new Android App Bundle to this edit. If you are using the -// Google API client libraries, please increase the timeout of the http request -// before calling this endpoint (a timeout of 2 minutes is recommended). See -// Timeouts and Errors -// (https://developers.google.com/api-client-library/java/google-api-java-client/errors) -// for an example in java. +// List: Lists all localized store listings. // // - editId: Identifier of the edit. // - packageName: Package name of the app. -func (r *EditsBundlesService) Upload(packageName string, editId string) *EditsBundlesUploadCall { - c := &EditsBundlesUploadCall{s: r.s, urlParams_: make(gensupport.URLParams)} +func (r *EditsListingsService) List(packageName string, editId string) *EditsListingsListCall { + c := &EditsListingsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.packageName = packageName c.editId = editId return c } -// AckBundleInstallationWarning sets the optional parameter -// "ackBundleInstallationWarning": Deprecated. The installation warning has -// been removed, it's not necessary to set this field anymore. -func (c *EditsBundlesUploadCall) AckBundleInstallationWarning(ackBundleInstallationWarning bool) *EditsBundlesUploadCall { - c.urlParams_.Set("ackBundleInstallationWarning", fmt.Sprint(ackBundleInstallationWarning)) - return c -} - -// DeviceTierConfigId sets the optional parameter "deviceTierConfigId": Device -// tier config (DTC) to be used for generating deliverables (APKs). Contains id -// of the DTC or "LATEST" for last uploaded DTC. -func (c *EditsBundlesUploadCall) DeviceTierConfigId(deviceTierConfigId string) *EditsBundlesUploadCall { - c.urlParams_.Set("deviceTierConfigId", deviceTierConfigId) - return c -} - -// Media specifies the media to upload in one or more chunks. The chunk size -// may be controlled by supplying a MediaOption generated by -// googleapi.ChunkSize. The chunk size defaults to -// googleapi.DefaultUploadChunkSize.The Content-Type header used in the upload -// request will be determined by sniffing the contents of r, unless a -// MediaOption generated by googleapi.ContentType is supplied. -// At most one of Media and ResumableMedia may be set. -func (c *EditsBundlesUploadCall) Media(r io.Reader, options ...googleapi.MediaOption) *EditsBundlesUploadCall { - c.mediaInfo_ = gensupport.NewInfoFromMedia(r, options) - return c -} - -// ResumableMedia specifies the media to upload in chunks and can be canceled -// with ctx. -// -// Deprecated: use Media instead. -// -// At most one of Media and ResumableMedia may be set. mediaType identifies the -// MIME media type of the upload, such as "image/png". If mediaType is "", it -// will be auto-detected. The provided ctx will supersede any context -// previously provided to the Context method. -func (c *EditsBundlesUploadCall) ResumableMedia(ctx context.Context, r io.ReaderAt, size int64, mediaType string) *EditsBundlesUploadCall { - c.ctx_ = ctx - c.mediaInfo_ = gensupport.NewInfoFromResumableMedia(r, size, mediaType) - return c -} - -// ProgressUpdater provides a callback function that will be called after every -// chunk. It should be a low-latency function in order to not slow down the -// upload operation. This should only be called when using ResumableMedia (as -// opposed to Media). -func (c *EditsBundlesUploadCall) ProgressUpdater(pu googleapi.ProgressUpdater) *EditsBundlesUploadCall { - c.mediaInfo_.SetProgressUpdater(pu) - 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 *EditsBundlesUploadCall) Fields(s ...googleapi.Field) *EditsBundlesUploadCall { +func (c *EditsListingsListCall) Fields(s ...googleapi.Field) *EditsListingsListCall { 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 *EditsListingsListCall) IfNoneMatch(entityTag string) *EditsListingsListCall { + c.ifNoneMatch_ = entityTag + return c +} + // Context sets the context to be used in this call's Do method. -// This context will supersede any context previously provided to the -// ResumableMedia method. -func (c *EditsBundlesUploadCall) Context(ctx context.Context) *EditsBundlesUploadCall { +func (c *EditsListingsListCall) Context(ctx context.Context) *EditsListingsListCall { 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 *EditsBundlesUploadCall) Header() http.Header { +func (c *EditsListingsListCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *EditsBundlesUploadCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) +func (c *EditsListingsListCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) + } c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/bundles") - if c.mediaInfo_ != nil { - urls = googleapi.ResolveRelative(c.s.BasePath, "/upload/androidpublisher/v3/applications/{packageName}/edits/{editId}/bundles") - c.urlParams_.Set("uploadType", c.mediaInfo_.UploadType()) - } - newBody, getBody, cleanup := c.mediaInfo_.UploadRequest(reqHeaders, nil) - defer cleanup() + urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/listings") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("POST", urls, newBody) + req, err := http.NewRequest("GET", urls, nil) if err != nil { return nil, err } req.Header = reqHeaders - req.GetBody = getBody googleapi.Expand(req.URL, map[string]string{ "packageName": c.packageName, "editId": c.editId, }) - c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.edits.bundles.upload", "request", internallog.HTTPRequest(req, nil)) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.edits.listings.list", "request", internallog.HTTPRequest(req, nil)) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "androidpublisher.edits.bundles.upload" call. +// Do executes the "androidpublisher.edits.listings.list" call. // Any non-2xx status code is an error. Response headers are in either -// *Bundle.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 *EditsBundlesUploadCall) Do(opts ...googleapi.CallOption) (*Bundle, error) { +// *ListingsListResponse.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 *EditsListingsListCall) Do(opts ...googleapi.CallOption) (*ListingsListResponse, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -10586,24 +14224,7 @@ func (c *EditsBundlesUploadCall) Do(opts ...googleapi.CallOption) (*Bundle, erro if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - rx := c.mediaInfo_.ResumableUpload(res.Header.Get("Location")) - if rx != nil { - rx.Client = c.s.client - rx.UserAgent = c.s.userAgent() - ctx := c.ctx_ - if ctx == nil { - ctx = context.TODO() - } - res, err = rx.Upload(ctx) - if err != nil { - return nil, err - } - defer res.Body.Close() - if err := googleapi.CheckResponse(res); err != nil { - return nil, gensupport.WrapError(err) - } - } - ret := &Bundle{ + ret := &ListingsListResponse{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -10614,75 +14235,70 @@ func (c *EditsBundlesUploadCall) Do(opts ...googleapi.CallOption) (*Bundle, erro if err != nil { return nil, err } - c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.edits.bundles.upload", "response", internallog.HTTPResponse(res, b)) + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.edits.listings.list", "response", internallog.HTTPResponse(res, b)) return ret, nil } -type EditsCountryavailabilityGetCall struct { - s *Service - packageName string - editId string - track string - urlParams_ gensupport.URLParams - ifNoneMatch_ string - ctx_ context.Context - header_ http.Header +type EditsListingsPatchCall struct { + s *Service + packageName string + editId string + language string + listing *Listing + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// Get: Gets country availability. +// Patch: Patches a localized store listing. // -// - editId: Identifier of the edit. -// - packageName: Package name of the app. -// - track: The track to read from. -func (r *EditsCountryavailabilityService) Get(packageName string, editId string, track string) *EditsCountryavailabilityGetCall { - c := &EditsCountryavailabilityGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// - editId: Identifier of the edit. +// - language: Language localization code (a BCP-47 language tag; for example, +// "de-AT" for Austrian German). +// - packageName: Package name of the app. +func (r *EditsListingsService) Patch(packageName string, editId string, language string, listing *Listing) *EditsListingsPatchCall { + c := &EditsListingsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.packageName = packageName c.editId = editId - c.track = track + c.language = language + c.listing = listing 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 *EditsCountryavailabilityGetCall) Fields(s ...googleapi.Field) *EditsCountryavailabilityGetCall { - 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 *EditsCountryavailabilityGetCall) IfNoneMatch(entityTag string) *EditsCountryavailabilityGetCall { - c.ifNoneMatch_ = entityTag +// details. +func (c *EditsListingsPatchCall) Fields(s ...googleapi.Field) *EditsListingsPatchCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } // Context sets the context to be used in this call's Do method. -func (c *EditsCountryavailabilityGetCall) Context(ctx context.Context) *EditsCountryavailabilityGetCall { +func (c *EditsListingsPatchCall) Context(ctx context.Context) *EditsListingsPatchCall { 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 *EditsCountryavailabilityGetCall) Header() http.Header { +func (c *EditsListingsPatchCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *EditsCountryavailabilityGetCall) 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 *EditsListingsPatchCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) + body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.listing) + if err != nil { + return nil, err } c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/countryAvailability/{track}") + urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/listings/{language}") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("GET", urls, nil) + req, err := http.NewRequest("PATCH", urls, body) if err != nil { return nil, err } @@ -10690,19 +14306,18 @@ func (c *EditsCountryavailabilityGetCall) doRequest(alt string) (*http.Response, googleapi.Expand(req.URL, map[string]string{ "packageName": c.packageName, "editId": c.editId, - "track": c.track, + "language": c.language, }) - c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.edits.countryavailability.get", "request", internallog.HTTPRequest(req, nil)) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.edits.listings.patch", "request", internallog.HTTPRequest(req, body.Bytes())) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "androidpublisher.edits.countryavailability.get" call. +// Do executes the "androidpublisher.edits.listings.patch" call. // Any non-2xx status code is an error. Response headers are in either -// *TrackCountryAvailability.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 *EditsCountryavailabilityGetCall) Do(opts ...googleapi.CallOption) (*TrackCountryAvailability, error) { +// *Listing.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 *EditsListingsPatchCall) Do(opts ...googleapi.CallOption) (*Listing, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -10721,7 +14336,7 @@ func (c *EditsCountryavailabilityGetCall) Do(opts ...googleapi.CallOption) (*Tra if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &TrackCountryAvailability{ + ret := &Listing{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -10732,134 +14347,89 @@ func (c *EditsCountryavailabilityGetCall) Do(opts ...googleapi.CallOption) (*Tra if err != nil { return nil, err } - c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.edits.countryavailability.get", "response", internallog.HTTPResponse(res, b)) + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.edits.listings.patch", "response", internallog.HTTPResponse(res, b)) return ret, nil } -type EditsDeobfuscationfilesUploadCall struct { - s *Service - packageNameid string - editId string - apkVersionCode int64 - deobfuscationFileType string - urlParams_ gensupport.URLParams - mediaInfo_ *gensupport.MediaInfo - ctx_ context.Context - header_ http.Header +type EditsListingsUpdateCall struct { + s *Service + packageName string + editId string + language string + listing *Listing + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// Upload: Uploads a new deobfuscation file and attaches to the specified APK. +// Update: Creates or updates a localized store listing. // -// - apkVersionCode: The version code of the APK whose Deobfuscation File is -// being uploaded. -// - deobfuscationFileType: The type of the deobfuscation file. -// - editId: Unique identifier for this edit. -// - packageName: Unique identifier for the Android app. -func (r *EditsDeobfuscationfilesService) Upload(packageNameid string, editId string, apkVersionCode int64, deobfuscationFileType string) *EditsDeobfuscationfilesUploadCall { - c := &EditsDeobfuscationfilesUploadCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.packageNameid = packageNameid +// - editId: Identifier of the edit. +// - language: Language localization code (a BCP-47 language tag; for example, +// "de-AT" for Austrian German). +// - packageName: Package name of the app. +func (r *EditsListingsService) Update(packageName string, editId string, language string, listing *Listing) *EditsListingsUpdateCall { + c := &EditsListingsUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.packageName = packageName c.editId = editId - c.apkVersionCode = apkVersionCode - c.deobfuscationFileType = deobfuscationFileType - return c -} - -// Media specifies the media to upload in one or more chunks. The chunk size -// may be controlled by supplying a MediaOption generated by -// googleapi.ChunkSize. The chunk size defaults to -// googleapi.DefaultUploadChunkSize.The Content-Type header used in the upload -// request will be determined by sniffing the contents of r, unless a -// MediaOption generated by googleapi.ContentType is supplied. -// At most one of Media and ResumableMedia may be set. -func (c *EditsDeobfuscationfilesUploadCall) Media(r io.Reader, options ...googleapi.MediaOption) *EditsDeobfuscationfilesUploadCall { - c.mediaInfo_ = gensupport.NewInfoFromMedia(r, options) - return c -} - -// ResumableMedia specifies the media to upload in chunks and can be canceled -// with ctx. -// -// Deprecated: use Media instead. -// -// At most one of Media and ResumableMedia may be set. mediaType identifies the -// MIME media type of the upload, such as "image/png". If mediaType is "", it -// will be auto-detected. The provided ctx will supersede any context -// previously provided to the Context method. -func (c *EditsDeobfuscationfilesUploadCall) ResumableMedia(ctx context.Context, r io.ReaderAt, size int64, mediaType string) *EditsDeobfuscationfilesUploadCall { - c.ctx_ = ctx - c.mediaInfo_ = gensupport.NewInfoFromResumableMedia(r, size, mediaType) - return c -} - -// ProgressUpdater provides a callback function that will be called after every -// chunk. It should be a low-latency function in order to not slow down the -// upload operation. This should only be called when using ResumableMedia (as -// opposed to Media). -func (c *EditsDeobfuscationfilesUploadCall) ProgressUpdater(pu googleapi.ProgressUpdater) *EditsDeobfuscationfilesUploadCall { - c.mediaInfo_.SetProgressUpdater(pu) + c.language = language + c.listing = listing 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 *EditsDeobfuscationfilesUploadCall) Fields(s ...googleapi.Field) *EditsDeobfuscationfilesUploadCall { +func (c *EditsListingsUpdateCall) Fields(s ...googleapi.Field) *EditsListingsUpdateCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } // Context sets the context to be used in this call's Do method. -// This context will supersede any context previously provided to the -// ResumableMedia method. -func (c *EditsDeobfuscationfilesUploadCall) Context(ctx context.Context) *EditsDeobfuscationfilesUploadCall { +func (c *EditsListingsUpdateCall) Context(ctx context.Context) *EditsListingsUpdateCall { 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 *EditsDeobfuscationfilesUploadCall) Header() http.Header { +func (c *EditsListingsUpdateCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *EditsDeobfuscationfilesUploadCall) doRequest(alt string) (*http.Response, error) { +func (c *EditsListingsUpdateCall) doRequest(alt string) (*http.Response, error) { reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) + body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.listing) + if err != nil { + return nil, err + } c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/apks/{apkVersionCode}/deobfuscationFiles/{deobfuscationFileType}") - if c.mediaInfo_ != nil { - urls = googleapi.ResolveRelative(c.s.BasePath, "/upload/androidpublisher/v3/applications/{packageName}/edits/{editId}/apks/{apkVersionCode}/deobfuscationFiles/{deobfuscationFileType}") - c.urlParams_.Set("uploadType", c.mediaInfo_.UploadType()) - } - newBody, getBody, cleanup := c.mediaInfo_.UploadRequest(reqHeaders, nil) - defer cleanup() + urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/listings/{language}") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("POST", urls, newBody) + req, err := http.NewRequest("PUT", urls, body) if err != nil { return nil, err } req.Header = reqHeaders - req.GetBody = getBody googleapi.Expand(req.URL, map[string]string{ - "packageName": c.packageNameid, - "editId": c.editId, - "apkVersionCode": strconv.FormatInt(c.apkVersionCode, 10), - "deobfuscationFileType": c.deobfuscationFileType, + "packageName": c.packageName, + "editId": c.editId, + "language": c.language, }) - c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.edits.deobfuscationfiles.upload", "request", internallog.HTTPRequest(req, nil)) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.edits.listings.update", "request", internallog.HTTPRequest(req, body.Bytes())) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "androidpublisher.edits.deobfuscationfiles.upload" call. +// Do executes the "androidpublisher.edits.listings.update" call. // Any non-2xx status code is an error. Response headers are in either -// *DeobfuscationFilesUploadResponse.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 *EditsDeobfuscationfilesUploadCall) Do(opts ...googleapi.CallOption) (*DeobfuscationFilesUploadResponse, error) { +// *Listing.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 *EditsListingsUpdateCall) Do(opts ...googleapi.CallOption) (*Listing, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -10878,24 +14448,7 @@ func (c *EditsDeobfuscationfilesUploadCall) Do(opts ...googleapi.CallOption) (*D if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - rx := c.mediaInfo_.ResumableUpload(res.Header.Get("Location")) - if rx != nil { - rx.Client = c.s.client - rx.UserAgent = c.s.userAgent() - ctx := c.ctx_ - if ctx == nil { - ctx = context.TODO() - } - res, err = rx.Upload(ctx) - if err != nil { - return nil, err - } - defer res.Body.Close() - if err := googleapi.CheckResponse(res); err != nil { - return nil, gensupport.WrapError(err) - } - } - ret := &DeobfuscationFilesUploadResponse{ + ret := &Listing{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -10906,35 +14459,38 @@ func (c *EditsDeobfuscationfilesUploadCall) Do(opts ...googleapi.CallOption) (*D if err != nil { return nil, err } - c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.edits.deobfuscationfiles.upload", "response", internallog.HTTPResponse(res, b)) + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.edits.listings.update", "response", internallog.HTTPResponse(res, b)) return ret, nil } -type EditsDetailsGetCall struct { +type EditsTestersGetCall struct { s *Service packageName string editId string + track string urlParams_ gensupport.URLParams ifNoneMatch_ string ctx_ context.Context header_ http.Header } -// Get: Gets details of an app. +// Get: Gets testers. Note: Testers resource does not support email lists. // // - editId: Identifier of the edit. // - packageName: Package name of the app. -func (r *EditsDetailsService) Get(packageName string, editId string) *EditsDetailsGetCall { - c := &EditsDetailsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// - track: The track to read from. +func (r *EditsTestersService) Get(packageName string, editId string, track string) *EditsTestersGetCall { + c := &EditsTestersGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.packageName = packageName c.editId = editId + c.track = track 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 *EditsDetailsGetCall) Fields(s ...googleapi.Field) *EditsDetailsGetCall { +func (c *EditsTestersGetCall) Fields(s ...googleapi.Field) *EditsTestersGetCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } @@ -10942,34 +14498,34 @@ func (c *EditsDetailsGetCall) Fields(s ...googleapi.Field) *EditsDetailsGetCall // 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 *EditsDetailsGetCall) IfNoneMatch(entityTag string) *EditsDetailsGetCall { +func (c *EditsTestersGetCall) IfNoneMatch(entityTag string) *EditsTestersGetCall { c.ifNoneMatch_ = entityTag return c } // Context sets the context to be used in this call's Do method. -func (c *EditsDetailsGetCall) Context(ctx context.Context) *EditsDetailsGetCall { +func (c *EditsTestersGetCall) Context(ctx context.Context) *EditsTestersGetCall { 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 *EditsDetailsGetCall) Header() http.Header { +func (c *EditsTestersGetCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *EditsDetailsGetCall) doRequest(alt string) (*http.Response, error) { +func (c *EditsTestersGetCall) doRequest(alt string) (*http.Response, error) { reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) if c.ifNoneMatch_ != "" { reqHeaders.Set("If-None-Match", c.ifNoneMatch_) } c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/details") + urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/testers/{track}") urls += "?" + c.urlParams_.Encode() req, err := http.NewRequest("GET", urls, nil) if err != nil { @@ -10979,17 +14535,18 @@ func (c *EditsDetailsGetCall) doRequest(alt string) (*http.Response, error) { googleapi.Expand(req.URL, map[string]string{ "packageName": c.packageName, "editId": c.editId, + "track": c.track, }) - c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.edits.details.get", "request", internallog.HTTPRequest(req, nil)) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.edits.testers.get", "request", internallog.HTTPRequest(req, nil)) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "androidpublisher.edits.details.get" call. +// Do executes the "androidpublisher.edits.testers.get" call. // Any non-2xx status code is an error. Response headers are in either -// *AppDetails.ServerResponse.Header or (if a response was returned at all) in +// *Testers.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 *EditsDetailsGetCall) Do(opts ...googleapi.CallOption) (*AppDetails, error) { +func (c *EditsTestersGetCall) Do(opts ...googleapi.CallOption) (*Testers, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -11008,7 +14565,7 @@ func (c *EditsDetailsGetCall) Do(opts ...googleapi.CallOption) (*AppDetails, err if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &AppDetails{ + ret := &Testers{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -11019,64 +14576,67 @@ func (c *EditsDetailsGetCall) Do(opts ...googleapi.CallOption) (*AppDetails, err if err != nil { return nil, err } - c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.edits.details.get", "response", internallog.HTTPResponse(res, b)) + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.edits.testers.get", "response", internallog.HTTPResponse(res, b)) return ret, nil } -type EditsDetailsPatchCall struct { +type EditsTestersPatchCall struct { s *Service packageName string editId string - appdetails *AppDetails + track string + testers *Testers urlParams_ gensupport.URLParams ctx_ context.Context header_ http.Header } -// Patch: Patches details of an app. +// Patch: Patches testers. Note: Testers resource does not support email lists. // // - editId: Identifier of the edit. // - packageName: Package name of the app. -func (r *EditsDetailsService) Patch(packageName string, editId string, appdetails *AppDetails) *EditsDetailsPatchCall { - c := &EditsDetailsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// - track: The track to update. +func (r *EditsTestersService) Patch(packageName string, editId string, track string, testers *Testers) *EditsTestersPatchCall { + c := &EditsTestersPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.packageName = packageName c.editId = editId - c.appdetails = appdetails + c.track = track + c.testers = testers 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 *EditsDetailsPatchCall) Fields(s ...googleapi.Field) *EditsDetailsPatchCall { +func (c *EditsTestersPatchCall) Fields(s ...googleapi.Field) *EditsTestersPatchCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } // Context sets the context to be used in this call's Do method. -func (c *EditsDetailsPatchCall) Context(ctx context.Context) *EditsDetailsPatchCall { +func (c *EditsTestersPatchCall) Context(ctx context.Context) *EditsTestersPatchCall { 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 *EditsDetailsPatchCall) Header() http.Header { +func (c *EditsTestersPatchCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *EditsDetailsPatchCall) doRequest(alt string) (*http.Response, error) { +func (c *EditsTestersPatchCall) doRequest(alt string) (*http.Response, error) { reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) - body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.appdetails) + body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.testers) if err != nil { return nil, err } c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/details") + urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/testers/{track}") urls += "?" + c.urlParams_.Encode() req, err := http.NewRequest("PATCH", urls, body) if err != nil { @@ -11086,17 +14646,18 @@ func (c *EditsDetailsPatchCall) doRequest(alt string) (*http.Response, error) { googleapi.Expand(req.URL, map[string]string{ "packageName": c.packageName, "editId": c.editId, + "track": c.track, }) - c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.edits.details.patch", "request", internallog.HTTPRequest(req, body.Bytes())) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.edits.testers.patch", "request", internallog.HTTPRequest(req, body.Bytes())) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "androidpublisher.edits.details.patch" call. +// Do executes the "androidpublisher.edits.testers.patch" call. // Any non-2xx status code is an error. Response headers are in either -// *AppDetails.ServerResponse.Header or (if a response was returned at all) in +// *Testers.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 *EditsDetailsPatchCall) Do(opts ...googleapi.CallOption) (*AppDetails, error) { +func (c *EditsTestersPatchCall) Do(opts ...googleapi.CallOption) (*Testers, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -11115,7 +14676,7 @@ func (c *EditsDetailsPatchCall) Do(opts ...googleapi.CallOption) (*AppDetails, e if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &AppDetails{ + ret := &Testers{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -11126,64 +14687,68 @@ func (c *EditsDetailsPatchCall) Do(opts ...googleapi.CallOption) (*AppDetails, e if err != nil { return nil, err } - c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.edits.details.patch", "response", internallog.HTTPResponse(res, b)) + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.edits.testers.patch", "response", internallog.HTTPResponse(res, b)) return ret, nil } -type EditsDetailsUpdateCall struct { +type EditsTestersUpdateCall struct { s *Service packageName string editId string - appdetails *AppDetails + track string + testers *Testers urlParams_ gensupport.URLParams ctx_ context.Context header_ http.Header } -// Update: Updates details of an app. +// Update: Updates testers. Note: Testers resource does not support email +// lists. // // - editId: Identifier of the edit. // - packageName: Package name of the app. -func (r *EditsDetailsService) Update(packageName string, editId string, appdetails *AppDetails) *EditsDetailsUpdateCall { - c := &EditsDetailsUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// - track: The track to update. +func (r *EditsTestersService) Update(packageName string, editId string, track string, testers *Testers) *EditsTestersUpdateCall { + c := &EditsTestersUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.packageName = packageName c.editId = editId - c.appdetails = appdetails + c.track = track + c.testers = testers 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 *EditsDetailsUpdateCall) Fields(s ...googleapi.Field) *EditsDetailsUpdateCall { +func (c *EditsTestersUpdateCall) Fields(s ...googleapi.Field) *EditsTestersUpdateCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } // Context sets the context to be used in this call's Do method. -func (c *EditsDetailsUpdateCall) Context(ctx context.Context) *EditsDetailsUpdateCall { +func (c *EditsTestersUpdateCall) Context(ctx context.Context) *EditsTestersUpdateCall { 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 *EditsDetailsUpdateCall) Header() http.Header { +func (c *EditsTestersUpdateCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *EditsDetailsUpdateCall) doRequest(alt string) (*http.Response, error) { +func (c *EditsTestersUpdateCall) doRequest(alt string) (*http.Response, error) { reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) - body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.appdetails) + body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.testers) if err != nil { return nil, err } c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/details") + urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/testers/{track}") urls += "?" + c.urlParams_.Encode() req, err := http.NewRequest("PUT", urls, body) if err != nil { @@ -11193,17 +14758,18 @@ func (c *EditsDetailsUpdateCall) doRequest(alt string) (*http.Response, error) { googleapi.Expand(req.URL, map[string]string{ "packageName": c.packageName, "editId": c.editId, + "track": c.track, }) - c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.edits.details.update", "request", internallog.HTTPRequest(req, body.Bytes())) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.edits.testers.update", "request", internallog.HTTPRequest(req, body.Bytes())) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "androidpublisher.edits.details.update" call. +// Do executes the "androidpublisher.edits.testers.update" call. // Any non-2xx status code is an error. Response headers are in either -// *AppDetails.ServerResponse.Header or (if a response was returned at all) in +// *Testers.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 *EditsDetailsUpdateCall) Do(opts ...googleapi.CallOption) (*AppDetails, error) { +func (c *EditsTestersUpdateCall) Do(opts ...googleapi.CallOption) (*Testers, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -11222,7 +14788,7 @@ func (c *EditsDetailsUpdateCall) Do(opts ...googleapi.CallOption) (*AppDetails, if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &AppDetails{ + ret := &Testers{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -11233,100 +14799,84 @@ func (c *EditsDetailsUpdateCall) Do(opts ...googleapi.CallOption) (*AppDetails, if err != nil { return nil, err } - c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.edits.details.update", "response", internallog.HTTPResponse(res, b)) + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.edits.testers.update", "response", internallog.HTTPResponse(res, b)) return ret, nil } -type EditsExpansionfilesGetCall struct { - s *Service - packageName string - editId string - apkVersionCode int64 - expansionFileType string - urlParams_ gensupport.URLParams - ifNoneMatch_ string - ctx_ context.Context - header_ http.Header +type EditsTracksCreateCall struct { + s *Service + packageName string + editId string + trackconfig *TrackConfig + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// Get: Fetches the expansion file configuration for the specified APK. +// Create: Creates a new track. // -// - apkVersionCode: The version code of the APK whose expansion file -// configuration is being read or modified. -// - editId: Identifier of the edit. -// - expansionFileType: The file type of the file configuration which is being -// read or modified. -// - packageName: Package name of the app. -func (r *EditsExpansionfilesService) Get(packageName string, editId string, apkVersionCode int64, expansionFileType string) *EditsExpansionfilesGetCall { - c := &EditsExpansionfilesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// - editId: Identifier of the edit. +// - packageName: Package name of the app. +func (r *EditsTracksService) Create(packageName string, editId string, trackconfig *TrackConfig) *EditsTracksCreateCall { + c := &EditsTracksCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.packageName = packageName c.editId = editId - c.apkVersionCode = apkVersionCode - c.expansionFileType = expansionFileType + c.trackconfig = trackconfig 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 *EditsExpansionfilesGetCall) Fields(s ...googleapi.Field) *EditsExpansionfilesGetCall { +func (c *EditsTracksCreateCall) Fields(s ...googleapi.Field) *EditsTracksCreateCall { 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 *EditsExpansionfilesGetCall) IfNoneMatch(entityTag string) *EditsExpansionfilesGetCall { - c.ifNoneMatch_ = entityTag - return c -} - // Context sets the context to be used in this call's Do method. -func (c *EditsExpansionfilesGetCall) Context(ctx context.Context) *EditsExpansionfilesGetCall { +func (c *EditsTracksCreateCall) Context(ctx context.Context) *EditsTracksCreateCall { 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 *EditsExpansionfilesGetCall) Header() http.Header { +func (c *EditsTracksCreateCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *EditsExpansionfilesGetCall) 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 *EditsTracksCreateCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) + body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.trackconfig) + if err != nil { + return nil, err } c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/apks/{apkVersionCode}/expansionFiles/{expansionFileType}") + urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/tracks") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("GET", urls, nil) + req, err := http.NewRequest("POST", urls, body) if err != nil { return nil, err } req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ - "packageName": c.packageName, - "editId": c.editId, - "apkVersionCode": strconv.FormatInt(c.apkVersionCode, 10), - "expansionFileType": c.expansionFileType, + "packageName": c.packageName, + "editId": c.editId, }) - c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.edits.expansionfiles.get", "request", internallog.HTTPRequest(req, nil)) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.edits.tracks.create", "request", internallog.HTTPRequest(req, body.Bytes())) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "androidpublisher.edits.expansionfiles.get" call. +// Do executes the "androidpublisher.edits.tracks.create" call. // Any non-2xx status code is an error. Response headers are in either -// *ExpansionFile.ServerResponse.Header or (if a response was returned at all) -// in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// *Track.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 *EditsExpansionfilesGetCall) Do(opts ...googleapi.CallOption) (*ExpansionFile, error) { +func (c *EditsTracksCreateCall) Do(opts ...googleapi.CallOption) (*Track, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -11345,7 +14895,7 @@ func (c *EditsExpansionfilesGetCall) Do(opts ...googleapi.CallOption) (*Expansio if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &ExpansionFile{ + ret := &Track{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -11356,95 +14906,95 @@ func (c *EditsExpansionfilesGetCall) Do(opts ...googleapi.CallOption) (*Expansio if err != nil { return nil, err } - c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.edits.expansionfiles.get", "response", internallog.HTTPResponse(res, b)) + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.edits.tracks.create", "response", internallog.HTTPResponse(res, b)) return ret, nil } -type EditsExpansionfilesPatchCall struct { - s *Service - packageName string - editId string - apkVersionCode int64 - expansionFileType string - expansionfile *ExpansionFile - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +type EditsTracksGetCall struct { + s *Service + packageName string + editId string + track string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header } -// Patch: Patches the APK's expansion file configuration to reference another -// APK's expansion file. To add a new expansion file use the Upload method. +// Get: Gets a track. // -// - apkVersionCode: The version code of the APK whose expansion file -// configuration is being read or modified. // - editId: Identifier of the edit. -// - expansionFileType: The file type of the expansion file configuration which -// is being updated. // - packageName: Package name of the app. -func (r *EditsExpansionfilesService) Patch(packageName string, editId string, apkVersionCode int64, expansionFileType string, expansionfile *ExpansionFile) *EditsExpansionfilesPatchCall { - c := &EditsExpansionfilesPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// - track: Identifier of the track. More on track name +// (https://developers.google.com/android-publisher/tracks#ff-track-name). +func (r *EditsTracksService) Get(packageName string, editId string, track string) *EditsTracksGetCall { + c := &EditsTracksGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.packageName = packageName c.editId = editId - c.apkVersionCode = apkVersionCode - c.expansionFileType = expansionFileType - c.expansionfile = expansionfile + c.track = track 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 *EditsExpansionfilesPatchCall) Fields(s ...googleapi.Field) *EditsExpansionfilesPatchCall { +func (c *EditsTracksGetCall) Fields(s ...googleapi.Field) *EditsTracksGetCall { 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 *EditsTracksGetCall) IfNoneMatch(entityTag string) *EditsTracksGetCall { + c.ifNoneMatch_ = entityTag + return c +} + // Context sets the context to be used in this call's Do method. -func (c *EditsExpansionfilesPatchCall) Context(ctx context.Context) *EditsExpansionfilesPatchCall { +func (c *EditsTracksGetCall) Context(ctx context.Context) *EditsTracksGetCall { 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 *EditsExpansionfilesPatchCall) Header() http.Header { +func (c *EditsTracksGetCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *EditsExpansionfilesPatchCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) - body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.expansionfile) - if err != nil { - return nil, err +func (c *EditsTracksGetCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) } c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/apks/{apkVersionCode}/expansionFiles/{expansionFileType}") + urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/tracks/{track}") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("PATCH", urls, body) + req, err := http.NewRequest("GET", urls, nil) if err != nil { return nil, err } req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ - "packageName": c.packageName, - "editId": c.editId, - "apkVersionCode": strconv.FormatInt(c.apkVersionCode, 10), - "expansionFileType": c.expansionFileType, + "packageName": c.packageName, + "editId": c.editId, + "track": c.track, }) - c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.edits.expansionfiles.patch", "request", internallog.HTTPRequest(req, body.Bytes())) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.edits.tracks.get", "request", internallog.HTTPRequest(req, nil)) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "androidpublisher.edits.expansionfiles.patch" call. +// Do executes the "androidpublisher.edits.tracks.get" call. // Any non-2xx status code is an error. Response headers are in either -// *ExpansionFile.ServerResponse.Header or (if a response was returned at all) -// in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// *Track.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 *EditsExpansionfilesPatchCall) Do(opts ...googleapi.CallOption) (*ExpansionFile, error) { +func (c *EditsTracksGetCall) Do(opts ...googleapi.CallOption) (*Track, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -11463,7 +15013,7 @@ func (c *EditsExpansionfilesPatchCall) Do(opts ...googleapi.CallOption) (*Expans if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &ExpansionFile{ + ret := &Track{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -11474,95 +15024,91 @@ func (c *EditsExpansionfilesPatchCall) Do(opts ...googleapi.CallOption) (*Expans if err != nil { return nil, err } - c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.edits.expansionfiles.patch", "response", internallog.HTTPResponse(res, b)) + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.edits.tracks.get", "response", internallog.HTTPResponse(res, b)) return ret, nil } -type EditsExpansionfilesUpdateCall struct { - s *Service - packageName string - editId string - apkVersionCode int64 - expansionFileType string - expansionfile *ExpansionFile - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +type EditsTracksListCall struct { + s *Service + packageName string + editId string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header } -// Update: Updates the APK's expansion file configuration to reference another -// APK's expansion file. To add a new expansion file use the Upload method. +// List: Lists all tracks. // -// - apkVersionCode: The version code of the APK whose expansion file -// configuration is being read or modified. -// - editId: Identifier of the edit. -// - expansionFileType: The file type of the file configuration which is being -// read or modified. -// - packageName: Package name of the app. -func (r *EditsExpansionfilesService) Update(packageName string, editId string, apkVersionCode int64, expansionFileType string, expansionfile *ExpansionFile) *EditsExpansionfilesUpdateCall { - c := &EditsExpansionfilesUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// - editId: Identifier of the edit. +// - packageName: Package name of the app. +func (r *EditsTracksService) List(packageName string, editId string) *EditsTracksListCall { + c := &EditsTracksListCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.packageName = packageName c.editId = editId - c.apkVersionCode = apkVersionCode - c.expansionFileType = expansionFileType - c.expansionfile = expansionfile 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 *EditsExpansionfilesUpdateCall) Fields(s ...googleapi.Field) *EditsExpansionfilesUpdateCall { +func (c *EditsTracksListCall) Fields(s ...googleapi.Field) *EditsTracksListCall { 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 *EditsTracksListCall) IfNoneMatch(entityTag string) *EditsTracksListCall { + c.ifNoneMatch_ = entityTag + return c +} + // Context sets the context to be used in this call's Do method. -func (c *EditsExpansionfilesUpdateCall) Context(ctx context.Context) *EditsExpansionfilesUpdateCall { +func (c *EditsTracksListCall) Context(ctx context.Context) *EditsTracksListCall { 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 *EditsExpansionfilesUpdateCall) Header() http.Header { +func (c *EditsTracksListCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *EditsExpansionfilesUpdateCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) - body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.expansionfile) - if err != nil { - return nil, err +func (c *EditsTracksListCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) } c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/apks/{apkVersionCode}/expansionFiles/{expansionFileType}") + urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/tracks") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("PUT", urls, body) + req, err := http.NewRequest("GET", urls, nil) if err != nil { return nil, err } req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ - "packageName": c.packageName, - "editId": c.editId, - "apkVersionCode": strconv.FormatInt(c.apkVersionCode, 10), - "expansionFileType": c.expansionFileType, + "packageName": c.packageName, + "editId": c.editId, }) - c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.edits.expansionfiles.update", "request", internallog.HTTPRequest(req, body.Bytes())) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.edits.tracks.list", "request", internallog.HTTPRequest(req, nil)) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "androidpublisher.edits.expansionfiles.update" call. +// Do executes the "androidpublisher.edits.tracks.list" call. // Any non-2xx status code is an error. Response headers are in either -// *ExpansionFile.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 *EditsExpansionfilesUpdateCall) Do(opts ...googleapi.CallOption) (*ExpansionFile, error) { +// *TracksListResponse.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 *EditsTracksListCall) Do(opts ...googleapi.CallOption) (*TracksListResponse, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -11581,7 +15127,7 @@ func (c *EditsExpansionfilesUpdateCall) Do(opts ...googleapi.CallOption) (*Expan if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &ExpansionFile{ + ret := &TracksListResponse{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -11592,135 +15138,89 @@ func (c *EditsExpansionfilesUpdateCall) Do(opts ...googleapi.CallOption) (*Expan if err != nil { return nil, err } - c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.edits.expansionfiles.update", "response", internallog.HTTPResponse(res, b)) + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.edits.tracks.list", "response", internallog.HTTPResponse(res, b)) return ret, nil } -type EditsExpansionfilesUploadCall struct { - s *Service - packageName string - editId string - apkVersionCode int64 - expansionFileType string - urlParams_ gensupport.URLParams - mediaInfo_ *gensupport.MediaInfo - ctx_ context.Context - header_ http.Header +type EditsTracksPatchCall struct { + s *Service + packageName string + editId string + track string + track2 *Track + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// Upload: Uploads a new expansion file and attaches to the specified APK. +// Patch: Patches a track. // -// - apkVersionCode: The version code of the APK whose expansion file -// configuration is being read or modified. // - editId: Identifier of the edit. -// - expansionFileType: The file type of the expansion file configuration which -// is being updated. // - packageName: Package name of the app. -func (r *EditsExpansionfilesService) Upload(packageName string, editId string, apkVersionCode int64, expansionFileType string) *EditsExpansionfilesUploadCall { - c := &EditsExpansionfilesUploadCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// - track: Identifier of the track. More on track name +// (https://developers.google.com/android-publisher/tracks#ff-track-name). +func (r *EditsTracksService) Patch(packageName string, editId string, track string, track2 *Track) *EditsTracksPatchCall { + c := &EditsTracksPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.packageName = packageName c.editId = editId - c.apkVersionCode = apkVersionCode - c.expansionFileType = expansionFileType - return c -} - -// Media specifies the media to upload in one or more chunks. The chunk size -// may be controlled by supplying a MediaOption generated by -// googleapi.ChunkSize. The chunk size defaults to -// googleapi.DefaultUploadChunkSize.The Content-Type header used in the upload -// request will be determined by sniffing the contents of r, unless a -// MediaOption generated by googleapi.ContentType is supplied. -// At most one of Media and ResumableMedia may be set. -func (c *EditsExpansionfilesUploadCall) Media(r io.Reader, options ...googleapi.MediaOption) *EditsExpansionfilesUploadCall { - c.mediaInfo_ = gensupport.NewInfoFromMedia(r, options) - return c -} - -// ResumableMedia specifies the media to upload in chunks and can be canceled -// with ctx. -// -// Deprecated: use Media instead. -// -// At most one of Media and ResumableMedia may be set. mediaType identifies the -// MIME media type of the upload, such as "image/png". If mediaType is "", it -// will be auto-detected. The provided ctx will supersede any context -// previously provided to the Context method. -func (c *EditsExpansionfilesUploadCall) ResumableMedia(ctx context.Context, r io.ReaderAt, size int64, mediaType string) *EditsExpansionfilesUploadCall { - c.ctx_ = ctx - c.mediaInfo_ = gensupport.NewInfoFromResumableMedia(r, size, mediaType) - return c -} - -// ProgressUpdater provides a callback function that will be called after every -// chunk. It should be a low-latency function in order to not slow down the -// upload operation. This should only be called when using ResumableMedia (as -// opposed to Media). -func (c *EditsExpansionfilesUploadCall) ProgressUpdater(pu googleapi.ProgressUpdater) *EditsExpansionfilesUploadCall { - c.mediaInfo_.SetProgressUpdater(pu) + c.track = track + c.track2 = track2 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 *EditsExpansionfilesUploadCall) Fields(s ...googleapi.Field) *EditsExpansionfilesUploadCall { +func (c *EditsTracksPatchCall) Fields(s ...googleapi.Field) *EditsTracksPatchCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } // Context sets the context to be used in this call's Do method. -// This context will supersede any context previously provided to the -// ResumableMedia method. -func (c *EditsExpansionfilesUploadCall) Context(ctx context.Context) *EditsExpansionfilesUploadCall { +func (c *EditsTracksPatchCall) Context(ctx context.Context) *EditsTracksPatchCall { 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 *EditsExpansionfilesUploadCall) Header() http.Header { +func (c *EditsTracksPatchCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *EditsExpansionfilesUploadCall) doRequest(alt string) (*http.Response, error) { +func (c *EditsTracksPatchCall) doRequest(alt string) (*http.Response, error) { reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) + body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.track2) + if err != nil { + return nil, err + } c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/apks/{apkVersionCode}/expansionFiles/{expansionFileType}") - if c.mediaInfo_ != nil { - urls = googleapi.ResolveRelative(c.s.BasePath, "/upload/androidpublisher/v3/applications/{packageName}/edits/{editId}/apks/{apkVersionCode}/expansionFiles/{expansionFileType}") - c.urlParams_.Set("uploadType", c.mediaInfo_.UploadType()) - } - newBody, getBody, cleanup := c.mediaInfo_.UploadRequest(reqHeaders, nil) - defer cleanup() + urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/tracks/{track}") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("POST", urls, newBody) + req, err := http.NewRequest("PATCH", urls, body) if err != nil { return nil, err } req.Header = reqHeaders - req.GetBody = getBody googleapi.Expand(req.URL, map[string]string{ - "packageName": c.packageName, - "editId": c.editId, - "apkVersionCode": strconv.FormatInt(c.apkVersionCode, 10), - "expansionFileType": c.expansionFileType, + "packageName": c.packageName, + "editId": c.editId, + "track": c.track, }) - c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.edits.expansionfiles.upload", "request", internallog.HTTPRequest(req, nil)) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.edits.tracks.patch", "request", internallog.HTTPRequest(req, body.Bytes())) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "androidpublisher.edits.expansionfiles.upload" call. +// Do executes the "androidpublisher.edits.tracks.patch" call. // Any non-2xx status code is an error. Response headers are in either -// *ExpansionFilesUploadResponse.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 *EditsExpansionfilesUploadCall) Do(opts ...googleapi.CallOption) (*ExpansionFilesUploadResponse, error) { +// *Track.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 *EditsTracksPatchCall) Do(opts ...googleapi.CallOption) (*Track, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -11739,24 +15239,7 @@ func (c *EditsExpansionfilesUploadCall) Do(opts ...googleapi.CallOption) (*Expan if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - rx := c.mediaInfo_.ResumableUpload(res.Header.Get("Location")) - if rx != nil { - rx.Client = c.s.client - rx.UserAgent = c.s.userAgent() - ctx := c.ctx_ - if ctx == nil { - ctx = context.TODO() - } - res, err = rx.Upload(ctx) - if err != nil { - return nil, err - } - defer res.Body.Close() - if err := googleapi.CheckResponse(res); err != nil { - return nil, gensupport.WrapError(err) - } - } - ret := &ExpansionFilesUploadResponse{ + ret := &Track{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -11767,71 +15250,70 @@ func (c *EditsExpansionfilesUploadCall) Do(opts ...googleapi.CallOption) (*Expan if err != nil { return nil, err } - c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.edits.expansionfiles.upload", "response", internallog.HTTPResponse(res, b)) + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.edits.tracks.patch", "response", internallog.HTTPResponse(res, b)) return ret, nil } -type EditsImagesDeleteCall struct { +type EditsTracksUpdateCall struct { s *Service packageName string editId string - language string - imageType string - imageId string + track string + track2 *Track urlParams_ gensupport.URLParams ctx_ context.Context header_ http.Header } -// Delete: Deletes the image (specified by id) from the edit. +// Update: Updates a track. // // - editId: Identifier of the edit. -// - imageId: Unique identifier an image within the set of images attached to -// this edit. -// - imageType: Type of the Image. -// - language: Language localization code (a BCP-47 language tag; for example, -// "de-AT" for Austrian German). // - packageName: Package name of the app. -func (r *EditsImagesService) Delete(packageName string, editId string, language string, imageType string, imageId string) *EditsImagesDeleteCall { - c := &EditsImagesDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// - track: Identifier of the track. More on track name +// (https://developers.google.com/android-publisher/tracks#ff-track-name). +func (r *EditsTracksService) Update(packageName string, editId string, track string, track2 *Track) *EditsTracksUpdateCall { + c := &EditsTracksUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.packageName = packageName c.editId = editId - c.language = language - c.imageType = imageType - c.imageId = imageId + c.track = track + c.track2 = track2 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 *EditsImagesDeleteCall) Fields(s ...googleapi.Field) *EditsImagesDeleteCall { +func (c *EditsTracksUpdateCall) Fields(s ...googleapi.Field) *EditsTracksUpdateCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } // Context sets the context to be used in this call's Do method. -func (c *EditsImagesDeleteCall) Context(ctx context.Context) *EditsImagesDeleteCall { +func (c *EditsTracksUpdateCall) Context(ctx context.Context) *EditsTracksUpdateCall { 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 *EditsImagesDeleteCall) Header() http.Header { +func (c *EditsTracksUpdateCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *EditsImagesDeleteCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) +func (c *EditsTracksUpdateCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) + body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.track2) + if err != nil { + return nil, err + } c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/listings/{language}/{imageType}/{imageId}") + urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/tracks/{track}") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("DELETE", urls, nil) + req, err := http.NewRequest("PUT", urls, body) if err != nil { return nil, err } @@ -11839,110 +15321,134 @@ func (c *EditsImagesDeleteCall) doRequest(alt string) (*http.Response, error) { googleapi.Expand(req.URL, map[string]string{ "packageName": c.packageName, "editId": c.editId, - "language": c.language, - "imageType": c.imageType, - "imageId": c.imageId, + "track": c.track, }) - c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.edits.images.delete", "request", internallog.HTTPRequest(req, nil)) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.edits.tracks.update", "request", internallog.HTTPRequest(req, body.Bytes())) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "androidpublisher.edits.images.delete" call. -func (c *EditsImagesDeleteCall) Do(opts ...googleapi.CallOption) error { +// Do executes the "androidpublisher.edits.tracks.update" call. +// Any non-2xx status code is an error. Response headers are in either +// *Track.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 *EditsTracksUpdateCall) Do(opts ...googleapi.CallOption) (*Track, 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 err + return nil, err } defer googleapi.CloseBody(res) if err := googleapi.CheckResponse(res); err != nil { - return gensupport.WrapError(err) + return nil, gensupport.WrapError(err) + } + ret := &Track{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + b, err := gensupport.DecodeResponseBytes(target, res) + if err != nil { + return nil, err } - c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.edits.images.delete", "response", internallog.HTTPResponse(res, nil)) - return nil + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.edits.tracks.update", "response", internallog.HTTPResponse(res, b)) + return ret, nil } -type EditsImagesDeleteallCall struct { - s *Service - packageName string - editId string - language string - imageType string - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +type ExternaltransactionsCreateexternaltransactionCall struct { + s *Service + parent string + externaltransaction *ExternalTransaction + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// Deleteall: Deletes all images for the specified language and image type. -// Returns an empty response if no images are found. +// Createexternaltransaction: Creates a new external transaction. // -// - editId: Identifier of the edit. -// - imageType: Type of the Image. Providing an image type that refers to no -// images is a no-op. -// - language: Language localization code (a BCP-47 language tag; for example, -// "de-AT" for Austrian German). Providing a language that is not supported -// by the App is a no-op. -// - packageName: Package name of the app. -func (r *EditsImagesService) Deleteall(packageName string, editId string, language string, imageType string) *EditsImagesDeleteallCall { - c := &EditsImagesDeleteallCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.packageName = packageName - c.editId = editId - c.language = language - c.imageType = imageType +// - parent: The parent resource where this external transaction will be +// created. Format: applications/{package_name}. +func (r *ExternaltransactionsService) Createexternaltransaction(parent string, externaltransaction *ExternalTransaction) *ExternaltransactionsCreateexternaltransactionCall { + c := &ExternaltransactionsCreateexternaltransactionCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + c.externaltransaction = externaltransaction + return c +} + +// ExternalTransactionId sets the optional parameter "externalTransactionId": +// Required. The id to use for the external transaction. Must be unique across +// all other transactions for the app. This value should be 1-63 characters and +// valid characters are /a-zA-Z0-9_-/. Do not use this field to store any +// Personally Identifiable Information (PII) such as emails. Attempting to +// store PII in this field may result in requests being blocked. +func (c *ExternaltransactionsCreateexternaltransactionCall) ExternalTransactionId(externalTransactionId string) *ExternaltransactionsCreateexternaltransactionCall { + c.urlParams_.Set("externalTransactionId", externalTransactionId) 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 *EditsImagesDeleteallCall) Fields(s ...googleapi.Field) *EditsImagesDeleteallCall { +func (c *ExternaltransactionsCreateexternaltransactionCall) Fields(s ...googleapi.Field) *ExternaltransactionsCreateexternaltransactionCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } // Context sets the context to be used in this call's Do method. -func (c *EditsImagesDeleteallCall) Context(ctx context.Context) *EditsImagesDeleteallCall { +func (c *ExternaltransactionsCreateexternaltransactionCall) Context(ctx context.Context) *ExternaltransactionsCreateexternaltransactionCall { 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 *EditsImagesDeleteallCall) Header() http.Header { +func (c *ExternaltransactionsCreateexternaltransactionCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *EditsImagesDeleteallCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) +func (c *ExternaltransactionsCreateexternaltransactionCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) + body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.externaltransaction) + if err != nil { + return nil, err + } c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/listings/{language}/{imageType}") + urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/{+parent}/externalTransactions") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("DELETE", urls, nil) + req, err := http.NewRequest("POST", urls, body) if err != nil { return nil, err } req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ - "packageName": c.packageName, - "editId": c.editId, - "language": c.language, - "imageType": c.imageType, + "parent": c.parent, }) - c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.edits.images.deleteall", "request", internallog.HTTPRequest(req, nil)) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.externaltransactions.createexternaltransaction", "request", internallog.HTTPRequest(req, body.Bytes())) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "androidpublisher.edits.images.deleteall" call. +// Do executes the "androidpublisher.externaltransactions.createexternaltransaction" call. // Any non-2xx status code is an error. Response headers are in either -// *ImagesDeleteAllResponse.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 *EditsImagesDeleteallCall) Do(opts ...googleapi.CallOption) (*ImagesDeleteAllResponse, error) { +// *ExternalTransaction.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 *ExternaltransactionsCreateexternaltransactionCall) Do(opts ...googleapi.CallOption) (*ExternalTransaction, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -11961,7 +15467,7 @@ func (c *EditsImagesDeleteallCall) Do(opts ...googleapi.CallOption) (*ImagesDele if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &ImagesDeleteAllResponse{ + ret := &ExternalTransaction{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -11972,44 +15478,33 @@ func (c *EditsImagesDeleteallCall) Do(opts ...googleapi.CallOption) (*ImagesDele if err != nil { return nil, err } - c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.edits.images.deleteall", "response", internallog.HTTPResponse(res, b)) + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.externaltransactions.createexternaltransaction", "response", internallog.HTTPResponse(res, b)) return ret, nil } -type EditsImagesListCall struct { +type ExternaltransactionsGetexternaltransactionCall struct { s *Service - packageName string - editId string - language string - imageType string + name string urlParams_ gensupport.URLParams ifNoneMatch_ string ctx_ context.Context header_ http.Header } -// List: Lists all images. The response may be empty. +// Getexternaltransaction: Gets an existing external transaction. // -// - editId: Identifier of the edit. -// - imageType: Type of the Image. Providing an image type that refers to no -// images will return an empty response. -// - language: Language localization code (a BCP-47 language tag; for example, -// "de-AT" for Austrian German). There must be a store listing for the -// specified language. -// - packageName: Package name of the app. -func (r *EditsImagesService) List(packageName string, editId string, language string, imageType string) *EditsImagesListCall { - c := &EditsImagesListCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.packageName = packageName - c.editId = editId - c.language = language - c.imageType = imageType +// - name: The name of the external transaction to retrieve. Format: +// applications/{package_name}/externalTransactions/{external_transaction}. +func (r *ExternaltransactionsService) Getexternaltransaction(name string) *ExternaltransactionsGetexternaltransactionCall { + c := &ExternaltransactionsGetexternaltransactionCall{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 *EditsImagesListCall) Fields(s ...googleapi.Field) *EditsImagesListCall { +func (c *ExternaltransactionsGetexternaltransactionCall) Fields(s ...googleapi.Field) *ExternaltransactionsGetexternaltransactionCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } @@ -12017,34 +15512,34 @@ func (c *EditsImagesListCall) Fields(s ...googleapi.Field) *EditsImagesListCall // 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 *EditsImagesListCall) IfNoneMatch(entityTag string) *EditsImagesListCall { +func (c *ExternaltransactionsGetexternaltransactionCall) IfNoneMatch(entityTag string) *ExternaltransactionsGetexternaltransactionCall { c.ifNoneMatch_ = entityTag return c } // Context sets the context to be used in this call's Do method. -func (c *EditsImagesListCall) Context(ctx context.Context) *EditsImagesListCall { +func (c *ExternaltransactionsGetexternaltransactionCall) Context(ctx context.Context) *ExternaltransactionsGetexternaltransactionCall { 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 *EditsImagesListCall) Header() http.Header { +func (c *ExternaltransactionsGetexternaltransactionCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *EditsImagesListCall) doRequest(alt string) (*http.Response, error) { +func (c *ExternaltransactionsGetexternaltransactionCall) doRequest(alt string) (*http.Response, error) { reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) if c.ifNoneMatch_ != "" { reqHeaders.Set("If-None-Match", c.ifNoneMatch_) } c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/listings/{language}/{imageType}") + urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/{+name}") urls += "?" + c.urlParams_.Encode() req, err := http.NewRequest("GET", urls, nil) if err != nil { @@ -12052,22 +15547,19 @@ func (c *EditsImagesListCall) doRequest(alt string) (*http.Response, error) { } req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ - "packageName": c.packageName, - "editId": c.editId, - "language": c.language, - "imageType": c.imageType, + "name": c.name, }) - c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.edits.images.list", "request", internallog.HTTPRequest(req, nil)) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.externaltransactions.getexternaltransaction", "request", internallog.HTTPRequest(req, nil)) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "androidpublisher.edits.images.list" call. +// Do executes the "androidpublisher.externaltransactions.getexternaltransaction" call. // Any non-2xx status code is an error. Response headers are in either -// *ImagesListResponse.ServerResponse.Header or (if a response was returned at +// *ExternalTransaction.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 *EditsImagesListCall) Do(opts ...googleapi.CallOption) (*ImagesListResponse, error) { +func (c *ExternaltransactionsGetexternaltransactionCall) Do(opts ...googleapi.CallOption) (*ExternalTransaction, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -12086,7 +15578,7 @@ func (c *EditsImagesListCall) Do(opts ...googleapi.CallOption) (*ImagesListRespo if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &ImagesListResponse{ + ret := &ExternalTransaction{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -12097,136 +15589,83 @@ func (c *EditsImagesListCall) Do(opts ...googleapi.CallOption) (*ImagesListRespo if err != nil { return nil, err } - c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.edits.images.list", "response", internallog.HTTPResponse(res, b)) + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.externaltransactions.getexternaltransaction", "response", internallog.HTTPResponse(res, b)) return ret, nil } -type EditsImagesUploadCall struct { - s *Service - packageName string - editId string - language string - imageType string - urlParams_ gensupport.URLParams - mediaInfo_ *gensupport.MediaInfo - ctx_ context.Context - header_ http.Header -} - -// Upload: Uploads an image of the specified language and image type, and adds -// to the edit. -// -// - editId: Identifier of the edit. -// - imageType: Type of the Image. -// - language: Language localization code (a BCP-47 language tag; for example, -// "de-AT" for Austrian German). Providing a language that is not supported -// by the App is a no-op. -// - packageName: Package name of the app. -func (r *EditsImagesService) Upload(packageName string, editId string, language string, imageType string) *EditsImagesUploadCall { - c := &EditsImagesUploadCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.packageName = packageName - c.editId = editId - c.language = language - c.imageType = imageType - return c -} - -// Media specifies the media to upload in one or more chunks. The chunk size -// may be controlled by supplying a MediaOption generated by -// googleapi.ChunkSize. The chunk size defaults to -// googleapi.DefaultUploadChunkSize.The Content-Type header used in the upload -// request will be determined by sniffing the contents of r, unless a -// MediaOption generated by googleapi.ContentType is supplied. -// At most one of Media and ResumableMedia may be set. -func (c *EditsImagesUploadCall) Media(r io.Reader, options ...googleapi.MediaOption) *EditsImagesUploadCall { - c.mediaInfo_ = gensupport.NewInfoFromMedia(r, options) - return c +type ExternaltransactionsRefundexternaltransactionCall struct { + s *Service + name string + refundexternaltransactionrequest *RefundExternalTransactionRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// ResumableMedia specifies the media to upload in chunks and can be canceled -// with ctx. -// -// Deprecated: use Media instead. +// Refundexternaltransaction: Refunds or partially refunds an existing external +// transaction. // -// At most one of Media and ResumableMedia may be set. mediaType identifies the -// MIME media type of the upload, such as "image/png". If mediaType is "", it -// will be auto-detected. The provided ctx will supersede any context -// previously provided to the Context method. -func (c *EditsImagesUploadCall) ResumableMedia(ctx context.Context, r io.ReaderAt, size int64, mediaType string) *EditsImagesUploadCall { - c.ctx_ = ctx - c.mediaInfo_ = gensupport.NewInfoFromResumableMedia(r, size, mediaType) - return c -} - -// ProgressUpdater provides a callback function that will be called after every -// chunk. It should be a low-latency function in order to not slow down the -// upload operation. This should only be called when using ResumableMedia (as -// opposed to Media). -func (c *EditsImagesUploadCall) ProgressUpdater(pu googleapi.ProgressUpdater) *EditsImagesUploadCall { - c.mediaInfo_.SetProgressUpdater(pu) +// - name: The name of the external transaction that will be refunded. Format: +// applications/{package_name}/externalTransactions/{external_transaction}. +func (r *ExternaltransactionsService) Refundexternaltransaction(name string, refundexternaltransactionrequest *RefundExternalTransactionRequest) *ExternaltransactionsRefundexternaltransactionCall { + c := &ExternaltransactionsRefundexternaltransactionCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + c.refundexternaltransactionrequest = refundexternaltransactionrequest 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 *EditsImagesUploadCall) Fields(s ...googleapi.Field) *EditsImagesUploadCall { +func (c *ExternaltransactionsRefundexternaltransactionCall) Fields(s ...googleapi.Field) *ExternaltransactionsRefundexternaltransactionCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } // Context sets the context to be used in this call's Do method. -// This context will supersede any context previously provided to the -// ResumableMedia method. -func (c *EditsImagesUploadCall) Context(ctx context.Context) *EditsImagesUploadCall { +func (c *ExternaltransactionsRefundexternaltransactionCall) Context(ctx context.Context) *ExternaltransactionsRefundexternaltransactionCall { 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 *EditsImagesUploadCall) Header() http.Header { +func (c *ExternaltransactionsRefundexternaltransactionCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *EditsImagesUploadCall) doRequest(alt string) (*http.Response, error) { +func (c *ExternaltransactionsRefundexternaltransactionCall) doRequest(alt string) (*http.Response, error) { reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) + body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.refundexternaltransactionrequest) + if err != nil { + return nil, err + } c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/listings/{language}/{imageType}") - if c.mediaInfo_ != nil { - urls = googleapi.ResolveRelative(c.s.BasePath, "/upload/androidpublisher/v3/applications/{packageName}/edits/{editId}/listings/{language}/{imageType}") - c.urlParams_.Set("uploadType", c.mediaInfo_.UploadType()) - } - newBody, getBody, cleanup := c.mediaInfo_.UploadRequest(reqHeaders, nil) - defer cleanup() + urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/{+name}:refund") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("POST", urls, newBody) + req, err := http.NewRequest("POST", urls, body) if err != nil { return nil, err } - req.Header = reqHeaders - req.GetBody = getBody - googleapi.Expand(req.URL, map[string]string{ - "packageName": c.packageName, - "editId": c.editId, - "language": c.language, - "imageType": c.imageType, + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "name": c.name, }) - c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.edits.images.upload", "request", internallog.HTTPRequest(req, nil)) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.externaltransactions.refundexternaltransaction", "request", internallog.HTTPRequest(req, body.Bytes())) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "androidpublisher.edits.images.upload" call. +// Do executes the "androidpublisher.externaltransactions.refundexternaltransaction" call. // Any non-2xx status code is an error. Response headers are in either -// *ImagesUploadResponse.ServerResponse.Header or (if a response was returned -// at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to +// *ExternalTransaction.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 *EditsImagesUploadCall) Do(opts ...googleapi.CallOption) (*ImagesUploadResponse, error) { +func (c *ExternaltransactionsRefundexternaltransactionCall) Do(opts ...googleapi.CallOption) (*ExternalTransaction, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -12245,24 +15684,7 @@ func (c *EditsImagesUploadCall) Do(opts ...googleapi.CallOption) (*ImagesUploadR if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - rx := c.mediaInfo_.ResumableUpload(res.Header.Get("Location")) - if rx != nil { - rx.Client = c.s.client - rx.UserAgent = c.s.userAgent() - ctx := c.ctx_ - if ctx == nil { - ctx = context.TODO() - } - res, err = rx.Upload(ctx) - if err != nil { - return nil, err - } - defer res.Body.Close() - if err := googleapi.CheckResponse(res); err != nil { - return nil, gensupport.WrapError(err) - } - } - ret := &ImagesUploadResponse{ + ret := &ExternalTransaction{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -12273,79 +15695,107 @@ func (c *EditsImagesUploadCall) Do(opts ...googleapi.CallOption) (*ImagesUploadR if err != nil { return nil, err } - c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.edits.images.upload", "response", internallog.HTTPResponse(res, b)) + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.externaltransactions.refundexternaltransaction", "response", internallog.HTTPResponse(res, b)) return ret, nil } -type EditsListingsDeleteCall struct { - s *Service - packageName string - editId string - language string - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +type GeneratedapksDownloadCall struct { + s *Service + packageName string + versionCode int64 + downloadId string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header } -// Delete: Deletes a localized store listing. +// Download: Downloads a single signed APK generated from an app bundle. // -// - editId: Identifier of the edit. -// - language: Language localization code (a BCP-47 language tag; for example, -// "de-AT" for Austrian German). +// - downloadId: Download ID, which uniquely identifies the APK to download. +// Can be obtained from the response of `generatedapks.list` method. // - packageName: Package name of the app. -func (r *EditsListingsService) Delete(packageName string, editId string, language string) *EditsListingsDeleteCall { - c := &EditsListingsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// - versionCode: Version code of the app bundle. +func (r *GeneratedapksService) Download(packageName string, versionCode int64, downloadId string) *GeneratedapksDownloadCall { + c := &GeneratedapksDownloadCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.packageName = packageName - c.editId = editId - c.language = language + c.versionCode = versionCode + c.downloadId = downloadId 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 *EditsListingsDeleteCall) Fields(s ...googleapi.Field) *EditsListingsDeleteCall { +func (c *GeneratedapksDownloadCall) Fields(s ...googleapi.Field) *GeneratedapksDownloadCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. -func (c *EditsListingsDeleteCall) Context(ctx context.Context) *EditsListingsDeleteCall { +// 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 *GeneratedapksDownloadCall) IfNoneMatch(entityTag string) *GeneratedapksDownloadCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do and Download methods. +func (c *GeneratedapksDownloadCall) Context(ctx context.Context) *GeneratedapksDownloadCall { 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 *EditsListingsDeleteCall) Header() http.Header { +func (c *GeneratedapksDownloadCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *EditsListingsDeleteCall) doRequest(alt string) (*http.Response, error) { +func (c *GeneratedapksDownloadCall) doRequest(alt string) (*http.Response, error) { reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) + } c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/listings/{language}") + urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/generatedApks/{versionCode}/downloads/{downloadId}:download") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("DELETE", urls, nil) + req, err := http.NewRequest("GET", urls, nil) if err != nil { return nil, err } req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ "packageName": c.packageName, - "editId": c.editId, - "language": c.language, + "versionCode": strconv.FormatInt(c.versionCode, 10), + "downloadId": c.downloadId, }) - c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.edits.listings.delete", "request", internallog.HTTPRequest(req, nil)) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.generatedapks.download", "request", internallog.HTTPRequest(req, nil)) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "androidpublisher.edits.listings.delete" call. -func (c *EditsListingsDeleteCall) Do(opts ...googleapi.CallOption) error { +// Download fetches the API endpoint's "media" value, instead of the normal +// API response value. If the returned error is nil, the Response is guaranteed to +// have a 2xx status code. Callers must close the Response.Body as usual. +func (c *GeneratedapksDownloadCall) Download(opts ...googleapi.CallOption) (*http.Response, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("media") + if err != nil { + return nil, err + } + if err := googleapi.CheckResponse(res); err != nil { + res.Body.Close() + return nil, gensupport.WrapError(err) + } + return res, nil +} + +// Do executes the "androidpublisher.generatedapks.download" call. +func (c *GeneratedapksDownloadCall) Do(opts ...googleapi.CallOption) error { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if err != nil { @@ -12355,172 +15805,196 @@ func (c *EditsListingsDeleteCall) Do(opts ...googleapi.CallOption) error { if err := googleapi.CheckResponse(res); err != nil { return gensupport.WrapError(err) } - c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.edits.listings.delete", "response", internallog.HTTPResponse(res, nil)) + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.generatedapks.download", "response", internallog.HTTPResponse(res, nil)) return nil } -type EditsListingsDeleteallCall struct { - s *Service - packageName string - editId string - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +type GeneratedapksListCall struct { + s *Service + packageName string + versionCode int64 + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header } -// Deleteall: Deletes all store listings. +// List: Returns download metadata for all APKs that were generated from a +// given app bundle. // -// - editId: Identifier of the edit. // - packageName: Package name of the app. -func (r *EditsListingsService) Deleteall(packageName string, editId string) *EditsListingsDeleteallCall { - c := &EditsListingsDeleteallCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// - versionCode: Version code of the app bundle. +func (r *GeneratedapksService) List(packageName string, versionCode int64) *GeneratedapksListCall { + c := &GeneratedapksListCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.packageName = packageName - c.editId = editId + c.versionCode = versionCode 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 *EditsListingsDeleteallCall) Fields(s ...googleapi.Field) *EditsListingsDeleteallCall { +func (c *GeneratedapksListCall) Fields(s ...googleapi.Field) *GeneratedapksListCall { 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 *GeneratedapksListCall) IfNoneMatch(entityTag string) *GeneratedapksListCall { + c.ifNoneMatch_ = entityTag + return c +} + // Context sets the context to be used in this call's Do method. -func (c *EditsListingsDeleteallCall) Context(ctx context.Context) *EditsListingsDeleteallCall { +func (c *GeneratedapksListCall) Context(ctx context.Context) *GeneratedapksListCall { 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 *EditsListingsDeleteallCall) Header() http.Header { +func (c *GeneratedapksListCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *EditsListingsDeleteallCall) doRequest(alt string) (*http.Response, error) { +func (c *GeneratedapksListCall) doRequest(alt string) (*http.Response, error) { reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) + } c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/listings") + urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/generatedApks/{versionCode}") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("DELETE", urls, nil) + req, err := http.NewRequest("GET", urls, nil) if err != nil { return nil, err } req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ "packageName": c.packageName, - "editId": c.editId, + "versionCode": strconv.FormatInt(c.versionCode, 10), }) - c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.edits.listings.deleteall", "request", internallog.HTTPRequest(req, nil)) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.generatedapks.list", "request", internallog.HTTPRequest(req, nil)) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "androidpublisher.edits.listings.deleteall" call. -func (c *EditsListingsDeleteallCall) Do(opts ...googleapi.CallOption) error { +// Do executes the "androidpublisher.generatedapks.list" call. +// Any non-2xx status code is an error. Response headers are in either +// *GeneratedApksListResponse.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 *GeneratedapksListCall) Do(opts ...googleapi.CallOption) (*GeneratedApksListResponse, 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 err + return nil, err } defer googleapi.CloseBody(res) if err := googleapi.CheckResponse(res); err != nil { - return gensupport.WrapError(err) + return nil, gensupport.WrapError(err) } - c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.edits.listings.deleteall", "response", internallog.HTTPResponse(res, nil)) - return nil + ret := &GeneratedApksListResponse{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + b, err := gensupport.DecodeResponseBytes(target, res) + if err != nil { + return nil, err + } + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.generatedapks.list", "response", internallog.HTTPResponse(res, b)) + return ret, nil } -type EditsListingsGetCall struct { - s *Service - packageName string - editId string - language string - urlParams_ gensupport.URLParams - ifNoneMatch_ string - ctx_ context.Context - header_ http.Header +type GrantsCreateCall struct { + s *Service + parent string + grant *Grant + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// Get: Gets a localized store listing. +// Create: Grant access for a user to the given package. // -// - editId: Identifier of the edit. -// - language: Language localization code (a BCP-47 language tag; for example, -// "de-AT" for Austrian German). -// - packageName: Package name of the app. -func (r *EditsListingsService) Get(packageName string, editId string, language string) *EditsListingsGetCall { - c := &EditsListingsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.packageName = packageName - c.editId = editId - c.language = language +// - parent: The user which needs permission. Format: +// developers/{developer}/users/{user}. +func (r *GrantsService) Create(parent string, grant *Grant) *GrantsCreateCall { + c := &GrantsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + c.grant = grant 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 *EditsListingsGetCall) Fields(s ...googleapi.Field) *EditsListingsGetCall { +func (c *GrantsCreateCall) Fields(s ...googleapi.Field) *GrantsCreateCall { 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 *EditsListingsGetCall) IfNoneMatch(entityTag string) *EditsListingsGetCall { - c.ifNoneMatch_ = entityTag - return c -} - // Context sets the context to be used in this call's Do method. -func (c *EditsListingsGetCall) Context(ctx context.Context) *EditsListingsGetCall { +func (c *GrantsCreateCall) Context(ctx context.Context) *GrantsCreateCall { 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 *EditsListingsGetCall) Header() http.Header { +func (c *GrantsCreateCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *EditsListingsGetCall) 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 *GrantsCreateCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) + body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.grant) + if err != nil { + return nil, err } c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/listings/{language}") + urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/{+parent}/grants") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("GET", urls, nil) + req, err := http.NewRequest("POST", urls, body) if err != nil { return nil, err } req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ - "packageName": c.packageName, - "editId": c.editId, - "language": c.language, + "parent": c.parent, }) - c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.edits.listings.get", "request", internallog.HTTPRequest(req, nil)) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.grants.create", "request", internallog.HTTPRequest(req, body.Bytes())) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "androidpublisher.edits.listings.get" call. +// Do executes the "androidpublisher.grants.create" call. // Any non-2xx status code is an error. Response headers are in either -// *Listing.ServerResponse.Header or (if a response was returned at all) in +// *Grant.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 *EditsListingsGetCall) Do(opts ...googleapi.CallOption) (*Listing, error) { +func (c *GrantsCreateCall) Do(opts ...googleapi.CallOption) (*Grant, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -12539,7 +16013,7 @@ func (c *EditsListingsGetCall) Do(opts ...googleapi.CallOption) (*Listing, error if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &Listing{ + ret := &Grant{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -12550,182 +16024,146 @@ func (c *EditsListingsGetCall) Do(opts ...googleapi.CallOption) (*Listing, error if err != nil { return nil, err } - c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.edits.listings.get", "response", internallog.HTTPResponse(res, b)) + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.grants.create", "response", internallog.HTTPResponse(res, b)) return ret, nil } -type EditsListingsListCall struct { - s *Service - packageName string - editId string - urlParams_ gensupport.URLParams - ifNoneMatch_ string - ctx_ context.Context - header_ http.Header +type GrantsDeleteCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// List: Lists all localized store listings. +// Delete: Removes all access for the user to the given package or developer +// account. // -// - editId: Identifier of the edit. -// - packageName: Package name of the app. -func (r *EditsListingsService) List(packageName string, editId string) *EditsListingsListCall { - c := &EditsListingsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.packageName = packageName - c.editId = editId +// - name: The name of the grant to delete. Format: +// developers/{developer}/users/{email}/grants/{package_name}. +func (r *GrantsService) Delete(name string) *GrantsDeleteCall { + c := &GrantsDeleteCall{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 *EditsListingsListCall) Fields(s ...googleapi.Field) *EditsListingsListCall { +func (c *GrantsDeleteCall) Fields(s ...googleapi.Field) *GrantsDeleteCall { 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 *EditsListingsListCall) IfNoneMatch(entityTag string) *EditsListingsListCall { - c.ifNoneMatch_ = entityTag - return c -} - // Context sets the context to be used in this call's Do method. -func (c *EditsListingsListCall) Context(ctx context.Context) *EditsListingsListCall { +func (c *GrantsDeleteCall) Context(ctx context.Context) *GrantsDeleteCall { 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 *EditsListingsListCall) Header() http.Header { +func (c *GrantsDeleteCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *EditsListingsListCall) doRequest(alt string) (*http.Response, error) { +func (c *GrantsDeleteCall) doRequest(alt string) (*http.Response, error) { reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) - if c.ifNoneMatch_ != "" { - reqHeaders.Set("If-None-Match", c.ifNoneMatch_) - } c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/listings") + urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/{+name}") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("GET", urls, nil) + req, err := http.NewRequest("DELETE", urls, nil) if err != nil { return nil, err } req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ - "packageName": c.packageName, - "editId": c.editId, + "name": c.name, }) - c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.edits.listings.list", "request", internallog.HTTPRequest(req, nil)) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.grants.delete", "request", internallog.HTTPRequest(req, nil)) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "androidpublisher.edits.listings.list" call. -// Any non-2xx status code is an error. Response headers are in either -// *ListingsListResponse.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 *EditsListingsListCall) Do(opts ...googleapi.CallOption) (*ListingsListResponse, error) { +// Do executes the "androidpublisher.grants.delete" call. +func (c *GrantsDeleteCall) Do(opts ...googleapi.CallOption) 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 + return err } defer googleapi.CloseBody(res) if err := googleapi.CheckResponse(res); err != nil { - return nil, gensupport.WrapError(err) - } - ret := &ListingsListResponse{ - ServerResponse: googleapi.ServerResponse{ - Header: res.Header, - HTTPStatusCode: res.StatusCode, - }, - } - target := &ret - b, err := gensupport.DecodeResponseBytes(target, res) - if err != nil { - return nil, err + return gensupport.WrapError(err) } - c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.edits.listings.list", "response", internallog.HTTPResponse(res, b)) - return ret, nil + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.grants.delete", "response", internallog.HTTPResponse(res, nil)) + return nil } -type EditsListingsPatchCall struct { - s *Service - packageName string - editId string - language string - listing *Listing - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +type GrantsPatchCall struct { + s *Service + name string + grant *Grant + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// Patch: Patches a localized store listing. +// Patch: Updates access for the user to the given package. // -// - editId: Identifier of the edit. -// - language: Language localization code (a BCP-47 language tag; for example, -// "de-AT" for Austrian German). -// - packageName: Package name of the app. -func (r *EditsListingsService) Patch(packageName string, editId string, language string, listing *Listing) *EditsListingsPatchCall { - c := &EditsListingsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.packageName = packageName - c.editId = editId - c.language = language - c.listing = listing +// - name: Resource name for this grant, following the pattern +// "developers/{developer}/users/{email}/grants/{package_name}". If this +// grant is for a draft app, the app ID will be used in this resource name +// instead of the package name. +func (r *GrantsService) Patch(name string, grant *Grant) *GrantsPatchCall { + c := &GrantsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + c.grant = grant + return c +} + +// UpdateMask sets the optional parameter "updateMask": The list of fields to +// be updated. +func (c *GrantsPatchCall) UpdateMask(updateMask string) *GrantsPatchCall { + 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 *EditsListingsPatchCall) Fields(s ...googleapi.Field) *EditsListingsPatchCall { +func (c *GrantsPatchCall) Fields(s ...googleapi.Field) *GrantsPatchCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } // Context sets the context to be used in this call's Do method. -func (c *EditsListingsPatchCall) Context(ctx context.Context) *EditsListingsPatchCall { +func (c *GrantsPatchCall) Context(ctx context.Context) *GrantsPatchCall { 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 *EditsListingsPatchCall) Header() http.Header { +func (c *GrantsPatchCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *EditsListingsPatchCall) doRequest(alt string) (*http.Response, error) { +func (c *GrantsPatchCall) doRequest(alt string) (*http.Response, error) { reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) - body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.listing) + body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.grant) if err != nil { return nil, err } c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/listings/{language}") + urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/{+name}") urls += "?" + c.urlParams_.Encode() req, err := http.NewRequest("PATCH", urls, body) if err != nil { @@ -12733,20 +16171,18 @@ func (c *EditsListingsPatchCall) doRequest(alt string) (*http.Response, error) { } req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ - "packageName": c.packageName, - "editId": c.editId, - "language": c.language, + "name": c.name, }) - c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.edits.listings.patch", "request", internallog.HTTPRequest(req, body.Bytes())) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.grants.patch", "request", internallog.HTTPRequest(req, body.Bytes())) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "androidpublisher.edits.listings.patch" call. +// Do executes the "androidpublisher.grants.patch" call. // Any non-2xx status code is an error. Response headers are in either -// *Listing.ServerResponse.Header or (if a response was returned at all) in +// *Grant.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 *EditsListingsPatchCall) Do(opts ...googleapi.CallOption) (*Listing, error) { +func (c *GrantsPatchCall) Do(opts ...googleapi.CallOption) (*Grant, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -12765,7 +16201,7 @@ func (c *EditsListingsPatchCall) Do(opts ...googleapi.CallOption) (*Listing, err if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &Listing{ + ret := &Grant{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -12776,150 +16212,128 @@ func (c *EditsListingsPatchCall) Do(opts ...googleapi.CallOption) (*Listing, err if err != nil { return nil, err } - c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.edits.listings.patch", "response", internallog.HTTPResponse(res, b)) + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.grants.patch", "response", internallog.HTTPResponse(res, b)) return ret, nil } -type EditsListingsUpdateCall struct { - s *Service - packageName string - editId string - language string - listing *Listing - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +type InappproductsBatchDeleteCall struct { + s *Service + packageName string + inappproductsbatchdeleterequest *InappproductsBatchDeleteRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// Update: Creates or updates a localized store listing. +// BatchDelete: Deletes in-app products (managed products or subscriptions). +// Set the latencyTolerance field on nested requests to +// PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_TOLERANT to achieve maximum update +// throughput. This method should not be used to delete subscriptions. See this +// article +// (https://android-developers.googleblog.com/2023/06/changes-to-google-play-developer-api-june-2023.html) +// for more information. // -// - editId: Identifier of the edit. -// - language: Language localization code (a BCP-47 language tag; for example, -// "de-AT" for Austrian German). -// - packageName: Package name of the app. -func (r *EditsListingsService) Update(packageName string, editId string, language string, listing *Listing) *EditsListingsUpdateCall { - c := &EditsListingsUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// - packageName: Package name of the app. +func (r *InappproductsService) BatchDelete(packageName string, inappproductsbatchdeleterequest *InappproductsBatchDeleteRequest) *InappproductsBatchDeleteCall { + c := &InappproductsBatchDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.packageName = packageName - c.editId = editId - c.language = language - c.listing = listing + c.inappproductsbatchdeleterequest = inappproductsbatchdeleterequest 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 *EditsListingsUpdateCall) Fields(s ...googleapi.Field) *EditsListingsUpdateCall { +func (c *InappproductsBatchDeleteCall) Fields(s ...googleapi.Field) *InappproductsBatchDeleteCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } // Context sets the context to be used in this call's Do method. -func (c *EditsListingsUpdateCall) Context(ctx context.Context) *EditsListingsUpdateCall { +func (c *InappproductsBatchDeleteCall) Context(ctx context.Context) *InappproductsBatchDeleteCall { 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 *EditsListingsUpdateCall) Header() http.Header { +func (c *InappproductsBatchDeleteCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *EditsListingsUpdateCall) doRequest(alt string) (*http.Response, error) { +func (c *InappproductsBatchDeleteCall) doRequest(alt string) (*http.Response, error) { reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) - body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.listing) + body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.inappproductsbatchdeleterequest) if err != nil { return nil, err } c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/listings/{language}") + urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/inappproducts:batchDelete") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("PUT", 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{ "packageName": c.packageName, - "editId": c.editId, - "language": c.language, }) - c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.edits.listings.update", "request", internallog.HTTPRequest(req, body.Bytes())) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.inappproducts.batchDelete", "request", internallog.HTTPRequest(req, body.Bytes())) return gensupport.SendRequest(c.ctx_, c.s.client, req) } - -// Do executes the "androidpublisher.edits.listings.update" call. -// Any non-2xx status code is an error. Response headers are in either -// *Listing.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 *EditsListingsUpdateCall) Do(opts ...googleapi.CallOption) (*Listing, error) { + +// Do executes the "androidpublisher.inappproducts.batchDelete" call. +func (c *InappproductsBatchDeleteCall) Do(opts ...googleapi.CallOption) 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 + return err } defer googleapi.CloseBody(res) if err := googleapi.CheckResponse(res); err != nil { - return nil, gensupport.WrapError(err) - } - ret := &Listing{ - ServerResponse: googleapi.ServerResponse{ - Header: res.Header, - HTTPStatusCode: res.StatusCode, - }, - } - target := &ret - b, err := gensupport.DecodeResponseBytes(target, res) - if err != nil { - return nil, err + return gensupport.WrapError(err) } - c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.edits.listings.update", "response", internallog.HTTPResponse(res, b)) - return ret, nil + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.inappproducts.batchDelete", "response", internallog.HTTPResponse(res, nil)) + return nil } -type EditsTestersGetCall struct { +type InappproductsBatchGetCall struct { s *Service packageName string - editId string - track string urlParams_ gensupport.URLParams ifNoneMatch_ string ctx_ context.Context header_ http.Header } -// Get: Gets testers. Note: Testers resource does not support email lists. +// BatchGet: Reads multiple in-app products, which can be managed products or +// subscriptions. This method should not be used to retrieve subscriptions. See +// this article +// (https://android-developers.googleblog.com/2023/06/changes-to-google-play-developer-api-june-2023.html) +// for more information. // -// - editId: Identifier of the edit. // - packageName: Package name of the app. -// - track: The track to read from. -func (r *EditsTestersService) Get(packageName string, editId string, track string) *EditsTestersGetCall { - c := &EditsTestersGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} +func (r *InappproductsService) BatchGet(packageName string) *InappproductsBatchGetCall { + c := &InappproductsBatchGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.packageName = packageName - c.editId = editId - c.track = track + return c +} + +// Sku sets the optional parameter "sku": Unique identifier for the in-app +// products. +func (c *InappproductsBatchGetCall) Sku(sku ...string) *InappproductsBatchGetCall { + c.urlParams_.SetMulti("sku", append([]string{}, sku...)) 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 *EditsTestersGetCall) Fields(s ...googleapi.Field) *EditsTestersGetCall { +func (c *InappproductsBatchGetCall) Fields(s ...googleapi.Field) *InappproductsBatchGetCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } @@ -12927,34 +16341,34 @@ func (c *EditsTestersGetCall) Fields(s ...googleapi.Field) *EditsTestersGetCall // 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 *EditsTestersGetCall) IfNoneMatch(entityTag string) *EditsTestersGetCall { +func (c *InappproductsBatchGetCall) IfNoneMatch(entityTag string) *InappproductsBatchGetCall { c.ifNoneMatch_ = entityTag return c } // Context sets the context to be used in this call's Do method. -func (c *EditsTestersGetCall) Context(ctx context.Context) *EditsTestersGetCall { +func (c *InappproductsBatchGetCall) Context(ctx context.Context) *InappproductsBatchGetCall { 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 *EditsTestersGetCall) Header() http.Header { +func (c *InappproductsBatchGetCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *EditsTestersGetCall) doRequest(alt string) (*http.Response, error) { +func (c *InappproductsBatchGetCall) doRequest(alt string) (*http.Response, error) { reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) if c.ifNoneMatch_ != "" { reqHeaders.Set("If-None-Match", c.ifNoneMatch_) } c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/testers/{track}") + urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/inappproducts:batchGet") urls += "?" + c.urlParams_.Encode() req, err := http.NewRequest("GET", urls, nil) if err != nil { @@ -12963,19 +16377,18 @@ func (c *EditsTestersGetCall) doRequest(alt string) (*http.Response, error) { req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ "packageName": c.packageName, - "editId": c.editId, - "track": c.track, }) - c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.edits.testers.get", "request", internallog.HTTPRequest(req, nil)) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.inappproducts.batchGet", "request", internallog.HTTPRequest(req, nil)) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "androidpublisher.edits.testers.get" call. +// Do executes the "androidpublisher.inappproducts.batchGet" call. // Any non-2xx status code is an error. Response headers are in either -// *Testers.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 *EditsTestersGetCall) Do(opts ...googleapi.CallOption) (*Testers, error) { +// *InappproductsBatchGetResponse.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 *InappproductsBatchGetCall) Do(opts ...googleapi.CallOption) (*InappproductsBatchGetResponse, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -12994,7 +16407,7 @@ func (c *EditsTestersGetCall) Do(opts ...googleapi.CallOption) (*Testers, error) if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &Testers{ + ret := &InappproductsBatchGetResponse{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -13005,88 +16418,87 @@ func (c *EditsTestersGetCall) Do(opts ...googleapi.CallOption) (*Testers, error) if err != nil { return nil, err } - c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.edits.testers.get", "response", internallog.HTTPResponse(res, b)) + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.inappproducts.batchGet", "response", internallog.HTTPResponse(res, b)) return ret, nil } -type EditsTestersPatchCall struct { - s *Service - packageName string - editId string - track string - testers *Testers - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +type InappproductsBatchUpdateCall struct { + s *Service + packageName string + inappproductsbatchupdaterequest *InappproductsBatchUpdateRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// Patch: Patches testers. Note: Testers resource does not support email lists. +// BatchUpdate: Updates or inserts one or more in-app products (managed +// products or subscriptions). Set the latencyTolerance field on nested +// requests to PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_TOLERANT to achieve +// maximum update throughput. This method should no longer be used to update +// subscriptions. See this article +// (https://android-developers.googleblog.com/2023/06/changes-to-google-play-developer-api-june-2023.html) +// for more information. // -// - editId: Identifier of the edit. // - packageName: Package name of the app. -// - track: The track to update. -func (r *EditsTestersService) Patch(packageName string, editId string, track string, testers *Testers) *EditsTestersPatchCall { - c := &EditsTestersPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)} +func (r *InappproductsService) BatchUpdate(packageName string, inappproductsbatchupdaterequest *InappproductsBatchUpdateRequest) *InappproductsBatchUpdateCall { + c := &InappproductsBatchUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.packageName = packageName - c.editId = editId - c.track = track - c.testers = testers + c.inappproductsbatchupdaterequest = inappproductsbatchupdaterequest 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 *EditsTestersPatchCall) Fields(s ...googleapi.Field) *EditsTestersPatchCall { +func (c *InappproductsBatchUpdateCall) Fields(s ...googleapi.Field) *InappproductsBatchUpdateCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } // Context sets the context to be used in this call's Do method. -func (c *EditsTestersPatchCall) Context(ctx context.Context) *EditsTestersPatchCall { +func (c *InappproductsBatchUpdateCall) Context(ctx context.Context) *InappproductsBatchUpdateCall { 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 *EditsTestersPatchCall) Header() http.Header { +func (c *InappproductsBatchUpdateCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *EditsTestersPatchCall) doRequest(alt string) (*http.Response, error) { +func (c *InappproductsBatchUpdateCall) doRequest(alt string) (*http.Response, error) { reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) - body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.testers) + body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.inappproductsbatchupdaterequest) if err != nil { return nil, err } c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/testers/{track}") + urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/inappproducts:batchUpdate") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("PATCH", 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{ "packageName": c.packageName, - "editId": c.editId, - "track": c.track, }) - c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.edits.testers.patch", "request", internallog.HTTPRequest(req, body.Bytes())) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.inappproducts.batchUpdate", "request", internallog.HTTPRequest(req, body.Bytes())) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "androidpublisher.edits.testers.patch" call. +// Do executes the "androidpublisher.inappproducts.batchUpdate" call. // Any non-2xx status code is an error. Response headers are in either -// *Testers.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 *EditsTestersPatchCall) Do(opts ...googleapi.CallOption) (*Testers, error) { +// *InappproductsBatchUpdateResponse.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 *InappproductsBatchUpdateCall) Do(opts ...googleapi.CallOption) (*InappproductsBatchUpdateResponse, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -13105,7 +16517,7 @@ func (c *EditsTestersPatchCall) Do(opts ...googleapi.CallOption) (*Testers, erro if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &Testers{ + ret := &InappproductsBatchUpdateResponse{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -13116,196 +16528,199 @@ func (c *EditsTestersPatchCall) Do(opts ...googleapi.CallOption) (*Testers, erro if err != nil { return nil, err } - c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.edits.testers.patch", "response", internallog.HTTPResponse(res, b)) + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.inappproducts.batchUpdate", "response", internallog.HTTPResponse(res, b)) return ret, nil } -type EditsTestersUpdateCall struct { +type InappproductsDeleteCall struct { s *Service packageName string - editId string - track string - testers *Testers + skuid string urlParams_ gensupport.URLParams ctx_ context.Context header_ http.Header } -// Update: Updates testers. Note: Testers resource does not support email -// lists. +// Delete: Deletes an in-app product (a managed product or a subscription). +// This method should no longer be used to delete subscriptions. See this +// article +// (https://android-developers.googleblog.com/2023/06/changes-to-google-play-developer-api-june-2023.html) +// for more information. // -// - editId: Identifier of the edit. // - packageName: Package name of the app. -// - track: The track to update. -func (r *EditsTestersService) Update(packageName string, editId string, track string, testers *Testers) *EditsTestersUpdateCall { - c := &EditsTestersUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// - sku: Unique identifier for the in-app product. +func (r *InappproductsService) Delete(packageName string, skuid string) *InappproductsDeleteCall { + c := &InappproductsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.packageName = packageName - c.editId = editId - c.track = track - c.testers = testers + c.skuid = skuid + return c +} + +// LatencyTolerance sets the optional parameter "latencyTolerance": The latency +// tolerance for the propagation of this product update. Defaults to +// latency-sensitive. +// +// Possible values: +// +// "PRODUCT_UPDATE_LATENCY_TOLERANCE_UNSPECIFIED" - Defaults to +// +// PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_SENSITIVE. +// +// "PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_SENSITIVE" - The update will +// +// propagate to clients within several minutes on average and up to a few hours +// in rare cases. Throughput is limited to 7,200 updates per app per hour. +// +// "PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_TOLERANT" - The update will +// +// propagate to clients within 24 hours. Supports high throughput of up to +// 720,000 updates per app per hour using batch modification methods. +func (c *InappproductsDeleteCall) LatencyTolerance(latencyTolerance string) *InappproductsDeleteCall { + c.urlParams_.Set("latencyTolerance", latencyTolerance) 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 *EditsTestersUpdateCall) Fields(s ...googleapi.Field) *EditsTestersUpdateCall { +func (c *InappproductsDeleteCall) Fields(s ...googleapi.Field) *InappproductsDeleteCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } // Context sets the context to be used in this call's Do method. -func (c *EditsTestersUpdateCall) Context(ctx context.Context) *EditsTestersUpdateCall { +func (c *InappproductsDeleteCall) Context(ctx context.Context) *InappproductsDeleteCall { 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 *EditsTestersUpdateCall) Header() http.Header { +func (c *InappproductsDeleteCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *EditsTestersUpdateCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) - body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.testers) - if err != nil { - return nil, err - } +func (c *InappproductsDeleteCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/testers/{track}") + urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/inappproducts/{sku}") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("PUT", urls, body) + req, err := http.NewRequest("DELETE", urls, nil) if err != nil { return nil, err } req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ "packageName": c.packageName, - "editId": c.editId, - "track": c.track, + "sku": c.skuid, }) - c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.edits.testers.update", "request", internallog.HTTPRequest(req, body.Bytes())) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.inappproducts.delete", "request", internallog.HTTPRequest(req, nil)) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "androidpublisher.edits.testers.update" call. -// Any non-2xx status code is an error. Response headers are in either -// *Testers.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 *EditsTestersUpdateCall) Do(opts ...googleapi.CallOption) (*Testers, error) { +// Do executes the "androidpublisher.inappproducts.delete" call. +func (c *InappproductsDeleteCall) Do(opts ...googleapi.CallOption) 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 + return err } defer googleapi.CloseBody(res) if err := googleapi.CheckResponse(res); err != nil { - return nil, gensupport.WrapError(err) - } - ret := &Testers{ - ServerResponse: googleapi.ServerResponse{ - Header: res.Header, - HTTPStatusCode: res.StatusCode, - }, - } - target := &ret - b, err := gensupport.DecodeResponseBytes(target, res) - if err != nil { - return nil, err + return gensupport.WrapError(err) } - c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.edits.testers.update", "response", internallog.HTTPResponse(res, b)) - return ret, nil + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.inappproducts.delete", "response", internallog.HTTPResponse(res, nil)) + return nil } -type EditsTracksCreateCall struct { - s *Service - packageName string - editId string - trackconfig *TrackConfig - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +type InappproductsGetCall struct { + s *Service + packageName string + skuid string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header } -// Create: Creates a new track. +// Get: Gets an in-app product, which can be a managed product or a +// subscription. This method should no longer be used to retrieve +// subscriptions. See this article +// (https://android-developers.googleblog.com/2023/06/changes-to-google-play-developer-api-june-2023.html) +// for more information. // -// - editId: Identifier of the edit. // - packageName: Package name of the app. -func (r *EditsTracksService) Create(packageName string, editId string, trackconfig *TrackConfig) *EditsTracksCreateCall { - c := &EditsTracksCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// - sku: Unique identifier for the in-app product. +func (r *InappproductsService) Get(packageName string, skuid string) *InappproductsGetCall { + c := &InappproductsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.packageName = packageName - c.editId = editId - c.trackconfig = trackconfig + c.skuid = skuid 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 *EditsTracksCreateCall) Fields(s ...googleapi.Field) *EditsTracksCreateCall { +func (c *InappproductsGetCall) Fields(s ...googleapi.Field) *InappproductsGetCall { 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 *InappproductsGetCall) IfNoneMatch(entityTag string) *InappproductsGetCall { + c.ifNoneMatch_ = entityTag + return c +} + // Context sets the context to be used in this call's Do method. -func (c *EditsTracksCreateCall) Context(ctx context.Context) *EditsTracksCreateCall { +func (c *InappproductsGetCall) Context(ctx context.Context) *InappproductsGetCall { 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 *EditsTracksCreateCall) Header() http.Header { +func (c *InappproductsGetCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *EditsTracksCreateCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) - body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.trackconfig) - if err != nil { - return nil, err +func (c *InappproductsGetCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) } c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/tracks") + urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/inappproducts/{sku}") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("POST", urls, body) + req, err := http.NewRequest("GET", urls, nil) if err != nil { return nil, err } req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ "packageName": c.packageName, - "editId": c.editId, + "sku": c.skuid, }) - c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.edits.tracks.create", "request", internallog.HTTPRequest(req, body.Bytes())) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.inappproducts.get", "request", internallog.HTTPRequest(req, nil)) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "androidpublisher.edits.tracks.create" call. +// Do executes the "androidpublisher.inappproducts.get" call. // Any non-2xx status code is an error. Response headers are in either -// *Track.ServerResponse.Header or (if a response was returned at all) in -// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// *InAppProduct.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 *EditsTracksCreateCall) Do(opts ...googleapi.CallOption) (*Track, error) { +func (c *InappproductsGetCall) Do(opts ...googleapi.CallOption) (*InAppProduct, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -13324,7 +16739,7 @@ func (c *EditsTracksCreateCall) Do(opts ...googleapi.CallOption) (*Track, error) if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &Track{ + ret := &InAppProduct{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -13335,95 +16750,94 @@ func (c *EditsTracksCreateCall) Do(opts ...googleapi.CallOption) (*Track, error) if err != nil { return nil, err } - c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.edits.tracks.create", "response", internallog.HTTPResponse(res, b)) + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.inappproducts.get", "response", internallog.HTTPResponse(res, b)) return ret, nil } -type EditsTracksGetCall struct { +type InappproductsInsertCall struct { s *Service packageName string - editId string - track string + inappproduct *InAppProduct urlParams_ gensupport.URLParams - ifNoneMatch_ string ctx_ context.Context header_ http.Header } -// Get: Gets a track. +// Insert: Creates an in-app product (a managed product or a subscription). +// This method should no longer be used to create subscriptions. See this +// article +// (https://android-developers.googleblog.com/2023/06/changes-to-google-play-developer-api-june-2023.html) +// for more information. // -// - editId: Identifier of the edit. -// - packageName: Package name of the app. -// - track: Identifier of the track. More on track name -// (https://developers.google.com/android-publisher/tracks#ff-track-name). -func (r *EditsTracksService) Get(packageName string, editId string, track string) *EditsTracksGetCall { - c := &EditsTracksGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// - packageName: Package name of the app. +func (r *InappproductsService) Insert(packageName string, inappproduct *InAppProduct) *InappproductsInsertCall { + c := &InappproductsInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.packageName = packageName - c.editId = editId - c.track = track + c.inappproduct = inappproduct + return c +} + +// AutoConvertMissingPrices sets the optional parameter +// "autoConvertMissingPrices": If true the prices for all regions targeted by +// the parent app that don't have a price specified for this in-app product +// will be auto converted to the target currency based on the default price. +// Defaults to false. +func (c *InappproductsInsertCall) AutoConvertMissingPrices(autoConvertMissingPrices bool) *InappproductsInsertCall { + c.urlParams_.Set("autoConvertMissingPrices", fmt.Sprint(autoConvertMissingPrices)) 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 *EditsTracksGetCall) Fields(s ...googleapi.Field) *EditsTracksGetCall { +func (c *InappproductsInsertCall) Fields(s ...googleapi.Field) *InappproductsInsertCall { 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 *EditsTracksGetCall) IfNoneMatch(entityTag string) *EditsTracksGetCall { - c.ifNoneMatch_ = entityTag - return c -} - // Context sets the context to be used in this call's Do method. -func (c *EditsTracksGetCall) Context(ctx context.Context) *EditsTracksGetCall { +func (c *InappproductsInsertCall) Context(ctx context.Context) *InappproductsInsertCall { 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 *EditsTracksGetCall) Header() http.Header { +func (c *InappproductsInsertCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *EditsTracksGetCall) 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 *InappproductsInsertCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) + body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.inappproduct) + if err != nil { + return nil, err } c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/tracks/{track}") + urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/inappproducts") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("GET", urls, nil) + req, err := http.NewRequest("POST", urls, body) if err != nil { return nil, err } req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ "packageName": c.packageName, - "editId": c.editId, - "track": c.track, }) - c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.edits.tracks.get", "request", internallog.HTTPRequest(req, nil)) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.inappproducts.insert", "request", internallog.HTTPRequest(req, body.Bytes())) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "androidpublisher.edits.tracks.get" call. +// Do executes the "androidpublisher.inappproducts.insert" call. // Any non-2xx status code is an error. Response headers are in either -// *Track.ServerResponse.Header or (if a response was returned at all) in -// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// *InAppProduct.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 *EditsTracksGetCall) Do(opts ...googleapi.CallOption) (*Track, error) { +func (c *InappproductsInsertCall) Do(opts ...googleapi.CallOption) (*InAppProduct, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -13442,7 +16856,7 @@ func (c *EditsTracksGetCall) Do(opts ...googleapi.CallOption) (*Track, error) { if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &Track{ + ret := &InAppProduct{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -13453,35 +16867,60 @@ func (c *EditsTracksGetCall) Do(opts ...googleapi.CallOption) (*Track, error) { if err != nil { return nil, err } - c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.edits.tracks.get", "response", internallog.HTTPResponse(res, b)) + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.inappproducts.insert", "response", internallog.HTTPResponse(res, b)) return ret, nil } -type EditsTracksListCall struct { +type InappproductsListCall struct { s *Service packageName string - editId string urlParams_ gensupport.URLParams ifNoneMatch_ string ctx_ context.Context header_ http.Header } -// List: Lists all tracks. +// List: Lists all in-app products - both managed products and subscriptions. +// If an app has a large number of in-app products, the response may be +// paginated. In this case the response field `tokenPagination.nextPageToken` +// will be set and the caller should provide its value as a `token` request +// parameter to retrieve the next page. This method should no longer be used to +// retrieve subscriptions. See this article +// (https://android-developers.googleblog.com/2023/06/changes-to-google-play-developer-api-june-2023.html) +// for more information. // -// - editId: Identifier of the edit. // - packageName: Package name of the app. -func (r *EditsTracksService) List(packageName string, editId string) *EditsTracksListCall { - c := &EditsTracksListCall{s: r.s, urlParams_: make(gensupport.URLParams)} +func (r *InappproductsService) List(packageName string) *InappproductsListCall { + c := &InappproductsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.packageName = packageName - c.editId = editId + return c +} + +// MaxResults sets the optional parameter "maxResults": Deprecated and ignored. +// The page size is determined by the server. +func (c *InappproductsListCall) MaxResults(maxResults int64) *InappproductsListCall { + c.urlParams_.Set("maxResults", fmt.Sprint(maxResults)) + return c +} + +// StartIndex sets the optional parameter "startIndex": Deprecated and ignored. +// Set the `token` parameter to retrieve the next page. +func (c *InappproductsListCall) StartIndex(startIndex int64) *InappproductsListCall { + c.urlParams_.Set("startIndex", fmt.Sprint(startIndex)) + return c +} + +// Token sets the optional parameter "token": Pagination token. If empty, list +// starts at the first product. +func (c *InappproductsListCall) Token(token string) *InappproductsListCall { + c.urlParams_.Set("token", token) 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 *EditsTracksListCall) Fields(s ...googleapi.Field) *EditsTracksListCall { +func (c *InappproductsListCall) Fields(s ...googleapi.Field) *InappproductsListCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } @@ -13489,34 +16928,34 @@ func (c *EditsTracksListCall) Fields(s ...googleapi.Field) *EditsTracksListCall // 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 *EditsTracksListCall) IfNoneMatch(entityTag string) *EditsTracksListCall { +func (c *InappproductsListCall) IfNoneMatch(entityTag string) *InappproductsListCall { c.ifNoneMatch_ = entityTag return c } // Context sets the context to be used in this call's Do method. -func (c *EditsTracksListCall) Context(ctx context.Context) *EditsTracksListCall { +func (c *InappproductsListCall) Context(ctx context.Context) *InappproductsListCall { 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 *EditsTracksListCall) Header() http.Header { +func (c *InappproductsListCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *EditsTracksListCall) doRequest(alt string) (*http.Response, error) { +func (c *InappproductsListCall) doRequest(alt string) (*http.Response, error) { reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) if c.ifNoneMatch_ != "" { reqHeaders.Set("If-None-Match", c.ifNoneMatch_) } c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/tracks") + urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/inappproducts") urls += "?" + c.urlParams_.Encode() req, err := http.NewRequest("GET", urls, nil) if err != nil { @@ -13525,19 +16964,18 @@ func (c *EditsTracksListCall) doRequest(alt string) (*http.Response, error) { req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ "packageName": c.packageName, - "editId": c.editId, }) - c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.edits.tracks.list", "request", internallog.HTTPRequest(req, nil)) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.inappproducts.list", "request", internallog.HTTPRequest(req, nil)) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "androidpublisher.edits.tracks.list" call. +// Do executes the "androidpublisher.inappproducts.list" call. // Any non-2xx status code is an error. Response headers are in either -// *TracksListResponse.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 *EditsTracksListCall) Do(opts ...googleapi.CallOption) (*TracksListResponse, error) { +// *InappproductsListResponse.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 *InappproductsListCall) Do(opts ...googleapi.CallOption) (*InappproductsListResponse, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -13556,7 +16994,7 @@ func (c *EditsTracksListCall) Do(opts ...googleapi.CallOption) (*TracksListRespo if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &TracksListResponse{ + ret := &InappproductsListResponse{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -13567,68 +17005,101 @@ func (c *EditsTracksListCall) Do(opts ...googleapi.CallOption) (*TracksListRespo if err != nil { return nil, err } - c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.edits.tracks.list", "response", internallog.HTTPResponse(res, b)) + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.inappproducts.list", "response", internallog.HTTPResponse(res, b)) return ret, nil } -type EditsTracksPatchCall struct { - s *Service - packageName string - editId string - track string - track2 *Track - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +type InappproductsPatchCall struct { + s *Service + packageName string + skuid string + inappproduct *InAppProduct + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Patch: Patches an in-app product (a managed product or a subscription). This +// method should no longer be used to update subscriptions. See this article +// (https://android-developers.googleblog.com/2023/06/changes-to-google-play-developer-api-june-2023.html) +// for more information. +// +// - packageName: Package name of the app. +// - sku: Unique identifier for the in-app product. +func (r *InappproductsService) Patch(packageName string, skuid string, inappproduct *InAppProduct) *InappproductsPatchCall { + c := &InappproductsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.packageName = packageName + c.skuid = skuid + c.inappproduct = inappproduct + return c } -// Patch: Patches a track. +// AutoConvertMissingPrices sets the optional parameter +// "autoConvertMissingPrices": If true the prices for all regions targeted by +// the parent app that don't have a price specified for this in-app product +// will be auto converted to the target currency based on the default price. +// Defaults to false. +func (c *InappproductsPatchCall) AutoConvertMissingPrices(autoConvertMissingPrices bool) *InappproductsPatchCall { + c.urlParams_.Set("autoConvertMissingPrices", fmt.Sprint(autoConvertMissingPrices)) + return c +} + +// LatencyTolerance sets the optional parameter "latencyTolerance": The latency +// tolerance for the propagation of this product update. Defaults to +// latency-sensitive. // -// - editId: Identifier of the edit. -// - packageName: Package name of the app. -// - track: Identifier of the track. More on track name -// (https://developers.google.com/android-publisher/tracks#ff-track-name). -func (r *EditsTracksService) Patch(packageName string, editId string, track string, track2 *Track) *EditsTracksPatchCall { - c := &EditsTracksPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.packageName = packageName - c.editId = editId - c.track = track - c.track2 = track2 +// Possible values: +// +// "PRODUCT_UPDATE_LATENCY_TOLERANCE_UNSPECIFIED" - Defaults to +// +// PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_SENSITIVE. +// +// "PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_SENSITIVE" - The update will +// +// propagate to clients within several minutes on average and up to a few hours +// in rare cases. Throughput is limited to 7,200 updates per app per hour. +// +// "PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_TOLERANT" - The update will +// +// propagate to clients within 24 hours. Supports high throughput of up to +// 720,000 updates per app per hour using batch modification methods. +func (c *InappproductsPatchCall) LatencyTolerance(latencyTolerance string) *InappproductsPatchCall { + c.urlParams_.Set("latencyTolerance", latencyTolerance) 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 *EditsTracksPatchCall) Fields(s ...googleapi.Field) *EditsTracksPatchCall { +func (c *InappproductsPatchCall) Fields(s ...googleapi.Field) *InappproductsPatchCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } // Context sets the context to be used in this call's Do method. -func (c *EditsTracksPatchCall) Context(ctx context.Context) *EditsTracksPatchCall { +func (c *InappproductsPatchCall) Context(ctx context.Context) *InappproductsPatchCall { 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 *EditsTracksPatchCall) Header() http.Header { +func (c *InappproductsPatchCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *EditsTracksPatchCall) doRequest(alt string) (*http.Response, error) { +func (c *InappproductsPatchCall) doRequest(alt string) (*http.Response, error) { reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) - body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.track2) + body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.inappproduct) if err != nil { return nil, err } c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/tracks/{track}") + urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/inappproducts/{sku}") urls += "?" + c.urlParams_.Encode() req, err := http.NewRequest("PATCH", urls, body) if err != nil { @@ -13637,19 +17108,18 @@ func (c *EditsTracksPatchCall) doRequest(alt string) (*http.Response, error) { req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ "packageName": c.packageName, - "editId": c.editId, - "track": c.track, + "sku": c.skuid, }) - c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.edits.tracks.patch", "request", internallog.HTTPRequest(req, body.Bytes())) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.inappproducts.patch", "request", internallog.HTTPRequest(req, body.Bytes())) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "androidpublisher.edits.tracks.patch" call. +// Do executes the "androidpublisher.inappproducts.patch" call. // Any non-2xx status code is an error. Response headers are in either -// *Track.ServerResponse.Header or (if a response was returned at all) in -// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// *InAppProduct.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 *EditsTracksPatchCall) Do(opts ...googleapi.CallOption) (*Track, error) { +func (c *InappproductsPatchCall) Do(opts ...googleapi.CallOption) (*InAppProduct, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -13668,7 +17138,7 @@ func (c *EditsTracksPatchCall) Do(opts ...googleapi.CallOption) (*Track, error) if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &Track{ + ret := &InAppProduct{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -13679,68 +17149,110 @@ func (c *EditsTracksPatchCall) Do(opts ...googleapi.CallOption) (*Track, error) if err != nil { return nil, err } - c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.edits.tracks.patch", "response", internallog.HTTPResponse(res, b)) + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.inappproducts.patch", "response", internallog.HTTPResponse(res, b)) return ret, nil } -type EditsTracksUpdateCall struct { - s *Service - packageName string - editId string - track string - track2 *Track - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +type InappproductsUpdateCall struct { + s *Service + packageName string + skuid string + inappproduct *InAppProduct + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// Update: Updates a track. +// Update: Updates an in-app product (a managed product or a subscription). +// This method should no longer be used to update subscriptions. See this +// article +// (https://android-developers.googleblog.com/2023/06/changes-to-google-play-developer-api-june-2023.html) +// for more information. // -// - editId: Identifier of the edit. -// - packageName: Package name of the app. -// - track: Identifier of the track. More on track name -// (https://developers.google.com/android-publisher/tracks#ff-track-name). -func (r *EditsTracksService) Update(packageName string, editId string, track string, track2 *Track) *EditsTracksUpdateCall { - c := &EditsTracksUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// - packageName: Package name of the app. +// - sku: Unique identifier for the in-app product. +func (r *InappproductsService) Update(packageName string, skuid string, inappproduct *InAppProduct) *InappproductsUpdateCall { + c := &InappproductsUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.packageName = packageName - c.editId = editId - c.track = track - c.track2 = track2 + c.skuid = skuid + c.inappproduct = inappproduct + return c +} + +// AllowMissing sets the optional parameter "allowMissing": If set to true, and +// the in-app product with the given package_name and sku doesn't exist, the +// in-app product will be created. +func (c *InappproductsUpdateCall) AllowMissing(allowMissing bool) *InappproductsUpdateCall { + c.urlParams_.Set("allowMissing", fmt.Sprint(allowMissing)) + return c +} + +// AutoConvertMissingPrices sets the optional parameter +// "autoConvertMissingPrices": If true the prices for all regions targeted by +// the parent app that don't have a price specified for this in-app product +// will be auto converted to the target currency based on the default price. +// Defaults to false. +func (c *InappproductsUpdateCall) AutoConvertMissingPrices(autoConvertMissingPrices bool) *InappproductsUpdateCall { + c.urlParams_.Set("autoConvertMissingPrices", fmt.Sprint(autoConvertMissingPrices)) + return c +} + +// LatencyTolerance sets the optional parameter "latencyTolerance": The latency +// tolerance for the propagation of this product update. Defaults to +// latency-sensitive. +// +// Possible values: +// +// "PRODUCT_UPDATE_LATENCY_TOLERANCE_UNSPECIFIED" - Defaults to +// +// PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_SENSITIVE. +// +// "PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_SENSITIVE" - The update will +// +// propagate to clients within several minutes on average and up to a few hours +// in rare cases. Throughput is limited to 7,200 updates per app per hour. +// +// "PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_TOLERANT" - The update will +// +// propagate to clients within 24 hours. Supports high throughput of up to +// 720,000 updates per app per hour using batch modification methods. +func (c *InappproductsUpdateCall) LatencyTolerance(latencyTolerance string) *InappproductsUpdateCall { + c.urlParams_.Set("latencyTolerance", latencyTolerance) 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 *EditsTracksUpdateCall) Fields(s ...googleapi.Field) *EditsTracksUpdateCall { +func (c *InappproductsUpdateCall) Fields(s ...googleapi.Field) *InappproductsUpdateCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } // Context sets the context to be used in this call's Do method. -func (c *EditsTracksUpdateCall) Context(ctx context.Context) *EditsTracksUpdateCall { +func (c *InappproductsUpdateCall) Context(ctx context.Context) *InappproductsUpdateCall { 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 *EditsTracksUpdateCall) Header() http.Header { +func (c *InappproductsUpdateCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *EditsTracksUpdateCall) doRequest(alt string) (*http.Response, error) { +func (c *InappproductsUpdateCall) doRequest(alt string) (*http.Response, error) { reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) - body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.track2) + body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.inappproduct) if err != nil { return nil, err } c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/edits/{editId}/tracks/{track}") + urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/inappproducts/{sku}") urls += "?" + c.urlParams_.Encode() req, err := http.NewRequest("PUT", urls, body) if err != nil { @@ -13749,19 +17261,18 @@ func (c *EditsTracksUpdateCall) doRequest(alt string) (*http.Response, error) { req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ "packageName": c.packageName, - "editId": c.editId, - "track": c.track, + "sku": c.skuid, }) - c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.edits.tracks.update", "request", internallog.HTTPRequest(req, body.Bytes())) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.inappproducts.update", "request", internallog.HTTPRequest(req, body.Bytes())) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "androidpublisher.edits.tracks.update" call. +// Do executes the "androidpublisher.inappproducts.update" call. // Any non-2xx status code is an error. Response headers are in either -// *Track.ServerResponse.Header or (if a response was returned at all) in -// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// *InAppProduct.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 *EditsTracksUpdateCall) Do(opts ...googleapi.CallOption) (*Track, error) { +func (c *InappproductsUpdateCall) Do(opts ...googleapi.CallOption) (*InAppProduct, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -13780,7 +17291,7 @@ func (c *EditsTracksUpdateCall) Do(opts ...googleapi.CallOption) (*Track, error) if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &Track{ + ret := &InAppProduct{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -13791,93 +17302,126 @@ func (c *EditsTracksUpdateCall) Do(opts ...googleapi.CallOption) (*Track, error) if err != nil { return nil, err } - c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.edits.tracks.update", "response", internallog.HTTPResponse(res, b)) + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.inappproducts.update", "response", internallog.HTTPResponse(res, b)) return ret, nil } -type ExternaltransactionsCreateexternaltransactionCall struct { - s *Service - parent string - externaltransaction *ExternalTransaction - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +type InternalappsharingartifactsUploadapkCall struct { + s *Service + packageName string + urlParams_ gensupport.URLParams + mediaInfo_ *gensupport.MediaInfo + ctx_ context.Context + header_ http.Header } -// Createexternaltransaction: Creates a new external transaction. +// Uploadapk: Uploads an APK to internal app sharing. If you are using the +// Google API client libraries, please increase the timeout of the http request +// before calling this endpoint (a timeout of 2 minutes is recommended). See +// Timeouts and Errors +// (https://developers.google.com/api-client-library/java/google-api-java-client/errors) +// for an example in java. // -// - parent: The parent resource where this external transaction will be -// created. Format: applications/{package_name}. -func (r *ExternaltransactionsService) Createexternaltransaction(parent string, externaltransaction *ExternalTransaction) *ExternaltransactionsCreateexternaltransactionCall { - c := &ExternaltransactionsCreateexternaltransactionCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.parent = parent - c.externaltransaction = externaltransaction +// - packageName: Package name of the app. +func (r *InternalappsharingartifactsService) Uploadapk(packageName string) *InternalappsharingartifactsUploadapkCall { + c := &InternalappsharingartifactsUploadapkCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.packageName = packageName return c } -// ExternalTransactionId sets the optional parameter "externalTransactionId": -// Required. The id to use for the external transaction. Must be unique across -// all other transactions for the app. This value should be 1-63 characters and -// valid characters are /a-zA-Z0-9_-/. Do not use this field to store any -// Personally Identifiable Information (PII) such as emails. Attempting to -// store PII in this field may result in requests being blocked. -func (c *ExternaltransactionsCreateexternaltransactionCall) ExternalTransactionId(externalTransactionId string) *ExternaltransactionsCreateexternaltransactionCall { - c.urlParams_.Set("externalTransactionId", externalTransactionId) +// Media specifies the media to upload in one or more chunks. The chunk size +// may be controlled by supplying a MediaOption generated by +// googleapi.ChunkSize. The chunk size defaults to +// googleapi.DefaultUploadChunkSize.The Content-Type header used in the upload +// request will be determined by sniffing the contents of r, unless a +// MediaOption generated by googleapi.ContentType is supplied. +// At most one of Media and ResumableMedia may be set. +func (c *InternalappsharingartifactsUploadapkCall) Media(r io.Reader, options ...googleapi.MediaOption) *InternalappsharingartifactsUploadapkCall { + c.mediaInfo_ = gensupport.NewInfoFromMedia(r, options) + return c +} + +// ResumableMedia specifies the media to upload in chunks and can be canceled +// with ctx. +// +// Deprecated: use Media instead. +// +// At most one of Media and ResumableMedia may be set. mediaType identifies the +// MIME media type of the upload, such as "image/png". If mediaType is "", it +// will be auto-detected. The provided ctx will supersede any context +// previously provided to the Context method. +func (c *InternalappsharingartifactsUploadapkCall) ResumableMedia(ctx context.Context, r io.ReaderAt, size int64, mediaType string) *InternalappsharingartifactsUploadapkCall { + c.ctx_ = ctx + c.mediaInfo_ = gensupport.NewInfoFromResumableMedia(r, size, mediaType) + return c +} + +// ProgressUpdater provides a callback function that will be called after every +// chunk. It should be a low-latency function in order to not slow down the +// upload operation. This should only be called when using ResumableMedia (as +// opposed to Media). +func (c *InternalappsharingartifactsUploadapkCall) ProgressUpdater(pu googleapi.ProgressUpdater) *InternalappsharingartifactsUploadapkCall { + c.mediaInfo_.SetProgressUpdater(pu) 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 *ExternaltransactionsCreateexternaltransactionCall) Fields(s ...googleapi.Field) *ExternaltransactionsCreateexternaltransactionCall { +func (c *InternalappsharingartifactsUploadapkCall) Fields(s ...googleapi.Field) *InternalappsharingartifactsUploadapkCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } // Context sets the context to be used in this call's Do method. -func (c *ExternaltransactionsCreateexternaltransactionCall) Context(ctx context.Context) *ExternaltransactionsCreateexternaltransactionCall { +// This context will supersede any context previously provided to the +// ResumableMedia method. +func (c *InternalappsharingartifactsUploadapkCall) Context(ctx context.Context) *InternalappsharingartifactsUploadapkCall { 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 *ExternaltransactionsCreateexternaltransactionCall) Header() http.Header { +func (c *InternalappsharingartifactsUploadapkCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ExternaltransactionsCreateexternaltransactionCall) doRequest(alt string) (*http.Response, error) { +func (c *InternalappsharingartifactsUploadapkCall) doRequest(alt string) (*http.Response, error) { reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) - body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.externaltransaction) - if err != nil { - return nil, err - } c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/{+parent}/externalTransactions") + urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/internalappsharing/{packageName}/artifacts/apk") + if c.mediaInfo_ != nil { + urls = googleapi.ResolveRelative(c.s.BasePath, "/upload/androidpublisher/v3/applications/internalappsharing/{packageName}/artifacts/apk") + c.urlParams_.Set("uploadType", c.mediaInfo_.UploadType()) + } + newBody, getBody, cleanup := c.mediaInfo_.UploadRequest(reqHeaders, nil) + defer cleanup() urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("POST", urls, body) + req, err := http.NewRequest("POST", urls, newBody) if err != nil { return nil, err } req.Header = reqHeaders + req.GetBody = getBody googleapi.Expand(req.URL, map[string]string{ - "parent": c.parent, + "packageName": c.packageName, }) - c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.externaltransactions.createexternaltransaction", "request", internallog.HTTPRequest(req, body.Bytes())) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.internalappsharingartifacts.uploadapk", "request", internallog.HTTPRequest(req, nil)) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "androidpublisher.externaltransactions.createexternaltransaction" call. +// Do executes the "androidpublisher.internalappsharingartifacts.uploadapk" call. // Any non-2xx status code is an error. Response headers are in either -// *ExternalTransaction.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 *ExternaltransactionsCreateexternaltransactionCall) Do(opts ...googleapi.CallOption) (*ExternalTransaction, error) { +// *InternalAppSharingArtifact.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 *InternalappsharingartifactsUploadapkCall) Do(opts ...googleapi.CallOption) (*InternalAppSharingArtifact, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -13896,7 +17440,24 @@ func (c *ExternaltransactionsCreateexternaltransactionCall) Do(opts ...googleapi if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &ExternalTransaction{ + rx := c.mediaInfo_.ResumableUpload(res.Header.Get("Location")) + if rx != nil { + rx.Client = c.s.client + rx.UserAgent = c.s.userAgent() + ctx := c.ctx_ + if ctx == nil { + ctx = context.TODO() + } + res, err = rx.Upload(ctx) + if err != nil { + return nil, err + } + defer res.Body.Close() + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + } + ret := &InternalAppSharingArtifact{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -13907,88 +17468,126 @@ func (c *ExternaltransactionsCreateexternaltransactionCall) Do(opts ...googleapi if err != nil { return nil, err } - c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.externaltransactions.createexternaltransaction", "response", internallog.HTTPResponse(res, b)) + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.internalappsharingartifacts.uploadapk", "response", internallog.HTTPResponse(res, b)) return ret, nil } -type ExternaltransactionsGetexternaltransactionCall struct { - s *Service - name string - urlParams_ gensupport.URLParams - ifNoneMatch_ string - ctx_ context.Context - header_ http.Header +type InternalappsharingartifactsUploadbundleCall struct { + s *Service + packageName string + urlParams_ gensupport.URLParams + mediaInfo_ *gensupport.MediaInfo + ctx_ context.Context + header_ http.Header } -// Getexternaltransaction: Gets an existing external transaction. +// Uploadbundle: Uploads an app bundle to internal app sharing. If you are +// using the Google API client libraries, please increase the timeout of the +// http request before calling this endpoint (a timeout of 2 minutes is +// recommended). See Timeouts and Errors +// (https://developers.google.com/api-client-library/java/google-api-java-client/errors) +// for an example in java. // -// - name: The name of the external transaction to retrieve. Format: -// applications/{package_name}/externalTransactions/{external_transaction}. -func (r *ExternaltransactionsService) Getexternaltransaction(name string) *ExternaltransactionsGetexternaltransactionCall { - c := &ExternaltransactionsGetexternaltransactionCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.name = name +// - packageName: Package name of the app. +func (r *InternalappsharingartifactsService) Uploadbundle(packageName string) *InternalappsharingartifactsUploadbundleCall { + c := &InternalappsharingartifactsUploadbundleCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.packageName = packageName + return c +} + +// Media specifies the media to upload in one or more chunks. The chunk size +// may be controlled by supplying a MediaOption generated by +// googleapi.ChunkSize. The chunk size defaults to +// googleapi.DefaultUploadChunkSize.The Content-Type header used in the upload +// request will be determined by sniffing the contents of r, unless a +// MediaOption generated by googleapi.ContentType is supplied. +// At most one of Media and ResumableMedia may be set. +func (c *InternalappsharingartifactsUploadbundleCall) Media(r io.Reader, options ...googleapi.MediaOption) *InternalappsharingartifactsUploadbundleCall { + c.mediaInfo_ = gensupport.NewInfoFromMedia(r, options) + return c +} + +// ResumableMedia specifies the media to upload in chunks and can be canceled +// with ctx. +// +// Deprecated: use Media instead. +// +// At most one of Media and ResumableMedia may be set. mediaType identifies the +// MIME media type of the upload, such as "image/png". If mediaType is "", it +// will be auto-detected. The provided ctx will supersede any context +// previously provided to the Context method. +func (c *InternalappsharingartifactsUploadbundleCall) ResumableMedia(ctx context.Context, r io.ReaderAt, size int64, mediaType string) *InternalappsharingartifactsUploadbundleCall { + c.ctx_ = ctx + c.mediaInfo_ = gensupport.NewInfoFromResumableMedia(r, size, mediaType) + return c +} + +// ProgressUpdater provides a callback function that will be called after every +// chunk. It should be a low-latency function in order to not slow down the +// upload operation. This should only be called when using ResumableMedia (as +// opposed to Media). +func (c *InternalappsharingartifactsUploadbundleCall) ProgressUpdater(pu googleapi.ProgressUpdater) *InternalappsharingartifactsUploadbundleCall { + c.mediaInfo_.SetProgressUpdater(pu) 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 *ExternaltransactionsGetexternaltransactionCall) Fields(s ...googleapi.Field) *ExternaltransactionsGetexternaltransactionCall { +func (c *InternalappsharingartifactsUploadbundleCall) Fields(s ...googleapi.Field) *InternalappsharingartifactsUploadbundleCall { 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 *ExternaltransactionsGetexternaltransactionCall) IfNoneMatch(entityTag string) *ExternaltransactionsGetexternaltransactionCall { - c.ifNoneMatch_ = entityTag - return c -} - // Context sets the context to be used in this call's Do method. -func (c *ExternaltransactionsGetexternaltransactionCall) Context(ctx context.Context) *ExternaltransactionsGetexternaltransactionCall { +// This context will supersede any context previously provided to the +// ResumableMedia method. +func (c *InternalappsharingartifactsUploadbundleCall) Context(ctx context.Context) *InternalappsharingartifactsUploadbundleCall { 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 *ExternaltransactionsGetexternaltransactionCall) Header() http.Header { +func (c *InternalappsharingartifactsUploadbundleCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ExternaltransactionsGetexternaltransactionCall) 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 *InternalappsharingartifactsUploadbundleCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/{+name}") + urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/internalappsharing/{packageName}/artifacts/bundle") + if c.mediaInfo_ != nil { + urls = googleapi.ResolveRelative(c.s.BasePath, "/upload/androidpublisher/v3/applications/internalappsharing/{packageName}/artifacts/bundle") + c.urlParams_.Set("uploadType", c.mediaInfo_.UploadType()) + } + newBody, getBody, cleanup := c.mediaInfo_.UploadRequest(reqHeaders, nil) + defer cleanup() urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("GET", urls, nil) + req, err := http.NewRequest("POST", urls, newBody) if err != nil { return nil, err } req.Header = reqHeaders + req.GetBody = getBody googleapi.Expand(req.URL, map[string]string{ - "name": c.name, + "packageName": c.packageName, }) - c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.externaltransactions.getexternaltransaction", "request", internallog.HTTPRequest(req, nil)) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.internalappsharingartifacts.uploadbundle", "request", internallog.HTTPRequest(req, nil)) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "androidpublisher.externaltransactions.getexternaltransaction" call. +// Do executes the "androidpublisher.internalappsharingartifacts.uploadbundle" call. // Any non-2xx status code is an error. Response headers are in either -// *ExternalTransaction.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 *ExternaltransactionsGetexternaltransactionCall) Do(opts ...googleapi.CallOption) (*ExternalTransaction, error) { +// *InternalAppSharingArtifact.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 *InternalappsharingartifactsUploadbundleCall) Do(opts ...googleapi.CallOption) (*InternalAppSharingArtifact, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -14007,7 +17606,24 @@ func (c *ExternaltransactionsGetexternaltransactionCall) Do(opts ...googleapi.Ca if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &ExternalTransaction{ + rx := c.mediaInfo_.ResumableUpload(res.Header.Get("Location")) + if rx != nil { + rx.Client = c.s.client + rx.UserAgent = c.s.userAgent() + ctx := c.ctx_ + if ctx == nil { + ctx = context.TODO() + } + res, err = rx.Upload(ctx) + if err != nil { + return nil, err + } + defer res.Body.Close() + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + } + ret := &InternalAppSharingArtifact{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -14018,63 +17634,63 @@ func (c *ExternaltransactionsGetexternaltransactionCall) Do(opts ...googleapi.Ca if err != nil { return nil, err } - c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.externaltransactions.getexternaltransaction", "response", internallog.HTTPResponse(res, b)) + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.internalappsharingartifacts.uploadbundle", "response", internallog.HTTPResponse(res, b)) return ret, nil } -type ExternaltransactionsRefundexternaltransactionCall struct { - s *Service - name string - refundexternaltransactionrequest *RefundExternalTransactionRequest - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +type MonetizationConvertRegionPricesCall struct { + s *Service + packageName string + convertregionpricesrequest *ConvertRegionPricesRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// Refundexternaltransaction: Refunds or partially refunds an existing external -// transaction. +// ConvertRegionPrices: Calculates the region prices, using today's exchange +// rate and country-specific pricing patterns, based on the price in the +// request for a set of regions. // -// - name: The name of the external transaction that will be refunded. Format: -// applications/{package_name}/externalTransactions/{external_transaction}. -func (r *ExternaltransactionsService) Refundexternaltransaction(name string, refundexternaltransactionrequest *RefundExternalTransactionRequest) *ExternaltransactionsRefundexternaltransactionCall { - c := &ExternaltransactionsRefundexternaltransactionCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.name = name - c.refundexternaltransactionrequest = refundexternaltransactionrequest +// - packageName: The app package name. +func (r *MonetizationService) ConvertRegionPrices(packageName string, convertregionpricesrequest *ConvertRegionPricesRequest) *MonetizationConvertRegionPricesCall { + c := &MonetizationConvertRegionPricesCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.packageName = packageName + c.convertregionpricesrequest = convertregionpricesrequest 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 *ExternaltransactionsRefundexternaltransactionCall) Fields(s ...googleapi.Field) *ExternaltransactionsRefundexternaltransactionCall { +func (c *MonetizationConvertRegionPricesCall) Fields(s ...googleapi.Field) *MonetizationConvertRegionPricesCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } // Context sets the context to be used in this call's Do method. -func (c *ExternaltransactionsRefundexternaltransactionCall) Context(ctx context.Context) *ExternaltransactionsRefundexternaltransactionCall { +func (c *MonetizationConvertRegionPricesCall) Context(ctx context.Context) *MonetizationConvertRegionPricesCall { 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 *ExternaltransactionsRefundexternaltransactionCall) Header() http.Header { +func (c *MonetizationConvertRegionPricesCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ExternaltransactionsRefundexternaltransactionCall) doRequest(alt string) (*http.Response, error) { +func (c *MonetizationConvertRegionPricesCall) doRequest(alt string) (*http.Response, error) { reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) - body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.refundexternaltransactionrequest) + body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.convertregionpricesrequest) if err != nil { return nil, err } c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/{+name}:refund") + urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/pricing:convertRegionPrices") urls += "?" + c.urlParams_.Encode() req, err := http.NewRequest("POST", urls, body) if err != nil { @@ -14082,19 +17698,19 @@ func (c *ExternaltransactionsRefundexternaltransactionCall) doRequest(alt string } req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ - "name": c.name, + "packageName": c.packageName, }) - c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.externaltransactions.refundexternaltransaction", "request", internallog.HTTPRequest(req, body.Bytes())) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.monetization.convertRegionPrices", "request", internallog.HTTPRequest(req, body.Bytes())) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "androidpublisher.externaltransactions.refundexternaltransaction" call. +// Do executes the "androidpublisher.monetization.convertRegionPrices" call. // Any non-2xx status code is an error. Response headers are in either -// *ExternalTransaction.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 *ExternaltransactionsRefundexternaltransactionCall) Do(opts ...googleapi.CallOption) (*ExternalTransaction, error) { +// *ConvertRegionPricesResponse.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 *MonetizationConvertRegionPricesCall) Do(opts ...googleapi.CallOption) (*ConvertRegionPricesResponse, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -14113,7 +17729,7 @@ func (c *ExternaltransactionsRefundexternaltransactionCall) Do(opts ...googleapi if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &ExternalTransaction{ + ret := &ConvertRegionPricesResponse{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -14124,107 +17740,78 @@ func (c *ExternaltransactionsRefundexternaltransactionCall) Do(opts ...googleapi if err != nil { return nil, err } - c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.externaltransactions.refundexternaltransaction", "response", internallog.HTTPResponse(res, b)) + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.monetization.convertRegionPrices", "response", internallog.HTTPResponse(res, b)) return ret, nil } -type GeneratedapksDownloadCall struct { - s *Service - packageName string - versionCode int64 - downloadId string - urlParams_ gensupport.URLParams - ifNoneMatch_ string - ctx_ context.Context - header_ http.Header +type MonetizationOnetimeproductsBatchDeleteCall struct { + s *Service + packageName string + batchdeleteonetimeproductsrequest *BatchDeleteOneTimeProductsRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// Download: Downloads a single signed APK generated from an app bundle. +// BatchDelete: Deletes one or more one-time products. // -// - downloadId: Download ID, which uniquely identifies the APK to download. -// Can be obtained from the response of `generatedapks.list` method. -// - packageName: Package name of the app. -// - versionCode: Version code of the app bundle. -func (r *GeneratedapksService) Download(packageName string, versionCode int64, downloadId string) *GeneratedapksDownloadCall { - c := &GeneratedapksDownloadCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// - packageName: The parent app (package name) for which the one-time products +// should be deleted. Must be equal to the package_name field on all the +// OneTimeProduct resources. +func (r *MonetizationOnetimeproductsService) BatchDelete(packageName string, batchdeleteonetimeproductsrequest *BatchDeleteOneTimeProductsRequest) *MonetizationOnetimeproductsBatchDeleteCall { + c := &MonetizationOnetimeproductsBatchDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.packageName = packageName - c.versionCode = versionCode - c.downloadId = downloadId + c.batchdeleteonetimeproductsrequest = batchdeleteonetimeproductsrequest 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 *GeneratedapksDownloadCall) Fields(s ...googleapi.Field) *GeneratedapksDownloadCall { +func (c *MonetizationOnetimeproductsBatchDeleteCall) Fields(s ...googleapi.Field) *MonetizationOnetimeproductsBatchDeleteCall { 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 *GeneratedapksDownloadCall) IfNoneMatch(entityTag string) *GeneratedapksDownloadCall { - c.ifNoneMatch_ = entityTag - return c -} - -// Context sets the context to be used in this call's Do and Download methods. -func (c *GeneratedapksDownloadCall) Context(ctx context.Context) *GeneratedapksDownloadCall { +// Context sets the context to be used in this call's Do method. +func (c *MonetizationOnetimeproductsBatchDeleteCall) Context(ctx context.Context) *MonetizationOnetimeproductsBatchDeleteCall { 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 *GeneratedapksDownloadCall) Header() http.Header { +func (c *MonetizationOnetimeproductsBatchDeleteCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *GeneratedapksDownloadCall) 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 *MonetizationOnetimeproductsBatchDeleteCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) + body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.batchdeleteonetimeproductsrequest) + if err != nil { + return nil, err } c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/generatedApks/{versionCode}/downloads/{downloadId}:download") + urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/oneTimeProducts:batchDelete") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("GET", urls, nil) + req, err := http.NewRequest("POST", urls, body) if err != nil { return nil, err } req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ "packageName": c.packageName, - "versionCode": strconv.FormatInt(c.versionCode, 10), - "downloadId": c.downloadId, }) - c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.generatedapks.download", "request", internallog.HTTPRequest(req, nil)) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.monetization.onetimeproducts.batchDelete", "request", internallog.HTTPRequest(req, body.Bytes())) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Download fetches the API endpoint's "media" value, instead of the normal -// API response value. If the returned error is nil, the Response is guaranteed to -// have a 2xx status code. Callers must close the Response.Body as usual. -func (c *GeneratedapksDownloadCall) Download(opts ...googleapi.CallOption) (*http.Response, error) { - gensupport.SetOptions(c.urlParams_, opts...) - res, err := c.doRequest("media") - if err != nil { - return nil, err - } - if err := googleapi.CheckResponse(res); err != nil { - res.Body.Close() - return nil, gensupport.WrapError(err) - } - return res, nil -} - -// Do executes the "androidpublisher.generatedapks.download" call. -func (c *GeneratedapksDownloadCall) Do(opts ...googleapi.CallOption) error { +// Do executes the "androidpublisher.monetization.onetimeproducts.batchDelete" call. +func (c *MonetizationOnetimeproductsBatchDeleteCall) Do(opts ...googleapi.CallOption) error { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if err != nil { @@ -14234,36 +17821,40 @@ func (c *GeneratedapksDownloadCall) Do(opts ...googleapi.CallOption) error { if err := googleapi.CheckResponse(res); err != nil { return gensupport.WrapError(err) } - c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.generatedapks.download", "response", internallog.HTTPResponse(res, nil)) + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.monetization.onetimeproducts.batchDelete", "response", internallog.HTTPResponse(res, nil)) return nil } -type GeneratedapksListCall struct { +type MonetizationOnetimeproductsBatchGetCall struct { s *Service packageName string - versionCode int64 urlParams_ gensupport.URLParams ifNoneMatch_ string ctx_ context.Context header_ http.Header } -// List: Returns download metadata for all APKs that were generated from a -// given app bundle. +// BatchGet: Reads one or more one-time products. // -// - packageName: Package name of the app. -// - versionCode: Version code of the app bundle. -func (r *GeneratedapksService) List(packageName string, versionCode int64) *GeneratedapksListCall { - c := &GeneratedapksListCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// - packageName: The parent app (package name) for which the products should +// be retrieved. Must be equal to the package_name field on all requests. +func (r *MonetizationOnetimeproductsService) BatchGet(packageName string) *MonetizationOnetimeproductsBatchGetCall { + c := &MonetizationOnetimeproductsBatchGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.packageName = packageName - c.versionCode = versionCode + return c +} + +// ProductIds sets the optional parameter "productIds": Required. A list of up +// to 100 product IDs to retrieve. All IDs must be different. +func (c *MonetizationOnetimeproductsBatchGetCall) ProductIds(productIds ...string) *MonetizationOnetimeproductsBatchGetCall { + c.urlParams_.SetMulti("productIds", append([]string{}, productIds...)) 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 *GeneratedapksListCall) Fields(s ...googleapi.Field) *GeneratedapksListCall { +func (c *MonetizationOnetimeproductsBatchGetCall) Fields(s ...googleapi.Field) *MonetizationOnetimeproductsBatchGetCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } @@ -14271,34 +17862,34 @@ func (c *GeneratedapksListCall) Fields(s ...googleapi.Field) *GeneratedapksListC // 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 *GeneratedapksListCall) IfNoneMatch(entityTag string) *GeneratedapksListCall { +func (c *MonetizationOnetimeproductsBatchGetCall) IfNoneMatch(entityTag string) *MonetizationOnetimeproductsBatchGetCall { c.ifNoneMatch_ = entityTag return c } // Context sets the context to be used in this call's Do method. -func (c *GeneratedapksListCall) Context(ctx context.Context) *GeneratedapksListCall { +func (c *MonetizationOnetimeproductsBatchGetCall) Context(ctx context.Context) *MonetizationOnetimeproductsBatchGetCall { 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 *GeneratedapksListCall) Header() http.Header { +func (c *MonetizationOnetimeproductsBatchGetCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *GeneratedapksListCall) doRequest(alt string) (*http.Response, error) { +func (c *MonetizationOnetimeproductsBatchGetCall) doRequest(alt string) (*http.Response, error) { reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) if c.ifNoneMatch_ != "" { reqHeaders.Set("If-None-Match", c.ifNoneMatch_) } c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/generatedApks/{versionCode}") + urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/oneTimeProducts:batchGet") urls += "?" + c.urlParams_.Encode() req, err := http.NewRequest("GET", urls, nil) if err != nil { @@ -14307,19 +17898,18 @@ func (c *GeneratedapksListCall) doRequest(alt string) (*http.Response, error) { req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ "packageName": c.packageName, - "versionCode": strconv.FormatInt(c.versionCode, 10), }) - c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.generatedapks.list", "request", internallog.HTTPRequest(req, nil)) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.monetization.onetimeproducts.batchGet", "request", internallog.HTTPRequest(req, nil)) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "androidpublisher.generatedapks.list" call. +// Do executes the "androidpublisher.monetization.onetimeproducts.batchGet" call. // Any non-2xx status code is an error. Response headers are in either -// *GeneratedApksListResponse.ServerResponse.Header or (if a response was +// *BatchGetOneTimeProductsResponse.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 *GeneratedapksListCall) Do(opts ...googleapi.CallOption) (*GeneratedApksListResponse, error) { +func (c *MonetizationOnetimeproductsBatchGetCall) Do(opts ...googleapi.CallOption) (*BatchGetOneTimeProductsResponse, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -14338,7 +17928,7 @@ func (c *GeneratedapksListCall) Do(opts ...googleapi.CallOption) (*GeneratedApks if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &GeneratedApksListResponse{ + ret := &BatchGetOneTimeProductsResponse{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -14349,62 +17939,63 @@ func (c *GeneratedapksListCall) Do(opts ...googleapi.CallOption) (*GeneratedApks if err != nil { return nil, err } - c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.generatedapks.list", "response", internallog.HTTPResponse(res, b)) + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.monetization.onetimeproducts.batchGet", "response", internallog.HTTPResponse(res, b)) return ret, nil } -type GrantsCreateCall struct { - s *Service - parent string - grant *Grant - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +type MonetizationOnetimeproductsBatchUpdateCall struct { + s *Service + packageName string + batchupdateonetimeproductsrequest *BatchUpdateOneTimeProductsRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// Create: Grant access for a user to the given package. +// BatchUpdate: Creates or updates one or more one-time products. // -// - parent: The user which needs permission. Format: -// developers/{developer}/users/{user}. -func (r *GrantsService) Create(parent string, grant *Grant) *GrantsCreateCall { - c := &GrantsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.parent = parent - c.grant = grant +// - packageName: The parent app (package name) for which the one-time products +// should be updated. Must be equal to the package_name field on all the +// OneTimeProduct resources. +func (r *MonetizationOnetimeproductsService) BatchUpdate(packageName string, batchupdateonetimeproductsrequest *BatchUpdateOneTimeProductsRequest) *MonetizationOnetimeproductsBatchUpdateCall { + c := &MonetizationOnetimeproductsBatchUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.packageName = packageName + c.batchupdateonetimeproductsrequest = batchupdateonetimeproductsrequest 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 *GrantsCreateCall) Fields(s ...googleapi.Field) *GrantsCreateCall { +func (c *MonetizationOnetimeproductsBatchUpdateCall) Fields(s ...googleapi.Field) *MonetizationOnetimeproductsBatchUpdateCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } // Context sets the context to be used in this call's Do method. -func (c *GrantsCreateCall) Context(ctx context.Context) *GrantsCreateCall { +func (c *MonetizationOnetimeproductsBatchUpdateCall) Context(ctx context.Context) *MonetizationOnetimeproductsBatchUpdateCall { 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 *GrantsCreateCall) Header() http.Header { +func (c *MonetizationOnetimeproductsBatchUpdateCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *GrantsCreateCall) doRequest(alt string) (*http.Response, error) { +func (c *MonetizationOnetimeproductsBatchUpdateCall) doRequest(alt string) (*http.Response, error) { reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) - body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.grant) + body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.batchupdateonetimeproductsrequest) if err != nil { return nil, err } c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/{+parent}/grants") + urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/oneTimeProducts:batchUpdate") urls += "?" + c.urlParams_.Encode() req, err := http.NewRequest("POST", urls, body) if err != nil { @@ -14412,18 +18003,19 @@ func (c *GrantsCreateCall) doRequest(alt string) (*http.Response, error) { } req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ - "parent": c.parent, + "packageName": c.packageName, }) - c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.grants.create", "request", internallog.HTTPRequest(req, body.Bytes())) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.monetization.onetimeproducts.batchUpdate", "request", internallog.HTTPRequest(req, body.Bytes())) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "androidpublisher.grants.create" call. +// Do executes the "androidpublisher.monetization.onetimeproducts.batchUpdate" call. // Any non-2xx status code is an error. Response headers are in either -// *Grant.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 *GrantsCreateCall) Do(opts ...googleapi.CallOption) (*Grant, error) { +// *BatchUpdateOneTimeProductsResponse.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 *MonetizationOnetimeproductsBatchUpdateCall) Do(opts ...googleapi.CallOption) (*BatchUpdateOneTimeProductsResponse, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -14442,7 +18034,7 @@ func (c *GrantsCreateCall) Do(opts ...googleapi.CallOption) (*Grant, error) { if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &Grant{ + ret := &BatchUpdateOneTimeProductsResponse{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -14453,284 +18045,226 @@ func (c *GrantsCreateCall) Do(opts ...googleapi.CallOption) (*Grant, error) { if err != nil { return nil, err } - c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.grants.create", "response", internallog.HTTPResponse(res, b)) + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.monetization.onetimeproducts.batchUpdate", "response", internallog.HTTPResponse(res, b)) return ret, nil } -type GrantsDeleteCall struct { - s *Service - name string - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +type MonetizationOnetimeproductsDeleteCall struct { + s *Service + packageName string + productId string + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// Delete: Removes all access for the user to the given package or developer -// account. +// Delete: Deletes a one-time product. // -// - name: The name of the grant to delete. Format: -// developers/{developer}/users/{email}/grants/{package_name}. -func (r *GrantsService) Delete(name string) *GrantsDeleteCall { - c := &GrantsDeleteCall{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 *GrantsDeleteCall) Fields(s ...googleapi.Field) *GrantsDeleteCall { - c.urlParams_.Set("fields", googleapi.CombineFields(s)) - return c -} - -// Context sets the context to be used in this call's Do method. -func (c *GrantsDeleteCall) Context(ctx context.Context) *GrantsDeleteCall { - c.ctx_ = ctx +// - packageName: The parent app (package name) of the one-time product to +// delete. +// - productId: The one-time product ID of the one-time product to delete. +func (r *MonetizationOnetimeproductsService) Delete(packageName string, productId string) *MonetizationOnetimeproductsDeleteCall { + c := &MonetizationOnetimeproductsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.packageName = packageName + c.productId = productId return c } -// Header returns a http.Header that can be modified by the caller to add -// headers to the request. -func (c *GrantsDeleteCall) Header() http.Header { - if c.header_ == nil { - c.header_ = make(http.Header) - } - return c.header_ -} - -func (c *GrantsDeleteCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) - c.urlParams_.Set("alt", alt) - c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/{+name}") - urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("DELETE", urls, nil) - if err != nil { - return nil, err - } - req.Header = reqHeaders - googleapi.Expand(req.URL, map[string]string{ - "name": c.name, - }) - c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.grants.delete", "request", internallog.HTTPRequest(req, nil)) - return gensupport.SendRequest(c.ctx_, c.s.client, req) -} - -// Do executes the "androidpublisher.grants.delete" call. -func (c *GrantsDeleteCall) 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) - } - c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.grants.delete", "response", internallog.HTTPResponse(res, nil)) - return nil -} - -type GrantsPatchCall struct { - s *Service - name string - grant *Grant - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header -} - -// Patch: Updates access for the user to the given package. +// LatencyTolerance sets the optional parameter "latencyTolerance": The latency +// tolerance for the propagation of this product update. Defaults to +// latency-sensitive. // -// - name: Resource name for this grant, following the pattern -// "developers/{developer}/users/{email}/grants/{package_name}". If this -// grant is for a draft app, the app ID will be used in this resource name -// instead of the package name. -func (r *GrantsService) Patch(name string, grant *Grant) *GrantsPatchCall { - c := &GrantsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.name = name - c.grant = grant - return c -} - -// UpdateMask sets the optional parameter "updateMask": The list of fields to -// be updated. -func (c *GrantsPatchCall) UpdateMask(updateMask string) *GrantsPatchCall { - c.urlParams_.Set("updateMask", updateMask) +// Possible values: +// +// "PRODUCT_UPDATE_LATENCY_TOLERANCE_UNSPECIFIED" - Defaults to +// +// PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_SENSITIVE. +// +// "PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_SENSITIVE" - The update will +// +// propagate to clients within several minutes on average and up to a few hours +// in rare cases. Throughput is limited to 7,200 updates per app per hour. +// +// "PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_TOLERANT" - The update will +// +// propagate to clients within 24 hours. Supports high throughput of up to +// 720,000 updates per app per hour using batch modification methods. +func (c *MonetizationOnetimeproductsDeleteCall) LatencyTolerance(latencyTolerance string) *MonetizationOnetimeproductsDeleteCall { + c.urlParams_.Set("latencyTolerance", latencyTolerance) 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 *GrantsPatchCall) Fields(s ...googleapi.Field) *GrantsPatchCall { +func (c *MonetizationOnetimeproductsDeleteCall) Fields(s ...googleapi.Field) *MonetizationOnetimeproductsDeleteCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } // Context sets the context to be used in this call's Do method. -func (c *GrantsPatchCall) Context(ctx context.Context) *GrantsPatchCall { +func (c *MonetizationOnetimeproductsDeleteCall) Context(ctx context.Context) *MonetizationOnetimeproductsDeleteCall { 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 *GrantsPatchCall) Header() http.Header { +func (c *MonetizationOnetimeproductsDeleteCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *GrantsPatchCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) - body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.grant) - if err != nil { - return nil, err - } +func (c *MonetizationOnetimeproductsDeleteCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/{+name}") + urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/oneTimeProducts/{productId}") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("PATCH", urls, body) + req, err := http.NewRequest("DELETE", urls, nil) if err != nil { return nil, err } req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ - "name": c.name, + "packageName": c.packageName, + "productId": c.productId, }) - c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.grants.patch", "request", internallog.HTTPRequest(req, body.Bytes())) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.monetization.onetimeproducts.delete", "request", internallog.HTTPRequest(req, nil)) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "androidpublisher.grants.patch" call. -// Any non-2xx status code is an error. Response headers are in either -// *Grant.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 *GrantsPatchCall) Do(opts ...googleapi.CallOption) (*Grant, error) { +// Do executes the "androidpublisher.monetization.onetimeproducts.delete" call. +func (c *MonetizationOnetimeproductsDeleteCall) Do(opts ...googleapi.CallOption) 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 + return err } defer googleapi.CloseBody(res) if err := googleapi.CheckResponse(res); err != nil { - return nil, gensupport.WrapError(err) - } - ret := &Grant{ - ServerResponse: googleapi.ServerResponse{ - Header: res.Header, - HTTPStatusCode: res.StatusCode, - }, - } - target := &ret - b, err := gensupport.DecodeResponseBytes(target, res) - if err != nil { - return nil, err + return gensupport.WrapError(err) } - c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.grants.patch", "response", internallog.HTTPResponse(res, b)) - return ret, nil + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.monetization.onetimeproducts.delete", "response", internallog.HTTPResponse(res, nil)) + return nil } -type InappproductsBatchDeleteCall struct { - s *Service - packageName string - inappproductsbatchdeleterequest *InappproductsBatchDeleteRequest - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +type MonetizationOnetimeproductsGetCall struct { + s *Service + packageName string + productId string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header } -// BatchDelete: Deletes in-app products (managed products or subscriptions). -// Set the latencyTolerance field on nested requests to -// PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_TOLERANT to achieve maximum update -// throughput. This method should not be used to delete subscriptions. See this -// article -// (https://android-developers.googleblog.com/2023/06/changes-to-google-play-developer-api-june-2023.html) -// for more information. +// Get: Reads a single one-time product. // -// - packageName: Package name of the app. -func (r *InappproductsService) BatchDelete(packageName string, inappproductsbatchdeleterequest *InappproductsBatchDeleteRequest) *InappproductsBatchDeleteCall { - c := &InappproductsBatchDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// - packageName: The parent app (package name) of the product to retrieve. +// - productId: The product ID of the product to retrieve. +func (r *MonetizationOnetimeproductsService) Get(packageName string, productId string) *MonetizationOnetimeproductsGetCall { + c := &MonetizationOnetimeproductsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.packageName = packageName - c.inappproductsbatchdeleterequest = inappproductsbatchdeleterequest + c.productId = productId 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 *InappproductsBatchDeleteCall) Fields(s ...googleapi.Field) *InappproductsBatchDeleteCall { +func (c *MonetizationOnetimeproductsGetCall) Fields(s ...googleapi.Field) *MonetizationOnetimeproductsGetCall { 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 *MonetizationOnetimeproductsGetCall) IfNoneMatch(entityTag string) *MonetizationOnetimeproductsGetCall { + c.ifNoneMatch_ = entityTag + return c +} + // Context sets the context to be used in this call's Do method. -func (c *InappproductsBatchDeleteCall) Context(ctx context.Context) *InappproductsBatchDeleteCall { +func (c *MonetizationOnetimeproductsGetCall) Context(ctx context.Context) *MonetizationOnetimeproductsGetCall { 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 *InappproductsBatchDeleteCall) Header() http.Header { +func (c *MonetizationOnetimeproductsGetCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *InappproductsBatchDeleteCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) - body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.inappproductsbatchdeleterequest) - if err != nil { - return nil, err +func (c *MonetizationOnetimeproductsGetCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) } c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/inappproducts:batchDelete") + urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/oneTimeProducts/{productId}") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("POST", urls, body) + req, err := http.NewRequest("GET", urls, nil) if err != nil { return nil, err } req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ "packageName": c.packageName, + "productId": c.productId, }) - c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.inappproducts.batchDelete", "request", internallog.HTTPRequest(req, body.Bytes())) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.monetization.onetimeproducts.get", "request", internallog.HTTPRequest(req, nil)) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "androidpublisher.inappproducts.batchDelete" call. -func (c *InappproductsBatchDeleteCall) Do(opts ...googleapi.CallOption) error { +// Do executes the "androidpublisher.monetization.onetimeproducts.get" call. +// Any non-2xx status code is an error. Response headers are in either +// *OneTimeProduct.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 *MonetizationOnetimeproductsGetCall) Do(opts ...googleapi.CallOption) (*OneTimeProduct, 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 err + return nil, err } defer googleapi.CloseBody(res) if err := googleapi.CheckResponse(res); err != nil { - return gensupport.WrapError(err) + return nil, gensupport.WrapError(err) } - c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.inappproducts.batchDelete", "response", internallog.HTTPResponse(res, nil)) - return nil + ret := &OneTimeProduct{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + b, err := gensupport.DecodeResponseBytes(target, res) + if err != nil { + return nil, err + } + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.monetization.onetimeproducts.get", "response", internallog.HTTPResponse(res, b)) + return ret, nil } -type InappproductsBatchGetCall struct { +type MonetizationOnetimeproductsListCall struct { s *Service packageName string urlParams_ gensupport.URLParams @@ -14739,30 +18273,38 @@ type InappproductsBatchGetCall struct { header_ http.Header } -// BatchGet: Reads multiple in-app products, which can be managed products or -// subscriptions. This method should not be used to retrieve subscriptions. See -// this article -// (https://android-developers.googleblog.com/2023/06/changes-to-google-play-developer-api-june-2023.html) -// for more information. +// List: Lists all one-time products under a given app. // -// - packageName: Package name of the app. -func (r *InappproductsService) BatchGet(packageName string) *InappproductsBatchGetCall { - c := &InappproductsBatchGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// - packageName: The parent app (package name) for which the one-time product +// should be read. +func (r *MonetizationOnetimeproductsService) List(packageName string) *MonetizationOnetimeproductsListCall { + c := &MonetizationOnetimeproductsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.packageName = packageName return c } -// Sku sets the optional parameter "sku": Unique identifier for the in-app -// products. -func (c *InappproductsBatchGetCall) Sku(sku ...string) *InappproductsBatchGetCall { - c.urlParams_.SetMulti("sku", append([]string{}, sku...)) +// PageSize sets the optional parameter "pageSize": The maximum number of +// one-time product to return. The service may return fewer than this value. If +// unspecified, at most 50 one-time products will be returned. The maximum +// value is 1000; values above 1000 will be coerced to 1000. +func (c *MonetizationOnetimeproductsListCall) PageSize(pageSize int64) *MonetizationOnetimeproductsListCall { + c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) + return c +} + +// PageToken sets the optional parameter "pageToken": A page token, received +// from a previous `ListOneTimeProducts` call. Provide this to retrieve the +// subsequent page. When paginating, all other parameters provided to +// `ListOneTimeProducts` must match the call that provided the page token. +func (c *MonetizationOnetimeproductsListCall) PageToken(pageToken string) *MonetizationOnetimeproductsListCall { + 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 *InappproductsBatchGetCall) Fields(s ...googleapi.Field) *InappproductsBatchGetCall { +func (c *MonetizationOnetimeproductsListCall) Fields(s ...googleapi.Field) *MonetizationOnetimeproductsListCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } @@ -14770,34 +18312,34 @@ func (c *InappproductsBatchGetCall) Fields(s ...googleapi.Field) *InappproductsB // 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 *InappproductsBatchGetCall) IfNoneMatch(entityTag string) *InappproductsBatchGetCall { +func (c *MonetizationOnetimeproductsListCall) IfNoneMatch(entityTag string) *MonetizationOnetimeproductsListCall { c.ifNoneMatch_ = entityTag return c } // Context sets the context to be used in this call's Do method. -func (c *InappproductsBatchGetCall) Context(ctx context.Context) *InappproductsBatchGetCall { +func (c *MonetizationOnetimeproductsListCall) Context(ctx context.Context) *MonetizationOnetimeproductsListCall { 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 *InappproductsBatchGetCall) Header() http.Header { +func (c *MonetizationOnetimeproductsListCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *InappproductsBatchGetCall) doRequest(alt string) (*http.Response, error) { +func (c *MonetizationOnetimeproductsListCall) doRequest(alt string) (*http.Response, error) { reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) if c.ifNoneMatch_ != "" { reqHeaders.Set("If-None-Match", c.ifNoneMatch_) } c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/inappproducts:batchGet") + urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/oneTimeProducts") urls += "?" + c.urlParams_.Encode() req, err := http.NewRequest("GET", urls, nil) if err != nil { @@ -14807,17 +18349,17 @@ func (c *InappproductsBatchGetCall) doRequest(alt string) (*http.Response, error googleapi.Expand(req.URL, map[string]string{ "packageName": c.packageName, }) - c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.inappproducts.batchGet", "request", internallog.HTTPRequest(req, nil)) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.monetization.onetimeproducts.list", "request", internallog.HTTPRequest(req, nil)) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "androidpublisher.inappproducts.batchGet" call. +// Do executes the "androidpublisher.monetization.onetimeproducts.list" call. // Any non-2xx status code is an error. Response headers are in either -// *InappproductsBatchGetResponse.ServerResponse.Header or (if a response was +// *ListOneTimeProductsResponse.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 *InappproductsBatchGetCall) Do(opts ...googleapi.CallOption) (*InappproductsBatchGetResponse, error) { +func (c *MonetizationOnetimeproductsListCall) Do(opts ...googleapi.CallOption) (*ListOneTimeProductsResponse, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -14836,7 +18378,7 @@ func (c *InappproductsBatchGetCall) Do(opts ...googleapi.CallOption) (*Inappprod if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &InappproductsBatchGetResponse{ + ret := &ListOneTimeProductsResponse{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -14847,87 +18389,163 @@ func (c *InappproductsBatchGetCall) Do(opts ...googleapi.CallOption) (*Inappprod if err != nil { return nil, err } - c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.inappproducts.batchGet", "response", internallog.HTTPResponse(res, b)) + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.monetization.onetimeproducts.list", "response", internallog.HTTPResponse(res, b)) return ret, nil } -type InappproductsBatchUpdateCall struct { - s *Service - packageName string - inappproductsbatchupdaterequest *InappproductsBatchUpdateRequest - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +// 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 *MonetizationOnetimeproductsListCall) Pages(ctx context.Context, f func(*ListOneTimeProductsResponse) 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) + } } -// BatchUpdate: Updates or inserts one or more in-app products (managed -// products or subscriptions). Set the latencyTolerance field on nested -// requests to PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_TOLERANT to achieve -// maximum update throughput. This method should no longer be used to update -// subscriptions. See this article -// (https://android-developers.googleblog.com/2023/06/changes-to-google-play-developer-api-june-2023.html) -// for more information. +type MonetizationOnetimeproductsPatchCall struct { + s *Service + packageName string + productId string + onetimeproduct *OneTimeProduct + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Patch: Creates or updates a one-time product. // -// - packageName: Package name of the app. -func (r *InappproductsService) BatchUpdate(packageName string, inappproductsbatchupdaterequest *InappproductsBatchUpdateRequest) *InappproductsBatchUpdateCall { - c := &InappproductsBatchUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// - packageName: Immutable. Package name of the parent app. +// - productId: Immutable. Unique product ID of the product. Unique within the +// parent app. Product IDs must start with a number or lowercase letter, and +// can contain numbers (0-9), lowercase letters (a-z), underscores (_), and +// periods (.). +func (r *MonetizationOnetimeproductsService) Patch(packageName string, productId string, onetimeproduct *OneTimeProduct) *MonetizationOnetimeproductsPatchCall { + c := &MonetizationOnetimeproductsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.packageName = packageName - c.inappproductsbatchupdaterequest = inappproductsbatchupdaterequest + c.productId = productId + c.onetimeproduct = onetimeproduct + return c +} + +// AllowMissing sets the optional parameter "allowMissing": If set to true, and +// the one-time product with the given package_name and product_id doesn't +// exist, the one-time product will be created. If a new one-time product is +// created, update_mask is ignored. +func (c *MonetizationOnetimeproductsPatchCall) AllowMissing(allowMissing bool) *MonetizationOnetimeproductsPatchCall { + c.urlParams_.Set("allowMissing", fmt.Sprint(allowMissing)) + return c +} + +// LatencyTolerance sets the optional parameter "latencyTolerance": The latency +// tolerance for the propagation of this product upsert. Defaults to +// latency-sensitive. +// +// Possible values: +// +// "PRODUCT_UPDATE_LATENCY_TOLERANCE_UNSPECIFIED" - Defaults to +// +// PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_SENSITIVE. +// +// "PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_SENSITIVE" - The update will +// +// propagate to clients within several minutes on average and up to a few hours +// in rare cases. Throughput is limited to 7,200 updates per app per hour. +// +// "PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_TOLERANT" - The update will +// +// propagate to clients within 24 hours. Supports high throughput of up to +// 720,000 updates per app per hour using batch modification methods. +func (c *MonetizationOnetimeproductsPatchCall) LatencyTolerance(latencyTolerance string) *MonetizationOnetimeproductsPatchCall { + c.urlParams_.Set("latencyTolerance", latencyTolerance) + return c +} + +// RegionsVersionVersion sets the optional parameter "regionsVersion.version": +// Required. A string representing the version of available regions being used +// for the specified resource. Regional prices and latest supported version for +// the resource have to be specified according to the information published in +// this article +// (https://support.google.com/googleplay/android-developer/answer/10532353). +// Each time the supported locations substantially change, the version will be +// incremented. Using this field will ensure that creating and updating the +// resource with an older region's version and set of regional prices and +// currencies will succeed even though a new version is available. +func (c *MonetizationOnetimeproductsPatchCall) RegionsVersionVersion(regionsVersionVersion string) *MonetizationOnetimeproductsPatchCall { + c.urlParams_.Set("regionsVersion.version", regionsVersionVersion) + return c +} + +// UpdateMask sets the optional parameter "updateMask": Required. The list of +// fields to be updated. +func (c *MonetizationOnetimeproductsPatchCall) UpdateMask(updateMask string) *MonetizationOnetimeproductsPatchCall { + 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 *InappproductsBatchUpdateCall) Fields(s ...googleapi.Field) *InappproductsBatchUpdateCall { +func (c *MonetizationOnetimeproductsPatchCall) Fields(s ...googleapi.Field) *MonetizationOnetimeproductsPatchCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } // Context sets the context to be used in this call's Do method. -func (c *InappproductsBatchUpdateCall) Context(ctx context.Context) *InappproductsBatchUpdateCall { +func (c *MonetizationOnetimeproductsPatchCall) Context(ctx context.Context) *MonetizationOnetimeproductsPatchCall { 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 *InappproductsBatchUpdateCall) Header() http.Header { +func (c *MonetizationOnetimeproductsPatchCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *InappproductsBatchUpdateCall) doRequest(alt string) (*http.Response, error) { +func (c *MonetizationOnetimeproductsPatchCall) doRequest(alt string) (*http.Response, error) { reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) - body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.inappproductsbatchupdaterequest) + body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.onetimeproduct) if err != nil { return nil, err } c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/inappproducts:batchUpdate") + urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/onetimeproducts/{productId}") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("POST", urls, body) + req, err := http.NewRequest("PATCH", urls, body) if err != nil { return nil, err } req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ "packageName": c.packageName, + "productId": c.productId, }) - c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.inappproducts.batchUpdate", "request", internallog.HTTPRequest(req, body.Bytes())) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.monetization.onetimeproducts.patch", "request", internallog.HTTPRequest(req, body.Bytes())) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "androidpublisher.inappproducts.batchUpdate" call. +// Do executes the "androidpublisher.monetization.onetimeproducts.patch" call. // Any non-2xx status code is an error. Response headers are in either -// *InappproductsBatchUpdateResponse.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 *InappproductsBatchUpdateCall) Do(opts ...googleapi.CallOption) (*InappproductsBatchUpdateResponse, error) { +// *OneTimeProduct.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 *MonetizationOnetimeproductsPatchCall) Do(opts ...googleapi.CallOption) (*OneTimeProduct, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -14946,7 +18564,7 @@ func (c *InappproductsBatchUpdateCall) Do(opts ...googleapi.CallOption) (*Inappp if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &InappproductsBatchUpdateResponse{ + ret := &OneTimeProduct{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -14957,102 +18575,86 @@ func (c *InappproductsBatchUpdateCall) Do(opts ...googleapi.CallOption) (*Inappp if err != nil { return nil, err } - c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.inappproducts.batchUpdate", "response", internallog.HTTPResponse(res, b)) + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.monetization.onetimeproducts.patch", "response", internallog.HTTPResponse(res, b)) return ret, nil } -type InappproductsDeleteCall struct { - s *Service - packageName string - skuid string - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +type MonetizationOnetimeproductsPurchaseOptionsBatchDeleteCall struct { + s *Service + packageName string + productId string + batchdeletepurchaseoptionsrequest *BatchDeletePurchaseOptionsRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// Delete: Deletes an in-app product (a managed product or a subscription). -// This method should no longer be used to delete subscriptions. See this -// article -// (https://android-developers.googleblog.com/2023/06/changes-to-google-play-developer-api-june-2023.html) -// for more information. +// BatchDelete: Deletes purchase options across one or multiple one-time +// products. By default this operation will fail if there are any existing +// offers under the deleted purchase options. Use the force parameter to +// override the default behavior. // -// - packageName: Package name of the app. -// - sku: Unique identifier for the in-app product. -func (r *InappproductsService) Delete(packageName string, skuid string) *InappproductsDeleteCall { - c := &InappproductsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// - packageName: The parent app (package name) of the purchase options to +// delete. +// - productId: The product ID of the parent one-time product, if all purchase +// options to delete belong to the same one-time product. If this batch +// delete spans multiple one-time products, set this field to "-". +func (r *MonetizationOnetimeproductsPurchaseOptionsService) BatchDelete(packageName string, productId string, batchdeletepurchaseoptionsrequest *BatchDeletePurchaseOptionsRequest) *MonetizationOnetimeproductsPurchaseOptionsBatchDeleteCall { + c := &MonetizationOnetimeproductsPurchaseOptionsBatchDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.packageName = packageName - c.skuid = skuid - return c -} - -// LatencyTolerance sets the optional parameter "latencyTolerance": The latency -// tolerance for the propagation of this product update. Defaults to -// latency-sensitive. -// -// Possible values: -// -// "PRODUCT_UPDATE_LATENCY_TOLERANCE_UNSPECIFIED" - Defaults to -// -// PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_SENSITIVE. -// -// "PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_SENSITIVE" - The update will -// -// propagate to clients within several minutes on average and up to a few hours -// in rare cases. Throughput is limited to 7,200 updates per app per hour. -// -// "PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_TOLERANT" - The update will -// -// propagate to clients within 24 hours. Supports high throughput of up to -// 720,000 updates per app per hour using batch modification methods. -func (c *InappproductsDeleteCall) LatencyTolerance(latencyTolerance string) *InappproductsDeleteCall { - c.urlParams_.Set("latencyTolerance", latencyTolerance) + c.productId = productId + c.batchdeletepurchaseoptionsrequest = batchdeletepurchaseoptionsrequest 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 *InappproductsDeleteCall) Fields(s ...googleapi.Field) *InappproductsDeleteCall { +func (c *MonetizationOnetimeproductsPurchaseOptionsBatchDeleteCall) Fields(s ...googleapi.Field) *MonetizationOnetimeproductsPurchaseOptionsBatchDeleteCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } // Context sets the context to be used in this call's Do method. -func (c *InappproductsDeleteCall) Context(ctx context.Context) *InappproductsDeleteCall { +func (c *MonetizationOnetimeproductsPurchaseOptionsBatchDeleteCall) Context(ctx context.Context) *MonetizationOnetimeproductsPurchaseOptionsBatchDeleteCall { 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 *InappproductsDeleteCall) Header() http.Header { +func (c *MonetizationOnetimeproductsPurchaseOptionsBatchDeleteCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *InappproductsDeleteCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) +func (c *MonetizationOnetimeproductsPurchaseOptionsBatchDeleteCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) + body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.batchdeletepurchaseoptionsrequest) + if err != nil { + return nil, err + } c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/inappproducts/{sku}") + urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/oneTimeProducts/{productId}/purchaseOptions:batchDelete") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("DELETE", urls, nil) + req, err := http.NewRequest("POST", urls, body) if err != nil { return nil, err } req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ "packageName": c.packageName, - "sku": c.skuid, + "productId": c.productId, }) - c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.inappproducts.delete", "request", internallog.HTTPRequest(req, nil)) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.monetization.onetimeproducts.purchaseOptions.batchDelete", "request", internallog.HTTPRequest(req, body.Bytes())) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "androidpublisher.inappproducts.delete" call. -func (c *InappproductsDeleteCall) Do(opts ...googleapi.CallOption) error { +// Do executes the "androidpublisher.monetization.onetimeproducts.purchaseOptions.batchDelete" call. +func (c *MonetizationOnetimeproductsPurchaseOptionsBatchDeleteCall) Do(opts ...googleapi.CallOption) error { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if err != nil { @@ -15062,94 +18664,89 @@ func (c *InappproductsDeleteCall) Do(opts ...googleapi.CallOption) error { if err := googleapi.CheckResponse(res); err != nil { return gensupport.WrapError(err) } - c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.inappproducts.delete", "response", internallog.HTTPResponse(res, nil)) + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.monetization.onetimeproducts.purchaseOptions.batchDelete", "response", internallog.HTTPResponse(res, nil)) return nil } -type InappproductsGetCall struct { - s *Service - packageName string - skuid string - urlParams_ gensupport.URLParams - ifNoneMatch_ string - ctx_ context.Context - header_ http.Header +type MonetizationOnetimeproductsPurchaseOptionsBatchUpdateStatesCall struct { + s *Service + packageName string + productId string + batchupdatepurchaseoptionstatesrequest *BatchUpdatePurchaseOptionStatesRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// Get: Gets an in-app product, which can be a managed product or a -// subscription. This method should no longer be used to retrieve -// subscriptions. See this article -// (https://android-developers.googleblog.com/2023/06/changes-to-google-play-developer-api-june-2023.html) -// for more information. +// BatchUpdateStates: Activates or deactivates purchase options across one or +// multiple one-time products. // -// - packageName: Package name of the app. -// - sku: Unique identifier for the in-app product. -func (r *InappproductsService) Get(packageName string, skuid string) *InappproductsGetCall { - c := &InappproductsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// - packageName: The parent app (package name) of the updated purchase +// options. +// - productId: The product ID of the parent one-time product, if all updated +// purchase options belong to the same one-time product. If this batch update +// spans multiple one-time products, set this field to "-". +func (r *MonetizationOnetimeproductsPurchaseOptionsService) BatchUpdateStates(packageName string, productId string, batchupdatepurchaseoptionstatesrequest *BatchUpdatePurchaseOptionStatesRequest) *MonetizationOnetimeproductsPurchaseOptionsBatchUpdateStatesCall { + c := &MonetizationOnetimeproductsPurchaseOptionsBatchUpdateStatesCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.packageName = packageName - c.skuid = skuid + c.productId = productId + c.batchupdatepurchaseoptionstatesrequest = batchupdatepurchaseoptionstatesrequest 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 *InappproductsGetCall) Fields(s ...googleapi.Field) *InappproductsGetCall { +func (c *MonetizationOnetimeproductsPurchaseOptionsBatchUpdateStatesCall) Fields(s ...googleapi.Field) *MonetizationOnetimeproductsPurchaseOptionsBatchUpdateStatesCall { 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 *InappproductsGetCall) IfNoneMatch(entityTag string) *InappproductsGetCall { - c.ifNoneMatch_ = entityTag - return c -} - // Context sets the context to be used in this call's Do method. -func (c *InappproductsGetCall) Context(ctx context.Context) *InappproductsGetCall { +func (c *MonetizationOnetimeproductsPurchaseOptionsBatchUpdateStatesCall) Context(ctx context.Context) *MonetizationOnetimeproductsPurchaseOptionsBatchUpdateStatesCall { 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 *InappproductsGetCall) Header() http.Header { +func (c *MonetizationOnetimeproductsPurchaseOptionsBatchUpdateStatesCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *InappproductsGetCall) 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 *MonetizationOnetimeproductsPurchaseOptionsBatchUpdateStatesCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) + body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.batchupdatepurchaseoptionstatesrequest) + if err != nil { + return nil, err } c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/inappproducts/{sku}") + urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/oneTimeProducts/{productId}/purchaseOptions:batchUpdateStates") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("GET", urls, nil) + req, err := http.NewRequest("POST", urls, body) if err != nil { return nil, err } req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ "packageName": c.packageName, - "sku": c.skuid, + "productId": c.productId, }) - c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.inappproducts.get", "request", internallog.HTTPRequest(req, nil)) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.monetization.onetimeproducts.purchaseOptions.batchUpdateStates", "request", internallog.HTTPRequest(req, body.Bytes())) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "androidpublisher.inappproducts.get" call. +// Do executes the "androidpublisher.monetization.onetimeproducts.purchaseOptions.batchUpdateStates" call. // Any non-2xx status code is an error. Response headers are in either -// *InAppProduct.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 *InappproductsGetCall) Do(opts ...googleapi.CallOption) (*InAppProduct, error) { +// *BatchUpdatePurchaseOptionStatesResponse.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 *MonetizationOnetimeproductsPurchaseOptionsBatchUpdateStatesCall) Do(opts ...googleapi.CallOption) (*BatchUpdatePurchaseOptionStatesResponse, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -15168,7 +18765,7 @@ func (c *InappproductsGetCall) Do(opts ...googleapi.CallOption) (*InAppProduct, if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &InAppProduct{ + ret := &BatchUpdatePurchaseOptionStatesResponse{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -15179,75 +18776,71 @@ func (c *InappproductsGetCall) Do(opts ...googleapi.CallOption) (*InAppProduct, if err != nil { return nil, err } - c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.inappproducts.get", "response", internallog.HTTPResponse(res, b)) + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.monetization.onetimeproducts.purchaseOptions.batchUpdateStates", "response", internallog.HTTPResponse(res, b)) return ret, nil } -type InappproductsInsertCall struct { - s *Service - packageName string - inappproduct *InAppProduct - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +type MonetizationOnetimeproductsPurchaseOptionsOffersActivateCall struct { + s *Service + packageName string + productId string + purchaseOptionId string + offerId string + activateonetimeproductofferrequest *ActivateOneTimeProductOfferRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// Insert: Creates an in-app product (a managed product or a subscription). -// This method should no longer be used to create subscriptions. See this -// article -// (https://android-developers.googleblog.com/2023/06/changes-to-google-play-developer-api-june-2023.html) -// for more information. +// Activate: Activates a one-time product offer. // -// - packageName: Package name of the app. -func (r *InappproductsService) Insert(packageName string, inappproduct *InAppProduct) *InappproductsInsertCall { - c := &InappproductsInsertCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// - offerId: The offer ID of the offer to activate. +// - packageName: The parent app (package name) of the offer to activate. +// - productId: The parent one-time product (ID) of the offer to activate. +// - purchaseOptionId: The parent purchase option (ID) of the offer to +// activate. +func (r *MonetizationOnetimeproductsPurchaseOptionsOffersService) Activate(packageName string, productId string, purchaseOptionId string, offerId string, activateonetimeproductofferrequest *ActivateOneTimeProductOfferRequest) *MonetizationOnetimeproductsPurchaseOptionsOffersActivateCall { + c := &MonetizationOnetimeproductsPurchaseOptionsOffersActivateCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.packageName = packageName - c.inappproduct = inappproduct - return c -} - -// AutoConvertMissingPrices sets the optional parameter -// "autoConvertMissingPrices": If true the prices for all regions targeted by -// the parent app that don't have a price specified for this in-app product -// will be auto converted to the target currency based on the default price. -// Defaults to false. -func (c *InappproductsInsertCall) AutoConvertMissingPrices(autoConvertMissingPrices bool) *InappproductsInsertCall { - c.urlParams_.Set("autoConvertMissingPrices", fmt.Sprint(autoConvertMissingPrices)) + c.productId = productId + c.purchaseOptionId = purchaseOptionId + c.offerId = offerId + c.activateonetimeproductofferrequest = activateonetimeproductofferrequest 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 *InappproductsInsertCall) Fields(s ...googleapi.Field) *InappproductsInsertCall { +func (c *MonetizationOnetimeproductsPurchaseOptionsOffersActivateCall) Fields(s ...googleapi.Field) *MonetizationOnetimeproductsPurchaseOptionsOffersActivateCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } // Context sets the context to be used in this call's Do method. -func (c *InappproductsInsertCall) Context(ctx context.Context) *InappproductsInsertCall { +func (c *MonetizationOnetimeproductsPurchaseOptionsOffersActivateCall) Context(ctx context.Context) *MonetizationOnetimeproductsPurchaseOptionsOffersActivateCall { 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 *InappproductsInsertCall) Header() http.Header { +func (c *MonetizationOnetimeproductsPurchaseOptionsOffersActivateCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *InappproductsInsertCall) doRequest(alt string) (*http.Response, error) { +func (c *MonetizationOnetimeproductsPurchaseOptionsOffersActivateCall) doRequest(alt string) (*http.Response, error) { reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) - body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.inappproduct) + body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.activateonetimeproductofferrequest) if err != nil { return nil, err } c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/inappproducts") + urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/oneTimeProducts/{productId}/purchaseOptions/{purchaseOptionId}/offers/{offerId}:activate") urls += "?" + c.urlParams_.Encode() req, err := http.NewRequest("POST", urls, body) if err != nil { @@ -15255,18 +18848,22 @@ func (c *InappproductsInsertCall) doRequest(alt string) (*http.Response, error) } req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ - "packageName": c.packageName, + "packageName": c.packageName, + "productId": c.productId, + "purchaseOptionId": c.purchaseOptionId, + "offerId": c.offerId, }) - c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.inappproducts.insert", "request", internallog.HTTPRequest(req, body.Bytes())) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.monetization.onetimeproducts.purchaseOptions.offers.activate", "request", internallog.HTTPRequest(req, body.Bytes())) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "androidpublisher.inappproducts.insert" call. +// Do executes the "androidpublisher.monetization.onetimeproducts.purchaseOptions.offers.activate" call. // Any non-2xx status code is an error. Response headers are in either -// *InAppProduct.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 *InappproductsInsertCall) Do(opts ...googleapi.CallOption) (*InAppProduct, error) { +// *OneTimeProductOffer.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 *MonetizationOnetimeproductsPurchaseOptionsOffersActivateCall) Do(opts ...googleapi.CallOption) (*OneTimeProductOffer, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -15285,7 +18882,7 @@ func (c *InappproductsInsertCall) Do(opts ...googleapi.CallOption) (*InAppProduc if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &InAppProduct{ + ret := &OneTimeProductOffer{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -15296,115 +18893,188 @@ func (c *InappproductsInsertCall) Do(opts ...googleapi.CallOption) (*InAppProduc if err != nil { return nil, err } - c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.inappproducts.insert", "response", internallog.HTTPResponse(res, b)) + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.monetization.onetimeproducts.purchaseOptions.offers.activate", "response", internallog.HTTPResponse(res, b)) return ret, nil } -type InappproductsListCall struct { - s *Service - packageName string - urlParams_ gensupport.URLParams - ifNoneMatch_ string - ctx_ context.Context - header_ http.Header +type MonetizationOnetimeproductsPurchaseOptionsOffersBatchDeleteCall struct { + s *Service + packageName string + productId string + purchaseOptionId string + batchdeleteonetimeproductoffersrequest *BatchDeleteOneTimeProductOffersRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// List: Lists all in-app products - both managed products and subscriptions. -// If an app has a large number of in-app products, the response may be -// paginated. In this case the response field `tokenPagination.nextPageToken` -// will be set and the caller should provide its value as a `token` request -// parameter to retrieve the next page. This method should no longer be used to -// retrieve subscriptions. See this article -// (https://android-developers.googleblog.com/2023/06/changes-to-google-play-developer-api-june-2023.html) -// for more information. +// BatchDelete: Deletes one or more one-time product offers. // -// - packageName: Package name of the app. -func (r *InappproductsService) List(packageName string) *InappproductsListCall { - c := &InappproductsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// - packageName: The parent app (package name) of the offers to delete. Must +// be equal to the package_name field on all the OneTimeProductOffer +// resources. +// - productId: The product ID of the parent one-time product, if all offers to +// delete belong to the same product. If this request spans multiple one-time +// products, set this field to "-". +// - purchaseOptionId: The parent purchase option (ID) for which the offers +// should be deleted. May be specified as '-' to update offers from multiple +// purchase options. +func (r *MonetizationOnetimeproductsPurchaseOptionsOffersService) BatchDelete(packageName string, productId string, purchaseOptionId string, batchdeleteonetimeproductoffersrequest *BatchDeleteOneTimeProductOffersRequest) *MonetizationOnetimeproductsPurchaseOptionsOffersBatchDeleteCall { + c := &MonetizationOnetimeproductsPurchaseOptionsOffersBatchDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.packageName = packageName + c.productId = productId + c.purchaseOptionId = purchaseOptionId + c.batchdeleteonetimeproductoffersrequest = batchdeleteonetimeproductoffersrequest return c } -// MaxResults sets the optional parameter "maxResults": Deprecated and ignored. -// The page size is determined by the server. -func (c *InappproductsListCall) MaxResults(maxResults int64) *InappproductsListCall { - c.urlParams_.Set("maxResults", fmt.Sprint(maxResults)) +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. +func (c *MonetizationOnetimeproductsPurchaseOptionsOffersBatchDeleteCall) Fields(s ...googleapi.Field) *MonetizationOnetimeproductsPurchaseOptionsOffersBatchDeleteCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *MonetizationOnetimeproductsPurchaseOptionsOffersBatchDeleteCall) Context(ctx context.Context) *MonetizationOnetimeproductsPurchaseOptionsOffersBatchDeleteCall { + c.ctx_ = ctx return c } -// StartIndex sets the optional parameter "startIndex": Deprecated and ignored. -// Set the `token` parameter to retrieve the next page. -func (c *InappproductsListCall) StartIndex(startIndex int64) *InappproductsListCall { - c.urlParams_.Set("startIndex", fmt.Sprint(startIndex)) - return c +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. +func (c *MonetizationOnetimeproductsPurchaseOptionsOffersBatchDeleteCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *MonetizationOnetimeproductsPurchaseOptionsOffersBatchDeleteCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) + body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.batchdeleteonetimeproductoffersrequest) + if err != nil { + return nil, err + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/oneTimeProducts/{productId}/purchaseOptions/{purchaseOptionId}/offers:batchDelete") + 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{ + "packageName": c.packageName, + "productId": c.productId, + "purchaseOptionId": c.purchaseOptionId, + }) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.monetization.onetimeproducts.purchaseOptions.offers.batchDelete", "request", internallog.HTTPRequest(req, body.Bytes())) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "androidpublisher.monetization.onetimeproducts.purchaseOptions.offers.batchDelete" call. +func (c *MonetizationOnetimeproductsPurchaseOptionsOffersBatchDeleteCall) 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) + } + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.monetization.onetimeproducts.purchaseOptions.offers.batchDelete", "response", internallog.HTTPResponse(res, nil)) + return nil +} + +type MonetizationOnetimeproductsPurchaseOptionsOffersBatchGetCall struct { + s *Service + packageName string + productId string + purchaseOptionId string + batchgetonetimeproductoffersrequest *BatchGetOneTimeProductOffersRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// Token sets the optional parameter "token": Pagination token. If empty, list -// starts at the first product. -func (c *InappproductsListCall) Token(token string) *InappproductsListCall { - c.urlParams_.Set("token", token) +// BatchGet: Reads one or more one-time product offers. +// +// - packageName: The parent app (package name) of the updated offers. Must be +// equal to the package_name field on all the updated OneTimeProductOffer +// resources. +// - productId: The product ID of the parent one-time product, if all updated +// offers belong to the same product. If this request spans multiple one-time +// products, set this field to "-". +// - purchaseOptionId: The parent purchase option (ID) for which the offers +// should be updated. May be specified as '-' to update offers from multiple +// purchase options. +func (r *MonetizationOnetimeproductsPurchaseOptionsOffersService) BatchGet(packageName string, productId string, purchaseOptionId string, batchgetonetimeproductoffersrequest *BatchGetOneTimeProductOffersRequest) *MonetizationOnetimeproductsPurchaseOptionsOffersBatchGetCall { + c := &MonetizationOnetimeproductsPurchaseOptionsOffersBatchGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.packageName = packageName + c.productId = productId + c.purchaseOptionId = purchaseOptionId + c.batchgetonetimeproductoffersrequest = batchgetonetimeproductoffersrequest 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 *InappproductsListCall) Fields(s ...googleapi.Field) *InappproductsListCall { +func (c *MonetizationOnetimeproductsPurchaseOptionsOffersBatchGetCall) Fields(s ...googleapi.Field) *MonetizationOnetimeproductsPurchaseOptionsOffersBatchGetCall { 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 *InappproductsListCall) IfNoneMatch(entityTag string) *InappproductsListCall { - c.ifNoneMatch_ = entityTag - return c -} - // Context sets the context to be used in this call's Do method. -func (c *InappproductsListCall) Context(ctx context.Context) *InappproductsListCall { +func (c *MonetizationOnetimeproductsPurchaseOptionsOffersBatchGetCall) Context(ctx context.Context) *MonetizationOnetimeproductsPurchaseOptionsOffersBatchGetCall { 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 *InappproductsListCall) Header() http.Header { +func (c *MonetizationOnetimeproductsPurchaseOptionsOffersBatchGetCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *InappproductsListCall) 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 *MonetizationOnetimeproductsPurchaseOptionsOffersBatchGetCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) + body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.batchgetonetimeproductoffersrequest) + if err != nil { + return nil, err } c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/inappproducts") + urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/oneTimeProducts/{productId}/purchaseOptions/{purchaseOptionId}/offers:batchGet") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("GET", urls, nil) + req, err := http.NewRequest("POST", urls, body) if err != nil { return nil, err } req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ - "packageName": c.packageName, + "packageName": c.packageName, + "productId": c.productId, + "purchaseOptionId": c.purchaseOptionId, }) - c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.inappproducts.list", "request", internallog.HTTPRequest(req, nil)) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.monetization.onetimeproducts.purchaseOptions.offers.batchGet", "request", internallog.HTTPRequest(req, body.Bytes())) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "androidpublisher.inappproducts.list" call. +// Do executes the "androidpublisher.monetization.onetimeproducts.purchaseOptions.offers.batchGet" call. // Any non-2xx status code is an error. Response headers are in either -// *InappproductsListResponse.ServerResponse.Header or (if a response was -// returned at all) in error.(*googleapi.Error).Header. Use +// *BatchGetOneTimeProductOffersResponse.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 *InappproductsListCall) Do(opts ...googleapi.CallOption) (*InappproductsListResponse, error) { +func (c *MonetizationOnetimeproductsPurchaseOptionsOffersBatchGetCall) Do(opts ...googleapi.CallOption) (*BatchGetOneTimeProductOffersResponse, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -15423,7 +19093,7 @@ func (c *InappproductsListCall) Do(opts ...googleapi.CallOption) (*Inappproducts if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &InappproductsListResponse{ + ret := &BatchGetOneTimeProductOffersResponse{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -15434,121 +19104,95 @@ func (c *InappproductsListCall) Do(opts ...googleapi.CallOption) (*Inappproducts if err != nil { return nil, err } - c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.inappproducts.list", "response", internallog.HTTPResponse(res, b)) + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.monetization.onetimeproducts.purchaseOptions.offers.batchGet", "response", internallog.HTTPResponse(res, b)) return ret, nil } -type InappproductsPatchCall struct { - s *Service - packageName string - skuid string - inappproduct *InAppProduct - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +type MonetizationOnetimeproductsPurchaseOptionsOffersBatchUpdateCall struct { + s *Service + packageName string + productId string + purchaseOptionId string + batchupdateonetimeproductoffersrequest *BatchUpdateOneTimeProductOffersRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// Patch: Patches an in-app product (a managed product or a subscription). This -// method should no longer be used to update subscriptions. See this article -// (https://android-developers.googleblog.com/2023/06/changes-to-google-play-developer-api-june-2023.html) -// for more information. +// BatchUpdate: Creates or updates one or more one-time product offers. // -// - packageName: Package name of the app. -// - sku: Unique identifier for the in-app product. -func (r *InappproductsService) Patch(packageName string, skuid string, inappproduct *InAppProduct) *InappproductsPatchCall { - c := &InappproductsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// - packageName: The parent app (package name) of the updated offers. Must be +// equal to the package_name field on all the updated OneTimeProductOffer +// resources. +// - productId: The product ID of the parent one-time product, if all updated +// offers belong to the same product. If this request spans multiple one-time +// products, set this field to "-". +// - purchaseOptionId: The parent purchase option (ID) for which the offers +// should be updated. May be specified as '-' to update offers from multiple +// purchase options. +func (r *MonetizationOnetimeproductsPurchaseOptionsOffersService) BatchUpdate(packageName string, productId string, purchaseOptionId string, batchupdateonetimeproductoffersrequest *BatchUpdateOneTimeProductOffersRequest) *MonetizationOnetimeproductsPurchaseOptionsOffersBatchUpdateCall { + c := &MonetizationOnetimeproductsPurchaseOptionsOffersBatchUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.packageName = packageName - c.skuid = skuid - c.inappproduct = inappproduct - return c -} - -// AutoConvertMissingPrices sets the optional parameter -// "autoConvertMissingPrices": If true the prices for all regions targeted by -// the parent app that don't have a price specified for this in-app product -// will be auto converted to the target currency based on the default price. -// Defaults to false. -func (c *InappproductsPatchCall) AutoConvertMissingPrices(autoConvertMissingPrices bool) *InappproductsPatchCall { - c.urlParams_.Set("autoConvertMissingPrices", fmt.Sprint(autoConvertMissingPrices)) - return c -} - -// LatencyTolerance sets the optional parameter "latencyTolerance": The latency -// tolerance for the propagation of this product update. Defaults to -// latency-sensitive. -// -// Possible values: -// -// "PRODUCT_UPDATE_LATENCY_TOLERANCE_UNSPECIFIED" - Defaults to -// -// PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_SENSITIVE. -// -// "PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_SENSITIVE" - The update will -// -// propagate to clients within several minutes on average and up to a few hours -// in rare cases. Throughput is limited to 7,200 updates per app per hour. -// -// "PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_TOLERANT" - The update will -// -// propagate to clients within 24 hours. Supports high throughput of up to -// 720,000 updates per app per hour using batch modification methods. -func (c *InappproductsPatchCall) LatencyTolerance(latencyTolerance string) *InappproductsPatchCall { - c.urlParams_.Set("latencyTolerance", latencyTolerance) + c.productId = productId + c.purchaseOptionId = purchaseOptionId + c.batchupdateonetimeproductoffersrequest = batchupdateonetimeproductoffersrequest 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 *InappproductsPatchCall) Fields(s ...googleapi.Field) *InappproductsPatchCall { +func (c *MonetizationOnetimeproductsPurchaseOptionsOffersBatchUpdateCall) Fields(s ...googleapi.Field) *MonetizationOnetimeproductsPurchaseOptionsOffersBatchUpdateCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } // Context sets the context to be used in this call's Do method. -func (c *InappproductsPatchCall) Context(ctx context.Context) *InappproductsPatchCall { +func (c *MonetizationOnetimeproductsPurchaseOptionsOffersBatchUpdateCall) Context(ctx context.Context) *MonetizationOnetimeproductsPurchaseOptionsOffersBatchUpdateCall { 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 *InappproductsPatchCall) Header() http.Header { +func (c *MonetizationOnetimeproductsPurchaseOptionsOffersBatchUpdateCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *InappproductsPatchCall) doRequest(alt string) (*http.Response, error) { +func (c *MonetizationOnetimeproductsPurchaseOptionsOffersBatchUpdateCall) doRequest(alt string) (*http.Response, error) { reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) - body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.inappproduct) + body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.batchupdateonetimeproductoffersrequest) if err != nil { return nil, err } c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/inappproducts/{sku}") + urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/oneTimeProducts/{productId}/purchaseOptions/{purchaseOptionId}/offers:batchUpdate") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("PATCH", 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{ - "packageName": c.packageName, - "sku": c.skuid, + "packageName": c.packageName, + "productId": c.productId, + "purchaseOptionId": c.purchaseOptionId, }) - c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.inappproducts.patch", "request", internallog.HTTPRequest(req, body.Bytes())) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.monetization.onetimeproducts.purchaseOptions.offers.batchUpdate", "request", internallog.HTTPRequest(req, body.Bytes())) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "androidpublisher.inappproducts.patch" call. +// Do executes the "androidpublisher.monetization.onetimeproducts.purchaseOptions.offers.batchUpdate" call. // Any non-2xx status code is an error. Response headers are in either -// *InAppProduct.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 *InappproductsPatchCall) Do(opts ...googleapi.CallOption) (*InAppProduct, error) { +// *BatchUpdateOneTimeProductOffersResponse.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 *MonetizationOnetimeproductsPurchaseOptionsOffersBatchUpdateCall) Do(opts ...googleapi.CallOption) (*BatchUpdateOneTimeProductOffersResponse, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -15567,7 +19211,7 @@ func (c *InappproductsPatchCall) Do(opts ...googleapi.CallOption) (*InAppProduct if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &InAppProduct{ + ret := &BatchUpdateOneTimeProductOffersResponse{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -15578,130 +19222,94 @@ func (c *InappproductsPatchCall) Do(opts ...googleapi.CallOption) (*InAppProduct if err != nil { return nil, err } - c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.inappproducts.patch", "response", internallog.HTTPResponse(res, b)) + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.monetization.onetimeproducts.purchaseOptions.offers.batchUpdate", "response", internallog.HTTPResponse(res, b)) return ret, nil } -type InappproductsUpdateCall struct { - s *Service - packageName string - skuid string - inappproduct *InAppProduct - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +type MonetizationOnetimeproductsPurchaseOptionsOffersBatchUpdateStatesCall struct { + s *Service + packageName string + productId string + purchaseOptionId string + batchupdateonetimeproductofferstatesrequest *BatchUpdateOneTimeProductOfferStatesRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// Update: Updates an in-app product (a managed product or a subscription). -// This method should no longer be used to update subscriptions. See this -// article -// (https://android-developers.googleblog.com/2023/06/changes-to-google-play-developer-api-june-2023.html) -// for more information. +// BatchUpdateStates: Updates a batch of one-time product offer states. // -// - packageName: Package name of the app. -// - sku: Unique identifier for the in-app product. -func (r *InappproductsService) Update(packageName string, skuid string, inappproduct *InAppProduct) *InappproductsUpdateCall { - c := &InappproductsUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// - packageName: The parent app (package name) of the updated one-time product +// offers. +// - productId: The product ID of the parent one-time product, if all updated +// offers belong to the same one-time product. If this batch update spans +// multiple one-time products, set this field to "-". +// - purchaseOptionId: The purchase option ID of the parent purchase option, if +// all updated offers belong to the same purchase option. If this batch +// update spans multiple purchase options, set this field to "-". +func (r *MonetizationOnetimeproductsPurchaseOptionsOffersService) BatchUpdateStates(packageName string, productId string, purchaseOptionId string, batchupdateonetimeproductofferstatesrequest *BatchUpdateOneTimeProductOfferStatesRequest) *MonetizationOnetimeproductsPurchaseOptionsOffersBatchUpdateStatesCall { + c := &MonetizationOnetimeproductsPurchaseOptionsOffersBatchUpdateStatesCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.packageName = packageName - c.skuid = skuid - c.inappproduct = inappproduct - return c -} - -// AllowMissing sets the optional parameter "allowMissing": If set to true, and -// the in-app product with the given package_name and sku doesn't exist, the -// in-app product will be created. -func (c *InappproductsUpdateCall) AllowMissing(allowMissing bool) *InappproductsUpdateCall { - c.urlParams_.Set("allowMissing", fmt.Sprint(allowMissing)) - return c -} - -// AutoConvertMissingPrices sets the optional parameter -// "autoConvertMissingPrices": If true the prices for all regions targeted by -// the parent app that don't have a price specified for this in-app product -// will be auto converted to the target currency based on the default price. -// Defaults to false. -func (c *InappproductsUpdateCall) AutoConvertMissingPrices(autoConvertMissingPrices bool) *InappproductsUpdateCall { - c.urlParams_.Set("autoConvertMissingPrices", fmt.Sprint(autoConvertMissingPrices)) - return c -} - -// LatencyTolerance sets the optional parameter "latencyTolerance": The latency -// tolerance for the propagation of this product update. Defaults to -// latency-sensitive. -// -// Possible values: -// -// "PRODUCT_UPDATE_LATENCY_TOLERANCE_UNSPECIFIED" - Defaults to -// -// PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_SENSITIVE. -// -// "PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_SENSITIVE" - The update will -// -// propagate to clients within several minutes on average and up to a few hours -// in rare cases. Throughput is limited to 7,200 updates per app per hour. -// -// "PRODUCT_UPDATE_LATENCY_TOLERANCE_LATENCY_TOLERANT" - The update will -// -// propagate to clients within 24 hours. Supports high throughput of up to -// 720,000 updates per app per hour using batch modification methods. -func (c *InappproductsUpdateCall) LatencyTolerance(latencyTolerance string) *InappproductsUpdateCall { - c.urlParams_.Set("latencyTolerance", latencyTolerance) + c.productId = productId + c.purchaseOptionId = purchaseOptionId + c.batchupdateonetimeproductofferstatesrequest = batchupdateonetimeproductofferstatesrequest 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 *InappproductsUpdateCall) Fields(s ...googleapi.Field) *InappproductsUpdateCall { +func (c *MonetizationOnetimeproductsPurchaseOptionsOffersBatchUpdateStatesCall) Fields(s ...googleapi.Field) *MonetizationOnetimeproductsPurchaseOptionsOffersBatchUpdateStatesCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } // Context sets the context to be used in this call's Do method. -func (c *InappproductsUpdateCall) Context(ctx context.Context) *InappproductsUpdateCall { +func (c *MonetizationOnetimeproductsPurchaseOptionsOffersBatchUpdateStatesCall) Context(ctx context.Context) *MonetizationOnetimeproductsPurchaseOptionsOffersBatchUpdateStatesCall { 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 *InappproductsUpdateCall) Header() http.Header { +func (c *MonetizationOnetimeproductsPurchaseOptionsOffersBatchUpdateStatesCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *InappproductsUpdateCall) doRequest(alt string) (*http.Response, error) { +func (c *MonetizationOnetimeproductsPurchaseOptionsOffersBatchUpdateStatesCall) doRequest(alt string) (*http.Response, error) { reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) - body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.inappproduct) + body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.batchupdateonetimeproductofferstatesrequest) if err != nil { return nil, err } c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/inappproducts/{sku}") + urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/oneTimeProducts/{productId}/purchaseOptions/{purchaseOptionId}/offers:batchUpdateStates") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("PUT", 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{ - "packageName": c.packageName, - "sku": c.skuid, + "packageName": c.packageName, + "productId": c.productId, + "purchaseOptionId": c.purchaseOptionId, }) - c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.inappproducts.update", "request", internallog.HTTPRequest(req, body.Bytes())) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.monetization.onetimeproducts.purchaseOptions.offers.batchUpdateStates", "request", internallog.HTTPRequest(req, body.Bytes())) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "androidpublisher.inappproducts.update" call. +// Do executes the "androidpublisher.monetization.onetimeproducts.purchaseOptions.offers.batchUpdateStates" call. // Any non-2xx status code is an error. Response headers are in either -// *InAppProduct.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 *InappproductsUpdateCall) Do(opts ...googleapi.CallOption) (*InAppProduct, error) { +// *BatchUpdateOneTimeProductOfferStatesResponse.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 *MonetizationOnetimeproductsPurchaseOptionsOffersBatchUpdateStatesCall) Do(opts ...googleapi.CallOption) (*BatchUpdateOneTimeProductOfferStatesResponse, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -15720,7 +19328,7 @@ func (c *InappproductsUpdateCall) Do(opts ...googleapi.CallOption) (*InAppProduc if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &InAppProduct{ + ret := &BatchUpdateOneTimeProductOfferStatesResponse{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -15731,126 +19339,93 @@ func (c *InappproductsUpdateCall) Do(opts ...googleapi.CallOption) (*InAppProduc if err != nil { return nil, err } - c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.inappproducts.update", "response", internallog.HTTPResponse(res, b)) + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.monetization.onetimeproducts.purchaseOptions.offers.batchUpdateStates", "response", internallog.HTTPResponse(res, b)) return ret, nil } -type InternalappsharingartifactsUploadapkCall struct { - s *Service - packageName string - urlParams_ gensupport.URLParams - mediaInfo_ *gensupport.MediaInfo - ctx_ context.Context - header_ http.Header -} - -// Uploadapk: Uploads an APK to internal app sharing. If you are using the -// Google API client libraries, please increase the timeout of the http request -// before calling this endpoint (a timeout of 2 minutes is recommended). See -// Timeouts and Errors -// (https://developers.google.com/api-client-library/java/google-api-java-client/errors) -// for an example in java. -// -// - packageName: Package name of the app. -func (r *InternalappsharingartifactsService) Uploadapk(packageName string) *InternalappsharingartifactsUploadapkCall { - c := &InternalappsharingartifactsUploadapkCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.packageName = packageName - return c -} - -// Media specifies the media to upload in one or more chunks. The chunk size -// may be controlled by supplying a MediaOption generated by -// googleapi.ChunkSize. The chunk size defaults to -// googleapi.DefaultUploadChunkSize.The Content-Type header used in the upload -// request will be determined by sniffing the contents of r, unless a -// MediaOption generated by googleapi.ContentType is supplied. -// At most one of Media and ResumableMedia may be set. -func (c *InternalappsharingartifactsUploadapkCall) Media(r io.Reader, options ...googleapi.MediaOption) *InternalappsharingartifactsUploadapkCall { - c.mediaInfo_ = gensupport.NewInfoFromMedia(r, options) - return c -} - -// ResumableMedia specifies the media to upload in chunks and can be canceled -// with ctx. -// -// Deprecated: use Media instead. -// -// At most one of Media and ResumableMedia may be set. mediaType identifies the -// MIME media type of the upload, such as "image/png". If mediaType is "", it -// will be auto-detected. The provided ctx will supersede any context -// previously provided to the Context method. -func (c *InternalappsharingartifactsUploadapkCall) ResumableMedia(ctx context.Context, r io.ReaderAt, size int64, mediaType string) *InternalappsharingartifactsUploadapkCall { - c.ctx_ = ctx - c.mediaInfo_ = gensupport.NewInfoFromResumableMedia(r, size, mediaType) - return c +type MonetizationOnetimeproductsPurchaseOptionsOffersCancelCall struct { + s *Service + packageName string + productId string + purchaseOptionId string + offerId string + cancelonetimeproductofferrequest *CancelOneTimeProductOfferRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// ProgressUpdater provides a callback function that will be called after every -// chunk. It should be a low-latency function in order to not slow down the -// upload operation. This should only be called when using ResumableMedia (as -// opposed to Media). -func (c *InternalappsharingartifactsUploadapkCall) ProgressUpdater(pu googleapi.ProgressUpdater) *InternalappsharingartifactsUploadapkCall { - c.mediaInfo_.SetProgressUpdater(pu) +// Cancel: Cancels a one-time product offer. +// +// - offerId: The offer ID of the offer to cancel. +// - packageName: The parent app (package name) of the offer to cancel. +// - productId: The parent one-time product (ID) of the offer to cancel. +// - purchaseOptionId: The parent purchase option (ID) of the offer to cancel. +func (r *MonetizationOnetimeproductsPurchaseOptionsOffersService) Cancel(packageName string, productId string, purchaseOptionId string, offerId string, cancelonetimeproductofferrequest *CancelOneTimeProductOfferRequest) *MonetizationOnetimeproductsPurchaseOptionsOffersCancelCall { + c := &MonetizationOnetimeproductsPurchaseOptionsOffersCancelCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.packageName = packageName + c.productId = productId + c.purchaseOptionId = purchaseOptionId + c.offerId = offerId + c.cancelonetimeproductofferrequest = cancelonetimeproductofferrequest 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 *InternalappsharingartifactsUploadapkCall) Fields(s ...googleapi.Field) *InternalappsharingartifactsUploadapkCall { +func (c *MonetizationOnetimeproductsPurchaseOptionsOffersCancelCall) Fields(s ...googleapi.Field) *MonetizationOnetimeproductsPurchaseOptionsOffersCancelCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } // Context sets the context to be used in this call's Do method. -// This context will supersede any context previously provided to the -// ResumableMedia method. -func (c *InternalappsharingartifactsUploadapkCall) Context(ctx context.Context) *InternalappsharingartifactsUploadapkCall { +func (c *MonetizationOnetimeproductsPurchaseOptionsOffersCancelCall) Context(ctx context.Context) *MonetizationOnetimeproductsPurchaseOptionsOffersCancelCall { 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 *InternalappsharingartifactsUploadapkCall) Header() http.Header { +func (c *MonetizationOnetimeproductsPurchaseOptionsOffersCancelCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *InternalappsharingartifactsUploadapkCall) doRequest(alt string) (*http.Response, error) { +func (c *MonetizationOnetimeproductsPurchaseOptionsOffersCancelCall) doRequest(alt string) (*http.Response, error) { reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) + body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.cancelonetimeproductofferrequest) + if err != nil { + return nil, err + } c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/internalappsharing/{packageName}/artifacts/apk") - if c.mediaInfo_ != nil { - urls = googleapi.ResolveRelative(c.s.BasePath, "/upload/androidpublisher/v3/applications/internalappsharing/{packageName}/artifacts/apk") - c.urlParams_.Set("uploadType", c.mediaInfo_.UploadType()) - } - newBody, getBody, cleanup := c.mediaInfo_.UploadRequest(reqHeaders, nil) - defer cleanup() + urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/oneTimeProducts/{productId}/purchaseOptions/{purchaseOptionId}/offers/{offerId}:cancel") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("POST", urls, newBody) + req, err := http.NewRequest("POST", urls, body) if err != nil { return nil, err } req.Header = reqHeaders - req.GetBody = getBody googleapi.Expand(req.URL, map[string]string{ - "packageName": c.packageName, + "packageName": c.packageName, + "productId": c.productId, + "purchaseOptionId": c.purchaseOptionId, + "offerId": c.offerId, }) - c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.internalappsharingartifacts.uploadapk", "request", internallog.HTTPRequest(req, nil)) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.monetization.onetimeproducts.purchaseOptions.offers.cancel", "request", internallog.HTTPRequest(req, body.Bytes())) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "androidpublisher.internalappsharingartifacts.uploadapk" call. +// Do executes the "androidpublisher.monetization.onetimeproducts.purchaseOptions.offers.cancel" call. // Any non-2xx status code is an error. Response headers are in either -// *InternalAppSharingArtifact.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 *InternalappsharingartifactsUploadapkCall) Do(opts ...googleapi.CallOption) (*InternalAppSharingArtifact, error) { +// *OneTimeProductOffer.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 *MonetizationOnetimeproductsPurchaseOptionsOffersCancelCall) Do(opts ...googleapi.CallOption) (*OneTimeProductOffer, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -15869,24 +19444,7 @@ func (c *InternalappsharingartifactsUploadapkCall) Do(opts ...googleapi.CallOpti if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - rx := c.mediaInfo_.ResumableUpload(res.Header.Get("Location")) - if rx != nil { - rx.Client = c.s.client - rx.UserAgent = c.s.userAgent() - ctx := c.ctx_ - if ctx == nil { - ctx = context.TODO() - } - res, err = rx.Upload(ctx) - if err != nil { - return nil, err - } - defer res.Body.Close() - if err := googleapi.CheckResponse(res); err != nil { - return nil, gensupport.WrapError(err) - } - } - ret := &InternalAppSharingArtifact{ + ret := &OneTimeProductOffer{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -15897,126 +19455,94 @@ func (c *InternalappsharingartifactsUploadapkCall) Do(opts ...googleapi.CallOpti if err != nil { return nil, err } - c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.internalappsharingartifacts.uploadapk", "response", internallog.HTTPResponse(res, b)) + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.monetization.onetimeproducts.purchaseOptions.offers.cancel", "response", internallog.HTTPResponse(res, b)) return ret, nil } -type InternalappsharingartifactsUploadbundleCall struct { - s *Service - packageName string - urlParams_ gensupport.URLParams - mediaInfo_ *gensupport.MediaInfo - ctx_ context.Context - header_ http.Header +type MonetizationOnetimeproductsPurchaseOptionsOffersDeactivateCall struct { + s *Service + packageName string + productId string + purchaseOptionId string + offerId string + deactivateonetimeproductofferrequest *DeactivateOneTimeProductOfferRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// Uploadbundle: Uploads an app bundle to internal app sharing. If you are -// using the Google API client libraries, please increase the timeout of the -// http request before calling this endpoint (a timeout of 2 minutes is -// recommended). See Timeouts and Errors -// (https://developers.google.com/api-client-library/java/google-api-java-client/errors) -// for an example in java. +// Deactivate: Deactivates a one-time product offer. // -// - packageName: Package name of the app. -func (r *InternalappsharingartifactsService) Uploadbundle(packageName string) *InternalappsharingartifactsUploadbundleCall { - c := &InternalappsharingartifactsUploadbundleCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// - offerId: The offer ID of the offer to deactivate. +// - packageName: The parent app (package name) of the offer to deactivate. +// - productId: The parent one-time product (ID) of the offer to deactivate. +// - purchaseOptionId: The parent purchase option (ID) of the offer to +// deactivate. +func (r *MonetizationOnetimeproductsPurchaseOptionsOffersService) Deactivate(packageName string, productId string, purchaseOptionId string, offerId string, deactivateonetimeproductofferrequest *DeactivateOneTimeProductOfferRequest) *MonetizationOnetimeproductsPurchaseOptionsOffersDeactivateCall { + c := &MonetizationOnetimeproductsPurchaseOptionsOffersDeactivateCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.packageName = packageName - return c -} - -// Media specifies the media to upload in one or more chunks. The chunk size -// may be controlled by supplying a MediaOption generated by -// googleapi.ChunkSize. The chunk size defaults to -// googleapi.DefaultUploadChunkSize.The Content-Type header used in the upload -// request will be determined by sniffing the contents of r, unless a -// MediaOption generated by googleapi.ContentType is supplied. -// At most one of Media and ResumableMedia may be set. -func (c *InternalappsharingartifactsUploadbundleCall) Media(r io.Reader, options ...googleapi.MediaOption) *InternalappsharingartifactsUploadbundleCall { - c.mediaInfo_ = gensupport.NewInfoFromMedia(r, options) - return c -} - -// ResumableMedia specifies the media to upload in chunks and can be canceled -// with ctx. -// -// Deprecated: use Media instead. -// -// At most one of Media and ResumableMedia may be set. mediaType identifies the -// MIME media type of the upload, such as "image/png". If mediaType is "", it -// will be auto-detected. The provided ctx will supersede any context -// previously provided to the Context method. -func (c *InternalappsharingartifactsUploadbundleCall) ResumableMedia(ctx context.Context, r io.ReaderAt, size int64, mediaType string) *InternalappsharingartifactsUploadbundleCall { - c.ctx_ = ctx - c.mediaInfo_ = gensupport.NewInfoFromResumableMedia(r, size, mediaType) - return c -} - -// ProgressUpdater provides a callback function that will be called after every -// chunk. It should be a low-latency function in order to not slow down the -// upload operation. This should only be called when using ResumableMedia (as -// opposed to Media). -func (c *InternalappsharingartifactsUploadbundleCall) ProgressUpdater(pu googleapi.ProgressUpdater) *InternalappsharingartifactsUploadbundleCall { - c.mediaInfo_.SetProgressUpdater(pu) + c.productId = productId + c.purchaseOptionId = purchaseOptionId + c.offerId = offerId + c.deactivateonetimeproductofferrequest = deactivateonetimeproductofferrequest 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 *InternalappsharingartifactsUploadbundleCall) Fields(s ...googleapi.Field) *InternalappsharingartifactsUploadbundleCall { +func (c *MonetizationOnetimeproductsPurchaseOptionsOffersDeactivateCall) Fields(s ...googleapi.Field) *MonetizationOnetimeproductsPurchaseOptionsOffersDeactivateCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } // Context sets the context to be used in this call's Do method. -// This context will supersede any context previously provided to the -// ResumableMedia method. -func (c *InternalappsharingartifactsUploadbundleCall) Context(ctx context.Context) *InternalappsharingartifactsUploadbundleCall { +func (c *MonetizationOnetimeproductsPurchaseOptionsOffersDeactivateCall) Context(ctx context.Context) *MonetizationOnetimeproductsPurchaseOptionsOffersDeactivateCall { 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 *InternalappsharingartifactsUploadbundleCall) Header() http.Header { +func (c *MonetizationOnetimeproductsPurchaseOptionsOffersDeactivateCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *InternalappsharingartifactsUploadbundleCall) doRequest(alt string) (*http.Response, error) { +func (c *MonetizationOnetimeproductsPurchaseOptionsOffersDeactivateCall) doRequest(alt string) (*http.Response, error) { reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) + body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.deactivateonetimeproductofferrequest) + if err != nil { + return nil, err + } c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/internalappsharing/{packageName}/artifacts/bundle") - if c.mediaInfo_ != nil { - urls = googleapi.ResolveRelative(c.s.BasePath, "/upload/androidpublisher/v3/applications/internalappsharing/{packageName}/artifacts/bundle") - c.urlParams_.Set("uploadType", c.mediaInfo_.UploadType()) - } - newBody, getBody, cleanup := c.mediaInfo_.UploadRequest(reqHeaders, nil) - defer cleanup() + urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/oneTimeProducts/{productId}/purchaseOptions/{purchaseOptionId}/offers/{offerId}:deactivate") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("POST", urls, newBody) + req, err := http.NewRequest("POST", urls, body) if err != nil { return nil, err } req.Header = reqHeaders - req.GetBody = getBody googleapi.Expand(req.URL, map[string]string{ - "packageName": c.packageName, + "packageName": c.packageName, + "productId": c.productId, + "purchaseOptionId": c.purchaseOptionId, + "offerId": c.offerId, }) - c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.internalappsharingartifacts.uploadbundle", "request", internallog.HTTPRequest(req, nil)) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.monetization.onetimeproducts.purchaseOptions.offers.deactivate", "request", internallog.HTTPRequest(req, body.Bytes())) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "androidpublisher.internalappsharingartifacts.uploadbundle" call. +// Do executes the "androidpublisher.monetization.onetimeproducts.purchaseOptions.offers.deactivate" call. // Any non-2xx status code is an error. Response headers are in either -// *InternalAppSharingArtifact.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 *InternalappsharingartifactsUploadbundleCall) Do(opts ...googleapi.CallOption) (*InternalAppSharingArtifact, error) { +// *OneTimeProductOffer.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 *MonetizationOnetimeproductsPurchaseOptionsOffersDeactivateCall) Do(opts ...googleapi.CallOption) (*OneTimeProductOffer, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -16035,24 +19561,7 @@ func (c *InternalappsharingartifactsUploadbundleCall) Do(opts ...googleapi.CallO if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - rx := c.mediaInfo_.ResumableUpload(res.Header.Get("Location")) - if rx != nil { - rx.Client = c.s.client - rx.UserAgent = c.s.userAgent() - ctx := c.ctx_ - if ctx == nil { - ctx = context.TODO() - } - res, err = rx.Upload(ctx) - if err != nil { - return nil, err - } - defer res.Body.Close() - if err := googleapi.CheckResponse(res); err != nil { - return nil, gensupport.WrapError(err) - } - } - ret := &InternalAppSharingArtifact{ + ret := &OneTimeProductOffer{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -16063,83 +19572,119 @@ func (c *InternalappsharingartifactsUploadbundleCall) Do(opts ...googleapi.CallO if err != nil { return nil, err } - c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.internalappsharingartifacts.uploadbundle", "response", internallog.HTTPResponse(res, b)) + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.monetization.onetimeproducts.purchaseOptions.offers.deactivate", "response", internallog.HTTPResponse(res, b)) return ret, nil } -type MonetizationConvertRegionPricesCall struct { - s *Service - packageName string - convertregionpricesrequest *ConvertRegionPricesRequest - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +type MonetizationOnetimeproductsPurchaseOptionsOffersListCall struct { + s *Service + packageName string + productId string + purchaseOptionId string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header } -// ConvertRegionPrices: Calculates the region prices, using today's exchange -// rate and country-specific pricing patterns, based on the price in the -// request for a set of regions. +// List: Lists all offers under a given app, product, or purchase option. // -// - packageName: The app package name. -func (r *MonetizationService) ConvertRegionPrices(packageName string, convertregionpricesrequest *ConvertRegionPricesRequest) *MonetizationConvertRegionPricesCall { - c := &MonetizationConvertRegionPricesCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// - packageName: The parent app (package name) for which the offers should be +// read. +// - productId: The parent one-time product (ID) for which the offers should be +// read. May be specified as '-' to read all offers under an app. +// - purchaseOptionId: The parent purchase option (ID) for which the offers +// should be read. May be specified as '-' to read all offers under a +// one-time product or an app. Must be specified as '-' if product_id is +// specified as '-'. +func (r *MonetizationOnetimeproductsPurchaseOptionsOffersService) List(packageName string, productId string, purchaseOptionId string) *MonetizationOnetimeproductsPurchaseOptionsOffersListCall { + c := &MonetizationOnetimeproductsPurchaseOptionsOffersListCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.packageName = packageName - c.convertregionpricesrequest = convertregionpricesrequest + c.productId = productId + c.purchaseOptionId = purchaseOptionId + return c +} + +// PageSize sets the optional parameter "pageSize": The maximum number of +// offers to return. The service may return fewer than this value. If +// unspecified, at most 50 offers will be returned. The maximum value is 1000; +// values above 1000 will be coerced to 1000. +func (c *MonetizationOnetimeproductsPurchaseOptionsOffersListCall) PageSize(pageSize int64) *MonetizationOnetimeproductsPurchaseOptionsOffersListCall { + c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) + return c +} + +// PageToken sets the optional parameter "pageToken": A page token, received +// from a previous `ListOneTimeProductsOffers` call. Provide this to retrieve +// the subsequent page. When paginating, product_id, package_name and +// purchase_option_id provided to `ListOneTimeProductsOffersRequest` must match +// the call that provided the page token. +func (c *MonetizationOnetimeproductsPurchaseOptionsOffersListCall) PageToken(pageToken string) *MonetizationOnetimeproductsPurchaseOptionsOffersListCall { + 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 *MonetizationConvertRegionPricesCall) Fields(s ...googleapi.Field) *MonetizationConvertRegionPricesCall { +func (c *MonetizationOnetimeproductsPurchaseOptionsOffersListCall) Fields(s ...googleapi.Field) *MonetizationOnetimeproductsPurchaseOptionsOffersListCall { 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 *MonetizationOnetimeproductsPurchaseOptionsOffersListCall) IfNoneMatch(entityTag string) *MonetizationOnetimeproductsPurchaseOptionsOffersListCall { + c.ifNoneMatch_ = entityTag + return c +} + // Context sets the context to be used in this call's Do method. -func (c *MonetizationConvertRegionPricesCall) Context(ctx context.Context) *MonetizationConvertRegionPricesCall { +func (c *MonetizationOnetimeproductsPurchaseOptionsOffersListCall) Context(ctx context.Context) *MonetizationOnetimeproductsPurchaseOptionsOffersListCall { 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 *MonetizationConvertRegionPricesCall) Header() http.Header { +func (c *MonetizationOnetimeproductsPurchaseOptionsOffersListCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *MonetizationConvertRegionPricesCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) - body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.convertregionpricesrequest) - if err != nil { - return nil, err +func (c *MonetizationOnetimeproductsPurchaseOptionsOffersListCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) } c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/pricing:convertRegionPrices") + urls := googleapi.ResolveRelative(c.s.BasePath, "androidpublisher/v3/applications/{packageName}/oneTimeProducts/{productId}/purchaseOptions/{purchaseOptionId}/offers") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("POST", urls, body) + req, err := http.NewRequest("GET", urls, nil) if err != nil { return nil, err } req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ - "packageName": c.packageName, + "packageName": c.packageName, + "productId": c.productId, + "purchaseOptionId": c.purchaseOptionId, }) - c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.monetization.convertRegionPrices", "request", internallog.HTTPRequest(req, body.Bytes())) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "androidpublisher.monetization.onetimeproducts.purchaseOptions.offers.list", "request", internallog.HTTPRequest(req, nil)) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "androidpublisher.monetization.convertRegionPrices" call. +// Do executes the "androidpublisher.monetization.onetimeproducts.purchaseOptions.offers.list" call. // Any non-2xx status code is an error. Response headers are in either -// *ConvertRegionPricesResponse.ServerResponse.Header or (if a response was -// returned at all) in error.(*googleapi.Error).Header. Use +// *ListOneTimeProductOffersResponse.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 *MonetizationConvertRegionPricesCall) Do(opts ...googleapi.CallOption) (*ConvertRegionPricesResponse, error) { +func (c *MonetizationOnetimeproductsPurchaseOptionsOffersListCall) Do(opts ...googleapi.CallOption) (*ListOneTimeProductOffersResponse, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -16158,7 +19703,7 @@ func (c *MonetizationConvertRegionPricesCall) Do(opts ...googleapi.CallOption) ( if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &ConvertRegionPricesResponse{ + ret := &ListOneTimeProductOffersResponse{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -16169,10 +19714,31 @@ func (c *MonetizationConvertRegionPricesCall) Do(opts ...googleapi.CallOption) ( if err != nil { return nil, err } - c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.monetization.convertRegionPrices", "response", internallog.HTTPResponse(res, b)) + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "androidpublisher.monetization.onetimeproducts.purchaseOptions.offers.list", "response", internallog.HTTPResponse(res, b)) 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 *MonetizationOnetimeproductsPurchaseOptionsOffersListCall) Pages(ctx context.Context, f func(*ListOneTimeProductOffersResponse) 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 MonetizationSubscriptionsArchiveCall struct { s *Service packageName string diff --git a/chat/v1/chat-api.json b/chat/v1/chat-api.json index f3996b924e7..24cd377cc53 100644 --- a/chat/v1/chat-api.json +++ b/chat/v1/chat-api.json @@ -737,7 +737,7 @@ ] }, "get": { - "description": "Returns details about a membership. For an example, see [Get details about a user's or Google Chat app's membership](https://developers.google.com/workspace/chat/get-members). Supports the following types of [authentication](https://developers.google.com/workspace/chat/authenticate-authorize): - [App authentication](https://developers.google.com/workspace/chat/authenticate-authorize-chat-app) with the authorization scope: - `https://www.googleapis.com/auth/chat.bot` - [User authentication](https://developers.google.com/workspace/chat/authenticate-authorize-chat-user) with one of the following authorization scopes: - `https://www.googleapis.com/auth/chat.memberships.readonly` - `https://www.googleapis.com/auth/chat.memberships` - User authentication grants administrator privileges when an administrator account authenticates, `use_admin_access` is `true`, and one of the following authorization scopes is used: - `https://www.googleapis.com/auth/chat.admin.memberships.readonly` - `https://www.googleapis.com/auth/chat.admin.memberships`", + "description": "Returns details about a membership. For an example, see [Get details about a user's or Google Chat app's membership](https://developers.google.com/workspace/chat/get-members). Supports the following types of [authentication](https://developers.google.com/workspace/chat/authenticate-authorize): - [App authentication](https://developers.google.com/workspace/chat/authenticate-authorize-chat-app) with one of the following authorization scopes: - `https://www.googleapis.com/auth/chat.bot` - `https://www.googleapis.com/auth/chat.app.memberships` (requires [administrator approval](https://support.google.com/a?p=chat-app-auth)) - [User authentication](https://developers.google.com/workspace/chat/authenticate-authorize-chat-user) with one of the following authorization scopes: - `https://www.googleapis.com/auth/chat.memberships.readonly` - `https://www.googleapis.com/auth/chat.memberships` - User authentication grants administrator privileges when an administrator account authenticates, `use_admin_access` is `true`, and one of the following authorization scopes is used: - `https://www.googleapis.com/auth/chat.admin.memberships.readonly` - `https://www.googleapis.com/auth/chat.admin.memberships`", "flatPath": "v1/spaces/{spacesId}/members/{membersId}", "httpMethod": "GET", "id": "chat.spaces.members.get", @@ -772,7 +772,7 @@ ] }, "list": { - "description": "Lists memberships in a space. For an example, see [List users and Google Chat apps in a space](https://developers.google.com/workspace/chat/list-members). Listing memberships with [app authentication](https://developers.google.com/workspace/chat/authenticate-authorize-chat-app) lists memberships in spaces that the Chat app has access to, but excludes Chat app memberships, including its own. Listing memberships with [User authentication](https://developers.google.com/workspace/chat/authenticate-authorize-chat-user) lists memberships in spaces that the authenticated user has access to. Supports the following types of [authentication](https://developers.google.com/workspace/chat/authenticate-authorize): - [App authentication](https://developers.google.com/workspace/chat/authenticate-authorize-chat-app) with the authorization scope: - `https://www.googleapis.com/auth/chat.bot` - [User authentication](https://developers.google.com/workspace/chat/authenticate-authorize-chat-user) with one of the following authorization scopes: - `https://www.googleapis.com/auth/chat.memberships.readonly` - `https://www.googleapis.com/auth/chat.memberships` - `https://www.googleapis.com/auth/chat.import` (import mode spaces only) - User authentication grants administrator privileges when an administrator account authenticates, `use_admin_access` is `true`, and one of the following authorization scopes is used: - `https://www.googleapis.com/auth/chat.admin.memberships.readonly` - `https://www.googleapis.com/auth/chat.admin.memberships`", + "description": "Lists memberships in a space. For an example, see [List users and Google Chat apps in a space](https://developers.google.com/workspace/chat/list-members). Listing memberships with [app authentication](https://developers.google.com/workspace/chat/authenticate-authorize-chat-app) lists memberships in spaces that the Chat app has access to, but excludes Chat app memberships, including its own. Listing memberships with [User authentication](https://developers.google.com/workspace/chat/authenticate-authorize-chat-user) lists memberships in spaces that the authenticated user has access to. Supports the following types of [authentication](https://developers.google.com/workspace/chat/authenticate-authorize): - [App authentication](https://developers.google.com/workspace/chat/authenticate-authorize-chat-app) with one of the following authorization scopes: - `https://www.googleapis.com/auth/chat.bot` - `https://www.googleapis.com/auth/chat.app.memberships` (requires [administrator approval](https://support.google.com/a?p=chat-app-auth)) - [User authentication](https://developers.google.com/workspace/chat/authenticate-authorize-chat-user) with one of the following authorization scopes: - `https://www.googleapis.com/auth/chat.memberships.readonly` - `https://www.googleapis.com/auth/chat.memberships` - `https://www.googleapis.com/auth/chat.import` (import mode spaces only) - User authentication grants administrator privileges when an administrator account authenticates, `use_admin_access` is `true`, and one of the following authorization scopes is used: - `https://www.googleapis.com/auth/chat.admin.memberships.readonly` - `https://www.googleapis.com/auth/chat.admin.memberships`", "flatPath": "v1/spaces/{spacesId}/members", "httpMethod": "GET", "id": "chat.spaces.members.list", @@ -1528,7 +1528,7 @@ } } }, - "revision": "20250710", + "revision": "20250717", "rootUrl": "https://chat.googleapis.com/", "schemas": { "AccessSettings": { @@ -4883,6 +4883,10 @@ "format": "google-datetime", "type": "string" }, + "customer": { + "description": "Optional. Immutable. The customer id of the domain of the space. Required only when creating a space with [app authentication](https://developers.google.com/workspace/chat/authenticate-authorize-chat-app) and `SpaceType` is `SPACE`, otherwise should not be set. In the format `customers/{customer}`, where `customer` is the `id` from the [Admin SDK customer resource]( https://developers.google.com/admin-sdk/directory/reference/rest/v1/customers). Private apps can also use the `customers/my_customer` alias to create the space in the same Google Workspace organization as the app. For DMs, this field isn't populated. [Developer Preview](https://developers.google.com/workspace/preview).", + "type": "string" + }, "displayName": { "description": "Optional. The space's display name. Required when [creating a space](https://developers.google.com/workspace/chat/api/reference/rest/v1/spaces/create) with a `spaceType` of `SPACE`. If you receive the error message `ALREADY_EXISTS` when creating a space or updating the `displayName`, try a different `displayName`. An existing space within the Google Workspace organization might already use this display name. For direct messages, this field might be empty. Supports up to 128 characters.", "type": "string" diff --git a/chat/v1/chat-gen.go b/chat/v1/chat-gen.go index 18fcc5f15dc..1234606d785 100644 --- a/chat/v1/chat-gen.go +++ b/chat/v1/chat-gen.go @@ -5491,6 +5491,18 @@ type Space struct { // the original creation time. Only populated in the output when `spaceType` is // `GROUP_CHAT` or `SPACE`. CreateTime string `json:"createTime,omitempty"` + // Customer: Optional. Immutable. The customer id of the domain of the space. + // Required only when creating a space with app authentication + // (https://developers.google.com/workspace/chat/authenticate-authorize-chat-app) + // and `SpaceType` is `SPACE`, otherwise should not be set. In the format + // `customers/{customer}`, where `customer` is the `id` from the Admin SDK + // customer resource ( + // https://developers.google.com/admin-sdk/directory/reference/rest/v1/customers). + // Private apps can also use the `customers/my_customer` alias to create the + // space in the same Google Workspace organization as the app. For DMs, this + // field isn't populated. Developer Preview + // (https://developers.google.com/workspace/preview). + Customer string `json:"customer,omitempty"` // DisplayName: Optional. The space's display name. Required when creating a // space // (https://developers.google.com/workspace/chat/api/reference/rest/v1/spaces/create) @@ -8863,7 +8875,10 @@ type SpacesMembersGetCall struct { // (https://developers.google.com/workspace/chat/authenticate-authorize): - App // authentication // (https://developers.google.com/workspace/chat/authenticate-authorize-chat-app) -// with the authorization scope: - `https://www.googleapis.com/auth/chat.bot` - +// with one of the following authorization scopes: - +// `https://www.googleapis.com/auth/chat.bot` - +// `https://www.googleapis.com/auth/chat.app.memberships` (requires +// administrator approval (https://support.google.com/a?p=chat-app-auth)) - // User authentication // (https://developers.google.com/workspace/chat/authenticate-authorize-chat-user) // with one of the following authorization scopes: - @@ -9016,7 +9031,10 @@ type SpacesMembersListCall struct { // (https://developers.google.com/workspace/chat/authenticate-authorize): - App // authentication // (https://developers.google.com/workspace/chat/authenticate-authorize-chat-app) -// with the authorization scope: - `https://www.googleapis.com/auth/chat.bot` - +// with one of the following authorization scopes: - +// `https://www.googleapis.com/auth/chat.bot` - +// `https://www.googleapis.com/auth/chat.app.memberships` (requires +// administrator approval (https://support.google.com/a?p=chat-app-auth)) - // User authentication // (https://developers.google.com/workspace/chat/authenticate-authorize-chat-user) // with one of the following authorization scopes: - diff --git a/firebaseml/v2beta/firebaseml-api.json b/firebaseml/v2beta/firebaseml-api.json index 9e467649160..55e25eeebd5 100644 --- a/firebaseml/v2beta/firebaseml-api.json +++ b/firebaseml/v2beta/firebaseml-api.json @@ -206,7 +206,7 @@ } } }, - "revision": "20250715", + "revision": "20250720", "rootUrl": "https://firebaseml.googleapis.com/", "schemas": { "Date": { @@ -1415,6 +1415,10 @@ "description": "Chunk from Google Maps.", "id": "GoogleCloudAiplatformV1beta1GroundingChunkMaps", "properties": { + "placeAnswerSources": { + "$ref": "GoogleCloudAiplatformV1beta1GroundingChunkMapsPlaceAnswerSources", + "description": "Sources used to generate the place answer. This includes review snippets and photos that were used to generate the answer, as well as uris to flag content." + }, "placeId": { "description": "This Place's resource name, in `places/{place_id}` format. Can be used to look up the Place.", "type": "string" @@ -1434,6 +1438,70 @@ }, "type": "object" }, + "GoogleCloudAiplatformV1beta1GroundingChunkMapsPlaceAnswerSources": { + "description": "Sources used to generate the place answer.", + "id": "GoogleCloudAiplatformV1beta1GroundingChunkMapsPlaceAnswerSources", + "properties": { + "flagContentUri": { + "description": "A link where users can flag a problem with the generated answer.", + "type": "string" + }, + "reviewSnippets": { + "description": "Snippets of reviews that are used to generate the answer.", + "items": { + "$ref": "GoogleCloudAiplatformV1beta1GroundingChunkMapsPlaceAnswerSourcesReviewSnippet" + }, + "type": "array" + } + }, + "type": "object" + }, + "GoogleCloudAiplatformV1beta1GroundingChunkMapsPlaceAnswerSourcesAuthorAttribution": { + "description": "Author attribution for a photo or review.", + "id": "GoogleCloudAiplatformV1beta1GroundingChunkMapsPlaceAnswerSourcesAuthorAttribution", + "properties": { + "displayName": { + "description": "Name of the author of the Photo or Review.", + "type": "string" + }, + "photoUri": { + "description": "Profile photo URI of the author of the Photo or Review.", + "type": "string" + }, + "uri": { + "description": "URI of the author of the Photo or Review.", + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudAiplatformV1beta1GroundingChunkMapsPlaceAnswerSourcesReviewSnippet": { + "description": "Encapsulates a review snippet.", + "id": "GoogleCloudAiplatformV1beta1GroundingChunkMapsPlaceAnswerSourcesReviewSnippet", + "properties": { + "authorAttribution": { + "$ref": "GoogleCloudAiplatformV1beta1GroundingChunkMapsPlaceAnswerSourcesAuthorAttribution", + "description": "This review's author." + }, + "flagContentUri": { + "description": "A link where users can flag a problem with the review.", + "type": "string" + }, + "googleMapsUri": { + "description": "A link to show the review on Google Maps.", + "type": "string" + }, + "relativePublishTimeDescription": { + "description": "A string of formatted recent time, expressing the review time relative to the current time in a form appropriate for the language and country.", + "type": "string" + }, + "review": { + "description": "A reference representing this place review which may be used to look up this place review again.", + "type": "string" + } + }, + "type": "object" + }, "GoogleCloudAiplatformV1beta1GroundingChunkRetrievedContext": { "description": "Chunk from context retrieved by the retrieval tools.", "id": "GoogleCloudAiplatformV1beta1GroundingChunkRetrievedContext", diff --git a/firebaseml/v2beta/firebaseml-gen.go b/firebaseml/v2beta/firebaseml-gen.go index 2083247f193..423d3a8a0ba 100644 --- a/firebaseml/v2beta/firebaseml-gen.go +++ b/firebaseml/v2beta/firebaseml-gen.go @@ -1700,6 +1700,10 @@ func (s GoogleCloudAiplatformV1beta1GroundingChunk) MarshalJSON() ([]byte, error // GoogleCloudAiplatformV1beta1GroundingChunkMaps: Chunk from Google Maps. type GoogleCloudAiplatformV1beta1GroundingChunkMaps struct { + // PlaceAnswerSources: Sources used to generate the place answer. This includes + // review snippets and photos that were used to generate the answer, as well as + // uris to flag content. + PlaceAnswerSources *GoogleCloudAiplatformV1beta1GroundingChunkMapsPlaceAnswerSources `json:"placeAnswerSources,omitempty"` // PlaceId: This Place's resource name, in `places/{place_id}` format. Can be // used to look up the Place. PlaceId string `json:"placeId,omitempty"` @@ -1709,15 +1713,15 @@ type GoogleCloudAiplatformV1beta1GroundingChunkMaps struct { Title string `json:"title,omitempty"` // Uri: URI reference of the chunk. Uri string `json:"uri,omitempty"` - // ForceSendFields is a list of field names (e.g. "PlaceId") 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. "PlaceAnswerSources") 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. "PlaceId") 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. "PlaceAnswerSources") 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:"-"` } @@ -1727,6 +1731,93 @@ func (s GoogleCloudAiplatformV1beta1GroundingChunkMaps) MarshalJSON() ([]byte, e return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudAiplatformV1beta1GroundingChunkMapsPlaceAnswerSources: Sources +// used to generate the place answer. +type GoogleCloudAiplatformV1beta1GroundingChunkMapsPlaceAnswerSources struct { + // FlagContentUri: A link where users can flag a problem with the generated + // answer. + FlagContentUri string `json:"flagContentUri,omitempty"` + // ReviewSnippets: Snippets of reviews that are used to generate the answer. + ReviewSnippets []*GoogleCloudAiplatformV1beta1GroundingChunkMapsPlaceAnswerSourcesReviewSnippet `json:"reviewSnippets,omitempty"` + // ForceSendFields is a list of field names (e.g. "FlagContentUri") 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. "FlagContentUri") 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 GoogleCloudAiplatformV1beta1GroundingChunkMapsPlaceAnswerSources) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudAiplatformV1beta1GroundingChunkMapsPlaceAnswerSources + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudAiplatformV1beta1GroundingChunkMapsPlaceAnswerSourcesAuthorAttribu +// tion: Author attribution for a photo or review. +type GoogleCloudAiplatformV1beta1GroundingChunkMapsPlaceAnswerSourcesAuthorAttribution struct { + // DisplayName: Name of the author of the Photo or Review. + DisplayName string `json:"displayName,omitempty"` + // PhotoUri: Profile photo URI of the author of the Photo or Review. + PhotoUri string `json:"photoUri,omitempty"` + // Uri: URI of the author of the Photo or Review. + Uri string `json:"uri,omitempty"` + // ForceSendFields is a list of field names (e.g. "DisplayName") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "DisplayName") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudAiplatformV1beta1GroundingChunkMapsPlaceAnswerSourcesAuthorAttribution) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudAiplatformV1beta1GroundingChunkMapsPlaceAnswerSourcesAuthorAttribution + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudAiplatformV1beta1GroundingChunkMapsPlaceAnswerSourcesReviewSnippet +// : Encapsulates a review snippet. +type GoogleCloudAiplatformV1beta1GroundingChunkMapsPlaceAnswerSourcesReviewSnippet struct { + // AuthorAttribution: This review's author. + AuthorAttribution *GoogleCloudAiplatformV1beta1GroundingChunkMapsPlaceAnswerSourcesAuthorAttribution `json:"authorAttribution,omitempty"` + // FlagContentUri: A link where users can flag a problem with the review. + FlagContentUri string `json:"flagContentUri,omitempty"` + // GoogleMapsUri: A link to show the review on Google Maps. + GoogleMapsUri string `json:"googleMapsUri,omitempty"` + // RelativePublishTimeDescription: A string of formatted recent time, + // expressing the review time relative to the current time in a form + // appropriate for the language and country. + RelativePublishTimeDescription string `json:"relativePublishTimeDescription,omitempty"` + // Review: A reference representing this place review which may be used to look + // up this place review again. + Review string `json:"review,omitempty"` + // ForceSendFields is a list of field names (e.g. "AuthorAttribution") 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. "AuthorAttribution") 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 GoogleCloudAiplatformV1beta1GroundingChunkMapsPlaceAnswerSourcesReviewSnippet) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudAiplatformV1beta1GroundingChunkMapsPlaceAnswerSourcesReviewSnippet + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudAiplatformV1beta1GroundingChunkRetrievedContext: Chunk from // context retrieved by the retrieval tools. type GoogleCloudAiplatformV1beta1GroundingChunkRetrievedContext struct { diff --git a/homegraph/v1/homegraph-api.json b/homegraph/v1/homegraph-api.json index ee45b3729ed..f5bbd1705ee 100644 --- a/homegraph/v1/homegraph-api.json +++ b/homegraph/v1/homegraph-api.json @@ -216,7 +216,7 @@ } } }, - "revision": "20250410", + "revision": "20250716", "rootUrl": "https://homegraph.googleapis.com/", "schemas": { "AgentDeviceId": { @@ -349,7 +349,7 @@ "type": "array" }, "name": { - "description": "Primary name of the device, generally provided by the user.", + "description": "Primary name of the device, generally provided by the user. Names will be truncated if over the 60 Unicode code point (character) limit and no errors will be thrown. Developers are responsible for handling long names.", "type": "string" }, "nicknames": { diff --git a/homegraph/v1/homegraph-gen.go b/homegraph/v1/homegraph-gen.go index 53c25808c2f..e8ce614277a 100644 --- a/homegraph/v1/homegraph-gen.go +++ b/homegraph/v1/homegraph-gen.go @@ -314,7 +314,9 @@ type DeviceNames struct { // DefaultNames: List of names provided by the manufacturer rather than the // user, such as serial numbers, SKUs, etc. DefaultNames []string `json:"defaultNames,omitempty"` - // Name: Primary name of the device, generally provided by the user. + // Name: Primary name of the device, generally provided by the user. Names will + // be truncated if over the 60 Unicode code point (character) limit and no + // errors will be thrown. Developers are responsible for handling long names. Name string `json:"name,omitempty"` // Nicknames: Additional names provided by the user for the device. Nicknames []string `json:"nicknames,omitempty"` diff --git a/iam/v1/iam-api.json b/iam/v1/iam-api.json index 86a7c4223ca..79fac73a80c 100644 --- a/iam/v1/iam-api.json +++ b/iam/v1/iam-api.json @@ -860,6 +860,388 @@ ] } } + }, + "scimTenants": { + "methods": { + "create": { + "description": "Creates a new WorkforcePoolProviderScimTenant in a WorkforcePoolProvider. You cannot reuse the name of a deleted scim tenant until 30 days after deletion.", + "flatPath": "v1/locations/{locationsId}/workforcePools/{workforcePoolsId}/providers/{providersId}/scimTenants", + "httpMethod": "POST", + "id": "iam.locations.workforcePools.providers.scimTenants.create", + "parameterOrder": [ + "parent" + ], + "parameters": { + "parent": { + "description": "Required. The parent to create scim tenant. Format: 'locations/{location}/workforcePools/{workforce_pool}/providers/{provider}'", + "location": "path", + "pattern": "^locations/[^/]+/workforcePools/[^/]+/providers/[^/]+$", + "required": true, + "type": "string" + }, + "workforcePoolProviderScimTenantId": { + "description": "Required. The ID to use for the scim tenant, which becomes the final component of the resource name. This value should be 4-32 characters, and may contain the characters [a-z0-9-].", + "location": "query", + "type": "string" + } + }, + "path": "v1/{+parent}/scimTenants", + "request": { + "$ref": "WorkforcePoolProviderScimTenant" + }, + "response": { + "$ref": "WorkforcePoolProviderScimTenant" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "delete": { + "description": "Deletes a WorkforcePoolProviderScimTenant. You can undelete a scim tenant for 30 days. After 30 days, deletion is permanent. You cannot update deleted scim tenants. However, you can view and list them.", + "flatPath": "v1/locations/{locationsId}/workforcePools/{workforcePoolsId}/providers/{providersId}/scimTenants/{scimTenantsId}", + "httpMethod": "DELETE", + "id": "iam.locations.workforcePools.providers.scimTenants.delete", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Required. The name of the scim tenant to delete. Format: `locations/{location}/workforcePools/{workforce_pool}/providers/{provider}/scimTenants/{scim_tenant}`", + "location": "path", + "pattern": "^locations/[^/]+/workforcePools/[^/]+/providers/[^/]+/scimTenants/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1/{+name}", + "response": { + "$ref": "WorkforcePoolProviderScimTenant" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "get": { + "description": "Gets an individual WorkforcePoolProviderScimTenant.", + "flatPath": "v1/locations/{locationsId}/workforcePools/{workforcePoolsId}/providers/{providersId}/scimTenants/{scimTenantsId}", + "httpMethod": "GET", + "id": "iam.locations.workforcePools.providers.scimTenants.get", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Required. The name of the scim tenant to retrieve. Format: `locations/{location}/workforcePools/{workforce_pool}/providers/{provider}/scimTenants/{scim_tenant}`", + "location": "path", + "pattern": "^locations/[^/]+/workforcePools/[^/]+/providers/[^/]+/scimTenants/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1/{+name}", + "response": { + "$ref": "WorkforcePoolProviderScimTenant" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "list": { + "description": "Lists all non-deleted WorkforcePoolProviderScimTenants in a WorkforcePoolProvider. If `show_deleted` is set to `true`, then deleted scim tenants are also listed.", + "flatPath": "v1/locations/{locationsId}/workforcePools/{workforcePoolsId}/providers/{providersId}/scimTenants", + "httpMethod": "GET", + "id": "iam.locations.workforcePools.providers.scimTenants.list", + "parameterOrder": [ + "parent" + ], + "parameters": { + "pageSize": { + "description": "Optional. The maximum number of scim tenants to return. If unspecified, at most 1 scim tenant will be returned.", + "format": "int32", + "location": "query", + "type": "integer" + }, + "pageToken": { + "description": "Optional. A page token, received from a previous `ListScimTenants` call. Provide this to retrieve the subsequent page.", + "location": "query", + "type": "string" + }, + "parent": { + "description": "Required. The parent to list scim tenants. Format: 'locations/{location}/workforcePools/{workforce_pool}/providers/{provider}'", + "location": "path", + "pattern": "^locations/[^/]+/workforcePools/[^/]+/providers/[^/]+$", + "required": true, + "type": "string" + }, + "showDeleted": { + "description": "Optional. Whether to return soft-deleted scim tenants.", + "location": "query", + "type": "boolean" + } + }, + "path": "v1/{+parent}/scimTenants", + "response": { + "$ref": "ListWorkforcePoolProviderScimTenantsResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "patch": { + "description": "Updates an existing WorkforcePoolProviderScimTenant.", + "flatPath": "v1/locations/{locationsId}/workforcePools/{workforcePoolsId}/providers/{providersId}/scimTenants/{scimTenantsId}", + "httpMethod": "PATCH", + "id": "iam.locations.workforcePools.providers.scimTenants.patch", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Identifier. The resource name of the SCIM Tenant. Format: `locations/{location}/workforcePools/{workforce_pool}/providers/ {workforce_pool_provider}/scimTenants/{scim_tenant}`", + "location": "path", + "pattern": "^locations/[^/]+/workforcePools/[^/]+/providers/[^/]+/scimTenants/[^/]+$", + "required": true, + "type": "string" + }, + "updateMask": { + "description": "Optional. The list of fields to update.", + "format": "google-fieldmask", + "location": "query", + "type": "string" + } + }, + "path": "v1/{+name}", + "request": { + "$ref": "WorkforcePoolProviderScimTenant" + }, + "response": { + "$ref": "WorkforcePoolProviderScimTenant" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "undelete": { + "description": "Undeletes a WorkforcePoolProviderScimTenant, as long as it was deleted fewer than 30 days ago.", + "flatPath": "v1/locations/{locationsId}/workforcePools/{workforcePoolsId}/providers/{providersId}/scimTenants/{scimTenantsId}:undelete", + "httpMethod": "POST", + "id": "iam.locations.workforcePools.providers.scimTenants.undelete", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Required. The name of the scim tenant to undelete. Format: `locations/{location}/workforcePools/{workforce_pool}/providers/{provider}/scimTenants/{scim_tenant}`", + "location": "path", + "pattern": "^locations/[^/]+/workforcePools/[^/]+/providers/[^/]+/scimTenants/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1/{+name}:undelete", + "request": { + "$ref": "UndeleteWorkforcePoolProviderScimTenantRequest" + }, + "response": { + "$ref": "WorkforcePoolProviderScimTenant" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + } + }, + "resources": { + "tokens": { + "methods": { + "create": { + "description": "Creates a new WorkforcePoolProviderScimToken in a WorkforcePoolProviderScimTenant. You cannot reuse the name of a deleted SCIM token until 30 days after deletion.", + "flatPath": "v1/locations/{locationsId}/workforcePools/{workforcePoolsId}/providers/{providersId}/scimTenants/{scimTenantsId}/tokens", + "httpMethod": "POST", + "id": "iam.locations.workforcePools.providers.scimTenants.tokens.create", + "parameterOrder": [ + "parent" + ], + "parameters": { + "parent": { + "description": "Required. The parent tenant to create scim token. Format: 'locations/{location}/workforcePools/{workforce_pool}/providers/{provider}/scimTenants/{scim_tenant}'", + "location": "path", + "pattern": "^locations/[^/]+/workforcePools/[^/]+/providers/[^/]+/scimTenants/[^/]+$", + "required": true, + "type": "string" + }, + "workforcePoolProviderScimTokenId": { + "description": "Required. The ID to use for the scim token, which becomes the final component of the resource name. This value should be 4-32 characters and follow this pattern: \"([a-z]([a-z0-9\\\\-]{2,30}[a-z0-9]))\"", + "location": "query", + "type": "string" + } + }, + "path": "v1/{+parent}/tokens", + "request": { + "$ref": "WorkforcePoolProviderScimToken" + }, + "response": { + "$ref": "WorkforcePoolProviderScimToken" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "delete": { + "description": "Deletes a WorkforcePoolProviderScimToken. You can undelete a scim token for 30 days. After 30 days, deletion is permanent. You cannot update deleted scim tokens. However, you can view and list them.", + "flatPath": "v1/locations/{locationsId}/workforcePools/{workforcePoolsId}/providers/{providersId}/scimTenants/{scimTenantsId}/tokens/{tokensId}", + "httpMethod": "DELETE", + "id": "iam.locations.workforcePools.providers.scimTenants.tokens.delete", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Required. The name of the scim token to delete. Format: `locations/{location}/workforcePools/{workforce_pool}/providers/{provider}/scimTenants/{scim_tenant}/tokens/{token}`", + "location": "path", + "pattern": "^locations/[^/]+/workforcePools/[^/]+/providers/[^/]+/scimTenants/[^/]+/tokens/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1/{+name}", + "response": { + "$ref": "WorkforcePoolProviderScimToken" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "get": { + "description": "Gets an individual WorkforcePoolProviderScimToken.", + "flatPath": "v1/locations/{locationsId}/workforcePools/{workforcePoolsId}/providers/{providersId}/scimTenants/{scimTenantsId}/tokens/{tokensId}", + "httpMethod": "GET", + "id": "iam.locations.workforcePools.providers.scimTenants.tokens.get", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Required. The name of the scim token to retrieve. Format: `locations/{location}/workforcePools/{workforce_pool}/providers/{provider}/scimTenants/{scim_tenant}/tokens/{token}`", + "location": "path", + "pattern": "^locations/[^/]+/workforcePools/[^/]+/providers/[^/]+/scimTenants/[^/]+/tokens/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1/{+name}", + "response": { + "$ref": "WorkforcePoolProviderScimToken" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "list": { + "description": "Lists all non-deleted WorkforcePoolProviderScimTokenss in a WorkforcePoolProviderScimTenant. If `show_deleted` is set to `true`, then deleted SCIM tokens are also listed.", + "flatPath": "v1/locations/{locationsId}/workforcePools/{workforcePoolsId}/providers/{providersId}/scimTenants/{scimTenantsId}/tokens", + "httpMethod": "GET", + "id": "iam.locations.workforcePools.providers.scimTenants.tokens.list", + "parameterOrder": [ + "parent" + ], + "parameters": { + "pageSize": { + "description": "Optional. The maximum number of scim tokens to return. If unspecified, at most 2 scim tokens will be returned.", + "format": "int32", + "location": "query", + "type": "integer" + }, + "pageToken": { + "description": "Optional. A page token, received from a previous `ListWorkforcePoolProviderScimTokens` call. Provide this to retrieve the subsequent page.", + "location": "query", + "type": "string" + }, + "parent": { + "description": "Required. The parent to list scim tokens. Format: 'locations/{location}/workforcePools/{workforce_pool}/providers/{provider}/scimTenants/{scim_tenant}'", + "location": "path", + "pattern": "^locations/[^/]+/workforcePools/[^/]+/providers/[^/]+/scimTenants/[^/]+$", + "required": true, + "type": "string" + }, + "showDeleted": { + "description": "Optional. Whether to return soft-deleted scim tokens.", + "location": "query", + "type": "boolean" + } + }, + "path": "v1/{+parent}/tokens", + "response": { + "$ref": "ListWorkforcePoolProviderScimTokensResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "patch": { + "description": "Updates an existing WorkforcePoolProviderScimToken.", + "flatPath": "v1/locations/{locationsId}/workforcePools/{workforcePoolsId}/providers/{providersId}/scimTenants/{scimTenantsId}/tokens/{tokensId}", + "httpMethod": "PATCH", + "id": "iam.locations.workforcePools.providers.scimTenants.tokens.patch", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Identifier. The resource name of the SCIM Token. Format: `locations/{location}/workforcePools/{workforce_pool}/providers/ {workforce_pool_provider}/scimTenants/{scim_tenant}/tokens/{token}`", + "location": "path", + "pattern": "^locations/[^/]+/workforcePools/[^/]+/providers/[^/]+/scimTenants/[^/]+/tokens/[^/]+$", + "required": true, + "type": "string" + }, + "updateMask": { + "description": "Optional. The list of fields to update.", + "format": "google-fieldmask", + "location": "query", + "type": "string" + } + }, + "path": "v1/{+name}", + "request": { + "$ref": "WorkforcePoolProviderScimToken" + }, + "response": { + "$ref": "WorkforcePoolProviderScimToken" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "undelete": { + "description": "Undeletes a WorkforcePoolProviderScimToken, as long as it was deleted fewer than 30 days ago.", + "flatPath": "v1/locations/{locationsId}/workforcePools/{workforcePoolsId}/providers/{providersId}/scimTenants/{scimTenantsId}/tokens/{tokensId}:undelete", + "httpMethod": "POST", + "id": "iam.locations.workforcePools.providers.scimTenants.tokens.undelete", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Required. The name of the scim token to undelete. Format: `locations/{location}/workforcePools/{workforce_pool}/providers/{provider}/scimTenants/{scim_tenant}/tokens/{token}`", + "location": "path", + "pattern": "^locations/[^/]+/workforcePools/[^/]+/providers/[^/]+/scimTenants/[^/]+/tokens/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1/{+name}:undelete", + "request": { + "$ref": "UndeleteWorkforcePoolProviderScimTokenRequest" + }, + "response": { + "$ref": "WorkforcePoolProviderScimToken" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + } + } + } + } } } }, @@ -3773,7 +4155,7 @@ } } }, - "revision": "20250627", + "revision": "20250718", "rootUrl": "https://iam.googleapis.com/", "schemas": { "AccessRestrictions": { @@ -4630,6 +5012,44 @@ }, "type": "object" }, + "ListWorkforcePoolProviderScimTenantsResponse": { + "description": "Response message for ListWorkforcePoolProviderScimTenants.", + "id": "ListWorkforcePoolProviderScimTenantsResponse", + "properties": { + "nextPageToken": { + "description": "Optional. A token, which can be sent as `page_token` to retrieve the next page. If this field is omitted, there are no subsequent pages.", + "type": "string" + }, + "workforcePoolProviderScimTenants": { + "description": "Output only. A list of scim tenants.", + "items": { + "$ref": "WorkforcePoolProviderScimTenant" + }, + "readOnly": true, + "type": "array" + } + }, + "type": "object" + }, + "ListWorkforcePoolProviderScimTokensResponse": { + "description": "Response message for ListWorkforcePoolProviderScimTokens.", + "id": "ListWorkforcePoolProviderScimTokensResponse", + "properties": { + "nextPageToken": { + "description": "Optional. A token, which can be sent as `page_token` to retrieve the next page. If this field is omitted, there are no subsequent pages.", + "type": "string" + }, + "workforcePoolProviderScimTokens": { + "description": "Output only. A list of scim tokens.", + "items": { + "$ref": "WorkforcePoolProviderScimToken" + }, + "readOnly": true, + "type": "array" + } + }, + "type": "object" + }, "ListWorkforcePoolProvidersResponse": { "description": "Response message for ListWorkforcePoolProviders.", "id": "ListWorkforcePoolProvidersResponse", @@ -5747,6 +6167,18 @@ "properties": {}, "type": "object" }, + "UndeleteWorkforcePoolProviderScimTenantRequest": { + "description": "Request message for UndeleteWorkforcePoolProviderScimTenant.", + "id": "UndeleteWorkforcePoolProviderScimTenantRequest", + "properties": {}, + "type": "object" + }, + "UndeleteWorkforcePoolProviderScimTokenRequest": { + "description": "Request message for UndeleteWorkforcePoolProviderScimToken.", + "id": "UndeleteWorkforcePoolProviderScimTokenRequest", + "properties": {}, + "type": "object" + }, "UndeleteWorkforcePoolRequest": { "description": "Request message for UndeleteWorkforcePool.", "id": "UndeleteWorkforcePoolRequest", @@ -5895,6 +6327,10 @@ "readOnly": true, "type": "string" }, + "extendedAttributesOauth2Client": { + "$ref": "GoogleIamAdminV1WorkforcePoolProviderExtraAttributesOAuth2Client", + "description": "Optional. The configuration for OAuth 2.0 client used to get the extended group memberships for user identities. Only the `AZURE_AD_GROUPS_ID` attribute type is supported. Extended groups supports a subset of Google Cloud services. When the user accesses these services, extended group memberships override the mapped `google.groups` attribute. Extended group memberships cannot be used in attribute mapping or attribute condition expressions. To keep extended group memberships up to date, extended groups are retrieved when the user signs in and at regular intervals during the user's active session. Each user identity in the workforce identity pool must map to a specific, unique Microsoft Entra ID user." + }, "extraAttributesOauth2Client": { "$ref": "GoogleIamAdminV1WorkforcePoolProviderExtraAttributesOAuth2Client", "description": "Optional. The configuration for OAuth 2.0 client used to get the additional user attributes. This should be used when users can't get the desired claims in authentication credentials. Currently this configuration is only supported with OIDC protocol." @@ -5977,6 +6413,93 @@ }, "type": "object" }, + "WorkforcePoolProviderScimTenant": { + "description": "Represents a scim tenant. Used for provisioning and managing identity data (such as Users and Groups) in cross-domain environments.", + "id": "WorkforcePoolProviderScimTenant", + "properties": { + "baseUri": { + "description": "Output only. Represents the base URI as defined in [RFC 7644, Section 1.3](https://datatracker.ietf.org/doc/html/rfc7644#section-1.3). Clients must use this as the root address for managing resources under the tenant. Format: https://iamscim.googleapis.com/{version}/{tenant_id}/", + "readOnly": true, + "type": "string" + }, + "claimMapping": { + "additionalProperties": { + "type": "string" + }, + "description": "Optional. Maps BYOID claims to SCIM claims.", + "type": "object" + }, + "description": { + "description": "Optional. The user-specified description of the scim tenant. Cannot exceed 256 characters.", + "type": "string" + }, + "displayName": { + "description": "Optional. The user-specified display name of the scim tenant. Cannot exceed 32 characters.", + "type": "string" + }, + "name": { + "description": "Identifier. The resource name of the SCIM Tenant. Format: `locations/{location}/workforcePools/{workforce_pool}/providers/ {workforce_pool_provider}/scimTenants/{scim_tenant}`", + "type": "string" + }, + "purgeTime": { + "description": "Output only. The timestamp when the scim tenant is going to be purged.", + "format": "google-datetime", + "readOnly": true, + "type": "string" + }, + "state": { + "description": "Output only. The state of the tenant.", + "enum": [ + "STATE_UNSPECIFIED", + "ACTIVE", + "DELETED" + ], + "enumDescriptions": [ + "State unspecified.", + "The tenant is active and may be used to provision users and groups.", + "The tenant is soft-deleted. Soft-deleted tenants are permanently deleted after approximately 30 days." + ], + "readOnly": true, + "type": "string" + } + }, + "type": "object" + }, + "WorkforcePoolProviderScimToken": { + "description": "Represents a token for the WorkforcePoolProviderScimTenant. Used for authenticating SCIM Provisioning requests.", + "id": "WorkforcePoolProviderScimToken", + "properties": { + "displayName": { + "description": "Optional. The user-specified display name of the scim token. Cannot exceed 32 characters.", + "type": "string" + }, + "name": { + "description": "Identifier. The resource name of the SCIM Token. Format: `locations/{location}/workforcePools/{workforce_pool}/providers/ {workforce_pool_provider}/scimTenants/{scim_tenant}/tokens/{token}`", + "type": "string" + }, + "securityToken": { + "description": "Output only. The token string. Provide this to the IdP for authentication. Will be set only during creation.", + "readOnly": true, + "type": "string" + }, + "state": { + "description": "Output only. The state of the token.", + "enum": [ + "STATE_UNSPECIFIED", + "ACTIVE", + "DELETED" + ], + "enumDescriptions": [ + "State unspecified.", + "The tenant is active and may be used to provision users and groups.", + "The tenant is soft-deleted. Soft-deleted tenants are permanently deleted after approximately 30 days." + ], + "readOnly": true, + "type": "string" + } + }, + "type": "object" + }, "WorkloadIdentityPool": { "description": "Represents a collection of workload identities. You can define IAM policies to grant these identities access to Google Cloud resources.", "id": "WorkloadIdentityPool", diff --git a/iam/v1/iam-gen.go b/iam/v1/iam-gen.go index 750ecc909b9..8d87a6823d1 100644 --- a/iam/v1/iam-gen.go +++ b/iam/v1/iam-gen.go @@ -221,6 +221,7 @@ func NewLocationsWorkforcePoolsProvidersService(s *Service) *LocationsWorkforceP rs := &LocationsWorkforcePoolsProvidersService{s: s} rs.Keys = NewLocationsWorkforcePoolsProvidersKeysService(s) rs.Operations = NewLocationsWorkforcePoolsProvidersOperationsService(s) + rs.ScimTenants = NewLocationsWorkforcePoolsProvidersScimTenantsService(s) return rs } @@ -230,6 +231,8 @@ type LocationsWorkforcePoolsProvidersService struct { Keys *LocationsWorkforcePoolsProvidersKeysService Operations *LocationsWorkforcePoolsProvidersOperationsService + + ScimTenants *LocationsWorkforcePoolsProvidersScimTenantsService } func NewLocationsWorkforcePoolsProvidersKeysService(s *Service) *LocationsWorkforcePoolsProvidersKeysService { @@ -262,6 +265,27 @@ type LocationsWorkforcePoolsProvidersOperationsService struct { s *Service } +func NewLocationsWorkforcePoolsProvidersScimTenantsService(s *Service) *LocationsWorkforcePoolsProvidersScimTenantsService { + rs := &LocationsWorkforcePoolsProvidersScimTenantsService{s: s} + rs.Tokens = NewLocationsWorkforcePoolsProvidersScimTenantsTokensService(s) + return rs +} + +type LocationsWorkforcePoolsProvidersScimTenantsService struct { + s *Service + + Tokens *LocationsWorkforcePoolsProvidersScimTenantsTokensService +} + +func NewLocationsWorkforcePoolsProvidersScimTenantsTokensService(s *Service) *LocationsWorkforcePoolsProvidersScimTenantsTokensService { + rs := &LocationsWorkforcePoolsProvidersScimTenantsTokensService{s: s} + return rs +} + +type LocationsWorkforcePoolsProvidersScimTenantsTokensService struct { + s *Service +} + func NewLocationsWorkforcePoolsSubjectsService(s *Service) *LocationsWorkforcePoolsSubjectsService { rs := &LocationsWorkforcePoolsSubjectsService{s: s} rs.Operations = NewLocationsWorkforcePoolsSubjectsOperationsService(s) @@ -1976,6 +2000,66 @@ func (s ListWorkforcePoolProviderKeysResponse) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// ListWorkforcePoolProviderScimTenantsResponse: Response message for +// ListWorkforcePoolProviderScimTenants. +type ListWorkforcePoolProviderScimTenantsResponse struct { + // NextPageToken: Optional. A token, which can be sent as `page_token` to + // retrieve the next page. If this field is omitted, there are no subsequent + // pages. + NextPageToken string `json:"nextPageToken,omitempty"` + // WorkforcePoolProviderScimTenants: Output only. A list of scim tenants. + WorkforcePoolProviderScimTenants []*WorkforcePoolProviderScimTenant `json:"workforcePoolProviderScimTenants,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 ListWorkforcePoolProviderScimTenantsResponse) MarshalJSON() ([]byte, error) { + type NoMethod ListWorkforcePoolProviderScimTenantsResponse + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// ListWorkforcePoolProviderScimTokensResponse: Response message for +// ListWorkforcePoolProviderScimTokens. +type ListWorkforcePoolProviderScimTokensResponse struct { + // NextPageToken: Optional. A token, which can be sent as `page_token` to + // retrieve the next page. If this field is omitted, there are no subsequent + // pages. + NextPageToken string `json:"nextPageToken,omitempty"` + // WorkforcePoolProviderScimTokens: Output only. A list of scim tokens. + WorkforcePoolProviderScimTokens []*WorkforcePoolProviderScimToken `json:"workforcePoolProviderScimTokens,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 ListWorkforcePoolProviderScimTokensResponse) MarshalJSON() ([]byte, error) { + type NoMethod ListWorkforcePoolProviderScimTokensResponse + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // ListWorkforcePoolProvidersResponse: Response message for // ListWorkforcePoolProviders. type ListWorkforcePoolProvidersResponse struct { @@ -3570,6 +3654,16 @@ type UndeleteWorkforcePoolProviderKeyRequest struct { type UndeleteWorkforcePoolProviderRequest struct { } +// UndeleteWorkforcePoolProviderScimTenantRequest: Request message for +// UndeleteWorkforcePoolProviderScimTenant. +type UndeleteWorkforcePoolProviderScimTenantRequest struct { +} + +// UndeleteWorkforcePoolProviderScimTokenRequest: Request message for +// UndeleteWorkforcePoolProviderScimToken. +type UndeleteWorkforcePoolProviderScimTokenRequest struct { +} + // UndeleteWorkforcePoolRequest: Request message for UndeleteWorkforcePool. type UndeleteWorkforcePoolRequest struct { } @@ -3778,6 +3872,18 @@ type WorkforcePoolProvider struct { // ExpireTime: Output only. Time after which the workload pool provider will be // permanently purged and cannot be recovered. ExpireTime string `json:"expireTime,omitempty"` + // ExtendedAttributesOauth2Client: Optional. The configuration for OAuth 2.0 + // client used to get the extended group memberships for user identities. Only + // the `AZURE_AD_GROUPS_ID` attribute type is supported. Extended groups + // supports a subset of Google Cloud services. When the user accesses these + // services, extended group memberships override the mapped `google.groups` + // attribute. Extended group memberships cannot be used in attribute mapping or + // attribute condition expressions. To keep extended group memberships up to + // date, extended groups are retrieved when the user signs in and at regular + // intervals during the user's active session. Each user identity in the + // workforce identity pool must map to a specific, unique Microsoft Entra ID + // user. + ExtendedAttributesOauth2Client *GoogleIamAdminV1WorkforcePoolProviderExtraAttributesOAuth2Client `json:"extendedAttributesOauth2Client,omitempty"` // ExtraAttributesOauth2Client: Optional. The configuration for OAuth 2.0 // client used to get the additional user attributes. This should be used when // users can't get the desired claims in authentication credentials. Currently @@ -3873,6 +3979,104 @@ func (s WorkforcePoolProviderKey) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// WorkforcePoolProviderScimTenant: Represents a scim tenant. Used for +// provisioning and managing identity data (such as Users and Groups) in +// cross-domain environments. +type WorkforcePoolProviderScimTenant struct { + // BaseUri: Output only. Represents the base URI as defined in RFC 7644, + // Section 1.3 (https://datatracker.ietf.org/doc/html/rfc7644#section-1.3). + // Clients must use this as the root address for managing resources under the + // tenant. Format: https://iamscim.googleapis.com/{version}/{tenant_id}/ + BaseUri string `json:"baseUri,omitempty"` + // ClaimMapping: Optional. Maps BYOID claims to SCIM claims. + ClaimMapping map[string]string `json:"claimMapping,omitempty"` + // Description: Optional. The user-specified description of the scim tenant. + // Cannot exceed 256 characters. + Description string `json:"description,omitempty"` + // DisplayName: Optional. The user-specified display name of the scim tenant. + // Cannot exceed 32 characters. + DisplayName string `json:"displayName,omitempty"` + // Name: Identifier. The resource name of the SCIM Tenant. Format: + // `locations/{location}/workforcePools/{workforce_pool}/providers/ + // {workforce_pool_provider}/scimTenants/{scim_tenant}` + Name string `json:"name,omitempty"` + // PurgeTime: Output only. The timestamp when the scim tenant is going to be + // purged. + PurgeTime string `json:"purgeTime,omitempty"` + // State: Output only. The state of the tenant. + // + // Possible values: + // "STATE_UNSPECIFIED" - State unspecified. + // "ACTIVE" - The tenant is active and may be used to provision users and + // groups. + // "DELETED" - The tenant is soft-deleted. Soft-deleted tenants are + // permanently deleted after approximately 30 days. + State string `json:"state,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the server. + googleapi.ServerResponse `json:"-"` + // ForceSendFields is a list of field names (e.g. "BaseUri") 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. "BaseUri") 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 WorkforcePoolProviderScimTenant) MarshalJSON() ([]byte, error) { + type NoMethod WorkforcePoolProviderScimTenant + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// WorkforcePoolProviderScimToken: Represents a token for the +// WorkforcePoolProviderScimTenant. Used for authenticating SCIM Provisioning +// requests. +type WorkforcePoolProviderScimToken struct { + // DisplayName: Optional. The user-specified display name of the scim token. + // Cannot exceed 32 characters. + DisplayName string `json:"displayName,omitempty"` + // Name: Identifier. The resource name of the SCIM Token. Format: + // `locations/{location}/workforcePools/{workforce_pool}/providers/ + // {workforce_pool_provider}/scimTenants/{scim_tenant}/tokens/{token}` + Name string `json:"name,omitempty"` + // SecurityToken: Output only. The token string. Provide this to the IdP for + // authentication. Will be set only during creation. + SecurityToken string `json:"securityToken,omitempty"` + // State: Output only. The state of the token. + // + // Possible values: + // "STATE_UNSPECIFIED" - State unspecified. + // "ACTIVE" - The tenant is active and may be used to provision users and + // groups. + // "DELETED" - The tenant is soft-deleted. Soft-deleted tenants are + // permanently deleted after approximately 30 days. + State string `json:"state,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the server. + googleapi.ServerResponse `json:"-"` + // ForceSendFields is a list of field names (e.g. "DisplayName") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "DisplayName") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s WorkforcePoolProviderScimToken) MarshalJSON() ([]byte, error) { + type NoMethod WorkforcePoolProviderScimToken + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // WorkloadIdentityPool: Represents a collection of workload identities. You // can define IAM policies to grant these identities access to Google Cloud // resources. @@ -7089,6 +7293,1421 @@ func (c *LocationsWorkforcePoolsProvidersOperationsGetCall) Do(opts ...googleapi return ret, nil } +type LocationsWorkforcePoolsProvidersScimTenantsCreateCall struct { + s *Service + parent string + workforcepoolproviderscimtenant *WorkforcePoolProviderScimTenant + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Create: Creates a new WorkforcePoolProviderScimTenant in a +// WorkforcePoolProvider. You cannot reuse the name of a deleted scim tenant +// until 30 days after deletion. +// +// - parent: The parent to create scim tenant. Format: +// 'locations/{location}/workforcePools/{workforce_pool}/providers/{provider}'. +func (r *LocationsWorkforcePoolsProvidersScimTenantsService) Create(parent string, workforcepoolproviderscimtenant *WorkforcePoolProviderScimTenant) *LocationsWorkforcePoolsProvidersScimTenantsCreateCall { + c := &LocationsWorkforcePoolsProvidersScimTenantsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + c.workforcepoolproviderscimtenant = workforcepoolproviderscimtenant + return c +} + +// WorkforcePoolProviderScimTenantId sets the optional parameter +// "workforcePoolProviderScimTenantId": Required. The ID to use for the scim +// tenant, which becomes the final component of the resource name. This value +// should be 4-32 characters, and may contain the characters [a-z0-9-]. +func (c *LocationsWorkforcePoolsProvidersScimTenantsCreateCall) WorkforcePoolProviderScimTenantId(workforcePoolProviderScimTenantId string) *LocationsWorkforcePoolsProvidersScimTenantsCreateCall { + c.urlParams_.Set("workforcePoolProviderScimTenantId", workforcePoolProviderScimTenantId) + 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 *LocationsWorkforcePoolsProvidersScimTenantsCreateCall) Fields(s ...googleapi.Field) *LocationsWorkforcePoolsProvidersScimTenantsCreateCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *LocationsWorkforcePoolsProvidersScimTenantsCreateCall) Context(ctx context.Context) *LocationsWorkforcePoolsProvidersScimTenantsCreateCall { + 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 *LocationsWorkforcePoolsProvidersScimTenantsCreateCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *LocationsWorkforcePoolsProvidersScimTenantsCreateCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) + body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.workforcepoolproviderscimtenant) + if err != nil { + return nil, err + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/scimTenants") + 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, + }) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "iam.locations.workforcePools.providers.scimTenants.create", "request", internallog.HTTPRequest(req, body.Bytes())) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "iam.locations.workforcePools.providers.scimTenants.create" call. +// Any non-2xx status code is an error. Response headers are in either +// *WorkforcePoolProviderScimTenant.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 *LocationsWorkforcePoolsProvidersScimTenantsCreateCall) Do(opts ...googleapi.CallOption) (*WorkforcePoolProviderScimTenant, 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 := &WorkforcePoolProviderScimTenant{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + b, err := gensupport.DecodeResponseBytes(target, res) + if err != nil { + return nil, err + } + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "iam.locations.workforcePools.providers.scimTenants.create", "response", internallog.HTTPResponse(res, b)) + return ret, nil +} + +type LocationsWorkforcePoolsProvidersScimTenantsDeleteCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Delete: Deletes a WorkforcePoolProviderScimTenant. You can undelete a scim +// tenant for 30 days. After 30 days, deletion is permanent. You cannot update +// deleted scim tenants. However, you can view and list them. +// +// - name: The name of the scim tenant to delete. Format: +// `locations/{location}/workforcePools/{workforce_pool}/providers/{provider}/ +// scimTenants/{scim_tenant}`. +func (r *LocationsWorkforcePoolsProvidersScimTenantsService) Delete(name string) *LocationsWorkforcePoolsProvidersScimTenantsDeleteCall { + c := &LocationsWorkforcePoolsProvidersScimTenantsDeleteCall{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 *LocationsWorkforcePoolsProvidersScimTenantsDeleteCall) Fields(s ...googleapi.Field) *LocationsWorkforcePoolsProvidersScimTenantsDeleteCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *LocationsWorkforcePoolsProvidersScimTenantsDeleteCall) Context(ctx context.Context) *LocationsWorkforcePoolsProvidersScimTenantsDeleteCall { + 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 *LocationsWorkforcePoolsProvidersScimTenantsDeleteCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *LocationsWorkforcePoolsProvidersScimTenantsDeleteCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) + 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, nil) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "name": c.name, + }) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "iam.locations.workforcePools.providers.scimTenants.delete", "request", internallog.HTTPRequest(req, nil)) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "iam.locations.workforcePools.providers.scimTenants.delete" call. +// Any non-2xx status code is an error. Response headers are in either +// *WorkforcePoolProviderScimTenant.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 *LocationsWorkforcePoolsProvidersScimTenantsDeleteCall) Do(opts ...googleapi.CallOption) (*WorkforcePoolProviderScimTenant, 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 := &WorkforcePoolProviderScimTenant{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + b, err := gensupport.DecodeResponseBytes(target, res) + if err != nil { + return nil, err + } + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "iam.locations.workforcePools.providers.scimTenants.delete", "response", internallog.HTTPResponse(res, b)) + return ret, nil +} + +type LocationsWorkforcePoolsProvidersScimTenantsGetCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// Get: Gets an individual WorkforcePoolProviderScimTenant. +// +// - name: The name of the scim tenant to retrieve. Format: +// `locations/{location}/workforcePools/{workforce_pool}/providers/{provider}/ +// scimTenants/{scim_tenant}`. +func (r *LocationsWorkforcePoolsProvidersScimTenantsService) Get(name string) *LocationsWorkforcePoolsProvidersScimTenantsGetCall { + c := &LocationsWorkforcePoolsProvidersScimTenantsGetCall{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 *LocationsWorkforcePoolsProvidersScimTenantsGetCall) Fields(s ...googleapi.Field) *LocationsWorkforcePoolsProvidersScimTenantsGetCall { + 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 *LocationsWorkforcePoolsProvidersScimTenantsGetCall) IfNoneMatch(entityTag string) *LocationsWorkforcePoolsProvidersScimTenantsGetCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *LocationsWorkforcePoolsProvidersScimTenantsGetCall) Context(ctx context.Context) *LocationsWorkforcePoolsProvidersScimTenantsGetCall { + 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 *LocationsWorkforcePoolsProvidersScimTenantsGetCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *LocationsWorkforcePoolsProvidersScimTenantsGetCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) + } + 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, nil) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "name": c.name, + }) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "iam.locations.workforcePools.providers.scimTenants.get", "request", internallog.HTTPRequest(req, nil)) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "iam.locations.workforcePools.providers.scimTenants.get" call. +// Any non-2xx status code is an error. Response headers are in either +// *WorkforcePoolProviderScimTenant.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 *LocationsWorkforcePoolsProvidersScimTenantsGetCall) Do(opts ...googleapi.CallOption) (*WorkforcePoolProviderScimTenant, 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 := &WorkforcePoolProviderScimTenant{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + b, err := gensupport.DecodeResponseBytes(target, res) + if err != nil { + return nil, err + } + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "iam.locations.workforcePools.providers.scimTenants.get", "response", internallog.HTTPResponse(res, b)) + return ret, nil +} + +type LocationsWorkforcePoolsProvidersScimTenantsListCall struct { + s *Service + parent string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// List: Lists all non-deleted WorkforcePoolProviderScimTenants in a +// WorkforcePoolProvider. If `show_deleted` is set to `true`, then deleted scim +// tenants are also listed. +// +// - parent: The parent to list scim tenants. Format: +// 'locations/{location}/workforcePools/{workforce_pool}/providers/{provider}'. +func (r *LocationsWorkforcePoolsProvidersScimTenantsService) List(parent string) *LocationsWorkforcePoolsProvidersScimTenantsListCall { + c := &LocationsWorkforcePoolsProvidersScimTenantsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + return c +} + +// PageSize sets the optional parameter "pageSize": The maximum number of scim +// tenants to return. If unspecified, at most 1 scim tenant will be returned. +func (c *LocationsWorkforcePoolsProvidersScimTenantsListCall) PageSize(pageSize int64) *LocationsWorkforcePoolsProvidersScimTenantsListCall { + c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) + return c +} + +// PageToken sets the optional parameter "pageToken": A page token, received +// from a previous `ListScimTenants` call. Provide this to retrieve the +// subsequent page. +func (c *LocationsWorkforcePoolsProvidersScimTenantsListCall) PageToken(pageToken string) *LocationsWorkforcePoolsProvidersScimTenantsListCall { + c.urlParams_.Set("pageToken", pageToken) + return c +} + +// ShowDeleted sets the optional parameter "showDeleted": Whether to return +// soft-deleted scim tenants. +func (c *LocationsWorkforcePoolsProvidersScimTenantsListCall) ShowDeleted(showDeleted bool) *LocationsWorkforcePoolsProvidersScimTenantsListCall { + c.urlParams_.Set("showDeleted", fmt.Sprint(showDeleted)) + 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 *LocationsWorkforcePoolsProvidersScimTenantsListCall) Fields(s ...googleapi.Field) *LocationsWorkforcePoolsProvidersScimTenantsListCall { + 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 *LocationsWorkforcePoolsProvidersScimTenantsListCall) IfNoneMatch(entityTag string) *LocationsWorkforcePoolsProvidersScimTenantsListCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *LocationsWorkforcePoolsProvidersScimTenantsListCall) Context(ctx context.Context) *LocationsWorkforcePoolsProvidersScimTenantsListCall { + 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 *LocationsWorkforcePoolsProvidersScimTenantsListCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *LocationsWorkforcePoolsProvidersScimTenantsListCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/scimTenants") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("GET", urls, nil) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "parent": c.parent, + }) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "iam.locations.workforcePools.providers.scimTenants.list", "request", internallog.HTTPRequest(req, nil)) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "iam.locations.workforcePools.providers.scimTenants.list" call. +// Any non-2xx status code is an error. Response headers are in either +// *ListWorkforcePoolProviderScimTenantsResponse.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 *LocationsWorkforcePoolsProvidersScimTenantsListCall) Do(opts ...googleapi.CallOption) (*ListWorkforcePoolProviderScimTenantsResponse, 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 := &ListWorkforcePoolProviderScimTenantsResponse{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + b, err := gensupport.DecodeResponseBytes(target, res) + if err != nil { + return nil, err + } + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "iam.locations.workforcePools.providers.scimTenants.list", "response", internallog.HTTPResponse(res, b)) + 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 *LocationsWorkforcePoolsProvidersScimTenantsListCall) Pages(ctx context.Context, f func(*ListWorkforcePoolProviderScimTenantsResponse) 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 LocationsWorkforcePoolsProvidersScimTenantsPatchCall struct { + s *Service + name string + workforcepoolproviderscimtenant *WorkforcePoolProviderScimTenant + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Patch: Updates an existing WorkforcePoolProviderScimTenant. +// +// - name: Identifier. The resource name of the SCIM Tenant. Format: +// `locations/{location}/workforcePools/{workforce_pool}/providers/ +// {workforce_pool_provider}/scimTenants/{scim_tenant}`. +func (r *LocationsWorkforcePoolsProvidersScimTenantsService) Patch(name string, workforcepoolproviderscimtenant *WorkforcePoolProviderScimTenant) *LocationsWorkforcePoolsProvidersScimTenantsPatchCall { + c := &LocationsWorkforcePoolsProvidersScimTenantsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + c.workforcepoolproviderscimtenant = workforcepoolproviderscimtenant + return c +} + +// UpdateMask sets the optional parameter "updateMask": The list of fields to +// update. +func (c *LocationsWorkforcePoolsProvidersScimTenantsPatchCall) UpdateMask(updateMask string) *LocationsWorkforcePoolsProvidersScimTenantsPatchCall { + 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 *LocationsWorkforcePoolsProvidersScimTenantsPatchCall) Fields(s ...googleapi.Field) *LocationsWorkforcePoolsProvidersScimTenantsPatchCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *LocationsWorkforcePoolsProvidersScimTenantsPatchCall) Context(ctx context.Context) *LocationsWorkforcePoolsProvidersScimTenantsPatchCall { + 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 *LocationsWorkforcePoolsProvidersScimTenantsPatchCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *LocationsWorkforcePoolsProvidersScimTenantsPatchCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) + body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.workforcepoolproviderscimtenant) + if err != nil { + return nil, err + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("PATCH", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "name": c.name, + }) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "iam.locations.workforcePools.providers.scimTenants.patch", "request", internallog.HTTPRequest(req, body.Bytes())) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "iam.locations.workforcePools.providers.scimTenants.patch" call. +// Any non-2xx status code is an error. Response headers are in either +// *WorkforcePoolProviderScimTenant.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 *LocationsWorkforcePoolsProvidersScimTenantsPatchCall) Do(opts ...googleapi.CallOption) (*WorkforcePoolProviderScimTenant, 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 := &WorkforcePoolProviderScimTenant{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + b, err := gensupport.DecodeResponseBytes(target, res) + if err != nil { + return nil, err + } + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "iam.locations.workforcePools.providers.scimTenants.patch", "response", internallog.HTTPResponse(res, b)) + return ret, nil +} + +type LocationsWorkforcePoolsProvidersScimTenantsUndeleteCall struct { + s *Service + name string + undeleteworkforcepoolproviderscimtenantrequest *UndeleteWorkforcePoolProviderScimTenantRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Undelete: Undeletes a WorkforcePoolProviderScimTenant, as long as it was +// deleted fewer than 30 days ago. +// +// - name: The name of the scim tenant to undelete. Format: +// `locations/{location}/workforcePools/{workforce_pool}/providers/{provider}/ +// scimTenants/{scim_tenant}`. +func (r *LocationsWorkforcePoolsProvidersScimTenantsService) Undelete(name string, undeleteworkforcepoolproviderscimtenantrequest *UndeleteWorkforcePoolProviderScimTenantRequest) *LocationsWorkforcePoolsProvidersScimTenantsUndeleteCall { + c := &LocationsWorkforcePoolsProvidersScimTenantsUndeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + c.undeleteworkforcepoolproviderscimtenantrequest = undeleteworkforcepoolproviderscimtenantrequest + 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 *LocationsWorkforcePoolsProvidersScimTenantsUndeleteCall) Fields(s ...googleapi.Field) *LocationsWorkforcePoolsProvidersScimTenantsUndeleteCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *LocationsWorkforcePoolsProvidersScimTenantsUndeleteCall) Context(ctx context.Context) *LocationsWorkforcePoolsProvidersScimTenantsUndeleteCall { + 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 *LocationsWorkforcePoolsProvidersScimTenantsUndeleteCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *LocationsWorkforcePoolsProvidersScimTenantsUndeleteCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) + body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.undeleteworkforcepoolproviderscimtenantrequest) + if err != nil { + return nil, err + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}:undelete") + 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, + }) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "iam.locations.workforcePools.providers.scimTenants.undelete", "request", internallog.HTTPRequest(req, body.Bytes())) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "iam.locations.workforcePools.providers.scimTenants.undelete" call. +// Any non-2xx status code is an error. Response headers are in either +// *WorkforcePoolProviderScimTenant.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 *LocationsWorkforcePoolsProvidersScimTenantsUndeleteCall) Do(opts ...googleapi.CallOption) (*WorkforcePoolProviderScimTenant, 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 := &WorkforcePoolProviderScimTenant{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + b, err := gensupport.DecodeResponseBytes(target, res) + if err != nil { + return nil, err + } + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "iam.locations.workforcePools.providers.scimTenants.undelete", "response", internallog.HTTPResponse(res, b)) + return ret, nil +} + +type LocationsWorkforcePoolsProvidersScimTenantsTokensCreateCall struct { + s *Service + parent string + workforcepoolproviderscimtoken *WorkforcePoolProviderScimToken + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Create: Creates a new WorkforcePoolProviderScimToken in a +// WorkforcePoolProviderScimTenant. You cannot reuse the name of a deleted SCIM +// token until 30 days after deletion. +// +// - parent: The parent tenant to create scim token. Format: +// 'locations/{location}/workforcePools/{workforce_pool}/providers/{provider}/ +// scimTenants/{scim_tenant}'. +func (r *LocationsWorkforcePoolsProvidersScimTenantsTokensService) Create(parent string, workforcepoolproviderscimtoken *WorkforcePoolProviderScimToken) *LocationsWorkforcePoolsProvidersScimTenantsTokensCreateCall { + c := &LocationsWorkforcePoolsProvidersScimTenantsTokensCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + c.workforcepoolproviderscimtoken = workforcepoolproviderscimtoken + return c +} + +// WorkforcePoolProviderScimTokenId sets the optional parameter +// "workforcePoolProviderScimTokenId": Required. The ID to use for the scim +// token, which becomes the final component of the resource name. This value +// should be 4-32 characters and follow this pattern: "(a-z +// ([a-z0-9\\-]{2,30}[a-z0-9]))" +func (c *LocationsWorkforcePoolsProvidersScimTenantsTokensCreateCall) WorkforcePoolProviderScimTokenId(workforcePoolProviderScimTokenId string) *LocationsWorkforcePoolsProvidersScimTenantsTokensCreateCall { + c.urlParams_.Set("workforcePoolProviderScimTokenId", workforcePoolProviderScimTokenId) + 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 *LocationsWorkforcePoolsProvidersScimTenantsTokensCreateCall) Fields(s ...googleapi.Field) *LocationsWorkforcePoolsProvidersScimTenantsTokensCreateCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *LocationsWorkforcePoolsProvidersScimTenantsTokensCreateCall) Context(ctx context.Context) *LocationsWorkforcePoolsProvidersScimTenantsTokensCreateCall { + 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 *LocationsWorkforcePoolsProvidersScimTenantsTokensCreateCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *LocationsWorkforcePoolsProvidersScimTenantsTokensCreateCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) + body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.workforcepoolproviderscimtoken) + if err != nil { + return nil, err + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/tokens") + 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, + }) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "iam.locations.workforcePools.providers.scimTenants.tokens.create", "request", internallog.HTTPRequest(req, body.Bytes())) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "iam.locations.workforcePools.providers.scimTenants.tokens.create" call. +// Any non-2xx status code is an error. Response headers are in either +// *WorkforcePoolProviderScimToken.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 *LocationsWorkforcePoolsProvidersScimTenantsTokensCreateCall) Do(opts ...googleapi.CallOption) (*WorkforcePoolProviderScimToken, 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 := &WorkforcePoolProviderScimToken{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + b, err := gensupport.DecodeResponseBytes(target, res) + if err != nil { + return nil, err + } + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "iam.locations.workforcePools.providers.scimTenants.tokens.create", "response", internallog.HTTPResponse(res, b)) + return ret, nil +} + +type LocationsWorkforcePoolsProvidersScimTenantsTokensDeleteCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Delete: Deletes a WorkforcePoolProviderScimToken. You can undelete a scim +// token for 30 days. After 30 days, deletion is permanent. You cannot update +// deleted scim tokens. However, you can view and list them. +// +// - name: The name of the scim token to delete. Format: +// `locations/{location}/workforcePools/{workforce_pool}/providers/{provider}/ +// scimTenants/{scim_tenant}/tokens/{token}`. +func (r *LocationsWorkforcePoolsProvidersScimTenantsTokensService) Delete(name string) *LocationsWorkforcePoolsProvidersScimTenantsTokensDeleteCall { + c := &LocationsWorkforcePoolsProvidersScimTenantsTokensDeleteCall{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 *LocationsWorkforcePoolsProvidersScimTenantsTokensDeleteCall) Fields(s ...googleapi.Field) *LocationsWorkforcePoolsProvidersScimTenantsTokensDeleteCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *LocationsWorkforcePoolsProvidersScimTenantsTokensDeleteCall) Context(ctx context.Context) *LocationsWorkforcePoolsProvidersScimTenantsTokensDeleteCall { + 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 *LocationsWorkforcePoolsProvidersScimTenantsTokensDeleteCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *LocationsWorkforcePoolsProvidersScimTenantsTokensDeleteCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) + 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, nil) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "name": c.name, + }) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "iam.locations.workforcePools.providers.scimTenants.tokens.delete", "request", internallog.HTTPRequest(req, nil)) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "iam.locations.workforcePools.providers.scimTenants.tokens.delete" call. +// Any non-2xx status code is an error. Response headers are in either +// *WorkforcePoolProviderScimToken.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 *LocationsWorkforcePoolsProvidersScimTenantsTokensDeleteCall) Do(opts ...googleapi.CallOption) (*WorkforcePoolProviderScimToken, 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 := &WorkforcePoolProviderScimToken{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + b, err := gensupport.DecodeResponseBytes(target, res) + if err != nil { + return nil, err + } + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "iam.locations.workforcePools.providers.scimTenants.tokens.delete", "response", internallog.HTTPResponse(res, b)) + return ret, nil +} + +type LocationsWorkforcePoolsProvidersScimTenantsTokensGetCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// Get: Gets an individual WorkforcePoolProviderScimToken. +// +// - name: The name of the scim token to retrieve. Format: +// `locations/{location}/workforcePools/{workforce_pool}/providers/{provider}/ +// scimTenants/{scim_tenant}/tokens/{token}`. +func (r *LocationsWorkforcePoolsProvidersScimTenantsTokensService) Get(name string) *LocationsWorkforcePoolsProvidersScimTenantsTokensGetCall { + c := &LocationsWorkforcePoolsProvidersScimTenantsTokensGetCall{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 *LocationsWorkforcePoolsProvidersScimTenantsTokensGetCall) Fields(s ...googleapi.Field) *LocationsWorkforcePoolsProvidersScimTenantsTokensGetCall { + 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 *LocationsWorkforcePoolsProvidersScimTenantsTokensGetCall) IfNoneMatch(entityTag string) *LocationsWorkforcePoolsProvidersScimTenantsTokensGetCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *LocationsWorkforcePoolsProvidersScimTenantsTokensGetCall) Context(ctx context.Context) *LocationsWorkforcePoolsProvidersScimTenantsTokensGetCall { + 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 *LocationsWorkforcePoolsProvidersScimTenantsTokensGetCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *LocationsWorkforcePoolsProvidersScimTenantsTokensGetCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) + } + 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, nil) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "name": c.name, + }) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "iam.locations.workforcePools.providers.scimTenants.tokens.get", "request", internallog.HTTPRequest(req, nil)) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "iam.locations.workforcePools.providers.scimTenants.tokens.get" call. +// Any non-2xx status code is an error. Response headers are in either +// *WorkforcePoolProviderScimToken.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 *LocationsWorkforcePoolsProvidersScimTenantsTokensGetCall) Do(opts ...googleapi.CallOption) (*WorkforcePoolProviderScimToken, 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 := &WorkforcePoolProviderScimToken{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + b, err := gensupport.DecodeResponseBytes(target, res) + if err != nil { + return nil, err + } + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "iam.locations.workforcePools.providers.scimTenants.tokens.get", "response", internallog.HTTPResponse(res, b)) + return ret, nil +} + +type LocationsWorkforcePoolsProvidersScimTenantsTokensListCall struct { + s *Service + parent string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// List: Lists all non-deleted WorkforcePoolProviderScimTokenss in a +// WorkforcePoolProviderScimTenant. If `show_deleted` is set to `true`, then +// deleted SCIM tokens are also listed. +// +// - parent: The parent to list scim tokens. Format: +// 'locations/{location}/workforcePools/{workforce_pool}/providers/{provider}/ +// scimTenants/{scim_tenant}'. +func (r *LocationsWorkforcePoolsProvidersScimTenantsTokensService) List(parent string) *LocationsWorkforcePoolsProvidersScimTenantsTokensListCall { + c := &LocationsWorkforcePoolsProvidersScimTenantsTokensListCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + return c +} + +// PageSize sets the optional parameter "pageSize": The maximum number of scim +// tokens to return. If unspecified, at most 2 scim tokens will be returned. +func (c *LocationsWorkforcePoolsProvidersScimTenantsTokensListCall) PageSize(pageSize int64) *LocationsWorkforcePoolsProvidersScimTenantsTokensListCall { + c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) + return c +} + +// PageToken sets the optional parameter "pageToken": A page token, received +// from a previous `ListWorkforcePoolProviderScimTokens` call. Provide this to +// retrieve the subsequent page. +func (c *LocationsWorkforcePoolsProvidersScimTenantsTokensListCall) PageToken(pageToken string) *LocationsWorkforcePoolsProvidersScimTenantsTokensListCall { + c.urlParams_.Set("pageToken", pageToken) + return c +} + +// ShowDeleted sets the optional parameter "showDeleted": Whether to return +// soft-deleted scim tokens. +func (c *LocationsWorkforcePoolsProvidersScimTenantsTokensListCall) ShowDeleted(showDeleted bool) *LocationsWorkforcePoolsProvidersScimTenantsTokensListCall { + c.urlParams_.Set("showDeleted", fmt.Sprint(showDeleted)) + 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 *LocationsWorkforcePoolsProvidersScimTenantsTokensListCall) Fields(s ...googleapi.Field) *LocationsWorkforcePoolsProvidersScimTenantsTokensListCall { + 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 *LocationsWorkforcePoolsProvidersScimTenantsTokensListCall) IfNoneMatch(entityTag string) *LocationsWorkforcePoolsProvidersScimTenantsTokensListCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *LocationsWorkforcePoolsProvidersScimTenantsTokensListCall) Context(ctx context.Context) *LocationsWorkforcePoolsProvidersScimTenantsTokensListCall { + 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 *LocationsWorkforcePoolsProvidersScimTenantsTokensListCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *LocationsWorkforcePoolsProvidersScimTenantsTokensListCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/tokens") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("GET", urls, nil) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "parent": c.parent, + }) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "iam.locations.workforcePools.providers.scimTenants.tokens.list", "request", internallog.HTTPRequest(req, nil)) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "iam.locations.workforcePools.providers.scimTenants.tokens.list" call. +// Any non-2xx status code is an error. Response headers are in either +// *ListWorkforcePoolProviderScimTokensResponse.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 *LocationsWorkforcePoolsProvidersScimTenantsTokensListCall) Do(opts ...googleapi.CallOption) (*ListWorkforcePoolProviderScimTokensResponse, 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 := &ListWorkforcePoolProviderScimTokensResponse{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + b, err := gensupport.DecodeResponseBytes(target, res) + if err != nil { + return nil, err + } + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "iam.locations.workforcePools.providers.scimTenants.tokens.list", "response", internallog.HTTPResponse(res, b)) + 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 *LocationsWorkforcePoolsProvidersScimTenantsTokensListCall) Pages(ctx context.Context, f func(*ListWorkforcePoolProviderScimTokensResponse) 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 LocationsWorkforcePoolsProvidersScimTenantsTokensPatchCall struct { + s *Service + name string + workforcepoolproviderscimtoken *WorkforcePoolProviderScimToken + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Patch: Updates an existing WorkforcePoolProviderScimToken. +// +// - name: Identifier. The resource name of the SCIM Token. Format: +// `locations/{location}/workforcePools/{workforce_pool}/providers/ +// {workforce_pool_provider}/scimTenants/{scim_tenant}/tokens/{token}`. +func (r *LocationsWorkforcePoolsProvidersScimTenantsTokensService) Patch(name string, workforcepoolproviderscimtoken *WorkforcePoolProviderScimToken) *LocationsWorkforcePoolsProvidersScimTenantsTokensPatchCall { + c := &LocationsWorkforcePoolsProvidersScimTenantsTokensPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + c.workforcepoolproviderscimtoken = workforcepoolproviderscimtoken + return c +} + +// UpdateMask sets the optional parameter "updateMask": The list of fields to +// update. +func (c *LocationsWorkforcePoolsProvidersScimTenantsTokensPatchCall) UpdateMask(updateMask string) *LocationsWorkforcePoolsProvidersScimTenantsTokensPatchCall { + 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 *LocationsWorkforcePoolsProvidersScimTenantsTokensPatchCall) Fields(s ...googleapi.Field) *LocationsWorkforcePoolsProvidersScimTenantsTokensPatchCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *LocationsWorkforcePoolsProvidersScimTenantsTokensPatchCall) Context(ctx context.Context) *LocationsWorkforcePoolsProvidersScimTenantsTokensPatchCall { + 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 *LocationsWorkforcePoolsProvidersScimTenantsTokensPatchCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *LocationsWorkforcePoolsProvidersScimTenantsTokensPatchCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) + body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.workforcepoolproviderscimtoken) + if err != nil { + return nil, err + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("PATCH", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "name": c.name, + }) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "iam.locations.workforcePools.providers.scimTenants.tokens.patch", "request", internallog.HTTPRequest(req, body.Bytes())) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "iam.locations.workforcePools.providers.scimTenants.tokens.patch" call. +// Any non-2xx status code is an error. Response headers are in either +// *WorkforcePoolProviderScimToken.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 *LocationsWorkforcePoolsProvidersScimTenantsTokensPatchCall) Do(opts ...googleapi.CallOption) (*WorkforcePoolProviderScimToken, 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 := &WorkforcePoolProviderScimToken{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + b, err := gensupport.DecodeResponseBytes(target, res) + if err != nil { + return nil, err + } + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "iam.locations.workforcePools.providers.scimTenants.tokens.patch", "response", internallog.HTTPResponse(res, b)) + return ret, nil +} + +type LocationsWorkforcePoolsProvidersScimTenantsTokensUndeleteCall struct { + s *Service + name string + undeleteworkforcepoolproviderscimtokenrequest *UndeleteWorkforcePoolProviderScimTokenRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Undelete: Undeletes a WorkforcePoolProviderScimToken, as long as it was +// deleted fewer than 30 days ago. +// +// - name: The name of the scim token to undelete. Format: +// `locations/{location}/workforcePools/{workforce_pool}/providers/{provider}/ +// scimTenants/{scim_tenant}/tokens/{token}`. +func (r *LocationsWorkforcePoolsProvidersScimTenantsTokensService) Undelete(name string, undeleteworkforcepoolproviderscimtokenrequest *UndeleteWorkforcePoolProviderScimTokenRequest) *LocationsWorkforcePoolsProvidersScimTenantsTokensUndeleteCall { + c := &LocationsWorkforcePoolsProvidersScimTenantsTokensUndeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + c.undeleteworkforcepoolproviderscimtokenrequest = undeleteworkforcepoolproviderscimtokenrequest + 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 *LocationsWorkforcePoolsProvidersScimTenantsTokensUndeleteCall) Fields(s ...googleapi.Field) *LocationsWorkforcePoolsProvidersScimTenantsTokensUndeleteCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *LocationsWorkforcePoolsProvidersScimTenantsTokensUndeleteCall) Context(ctx context.Context) *LocationsWorkforcePoolsProvidersScimTenantsTokensUndeleteCall { + 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 *LocationsWorkforcePoolsProvidersScimTenantsTokensUndeleteCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *LocationsWorkforcePoolsProvidersScimTenantsTokensUndeleteCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) + body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.undeleteworkforcepoolproviderscimtokenrequest) + if err != nil { + return nil, err + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}:undelete") + 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, + }) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "iam.locations.workforcePools.providers.scimTenants.tokens.undelete", "request", internallog.HTTPRequest(req, body.Bytes())) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "iam.locations.workforcePools.providers.scimTenants.tokens.undelete" call. +// Any non-2xx status code is an error. Response headers are in either +// *WorkforcePoolProviderScimToken.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 *LocationsWorkforcePoolsProvidersScimTenantsTokensUndeleteCall) Do(opts ...googleapi.CallOption) (*WorkforcePoolProviderScimToken, 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 := &WorkforcePoolProviderScimToken{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + b, err := gensupport.DecodeResponseBytes(target, res) + if err != nil { + return nil, err + } + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "iam.locations.workforcePools.providers.scimTenants.tokens.undelete", "response", internallog.HTTPResponse(res, b)) + return ret, nil +} + type LocationsWorkforcePoolsSubjectsDeleteCall struct { s *Service name string diff --git a/merchantapi/accounts_v1beta/merchantapi-api.json b/merchantapi/accounts_v1beta/merchantapi-api.json index 0b8945fc73d..afe957eb852 100644 --- a/merchantapi/accounts_v1beta/merchantapi-api.json +++ b/merchantapi/accounts_v1beta/merchantapi-api.json @@ -180,31 +180,6 @@ "https://www.googleapis.com/auth/content" ] }, - "getDeveloperRegistration": { - "description": "Retrieves a developer registration for a merchant.", - "flatPath": "accounts/v1beta/accounts/{accountsId}/developerRegistration", - "httpMethod": "GET", - "id": "merchantapi.accounts.getDeveloperRegistration", - "parameterOrder": [ - "name" - ], - "parameters": { - "name": { - "description": "Required. The `name` (ID) of the developer registration.", - "location": "path", - "pattern": "^accounts/[^/]+/developerRegistration$", - "required": true, - "type": "string" - } - }, - "path": "accounts/v1beta/{+name}", - "response": { - "$ref": "DeveloperRegistration" - }, - "scopes": [ - "https://www.googleapis.com/auth/content" - ] - }, "list": { "description": "Note: For the `accounts.list` method, quota and limits usage are charged for each user, and not for the Merchant Center ID or the advanced account ID. To list several sub-accounts, you should use the `accounts.listSubaccounts` method, which is more suitable for advanced accounts use case.", "flatPath": "accounts/v1beta/accounts", @@ -563,6 +538,31 @@ }, "developerRegistration": { "methods": { + "getDeveloperRegistration": { + "description": "Retrieves a developer registration for a merchant.", + "flatPath": "accounts/v1beta/accounts/{accountsId}/developerRegistration", + "httpMethod": "GET", + "id": "merchantapi.accounts.developerRegistration.getDeveloperRegistration", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Required. The `name` (ID) of the developer registration.", + "location": "path", + "pattern": "^accounts/[^/]+/developerRegistration$", + "required": true, + "type": "string" + } + }, + "path": "accounts/v1beta/{+name}", + "response": { + "$ref": "DeveloperRegistration" + }, + "scopes": [ + "https://www.googleapis.com/auth/content" + ] + }, "registerGcp": { "description": "Registers the GCP used for the API call to the shopping account passed in the request. Will create a user with an \"API developer\" and add the \"developer_email\" as a contact with \"API notifications\" email preference on.", "flatPath": "accounts/v1beta/accounts/{accountsId}/developerRegistration:registerGcp", @@ -582,7 +582,7 @@ }, "path": "accounts/v1beta/{+name}:registerGcp", "request": { - "$ref": "RegisterGCPRequest" + "$ref": "RegisterGcpRequest" }, "response": { "$ref": "DeveloperRegistration" @@ -610,7 +610,7 @@ }, "path": "accounts/v1beta/{+name}:unregisterGcp", "request": { - "$ref": "UnregisterGCPRequest" + "$ref": "UnregisterGcpRequest" }, "response": { "$ref": "Empty" @@ -2311,7 +2311,7 @@ } } }, - "revision": "20250715", + "revision": "20250721", "rootUrl": "https://merchantapi.googleapis.com/", "schemas": { "About": { @@ -4766,9 +4766,9 @@ }, "type": "object" }, - "RegisterGCPRequest": { + "RegisterGcpRequest": { "description": "Request message for the RegisterGCP method.", - "id": "RegisterGCPRequest", + "id": "RegisterGcpRequest", "properties": { "developerEmail": { "description": "Immutable. If the developer email provided is associated with a user in the merchant account provided, the user will be updated to have \"API developer\" access type and the email preference corresponding to that user will be updated to have the new \"API notifications\" preference. If the developer email provided is not associated with any user we will just add it as a contact. The email preference corresponding to that contact will have the new \"API notifications\" preference", @@ -5268,9 +5268,9 @@ "properties": {}, "type": "object" }, - "UnregisterGCPRequest": { + "UnregisterGcpRequest": { "description": "Request message for the UnregisterGCP method.", - "id": "UnregisterGCPRequest", + "id": "UnregisterGcpRequest", "properties": {}, "type": "object" }, diff --git a/merchantapi/accounts_v1beta/merchantapi-gen.go b/merchantapi/accounts_v1beta/merchantapi-gen.go index bfec7467ec1..5673ada4d29 100644 --- a/merchantapi/accounts_v1beta/merchantapi-gen.go +++ b/merchantapi/accounts_v1beta/merchantapi-gen.go @@ -3684,8 +3684,8 @@ func (s Region) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// RegisterGCPRequest: Request message for the RegisterGCP method. -type RegisterGCPRequest struct { +// RegisterGcpRequest: Request message for the RegisterGCP method. +type RegisterGcpRequest struct { // DeveloperEmail: Immutable. If the developer email provided is associated // with a user in the merchant account provided, the user will be updated to // have "API developer" access type and the email preference corresponding to @@ -3707,8 +3707,8 @@ type RegisterGCPRequest struct { NullFields []string `json:"-"` } -func (s RegisterGCPRequest) MarshalJSON() ([]byte, error) { - type NoMethod RegisterGCPRequest +func (s RegisterGcpRequest) MarshalJSON() ([]byte, error) { + type NoMethod RegisterGcpRequest return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } @@ -4400,8 +4400,8 @@ func (s TransitTimeValue) MarshalJSON() ([]byte, error) { type UnclaimHomepageRequest struct { } -// UnregisterGCPRequest: Request message for the UnregisterGCP method. -type UnregisterGCPRequest struct { +// UnregisterGcpRequest: Request message for the UnregisterGCP method. +type UnregisterGcpRequest struct { } // UriSettings: URL settings for cart or checkout URL. @@ -4974,116 +4974,6 @@ func (c *AccountsGetCall) Do(opts ...googleapi.CallOption) (*Account, error) { return ret, nil } -type AccountsGetDeveloperRegistrationCall struct { - s *APIService - name string - urlParams_ gensupport.URLParams - ifNoneMatch_ string - ctx_ context.Context - header_ http.Header -} - -// GetDeveloperRegistration: Retrieves a developer registration for a merchant. -// -// - name: The `name` (ID) of the developer registration. -func (r *AccountsService) GetDeveloperRegistration(name string) *AccountsGetDeveloperRegistrationCall { - c := &AccountsGetDeveloperRegistrationCall{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 *AccountsGetDeveloperRegistrationCall) Fields(s ...googleapi.Field) *AccountsGetDeveloperRegistrationCall { - 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 *AccountsGetDeveloperRegistrationCall) IfNoneMatch(entityTag string) *AccountsGetDeveloperRegistrationCall { - c.ifNoneMatch_ = entityTag - return c -} - -// Context sets the context to be used in this call's Do method. -func (c *AccountsGetDeveloperRegistrationCall) Context(ctx context.Context) *AccountsGetDeveloperRegistrationCall { - 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 *AccountsGetDeveloperRegistrationCall) Header() http.Header { - if c.header_ == nil { - c.header_ = make(http.Header) - } - return c.header_ -} - -func (c *AccountsGetDeveloperRegistrationCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) - if c.ifNoneMatch_ != "" { - reqHeaders.Set("If-None-Match", c.ifNoneMatch_) - } - c.urlParams_.Set("alt", alt) - c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "accounts/v1beta/{+name}") - urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("GET", urls, nil) - if err != nil { - return nil, err - } - req.Header = reqHeaders - googleapi.Expand(req.URL, map[string]string{ - "name": c.name, - }) - c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "merchantapi.accounts.getDeveloperRegistration", "request", internallog.HTTPRequest(req, nil)) - return gensupport.SendRequest(c.ctx_, c.s.client, req) -} - -// Do executes the "merchantapi.accounts.getDeveloperRegistration" call. -// Any non-2xx status code is an error. Response headers are in either -// *DeveloperRegistration.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 *AccountsGetDeveloperRegistrationCall) Do(opts ...googleapi.CallOption) (*DeveloperRegistration, 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 := &DeveloperRegistration{ - ServerResponse: googleapi.ServerResponse{ - Header: res.Header, - HTTPStatusCode: res.StatusCode, - }, - } - target := &ret - b, err := gensupport.DecodeResponseBytes(target, res) - if err != nil { - return nil, err - } - c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "merchantapi.accounts.getDeveloperRegistration", "response", internallog.HTTPResponse(res, b)) - return ret, nil -} - type AccountsListCall struct { s *APIService urlParams_ gensupport.URLParams @@ -6411,10 +6301,120 @@ func (c *AccountsBusinessInfoUpdateBusinessInfoCall) Do(opts ...googleapi.CallOp return ret, nil } +type AccountsDeveloperRegistrationGetDeveloperRegistrationCall struct { + s *APIService + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// GetDeveloperRegistration: Retrieves a developer registration for a merchant. +// +// - name: The `name` (ID) of the developer registration. +func (r *AccountsDeveloperRegistrationService) GetDeveloperRegistration(name string) *AccountsDeveloperRegistrationGetDeveloperRegistrationCall { + c := &AccountsDeveloperRegistrationGetDeveloperRegistrationCall{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 *AccountsDeveloperRegistrationGetDeveloperRegistrationCall) Fields(s ...googleapi.Field) *AccountsDeveloperRegistrationGetDeveloperRegistrationCall { + 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 *AccountsDeveloperRegistrationGetDeveloperRegistrationCall) IfNoneMatch(entityTag string) *AccountsDeveloperRegistrationGetDeveloperRegistrationCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *AccountsDeveloperRegistrationGetDeveloperRegistrationCall) Context(ctx context.Context) *AccountsDeveloperRegistrationGetDeveloperRegistrationCall { + 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 *AccountsDeveloperRegistrationGetDeveloperRegistrationCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *AccountsDeveloperRegistrationGetDeveloperRegistrationCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "accounts/v1beta/{+name}") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("GET", urls, nil) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "name": c.name, + }) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "merchantapi.accounts.developerRegistration.getDeveloperRegistration", "request", internallog.HTTPRequest(req, nil)) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "merchantapi.accounts.developerRegistration.getDeveloperRegistration" call. +// Any non-2xx status code is an error. Response headers are in either +// *DeveloperRegistration.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 *AccountsDeveloperRegistrationGetDeveloperRegistrationCall) Do(opts ...googleapi.CallOption) (*DeveloperRegistration, 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 := &DeveloperRegistration{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + b, err := gensupport.DecodeResponseBytes(target, res) + if err != nil { + return nil, err + } + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "merchantapi.accounts.developerRegistration.getDeveloperRegistration", "response", internallog.HTTPResponse(res, b)) + return ret, nil +} + type AccountsDeveloperRegistrationRegisterGcpCall struct { s *APIService name string - registergcprequest *RegisterGCPRequest + registergcprequest *RegisterGcpRequest urlParams_ gensupport.URLParams ctx_ context.Context header_ http.Header @@ -6428,7 +6428,7 @@ type AccountsDeveloperRegistrationRegisterGcpCall struct { // - name: The name of the developer registration to be created for the // merchant account that the GCP will be registered with. Format: // `accounts/{account}/developerRegistration`. -func (r *AccountsDeveloperRegistrationService) RegisterGcp(name string, registergcprequest *RegisterGCPRequest) *AccountsDeveloperRegistrationRegisterGcpCall { +func (r *AccountsDeveloperRegistrationService) RegisterGcp(name string, registergcprequest *RegisterGcpRequest) *AccountsDeveloperRegistrationRegisterGcpCall { c := &AccountsDeveloperRegistrationRegisterGcpCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.name = name c.registergcprequest = registergcprequest @@ -6523,7 +6523,7 @@ func (c *AccountsDeveloperRegistrationRegisterGcpCall) Do(opts ...googleapi.Call type AccountsDeveloperRegistrationUnregisterGcpCall struct { s *APIService name string - unregistergcprequest *UnregisterGCPRequest + unregistergcprequest *UnregisterGcpRequest urlParams_ gensupport.URLParams ctx_ context.Context header_ http.Header @@ -6536,7 +6536,7 @@ type AccountsDeveloperRegistrationUnregisterGcpCall struct { // - name: The name of the developer registration to be created for the // merchant account that the GCP will be registered with. Format: // `accounts/{account}/developerRegistration`. -func (r *AccountsDeveloperRegistrationService) UnregisterGcp(name string, unregistergcprequest *UnregisterGCPRequest) *AccountsDeveloperRegistrationUnregisterGcpCall { +func (r *AccountsDeveloperRegistrationService) UnregisterGcp(name string, unregistergcprequest *UnregisterGcpRequest) *AccountsDeveloperRegistrationUnregisterGcpCall { c := &AccountsDeveloperRegistrationUnregisterGcpCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.name = name c.unregistergcprequest = unregistergcprequest diff --git a/merchantapi/datasources_v1beta/merchantapi-api.json b/merchantapi/datasources_v1beta/merchantapi-api.json index 7d9ab817130..181d8ccf1d8 100644 --- a/merchantapi/datasources_v1beta/merchantapi-api.json +++ b/merchantapi/datasources_v1beta/merchantapi-api.json @@ -321,7 +321,7 @@ } } }, - "revision": "20250710", + "revision": "20250721", "rootUrl": "https://merchantapi.googleapis.com/", "schemas": { "DataSource": { @@ -592,7 +592,7 @@ "File input type unspecified.", "The file is uploaded through SFTP, Google Cloud Storage or manually in the Merchant Center.", "The file is fetched from the configured fetch_uri.", - "The file is fetched from Google Sheets specified in the fetch_uri." + "The file is fetched from Google Sheets specified in the fetch_uri. However, you can't set up `GOOGLE_SHEETS` as a data source through the API. To add `GOOGLE_SHEETS` as a data source through the Merchant Center, see [Add products to Merchant Center](https://support.google.com/merchants/answer/12158053)." ], "readOnly": true, "type": "string" diff --git a/merchantapi/datasources_v1beta/merchantapi-gen.go b/merchantapi/datasources_v1beta/merchantapi-gen.go index ce359ddf058..29342e1d147 100644 --- a/merchantapi/datasources_v1beta/merchantapi-gen.go +++ b/merchantapi/datasources_v1beta/merchantapi-gen.go @@ -475,7 +475,10 @@ type FileInput struct { // manually in the Merchant Center. // "FETCH" - The file is fetched from the configured fetch_uri. // "GOOGLE_SHEETS" - The file is fetched from Google Sheets specified in the - // fetch_uri. + // fetch_uri. However, you can't set up `GOOGLE_SHEETS` as a data source + // through the API. To add `GOOGLE_SHEETS` as a data source through the + // Merchant Center, see [Add products to Merchant + // Center](https://support.google.com/merchants/answer/12158053). FileInputType string `json:"fileInputType,omitempty"` // FileName: Optional. The file name of the data source. Required for `UPLOAD` // file input type. diff --git a/merchantapi/inventories_v1beta/merchantapi-api.json b/merchantapi/inventories_v1beta/merchantapi-api.json index fdc71f14da1..fcbcc8774f2 100644 --- a/merchantapi/inventories_v1beta/merchantapi-api.json +++ b/merchantapi/inventories_v1beta/merchantapi-api.json @@ -300,7 +300,7 @@ } } }, - "revision": "20250623", + "revision": "20250721", "rootUrl": "https://merchantapi.googleapis.com/", "schemas": { "CustomAttribute": { @@ -399,6 +399,7 @@ "type": "string" }, "customAttributes": { + "deprecated": true, "description": "A list of custom (merchant-provided) attributes. You can also use `CustomAttribute` to submit any attribute of the data specification in its generic form.", "items": { "$ref": "CustomAttribute" @@ -627,6 +628,7 @@ "type": "string" }, "customAttributes": { + "deprecated": true, "description": "A list of custom (merchant-provided) attributes. You can also use `CustomAttribute` to submit any attribute of the data specification in its generic form.", "items": { "$ref": "CustomAttribute" diff --git a/networksecurity/v1/networksecurity-api.json b/networksecurity/v1/networksecurity-api.json index dd67a69dd19..41703483720 100644 --- a/networksecurity/v1/networksecurity-api.json +++ b/networksecurity/v1/networksecurity-api.json @@ -2338,7 +2338,7 @@ ], "parameters": { "name": { - "description": "Required. Name of the ClientTlsPolicy resource. It matches the pattern `projects/*/locations/{location}/clientTlsPolicies/{client_tls_policy}`", + "description": "Required. Name of the ClientTlsPolicy resource. It matches the pattern `projects/{project}/locations/{location}/clientTlsPolicies/{client_tls_policy}`", "location": "path", "pattern": "^projects/[^/]+/locations/[^/]+/clientTlsPolicies/[^/]+$", "required": true, @@ -5070,7 +5070,7 @@ } } }, - "revision": "20250604", + "revision": "20250714", "rootUrl": "https://networksecurity.googleapis.com/", "schemas": { "AddAddressGroupItemsRequest": { @@ -5387,12 +5387,19 @@ "id": "AuthzPolicyAuthzRuleFromRequestSource", "properties": { "ipBlocks": { - "description": "Optional. A list of IPs or CIDRs to match against the source IP of a request. Limited to 5 ip_blocks.", + "description": "Optional. A list of IP addresses or IP address ranges to match against the source IP address of the request. Limited to 5 ip_blocks.", "items": { "$ref": "AuthzPolicyAuthzRuleIpBlock" }, "type": "array" }, + "principals": { + "description": "Optional. A list of identities derived from the client's certificate. This field will not match on a request unless frontend mutual TLS is enabled for the forwarding rule or Gateway and the client certificate has been successfully validated by mTLS. Each identity is a string whose value is matched against a list of URI SANs, DNS Name SANs, or the common name in the client's certificate. A match happens when any principal matches with the rule. Limited to 5 principals.", + "items": { + "$ref": "AuthzPolicyAuthzRulePrincipal" + }, + "type": "array" + }, "resources": { "description": "Optional. A list of resources to match against the resource of the source VM of a request. Limited to 5 resources.", "items": { @@ -5434,6 +5441,33 @@ }, "type": "object" }, + "AuthzPolicyAuthzRulePrincipal": { + "description": "Describes the properties of a principal to be matched against.", + "id": "AuthzPolicyAuthzRulePrincipal", + "properties": { + "principal": { + "$ref": "AuthzPolicyAuthzRuleStringMatch", + "description": "Required. A non-empty string whose value is matched against the principal value based on the principal_selector. Only exact match can be applied for CLIENT_CERT_URI_SAN, CLIENT_CERT_DNS_NAME_SAN, CLIENT_CERT_COMMON_NAME selectors." + }, + "principalSelector": { + "description": "Optional. An enum to decide what principal value the principal rule will match against. If not specified, the PrincipalSelector is CLIENT_CERT_URI_SAN.", + "enum": [ + "PRINCIPAL_SELECTOR_UNSPECIFIED", + "CLIENT_CERT_URI_SAN", + "CLIENT_CERT_DNS_NAME_SAN", + "CLIENT_CERT_COMMON_NAME" + ], + "enumDescriptions": [ + "Unspecified principal selector. It will be treated as CLIENT_CERT_URI_SAN by default.", + "The principal rule is matched against a list of URI SANs in the validated client’s certificate. A match happens when there is any exact URI SAN value match. This is the default principal selector.", + "The principal rule is matched against a list of DNS Name SANs in the validated client’s certificate. A match happens when there is any exact DNS Name SAN value match.", + "The principal rule is matched against the common name in the client’s certificate. Authorization against multiple common names in the client certificate is not supported. Requests with multiple common names in the client certificate will be rejected if CLIENT_CERT_COMMON_NAME is set as the principal selector. A match happens when there is an exact common name value match. This is only applicable for Application Load Balancers except for classic Global External Application load balancer. CLIENT_CERT_COMMON_NAME is not supported for INTERNAL_SELF_MANAGED load balancing scheme." + ], + "type": "string" + } + }, + "type": "object" + }, "AuthzPolicyAuthzRuleRequestResource": { "description": "Describes the properties of a client VM resource accessing the internal application load balancers.", "id": "AuthzPolicyAuthzRuleRequestResource", @@ -5624,7 +5658,7 @@ "type": "object" }, "BackendAuthenticationConfig": { - "description": "BackendAuthenticationConfig message groups the TrustConfig together with other settings that control how the load balancer authenticates, and expresses its identity to, the backend: * `trustConfig` is the attached TrustConfig. * `wellKnownRoots` indicates whether the load balance should trust backend server certificates that are issued by public certificate authorities, in addition to certificates trusted by the TrustConfig. * `clientCertificate` is a client certificate that the load balancer uses to express its identity to the backend, if the connection to the backend uses mTLS. You can attach the BackendAuthenticationConfig to the load balancer’s BackendService directly determining how that BackendService negotiates TLS.", + "description": "BackendAuthenticationConfig message groups the TrustConfig together with other settings that control how the load balancer authenticates, and expresses its identity to, the backend: * `trustConfig` is the attached TrustConfig. * `wellKnownRoots` indicates whether the load balance should trust backend server certificates that are issued by public certificate authorities, in addition to certificates trusted by the TrustConfig. * `clientCertificate` is a client certificate that the load balancer uses to express its identity to the backend, if the connection to the backend uses mTLS. You can attach the BackendAuthenticationConfig to the load balancer's BackendService directly determining how that BackendService negotiates TLS.", "id": "BackendAuthenticationConfig", "properties": { "clientCertificate": { @@ -5727,7 +5761,7 @@ "type": "object" }, "name": { - "description": "Required. Name of the ClientTlsPolicy resource. It matches the pattern `projects/*/locations/{location}/clientTlsPolicies/{client_tls_policy}`", + "description": "Required. Name of the ClientTlsPolicy resource. It matches the pattern `projects/{project}/locations/{location}/clientTlsPolicies/{client_tls_policy}`", "type": "string" }, "serverValidationCa": { diff --git a/networksecurity/v1/networksecurity-gen.go b/networksecurity/v1/networksecurity-gen.go index bc2b8368d5c..5d8b0adf9f6 100644 --- a/networksecurity/v1/networksecurity-gen.go +++ b/networksecurity/v1/networksecurity-gen.go @@ -824,9 +824,17 @@ func (s AuthzPolicyAuthzRuleFrom) MarshalJSON() ([]byte, error) { // AuthzPolicyAuthzRuleFromRequestSource: Describes the properties of a single // source. type AuthzPolicyAuthzRuleFromRequestSource struct { - // IpBlocks: Optional. A list of IPs or CIDRs to match against the source IP of - // a request. Limited to 5 ip_blocks. + // IpBlocks: Optional. A list of IP addresses or IP address ranges to match + // against the source IP address of the request. Limited to 5 ip_blocks. IpBlocks []*AuthzPolicyAuthzRuleIpBlock `json:"ipBlocks,omitempty"` + // Principals: Optional. A list of identities derived from the client's + // certificate. This field will not match on a request unless frontend mutual + // TLS is enabled for the forwarding rule or Gateway and the client certificate + // has been successfully validated by mTLS. Each identity is a string whose + // value is matched against a list of URI SANs, DNS Name SANs, or the common + // name in the client's certificate. A match happens when any principal matches + // with the rule. Limited to 5 principals. + Principals []*AuthzPolicyAuthzRulePrincipal `json:"principals,omitempty"` // Resources: Optional. A list of resources to match against the resource of // the source VM of a request. Limited to 5 resources. Resources []*AuthzPolicyAuthzRuleRequestResource `json:"resources,omitempty"` @@ -897,6 +905,55 @@ func (s AuthzPolicyAuthzRuleIpBlock) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// AuthzPolicyAuthzRulePrincipal: Describes the properties of a principal to be +// matched against. +type AuthzPolicyAuthzRulePrincipal struct { + // Principal: Required. A non-empty string whose value is matched against the + // principal value based on the principal_selector. Only exact match can be + // applied for CLIENT_CERT_URI_SAN, CLIENT_CERT_DNS_NAME_SAN, + // CLIENT_CERT_COMMON_NAME selectors. + Principal *AuthzPolicyAuthzRuleStringMatch `json:"principal,omitempty"` + // PrincipalSelector: Optional. An enum to decide what principal value the + // principal rule will match against. If not specified, the PrincipalSelector + // is CLIENT_CERT_URI_SAN. + // + // Possible values: + // "PRINCIPAL_SELECTOR_UNSPECIFIED" - Unspecified principal selector. It will + // be treated as CLIENT_CERT_URI_SAN by default. + // "CLIENT_CERT_URI_SAN" - The principal rule is matched against a list of + // URI SANs in the validated client’s certificate. A match happens when there + // is any exact URI SAN value match. This is the default principal selector. + // "CLIENT_CERT_DNS_NAME_SAN" - The principal rule is matched against a list + // of DNS Name SANs in the validated client’s certificate. A match happens + // when there is any exact DNS Name SAN value match. + // "CLIENT_CERT_COMMON_NAME" - The principal rule is matched against the + // common name in the client’s certificate. Authorization against multiple + // common names in the client certificate is not supported. Requests with + // multiple common names in the client certificate will be rejected if + // CLIENT_CERT_COMMON_NAME is set as the principal selector. A match happens + // when there is an exact common name value match. This is only applicable for + // Application Load Balancers except for classic Global External Application + // load balancer. CLIENT_CERT_COMMON_NAME is not supported for + // INTERNAL_SELF_MANAGED load balancing scheme. + PrincipalSelector string `json:"principalSelector,omitempty"` + // ForceSendFields is a list of field names (e.g. "Principal") 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. "Principal") 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 AuthzPolicyAuthzRulePrincipal) MarshalJSON() ([]byte, error) { + type NoMethod AuthzPolicyAuthzRulePrincipal + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // AuthzPolicyAuthzRuleRequestResource: Describes the properties of a client VM // resource accessing the internal application load balancers. type AuthzPolicyAuthzRuleRequestResource struct { @@ -1203,8 +1260,8 @@ func (s AuthzPolicyTarget) MarshalJSON() ([]byte, error) { // TrustConfig. * `clientCertificate` is a client certificate that the load // balancer uses to express its identity to the backend, if the connection to // the backend uses mTLS. You can attach the BackendAuthenticationConfig to the -// load balancer’s BackendService directly determining how that -// BackendService negotiates TLS. +// load balancer's BackendService directly determining how that BackendService +// negotiates TLS. type BackendAuthenticationConfig struct { // ClientCertificate: Optional. A reference to a // certificatemanager.googleapis.com.Certificate resource. This is a relative @@ -1320,7 +1377,8 @@ type ClientTlsPolicy struct { // Labels: Optional. Set of label tags associated with the resource. Labels map[string]string `json:"labels,omitempty"` // Name: Required. Name of the ClientTlsPolicy resource. It matches the pattern - // `projects/*/locations/{location}/clientTlsPolicies/{client_tls_policy}` + // `projects/{project}/locations/{location}/clientTlsPolicies/{client_tls_policy + // }` Name string `json:"name,omitempty"` // ServerValidationCa: Optional. Defines the mechanism to obtain the // Certificate Authority certificate to validate the server certificate. If @@ -13113,7 +13171,8 @@ type ProjectsLocationsClientTlsPoliciesPatchCall struct { // Patch: Updates the parameters of a single ClientTlsPolicy. // // - name: Name of the ClientTlsPolicy resource. It matches the pattern -// `projects/*/locations/{location}/clientTlsPolicies/{client_tls_policy}`. +// `projects/{project}/locations/{location}/clientTlsPolicies/{client_tls_poli +// cy}`. func (r *ProjectsLocationsClientTlsPoliciesService) Patch(name string, clienttlspolicy *ClientTlsPolicy) *ProjectsLocationsClientTlsPoliciesPatchCall { c := &ProjectsLocationsClientTlsPoliciesPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.name = name diff --git a/retail/v2/retail-api.json b/retail/v2/retail-api.json index 5c8a1bda7c8..a90a8c48e9d 100644 --- a/retail/v2/retail-api.json +++ b/retail/v2/retail-api.json @@ -2282,7 +2282,7 @@ } } }, - "revision": "20250703", + "revision": "20250717", "rootUrl": "https://retail.googleapis.com/", "schemas": { "GoogleApiHttpBody": { @@ -4236,6 +4236,42 @@ }, "type": "object" }, + "GoogleCloudRetailV2PanelInfo": { + "description": "Detailed panel information associated with a user event.", + "id": "GoogleCloudRetailV2PanelInfo", + "properties": { + "attributionToken": { + "description": "Optional. The attribution token of the panel.", + "type": "string" + }, + "displayName": { + "description": "Optional. The display name of the panel.", + "type": "string" + }, + "panelId": { + "description": "Required. The panel ID.", + "type": "string" + }, + "panelPosition": { + "description": "Optional. The ordered position of the panel, if shown to the user with other panels. If set, then total_panels must also be set.", + "format": "int32", + "type": "integer" + }, + "productDetails": { + "description": "Optional. The product details associated with the panel.", + "items": { + "$ref": "GoogleCloudRetailV2ProductDetail" + }, + "type": "array" + }, + "totalPanels": { + "description": "Optional. The total number of panels, including this one, shown to the user. Must be set if panel_position is set.", + "format": "int32", + "type": "integer" + } + }, + "type": "object" + }, "GoogleCloudRetailV2PauseModelRequest": { "description": "Request for pausing training of a model.", "id": "GoogleCloudRetailV2PauseModelRequest", @@ -6331,6 +6367,13 @@ "description": "A unique ID of a web page view. This should be kept the same for all user events triggered from the same pageview. For example, an item detail page view could trigger multiple events as the user is browsing the page. The `pageViewId` property should be kept the same for all these events so that they can be grouped together properly. When using the client side event reporting with JavaScript pixel and Google Tag Manager, this value is filled in automatically.", "type": "string" }, + "panels": { + "description": "Optional. List of panels associated with this event. Used for panel-level impression data.", + "items": { + "$ref": "GoogleCloudRetailV2PanelInfo" + }, + "type": "array" + }, "productDetails": { "description": "The main product details related to the event. This field is optional except for the following event types: * `add-to-cart` * `detail-page-view` * `purchase-complete` In a `search` event, this field represents the products returned to the end user on the current page (the end user may have not finished browsing the whole page yet). When a new page is returned to the end user, after pagination/filtering/ordering even for the same query, a new `search` event with different product_details is desired. The end user may have not finished browsing the whole page yet.", "items": { diff --git a/retail/v2/retail-gen.go b/retail/v2/retail-gen.go index 55b8c7e2c90..d41dd96a1c9 100644 --- a/retail/v2/retail-gen.go +++ b/retail/v2/retail-gen.go @@ -3351,6 +3351,41 @@ func (s GoogleCloudRetailV2OutputResult) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudRetailV2PanelInfo: Detailed panel information associated with a +// user event. +type GoogleCloudRetailV2PanelInfo struct { + // AttributionToken: Optional. The attribution token of the panel. + AttributionToken string `json:"attributionToken,omitempty"` + // DisplayName: Optional. The display name of the panel. + DisplayName string `json:"displayName,omitempty"` + // PanelId: Required. The panel ID. + PanelId string `json:"panelId,omitempty"` + // PanelPosition: Optional. The ordered position of the panel, if shown to the + // user with other panels. If set, then total_panels must also be set. + PanelPosition int64 `json:"panelPosition,omitempty"` + // ProductDetails: Optional. The product details associated with the panel. + ProductDetails []*GoogleCloudRetailV2ProductDetail `json:"productDetails,omitempty"` + // TotalPanels: Optional. The total number of panels, including this one, shown + // to the user. Must be set if panel_position is set. + TotalPanels int64 `json:"totalPanels,omitempty"` + // ForceSendFields is a list of field names (e.g. "AttributionToken") 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. "AttributionToken") 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 GoogleCloudRetailV2PanelInfo) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudRetailV2PanelInfo + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudRetailV2PauseModelRequest: Request for pausing training of a // model. type GoogleCloudRetailV2PauseModelRequest struct { @@ -6706,6 +6741,9 @@ type GoogleCloudRetailV2UserEvent struct { // event reporting with JavaScript pixel and Google Tag Manager, this value is // filled in automatically. PageViewId string `json:"pageViewId,omitempty"` + // Panels: Optional. List of panels associated with this event. Used for + // panel-level impression data. + Panels []*GoogleCloudRetailV2PanelInfo `json:"panels,omitempty"` // ProductDetails: The main product details related to the event. This field is // optional except for the following event types: * `add-to-cart` * // `detail-page-view` * `purchase-complete` In a `search` event, this field diff --git a/retail/v2alpha/retail-api.json b/retail/v2alpha/retail-api.json index c606cb20f14..a1f943a70d5 100644 --- a/retail/v2alpha/retail-api.json +++ b/retail/v2alpha/retail-api.json @@ -2859,7 +2859,7 @@ } } }, - "revision": "20250710", + "revision": "20250717", "rootUrl": "https://retail.googleapis.com/", "schemas": { "GoogleApiHttpBody": { @@ -4662,6 +4662,13 @@ "description": "Optional. Raw search query to be searched for. If this field is empty, the request is considered a category browsing request.", "type": "string" }, + "safetySettings": { + "description": "Optional. The safety settings to be applied to the generated content.", + "items": { + "$ref": "GoogleCloudRetailV2alphaSafetySetting" + }, + "type": "array" + }, "searchParams": { "$ref": "GoogleCloudRetailV2alphaConversationalSearchRequestSearchParams", "description": "Optional. Search parameters." @@ -5975,6 +5982,12 @@ "format": "int64", "type": "string" }, + "primaryFeedId": { + "deprecated": true, + "description": "Merchant Center primary feed ID. Deprecated: use data_source_id instead.", + "format": "int64", + "type": "string" + }, "primaryFeedName": { "description": "Merchant Center primary feed name. The name is used for the display purposes only.", "type": "string" @@ -6353,6 +6366,42 @@ }, "type": "object" }, + "GoogleCloudRetailV2alphaPanelInfo": { + "description": "Detailed panel information associated with a user event.", + "id": "GoogleCloudRetailV2alphaPanelInfo", + "properties": { + "attributionToken": { + "description": "Optional. The attribution token of the panel.", + "type": "string" + }, + "displayName": { + "description": "Optional. The display name of the panel.", + "type": "string" + }, + "panelId": { + "description": "Required. The panel ID.", + "type": "string" + }, + "panelPosition": { + "description": "Optional. The ordered position of the panel, if shown to the user with other panels. If set, then total_panels must also be set.", + "format": "int32", + "type": "integer" + }, + "productDetails": { + "description": "Optional. The product details associated with the panel.", + "items": { + "$ref": "GoogleCloudRetailV2alphaProductDetail" + }, + "type": "array" + }, + "totalPanels": { + "description": "Optional. The total number of panels, including this one, shown to the user. Must be set if panel_position is set.", + "format": "int32", + "type": "integer" + } + }, + "type": "object" + }, "GoogleCloudRetailV2alphaPauseModelRequest": { "description": "Request for pausing training of a model.", "id": "GoogleCloudRetailV2alphaPauseModelRequest", @@ -7458,6 +7507,67 @@ }, "type": "object" }, + "GoogleCloudRetailV2alphaSafetySetting": { + "description": "Safety settings.", + "id": "GoogleCloudRetailV2alphaSafetySetting", + "properties": { + "category": { + "description": "Harm category.", + "enum": [ + "HARM_CATEGORY_UNSPECIFIED", + "HARM_CATEGORY_HATE_SPEECH", + "HARM_CATEGORY_DANGEROUS_CONTENT", + "HARM_CATEGORY_HARASSMENT", + "HARM_CATEGORY_SEXUALLY_EXPLICIT", + "HARM_CATEGORY_CIVIC_INTEGRITY" + ], + "enumDescriptions": [ + "The harm category is unspecified.", + "The harm category is hate speech.", + "The harm category is dangerous content.", + "The harm category is harassment.", + "The harm category is sexually explicit content.", + "The harm category is civic integrity." + ], + "type": "string" + }, + "method": { + "description": "Optional. Specify if the threshold is used for probability or severity score. If not specified, the threshold is used for probability score.", + "enum": [ + "HARM_BLOCK_METHOD_UNSPECIFIED", + "SEVERITY", + "PROBABILITY" + ], + "enumDescriptions": [ + "The harm block method is unspecified.", + "The harm block method uses both probability and severity scores.", + "The harm block method uses the probability score." + ], + "type": "string" + }, + "threshold": { + "description": "The harm block threshold.", + "enum": [ + "HARM_BLOCK_THRESHOLD_UNSPECIFIED", + "BLOCK_LOW_AND_ABOVE", + "BLOCK_MEDIUM_AND_ABOVE", + "BLOCK_ONLY_HIGH", + "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.", + "Turn off the safety filter." + ], + "type": "string" + } + }, + "type": "object" + }, "GoogleCloudRetailV2alphaSearchRequest": { "description": "Request message for SearchService.Search method.", "id": "GoogleCloudRetailV2alphaSearchRequest", @@ -8517,6 +8627,13 @@ "description": "A unique ID of a web page view. This should be kept the same for all user events triggered from the same pageview. For example, an item detail page view could trigger multiple events as the user is browsing the page. The `pageViewId` property should be kept the same for all these events so that they can be grouped together properly. When using the client side event reporting with JavaScript pixel and Google Tag Manager, this value is filled in automatically.", "type": "string" }, + "panels": { + "description": "Optional. List of panels associated with this event. Used for panel-level impression data.", + "items": { + "$ref": "GoogleCloudRetailV2alphaPanelInfo" + }, + "type": "array" + }, "productDetails": { "description": "The main product details related to the event. This field is optional except for the following event types: * `add-to-cart` * `detail-page-view` * `purchase-complete` In a `search` event, this field represents the products returned to the end user on the current page (the end user may have not finished browsing the whole page yet). When a new page is returned to the end user, after pagination/filtering/ordering even for the same query, a new `search` event with different product_details is desired. The end user may have not finished browsing the whole page yet.", "items": { diff --git a/retail/v2alpha/retail-gen.go b/retail/v2alpha/retail-gen.go index 4fc577e25c3..0b48e1c5888 100644 --- a/retail/v2alpha/retail-gen.go +++ b/retail/v2alpha/retail-gen.go @@ -3024,6 +3024,9 @@ type GoogleCloudRetailV2alphaConversationalSearchRequest struct { // Query: Optional. Raw search query to be searched for. If this field is // empty, the request is considered a category browsing request. Query string `json:"query,omitempty"` + // SafetySettings: Optional. The safety settings to be applied to the generated + // content. + SafetySettings []*GoogleCloudRetailV2alphaSafetySetting `json:"safetySettings,omitempty"` // SearchParams: Optional. Search parameters. SearchParams *GoogleCloudRetailV2alphaConversationalSearchRequestSearchParams `json:"searchParams,omitempty"` // UserInfo: Optional. User information. @@ -5162,6 +5165,9 @@ func (s GoogleCloudRetailV2alphaMerchantCenterAccountLinkMerchantCenterFeedFilte type GoogleCloudRetailV2alphaMerchantCenterFeedFilter struct { // DataSourceId: AFM data source ID. DataSourceId int64 `json:"dataSourceId,omitempty,string"` + // PrimaryFeedId: Merchant Center primary feed ID. Deprecated: use + // data_source_id instead. + PrimaryFeedId int64 `json:"primaryFeedId,omitempty,string"` // PrimaryFeedName: Merchant Center primary feed name. The name is used for the // display purposes only. PrimaryFeedName string `json:"primaryFeedName,omitempty"` @@ -5741,6 +5747,41 @@ func (s GoogleCloudRetailV2alphaOutputResult) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudRetailV2alphaPanelInfo: Detailed panel information associated +// with a user event. +type GoogleCloudRetailV2alphaPanelInfo struct { + // AttributionToken: Optional. The attribution token of the panel. + AttributionToken string `json:"attributionToken,omitempty"` + // DisplayName: Optional. The display name of the panel. + DisplayName string `json:"displayName,omitempty"` + // PanelId: Required. The panel ID. + PanelId string `json:"panelId,omitempty"` + // PanelPosition: Optional. The ordered position of the panel, if shown to the + // user with other panels. If set, then total_panels must also be set. + PanelPosition int64 `json:"panelPosition,omitempty"` + // ProductDetails: Optional. The product details associated with the panel. + ProductDetails []*GoogleCloudRetailV2alphaProductDetail `json:"productDetails,omitempty"` + // TotalPanels: Optional. The total number of panels, including this one, shown + // to the user. Must be set if panel_position is set. + TotalPanels int64 `json:"totalPanels,omitempty"` + // ForceSendFields is a list of field names (e.g. "AttributionToken") 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. "AttributionToken") 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 GoogleCloudRetailV2alphaPanelInfo) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudRetailV2alphaPanelInfo + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudRetailV2alphaPauseModelRequest: Request for pausing training of a // model. type GoogleCloudRetailV2alphaPauseModelRequest struct { @@ -7585,6 +7626,58 @@ func (s GoogleCloudRetailV2alphaRuleTwowaySynonymsAction) MarshalJSON() ([]byte, return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudRetailV2alphaSafetySetting: Safety settings. +type GoogleCloudRetailV2alphaSafetySetting struct { + // Category: Harm category. + // + // Possible values: + // "HARM_CATEGORY_UNSPECIFIED" - The harm category is unspecified. + // "HARM_CATEGORY_HATE_SPEECH" - The harm category is hate speech. + // "HARM_CATEGORY_DANGEROUS_CONTENT" - The harm category is dangerous + // content. + // "HARM_CATEGORY_HARASSMENT" - The harm category is harassment. + // "HARM_CATEGORY_SEXUALLY_EXPLICIT" - The harm category is sexually explicit + // content. + // "HARM_CATEGORY_CIVIC_INTEGRITY" - The harm category is civic integrity. + Category string `json:"category,omitempty"` + // Method: Optional. Specify if the threshold is used for probability or + // severity score. If not specified, the threshold is used for probability + // score. + // + // Possible values: + // "HARM_BLOCK_METHOD_UNSPECIFIED" - The harm block method is unspecified. + // "SEVERITY" - The harm block method uses both probability and severity + // scores. + // "PROBABILITY" - The harm block method uses the probability score. + Method string `json:"method,omitempty"` + // Threshold: The harm block threshold. + // + // Possible values: + // "HARM_BLOCK_THRESHOLD_UNSPECIFIED" - Unspecified harm block threshold. + // "BLOCK_LOW_AND_ABOVE" - Block low threshold and above (i.e. block more). + // "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 + // 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. "Category") 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 GoogleCloudRetailV2alphaSafetySetting) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudRetailV2alphaSafetySetting + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudRetailV2alphaSearchRequest: Request message for // SearchService.Search method. type GoogleCloudRetailV2alphaSearchRequest struct { @@ -9180,6 +9273,9 @@ type GoogleCloudRetailV2alphaUserEvent struct { // event reporting with JavaScript pixel and Google Tag Manager, this value is // filled in automatically. PageViewId string `json:"pageViewId,omitempty"` + // Panels: Optional. List of panels associated with this event. Used for + // panel-level impression data. + Panels []*GoogleCloudRetailV2alphaPanelInfo `json:"panels,omitempty"` // ProductDetails: The main product details related to the event. This field is // optional except for the following event types: * `add-to-cart` * // `detail-page-view` * `purchase-complete` In a `search` event, this field diff --git a/retail/v2beta/retail-api.json b/retail/v2beta/retail-api.json index af89f58a908..5c591a9ecfb 100644 --- a/retail/v2beta/retail-api.json +++ b/retail/v2beta/retail-api.json @@ -2427,7 +2427,7 @@ } } }, - "revision": "20250710", + "revision": "20250717", "rootUrl": "https://retail.googleapis.com/", "schemas": { "GoogleApiHttpBody": { @@ -5738,6 +5738,12 @@ "format": "int64", "type": "string" }, + "primaryFeedId": { + "deprecated": true, + "description": "Merchant Center primary feed ID. Deprecated: use data_source_id instead.", + "format": "int64", + "type": "string" + }, "primaryFeedName": { "description": "Merchant Center primary feed name. The name is used for the display purposes only.", "type": "string" @@ -6043,6 +6049,42 @@ }, "type": "object" }, + "GoogleCloudRetailV2betaPanelInfo": { + "description": "Detailed panel information associated with a user event.", + "id": "GoogleCloudRetailV2betaPanelInfo", + "properties": { + "attributionToken": { + "description": "Optional. The attribution token of the panel.", + "type": "string" + }, + "displayName": { + "description": "Optional. The display name of the panel.", + "type": "string" + }, + "panelId": { + "description": "Required. The panel ID.", + "type": "string" + }, + "panelPosition": { + "description": "Optional. The ordered position of the panel, if shown to the user with other panels. If set, then total_panels must also be set.", + "format": "int32", + "type": "integer" + }, + "productDetails": { + "description": "Optional. The product details associated with the panel.", + "items": { + "$ref": "GoogleCloudRetailV2betaProductDetail" + }, + "type": "array" + }, + "totalPanels": { + "description": "Optional. The total number of panels, including this one, shown to the user. Must be set if panel_position is set.", + "format": "int32", + "type": "integer" + } + }, + "type": "object" + }, "GoogleCloudRetailV2betaPauseModelRequest": { "description": "Request for pausing training of a model.", "id": "GoogleCloudRetailV2betaPauseModelRequest", @@ -8138,6 +8180,13 @@ "description": "A unique ID of a web page view. This should be kept the same for all user events triggered from the same pageview. For example, an item detail page view could trigger multiple events as the user is browsing the page. The `pageViewId` property should be kept the same for all these events so that they can be grouped together properly. When using the client side event reporting with JavaScript pixel and Google Tag Manager, this value is filled in automatically.", "type": "string" }, + "panels": { + "description": "Optional. List of panels associated with this event. Used for panel-level impression data.", + "items": { + "$ref": "GoogleCloudRetailV2betaPanelInfo" + }, + "type": "array" + }, "productDetails": { "description": "The main product details related to the event. This field is optional except for the following event types: * `add-to-cart` * `detail-page-view` * `purchase-complete` In a `search` event, this field represents the products returned to the end user on the current page (the end user may have not finished browsing the whole page yet). When a new page is returned to the end user, after pagination/filtering/ordering even for the same query, a new `search` event with different product_details is desired. The end user may have not finished browsing the whole page yet.", "items": { diff --git a/retail/v2beta/retail-gen.go b/retail/v2beta/retail-gen.go index 44ac930aefd..33c388e4490 100644 --- a/retail/v2beta/retail-gen.go +++ b/retail/v2beta/retail-gen.go @@ -5327,6 +5327,9 @@ func (s GoogleCloudRetailV2betaLocalInventory) MarshalJSON() ([]byte, error) { type GoogleCloudRetailV2betaMerchantCenterFeedFilter struct { // DataSourceId: AFM data source ID. DataSourceId int64 `json:"dataSourceId,omitempty,string"` + // PrimaryFeedId: Merchant Center primary feed ID. Deprecated: use + // data_source_id instead. + PrimaryFeedId int64 `json:"primaryFeedId,omitempty,string"` // PrimaryFeedName: Merchant Center primary feed name. The name is used for the // display purposes only. PrimaryFeedName string `json:"primaryFeedName,omitempty"` @@ -5758,6 +5761,41 @@ func (s GoogleCloudRetailV2betaOutputResult) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudRetailV2betaPanelInfo: Detailed panel information associated with +// a user event. +type GoogleCloudRetailV2betaPanelInfo struct { + // AttributionToken: Optional. The attribution token of the panel. + AttributionToken string `json:"attributionToken,omitempty"` + // DisplayName: Optional. The display name of the panel. + DisplayName string `json:"displayName,omitempty"` + // PanelId: Required. The panel ID. + PanelId string `json:"panelId,omitempty"` + // PanelPosition: Optional. The ordered position of the panel, if shown to the + // user with other panels. If set, then total_panels must also be set. + PanelPosition int64 `json:"panelPosition,omitempty"` + // ProductDetails: Optional. The product details associated with the panel. + ProductDetails []*GoogleCloudRetailV2betaProductDetail `json:"productDetails,omitempty"` + // TotalPanels: Optional. The total number of panels, including this one, shown + // to the user. Must be set if panel_position is set. + TotalPanels int64 `json:"totalPanels,omitempty"` + // ForceSendFields is a list of field names (e.g. "AttributionToken") 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. "AttributionToken") 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 GoogleCloudRetailV2betaPanelInfo) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudRetailV2betaPanelInfo + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudRetailV2betaPauseModelRequest: Request for pausing training of a // model. type GoogleCloudRetailV2betaPauseModelRequest struct { @@ -9115,6 +9153,9 @@ type GoogleCloudRetailV2betaUserEvent struct { // event reporting with JavaScript pixel and Google Tag Manager, this value is // filled in automatically. PageViewId string `json:"pageViewId,omitempty"` + // Panels: Optional. List of panels associated with this event. Used for + // panel-level impression data. + Panels []*GoogleCloudRetailV2betaPanelInfo `json:"panels,omitempty"` // ProductDetails: The main product details related to the event. This field is // optional except for the following event types: * `add-to-cart` * // `detail-page-view` * `purchase-complete` In a `search` event, this field diff --git a/searchads360/v0/searchads360-api.json b/searchads360/v0/searchads360-api.json index 4aeec2219d1..fd55c88121b 100644 --- a/searchads360/v0/searchads360-api.json +++ b/searchads360/v0/searchads360-api.json @@ -260,7 +260,7 @@ } } }, - "revision": "20250407", + "revision": "20250721", "rootUrl": "https://searchads360.googleapis.com/", "schemas": { "GoogleAdsSearchads360V0Common__AdScheduleInfo": { @@ -447,7 +447,8 @@ "PROMOTION", "AD_IMAGE", "LEAD_FORM", - "BUSINESS_LOGO" + "BUSINESS_LOGO", + "DESCRIPTION_PREFIX" ], "enumDescriptions": [ "No value has been specified.", @@ -481,7 +482,8 @@ "This asset is used as a promotion.", "This asset is used as an image.", "The asset is used as a lead form.", - "The asset is used as a business logo." + "The asset is used as a business logo.", + "The asset is used as a description prefix." ], "type": "string" } @@ -2686,6 +2688,38 @@ ], "type": "string" }, + "conversionCustomVariableError": { + "description": "The reasons for the conversion custom variable error", + "enum": [ + "UNSPECIFIED", + "UNKNOWN", + "DUPLICATE_NAME", + "DUPLICATE_TAG", + "RESERVED_TAG", + "NOT_FOUND", + "NOT_AVAILABLE", + "INCOMPATIBLE_TYPE", + "INVALID_METRIC", + "EXCEEDS_CARDINALITY_LIMIT", + "INVALID_DIMENSION", + "INCOMPATIBLE_WITH_SELECTED_RESOURCE" + ], + "enumDescriptions": [ + "Enum unspecified.", + "The received error code is not known in this version.", + "A conversion custom variable with the specified name already exists.", + "A conversion custom variable with the specified tag already exists.", + "A conversion custom variable with the specified tag is reserved for other uses.", + "The conversion custom variable is not found.", + "The conversion custom variable is not available for use.", + "The conversion custom variable requested is incompatible with the current request.", + "The conversion custom variable requested is not of type METRIC.", + "The conversion custom variable's cardinality exceeds the segmentation limit.", + "The conversion custom variable requested is not of type DIMENSION.", + "The conversion custom variable requested is incompatible with the selected resource." + ], + "type": "string" + }, "customColumnError": { "description": "The reasons for the custom column error", "enum": [ @@ -3909,7 +3943,7 @@ "type": "string" }, "name": { - "description": "Immutable. The name of the ad. This is only used to be able to identify the ad. It does not need to be unique and does not affect the served ad. The name field is currently only supported for DisplayUploadAd, ImageAd, ShoppingComparisonListingAd and VideoAd.", + "description": "Immutable. The name of the ad. This is only used to be able to identify the ad. It does not need to be unique and does not affect the served ad.", "type": "string" }, "productAd": { diff --git a/searchads360/v0/searchads360-gen.go b/searchads360/v0/searchads360-gen.go index 269b1a43579..866e6b987fd 100644 --- a/searchads360/v0/searchads360-gen.go +++ b/searchads360/v0/searchads360-gen.go @@ -401,6 +401,7 @@ type GoogleAdsSearchads360V0Common__AssetUsage struct { // "AD_IMAGE" - This asset is used as an image. // "LEAD_FORM" - The asset is used as a lead form. // "BUSINESS_LOGO" - The asset is used as a business logo. + // "DESCRIPTION_PREFIX" - The asset is used as a description prefix. ServedAssetFieldType string `json:"servedAssetFieldType,omitempty"` // ForceSendFields is a list of field names (e.g. "Asset") to unconditionally // include in API requests. By default, fields with empty or default values are @@ -3060,6 +3061,31 @@ type GoogleAdsSearchads360V0Errors__ErrorCode struct { // "METRIC_ACCESS_DENIED" - The developer does not have access to the metrics // queried. AuthorizationError string `json:"authorizationError,omitempty"` + // ConversionCustomVariableError: The reasons for the conversion custom + // variable error + // + // Possible values: + // "UNSPECIFIED" - Enum unspecified. + // "UNKNOWN" - The received error code is not known in this version. + // "DUPLICATE_NAME" - A conversion custom variable with the specified name + // already exists. + // "DUPLICATE_TAG" - A conversion custom variable with the specified tag + // already exists. + // "RESERVED_TAG" - A conversion custom variable with the specified tag is + // reserved for other uses. + // "NOT_FOUND" - The conversion custom variable is not found. + // "NOT_AVAILABLE" - The conversion custom variable is not available for use. + // "INCOMPATIBLE_TYPE" - The conversion custom variable requested is + // incompatible with the current request. + // "INVALID_METRIC" - The conversion custom variable requested is not of type + // METRIC. + // "EXCEEDS_CARDINALITY_LIMIT" - The conversion custom variable's cardinality + // exceeds the segmentation limit. + // "INVALID_DIMENSION" - The conversion custom variable requested is not of + // type DIMENSION. + // "INCOMPATIBLE_WITH_SELECTED_RESOURCE" - The conversion custom variable + // requested is incompatible with the selected resource. + ConversionCustomVariableError string `json:"conversionCustomVariableError,omitempty"` // CustomColumnError: The reasons for the custom column error // // Possible values: @@ -4505,8 +4531,7 @@ type GoogleAdsSearchads360V0Resources__Ad struct { Id int64 `json:"id,omitempty,string"` // Name: Immutable. The name of the ad. This is only used to be able to // identify the ad. It does not need to be unique and does not affect the - // served ad. The name field is currently only supported for DisplayUploadAd, - // ImageAd, ShoppingComparisonListingAd and VideoAd. + // served ad. Name string `json:"name,omitempty"` // ProductAd: Immutable. Details pertaining to a product ad. ProductAd *GoogleAdsSearchads360V0Common__SearchAds360ProductAdInfo `json:"productAd,omitempty"` diff --git a/serviceconsumermanagement/v1/serviceconsumermanagement-api.json b/serviceconsumermanagement/v1/serviceconsumermanagement-api.json index eec1bb5148f..c5af9e9b89b 100644 --- a/serviceconsumermanagement/v1/serviceconsumermanagement-api.json +++ b/serviceconsumermanagement/v1/serviceconsumermanagement-api.json @@ -542,7 +542,7 @@ } } }, - "revision": "20250515", + "revision": "20250619", "rootUrl": "https://serviceconsumermanagement.googleapis.com/", "schemas": { "AddTenantProjectRequest": { @@ -2390,6 +2390,10 @@ "common": { "$ref": "CommonLanguageSettings", "description": "Some settings." + }, + "libraryPackage": { + "description": "The package name to use in Php. Clobbers the php_namespace option set in the protobuf. This should be used **only** by APIs who have already set the language_settings.php.package_name\" field in gapic.yaml. API teams should use the protobuf php_namespace option where possible. Example of a YAML configuration:: publishing: library_settings: php_settings: library_package: Google\\Cloud\\PubSub\\V1", + "type": "string" } }, "type": "object" diff --git a/serviceconsumermanagement/v1/serviceconsumermanagement-gen.go b/serviceconsumermanagement/v1/serviceconsumermanagement-gen.go index c6e6bb14a92..ea4a9ca79f0 100644 --- a/serviceconsumermanagement/v1/serviceconsumermanagement-gen.go +++ b/serviceconsumermanagement/v1/serviceconsumermanagement-gen.go @@ -3024,6 +3024,13 @@ func (s Page) MarshalJSON() ([]byte, error) { type PhpSettings struct { // Common: Some settings. Common *CommonLanguageSettings `json:"common,omitempty"` + // LibraryPackage: The package name to use in Php. Clobbers the php_namespace + // option set in the protobuf. This should be used **only** by APIs who have + // already set the language_settings.php.package_name" field in gapic.yaml. API + // teams should use the protobuf php_namespace option where possible. Example + // of a YAML configuration:: publishing: library_settings: php_settings: + // library_package: Google\Cloud\PubSub\V1 + LibraryPackage string `json:"libraryPackage,omitempty"` // ForceSendFields is a list of field names (e.g. "Common") to unconditionally // include in API requests. By default, fields with empty or default values are // omitted from API requests. See diff --git a/serviceconsumermanagement/v1beta1/serviceconsumermanagement-api.json b/serviceconsumermanagement/v1beta1/serviceconsumermanagement-api.json index 25f31840fd3..ea991ee4823 100644 --- a/serviceconsumermanagement/v1beta1/serviceconsumermanagement-api.json +++ b/serviceconsumermanagement/v1beta1/serviceconsumermanagement-api.json @@ -724,7 +724,7 @@ } } }, - "revision": "20250515", + "revision": "20250619", "rootUrl": "https://serviceconsumermanagement.googleapis.com/", "schemas": { "Api": { @@ -2448,6 +2448,10 @@ "common": { "$ref": "CommonLanguageSettings", "description": "Some settings." + }, + "libraryPackage": { + "description": "The package name to use in Php. Clobbers the php_namespace option set in the protobuf. This should be used **only** by APIs who have already set the language_settings.php.package_name\" field in gapic.yaml. API teams should use the protobuf php_namespace option where possible. Example of a YAML configuration:: publishing: library_settings: php_settings: library_package: Google\\Cloud\\PubSub\\V1", + "type": "string" } }, "type": "object" diff --git a/serviceconsumermanagement/v1beta1/serviceconsumermanagement-gen.go b/serviceconsumermanagement/v1beta1/serviceconsumermanagement-gen.go index e688703266a..8c1de807689 100644 --- a/serviceconsumermanagement/v1beta1/serviceconsumermanagement-gen.go +++ b/serviceconsumermanagement/v1beta1/serviceconsumermanagement-gen.go @@ -2838,6 +2838,13 @@ func (s Page) MarshalJSON() ([]byte, error) { type PhpSettings struct { // Common: Some settings. Common *CommonLanguageSettings `json:"common,omitempty"` + // LibraryPackage: The package name to use in Php. Clobbers the php_namespace + // option set in the protobuf. This should be used **only** by APIs who have + // already set the language_settings.php.package_name" field in gapic.yaml. API + // teams should use the protobuf php_namespace option where possible. Example + // of a YAML configuration:: publishing: library_settings: php_settings: + // library_package: Google\Cloud\PubSub\V1 + LibraryPackage string `json:"libraryPackage,omitempty"` // ForceSendFields is a list of field names (e.g. "Common") to unconditionally // include in API requests. By default, fields with empty or default values are // omitted from API requests. See diff --git a/serviceusage/v1/serviceusage-api.json b/serviceusage/v1/serviceusage-api.json index 3a8659cee2c..a26c1378396 100644 --- a/serviceusage/v1/serviceusage-api.json +++ b/serviceusage/v1/serviceusage-api.json @@ -426,7 +426,7 @@ } } }, - "revision": "20250515", + "revision": "20250619", "rootUrl": "https://serviceusage.googleapis.com/", "schemas": { "AddEnableRulesMetadata": { @@ -3222,6 +3222,10 @@ "common": { "$ref": "CommonLanguageSettings", "description": "Some settings." + }, + "libraryPackage": { + "description": "The package name to use in Php. Clobbers the php_namespace option set in the protobuf. This should be used **only** by APIs who have already set the language_settings.php.package_name\" field in gapic.yaml. API teams should use the protobuf php_namespace option where possible. Example of a YAML configuration:: publishing: library_settings: php_settings: library_package: Google\\Cloud\\PubSub\\V1", + "type": "string" } }, "type": "object" diff --git a/serviceusage/v1/serviceusage-gen.go b/serviceusage/v1/serviceusage-gen.go index 69b4d1f6290..770b7d56540 100644 --- a/serviceusage/v1/serviceusage-gen.go +++ b/serviceusage/v1/serviceusage-gen.go @@ -4147,6 +4147,13 @@ func (s Page) MarshalJSON() ([]byte, error) { type PhpSettings struct { // Common: Some settings. Common *CommonLanguageSettings `json:"common,omitempty"` + // LibraryPackage: The package name to use in Php. Clobbers the php_namespace + // option set in the protobuf. This should be used **only** by APIs who have + // already set the language_settings.php.package_name" field in gapic.yaml. API + // teams should use the protobuf php_namespace option where possible. Example + // of a YAML configuration:: publishing: library_settings: php_settings: + // library_package: Google\Cloud\PubSub\V1 + LibraryPackage string `json:"libraryPackage,omitempty"` // ForceSendFields is a list of field names (e.g. "Common") to unconditionally // include in API requests. By default, fields with empty or default values are // omitted from API requests. See diff --git a/serviceusage/v1beta1/serviceusage-api.json b/serviceusage/v1beta1/serviceusage-api.json index 3e54922fee2..8cec9f1a9f1 100644 --- a/serviceusage/v1beta1/serviceusage-api.json +++ b/serviceusage/v1beta1/serviceusage-api.json @@ -964,7 +964,7 @@ } } }, - "revision": "20250515", + "revision": "20250619", "rootUrl": "https://serviceusage.googleapis.com/", "schemas": { "AddEnableRulesMetadata": { @@ -3931,6 +3931,10 @@ "common": { "$ref": "CommonLanguageSettings", "description": "Some settings." + }, + "libraryPackage": { + "description": "The package name to use in Php. Clobbers the php_namespace option set in the protobuf. This should be used **only** by APIs who have already set the language_settings.php.package_name\" field in gapic.yaml. API teams should use the protobuf php_namespace option where possible. Example of a YAML configuration:: publishing: library_settings: php_settings: library_package: Google\\Cloud\\PubSub\\V1", + "type": "string" } }, "type": "object" diff --git a/serviceusage/v1beta1/serviceusage-gen.go b/serviceusage/v1beta1/serviceusage-gen.go index 9180c3bf71f..d86812d3481 100644 --- a/serviceusage/v1beta1/serviceusage-gen.go +++ b/serviceusage/v1beta1/serviceusage-gen.go @@ -4421,6 +4421,13 @@ func (s Page) MarshalJSON() ([]byte, error) { type PhpSettings struct { // Common: Some settings. Common *CommonLanguageSettings `json:"common,omitempty"` + // LibraryPackage: The package name to use in Php. Clobbers the php_namespace + // option set in the protobuf. This should be used **only** by APIs who have + // already set the language_settings.php.package_name" field in gapic.yaml. API + // teams should use the protobuf php_namespace option where possible. Example + // of a YAML configuration:: publishing: library_settings: php_settings: + // library_package: Google\Cloud\PubSub\V1 + LibraryPackage string `json:"libraryPackage,omitempty"` // ForceSendFields is a list of field names (e.g. "Common") to unconditionally // include in API requests. By default, fields with empty or default values are // omitted from API requests. See diff --git a/storage/v1/storage-api.json b/storage/v1/storage-api.json index 8ad0d403bdc..251396d4956 100644 --- a/storage/v1/storage-api.json +++ b/storage/v1/storage-api.json @@ -253,7 +253,7 @@ "location": "northamerica-south1" } ], - "etag": "\"31353834363234393531343533373938353433\"", + "etag": "\"31383438373536343936353833383831333836\"", "icons": { "x16": "https://www.google.com/images/icons/product/cloud_storage-16.png", "x32": "https://www.google.com/images/icons/product/cloud_storage-32.png" @@ -4544,7 +4544,7 @@ } } }, - "revision": "20250629", + "revision": "20250718", "rootUrl": "https://storage.googleapis.com/", "schemas": { "AdvanceRelocateBucketOperationRequest": { @@ -4758,9 +4758,78 @@ "encryption": { "description": "Encryption configuration for a bucket.", "properties": { + "customerManagedEncryptionEnforcementConfig": { + "description": "If set, the new objects created in this bucket must comply with this enforcement config. Changing this has no effect on existing objects; it applies to new objects only. If omitted, the new objects are allowed to be encrypted with Customer Managed Encryption type by default.", + "properties": { + "effectiveTime": { + "description": "Server-determined value that indicates the time from which configuration was enforced and effective. This value is in RFC 3339 format.", + "format": "date-time", + "type": "string" + }, + "restrictionMode": { + "description": "Restriction mode for Customer-Managed Encryption Keys. Defaults to NotRestricted.", + "enum": [ + "NotRestricted", + "FullyRestricted" + ], + "enumDescriptions": [ + "Creation of new objects with Customer-Managed Encryption is not restricted.", + "Creation of new objects with Customer-Managed Encryption is fully restricted." + ], + "type": "string" + } + }, + "type": "object" + }, + "customerSuppliedEncryptionEnforcementConfig": { + "description": "If set, the new objects created in this bucket must comply with this enforcement config. Changing this has no effect on existing objects; it applies to new objects only. If omitted, the new objects are allowed to be encrypted with Customer Supplied Encryption type by default.", + "properties": { + "effectiveTime": { + "description": "Server-determined value that indicates the time from which configuration was enforced and effective. This value is in RFC 3339 format.", + "format": "date-time", + "type": "string" + }, + "restrictionMode": { + "description": "Restriction mode for Customer-Supplied Encryption Keys. Defaults to NotRestricted.", + "enum": [ + "NotRestricted", + "FullyRestricted" + ], + "enumDescriptions": [ + "Creation of new objects with Customer-Supplied Encryption is not restricted.", + "Creation of new objects with Customer-Supplied Encryption is fully restricted." + ], + "type": "string" + } + }, + "type": "object" + }, "defaultKmsKeyName": { "description": "A Cloud KMS key that will be used to encrypt objects inserted into this bucket, if no encryption method is specified.", "type": "string" + }, + "googleManagedEncryptionEnforcementConfig": { + "description": "If set, the new objects created in this bucket must comply with this enforcement config. Changing this has no effect on existing objects; it applies to new objects only. If omitted, the new objects are allowed to be encrypted with Google Managed Encryption type by default.", + "properties": { + "effectiveTime": { + "description": "Server-determined value that indicates the time from which configuration was enforced and effective. This value is in RFC 3339 format.", + "format": "date-time", + "type": "string" + }, + "restrictionMode": { + "description": "Restriction mode for Google-Managed Encryption Keys. Defaults to NotRestricted.", + "enum": [ + "NotRestricted", + "FullyRestricted" + ], + "enumDescriptions": [ + "Creation of new objects with Google Managed Encryption is not restricted.", + "Creation of new objects with Google Managed Encryption is fully restricted." + ], + "type": "string" + } + }, + "type": "object" } }, "type": "object" diff --git a/storage/v1/storage-gen.go b/storage/v1/storage-gen.go index 0983dadf4b3..0714b7e0890 100644 --- a/storage/v1/storage-gen.go +++ b/storage/v1/storage-gen.go @@ -709,18 +709,38 @@ func (s BucketCustomPlacementConfig) MarshalJSON() ([]byte, error) { // BucketEncryption: Encryption configuration for a bucket. type BucketEncryption struct { + // CustomerManagedEncryptionEnforcementConfig: If set, the new objects created + // in this bucket must comply with this enforcement config. Changing this has + // no effect on existing objects; it applies to new objects only. If omitted, + // the new objects are allowed to be encrypted with Customer Managed Encryption + // type by default. + CustomerManagedEncryptionEnforcementConfig *BucketEncryptionCustomerManagedEncryptionEnforcementConfig `json:"customerManagedEncryptionEnforcementConfig,omitempty"` + // CustomerSuppliedEncryptionEnforcementConfig: If set, the new objects created + // in this bucket must comply with this enforcement config. Changing this has + // no effect on existing objects; it applies to new objects only. If omitted, + // the new objects are allowed to be encrypted with Customer Supplied + // Encryption type by default. + CustomerSuppliedEncryptionEnforcementConfig *BucketEncryptionCustomerSuppliedEncryptionEnforcementConfig `json:"customerSuppliedEncryptionEnforcementConfig,omitempty"` // DefaultKmsKeyName: A Cloud KMS key that will be used to encrypt objects // inserted into this bucket, if no encryption method is specified. DefaultKmsKeyName string `json:"defaultKmsKeyName,omitempty"` - // ForceSendFields is a list of field names (e.g. "DefaultKmsKeyName") to - // unconditionally include in API requests. By default, fields with empty or - // default values are omitted from API requests. See + // GoogleManagedEncryptionEnforcementConfig: If set, the new objects created in + // this bucket must comply with this enforcement config. Changing this has no + // effect on existing objects; it applies to new objects only. If omitted, the + // new objects are allowed to be encrypted with Google Managed Encryption type + // by default. + GoogleManagedEncryptionEnforcementConfig *BucketEncryptionGoogleManagedEncryptionEnforcementConfig `json:"googleManagedEncryptionEnforcementConfig,omitempty"` + // ForceSendFields is a list of field names (e.g. + // "CustomerManagedEncryptionEnforcementConfig") 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. "DefaultKmsKeyName") 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. + // "CustomerManagedEncryptionEnforcementConfig") 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:"-"` } @@ -730,6 +750,114 @@ func (s BucketEncryption) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// BucketEncryptionCustomerManagedEncryptionEnforcementConfig: If set, the new +// objects created in this bucket must comply with this enforcement config. +// Changing this has no effect on existing objects; it applies to new objects +// only. If omitted, the new objects are allowed to be encrypted with Customer +// Managed Encryption type by default. +type BucketEncryptionCustomerManagedEncryptionEnforcementConfig struct { + // EffectiveTime: Server-determined value that indicates the time from which + // configuration was enforced and effective. This value is in RFC 3339 format. + EffectiveTime string `json:"effectiveTime,omitempty"` + // RestrictionMode: Restriction mode for Customer-Managed Encryption Keys. + // Defaults to NotRestricted. + // + // Possible values: + // "NotRestricted" - Creation of new objects with Customer-Managed Encryption + // is not restricted. + // "FullyRestricted" - Creation of new objects with Customer-Managed + // Encryption is fully restricted. + RestrictionMode string `json:"restrictionMode,omitempty"` + // ForceSendFields is a list of field names (e.g. "EffectiveTime") 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. "EffectiveTime") 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 BucketEncryptionCustomerManagedEncryptionEnforcementConfig) MarshalJSON() ([]byte, error) { + type NoMethod BucketEncryptionCustomerManagedEncryptionEnforcementConfig + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// BucketEncryptionCustomerSuppliedEncryptionEnforcementConfig: If set, the new +// objects created in this bucket must comply with this enforcement config. +// Changing this has no effect on existing objects; it applies to new objects +// only. If omitted, the new objects are allowed to be encrypted with Customer +// Supplied Encryption type by default. +type BucketEncryptionCustomerSuppliedEncryptionEnforcementConfig struct { + // EffectiveTime: Server-determined value that indicates the time from which + // configuration was enforced and effective. This value is in RFC 3339 format. + EffectiveTime string `json:"effectiveTime,omitempty"` + // RestrictionMode: Restriction mode for Customer-Supplied Encryption Keys. + // Defaults to NotRestricted. + // + // Possible values: + // "NotRestricted" - Creation of new objects with Customer-Supplied + // Encryption is not restricted. + // "FullyRestricted" - Creation of new objects with Customer-Supplied + // Encryption is fully restricted. + RestrictionMode string `json:"restrictionMode,omitempty"` + // ForceSendFields is a list of field names (e.g. "EffectiveTime") 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. "EffectiveTime") 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 BucketEncryptionCustomerSuppliedEncryptionEnforcementConfig) MarshalJSON() ([]byte, error) { + type NoMethod BucketEncryptionCustomerSuppliedEncryptionEnforcementConfig + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// BucketEncryptionGoogleManagedEncryptionEnforcementConfig: If set, the new +// objects created in this bucket must comply with this enforcement config. +// Changing this has no effect on existing objects; it applies to new objects +// only. If omitted, the new objects are allowed to be encrypted with Google +// Managed Encryption type by default. +type BucketEncryptionGoogleManagedEncryptionEnforcementConfig struct { + // EffectiveTime: Server-determined value that indicates the time from which + // configuration was enforced and effective. This value is in RFC 3339 format. + EffectiveTime string `json:"effectiveTime,omitempty"` + // RestrictionMode: Restriction mode for Google-Managed Encryption Keys. + // Defaults to NotRestricted. + // + // Possible values: + // "NotRestricted" - Creation of new objects with Google Managed Encryption + // is not restricted. + // "FullyRestricted" - Creation of new objects with Google Managed Encryption + // is fully restricted. + RestrictionMode string `json:"restrictionMode,omitempty"` + // ForceSendFields is a list of field names (e.g. "EffectiveTime") 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. "EffectiveTime") 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 BucketEncryptionGoogleManagedEncryptionEnforcementConfig) MarshalJSON() ([]byte, error) { + type NoMethod BucketEncryptionGoogleManagedEncryptionEnforcementConfig + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // BucketHierarchicalNamespace: The bucket's hierarchical namespace // configuration. type BucketHierarchicalNamespace struct { From cac72a14582b9675f5889a346f4f195988a2c9b5 Mon Sep 17 00:00:00 2001 From: Yoshi Automation Bot Date: Thu, 24 Jul 2025 00:34:23 -0700 Subject: [PATCH 02/10] feat(all): auto-regenerate discovery clients (#3243) --- .../v1/androidenterprise-api.json | 31 +- androidenterprise/v1/androidenterprise-gen.go | 40 ++ bigquery/v2/bigquery-api.json | 12 +- bigquery/v2/bigquery-gen.go | 13 +- chat/v1/chat-api.json | 83 ++- chat/v1/chat-gen.go | 105 +++- chromemanagement/v1/chromemanagement-api.json | 20 +- chromemanagement/v1/chromemanagement-gen.go | 9 + connectors/v1/connectors-api.json | 7 +- connectors/v1/connectors-gen.go | 9 + discoveryengine/v1/discoveryengine-api.json | 74 ++- discoveryengine/v1/discoveryengine-gen.go | 142 +++-- .../v1alpha/discoveryengine-api.json | 405 +++++++++++- .../v1alpha/discoveryengine-gen.go | 582 ++++++++++++++++-- .../v1beta/discoveryengine-api.json | 74 ++- discoveryengine/v1beta/discoveryengine-gen.go | 142 +++-- drive/v3/drive-api.json | 6 +- drive/v3/drive-gen.go | 7 +- file/v1/file-api.json | 8 +- file/v1/file-gen.go | 2 + .../v1/mybusinessverifications-api.json | 77 ++- .../v1/mybusinessverifications-gen.go | 213 +++++++ securitycenter/v1/securitycenter-api.json | 274 ++++++++- securitycenter/v1/securitycenter-gen.go | 280 ++++++++- .../v1beta2/securitycenter-api.json | 274 ++++++++- securitycenter/v1beta2/securitycenter-gen.go | 280 ++++++++- texttospeech/v1/texttospeech-api.json | 4 +- texttospeech/v1/texttospeech-gen.go | 3 +- texttospeech/v1beta1/texttospeech-api.json | 4 +- texttospeech/v1beta1/texttospeech-gen.go | 3 +- vmmigration/v1/vmmigration-api.json | 4 +- vmmigration/v1/vmmigration-gen.go | 2 +- vmmigration/v1alpha1/vmmigration-api.json | 4 +- vmmigration/v1alpha1/vmmigration-gen.go | 2 +- workstations/v1beta/workstations-api.json | 7 +- workstations/v1beta/workstations-gen.go | 3 + 36 files changed, 2920 insertions(+), 285 deletions(-) diff --git a/androidenterprise/v1/androidenterprise-api.json b/androidenterprise/v1/androidenterprise-api.json index ab294bacfb1..9fe9a36cfe3 100644 --- a/androidenterprise/v1/androidenterprise-api.json +++ b/androidenterprise/v1/androidenterprise-api.json @@ -2691,7 +2691,7 @@ } } }, - "revision": "20250610", + "revision": "20250720", "rootUrl": "https://androidenterprise.googleapis.com/", "schemas": { "Administrator": { @@ -3342,6 +3342,10 @@ ], "type": "string" }, + "googleAuthenticationOptions": { + "$ref": "EnrollmentTokenGoogleAuthenticationOptions", + "description": "[Optional] Provides options related to Google authentication during the enrollment." + }, "token": { "description": "The token value that's passed to the device and authorizes the device to enroll. This is a read-only field generated by the server.", "type": "string" @@ -3349,6 +3353,31 @@ }, "type": "object" }, + "EnrollmentTokenGoogleAuthenticationOptions": { + "description": "Options for Google authentication during the enrollment.", + "id": "EnrollmentTokenGoogleAuthenticationOptions", + "properties": { + "authenticationRequirement": { + "description": "[Optional] Specifies whether user should authenticate with Google during enrollment. This setting, if specified,`GoogleAuthenticationSettings` specified for the enterprise resource is ignored for devices enrolled with this token.", + "enum": [ + "authenticationRequirementUnspecified", + "optional", + "required" + ], + "enumDescriptions": [ + "The value is unused.", + "Google authentication is optional for the user. This means the user can choose to skip Google authentication during enrollment.", + "Google authentication is required for the user. This means the user must authenticate with a Google account to proceed." + ], + "type": "string" + }, + "requiredAccountEmail": { + "description": "[Optional] Specifies the managed Google account that the user must use during enrollment.`AuthenticationRequirement` must be set to`REQUIRED` if this field is set.", + "type": "string" + } + }, + "type": "object" + }, "Enterprise": { "description": "An Enterprises resource represents the binding between an EMM and a specific organization. That binding can be instantiated in one of two different ways using this API as follows: - For Google managed domain customers, the process involves using Enterprises.enroll and Enterprises.setAccount (in conjunction with artifacts obtained from the Admin console and the Google API Console) and submitted to the EMM through a more-or-less manual process. - For managed Google Play Accounts customers, the process involves using Enterprises.generateSignupUrl and Enterprises.completeSignup in conjunction with the managed Google Play sign-up UI (Google-provided mechanism) to create the binding without manual steps. As an EMM, you can support either or both approaches in your EMM console. See Create an Enterprise for details.", "id": "Enterprise", diff --git a/androidenterprise/v1/androidenterprise-gen.go b/androidenterprise/v1/androidenterprise-gen.go index 37535aba526..b7a061a334f 100644 --- a/androidenterprise/v1/androidenterprise-gen.go +++ b/androidenterprise/v1/androidenterprise-gen.go @@ -1192,6 +1192,9 @@ type EnrollmentToken struct { // "userlessDevice" - The enrollment token is for a userless device. // "userDevice" - The enrollment token is for a user device. EnrollmentTokenType string `json:"enrollmentTokenType,omitempty"` + // GoogleAuthenticationOptions: [Optional] Provides options related to Google + // authentication during the enrollment. + GoogleAuthenticationOptions *EnrollmentTokenGoogleAuthenticationOptions `json:"googleAuthenticationOptions,omitempty"` // Token: The token value that's passed to the device and authorizes the device // to enroll. This is a read-only field generated by the server. Token string `json:"token,omitempty"` @@ -1216,6 +1219,43 @@ func (s EnrollmentToken) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// EnrollmentTokenGoogleAuthenticationOptions: Options for Google +// authentication during the enrollment. +type EnrollmentTokenGoogleAuthenticationOptions struct { + // AuthenticationRequirement: [Optional] Specifies whether user should + // authenticate with Google during enrollment. This setting, if + // specified,`GoogleAuthenticationSettings` specified for the enterprise + // resource is ignored for devices enrolled with this token. + // + // Possible values: + // "authenticationRequirementUnspecified" - The value is unused. + // "optional" - Google authentication is optional for the user. This means + // the user can choose to skip Google authentication during enrollment. + // "required" - Google authentication is required for the user. This means + // the user must authenticate with a Google account to proceed. + AuthenticationRequirement string `json:"authenticationRequirement,omitempty"` + // RequiredAccountEmail: [Optional] Specifies the managed Google account that + // the user must use during enrollment.`AuthenticationRequirement` must be set + // to`REQUIRED` if this field is set. + RequiredAccountEmail string `json:"requiredAccountEmail,omitempty"` + // ForceSendFields is a list of field names (e.g. "AuthenticationRequirement") + // 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. "AuthenticationRequirement") 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 EnrollmentTokenGoogleAuthenticationOptions) MarshalJSON() ([]byte, error) { + type NoMethod EnrollmentTokenGoogleAuthenticationOptions + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // Enterprise: An Enterprises resource represents the binding between an EMM // and a specific organization. That binding can be instantiated in one of two // different ways using this API as follows: - For Google managed domain diff --git a/bigquery/v2/bigquery-api.json b/bigquery/v2/bigquery-api.json index c25c62c59a2..d698d15e76c 100644 --- a/bigquery/v2/bigquery-api.json +++ b/bigquery/v2/bigquery-api.json @@ -2345,7 +2345,7 @@ } } }, - "revision": "20250615", + "revision": "20250706", "rootUrl": "https://bigquery.googleapis.com/", "schemas": { "AggregateClassificationMetrics": { @@ -4637,6 +4637,10 @@ "description": "The external service cost is a portion of the total cost, these costs are not additive with total_bytes_billed. Moreover, this field only track external service costs that will show up as BigQuery costs (e.g. training BigQuery ML job with google cloud CAIP or Automl Tables services), not other costs which may be accrued by running the query (e.g. reading from Bigtable or Cloud Storage). The external service costs with different billing sku (e.g. CAIP job is charged based on VM usage) are converted to BigQuery billed_bytes and slot_ms with equivalent amount of US dollars. Services may not directly correlate to these metrics, but these are the equivalents for billing purposes. Output only.", "id": "ExternalServiceCost", "properties": { + "billingMethod": { + "description": "The billing method used for the external job. This field is only used when billed on the services sku, set to \"SERVICES_SKU\". Otherwise, it is unspecified for backward compatibility.", + "type": "string" + }, "bytesBilled": { "description": "External service cost in terms of bigquery bytes billed.", "format": "int64", @@ -6439,6 +6443,12 @@ "readOnly": true, "type": "string" }, + "totalServicesSkuSlotMs": { + "description": "Output only. Total slot-milliseconds for the job that run on external services and billed on the service SKU. This field is only populated for jobs that have external service costs, and is the total of the usage for costs whose billing method is \"SERVICES_SKU\".", + "format": "int64", + "readOnly": true, + "type": "string" + }, "totalSlotMs": { "description": "Output only. Slot-milliseconds for the job.", "format": "int64", diff --git a/bigquery/v2/bigquery-gen.go b/bigquery/v2/bigquery-gen.go index 019e0f9c1e6..8d29993a5b6 100644 --- a/bigquery/v2/bigquery-gen.go +++ b/bigquery/v2/bigquery-gen.go @@ -3455,6 +3455,10 @@ func (s *ExternalRuntimeOptions) UnmarshalJSON(data []byte) error { // dollars. Services may not directly correlate to these metrics, but these are // the equivalents for billing purposes. Output only. type ExternalServiceCost struct { + // BillingMethod: The billing method used for the external job. This field is + // only used when billed on the services sku, set to "SERVICES_SKU". Otherwise, + // it is unspecified for backward compatibility. + BillingMethod string `json:"billingMethod,omitempty"` // BytesBilled: External service cost in terms of bigquery bytes billed. BytesBilled int64 `json:"bytesBilled,omitempty,string"` // BytesProcessed: External service cost in terms of bigquery bytes processed. @@ -3467,13 +3471,13 @@ type ExternalServiceCost struct { ReservedSlotCount int64 `json:"reservedSlotCount,omitempty,string"` // SlotMs: External service cost in terms of bigquery slot milliseconds. SlotMs int64 `json:"slotMs,omitempty,string"` - // ForceSendFields is a list of field names (e.g. "BytesBilled") to + // ForceSendFields is a list of field names (e.g. "BillingMethod") 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. "BytesBilled") to include in API + // NullFields is a list of field names (e.g. "BillingMethod") 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. @@ -5551,6 +5555,11 @@ type JobStatistics2 struct { // TotalPartitionsProcessed: Output only. Total number of partitions processed // from all partitioned tables referenced in the job. TotalPartitionsProcessed int64 `json:"totalPartitionsProcessed,omitempty,string"` + // TotalServicesSkuSlotMs: Output only. Total slot-milliseconds for the job + // that run on external services and billed on the service SKU. This field is + // only populated for jobs that have external service costs, and is the total + // of the usage for costs whose billing method is "SERVICES_SKU". + TotalServicesSkuSlotMs int64 `json:"totalServicesSkuSlotMs,omitempty,string"` // TotalSlotMs: Output only. Slot-milliseconds for the job. TotalSlotMs int64 `json:"totalSlotMs,omitempty,string"` // TransferredBytes: Output only. Total bytes transferred for cross-cloud diff --git a/chat/v1/chat-api.json b/chat/v1/chat-api.json index 24cd377cc53..f98b24cf141 100644 --- a/chat/v1/chat-api.json +++ b/chat/v1/chat-api.json @@ -1528,7 +1528,7 @@ } } }, - "revision": "20250717", + "revision": "20250720", "rootUrl": "https://chat.googleapis.com/", "schemas": { "AccessSettings": { @@ -1678,7 +1678,7 @@ "type": "object" }, "Annotation": { - "description": "Output only. Annotations associated with the plain-text body of the message. To add basic formatting to a text message, see [Format text messages](https://developers.google.com/workspace/chat/format-messages). Example plain-text message body: ``` Hello @FooBot how are you!\" ``` The corresponding annotations metadata: ``` \"annotations\":[{ \"type\":\"USER_MENTION\", \"startIndex\":6, \"length\":7, \"userMention\": { \"user\": { \"name\":\"users/{user}\", \"displayName\":\"FooBot\", \"avatarUrl\":\"https://goo.gl/aeDtrS/", \"type\":\"BOT\" }, \"type\":\"MENTION\" } }] ```", + "description": "Annotations can be associated with the plain-text body of the message or with chips that link to Google Workspace resources like Google Docs or Sheets with a `start_index` and `length` of 0. To add basic formatting to a text message, see [Format text messages](https://developers.google.com/workspace/chat/format-messages). Example plain-text message body: ``` Hello @FooBot how are you!\" ``` The corresponding annotations metadata: ``` \"annotations\":[{ \"type\":\"USER_MENTION\", \"startIndex\":6, \"length\":7, \"userMention\": { \"user\": { \"name\":\"users/{user}\", \"displayName\":\"FooBot\", \"avatarUrl\":\"https://goo.gl/aeDtrS/", \"type\":\"BOT\" }, \"type\":\"MENTION\" } }] ```", "id": "Annotation", "properties": { "customEmojiMetadata": { @@ -1686,7 +1686,7 @@ "description": "The metadata for a custom emoji." }, "length": { - "description": "Length of the substring in the plain-text message body this annotation corresponds to.", + "description": "Length of the substring in the plain-text message body this annotation corresponds to. If not present, indicates a length of 0.", "format": "int32", "type": "integer" }, @@ -1851,6 +1851,21 @@ }, "type": "object" }, + "CalendarEventLinkData": { + "description": "Data for Calendar event links.", + "id": "CalendarEventLinkData", + "properties": { + "calendarId": { + "description": "The [Calendar identifier](https://developers.google.com/workspace/calendar/api/v3/reference/calendars) of the linked Calendar.", + "type": "string" + }, + "eventId": { + "description": "The [Event identifier](https://developers.google.com/workspace/calendar/api/v3/reference/events) of the linked Calendar event.", + "type": "string" + } + }, + "type": "object" + }, "Card": { "description": "A card is a UI element that can contain UI widgets such as text and images.", "id": "Card", @@ -4157,6 +4172,48 @@ }, "type": "object" }, + "MeetSpaceLinkData": { + "description": "Data for Meet space links.", + "id": "MeetSpaceLinkData", + "properties": { + "huddleStatus": { + "description": "Optional. Output only. If the Meet is a Huddle, indicates the status of the huddle. Otherwise, this is unset.", + "enum": [ + "HUDDLE_STATUS_UNSPECIFIED", + "STARTED", + "ENDED", + "MISSED" + ], + "enumDescriptions": [ + "Default value for the enum. Don't use.", + "The huddle has started.", + "The huddle has ended. In this case the meet space URI and identifiers will no longer be valid.", + "The huddle has been missed. In this case the meet space URI and identifiers will no longer be valid." + ], + "readOnly": true, + "type": "string" + }, + "meetingCode": { + "description": "Meeting code of the linked Meet space.", + "type": "string" + }, + "type": { + "description": "Indicates the type of the Meet space.", + "enum": [ + "TYPE_UNSPECIFIED", + "MEETING", + "HUDDLE" + ], + "enumDescriptions": [ + "Default value for the enum. Don't use.", + "The meet space is a meeting.", + "The meet space is a huddle." + ], + "type": "string" + } + }, + "type": "object" + }, "Membership": { "description": "Represents a membership relation in Google Chat, such as whether a user or Chat app is invited to, part of, or absent from a space.", "id": "Membership", @@ -4327,7 +4384,7 @@ "description": "Input only. Parameters that a Chat app can use to configure how its response is posted." }, "annotations": { - "description": "Output only. Annotations associated with the `text` in this message.", + "description": "Output only. Annotations can be associated with the plain-text body of the message or with chips that link to Google Workspace resources like Google Docs or Sheets with a `start_index` and `length` of 0.", "items": { "$ref": "Annotation" }, @@ -4706,9 +4763,13 @@ "type": "object" }, "RichLinkMetadata": { - "description": "A rich link to a resource.", + "description": "A rich link to a resource. Rich links can be associated with the plain-text body of the message or represent chips that link to Google Workspace resources like Google Docs or Sheets with a with `start_index` and `length` of 0.", "id": "RichLinkMetadata", "properties": { + "calendarEventLinkData": { + "$ref": "CalendarEventLinkData", + "description": "Data for a calendar event link." + }, "chatSpaceLinkData": { "$ref": "ChatSpaceLinkData", "description": "Data for a chat space link." @@ -4717,17 +4778,25 @@ "$ref": "DriveLinkData", "description": "Data for a drive link." }, + "meetSpaceLinkData": { + "$ref": "MeetSpaceLinkData", + "description": "Data for a meet space link." + }, "richLinkType": { "description": "The rich link type.", "enum": [ "RICH_LINK_TYPE_UNSPECIFIED", "DRIVE_FILE", - "CHAT_SPACE" + "CHAT_SPACE", + "MEET_SPACE", + "CALENDAR_EVENT" ], "enumDescriptions": [ "Default value for the enum. Don't use.", "A Google Drive rich link type.", - "A Chat space rich link type. For example, a space smart chip." + "A Chat space rich link type. For example, a space smart chip.", + "A Meet message rich link type. For example, a Meet chip.", + "A Calendar message rich link type. For example, a Calendar chip." ], "type": "string" }, diff --git a/chat/v1/chat-gen.go b/chat/v1/chat-gen.go index 1234606d785..d7ec9c59334 100644 --- a/chat/v1/chat-gen.go +++ b/chat/v1/chat-gen.go @@ -688,10 +688,12 @@ func (s ActionStatus) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// Annotation: Output only. Annotations associated with the plain-text body of -// the message. To add basic formatting to a text message, see Format text -// messages (https://developers.google.com/workspace/chat/format-messages). -// Example plain-text message body: ``` Hello @FooBot how are you!" ``` The +// Annotation: Annotations can be associated with the plain-text body of the +// message or with chips that link to Google Workspace resources like Google +// Docs or Sheets with a `start_index` and `length` of 0. To add basic +// formatting to a text message, see Format text messages +// (https://developers.google.com/workspace/chat/format-messages). Example +// plain-text message body: ``` Hello @FooBot how are you!" ``` The // corresponding annotations metadata: ``` "annotations":[{ // "type":"USER_MENTION", "startIndex":6, "length":7, "userMention": { "user": // { "name":"users/{user}", "displayName":"FooBot", @@ -701,7 +703,7 @@ type Annotation struct { // CustomEmojiMetadata: The metadata for a custom emoji. CustomEmojiMetadata *CustomEmojiMetadata `json:"customEmojiMetadata,omitempty"` // Length: Length of the substring in the plain-text message body this - // annotation corresponds to. + // annotation corresponds to. If not present, indicates a length of 0. Length int64 `json:"length,omitempty"` // RichLinkMetadata: The metadata for a rich link. RichLinkMetadata *RichLinkMetadata `json:"richLinkMetadata,omitempty"` @@ -898,6 +900,34 @@ func (s Button) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// CalendarEventLinkData: Data for Calendar event links. +type CalendarEventLinkData struct { + // CalendarId: The Calendar identifier + // (https://developers.google.com/workspace/calendar/api/v3/reference/calendars) + // of the linked Calendar. + CalendarId string `json:"calendarId,omitempty"` + // EventId: The Event identifier + // (https://developers.google.com/workspace/calendar/api/v3/reference/events) + // of the linked Calendar event. + EventId string `json:"eventId,omitempty"` + // ForceSendFields is a list of field names (e.g. "CalendarId") 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. "CalendarId") 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 CalendarEventLinkData) MarshalJSON() ([]byte, error) { + type NoMethod CalendarEventLinkData + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // Card: A card is a UI element that can contain UI widgets such as text and // images. type Card struct { @@ -4425,6 +4455,46 @@ func (s Media) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// MeetSpaceLinkData: Data for Meet space links. +type MeetSpaceLinkData struct { + // HuddleStatus: Optional. Output only. If the Meet is a Huddle, indicates the + // status of the huddle. Otherwise, this is unset. + // + // Possible values: + // "HUDDLE_STATUS_UNSPECIFIED" - Default value for the enum. Don't use. + // "STARTED" - The huddle has started. + // "ENDED" - The huddle has ended. In this case the meet space URI and + // identifiers will no longer be valid. + // "MISSED" - The huddle has been missed. In this case the meet space URI and + // identifiers will no longer be valid. + HuddleStatus string `json:"huddleStatus,omitempty"` + // MeetingCode: Meeting code of the linked Meet space. + MeetingCode string `json:"meetingCode,omitempty"` + // Type: Indicates the type of the Meet space. + // + // Possible values: + // "TYPE_UNSPECIFIED" - Default value for the enum. Don't use. + // "MEETING" - The meet space is a meeting. + // "HUDDLE" - The meet space is a huddle. + Type string `json:"type,omitempty"` + // ForceSendFields is a list of field names (e.g. "HuddleStatus") 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. "HuddleStatus") 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 MeetSpaceLinkData) MarshalJSON() ([]byte, error) { + type NoMethod MeetSpaceLinkData + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // Membership: Represents a membership relation in Google Chat, such as whether // a user or Chat app is invited to, part of, or absent from a space. type Membership struct { @@ -4680,8 +4750,9 @@ type Message struct { // ActionResponse: Input only. Parameters that a Chat app can use to configure // how its response is posted. ActionResponse *ActionResponse `json:"actionResponse,omitempty"` - // Annotations: Output only. Annotations associated with the `text` in this - // message. + // Annotations: Output only. Annotations can be associated with the plain-text + // body of the message or with chips that link to Google Workspace resources + // like Google Docs or Sheets with a `start_index` and `length` of 0. Annotations []*Annotation `json:"annotations,omitempty"` // ArgumentText: Output only. Plain-text body of the message with all Chat app // mentions stripped out. @@ -5233,12 +5304,19 @@ func (s ReactionDeletedEventData) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// RichLinkMetadata: A rich link to a resource. +// RichLinkMetadata: A rich link to a resource. Rich links can be associated +// with the plain-text body of the message or represent chips that link to +// Google Workspace resources like Google Docs or Sheets with a with +// `start_index` and `length` of 0. type RichLinkMetadata struct { + // CalendarEventLinkData: Data for a calendar event link. + CalendarEventLinkData *CalendarEventLinkData `json:"calendarEventLinkData,omitempty"` // ChatSpaceLinkData: Data for a chat space link. ChatSpaceLinkData *ChatSpaceLinkData `json:"chatSpaceLinkData,omitempty"` // DriveLinkData: Data for a drive link. DriveLinkData *DriveLinkData `json:"driveLinkData,omitempty"` + // MeetSpaceLinkData: Data for a meet space link. + MeetSpaceLinkData *MeetSpaceLinkData `json:"meetSpaceLinkData,omitempty"` // RichLinkType: The rich link type. // // Possible values: @@ -5246,18 +5324,21 @@ type RichLinkMetadata struct { // "DRIVE_FILE" - A Google Drive rich link type. // "CHAT_SPACE" - A Chat space rich link type. For example, a space smart // chip. + // "MEET_SPACE" - A Meet message rich link type. For example, a Meet chip. + // "CALENDAR_EVENT" - A Calendar message rich link type. For example, a + // Calendar chip. 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. "ChatSpaceLinkData") to + // ForceSendFields is a list of field names (e.g. "CalendarEventLinkData") 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. "ChatSpaceLinkData") 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. "CalendarEventLinkData") 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/chromemanagement/v1/chromemanagement-api.json b/chromemanagement/v1/chromemanagement-api.json index 9033b17e600..8b27fc32704 100644 --- a/chromemanagement/v1/chromemanagement-api.json +++ b/chromemanagement/v1/chromemanagement-api.json @@ -1181,7 +1181,7 @@ "type": "string" }, "readMask": { - "description": "Required. Read mask to specify which fields to return. Although currently required, this field will become optional, while the filter parameter with an event type will be come required. Supported read_mask paths are: - device - user - audio_severe_underrun_event - usb_peripherals_event - https_latency_change_event - network_state_change_event - wifi_signal_strength_event - vpn_connection_state_change_event - app_install_event - app_uninstall_event - app_launch_event - os_crash_event ", + "description": "Required. Read mask to specify which fields to return. Although currently required, this field will become optional, while the filter parameter with an event type will be come required. Supported read_mask paths are: - device - user - audio_severe_underrun_event - usb_peripherals_event - https_latency_change_event - network_state_change_event - wifi_signal_strength_event - vpn_connection_state_change_event - app_install_event - app_uninstall_event - app_launch_event - os_crash_event - external_displays_event ", "format": "google-fieldmask", "location": "query", "type": "string" @@ -1377,7 +1377,7 @@ } } }, - "revision": "20250710", + "revision": "20250721", "rootUrl": "https://chromemanagement.googleapis.com/", "schemas": { "GoogleChromeManagementV1AndroidAppInfo": { @@ -4521,7 +4521,9 @@ "APP_INSTALLED", "APP_UNINSTALLED", "APP_LAUNCHED", - "OS_CRASH" + "OS_CRASH", + "EXTERNAL_DISPLAY_CONNECTED", + "EXTERNAL_DISPLAY_DISCONNECTED" ], "enumDescriptions": [ "Event type unknown.", @@ -4536,7 +4538,9 @@ "Triggered when an app is installed.", "Triggered when an app is uninstalled.", "Triggered when an app is launched.", - "Triggered when a crash occurs." + "Triggered when a crash occurs.", + "Triggered when an external display is connected.", + "Triggered when an external display is disconnected." ], "type": "string" }, @@ -4608,7 +4612,9 @@ "APP_INSTALLED", "APP_UNINSTALLED", "APP_LAUNCHED", - "OS_CRASH" + "OS_CRASH", + "EXTERNAL_DISPLAY_CONNECTED", + "EXTERNAL_DISPLAY_DISCONNECTED" ], "enumDescriptions": [ "Event type unknown.", @@ -4623,7 +4629,9 @@ "Triggered when an app is installed.", "Triggered when an app is uninstalled.", "Triggered when an app is launched.", - "Triggered when a crash occurs." + "Triggered when a crash occurs.", + "Triggered when an external display is connected.", + "Triggered when an external display is disconnected." ], "type": "string" }, diff --git a/chromemanagement/v1/chromemanagement-gen.go b/chromemanagement/v1/chromemanagement-gen.go index c0f3234237e..8af3c2a0bff 100644 --- a/chromemanagement/v1/chromemanagement-gen.go +++ b/chromemanagement/v1/chromemanagement-gen.go @@ -3413,6 +3413,10 @@ type GoogleChromeManagementV1TelemetryEvent struct { // "APP_UNINSTALLED" - Triggered when an app is uninstalled. // "APP_LAUNCHED" - Triggered when an app is launched. // "OS_CRASH" - Triggered when a crash occurs. + // "EXTERNAL_DISPLAY_CONNECTED" - Triggered when an external display is + // connected. + // "EXTERNAL_DISPLAY_DISCONNECTED" - Triggered when an external display is + // disconnected. EventType string `json:"eventType,omitempty"` // HttpsLatencyChangeEvent: Output only. Payload for HTTPS latency change // event. Present only when `event_type` is `NETWORK_HTTPS_LATENCY_CHANGE`. @@ -3484,6 +3488,10 @@ type GoogleChromeManagementV1TelemetryEventNotificationFilter struct { // "APP_UNINSTALLED" - Triggered when an app is uninstalled. // "APP_LAUNCHED" - Triggered when an app is launched. // "OS_CRASH" - Triggered when a crash occurs. + // "EXTERNAL_DISPLAY_CONNECTED" - Triggered when an external display is + // connected. + // "EXTERNAL_DISPLAY_DISCONNECTED" - Triggered when an external display is + // disconnected. EventTypes []string `json:"eventTypes,omitempty"` // ForceSendFields is a list of field names (e.g. "EventTypes") to // unconditionally include in API requests. By default, fields with empty or @@ -8597,6 +8605,7 @@ func (c *CustomersTelemetryEventsListCall) PageToken(pageToken string) *Customer // https_latency_change_event - network_state_change_event - // wifi_signal_strength_event - vpn_connection_state_change_event - // app_install_event - app_uninstall_event - app_launch_event - os_crash_event +// - external_displays_event func (c *CustomersTelemetryEventsListCall) ReadMask(readMask string) *CustomersTelemetryEventsListCall { c.urlParams_.Set("readMask", readMask) return c diff --git a/connectors/v1/connectors-api.json b/connectors/v1/connectors-api.json index 3a7ee7e01ef..060908e4e2f 100644 --- a/connectors/v1/connectors-api.json +++ b/connectors/v1/connectors-api.json @@ -311,6 +311,11 @@ "name" ], "parameters": { + "force": { + "description": "Optional. If set to true, any child EndUserAuthentication/EventSubscription resources will also be deleted. Otherwise, the request will fail if the connection has any children. Followed the best practice from https://aip.dev/135#cascading-delete", + "location": "query", + "type": "boolean" + }, "name": { "description": "Required. Resource name of the form: `projects/*/locations/*/connections/*`", "location": "path", @@ -2752,7 +2757,7 @@ } } }, - "revision": "20250703", + "revision": "20250721", "rootUrl": "https://connectors.googleapis.com/", "schemas": { "AuditConfig": { diff --git a/connectors/v1/connectors-gen.go b/connectors/v1/connectors-gen.go index 170ea1a4e05..e29caaff38f 100644 --- a/connectors/v1/connectors-gen.go +++ b/connectors/v1/connectors-gen.go @@ -7391,6 +7391,15 @@ func (r *ProjectsLocationsConnectionsService) Delete(name string) *ProjectsLocat return c } +// Force sets the optional parameter "force": If set to true, any child +// EndUserAuthentication/EventSubscription resources will also be deleted. +// Otherwise, the request will fail if the connection has any children. +// Followed the best practice from https://aip.dev/135#cascading-delete +func (c *ProjectsLocationsConnectionsDeleteCall) Force(force bool) *ProjectsLocationsConnectionsDeleteCall { + c.urlParams_.Set("force", fmt.Sprint(force)) + return c +} + // Fields allows partial responses to be retrieved. See // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more // details. diff --git a/discoveryengine/v1/discoveryengine-api.json b/discoveryengine/v1/discoveryengine-api.json index 0a5287554f9..7ff6c914883 100644 --- a/discoveryengine/v1/discoveryengine-api.json +++ b/discoveryengine/v1/discoveryengine-api.json @@ -2175,7 +2175,7 @@ ], "parameters": { "filter": { - "description": "A filter to apply on the list results. The supported features are: user_pseudo_id, state, starred. Examples: \"user_pseudo_id = some_id\" \"starred = true\"", + "description": "A comma-separated list of fields to filter by, in EBNF grammar. The supported fields are: * `user_pseudo_id` * `state` * `display_name` * `starred` * `is_pinned` * `labels` * `create_time` * `update_time` Examples: \"user_pseudo_id = some_id\" \"display_name = \\\"some_name\\\"\" \"starred = true\" \"is_pinned=true AND (NOT labels:hidden)\" \"create_time \u003e \\\"1970-01-01T12:00:00Z\\\"\"", "location": "query", "type": "string" }, @@ -3982,7 +3982,7 @@ ], "parameters": { "filter": { - "description": "A filter to apply on the list results. The supported features are: user_pseudo_id, state, starred. Examples: \"user_pseudo_id = some_id\" \"starred = true\"", + "description": "A comma-separated list of fields to filter by, in EBNF grammar. The supported fields are: * `user_pseudo_id` * `state` * `display_name` * `starred` * `is_pinned` * `labels` * `create_time` * `update_time` Examples: \"user_pseudo_id = some_id\" \"display_name = \\\"some_name\\\"\" \"starred = true\" \"is_pinned=true AND (NOT labels:hidden)\" \"create_time \u003e \\\"1970-01-01T12:00:00Z\\\"\"", "location": "query", "type": "string" }, @@ -5788,7 +5788,7 @@ ], "parameters": { "filter": { - "description": "A filter to apply on the list results. The supported features are: user_pseudo_id, state, starred. Examples: \"user_pseudo_id = some_id\" \"starred = true\"", + "description": "A comma-separated list of fields to filter by, in EBNF grammar. The supported fields are: * `user_pseudo_id` * `state` * `display_name` * `starred` * `is_pinned` * `labels` * `create_time` * `update_time` Examples: \"user_pseudo_id = some_id\" \"display_name = \\\"some_name\\\"\" \"starred = true\" \"is_pinned=true AND (NOT labels:hidden)\" \"create_time \u003e \\\"1970-01-01T12:00:00Z\\\"\"", "location": "query", "type": "string" }, @@ -7191,7 +7191,7 @@ } } }, - "revision": "20250716", + "revision": "20250723", "rootUrl": "https://discoveryengine.googleapis.com/", "schemas": { "GoogleApiDistribution": { @@ -9184,6 +9184,10 @@ }, "type": "array" }, + "name": { + "description": "Immutable. Identifier. Resource name of the `AssistAnswer`. Format: `projects/{project}/locations/{location}/collections/{collection}/engines/{engine}/sessions/{session}/assistAnswers/{assist_answer}` This field must be a UTF-8 encoded string with a length limit of 1024 characters.", + "type": "string" + }, "replies": { "description": "Replies of the assistant.", "items": { @@ -9238,6 +9242,17 @@ }, "type": "object" }, + "GoogleCloudDiscoveryengineV1Assistant": { + "description": "Discovery Engine Assistant resource.", + "id": "GoogleCloudDiscoveryengineV1Assistant", + "properties": { + "name": { + "description": "Immutable. Resource name of the assistant. Format: `projects/{project}/locations/{location}/collections/{collection}/engines/{engine}/assistants/{assistant}` It must be a UTF-8 encoded string with a length limit of 1024 characters.", + "type": "string" + } + }, + "type": "object" + }, "GoogleCloudDiscoveryengineV1AssistantContent": { "description": "Multi-modal content.", "id": "GoogleCloudDiscoveryengineV1AssistantContent", @@ -10180,11 +10195,12 @@ "type": "boolean" }, "kmsKey": { - "description": "KMS key resource name which will be used to encrypt resources `projects/{project}/locations/{location}/keyRings/{keyRing}/cryptoKeys/{keyId}`.", + "description": "Required. KMS key resource name which will be used to encrypt resources `projects/{project}/locations/{location}/keyRings/{keyRing}/cryptoKeys/{keyId}`.", "type": "string" }, "kmsKeyVersion": { - "description": "KMS key version resource name which will be used to encrypt resources `/cryptoKeyVersions/{keyVersion}`.", + "description": "Output only. KMS key version resource name which will be used to encrypt resources `/cryptoKeyVersions/{keyVersion}`.", + "readOnly": true, "type": "string" }, "lastRotationTimestampMicros": { @@ -13089,6 +13105,21 @@ "dataUseTermsVersion": { "description": "Required. The version of the [Terms for data use](https://cloud.google.com/retail/data-use-terms) that caller has read and would like to give consent to. Acceptable version is `2022-11-23`, and this may change over time.", "type": "string" + }, + "saasParams": { + "$ref": "GoogleCloudDiscoveryengineV1ProvisionProjectRequestSaasParams", + "description": "Optional. Parameters for Agentspace." + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1ProvisionProjectRequestSaasParams": { + "description": "Parameters for Agentspace.", + "id": "GoogleCloudDiscoveryengineV1ProvisionProjectRequestSaasParams", + "properties": { + "acceptBizQos": { + "description": "Optional. Set to `true` to specify that caller has read and would like to give consent to the [Terms for Agent Space quality of service].", + "type": "boolean" } }, "type": "object" @@ -13360,7 +13391,7 @@ "type": "string" }, "records": { - "description": "Required. A list of records to rank. At most 200 records to rank.", + "description": "Required. A list of records to rank.", "items": { "$ref": "GoogleCloudDiscoveryengineV1RankingRecord" }, @@ -15086,10 +15117,6 @@ "$ref": "GoogleCloudDiscoveryengineV1StreamAssistRequestToolsSpecImageGenerationSpec", "description": "Optional. Specification of the image generation tool." }, - "toolRegistry": { - "description": "Optional. The name of the tool registry to use. Format: `projects/{project}/locations/{location}/toolRegistries/{tool_registry}`", - "type": "string" - }, "vertexAiSearchSpec": { "$ref": "GoogleCloudDiscoveryengineV1StreamAssistRequestToolsSpecVertexAiSearchSpec", "description": "Optional. Specification of the Vertex AI Search tool." @@ -15122,11 +15149,6 @@ }, "type": "array" }, - "disabled": { - "deprecated": true, - "description": "Optional. Deprecated. Please refrain from using this field. Whether the Vertex AI Search tool is disabled. Default value is false, the tool is enabled by default.", - "type": "boolean" - }, "filter": { "description": "Optional. The filter syntax consists of an expression language for constructing a predicate from one or more fields of the documents being filtered. Filter expression is case-sensitive. If this field is unrecognizable, an `INVALID_ARGUMENT` is returned. Filtering in Vertex AI Search is done by mapping the LHS filter key to a key property defined in the Vertex AI Search backend -- this mapping is defined by the customer in their schema. For example a media customer might have a field 'name' in their schema. In this case the filter would look like this: filter --\u003e name:'ANY(\"king kong\")' For more information about filtering including syntax and filter operators, see [Filter](https://cloud.google.com/generative-ai-app-builder/docs/filter-search-metadata)", "type": "string" @@ -15143,13 +15165,7 @@ "GoogleCloudDiscoveryengineV1StreamAssistRequestToolsSpecWebGroundingSpec": { "description": "Specification of the web grounding tool.", "id": "GoogleCloudDiscoveryengineV1StreamAssistRequestToolsSpecWebGroundingSpec", - "properties": { - "enabled": { - "deprecated": true, - "description": "Optional. Deprecated. Please refrain from using this field. Whether the web grounding tool is enabled.", - "type": "boolean" - } - }, + "properties": {}, "type": "object" }, "GoogleCloudDiscoveryengineV1StreamAssistResponse": { @@ -16580,11 +16596,12 @@ "type": "boolean" }, "kmsKey": { - "description": "KMS key resource name which will be used to encrypt resources `projects/{project}/locations/{location}/keyRings/{keyRing}/cryptoKeys/{keyId}`.", + "description": "Required. KMS key resource name which will be used to encrypt resources `projects/{project}/locations/{location}/keyRings/{keyRing}/cryptoKeys/{keyId}`.", "type": "string" }, "kmsKeyVersion": { - "description": "KMS key version resource name which will be used to encrypt resources `/cryptoKeyVersions/{keyVersion}`.", + "description": "Output only. KMS key version resource name which will be used to encrypt resources `/cryptoKeyVersions/{keyVersion}`.", + "readOnly": true, "type": "string" }, "lastRotationTimestampMicros": { @@ -19418,7 +19435,7 @@ "id": "GoogleCloudDiscoveryengineV1alphaListSessionsRequest", "properties": { "filter": { - "description": "A filter to apply on the list results. The supported features are: user_pseudo_id, state, starred. Examples: \"user_pseudo_id = some_id\" \"starred = true\"", + "description": "A comma-separated list of fields to filter by, in EBNF grammar. The supported fields are: * `user_pseudo_id` * `state` * `display_name` * `starred` * `is_pinned` * `labels` * `create_time` * `update_time` Examples: \"user_pseudo_id = some_id\" \"display_name = \\\"some_name\\\"\" \"starred = true\" \"is_pinned=true AND (NOT labels:hidden)\" \"create_time \u003e \\\"1970-01-01T12:00:00Z\\\"\"", "type": "string" }, "orderBy": { @@ -21691,11 +21708,12 @@ "type": "boolean" }, "kmsKey": { - "description": "KMS key resource name which will be used to encrypt resources `projects/{project}/locations/{location}/keyRings/{keyRing}/cryptoKeys/{keyId}`.", + "description": "Required. KMS key resource name which will be used to encrypt resources `projects/{project}/locations/{location}/keyRings/{keyRing}/cryptoKeys/{keyId}`.", "type": "string" }, "kmsKeyVersion": { - "description": "KMS key version resource name which will be used to encrypt resources `/cryptoKeyVersions/{keyVersion}`.", + "description": "Output only. KMS key version resource name which will be used to encrypt resources `/cryptoKeyVersions/{keyVersion}`.", + "readOnly": true, "type": "string" }, "lastRotationTimestampMicros": { diff --git a/discoveryengine/v1/discoveryengine-gen.go b/discoveryengine/v1/discoveryengine-gen.go index cc94b3b7cea..7ab0746fccc 100644 --- a/discoveryengine/v1/discoveryengine-gen.go +++ b/discoveryengine/v1/discoveryengine-gen.go @@ -3874,6 +3874,11 @@ type GoogleCloudDiscoveryengineV1AssistAnswer struct { // to answer because of a customer policy violation (e.g., the query or the // answer contained a banned phrase). AssistSkippedReasons []string `json:"assistSkippedReasons,omitempty"` + // Name: Immutable. Identifier. Resource name of the `AssistAnswer`. Format: + // `projects/{project}/locations/{location}/collections/{collection}/engines/{en + // gine}/sessions/{session}/assistAnswers/{assist_answer}` This field must be a + // UTF-8 encoded string with a length limit of 1024 characters. + Name string `json:"name,omitempty"` // Replies: Replies of the assistant. Replies []*GoogleCloudDiscoveryengineV1AssistAnswerReply `json:"replies,omitempty"` // State: State of the answer generation. @@ -3954,6 +3959,31 @@ func (s GoogleCloudDiscoveryengineV1AssistUserMetadata) MarshalJSON() ([]byte, e return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudDiscoveryengineV1Assistant: Discovery Engine Assistant resource. +type GoogleCloudDiscoveryengineV1Assistant struct { + // Name: Immutable. Resource name of the assistant. Format: + // `projects/{project}/locations/{location}/collections/{collection}/engines/{en + // gine}/assistants/{assistant}` It must be a UTF-8 encoded string with a + // length limit of 1024 characters. + 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. "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 GoogleCloudDiscoveryengineV1Assistant) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1Assistant + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudDiscoveryengineV1AssistantContent: Multi-modal content. type GoogleCloudDiscoveryengineV1AssistantContent struct { // CodeExecutionResult: Result of executing an ExecutableCode. @@ -5239,12 +5269,13 @@ func (s GoogleCloudDiscoveryengineV1CloudSqlSource) MarshalJSON() ([]byte, error type GoogleCloudDiscoveryengineV1CmekConfig struct { // IsDefault: Output only. The default CmekConfig for the Customer. IsDefault bool `json:"isDefault,omitempty"` - // KmsKey: KMS key resource name which will be used to encrypt resources + // KmsKey: Required. KMS key resource name which will be used to encrypt + // resources // `projects/{project}/locations/{location}/keyRings/{keyRing}/cryptoKeys/{keyId // }`. KmsKey string `json:"kmsKey,omitempty"` - // KmsKeyVersion: KMS key version resource name which will be used to encrypt - // resources `/cryptoKeyVersions/{keyVersion}`. + // KmsKeyVersion: Output only. KMS key version resource name which will be used + // to encrypt resources `/cryptoKeyVersions/{keyVersion}`. KmsKeyVersion string `json:"kmsKeyVersion,omitempty"` // LastRotationTimestampMicros: Output only. The timestamp of the last key // rotation. @@ -9404,6 +9435,8 @@ type GoogleCloudDiscoveryengineV1ProvisionProjectRequest struct { // would like to give consent to. Acceptable version is `2022-11-23`, and this // may change over time. DataUseTermsVersion string `json:"dataUseTermsVersion,omitempty"` + // SaasParams: Optional. Parameters for Agentspace. + SaasParams *GoogleCloudDiscoveryengineV1ProvisionProjectRequestSaasParams `json:"saasParams,omitempty"` // ForceSendFields is a list of field names (e.g. "AcceptDataUseTerms") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See @@ -9422,6 +9455,31 @@ func (s GoogleCloudDiscoveryengineV1ProvisionProjectRequest) MarshalJSON() ([]by return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudDiscoveryengineV1ProvisionProjectRequestSaasParams: Parameters +// for Agentspace. +type GoogleCloudDiscoveryengineV1ProvisionProjectRequestSaasParams struct { + // AcceptBizQos: Optional. Set to `true` to specify that caller has read and + // would like to give consent to the [Terms for Agent Space quality of + // service]. + AcceptBizQos bool `json:"acceptBizQos,omitempty"` + // ForceSendFields is a list of field names (e.g. "AcceptBizQos") 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. "AcceptBizQos") 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 GoogleCloudDiscoveryengineV1ProvisionProjectRequestSaasParams) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1ProvisionProjectRequestSaasParams + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudDiscoveryengineV1PurgeCompletionSuggestionsMetadata: Metadata // related to the progress of the PurgeCompletionSuggestions operation. This is // returned by the google.longrunning.Operation.metadata field. @@ -9828,7 +9886,7 @@ type GoogleCloudDiscoveryengineV1RankRequest struct { Model string `json:"model,omitempty"` // Query: The query to use. Query string `json:"query,omitempty"` - // Records: Required. A list of records to rank. At most 200 records to rank. + // Records: Required. A list of records to rank. Records []*GoogleCloudDiscoveryengineV1RankingRecord `json:"records,omitempty"` // TopN: The number of results to return. If this is unset or no bigger than // zero, returns all results. @@ -12379,9 +12437,6 @@ func (s GoogleCloudDiscoveryengineV1StreamAssistRequestGenerationSpec) MarshalJS type GoogleCloudDiscoveryengineV1StreamAssistRequestToolsSpec struct { // ImageGenerationSpec: Optional. Specification of the image generation tool. ImageGenerationSpec *GoogleCloudDiscoveryengineV1StreamAssistRequestToolsSpecImageGenerationSpec `json:"imageGenerationSpec,omitempty"` - // ToolRegistry: Optional. The name of the tool registry to use. Format: - // `projects/{project}/locations/{location}/toolRegistries/{tool_registry}` - ToolRegistry string `json:"toolRegistry,omitempty"` // VertexAiSearchSpec: Optional. Specification of the Vertex AI Search tool. VertexAiSearchSpec *GoogleCloudDiscoveryengineV1StreamAssistRequestToolsSpecVertexAiSearchSpec `json:"vertexAiSearchSpec,omitempty"` // VideoGenerationSpec: Optional. Specification of the video generation tool. @@ -12421,10 +12476,6 @@ type GoogleCloudDiscoveryengineV1StreamAssistRequestToolsSpecVertexAiSearchSpec // call and configurations for those data stores. This is only considered for // Engines with multiple data stores. DataStoreSpecs []*GoogleCloudDiscoveryengineV1SearchRequestDataStoreSpec `json:"dataStoreSpecs,omitempty"` - // Disabled: Optional. Deprecated. Please refrain from using this field. - // Whether the Vertex AI Search tool is disabled. Default value is false, the - // tool is enabled by default. - Disabled bool `json:"disabled,omitempty"` // Filter: Optional. The filter syntax consists of an expression language for // constructing a predicate from one or more fields of the documents being // filtered. Filter expression is case-sensitive. If this field is @@ -12463,25 +12514,6 @@ type GoogleCloudDiscoveryengineV1StreamAssistRequestToolsSpecVideoGenerationSpec // GoogleCloudDiscoveryengineV1StreamAssistRequestToolsSpecWebGroundingSpec: // Specification of the web grounding tool. type GoogleCloudDiscoveryengineV1StreamAssistRequestToolsSpecWebGroundingSpec struct { - // Enabled: Optional. Deprecated. Please refrain from using this field. Whether - // the web grounding tool is enabled. - Enabled bool `json:"enabled,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 GoogleCloudDiscoveryengineV1StreamAssistRequestToolsSpecWebGroundingSpec) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1StreamAssistRequestToolsSpecWebGroundingSpec - return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } // GoogleCloudDiscoveryengineV1StreamAssistResponse: Response for the @@ -14359,12 +14391,13 @@ func (s GoogleCloudDiscoveryengineV1alphaBatchUpdateUserLicensesResponse) Marsha type GoogleCloudDiscoveryengineV1alphaCmekConfig struct { // IsDefault: Output only. The default CmekConfig for the Customer. IsDefault bool `json:"isDefault,omitempty"` - // KmsKey: KMS key resource name which will be used to encrypt resources + // KmsKey: Required. KMS key resource name which will be used to encrypt + // resources // `projects/{project}/locations/{location}/keyRings/{keyRing}/cryptoKeys/{keyId // }`. KmsKey string `json:"kmsKey,omitempty"` - // KmsKeyVersion: KMS key version resource name which will be used to encrypt - // resources `/cryptoKeyVersions/{keyVersion}`. + // KmsKeyVersion: Output only. KMS key version resource name which will be used + // to encrypt resources `/cryptoKeyVersions/{keyVersion}`. KmsKeyVersion string `json:"kmsKeyVersion,omitempty"` // LastRotationTimestampMicros: Output only. The timestamp of the last key // rotation. @@ -17927,9 +17960,12 @@ func (s GoogleCloudDiscoveryengineV1alphaLanguageInfo) MarshalJSON() ([]byte, er // GoogleCloudDiscoveryengineV1alphaListSessionsRequest: Request for // ListSessions method. type GoogleCloudDiscoveryengineV1alphaListSessionsRequest struct { - // Filter: A filter to apply on the list results. The supported features are: - // user_pseudo_id, state, starred. Examples: "user_pseudo_id = some_id" - // "starred = true" + // Filter: A comma-separated list of fields to filter by, in EBNF grammar. The + // supported fields are: * `user_pseudo_id` * `state` * `display_name` * + // `starred` * `is_pinned` * `labels` * `create_time` * `update_time` Examples: + // "user_pseudo_id = some_id" "display_name = \"some_name\"" "starred = true" + // "is_pinned=true AND (NOT labels:hidden)" "create_time > + // \"1970-01-01T12:00:00Z\"" Filter string `json:"filter,omitempty"` // OrderBy: A comma-separated list of fields to order by, sorted in ascending // order. Use "desc" after a field name for descending. Supported fields: * @@ -21140,12 +21176,13 @@ func (s GoogleCloudDiscoveryengineV1betaBatchUpdateUserLicensesResponse) Marshal type GoogleCloudDiscoveryengineV1betaCmekConfig struct { // IsDefault: Output only. The default CmekConfig for the Customer. IsDefault bool `json:"isDefault,omitempty"` - // KmsKey: KMS key resource name which will be used to encrypt resources + // KmsKey: Required. KMS key resource name which will be used to encrypt + // resources // `projects/{project}/locations/{location}/keyRings/{keyRing}/cryptoKeys/{keyId // }`. KmsKey string `json:"kmsKey,omitempty"` - // KmsKeyVersion: KMS key version resource name which will be used to encrypt - // resources `/cryptoKeyVersions/{keyVersion}`. + // KmsKeyVersion: Output only. KMS key version resource name which will be used + // to encrypt resources `/cryptoKeyVersions/{keyVersion}`. KmsKeyVersion string `json:"kmsKeyVersion,omitempty"` // LastRotationTimestampMicros: Output only. The timestamp of the last key // rotation. @@ -33956,9 +33993,12 @@ func (r *ProjectsLocationsCollectionsDataStoresSessionsService) List(parent stri return c } -// Filter sets the optional parameter "filter": A filter to apply on the list -// results. The supported features are: user_pseudo_id, state, starred. -// Examples: "user_pseudo_id = some_id" "starred = true" +// Filter sets the optional parameter "filter": A comma-separated list of +// fields to filter by, in EBNF grammar. The supported fields are: * +// `user_pseudo_id` * `state` * `display_name` * `starred` * `is_pinned` * +// `labels` * `create_time` * `update_time` Examples: "user_pseudo_id = +// some_id" "display_name = \"some_name\"" "starred = true" "is_pinned=true AND +// (NOT labels:hidden)" "create_time > \"1970-01-01T12:00:00Z\"" func (c *ProjectsLocationsCollectionsDataStoresSessionsListCall) Filter(filter string) *ProjectsLocationsCollectionsDataStoresSessionsListCall { c.urlParams_.Set("filter", filter) return c @@ -40718,9 +40758,12 @@ func (r *ProjectsLocationsCollectionsEnginesSessionsService) List(parent string) return c } -// Filter sets the optional parameter "filter": A filter to apply on the list -// results. The supported features are: user_pseudo_id, state, starred. -// Examples: "user_pseudo_id = some_id" "starred = true" +// Filter sets the optional parameter "filter": A comma-separated list of +// fields to filter by, in EBNF grammar. The supported fields are: * +// `user_pseudo_id` * `state` * `display_name` * `starred` * `is_pinned` * +// `labels` * `create_time` * `update_time` Examples: "user_pseudo_id = +// some_id" "display_name = \"some_name\"" "starred = true" "is_pinned=true AND +// (NOT labels:hidden)" "create_time > \"1970-01-01T12:00:00Z\"" func (c *ProjectsLocationsCollectionsEnginesSessionsListCall) Filter(filter string) *ProjectsLocationsCollectionsEnginesSessionsListCall { c.urlParams_.Set("filter", filter) return c @@ -47443,9 +47486,12 @@ func (r *ProjectsLocationsDataStoresSessionsService) List(parent string) *Projec return c } -// Filter sets the optional parameter "filter": A filter to apply on the list -// results. The supported features are: user_pseudo_id, state, starred. -// Examples: "user_pseudo_id = some_id" "starred = true" +// Filter sets the optional parameter "filter": A comma-separated list of +// fields to filter by, in EBNF grammar. The supported fields are: * +// `user_pseudo_id` * `state` * `display_name` * `starred` * `is_pinned` * +// `labels` * `create_time` * `update_time` Examples: "user_pseudo_id = +// some_id" "display_name = \"some_name\"" "starred = true" "is_pinned=true AND +// (NOT labels:hidden)" "create_time > \"1970-01-01T12:00:00Z\"" func (c *ProjectsLocationsDataStoresSessionsListCall) Filter(filter string) *ProjectsLocationsDataStoresSessionsListCall { c.urlParams_.Set("filter", filter) return c diff --git a/discoveryengine/v1alpha/discoveryengine-api.json b/discoveryengine/v1alpha/discoveryengine-api.json index c7d6812d176..185074f1d3a 100644 --- a/discoveryengine/v1alpha/discoveryengine-api.json +++ b/discoveryengine/v1alpha/discoveryengine-api.json @@ -3023,7 +3023,7 @@ ], "parameters": { "filter": { - "description": "A filter to apply on the list results. The supported features are: user_pseudo_id, state, starred. Examples: \"user_pseudo_id = some_id\" \"starred = true\"", + "description": "A comma-separated list of fields to filter by, in EBNF grammar. The supported fields are: * `user_pseudo_id` * `state` * `display_name` * `starred` * `is_pinned` * `labels` * `create_time` * `update_time` Examples: \"user_pseudo_id = some_id\" \"display_name = \\\"some_name\\\"\" \"starred = true\" \"is_pinned=true AND (NOT labels:hidden)\" \"create_time \u003e \\\"1970-01-01T12:00:00Z\\\"\"", "location": "query", "type": "string" }, @@ -5067,7 +5067,7 @@ ], "parameters": { "filter": { - "description": "A filter to apply on the list results. The supported features are: user_pseudo_id, state, starred. Examples: \"user_pseudo_id = some_id\" \"starred = true\"", + "description": "A comma-separated list of fields to filter by, in EBNF grammar. The supported fields are: * `user_pseudo_id` * `state` * `display_name` * `starred` * `is_pinned` * `labels` * `create_time` * `update_time` Examples: \"user_pseudo_id = some_id\" \"display_name = \\\"some_name\\\"\" \"starred = true\" \"is_pinned=true AND (NOT labels:hidden)\" \"create_time \u003e \\\"1970-01-01T12:00:00Z\\\"\"", "location": "query", "type": "string" }, @@ -5167,6 +5167,51 @@ ] } } + }, + "files": { + "methods": { + "list": { + "description": "Lists metadata for all files in the current session.", + "flatPath": "v1alpha/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/engines/{enginesId}/sessions/{sessionsId}/files", + "httpMethod": "GET", + "id": "discoveryengine.projects.locations.collections.engines.sessions.files.list", + "parameterOrder": [ + "parent" + ], + "parameters": { + "filter": { + "description": "Optional. The filter syntax consists of an expression language for constructing a predicate from one or more fields of the files being filtered. Filter expression is case-sensitive. Currently supported field names are: * upload_time * last_add_time * last_use_time * file_name * mime_type Some examples of filters would be: * \"file_name = 'file_1'\" * \"file_name = 'file_1' AND mime_type = 'text/plain'\" * \"last_use_time \u003e '2025-06-14T12:00:00Z'\" For a full description of the filter format, please see https://google.aip.dev/160.", + "location": "query", + "type": "string" + }, + "pageSize": { + "description": "Optional. The maximum number of files to return. The service may return fewer than this value. If unspecified, at most 100 files will be returned. The maximum value is 1000; values above 1000 will be coerced to 1000. If user specifies a value less than or equal to 0 - the request will be rejected with an INVALID_ARGUMENT error.", + "format": "int32", + "location": "query", + "type": "integer" + }, + "pageToken": { + "description": "Optional. A page token received from a previous `ListFiles` call. Provide this to retrieve the subsequent page. When paginating, all other parameters provided to `ListFiles` must match the call that provided the page token (except `page_size`, which may differ).", + "location": "query", + "type": "string" + }, + "parent": { + "description": "Required. The resource name of the Session. Format: `projects/{project}/locations/{location}/collections/{collection}/engines/{engine}/sessions/{session}` Name of the session resource to which the file belong.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/engines/[^/]+/sessions/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1alpha/{+parent}/files", + "response": { + "$ref": "GoogleCloudDiscoveryengineV1alphaListFilesResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + } + } } } }, @@ -7161,7 +7206,7 @@ ], "parameters": { "filter": { - "description": "A filter to apply on the list results. The supported features are: user_pseudo_id, state, starred. Examples: \"user_pseudo_id = some_id\" \"starred = true\"", + "description": "A comma-separated list of fields to filter by, in EBNF grammar. The supported fields are: * `user_pseudo_id` * `state` * `display_name` * `starred` * `is_pinned` * `labels` * `create_time` * `update_time` Examples: \"user_pseudo_id = some_id\" \"display_name = \\\"some_name\\\"\" \"starred = true\" \"is_pinned=true AND (NOT labels:hidden)\" \"create_time \u003e \\\"1970-01-01T12:00:00Z\\\"\"", "location": "query", "type": "string" }, @@ -9253,7 +9298,7 @@ } } }, - "revision": "20250716", + "revision": "20250723", "rootUrl": "https://discoveryengine.googleapis.com/", "schemas": { "ApiservingMediaRequestInfo": { @@ -10330,6 +10375,17 @@ }, "type": "object" }, + "GoogleCloudDiscoveryengineV1Assistant": { + "description": "Discovery Engine Assistant resource.", + "id": "GoogleCloudDiscoveryengineV1Assistant", + "properties": { + "name": { + "description": "Immutable. Resource name of the assistant. Format: `projects/{project}/locations/{location}/collections/{collection}/engines/{engine}/assistants/{assistant}` It must be a UTF-8 encoded string with a length limit of 1024 characters.", + "type": "string" + } + }, + "type": "object" + }, "GoogleCloudDiscoveryengineV1BatchCreateTargetSiteMetadata": { "description": "Metadata related to the progress of the SiteSearchEngineService.BatchCreateTargetSites operation. This will be returned by the google.longrunning.Operation.metadata field.", "id": "GoogleCloudDiscoveryengineV1BatchCreateTargetSiteMetadata", @@ -10419,11 +10475,12 @@ "type": "boolean" }, "kmsKey": { - "description": "KMS key resource name which will be used to encrypt resources `projects/{project}/locations/{location}/keyRings/{keyRing}/cryptoKeys/{keyId}`.", + "description": "Required. KMS key resource name which will be used to encrypt resources `projects/{project}/locations/{location}/keyRings/{keyRing}/cryptoKeys/{keyId}`.", "type": "string" }, "kmsKeyVersion": { - "description": "KMS key version resource name which will be used to encrypt resources `/cryptoKeyVersions/{keyVersion}`.", + "description": "Output only. KMS key version resource name which will be used to encrypt resources `/cryptoKeyVersions/{keyVersion}`.", + "readOnly": true, "type": "string" }, "lastRotationTimestampMicros": { @@ -14667,6 +14724,10 @@ }, "type": "array" }, + "name": { + "description": "Immutable. Identifier. Resource name of the `AssistAnswer`. Format: `projects/{project}/locations/{location}/collections/{collection}/engines/{engine}/sessions/{session}/assistAnswers/{assist_answer}` This field must be a UTF-8 encoded string with a length limit of 1024 characters.", + "type": "string" + }, "replies": { "description": "Replies of the assistant.", "items": { @@ -15766,11 +15827,12 @@ "type": "boolean" }, "kmsKey": { - "description": "KMS key resource name which will be used to encrypt resources `projects/{project}/locations/{location}/keyRings/{keyRing}/cryptoKeys/{keyId}`.", + "description": "Required. KMS key resource name which will be used to encrypt resources `projects/{project}/locations/{location}/keyRings/{keyRing}/cryptoKeys/{keyId}`.", "type": "string" }, "kmsKeyVersion": { - "description": "KMS key version resource name which will be used to encrypt resources `/cryptoKeyVersions/{keyVersion}`.", + "description": "Output only. KMS key version resource name which will be used to encrypt resources `/cryptoKeyVersions/{keyVersion}`.", + "readOnly": true, "type": "string" }, "lastRotationTimestampMicros": { @@ -18906,6 +18968,169 @@ }, "type": "object" }, + "GoogleCloudDiscoveryengineV1alphaFileCharacteristics": { + "description": "Caracteristics of other file types.", + "id": "GoogleCloudDiscoveryengineV1alphaFileCharacteristics", + "properties": { + "characteristics": { + "additionalProperties": { + "type": "string" + }, + "description": "Output only. Generic map of characteristics.", + "readOnly": true, + "type": "object" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaFileMetadata": { + "description": "Represents a file attached to a session (context file)", + "id": "GoogleCloudDiscoveryengineV1alphaFileMetadata", + "properties": { + "byteSize": { + "description": "Output only. The size of the context file in bytes.", + "format": "int64", + "readOnly": true, + "type": "string" + }, + "downloadUri": { + "description": "Output only. The AssistantService.DownloadSessionFile URL to download the file. This URL will need the same credentials as AssistantService.ListSessionFileMetadata method and will provide the resource.", + "readOnly": true, + "type": "string" + }, + "fileId": { + "description": "Output only. The ID of the file.", + "readOnly": true, + "type": "string" + }, + "fileOriginType": { + "description": "Optional. The origin of the file.", + "enum": [ + "FILE_ORIGIN_TYPE_UNSPECIFIED", + "USER_PROVIDED", + "AI_GENERATED", + "INTERNALLY_GENERATED" + ], + "enumDescriptions": [ + "Default value.", + "The file was provided by the user.", + "The file was generated by an AI model.", + "The file was generated from other files by an internal process." + ], + "type": "string" + }, + "lastAddTime": { + "description": "Output only. The time the file was added to the session. Note that if a file was added, then modified externally, then added again, the add time will be updated.", + "format": "google-datetime", + "readOnly": true, + "type": "string" + }, + "metadata": { + "additionalProperties": { + "type": "string" + }, + "description": "Optional. Represents metadata related to the file that can suit particular use cases. The prefix \"google.\" is reserved for the key for use by Google, but other prefixes can be freely used.", + "type": "object" + }, + "mimeType": { + "description": "The content type of the file, see https://www.iana.org/assignments/media-types/media-types.xhtml.", + "type": "string" + }, + "name": { + "description": "Output only. The name of the file uploaded.", + "readOnly": true, + "type": "string" + }, + "originalSourceType": { + "description": "Optional. The type of the original source of the file.", + "enum": [ + "FILE_SOURCE_UNSPECIFIED", + "FILE_SOURCE_INLINE", + "FILE_SOURCE_LOCAL", + "FILE_SOURCE_CLOUD_STORAGE", + "FILE_SOURCE_CLOUD_DRIVE", + "FILE_SOURCE_URL" + ], + "enumDescriptions": [ + "Default value. Unknown source.", + "The data of the file was provided inline (e.g. pasted from the clipboard).", + "The file was uploaded from a local file.", + "The file was uploaded from Cloud Storage.", + "The file was uploaded from Drive.", + "The file was retrieved from a URL (e.g. public web)." + ], + "type": "string" + }, + "originalUri": { + "description": "Optional. The original location of the file. It may be a local file path, or any other URI that allows accessing the file in an external system. There are two scenarios in which this url may be empty: 1. If the file was sent as inline data (e.g. pasted from the clipboard). 2. If the original location is not available. Note that there's no guarantee that the URI will be pointing to a valid or actually existing file. For example, a file might have been uploaded to the session, and then deleted from the original source.", + "type": "string" + }, + "uploadTime": { + "description": "Output only. The time the file was uploaded (If this is a file generated by an internal process and then made available to the session, this indicates the moment it happened).", + "format": "google-datetime", + "readOnly": true, + "type": "string" + }, + "views": { + "additionalProperties": { + "$ref": "GoogleCloudDiscoveryengineV1alphaFileView" + }, + "description": "Output only. Alternate views of this file object. Each file view is attached to a specific role. Possible example keys: - \"thumbnail\" - \"mobile_thumbnail\" - \"clip\" - \"summary\" - \"translation\"", + "readOnly": true, + "type": "object" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaFileView": { + "description": "Represents a specific alternate version or \"view\" of a file object, such as a summary, a thumbnail, a translated version, etc.", + "id": "GoogleCloudDiscoveryengineV1alphaFileView", + "properties": { + "byteSize": { + "description": "Output only. The size of the view in bytes.", + "format": "int64", + "readOnly": true, + "type": "string" + }, + "createTime": { + "description": "Output only. The time the view was created.", + "format": "google-datetime", + "readOnly": true, + "type": "string" + }, + "fileCharacteristics": { + "$ref": "GoogleCloudDiscoveryengineV1alphaFileCharacteristics", + "description": "Output only. Characteristics of other file types.", + "readOnly": true + }, + "imageCharacteristics": { + "$ref": "GoogleCloudDiscoveryengineV1alphaImageCharacteristics", + "description": "Output only. Characteristics of an image media view.", + "readOnly": true + }, + "mimeType": { + "description": "Output only. MIME type (e.g., \"image/jpeg\", \"image/png\", \"text/plain\", \"video/mp4\")", + "readOnly": true, + "type": "string" + }, + "uri": { + "description": "Output only. The URI to access this media view.", + "readOnly": true, + "type": "string" + }, + "videoCharacteristics": { + "$ref": "GoogleCloudDiscoveryengineV1alphaVideoCharacteristics", + "description": "Output only. Characteristics of a video media view.", + "readOnly": true + }, + "viewId": { + "description": "Output only. Globally Unique id for this specific view.", + "readOnly": true, + "type": "string" + } + }, + "type": "object" + }, "GoogleCloudDiscoveryengineV1alphaFirestoreSource": { "description": "Firestore source import data from.", "id": "GoogleCloudDiscoveryengineV1alphaFirestoreSource", @@ -19182,6 +19407,52 @@ }, "type": "object" }, + "GoogleCloudDiscoveryengineV1alphaImageCharacteristics": { + "description": "Standard characteristics of an image media view.", + "id": "GoogleCloudDiscoveryengineV1alphaImageCharacteristics", + "properties": { + "bitDepth": { + "description": "Output only. Bit depth of the image (e.g., 8-bit, 16-bit).", + "format": "int32", + "readOnly": true, + "type": "integer" + }, + "colorSpace": { + "description": "Output only. Color space of the image (e.g., \"RGB\", \"CMYK\", \"Grayscale\").", + "enum": [ + "COLOR_SPACE_UNSPECIFIED", + "RGB", + "CMYK", + "GRAYSCALE", + "YUV", + "OTHER_COLOR_SPACE" + ], + "enumDescriptions": [ + "Default value. Unknown color space.", + "Red, green, blue colorspace.", + "Cyan, magenta, yellow, and black colorspace.", + "Grayscale colorspace.", + "YUV colorspace.", + "Other colorspace." + ], + "readOnly": true, + "type": "string" + }, + "height": { + "description": "Output only. Image height in pixels.", + "format": "int32", + "readOnly": true, + "type": "integer" + }, + "width": { + "description": "Output only. Image width in pixels.", + "format": "int32", + "readOnly": true, + "type": "integer" + } + }, + "type": "object" + }, "GoogleCloudDiscoveryengineV1alphaImportCompletionSuggestionsMetadata": { "description": "Metadata related to the progress of the ImportCompletionSuggestions operation. This will be returned by the google.longrunning.Operation.metadata field.", "id": "GoogleCloudDiscoveryengineV1alphaImportCompletionSuggestionsMetadata", @@ -19983,6 +20254,24 @@ }, "type": "object" }, + "GoogleCloudDiscoveryengineV1alphaListFilesResponse": { + "description": "Response message for SessionService.ListFiles method.", + "id": "GoogleCloudDiscoveryengineV1alphaListFilesResponse", + "properties": { + "files": { + "description": "The FileMetadatas.", + "items": { + "$ref": "GoogleCloudDiscoveryengineV1alphaFileMetadata" + }, + "type": "array" + }, + "nextPageToken": { + "description": "A token to retrieve next page of results. Pass this value in the ListFilesRequest.page_token field in the subsequent call to `ListFiles` method to retrieve the next page of results.", + "type": "string" + } + }, + "type": "object" + }, "GoogleCloudDiscoveryengineV1alphaListIdentityMappingStoresResponse": { "description": "Response message for IdentityMappingStoreService.ListIdentityMappingStores", "id": "GoogleCloudDiscoveryengineV1alphaListIdentityMappingStoresResponse", @@ -20096,7 +20385,7 @@ "id": "GoogleCloudDiscoveryengineV1alphaListSessionsRequest", "properties": { "filter": { - "description": "A filter to apply on the list results. The supported features are: user_pseudo_id, state, starred. Examples: \"user_pseudo_id = some_id\" \"starred = true\"", + "description": "A comma-separated list of fields to filter by, in EBNF grammar. The supported fields are: * `user_pseudo_id` * `state` * `display_name` * `starred` * `is_pinned` * `labels` * `create_time` * `update_time` Examples: \"user_pseudo_id = some_id\" \"display_name = \\\"some_name\\\"\" \"starred = true\" \"is_pinned=true AND (NOT labels:hidden)\" \"create_time \u003e \\\"1970-01-01T12:00:00Z\\\"\"", "type": "string" }, "orderBy": { @@ -20461,6 +20750,21 @@ "dataUseTermsVersion": { "description": "Required. The version of the [Terms for data use](https://cloud.google.com/retail/data-use-terms) that caller has read and would like to give consent to. Acceptable version is `2022-11-23`, and this may change over time.", "type": "string" + }, + "saasParams": { + "$ref": "GoogleCloudDiscoveryengineV1alphaProvisionProjectRequestSaasParams", + "description": "Optional. Parameters for Agentspace." + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaProvisionProjectRequestSaasParams": { + "description": "Parameters for Agentspace.", + "id": "GoogleCloudDiscoveryengineV1alphaProvisionProjectRequestSaasParams", + "properties": { + "acceptBizQos": { + "description": "Optional. Set to `true` to specify that caller has read and would like to give consent to the [Terms for Agent Space quality of service].", + "type": "boolean" } }, "type": "object" @@ -20825,7 +21129,7 @@ "type": "string" }, "records": { - "description": "Required. A list of records to rank. At most 200 records to rank.", + "description": "Required. A list of records to rank.", "items": { "$ref": "GoogleCloudDiscoveryengineV1alphaRankingRecord" }, @@ -23839,10 +24143,6 @@ "$ref": "GoogleCloudDiscoveryengineV1alphaStreamAssistRequestToolsSpecImageGenerationSpec", "description": "Optional. Specification of the image generation tool." }, - "toolRegistry": { - "description": "Optional. The name of the tool registry to use. Format: `projects/{project}/locations/{location}/toolRegistries/{tool_registry}`", - "type": "string" - }, "vertexAiSearchSpec": { "$ref": "GoogleCloudDiscoveryengineV1alphaStreamAssistRequestToolsSpecVertexAiSearchSpec", "description": "Optional. Specification of the Vertex AI Search tool." @@ -23875,11 +24175,6 @@ }, "type": "array" }, - "disabled": { - "deprecated": true, - "description": "Optional. Deprecated. Please refrain from using this field. Whether the Vertex AI Search tool is disabled. Default value is false, the tool is enabled by default.", - "type": "boolean" - }, "filter": { "description": "Optional. The filter syntax consists of an expression language for constructing a predicate from one or more fields of the documents being filtered. Filter expression is case-sensitive. If this field is unrecognizable, an `INVALID_ARGUMENT` is returned. Filtering in Vertex AI Search is done by mapping the LHS filter key to a key property defined in the Vertex AI Search backend -- this mapping is defined by the customer in their schema. For example a media customer might have a field 'name' in their schema. In this case the filter would look like this: filter --\u003e name:'ANY(\"king kong\")' For more information about filtering including syntax and filter operators, see [Filter](https://cloud.google.com/generative-ai-app-builder/docs/filter-search-metadata)", "type": "string" @@ -23896,13 +24191,7 @@ "GoogleCloudDiscoveryengineV1alphaStreamAssistRequestToolsSpecWebGroundingSpec": { "description": "Specification of the web grounding tool.", "id": "GoogleCloudDiscoveryengineV1alphaStreamAssistRequestToolsSpecWebGroundingSpec", - "properties": { - "enabled": { - "deprecated": true, - "description": "Optional. Deprecated. Please refrain from using this field. Whether the web grounding tool is enabled.", - "type": "boolean" - } - }, + "properties": {}, "type": "object" }, "GoogleCloudDiscoveryengineV1alphaStreamAssistResponse": { @@ -24527,6 +24816,65 @@ }, "type": "object" }, + "GoogleCloudDiscoveryengineV1alphaVideoCharacteristics": { + "description": "Standard characteristics of a video media view.", + "id": "GoogleCloudDiscoveryengineV1alphaVideoCharacteristics", + "properties": { + "audioBitrateKbps": { + "description": "Output only. Bitrate of the audio in kbps.", + "format": "int32", + "readOnly": true, + "type": "integer" + }, + "audioCodecs": { + "description": "Output only. Audio codecs used in the video.", + "items": { + "type": "string" + }, + "readOnly": true, + "type": "array" + }, + "duration": { + "description": "Output only. Video duration.", + "format": "google-duration", + "readOnly": true, + "type": "string" + }, + "frameRate": { + "description": "Output only. Frame rate (frames per second).", + "format": "double", + "readOnly": true, + "type": "number" + }, + "height": { + "description": "Output only. Video height in pixels.", + "format": "int32", + "readOnly": true, + "type": "integer" + }, + "videoBitrateKbps": { + "description": "Output only. Bitrate of the video in kbps.", + "format": "int32", + "readOnly": true, + "type": "integer" + }, + "videoCodecs": { + "description": "Output only. Video codecs used in the video.", + "items": { + "type": "string" + }, + "readOnly": true, + "type": "array" + }, + "width": { + "description": "Output only. Video width in pixels.", + "format": "int32", + "readOnly": true, + "type": "integer" + } + }, + "type": "object" + }, "GoogleCloudDiscoveryengineV1alphaWidgetConfig": { "description": "WidgetConfig captures configs at the Widget level.", "id": "GoogleCloudDiscoveryengineV1alphaWidgetConfig", @@ -25403,11 +25751,12 @@ "type": "boolean" }, "kmsKey": { - "description": "KMS key resource name which will be used to encrypt resources `projects/{project}/locations/{location}/keyRings/{keyRing}/cryptoKeys/{keyId}`.", + "description": "Required. KMS key resource name which will be used to encrypt resources `projects/{project}/locations/{location}/keyRings/{keyRing}/cryptoKeys/{keyId}`.", "type": "string" }, "kmsKeyVersion": { - "description": "KMS key version resource name which will be used to encrypt resources `/cryptoKeyVersions/{keyVersion}`.", + "description": "Output only. KMS key version resource name which will be used to encrypt resources `/cryptoKeyVersions/{keyVersion}`.", + "readOnly": true, "type": "string" }, "lastRotationTimestampMicros": { diff --git a/discoveryengine/v1alpha/discoveryengine-gen.go b/discoveryengine/v1alpha/discoveryengine-gen.go index 4e01e7f2df0..71508f957b7 100644 --- a/discoveryengine/v1alpha/discoveryengine-gen.go +++ b/discoveryengine/v1alpha/discoveryengine-gen.go @@ -703,6 +703,7 @@ type ProjectsLocationsCollectionsEnginesServingConfigsService struct { func NewProjectsLocationsCollectionsEnginesSessionsService(s *Service) *ProjectsLocationsCollectionsEnginesSessionsService { rs := &ProjectsLocationsCollectionsEnginesSessionsService{s: s} rs.Answers = NewProjectsLocationsCollectionsEnginesSessionsAnswersService(s) + rs.Files = NewProjectsLocationsCollectionsEnginesSessionsFilesService(s) return rs } @@ -710,6 +711,8 @@ type ProjectsLocationsCollectionsEnginesSessionsService struct { s *Service Answers *ProjectsLocationsCollectionsEnginesSessionsAnswersService + + Files *ProjectsLocationsCollectionsEnginesSessionsFilesService } func NewProjectsLocationsCollectionsEnginesSessionsAnswersService(s *Service) *ProjectsLocationsCollectionsEnginesSessionsAnswersService { @@ -721,6 +724,15 @@ type ProjectsLocationsCollectionsEnginesSessionsAnswersService struct { s *Service } +func NewProjectsLocationsCollectionsEnginesSessionsFilesService(s *Service) *ProjectsLocationsCollectionsEnginesSessionsFilesService { + rs := &ProjectsLocationsCollectionsEnginesSessionsFilesService{s: s} + return rs +} + +type ProjectsLocationsCollectionsEnginesSessionsFilesService struct { + s *Service +} + func NewProjectsLocationsCollectionsEnginesWidgetConfigsService(s *Service) *ProjectsLocationsCollectionsEnginesWidgetConfigsService { rs := &ProjectsLocationsCollectionsEnginesWidgetConfigsService{s: s} return rs @@ -2722,6 +2734,31 @@ func (s *GoogleCloudDiscoveryengineV1AnswerGenerationSpecUserDefinedClassifierSp return nil } +// GoogleCloudDiscoveryengineV1Assistant: Discovery Engine Assistant resource. +type GoogleCloudDiscoveryengineV1Assistant struct { + // Name: Immutable. Resource name of the assistant. Format: + // `projects/{project}/locations/{location}/collections/{collection}/engines/{en + // gine}/assistants/{assistant}` It must be a UTF-8 encoded string with a + // length limit of 1024 characters. + 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. "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 GoogleCloudDiscoveryengineV1Assistant) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1Assistant + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudDiscoveryengineV1BatchCreateTargetSiteMetadata: Metadata related // to the progress of the SiteSearchEngineService.BatchCreateTargetSites // operation. This will be returned by the @@ -2835,12 +2872,13 @@ func (s GoogleCloudDiscoveryengineV1BatchUpdateUserLicensesResponse) MarshalJSON type GoogleCloudDiscoveryengineV1CmekConfig struct { // IsDefault: Output only. The default CmekConfig for the Customer. IsDefault bool `json:"isDefault,omitempty"` - // KmsKey: KMS key resource name which will be used to encrypt resources + // KmsKey: Required. KMS key resource name which will be used to encrypt + // resources // `projects/{project}/locations/{location}/keyRings/{keyRing}/cryptoKeys/{keyId // }`. KmsKey string `json:"kmsKey,omitempty"` - // KmsKeyVersion: KMS key version resource name which will be used to encrypt - // resources `/cryptoKeyVersions/{keyVersion}`. + // KmsKeyVersion: Output only. KMS key version resource name which will be used + // to encrypt resources `/cryptoKeyVersions/{keyVersion}`. KmsKeyVersion string `json:"kmsKeyVersion,omitempty"` // LastRotationTimestampMicros: Output only. The timestamp of the last key // rotation. @@ -8572,6 +8610,11 @@ type GoogleCloudDiscoveryengineV1alphaAssistAnswer struct { // to answer because of a customer policy violation (e.g., the query or the // answer contained a banned phrase). AssistSkippedReasons []string `json:"assistSkippedReasons,omitempty"` + // Name: Immutable. Identifier. Resource name of the `AssistAnswer`. Format: + // `projects/{project}/locations/{location}/collections/{collection}/engines/{en + // gine}/sessions/{session}/assistAnswers/{assist_answer}` This field must be a + // UTF-8 encoded string with a length limit of 1024 characters. + Name string `json:"name,omitempty"` // Replies: Replies of the assistant. Replies []*GoogleCloudDiscoveryengineV1alphaAssistAnswerReply `json:"replies,omitempty"` // State: State of the answer generation. @@ -10084,12 +10127,13 @@ func (s GoogleCloudDiscoveryengineV1alphaCloudSqlSource) MarshalJSON() ([]byte, type GoogleCloudDiscoveryengineV1alphaCmekConfig struct { // IsDefault: Output only. The default CmekConfig for the Customer. IsDefault bool `json:"isDefault,omitempty"` - // KmsKey: KMS key resource name which will be used to encrypt resources + // KmsKey: Required. KMS key resource name which will be used to encrypt + // resources // `projects/{project}/locations/{location}/keyRings/{keyRing}/cryptoKeys/{keyId // }`. KmsKey string `json:"kmsKey,omitempty"` - // KmsKeyVersion: KMS key version resource name which will be used to encrypt - // resources `/cryptoKeyVersions/{keyVersion}`. + // KmsKeyVersion: Output only. KMS key version resource name which will be used + // to encrypt resources `/cryptoKeyVersions/{keyVersion}`. KmsKeyVersion string `json:"kmsKeyVersion,omitempty"` // LastRotationTimestampMicros: Output only. The timestamp of the last key // rotation. @@ -14114,6 +14158,148 @@ func (s GoogleCloudDiscoveryengineV1alphaFieldConfig) MarshalJSON() ([]byte, err return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudDiscoveryengineV1alphaFileCharacteristics: Caracteristics of +// other file types. +type GoogleCloudDiscoveryengineV1alphaFileCharacteristics struct { + // Characteristics: Output only. Generic map of characteristics. + Characteristics map[string]string `json:"characteristics,omitempty"` + // ForceSendFields is a list of field names (e.g. "Characteristics") 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. "Characteristics") 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 GoogleCloudDiscoveryengineV1alphaFileCharacteristics) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaFileCharacteristics + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaFileMetadata: Represents a file attached to +// a session (context file) +type GoogleCloudDiscoveryengineV1alphaFileMetadata struct { + // ByteSize: Output only. The size of the context file in bytes. + ByteSize int64 `json:"byteSize,omitempty,string"` + // DownloadUri: Output only. The AssistantService.DownloadSessionFile URL to + // download the file. This URL will need the same credentials as + // AssistantService.ListSessionFileMetadata method and will provide the + // resource. + DownloadUri string `json:"downloadUri,omitempty"` + // FileId: Output only. The ID of the file. + FileId string `json:"fileId,omitempty"` + // FileOriginType: Optional. The origin of the file. + // + // Possible values: + // "FILE_ORIGIN_TYPE_UNSPECIFIED" - Default value. + // "USER_PROVIDED" - The file was provided by the user. + // "AI_GENERATED" - The file was generated by an AI model. + // "INTERNALLY_GENERATED" - The file was generated from other files by an + // internal process. + FileOriginType string `json:"fileOriginType,omitempty"` + // LastAddTime: Output only. The time the file was added to the session. Note + // that if a file was added, then modified externally, then added again, the + // add time will be updated. + LastAddTime string `json:"lastAddTime,omitempty"` + // Metadata: Optional. Represents metadata related to the file that can suit + // particular use cases. The prefix "google." is reserved for the key for use + // by Google, but other prefixes can be freely used. + Metadata map[string]string `json:"metadata,omitempty"` + // MimeType: The content type of the file, see + // https://www.iana.org/assignments/media-types/media-types.xhtml. + MimeType string `json:"mimeType,omitempty"` + // Name: Output only. The name of the file uploaded. + Name string `json:"name,omitempty"` + // OriginalSourceType: Optional. The type of the original source of the file. + // + // Possible values: + // "FILE_SOURCE_UNSPECIFIED" - Default value. Unknown source. + // "FILE_SOURCE_INLINE" - The data of the file was provided inline (e.g. + // pasted from the clipboard). + // "FILE_SOURCE_LOCAL" - The file was uploaded from a local file. + // "FILE_SOURCE_CLOUD_STORAGE" - The file was uploaded from Cloud Storage. + // "FILE_SOURCE_CLOUD_DRIVE" - The file was uploaded from Drive. + // "FILE_SOURCE_URL" - The file was retrieved from a URL (e.g. public web). + OriginalSourceType string `json:"originalSourceType,omitempty"` + // OriginalUri: Optional. The original location of the file. It may be a local + // file path, or any other URI that allows accessing the file in an external + // system. There are two scenarios in which this url may be empty: 1. If the + // file was sent as inline data (e.g. pasted from the clipboard). 2. If the + // original location is not available. Note that there's no guarantee that the + // URI will be pointing to a valid or actually existing file. For example, a + // file might have been uploaded to the session, and then deleted from the + // original source. + OriginalUri string `json:"originalUri,omitempty"` + // UploadTime: Output only. The time the file was uploaded (If this is a file + // generated by an internal process and then made available to the session, + // this indicates the moment it happened). + UploadTime string `json:"uploadTime,omitempty"` + // Views: Output only. Alternate views of this file object. Each file view is + // attached to a specific role. Possible example keys: - "thumbnail" - + // "mobile_thumbnail" - "clip" - "summary" - "translation" + Views map[string]GoogleCloudDiscoveryengineV1alphaFileView `json:"views,omitempty"` + // ForceSendFields is a list of field names (e.g. "ByteSize") 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. "ByteSize") 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 GoogleCloudDiscoveryengineV1alphaFileMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaFileMetadata + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaFileView: Represents a specific alternate +// version or "view" of a file object, such as a summary, a thumbnail, a +// translated version, etc. +type GoogleCloudDiscoveryengineV1alphaFileView struct { + // ByteSize: Output only. The size of the view in bytes. + ByteSize int64 `json:"byteSize,omitempty,string"` + // CreateTime: Output only. The time the view was created. + CreateTime string `json:"createTime,omitempty"` + // FileCharacteristics: Output only. Characteristics of other file types. + FileCharacteristics *GoogleCloudDiscoveryengineV1alphaFileCharacteristics `json:"fileCharacteristics,omitempty"` + // ImageCharacteristics: Output only. Characteristics of an image media view. + ImageCharacteristics *GoogleCloudDiscoveryengineV1alphaImageCharacteristics `json:"imageCharacteristics,omitempty"` + // MimeType: Output only. MIME type (e.g., "image/jpeg", "image/png", + // "text/plain", "video/mp4") + MimeType string `json:"mimeType,omitempty"` + // Uri: Output only. The URI to access this media view. + Uri string `json:"uri,omitempty"` + // VideoCharacteristics: Output only. Characteristics of a video media view. + VideoCharacteristics *GoogleCloudDiscoveryengineV1alphaVideoCharacteristics `json:"videoCharacteristics,omitempty"` + // ViewId: Output only. Globally Unique id for this specific view. + ViewId string `json:"viewId,omitempty"` + // ForceSendFields is a list of field names (e.g. "ByteSize") 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. "ByteSize") 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 GoogleCloudDiscoveryengineV1alphaFileView) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaFileView + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudDiscoveryengineV1alphaFirestoreSource: Firestore source import // data from. type GoogleCloudDiscoveryengineV1alphaFirestoreSource struct { @@ -14563,6 +14749,44 @@ func (s GoogleCloudDiscoveryengineV1alphaIdpConfigExternalIdpConfig) MarshalJSON return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudDiscoveryengineV1alphaImageCharacteristics: Standard +// characteristics of an image media view. +type GoogleCloudDiscoveryengineV1alphaImageCharacteristics struct { + // BitDepth: Output only. Bit depth of the image (e.g., 8-bit, 16-bit). + BitDepth int64 `json:"bitDepth,omitempty"` + // ColorSpace: Output only. Color space of the image (e.g., "RGB", "CMYK", + // "Grayscale"). + // + // Possible values: + // "COLOR_SPACE_UNSPECIFIED" - Default value. Unknown color space. + // "RGB" - Red, green, blue colorspace. + // "CMYK" - Cyan, magenta, yellow, and black colorspace. + // "GRAYSCALE" - Grayscale colorspace. + // "YUV" - YUV colorspace. + // "OTHER_COLOR_SPACE" - Other colorspace. + ColorSpace string `json:"colorSpace,omitempty"` + // Height: Output only. Image height in pixels. + Height int64 `json:"height,omitempty"` + // Width: Output only. Image width in pixels. + Width int64 `json:"width,omitempty"` + // ForceSendFields is a list of field names (e.g. "BitDepth") 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. "BitDepth") 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 GoogleCloudDiscoveryengineV1alphaImageCharacteristics) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaImageCharacteristics + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudDiscoveryengineV1alphaImportCompletionSuggestionsMetadata: // Metadata related to the progress of the ImportCompletionSuggestions // operation. This will be returned by the @@ -15741,6 +15965,36 @@ func (s GoogleCloudDiscoveryengineV1alphaListEvaluationsResponse) MarshalJSON() return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudDiscoveryengineV1alphaListFilesResponse: Response message for +// SessionService.ListFiles method. +type GoogleCloudDiscoveryengineV1alphaListFilesResponse struct { + // Files: The FileMetadatas. + Files []*GoogleCloudDiscoveryengineV1alphaFileMetadata `json:"files,omitempty"` + // NextPageToken: A token to retrieve next page of results. Pass this value in + // the ListFilesRequest.page_token field in the subsequent call to `ListFiles` + // method to retrieve the next page of results. + 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. "Files") 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. "Files") 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 GoogleCloudDiscoveryengineV1alphaListFilesResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaListFilesResponse + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudDiscoveryengineV1alphaListIdentityMappingStoresResponse: Response // message for IdentityMappingStoreService.ListIdentityMappingStores type GoogleCloudDiscoveryengineV1alphaListIdentityMappingStoresResponse struct { @@ -15920,9 +16174,12 @@ func (s GoogleCloudDiscoveryengineV1alphaListServingConfigsResponse) MarshalJSON // GoogleCloudDiscoveryengineV1alphaListSessionsRequest: Request for // ListSessions method. type GoogleCloudDiscoveryengineV1alphaListSessionsRequest struct { - // Filter: A filter to apply on the list results. The supported features are: - // user_pseudo_id, state, starred. Examples: "user_pseudo_id = some_id" - // "starred = true" + // Filter: A comma-separated list of fields to filter by, in EBNF grammar. The + // supported fields are: * `user_pseudo_id` * `state` * `display_name` * + // `starred` * `is_pinned` * `labels` * `create_time` * `update_time` Examples: + // "user_pseudo_id = some_id" "display_name = \"some_name\"" "starred = true" + // "is_pinned=true AND (NOT labels:hidden)" "create_time > + // \"1970-01-01T12:00:00Z\"" Filter string `json:"filter,omitempty"` // OrderBy: A comma-separated list of fields to order by, sorted in ascending // order. Use "desc" after a field name for descending. Supported fields: * @@ -16473,6 +16730,8 @@ type GoogleCloudDiscoveryengineV1alphaProvisionProjectRequest struct { // would like to give consent to. Acceptable version is `2022-11-23`, and this // may change over time. DataUseTermsVersion string `json:"dataUseTermsVersion,omitempty"` + // SaasParams: Optional. Parameters for Agentspace. + SaasParams *GoogleCloudDiscoveryengineV1alphaProvisionProjectRequestSaasParams `json:"saasParams,omitempty"` // ForceSendFields is a list of field names (e.g. "AcceptDataUseTerms") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See @@ -16491,6 +16750,31 @@ func (s GoogleCloudDiscoveryengineV1alphaProvisionProjectRequest) MarshalJSON() return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudDiscoveryengineV1alphaProvisionProjectRequestSaasParams: +// Parameters for Agentspace. +type GoogleCloudDiscoveryengineV1alphaProvisionProjectRequestSaasParams struct { + // AcceptBizQos: Optional. Set to `true` to specify that caller has read and + // would like to give consent to the [Terms for Agent Space quality of + // service]. + AcceptBizQos bool `json:"acceptBizQos,omitempty"` + // ForceSendFields is a list of field names (e.g. "AcceptBizQos") 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. "AcceptBizQos") 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 GoogleCloudDiscoveryengineV1alphaProvisionProjectRequestSaasParams) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaProvisionProjectRequestSaasParams + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudDiscoveryengineV1alphaPurgeCompletionSuggestionsMetadata: // Metadata related to the progress of the PurgeCompletionSuggestions // operation. This is returned by the google.longrunning.Operation.metadata @@ -17060,7 +17344,7 @@ type GoogleCloudDiscoveryengineV1alphaRankRequest struct { Model string `json:"model,omitempty"` // Query: The query to use. Query string `json:"query,omitempty"` - // Records: Required. A list of records to rank. At most 200 records to rank. + // Records: Required. A list of records to rank. Records []*GoogleCloudDiscoveryengineV1alphaRankingRecord `json:"records,omitempty"` // TopN: The number of results to return. If this is unset or no bigger than // zero, returns all results. @@ -21345,9 +21629,6 @@ func (s GoogleCloudDiscoveryengineV1alphaStreamAssistRequestGenerationSpec) Mars type GoogleCloudDiscoveryengineV1alphaStreamAssistRequestToolsSpec struct { // ImageGenerationSpec: Optional. Specification of the image generation tool. ImageGenerationSpec *GoogleCloudDiscoveryengineV1alphaStreamAssistRequestToolsSpecImageGenerationSpec `json:"imageGenerationSpec,omitempty"` - // ToolRegistry: Optional. The name of the tool registry to use. Format: - // `projects/{project}/locations/{location}/toolRegistries/{tool_registry}` - ToolRegistry string `json:"toolRegistry,omitempty"` // VertexAiSearchSpec: Optional. Specification of the Vertex AI Search tool. VertexAiSearchSpec *GoogleCloudDiscoveryengineV1alphaStreamAssistRequestToolsSpecVertexAiSearchSpec `json:"vertexAiSearchSpec,omitempty"` // VideoGenerationSpec: Optional. Specification of the video generation tool. @@ -21387,10 +21668,6 @@ type GoogleCloudDiscoveryengineV1alphaStreamAssistRequestToolsSpecVertexAiSearch // call and configurations for those data stores. This is only considered for // Engines with multiple data stores. DataStoreSpecs []*GoogleCloudDiscoveryengineV1alphaSearchRequestDataStoreSpec `json:"dataStoreSpecs,omitempty"` - // Disabled: Optional. Deprecated. Please refrain from using this field. - // Whether the Vertex AI Search tool is disabled. Default value is false, the - // tool is enabled by default. - Disabled bool `json:"disabled,omitempty"` // Filter: Optional. The filter syntax consists of an expression language for // constructing a predicate from one or more fields of the documents being // filtered. Filter expression is case-sensitive. If this field is @@ -21429,25 +21706,6 @@ type GoogleCloudDiscoveryengineV1alphaStreamAssistRequestToolsSpecVideoGeneratio // GoogleCloudDiscoveryengineV1alphaStreamAssistRequestToolsSpecWebGroundingSpec // : Specification of the web grounding tool. type GoogleCloudDiscoveryengineV1alphaStreamAssistRequestToolsSpecWebGroundingSpec struct { - // Enabled: Optional. Deprecated. Please refrain from using this field. Whether - // the web grounding tool is enabled. - Enabled bool `json:"enabled,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 GoogleCloudDiscoveryengineV1alphaStreamAssistRequestToolsSpecWebGroundingSpec) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaStreamAssistRequestToolsSpecWebGroundingSpec - return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } // GoogleCloudDiscoveryengineV1alphaStreamAssistResponse: Response for the @@ -22363,6 +22621,57 @@ func (s GoogleCloudDiscoveryengineV1alphaUserLicense) MarshalJSON() ([]byte, err return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudDiscoveryengineV1alphaVideoCharacteristics: Standard +// characteristics of a video media view. +type GoogleCloudDiscoveryengineV1alphaVideoCharacteristics struct { + // AudioBitrateKbps: Output only. Bitrate of the audio in kbps. + AudioBitrateKbps int64 `json:"audioBitrateKbps,omitempty"` + // AudioCodecs: Output only. Audio codecs used in the video. + AudioCodecs []string `json:"audioCodecs,omitempty"` + // Duration: Output only. Video duration. + Duration string `json:"duration,omitempty"` + // FrameRate: Output only. Frame rate (frames per second). + FrameRate float64 `json:"frameRate,omitempty"` + // Height: Output only. Video height in pixels. + Height int64 `json:"height,omitempty"` + // VideoBitrateKbps: Output only. Bitrate of the video in kbps. + VideoBitrateKbps int64 `json:"videoBitrateKbps,omitempty"` + // VideoCodecs: Output only. Video codecs used in the video. + VideoCodecs []string `json:"videoCodecs,omitempty"` + // Width: Output only. Video width in pixels. + Width int64 `json:"width,omitempty"` + // ForceSendFields is a list of field names (e.g. "AudioBitrateKbps") 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. "AudioBitrateKbps") 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 GoogleCloudDiscoveryengineV1alphaVideoCharacteristics) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaVideoCharacteristics + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +func (s *GoogleCloudDiscoveryengineV1alphaVideoCharacteristics) UnmarshalJSON(data []byte) error { + type NoMethod GoogleCloudDiscoveryengineV1alphaVideoCharacteristics + var s1 struct { + FrameRate gensupport.JSONFloat64 `json:"frameRate"` + *NoMethod + } + s1.NoMethod = (*NoMethod)(s) + if err := json.Unmarshal(data, &s1); err != nil { + return err + } + s.FrameRate = float64(s1.FrameRate) + return nil +} + // GoogleCloudDiscoveryengineV1alphaWidgetConfig: WidgetConfig captures configs // at the Widget level. type GoogleCloudDiscoveryengineV1alphaWidgetConfig struct { @@ -23257,12 +23566,13 @@ func (s GoogleCloudDiscoveryengineV1betaBatchUpdateUserLicensesResponse) Marshal type GoogleCloudDiscoveryengineV1betaCmekConfig struct { // IsDefault: Output only. The default CmekConfig for the Customer. IsDefault bool `json:"isDefault,omitempty"` - // KmsKey: KMS key resource name which will be used to encrypt resources + // KmsKey: Required. KMS key resource name which will be used to encrypt + // resources // `projects/{project}/locations/{location}/keyRings/{keyRing}/cryptoKeys/{keyId // }`. KmsKey string `json:"kmsKey,omitempty"` - // KmsKeyVersion: KMS key version resource name which will be used to encrypt - // resources `/cryptoKeyVersions/{keyVersion}`. + // KmsKeyVersion: Output only. KMS key version resource name which will be used + // to encrypt resources `/cryptoKeyVersions/{keyVersion}`. KmsKeyVersion string `json:"kmsKeyVersion,omitempty"` // LastRotationTimestampMicros: Output only. The timestamp of the last key // rotation. @@ -39476,9 +39786,12 @@ func (r *ProjectsLocationsCollectionsDataStoresSessionsService) List(parent stri return c } -// Filter sets the optional parameter "filter": A filter to apply on the list -// results. The supported features are: user_pseudo_id, state, starred. -// Examples: "user_pseudo_id = some_id" "starred = true" +// Filter sets the optional parameter "filter": A comma-separated list of +// fields to filter by, in EBNF grammar. The supported fields are: * +// `user_pseudo_id` * `state` * `display_name` * `starred` * `is_pinned` * +// `labels` * `create_time` * `update_time` Examples: "user_pseudo_id = +// some_id" "display_name = \"some_name\"" "starred = true" "is_pinned=true AND +// (NOT labels:hidden)" "create_time > \"1970-01-01T12:00:00Z\"" func (c *ProjectsLocationsCollectionsDataStoresSessionsListCall) Filter(filter string) *ProjectsLocationsCollectionsDataStoresSessionsListCall { c.urlParams_.Set("filter", filter) return c @@ -47172,9 +47485,12 @@ func (r *ProjectsLocationsCollectionsEnginesSessionsService) List(parent string) return c } -// Filter sets the optional parameter "filter": A filter to apply on the list -// results. The supported features are: user_pseudo_id, state, starred. -// Examples: "user_pseudo_id = some_id" "starred = true" +// Filter sets the optional parameter "filter": A comma-separated list of +// fields to filter by, in EBNF grammar. The supported fields are: * +// `user_pseudo_id` * `state` * `display_name` * `starred` * `is_pinned` * +// `labels` * `create_time` * `update_time` Examples: "user_pseudo_id = +// some_id" "display_name = \"some_name\"" "starred = true" "is_pinned=true AND +// (NOT labels:hidden)" "create_time > \"1970-01-01T12:00:00Z\"" func (c *ProjectsLocationsCollectionsEnginesSessionsListCall) Filter(filter string) *ProjectsLocationsCollectionsEnginesSessionsListCall { c.urlParams_.Set("filter", filter) return c @@ -47546,6 +47862,173 @@ func (c *ProjectsLocationsCollectionsEnginesSessionsAnswersGetCall) Do(opts ...g return ret, nil } +type ProjectsLocationsCollectionsEnginesSessionsFilesListCall struct { + s *Service + parent string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// List: Lists metadata for all files in the current session. +// +// - parent: The resource name of the Session. Format: +// `projects/{project}/locations/{location}/collections/{collection}/engines/{ +// engine}/sessions/{session}` Name of the session resource to which the file +// belong. +func (r *ProjectsLocationsCollectionsEnginesSessionsFilesService) List(parent string) *ProjectsLocationsCollectionsEnginesSessionsFilesListCall { + c := &ProjectsLocationsCollectionsEnginesSessionsFilesListCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + return c +} + +// Filter sets the optional parameter "filter": The filter syntax consists of +// an expression language for constructing a predicate from one or more fields +// of the files being filtered. Filter expression is case-sensitive. Currently +// supported field names are: * upload_time * last_add_time * last_use_time * +// file_name * mime_type Some examples of filters would be: * "file_name = +// 'file_1'" * "file_name = 'file_1' AND mime_type = 'text/plain'" * +// "last_use_time > '2025-06-14T12:00:00Z'" For a full description of the +// filter format, please see https://google.aip.dev/160. +func (c *ProjectsLocationsCollectionsEnginesSessionsFilesListCall) Filter(filter string) *ProjectsLocationsCollectionsEnginesSessionsFilesListCall { + c.urlParams_.Set("filter", filter) + return c +} + +// PageSize sets the optional parameter "pageSize": The maximum number of files +// to return. The service may return fewer than this value. If unspecified, at +// most 100 files will be returned. The maximum value is 1000; values above +// 1000 will be coerced to 1000. If user specifies a value less than or equal +// to 0 - the request will be rejected with an INVALID_ARGUMENT error. +func (c *ProjectsLocationsCollectionsEnginesSessionsFilesListCall) PageSize(pageSize int64) *ProjectsLocationsCollectionsEnginesSessionsFilesListCall { + c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) + return c +} + +// PageToken sets the optional parameter "pageToken": A page token received +// from a previous `ListFiles` call. Provide this to retrieve the subsequent +// page. When paginating, all other parameters provided to `ListFiles` must +// match the call that provided the page token (except `page_size`, which may +// differ). +func (c *ProjectsLocationsCollectionsEnginesSessionsFilesListCall) PageToken(pageToken string) *ProjectsLocationsCollectionsEnginesSessionsFilesListCall { + 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 *ProjectsLocationsCollectionsEnginesSessionsFilesListCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsEnginesSessionsFilesListCall { + 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 *ProjectsLocationsCollectionsEnginesSessionsFilesListCall) IfNoneMatch(entityTag string) *ProjectsLocationsCollectionsEnginesSessionsFilesListCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsCollectionsEnginesSessionsFilesListCall) Context(ctx context.Context) *ProjectsLocationsCollectionsEnginesSessionsFilesListCall { + 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 *ProjectsLocationsCollectionsEnginesSessionsFilesListCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsCollectionsEnginesSessionsFilesListCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+parent}/files") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("GET", urls, nil) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "parent": c.parent, + }) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "discoveryengine.projects.locations.collections.engines.sessions.files.list", "request", internallog.HTTPRequest(req, nil)) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "discoveryengine.projects.locations.collections.engines.sessions.files.list" call. +// Any non-2xx status code is an error. Response headers are in either +// *GoogleCloudDiscoveryengineV1alphaListFilesResponse.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 *ProjectsLocationsCollectionsEnginesSessionsFilesListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1alphaListFilesResponse, 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 := &GoogleCloudDiscoveryengineV1alphaListFilesResponse{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + b, err := gensupport.DecodeResponseBytes(target, res) + if err != nil { + return nil, err + } + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "discoveryengine.projects.locations.collections.engines.sessions.files.list", "response", internallog.HTTPResponse(res, b)) + 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 *ProjectsLocationsCollectionsEnginesSessionsFilesListCall) Pages(ctx context.Context, f func(*GoogleCloudDiscoveryengineV1alphaListFilesResponse) 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 ProjectsLocationsCollectionsEnginesWidgetConfigsGetCall struct { s *Service name string @@ -54957,9 +55440,12 @@ func (r *ProjectsLocationsDataStoresSessionsService) List(parent string) *Projec return c } -// Filter sets the optional parameter "filter": A filter to apply on the list -// results. The supported features are: user_pseudo_id, state, starred. -// Examples: "user_pseudo_id = some_id" "starred = true" +// Filter sets the optional parameter "filter": A comma-separated list of +// fields to filter by, in EBNF grammar. The supported fields are: * +// `user_pseudo_id` * `state` * `display_name` * `starred` * `is_pinned` * +// `labels` * `create_time` * `update_time` Examples: "user_pseudo_id = +// some_id" "display_name = \"some_name\"" "starred = true" "is_pinned=true AND +// (NOT labels:hidden)" "create_time > \"1970-01-01T12:00:00Z\"" func (c *ProjectsLocationsDataStoresSessionsListCall) Filter(filter string) *ProjectsLocationsDataStoresSessionsListCall { c.urlParams_.Set("filter", filter) return c diff --git a/discoveryengine/v1beta/discoveryengine-api.json b/discoveryengine/v1beta/discoveryengine-api.json index 021cfe23cd9..3004f850d92 100644 --- a/discoveryengine/v1beta/discoveryengine-api.json +++ b/discoveryengine/v1beta/discoveryengine-api.json @@ -2320,7 +2320,7 @@ ], "parameters": { "filter": { - "description": "A filter to apply on the list results. The supported features are: user_pseudo_id, state, starred. Examples: \"user_pseudo_id = some_id\" \"starred = true\"", + "description": "A comma-separated list of fields to filter by, in EBNF grammar. The supported fields are: * `user_pseudo_id` * `state` * `display_name` * `starred` * `is_pinned` * `labels` * `create_time` * `update_time` Examples: \"user_pseudo_id = some_id\" \"display_name = \\\"some_name\\\"\" \"starred = true\" \"is_pinned=true AND (NOT labels:hidden)\" \"create_time \u003e \\\"1970-01-01T12:00:00Z\\\"\"", "location": "query", "type": "string" }, @@ -4272,7 +4272,7 @@ ], "parameters": { "filter": { - "description": "A filter to apply on the list results. The supported features are: user_pseudo_id, state, starred. Examples: \"user_pseudo_id = some_id\" \"starred = true\"", + "description": "A comma-separated list of fields to filter by, in EBNF grammar. The supported fields are: * `user_pseudo_id` * `state` * `display_name` * `starred` * `is_pinned` * `labels` * `create_time` * `update_time` Examples: \"user_pseudo_id = some_id\" \"display_name = \\\"some_name\\\"\" \"starred = true\" \"is_pinned=true AND (NOT labels:hidden)\" \"create_time \u003e \\\"1970-01-01T12:00:00Z\\\"\"", "location": "query", "type": "string" }, @@ -6139,7 +6139,7 @@ ], "parameters": { "filter": { - "description": "A filter to apply on the list results. The supported features are: user_pseudo_id, state, starred. Examples: \"user_pseudo_id = some_id\" \"starred = true\"", + "description": "A comma-separated list of fields to filter by, in EBNF grammar. The supported fields are: * `user_pseudo_id` * `state` * `display_name` * `starred` * `is_pinned` * `labels` * `create_time` * `update_time` Examples: \"user_pseudo_id = some_id\" \"display_name = \\\"some_name\\\"\" \"starred = true\" \"is_pinned=true AND (NOT labels:hidden)\" \"create_time \u003e \\\"1970-01-01T12:00:00Z\\\"\"", "location": "query", "type": "string" }, @@ -8047,7 +8047,7 @@ } } }, - "revision": "20250716", + "revision": "20250723", "rootUrl": "https://discoveryengine.googleapis.com/", "schemas": { "GoogleApiDistribution": { @@ -8532,6 +8532,17 @@ }, "type": "object" }, + "GoogleCloudDiscoveryengineV1Assistant": { + "description": "Discovery Engine Assistant resource.", + "id": "GoogleCloudDiscoveryengineV1Assistant", + "properties": { + "name": { + "description": "Immutable. Resource name of the assistant. Format: `projects/{project}/locations/{location}/collections/{collection}/engines/{engine}/assistants/{assistant}` It must be a UTF-8 encoded string with a length limit of 1024 characters.", + "type": "string" + } + }, + "type": "object" + }, "GoogleCloudDiscoveryengineV1BatchCreateTargetSiteMetadata": { "description": "Metadata related to the progress of the SiteSearchEngineService.BatchCreateTargetSites operation. This will be returned by the google.longrunning.Operation.metadata field.", "id": "GoogleCloudDiscoveryengineV1BatchCreateTargetSiteMetadata", @@ -8621,11 +8632,12 @@ "type": "boolean" }, "kmsKey": { - "description": "KMS key resource name which will be used to encrypt resources `projects/{project}/locations/{location}/keyRings/{keyRing}/cryptoKeys/{keyId}`.", + "description": "Required. KMS key resource name which will be used to encrypt resources `projects/{project}/locations/{location}/keyRings/{keyRing}/cryptoKeys/{keyId}`.", "type": "string" }, "kmsKeyVersion": { - "description": "KMS key version resource name which will be used to encrypt resources `/cryptoKeyVersions/{keyVersion}`.", + "description": "Output only. KMS key version resource name which will be used to encrypt resources `/cryptoKeyVersions/{keyVersion}`.", + "readOnly": true, "type": "string" }, "lastRotationTimestampMicros": { @@ -11920,11 +11932,12 @@ "type": "boolean" }, "kmsKey": { - "description": "KMS key resource name which will be used to encrypt resources `projects/{project}/locations/{location}/keyRings/{keyRing}/cryptoKeys/{keyId}`.", + "description": "Required. KMS key resource name which will be used to encrypt resources `projects/{project}/locations/{location}/keyRings/{keyRing}/cryptoKeys/{keyId}`.", "type": "string" }, "kmsKeyVersion": { - "description": "KMS key version resource name which will be used to encrypt resources `/cryptoKeyVersions/{keyVersion}`.", + "description": "Output only. KMS key version resource name which will be used to encrypt resources `/cryptoKeyVersions/{keyVersion}`.", + "readOnly": true, "type": "string" }, "lastRotationTimestampMicros": { @@ -14758,7 +14771,7 @@ "id": "GoogleCloudDiscoveryengineV1alphaListSessionsRequest", "properties": { "filter": { - "description": "A filter to apply on the list results. The supported features are: user_pseudo_id, state, starred. Examples: \"user_pseudo_id = some_id\" \"starred = true\"", + "description": "A comma-separated list of fields to filter by, in EBNF grammar. The supported fields are: * `user_pseudo_id` * `state` * `display_name` * `starred` * `is_pinned` * `labels` * `create_time` * `update_time` Examples: \"user_pseudo_id = some_id\" \"display_name = \\\"some_name\\\"\" \"starred = true\" \"is_pinned=true AND (NOT labels:hidden)\" \"create_time \u003e \\\"1970-01-01T12:00:00Z\\\"\"", "type": "string" }, "orderBy": { @@ -18605,6 +18618,10 @@ }, "type": "array" }, + "name": { + "description": "Immutable. Identifier. Resource name of the `AssistAnswer`. Format: `projects/{project}/locations/{location}/collections/{collection}/engines/{engine}/sessions/{session}/assistAnswers/{assist_answer}` This field must be a UTF-8 encoded string with a length limit of 1024 characters.", + "type": "string" + }, "replies": { "description": "Replies of the assistant.", "items": { @@ -19601,11 +19618,12 @@ "type": "boolean" }, "kmsKey": { - "description": "KMS key resource name which will be used to encrypt resources `projects/{project}/locations/{location}/keyRings/{keyRing}/cryptoKeys/{keyId}`.", + "description": "Required. KMS key resource name which will be used to encrypt resources `projects/{project}/locations/{location}/keyRings/{keyRing}/cryptoKeys/{keyId}`.", "type": "string" }, "kmsKeyVersion": { - "description": "KMS key version resource name which will be used to encrypt resources `/cryptoKeyVersions/{keyVersion}`.", + "description": "Output only. KMS key version resource name which will be used to encrypt resources `/cryptoKeyVersions/{keyVersion}`.", + "readOnly": true, "type": "string" }, "lastRotationTimestampMicros": { @@ -22956,6 +22974,21 @@ "dataUseTermsVersion": { "description": "Required. The version of the [Terms for data use](https://cloud.google.com/retail/data-use-terms) that caller has read and would like to give consent to. Acceptable version is `2022-11-23`, and this may change over time.", "type": "string" + }, + "saasParams": { + "$ref": "GoogleCloudDiscoveryengineV1betaProvisionProjectRequestSaasParams", + "description": "Optional. Parameters for Agentspace." + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1betaProvisionProjectRequestSaasParams": { + "description": "Parameters for Agentspace.", + "id": "GoogleCloudDiscoveryengineV1betaProvisionProjectRequestSaasParams", + "properties": { + "acceptBizQos": { + "description": "Optional. Set to `true` to specify that caller has read and would like to give consent to the [Terms for Agent Space quality of service].", + "type": "boolean" } }, "type": "object" @@ -23246,7 +23279,7 @@ "type": "string" }, "records": { - "description": "Required. A list of records to rank. At most 200 records to rank.", + "description": "Required. A list of records to rank.", "items": { "$ref": "GoogleCloudDiscoveryengineV1betaRankingRecord" }, @@ -25807,10 +25840,6 @@ "$ref": "GoogleCloudDiscoveryengineV1betaStreamAssistRequestToolsSpecImageGenerationSpec", "description": "Optional. Specification of the image generation tool." }, - "toolRegistry": { - "description": "Optional. The name of the tool registry to use. Format: `projects/{project}/locations/{location}/toolRegistries/{tool_registry}`", - "type": "string" - }, "vertexAiSearchSpec": { "$ref": "GoogleCloudDiscoveryengineV1betaStreamAssistRequestToolsSpecVertexAiSearchSpec", "description": "Optional. Specification of the Vertex AI Search tool." @@ -25843,11 +25872,6 @@ }, "type": "array" }, - "disabled": { - "deprecated": true, - "description": "Optional. Deprecated. Please refrain from using this field. Whether the Vertex AI Search tool is disabled. Default value is false, the tool is enabled by default.", - "type": "boolean" - }, "filter": { "description": "Optional. The filter syntax consists of an expression language for constructing a predicate from one or more fields of the documents being filtered. Filter expression is case-sensitive. If this field is unrecognizable, an `INVALID_ARGUMENT` is returned. Filtering in Vertex AI Search is done by mapping the LHS filter key to a key property defined in the Vertex AI Search backend -- this mapping is defined by the customer in their schema. For example a media customer might have a field 'name' in their schema. In this case the filter would look like this: filter --\u003e name:'ANY(\"king kong\")' For more information about filtering including syntax and filter operators, see [Filter](https://cloud.google.com/generative-ai-app-builder/docs/filter-search-metadata)", "type": "string" @@ -25864,13 +25888,7 @@ "GoogleCloudDiscoveryengineV1betaStreamAssistRequestToolsSpecWebGroundingSpec": { "description": "Specification of the web grounding tool.", "id": "GoogleCloudDiscoveryengineV1betaStreamAssistRequestToolsSpecWebGroundingSpec", - "properties": { - "enabled": { - "deprecated": true, - "description": "Optional. Deprecated. Please refrain from using this field. Whether the web grounding tool is enabled.", - "type": "boolean" - } - }, + "properties": {}, "type": "object" }, "GoogleCloudDiscoveryengineV1betaStreamAssistResponse": { diff --git a/discoveryengine/v1beta/discoveryengine-gen.go b/discoveryengine/v1beta/discoveryengine-gen.go index 463c2575352..0d6cecaa53f 100644 --- a/discoveryengine/v1beta/discoveryengine-gen.go +++ b/discoveryengine/v1beta/discoveryengine-gen.go @@ -1904,6 +1904,31 @@ func (s *GoogleCloudDiscoveryengineV1AnswerGenerationSpecUserDefinedClassifierSp return nil } +// GoogleCloudDiscoveryengineV1Assistant: Discovery Engine Assistant resource. +type GoogleCloudDiscoveryengineV1Assistant struct { + // Name: Immutable. Resource name of the assistant. Format: + // `projects/{project}/locations/{location}/collections/{collection}/engines/{en + // gine}/assistants/{assistant}` It must be a UTF-8 encoded string with a + // length limit of 1024 characters. + 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. "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 GoogleCloudDiscoveryengineV1Assistant) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1Assistant + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudDiscoveryengineV1BatchCreateTargetSiteMetadata: Metadata related // to the progress of the SiteSearchEngineService.BatchCreateTargetSites // operation. This will be returned by the @@ -2017,12 +2042,13 @@ func (s GoogleCloudDiscoveryengineV1BatchUpdateUserLicensesResponse) MarshalJSON type GoogleCloudDiscoveryengineV1CmekConfig struct { // IsDefault: Output only. The default CmekConfig for the Customer. IsDefault bool `json:"isDefault,omitempty"` - // KmsKey: KMS key resource name which will be used to encrypt resources + // KmsKey: Required. KMS key resource name which will be used to encrypt + // resources // `projects/{project}/locations/{location}/keyRings/{keyRing}/cryptoKeys/{keyId // }`. KmsKey string `json:"kmsKey,omitempty"` - // KmsKeyVersion: KMS key version resource name which will be used to encrypt - // resources `/cryptoKeyVersions/{keyVersion}`. + // KmsKeyVersion: Output only. KMS key version resource name which will be used + // to encrypt resources `/cryptoKeyVersions/{keyVersion}`. KmsKeyVersion string `json:"kmsKeyVersion,omitempty"` // LastRotationTimestampMicros: Output only. The timestamp of the last key // rotation. @@ -6392,12 +6418,13 @@ func (s GoogleCloudDiscoveryengineV1alphaBatchUpdateUserLicensesResponse) Marsha type GoogleCloudDiscoveryengineV1alphaCmekConfig struct { // IsDefault: Output only. The default CmekConfig for the Customer. IsDefault bool `json:"isDefault,omitempty"` - // KmsKey: KMS key resource name which will be used to encrypt resources + // KmsKey: Required. KMS key resource name which will be used to encrypt + // resources // `projects/{project}/locations/{location}/keyRings/{keyRing}/cryptoKeys/{keyId // }`. KmsKey string `json:"kmsKey,omitempty"` - // KmsKeyVersion: KMS key version resource name which will be used to encrypt - // resources `/cryptoKeyVersions/{keyVersion}`. + // KmsKeyVersion: Output only. KMS key version resource name which will be used + // to encrypt resources `/cryptoKeyVersions/{keyVersion}`. KmsKeyVersion string `json:"kmsKeyVersion,omitempty"` // LastRotationTimestampMicros: Output only. The timestamp of the last key // rotation. @@ -9960,9 +9987,12 @@ func (s GoogleCloudDiscoveryengineV1alphaLanguageInfo) MarshalJSON() ([]byte, er // GoogleCloudDiscoveryengineV1alphaListSessionsRequest: Request for // ListSessions method. type GoogleCloudDiscoveryengineV1alphaListSessionsRequest struct { - // Filter: A filter to apply on the list results. The supported features are: - // user_pseudo_id, state, starred. Examples: "user_pseudo_id = some_id" - // "starred = true" + // Filter: A comma-separated list of fields to filter by, in EBNF grammar. The + // supported fields are: * `user_pseudo_id` * `state` * `display_name` * + // `starred` * `is_pinned` * `labels` * `create_time` * `update_time` Examples: + // "user_pseudo_id = some_id" "display_name = \"some_name\"" "starred = true" + // "is_pinned=true AND (NOT labels:hidden)" "create_time > + // \"1970-01-01T12:00:00Z\"" Filter string `json:"filter,omitempty"` // OrderBy: A comma-separated list of fields to order by, sorted in ascending // order. Use "desc" after a field name for descending. Supported fields: * @@ -15277,6 +15307,11 @@ type GoogleCloudDiscoveryengineV1betaAssistAnswer struct { // to answer because of a customer policy violation (e.g., the query or the // answer contained a banned phrase). AssistSkippedReasons []string `json:"assistSkippedReasons,omitempty"` + // Name: Immutable. Identifier. Resource name of the `AssistAnswer`. Format: + // `projects/{project}/locations/{location}/collections/{collection}/engines/{en + // gine}/sessions/{session}/assistAnswers/{assist_answer}` This field must be a + // UTF-8 encoded string with a length limit of 1024 characters. + Name string `json:"name,omitempty"` // Replies: Replies of the assistant. Replies []*GoogleCloudDiscoveryengineV1betaAssistAnswerReply `json:"replies,omitempty"` // State: State of the answer generation. @@ -16644,12 +16679,13 @@ func (s GoogleCloudDiscoveryengineV1betaCloudSqlSource) MarshalJSON() ([]byte, e type GoogleCloudDiscoveryengineV1betaCmekConfig struct { // IsDefault: Output only. The default CmekConfig for the Customer. IsDefault bool `json:"isDefault,omitempty"` - // KmsKey: KMS key resource name which will be used to encrypt resources + // KmsKey: Required. KMS key resource name which will be used to encrypt + // resources // `projects/{project}/locations/{location}/keyRings/{keyRing}/cryptoKeys/{keyId // }`. KmsKey string `json:"kmsKey,omitempty"` - // KmsKeyVersion: KMS key version resource name which will be used to encrypt - // resources `/cryptoKeyVersions/{keyVersion}`. + // KmsKeyVersion: Output only. KMS key version resource name which will be used + // to encrypt resources `/cryptoKeyVersions/{keyVersion}`. KmsKeyVersion string `json:"kmsKeyVersion,omitempty"` // LastRotationTimestampMicros: Output only. The timestamp of the last key // rotation. @@ -21449,6 +21485,8 @@ type GoogleCloudDiscoveryengineV1betaProvisionProjectRequest struct { // would like to give consent to. Acceptable version is `2022-11-23`, and this // may change over time. DataUseTermsVersion string `json:"dataUseTermsVersion,omitempty"` + // SaasParams: Optional. Parameters for Agentspace. + SaasParams *GoogleCloudDiscoveryengineV1betaProvisionProjectRequestSaasParams `json:"saasParams,omitempty"` // ForceSendFields is a list of field names (e.g. "AcceptDataUseTerms") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See @@ -21467,6 +21505,31 @@ func (s GoogleCloudDiscoveryengineV1betaProvisionProjectRequest) MarshalJSON() ( return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudDiscoveryengineV1betaProvisionProjectRequestSaasParams: +// Parameters for Agentspace. +type GoogleCloudDiscoveryengineV1betaProvisionProjectRequestSaasParams struct { + // AcceptBizQos: Optional. Set to `true` to specify that caller has read and + // would like to give consent to the [Terms for Agent Space quality of + // service]. + AcceptBizQos bool `json:"acceptBizQos,omitempty"` + // ForceSendFields is a list of field names (e.g. "AcceptBizQos") 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. "AcceptBizQos") 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 GoogleCloudDiscoveryengineV1betaProvisionProjectRequestSaasParams) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaProvisionProjectRequestSaasParams + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudDiscoveryengineV1betaPurgeCompletionSuggestionsRequest: Request // message for CompletionService.PurgeCompletionSuggestions method. type GoogleCloudDiscoveryengineV1betaPurgeCompletionSuggestionsRequest struct { @@ -21927,7 +21990,7 @@ type GoogleCloudDiscoveryengineV1betaRankRequest struct { Model string `json:"model,omitempty"` // Query: The query to use. Query string `json:"query,omitempty"` - // Records: Required. A list of records to rank. At most 200 records to rank. + // Records: Required. A list of records to rank. Records []*GoogleCloudDiscoveryengineV1betaRankingRecord `json:"records,omitempty"` // TopN: The number of results to return. If this is unset or no bigger than // zero, returns all results. @@ -25660,9 +25723,6 @@ func (s GoogleCloudDiscoveryengineV1betaStreamAssistRequestGenerationSpec) Marsh type GoogleCloudDiscoveryengineV1betaStreamAssistRequestToolsSpec struct { // ImageGenerationSpec: Optional. Specification of the image generation tool. ImageGenerationSpec *GoogleCloudDiscoveryengineV1betaStreamAssistRequestToolsSpecImageGenerationSpec `json:"imageGenerationSpec,omitempty"` - // ToolRegistry: Optional. The name of the tool registry to use. Format: - // `projects/{project}/locations/{location}/toolRegistries/{tool_registry}` - ToolRegistry string `json:"toolRegistry,omitempty"` // VertexAiSearchSpec: Optional. Specification of the Vertex AI Search tool. VertexAiSearchSpec *GoogleCloudDiscoveryengineV1betaStreamAssistRequestToolsSpecVertexAiSearchSpec `json:"vertexAiSearchSpec,omitempty"` // VideoGenerationSpec: Optional. Specification of the video generation tool. @@ -25702,10 +25762,6 @@ type GoogleCloudDiscoveryengineV1betaStreamAssistRequestToolsSpecVertexAiSearchS // call and configurations for those data stores. This is only considered for // Engines with multiple data stores. DataStoreSpecs []*GoogleCloudDiscoveryengineV1betaSearchRequestDataStoreSpec `json:"dataStoreSpecs,omitempty"` - // Disabled: Optional. Deprecated. Please refrain from using this field. - // Whether the Vertex AI Search tool is disabled. Default value is false, the - // tool is enabled by default. - Disabled bool `json:"disabled,omitempty"` // Filter: Optional. The filter syntax consists of an expression language for // constructing a predicate from one or more fields of the documents being // filtered. Filter expression is case-sensitive. If this field is @@ -25745,25 +25801,6 @@ type GoogleCloudDiscoveryengineV1betaStreamAssistRequestToolsSpecVideoGeneration // // Specification of the web grounding tool. type GoogleCloudDiscoveryengineV1betaStreamAssistRequestToolsSpecWebGroundingSpec struct { - // Enabled: Optional. Deprecated. Please refrain from using this field. Whether - // the web grounding tool is enabled. - Enabled bool `json:"enabled,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 GoogleCloudDiscoveryengineV1betaStreamAssistRequestToolsSpecWebGroundingSpec) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaStreamAssistRequestToolsSpecWebGroundingSpec - return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } // GoogleCloudDiscoveryengineV1betaStreamAssistResponse: Response for the @@ -35262,9 +35299,12 @@ func (r *ProjectsLocationsCollectionsDataStoresSessionsService) List(parent stri return c } -// Filter sets the optional parameter "filter": A filter to apply on the list -// results. The supported features are: user_pseudo_id, state, starred. -// Examples: "user_pseudo_id = some_id" "starred = true" +// Filter sets the optional parameter "filter": A comma-separated list of +// fields to filter by, in EBNF grammar. The supported fields are: * +// `user_pseudo_id` * `state` * `display_name` * `starred` * `is_pinned` * +// `labels` * `create_time` * `update_time` Examples: "user_pseudo_id = +// some_id" "display_name = \"some_name\"" "starred = true" "is_pinned=true AND +// (NOT labels:hidden)" "create_time > \"1970-01-01T12:00:00Z\"" func (c *ProjectsLocationsCollectionsDataStoresSessionsListCall) Filter(filter string) *ProjectsLocationsCollectionsDataStoresSessionsListCall { c.urlParams_.Set("filter", filter) return c @@ -42606,9 +42646,12 @@ func (r *ProjectsLocationsCollectionsEnginesSessionsService) List(parent string) return c } -// Filter sets the optional parameter "filter": A filter to apply on the list -// results. The supported features are: user_pseudo_id, state, starred. -// Examples: "user_pseudo_id = some_id" "starred = true" +// Filter sets the optional parameter "filter": A comma-separated list of +// fields to filter by, in EBNF grammar. The supported fields are: * +// `user_pseudo_id` * `state` * `display_name` * `starred` * `is_pinned` * +// `labels` * `create_time` * `update_time` Examples: "user_pseudo_id = +// some_id" "display_name = \"some_name\"" "starred = true" "is_pinned=true AND +// (NOT labels:hidden)" "create_time > \"1970-01-01T12:00:00Z\"" func (c *ProjectsLocationsCollectionsEnginesSessionsListCall) Filter(filter string) *ProjectsLocationsCollectionsEnginesSessionsListCall { c.urlParams_.Set("filter", filter) return c @@ -49595,9 +49638,12 @@ func (r *ProjectsLocationsDataStoresSessionsService) List(parent string) *Projec return c } -// Filter sets the optional parameter "filter": A filter to apply on the list -// results. The supported features are: user_pseudo_id, state, starred. -// Examples: "user_pseudo_id = some_id" "starred = true" +// Filter sets the optional parameter "filter": A comma-separated list of +// fields to filter by, in EBNF grammar. The supported fields are: * +// `user_pseudo_id` * `state` * `display_name` * `starred` * `is_pinned` * +// `labels` * `create_time` * `update_time` Examples: "user_pseudo_id = +// some_id" "display_name = \"some_name\"" "starred = true" "is_pinned=true AND +// (NOT labels:hidden)" "create_time > \"1970-01-01T12:00:00Z\"" func (c *ProjectsLocationsDataStoresSessionsListCall) Filter(filter string) *ProjectsLocationsDataStoresSessionsListCall { c.urlParams_.Set("filter", filter) return c diff --git a/drive/v3/drive-api.json b/drive/v3/drive-api.json index 79787453606..248865703d8 100644 --- a/drive/v3/drive-api.json +++ b/drive/v3/drive-api.json @@ -2806,7 +2806,7 @@ } } }, - "revision": "20250701", + "revision": "20250717", "rootUrl": "https://www.googleapis.com/", "schemas": { "About": { @@ -3464,7 +3464,7 @@ "properties": { "effectiveDownloadRestrictionWithContext": { "$ref": "DownloadRestriction", - "description": "The effective download restriction applied to this file. This considers all restriction settings and DLP rules." + "description": "Output only. The effective download restriction applied to this file. This considers all restriction settings and DLP rules." }, "itemDownloadRestriction": { "$ref": "DownloadRestriction", @@ -3721,7 +3721,7 @@ "type": "boolean" }, "canChangeItemDownloadRestriction": { - "description": "Output only. Whether the current user can change the owner-applied download restrictions of the file.", + "description": "Output only. Whether the current user can change the owner or organizer-applied download restrictions of the file.", "type": "boolean" }, "canChangeSecurityUpdateEnabled": { diff --git a/drive/v3/drive-gen.go b/drive/v3/drive-gen.go index 466935d67e2..5b40a317e38 100644 --- a/drive/v3/drive-gen.go +++ b/drive/v3/drive-gen.go @@ -1034,8 +1034,9 @@ func (s DownloadRestriction) MarshalJSON() ([]byte, error) { // DownloadRestrictionsMetadata: Download restrictions applied to the file. type DownloadRestrictionsMetadata struct { - // EffectiveDownloadRestrictionWithContext: The effective download restriction - // applied to this file. This considers all restriction settings and DLP rules. + // EffectiveDownloadRestrictionWithContext: Output only. The effective download + // restriction applied to this file. This considers all restriction settings + // and DLP rules. EffectiveDownloadRestrictionWithContext *DownloadRestriction `json:"effectiveDownloadRestrictionWithContext,omitempty"` // ItemDownloadRestriction: The download restriction of the file applied // directly by the owner or organizer. This does not take into account shared @@ -1628,7 +1629,7 @@ type FileCapabilities struct { // can change the `copyRequiresWriterPermission` restriction of this file. CanChangeCopyRequiresWriterPermission bool `json:"canChangeCopyRequiresWriterPermission,omitempty"` // CanChangeItemDownloadRestriction: Output only. Whether the current user can - // change the owner-applied download restrictions of the file. + // change the owner or organizer-applied download restrictions of the file. CanChangeItemDownloadRestriction bool `json:"canChangeItemDownloadRestriction,omitempty"` // CanChangeSecurityUpdateEnabled: Output only. Whether the current user can // change the securityUpdateEnabled field on link share metadata. diff --git a/file/v1/file-api.json b/file/v1/file-api.json index b8d22204864..26f5241e506 100644 --- a/file/v1/file-api.json +++ b/file/v1/file-api.json @@ -908,7 +908,7 @@ } } }, - "revision": "20250421", + "revision": "20250716", "rootUrl": "https://file.googleapis.com/", "schemas": { "Backup": { @@ -2143,6 +2143,12 @@ }, "readOnly": true, "type": "array" + }, + "stateUpdateTime": { + "description": "Output only. The time when the replica state was updated.", + "format": "google-datetime", + "readOnly": true, + "type": "string" } }, "type": "object" diff --git a/file/v1/file-gen.go b/file/v1/file-gen.go index 9546812e40e..500d2a30ede 100644 --- a/file/v1/file-gen.go +++ b/file/v1/file-gen.go @@ -1641,6 +1641,8 @@ type ReplicaConfig struct { // "PEER_INSTANCE_UNREACHABLE" - The peer instance is unreachable. // "REMOVE_FAILED" - The remove replica peer instance operation failed. StateReasons []string `json:"stateReasons,omitempty"` + // StateUpdateTime: Output only. The time when the replica state was updated. + StateUpdateTime string `json:"stateUpdateTime,omitempty"` // ForceSendFields is a list of field names (e.g. "LastActiveSyncTime") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See diff --git a/mybusinessverifications/v1/mybusinessverifications-api.json b/mybusinessverifications/v1/mybusinessverifications-api.json index 5020f0a2db3..cbc9315b95d 100644 --- a/mybusinessverifications/v1/mybusinessverifications-api.json +++ b/mybusinessverifications/v1/mybusinessverifications-api.json @@ -235,9 +235,28 @@ } } } + }, + "verificationTokens": { + "methods": { + "generate": { + "description": "Generate a token for the provided location data to verify the location.", + "flatPath": "v1/verificationTokens:generate", + "httpMethod": "POST", + "id": "mybusinessverifications.verificationTokens.generate", + "parameterOrder": [], + "parameters": {}, + "path": "v1/verificationTokens:generate", + "request": { + "$ref": "GenerateInstantVerificationTokenRequest" + }, + "response": { + "$ref": "GenerateInstantVerificationTokenResponse" + } + } + } } }, - "revision": "20250615", + "revision": "20250721", "rootUrl": "https://mybusinessverifications.googleapis.com/", "schemas": { "AddressVerificationData": { @@ -351,6 +370,47 @@ }, "type": "object" }, + "GenerateInstantVerificationTokenRequest": { + "description": "Request message for Verifications.GenerateInstantVerificationToken.", + "id": "GenerateInstantVerificationTokenRequest", + "properties": { + "locationData": { + "$ref": "LocationData", + "description": "Immutable. The address and other details of the location to generate an instant verification token for." + }, + "locationId": { + "description": "The location identifier associated with an unverified listing. This is the location id generated at the time that the listing was originally created. It is the final portion of a location resource name as generated by the Google My Business API. Note: the caller must be an owner or manager of this listing in order to generate a verification token. See the [location resource](/my-business/reference/rest/v4/accounts.locations) documentation for more information.", + "type": "string" + } + }, + "type": "object" + }, + "GenerateInstantVerificationTokenResponse": { + "description": "Response message for Verifications.GenerateInstantVerificationToken.", + "id": "GenerateInstantVerificationTokenResponse", + "properties": { + "instantVerificationToken": { + "description": "The generated instant verification token.", + "type": "string" + }, + "result": { + "description": "Output only. The result of the instant verification token generation.", + "enum": [ + "RESULT_UNSPECIFIED", + "SUCCEEDED", + "FAILED" + ], + "enumDescriptions": [ + "Default value, will result in errors.", + "The instant verification token was generated successfully.", + "The instant verification token was not generated.." + ], + "readOnly": true, + "type": "string" + } + }, + "type": "object" + }, "ListVerificationsResponse": { "description": "Response message for Verifications.ListVerifications.", "id": "ListVerificationsResponse", @@ -369,6 +429,21 @@ }, "type": "object" }, + "LocationData": { + "description": "The address and other details of the location to generate an instant verification token for.", + "id": "LocationData", + "properties": { + "address": { + "$ref": "PostalAddress", + "description": "Immutable. A precise, accurate address to describe your business location. PO boxes or mailboxes located at remote locations are not acceptable. At this time, you can specify a maximum of five `address_lines` values in the address." + }, + "name": { + "description": "Immutable. Name should reflect your business's real-world name, as used consistently on your storefront, website, and stationery, and as known to customers. Any additional information, when relevant, can be included in other fields of the resource (for example, `Address`, `Categories`). Don't add unnecessary information to your name (for example, prefer \"Google\" over \"Google Inc. - Mountain View Corporate Headquarters\"). Don't include marketing taglines, store codes, special characters, hours or closed/open status, phone numbers, website URLs, service/product information, location/address or directions, or containment information (for example, \"Chase ATM in Duane Reade\").", + "type": "string" + } + }, + "type": "object" + }, "PostalAddress": { "description": "Represents a postal address, such as for postal delivery or payments addresses. With a postal address, a postal service can deliver items to a premise, P.O. box, or similar. A postal address is not intended to model geographical locations like roads, towns, or mountains. In typical usage, an address would be created by user input or from importing existing data, depending on the type of process. Advice on address input or editing: - Use an internationalization-ready address widget such as https://github.com/google/libaddressinput. - Users should not be presented with UI elements for input or editing of fields outside countries where that field is used. For more guidance on how to use this schema, see: https://support.google.com/business/answer/6397478.", "id": "PostalAddress", diff --git a/mybusinessverifications/v1/mybusinessverifications-gen.go b/mybusinessverifications/v1/mybusinessverifications-gen.go index 388655046c3..d13f86fdf4f 100644 --- a/mybusinessverifications/v1/mybusinessverifications-gen.go +++ b/mybusinessverifications/v1/mybusinessverifications-gen.go @@ -108,6 +108,7 @@ func NewService(ctx context.Context, opts ...option.ClientOption) (*Service, err } s := &Service{client: client, BasePath: basePath, logger: internaloption.GetLogger(opts)} s.Locations = NewLocationsService(s) + s.VerificationTokens = NewVerificationTokensService(s) if endpoint != "" { s.BasePath = endpoint } @@ -133,6 +134,8 @@ type Service struct { UserAgent string // optional additional User-Agent fragment Locations *LocationsService + + VerificationTokens *VerificationTokensService } func (s *Service) userAgent() string { @@ -163,6 +166,15 @@ type LocationsVerificationsService struct { s *Service } +func NewVerificationTokensService(s *Service) *VerificationTokensService { + rs := &VerificationTokensService{s: s} + return rs +} + +type VerificationTokensService struct { + s *Service +} + // AddressVerificationData: Display data for verifications through postcard. type AddressVerificationData struct { // Address: Address that a postcard can be sent to. @@ -357,6 +369,72 @@ func (s FetchVerificationOptionsResponse) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GenerateInstantVerificationTokenRequest: Request message for +// Verifications.GenerateInstantVerificationToken. +type GenerateInstantVerificationTokenRequest struct { + // LocationData: Immutable. The address and other details of the location to + // generate an instant verification token for. + LocationData *LocationData `json:"locationData,omitempty"` + // LocationId: The location identifier associated with an unverified listing. + // This is the location id generated at the time that the listing was + // originally created. It is the final portion of a location resource name as + // generated by the Google My Business API. Note: the caller must be an owner + // or manager of this listing in order to generate a verification token. See + // the location resource (/my-business/reference/rest/v4/accounts.locations) + // documentation for more information. + LocationId string `json:"locationId,omitempty"` + // ForceSendFields is a list of field names (e.g. "LocationData") 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. "LocationData") 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 GenerateInstantVerificationTokenRequest) MarshalJSON() ([]byte, error) { + type NoMethod GenerateInstantVerificationTokenRequest + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GenerateInstantVerificationTokenResponse: Response message for +// Verifications.GenerateInstantVerificationToken. +type GenerateInstantVerificationTokenResponse struct { + // InstantVerificationToken: The generated instant verification token. + InstantVerificationToken string `json:"instantVerificationToken,omitempty"` + // Result: Output only. The result of the instant verification token + // generation. + // + // Possible values: + // "RESULT_UNSPECIFIED" - Default value, will result in errors. + // "SUCCEEDED" - The instant verification token was generated successfully. + // "FAILED" - The instant verification token was not generated.. + Result string `json:"result,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the server. + googleapi.ServerResponse `json:"-"` + // ForceSendFields is a list of field names (e.g. "InstantVerificationToken") + // 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. "InstantVerificationToken") 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 GenerateInstantVerificationTokenResponse) MarshalJSON() ([]byte, error) { + type NoMethod GenerateInstantVerificationTokenResponse + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // ListVerificationsResponse: Response message for // Verifications.ListVerifications. type ListVerificationsResponse struct { @@ -388,6 +466,43 @@ func (s ListVerificationsResponse) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// LocationData: The address and other details of the location to generate an +// instant verification token for. +type LocationData struct { + // Address: Immutable. A precise, accurate address to describe your business + // location. PO boxes or mailboxes located at remote locations are not + // acceptable. At this time, you can specify a maximum of five `address_lines` + // values in the address. + Address *PostalAddress `json:"address,omitempty"` + // Name: Immutable. Name should reflect your business's real-world name, as + // used consistently on your storefront, website, and stationery, and as known + // to customers. Any additional information, when relevant, can be included in + // other fields of the resource (for example, `Address`, `Categories`). Don't + // add unnecessary information to your name (for example, prefer "Google" over + // "Google Inc. - Mountain View Corporate Headquarters"). Don't include + // marketing taglines, store codes, special characters, hours or closed/open + // status, phone numbers, website URLs, service/product information, + // location/address or directions, or containment information (for example, + // "Chase ATM in Duane Reade"). + Name string `json:"name,omitempty"` + // ForceSendFields is a list of field names (e.g. "Address") 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. "Address") 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) +} + // PostalAddress: Represents a postal address, such as for postal delivery or // payments addresses. With a postal address, a postal service can deliver // items to a premise, P.O. box, or similar. A postal address is not intended @@ -1377,3 +1492,101 @@ func (c *LocationsVerificationsListCall) Pages(ctx context.Context, f func(*List c.PageToken(x.NextPageToken) } } + +type VerificationTokensGenerateCall struct { + s *Service + generateinstantverificationtokenrequest *GenerateInstantVerificationTokenRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Generate: Generate a token for the provided location data to verify the +// location. +func (r *VerificationTokensService) Generate(generateinstantverificationtokenrequest *GenerateInstantVerificationTokenRequest) *VerificationTokensGenerateCall { + c := &VerificationTokensGenerateCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.generateinstantverificationtokenrequest = generateinstantverificationtokenrequest + 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 *VerificationTokensGenerateCall) Fields(s ...googleapi.Field) *VerificationTokensGenerateCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *VerificationTokensGenerateCall) Context(ctx context.Context) *VerificationTokensGenerateCall { + 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 *VerificationTokensGenerateCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *VerificationTokensGenerateCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) + body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.generateinstantverificationtokenrequest) + if err != nil { + return nil, err + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1/verificationTokens:generate") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("POST", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "mybusinessverifications.verificationTokens.generate", "request", internallog.HTTPRequest(req, body.Bytes())) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "mybusinessverifications.verificationTokens.generate" call. +// Any non-2xx status code is an error. Response headers are in either +// *GenerateInstantVerificationTokenResponse.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 *VerificationTokensGenerateCall) Do(opts ...googleapi.CallOption) (*GenerateInstantVerificationTokenResponse, 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 := &GenerateInstantVerificationTokenResponse{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + b, err := gensupport.DecodeResponseBytes(target, res) + if err != nil { + return nil, err + } + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "mybusinessverifications.verificationTokens.generate", "response", internallog.HTTPResponse(res, b)) + return ret, nil +} diff --git a/securitycenter/v1/securitycenter-api.json b/securitycenter/v1/securitycenter-api.json index f2b8aef6bef..bd7537b3b53 100644 --- a/securitycenter/v1/securitycenter-api.json +++ b/securitycenter/v1/securitycenter-api.json @@ -5938,7 +5938,7 @@ } } }, - "revision": "20250707", + "revision": "20250721", "rootUrl": "https://securitycenter.googleapis.com/", "schemas": { "Access": { @@ -6802,6 +6802,40 @@ }, "type": "object" }, + "CloudControl": { + "description": "CloudControl associated with the finding.", + "id": "CloudControl", + "properties": { + "cloudControlName": { + "description": "Name of the CloudControl associated with the finding.", + "type": "string" + }, + "policyType": { + "description": "Policy type of the CloudControl", + "type": "string" + }, + "type": { + "description": "Type of cloud control.", + "enum": [ + "CLOUD_CONTROL_TYPE_UNSPECIFIED", + "BUILT_IN", + "CUSTOM" + ], + "enumDescriptions": [ + "Unspecified.", + "Built in Cloud Control.", + "Custom Cloud Control." + ], + "type": "string" + }, + "version": { + "description": "Version of the Cloud Control", + "format": "int32", + "type": "integer" + } + }, + "type": "object" + }, "CloudDlpDataProfile": { "description": "The [data profile](https://cloud.google.com/dlp/docs/data-profiles) associated with the finding.", "id": "CloudDlpDataProfile", @@ -6897,6 +6931,31 @@ }, "type": "object" }, + "ComplianceDetails": { + "description": "Compliance Details associated with the finding.", + "id": "ComplianceDetails", + "properties": { + "cloudControl": { + "$ref": "CloudControl", + "description": "CloudControl associated with the finding" + }, + "cloudControlDeploymentNames": { + "description": "Cloud Control Deployments associated with the finding. For example, organizations/123/locations/global/cloudControlDeployments/deploymentIdentifier", + "items": { + "type": "string" + }, + "type": "array" + }, + "frameworks": { + "description": "Details of Frameworks associated with the finding", + "items": { + "$ref": "Framework" + }, + "type": "array" + } + }, + "type": "object" + }, "Connection": { "description": "Contains information about the IP connection associated with the finding.", "id": "Connection", @@ -6998,6 +7057,21 @@ }, "type": "object" }, + "Control": { + "description": "Compliance control associated with the finding.", + "id": "Control", + "properties": { + "controlName": { + "description": "Name of the Control", + "type": "string" + }, + "displayName": { + "description": "Display name of the control. For example, AU-02.", + "type": "string" + } + }, + "type": "object" + }, "CreateResourceValueConfigRequest": { "description": "Request message to create single resource value config", "id": "CreateResourceValueConfigRequest", @@ -7900,6 +7974,10 @@ "$ref": "CloudDlpInspection", "description": "Cloud Data Loss Prevention (Cloud DLP) inspection results that are associated with the finding." }, + "complianceDetails": { + "$ref": "ComplianceDetails", + "description": "Details about the compliance implications of the finding." + }, "compliances": { "description": "Contains compliance information for security standards associated to the finding.", "items": { @@ -8234,6 +8312,63 @@ }, "type": "object" }, + "Framework": { + "description": "Compliance framework associated with the finding.", + "id": "Framework", + "properties": { + "category": { + "description": "Category of the framework associated with the finding. E.g. Security Benchmark, or Assured Workloads", + "items": { + "enum": [ + "FRAMEWORK_CATEGORY_UNSPECIFIED", + "SECURITY_BENCHMARKS", + "ASSURED_WORKLOADS", + "DATA_SECURITY", + "GOOGLE_BEST_PRACTICES" + ], + "enumDescriptions": [ + "Default value. This value is unused.", + "Security Benchmarks framework", + "Assured Workloads framework", + "Data Security framework", + "Google Best Practices framework" + ], + "type": "string" + }, + "type": "array" + }, + "controls": { + "description": "The controls associated with the framework.", + "items": { + "$ref": "Control" + }, + "type": "array" + }, + "displayName": { + "description": "Display name of the framework. For a standard framework, this will look like e.g. PCI DSS 3.2.1, whereas for a custom framework it can be a user defined string like MyFramework", + "type": "string" + }, + "name": { + "description": "Name of the framework associated with the finding", + "type": "string" + }, + "type": { + "description": "Type of the framework associated with the finding, to specify whether the framework is built-in (pre-defined and immutable) or a custom framework defined by the customer (equivalent to security posture)", + "enum": [ + "FRAMEWORK_TYPE_UNSPECIFIED", + "FRAMEWORK_TYPE_BUILT_IN", + "FRAMEWORK_TYPE_CUSTOM" + ], + "enumDescriptions": [ + "Default value. This value is unused.", + "The framework is a built-in framework if it is created and managed by GCP.", + "The framework is a custom framework if it is created and managed by the user." + ], + "type": "string" + } + }, + "type": "object" + }, "GcpMetadata": { "description": "Google Cloud metadata associated with the resource. Only applicable if the finding's cloud provider is Google Cloud.", "id": "GcpMetadata", @@ -9802,6 +9937,40 @@ }, "type": "object" }, + "GoogleCloudSecuritycenterV2CloudControl": { + "description": "CloudControl associated with the finding.", + "id": "GoogleCloudSecuritycenterV2CloudControl", + "properties": { + "cloudControlName": { + "description": "Name of the CloudControl associated with the finding.", + "type": "string" + }, + "policyType": { + "description": "Policy type of the CloudControl", + "type": "string" + }, + "type": { + "description": "Type of cloud control.", + "enum": [ + "CLOUD_CONTROL_TYPE_UNSPECIFIED", + "BUILT_IN", + "CUSTOM" + ], + "enumDescriptions": [ + "Unspecified.", + "Built in Cloud Control.", + "Custom Cloud Control." + ], + "type": "string" + }, + "version": { + "description": "Version of the Cloud Control", + "format": "int32", + "type": "integer" + } + }, + "type": "object" + }, "GoogleCloudSecuritycenterV2CloudDlpDataProfile": { "description": "The [data profile](https://cloud.google.com/dlp/docs/data-profiles) associated with the finding.", "id": "GoogleCloudSecuritycenterV2CloudDlpDataProfile", @@ -9897,6 +10066,31 @@ }, "type": "object" }, + "GoogleCloudSecuritycenterV2ComplianceDetails": { + "description": "Compliance Details associated with the finding.", + "id": "GoogleCloudSecuritycenterV2ComplianceDetails", + "properties": { + "cloudControl": { + "$ref": "GoogleCloudSecuritycenterV2CloudControl", + "description": "CloudControl associated with the finding" + }, + "cloudControlDeploymentNames": { + "description": "Cloud Control Deployments associated with the finding. For example, organizations/123/locations/global/cloudControlDeployments/deploymentIdentifier", + "items": { + "type": "string" + }, + "type": "array" + }, + "frameworks": { + "description": "Details of Frameworks associated with the finding", + "items": { + "$ref": "GoogleCloudSecuritycenterV2Framework" + }, + "type": "array" + } + }, + "type": "object" + }, "GoogleCloudSecuritycenterV2Connection": { "description": "Contains information about the IP connection associated with the finding.", "id": "GoogleCloudSecuritycenterV2Connection", @@ -9998,6 +10192,21 @@ }, "type": "object" }, + "GoogleCloudSecuritycenterV2Control": { + "description": "Compliance control associated with the finding.", + "id": "GoogleCloudSecuritycenterV2Control", + "properties": { + "controlName": { + "description": "Name of the Control", + "type": "string" + }, + "displayName": { + "description": "Display name of the control. For example, AU-02.", + "type": "string" + } + }, + "type": "object" + }, "GoogleCloudSecuritycenterV2Cve": { "description": "CVE stands for Common Vulnerabilities and Exposures. Information from the [CVE record](https://www.cve.org/ResourcesSupport/Glossary) that describes this vulnerability.", "id": "GoogleCloudSecuritycenterV2Cve", @@ -10710,6 +10919,10 @@ "$ref": "GoogleCloudSecuritycenterV2CloudDlpInspection", "description": "Cloud Data Loss Prevention (Cloud DLP) inspection results that are associated with the finding." }, + "complianceDetails": { + "$ref": "GoogleCloudSecuritycenterV2ComplianceDetails", + "description": "Details about the compliance implications of the finding." + }, "compliances": { "description": "Contains compliance information for security standards associated to the finding.", "items": { @@ -11046,6 +11259,63 @@ }, "type": "object" }, + "GoogleCloudSecuritycenterV2Framework": { + "description": "Compliance framework associated with the finding.", + "id": "GoogleCloudSecuritycenterV2Framework", + "properties": { + "category": { + "description": "Category of the framework associated with the finding. E.g. Security Benchmark, or Assured Workloads", + "items": { + "enum": [ + "FRAMEWORK_CATEGORY_UNSPECIFIED", + "SECURITY_BENCHMARKS", + "ASSURED_WORKLOADS", + "DATA_SECURITY", + "GOOGLE_BEST_PRACTICES" + ], + "enumDescriptions": [ + "Default value. This value is unused.", + "Security Benchmarks framework", + "Assured Workloads framework", + "Data Security framework", + "Google Best Practices framework" + ], + "type": "string" + }, + "type": "array" + }, + "controls": { + "description": "The controls associated with the framework.", + "items": { + "$ref": "GoogleCloudSecuritycenterV2Control" + }, + "type": "array" + }, + "displayName": { + "description": "Display name of the framework. For a standard framework, this will look like e.g. PCI DSS 3.2.1, whereas for a custom framework it can be a user defined string like MyFramework", + "type": "string" + }, + "name": { + "description": "Name of the framework associated with the finding", + "type": "string" + }, + "type": { + "description": "Type of the framework associated with the finding, to specify whether the framework is built-in (pre-defined and immutable) or a custom framework defined by the customer (equivalent to security posture)", + "enum": [ + "FRAMEWORK_TYPE_UNSPECIFIED", + "FRAMEWORK_TYPE_BUILT_IN", + "FRAMEWORK_TYPE_CUSTOM" + ], + "enumDescriptions": [ + "Default value. This value is unused.", + "The framework is a built-in framework if it is created and managed by GCP.", + "The framework is a custom framework if it is created and managed by the user." + ], + "type": "string" + } + }, + "type": "object" + }, "GoogleCloudSecuritycenterV2Geolocation": { "description": "Represents a geographical location for a given access.", "id": "GoogleCloudSecuritycenterV2Geolocation", @@ -12938,7 +13208,7 @@ }, "gcpMetadata": { "$ref": "GcpMetadata", - "description": "The GCP metadata associated with the finding." + "description": "The Google Cloud metadata associated with the finding." }, "location": { "description": "The region or location of the service (if applicable).", diff --git a/securitycenter/v1/securitycenter-gen.go b/securitycenter/v1/securitycenter-gen.go index ef742c45a9e..a00da60a03f 100644 --- a/securitycenter/v1/securitycenter-gen.go +++ b/securitycenter/v1/securitycenter-gen.go @@ -2150,6 +2150,39 @@ func (s CloudArmor) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// CloudControl: CloudControl associated with the finding. +type CloudControl struct { + // CloudControlName: Name of the CloudControl associated with the finding. + CloudControlName string `json:"cloudControlName,omitempty"` + // PolicyType: Policy type of the CloudControl + PolicyType string `json:"policyType,omitempty"` + // Type: Type of cloud control. + // + // Possible values: + // "CLOUD_CONTROL_TYPE_UNSPECIFIED" - Unspecified. + // "BUILT_IN" - Built in Cloud Control. + // "CUSTOM" - Custom Cloud Control. + Type string `json:"type,omitempty"` + // Version: Version of the Cloud Control + Version int64 `json:"version,omitempty"` + // ForceSendFields is a list of field names (e.g. "CloudControlName") 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. "CloudControlName") 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 CloudControl) MarshalJSON() ([]byte, error) { + type NoMethod CloudControl + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // CloudDlpDataProfile: The data profile // (https://cloud.google.com/dlp/docs/data-profiles) associated with the // finding. @@ -2279,6 +2312,35 @@ func (s Compliance) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// ComplianceDetails: Compliance Details associated with the finding. +type ComplianceDetails struct { + // CloudControl: CloudControl associated with the finding + CloudControl *CloudControl `json:"cloudControl,omitempty"` + // CloudControlDeploymentNames: Cloud Control Deployments associated with the + // finding. For example, + // organizations/123/locations/global/cloudControlDeployments/deploymentIdentifi + // er + CloudControlDeploymentNames []string `json:"cloudControlDeploymentNames,omitempty"` + // Frameworks: Details of Frameworks associated with the finding + Frameworks []*Framework `json:"frameworks,omitempty"` + // ForceSendFields is a list of field names (e.g. "CloudControl") 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. "CloudControl") 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 ComplianceDetails) MarshalJSON() ([]byte, error) { + type NoMethod ComplianceDetails + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // Connection: Contains information about the IP connection associated with the // finding. type Connection struct { @@ -2397,6 +2459,30 @@ func (s Container) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// Control: Compliance control associated with the finding. +type Control struct { + // ControlName: Name of the Control + ControlName string `json:"controlName,omitempty"` + // DisplayName: Display name of the control. For example, AU-02. + DisplayName string `json:"displayName,omitempty"` + // ForceSendFields is a list of field names (e.g. "ControlName") 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. "ControlName") 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 Control) MarshalJSON() ([]byte, error) { + type NoMethod Control + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // CreateResourceValueConfigRequest: Request message to create single resource // value config type CreateResourceValueConfigRequest struct { @@ -3481,6 +3567,8 @@ type Finding struct { // CloudDlpInspection: Cloud Data Loss Prevention (Cloud DLP) inspection // results that are associated with the finding. CloudDlpInspection *CloudDlpInspection `json:"cloudDlpInspection,omitempty"` + // ComplianceDetails: Details about the compliance implications of the finding. + ComplianceDetails *ComplianceDetails `json:"complianceDetails,omitempty"` // Compliances: Contains compliance information for security standards // associated to the finding. Compliances []*Compliance `json:"compliances,omitempty"` @@ -3760,6 +3848,55 @@ func (s Folder) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// Framework: Compliance framework associated with the finding. +type Framework struct { + // Category: Category of the framework associated with the finding. E.g. + // Security Benchmark, or Assured Workloads + // + // Possible values: + // "FRAMEWORK_CATEGORY_UNSPECIFIED" - Default value. This value is unused. + // "SECURITY_BENCHMARKS" - Security Benchmarks framework + // "ASSURED_WORKLOADS" - Assured Workloads framework + // "DATA_SECURITY" - Data Security framework + // "GOOGLE_BEST_PRACTICES" - Google Best Practices framework + Category []string `json:"category,omitempty"` + // Controls: The controls associated with the framework. + Controls []*Control `json:"controls,omitempty"` + // DisplayName: Display name of the framework. For a standard framework, this + // will look like e.g. PCI DSS 3.2.1, whereas for a custom framework it can be + // a user defined string like MyFramework + DisplayName string `json:"displayName,omitempty"` + // Name: Name of the framework associated with the finding + Name string `json:"name,omitempty"` + // Type: Type of the framework associated with the finding, to specify whether + // the framework is built-in (pre-defined and immutable) or a custom framework + // defined by the customer (equivalent to security posture) + // + // Possible values: + // "FRAMEWORK_TYPE_UNSPECIFIED" - Default value. This value is unused. + // "FRAMEWORK_TYPE_BUILT_IN" - The framework is a built-in framework if it is + // created and managed by GCP. + // "FRAMEWORK_TYPE_CUSTOM" - The framework is a custom framework if it is + // created and managed by the user. + Type string `json:"type,omitempty"` + // ForceSendFields is a list of field names (e.g. "Category") 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. "Category") 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 Framework) MarshalJSON() ([]byte, error) { + type NoMethod Framework + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GcpMetadata: Google Cloud metadata associated with the resource. Only // applicable if the finding's cloud provider is Google Cloud. type GcpMetadata struct { @@ -5776,6 +5913,40 @@ func (s GoogleCloudSecuritycenterV2CloudArmor) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudSecuritycenterV2CloudControl: CloudControl associated with the +// finding. +type GoogleCloudSecuritycenterV2CloudControl struct { + // CloudControlName: Name of the CloudControl associated with the finding. + CloudControlName string `json:"cloudControlName,omitempty"` + // PolicyType: Policy type of the CloudControl + PolicyType string `json:"policyType,omitempty"` + // Type: Type of cloud control. + // + // Possible values: + // "CLOUD_CONTROL_TYPE_UNSPECIFIED" - Unspecified. + // "BUILT_IN" - Built in Cloud Control. + // "CUSTOM" - Custom Cloud Control. + Type string `json:"type,omitempty"` + // Version: Version of the Cloud Control + Version int64 `json:"version,omitempty"` + // ForceSendFields is a list of field names (e.g. "CloudControlName") 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. "CloudControlName") 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 GoogleCloudSecuritycenterV2CloudControl) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudSecuritycenterV2CloudControl + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudSecuritycenterV2CloudDlpDataProfile: The data profile // (https://cloud.google.com/dlp/docs/data-profiles) associated with the // finding. @@ -5907,6 +6078,36 @@ func (s GoogleCloudSecuritycenterV2Compliance) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudSecuritycenterV2ComplianceDetails: Compliance Details associated +// with the finding. +type GoogleCloudSecuritycenterV2ComplianceDetails struct { + // CloudControl: CloudControl associated with the finding + CloudControl *GoogleCloudSecuritycenterV2CloudControl `json:"cloudControl,omitempty"` + // CloudControlDeploymentNames: Cloud Control Deployments associated with the + // finding. For example, + // organizations/123/locations/global/cloudControlDeployments/deploymentIdentifi + // er + CloudControlDeploymentNames []string `json:"cloudControlDeploymentNames,omitempty"` + // Frameworks: Details of Frameworks associated with the finding + Frameworks []*GoogleCloudSecuritycenterV2Framework `json:"frameworks,omitempty"` + // ForceSendFields is a list of field names (e.g. "CloudControl") 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. "CloudControl") 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 GoogleCloudSecuritycenterV2ComplianceDetails) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudSecuritycenterV2ComplianceDetails + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudSecuritycenterV2Connection: Contains information about the IP // connection associated with the finding. type GoogleCloudSecuritycenterV2Connection struct { @@ -6025,6 +6226,31 @@ func (s GoogleCloudSecuritycenterV2Container) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudSecuritycenterV2Control: Compliance control associated with the +// finding. +type GoogleCloudSecuritycenterV2Control struct { + // ControlName: Name of the Control + ControlName string `json:"controlName,omitempty"` + // DisplayName: Display name of the control. For example, AU-02. + DisplayName string `json:"displayName,omitempty"` + // ForceSendFields is a list of field names (e.g. "ControlName") 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. "ControlName") 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 GoogleCloudSecuritycenterV2Control) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudSecuritycenterV2Control + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudSecuritycenterV2Cve: CVE stands for Common Vulnerabilities and // Exposures. Information from the CVE record // (https://www.cve.org/ResourcesSupport/Glossary) that describes this @@ -6880,6 +7106,8 @@ type GoogleCloudSecuritycenterV2Finding struct { // CloudDlpInspection: Cloud Data Loss Prevention (Cloud DLP) inspection // results that are associated with the finding. CloudDlpInspection *GoogleCloudSecuritycenterV2CloudDlpInspection `json:"cloudDlpInspection,omitempty"` + // ComplianceDetails: Details about the compliance implications of the finding. + ComplianceDetails *GoogleCloudSecuritycenterV2ComplianceDetails `json:"complianceDetails,omitempty"` // Compliances: Contains compliance information for security standards // associated to the finding. Compliances []*GoogleCloudSecuritycenterV2Compliance `json:"compliances,omitempty"` @@ -7166,6 +7394,56 @@ func (s GoogleCloudSecuritycenterV2Folder) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudSecuritycenterV2Framework: Compliance framework associated with +// the finding. +type GoogleCloudSecuritycenterV2Framework struct { + // Category: Category of the framework associated with the finding. E.g. + // Security Benchmark, or Assured Workloads + // + // Possible values: + // "FRAMEWORK_CATEGORY_UNSPECIFIED" - Default value. This value is unused. + // "SECURITY_BENCHMARKS" - Security Benchmarks framework + // "ASSURED_WORKLOADS" - Assured Workloads framework + // "DATA_SECURITY" - Data Security framework + // "GOOGLE_BEST_PRACTICES" - Google Best Practices framework + Category []string `json:"category,omitempty"` + // Controls: The controls associated with the framework. + Controls []*GoogleCloudSecuritycenterV2Control `json:"controls,omitempty"` + // DisplayName: Display name of the framework. For a standard framework, this + // will look like e.g. PCI DSS 3.2.1, whereas for a custom framework it can be + // a user defined string like MyFramework + DisplayName string `json:"displayName,omitempty"` + // Name: Name of the framework associated with the finding + Name string `json:"name,omitempty"` + // Type: Type of the framework associated with the finding, to specify whether + // the framework is built-in (pre-defined and immutable) or a custom framework + // defined by the customer (equivalent to security posture) + // + // Possible values: + // "FRAMEWORK_TYPE_UNSPECIFIED" - Default value. This value is unused. + // "FRAMEWORK_TYPE_BUILT_IN" - The framework is a built-in framework if it is + // created and managed by GCP. + // "FRAMEWORK_TYPE_CUSTOM" - The framework is a custom framework if it is + // created and managed by the user. + Type string `json:"type,omitempty"` + // ForceSendFields is a list of field names (e.g. "Category") 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. "Category") 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 GoogleCloudSecuritycenterV2Framework) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudSecuritycenterV2Framework + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudSecuritycenterV2Geolocation: Represents a geographical location // for a given access. type GoogleCloudSecuritycenterV2Geolocation struct { @@ -9013,7 +9291,7 @@ type GoogleCloudSecuritycenterV2Resource struct { CloudProvider string `json:"cloudProvider,omitempty"` // DisplayName: The human readable name of the resource. DisplayName string `json:"displayName,omitempty"` - // GcpMetadata: The GCP metadata associated with the finding. + // GcpMetadata: The Google Cloud metadata associated with the finding. GcpMetadata *GcpMetadata `json:"gcpMetadata,omitempty"` // Location: The region or location of the service (if applicable). Location string `json:"location,omitempty"` diff --git a/securitycenter/v1beta2/securitycenter-api.json b/securitycenter/v1beta2/securitycenter-api.json index 0eee6576392..f5480bfede8 100644 --- a/securitycenter/v1beta2/securitycenter-api.json +++ b/securitycenter/v1beta2/securitycenter-api.json @@ -2003,7 +2003,7 @@ } } }, - "revision": "20250707", + "revision": "20250721", "rootUrl": "https://securitycenter.googleapis.com/", "schemas": { "Access": { @@ -2539,6 +2539,40 @@ }, "type": "object" }, + "CloudControl": { + "description": "CloudControl associated with the finding.", + "id": "CloudControl", + "properties": { + "cloudControlName": { + "description": "Name of the CloudControl associated with the finding.", + "type": "string" + }, + "policyType": { + "description": "Policy type of the CloudControl", + "type": "string" + }, + "type": { + "description": "Type of cloud control.", + "enum": [ + "CLOUD_CONTROL_TYPE_UNSPECIFIED", + "BUILT_IN", + "CUSTOM" + ], + "enumDescriptions": [ + "Unspecified.", + "Built in Cloud Control.", + "Custom Cloud Control." + ], + "type": "string" + }, + "version": { + "description": "Version of the Cloud Control", + "format": "int32", + "type": "integer" + } + }, + "type": "object" + }, "CloudDlpDataProfile": { "description": "The [data profile](https://cloud.google.com/dlp/docs/data-profiles) associated with the finding.", "id": "CloudDlpDataProfile", @@ -2634,6 +2668,31 @@ }, "type": "object" }, + "ComplianceDetails": { + "description": "Compliance Details associated with the finding.", + "id": "ComplianceDetails", + "properties": { + "cloudControl": { + "$ref": "CloudControl", + "description": "CloudControl associated with the finding" + }, + "cloudControlDeploymentNames": { + "description": "Cloud Control Deployments associated with the finding. For example, organizations/123/locations/global/cloudControlDeployments/deploymentIdentifier", + "items": { + "type": "string" + }, + "type": "array" + }, + "frameworks": { + "description": "Details of Frameworks associated with the finding", + "items": { + "$ref": "Framework" + }, + "type": "array" + } + }, + "type": "object" + }, "Config": { "description": "Configuration of a module.", "id": "Config", @@ -2811,6 +2870,21 @@ }, "type": "object" }, + "Control": { + "description": "Compliance control associated with the finding.", + "id": "Control", + "properties": { + "controlName": { + "description": "Name of the Control", + "type": "string" + }, + "displayName": { + "description": "Display name of the control. For example, AU-02.", + "type": "string" + } + }, + "type": "object" + }, "Cve": { "description": "CVE stands for Common Vulnerabilities and Exposures. Information from the [CVE record](https://www.cve.org/ResourcesSupport/Glossary) that describes this vulnerability.", "id": "Cve", @@ -3586,6 +3660,10 @@ "$ref": "CloudDlpInspection", "description": "Cloud Data Loss Prevention (Cloud DLP) inspection results that are associated with the finding." }, + "complianceDetails": { + "$ref": "ComplianceDetails", + "description": "Details about the compliance implications of the finding." + }, "compliances": { "description": "Contains compliance information for security standards associated to the finding.", "items": { @@ -3920,6 +3998,63 @@ }, "type": "object" }, + "Framework": { + "description": "Compliance framework associated with the finding.", + "id": "Framework", + "properties": { + "category": { + "description": "Category of the framework associated with the finding. E.g. Security Benchmark, or Assured Workloads", + "items": { + "enum": [ + "FRAMEWORK_CATEGORY_UNSPECIFIED", + "SECURITY_BENCHMARKS", + "ASSURED_WORKLOADS", + "DATA_SECURITY", + "GOOGLE_BEST_PRACTICES" + ], + "enumDescriptions": [ + "Default value. This value is unused.", + "Security Benchmarks framework", + "Assured Workloads framework", + "Data Security framework", + "Google Best Practices framework" + ], + "type": "string" + }, + "type": "array" + }, + "controls": { + "description": "The controls associated with the framework.", + "items": { + "$ref": "Control" + }, + "type": "array" + }, + "displayName": { + "description": "Display name of the framework. For a standard framework, this will look like e.g. PCI DSS 3.2.1, whereas for a custom framework it can be a user defined string like MyFramework", + "type": "string" + }, + "name": { + "description": "Name of the framework associated with the finding", + "type": "string" + }, + "type": { + "description": "Type of the framework associated with the finding, to specify whether the framework is built-in (pre-defined and immutable) or a custom framework defined by the customer (equivalent to security posture)", + "enum": [ + "FRAMEWORK_TYPE_UNSPECIFIED", + "FRAMEWORK_TYPE_BUILT_IN", + "FRAMEWORK_TYPE_CUSTOM" + ], + "enumDescriptions": [ + "Default value. This value is unused.", + "The framework is a built-in framework if it is created and managed by GCP.", + "The framework is a custom framework if it is created and managed by the user." + ], + "type": "string" + } + }, + "type": "object" + }, "GcpMetadata": { "description": "Google Cloud metadata associated with the resource. Only applicable if the finding's cloud provider is Google Cloud.", "id": "GcpMetadata", @@ -5465,6 +5600,40 @@ }, "type": "object" }, + "GoogleCloudSecuritycenterV2CloudControl": { + "description": "CloudControl associated with the finding.", + "id": "GoogleCloudSecuritycenterV2CloudControl", + "properties": { + "cloudControlName": { + "description": "Name of the CloudControl associated with the finding.", + "type": "string" + }, + "policyType": { + "description": "Policy type of the CloudControl", + "type": "string" + }, + "type": { + "description": "Type of cloud control.", + "enum": [ + "CLOUD_CONTROL_TYPE_UNSPECIFIED", + "BUILT_IN", + "CUSTOM" + ], + "enumDescriptions": [ + "Unspecified.", + "Built in Cloud Control.", + "Custom Cloud Control." + ], + "type": "string" + }, + "version": { + "description": "Version of the Cloud Control", + "format": "int32", + "type": "integer" + } + }, + "type": "object" + }, "GoogleCloudSecuritycenterV2CloudDlpDataProfile": { "description": "The [data profile](https://cloud.google.com/dlp/docs/data-profiles) associated with the finding.", "id": "GoogleCloudSecuritycenterV2CloudDlpDataProfile", @@ -5560,6 +5729,31 @@ }, "type": "object" }, + "GoogleCloudSecuritycenterV2ComplianceDetails": { + "description": "Compliance Details associated with the finding.", + "id": "GoogleCloudSecuritycenterV2ComplianceDetails", + "properties": { + "cloudControl": { + "$ref": "GoogleCloudSecuritycenterV2CloudControl", + "description": "CloudControl associated with the finding" + }, + "cloudControlDeploymentNames": { + "description": "Cloud Control Deployments associated with the finding. For example, organizations/123/locations/global/cloudControlDeployments/deploymentIdentifier", + "items": { + "type": "string" + }, + "type": "array" + }, + "frameworks": { + "description": "Details of Frameworks associated with the finding", + "items": { + "$ref": "GoogleCloudSecuritycenterV2Framework" + }, + "type": "array" + } + }, + "type": "object" + }, "GoogleCloudSecuritycenterV2Connection": { "description": "Contains information about the IP connection associated with the finding.", "id": "GoogleCloudSecuritycenterV2Connection", @@ -5661,6 +5855,21 @@ }, "type": "object" }, + "GoogleCloudSecuritycenterV2Control": { + "description": "Compliance control associated with the finding.", + "id": "GoogleCloudSecuritycenterV2Control", + "properties": { + "controlName": { + "description": "Name of the Control", + "type": "string" + }, + "displayName": { + "description": "Display name of the control. For example, AU-02.", + "type": "string" + } + }, + "type": "object" + }, "GoogleCloudSecuritycenterV2Cve": { "description": "CVE stands for Common Vulnerabilities and Exposures. Information from the [CVE record](https://www.cve.org/ResourcesSupport/Glossary) that describes this vulnerability.", "id": "GoogleCloudSecuritycenterV2Cve", @@ -6373,6 +6582,10 @@ "$ref": "GoogleCloudSecuritycenterV2CloudDlpInspection", "description": "Cloud Data Loss Prevention (Cloud DLP) inspection results that are associated with the finding." }, + "complianceDetails": { + "$ref": "GoogleCloudSecuritycenterV2ComplianceDetails", + "description": "Details about the compliance implications of the finding." + }, "compliances": { "description": "Contains compliance information for security standards associated to the finding.", "items": { @@ -6709,6 +6922,63 @@ }, "type": "object" }, + "GoogleCloudSecuritycenterV2Framework": { + "description": "Compliance framework associated with the finding.", + "id": "GoogleCloudSecuritycenterV2Framework", + "properties": { + "category": { + "description": "Category of the framework associated with the finding. E.g. Security Benchmark, or Assured Workloads", + "items": { + "enum": [ + "FRAMEWORK_CATEGORY_UNSPECIFIED", + "SECURITY_BENCHMARKS", + "ASSURED_WORKLOADS", + "DATA_SECURITY", + "GOOGLE_BEST_PRACTICES" + ], + "enumDescriptions": [ + "Default value. This value is unused.", + "Security Benchmarks framework", + "Assured Workloads framework", + "Data Security framework", + "Google Best Practices framework" + ], + "type": "string" + }, + "type": "array" + }, + "controls": { + "description": "The controls associated with the framework.", + "items": { + "$ref": "GoogleCloudSecuritycenterV2Control" + }, + "type": "array" + }, + "displayName": { + "description": "Display name of the framework. For a standard framework, this will look like e.g. PCI DSS 3.2.1, whereas for a custom framework it can be a user defined string like MyFramework", + "type": "string" + }, + "name": { + "description": "Name of the framework associated with the finding", + "type": "string" + }, + "type": { + "description": "Type of the framework associated with the finding, to specify whether the framework is built-in (pre-defined and immutable) or a custom framework defined by the customer (equivalent to security posture)", + "enum": [ + "FRAMEWORK_TYPE_UNSPECIFIED", + "FRAMEWORK_TYPE_BUILT_IN", + "FRAMEWORK_TYPE_CUSTOM" + ], + "enumDescriptions": [ + "Default value. This value is unused.", + "The framework is a built-in framework if it is created and managed by GCP.", + "The framework is a custom framework if it is created and managed by the user." + ], + "type": "string" + } + }, + "type": "object" + }, "GoogleCloudSecuritycenterV2Geolocation": { "description": "Represents a geographical location for a given access.", "id": "GoogleCloudSecuritycenterV2Geolocation", @@ -8601,7 +8871,7 @@ }, "gcpMetadata": { "$ref": "GcpMetadata", - "description": "The GCP metadata associated with the finding." + "description": "The Google Cloud metadata associated with the finding." }, "location": { "description": "The region or location of the service (if applicable).", diff --git a/securitycenter/v1beta2/securitycenter-gen.go b/securitycenter/v1beta2/securitycenter-gen.go index 6f49c89a40b..a534a177b24 100644 --- a/securitycenter/v1beta2/securitycenter-gen.go +++ b/securitycenter/v1beta2/securitycenter-gen.go @@ -1205,6 +1205,39 @@ func (s CloudArmor) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// CloudControl: CloudControl associated with the finding. +type CloudControl struct { + // CloudControlName: Name of the CloudControl associated with the finding. + CloudControlName string `json:"cloudControlName,omitempty"` + // PolicyType: Policy type of the CloudControl + PolicyType string `json:"policyType,omitempty"` + // Type: Type of cloud control. + // + // Possible values: + // "CLOUD_CONTROL_TYPE_UNSPECIFIED" - Unspecified. + // "BUILT_IN" - Built in Cloud Control. + // "CUSTOM" - Custom Cloud Control. + Type string `json:"type,omitempty"` + // Version: Version of the Cloud Control + Version int64 `json:"version,omitempty"` + // ForceSendFields is a list of field names (e.g. "CloudControlName") 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. "CloudControlName") 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 CloudControl) MarshalJSON() ([]byte, error) { + type NoMethod CloudControl + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // CloudDlpDataProfile: The data profile // (https://cloud.google.com/dlp/docs/data-profiles) associated with the // finding. @@ -1334,6 +1367,35 @@ func (s Compliance) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// ComplianceDetails: Compliance Details associated with the finding. +type ComplianceDetails struct { + // CloudControl: CloudControl associated with the finding + CloudControl *CloudControl `json:"cloudControl,omitempty"` + // CloudControlDeploymentNames: Cloud Control Deployments associated with the + // finding. For example, + // organizations/123/locations/global/cloudControlDeployments/deploymentIdentifi + // er + CloudControlDeploymentNames []string `json:"cloudControlDeploymentNames,omitempty"` + // Frameworks: Details of Frameworks associated with the finding + Frameworks []*Framework `json:"frameworks,omitempty"` + // ForceSendFields is a list of field names (e.g. "CloudControl") 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. "CloudControl") 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 ComplianceDetails) MarshalJSON() ([]byte, error) { + type NoMethod ComplianceDetails + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // Config: Configuration of a module. type Config struct { // ModuleEnablementState: The state of enablement for the module at its level @@ -1535,6 +1597,30 @@ func (s ContainerThreatDetectionSettings) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// Control: Compliance control associated with the finding. +type Control struct { + // ControlName: Name of the Control + ControlName string `json:"controlName,omitempty"` + // DisplayName: Display name of the control. For example, AU-02. + DisplayName string `json:"displayName,omitempty"` + // ForceSendFields is a list of field names (e.g. "ControlName") 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. "ControlName") 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 Control) MarshalJSON() ([]byte, error) { + type NoMethod Control + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // Cve: CVE stands for Common Vulnerabilities and Exposures. Information from // the CVE record (https://www.cve.org/ResourcesSupport/Glossary) that // describes this vulnerability. @@ -2469,6 +2555,8 @@ type Finding struct { // CloudDlpInspection: Cloud Data Loss Prevention (Cloud DLP) inspection // results that are associated with the finding. CloudDlpInspection *CloudDlpInspection `json:"cloudDlpInspection,omitempty"` + // ComplianceDetails: Details about the compliance implications of the finding. + ComplianceDetails *ComplianceDetails `json:"complianceDetails,omitempty"` // Compliances: Contains compliance information for security standards // associated to the finding. Compliances []*Compliance `json:"compliances,omitempty"` @@ -2745,6 +2833,55 @@ func (s Folder) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// Framework: Compliance framework associated with the finding. +type Framework struct { + // Category: Category of the framework associated with the finding. E.g. + // Security Benchmark, or Assured Workloads + // + // Possible values: + // "FRAMEWORK_CATEGORY_UNSPECIFIED" - Default value. This value is unused. + // "SECURITY_BENCHMARKS" - Security Benchmarks framework + // "ASSURED_WORKLOADS" - Assured Workloads framework + // "DATA_SECURITY" - Data Security framework + // "GOOGLE_BEST_PRACTICES" - Google Best Practices framework + Category []string `json:"category,omitempty"` + // Controls: The controls associated with the framework. + Controls []*Control `json:"controls,omitempty"` + // DisplayName: Display name of the framework. For a standard framework, this + // will look like e.g. PCI DSS 3.2.1, whereas for a custom framework it can be + // a user defined string like MyFramework + DisplayName string `json:"displayName,omitempty"` + // Name: Name of the framework associated with the finding + Name string `json:"name,omitempty"` + // Type: Type of the framework associated with the finding, to specify whether + // the framework is built-in (pre-defined and immutable) or a custom framework + // defined by the customer (equivalent to security posture) + // + // Possible values: + // "FRAMEWORK_TYPE_UNSPECIFIED" - Default value. This value is unused. + // "FRAMEWORK_TYPE_BUILT_IN" - The framework is a built-in framework if it is + // created and managed by GCP. + // "FRAMEWORK_TYPE_CUSTOM" - The framework is a custom framework if it is + // created and managed by the user. + Type string `json:"type,omitempty"` + // ForceSendFields is a list of field names (e.g. "Category") 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. "Category") 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 Framework) MarshalJSON() ([]byte, error) { + type NoMethod Framework + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GcpMetadata: Google Cloud metadata associated with the resource. Only // applicable if the finding's cloud provider is Google Cloud. type GcpMetadata struct { @@ -4688,6 +4825,40 @@ func (s GoogleCloudSecuritycenterV2CloudArmor) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudSecuritycenterV2CloudControl: CloudControl associated with the +// finding. +type GoogleCloudSecuritycenterV2CloudControl struct { + // CloudControlName: Name of the CloudControl associated with the finding. + CloudControlName string `json:"cloudControlName,omitempty"` + // PolicyType: Policy type of the CloudControl + PolicyType string `json:"policyType,omitempty"` + // Type: Type of cloud control. + // + // Possible values: + // "CLOUD_CONTROL_TYPE_UNSPECIFIED" - Unspecified. + // "BUILT_IN" - Built in Cloud Control. + // "CUSTOM" - Custom Cloud Control. + Type string `json:"type,omitempty"` + // Version: Version of the Cloud Control + Version int64 `json:"version,omitempty"` + // ForceSendFields is a list of field names (e.g. "CloudControlName") 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. "CloudControlName") 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 GoogleCloudSecuritycenterV2CloudControl) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudSecuritycenterV2CloudControl + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudSecuritycenterV2CloudDlpDataProfile: The data profile // (https://cloud.google.com/dlp/docs/data-profiles) associated with the // finding. @@ -4819,6 +4990,36 @@ func (s GoogleCloudSecuritycenterV2Compliance) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudSecuritycenterV2ComplianceDetails: Compliance Details associated +// with the finding. +type GoogleCloudSecuritycenterV2ComplianceDetails struct { + // CloudControl: CloudControl associated with the finding + CloudControl *GoogleCloudSecuritycenterV2CloudControl `json:"cloudControl,omitempty"` + // CloudControlDeploymentNames: Cloud Control Deployments associated with the + // finding. For example, + // organizations/123/locations/global/cloudControlDeployments/deploymentIdentifi + // er + CloudControlDeploymentNames []string `json:"cloudControlDeploymentNames,omitempty"` + // Frameworks: Details of Frameworks associated with the finding + Frameworks []*GoogleCloudSecuritycenterV2Framework `json:"frameworks,omitempty"` + // ForceSendFields is a list of field names (e.g. "CloudControl") 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. "CloudControl") 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 GoogleCloudSecuritycenterV2ComplianceDetails) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudSecuritycenterV2ComplianceDetails + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudSecuritycenterV2Connection: Contains information about the IP // connection associated with the finding. type GoogleCloudSecuritycenterV2Connection struct { @@ -4937,6 +5138,31 @@ func (s GoogleCloudSecuritycenterV2Container) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudSecuritycenterV2Control: Compliance control associated with the +// finding. +type GoogleCloudSecuritycenterV2Control struct { + // ControlName: Name of the Control + ControlName string `json:"controlName,omitempty"` + // DisplayName: Display name of the control. For example, AU-02. + DisplayName string `json:"displayName,omitempty"` + // ForceSendFields is a list of field names (e.g. "ControlName") 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. "ControlName") 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 GoogleCloudSecuritycenterV2Control) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudSecuritycenterV2Control + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudSecuritycenterV2Cve: CVE stands for Common Vulnerabilities and // Exposures. Information from the CVE record // (https://www.cve.org/ResourcesSupport/Glossary) that describes this @@ -5792,6 +6018,8 @@ type GoogleCloudSecuritycenterV2Finding struct { // CloudDlpInspection: Cloud Data Loss Prevention (Cloud DLP) inspection // results that are associated with the finding. CloudDlpInspection *GoogleCloudSecuritycenterV2CloudDlpInspection `json:"cloudDlpInspection,omitempty"` + // ComplianceDetails: Details about the compliance implications of the finding. + ComplianceDetails *GoogleCloudSecuritycenterV2ComplianceDetails `json:"complianceDetails,omitempty"` // Compliances: Contains compliance information for security standards // associated to the finding. Compliances []*GoogleCloudSecuritycenterV2Compliance `json:"compliances,omitempty"` @@ -6078,6 +6306,56 @@ func (s GoogleCloudSecuritycenterV2Folder) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudSecuritycenterV2Framework: Compliance framework associated with +// the finding. +type GoogleCloudSecuritycenterV2Framework struct { + // Category: Category of the framework associated with the finding. E.g. + // Security Benchmark, or Assured Workloads + // + // Possible values: + // "FRAMEWORK_CATEGORY_UNSPECIFIED" - Default value. This value is unused. + // "SECURITY_BENCHMARKS" - Security Benchmarks framework + // "ASSURED_WORKLOADS" - Assured Workloads framework + // "DATA_SECURITY" - Data Security framework + // "GOOGLE_BEST_PRACTICES" - Google Best Practices framework + Category []string `json:"category,omitempty"` + // Controls: The controls associated with the framework. + Controls []*GoogleCloudSecuritycenterV2Control `json:"controls,omitempty"` + // DisplayName: Display name of the framework. For a standard framework, this + // will look like e.g. PCI DSS 3.2.1, whereas for a custom framework it can be + // a user defined string like MyFramework + DisplayName string `json:"displayName,omitempty"` + // Name: Name of the framework associated with the finding + Name string `json:"name,omitempty"` + // Type: Type of the framework associated with the finding, to specify whether + // the framework is built-in (pre-defined and immutable) or a custom framework + // defined by the customer (equivalent to security posture) + // + // Possible values: + // "FRAMEWORK_TYPE_UNSPECIFIED" - Default value. This value is unused. + // "FRAMEWORK_TYPE_BUILT_IN" - The framework is a built-in framework if it is + // created and managed by GCP. + // "FRAMEWORK_TYPE_CUSTOM" - The framework is a custom framework if it is + // created and managed by the user. + Type string `json:"type,omitempty"` + // ForceSendFields is a list of field names (e.g. "Category") 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. "Category") 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 GoogleCloudSecuritycenterV2Framework) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudSecuritycenterV2Framework + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudSecuritycenterV2Geolocation: Represents a geographical location // for a given access. type GoogleCloudSecuritycenterV2Geolocation struct { @@ -7925,7 +8203,7 @@ type GoogleCloudSecuritycenterV2Resource struct { CloudProvider string `json:"cloudProvider,omitempty"` // DisplayName: The human readable name of the resource. DisplayName string `json:"displayName,omitempty"` - // GcpMetadata: The GCP metadata associated with the finding. + // GcpMetadata: The Google Cloud metadata associated with the finding. GcpMetadata *GcpMetadata `json:"gcpMetadata,omitempty"` // Location: The region or location of the service (if applicable). Location string `json:"location,omitempty"` diff --git a/texttospeech/v1/texttospeech-api.json b/texttospeech/v1/texttospeech-api.json index e86d3dc0393..4106c09c5c3 100644 --- a/texttospeech/v1/texttospeech-api.json +++ b/texttospeech/v1/texttospeech-api.json @@ -318,7 +318,7 @@ } } }, - "revision": "20250612", + "revision": "20250716", "rootUrl": "https://texttospeech.googleapis.com/", "schemas": { "AdvancedVoiceOptions": { @@ -349,7 +349,7 @@ "M4A" ], "enumDescriptions": [ - "Not specified. Will return result google.rpc.Code.INVALID_ARGUMENT.", + "Not specified. Only used by GenerateVoiceCloningKey. Otherwise, will return result google.rpc.Code.INVALID_ARGUMENT.", "Uncompressed 16-bit signed little-endian samples (Linear PCM). Audio content returned as LINEAR16 also contains a WAV header.", "MP3 audio at 32kbps.", "Opus encoded audio wrapped in an ogg container. The result is a file which can be played natively on Android, and in browsers (at least Chrome and Firefox). The quality of the encoding is considerably higher than MP3 while using approximately the same bitrate.", diff --git a/texttospeech/v1/texttospeech-gen.go b/texttospeech/v1/texttospeech-gen.go index 701c7b45d9e..1832dcdf760 100644 --- a/texttospeech/v1/texttospeech-gen.go +++ b/texttospeech/v1/texttospeech-gen.go @@ -253,7 +253,8 @@ type AudioConfig struct { // AudioEncoding: Required. The format of the audio byte stream. // // Possible values: - // "AUDIO_ENCODING_UNSPECIFIED" - Not specified. Will return result + // "AUDIO_ENCODING_UNSPECIFIED" - Not specified. Only used by + // GenerateVoiceCloningKey. Otherwise, will return result // google.rpc.Code.INVALID_ARGUMENT. // "LINEAR16" - Uncompressed 16-bit signed little-endian samples (Linear // PCM). Audio content returned as LINEAR16 also contains a WAV header. diff --git a/texttospeech/v1beta1/texttospeech-api.json b/texttospeech/v1beta1/texttospeech-api.json index fd81ec48b48..e75c93dd9c3 100644 --- a/texttospeech/v1beta1/texttospeech-api.json +++ b/texttospeech/v1beta1/texttospeech-api.json @@ -261,7 +261,7 @@ } } }, - "revision": "20250612", + "revision": "20250716", "rootUrl": "https://texttospeech.googleapis.com/", "schemas": { "AdvancedVoiceOptions": { @@ -293,7 +293,7 @@ "M4A" ], "enumDescriptions": [ - "Not specified. Will return result google.rpc.Code.INVALID_ARGUMENT.", + "Not specified. Only used by GenerateVoiceCloningKey. Otherwise, will return result google.rpc.Code.INVALID_ARGUMENT.", "Uncompressed 16-bit signed little-endian samples (Linear PCM). Audio content returned as LINEAR16 also contains a WAV header.", "MP3 audio at 32kbps.", "MP3 at 64kbps.", diff --git a/texttospeech/v1beta1/texttospeech-gen.go b/texttospeech/v1beta1/texttospeech-gen.go index cf697a77ef8..9092486e6d0 100644 --- a/texttospeech/v1beta1/texttospeech-gen.go +++ b/texttospeech/v1beta1/texttospeech-gen.go @@ -241,7 +241,8 @@ type AudioConfig struct { // AudioEncoding: Required. The format of the audio byte stream. // // Possible values: - // "AUDIO_ENCODING_UNSPECIFIED" - Not specified. Will return result + // "AUDIO_ENCODING_UNSPECIFIED" - Not specified. Only used by + // GenerateVoiceCloningKey. Otherwise, will return result // google.rpc.Code.INVALID_ARGUMENT. // "LINEAR16" - Uncompressed 16-bit signed little-endian samples (Linear // PCM). Audio content returned as LINEAR16 also contains a WAV header. diff --git a/vmmigration/v1/vmmigration-api.json b/vmmigration/v1/vmmigration-api.json index a1a127612a0..04f72f52587 100644 --- a/vmmigration/v1/vmmigration-api.json +++ b/vmmigration/v1/vmmigration-api.json @@ -2254,7 +2254,7 @@ } } }, - "revision": "20250701", + "revision": "20250717", "rootUrl": "https://vmmigration.googleapis.com/", "schemas": { "AccessKeyCredentials": { @@ -3321,7 +3321,7 @@ "type": "boolean" }, "serviceAccount": { - "description": "The service account to associate the VM with.", + "description": "Optional. The service account to associate the VM with.", "type": "string" }, "targetProject": { diff --git a/vmmigration/v1/vmmigration-gen.go b/vmmigration/v1/vmmigration-gen.go index 789a3b02844..2e1b8009318 100644 --- a/vmmigration/v1/vmmigration-gen.go +++ b/vmmigration/v1/vmmigration-gen.go @@ -1258,7 +1258,7 @@ type ComputeEngineTargetDefaults struct { // SecureBoot: Defines whether the instance has Secure Boot enabled. This can // be set to true only if the VM boot option is EFI. SecureBoot bool `json:"secureBoot,omitempty"` - // ServiceAccount: The service account to associate the VM with. + // ServiceAccount: Optional. The service account to associate the VM with. ServiceAccount string `json:"serviceAccount,omitempty"` // TargetProject: The full path of the resource of type TargetProject which // represents the Compute Engine project in which to create this VM. diff --git a/vmmigration/v1alpha1/vmmigration-api.json b/vmmigration/v1alpha1/vmmigration-api.json index 51009685056..854e45623eb 100644 --- a/vmmigration/v1alpha1/vmmigration-api.json +++ b/vmmigration/v1alpha1/vmmigration-api.json @@ -2254,7 +2254,7 @@ } } }, - "revision": "20250701", + "revision": "20250717", "rootUrl": "https://vmmigration.googleapis.com/", "schemas": { "AccessKeyCredentials": { @@ -3333,7 +3333,7 @@ "type": "boolean" }, "serviceAccount": { - "description": "The service account to associate the VM with.", + "description": "Optional. The service account to associate the VM with.", "type": "string" }, "targetProject": { diff --git a/vmmigration/v1alpha1/vmmigration-gen.go b/vmmigration/v1alpha1/vmmigration-gen.go index b8e60598c1d..1cbd1a8a034 100644 --- a/vmmigration/v1alpha1/vmmigration-gen.go +++ b/vmmigration/v1alpha1/vmmigration-gen.go @@ -1264,7 +1264,7 @@ type ComputeEngineTargetDefaults struct { // SecureBoot: Defines whether the instance has Secure Boot enabled. This can // be set to true only if the VM boot option is EFI. SecureBoot bool `json:"secureBoot,omitempty"` - // ServiceAccount: The service account to associate the VM with. + // ServiceAccount: Optional. The service account to associate the VM with. ServiceAccount string `json:"serviceAccount,omitempty"` // TargetProject: The full path of the resource of type TargetProject which // represents the Compute Engine project in which to create this VM. diff --git a/workstations/v1beta/workstations-api.json b/workstations/v1beta/workstations-api.json index 15ba594a9a1..d65be5cee27 100644 --- a/workstations/v1beta/workstations-api.json +++ b/workstations/v1beta/workstations-api.json @@ -1142,7 +1142,7 @@ } } }, - "revision": "20250625", + "revision": "20250716", "rootUrl": "https://workstations.googleapis.com/", "schemas": { "Accelerator": { @@ -2296,6 +2296,11 @@ "description": "Output only. Boost configuration ID.", "readOnly": true, "type": "string" + }, + "running": { + "description": "Output only. Whether or not the current workstation is actively boosted with this id.", + "readOnly": true, + "type": "boolean" } }, "type": "object" diff --git a/workstations/v1beta/workstations-gen.go b/workstations/v1beta/workstations-gen.go index 8bd84eb3392..06d3a2cffb6 100644 --- a/workstations/v1beta/workstations-gen.go +++ b/workstations/v1beta/workstations-gen.go @@ -1944,6 +1944,9 @@ func (s Workstation) MarshalJSON() ([]byte, error) { type WorkstationBoostConfig struct { // Id: Output only. Boost configuration ID. Id string `json:"id,omitempty"` + // Running: Output only. Whether or not the current workstation is actively + // boosted with this id. + Running bool `json:"running,omitempty"` // ForceSendFields is a list of field names (e.g. "Id") to unconditionally // include in API requests. By default, fields with empty or default values are // omitted from API requests. See From e6b1c8715fbffd4598a9c80c21c274f858ea2cfe Mon Sep 17 00:00:00 2001 From: Yoshi Automation Bot Date: Fri, 25 Jul 2025 00:38:30 -0700 Subject: [PATCH 03/10] feat(all): auto-regenerate discovery clients (#3244) --- apigee/v1/apigee-api.json | 12 +- apigee/v1/apigee-gen.go | 15 +- cloudbuild/v1/cloudbuild-api.json | 4 +- cloudbuild/v1/cloudbuild-gen.go | 4 +- cloudbuild/v2/cloudbuild-api.json | 27 +- cloudbuild/v2/cloudbuild-gen.go | 28 -- .../v1/contactcenterinsights-api.json | 27 +- .../v1/contactcenterinsights-gen.go | 56 +++- content/v2.1/content-api.json | 4 +- content/v2.1/content-gen.go | 3 +- fcm/v1/fcm-api.json | 6 +- fcm/v1/fcm-gen.go | 5 +- file/v1beta1/file-api.json | 8 +- file/v1beta1/file-gen.go | 2 + gkehub/v1beta/gkehub-api.json | 20 +- gkehub/v1beta/gkehub-gen.go | 6 + gkehub/v2/gkehub-api.json | 20 +- gkehub/v2/gkehub-gen.go | 6 + gkehub/v2alpha/gkehub-api.json | 20 +- gkehub/v2alpha/gkehub-gen.go | 6 + .../v1/mybusinessbusinessinformation-api.json | 7 +- .../v1/mybusinessbusinessinformation-gen.go | 2 + .../v1/networkmanagement-api.json | 11 +- networkmanagement/v1/networkmanagement-gen.go | 5 +- .../v1beta1/securitycenter-api.json | 274 ++++++++++++++++- securitycenter/v1beta1/securitycenter-gen.go | 280 +++++++++++++++++- .../v1/servicenetworking-api.json | 22 +- servicenetworking/v1/servicenetworking-gen.go | 47 ++- .../v1beta/servicenetworking-api.json | 22 +- .../v1beta/servicenetworking-gen.go | 47 ++- 30 files changed, 825 insertions(+), 171 deletions(-) diff --git a/apigee/v1/apigee-api.json b/apigee/v1/apigee-api.json index ba5a3a3d3cf..fea4e5a73c1 100644 --- a/apigee/v1/apigee-api.json +++ b/apigee/v1/apigee-api.json @@ -5321,7 +5321,7 @@ ], "parameters": { "name": { - "description": "Required. The name of the debug session to retrieve. Must be of the form: `organizations/{organization}/environments/{environment}/apis/{api}/revisions/{revision}/debugsessions/{session}`. If the API proxy resource has the `space` attribute set, IAM permissions are checked differently . To learn more, read the [Apigee Spaces Overview](https://cloud.google.com/apigee/docs/api-platform/system-administration/spaces/apigee-spaces-overview).", + "description": "Required. The name of the debug session to retrieve. Must be of the form: `organizations/{organization}/environments/{environment}/apis/{api}/revisions/{revision}/debugsessions/{debug_session}`. If the API proxy resource has the `space` attribute set, IAM permissions are checked differently . To learn more, read the [Apigee Spaces Overview](https://cloud.google.com/apigee/docs/api-platform/system-administration/spaces/apigee-spaces-overview).", "location": "path", "pattern": "^organizations/[^/]+/environments/[^/]+/apis/[^/]+/revisions/[^/]+/debugsessions/[^/]+$", "required": true, @@ -5346,13 +5346,13 @@ ], "parameters": { "pageSize": { - "description": "Maximum number of debug sessions to return. The page size defaults to 25.", + "description": "Optional. Maximum number of debug sessions to return. The page size defaults to 25.", "format": "int32", "location": "query", "type": "integer" }, "pageToken": { - "description": "Page token, returned from a previous ListDebugSessions call, that you can use to retrieve the next page.", + "description": "Optional. Page token, returned from a previous ListDebugSessions call, that you can use to retrieve the next page.", "location": "query", "type": "string" }, @@ -5386,7 +5386,7 @@ ], "parameters": { "name": { - "description": "Required. The name of the debug session transaction. Must be of the form: `organizations/{organization}/environments/{environment}/apis/{api}/revisions/{revision}/debugsessions/{session}/data/{transaction}`. If the API proxy resource has the `space` attribute set, IAM permissions are checked differently . To learn more, read the [Apigee Spaces Overview](https://cloud.google.com/apigee/docs/api-platform/system-administration/spaces/apigee-spaces-overview).", + "description": "Required. The name of the debug session transaction. Must be of the form: `organizations/{organization}/environments/{environment}/apis/{api}/revisions/{revision}/debugsessions/{debug_session}/data/{transaction}`. If the API proxy resource has the `space` attribute set, IAM permissions are checked differently . To learn more, read the [Apigee Spaces Overview](https://cloud.google.com/apigee/docs/api-platform/system-administration/spaces/apigee-spaces-overview).", "location": "path", "pattern": "^organizations/[^/]+/environments/[^/]+/apis/[^/]+/revisions/[^/]+/debugsessions/[^/]+/data/[^/]+$", "required": true, @@ -9735,7 +9735,7 @@ "type": "string" }, "updateMask": { - "description": "Optional. The list of fields to update. Valid fields to update are `profile`, `scope`, `include_all_resources`, `include`, and `exclude`.", + "description": "Optional. The list of fields to update. Valid fields to update are `include_all_resources` and `include`.", "format": "google-fieldmask", "location": "query", "type": "string" @@ -11127,7 +11127,7 @@ } } }, - "revision": "20250701", + "revision": "20250722", "rootUrl": "https://apigee.googleapis.com/", "schemas": { "EdgeConfigstoreBundleBadBundle": { diff --git a/apigee/v1/apigee-gen.go b/apigee/v1/apigee-gen.go index 4cb3c3b4949..a619bee14bd 100644 --- a/apigee/v1/apigee-gen.go +++ b/apigee/v1/apigee-gen.go @@ -32041,9 +32041,9 @@ type OrganizationsEnvironmentsApisRevisionsDebugsessionsGetCall struct { // // - name: The name of the debug session to retrieve. Must be of the form: // `organizations/{organization}/environments/{environment}/apis/{api}/revisio -// ns/{revision}/debugsessions/{session}`. If the API proxy resource has the -// `space` attribute set, IAM permissions are checked differently . To learn -// more, read the Apigee Spaces Overview +// ns/{revision}/debugsessions/{debug_session}`. If the API proxy resource +// has the `space` attribute set, IAM permissions are checked differently . +// To learn more, read the Apigee Spaces Overview // (https://cloud.google.com/apigee/docs/api-platform/system-administration/spaces/apigee-spaces-overview). func (r *OrganizationsEnvironmentsApisRevisionsDebugsessionsService) Get(name string) *OrganizationsEnvironmentsApisRevisionsDebugsessionsGetCall { c := &OrganizationsEnvironmentsApisRevisionsDebugsessionsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} @@ -32309,9 +32309,9 @@ type OrganizationsEnvironmentsApisRevisionsDebugsessionsDataGetCall struct { // // - name: The name of the debug session transaction. Must be of the form: // `organizations/{organization}/environments/{environment}/apis/{api}/revisio -// ns/{revision}/debugsessions/{session}/data/{transaction}`. If the API -// proxy resource has the `space` attribute set, IAM permissions are checked -// differently . To learn more, read the Apigee Spaces Overview +// ns/{revision}/debugsessions/{debug_session}/data/{transaction}`. If the +// API proxy resource has the `space` attribute set, IAM permissions are +// checked differently . To learn more, read the Apigee Spaces Overview // (https://cloud.google.com/apigee/docs/api-platform/system-administration/spaces/apigee-spaces-overview). func (r *OrganizationsEnvironmentsApisRevisionsDebugsessionsDataService) Get(name string) *OrganizationsEnvironmentsApisRevisionsDebugsessionsDataGetCall { c := &OrganizationsEnvironmentsApisRevisionsDebugsessionsDataGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} @@ -48101,8 +48101,7 @@ func (r *OrganizationsSecurityMonitoringConditionsService) Patch(name string, go } // UpdateMask sets the optional parameter "updateMask": The list of fields to -// update. Valid fields to update are `profile`, `scope`, -// `include_all_resources`, `include`, and `exclude`. +// update. Valid fields to update are `include_all_resources` and `include`. func (c *OrganizationsSecurityMonitoringConditionsPatchCall) UpdateMask(updateMask string) *OrganizationsSecurityMonitoringConditionsPatchCall { c.urlParams_.Set("updateMask", updateMask) return c diff --git a/cloudbuild/v1/cloudbuild-api.json b/cloudbuild/v1/cloudbuild-api.json index 8a5a89f2f0a..106213cf025 100644 --- a/cloudbuild/v1/cloudbuild-api.json +++ b/cloudbuild/v1/cloudbuild-api.json @@ -2573,7 +2573,7 @@ } } }, - "revision": "20250609", + "revision": "20250718", "rootUrl": "https://cloudbuild.googleapis.com/", "schemas": { "ApprovalConfig": { @@ -5043,7 +5043,7 @@ "type": "boolean" }, "routeAllTraffic": { - "description": "Immutable. Route all traffic through PSC interface. Enable this if you want full control of traffic in the private pool. Configure Cloud NAT for the subnet of network attachment if you need to access public Internet. If false, Only route private IPs, e.g. 10.0.0.0/8, 172.16.0.0/12, and 192.168.0.0/16 through PSC interface.", + "description": "Immutable. Route all traffic through PSC interface. Enable this if you want full control of traffic in the private pool. Configure Cloud NAT for the subnet of network attachment if you need to access public Internet. If false, Only route RFC 1918 (10.0.0.0/8, 172.16.0.0/12, and 192.168.0.0/16) and RFC 6598 (100.64.0.0/10) through PSC interface.", "type": "boolean" } }, diff --git a/cloudbuild/v1/cloudbuild-gen.go b/cloudbuild/v1/cloudbuild-gen.go index c3fa0a0647a..b6eb9ea9da6 100644 --- a/cloudbuild/v1/cloudbuild-gen.go +++ b/cloudbuild/v1/cloudbuild-gen.go @@ -3407,8 +3407,8 @@ type PrivateServiceConnect struct { // RouteAllTraffic: Immutable. Route all traffic through PSC interface. Enable // this if you want full control of traffic in the private pool. Configure // Cloud NAT for the subnet of network attachment if you need to access public - // Internet. If false, Only route private IPs, e.g. 10.0.0.0/8, 172.16.0.0/12, - // and 192.168.0.0/16 through PSC interface. + // Internet. If false, Only route RFC 1918 (10.0.0.0/8, 172.16.0.0/12, and + // 192.168.0.0/16) and RFC 6598 (100.64.0.0/10) through PSC interface. RouteAllTraffic bool `json:"routeAllTraffic,omitempty"` // ForceSendFields is a list of field names (e.g. "NetworkAttachment") to // unconditionally include in API requests. By default, fields with empty or diff --git a/cloudbuild/v2/cloudbuild-api.json b/cloudbuild/v2/cloudbuild-api.json index 152890e8d06..259a85800b1 100644 --- a/cloudbuild/v2/cloudbuild-api.json +++ b/cloudbuild/v2/cloudbuild-api.json @@ -1087,7 +1087,7 @@ } } }, - "revision": "20250418", + "revision": "20250718", "rootUrl": "https://cloudbuild.googleapis.com/", "schemas": { "AuditConfig": { @@ -1253,27 +1253,6 @@ "properties": {}, "type": "object" }, - "Capabilities": { - "description": "Capabilities adds and removes POSIX capabilities from running containers.", - "id": "Capabilities", - "properties": { - "add": { - "description": "Optional. Added capabilities +optional", - "items": { - "type": "string" - }, - "type": "array" - }, - "drop": { - "description": "Optional. Removed capabilities +optional", - "items": { - "type": "string" - }, - "type": "array" - } - }, - "type": "object" - }, "ChildStatusReference": { "description": "ChildStatusReference is used to point to the statuses of individual TaskRuns and Runs within this PipelineRun.", "id": "ChildStatusReference", @@ -2809,10 +2788,6 @@ "description": "Optional. AllowPrivilegeEscalation controls whether a process can gain more privileges than its parent process. This bool directly controls if the no_new_privs flag will be set on the container process. AllowPrivilegeEscalation is true always when the container is: 1) run as Privileged 2) has CAP_SYS_ADMIN Note that this field cannot be set when spec.os.name is windows. +optional", "type": "boolean" }, - "capabilities": { - "$ref": "Capabilities", - "description": "Optional. Adds and removes POSIX capabilities from running containers." - }, "privileged": { "description": "Run container in privileged mode.", "type": "boolean" diff --git a/cloudbuild/v2/cloudbuild-gen.go b/cloudbuild/v2/cloudbuild-gen.go index 5ec969c4157..52ec42fd6ea 100644 --- a/cloudbuild/v2/cloudbuild-gen.go +++ b/cloudbuild/v2/cloudbuild-gen.go @@ -519,31 +519,6 @@ func (s BitbucketDataCenterConfig) MarshalJSON() ([]byte, error) { type CancelOperationRequest struct { } -// Capabilities: Capabilities adds and removes POSIX capabilities from running -// containers. -type Capabilities struct { - // Add: Optional. Added capabilities +optional - Add []string `json:"add,omitempty"` - // Drop: Optional. Removed capabilities +optional - Drop []string `json:"drop,omitempty"` - // ForceSendFields is a list of field names (e.g. "Add") 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. "Add") 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 Capabilities) MarshalJSON() ([]byte, error) { - type NoMethod Capabilities - return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) -} - // ChildStatusReference: ChildStatusReference is used to point to the statuses // of individual TaskRuns and Runs within this PipelineRun. type ChildStatusReference struct { @@ -2259,9 +2234,6 @@ type SecurityContext struct { // run as Privileged 2) has CAP_SYS_ADMIN Note that this field cannot be set // when spec.os.name is windows. +optional AllowPrivilegeEscalation bool `json:"allowPrivilegeEscalation,omitempty"` - // Capabilities: Optional. Adds and removes POSIX capabilities from running - // containers. - Capabilities *Capabilities `json:"capabilities,omitempty"` // Privileged: Run container in privileged mode. Privileged bool `json:"privileged,omitempty"` // RunAsGroup: Optional. The GID to run the entrypoint of the container diff --git a/contactcenterinsights/v1/contactcenterinsights-api.json b/contactcenterinsights/v1/contactcenterinsights-api.json index 1009e501c5e..6163951f572 100644 --- a/contactcenterinsights/v1/contactcenterinsights-api.json +++ b/contactcenterinsights/v1/contactcenterinsights-api.json @@ -2335,6 +2335,11 @@ "name" ], "parameters": { + "allowMissing": { + "description": "Optional. Defaults to false. If set to true, and the conversation is not found, a new conversation will be created. In this situation, `update_mask` is ignored.", + "location": "query", + "type": "boolean" + }, "name": { "description": "Immutable. The resource name of the conversation. Format: projects/{project}/locations/{location}/conversations/{conversation}", "location": "path", @@ -5300,7 +5305,7 @@ } } }, - "revision": "20250711", + "revision": "20250721", "rootUrl": "https://contactcenterinsights.googleapis.com/", "schemas": { "GoogleCloudContactcenterinsightsV1Analysis": { @@ -7890,11 +7895,11 @@ "id": "GoogleCloudContactcenterinsightsV1IngestConversationsRequestGcsSource", "properties": { "audioBucketUri": { - "description": "Optional. The Cloud Storage path to the conversation audio file if already transcribed. Note that: [1] Don't set this field if the audio is not transcribed. [2] Audio files and transcript files must be in separate buckets / folders. [3] A source file and its corresponding audio file must share the same name to be properly ingested, E.g. `gs://bucket/transcript/conversation1.json` and `gs://bucket/audio/conversation1.mp3`.", + "description": "Optional. The Cloud Storage path to the conversation audio file. Note that: [1] Audio files will be transcribed if not already. [2] Audio files and transcript files must be in separate buckets / folders. [3] A source file and its corresponding audio file must share the same name to be properly ingested, E.g. `gs://bucket/transcript/conversation1.json` and `gs://bucket/audio/conversation1.mp3`.", "type": "string" }, "bucketObjectType": { - "description": "Optional. Specifies the type of the objects in `bucket_uri`.", + "description": "Optional. Specifies the type of the objects in `bucket_uri`. Avoid passing this. This is inferred from the `transcript_bucket_uri`, `audio_bucket_uri`.", "enum": [ "BUCKET_OBJECT_TYPE_UNSPECIFIED", "TRANSCRIPT", @@ -7908,7 +7913,7 @@ "type": "string" }, "bucketUri": { - "description": "Required. The Cloud Storage bucket containing source objects.", + "description": "Optional. The Cloud Storage bucket containing source objects. Avoid passing this. Pass this through one of `transcript_bucket_uri` or `audio_bucket_uri`.", "type": "string" }, "customMetadataKeys": { @@ -7921,6 +7926,10 @@ "metadataBucketUri": { "description": "Optional. The Cloud Storage path to the conversation metadata. Note that: [1] Metadata files are expected to be in JSON format. [2] Metadata and source files (transcripts or audio) must be in separate buckets / folders. [3] A source file and its corresponding metadata file must share the same name to be properly ingested, E.g. `gs://bucket/audio/conversation1.mp3` and `gs://bucket/metadata/conversation1.json`.", "type": "string" + }, + "transcriptBucketUri": { + "description": "Optional. The Cloud Storage path to the conversation transcripts. Note that: [1] Transcript files are expected to be in JSON format. [2] Transcript, audio, metadata files must be in separate buckets / folders. [3] A source file and its corresponding metadata file must share the same name to be properly ingested, E.g. `gs://bucket/audio/conversation1.mp3` and `gs://bucket/metadata/conversation1.json`.", + "type": "string" } }, "type": "object" @@ -12287,11 +12296,11 @@ "id": "GoogleCloudContactcenterinsightsV1alpha1IngestConversationsRequestGcsSource", "properties": { "audioBucketUri": { - "description": "Optional. The Cloud Storage path to the conversation audio file if already transcribed. Note that: [1] Don't set this field if the audio is not transcribed. [2] Audio files and transcript files must be in separate buckets / folders. [3] A source file and its corresponding audio file must share the same name to be properly ingested, E.g. `gs://bucket/transcript/conversation1.json` and `gs://bucket/audio/conversation1.mp3`.", + "description": "Optional. The Cloud Storage path to the conversation audio file. Note that: [1] Audio files will be transcribed if not already. [2] Audio files and transcript files must be in separate buckets / folders. [3] A source file and its corresponding audio file must share the same name to be properly ingested, E.g. `gs://bucket/transcript/conversation1.json` and `gs://bucket/audio/conversation1.mp3`.", "type": "string" }, "bucketObjectType": { - "description": "Optional. Specifies the type of the objects in `bucket_uri`.", + "description": "Optional. Specifies the type of the objects in `bucket_uri`. Avoid passing this. This is inferred from the `transcript_bucket_uri`, `audio_bucket_uri`.", "enum": [ "BUCKET_OBJECT_TYPE_UNSPECIFIED", "TRANSCRIPT", @@ -12305,7 +12314,7 @@ "type": "string" }, "bucketUri": { - "description": "Required. The Cloud Storage bucket containing source objects.", + "description": "Optional. The Cloud Storage bucket containing source objects. Avoid passing this. Pass this through one of `transcript_bucket_uri` or `audio_bucket_uri`.", "type": "string" }, "customMetadataKeys": { @@ -12318,6 +12327,10 @@ "metadataBucketUri": { "description": "Optional. The Cloud Storage path to the conversation metadata. Note that: [1] Metadata files are expected to be in JSON format. [2] Metadata and source files (transcripts or audio) must be in separate buckets / folders. [3] A source file and its corresponding metadata file must share the same name to be properly ingested, E.g. `gs://bucket/audio/conversation1.mp3` and `gs://bucket/metadata/conversation1.json`.", "type": "string" + }, + "transcriptBucketUri": { + "description": "Optional. The Cloud Storage path to the conversation transcripts. Note that: [1] Transcript files are expected to be in JSON format. [2] Transcript, audio, metadata files must be in separate buckets / folders. [3] A source file and its corresponding metadata file must share the same name to be properly ingested, E.g. `gs://bucket/audio/conversation1.mp3` and `gs://bucket/metadata/conversation1.json`.", + "type": "string" } }, "type": "object" diff --git a/contactcenterinsights/v1/contactcenterinsights-gen.go b/contactcenterinsights/v1/contactcenterinsights-gen.go index aa3f40449d6..c0fb805f167 100644 --- a/contactcenterinsights/v1/contactcenterinsights-gen.go +++ b/contactcenterinsights/v1/contactcenterinsights-gen.go @@ -3776,15 +3776,15 @@ func (s GoogleCloudContactcenterinsightsV1IngestConversationsRequestConversation // Configuration for Cloud Storage bucket sources. type GoogleCloudContactcenterinsightsV1IngestConversationsRequestGcsSource struct { // AudioBucketUri: Optional. The Cloud Storage path to the conversation audio - // file if already transcribed. Note that: [1] Don't set this field if the - // audio is not transcribed. [2] Audio files and transcript files must be in - // separate buckets / folders. [3] A source file and its corresponding audio - // file must share the same name to be properly ingested, E.g. - // `gs://bucket/transcript/conversation1.json` and + // file. Note that: [1] Audio files will be transcribed if not already. [2] + // Audio files and transcript files must be in separate buckets / folders. [3] + // A source file and its corresponding audio file must share the same name to + // be properly ingested, E.g. `gs://bucket/transcript/conversation1.json` and // `gs://bucket/audio/conversation1.mp3`. AudioBucketUri string `json:"audioBucketUri,omitempty"` // BucketObjectType: Optional. Specifies the type of the objects in - // `bucket_uri`. + // `bucket_uri`. Avoid passing this. This is inferred from the + // `transcript_bucket_uri`, `audio_bucket_uri`. // // Possible values: // "BUCKET_OBJECT_TYPE_UNSPECIFIED" - The object type is unspecified and will @@ -3792,7 +3792,9 @@ type GoogleCloudContactcenterinsightsV1IngestConversationsRequestGcsSource struc // "TRANSCRIPT" - The object is a transcript. // "AUDIO" - The object is an audio file. BucketObjectType string `json:"bucketObjectType,omitempty"` - // BucketUri: Required. The Cloud Storage bucket containing source objects. + // BucketUri: Optional. The Cloud Storage bucket containing source objects. + // Avoid passing this. Pass this through one of `transcript_bucket_uri` or + // `audio_bucket_uri`. BucketUri string `json:"bucketUri,omitempty"` // CustomMetadataKeys: Optional. Custom keys to extract as conversation labels // from metadata files in `metadata_bucket_uri`. Keys not included in this @@ -3807,6 +3809,14 @@ type GoogleCloudContactcenterinsightsV1IngestConversationsRequestGcsSource struc // `gs://bucket/audio/conversation1.mp3` and // `gs://bucket/metadata/conversation1.json`. MetadataBucketUri string `json:"metadataBucketUri,omitempty"` + // TranscriptBucketUri: Optional. The Cloud Storage path to the conversation + // transcripts. Note that: [1] Transcript files are expected to be in JSON + // format. [2] Transcript, audio, metadata files must be in separate buckets / + // folders. [3] A source file and its corresponding metadata file must share + // the same name to be properly ingested, E.g. + // `gs://bucket/audio/conversation1.mp3` and + // `gs://bucket/metadata/conversation1.json`. + TranscriptBucketUri string `json:"transcriptBucketUri,omitempty"` // ForceSendFields is a list of field names (e.g. "AudioBucketUri") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See @@ -9563,15 +9573,15 @@ func (s GoogleCloudContactcenterinsightsV1alpha1IngestConversationsRequestConver // Configuration for Cloud Storage bucket sources. type GoogleCloudContactcenterinsightsV1alpha1IngestConversationsRequestGcsSource struct { // AudioBucketUri: Optional. The Cloud Storage path to the conversation audio - // file if already transcribed. Note that: [1] Don't set this field if the - // audio is not transcribed. [2] Audio files and transcript files must be in - // separate buckets / folders. [3] A source file and its corresponding audio - // file must share the same name to be properly ingested, E.g. - // `gs://bucket/transcript/conversation1.json` and + // file. Note that: [1] Audio files will be transcribed if not already. [2] + // Audio files and transcript files must be in separate buckets / folders. [3] + // A source file and its corresponding audio file must share the same name to + // be properly ingested, E.g. `gs://bucket/transcript/conversation1.json` and // `gs://bucket/audio/conversation1.mp3`. AudioBucketUri string `json:"audioBucketUri,omitempty"` // BucketObjectType: Optional. Specifies the type of the objects in - // `bucket_uri`. + // `bucket_uri`. Avoid passing this. This is inferred from the + // `transcript_bucket_uri`, `audio_bucket_uri`. // // Possible values: // "BUCKET_OBJECT_TYPE_UNSPECIFIED" - The object type is unspecified and will @@ -9579,7 +9589,9 @@ type GoogleCloudContactcenterinsightsV1alpha1IngestConversationsRequestGcsSource // "TRANSCRIPT" - The object is a transcript. // "AUDIO" - The object is an audio file. BucketObjectType string `json:"bucketObjectType,omitempty"` - // BucketUri: Required. The Cloud Storage bucket containing source objects. + // BucketUri: Optional. The Cloud Storage bucket containing source objects. + // Avoid passing this. Pass this through one of `transcript_bucket_uri` or + // `audio_bucket_uri`. BucketUri string `json:"bucketUri,omitempty"` // CustomMetadataKeys: Optional. Custom keys to extract as conversation labels // from metadata files in `metadata_bucket_uri`. Keys not included in this @@ -9594,6 +9606,14 @@ type GoogleCloudContactcenterinsightsV1alpha1IngestConversationsRequestGcsSource // `gs://bucket/audio/conversation1.mp3` and // `gs://bucket/metadata/conversation1.json`. MetadataBucketUri string `json:"metadataBucketUri,omitempty"` + // TranscriptBucketUri: Optional. The Cloud Storage path to the conversation + // transcripts. Note that: [1] Transcript files are expected to be in JSON + // format. [2] Transcript, audio, metadata files must be in separate buckets / + // folders. [3] A source file and its corresponding metadata file must share + // the same name to be properly ingested, E.g. + // `gs://bucket/audio/conversation1.mp3` and + // `gs://bucket/metadata/conversation1.json`. + TranscriptBucketUri string `json:"transcriptBucketUri,omitempty"` // ForceSendFields is a list of field names (e.g. "AudioBucketUri") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See @@ -19605,6 +19625,14 @@ func (r *ProjectsLocationsConversationsService) Patch(name string, googlecloudco return c } +// AllowMissing sets the optional parameter "allowMissing": Defaults to false. +// If set to true, and the conversation is not found, a new conversation will +// be created. In this situation, `update_mask` is ignored. +func (c *ProjectsLocationsConversationsPatchCall) AllowMissing(allowMissing bool) *ProjectsLocationsConversationsPatchCall { + c.urlParams_.Set("allowMissing", fmt.Sprint(allowMissing)) + return c +} + // UpdateMask sets the optional parameter "updateMask": The list of fields to // be updated. All possible fields can be updated by passing `*`, or a subset // of the following updateable fields can be provided: * `agent_id` * diff --git a/content/v2.1/content-api.json b/content/v2.1/content-api.json index df3b2efba78..6e4b91eafec 100644 --- a/content/v2.1/content-api.json +++ b/content/v2.1/content-api.json @@ -1457,7 +1457,7 @@ "type": "string" }, "updateMask": { - "description": "Optional. List of fields being updated.", + "description": "Optional. List of fields being updated. The following fields can be updated: `attribution_settings`, `display_name`, `currency_code`.", "format": "google-fieldmask", "location": "query", "type": "string" @@ -4570,7 +4570,7 @@ } } }, - "revision": "20250621", + "revision": "20250723", "rootUrl": "https://shoppingcontent.googleapis.com/", "schemas": { "Account": { diff --git a/content/v2.1/content-gen.go b/content/v2.1/content-gen.go index 83c3c21d1a1..7d84d4e4cdd 100644 --- a/content/v2.1/content-gen.go +++ b/content/v2.1/content-gen.go @@ -17504,7 +17504,8 @@ func (r *ConversionsourcesService) Patch(merchantId int64, conversionSourceId st } // UpdateMask sets the optional parameter "updateMask": List of fields being -// updated. +// updated. The following fields can be updated: `attribution_settings`, +// `display_name`, `currency_code`. func (c *ConversionsourcesPatchCall) UpdateMask(updateMask string) *ConversionsourcesPatchCall { c.urlParams_.Set("updateMask", updateMask) return c diff --git a/fcm/v1/fcm-api.json b/fcm/v1/fcm-api.json index 6feb64a3bda..0003ca39809 100644 --- a/fcm/v1/fcm-api.json +++ b/fcm/v1/fcm-api.json @@ -146,7 +146,7 @@ } } }, - "revision": "20250610", + "revision": "20250722", "rootUrl": "https://fcm.googleapis.com/", "schemas": { "AndroidConfig": { @@ -154,7 +154,7 @@ "id": "AndroidConfig", "properties": { "bandwidthConstrainedOk": { - "description": "Optional. If set to true, messages will be allowed to be delivered to the app while the device is in bandwidth constrained mode.", + "description": "Optional. If set to true, messages will be allowed to be delivered to the app while the device is in bandwidth constrained mode. This should only be enabled when the app has been tested to properly handle messages in bandwidth constrained mode.", "type": "boolean" }, "collapseKey": { @@ -197,7 +197,7 @@ "type": "string" }, "restrictedSatelliteOk": { - "description": "Optional. If set to true, messages will be allowed to be delivered to the app while the device is connected over a restricted satellite network. This should only be enabled for messages that can be handled over a restricted satellite network and only for apps that are allowed to work over a restricted satellite network. Note that the ability of the app to connect to a restricted satellite network is dependent on the carrier's settings and the device model.", + "description": "Optional. If set to true, messages will be allowed to be delivered to the app while the device is connected over a restricted satellite network. This should only be enabled for messages that can be handled over a restricted satellite network and only for apps that are enabled to work over a restricted satellite network. Note that the ability of the app to connect to a restricted satellite network is dependent on the carrier's settings and the device model.", "type": "boolean" }, "ttl": { diff --git a/fcm/v1/fcm-gen.go b/fcm/v1/fcm-gen.go index c97452e5e8b..54ee3566b74 100644 --- a/fcm/v1/fcm-gen.go +++ b/fcm/v1/fcm-gen.go @@ -190,7 +190,8 @@ type ProjectsMessagesService struct { type AndroidConfig struct { // BandwidthConstrainedOk: Optional. If set to true, messages will be allowed // to be delivered to the app while the device is in bandwidth constrained - // mode. + // mode. This should only be enabled when the app has been tested to properly + // handle messages in bandwidth constrained mode. BandwidthConstrainedOk bool `json:"bandwidthConstrainedOk,omitempty"` // CollapseKey: An identifier of a group of messages that can be collapsed, so // that only the last message gets sent when delivery can be resumed. A maximum @@ -234,7 +235,7 @@ type AndroidConfig struct { // be delivered to the app while the device is connected over a restricted // satellite network. This should only be enabled for messages that can be // handled over a restricted satellite network and only for apps that are - // allowed to work over a restricted satellite network. Note that the ability + // enabled to work over a restricted satellite network. Note that the ability // of the app to connect to a restricted satellite network is dependent on the // carrier's settings and the device model. RestrictedSatelliteOk bool `json:"restrictedSatelliteOk,omitempty"` diff --git a/file/v1beta1/file-api.json b/file/v1beta1/file-api.json index b42dcc0ba91..5e312293bca 100644 --- a/file/v1beta1/file-api.json +++ b/file/v1beta1/file-api.json @@ -1075,7 +1075,7 @@ } } }, - "revision": "20250421", + "revision": "20250716", "rootUrl": "https://file.googleapis.com/", "schemas": { "Backup": { @@ -2460,6 +2460,12 @@ "type": "string" }, "type": "array" + }, + "stateUpdateTime": { + "description": "Output only. The time when the replica state was updated.", + "format": "google-datetime", + "readOnly": true, + "type": "string" } }, "type": "object" diff --git a/file/v1beta1/file-gen.go b/file/v1beta1/file-gen.go index 03e15e04961..826f27acd9d 100644 --- a/file/v1beta1/file-gen.go +++ b/file/v1beta1/file-gen.go @@ -1842,6 +1842,8 @@ type ReplicaConfig struct { // "PEER_INSTANCE_UNREACHABLE" - The peer instance is unreachable. // "REMOVE_FAILED" - The remove replica peer instance operation failed. StateReasons []string `json:"stateReasons,omitempty"` + // StateUpdateTime: Output only. The time when the replica state was updated. + StateUpdateTime string `json:"stateUpdateTime,omitempty"` // ForceSendFields is a list of field names (e.g. "LastActiveSyncTime") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See diff --git a/gkehub/v1beta/gkehub-api.json b/gkehub/v1beta/gkehub-api.json index 529781f5d64..2af247960a0 100644 --- a/gkehub/v1beta/gkehub-api.json +++ b/gkehub/v1beta/gkehub-api.json @@ -2117,7 +2117,7 @@ } } }, - "revision": "20250715", + "revision": "20250720", "rootUrl": "https://gkehub.googleapis.com/", "schemas": { "AppDevExperienceFeatureSpec": { @@ -6546,7 +6546,8 @@ "ACTIVE", "STALLED", "NEEDS_ATTENTION", - "DEGRADED" + "DEGRADED", + "DEPROVISIONING" ], "enumDescriptions": [ "Unspecified", @@ -6556,7 +6557,8 @@ "ACTIVE means that the component is ready for use.", "STALLED means that provisioning could not be done.", "NEEDS_ATTENTION means that the component is ready, but some user intervention is required. (For example that the user should migrate workloads to a new control plane revision.)", - "DEGRADED means that the component is ready, but operating in a degraded state." + "DEGRADED means that the component is ready, but operating in a degraded state.", + "DEPROVISIONING means that deprovisioning is in progress." ], "type": "string" } @@ -6584,7 +6586,8 @@ "ACTIVE", "STALLED", "NEEDS_ATTENTION", - "DEGRADED" + "DEGRADED", + "DEPROVISIONING" ], "enumDescriptions": [ "Unspecified", @@ -6594,7 +6597,8 @@ "ACTIVE means that the component is ready for use.", "STALLED means that provisioning could not be done.", "NEEDS_ATTENTION means that the component is ready, but some user intervention is required. (For example that the user should migrate workloads to a new control plane revision.)", - "DEGRADED means that the component is ready, but operating in a degraded state." + "DEGRADED means that the component is ready, but operating in a degraded state.", + "DEPROVISIONING means that deprovisioning is in progress." ], "type": "string" } @@ -6639,12 +6643,14 @@ "enum": [ "MANAGEMENT_UNSPECIFIED", "MANAGEMENT_AUTOMATIC", - "MANAGEMENT_MANUAL" + "MANAGEMENT_MANUAL", + "MANAGEMENT_NOT_INSTALLED" ], "enumDescriptions": [ "Unspecified", "Google should manage my Service Mesh for the cluster.", - "User will manually configure their service mesh components." + "User will manually configure their service mesh components.", + "Google should remove any managed Service Mesh components from this cluster and deprovision any resources." ], "type": "string" } diff --git a/gkehub/v1beta/gkehub-gen.go b/gkehub/v1beta/gkehub-gen.go index a610abc43ee..9ac09e03a3d 100644 --- a/gkehub/v1beta/gkehub-gen.go +++ b/gkehub/v1beta/gkehub-gen.go @@ -5784,6 +5784,8 @@ type ServiceMeshControlPlaneManagement struct { // migrate workloads to a new control plane revision.) // "DEGRADED" - DEGRADED means that the component is ready, but operating in // a degraded state. + // "DEPROVISIONING" - DEPROVISIONING means that deprovisioning is in + // progress. State string `json:"state,omitempty"` // ForceSendFields is a list of field names (e.g. "Details") to unconditionally // include in API requests. By default, fields with empty or default values are @@ -5823,6 +5825,8 @@ type ServiceMeshDataPlaneManagement struct { // migrate workloads to a new control plane revision.) // "DEGRADED" - DEGRADED means that the component is ready, but operating in // a degraded state. + // "DEPROVISIONING" - DEPROVISIONING means that deprovisioning is in + // progress. State string `json:"state,omitempty"` // ForceSendFields is a list of field names (e.g. "Details") to unconditionally // include in API requests. By default, fields with empty or default values are @@ -5873,6 +5877,8 @@ type ServiceMeshMembershipSpec struct { // cluster. // "MANAGEMENT_MANUAL" - User will manually configure their service mesh // components. + // "MANAGEMENT_NOT_INSTALLED" - Google should remove any managed Service Mesh + // components from this cluster and deprovision any resources. Management string `json:"management,omitempty"` // ForceSendFields is a list of field names (e.g. "ConfigApi") to // unconditionally include in API requests. By default, fields with empty or diff --git a/gkehub/v2/gkehub-api.json b/gkehub/v2/gkehub-api.json index 60e9544574c..debf40e19dc 100644 --- a/gkehub/v2/gkehub-api.json +++ b/gkehub/v2/gkehub-api.json @@ -477,7 +477,7 @@ } } }, - "revision": "20250715", + "revision": "20250720", "rootUrl": "https://gkehub.googleapis.com/", "schemas": { "AppDevExperienceState": { @@ -3178,7 +3178,8 @@ "ACTIVE", "STALLED", "NEEDS_ATTENTION", - "DEGRADED" + "DEGRADED", + "DEPROVISIONING" ], "enumDescriptions": [ "Unspecified", @@ -3188,7 +3189,8 @@ "ACTIVE means that the component is ready for use.", "STALLED means that provisioning could not be done.", "NEEDS_ATTENTION means that the component is ready, but some user intervention is required. (For example that the user should migrate workloads to a new control plane revision.)", - "DEGRADED means that the component is ready, but operating in a degraded state." + "DEGRADED means that the component is ready, but operating in a degraded state.", + "DEPROVISIONING means that deprovisioning is in progress." ], "type": "string" } @@ -3216,7 +3218,8 @@ "ACTIVE", "STALLED", "NEEDS_ATTENTION", - "DEGRADED" + "DEGRADED", + "DEPROVISIONING" ], "enumDescriptions": [ "Unspecified", @@ -3226,7 +3229,8 @@ "ACTIVE means that the component is ready for use.", "STALLED means that provisioning could not be done.", "NEEDS_ATTENTION means that the component is ready, but some user intervention is required. (For example that the user should migrate workloads to a new control plane revision.)", - "DEGRADED means that the component is ready, but operating in a degraded state." + "DEGRADED means that the component is ready, but operating in a degraded state.", + "DEPROVISIONING means that deprovisioning is in progress." ], "type": "string" } @@ -3288,12 +3292,14 @@ "enum": [ "MANAGEMENT_UNSPECIFIED", "MANAGEMENT_AUTOMATIC", - "MANAGEMENT_MANUAL" + "MANAGEMENT_MANUAL", + "MANAGEMENT_NOT_INSTALLED" ], "enumDescriptions": [ "Unspecified", "Google should manage my Service Mesh for the cluster.", - "User will manually configure their service mesh components." + "User will manually configure their service mesh components.", + "Google should remove any managed Service Mesh components from this cluster and deprovision any resources." ], "type": "string" } diff --git a/gkehub/v2/gkehub-gen.go b/gkehub/v2/gkehub-gen.go index f1430dd9e7a..91ea749d737 100644 --- a/gkehub/v2/gkehub-gen.go +++ b/gkehub/v2/gkehub-gen.go @@ -3304,6 +3304,8 @@ type ServiceMeshControlPlaneManagement struct { // migrate workloads to a new control plane revision.) // "DEGRADED" - DEGRADED means that the component is ready, but operating in // a degraded state. + // "DEPROVISIONING" - DEPROVISIONING means that deprovisioning is in + // progress. State string `json:"state,omitempty"` // ForceSendFields is a list of field names (e.g. "Details") to unconditionally // include in API requests. By default, fields with empty or default values are @@ -3343,6 +3345,8 @@ type ServiceMeshDataPlaneManagement struct { // migrate workloads to a new control plane revision.) // "DEGRADED" - DEGRADED means that the component is ready, but operating in // a degraded state. + // "DEPROVISIONING" - DEPROVISIONING means that deprovisioning is in + // progress. State string `json:"state,omitempty"` // ForceSendFields is a list of field names (e.g. "Details") to unconditionally // include in API requests. By default, fields with empty or default values are @@ -3405,6 +3409,8 @@ type ServiceMeshSpec struct { // cluster. // "MANAGEMENT_MANUAL" - User will manually configure their service mesh // components. + // "MANAGEMENT_NOT_INSTALLED" - Google should remove any managed Service Mesh + // components from this cluster and deprovision any resources. Management string `json:"management,omitempty"` // ForceSendFields is a list of field names (e.g. "ConfigApi") to // unconditionally include in API requests. By default, fields with empty or diff --git a/gkehub/v2alpha/gkehub-api.json b/gkehub/v2alpha/gkehub-api.json index cedf7504209..f6f7abffd2f 100644 --- a/gkehub/v2alpha/gkehub-api.json +++ b/gkehub/v2alpha/gkehub-api.json @@ -477,7 +477,7 @@ } } }, - "revision": "20250715", + "revision": "20250720", "rootUrl": "https://gkehub.googleapis.com/", "schemas": { "AppDevExperienceState": { @@ -3178,7 +3178,8 @@ "ACTIVE", "STALLED", "NEEDS_ATTENTION", - "DEGRADED" + "DEGRADED", + "DEPROVISIONING" ], "enumDescriptions": [ "Unspecified", @@ -3188,7 +3189,8 @@ "ACTIVE means that the component is ready for use.", "STALLED means that provisioning could not be done.", "NEEDS_ATTENTION means that the component is ready, but some user intervention is required. (For example that the user should migrate workloads to a new control plane revision.)", - "DEGRADED means that the component is ready, but operating in a degraded state." + "DEGRADED means that the component is ready, but operating in a degraded state.", + "DEPROVISIONING means that deprovisioning is in progress." ], "type": "string" } @@ -3216,7 +3218,8 @@ "ACTIVE", "STALLED", "NEEDS_ATTENTION", - "DEGRADED" + "DEGRADED", + "DEPROVISIONING" ], "enumDescriptions": [ "Unspecified", @@ -3226,7 +3229,8 @@ "ACTIVE means that the component is ready for use.", "STALLED means that provisioning could not be done.", "NEEDS_ATTENTION means that the component is ready, but some user intervention is required. (For example that the user should migrate workloads to a new control plane revision.)", - "DEGRADED means that the component is ready, but operating in a degraded state." + "DEGRADED means that the component is ready, but operating in a degraded state.", + "DEPROVISIONING means that deprovisioning is in progress." ], "type": "string" } @@ -3288,12 +3292,14 @@ "enum": [ "MANAGEMENT_UNSPECIFIED", "MANAGEMENT_AUTOMATIC", - "MANAGEMENT_MANUAL" + "MANAGEMENT_MANUAL", + "MANAGEMENT_NOT_INSTALLED" ], "enumDescriptions": [ "Unspecified", "Google should manage my Service Mesh for the cluster.", - "User will manually configure their service mesh components." + "User will manually configure their service mesh components.", + "Google should remove any managed Service Mesh components from this cluster and deprovision any resources." ], "type": "string" } diff --git a/gkehub/v2alpha/gkehub-gen.go b/gkehub/v2alpha/gkehub-gen.go index f027c9f7bdc..c9742efb72d 100644 --- a/gkehub/v2alpha/gkehub-gen.go +++ b/gkehub/v2alpha/gkehub-gen.go @@ -3304,6 +3304,8 @@ type ServiceMeshControlPlaneManagement struct { // migrate workloads to a new control plane revision.) // "DEGRADED" - DEGRADED means that the component is ready, but operating in // a degraded state. + // "DEPROVISIONING" - DEPROVISIONING means that deprovisioning is in + // progress. State string `json:"state,omitempty"` // ForceSendFields is a list of field names (e.g. "Details") to unconditionally // include in API requests. By default, fields with empty or default values are @@ -3343,6 +3345,8 @@ type ServiceMeshDataPlaneManagement struct { // migrate workloads to a new control plane revision.) // "DEGRADED" - DEGRADED means that the component is ready, but operating in // a degraded state. + // "DEPROVISIONING" - DEPROVISIONING means that deprovisioning is in + // progress. State string `json:"state,omitempty"` // ForceSendFields is a list of field names (e.g. "Details") to unconditionally // include in API requests. By default, fields with empty or default values are @@ -3405,6 +3409,8 @@ type ServiceMeshSpec struct { // cluster. // "MANAGEMENT_MANUAL" - User will manually configure their service mesh // components. + // "MANAGEMENT_NOT_INSTALLED" - Google should remove any managed Service Mesh + // components from this cluster and deprovision any resources. Management string `json:"management,omitempty"` // ForceSendFields is a list of field names (e.g. "ConfigApi") to // unconditionally include in API requests. By default, fields with empty or diff --git a/mybusinessbusinessinformation/v1/mybusinessbusinessinformation-api.json b/mybusinessbusinessinformation/v1/mybusinessbusinessinformation-api.json index 0af13e0d7b8..d83b1b31b96 100644 --- a/mybusinessbusinessinformation/v1/mybusinessbusinessinformation-api.json +++ b/mybusinessbusinessinformation/v1/mybusinessbusinessinformation-api.json @@ -612,7 +612,7 @@ } } }, - "revision": "20250618", + "revision": "20250723", "rootUrl": "https://mybusinessbusinessinformation.googleapis.com/", "schemas": { "AdWordsLocationExtensions": { @@ -1228,6 +1228,11 @@ "readOnly": true, "type": "boolean" }, + "isParticularlyPersonalPlace": { + "description": "Output only.", + "readOnly": true, + "type": "boolean" + }, "mapsUri": { "description": "Output only. A link to the location on Maps.", "readOnly": true, diff --git a/mybusinessbusinessinformation/v1/mybusinessbusinessinformation-gen.go b/mybusinessbusinessinformation/v1/mybusinessbusinessinformation-gen.go index 3dc49be3317..67f58851efb 100644 --- a/mybusinessbusinessinformation/v1/mybusinessbusinessinformation-gen.go +++ b/mybusinessbusinessinformation/v1/mybusinessbusinessinformation-gen.go @@ -1074,6 +1074,8 @@ type Metadata struct { // locations.getVoiceOfMerchantState API to get details as to why they do not // have Voice of Merchant. HasVoiceOfMerchant bool `json:"hasVoiceOfMerchant,omitempty"` + // IsParticularlyPersonalPlace: Output only. + IsParticularlyPersonalPlace bool `json:"isParticularlyPersonalPlace,omitempty"` // MapsUri: Output only. A link to the location on Maps. MapsUri string `json:"mapsUri,omitempty"` // NewReviewUri: Output only. A link to the page on Google Search where a diff --git a/networkmanagement/v1/networkmanagement-api.json b/networkmanagement/v1/networkmanagement-api.json index fd73d958a68..c4002b8e2bb 100644 --- a/networkmanagement/v1/networkmanagement-api.json +++ b/networkmanagement/v1/networkmanagement-api.json @@ -1289,7 +1289,7 @@ } } }, - "revision": "20250709", + "revision": "20250716", "rootUrl": "https://networkmanagement.googleapis.com/", "schemas": { "AbortInfo": { @@ -2566,10 +2566,13 @@ "readOnly": true, "type": "string" }, - "cloudVpcId": { - "description": "Output only. The id of Virtual Private Cloud (VPC) of the host.", + "cloudVirtualNetworkIds": { + "description": "Output only. The ids of cloud virtual networks of the host.", + "items": { + "type": "string" + }, "readOnly": true, - "type": "string" + "type": "array" }, "cloudZone": { "description": "Output only. The cloud zone of the host.", diff --git a/networkmanagement/v1/networkmanagement-gen.go b/networkmanagement/v1/networkmanagement-gen.go index 242301ff780..4361d7e6835 100644 --- a/networkmanagement/v1/networkmanagement-gen.go +++ b/networkmanagement/v1/networkmanagement-gen.go @@ -1779,8 +1779,9 @@ type Host struct { CloudProvider string `json:"cloudProvider,omitempty"` // CloudRegion: Output only. The cloud region of the host. CloudRegion string `json:"cloudRegion,omitempty"` - // CloudVpcId: Output only. The id of Virtual Private Cloud (VPC) of the host. - CloudVpcId string `json:"cloudVpcId,omitempty"` + // CloudVirtualNetworkIds: Output only. The ids of cloud virtual networks of + // the host. + CloudVirtualNetworkIds []string `json:"cloudVirtualNetworkIds,omitempty"` // CloudZone: Output only. The cloud zone of the host. CloudZone string `json:"cloudZone,omitempty"` // Os: Output only. The operating system of the host. diff --git a/securitycenter/v1beta1/securitycenter-api.json b/securitycenter/v1beta1/securitycenter-api.json index 3f37de4ac8b..87171f1dd22 100644 --- a/securitycenter/v1beta1/securitycenter-api.json +++ b/securitycenter/v1beta1/securitycenter-api.json @@ -913,7 +913,7 @@ } } }, - "revision": "20250707", + "revision": "20250721", "rootUrl": "https://securitycenter.googleapis.com/", "schemas": { "Access": { @@ -1589,6 +1589,40 @@ }, "type": "object" }, + "CloudControl": { + "description": "CloudControl associated with the finding.", + "id": "CloudControl", + "properties": { + "cloudControlName": { + "description": "Name of the CloudControl associated with the finding.", + "type": "string" + }, + "policyType": { + "description": "Policy type of the CloudControl", + "type": "string" + }, + "type": { + "description": "Type of cloud control.", + "enum": [ + "CLOUD_CONTROL_TYPE_UNSPECIFIED", + "BUILT_IN", + "CUSTOM" + ], + "enumDescriptions": [ + "Unspecified.", + "Built in Cloud Control.", + "Custom Cloud Control." + ], + "type": "string" + }, + "version": { + "description": "Version of the Cloud Control", + "format": "int32", + "type": "integer" + } + }, + "type": "object" + }, "CloudDlpDataProfile": { "description": "The [data profile](https://cloud.google.com/dlp/docs/data-profiles) associated with the finding.", "id": "CloudDlpDataProfile", @@ -1684,6 +1718,31 @@ }, "type": "object" }, + "ComplianceDetails": { + "description": "Compliance Details associated with the finding.", + "id": "ComplianceDetails", + "properties": { + "cloudControl": { + "$ref": "CloudControl", + "description": "CloudControl associated with the finding" + }, + "cloudControlDeploymentNames": { + "description": "Cloud Control Deployments associated with the finding. For example, organizations/123/locations/global/cloudControlDeployments/deploymentIdentifier", + "items": { + "type": "string" + }, + "type": "array" + }, + "frameworks": { + "description": "Details of Frameworks associated with the finding", + "items": { + "$ref": "Framework" + }, + "type": "array" + } + }, + "type": "object" + }, "Connection": { "description": "Contains information about the IP connection associated with the finding.", "id": "Connection", @@ -1785,6 +1844,21 @@ }, "type": "object" }, + "Control": { + "description": "Compliance control associated with the finding.", + "id": "Control", + "properties": { + "controlName": { + "description": "Name of the Control", + "type": "string" + }, + "displayName": { + "description": "Display name of the control. For example, AU-02.", + "type": "string" + } + }, + "type": "object" + }, "Cve": { "description": "CVE stands for Common Vulnerabilities and Exposures. Information from the [CVE record](https://www.cve.org/ResourcesSupport/Glossary) that describes this vulnerability.", "id": "Cve", @@ -2489,6 +2563,10 @@ "$ref": "CloudDlpInspection", "description": "Cloud Data Loss Prevention (Cloud DLP) inspection results that are associated with the finding." }, + "complianceDetails": { + "$ref": "ComplianceDetails", + "description": "Details about the compliance implications of the finding." + }, "compliances": { "description": "Contains compliance information for security standards associated to the finding.", "items": { @@ -2823,6 +2901,63 @@ }, "type": "object" }, + "Framework": { + "description": "Compliance framework associated with the finding.", + "id": "Framework", + "properties": { + "category": { + "description": "Category of the framework associated with the finding. E.g. Security Benchmark, or Assured Workloads", + "items": { + "enum": [ + "FRAMEWORK_CATEGORY_UNSPECIFIED", + "SECURITY_BENCHMARKS", + "ASSURED_WORKLOADS", + "DATA_SECURITY", + "GOOGLE_BEST_PRACTICES" + ], + "enumDescriptions": [ + "Default value. This value is unused.", + "Security Benchmarks framework", + "Assured Workloads framework", + "Data Security framework", + "Google Best Practices framework" + ], + "type": "string" + }, + "type": "array" + }, + "controls": { + "description": "The controls associated with the framework.", + "items": { + "$ref": "Control" + }, + "type": "array" + }, + "displayName": { + "description": "Display name of the framework. For a standard framework, this will look like e.g. PCI DSS 3.2.1, whereas for a custom framework it can be a user defined string like MyFramework", + "type": "string" + }, + "name": { + "description": "Name of the framework associated with the finding", + "type": "string" + }, + "type": { + "description": "Type of the framework associated with the finding, to specify whether the framework is built-in (pre-defined and immutable) or a custom framework defined by the customer (equivalent to security posture)", + "enum": [ + "FRAMEWORK_TYPE_UNSPECIFIED", + "FRAMEWORK_TYPE_BUILT_IN", + "FRAMEWORK_TYPE_CUSTOM" + ], + "enumDescriptions": [ + "Default value. This value is unused.", + "The framework is a built-in framework if it is created and managed by GCP.", + "The framework is a custom framework if it is created and managed by the user." + ], + "type": "string" + } + }, + "type": "object" + }, "GcpMetadata": { "description": "Google Cloud metadata associated with the resource. Only applicable if the finding's cloud provider is Google Cloud.", "id": "GcpMetadata", @@ -4472,6 +4607,40 @@ }, "type": "object" }, + "GoogleCloudSecuritycenterV2CloudControl": { + "description": "CloudControl associated with the finding.", + "id": "GoogleCloudSecuritycenterV2CloudControl", + "properties": { + "cloudControlName": { + "description": "Name of the CloudControl associated with the finding.", + "type": "string" + }, + "policyType": { + "description": "Policy type of the CloudControl", + "type": "string" + }, + "type": { + "description": "Type of cloud control.", + "enum": [ + "CLOUD_CONTROL_TYPE_UNSPECIFIED", + "BUILT_IN", + "CUSTOM" + ], + "enumDescriptions": [ + "Unspecified.", + "Built in Cloud Control.", + "Custom Cloud Control." + ], + "type": "string" + }, + "version": { + "description": "Version of the Cloud Control", + "format": "int32", + "type": "integer" + } + }, + "type": "object" + }, "GoogleCloudSecuritycenterV2CloudDlpDataProfile": { "description": "The [data profile](https://cloud.google.com/dlp/docs/data-profiles) associated with the finding.", "id": "GoogleCloudSecuritycenterV2CloudDlpDataProfile", @@ -4567,6 +4736,31 @@ }, "type": "object" }, + "GoogleCloudSecuritycenterV2ComplianceDetails": { + "description": "Compliance Details associated with the finding.", + "id": "GoogleCloudSecuritycenterV2ComplianceDetails", + "properties": { + "cloudControl": { + "$ref": "GoogleCloudSecuritycenterV2CloudControl", + "description": "CloudControl associated with the finding" + }, + "cloudControlDeploymentNames": { + "description": "Cloud Control Deployments associated with the finding. For example, organizations/123/locations/global/cloudControlDeployments/deploymentIdentifier", + "items": { + "type": "string" + }, + "type": "array" + }, + "frameworks": { + "description": "Details of Frameworks associated with the finding", + "items": { + "$ref": "GoogleCloudSecuritycenterV2Framework" + }, + "type": "array" + } + }, + "type": "object" + }, "GoogleCloudSecuritycenterV2Connection": { "description": "Contains information about the IP connection associated with the finding.", "id": "GoogleCloudSecuritycenterV2Connection", @@ -4668,6 +4862,21 @@ }, "type": "object" }, + "GoogleCloudSecuritycenterV2Control": { + "description": "Compliance control associated with the finding.", + "id": "GoogleCloudSecuritycenterV2Control", + "properties": { + "controlName": { + "description": "Name of the Control", + "type": "string" + }, + "displayName": { + "description": "Display name of the control. For example, AU-02.", + "type": "string" + } + }, + "type": "object" + }, "GoogleCloudSecuritycenterV2Cve": { "description": "CVE stands for Common Vulnerabilities and Exposures. Information from the [CVE record](https://www.cve.org/ResourcesSupport/Glossary) that describes this vulnerability.", "id": "GoogleCloudSecuritycenterV2Cve", @@ -5380,6 +5589,10 @@ "$ref": "GoogleCloudSecuritycenterV2CloudDlpInspection", "description": "Cloud Data Loss Prevention (Cloud DLP) inspection results that are associated with the finding." }, + "complianceDetails": { + "$ref": "GoogleCloudSecuritycenterV2ComplianceDetails", + "description": "Details about the compliance implications of the finding." + }, "compliances": { "description": "Contains compliance information for security standards associated to the finding.", "items": { @@ -5716,6 +5929,63 @@ }, "type": "object" }, + "GoogleCloudSecuritycenterV2Framework": { + "description": "Compliance framework associated with the finding.", + "id": "GoogleCloudSecuritycenterV2Framework", + "properties": { + "category": { + "description": "Category of the framework associated with the finding. E.g. Security Benchmark, or Assured Workloads", + "items": { + "enum": [ + "FRAMEWORK_CATEGORY_UNSPECIFIED", + "SECURITY_BENCHMARKS", + "ASSURED_WORKLOADS", + "DATA_SECURITY", + "GOOGLE_BEST_PRACTICES" + ], + "enumDescriptions": [ + "Default value. This value is unused.", + "Security Benchmarks framework", + "Assured Workloads framework", + "Data Security framework", + "Google Best Practices framework" + ], + "type": "string" + }, + "type": "array" + }, + "controls": { + "description": "The controls associated with the framework.", + "items": { + "$ref": "GoogleCloudSecuritycenterV2Control" + }, + "type": "array" + }, + "displayName": { + "description": "Display name of the framework. For a standard framework, this will look like e.g. PCI DSS 3.2.1, whereas for a custom framework it can be a user defined string like MyFramework", + "type": "string" + }, + "name": { + "description": "Name of the framework associated with the finding", + "type": "string" + }, + "type": { + "description": "Type of the framework associated with the finding, to specify whether the framework is built-in (pre-defined and immutable) or a custom framework defined by the customer (equivalent to security posture)", + "enum": [ + "FRAMEWORK_TYPE_UNSPECIFIED", + "FRAMEWORK_TYPE_BUILT_IN", + "FRAMEWORK_TYPE_CUSTOM" + ], + "enumDescriptions": [ + "Default value. This value is unused.", + "The framework is a built-in framework if it is created and managed by GCP.", + "The framework is a custom framework if it is created and managed by the user." + ], + "type": "string" + } + }, + "type": "object" + }, "GoogleCloudSecuritycenterV2Geolocation": { "description": "Represents a geographical location for a given access.", "id": "GoogleCloudSecuritycenterV2Geolocation", @@ -7608,7 +7878,7 @@ }, "gcpMetadata": { "$ref": "GcpMetadata", - "description": "The GCP metadata associated with the finding." + "description": "The Google Cloud metadata associated with the finding." }, "location": { "description": "The region or location of the service (if applicable).", diff --git a/securitycenter/v1beta1/securitycenter-gen.go b/securitycenter/v1beta1/securitycenter-gen.go index f09c0a1d10e..f58d59c6aa5 100644 --- a/securitycenter/v1beta1/securitycenter-gen.go +++ b/securitycenter/v1beta1/securitycenter-gen.go @@ -1234,6 +1234,39 @@ func (s CloudArmor) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// CloudControl: CloudControl associated with the finding. +type CloudControl struct { + // CloudControlName: Name of the CloudControl associated with the finding. + CloudControlName string `json:"cloudControlName,omitempty"` + // PolicyType: Policy type of the CloudControl + PolicyType string `json:"policyType,omitempty"` + // Type: Type of cloud control. + // + // Possible values: + // "CLOUD_CONTROL_TYPE_UNSPECIFIED" - Unspecified. + // "BUILT_IN" - Built in Cloud Control. + // "CUSTOM" - Custom Cloud Control. + Type string `json:"type,omitempty"` + // Version: Version of the Cloud Control + Version int64 `json:"version,omitempty"` + // ForceSendFields is a list of field names (e.g. "CloudControlName") 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. "CloudControlName") 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 CloudControl) MarshalJSON() ([]byte, error) { + type NoMethod CloudControl + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // CloudDlpDataProfile: The data profile // (https://cloud.google.com/dlp/docs/data-profiles) associated with the // finding. @@ -1363,6 +1396,35 @@ func (s Compliance) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// ComplianceDetails: Compliance Details associated with the finding. +type ComplianceDetails struct { + // CloudControl: CloudControl associated with the finding + CloudControl *CloudControl `json:"cloudControl,omitempty"` + // CloudControlDeploymentNames: Cloud Control Deployments associated with the + // finding. For example, + // organizations/123/locations/global/cloudControlDeployments/deploymentIdentifi + // er + CloudControlDeploymentNames []string `json:"cloudControlDeploymentNames,omitempty"` + // Frameworks: Details of Frameworks associated with the finding + Frameworks []*Framework `json:"frameworks,omitempty"` + // ForceSendFields is a list of field names (e.g. "CloudControl") 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. "CloudControl") 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 ComplianceDetails) MarshalJSON() ([]byte, error) { + type NoMethod ComplianceDetails + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // Connection: Contains information about the IP connection associated with the // finding. type Connection struct { @@ -1481,6 +1543,30 @@ func (s Container) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// Control: Compliance control associated with the finding. +type Control struct { + // ControlName: Name of the Control + ControlName string `json:"controlName,omitempty"` + // DisplayName: Display name of the control. For example, AU-02. + DisplayName string `json:"displayName,omitempty"` + // ForceSendFields is a list of field names (e.g. "ControlName") 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. "ControlName") 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 Control) MarshalJSON() ([]byte, error) { + type NoMethod Control + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // Cve: CVE stands for Common Vulnerabilities and Exposures. Information from // the CVE record (https://www.cve.org/ResourcesSupport/Glossary) that // describes this vulnerability. @@ -2345,6 +2431,8 @@ type Finding struct { // CloudDlpInspection: Cloud Data Loss Prevention (Cloud DLP) inspection // results that are associated with the finding. CloudDlpInspection *CloudDlpInspection `json:"cloudDlpInspection,omitempty"` + // ComplianceDetails: Details about the compliance implications of the finding. + ComplianceDetails *ComplianceDetails `json:"complianceDetails,omitempty"` // Compliances: Contains compliance information for security standards // associated to the finding. Compliances []*Compliance `json:"compliances,omitempty"` @@ -2621,6 +2709,55 @@ func (s Folder) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// Framework: Compliance framework associated with the finding. +type Framework struct { + // Category: Category of the framework associated with the finding. E.g. + // Security Benchmark, or Assured Workloads + // + // Possible values: + // "FRAMEWORK_CATEGORY_UNSPECIFIED" - Default value. This value is unused. + // "SECURITY_BENCHMARKS" - Security Benchmarks framework + // "ASSURED_WORKLOADS" - Assured Workloads framework + // "DATA_SECURITY" - Data Security framework + // "GOOGLE_BEST_PRACTICES" - Google Best Practices framework + Category []string `json:"category,omitempty"` + // Controls: The controls associated with the framework. + Controls []*Control `json:"controls,omitempty"` + // DisplayName: Display name of the framework. For a standard framework, this + // will look like e.g. PCI DSS 3.2.1, whereas for a custom framework it can be + // a user defined string like MyFramework + DisplayName string `json:"displayName,omitempty"` + // Name: Name of the framework associated with the finding + Name string `json:"name,omitempty"` + // Type: Type of the framework associated with the finding, to specify whether + // the framework is built-in (pre-defined and immutable) or a custom framework + // defined by the customer (equivalent to security posture) + // + // Possible values: + // "FRAMEWORK_TYPE_UNSPECIFIED" - Default value. This value is unused. + // "FRAMEWORK_TYPE_BUILT_IN" - The framework is a built-in framework if it is + // created and managed by GCP. + // "FRAMEWORK_TYPE_CUSTOM" - The framework is a custom framework if it is + // created and managed by the user. + Type string `json:"type,omitempty"` + // ForceSendFields is a list of field names (e.g. "Category") 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. "Category") 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 Framework) MarshalJSON() ([]byte, error) { + type NoMethod Framework + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GcpMetadata: Google Cloud metadata associated with the resource. Only // applicable if the finding's cloud provider is Google Cloud. type GcpMetadata struct { @@ -4737,6 +4874,40 @@ func (s GoogleCloudSecuritycenterV2CloudArmor) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudSecuritycenterV2CloudControl: CloudControl associated with the +// finding. +type GoogleCloudSecuritycenterV2CloudControl struct { + // CloudControlName: Name of the CloudControl associated with the finding. + CloudControlName string `json:"cloudControlName,omitempty"` + // PolicyType: Policy type of the CloudControl + PolicyType string `json:"policyType,omitempty"` + // Type: Type of cloud control. + // + // Possible values: + // "CLOUD_CONTROL_TYPE_UNSPECIFIED" - Unspecified. + // "BUILT_IN" - Built in Cloud Control. + // "CUSTOM" - Custom Cloud Control. + Type string `json:"type,omitempty"` + // Version: Version of the Cloud Control + Version int64 `json:"version,omitempty"` + // ForceSendFields is a list of field names (e.g. "CloudControlName") 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. "CloudControlName") 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 GoogleCloudSecuritycenterV2CloudControl) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudSecuritycenterV2CloudControl + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudSecuritycenterV2CloudDlpDataProfile: The data profile // (https://cloud.google.com/dlp/docs/data-profiles) associated with the // finding. @@ -4868,6 +5039,36 @@ func (s GoogleCloudSecuritycenterV2Compliance) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudSecuritycenterV2ComplianceDetails: Compliance Details associated +// with the finding. +type GoogleCloudSecuritycenterV2ComplianceDetails struct { + // CloudControl: CloudControl associated with the finding + CloudControl *GoogleCloudSecuritycenterV2CloudControl `json:"cloudControl,omitempty"` + // CloudControlDeploymentNames: Cloud Control Deployments associated with the + // finding. For example, + // organizations/123/locations/global/cloudControlDeployments/deploymentIdentifi + // er + CloudControlDeploymentNames []string `json:"cloudControlDeploymentNames,omitempty"` + // Frameworks: Details of Frameworks associated with the finding + Frameworks []*GoogleCloudSecuritycenterV2Framework `json:"frameworks,omitempty"` + // ForceSendFields is a list of field names (e.g. "CloudControl") 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. "CloudControl") 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 GoogleCloudSecuritycenterV2ComplianceDetails) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudSecuritycenterV2ComplianceDetails + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudSecuritycenterV2Connection: Contains information about the IP // connection associated with the finding. type GoogleCloudSecuritycenterV2Connection struct { @@ -4986,6 +5187,31 @@ func (s GoogleCloudSecuritycenterV2Container) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudSecuritycenterV2Control: Compliance control associated with the +// finding. +type GoogleCloudSecuritycenterV2Control struct { + // ControlName: Name of the Control + ControlName string `json:"controlName,omitempty"` + // DisplayName: Display name of the control. For example, AU-02. + DisplayName string `json:"displayName,omitempty"` + // ForceSendFields is a list of field names (e.g. "ControlName") 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. "ControlName") 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 GoogleCloudSecuritycenterV2Control) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudSecuritycenterV2Control + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudSecuritycenterV2Cve: CVE stands for Common Vulnerabilities and // Exposures. Information from the CVE record // (https://www.cve.org/ResourcesSupport/Glossary) that describes this @@ -5841,6 +6067,8 @@ type GoogleCloudSecuritycenterV2Finding struct { // CloudDlpInspection: Cloud Data Loss Prevention (Cloud DLP) inspection // results that are associated with the finding. CloudDlpInspection *GoogleCloudSecuritycenterV2CloudDlpInspection `json:"cloudDlpInspection,omitempty"` + // ComplianceDetails: Details about the compliance implications of the finding. + ComplianceDetails *GoogleCloudSecuritycenterV2ComplianceDetails `json:"complianceDetails,omitempty"` // Compliances: Contains compliance information for security standards // associated to the finding. Compliances []*GoogleCloudSecuritycenterV2Compliance `json:"compliances,omitempty"` @@ -6127,6 +6355,56 @@ func (s GoogleCloudSecuritycenterV2Folder) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudSecuritycenterV2Framework: Compliance framework associated with +// the finding. +type GoogleCloudSecuritycenterV2Framework struct { + // Category: Category of the framework associated with the finding. E.g. + // Security Benchmark, or Assured Workloads + // + // Possible values: + // "FRAMEWORK_CATEGORY_UNSPECIFIED" - Default value. This value is unused. + // "SECURITY_BENCHMARKS" - Security Benchmarks framework + // "ASSURED_WORKLOADS" - Assured Workloads framework + // "DATA_SECURITY" - Data Security framework + // "GOOGLE_BEST_PRACTICES" - Google Best Practices framework + Category []string `json:"category,omitempty"` + // Controls: The controls associated with the framework. + Controls []*GoogleCloudSecuritycenterV2Control `json:"controls,omitempty"` + // DisplayName: Display name of the framework. For a standard framework, this + // will look like e.g. PCI DSS 3.2.1, whereas for a custom framework it can be + // a user defined string like MyFramework + DisplayName string `json:"displayName,omitempty"` + // Name: Name of the framework associated with the finding + Name string `json:"name,omitempty"` + // Type: Type of the framework associated with the finding, to specify whether + // the framework is built-in (pre-defined and immutable) or a custom framework + // defined by the customer (equivalent to security posture) + // + // Possible values: + // "FRAMEWORK_TYPE_UNSPECIFIED" - Default value. This value is unused. + // "FRAMEWORK_TYPE_BUILT_IN" - The framework is a built-in framework if it is + // created and managed by GCP. + // "FRAMEWORK_TYPE_CUSTOM" - The framework is a custom framework if it is + // created and managed by the user. + Type string `json:"type,omitempty"` + // ForceSendFields is a list of field names (e.g. "Category") 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. "Category") 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 GoogleCloudSecuritycenterV2Framework) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudSecuritycenterV2Framework + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudSecuritycenterV2Geolocation: Represents a geographical location // for a given access. type GoogleCloudSecuritycenterV2Geolocation struct { @@ -7974,7 +8252,7 @@ type GoogleCloudSecuritycenterV2Resource struct { CloudProvider string `json:"cloudProvider,omitempty"` // DisplayName: The human readable name of the resource. DisplayName string `json:"displayName,omitempty"` - // GcpMetadata: The GCP metadata associated with the finding. + // GcpMetadata: The Google Cloud metadata associated with the finding. GcpMetadata *GcpMetadata `json:"gcpMetadata,omitempty"` // Location: The region or location of the service (if applicable). Location string `json:"location,omitempty"` diff --git a/servicenetworking/v1/servicenetworking-api.json b/servicenetworking/v1/servicenetworking-api.json index 7920bc757c7..5dde5356615 100644 --- a/servicenetworking/v1/servicenetworking-api.json +++ b/servicenetworking/v1/servicenetworking-api.json @@ -1029,7 +1029,7 @@ } } }, - "revision": "20250713", + "revision": "20250722", "rootUrl": "https://servicenetworking.googleapis.com/", "schemas": { "AddDnsRecordSetMetadata": { @@ -1234,7 +1234,7 @@ "type": "object" }, "Api": { - "description": "Api is a light-weight descriptor for an API Interface. Interfaces are also described as \"protocol buffer services\" in some contexts, such as by the \"service\" keyword in a .proto file, but they are different from API Services, which represent a concrete implementation of an interface as opposed to simply a description of methods and bindings. They are also sometimes simply referred to as \"APIs\" in other contexts, such as the name of this message itself. See https://cloud.google.com/apis/design/glossary for detailed terminology.", + "description": "Api is a light-weight descriptor for an API Interface. Interfaces are also described as \"protocol buffer services\" in some contexts, such as by the \"service\" keyword in a .proto file, but they are different from API Services, which represent a concrete implementation of an interface as opposed to simply a description of methods and bindings. They are also sometimes simply referred to as \"APIs\" in other contexts, such as the name of this message itself. See https://cloud.google.com/apis/design/glossary for detailed terminology. New usages of this message as an alternative to ServiceDescriptorProto are strongly discouraged. This message does not reliability preserve all information necessary to model the schema and preserve semantics. Instead make use of FileDescriptorSet which preserves the necessary information.", "id": "Api", "properties": { "edition": { @@ -2254,7 +2254,7 @@ "type": "object" }, "Enum": { - "description": "Enum type definition.", + "description": "Enum type definition. New usages of this message as an alternative to EnumDescriptorProto are strongly discouraged. This message does not reliability preserve all information necessary to model the schema and preserve semantics. Instead make use of FileDescriptorSet which preserves the necessary information.", "id": "Enum", "properties": { "edition": { @@ -2301,7 +2301,7 @@ "type": "object" }, "EnumValue": { - "description": "Enum value definition.", + "description": "Enum value definition. New usages of this message as an alternative to EnumValueDescriptorProto are strongly discouraged. This message does not reliability preserve all information necessary to model the schema and preserve semantics. Instead make use of FileDescriptorSet which preserves the necessary information.", "id": "EnumValue", "properties": { "name": { @@ -2343,7 +2343,7 @@ "type": "object" }, "Field": { - "description": "A single field of a message type.", + "description": "A single field of a message type. New usages of this message as an alternative to FieldDescriptorProto are strongly discouraged. This message does not reliability preserve all information necessary to model the schema and preserve semantics. Instead make use of FileDescriptorSet which preserves the necessary information.", "id": "Field", "properties": { "cardinality": { @@ -2878,11 +2878,12 @@ "type": "object" }, "Method": { - "description": "Method represents a method of an API interface.", + "description": "Method represents a method of an API interface. New usages of this message as an alternative to MethodDescriptorProto are strongly discouraged. This message does not reliability preserve all information necessary to model the schema and preserve semantics. Instead make use of FileDescriptorSet which preserves the necessary information.", "id": "Method", "properties": { "edition": { - "description": "The source edition string, only valid when syntax is SYNTAX_EDITIONS.", + "deprecated": true, + "description": "The source edition string, only valid when syntax is SYNTAX_EDITIONS. This field should be ignored, instead the edition should be inherited from Api. This is similar to Field and EnumValue.", "type": "string" }, "name": { @@ -2913,7 +2914,8 @@ "type": "string" }, "syntax": { - "description": "The source syntax of this method.", + "deprecated": true, + "description": "The source syntax of this method. This field should be ignored, instead the syntax should be inherited from Api. This is similar to Field and EnumValue.", "enum": [ "SYNTAX_PROTO2", "SYNTAX_PROTO3", @@ -3326,7 +3328,7 @@ "type": "object" }, "Option": { - "description": "A protocol buffer option, which can be attached to a message, field, enumeration, etc.", + "description": "A protocol buffer option, which can be attached to a message, field, enumeration, etc. New usages of this message as an alternative to FileOptions, MessageOptions, FieldOptions, EnumOptions, EnumValueOptions, ServiceOptions, or MethodOptions are strongly discouraged.", "id": "Option", "properties": { "name": { @@ -4098,7 +4100,7 @@ "type": "object" }, "Type": { - "description": "A protocol buffer message type.", + "description": "A protocol buffer message type. New usages of this message as an alternative to DescriptorProto are strongly discouraged. This message does not reliability preserve all information necessary to model the schema and preserve semantics. Instead make use of FileDescriptorSet which preserves the necessary information.", "id": "Type", "properties": { "edition": { diff --git a/servicenetworking/v1/servicenetworking-gen.go b/servicenetworking/v1/servicenetworking-gen.go index e949815b349..3fbd51f5c7d 100644 --- a/servicenetworking/v1/servicenetworking-gen.go +++ b/servicenetworking/v1/servicenetworking-gen.go @@ -590,7 +590,11 @@ func (s AddSubnetworkRequest) MarshalJSON() ([]byte, error) { // opposed to simply a description of methods and bindings. They are also // sometimes simply referred to as "APIs" in other contexts, such as the name // of this message itself. See https://cloud.google.com/apis/design/glossary -// for detailed terminology. +// for detailed terminology. New usages of this message as an alternative to +// ServiceDescriptorProto are strongly discouraged. This message does not +// reliability preserve all information necessary to model the schema and +// preserve semantics. Instead make use of FileDescriptorSet which preserves +// the necessary information. type Api struct { // Edition: The source edition string, only valid when syntax is // SYNTAX_EDITIONS. @@ -2047,7 +2051,11 @@ func (s Endpoint) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// Enum: Enum type definition. +// Enum: Enum type definition. New usages of this message as an alternative to +// EnumDescriptorProto are strongly discouraged. This message does not +// reliability preserve all information necessary to model the schema and +// preserve semantics. Instead make use of FileDescriptorSet which preserves +// the necessary information. type Enum struct { // Edition: The source edition string, only valid when syntax is // SYNTAX_EDITIONS. @@ -2085,7 +2093,11 @@ func (s Enum) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// EnumValue: Enum value definition. +// EnumValue: Enum value definition. New usages of this message as an +// alternative to EnumValueDescriptorProto are strongly discouraged. This +// message does not reliability preserve all information necessary to model the +// schema and preserve semantics. Instead make use of FileDescriptorSet which +// preserves the necessary information. type EnumValue struct { // Name: Enum value name. Name string `json:"name,omitempty"` @@ -2148,7 +2160,11 @@ func (s ExperimentalFeatures) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// Field: A single field of a message type. +// Field: A single field of a message type. New usages of this message as an +// alternative to FieldDescriptorProto are strongly discouraged. This message +// does not reliability preserve all information necessary to model the schema +// and preserve semantics. Instead make use of FileDescriptorSet which +// preserves the necessary information. type Field struct { // Cardinality: The field cardinality. // @@ -3028,10 +3044,15 @@ func (s *LongRunning) UnmarshalJSON(data []byte) error { return nil } -// Method: Method represents a method of an API interface. +// Method: Method represents a method of an API interface. New usages of this +// message as an alternative to MethodDescriptorProto are strongly discouraged. +// This message does not reliability preserve all information necessary to +// model the schema and preserve semantics. Instead make use of +// FileDescriptorSet which preserves the necessary information. type Method struct { // Edition: The source edition string, only valid when syntax is - // SYNTAX_EDITIONS. + // SYNTAX_EDITIONS. This field should be ignored, instead the edition should be + // inherited from Api. This is similar to Field and EnumValue. Edition string `json:"edition,omitempty"` // Name: The simple name of this method. Name string `json:"name,omitempty"` @@ -3045,7 +3066,9 @@ type Method struct { ResponseStreaming bool `json:"responseStreaming,omitempty"` // ResponseTypeUrl: The URL of the output message type. ResponseTypeUrl string `json:"responseTypeUrl,omitempty"` - // Syntax: The source syntax of this method. + // Syntax: The source syntax of this method. This field should be ignored, + // instead the syntax should be inherited from Api. This is similar to Field + // and EnumValue. // // Possible values: // "SYNTAX_PROTO2" - Syntax `proto2`. @@ -3750,7 +3773,9 @@ func (s Operation) MarshalJSON() ([]byte, error) { } // Option: A protocol buffer option, which can be attached to a message, field, -// enumeration, etc. +// enumeration, etc. New usages of this message as an alternative to +// FileOptions, MessageOptions, FieldOptions, EnumOptions, EnumValueOptions, +// ServiceOptions, or MethodOptions are strongly discouraged. type Option struct { // Name: The option's name. For protobuf built-in options (options defined in // descriptor.proto), this is the short name. For example, "map_entry". For @@ -4803,7 +4828,11 @@ func (s SystemParameters) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// Type: A protocol buffer message type. +// Type: A protocol buffer message type. New usages of this message as an +// alternative to DescriptorProto are strongly discouraged. This message does +// not reliability preserve all information necessary to model the schema and +// preserve semantics. Instead make use of FileDescriptorSet which preserves +// the necessary information. type Type struct { // Edition: The source edition string, only valid when syntax is // SYNTAX_EDITIONS. diff --git a/servicenetworking/v1beta/servicenetworking-api.json b/servicenetworking/v1beta/servicenetworking-api.json index 43ae89e12c0..b82cab95089 100644 --- a/servicenetworking/v1beta/servicenetworking-api.json +++ b/servicenetworking/v1beta/servicenetworking-api.json @@ -307,7 +307,7 @@ } } }, - "revision": "20250713", + "revision": "20250722", "rootUrl": "https://servicenetworking.googleapis.com/", "schemas": { "AddDnsRecordSetMetadata": { @@ -401,7 +401,7 @@ "type": "object" }, "Api": { - "description": "Api is a light-weight descriptor for an API Interface. Interfaces are also described as \"protocol buffer services\" in some contexts, such as by the \"service\" keyword in a .proto file, but they are different from API Services, which represent a concrete implementation of an interface as opposed to simply a description of methods and bindings. They are also sometimes simply referred to as \"APIs\" in other contexts, such as the name of this message itself. See https://cloud.google.com/apis/design/glossary for detailed terminology.", + "description": "Api is a light-weight descriptor for an API Interface. Interfaces are also described as \"protocol buffer services\" in some contexts, such as by the \"service\" keyword in a .proto file, but they are different from API Services, which represent a concrete implementation of an interface as opposed to simply a description of methods and bindings. They are also sometimes simply referred to as \"APIs\" in other contexts, such as the name of this message itself. See https://cloud.google.com/apis/design/glossary for detailed terminology. New usages of this message as an alternative to ServiceDescriptorProto are strongly discouraged. This message does not reliability preserve all information necessary to model the schema and preserve semantics. Instead make use of FileDescriptorSet which preserves the necessary information.", "id": "Api", "properties": { "edition": { @@ -1349,7 +1349,7 @@ "type": "object" }, "Enum": { - "description": "Enum type definition.", + "description": "Enum type definition. New usages of this message as an alternative to EnumDescriptorProto are strongly discouraged. This message does not reliability preserve all information necessary to model the schema and preserve semantics. Instead make use of FileDescriptorSet which preserves the necessary information.", "id": "Enum", "properties": { "edition": { @@ -1396,7 +1396,7 @@ "type": "object" }, "EnumValue": { - "description": "Enum value definition.", + "description": "Enum value definition. New usages of this message as an alternative to EnumValueDescriptorProto are strongly discouraged. This message does not reliability preserve all information necessary to model the schema and preserve semantics. Instead make use of FileDescriptorSet which preserves the necessary information.", "id": "EnumValue", "properties": { "name": { @@ -1438,7 +1438,7 @@ "type": "object" }, "Field": { - "description": "A single field of a message type.", + "description": "A single field of a message type. New usages of this message as an alternative to FieldDescriptorProto are strongly discouraged. This message does not reliability preserve all information necessary to model the schema and preserve semantics. Instead make use of FileDescriptorSet which preserves the necessary information.", "id": "Field", "properties": { "cardinality": { @@ -1898,11 +1898,12 @@ "type": "object" }, "Method": { - "description": "Method represents a method of an API interface.", + "description": "Method represents a method of an API interface. New usages of this message as an alternative to MethodDescriptorProto are strongly discouraged. This message does not reliability preserve all information necessary to model the schema and preserve semantics. Instead make use of FileDescriptorSet which preserves the necessary information.", "id": "Method", "properties": { "edition": { - "description": "The source edition string, only valid when syntax is SYNTAX_EDITIONS.", + "deprecated": true, + "description": "The source edition string, only valid when syntax is SYNTAX_EDITIONS. This field should be ignored, instead the edition should be inherited from Api. This is similar to Field and EnumValue.", "type": "string" }, "name": { @@ -1933,7 +1934,8 @@ "type": "string" }, "syntax": { - "description": "The source syntax of this method.", + "deprecated": true, + "description": "The source syntax of this method. This field should be ignored, instead the syntax should be inherited from Api. This is similar to Field and EnumValue.", "enum": [ "SYNTAX_PROTO2", "SYNTAX_PROTO3", @@ -2346,7 +2348,7 @@ "type": "object" }, "Option": { - "description": "A protocol buffer option, which can be attached to a message, field, enumeration, etc.", + "description": "A protocol buffer option, which can be attached to a message, field, enumeration, etc. New usages of this message as an alternative to FileOptions, MessageOptions, FieldOptions, EnumOptions, EnumValueOptions, ServiceOptions, or MethodOptions are strongly discouraged.", "id": "Option", "properties": { "name": { @@ -3027,7 +3029,7 @@ "type": "object" }, "Type": { - "description": "A protocol buffer message type.", + "description": "A protocol buffer message type. New usages of this message as an alternative to DescriptorProto are strongly discouraged. This message does not reliability preserve all information necessary to model the schema and preserve semantics. Instead make use of FileDescriptorSet which preserves the necessary information.", "id": "Type", "properties": { "edition": { diff --git a/servicenetworking/v1beta/servicenetworking-gen.go b/servicenetworking/v1beta/servicenetworking-gen.go index 115996d9e81..ac1da17b7c8 100644 --- a/servicenetworking/v1beta/servicenetworking-gen.go +++ b/servicenetworking/v1beta/servicenetworking-gen.go @@ -325,7 +325,11 @@ func (s AddSubnetworkRequest) MarshalJSON() ([]byte, error) { // opposed to simply a description of methods and bindings. They are also // sometimes simply referred to as "APIs" in other contexts, such as the name // of this message itself. See https://cloud.google.com/apis/design/glossary -// for detailed terminology. +// for detailed terminology. New usages of this message as an alternative to +// ServiceDescriptorProto are strongly discouraged. This message does not +// reliability preserve all information necessary to model the schema and +// preserve semantics. Instead make use of FileDescriptorSet which preserves +// the necessary information. type Api struct { // Edition: The source edition string, only valid when syntax is // SYNTAX_EDITIONS. @@ -1636,7 +1640,11 @@ func (s Endpoint) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// Enum: Enum type definition. +// Enum: Enum type definition. New usages of this message as an alternative to +// EnumDescriptorProto are strongly discouraged. This message does not +// reliability preserve all information necessary to model the schema and +// preserve semantics. Instead make use of FileDescriptorSet which preserves +// the necessary information. type Enum struct { // Edition: The source edition string, only valid when syntax is // SYNTAX_EDITIONS. @@ -1674,7 +1682,11 @@ func (s Enum) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// EnumValue: Enum value definition. +// EnumValue: Enum value definition. New usages of this message as an +// alternative to EnumValueDescriptorProto are strongly discouraged. This +// message does not reliability preserve all information necessary to model the +// schema and preserve semantics. Instead make use of FileDescriptorSet which +// preserves the necessary information. type EnumValue struct { // Name: Enum value name. Name string `json:"name,omitempty"` @@ -1737,7 +1749,11 @@ func (s ExperimentalFeatures) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// Field: A single field of a message type. +// Field: A single field of a message type. New usages of this message as an +// alternative to FieldDescriptorProto are strongly discouraged. This message +// does not reliability preserve all information necessary to model the schema +// and preserve semantics. Instead make use of FileDescriptorSet which +// preserves the necessary information. type Field struct { // Cardinality: The field cardinality. // @@ -2481,10 +2497,15 @@ func (s *LongRunning) UnmarshalJSON(data []byte) error { return nil } -// Method: Method represents a method of an API interface. +// Method: Method represents a method of an API interface. New usages of this +// message as an alternative to MethodDescriptorProto are strongly discouraged. +// This message does not reliability preserve all information necessary to +// model the schema and preserve semantics. Instead make use of +// FileDescriptorSet which preserves the necessary information. type Method struct { // Edition: The source edition string, only valid when syntax is - // SYNTAX_EDITIONS. + // SYNTAX_EDITIONS. This field should be ignored, instead the edition should be + // inherited from Api. This is similar to Field and EnumValue. Edition string `json:"edition,omitempty"` // Name: The simple name of this method. Name string `json:"name,omitempty"` @@ -2498,7 +2519,9 @@ type Method struct { ResponseStreaming bool `json:"responseStreaming,omitempty"` // ResponseTypeUrl: The URL of the output message type. ResponseTypeUrl string `json:"responseTypeUrl,omitempty"` - // Syntax: The source syntax of this method. + // Syntax: The source syntax of this method. This field should be ignored, + // instead the syntax should be inherited from Api. This is similar to Field + // and EnumValue. // // Possible values: // "SYNTAX_PROTO2" - Syntax `proto2`. @@ -3203,7 +3226,9 @@ func (s Operation) MarshalJSON() ([]byte, error) { } // Option: A protocol buffer option, which can be attached to a message, field, -// enumeration, etc. +// enumeration, etc. New usages of this message as an alternative to +// FileOptions, MessageOptions, FieldOptions, EnumOptions, EnumValueOptions, +// ServiceOptions, or MethodOptions are strongly discouraged. type Option struct { // Name: The option's name. For protobuf built-in options (options defined in // descriptor.proto), this is the short name. For example, "map_entry". For @@ -4110,7 +4135,11 @@ func (s SystemParameters) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// Type: A protocol buffer message type. +// Type: A protocol buffer message type. New usages of this message as an +// alternative to DescriptorProto are strongly discouraged. This message does +// not reliability preserve all information necessary to model the schema and +// preserve semantics. Instead make use of FileDescriptorSet which preserves +// the necessary information. type Type struct { // Edition: The source edition string, only valid when syntax is // SYNTAX_EDITIONS. From 2c1ff18dfc5f5c9e422ed03c8daf571264eaec4c Mon Sep 17 00:00:00 2001 From: Yoshi Automation Bot Date: Sat, 26 Jul 2025 00:34:28 -0700 Subject: [PATCH 04/10] feat(all): auto-regenerate discovery clients (#3245) --- .../v1alpha/analyticsadmin-api.json | 65 +- analyticsadmin/v1alpha/analyticsadmin-gen.go | 169 +++ androidpublisher/v3/androidpublisher-api.json | 8 +- androidpublisher/v3/androidpublisher-gen.go | 2 + backupdr/v1/backupdr-api.json | 10 +- backupdr/v1/backupdr-gen.go | 8 +- discoveryengine/v1/discoveryengine-api.json | 61 +- discoveryengine/v1/discoveryengine-gen.go | 229 ++++ .../v1alpha/discoveryengine-api.json | 412 +++++++- .../v1alpha/discoveryengine-gen.go | 998 ++++++++++++++++-- .../v1beta/discoveryengine-api.json | 72 +- discoveryengine/v1beta/discoveryengine-gen.go | 255 +++++ dlp/v2/dlp-api.json | 32 +- dlp/v2/dlp-gen.go | 41 +- firebaseml/v2beta/firebaseml-api.json | 30 +- firebaseml/v2beta/firebaseml-gen.go | 47 +- gkehub/v1/gkehub-api.json | 20 +- gkehub/v1/gkehub-gen.go | 6 + iamcredentials/v1/iamcredentials-api.json | 22 +- .../products_v1beta/merchantapi-api.json | 6 +- .../products_v1beta/merchantapi-gen.go | 22 +- redis/v1/redis-api.json | 53 +- redis/v1/redis-gen.go | 37 +- redis/v1beta1/redis-api.json | 53 +- redis/v1beta1/redis-gen.go | 37 +- run/v2/run-api.json | 11 +- run/v2/run-gen.go | 6 +- workloadmanager/v1/workloadmanager-api.json | 7 +- workloadmanager/v1/workloadmanager-gen.go | 3 + 29 files changed, 2448 insertions(+), 274 deletions(-) diff --git a/analyticsadmin/v1alpha/analyticsadmin-api.json b/analyticsadmin/v1alpha/analyticsadmin-api.json index b7db1159919..a518339a614 100644 --- a/analyticsadmin/v1alpha/analyticsadmin-api.json +++ b/analyticsadmin/v1alpha/analyticsadmin-api.json @@ -975,6 +975,34 @@ "https://www.googleapis.com/auth/analytics.readonly" ] }, + "submitUserDeletion": { + "description": "Submits a request for user deletion for a property.", + "flatPath": "v1alpha/properties/{propertiesId}:submitUserDeletion", + "httpMethod": "POST", + "id": "analyticsadmin.properties.submitUserDeletion", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Required. The name of the property to submit user deletion for.", + "location": "path", + "pattern": "^properties/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1alpha/{+name}:submitUserDeletion", + "request": { + "$ref": "GoogleAnalyticsAdminV1alphaSubmitUserDeletionRequest" + }, + "response": { + "$ref": "GoogleAnalyticsAdminV1alphaSubmitUserDeletionResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/analytics.edit" + ] + }, "updateAttributionSettings": { "description": "Updates attribution settings on a property.", "flatPath": "v1alpha/properties/{propertiesId}/attributionSettings", @@ -5058,7 +5086,7 @@ } } }, - "revision": "20250713", + "revision": "20250723", "rootUrl": "https://analyticsadmin.googleapis.com/", "schemas": { "GoogleAnalyticsAdminV1alphaAccessBetweenFilter": { @@ -9127,6 +9155,41 @@ }, "type": "object" }, + "GoogleAnalyticsAdminV1alphaSubmitUserDeletionRequest": { + "description": "Request message for SubmitUserDeletion RPC.", + "id": "GoogleAnalyticsAdminV1alphaSubmitUserDeletionRequest", + "properties": { + "appInstanceId": { + "description": "Firebase [application instance ID](https://firebase.google.com/docs/reference/android/com/google/firebase/analytics/FirebaseAnalytics.html#getAppInstanceId).", + "type": "string" + }, + "clientId": { + "description": "Google Analytics [client ID](https://support.google.com/analytics/answer/11593727).", + "type": "string" + }, + "userId": { + "description": "Google Analytics [user ID](https://firebase.google.com/docs/analytics/userid).", + "type": "string" + }, + "userProvidedData": { + "description": "[User-provided data](https://support.google.com/analytics/answer/14077171). May contain either one email address or one phone number. Email addresses should be normalized as such: * lowercase * remove periods before @ for gmail.com/googlemail.com addresses * remove all spaces Phone numbers should be normalized as such: * remove all non digit characters * add + prefix", + "type": "string" + } + }, + "type": "object" + }, + "GoogleAnalyticsAdminV1alphaSubmitUserDeletionResponse": { + "description": "Response message for SubmitUserDeletion RPC.", + "id": "GoogleAnalyticsAdminV1alphaSubmitUserDeletionResponse", + "properties": { + "deletionRequestTime": { + "description": "Marks the moment for which all visitor data before this point should be deleted. This is set to the time at which the deletion request was received.", + "format": "google-datetime", + "type": "string" + } + }, + "type": "object" + }, "GoogleAnalyticsAdminV1alphaSubpropertyEventFilter": { "description": "A resource message representing a Google Analytics subproperty event filter.", "id": "GoogleAnalyticsAdminV1alphaSubpropertyEventFilter", diff --git a/analyticsadmin/v1alpha/analyticsadmin-gen.go b/analyticsadmin/v1alpha/analyticsadmin-gen.go index 208e3a34575..9f9d82c0aa1 100644 --- a/analyticsadmin/v1alpha/analyticsadmin-gen.go +++ b/analyticsadmin/v1alpha/analyticsadmin-gen.go @@ -5986,6 +5986,71 @@ func (s GoogleAnalyticsAdminV1alphaSearchChangeHistoryEventsResponse) MarshalJSO return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleAnalyticsAdminV1alphaSubmitUserDeletionRequest: Request message for +// SubmitUserDeletion RPC. +type GoogleAnalyticsAdminV1alphaSubmitUserDeletionRequest struct { + // AppInstanceId: Firebase application instance ID + // (https://firebase.google.com/docs/reference/android/com/google/firebase/analytics/FirebaseAnalytics.html#getAppInstanceId). + AppInstanceId string `json:"appInstanceId,omitempty"` + // ClientId: Google Analytics client ID + // (https://support.google.com/analytics/answer/11593727). + ClientId string `json:"clientId,omitempty"` + // UserId: Google Analytics user ID + // (https://firebase.google.com/docs/analytics/userid). + UserId string `json:"userId,omitempty"` + // UserProvidedData: User-provided data + // (https://support.google.com/analytics/answer/14077171). May contain either + // one email address or one phone number. Email addresses should be normalized + // as such: * lowercase * remove periods before @ for gmail.com/googlemail.com + // addresses * remove all spaces Phone numbers should be normalized as such: * + // remove all non digit characters * add + prefix + UserProvidedData string `json:"userProvidedData,omitempty"` + // ForceSendFields is a list of field names (e.g. "AppInstanceId") 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. "AppInstanceId") 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 GoogleAnalyticsAdminV1alphaSubmitUserDeletionRequest) MarshalJSON() ([]byte, error) { + type NoMethod GoogleAnalyticsAdminV1alphaSubmitUserDeletionRequest + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleAnalyticsAdminV1alphaSubmitUserDeletionResponse: Response message for +// SubmitUserDeletion RPC. +type GoogleAnalyticsAdminV1alphaSubmitUserDeletionResponse struct { + // DeletionRequestTime: Marks the moment for which all visitor data before this + // point should be deleted. This is set to the time at which the deletion + // request was received. + DeletionRequestTime string `json:"deletionRequestTime,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the server. + googleapi.ServerResponse `json:"-"` + // ForceSendFields is a list of field names (e.g. "DeletionRequestTime") 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. "DeletionRequestTime") 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 GoogleAnalyticsAdminV1alphaSubmitUserDeletionResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleAnalyticsAdminV1alphaSubmitUserDeletionResponse + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleAnalyticsAdminV1alphaSubpropertyEventFilter: A resource message // representing a Google Analytics subproperty event filter. type GoogleAnalyticsAdminV1alphaSubpropertyEventFilter struct { @@ -9879,6 +9944,110 @@ func (c *PropertiesRunAccessReportCall) Do(opts ...googleapi.CallOption) (*Googl return ret, nil } +type PropertiesSubmitUserDeletionCall struct { + s *Service + name string + googleanalyticsadminv1alphasubmituserdeletionrequest *GoogleAnalyticsAdminV1alphaSubmitUserDeletionRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// SubmitUserDeletion: Submits a request for user deletion for a property. +// +// - name: The name of the property to submit user deletion for. +func (r *PropertiesService) SubmitUserDeletion(name string, googleanalyticsadminv1alphasubmituserdeletionrequest *GoogleAnalyticsAdminV1alphaSubmitUserDeletionRequest) *PropertiesSubmitUserDeletionCall { + c := &PropertiesSubmitUserDeletionCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + c.googleanalyticsadminv1alphasubmituserdeletionrequest = googleanalyticsadminv1alphasubmituserdeletionrequest + 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 *PropertiesSubmitUserDeletionCall) Fields(s ...googleapi.Field) *PropertiesSubmitUserDeletionCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *PropertiesSubmitUserDeletionCall) Context(ctx context.Context) *PropertiesSubmitUserDeletionCall { + 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 *PropertiesSubmitUserDeletionCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *PropertiesSubmitUserDeletionCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) + body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.googleanalyticsadminv1alphasubmituserdeletionrequest) + if err != nil { + return nil, err + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+name}:submitUserDeletion") + 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, + }) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "analyticsadmin.properties.submitUserDeletion", "request", internallog.HTTPRequest(req, body.Bytes())) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "analyticsadmin.properties.submitUserDeletion" call. +// Any non-2xx status code is an error. Response headers are in either +// *GoogleAnalyticsAdminV1alphaSubmitUserDeletionResponse.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 *PropertiesSubmitUserDeletionCall) Do(opts ...googleapi.CallOption) (*GoogleAnalyticsAdminV1alphaSubmitUserDeletionResponse, 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 := &GoogleAnalyticsAdminV1alphaSubmitUserDeletionResponse{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + b, err := gensupport.DecodeResponseBytes(target, res) + if err != nil { + return nil, err + } + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "analyticsadmin.properties.submitUserDeletion", "response", internallog.HTTPResponse(res, b)) + return ret, nil +} + type PropertiesUpdateAttributionSettingsCall struct { s *Service name string diff --git a/androidpublisher/v3/androidpublisher-api.json b/androidpublisher/v3/androidpublisher-api.json index ed40c60f397..4515c25333a 100644 --- a/androidpublisher/v3/androidpublisher-api.json +++ b/androidpublisher/v3/androidpublisher-api.json @@ -5521,7 +5521,7 @@ } } }, - "revision": "20250719", + "revision": "20250724", "rootUrl": "https://androidpublisher.googleapis.com/", "schemas": { "Abi": { @@ -9374,13 +9374,15 @@ "AVAILABILITY_UNSPECIFIED", "AVAILABLE", "NO_LONGER_AVAILABLE", - "AVAILABLE_IF_RELEASED" + "AVAILABLE_IF_RELEASED", + "AVAILABLE_FOR_OFFERS_ONLY" ], "enumDescriptions": [ "Unspecified availability. Must not be used.", "The purchase option is available to users.", "The purchase option is no longer available to users. This value can only be used if the availability was previously set as AVAILABLE.", - "The purchase option is initially unavailable, but made available via a released pre-order offer." + "The purchase option is initially unavailable, but made available via a released pre-order offer.", + "The purchase option is unavailable but offers linked to it (i.e. Play Points offer) are available." ], "type": "string" }, diff --git a/androidpublisher/v3/androidpublisher-gen.go b/androidpublisher/v3/androidpublisher-gen.go index a2b312edfff..883088e2924 100644 --- a/androidpublisher/v3/androidpublisher-gen.go +++ b/androidpublisher/v3/androidpublisher-gen.go @@ -5721,6 +5721,8 @@ type OneTimeProductPurchaseOptionRegionalPricingAndAvailabilityConfig struct { // AVAILABLE. // "AVAILABLE_IF_RELEASED" - The purchase option is initially unavailable, // but made available via a released pre-order offer. + // "AVAILABLE_FOR_OFFERS_ONLY" - The purchase option is unavailable but + // offers linked to it (i.e. Play Points offer) are available. Availability string `json:"availability,omitempty"` // Price: The price of the purchase option in the specified region. Must be set // in the currency that is linked to the specified region. diff --git a/backupdr/v1/backupdr-api.json b/backupdr/v1/backupdr-api.json index 8111e0d01f6..09568a99845 100644 --- a/backupdr/v1/backupdr-api.json +++ b/backupdr/v1/backupdr-api.json @@ -2060,7 +2060,7 @@ } } }, - "revision": "20250711", + "revision": "20250720", "rootUrl": "https://backupdr.googleapis.com/", "schemas": { "AbandonBackupRequest": { @@ -2791,12 +2791,6 @@ "format": "google-datetime", "readOnly": true, "type": "string" - }, - "lastSuccessfulLogBackupConsistencyTime": { - "description": "Output only. If the last log backup were successful, this field has the consistency date.", - "format": "google-datetime", - "readOnly": true, - "type": "string" } }, "type": "object" @@ -2905,7 +2899,7 @@ "id": "BackupPlan", "properties": { "backupRules": { - "description": "Required. The backup rules for this `BackupPlan`. There must be at least one `BackupRule` message.", + "description": "Optional. The backup rules for this `BackupPlan`. There must be at least one `BackupRule` message if on_demand_retention_limit_days is not set.", "items": { "$ref": "BackupRule" }, diff --git a/backupdr/v1/backupdr-gen.go b/backupdr/v1/backupdr-gen.go index 3b548374bd6..f3792421363 100644 --- a/backupdr/v1/backupdr-gen.go +++ b/backupdr/v1/backupdr-gen.go @@ -1003,9 +1003,6 @@ type BackupConfigInfo struct { // LastSuccessfulBackupConsistencyTime: Output only. If the last backup were // successful, this field has the consistency date. LastSuccessfulBackupConsistencyTime string `json:"lastSuccessfulBackupConsistencyTime,omitempty"` - // LastSuccessfulLogBackupConsistencyTime: Output only. If the last log backup - // were successful, this field has the consistency date. - LastSuccessfulLogBackupConsistencyTime string `json:"lastSuccessfulLogBackupConsistencyTime,omitempty"` // ForceSendFields is a list of field names (e.g. // "BackupApplianceBackupConfig") to unconditionally include in API requests. // By default, fields with empty or default values are omitted from API @@ -1167,8 +1164,9 @@ func (s BackupLock) MarshalJSON() ([]byte, error) { // `BackupRule` has a retention policy and defines a schedule by which the // system is to perform backup workloads. type BackupPlan struct { - // BackupRules: Required. The backup rules for this `BackupPlan`. There must be - // at least one `BackupRule` message. + // BackupRules: Optional. The backup rules for this `BackupPlan`. There must be + // at least one `BackupRule` message if on_demand_retention_limit_days is not + // set. BackupRules []*BackupRule `json:"backupRules,omitempty"` // BackupVault: Required. Resource name of backup vault which will be used as // storage location for backups. Format: diff --git a/discoveryengine/v1/discoveryengine-api.json b/discoveryengine/v1/discoveryengine-api.json index 7ff6c914883..3d74a961f57 100644 --- a/discoveryengine/v1/discoveryengine-api.json +++ b/discoveryengine/v1/discoveryengine-api.json @@ -3196,6 +3196,65 @@ "resources": { "assistants": { "methods": { + "get": { + "description": "Gets an Assistant.", + "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/engines/{enginesId}/assistants/{assistantsId}", + "httpMethod": "GET", + "id": "discoveryengine.projects.locations.collections.engines.assistants.get", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Required. Resource name of Assistant. Format: `projects/{project}/locations/{location}/collections/{collection}/engines/{engine}/assistants/{assistant}`", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/engines/[^/]+/assistants/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1/{+name}", + "response": { + "$ref": "GoogleCloudDiscoveryengineV1Assistant" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "patch": { + "description": "Updates an Assistant", + "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/engines/{enginesId}/assistants/{assistantsId}", + "httpMethod": "PATCH", + "id": "discoveryengine.projects.locations.collections.engines.assistants.patch", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Immutable. Resource name of the assistant. Format: `projects/{project}/locations/{location}/collections/{collection}/engines/{engine}/assistants/{assistant}` It must be a UTF-8 encoded string with a length limit of 1024 characters.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/engines/[^/]+/assistants/[^/]+$", + "required": true, + "type": "string" + }, + "updateMask": { + "description": "The list of fields to update.", + "format": "google-fieldmask", + "location": "query", + "type": "string" + } + }, + "path": "v1/{+name}", + "request": { + "$ref": "GoogleCloudDiscoveryengineV1Assistant" + }, + "response": { + "$ref": "GoogleCloudDiscoveryengineV1Assistant" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, "streamAssist": { "description": "Assists the user with a query in a streaming fashion.", "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/engines/{enginesId}/assistants/{assistantsId}:streamAssist", @@ -7191,7 +7250,7 @@ } } }, - "revision": "20250723", + "revision": "20250724", "rootUrl": "https://discoveryengine.googleapis.com/", "schemas": { "GoogleApiDistribution": { diff --git a/discoveryengine/v1/discoveryengine-gen.go b/discoveryengine/v1/discoveryengine-gen.go index 7ab0746fccc..d29fed7b460 100644 --- a/discoveryengine/v1/discoveryengine-gen.go +++ b/discoveryengine/v1/discoveryengine-gen.go @@ -3966,6 +3966,9 @@ type GoogleCloudDiscoveryengineV1Assistant struct { // gine}/assistants/{assistant}` It must be a UTF-8 encoded string with a // length limit of 1024 characters. Name string `json:"name,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the server. + googleapi.ServerResponse `json:"-"` // ForceSendFields is a list of field names (e.g. "Name") to unconditionally // include in API requests. By default, fields with empty or default values are // omitted from API requests. See @@ -37787,6 +37790,232 @@ func (c *ProjectsLocationsCollectionsEnginesPatchCall) Do(opts ...googleapi.Call return ret, nil } +type ProjectsLocationsCollectionsEnginesAssistantsGetCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// Get: Gets an Assistant. +// +// - name: Resource name of Assistant. Format: +// `projects/{project}/locations/{location}/collections/{collection}/engines/{ +// engine}/assistants/{assistant}`. +func (r *ProjectsLocationsCollectionsEnginesAssistantsService) Get(name string) *ProjectsLocationsCollectionsEnginesAssistantsGetCall { + c := &ProjectsLocationsCollectionsEnginesAssistantsGetCall{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 *ProjectsLocationsCollectionsEnginesAssistantsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsEnginesAssistantsGetCall { + 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 *ProjectsLocationsCollectionsEnginesAssistantsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsCollectionsEnginesAssistantsGetCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsCollectionsEnginesAssistantsGetCall) Context(ctx context.Context) *ProjectsLocationsCollectionsEnginesAssistantsGetCall { + 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 *ProjectsLocationsCollectionsEnginesAssistantsGetCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsCollectionsEnginesAssistantsGetCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) + } + 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, nil) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "name": c.name, + }) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "discoveryengine.projects.locations.collections.engines.assistants.get", "request", internallog.HTTPRequest(req, nil)) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "discoveryengine.projects.locations.collections.engines.assistants.get" call. +// Any non-2xx status code is an error. Response headers are in either +// *GoogleCloudDiscoveryengineV1Assistant.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 *ProjectsLocationsCollectionsEnginesAssistantsGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1Assistant, 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 := &GoogleCloudDiscoveryengineV1Assistant{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + b, err := gensupport.DecodeResponseBytes(target, res) + if err != nil { + return nil, err + } + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "discoveryengine.projects.locations.collections.engines.assistants.get", "response", internallog.HTTPResponse(res, b)) + return ret, nil +} + +type ProjectsLocationsCollectionsEnginesAssistantsPatchCall struct { + s *Service + name string + googleclouddiscoveryenginev1assistant *GoogleCloudDiscoveryengineV1Assistant + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Patch: Updates an Assistant +// +// - name: Immutable. Resource name of the assistant. Format: +// `projects/{project}/locations/{location}/collections/{collection}/engines/{ +// engine}/assistants/{assistant}` It must be a UTF-8 encoded string with a +// length limit of 1024 characters. +func (r *ProjectsLocationsCollectionsEnginesAssistantsService) Patch(name string, googleclouddiscoveryenginev1assistant *GoogleCloudDiscoveryengineV1Assistant) *ProjectsLocationsCollectionsEnginesAssistantsPatchCall { + c := &ProjectsLocationsCollectionsEnginesAssistantsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + c.googleclouddiscoveryenginev1assistant = googleclouddiscoveryenginev1assistant + return c +} + +// UpdateMask sets the optional parameter "updateMask": The list of fields to +// update. +func (c *ProjectsLocationsCollectionsEnginesAssistantsPatchCall) UpdateMask(updateMask string) *ProjectsLocationsCollectionsEnginesAssistantsPatchCall { + 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 *ProjectsLocationsCollectionsEnginesAssistantsPatchCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsEnginesAssistantsPatchCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsCollectionsEnginesAssistantsPatchCall) Context(ctx context.Context) *ProjectsLocationsCollectionsEnginesAssistantsPatchCall { + 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 *ProjectsLocationsCollectionsEnginesAssistantsPatchCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsCollectionsEnginesAssistantsPatchCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) + body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.googleclouddiscoveryenginev1assistant) + if err != nil { + return nil, err + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("PATCH", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "name": c.name, + }) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "discoveryengine.projects.locations.collections.engines.assistants.patch", "request", internallog.HTTPRequest(req, body.Bytes())) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "discoveryengine.projects.locations.collections.engines.assistants.patch" call. +// Any non-2xx status code is an error. Response headers are in either +// *GoogleCloudDiscoveryengineV1Assistant.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 *ProjectsLocationsCollectionsEnginesAssistantsPatchCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1Assistant, 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 := &GoogleCloudDiscoveryengineV1Assistant{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + b, err := gensupport.DecodeResponseBytes(target, res) + if err != nil { + return nil, err + } + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "discoveryengine.projects.locations.collections.engines.assistants.patch", "response", internallog.HTTPResponse(res, b)) + return ret, nil +} + type ProjectsLocationsCollectionsEnginesAssistantsStreamAssistCall struct { s *Service name string diff --git a/discoveryengine/v1alpha/discoveryengine-api.json b/discoveryengine/v1alpha/discoveryengine-api.json index 185074f1d3a..d3446351057 100644 --- a/discoveryengine/v1alpha/discoveryengine-api.json +++ b/discoveryengine/v1alpha/discoveryengine-api.json @@ -137,45 +137,42 @@ "resources": { "media": { "methods": { - "upload": { - "description": "Uploads a file for Notebook LM to use. Creates a Source.", - "flatPath": "v1alpha/projects/{projectsId}/locations/{locationsId}/notebooks/{notebooksId}/sources:uploadFile", - "httpMethod": "POST", - "id": "discoveryengine.media.upload", - "mediaUpload": { - "accept": [ - "*/*" - ], - "protocols": { - "simple": { - "multipart": true, - "path": "/upload/v1alpha/{+parent}/sources:uploadFile" - } - } - }, + "download": { + "description": "Downloads a file from the session.", + "flatPath": "v1alpha/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/engines/{enginesId}/sessions/{sessionsId}:downloadFile", + "httpMethod": "GET", + "id": "discoveryengine.media.download", "parameterOrder": [ - "parent" + "name" ], "parameters": { - "parent": { - "description": "Required. The parent resource where the sources will be created. Format: projects/{project}/locations/{location}/notebooks/{notebook}", + "fileId": { + "description": "Required. The ID of the file to be downloaded.", + "location": "query", + "type": "string" + }, + "name": { + "description": "Required. The resource name of the Session. Format: `projects/{project}/locations/{location}/collections/{collection}/engines/{engine}/sessions/{session}`", "location": "path", - "pattern": "^projects/[^/]+/locations/[^/]+/notebooks/[^/]+$", + "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/engines/[^/]+/sessions/[^/]+$", "required": true, "type": "string" + }, + "viewId": { + "description": "Optional. The ID of the view to be downloaded.", + "location": "query", + "type": "string" } }, - "path": "v1alpha/{+parent}/sources:uploadFile", - "request": { - "$ref": "GoogleCloudNotebooklmV1alphaUploadSourceFileRequest" - }, + "path": "v1alpha/{+name}:downloadFile", "response": { - "$ref": "GoogleCloudNotebooklmV1alphaUploadSourceFileResponse" + "$ref": "GdataMedia" }, "scopes": [ "https://www.googleapis.com/auth/cloud-platform" ], - "supportsMediaUpload": true + "supportsMediaDownload": true, + "useMediaDownloadService": true } } }, @@ -4220,6 +4217,65 @@ "resources": { "assistants": { "methods": { + "get": { + "description": "Gets an Assistant.", + "flatPath": "v1alpha/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/engines/{enginesId}/assistants/{assistantsId}", + "httpMethod": "GET", + "id": "discoveryengine.projects.locations.collections.engines.assistants.get", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Required. Resource name of Assistant. Format: `projects/{project}/locations/{location}/collections/{collection}/engines/{engine}/assistants/{assistant}`", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/engines/[^/]+/assistants/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1alpha/{+name}", + "response": { + "$ref": "GoogleCloudDiscoveryengineV1alphaAssistant" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "patch": { + "description": "Updates an Assistant", + "flatPath": "v1alpha/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/engines/{enginesId}/assistants/{assistantsId}", + "httpMethod": "PATCH", + "id": "discoveryengine.projects.locations.collections.engines.assistants.patch", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Immutable. Resource name of the assistant. Format: `projects/{project}/locations/{location}/collections/{collection}/engines/{engine}/assistants/{assistant}` It must be a UTF-8 encoded string with a length limit of 1024 characters.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/engines/[^/]+/assistants/[^/]+$", + "required": true, + "type": "string" + }, + "updateMask": { + "description": "The list of fields to update.", + "format": "google-fieldmask", + "location": "query", + "type": "string" + } + }, + "path": "v1alpha/{+name}", + "request": { + "$ref": "GoogleCloudDiscoveryengineV1alphaAssistant" + }, + "response": { + "$ref": "GoogleCloudDiscoveryengineV1alphaAssistant" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, "streamAssist": { "description": "Assists the user with a query in a streaming fashion.", "flatPath": "v1alpha/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/engines/{enginesId}/assistants/{assistantsId}:streamAssist", @@ -8386,9 +8442,75 @@ } }, "notebooks": { + "methods": { + "listRecentlyViewed": { + "description": "Lists the recently viewed notebooks. Needs a side channel with the user's EUC.", + "flatPath": "v1alpha/projects/{projectsId}/locations/{locationsId}/notebooks:listRecentlyViewed", + "httpMethod": "GET", + "id": "discoveryengine.projects.locations.notebooks.listRecentlyViewed", + "parameterOrder": [ + "parent" + ], + "parameters": { + "pageSize": { + "description": "Optional. Maximum number of Notebooks to return. If unspecified, defaults to \"200\". The maximum allowed value is \"500\". If this field is negative, will use the default value.", + "format": "int32", + "location": "query", + "type": "integer" + }, + "pageToken": { + "description": "Optional. The page token, provide this to retrieve the subsequent page.", + "location": "query", + "type": "string" + }, + "parent": { + "description": "Required. The parent branch resource name, such as `projects/{project}/locations/{location}`.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1alpha/{+parent}/notebooks:listRecentlyViewed", + "response": { + "$ref": "GoogleCloudNotebooklmV1alphaListRecentlyViewedNotebooksResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + } + }, "resources": { "sources": { "methods": { + "batchCreate": { + "description": "Creates a list of Sources.", + "flatPath": "v1alpha/projects/{projectsId}/locations/{locationsId}/notebooks/{notebooksId}/sources:batchCreate", + "httpMethod": "POST", + "id": "discoveryengine.projects.locations.notebooks.sources.batchCreate", + "parameterOrder": [ + "parent" + ], + "parameters": { + "parent": { + "description": "Required. The parent resource where the sources will be created. Format: projects/{project}/locations/{location}/notebooks/{notebook}", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/notebooks/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1alpha/{+parent}/sources:batchCreate", + "request": { + "$ref": "GoogleCloudNotebooklmV1alphaBatchCreateSourcesRequest" + }, + "response": { + "$ref": "GoogleCloudNotebooklmV1alphaBatchCreateSourcesResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, "uploadFile": { "description": "Uploads a file for Notebook LM to use. Creates a Source.", "flatPath": "v1alpha/projects/{projectsId}/locations/{locationsId}/notebooks/{notebooksId}/sources/{sourceId}:uploadFile", @@ -9298,7 +9420,7 @@ } } }, - "revision": "20250723", + "revision": "20250724", "rootUrl": "https://discoveryengine.googleapis.com/", "schemas": { "ApiservingMediaRequestInfo": { @@ -14782,6 +14904,17 @@ }, "type": "object" }, + "GoogleCloudDiscoveryengineV1alphaAssistant": { + "description": "Discovery Engine Assistant resource.", + "id": "GoogleCloudDiscoveryengineV1alphaAssistant", + "properties": { + "name": { + "description": "Immutable. Resource name of the assistant. Format: `projects/{project}/locations/{location}/collections/{collection}/engines/{engine}/assistants/{assistant}` It must be a UTF-8 encoded string with a length limit of 1024 characters.", + "type": "string" + } + }, + "type": "object" + }, "GoogleCloudDiscoveryengineV1alphaAssistantContent": { "description": "Multi-modal content.", "id": "GoogleCloudDiscoveryengineV1alphaAssistantContent", @@ -24628,6 +24761,36 @@ }, "type": "object" }, + "GoogleCloudDiscoveryengineV1alphaUploadSessionFileRequest": { + "description": "Request for the AssistantService.UploadSessionFile method.", + "id": "GoogleCloudDiscoveryengineV1alphaUploadSessionFileRequest", + "properties": { + "blob": { + "$ref": "GdataMedia", + "description": "Information about the file being uploaded." + }, + "mediaRequestInfo": { + "$ref": "ApiservingMediaRequestInfo", + "description": "Media upload request metadata." + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaUploadSessionFileResponse": { + "description": "Response for the AssistantService.UploadSessionFile method.", + "id": "GoogleCloudDiscoveryengineV1alphaUploadSessionFileResponse", + "properties": { + "fileId": { + "description": "The ID of the uploaded file.", + "type": "string" + }, + "mediaResponseInfo": { + "$ref": "ApiservingMediaResponseInfo", + "description": "Media upload response metadata." + } + }, + "type": "object" + }, "GoogleCloudDiscoveryengineV1alphaUserEvent": { "description": "UserEvent captures all metadata information Discovery Engine API needs to know about how end users interact with your website.", "id": "GoogleCloudDiscoveryengineV1alphaUserEvent", @@ -29084,6 +29247,145 @@ }, "type": "object" }, + "GoogleCloudNotebooklmV1alphaAgentspaceMetadata": { + "description": "Metadata about an agentspace source.", + "id": "GoogleCloudNotebooklmV1alphaAgentspaceMetadata", + "properties": { + "documentName": { + "description": "Output only. The full document name in Agentspace.", + "readOnly": true, + "type": "string" + }, + "documentTitle": { + "description": "Output only. The title of the document.", + "readOnly": true, + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudNotebooklmV1alphaBatchCreateSourcesRequest": { + "description": "Request for SourceService.BatchCreateSources method.", + "id": "GoogleCloudNotebooklmV1alphaBatchCreateSourcesRequest", + "properties": { + "userContents": { + "description": "Required. The UserContents to be uploaded.", + "items": { + "$ref": "GoogleCloudNotebooklmV1alphaUserContent" + }, + "type": "array" + } + }, + "type": "object" + }, + "GoogleCloudNotebooklmV1alphaBatchCreateSourcesResponse": { + "description": "Response for SourceService.BatchCreateSources method.", + "id": "GoogleCloudNotebooklmV1alphaBatchCreateSourcesResponse", + "properties": { + "sources": { + "description": "The Sources.", + "items": { + "$ref": "GoogleCloudNotebooklmV1alphaSource" + }, + "type": "array" + } + }, + "type": "object" + }, + "GoogleCloudNotebooklmV1alphaListRecentlyViewedNotebooksResponse": { + "description": "Response for NotebookService.ListRecentlyViewedNotebooks method.", + "id": "GoogleCloudNotebooklmV1alphaListRecentlyViewedNotebooksResponse", + "properties": { + "nextPageToken": { + "description": "The page token, provide this to retrieve the subsequent page.", + "type": "string" + }, + "notebooks": { + "description": "The list of recently viewed notebooks.", + "items": { + "$ref": "GoogleCloudNotebooklmV1alphaNotebook" + }, + "type": "array" + } + }, + "type": "object" + }, + "GoogleCloudNotebooklmV1alphaNotebook": { + "description": "Notebook is a resource where users can store their content (as sources) and interacts with the content.", + "id": "GoogleCloudNotebooklmV1alphaNotebook", + "properties": { + "emoji": { + "description": "Output only. The emoji of the notebook.", + "readOnly": true, + "type": "string" + }, + "metadata": { + "$ref": "GoogleCloudNotebooklmV1alphaNotebookMetadata", + "description": "The metadata of the notebook." + }, + "name": { + "description": "Identifier. The identifier of the notebook. Format: `projects/{project}/locations/{location}/notebooks/{notebook_id}`. This field must be a UTF-8 encoded string.", + "type": "string" + }, + "notebookId": { + "description": "Optional. Notebook id, which is the last segment of the notebook's resource name. This is to make it similar with notebooklm API.", + "type": "string" + }, + "title": { + "description": "Optional. The title of the notebook.", + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudNotebooklmV1alphaNotebookMetadata": { + "description": "Metadata for a notebook.", + "id": "GoogleCloudNotebooklmV1alphaNotebookMetadata", + "properties": { + "createTime": { + "description": "The time at which this project was created.", + "format": "google-datetime", + "type": "string" + }, + "isShareable": { + "description": "True if the project is shareable.", + "type": "boolean" + }, + "isShared": { + "description": "True if this project is currently shared with other people, false otherwise.", + "type": "boolean" + }, + "lastViewed": { + "description": "A timestamp indicating the time that the current in session user has last viewed the project.", + "format": "google-datetime", + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudNotebooklmV1alphaSource": { + "description": "Source represents a single source of content.", + "id": "GoogleCloudNotebooklmV1alphaSource", + "properties": { + "metadata": { + "$ref": "GoogleCloudNotebooklmV1alphaSourceMetadata", + "description": "Metadata about the source." + }, + "name": { + "description": "Identifier. The full resource name of the source. Format: `projects/{project}/locations/{location}/notebooks/{notebook}/sources/{source_id}`. This field must be a UTF-8 encoded string with a length limit of 1024 characters.", + "type": "string" + }, + "sourceId": { + "$ref": "GoogleCloudNotebooklmV1alphaSourceId", + "description": "Optional. Source id, which is the last segment of the source's resource name. This is to make it similar with notebooklm API." + }, + "title": { + "description": "Optional. Title of the source.", + "type": "string" + } + }, + "type": "object" + }, "GoogleCloudNotebooklmV1alphaSourceId": { "description": "SourceId is the last segment of the source's resource name.", "id": "GoogleCloudNotebooklmV1alphaSourceId", @@ -29095,6 +29397,32 @@ }, "type": "object" }, + "GoogleCloudNotebooklmV1alphaSourceMetadata": { + "description": "Represents the metadata of a source and some additional information.", + "id": "GoogleCloudNotebooklmV1alphaSourceMetadata", + "properties": { + "agentspaceMetadata": { + "$ref": "GoogleCloudNotebooklmV1alphaAgentspaceMetadata", + "description": "Metadata for an agentspace source." + }, + "sourceAddedTimestamp": { + "description": "The timestamp the source was added.", + "format": "google-datetime", + "type": "string" + }, + "tokenCount": { + "description": "The number of tokens in the source.", + "format": "int32", + "type": "integer" + }, + "wordCount": { + "description": "The word count of the source.", + "format": "int32", + "type": "integer" + } + }, + "type": "object" + }, "GoogleCloudNotebooklmV1alphaUploadSourceFileRequest": { "description": "Request for the SourceService.UploadSourceFile method.", "id": "GoogleCloudNotebooklmV1alphaUploadSourceFileRequest", @@ -29129,6 +29457,36 @@ }, "type": "object" }, + "GoogleCloudNotebooklmV1alphaUserContent": { + "description": "The \"Content\" messages refer to data the user wants to upload.", + "id": "GoogleCloudNotebooklmV1alphaUserContent", + "properties": { + "agentspaceContent": { + "$ref": "GoogleCloudNotebooklmV1alphaUserContentAgentspaceContent", + "description": "Agentspace content uploaded as source." + } + }, + "type": "object" + }, + "GoogleCloudNotebooklmV1alphaUserContentAgentspaceContent": { + "description": "Agentspace content uploaded as source.", + "id": "GoogleCloudNotebooklmV1alphaUserContentAgentspaceContent", + "properties": { + "documentName": { + "description": "Optional. The full document name in Agentspace.", + "type": "string" + }, + "engineName": { + "description": "Optional. Engine to verify the permission of the document.", + "type": "string" + }, + "ideaforgeIdeaName": { + "description": "Optional. The full idea name for IdeaForge.", + "type": "string" + } + }, + "type": "object" + }, "GoogleLongrunningCancelOperationRequest": { "description": "The request message for Operations.CancelOperation.", "id": "GoogleLongrunningCancelOperationRequest", diff --git a/discoveryengine/v1alpha/discoveryengine-gen.go b/discoveryengine/v1alpha/discoveryengine-gen.go index 71508f957b7..99183fd32b9 100644 --- a/discoveryengine/v1alpha/discoveryengine-gen.go +++ b/discoveryengine/v1alpha/discoveryengine-gen.go @@ -1853,6 +1853,9 @@ type GdataMedia struct { Timestamp uint64 `json:"timestamp,omitempty,string"` // Token: A unique fingerprint/version id for the media data Token string `json:"token,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the server. + googleapi.ServerResponse `json:"-"` // ForceSendFields is a list of field names (e.g. "Algorithm") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See @@ -8695,6 +8698,35 @@ func (s GoogleCloudDiscoveryengineV1alphaAssistUserMetadata) MarshalJSON() ([]by return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudDiscoveryengineV1alphaAssistant: Discovery Engine Assistant +// resource. +type GoogleCloudDiscoveryengineV1alphaAssistant struct { + // Name: Immutable. Resource name of the assistant. Format: + // `projects/{project}/locations/{location}/collections/{collection}/engines/{en + // gine}/assistants/{assistant}` It must be a UTF-8 encoded string with a + // length limit of 1024 characters. + Name string `json:"name,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the server. + googleapi.ServerResponse `json:"-"` + // ForceSendFields is a list of field names (e.g. "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. "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 GoogleCloudDiscoveryengineV1alphaAssistant) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaAssistant + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudDiscoveryengineV1alphaAssistantContent: Multi-modal content. type GoogleCloudDiscoveryengineV1alphaAssistantContent struct { // CodeExecutionResult: Result of executing an ExecutableCode. @@ -22360,6 +22392,56 @@ func (s GoogleCloudDiscoveryengineV1alphaUpdateTargetSiteMetadata) MarshalJSON() return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudDiscoveryengineV1alphaUploadSessionFileRequest: Request for the +// AssistantService.UploadSessionFile method. +type GoogleCloudDiscoveryengineV1alphaUploadSessionFileRequest struct { + // Blob: Information about the file being uploaded. + Blob *GdataMedia `json:"blob,omitempty"` + // MediaRequestInfo: Media upload request metadata. + MediaRequestInfo *ApiservingMediaRequestInfo `json:"mediaRequestInfo,omitempty"` + // ForceSendFields is a list of field names (e.g. "Blob") 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. "Blob") 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 GoogleCloudDiscoveryengineV1alphaUploadSessionFileRequest) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaUploadSessionFileRequest + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaUploadSessionFileResponse: Response for the +// AssistantService.UploadSessionFile method. +type GoogleCloudDiscoveryengineV1alphaUploadSessionFileResponse struct { + // FileId: The ID of the uploaded file. + FileId string `json:"fileId,omitempty"` + // MediaResponseInfo: Media upload response metadata. + MediaResponseInfo *ApiservingMediaResponseInfo `json:"mediaResponseInfo,omitempty"` + // ForceSendFields is a list of field names (e.g. "FileId") 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. "FileId") 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 GoogleCloudDiscoveryengineV1alphaUploadSessionFileResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaUploadSessionFileResponse + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudDiscoveryengineV1alphaUserEvent: UserEvent captures all metadata // information Discovery Engine API needs to know about how end users interact // with your website. @@ -28323,6 +28405,205 @@ func (s GoogleCloudDiscoveryengineV1betaWorkspaceConfig) MarshalJSON() ([]byte, return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudNotebooklmV1alphaAgentspaceMetadata: Metadata about an agentspace +// source. +type GoogleCloudNotebooklmV1alphaAgentspaceMetadata struct { + // DocumentName: Output only. The full document name in Agentspace. + DocumentName string `json:"documentName,omitempty"` + // DocumentTitle: Output only. The title of the document. + DocumentTitle string `json:"documentTitle,omitempty"` + // ForceSendFields is a list of field names (e.g. "DocumentName") 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. "DocumentName") 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 GoogleCloudNotebooklmV1alphaAgentspaceMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudNotebooklmV1alphaAgentspaceMetadata + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudNotebooklmV1alphaBatchCreateSourcesRequest: Request for +// SourceService.BatchCreateSources method. +type GoogleCloudNotebooklmV1alphaBatchCreateSourcesRequest struct { + // UserContents: Required. The UserContents to be uploaded. + UserContents []*GoogleCloudNotebooklmV1alphaUserContent `json:"userContents,omitempty"` + // ForceSendFields is a list of field names (e.g. "UserContents") 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. "UserContents") 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 GoogleCloudNotebooklmV1alphaBatchCreateSourcesRequest) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudNotebooklmV1alphaBatchCreateSourcesRequest + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudNotebooklmV1alphaBatchCreateSourcesResponse: Response for +// SourceService.BatchCreateSources method. +type GoogleCloudNotebooklmV1alphaBatchCreateSourcesResponse struct { + // Sources: The Sources. + Sources []*GoogleCloudNotebooklmV1alphaSource `json:"sources,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the server. + googleapi.ServerResponse `json:"-"` + // ForceSendFields is a list of field names (e.g. "Sources") 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. "Sources") 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 GoogleCloudNotebooklmV1alphaBatchCreateSourcesResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudNotebooklmV1alphaBatchCreateSourcesResponse + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudNotebooklmV1alphaListRecentlyViewedNotebooksResponse: Response +// for NotebookService.ListRecentlyViewedNotebooks method. +type GoogleCloudNotebooklmV1alphaListRecentlyViewedNotebooksResponse struct { + // NextPageToken: The page token, provide this to retrieve the subsequent page. + NextPageToken string `json:"nextPageToken,omitempty"` + // Notebooks: The list of recently viewed notebooks. + Notebooks []*GoogleCloudNotebooklmV1alphaNotebook `json:"notebooks,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 GoogleCloudNotebooklmV1alphaListRecentlyViewedNotebooksResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudNotebooklmV1alphaListRecentlyViewedNotebooksResponse + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudNotebooklmV1alphaNotebook: Notebook is a resource where users can +// store their content (as sources) and interacts with the content. +type GoogleCloudNotebooklmV1alphaNotebook struct { + // Emoji: Output only. The emoji of the notebook. + Emoji string `json:"emoji,omitempty"` + // Metadata: The metadata of the notebook. + Metadata *GoogleCloudNotebooklmV1alphaNotebookMetadata `json:"metadata,omitempty"` + // Name: Identifier. The identifier of the notebook. Format: + // `projects/{project}/locations/{location}/notebooks/{notebook_id}`. This + // field must be a UTF-8 encoded string. + Name string `json:"name,omitempty"` + // NotebookId: Optional. Notebook id, which is the last segment of the + // notebook's resource name. This is to make it similar with notebooklm API. + NotebookId string `json:"notebookId,omitempty"` + // Title: Optional. The title of the notebook. + Title string `json:"title,omitempty"` + // ForceSendFields is a list of field names (e.g. "Emoji") 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. "Emoji") 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 GoogleCloudNotebooklmV1alphaNotebook) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudNotebooklmV1alphaNotebook + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudNotebooklmV1alphaNotebookMetadata: Metadata for a notebook. +type GoogleCloudNotebooklmV1alphaNotebookMetadata struct { + // CreateTime: The time at which this project was created. + CreateTime string `json:"createTime,omitempty"` + // IsShareable: True if the project is shareable. + IsShareable bool `json:"isShareable,omitempty"` + // IsShared: True if this project is currently shared with other people, false + // otherwise. + IsShared bool `json:"isShared,omitempty"` + // LastViewed: A timestamp indicating the time that the current in session user + // has last viewed the project. + LastViewed string `json:"lastViewed,omitempty"` + // 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 GoogleCloudNotebooklmV1alphaNotebookMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudNotebooklmV1alphaNotebookMetadata + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudNotebooklmV1alphaSource: Source represents a single source of +// content. +type GoogleCloudNotebooklmV1alphaSource struct { + // Metadata: Metadata about the source. + Metadata *GoogleCloudNotebooklmV1alphaSourceMetadata `json:"metadata,omitempty"` + // Name: Identifier. The full resource name of the source. Format: + // `projects/{project}/locations/{location}/notebooks/{notebook}/sources/{source + // _id}`. This field must be a UTF-8 encoded string with a length limit of 1024 + // characters. + Name string `json:"name,omitempty"` + // SourceId: Optional. Source id, which is the last segment of the source's + // resource name. This is to make it similar with notebooklm API. + SourceId *GoogleCloudNotebooklmV1alphaSourceId `json:"sourceId,omitempty"` + // Title: Optional. Title of the source. + Title string `json:"title,omitempty"` + // ForceSendFields is a list of field names (e.g. "Metadata") 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. "Metadata") 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 GoogleCloudNotebooklmV1alphaSource) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudNotebooklmV1alphaSource + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudNotebooklmV1alphaSourceId: SourceId is the last segment of the // source's resource name. type GoogleCloudNotebooklmV1alphaSourceId struct { @@ -28346,6 +28627,35 @@ func (s GoogleCloudNotebooklmV1alphaSourceId) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudNotebooklmV1alphaSourceMetadata: Represents the metadata of a +// source and some additional information. +type GoogleCloudNotebooklmV1alphaSourceMetadata struct { + // AgentspaceMetadata: Metadata for an agentspace source. + AgentspaceMetadata *GoogleCloudNotebooklmV1alphaAgentspaceMetadata `json:"agentspaceMetadata,omitempty"` + // SourceAddedTimestamp: The timestamp the source was added. + SourceAddedTimestamp string `json:"sourceAddedTimestamp,omitempty"` + // TokenCount: The number of tokens in the source. + TokenCount int64 `json:"tokenCount,omitempty"` + // WordCount: The word count of the source. + WordCount int64 `json:"wordCount,omitempty"` + // ForceSendFields is a list of field names (e.g. "AgentspaceMetadata") 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. "AgentspaceMetadata") 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 GoogleCloudNotebooklmV1alphaSourceMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudNotebooklmV1alphaSourceMetadata + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudNotebooklmV1alphaUploadSourceFileRequest: Request for the // SourceService.UploadSourceFile method. type GoogleCloudNotebooklmV1alphaUploadSourceFileRequest struct { @@ -28402,6 +28712,56 @@ func (s GoogleCloudNotebooklmV1alphaUploadSourceFileResponse) MarshalJSON() ([]b return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudNotebooklmV1alphaUserContent: The "Content" messages refer to +// data the user wants to upload. +type GoogleCloudNotebooklmV1alphaUserContent struct { + // AgentspaceContent: Agentspace content uploaded as source. + AgentspaceContent *GoogleCloudNotebooklmV1alphaUserContentAgentspaceContent `json:"agentspaceContent,omitempty"` + // ForceSendFields is a list of field names (e.g. "AgentspaceContent") 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. "AgentspaceContent") 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 GoogleCloudNotebooklmV1alphaUserContent) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudNotebooklmV1alphaUserContent + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudNotebooklmV1alphaUserContentAgentspaceContent: Agentspace content +// uploaded as source. +type GoogleCloudNotebooklmV1alphaUserContentAgentspaceContent struct { + // DocumentName: Optional. The full document name in Agentspace. + DocumentName string `json:"documentName,omitempty"` + // EngineName: Optional. Engine to verify the permission of the document. + EngineName string `json:"engineName,omitempty"` + // IdeaforgeIdeaName: Optional. The full idea name for IdeaForge. + IdeaforgeIdeaName string `json:"ideaforgeIdeaName,omitempty"` + // ForceSendFields is a list of field names (e.g. "DocumentName") 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. "DocumentName") 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 GoogleCloudNotebooklmV1alphaUserContentAgentspaceContent) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudNotebooklmV1alphaUserContentAgentspaceContent + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleLongrunningCancelOperationRequest: The request message for // Operations.CancelOperation. type GoogleLongrunningCancelOperationRequest struct { @@ -28894,124 +29254,114 @@ func (s GoogleTypeTimeZone) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -type MediaUploadCall struct { - s *Service - parent string - googlecloudnotebooklmv1alphauploadsourcefilerequest *GoogleCloudNotebooklmV1alphaUploadSourceFileRequest - urlParams_ gensupport.URLParams - mediaInfo_ *gensupport.MediaInfo - ctx_ context.Context - header_ http.Header +type MediaDownloadCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header } -// Upload: Uploads a file for Notebook LM to use. Creates a Source. +// Download: Downloads a file from the session. // -// - parent: The parent resource where the sources will be created. Format: -// projects/{project}/locations/{location}/notebooks/{notebook}. -func (r *MediaService) Upload(parent string, googlecloudnotebooklmv1alphauploadsourcefilerequest *GoogleCloudNotebooklmV1alphaUploadSourceFileRequest) *MediaUploadCall { - c := &MediaUploadCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.parent = parent - c.googlecloudnotebooklmv1alphauploadsourcefilerequest = googlecloudnotebooklmv1alphauploadsourcefilerequest - return c -} - -// Media specifies the media to upload in one or more chunks. The chunk size -// may be controlled by supplying a MediaOption generated by -// googleapi.ChunkSize. The chunk size defaults to -// googleapi.DefaultUploadChunkSize.The Content-Type header used in the upload -// request will be determined by sniffing the contents of r, unless a -// MediaOption generated by googleapi.ContentType is supplied. -// At most one of Media and ResumableMedia may be set. -func (c *MediaUploadCall) Media(r io.Reader, options ...googleapi.MediaOption) *MediaUploadCall { - c.mediaInfo_ = gensupport.NewInfoFromMedia(r, options) +// - name: The resource name of the Session. Format: +// `projects/{project}/locations/{location}/collections/{collection}/engines/{ +// engine}/sessions/{session}`. +func (r *MediaService) Download(name string) *MediaDownloadCall { + c := &MediaDownloadCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name return c } -// ResumableMedia specifies the media to upload in chunks and can be canceled -// with ctx. -// -// Deprecated: use Media instead. -// -// At most one of Media and ResumableMedia may be set. mediaType identifies the -// MIME media type of the upload, such as "image/png". If mediaType is "", it -// will be auto-detected. The provided ctx will supersede any context -// previously provided to the Context method. -func (c *MediaUploadCall) ResumableMedia(ctx context.Context, r io.ReaderAt, size int64, mediaType string) *MediaUploadCall { - c.ctx_ = ctx - c.mediaInfo_ = gensupport.NewInfoFromResumableMedia(r, size, mediaType) +// FileId sets the optional parameter "fileId": Required. The ID of the file to +// be downloaded. +func (c *MediaDownloadCall) FileId(fileId string) *MediaDownloadCall { + c.urlParams_.Set("fileId", fileId) return c } -// ProgressUpdater provides a callback function that will be called after every -// chunk. It should be a low-latency function in order to not slow down the -// upload operation. This should only be called when using ResumableMedia (as -// opposed to Media). -func (c *MediaUploadCall) ProgressUpdater(pu googleapi.ProgressUpdater) *MediaUploadCall { - c.mediaInfo_.SetProgressUpdater(pu) +// ViewId sets the optional parameter "viewId": The ID of the view to be +// downloaded. +func (c *MediaDownloadCall) ViewId(viewId string) *MediaDownloadCall { + c.urlParams_.Set("viewId", viewId) 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 *MediaUploadCall) Fields(s ...googleapi.Field) *MediaUploadCall { +func (c *MediaDownloadCall) Fields(s ...googleapi.Field) *MediaDownloadCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// Context sets the context to be used in this call's Do method. -// This context will supersede any context previously provided to the -// ResumableMedia method. -func (c *MediaUploadCall) Context(ctx context.Context) *MediaUploadCall { +// 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 *MediaDownloadCall) IfNoneMatch(entityTag string) *MediaDownloadCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do and Download methods. +func (c *MediaDownloadCall) Context(ctx context.Context) *MediaDownloadCall { 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 *MediaUploadCall) Header() http.Header { +func (c *MediaDownloadCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *MediaUploadCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) - body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.googlecloudnotebooklmv1alphauploadsourcefilerequest) - if err != nil { - return nil, err +func (c *MediaDownloadCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) } c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+parent}/sources:uploadFile") - if c.mediaInfo_ != nil { - urls = googleapi.ResolveRelative(c.s.BasePath, "/upload/v1alpha/{+parent}/sources:uploadFile") - c.urlParams_.Set("uploadType", c.mediaInfo_.UploadType()) - } - newBody, getBody, cleanup := c.mediaInfo_.UploadRequest(reqHeaders, body) - defer cleanup() + urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+name}:downloadFile") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("POST", urls, newBody) + req, err := http.NewRequest("GET", urls, nil) if err != nil { return nil, err } req.Header = reqHeaders - req.GetBody = getBody googleapi.Expand(req.URL, map[string]string{ - "parent": c.parent, + "name": c.name, }) - c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "discoveryengine.media.upload", "request", internallog.HTTPRequest(req, body.Bytes())) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "discoveryengine.media.download", "request", internallog.HTTPRequest(req, nil)) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "discoveryengine.media.upload" call. +// Download fetches the API endpoint's "media" value, instead of the normal +// API response value. If the returned error is nil, the Response is guaranteed to +// have a 2xx status code. Callers must close the Response.Body as usual. +func (c *MediaDownloadCall) Download(opts ...googleapi.CallOption) (*http.Response, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("media") + if err != nil { + return nil, err + } + if err := googleapi.CheckResponse(res); err != nil { + res.Body.Close() + return nil, gensupport.WrapError(err) + } + return res, nil +} + +// Do executes the "discoveryengine.media.download" call. // Any non-2xx status code is an error. Response headers are in either -// *GoogleCloudNotebooklmV1alphaUploadSourceFileResponse.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 *MediaUploadCall) Do(opts ...googleapi.CallOption) (*GoogleCloudNotebooklmV1alphaUploadSourceFileResponse, error) { +// *GdataMedia.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 *MediaDownloadCall) Do(opts ...googleapi.CallOption) (*GdataMedia, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -29030,24 +29380,7 @@ func (c *MediaUploadCall) Do(opts ...googleapi.CallOption) (*GoogleCloudNotebook if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - rx := c.mediaInfo_.ResumableUpload(res.Header.Get("Location")) - if rx != nil { - rx.Client = c.s.client - rx.UserAgent = c.s.userAgent() - ctx := c.ctx_ - if ctx == nil { - ctx = context.TODO() - } - res, err = rx.Upload(ctx) - if err != nil { - return nil, err - } - defer res.Body.Close() - if err := googleapi.CheckResponse(res); err != nil { - return nil, gensupport.WrapError(err) - } - } - ret := &GoogleCloudNotebooklmV1alphaUploadSourceFileResponse{ + ret := &GdataMedia{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -29058,7 +29391,7 @@ func (c *MediaUploadCall) Do(opts ...googleapi.CallOption) (*GoogleCloudNotebook if err != nil { return nil, err } - c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "discoveryengine.media.upload", "response", internallog.HTTPResponse(res, b)) + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "discoveryengine.media.download", "response", internallog.HTTPResponse(res, b)) return ret, nil } @@ -44253,6 +44586,232 @@ func (c *ProjectsLocationsCollectionsEnginesTuneCall) Do(opts ...googleapi.CallO return ret, nil } +type ProjectsLocationsCollectionsEnginesAssistantsGetCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// Get: Gets an Assistant. +// +// - name: Resource name of Assistant. Format: +// `projects/{project}/locations/{location}/collections/{collection}/engines/{ +// engine}/assistants/{assistant}`. +func (r *ProjectsLocationsCollectionsEnginesAssistantsService) Get(name string) *ProjectsLocationsCollectionsEnginesAssistantsGetCall { + c := &ProjectsLocationsCollectionsEnginesAssistantsGetCall{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 *ProjectsLocationsCollectionsEnginesAssistantsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsEnginesAssistantsGetCall { + 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 *ProjectsLocationsCollectionsEnginesAssistantsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsCollectionsEnginesAssistantsGetCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsCollectionsEnginesAssistantsGetCall) Context(ctx context.Context) *ProjectsLocationsCollectionsEnginesAssistantsGetCall { + 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 *ProjectsLocationsCollectionsEnginesAssistantsGetCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsCollectionsEnginesAssistantsGetCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) + } + 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, nil) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "name": c.name, + }) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "discoveryengine.projects.locations.collections.engines.assistants.get", "request", internallog.HTTPRequest(req, nil)) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "discoveryengine.projects.locations.collections.engines.assistants.get" call. +// Any non-2xx status code is an error. Response headers are in either +// *GoogleCloudDiscoveryengineV1alphaAssistant.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 *ProjectsLocationsCollectionsEnginesAssistantsGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1alphaAssistant, 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 := &GoogleCloudDiscoveryengineV1alphaAssistant{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + b, err := gensupport.DecodeResponseBytes(target, res) + if err != nil { + return nil, err + } + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "discoveryengine.projects.locations.collections.engines.assistants.get", "response", internallog.HTTPResponse(res, b)) + return ret, nil +} + +type ProjectsLocationsCollectionsEnginesAssistantsPatchCall struct { + s *Service + name string + googleclouddiscoveryenginev1alphaassistant *GoogleCloudDiscoveryengineV1alphaAssistant + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Patch: Updates an Assistant +// +// - name: Immutable. Resource name of the assistant. Format: +// `projects/{project}/locations/{location}/collections/{collection}/engines/{ +// engine}/assistants/{assistant}` It must be a UTF-8 encoded string with a +// length limit of 1024 characters. +func (r *ProjectsLocationsCollectionsEnginesAssistantsService) Patch(name string, googleclouddiscoveryenginev1alphaassistant *GoogleCloudDiscoveryengineV1alphaAssistant) *ProjectsLocationsCollectionsEnginesAssistantsPatchCall { + c := &ProjectsLocationsCollectionsEnginesAssistantsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + c.googleclouddiscoveryenginev1alphaassistant = googleclouddiscoveryenginev1alphaassistant + return c +} + +// UpdateMask sets the optional parameter "updateMask": The list of fields to +// update. +func (c *ProjectsLocationsCollectionsEnginesAssistantsPatchCall) UpdateMask(updateMask string) *ProjectsLocationsCollectionsEnginesAssistantsPatchCall { + 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 *ProjectsLocationsCollectionsEnginesAssistantsPatchCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsEnginesAssistantsPatchCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsCollectionsEnginesAssistantsPatchCall) Context(ctx context.Context) *ProjectsLocationsCollectionsEnginesAssistantsPatchCall { + 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 *ProjectsLocationsCollectionsEnginesAssistantsPatchCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsCollectionsEnginesAssistantsPatchCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) + body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.googleclouddiscoveryenginev1alphaassistant) + if err != nil { + return nil, err + } + 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("PATCH", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "name": c.name, + }) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "discoveryengine.projects.locations.collections.engines.assistants.patch", "request", internallog.HTTPRequest(req, body.Bytes())) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "discoveryengine.projects.locations.collections.engines.assistants.patch" call. +// Any non-2xx status code is an error. Response headers are in either +// *GoogleCloudDiscoveryengineV1alphaAssistant.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 *ProjectsLocationsCollectionsEnginesAssistantsPatchCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1alphaAssistant, 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 := &GoogleCloudDiscoveryengineV1alphaAssistant{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + b, err := gensupport.DecodeResponseBytes(target, res) + if err != nil { + return nil, err + } + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "discoveryengine.projects.locations.collections.engines.assistants.patch", "response", internallog.HTTPResponse(res, b)) + return ret, nil +} + type ProjectsLocationsCollectionsEnginesAssistantsStreamAssistCall struct { s *Service name string @@ -59849,6 +60408,261 @@ func (c *ProjectsLocationsIdentityMappingStoresOperationsListCall) Pages(ctx con } } +type ProjectsLocationsNotebooksListRecentlyViewedCall struct { + s *Service + parent string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// ListRecentlyViewed: Lists the recently viewed notebooks. Needs a side +// channel with the user's EUC. +// +// - parent: The parent branch resource name, such as +// `projects/{project}/locations/{location}`. +func (r *ProjectsLocationsNotebooksService) ListRecentlyViewed(parent string) *ProjectsLocationsNotebooksListRecentlyViewedCall { + c := &ProjectsLocationsNotebooksListRecentlyViewedCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + return c +} + +// PageSize sets the optional parameter "pageSize": Maximum number of Notebooks +// to return. If unspecified, defaults to "200". The maximum allowed value is +// "500". If this field is negative, will use the default value. +func (c *ProjectsLocationsNotebooksListRecentlyViewedCall) PageSize(pageSize int64) *ProjectsLocationsNotebooksListRecentlyViewedCall { + c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) + return c +} + +// PageToken sets the optional parameter "pageToken": The page token, provide +// this to retrieve the subsequent page. +func (c *ProjectsLocationsNotebooksListRecentlyViewedCall) PageToken(pageToken string) *ProjectsLocationsNotebooksListRecentlyViewedCall { + 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 *ProjectsLocationsNotebooksListRecentlyViewedCall) Fields(s ...googleapi.Field) *ProjectsLocationsNotebooksListRecentlyViewedCall { + 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 *ProjectsLocationsNotebooksListRecentlyViewedCall) IfNoneMatch(entityTag string) *ProjectsLocationsNotebooksListRecentlyViewedCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsNotebooksListRecentlyViewedCall) Context(ctx context.Context) *ProjectsLocationsNotebooksListRecentlyViewedCall { + 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 *ProjectsLocationsNotebooksListRecentlyViewedCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsNotebooksListRecentlyViewedCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+parent}/notebooks:listRecentlyViewed") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("GET", urls, nil) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "parent": c.parent, + }) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "discoveryengine.projects.locations.notebooks.listRecentlyViewed", "request", internallog.HTTPRequest(req, nil)) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "discoveryengine.projects.locations.notebooks.listRecentlyViewed" call. +// Any non-2xx status code is an error. Response headers are in either +// *GoogleCloudNotebooklmV1alphaListRecentlyViewedNotebooksResponse.ServerRespon +// se.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 *ProjectsLocationsNotebooksListRecentlyViewedCall) Do(opts ...googleapi.CallOption) (*GoogleCloudNotebooklmV1alphaListRecentlyViewedNotebooksResponse, 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 := &GoogleCloudNotebooklmV1alphaListRecentlyViewedNotebooksResponse{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + b, err := gensupport.DecodeResponseBytes(target, res) + if err != nil { + return nil, err + } + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "discoveryengine.projects.locations.notebooks.listRecentlyViewed", "response", internallog.HTTPResponse(res, b)) + 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 *ProjectsLocationsNotebooksListRecentlyViewedCall) Pages(ctx context.Context, f func(*GoogleCloudNotebooklmV1alphaListRecentlyViewedNotebooksResponse) 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 ProjectsLocationsNotebooksSourcesBatchCreateCall struct { + s *Service + parent string + googlecloudnotebooklmv1alphabatchcreatesourcesrequest *GoogleCloudNotebooklmV1alphaBatchCreateSourcesRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// BatchCreate: Creates a list of Sources. +// +// - parent: The parent resource where the sources will be created. Format: +// projects/{project}/locations/{location}/notebooks/{notebook}. +func (r *ProjectsLocationsNotebooksSourcesService) BatchCreate(parent string, googlecloudnotebooklmv1alphabatchcreatesourcesrequest *GoogleCloudNotebooklmV1alphaBatchCreateSourcesRequest) *ProjectsLocationsNotebooksSourcesBatchCreateCall { + c := &ProjectsLocationsNotebooksSourcesBatchCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + c.googlecloudnotebooklmv1alphabatchcreatesourcesrequest = googlecloudnotebooklmv1alphabatchcreatesourcesrequest + 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 *ProjectsLocationsNotebooksSourcesBatchCreateCall) Fields(s ...googleapi.Field) *ProjectsLocationsNotebooksSourcesBatchCreateCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsNotebooksSourcesBatchCreateCall) Context(ctx context.Context) *ProjectsLocationsNotebooksSourcesBatchCreateCall { + 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 *ProjectsLocationsNotebooksSourcesBatchCreateCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsNotebooksSourcesBatchCreateCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) + body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.googlecloudnotebooklmv1alphabatchcreatesourcesrequest) + if err != nil { + return nil, err + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+parent}/sources:batchCreate") + 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, + }) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "discoveryengine.projects.locations.notebooks.sources.batchCreate", "request", internallog.HTTPRequest(req, body.Bytes())) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "discoveryengine.projects.locations.notebooks.sources.batchCreate" call. +// Any non-2xx status code is an error. Response headers are in either +// *GoogleCloudNotebooklmV1alphaBatchCreateSourcesResponse.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 *ProjectsLocationsNotebooksSourcesBatchCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudNotebooklmV1alphaBatchCreateSourcesResponse, 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 := &GoogleCloudNotebooklmV1alphaBatchCreateSourcesResponse{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + b, err := gensupport.DecodeResponseBytes(target, res) + if err != nil { + return nil, err + } + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "discoveryengine.projects.locations.notebooks.sources.batchCreate", "response", internallog.HTTPResponse(res, b)) + return ret, nil +} + type ProjectsLocationsNotebooksSourcesUploadFileCall struct { s *Service parent string diff --git a/discoveryengine/v1beta/discoveryengine-api.json b/discoveryengine/v1beta/discoveryengine-api.json index 3004f850d92..803bbc1a87e 100644 --- a/discoveryengine/v1beta/discoveryengine-api.json +++ b/discoveryengine/v1beta/discoveryengine-api.json @@ -3425,6 +3425,65 @@ "resources": { "assistants": { "methods": { + "get": { + "description": "Gets an Assistant.", + "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/engines/{enginesId}/assistants/{assistantsId}", + "httpMethod": "GET", + "id": "discoveryengine.projects.locations.collections.engines.assistants.get", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Required. Resource name of Assistant. Format: `projects/{project}/locations/{location}/collections/{collection}/engines/{engine}/assistants/{assistant}`", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/engines/[^/]+/assistants/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1beta/{+name}", + "response": { + "$ref": "GoogleCloudDiscoveryengineV1betaAssistant" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "patch": { + "description": "Updates an Assistant", + "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/engines/{enginesId}/assistants/{assistantsId}", + "httpMethod": "PATCH", + "id": "discoveryengine.projects.locations.collections.engines.assistants.patch", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Immutable. Resource name of the assistant. Format: `projects/{project}/locations/{location}/collections/{collection}/engines/{engine}/assistants/{assistant}` It must be a UTF-8 encoded string with a length limit of 1024 characters.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/engines/[^/]+/assistants/[^/]+$", + "required": true, + "type": "string" + }, + "updateMask": { + "description": "The list of fields to update.", + "format": "google-fieldmask", + "location": "query", + "type": "string" + } + }, + "path": "v1beta/{+name}", + "request": { + "$ref": "GoogleCloudDiscoveryengineV1betaAssistant" + }, + "response": { + "$ref": "GoogleCloudDiscoveryengineV1betaAssistant" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, "streamAssist": { "description": "Assists the user with a query in a streaming fashion.", "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/engines/{enginesId}/assistants/{assistantsId}:streamAssist", @@ -8047,7 +8106,7 @@ } } }, - "revision": "20250723", + "revision": "20250724", "rootUrl": "https://discoveryengine.googleapis.com/", "schemas": { "GoogleApiDistribution": { @@ -18676,6 +18735,17 @@ }, "type": "object" }, + "GoogleCloudDiscoveryengineV1betaAssistant": { + "description": "Discovery Engine Assistant resource.", + "id": "GoogleCloudDiscoveryengineV1betaAssistant", + "properties": { + "name": { + "description": "Immutable. Resource name of the assistant. Format: `projects/{project}/locations/{location}/collections/{collection}/engines/{engine}/assistants/{assistant}` It must be a UTF-8 encoded string with a length limit of 1024 characters.", + "type": "string" + } + }, + "type": "object" + }, "GoogleCloudDiscoveryengineV1betaAssistantContent": { "description": "Multi-modal content.", "id": "GoogleCloudDiscoveryengineV1betaAssistantContent", diff --git a/discoveryengine/v1beta/discoveryengine-gen.go b/discoveryengine/v1beta/discoveryengine-gen.go index 0d6cecaa53f..991aaf02214 100644 --- a/discoveryengine/v1beta/discoveryengine-gen.go +++ b/discoveryengine/v1beta/discoveryengine-gen.go @@ -15392,6 +15392,35 @@ func (s GoogleCloudDiscoveryengineV1betaAssistUserMetadata) MarshalJSON() ([]byt return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudDiscoveryengineV1betaAssistant: Discovery Engine Assistant +// resource. +type GoogleCloudDiscoveryengineV1betaAssistant struct { + // Name: Immutable. Resource name of the assistant. Format: + // `projects/{project}/locations/{location}/collections/{collection}/engines/{en + // gine}/assistants/{assistant}` It must be a UTF-8 encoded string with a + // length limit of 1024 characters. + Name string `json:"name,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the server. + googleapi.ServerResponse `json:"-"` + // ForceSendFields is a list of field names (e.g. "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. "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 GoogleCloudDiscoveryengineV1betaAssistant) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaAssistant + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudDiscoveryengineV1betaAssistantContent: Multi-modal content. type GoogleCloudDiscoveryengineV1betaAssistantContent struct { // CodeExecutionResult: Result of executing an ExecutableCode. @@ -39414,6 +39443,232 @@ func (c *ProjectsLocationsCollectionsEnginesTuneCall) Do(opts ...googleapi.CallO return ret, nil } +type ProjectsLocationsCollectionsEnginesAssistantsGetCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// Get: Gets an Assistant. +// +// - name: Resource name of Assistant. Format: +// `projects/{project}/locations/{location}/collections/{collection}/engines/{ +// engine}/assistants/{assistant}`. +func (r *ProjectsLocationsCollectionsEnginesAssistantsService) Get(name string) *ProjectsLocationsCollectionsEnginesAssistantsGetCall { + c := &ProjectsLocationsCollectionsEnginesAssistantsGetCall{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 *ProjectsLocationsCollectionsEnginesAssistantsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsEnginesAssistantsGetCall { + 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 *ProjectsLocationsCollectionsEnginesAssistantsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsCollectionsEnginesAssistantsGetCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsCollectionsEnginesAssistantsGetCall) Context(ctx context.Context) *ProjectsLocationsCollectionsEnginesAssistantsGetCall { + 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 *ProjectsLocationsCollectionsEnginesAssistantsGetCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsCollectionsEnginesAssistantsGetCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("GET", urls, nil) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "name": c.name, + }) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "discoveryengine.projects.locations.collections.engines.assistants.get", "request", internallog.HTTPRequest(req, nil)) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "discoveryengine.projects.locations.collections.engines.assistants.get" call. +// Any non-2xx status code is an error. Response headers are in either +// *GoogleCloudDiscoveryengineV1betaAssistant.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 *ProjectsLocationsCollectionsEnginesAssistantsGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1betaAssistant, 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 := &GoogleCloudDiscoveryengineV1betaAssistant{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + b, err := gensupport.DecodeResponseBytes(target, res) + if err != nil { + return nil, err + } + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "discoveryengine.projects.locations.collections.engines.assistants.get", "response", internallog.HTTPResponse(res, b)) + return ret, nil +} + +type ProjectsLocationsCollectionsEnginesAssistantsPatchCall struct { + s *Service + name string + googleclouddiscoveryenginev1betaassistant *GoogleCloudDiscoveryengineV1betaAssistant + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Patch: Updates an Assistant +// +// - name: Immutable. Resource name of the assistant. Format: +// `projects/{project}/locations/{location}/collections/{collection}/engines/{ +// engine}/assistants/{assistant}` It must be a UTF-8 encoded string with a +// length limit of 1024 characters. +func (r *ProjectsLocationsCollectionsEnginesAssistantsService) Patch(name string, googleclouddiscoveryenginev1betaassistant *GoogleCloudDiscoveryengineV1betaAssistant) *ProjectsLocationsCollectionsEnginesAssistantsPatchCall { + c := &ProjectsLocationsCollectionsEnginesAssistantsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + c.googleclouddiscoveryenginev1betaassistant = googleclouddiscoveryenginev1betaassistant + return c +} + +// UpdateMask sets the optional parameter "updateMask": The list of fields to +// update. +func (c *ProjectsLocationsCollectionsEnginesAssistantsPatchCall) UpdateMask(updateMask string) *ProjectsLocationsCollectionsEnginesAssistantsPatchCall { + 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 *ProjectsLocationsCollectionsEnginesAssistantsPatchCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsEnginesAssistantsPatchCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsCollectionsEnginesAssistantsPatchCall) Context(ctx context.Context) *ProjectsLocationsCollectionsEnginesAssistantsPatchCall { + 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 *ProjectsLocationsCollectionsEnginesAssistantsPatchCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsCollectionsEnginesAssistantsPatchCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) + body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.googleclouddiscoveryenginev1betaassistant) + if err != nil { + return nil, err + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+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, + }) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "discoveryengine.projects.locations.collections.engines.assistants.patch", "request", internallog.HTTPRequest(req, body.Bytes())) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "discoveryengine.projects.locations.collections.engines.assistants.patch" call. +// Any non-2xx status code is an error. Response headers are in either +// *GoogleCloudDiscoveryengineV1betaAssistant.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 *ProjectsLocationsCollectionsEnginesAssistantsPatchCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1betaAssistant, 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 := &GoogleCloudDiscoveryengineV1betaAssistant{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + b, err := gensupport.DecodeResponseBytes(target, res) + if err != nil { + return nil, err + } + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "discoveryengine.projects.locations.collections.engines.assistants.patch", "response", internallog.HTTPResponse(res, b)) + return ret, nil +} + type ProjectsLocationsCollectionsEnginesAssistantsStreamAssistCall struct { s *Service name string diff --git a/dlp/v2/dlp-api.json b/dlp/v2/dlp-api.json index 0945e373dab..ed6975ba8d3 100644 --- a/dlp/v2/dlp-api.json +++ b/dlp/v2/dlp-api.json @@ -5118,7 +5118,7 @@ } } }, - "revision": "20250713", + "revision": "20250720", "rootUrl": "https://dlp.googleapis.com/", "schemas": { "GooglePrivacyDlpV2Action": { @@ -8272,16 +8272,16 @@ "type": "object" }, "GooglePrivacyDlpV2DocumentFallbackLocation": { - "description": "Configure document processing to fall back to the configured processing option below if document processing is unavailable in the original request location.", + "description": "Configure document processing to fall back to any of the following processing options if document processing is unavailable in the original request location.", "id": "GooglePrivacyDlpV2DocumentFallbackLocation", "properties": { "globalProcessing": { "$ref": "GooglePrivacyDlpV2GlobalProcessing", - "description": "Processing will happen in the global region." + "description": "Processing occurs in the global region." }, "multiRegionProcessing": { "$ref": "GooglePrivacyDlpV2MultiRegionProcessing", - "description": "Processing will happen in a multi-region that contains the current region if available." + "description": "Processing occurs in a multi-region that contains the current region if available." } }, "type": "object" @@ -8987,7 +8987,7 @@ "type": "object" }, "GooglePrivacyDlpV2GlobalProcessing": { - "description": "Processing will happen in the global region.", + "description": "Processing occurs in the global region.", "id": "GooglePrivacyDlpV2GlobalProcessing", "properties": {}, "type": "object" @@ -9138,16 +9138,16 @@ "type": "object" }, "GooglePrivacyDlpV2ImageFallbackLocation": { - "description": "Configure image processing to fall back to the configured processing option below if unavailable in the request location.", + "description": "Configure image processing to fall back to any of the following processing options if image processing is unavailable in the original request location.", "id": "GooglePrivacyDlpV2ImageFallbackLocation", "properties": { "globalProcessing": { "$ref": "GooglePrivacyDlpV2GlobalProcessing", - "description": "Processing will happen in the global region." + "description": "Processing occurs in the global region." }, "multiRegionProcessing": { "$ref": "GooglePrivacyDlpV2MultiRegionProcessing", - "description": "Processing will happen in a multi-region that contains the current region if available." + "description": "Processing occurs in a multi-region that contains the current region if available." } }, "type": "object" @@ -9269,6 +9269,7 @@ "ARGENTINA", "ARMENIA", "AUSTRALIA", + "AUSTRIA", "AZERBAIJAN", "BELARUS", "BELGIUM", @@ -9323,6 +9324,7 @@ "The infoType is typically used in Argentina.", "The infoType is typically used in Armenia.", "The infoType is typically used in Australia.", + "The infoType is typically used in Austria.", "The infoType is typically used in Azerbaijan.", "The infoType is typically used in Belarus.", "The infoType is typically used in Belgium.", @@ -10562,7 +10564,7 @@ "type": "object" }, "GooglePrivacyDlpV2MultiRegionProcessing": { - "description": "Processing will happen in a multi-region that contains the current region if available.", + "description": "Processing occurs in a multi-region that contains the current region if available.", "id": "GooglePrivacyDlpV2MultiRegionProcessing", "properties": {}, "type": "object" @@ -10895,11 +10897,11 @@ "properties": { "documentFallbackLocation": { "$ref": "GooglePrivacyDlpV2DocumentFallbackLocation", - "description": "Document processing will fall back using this configuration." + "description": "Document processing falls back using this configuration." }, "imageFallbackLocation": { "$ref": "GooglePrivacyDlpV2ImageFallbackLocation", - "description": "Image processing will fall back using this configuration." + "description": "Image processing falls back using this configuration." } }, "type": "object" @@ -11148,7 +11150,7 @@ "id": "GooglePrivacyDlpV2QuasiId", "properties": { "customTag": { - "description": "A column can be tagged with a custom tag. In this case, the user must indicate an auxiliary table that contains statistical information on the possible values of this column (below).", + "description": "A column can be tagged with a custom tag. In this case, the user must indicate an auxiliary table that contains statistical information on the possible values of this column.", "type": "string" }, "field": { @@ -11186,7 +11188,7 @@ "id": "GooglePrivacyDlpV2QuasiIdentifierField", "properties": { "customTag": { - "description": "A column can be tagged with a custom tag. In this case, the user must indicate an auxiliary table that contains statistical information on the possible values of this column (below).", + "description": "A column can be tagged with a custom tag. In this case, the user must indicate an auxiliary table that contains statistical information on the possible values of this column.", "type": "string" }, "field": { @@ -11534,7 +11536,7 @@ "type": "object" }, "GooglePrivacyDlpV2Result": { - "description": "All result fields mentioned below are updated while the job is processing.", + "description": "All Result fields are updated while the job is processing.", "id": "GooglePrivacyDlpV2Result", "properties": { "hybridStats": { @@ -12310,7 +12312,7 @@ "id": "GooglePrivacyDlpV2TaggedField", "properties": { "customTag": { - "description": "A column can be tagged with a custom tag. In this case, the user must indicate an auxiliary table that contains statistical information on the possible values of this column (below).", + "description": "A column can be tagged with a custom tag. In this case, the user must indicate an auxiliary table that contains statistical information on the possible values of this column.", "type": "string" }, "field": { diff --git a/dlp/v2/dlp-gen.go b/dlp/v2/dlp-gen.go index 78f45406734..bd3f942fe4e 100644 --- a/dlp/v2/dlp-gen.go +++ b/dlp/v2/dlp-gen.go @@ -5028,13 +5028,13 @@ func (s GooglePrivacyDlpV2DlpJob) MarshalJSON() ([]byte, error) { } // GooglePrivacyDlpV2DocumentFallbackLocation: Configure document processing to -// fall back to the configured processing option below if document processing +// fall back to any of the following processing options if document processing // is unavailable in the original request location. type GooglePrivacyDlpV2DocumentFallbackLocation struct { - // GlobalProcessing: Processing will happen in the global region. + // GlobalProcessing: Processing occurs in the global region. GlobalProcessing *GooglePrivacyDlpV2GlobalProcessing `json:"globalProcessing,omitempty"` - // MultiRegionProcessing: Processing will happen in a multi-region that - // contains the current region if available. + // MultiRegionProcessing: Processing occurs in a multi-region that contains the + // current region if available. MultiRegionProcessing *GooglePrivacyDlpV2MultiRegionProcessing `json:"multiRegionProcessing,omitempty"` // ForceSendFields is a list of field names (e.g. "GlobalProcessing") to // unconditionally include in API requests. By default, fields with empty or @@ -5965,8 +5965,7 @@ func (s *GooglePrivacyDlpV2FixedSizeBucketingConfig) UnmarshalJSON(data []byte) return nil } -// GooglePrivacyDlpV2GlobalProcessing: Processing will happen in the global -// region. +// GooglePrivacyDlpV2GlobalProcessing: Processing occurs in the global region. type GooglePrivacyDlpV2GlobalProcessing struct { } @@ -6211,13 +6210,13 @@ func (s GooglePrivacyDlpV2HybridOptions) MarshalJSON() ([]byte, error) { } // GooglePrivacyDlpV2ImageFallbackLocation: Configure image processing to fall -// back to the configured processing option below if unavailable in the request -// location. +// back to any of the following processing options if image processing is +// unavailable in the original request location. type GooglePrivacyDlpV2ImageFallbackLocation struct { - // GlobalProcessing: Processing will happen in the global region. + // GlobalProcessing: Processing occurs in the global region. GlobalProcessing *GooglePrivacyDlpV2GlobalProcessing `json:"globalProcessing,omitempty"` - // MultiRegionProcessing: Processing will happen in a multi-region that - // contains the current region if available. + // MultiRegionProcessing: Processing occurs in a multi-region that contains the + // current region if available. MultiRegionProcessing *GooglePrivacyDlpV2MultiRegionProcessing `json:"multiRegionProcessing,omitempty"` // ForceSendFields is a list of field names (e.g. "GlobalProcessing") to // unconditionally include in API requests. By default, fields with empty or @@ -6403,6 +6402,7 @@ type GooglePrivacyDlpV2InfoTypeCategory struct { // "ARGENTINA" - The infoType is typically used in Argentina. // "ARMENIA" - The infoType is typically used in Armenia. // "AUSTRALIA" - The infoType is typically used in Australia. + // "AUSTRIA" - The infoType is typically used in Austria. // "AZERBAIJAN" - The infoType is typically used in Azerbaijan. // "BELARUS" - The infoType is typically used in Belarus. // "BELGIUM" - The infoType is typically used in Belgium. @@ -8076,8 +8076,8 @@ func (s GooglePrivacyDlpV2MetadataLocation) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GooglePrivacyDlpV2MultiRegionProcessing: Processing will happen in a -// multi-region that contains the current region if available. +// GooglePrivacyDlpV2MultiRegionProcessing: Processing occurs in a multi-region +// that contains the current region if available. type GooglePrivacyDlpV2MultiRegionProcessing struct { } @@ -8573,11 +8573,10 @@ func (s GooglePrivacyDlpV2PrivacyMetric) MarshalJSON() ([]byte, error) { // regions but configuring ProcessingLocation will redirect OCR to a location // where OCR is provided. type GooglePrivacyDlpV2ProcessingLocation struct { - // DocumentFallbackLocation: Document processing will fall back using this + // DocumentFallbackLocation: Document processing falls back using this // configuration. DocumentFallbackLocation *GooglePrivacyDlpV2DocumentFallbackLocation `json:"documentFallbackLocation,omitempty"` - // ImageFallbackLocation: Image processing will fall back using this - // configuration. + // ImageFallbackLocation: Image processing falls back using this configuration. ImageFallbackLocation *GooglePrivacyDlpV2ImageFallbackLocation `json:"imageFallbackLocation,omitempty"` // ForceSendFields is a list of field names (e.g. "DocumentFallbackLocation") // to unconditionally include in API requests. By default, fields with empty or @@ -8920,7 +8919,7 @@ type GooglePrivacyDlpV2PublishToStackdriver struct { type GooglePrivacyDlpV2QuasiId struct { // CustomTag: A column can be tagged with a custom tag. In this case, the user // must indicate an auxiliary table that contains statistical information on - // the possible values of this column (below). + // the possible values of this column. CustomTag string `json:"customTag,omitempty"` // Field: Required. Identifies the column. Field *GooglePrivacyDlpV2FieldId `json:"field,omitempty"` @@ -8983,7 +8982,7 @@ func (s GooglePrivacyDlpV2QuasiIdField) MarshalJSON() ([]byte, error) { type GooglePrivacyDlpV2QuasiIdentifierField struct { // CustomTag: A column can be tagged with a custom tag. In this case, the user // must indicate an auxiliary table that contains statistical information on - // the possible values of this column (below). + // the possible values of this column. CustomTag string `json:"customTag,omitempty"` // Field: Identifies the column. Field *GooglePrivacyDlpV2FieldId `json:"field,omitempty"` @@ -9544,8 +9543,8 @@ func (s GooglePrivacyDlpV2RequestedRiskAnalysisOptions) MarshalJSON() ([]byte, e return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GooglePrivacyDlpV2Result: All result fields mentioned below are updated -// while the job is processing. +// GooglePrivacyDlpV2Result: All Result fields are updated while the job is +// processing. type GooglePrivacyDlpV2Result struct { // HybridStats: Statistics related to the processing of hybrid inspect. HybridStats *GooglePrivacyDlpV2HybridInspectStatistics `json:"hybridStats,omitempty"` @@ -10544,7 +10543,7 @@ func (s GooglePrivacyDlpV2TagValue) MarshalJSON() ([]byte, error) { type GooglePrivacyDlpV2TaggedField struct { // CustomTag: A column can be tagged with a custom tag. In this case, the user // must indicate an auxiliary table that contains statistical information on - // the possible values of this column (below). + // the possible values of this column. CustomTag string `json:"customTag,omitempty"` // Field: Required. Identifies the column. Field *GooglePrivacyDlpV2FieldId `json:"field,omitempty"` diff --git a/firebaseml/v2beta/firebaseml-api.json b/firebaseml/v2beta/firebaseml-api.json index 55e25eeebd5..40a21f1a04a 100644 --- a/firebaseml/v2beta/firebaseml-api.json +++ b/firebaseml/v2beta/firebaseml-api.json @@ -206,7 +206,7 @@ } } }, - "revision": "20250720", + "revision": "20250723", "rootUrl": "https://firebaseml.googleapis.com/", "schemas": { "Date": { @@ -2371,10 +2371,6 @@ "$ref": "GoogleCloudAiplatformV1beta1ToolCodeExecution", "description": "Optional. CodeExecution tool type. Enables the model to execute code as part of generation." }, - "computerUse": { - "$ref": "GoogleCloudAiplatformV1beta1ToolComputerUse", - "description": "Optional. Tool to support the model interacting directly with the computer. If enabled, it automatically populates computer-use specific Function Declarations." - }, "enterpriseWebSearch": { "$ref": "GoogleCloudAiplatformV1beta1EnterpriseWebSearch", "description": "Optional. Tool to support searching public web data, powered by Vertex AI Search and Sec4 compliance." @@ -2415,25 +2411,6 @@ "properties": {}, "type": "object" }, - "GoogleCloudAiplatformV1beta1ToolComputerUse": { - "description": "Tool to support computer use.", - "id": "GoogleCloudAiplatformV1beta1ToolComputerUse", - "properties": { - "environment": { - "description": "Required. The environment being operated.", - "enum": [ - "ENVIRONMENT_UNSPECIFIED", - "ENVIRONMENT_BROWSER" - ], - "enumDescriptions": [ - "Defaults to browser.", - "Operates in a web browser." - ], - "type": "string" - } - }, - "type": "object" - }, "GoogleCloudAiplatformV1beta1ToolConfig": { "description": "Tool config. This config is shared for all tools provided in the request.", "id": "GoogleCloudAiplatformV1beta1ToolConfig", @@ -2616,6 +2593,11 @@ "format": "google-duration", "type": "string" }, + "fps": { + "description": "Optional. The frame rate of the video sent to the model. If not specified, the default value will be 1.0. The fps range is (0.0, 24.0].", + "format": "double", + "type": "number" + }, "startOffset": { "description": "Optional. The start offset of the video.", "format": "google-duration", diff --git a/firebaseml/v2beta/firebaseml-gen.go b/firebaseml/v2beta/firebaseml-gen.go index 423d3a8a0ba..c5a1f71875a 100644 --- a/firebaseml/v2beta/firebaseml-gen.go +++ b/firebaseml/v2beta/firebaseml-gen.go @@ -2862,10 +2862,6 @@ type GoogleCloudAiplatformV1beta1Tool struct { // CodeExecution: Optional. CodeExecution tool type. Enables the model to // execute code as part of generation. CodeExecution *GoogleCloudAiplatformV1beta1ToolCodeExecution `json:"codeExecution,omitempty"` - // ComputerUse: Optional. Tool to support the model interacting directly with - // the computer. If enabled, it automatically populates computer-use specific - // Function Declarations. - ComputerUse *GoogleCloudAiplatformV1beta1ToolComputerUse `json:"computerUse,omitempty"` // EnterpriseWebSearch: Optional. Tool to support searching public web data, // powered by Vertex AI Search and Sec4 compliance. EnterpriseWebSearch *GoogleCloudAiplatformV1beta1EnterpriseWebSearch `json:"enterpriseWebSearch,omitempty"` @@ -2917,32 +2913,6 @@ func (s GoogleCloudAiplatformV1beta1Tool) MarshalJSON() ([]byte, error) { type GoogleCloudAiplatformV1beta1ToolCodeExecution struct { } -// GoogleCloudAiplatformV1beta1ToolComputerUse: Tool to support computer use. -type GoogleCloudAiplatformV1beta1ToolComputerUse struct { - // Environment: Required. The environment being operated. - // - // Possible values: - // "ENVIRONMENT_UNSPECIFIED" - Defaults to browser. - // "ENVIRONMENT_BROWSER" - Operates in a web browser. - Environment string `json:"environment,omitempty"` - // ForceSendFields is a list of field names (e.g. "Environment") 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. "Environment") 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 GoogleCloudAiplatformV1beta1ToolComputerUse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudAiplatformV1beta1ToolComputerUse - return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) -} - // GoogleCloudAiplatformV1beta1ToolConfig: Tool config. This config is shared // for all tools provided in the request. type GoogleCloudAiplatformV1beta1ToolConfig struct { @@ -3192,6 +3162,9 @@ func (s GoogleCloudAiplatformV1beta1VertexRagStoreRagResource) MarshalJSON() ([] type GoogleCloudAiplatformV1beta1VideoMetadata struct { // EndOffset: Optional. The end offset of the video. EndOffset string `json:"endOffset,omitempty"` + // Fps: Optional. The frame rate of the video sent to the model. If not + // specified, the default value will be 1.0. The fps range is (0.0, 24.0]. + Fps float64 `json:"fps,omitempty"` // StartOffset: Optional. The start offset of the video. StartOffset string `json:"startOffset,omitempty"` // ForceSendFields is a list of field names (e.g. "EndOffset") to @@ -3212,6 +3185,20 @@ func (s GoogleCloudAiplatformV1beta1VideoMetadata) MarshalJSON() ([]byte, error) return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +func (s *GoogleCloudAiplatformV1beta1VideoMetadata) UnmarshalJSON(data []byte) error { + type NoMethod GoogleCloudAiplatformV1beta1VideoMetadata + var s1 struct { + Fps gensupport.JSONFloat64 `json:"fps"` + *NoMethod + } + s1.NoMethod = (*NoMethod)(s) + if err := json.Unmarshal(data, &s1); err != nil { + return err + } + s.Fps = float64(s1.Fps) + return nil +} + // GoogleCloudAiplatformV1beta1VoiceConfig: The configuration for the voice to // use. type GoogleCloudAiplatformV1beta1VoiceConfig struct { diff --git a/gkehub/v1/gkehub-api.json b/gkehub/v1/gkehub-api.json index 6cca7b51584..84f21aa3c2d 100644 --- a/gkehub/v1/gkehub-api.json +++ b/gkehub/v1/gkehub-api.json @@ -2117,7 +2117,7 @@ } } }, - "revision": "20250715", + "revision": "20250720", "rootUrl": "https://gkehub.googleapis.com/", "schemas": { "AppDevExperienceFeatureSpec": { @@ -6420,7 +6420,8 @@ "ACTIVE", "STALLED", "NEEDS_ATTENTION", - "DEGRADED" + "DEGRADED", + "DEPROVISIONING" ], "enumDescriptions": [ "Unspecified", @@ -6430,7 +6431,8 @@ "ACTIVE means that the component is ready for use.", "STALLED means that provisioning could not be done.", "NEEDS_ATTENTION means that the component is ready, but some user intervention is required. (For example that the user should migrate workloads to a new control plane revision.)", - "DEGRADED means that the component is ready, but operating in a degraded state." + "DEGRADED means that the component is ready, but operating in a degraded state.", + "DEPROVISIONING means that deprovisioning is in progress." ], "type": "string" } @@ -6458,7 +6460,8 @@ "ACTIVE", "STALLED", "NEEDS_ATTENTION", - "DEGRADED" + "DEGRADED", + "DEPROVISIONING" ], "enumDescriptions": [ "Unspecified", @@ -6468,7 +6471,8 @@ "ACTIVE means that the component is ready for use.", "STALLED means that provisioning could not be done.", "NEEDS_ATTENTION means that the component is ready, but some user intervention is required. (For example that the user should migrate workloads to a new control plane revision.)", - "DEGRADED means that the component is ready, but operating in a degraded state." + "DEGRADED means that the component is ready, but operating in a degraded state.", + "DEPROVISIONING means that deprovisioning is in progress." ], "type": "string" } @@ -6513,12 +6517,14 @@ "enum": [ "MANAGEMENT_UNSPECIFIED", "MANAGEMENT_AUTOMATIC", - "MANAGEMENT_MANUAL" + "MANAGEMENT_MANUAL", + "MANAGEMENT_NOT_INSTALLED" ], "enumDescriptions": [ "Unspecified", "Google should manage my Service Mesh for the cluster.", - "User will manually configure their service mesh components." + "User will manually configure their service mesh components.", + "Google should remove any managed Service Mesh components from this cluster and deprovision any resources." ], "type": "string" } diff --git a/gkehub/v1/gkehub-gen.go b/gkehub/v1/gkehub-gen.go index 5e6092ed04a..0376e5ad9db 100644 --- a/gkehub/v1/gkehub-gen.go +++ b/gkehub/v1/gkehub-gen.go @@ -5621,6 +5621,8 @@ type ServiceMeshControlPlaneManagement struct { // migrate workloads to a new control plane revision.) // "DEGRADED" - DEGRADED means that the component is ready, but operating in // a degraded state. + // "DEPROVISIONING" - DEPROVISIONING means that deprovisioning is in + // progress. State string `json:"state,omitempty"` // ForceSendFields is a list of field names (e.g. "Details") to unconditionally // include in API requests. By default, fields with empty or default values are @@ -5660,6 +5662,8 @@ type ServiceMeshDataPlaneManagement struct { // migrate workloads to a new control plane revision.) // "DEGRADED" - DEGRADED means that the component is ready, but operating in // a degraded state. + // "DEPROVISIONING" - DEPROVISIONING means that deprovisioning is in + // progress. State string `json:"state,omitempty"` // ForceSendFields is a list of field names (e.g. "Details") to unconditionally // include in API requests. By default, fields with empty or default values are @@ -5710,6 +5714,8 @@ type ServiceMeshMembershipSpec struct { // cluster. // "MANAGEMENT_MANUAL" - User will manually configure their service mesh // components. + // "MANAGEMENT_NOT_INSTALLED" - Google should remove any managed Service Mesh + // components from this cluster and deprovision any resources. Management string `json:"management,omitempty"` // ForceSendFields is a list of field names (e.g. "ConfigApi") to // unconditionally include in API requests. By default, fields with empty or diff --git a/iamcredentials/v1/iamcredentials-api.json b/iamcredentials/v1/iamcredentials-api.json index 1949c777bf2..a841fc7cb9e 100644 --- a/iamcredentials/v1/iamcredentials-api.json +++ b/iamcredentials/v1/iamcredentials-api.json @@ -16,6 +16,26 @@ "discoveryVersion": "v1", "documentationLink": "https://cloud.google.com/iam/docs/creating-short-lived-service-account-credentials", "endpoints": [ + { + "description": "Regional Endpoint", + "endpointUrl": "https://iamcredentials.asia-east1.rep.googleapis.com/", + "location": "asia-east1" + }, + { + "description": "Regional Endpoint", + "endpointUrl": "https://iamcredentials.europe-west1.rep.googleapis.com/", + "location": "europe-west1" + }, + { + "description": "Regional Endpoint", + "endpointUrl": "https://iamcredentials.us-central1.rep.googleapis.com/", + "location": "us-central1" + }, + { + "description": "Regional Endpoint", + "endpointUrl": "https://iamcredentials.us-east1.rep.googleapis.com/", + "location": "us-east1" + }, { "description": "Regional Endpoint", "endpointUrl": "https://iamcredentials.us-east7.rep.googleapis.com/", @@ -315,7 +335,7 @@ } } }, - "revision": "20250417", + "revision": "20250717", "rootUrl": "https://iamcredentials.googleapis.com/", "schemas": { "GenerateAccessTokenRequest": { diff --git a/merchantapi/products_v1beta/merchantapi-api.json b/merchantapi/products_v1beta/merchantapi-api.json index 22e56128229..f274789c9a2 100644 --- a/merchantapi/products_v1beta/merchantapi-api.json +++ b/merchantapi/products_v1beta/merchantapi-api.json @@ -281,7 +281,7 @@ } } }, - "revision": "20250716", + "revision": "20250724", "rootUrl": "https://merchantapi.googleapis.com/", "schemas": { "Attributes": { @@ -423,7 +423,7 @@ "type": "string" }, "excludedDestinations": { - "description": "The list of destinations to exclude for this target (corresponds to unchecked check boxes in Merchant Center). For more information, see [Excluded destination](https://support.google.com/merchants/answer/6324486). Note: We recommend setting destinations on datasources level for most use cases. Use this field within products to only setup exceptions.", + "description": "Destinations also known as [Marketing methods](https://support.google.com/merchants/answer/15130232) selections. The list of destinations to exclude for this target (corresponds to unchecked check boxes in Merchant Center). For more information, see [Excluded destination](https://support.google.com/merchants/answer/6324486). Note: We recommend setting destinations on datasources level for most use cases. Use this field within products to only setup exceptions.", "items": { "type": "string" }, @@ -477,7 +477,7 @@ "type": "string" }, "includedDestinations": { - "description": "The list of destinations to include for this target (corresponds to checked check boxes in Merchant Center). Default destinations are always included unless provided in `excludedDestinations`. For more information, see [Included destination](https://support.google.com/merchants/answer/7501026). Note: We recommend setting destinations on datasources level for most use cases. Use this field within products to only setup exceptions.", + "description": "Destinations also known as [Marketing methods](https://support.google.com/merchants/answer/15130232) selections. The list of destinations to include for this target (corresponds to checked check boxes in Merchant Center). Default destinations are always included unless provided in `excludedDestinations`. For more information, see [Included destination](https://support.google.com/merchants/answer/7501026). Note: We recommend setting destinations on datasources level for most use cases. Use this field within products to only setup exceptions.", "items": { "type": "string" }, diff --git a/merchantapi/products_v1beta/merchantapi-gen.go b/merchantapi/products_v1beta/merchantapi-gen.go index 211403e1780..a12655f2a25 100644 --- a/merchantapi/products_v1beta/merchantapi-gen.go +++ b/merchantapi/products_v1beta/merchantapi-gen.go @@ -284,9 +284,10 @@ type Attributes struct { // EnergyEfficiencyClass: The energy efficiency class as defined in EU // directive 2010/30/EU. EnergyEfficiencyClass string `json:"energyEfficiencyClass,omitempty"` - // ExcludedDestinations: The list of destinations to exclude for this target - // (corresponds to unchecked check boxes in Merchant Center). For more - // information, see Excluded destination + // ExcludedDestinations: Destinations also known as Marketing methods + // (https://support.google.com/merchants/answer/15130232) selections. The list + // of destinations to exclude for this target (corresponds to unchecked check + // boxes in Merchant Center). For more information, see Excluded destination // (https://support.google.com/merchants/answer/6324486). Note: We recommend // setting destinations on datasources level for most use cases. Use this field // within products to only setup exceptions. @@ -327,13 +328,14 @@ type Attributes struct { IdentifierExists bool `json:"identifierExists,omitempty"` // ImageLink: URL of an image of the item. ImageLink string `json:"imageLink,omitempty"` - // IncludedDestinations: The list of destinations to include for this target - // (corresponds to checked check boxes in Merchant Center). Default - // destinations are always included unless provided in `excludedDestinations`. - // For more information, see Included destination - // (https://support.google.com/merchants/answer/7501026). Note: We recommend - // setting destinations on datasources level for most use cases. Use this field - // within products to only setup exceptions. + // IncludedDestinations: Destinations also known as Marketing methods + // (https://support.google.com/merchants/answer/15130232) selections. The list + // of destinations to include for this target (corresponds to checked check + // boxes in Merchant Center). Default destinations are always included unless + // provided in `excludedDestinations`. For more information, see Included + // destination (https://support.google.com/merchants/answer/7501026). Note: We + // recommend setting destinations on datasources level for most use cases. Use + // this field within products to only setup exceptions. IncludedDestinations []string `json:"includedDestinations,omitempty"` // Installment: Number and amount of installments to pay for an item. Installment *Installment `json:"installment,omitempty"` diff --git a/redis/v1/redis-api.json b/redis/v1/redis-api.json index 3037a3c2ea7..d61f83a5ff7 100644 --- a/redis/v1/redis-api.json +++ b/redis/v1/redis-api.json @@ -1073,7 +1073,7 @@ } } }, - "revision": "20250701", + "revision": "20250718", "rootUrl": "https://redis.googleapis.com/", "schemas": { "AOFConfig": { @@ -1367,6 +1367,17 @@ }, "type": "object" }, + "BackupDRConfiguration": { + "description": "BackupDRConfiguration to capture the backup and disaster recovery details of database resource.", + "id": "BackupDRConfiguration", + "properties": { + "backupdrManaged": { + "description": "Indicates if the resource is managed by BackupDR.", + "type": "boolean" + } + }, + "type": "object" + }, "BackupFile": { "description": "Backup is consisted of multiple backup files.", "id": "BackupFile", @@ -1615,6 +1626,16 @@ "format": "int32", "type": "integer" }, + "satisfiesPzi": { + "description": "Optional. Output only. Reserved for future use.", + "readOnly": true, + "type": "boolean" + }, + "satisfiesPzs": { + "description": "Optional. Output only. Reserved for future use.", + "readOnly": true, + "type": "boolean" + }, "shardCount": { "description": "Optional. Number of shards for the Redis cluster.", "format": "int32", @@ -2203,7 +2224,9 @@ "SIGNAL_TYPE_HIGH_READ_PRESSURE", "SIGNAL_TYPE_ENCRYPTION_ORG_POLICY_NOT_SATISFIED", "SIGNAL_TYPE_LOCATION_ORG_POLICY_NOT_SATISFIED", - "SIGNAL_TYPE_OUTDATED_MINOR_VERSION" + "SIGNAL_TYPE_OUTDATED_MINOR_VERSION", + "SIGNAL_TYPE_SCHEMA_NOT_OPTIMIZED", + "SIGNAL_TYPE_MANY_IDLE_CONNECTIONS" ], "enumDeprecated": [ false, @@ -2302,6 +2325,8 @@ false, false, false, + false, + false, false ], "enumDescriptions": [ @@ -2401,7 +2426,9 @@ "Heavy read pressure on the database rows.", "Encryption org policy not satisfied.", "Location org policy not satisfied.", - "Outdated DB minor version." + "Outdated DB minor version.", + "Schema not optimized.", + "High number of idle connections." ], "type": "string" }, @@ -2465,7 +2492,7 @@ "type": "object" }, "DatabaseResourceMetadata": { - "description": "Common model for database resource instance metadata. Next ID: 25", + "description": "Common model for database resource instance metadata. Next ID: 26", "id": "DatabaseResourceMetadata", "properties": { "availabilityConfiguration": { @@ -2480,6 +2507,10 @@ "$ref": "BackupRun", "description": "Latest backup run information for this instance" }, + "backupdrConfiguration": { + "$ref": "BackupDRConfiguration", + "description": "Optional. BackupDR Configuration for the resource." + }, "creationTime": { "description": "The creation time of the resource, i.e. the time when resource is created and recorded in partner service.", "format": "google-datetime", @@ -2552,6 +2583,7 @@ }, "gcbdrConfiguration": { "$ref": "GCBDRConfiguration", + "deprecated": true, "description": "GCBDR configuration for the resource." }, "id": { @@ -2819,7 +2851,9 @@ "SIGNAL_TYPE_HIGH_READ_PRESSURE", "SIGNAL_TYPE_ENCRYPTION_ORG_POLICY_NOT_SATISFIED", "SIGNAL_TYPE_LOCATION_ORG_POLICY_NOT_SATISFIED", - "SIGNAL_TYPE_OUTDATED_MINOR_VERSION" + "SIGNAL_TYPE_OUTDATED_MINOR_VERSION", + "SIGNAL_TYPE_SCHEMA_NOT_OPTIMIZED", + "SIGNAL_TYPE_MANY_IDLE_CONNECTIONS" ], "enumDeprecated": [ false, @@ -2918,6 +2952,8 @@ false, false, false, + false, + false, false ], "enumDescriptions": [ @@ -3017,7 +3053,9 @@ "Heavy read pressure on the database rows.", "Encryption org policy not satisfied.", "Location org policy not satisfied.", - "Outdated DB minor version." + "Outdated DB minor version.", + "Schema not optimized.", + "High number of idle connections." ], "type": "string" } @@ -4230,6 +4268,7 @@ "ENGINE_OTHER", "ENGINE_FIRESTORE_WITH_NATIVE_MODE", "ENGINE_FIRESTORE_WITH_DATASTORE_MODE", + "ENGINE_FIRESTORE_WITH_MONGODB_COMPATIBILITY_MODE", "ENGINE_EXADATA_ORACLE", "ENGINE_ADB_SERVERLESS_ORACLE" ], @@ -4251,6 +4290,7 @@ false, false, false, + false, false ], "enumDescriptions": [ @@ -4270,6 +4310,7 @@ "Other refers to rest of other database engine. This is to be when engine is known, but it is not present in this enum.", "Firestore with native mode.", "Firestore with datastore mode.", + "Firestore with MongoDB compatibility mode.", "Oracle Exadata engine.", "Oracle Autonomous DB Serverless engine." ], diff --git a/redis/v1/redis-gen.go b/redis/v1/redis-gen.go index 6c09b37b06e..76334c7e37f 100644 --- a/redis/v1/redis-gen.go +++ b/redis/v1/redis-gen.go @@ -518,6 +518,29 @@ func (s BackupConfiguration) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// BackupDRConfiguration: BackupDRConfiguration to capture the backup and +// disaster recovery details of database resource. +type BackupDRConfiguration struct { + // BackupdrManaged: Indicates if the resource is managed by BackupDR. + BackupdrManaged bool `json:"backupdrManaged,omitempty"` + // ForceSendFields is a list of field names (e.g. "BackupdrManaged") 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. "BackupdrManaged") 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 BackupDRConfiguration) MarshalJSON() ([]byte, error) { + type NoMethod BackupDRConfiguration + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // BackupFile: Backup is consisted of multiple backup files. type BackupFile struct { // CreateTime: Output only. The time when the backup file was created. @@ -728,6 +751,10 @@ type Cluster struct { RedisConfigs map[string]string `json:"redisConfigs,omitempty"` // ReplicaCount: Optional. The number of replica nodes per shard. ReplicaCount int64 `json:"replicaCount,omitempty"` + // SatisfiesPzi: Optional. Output only. Reserved for future use. + SatisfiesPzi bool `json:"satisfiesPzi,omitempty"` + // SatisfiesPzs: Optional. Output only. Reserved for future use. + SatisfiesPzs bool `json:"satisfiesPzs,omitempty"` // ShardCount: Optional. Number of shards for the Redis cluster. ShardCount int64 `json:"shardCount,omitempty"` // SimulateMaintenanceEvent: Optional. Input only. Simulate a maintenance @@ -1478,6 +1505,8 @@ type DatabaseResourceHealthSignalData struct { // "SIGNAL_TYPE_LOCATION_ORG_POLICY_NOT_SATISFIED" - Location org policy not // satisfied. // "SIGNAL_TYPE_OUTDATED_MINOR_VERSION" - Outdated DB minor version. + // "SIGNAL_TYPE_SCHEMA_NOT_OPTIMIZED" - Schema not optimized. + // "SIGNAL_TYPE_MANY_IDLE_CONNECTIONS" - High number of idle connections. SignalType string `json:"signalType,omitempty"` // Possible values: // "STATE_UNSPECIFIED" - Unspecified state. @@ -1562,7 +1591,7 @@ func (s DatabaseResourceId) MarshalJSON() ([]byte, error) { } // DatabaseResourceMetadata: Common model for database resource instance -// metadata. Next ID: 25 +// metadata. Next ID: 26 type DatabaseResourceMetadata struct { // AvailabilityConfiguration: Availability configuration for this instance AvailabilityConfiguration *AvailabilityConfiguration `json:"availabilityConfiguration,omitempty"` @@ -1570,6 +1599,8 @@ type DatabaseResourceMetadata struct { BackupConfiguration *BackupConfiguration `json:"backupConfiguration,omitempty"` // BackupRun: Latest backup run information for this instance BackupRun *BackupRun `json:"backupRun,omitempty"` + // BackupdrConfiguration: Optional. BackupDR Configuration for the resource. + BackupdrConfiguration *BackupDRConfiguration `json:"backupdrConfiguration,omitempty"` // CreationTime: The creation time of the resource, i.e. the time when resource // is created and recorded in partner service. CreationTime string `json:"creationTime,omitempty"` @@ -1963,6 +1994,8 @@ type DatabaseResourceRecommendationSignalData struct { // "SIGNAL_TYPE_LOCATION_ORG_POLICY_NOT_SATISFIED" - Location org policy not // satisfied. // "SIGNAL_TYPE_OUTDATED_MINOR_VERSION" - Outdated DB minor version. + // "SIGNAL_TYPE_SCHEMA_NOT_OPTIMIZED" - Schema not optimized. + // "SIGNAL_TYPE_MANY_IDLE_CONNECTIONS" - High number of idle connections. SignalType string `json:"signalType,omitempty"` // ForceSendFields is a list of field names (e.g. "AdditionalMetadata") to // unconditionally include in API requests. By default, fields with empty or @@ -3424,6 +3457,8 @@ type Product struct { // be when engine is known, but it is not present in this enum. // "ENGINE_FIRESTORE_WITH_NATIVE_MODE" - Firestore with native mode. // "ENGINE_FIRESTORE_WITH_DATASTORE_MODE" - Firestore with datastore mode. + // "ENGINE_FIRESTORE_WITH_MONGODB_COMPATIBILITY_MODE" - Firestore with + // MongoDB compatibility mode. // "ENGINE_EXADATA_ORACLE" - Oracle Exadata engine. // "ENGINE_ADB_SERVERLESS_ORACLE" - Oracle Autonomous DB Serverless engine. Engine string `json:"engine,omitempty"` diff --git a/redis/v1beta1/redis-api.json b/redis/v1beta1/redis-api.json index a79730b853b..b6c878ecf47 100644 --- a/redis/v1beta1/redis-api.json +++ b/redis/v1beta1/redis-api.json @@ -1073,7 +1073,7 @@ } } }, - "revision": "20250701", + "revision": "20250718", "rootUrl": "https://redis.googleapis.com/", "schemas": { "AOFConfig": { @@ -1367,6 +1367,17 @@ }, "type": "object" }, + "BackupDRConfiguration": { + "description": "BackupDRConfiguration to capture the backup and disaster recovery details of database resource.", + "id": "BackupDRConfiguration", + "properties": { + "backupdrManaged": { + "description": "Indicates if the resource is managed by BackupDR.", + "type": "boolean" + } + }, + "type": "object" + }, "BackupFile": { "description": "Backup is consisted of multiple backup files.", "id": "BackupFile", @@ -1615,6 +1626,16 @@ "format": "int32", "type": "integer" }, + "satisfiesPzi": { + "description": "Optional. Output only. Reserved for future use.", + "readOnly": true, + "type": "boolean" + }, + "satisfiesPzs": { + "description": "Optional. Output only. Reserved for future use.", + "readOnly": true, + "type": "boolean" + }, "shardCount": { "description": "Optional. Number of shards for the Redis cluster.", "format": "int32", @@ -2203,7 +2224,9 @@ "SIGNAL_TYPE_HIGH_READ_PRESSURE", "SIGNAL_TYPE_ENCRYPTION_ORG_POLICY_NOT_SATISFIED", "SIGNAL_TYPE_LOCATION_ORG_POLICY_NOT_SATISFIED", - "SIGNAL_TYPE_OUTDATED_MINOR_VERSION" + "SIGNAL_TYPE_OUTDATED_MINOR_VERSION", + "SIGNAL_TYPE_SCHEMA_NOT_OPTIMIZED", + "SIGNAL_TYPE_MANY_IDLE_CONNECTIONS" ], "enumDeprecated": [ false, @@ -2302,6 +2325,8 @@ false, false, false, + false, + false, false ], "enumDescriptions": [ @@ -2401,7 +2426,9 @@ "Heavy read pressure on the database rows.", "Encryption org policy not satisfied.", "Location org policy not satisfied.", - "Outdated DB minor version." + "Outdated DB minor version.", + "Schema not optimized.", + "High number of idle connections." ], "type": "string" }, @@ -2465,7 +2492,7 @@ "type": "object" }, "DatabaseResourceMetadata": { - "description": "Common model for database resource instance metadata. Next ID: 25", + "description": "Common model for database resource instance metadata. Next ID: 26", "id": "DatabaseResourceMetadata", "properties": { "availabilityConfiguration": { @@ -2480,6 +2507,10 @@ "$ref": "BackupRun", "description": "Latest backup run information for this instance" }, + "backupdrConfiguration": { + "$ref": "BackupDRConfiguration", + "description": "Optional. BackupDR Configuration for the resource." + }, "creationTime": { "description": "The creation time of the resource, i.e. the time when resource is created and recorded in partner service.", "format": "google-datetime", @@ -2552,6 +2583,7 @@ }, "gcbdrConfiguration": { "$ref": "GCBDRConfiguration", + "deprecated": true, "description": "GCBDR configuration for the resource." }, "id": { @@ -2819,7 +2851,9 @@ "SIGNAL_TYPE_HIGH_READ_PRESSURE", "SIGNAL_TYPE_ENCRYPTION_ORG_POLICY_NOT_SATISFIED", "SIGNAL_TYPE_LOCATION_ORG_POLICY_NOT_SATISFIED", - "SIGNAL_TYPE_OUTDATED_MINOR_VERSION" + "SIGNAL_TYPE_OUTDATED_MINOR_VERSION", + "SIGNAL_TYPE_SCHEMA_NOT_OPTIMIZED", + "SIGNAL_TYPE_MANY_IDLE_CONNECTIONS" ], "enumDeprecated": [ false, @@ -2918,6 +2952,8 @@ false, false, false, + false, + false, false ], "enumDescriptions": [ @@ -3017,7 +3053,9 @@ "Heavy read pressure on the database rows.", "Encryption org policy not satisfied.", "Location org policy not satisfied.", - "Outdated DB minor version." + "Outdated DB minor version.", + "Schema not optimized.", + "High number of idle connections." ], "type": "string" } @@ -4237,6 +4275,7 @@ "ENGINE_OTHER", "ENGINE_FIRESTORE_WITH_NATIVE_MODE", "ENGINE_FIRESTORE_WITH_DATASTORE_MODE", + "ENGINE_FIRESTORE_WITH_MONGODB_COMPATIBILITY_MODE", "ENGINE_EXADATA_ORACLE", "ENGINE_ADB_SERVERLESS_ORACLE" ], @@ -4258,6 +4297,7 @@ false, false, false, + false, false ], "enumDescriptions": [ @@ -4277,6 +4317,7 @@ "Other refers to rest of other database engine. This is to be when engine is known, but it is not present in this enum.", "Firestore with native mode.", "Firestore with datastore mode.", + "Firestore with MongoDB compatibility mode.", "Oracle Exadata engine.", "Oracle Autonomous DB Serverless engine." ], diff --git a/redis/v1beta1/redis-gen.go b/redis/v1beta1/redis-gen.go index 501e9aaa6b2..d62fa624adc 100644 --- a/redis/v1beta1/redis-gen.go +++ b/redis/v1beta1/redis-gen.go @@ -518,6 +518,29 @@ func (s BackupConfiguration) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// BackupDRConfiguration: BackupDRConfiguration to capture the backup and +// disaster recovery details of database resource. +type BackupDRConfiguration struct { + // BackupdrManaged: Indicates if the resource is managed by BackupDR. + BackupdrManaged bool `json:"backupdrManaged,omitempty"` + // ForceSendFields is a list of field names (e.g. "BackupdrManaged") 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. "BackupdrManaged") 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 BackupDRConfiguration) MarshalJSON() ([]byte, error) { + type NoMethod BackupDRConfiguration + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // BackupFile: Backup is consisted of multiple backup files. type BackupFile struct { // CreateTime: Output only. The time when the backup file was created. @@ -728,6 +751,10 @@ type Cluster struct { RedisConfigs map[string]string `json:"redisConfigs,omitempty"` // ReplicaCount: Optional. The number of replica nodes per shard. ReplicaCount int64 `json:"replicaCount,omitempty"` + // SatisfiesPzi: Optional. Output only. Reserved for future use. + SatisfiesPzi bool `json:"satisfiesPzi,omitempty"` + // SatisfiesPzs: Optional. Output only. Reserved for future use. + SatisfiesPzs bool `json:"satisfiesPzs,omitempty"` // ShardCount: Optional. Number of shards for the Redis cluster. ShardCount int64 `json:"shardCount,omitempty"` // SimulateMaintenanceEvent: Optional. Input only. Simulate a maintenance @@ -1478,6 +1505,8 @@ type DatabaseResourceHealthSignalData struct { // "SIGNAL_TYPE_LOCATION_ORG_POLICY_NOT_SATISFIED" - Location org policy not // satisfied. // "SIGNAL_TYPE_OUTDATED_MINOR_VERSION" - Outdated DB minor version. + // "SIGNAL_TYPE_SCHEMA_NOT_OPTIMIZED" - Schema not optimized. + // "SIGNAL_TYPE_MANY_IDLE_CONNECTIONS" - High number of idle connections. SignalType string `json:"signalType,omitempty"` // Possible values: // "STATE_UNSPECIFIED" - Unspecified state. @@ -1562,7 +1591,7 @@ func (s DatabaseResourceId) MarshalJSON() ([]byte, error) { } // DatabaseResourceMetadata: Common model for database resource instance -// metadata. Next ID: 25 +// metadata. Next ID: 26 type DatabaseResourceMetadata struct { // AvailabilityConfiguration: Availability configuration for this instance AvailabilityConfiguration *AvailabilityConfiguration `json:"availabilityConfiguration,omitempty"` @@ -1570,6 +1599,8 @@ type DatabaseResourceMetadata struct { BackupConfiguration *BackupConfiguration `json:"backupConfiguration,omitempty"` // BackupRun: Latest backup run information for this instance BackupRun *BackupRun `json:"backupRun,omitempty"` + // BackupdrConfiguration: Optional. BackupDR Configuration for the resource. + BackupdrConfiguration *BackupDRConfiguration `json:"backupdrConfiguration,omitempty"` // CreationTime: The creation time of the resource, i.e. the time when resource // is created and recorded in partner service. CreationTime string `json:"creationTime,omitempty"` @@ -1963,6 +1994,8 @@ type DatabaseResourceRecommendationSignalData struct { // "SIGNAL_TYPE_LOCATION_ORG_POLICY_NOT_SATISFIED" - Location org policy not // satisfied. // "SIGNAL_TYPE_OUTDATED_MINOR_VERSION" - Outdated DB minor version. + // "SIGNAL_TYPE_SCHEMA_NOT_OPTIMIZED" - Schema not optimized. + // "SIGNAL_TYPE_MANY_IDLE_CONNECTIONS" - High number of idle connections. SignalType string `json:"signalType,omitempty"` // ForceSendFields is a list of field names (e.g. "AdditionalMetadata") to // unconditionally include in API requests. By default, fields with empty or @@ -3428,6 +3461,8 @@ type Product struct { // be when engine is known, but it is not present in this enum. // "ENGINE_FIRESTORE_WITH_NATIVE_MODE" - Firestore with native mode. // "ENGINE_FIRESTORE_WITH_DATASTORE_MODE" - Firestore with datastore mode. + // "ENGINE_FIRESTORE_WITH_MONGODB_COMPATIBILITY_MODE" - Firestore with + // MongoDB compatibility mode. // "ENGINE_EXADATA_ORACLE" - Oracle Exadata engine. // "ENGINE_ADB_SERVERLESS_ORACLE" - Oracle Autonomous DB Serverless engine. Engine string `json:"engine,omitempty"` diff --git a/run/v2/run-api.json b/run/v2/run-api.json index b76bab99551..d8ce28480f6 100644 --- a/run/v2/run-api.json +++ b/run/v2/run-api.json @@ -1922,7 +1922,7 @@ } } }, - "revision": "20250712", + "revision": "20250718", "rootUrl": "https://run.googleapis.com/", "schemas": { "GoogleCloudRunV2BinaryAuthorization": { @@ -2958,8 +2958,7 @@ "type": "string" }, "etag": { - "description": "Output only. A system-generated fingerprint for this version of the resource. May be used to detect modification conflict during updates.", - "readOnly": true, + "description": "Optional. A system-generated fingerprint for this version of the resource. May be used to detect modification conflict during updates.", "type": "string" }, "executionCount": { @@ -3844,8 +3843,7 @@ "type": "string" }, "etag": { - "description": "Output only. A system-generated fingerprint for this version of the resource. May be used to detect modification conflict during updates.", - "readOnly": true, + "description": "Optional. A system-generated fingerprint for this version of the resource. May be used to detect modification conflict during updates.", "type": "string" }, "expireTime": { @@ -4675,8 +4673,7 @@ "type": "string" }, "etag": { - "description": "Output only. A system-generated fingerprint for this version of the resource. May be used to detect modification conflict during updates.", - "readOnly": true, + "description": "Optional. A system-generated fingerprint for this version of the resource. May be used to detect modification conflict during updates.", "type": "string" }, "expireTime": { diff --git a/run/v2/run-gen.go b/run/v2/run-gen.go index 564e7ac3390..16d9513420c 100644 --- a/run/v2/run-gen.go +++ b/run/v2/run-gen.go @@ -1420,7 +1420,7 @@ type GoogleCloudRunV2Job struct { // DeleteTime: Output only. The deletion time. It is only populated as a // response to a Delete request. DeleteTime string `json:"deleteTime,omitempty"` - // Etag: Output only. A system-generated fingerprint for this version of the + // Etag: Optional. A system-generated fingerprint for this version of the // resource. May be used to detect modification conflict during updates. Etag string `json:"etag,omitempty"` // ExecutionCount: Output only. Number of executions created for this job. @@ -2464,7 +2464,7 @@ type GoogleCloudRunV2Service struct { // Description: User-provided description of the Service. This field currently // has a 512-character limit. Description string `json:"description,omitempty"` - // Etag: Output only. A system-generated fingerprint for this version of the + // Etag: Optional. A system-generated fingerprint for this version of the // resource. May be used to detect modification conflict during updates. Etag string `json:"etag,omitempty"` // ExpireTime: Output only. For a deleted resource, the time after which it @@ -3330,7 +3330,7 @@ type GoogleCloudRunV2WorkerPool struct { // Description: User-provided description of the WorkerPool. This field // currently has a 512-character limit. Description string `json:"description,omitempty"` - // Etag: Output only. A system-generated fingerprint for this version of the + // Etag: Optional. A system-generated fingerprint for this version of the // resource. May be used to detect modification conflict during updates. Etag string `json:"etag,omitempty"` // ExpireTime: Output only. For a deleted resource, the time after which it diff --git a/workloadmanager/v1/workloadmanager-api.json b/workloadmanager/v1/workloadmanager-api.json index 1d563bcda48..38869f6b9a7 100644 --- a/workloadmanager/v1/workloadmanager-api.json +++ b/workloadmanager/v1/workloadmanager-api.json @@ -879,7 +879,7 @@ } } }, - "revision": "20250630", + "revision": "20250714", "rootUrl": "https://workloadmanager.googleapis.com/", "schemas": { "AgentCommand": { @@ -963,6 +963,11 @@ "readOnly": true, "type": "string" }, + "instanceUri": { + "description": "Output only. The URI of the instance. Format: projects//zones//instances/", + "readOnly": true, + "type": "string" + }, "kernelVersion": { "$ref": "SapDiscoveryResourceInstancePropertiesKernelVersion", "description": "Output only. The kernel version of the system.", diff --git a/workloadmanager/v1/workloadmanager-gen.go b/workloadmanager/v1/workloadmanager-gen.go index ffdd364b591..283289354b8 100644 --- a/workloadmanager/v1/workloadmanager-gen.go +++ b/workloadmanager/v1/workloadmanager-gen.go @@ -339,6 +339,9 @@ type AgentStatus struct { // InstalledVersion: Output only. The installed version of the agent on the // host. InstalledVersion string `json:"installedVersion,omitempty"` + // InstanceUri: Output only. The URI of the instance. Format: + // projects//zones//instances/ + InstanceUri string `json:"instanceUri,omitempty"` // KernelVersion: Output only. The kernel version of the system. KernelVersion *SapDiscoveryResourceInstancePropertiesKernelVersion `json:"kernelVersion,omitempty"` // References: Output only. Optional references to public documentation. From 09e5c0743dfa02b62cf54c797725b5c09744ec65 Mon Sep 17 00:00:00 2001 From: Yoshi Automation Bot Date: Sun, 27 Jul 2025 00:36:22 -0700 Subject: [PATCH 05/10] feat(all): auto-regenerate discovery clients (#3247) --- .../v1/accesscontextmanager-api.json | 4 +- .../v1/accesscontextmanager-gen.go | 6 +- alloydb/v1/alloydb-api.json | 153 +++++++- alloydb/v1/alloydb-gen.go | 137 ++++++- datacatalog/v1/datacatalog-api.json | 3 +- datacatalog/v1/datacatalog-gen.go | 3 - drive/v3/drive-api.json | 108 +----- drive/v3/drive-gen.go | 337 ------------------ gkehub/v1alpha/gkehub-api.json | 20 +- gkehub/v1alpha/gkehub-gen.go | 6 + gkehub/v2beta/gkehub-api.json | 20 +- gkehub/v2beta/gkehub-gen.go | 6 + looker/v1/looker-api.json | 16 +- looker/v1/looker-gen.go | 7 + .../v1/videointelligence-api.json | 177 ++++++++- videointelligence/v1/videointelligence-gen.go | 225 ++++++++++-- .../v1beta2/videointelligence-api.json | 177 ++++++++- .../v1beta2/videointelligence-gen.go | 225 ++++++++++-- .../v1p1beta1/videointelligence-api.json | 177 ++++++++- .../v1p1beta1/videointelligence-gen.go | 225 ++++++++++-- .../v1p2beta1/videointelligence-api.json | 177 ++++++++- .../v1p2beta1/videointelligence-gen.go | 225 ++++++++++-- .../v1p3beta1/videointelligence-api.json | 177 ++++++++- .../v1p3beta1/videointelligence-gen.go | 225 ++++++++++-- 24 files changed, 2147 insertions(+), 689 deletions(-) diff --git a/accesscontextmanager/v1/accesscontextmanager-api.json b/accesscontextmanager/v1/accesscontextmanager-api.json index 78798bb9054..40e164f1439 100644 --- a/accesscontextmanager/v1/accesscontextmanager-api.json +++ b/accesscontextmanager/v1/accesscontextmanager-api.json @@ -1295,7 +1295,7 @@ } } }, - "revision": "20250412", + "revision": "20250723", "rootUrl": "https://accesscontextmanager.googleapis.com/", "schemas": { "AccessContextManagerOperationMetadata": { @@ -1913,7 +1913,7 @@ "type": "array" }, "groupKey": { - "description": "Required. Immutable. Google Group id whose members are subject to this binding's restrictions. See \"id\" in the [G Suite Directory API's Groups resource] (https://developers.google.com/admin-sdk/directory/v1/reference/groups#resource). If a group's email address/alias is changed, this resource will continue to point at the changed group. This field does not accept group email addresses or aliases. Example: \"01d520gv4vjcrht\"", + "description": "Optional. Immutable. Google Group id whose users are subject to this binding's restrictions. See \"id\" in the [Google Workspace Directory API's Group Resource] (https://developers.google.com/admin-sdk/directory/v1/reference/groups#resource). If a group's email address/alias is changed, this resource will continue to point at the changed group. This field does not accept group email addresses or aliases. Example: \"01d520gv4vjcrht\"", "type": "string" }, "name": { diff --git a/accesscontextmanager/v1/accesscontextmanager-gen.go b/accesscontextmanager/v1/accesscontextmanager-gen.go index 5a0822eef41..d7c77c7740e 100644 --- a/accesscontextmanager/v1/accesscontextmanager-gen.go +++ b/accesscontextmanager/v1/accesscontextmanager-gen.go @@ -1215,9 +1215,9 @@ type GcpUserAccessBinding struct { // have exactly one element. Example: // "accessPolicies/9522/accessLevels/device_trusted" DryRunAccessLevels []string `json:"dryRunAccessLevels,omitempty"` - // GroupKey: Required. Immutable. Google Group id whose members are subject to - // this binding's restrictions. See "id" in the [G Suite Directory API's Groups - // resource] + // GroupKey: Optional. Immutable. Google Group id whose users are subject to + // this binding's restrictions. See "id" in the [Google Workspace Directory + // API's Group Resource] // (https://developers.google.com/admin-sdk/directory/v1/reference/groups#resource). // If a group's email address/alias is changed, this resource will continue to // point at the changed group. This field does not accept group email addresses diff --git a/alloydb/v1/alloydb-api.json b/alloydb/v1/alloydb-api.json index 4089f7de899..94cd27e4c95 100644 --- a/alloydb/v1/alloydb-api.json +++ b/alloydb/v1/alloydb-api.json @@ -1622,7 +1622,7 @@ } } }, - "revision": "20250612", + "revision": "20250723", "rootUrl": "https://alloydb.googleapis.com/", "schemas": { "AuthorizedNetwork": { @@ -3888,6 +3888,33 @@ }, "type": "object" }, + "StageSchedule": { + "description": "Timing information for the stage execution.", + "id": "StageSchedule", + "properties": { + "actualEndTime": { + "description": "Actual end time of the stage. Set only if the stage has completed.", + "format": "google-datetime", + "type": "string" + }, + "actualStartTime": { + "description": "Actual start time of the stage. Set only if the stage has started.", + "format": "google-datetime", + "type": "string" + }, + "estimatedEndTime": { + "description": "When the stage is expected to end. Set only if the stage has not completed yet.", + "format": "google-datetime", + "type": "string" + }, + "estimatedStartTime": { + "description": "When the stage is expected to start. Set only if the stage has not started yet.", + "format": "google-datetime", + "type": "string" + } + }, + "type": "object" + }, "StageStatus": { "description": "Status of an upgrade stage.", "id": "StageStatus", @@ -3896,6 +3923,11 @@ "$ref": "ReadPoolInstancesUpgradeStageStatus", "description": "Read pool instances upgrade metadata." }, + "schedule": { + "$ref": "StageSchedule", + "description": "Output only. Timing information for the stage execution.", + "readOnly": true + }, "stage": { "description": "Upgrade stage.", "enum": [ @@ -4059,6 +4091,17 @@ }, "type": "object" }, + "StorageDatabasecenterPartnerapiV1mainBackupDRConfiguration": { + "description": "BackupDRConfiguration to capture the backup and disaster recovery details of database resource.", + "id": "StorageDatabasecenterPartnerapiV1mainBackupDRConfiguration", + "properties": { + "backupdrManaged": { + "description": "Indicates if the resource is managed by BackupDR.", + "type": "boolean" + } + }, + "type": "object" + }, "StorageDatabasecenterPartnerapiV1mainBackupRun": { "description": "A backup run.", "id": "StorageDatabasecenterPartnerapiV1mainBackupRun", @@ -4109,6 +4152,50 @@ }, "type": "object" }, + "StorageDatabasecenterPartnerapiV1mainConfigBasedSignalData": { + "description": "Config based signal data. This is used to send signals to Condor which are based on the DB level configurations. These will be used to send signals for self managed databases.", + "id": "StorageDatabasecenterPartnerapiV1mainConfigBasedSignalData", + "properties": { + "fullResourceName": { + "description": "Required. Full Resource name of the source resource.", + "type": "string" + }, + "lastRefreshTime": { + "description": "Required. Last time signal was refreshed", + "format": "google-datetime", + "type": "string" + }, + "resourceId": { + "$ref": "StorageDatabasecenterPartnerapiV1mainDatabaseResourceId", + "description": "Database resource id." + }, + "signalBoolValue": { + "description": "Signal data for boolean signals.", + "type": "boolean" + }, + "signalType": { + "description": "Required. Signal type of the signal", + "enum": [ + "SIGNAL_TYPE_UNSPECIFIED", + "SIGNAL_TYPE_OUTDATED_MINOR_VERSION", + "SIGNAL_TYPE_DATABASE_AUDITING_DISABLED", + "SIGNAL_TYPE_NO_ROOT_PASSWORD", + "SIGNAL_TYPE_EXPOSED_TO_PUBLIC_ACCESS", + "SIGNAL_TYPE_UNENCRYPTED_CONNECTIONS" + ], + "enumDescriptions": [ + "Unspecified signal type.", + "Outdated Minor Version", + "Represents database auditing is disabled.", + "Represents if a database has a password configured for the root account or not.", + "Represents if a resource is exposed to public access.", + "Represents if a resources requires all incoming connections to use SSL or not." + ], + "type": "string" + } + }, + "type": "object" + }, "StorageDatabasecenterPartnerapiV1mainCustomMetadataData": { "description": "Any custom metadata associated with the resource. e.g. A spanner instance can have multiple databases with its own unique metadata. Information for these individual databases can be captured in custom metadata data", "id": "StorageDatabasecenterPartnerapiV1mainCustomMetadataData", @@ -4124,9 +4211,13 @@ "type": "object" }, "StorageDatabasecenterPartnerapiV1mainDatabaseResourceFeed": { - "description": "DatabaseResourceFeed is the top level proto to be used to ingest different database resource level events into Condor platform. Next ID: 8", + "description": "DatabaseResourceFeed is the top level proto to be used to ingest different database resource level events into Condor platform. Next ID: 9", "id": "StorageDatabasecenterPartnerapiV1mainDatabaseResourceFeed", "properties": { + "configBasedSignalData": { + "$ref": "StorageDatabasecenterPartnerapiV1mainConfigBasedSignalData", + "description": "Config based signal data is used to ingest signals that are generated based on the configuration of the database resource." + }, "feedTimestamp": { "description": "Required. Timestamp when feed is generated.", "format": "google-datetime", @@ -4139,14 +4230,16 @@ "RESOURCE_METADATA", "OBSERVABILITY_DATA", "SECURITY_FINDING_DATA", - "RECOMMENDATION_SIGNAL_DATA" + "RECOMMENDATION_SIGNAL_DATA", + "CONFIG_BASED_SIGNAL_DATA" ], "enumDescriptions": [ "", "Database resource metadata feed from control plane", "Database resource monitoring data", "Database resource security health signal data", - "Database resource recommendation signal data" + "Database resource recommendation signal data", + "Database config based signal data" ], "type": "string" }, @@ -4380,7 +4473,12 @@ "SIGNAL_TYPE_HIGH_WRITE_PRESSURE", "SIGNAL_TYPE_HIGH_READ_PRESSURE", "SIGNAL_TYPE_ENCRYPTION_ORG_POLICY_NOT_SATISFIED", - "SIGNAL_TYPE_LOCATION_ORG_POLICY_NOT_SATISFIED" + "SIGNAL_TYPE_LOCATION_ORG_POLICY_NOT_SATISFIED", + "SIGNAL_TYPE_OUTDATED_MINOR_VERSION", + "SIGNAL_TYPE_SCHEMA_NOT_OPTIMIZED", + "SIGNAL_TYPE_MANY_IDLE_CONNECTIONS", + "SIGNAL_TYPE_REPLICATION_LAG", + "SIGNAL_TYPE_OUTDATED_VERSION" ], "enumDeprecated": [ false, @@ -4478,6 +4576,11 @@ false, false, false, + false, + false, + false, + false, + false, false ], "enumDescriptions": [ @@ -4576,7 +4679,12 @@ "Heavy write pressure on the database rows.", "Heavy read pressure on the database rows.", "Encryption org policy not satisfied.", - "Location org policy not satisfied." + "Location org policy not satisfied.", + "Outdated DB minor version.", + "Schema not optimized.", + "High number of idle connections.", + "Replication delay.", + "Outdated version." ], "type": "string" }, @@ -4640,7 +4748,7 @@ "type": "object" }, "StorageDatabasecenterPartnerapiV1mainDatabaseResourceMetadata": { - "description": "Common model for database resource instance metadata. Next ID: 25", + "description": "Common model for database resource instance metadata. Next ID: 26", "id": "StorageDatabasecenterPartnerapiV1mainDatabaseResourceMetadata", "properties": { "availabilityConfiguration": { @@ -4655,6 +4763,10 @@ "$ref": "StorageDatabasecenterPartnerapiV1mainBackupRun", "description": "Latest backup run information for this instance" }, + "backupdrConfiguration": { + "$ref": "StorageDatabasecenterPartnerapiV1mainBackupDRConfiguration", + "description": "Optional. BackupDR Configuration for the resource." + }, "creationTime": { "description": "The creation time of the resource, i.e. the time when resource is created and recorded in partner service.", "format": "google-datetime", @@ -4727,6 +4839,7 @@ }, "gcbdrConfiguration": { "$ref": "StorageDatabasecenterPartnerapiV1mainGCBDRConfiguration", + "deprecated": true, "description": "GCBDR configuration for the resource." }, "id": { @@ -4993,7 +5106,12 @@ "SIGNAL_TYPE_HIGH_WRITE_PRESSURE", "SIGNAL_TYPE_HIGH_READ_PRESSURE", "SIGNAL_TYPE_ENCRYPTION_ORG_POLICY_NOT_SATISFIED", - "SIGNAL_TYPE_LOCATION_ORG_POLICY_NOT_SATISFIED" + "SIGNAL_TYPE_LOCATION_ORG_POLICY_NOT_SATISFIED", + "SIGNAL_TYPE_OUTDATED_MINOR_VERSION", + "SIGNAL_TYPE_SCHEMA_NOT_OPTIMIZED", + "SIGNAL_TYPE_MANY_IDLE_CONNECTIONS", + "SIGNAL_TYPE_REPLICATION_LAG", + "SIGNAL_TYPE_OUTDATED_VERSION" ], "enumDeprecated": [ false, @@ -5091,6 +5209,11 @@ false, false, false, + false, + false, + false, + false, + false, false ], "enumDescriptions": [ @@ -5189,7 +5312,12 @@ "Heavy write pressure on the database rows.", "Heavy read pressure on the database rows.", "Encryption org policy not satisfied.", - "Location org policy not satisfied." + "Location org policy not satisfied.", + "Outdated DB minor version.", + "Schema not optimized.", + "High number of idle connections.", + "Replication delay.", + "Outdated version." ], "type": "string" } @@ -5500,6 +5628,7 @@ "ENGINE_OTHER", "ENGINE_FIRESTORE_WITH_NATIVE_MODE", "ENGINE_FIRESTORE_WITH_DATASTORE_MODE", + "ENGINE_FIRESTORE_WITH_MONGODB_COMPATIBILITY_MODE", "ENGINE_EXADATA_ORACLE", "ENGINE_ADB_SERVERLESS_ORACLE" ], @@ -5521,6 +5650,7 @@ false, false, false, + false, false ], "enumDescriptions": [ @@ -5540,11 +5670,16 @@ "Other refers to rest of other database engine. This is to be when engine is known, but it is not present in this enum.", "Firestore with native mode.", "Firestore with datastore mode.", + "Firestore with MongoDB compatibility mode.", "Oracle Exadata engine.", "Oracle Autonomous DB Serverless engine." ], "type": "string" }, + "minorVersion": { + "description": "Minor version of the underlying database engine. Example values: For MySQL, it could be \"8.0.32\", \"5.7.32\" etc.. For Postgres, it could be \"14.3\", \"15.3\" etc..", + "type": "string" + }, "type": { "description": "Type of specific database product. It could be CloudSQL, AlloyDB etc..", "enum": [ diff --git a/alloydb/v1/alloydb-gen.go b/alloydb/v1/alloydb-gen.go index 7527207f82f..c6b667c91e5 100644 --- a/alloydb/v1/alloydb-gen.go +++ b/alloydb/v1/alloydb-gen.go @@ -2895,10 +2895,44 @@ func (s StageInfo) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// StageSchedule: Timing information for the stage execution. +type StageSchedule struct { + // ActualEndTime: Actual end time of the stage. Set only if the stage has + // completed. + ActualEndTime string `json:"actualEndTime,omitempty"` + // ActualStartTime: Actual start time of the stage. Set only if the stage has + // started. + ActualStartTime string `json:"actualStartTime,omitempty"` + // EstimatedEndTime: When the stage is expected to end. Set only if the stage + // has not completed yet. + EstimatedEndTime string `json:"estimatedEndTime,omitempty"` + // EstimatedStartTime: When the stage is expected to start. Set only if the + // stage has not started yet. + EstimatedStartTime string `json:"estimatedStartTime,omitempty"` + // ForceSendFields is a list of field names (e.g. "ActualEndTime") 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. "ActualEndTime") 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 StageSchedule) MarshalJSON() ([]byte, error) { + type NoMethod StageSchedule + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // StageStatus: Status of an upgrade stage. type StageStatus struct { // ReadPoolInstancesUpgrade: Read pool instances upgrade metadata. ReadPoolInstancesUpgrade *ReadPoolInstancesUpgradeStageStatus `json:"readPoolInstancesUpgrade,omitempty"` + // Schedule: Output only. Timing information for the stage execution. + Schedule *StageSchedule `json:"schedule,omitempty"` // Stage: Upgrade stage. // // Possible values: @@ -3077,6 +3111,30 @@ func (s StorageDatabasecenterPartnerapiV1mainBackupConfiguration) MarshalJSON() return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// StorageDatabasecenterPartnerapiV1mainBackupDRConfiguration: +// BackupDRConfiguration to capture the backup and disaster recovery details of +// database resource. +type StorageDatabasecenterPartnerapiV1mainBackupDRConfiguration struct { + // BackupdrManaged: Indicates if the resource is managed by BackupDR. + BackupdrManaged bool `json:"backupdrManaged,omitempty"` + // ForceSendFields is a list of field names (e.g. "BackupdrManaged") 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. "BackupdrManaged") 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 StorageDatabasecenterPartnerapiV1mainBackupDRConfiguration) MarshalJSON() ([]byte, error) { + type NoMethod StorageDatabasecenterPartnerapiV1mainBackupDRConfiguration + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // StorageDatabasecenterPartnerapiV1mainBackupRun: A backup run. type StorageDatabasecenterPartnerapiV1mainBackupRun struct { // EndTime: The time the backup operation completed. REQUIRED @@ -3137,6 +3195,51 @@ func (s StorageDatabasecenterPartnerapiV1mainCompliance) MarshalJSON() ([]byte, return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// StorageDatabasecenterPartnerapiV1mainConfigBasedSignalData: Config based +// signal data. This is used to send signals to Condor which are based on the +// DB level configurations. These will be used to send signals for self managed +// databases. +type StorageDatabasecenterPartnerapiV1mainConfigBasedSignalData struct { + // FullResourceName: Required. Full Resource name of the source resource. + FullResourceName string `json:"fullResourceName,omitempty"` + // LastRefreshTime: Required. Last time signal was refreshed + LastRefreshTime string `json:"lastRefreshTime,omitempty"` + // ResourceId: Database resource id. + ResourceId *StorageDatabasecenterPartnerapiV1mainDatabaseResourceId `json:"resourceId,omitempty"` + // SignalBoolValue: Signal data for boolean signals. + SignalBoolValue bool `json:"signalBoolValue,omitempty"` + // SignalType: Required. Signal type of the signal + // + // Possible values: + // "SIGNAL_TYPE_UNSPECIFIED" - Unspecified signal type. + // "SIGNAL_TYPE_OUTDATED_MINOR_VERSION" - Outdated Minor Version + // "SIGNAL_TYPE_DATABASE_AUDITING_DISABLED" - Represents database auditing is + // disabled. + // "SIGNAL_TYPE_NO_ROOT_PASSWORD" - Represents if a database has a password + // configured for the root account or not. + // "SIGNAL_TYPE_EXPOSED_TO_PUBLIC_ACCESS" - Represents if a resource is + // exposed to public access. + // "SIGNAL_TYPE_UNENCRYPTED_CONNECTIONS" - Represents if a resources requires + // all incoming connections to use SSL or not. + SignalType string `json:"signalType,omitempty"` + // ForceSendFields is a list of field names (e.g. "FullResourceName") 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. "FullResourceName") 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 StorageDatabasecenterPartnerapiV1mainConfigBasedSignalData) MarshalJSON() ([]byte, error) { + type NoMethod StorageDatabasecenterPartnerapiV1mainConfigBasedSignalData + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // StorageDatabasecenterPartnerapiV1mainCustomMetadataData: Any custom metadata // associated with the resource. e.g. A spanner instance can have multiple // databases with its own unique metadata. Information for these individual @@ -3166,8 +3269,11 @@ func (s StorageDatabasecenterPartnerapiV1mainCustomMetadataData) MarshalJSON() ( // StorageDatabasecenterPartnerapiV1mainDatabaseResourceFeed: // DatabaseResourceFeed is the top level proto to be used to ingest different -// database resource level events into Condor platform. Next ID: 8 +// database resource level events into Condor platform. Next ID: 9 type StorageDatabasecenterPartnerapiV1mainDatabaseResourceFeed struct { + // ConfigBasedSignalData: Config based signal data is used to ingest signals + // that are generated based on the configuration of the database resource. + ConfigBasedSignalData *StorageDatabasecenterPartnerapiV1mainConfigBasedSignalData `json:"configBasedSignalData,omitempty"` // FeedTimestamp: Required. Timestamp when feed is generated. FeedTimestamp string `json:"feedTimestamp,omitempty"` // FeedType: Required. Type feed to be ingested into condor @@ -3179,6 +3285,7 @@ type StorageDatabasecenterPartnerapiV1mainDatabaseResourceFeed struct { // "SECURITY_FINDING_DATA" - Database resource security health signal data // "RECOMMENDATION_SIGNAL_DATA" - Database resource recommendation signal // data + // "CONFIG_BASED_SIGNAL_DATA" - Database config based signal data FeedType string `json:"feedType,omitempty"` ObservabilityMetricData *StorageDatabasecenterPartnerapiV1mainObservabilityMetricData `json:"observabilityMetricData,omitempty"` RecommendationSignalData *StorageDatabasecenterPartnerapiV1mainDatabaseResourceRecommendationSignalData `json:"recommendationSignalData,omitempty"` @@ -3187,15 +3294,15 @@ type StorageDatabasecenterPartnerapiV1mainDatabaseResourceFeed struct { // available in individual feed level as well. ResourceId *StorageDatabasecenterPartnerapiV1mainDatabaseResourceId `json:"resourceId,omitempty"` ResourceMetadata *StorageDatabasecenterPartnerapiV1mainDatabaseResourceMetadata `json:"resourceMetadata,omitempty"` - // ForceSendFields is a list of field names (e.g. "FeedTimestamp") to + // ForceSendFields is a list of field names (e.g. "ConfigBasedSignalData") 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. "FeedTimestamp") 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. "ConfigBasedSignalData") 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:"-"` } @@ -3510,6 +3617,11 @@ type StorageDatabasecenterPartnerapiV1mainDatabaseResourceHealthSignalData struc // not satisfied. // "SIGNAL_TYPE_LOCATION_ORG_POLICY_NOT_SATISFIED" - Location org policy not // satisfied. + // "SIGNAL_TYPE_OUTDATED_MINOR_VERSION" - Outdated DB minor version. + // "SIGNAL_TYPE_SCHEMA_NOT_OPTIMIZED" - Schema not optimized. + // "SIGNAL_TYPE_MANY_IDLE_CONNECTIONS" - High number of idle connections. + // "SIGNAL_TYPE_REPLICATION_LAG" - Replication delay. + // "SIGNAL_TYPE_OUTDATED_VERSION" - Outdated version. SignalType string `json:"signalType,omitempty"` // Possible values: // "STATE_UNSPECIFIED" - Unspecified state. @@ -3594,7 +3706,7 @@ func (s StorageDatabasecenterPartnerapiV1mainDatabaseResourceId) MarshalJSON() ( } // StorageDatabasecenterPartnerapiV1mainDatabaseResourceMetadata: Common model -// for database resource instance metadata. Next ID: 25 +// for database resource instance metadata. Next ID: 26 type StorageDatabasecenterPartnerapiV1mainDatabaseResourceMetadata struct { // AvailabilityConfiguration: Availability configuration for this instance AvailabilityConfiguration *StorageDatabasecenterPartnerapiV1mainAvailabilityConfiguration `json:"availabilityConfiguration,omitempty"` @@ -3602,6 +3714,8 @@ type StorageDatabasecenterPartnerapiV1mainDatabaseResourceMetadata struct { BackupConfiguration *StorageDatabasecenterPartnerapiV1mainBackupConfiguration `json:"backupConfiguration,omitempty"` // BackupRun: Latest backup run information for this instance BackupRun *StorageDatabasecenterPartnerapiV1mainBackupRun `json:"backupRun,omitempty"` + // BackupdrConfiguration: Optional. BackupDR Configuration for the resource. + BackupdrConfiguration *StorageDatabasecenterPartnerapiV1mainBackupDRConfiguration `json:"backupdrConfiguration,omitempty"` // CreationTime: The creation time of the resource, i.e. the time when resource // is created and recorded in partner service. CreationTime string `json:"creationTime,omitempty"` @@ -3994,6 +4108,11 @@ type StorageDatabasecenterPartnerapiV1mainDatabaseResourceRecommendationSignalDa // not satisfied. // "SIGNAL_TYPE_LOCATION_ORG_POLICY_NOT_SATISFIED" - Location org policy not // satisfied. + // "SIGNAL_TYPE_OUTDATED_MINOR_VERSION" - Outdated DB minor version. + // "SIGNAL_TYPE_SCHEMA_NOT_OPTIMIZED" - Schema not optimized. + // "SIGNAL_TYPE_MANY_IDLE_CONNECTIONS" - High number of idle connections. + // "SIGNAL_TYPE_REPLICATION_LAG" - Replication delay. + // "SIGNAL_TYPE_OUTDATED_VERSION" - Outdated version. SignalType string `json:"signalType,omitempty"` // ForceSendFields is a list of field names (e.g. "AdditionalMetadata") to // unconditionally include in API requests. By default, fields with empty or @@ -4371,9 +4490,15 @@ type StorageDatabasecenterProtoCommonProduct struct { // be when engine is known, but it is not present in this enum. // "ENGINE_FIRESTORE_WITH_NATIVE_MODE" - Firestore with native mode. // "ENGINE_FIRESTORE_WITH_DATASTORE_MODE" - Firestore with datastore mode. + // "ENGINE_FIRESTORE_WITH_MONGODB_COMPATIBILITY_MODE" - Firestore with + // MongoDB compatibility mode. // "ENGINE_EXADATA_ORACLE" - Oracle Exadata engine. // "ENGINE_ADB_SERVERLESS_ORACLE" - Oracle Autonomous DB Serverless engine. Engine string `json:"engine,omitempty"` + // MinorVersion: Minor version of the underlying database engine. Example + // values: For MySQL, it could be "8.0.32", "5.7.32" etc.. For Postgres, it + // could be "14.3", "15.3" etc.. + MinorVersion string `json:"minorVersion,omitempty"` // Type: Type of specific database product. It could be CloudSQL, AlloyDB etc.. // // Possible values: diff --git a/datacatalog/v1/datacatalog-api.json b/datacatalog/v1/datacatalog-api.json index 60e37742a82..98c1509df9d 100644 --- a/datacatalog/v1/datacatalog-api.json +++ b/datacatalog/v1/datacatalog-api.json @@ -2339,7 +2339,7 @@ } } }, - "revision": "20250609", + "revision": "20250720", "rootUrl": "https://datacatalog.googleapis.com/", "schemas": { "Binding": { @@ -3861,7 +3861,6 @@ "id": "GoogleCloudDatacatalogV1ReconcileTagsRequest", "properties": { "forceDeleteMissing": { - "description": "If set to `true`, deletes entry tags related to a tag template not listed in the tags source from an entry. If set to `false`, unlisted tags are retained.", "type": "boolean" }, "tagTemplate": { diff --git a/datacatalog/v1/datacatalog-gen.go b/datacatalog/v1/datacatalog-gen.go index 17076d24d67..c671842f328 100644 --- a/datacatalog/v1/datacatalog-gen.go +++ b/datacatalog/v1/datacatalog-gen.go @@ -2548,9 +2548,6 @@ func (s GoogleCloudDatacatalogV1ReconcileTagsMetadata) MarshalJSON() ([]byte, er // GoogleCloudDatacatalogV1ReconcileTagsRequest: Request message for // ReconcileTags. type GoogleCloudDatacatalogV1ReconcileTagsRequest struct { - // ForceDeleteMissing: If set to `true`, deletes entry tags related to a tag - // template not listed in the tags source from an entry. If set to `false`, - // unlisted tags are retained. ForceDeleteMissing bool `json:"forceDeleteMissing,omitempty"` // TagTemplate: Required. The name of the tag template, which is used for // reconciliation. diff --git a/drive/v3/drive-api.json b/drive/v3/drive-api.json index 248865703d8..95bc8c8db3a 100644 --- a/drive/v3/drive-api.json +++ b/drive/v3/drive-api.json @@ -1816,54 +1816,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": "operations/{name}:cancel", - "httpMethod": "POST", - "id": "drive.operations.cancel", - "parameterOrder": [ - "name" - ], - "parameters": { - "name": { - "description": "The name of the operation resource to be cancelled.", - "location": "path", - "required": true, - "type": "string" - } - }, - "path": "operations/{name}:cancel", - "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" - ] - }, - "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": "operations/{name}", - "httpMethod": "DELETE", - "id": "drive.operations.delete", - "parameterOrder": [ - "name" - ], - "parameters": { - "name": { - "description": "The name of the operation resource to be deleted.", - "location": "path", - "required": true, - "type": "string" - } - }, - "path": "operations/{name}", - "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" - ] - }, "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}", @@ -1890,46 +1842,6 @@ "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" - }, - "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" - ] } } }, @@ -2806,7 +2718,7 @@ } } }, - "revision": "20250717", + "revision": "20250723", "rootUrl": "https://www.googleapis.com/", "schemas": { "About": { @@ -4620,24 +4532,6 @@ }, "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", diff --git a/drive/v3/drive-gen.go b/drive/v3/drive-gen.go index 5b40a317e38..cab23fb2935 100644 --- a/drive/v3/drive-gen.go +++ b/drive/v3/drive-gen.go @@ -2344,34 +2344,6 @@ func (s ListAccessProposalsResponse) 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. @@ -7977,163 +7949,6 @@ func (c *FilesWatchCall) Do(opts ...googleapi.CallOption) (*Channel, error) { return ret, nil } -type OperationsCancelCall 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 *OperationsService) Cancel(name string) *OperationsCancelCall { - c := &OperationsCancelCall{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 *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(), "", c.header_) - c.urlParams_.Set("alt", alt) - c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "operations/{name}:cancel") - urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("POST", urls, nil) - if err != nil { - return nil, err - } - req.Header = reqHeaders - googleapi.Expand(req.URL, map[string]string{ - "name": c.name, - }) - c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "drive.operations.cancel", "request", internallog.HTTPRequest(req, nil)) - return gensupport.SendRequest(c.ctx_, c.s.client, req) -} - -// Do executes the "drive.operations.cancel" call. -func (c *OperationsCancelCall) 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) - } - c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "drive.operations.cancel", "response", internallog.HTTPResponse(res, nil)) - return 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_) - 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("DELETE", urls, nil) - if err != nil { - return nil, err - } - req.Header = reqHeaders - googleapi.Expand(req.URL, map[string]string{ - "name": c.name, - }) - c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "drive.operations.delete", "request", internallog.HTTPRequest(req, nil)) - return gensupport.SendRequest(c.ctx_, c.s.client, req) -} - -// Do executes the "drive.operations.delete" call. -func (c *OperationsDeleteCall) 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) - } - c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "drive.operations.delete", "response", internallog.HTTPResponse(res, nil)) - return nil -} - type OperationsGetCall struct { s *Service name string @@ -8245,158 +8060,6 @@ func (c *OperationsGetCall) Do(opts ...googleapi.CallOption) (*Operation, error) 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_) - } - 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, nil) - if err != nil { - return nil, err - } - req.Header = reqHeaders - c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "drive.operations.list", "request", internallog.HTTPRequest(req, nil)) - 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 - b, err := gensupport.DecodeResponseBytes(target, res) - if err != nil { - return nil, err - } - c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "drive.operations.list", "response", internallog.HTTPResponse(res, b)) - 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/gkehub/v1alpha/gkehub-api.json b/gkehub/v1alpha/gkehub-api.json index cacada6530d..9367a186710 100644 --- a/gkehub/v1alpha/gkehub-api.json +++ b/gkehub/v1alpha/gkehub-api.json @@ -2261,7 +2261,7 @@ } } }, - "revision": "20250715", + "revision": "20250720", "rootUrl": "https://gkehub.googleapis.com/", "schemas": { "AppDevExperienceFeatureSpec": { @@ -7004,7 +7004,8 @@ "ACTIVE", "STALLED", "NEEDS_ATTENTION", - "DEGRADED" + "DEGRADED", + "DEPROVISIONING" ], "enumDescriptions": [ "Unspecified", @@ -7014,7 +7015,8 @@ "ACTIVE means that the component is ready for use.", "STALLED means that provisioning could not be done.", "NEEDS_ATTENTION means that the component is ready, but some user intervention is required. (For example that the user should migrate workloads to a new control plane revision.)", - "DEGRADED means that the component is ready, but operating in a degraded state." + "DEGRADED means that the component is ready, but operating in a degraded state.", + "DEPROVISIONING means that deprovisioning is in progress." ], "type": "string" } @@ -7042,7 +7044,8 @@ "ACTIVE", "STALLED", "NEEDS_ATTENTION", - "DEGRADED" + "DEGRADED", + "DEPROVISIONING" ], "enumDescriptions": [ "Unspecified", @@ -7052,7 +7055,8 @@ "ACTIVE means that the component is ready for use.", "STALLED means that provisioning could not be done.", "NEEDS_ATTENTION means that the component is ready, but some user intervention is required. (For example that the user should migrate workloads to a new control plane revision.)", - "DEGRADED means that the component is ready, but operating in a degraded state." + "DEGRADED means that the component is ready, but operating in a degraded state.", + "DEPROVISIONING means that deprovisioning is in progress." ], "type": "string" } @@ -7260,12 +7264,14 @@ "enum": [ "MANAGEMENT_UNSPECIFIED", "MANAGEMENT_AUTOMATIC", - "MANAGEMENT_MANUAL" + "MANAGEMENT_MANUAL", + "MANAGEMENT_NOT_INSTALLED" ], "enumDescriptions": [ "Unspecified", "Google should manage my Service Mesh for the cluster.", - "User will manually configure their service mesh components." + "User will manually configure their service mesh components.", + "Google should remove any managed Service Mesh components from this cluster and deprovision any resources." ], "type": "string" } diff --git a/gkehub/v1alpha/gkehub-gen.go b/gkehub/v1alpha/gkehub-gen.go index 60ac04106bd..04ada050285 100644 --- a/gkehub/v1alpha/gkehub-gen.go +++ b/gkehub/v1alpha/gkehub-gen.go @@ -6174,6 +6174,8 @@ type ServiceMeshControlPlaneManagement struct { // migrate workloads to a new control plane revision.) // "DEGRADED" - DEGRADED means that the component is ready, but operating in // a degraded state. + // "DEPROVISIONING" - DEPROVISIONING means that deprovisioning is in + // progress. State string `json:"state,omitempty"` // ForceSendFields is a list of field names (e.g. "Details") to unconditionally // include in API requests. By default, fields with empty or default values are @@ -6213,6 +6215,8 @@ type ServiceMeshDataPlaneManagement struct { // migrate workloads to a new control plane revision.) // "DEGRADED" - DEGRADED means that the component is ready, but operating in // a degraded state. + // "DEPROVISIONING" - DEPROVISIONING means that deprovisioning is in + // progress. State string `json:"state,omitempty"` // ForceSendFields is a list of field names (e.g. "Details") to unconditionally // include in API requests. By default, fields with empty or default values are @@ -6399,6 +6403,8 @@ type ServiceMeshMembershipSpec struct { // cluster. // "MANAGEMENT_MANUAL" - User will manually configure their service mesh // components. + // "MANAGEMENT_NOT_INSTALLED" - Google should remove any managed Service Mesh + // components from this cluster and deprovision any resources. Management string `json:"management,omitempty"` // ForceSendFields is a list of field names (e.g. "ConfigApi") to // unconditionally include in API requests. By default, fields with empty or diff --git a/gkehub/v2beta/gkehub-api.json b/gkehub/v2beta/gkehub-api.json index d98b0f5cfb5..5ad25da4f76 100644 --- a/gkehub/v2beta/gkehub-api.json +++ b/gkehub/v2beta/gkehub-api.json @@ -477,7 +477,7 @@ } } }, - "revision": "20250715", + "revision": "20250720", "rootUrl": "https://gkehub.googleapis.com/", "schemas": { "AppDevExperienceState": { @@ -3178,7 +3178,8 @@ "ACTIVE", "STALLED", "NEEDS_ATTENTION", - "DEGRADED" + "DEGRADED", + "DEPROVISIONING" ], "enumDescriptions": [ "Unspecified", @@ -3188,7 +3189,8 @@ "ACTIVE means that the component is ready for use.", "STALLED means that provisioning could not be done.", "NEEDS_ATTENTION means that the component is ready, but some user intervention is required. (For example that the user should migrate workloads to a new control plane revision.)", - "DEGRADED means that the component is ready, but operating in a degraded state." + "DEGRADED means that the component is ready, but operating in a degraded state.", + "DEPROVISIONING means that deprovisioning is in progress." ], "type": "string" } @@ -3216,7 +3218,8 @@ "ACTIVE", "STALLED", "NEEDS_ATTENTION", - "DEGRADED" + "DEGRADED", + "DEPROVISIONING" ], "enumDescriptions": [ "Unspecified", @@ -3226,7 +3229,8 @@ "ACTIVE means that the component is ready for use.", "STALLED means that provisioning could not be done.", "NEEDS_ATTENTION means that the component is ready, but some user intervention is required. (For example that the user should migrate workloads to a new control plane revision.)", - "DEGRADED means that the component is ready, but operating in a degraded state." + "DEGRADED means that the component is ready, but operating in a degraded state.", + "DEPROVISIONING means that deprovisioning is in progress." ], "type": "string" } @@ -3288,12 +3292,14 @@ "enum": [ "MANAGEMENT_UNSPECIFIED", "MANAGEMENT_AUTOMATIC", - "MANAGEMENT_MANUAL" + "MANAGEMENT_MANUAL", + "MANAGEMENT_NOT_INSTALLED" ], "enumDescriptions": [ "Unspecified", "Google should manage my Service Mesh for the cluster.", - "User will manually configure their service mesh components." + "User will manually configure their service mesh components.", + "Google should remove any managed Service Mesh components from this cluster and deprovision any resources." ], "type": "string" } diff --git a/gkehub/v2beta/gkehub-gen.go b/gkehub/v2beta/gkehub-gen.go index 715d50657ad..b96d78ccecf 100644 --- a/gkehub/v2beta/gkehub-gen.go +++ b/gkehub/v2beta/gkehub-gen.go @@ -3304,6 +3304,8 @@ type ServiceMeshControlPlaneManagement struct { // migrate workloads to a new control plane revision.) // "DEGRADED" - DEGRADED means that the component is ready, but operating in // a degraded state. + // "DEPROVISIONING" - DEPROVISIONING means that deprovisioning is in + // progress. State string `json:"state,omitempty"` // ForceSendFields is a list of field names (e.g. "Details") to unconditionally // include in API requests. By default, fields with empty or default values are @@ -3343,6 +3345,8 @@ type ServiceMeshDataPlaneManagement struct { // migrate workloads to a new control plane revision.) // "DEGRADED" - DEGRADED means that the component is ready, but operating in // a degraded state. + // "DEPROVISIONING" - DEPROVISIONING means that deprovisioning is in + // progress. State string `json:"state,omitempty"` // ForceSendFields is a list of field names (e.g. "Details") to unconditionally // include in API requests. By default, fields with empty or default values are @@ -3405,6 +3409,8 @@ type ServiceMeshSpec struct { // cluster. // "MANAGEMENT_MANUAL" - User will manually configure their service mesh // components. + // "MANAGEMENT_NOT_INSTALLED" - Google should remove any managed Service Mesh + // components from this cluster and deprovision any resources. Management string `json:"management,omitempty"` // ForceSendFields is a list of field names (e.g. "ConfigApi") to // unconditionally include in API requests. By default, fields with empty or diff --git a/looker/v1/looker-api.json b/looker/v1/looker-api.json index 9b3ccbd9cca..43b783dbfc3 100644 --- a/looker/v1/looker-api.json +++ b/looker/v1/looker-api.json @@ -710,7 +710,7 @@ } } }, - "revision": "20250615", + "revision": "20250721", "rootUrl": "https://looker.googleapis.com/", "schemas": { "AdminSettings": { @@ -952,6 +952,20 @@ "$ref": "AdminSettings", "description": "Looker Instance Admin settings." }, + "classType": { + "description": "Optional. Storage class of the instance.", + "enum": [ + "CLASS_TYPE_UNSPECIFIED", + "R1", + "P1" + ], + "enumDescriptions": [ + "Unspecified storage class.", + "Filestore.", + "PD SSD." + ], + "type": "string" + }, "consumerNetwork": { "description": "Network name in the consumer project. Format: `projects/{project}/global/networks/{network}`. Note that the consumer network may be in a different GCP project than the consumer project that is hosting the Looker Instance.", "type": "string" diff --git a/looker/v1/looker-gen.go b/looker/v1/looker-gen.go index ad47abd3cdb..825c6f5bd8c 100644 --- a/looker/v1/looker-gen.go +++ b/looker/v1/looker-gen.go @@ -525,6 +525,13 @@ func (s ImportInstanceRequest) MarshalJSON() ([]byte, error) { type Instance struct { // AdminSettings: Looker Instance Admin settings. AdminSettings *AdminSettings `json:"adminSettings,omitempty"` + // ClassType: Optional. Storage class of the instance. + // + // Possible values: + // "CLASS_TYPE_UNSPECIFIED" - Unspecified storage class. + // "R1" - Filestore. + // "P1" - PD SSD. + ClassType string `json:"classType,omitempty"` // ConsumerNetwork: Network name in the consumer project. Format: // `projects/{project}/global/networks/{network}`. Note that the consumer // network may be in a different GCP project than the consumer project that is diff --git a/videointelligence/v1/videointelligence-api.json b/videointelligence/v1/videointelligence-api.json index e1cca72bb68..73e4d741be7 100644 --- a/videointelligence/v1/videointelligence-api.json +++ b/videointelligence/v1/videointelligence-api.json @@ -350,7 +350,7 @@ } } }, - "revision": "20250710", + "revision": "20250724", "rootUrl": "https://videointelligence.googleapis.com/", "schemas": { "GoogleCloudVideointelligenceV1_AnnotateVideoProgress": { @@ -475,7 +475,7 @@ }, "point": { "$ref": "GoogleCloudVideointelligenceV1_NormalizedVertex", - "description": "The 2D point of the detected landmark using the normalized image coordindate system. The normalized coordinates have the range from 0 to 1." + "description": "The 2D point of the detected landmark using the normalized image coordinate system. The normalized coordinates have the range from 0 to 1." } }, "type": "object" @@ -560,6 +560,33 @@ }, "type": "object" }, + "GoogleCloudVideointelligenceV1_ExportToOutputUriStatus": { + "description": "Status of exporting annotation response to user specified `output_uri`.", + "id": "GoogleCloudVideointelligenceV1_ExportToOutputUriStatus", + "properties": { + "state": { + "description": "Output only. State of the `output_uri` export.", + "enum": [ + "STATE_UNSPECIFIED", + "SUCCEEDED", + "FAILED" + ], + "enumDescriptions": [ + "Default value.", + "Export succeeded.", + "Export failed." + ], + "readOnly": true, + "type": "string" + }, + "status": { + "$ref": "GoogleRpc_Status", + "description": "Output only. Only set if state is FAILED.", + "readOnly": true + } + }, + "type": "object" + }, "GoogleCloudVideointelligenceV1_FaceAnnotation": { "deprecated": true, "description": "Deprecated. No effect.", @@ -823,7 +850,7 @@ "type": "object" }, "GoogleCloudVideointelligenceV1_NormalizedBoundingPoly": { - "description": "Normalized bounding polygon for text (that might not be aligned with axis). Contains list of the corner points in clockwise order starting from top-left corner. For example, for a rectangular bounding box: When the text is horizontal it might look like: 0----1 | | 3----2 When it's clockwise rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertex order will still be (0, 1, 2, 3). Note that values can be less than 0, or greater than 1 due to trignometric calculations for location of the box.", + "description": "Normalized bounding polygon for text (that might not be aligned with axis). Contains list of the corner points in clockwise order starting from top-left corner. For example, for a rectangular bounding box: When the text is horizontal it might look like: 0----1 | | 3----2 When it's clockwise rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertex order will still be (0, 1, 2, 3). Note that values can be less than 0, or greater than 1 due to trigonometric calculations for location of the box.", "id": "GoogleCloudVideointelligenceV1_NormalizedBoundingPoly", "properties": { "vertices": { @@ -1217,6 +1244,10 @@ "description": "Annotation progress for a single video.", "id": "GoogleCloudVideointelligenceV1_VideoAnnotationProgress", "properties": { + "exportStatus": { + "$ref": "GoogleCloudVideointelligenceV1_ExportToOutputUriStatus", + "description": "Status of exporting annotation response to user specified `output_uri`. Only set if `output_uri` is set in the request." + }, "feature": { "description": "Specifies which feature is being tracked if the request contains more than one feature.", "enum": [ @@ -1545,7 +1576,7 @@ }, "point": { "$ref": "GoogleCloudVideointelligenceV1beta2_NormalizedVertex", - "description": "The 2D point of the detected landmark using the normalized image coordindate system. The normalized coordinates have the range from 0 to 1." + "description": "The 2D point of the detected landmark using the normalized image coordinate system. The normalized coordinates have the range from 0 to 1." } }, "type": "object" @@ -1619,6 +1650,33 @@ }, "type": "object" }, + "GoogleCloudVideointelligenceV1beta2_ExportToOutputUriStatus": { + "description": "Status of exporting annotation response to user specified `output_uri`.", + "id": "GoogleCloudVideointelligenceV1beta2_ExportToOutputUriStatus", + "properties": { + "state": { + "description": "Output only. State of the `output_uri` export.", + "enum": [ + "STATE_UNSPECIFIED", + "SUCCEEDED", + "FAILED" + ], + "enumDescriptions": [ + "Default value.", + "Export succeeded.", + "Export failed." + ], + "readOnly": true, + "type": "string" + }, + "status": { + "$ref": "GoogleRpc_Status", + "description": "Output only. Only set if state is FAILED.", + "readOnly": true + } + }, + "type": "object" + }, "GoogleCloudVideointelligenceV1beta2_FaceAnnotation": { "deprecated": true, "description": "Deprecated. No effect.", @@ -1822,7 +1880,7 @@ "type": "object" }, "GoogleCloudVideointelligenceV1beta2_NormalizedBoundingPoly": { - "description": "Normalized bounding polygon for text (that might not be aligned with axis). Contains list of the corner points in clockwise order starting from top-left corner. For example, for a rectangular bounding box: When the text is horizontal it might look like: 0----1 | | 3----2 When it's clockwise rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertex order will still be (0, 1, 2, 3). Note that values can be less than 0, or greater than 1 due to trignometric calculations for location of the box.", + "description": "Normalized bounding polygon for text (that might not be aligned with axis). Contains list of the corner points in clockwise order starting from top-left corner. For example, for a rectangular bounding box: When the text is horizontal it might look like: 0----1 | | 3----2 When it's clockwise rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertex order will still be (0, 1, 2, 3). Note that values can be less than 0, or greater than 1 due to trigonometric calculations for location of the box.", "id": "GoogleCloudVideointelligenceV1beta2_NormalizedBoundingPoly", "properties": { "vertices": { @@ -2091,6 +2149,10 @@ "description": "Annotation progress for a single video.", "id": "GoogleCloudVideointelligenceV1beta2_VideoAnnotationProgress", "properties": { + "exportStatus": { + "$ref": "GoogleCloudVideointelligenceV1beta2_ExportToOutputUriStatus", + "description": "Status of exporting annotation response to user specified `output_uri`. Only set if `output_uri` is set in the request." + }, "feature": { "description": "Specifies which feature is being tracked if the request contains more than one feature.", "enum": [ @@ -2373,7 +2435,7 @@ }, "point": { "$ref": "GoogleCloudVideointelligenceV1p1beta1_NormalizedVertex", - "description": "The 2D point of the detected landmark using the normalized image coordindate system. The normalized coordinates have the range from 0 to 1." + "description": "The 2D point of the detected landmark using the normalized image coordinate system. The normalized coordinates have the range from 0 to 1." } }, "type": "object" @@ -2447,6 +2509,33 @@ }, "type": "object" }, + "GoogleCloudVideointelligenceV1p1beta1_ExportToOutputUriStatus": { + "description": "Status of exporting annotation response to user specified `output_uri`.", + "id": "GoogleCloudVideointelligenceV1p1beta1_ExportToOutputUriStatus", + "properties": { + "state": { + "description": "Output only. State of the `output_uri` export.", + "enum": [ + "STATE_UNSPECIFIED", + "SUCCEEDED", + "FAILED" + ], + "enumDescriptions": [ + "Default value.", + "Export succeeded.", + "Export failed." + ], + "readOnly": true, + "type": "string" + }, + "status": { + "$ref": "GoogleRpc_Status", + "description": "Output only. Only set if state is FAILED.", + "readOnly": true + } + }, + "type": "object" + }, "GoogleCloudVideointelligenceV1p1beta1_FaceAnnotation": { "deprecated": true, "description": "Deprecated. No effect.", @@ -2650,7 +2739,7 @@ "type": "object" }, "GoogleCloudVideointelligenceV1p1beta1_NormalizedBoundingPoly": { - "description": "Normalized bounding polygon for text (that might not be aligned with axis). Contains list of the corner points in clockwise order starting from top-left corner. For example, for a rectangular bounding box: When the text is horizontal it might look like: 0----1 | | 3----2 When it's clockwise rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertex order will still be (0, 1, 2, 3). Note that values can be less than 0, or greater than 1 due to trignometric calculations for location of the box.", + "description": "Normalized bounding polygon for text (that might not be aligned with axis). Contains list of the corner points in clockwise order starting from top-left corner. For example, for a rectangular bounding box: When the text is horizontal it might look like: 0----1 | | 3----2 When it's clockwise rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertex order will still be (0, 1, 2, 3). Note that values can be less than 0, or greater than 1 due to trigonometric calculations for location of the box.", "id": "GoogleCloudVideointelligenceV1p1beta1_NormalizedBoundingPoly", "properties": { "vertices": { @@ -2919,6 +3008,10 @@ "description": "Annotation progress for a single video.", "id": "GoogleCloudVideointelligenceV1p1beta1_VideoAnnotationProgress", "properties": { + "exportStatus": { + "$ref": "GoogleCloudVideointelligenceV1p1beta1_ExportToOutputUriStatus", + "description": "Status of exporting annotation response to user specified `output_uri`. Only set if `output_uri` is set in the request." + }, "feature": { "description": "Specifies which feature is being tracked if the request contains more than one feature.", "enum": [ @@ -3201,7 +3294,7 @@ }, "point": { "$ref": "GoogleCloudVideointelligenceV1p2beta1_NormalizedVertex", - "description": "The 2D point of the detected landmark using the normalized image coordindate system. The normalized coordinates have the range from 0 to 1." + "description": "The 2D point of the detected landmark using the normalized image coordinate system. The normalized coordinates have the range from 0 to 1." } }, "type": "object" @@ -3275,6 +3368,33 @@ }, "type": "object" }, + "GoogleCloudVideointelligenceV1p2beta1_ExportToOutputUriStatus": { + "description": "Status of exporting annotation response to user specified `output_uri`.", + "id": "GoogleCloudVideointelligenceV1p2beta1_ExportToOutputUriStatus", + "properties": { + "state": { + "description": "Output only. State of the `output_uri` export.", + "enum": [ + "STATE_UNSPECIFIED", + "SUCCEEDED", + "FAILED" + ], + "enumDescriptions": [ + "Default value.", + "Export succeeded.", + "Export failed." + ], + "readOnly": true, + "type": "string" + }, + "status": { + "$ref": "GoogleRpc_Status", + "description": "Output only. Only set if state is FAILED.", + "readOnly": true + } + }, + "type": "object" + }, "GoogleCloudVideointelligenceV1p2beta1_FaceAnnotation": { "deprecated": true, "description": "Deprecated. No effect.", @@ -3478,7 +3598,7 @@ "type": "object" }, "GoogleCloudVideointelligenceV1p2beta1_NormalizedBoundingPoly": { - "description": "Normalized bounding polygon for text (that might not be aligned with axis). Contains list of the corner points in clockwise order starting from top-left corner. For example, for a rectangular bounding box: When the text is horizontal it might look like: 0----1 | | 3----2 When it's clockwise rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertex order will still be (0, 1, 2, 3). Note that values can be less than 0, or greater than 1 due to trignometric calculations for location of the box.", + "description": "Normalized bounding polygon for text (that might not be aligned with axis). Contains list of the corner points in clockwise order starting from top-left corner. For example, for a rectangular bounding box: When the text is horizontal it might look like: 0----1 | | 3----2 When it's clockwise rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertex order will still be (0, 1, 2, 3). Note that values can be less than 0, or greater than 1 due to trigonometric calculations for location of the box.", "id": "GoogleCloudVideointelligenceV1p2beta1_NormalizedBoundingPoly", "properties": { "vertices": { @@ -3747,6 +3867,10 @@ "description": "Annotation progress for a single video.", "id": "GoogleCloudVideointelligenceV1p2beta1_VideoAnnotationProgress", "properties": { + "exportStatus": { + "$ref": "GoogleCloudVideointelligenceV1p2beta1_ExportToOutputUriStatus", + "description": "Status of exporting annotation response to user specified `output_uri`. Only set if `output_uri` is set in the request." + }, "feature": { "description": "Specifies which feature is being tracked if the request contains more than one feature.", "enum": [ @@ -4084,7 +4208,7 @@ }, "point": { "$ref": "GoogleCloudVideointelligenceV1p3beta1_NormalizedVertex", - "description": "The 2D point of the detected landmark using the normalized image coordindate system. The normalized coordinates have the range from 0 to 1." + "description": "The 2D point of the detected landmark using the normalized image coordinate system. The normalized coordinates have the range from 0 to 1." } }, "type": "object" @@ -4158,6 +4282,33 @@ }, "type": "object" }, + "GoogleCloudVideointelligenceV1p3beta1_ExportToOutputUriStatus": { + "description": "Status of exporting annotation response to user specified `output_uri`.", + "id": "GoogleCloudVideointelligenceV1p3beta1_ExportToOutputUriStatus", + "properties": { + "state": { + "description": "Output only. State of the `output_uri` export.", + "enum": [ + "STATE_UNSPECIFIED", + "SUCCEEDED", + "FAILED" + ], + "enumDescriptions": [ + "Default value.", + "Export succeeded.", + "Export failed." + ], + "readOnly": true, + "type": "string" + }, + "status": { + "$ref": "GoogleRpc_Status", + "description": "Output only. Only set if state is FAILED.", + "readOnly": true + } + }, + "type": "object" + }, "GoogleCloudVideointelligenceV1p3beta1_FaceAnnotation": { "deprecated": true, "description": "Deprecated. No effect.", @@ -4361,7 +4512,7 @@ "type": "object" }, "GoogleCloudVideointelligenceV1p3beta1_NormalizedBoundingPoly": { - "description": "Normalized bounding polygon for text (that might not be aligned with axis). Contains list of the corner points in clockwise order starting from top-left corner. For example, for a rectangular bounding box: When the text is horizontal it might look like: 0----1 | | 3----2 When it's clockwise rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertex order will still be (0, 1, 2, 3). Note that values can be less than 0, or greater than 1 due to trignometric calculations for location of the box.", + "description": "Normalized bounding polygon for text (that might not be aligned with axis). Contains list of the corner points in clockwise order starting from top-left corner. For example, for a rectangular bounding box: When the text is horizontal it might look like: 0----1 | | 3----2 When it's clockwise rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertex order will still be (0, 1, 2, 3). Note that values can be less than 0, or greater than 1 due to trigonometric calculations for location of the box.", "id": "GoogleCloudVideointelligenceV1p3beta1_NormalizedBoundingPoly", "properties": { "vertices": { @@ -4702,6 +4853,10 @@ "description": "Annotation progress for a single video.", "id": "GoogleCloudVideointelligenceV1p3beta1_VideoAnnotationProgress", "properties": { + "exportStatus": { + "$ref": "GoogleCloudVideointelligenceV1p3beta1_ExportToOutputUriStatus", + "description": "Status of exporting annotation response to user specified `output_uri`. Only set if `output_uri` is set in the request." + }, "feature": { "description": "Specifies which feature is being tracked if the request contains more than one feature.", "enum": [ diff --git a/videointelligence/v1/videointelligence-gen.go b/videointelligence/v1/videointelligence-gen.go index 7ba18e5e960..dbb5bca407a 100644 --- a/videointelligence/v1/videointelligence-gen.go +++ b/videointelligence/v1/videointelligence-gen.go @@ -414,7 +414,7 @@ type GoogleCloudVideointelligenceV1DetectedLandmark struct { // Name: The name of this landmark, for example, left_hand, right_shoulder. Name string `json:"name,omitempty"` // Point: The 2D point of the detected landmark using the normalized image - // coordindate system. The normalized coordinates have the range from 0 to 1. + // coordinate system. The normalized coordinates have the range from 0 to 1. Point *GoogleCloudVideointelligenceV1NormalizedVertex `json:"point,omitempty"` // ForceSendFields is a list of field names (e.g. "Confidence") to // unconditionally include in API requests. By default, fields with empty or @@ -559,6 +559,36 @@ func (s GoogleCloudVideointelligenceV1ExplicitContentFrame) MarshalJSON() ([]byt return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudVideointelligenceV1ExportToOutputUriStatus: Status of exporting +// annotation response to user specified `output_uri`. +type GoogleCloudVideointelligenceV1ExportToOutputUriStatus struct { + // State: Output only. State of the `output_uri` export. + // + // Possible values: + // "STATE_UNSPECIFIED" - Default value. + // "SUCCEEDED" - Export succeeded. + // "FAILED" - Export failed. + State string `json:"state,omitempty"` + // Status: Output only. Only set if state is FAILED. + Status *GoogleRpcStatus `json:"status,omitempty"` + // ForceSendFields is a list of field names (e.g. "State") 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. "State") 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 GoogleCloudVideointelligenceV1ExportToOutputUriStatus) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudVideointelligenceV1ExportToOutputUriStatus + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudVideointelligenceV1FaceAnnotation: Deprecated. No effect. type GoogleCloudVideointelligenceV1FaceAnnotation struct { // Frames: All video frames where a face was detected. @@ -960,7 +990,7 @@ func (s *GoogleCloudVideointelligenceV1NormalizedBoundingBox) UnmarshalJSON(data // like: 0----1 | | 3----2 When it's clockwise rotated 180 degrees around the // top-left corner it becomes: 2----3 | | 1----0 and the vertex order will // still be (0, 1, 2, 3). Note that values can be less than 0, or greater than -// 1 due to trignometric calculations for location of the box. +// 1 due to trigonometric calculations for location of the box. type GoogleCloudVideointelligenceV1NormalizedBoundingPoly struct { // Vertices: Normalized vertices of the bounding polygon. Vertices []*GoogleCloudVideointelligenceV1NormalizedVertex `json:"vertices,omitempty"` @@ -1590,6 +1620,9 @@ func (s *GoogleCloudVideointelligenceV1Track) UnmarshalJSON(data []byte) error { // GoogleCloudVideointelligenceV1VideoAnnotationProgress: Annotation progress // for a single video. type GoogleCloudVideointelligenceV1VideoAnnotationProgress struct { + // ExportStatus: Status of exporting annotation response to user specified + // `output_uri`. Only set if `output_uri` is set in the request. + ExportStatus *GoogleCloudVideointelligenceV1ExportToOutputUriStatus `json:"exportStatus,omitempty"` // Feature: Specifies which feature is being tracked if the request contains // more than one feature. // @@ -1619,13 +1652,13 @@ type GoogleCloudVideointelligenceV1VideoAnnotationProgress struct { StartTime string `json:"startTime,omitempty"` // UpdateTime: Time of the most recent update. UpdateTime string `json:"updateTime,omitempty"` - // ForceSendFields is a list of field names (e.g. "Feature") 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. "ExportStatus") 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. "Feature") to include in API + // NullFields is a list of field names (e.g. "ExportStatus") 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. @@ -1945,7 +1978,7 @@ type GoogleCloudVideointelligenceV1beta2DetectedLandmark struct { // Name: The name of this landmark, for example, left_hand, right_shoulder. Name string `json:"name,omitempty"` // Point: The 2D point of the detected landmark using the normalized image - // coordindate system. The normalized coordinates have the range from 0 to 1. + // coordinate system. The normalized coordinates have the range from 0 to 1. Point *GoogleCloudVideointelligenceV1beta2NormalizedVertex `json:"point,omitempty"` // ForceSendFields is a list of field names (e.g. "Confidence") to // unconditionally include in API requests. By default, fields with empty or @@ -2068,6 +2101,36 @@ func (s GoogleCloudVideointelligenceV1beta2ExplicitContentFrame) MarshalJSON() ( return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudVideointelligenceV1beta2ExportToOutputUriStatus: Status of +// exporting annotation response to user specified `output_uri`. +type GoogleCloudVideointelligenceV1beta2ExportToOutputUriStatus struct { + // State: Output only. State of the `output_uri` export. + // + // Possible values: + // "STATE_UNSPECIFIED" - Default value. + // "SUCCEEDED" - Export succeeded. + // "FAILED" - Export failed. + State string `json:"state,omitempty"` + // Status: Output only. Only set if state is FAILED. + Status *GoogleRpcStatus `json:"status,omitempty"` + // ForceSendFields is a list of field names (e.g. "State") 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. "State") 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 GoogleCloudVideointelligenceV1beta2ExportToOutputUriStatus) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudVideointelligenceV1beta2ExportToOutputUriStatus + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudVideointelligenceV1beta2FaceAnnotation: Deprecated. No effect. type GoogleCloudVideointelligenceV1beta2FaceAnnotation struct { // Frames: All video frames where a face was detected. @@ -2370,7 +2433,7 @@ func (s *GoogleCloudVideointelligenceV1beta2NormalizedBoundingBox) UnmarshalJSON // might look like: 0----1 | | 3----2 When it's clockwise rotated 180 degrees // around the top-left corner it becomes: 2----3 | | 1----0 and the vertex // order will still be (0, 1, 2, 3). Note that values can be less than 0, or -// greater than 1 due to trignometric calculations for location of the box. +// greater than 1 due to trigonometric calculations for location of the box. type GoogleCloudVideointelligenceV1beta2NormalizedBoundingPoly struct { // Vertices: Normalized vertices of the bounding polygon. Vertices []*GoogleCloudVideointelligenceV1beta2NormalizedVertex `json:"vertices,omitempty"` @@ -2795,6 +2858,9 @@ func (s *GoogleCloudVideointelligenceV1beta2Track) UnmarshalJSON(data []byte) er // GoogleCloudVideointelligenceV1beta2VideoAnnotationProgress: Annotation // progress for a single video. type GoogleCloudVideointelligenceV1beta2VideoAnnotationProgress struct { + // ExportStatus: Status of exporting annotation response to user specified + // `output_uri`. Only set if `output_uri` is set in the request. + ExportStatus *GoogleCloudVideointelligenceV1beta2ExportToOutputUriStatus `json:"exportStatus,omitempty"` // Feature: Specifies which feature is being tracked if the request contains // more than one feature. // @@ -2824,13 +2890,13 @@ type GoogleCloudVideointelligenceV1beta2VideoAnnotationProgress struct { StartTime string `json:"startTime,omitempty"` // UpdateTime: Time of the most recent update. UpdateTime string `json:"updateTime,omitempty"` - // ForceSendFields is a list of field names (e.g. "Feature") 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. "ExportStatus") 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. "Feature") to include in API + // NullFields is a list of field names (e.g. "ExportStatus") 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. @@ -3108,7 +3174,7 @@ type GoogleCloudVideointelligenceV1p1beta1DetectedLandmark struct { // Name: The name of this landmark, for example, left_hand, right_shoulder. Name string `json:"name,omitempty"` // Point: The 2D point of the detected landmark using the normalized image - // coordindate system. The normalized coordinates have the range from 0 to 1. + // coordinate system. The normalized coordinates have the range from 0 to 1. Point *GoogleCloudVideointelligenceV1p1beta1NormalizedVertex `json:"point,omitempty"` // ForceSendFields is a list of field names (e.g. "Confidence") to // unconditionally include in API requests. By default, fields with empty or @@ -3231,6 +3297,36 @@ func (s GoogleCloudVideointelligenceV1p1beta1ExplicitContentFrame) MarshalJSON() return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudVideointelligenceV1p1beta1ExportToOutputUriStatus: Status of +// exporting annotation response to user specified `output_uri`. +type GoogleCloudVideointelligenceV1p1beta1ExportToOutputUriStatus struct { + // State: Output only. State of the `output_uri` export. + // + // Possible values: + // "STATE_UNSPECIFIED" - Default value. + // "SUCCEEDED" - Export succeeded. + // "FAILED" - Export failed. + State string `json:"state,omitempty"` + // Status: Output only. Only set if state is FAILED. + Status *GoogleRpcStatus `json:"status,omitempty"` + // ForceSendFields is a list of field names (e.g. "State") 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. "State") 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 GoogleCloudVideointelligenceV1p1beta1ExportToOutputUriStatus) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudVideointelligenceV1p1beta1ExportToOutputUriStatus + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudVideointelligenceV1p1beta1FaceAnnotation: Deprecated. No effect. type GoogleCloudVideointelligenceV1p1beta1FaceAnnotation struct { // Frames: All video frames where a face was detected. @@ -3533,7 +3629,7 @@ func (s *GoogleCloudVideointelligenceV1p1beta1NormalizedBoundingBox) UnmarshalJS // might look like: 0----1 | | 3----2 When it's clockwise rotated 180 degrees // around the top-left corner it becomes: 2----3 | | 1----0 and the vertex // order will still be (0, 1, 2, 3). Note that values can be less than 0, or -// greater than 1 due to trignometric calculations for location of the box. +// greater than 1 due to trigonometric calculations for location of the box. type GoogleCloudVideointelligenceV1p1beta1NormalizedBoundingPoly struct { // Vertices: Normalized vertices of the bounding polygon. Vertices []*GoogleCloudVideointelligenceV1p1beta1NormalizedVertex `json:"vertices,omitempty"` @@ -3958,6 +4054,9 @@ func (s *GoogleCloudVideointelligenceV1p1beta1Track) UnmarshalJSON(data []byte) // GoogleCloudVideointelligenceV1p1beta1VideoAnnotationProgress: Annotation // progress for a single video. type GoogleCloudVideointelligenceV1p1beta1VideoAnnotationProgress struct { + // ExportStatus: Status of exporting annotation response to user specified + // `output_uri`. Only set if `output_uri` is set in the request. + ExportStatus *GoogleCloudVideointelligenceV1p1beta1ExportToOutputUriStatus `json:"exportStatus,omitempty"` // Feature: Specifies which feature is being tracked if the request contains // more than one feature. // @@ -3987,13 +4086,13 @@ type GoogleCloudVideointelligenceV1p1beta1VideoAnnotationProgress struct { StartTime string `json:"startTime,omitempty"` // UpdateTime: Time of the most recent update. UpdateTime string `json:"updateTime,omitempty"` - // ForceSendFields is a list of field names (e.g. "Feature") 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. "ExportStatus") 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. "Feature") to include in API + // NullFields is a list of field names (e.g. "ExportStatus") 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. @@ -4271,7 +4370,7 @@ type GoogleCloudVideointelligenceV1p2beta1DetectedLandmark struct { // Name: The name of this landmark, for example, left_hand, right_shoulder. Name string `json:"name,omitempty"` // Point: The 2D point of the detected landmark using the normalized image - // coordindate system. The normalized coordinates have the range from 0 to 1. + // coordinate system. The normalized coordinates have the range from 0 to 1. Point *GoogleCloudVideointelligenceV1p2beta1NormalizedVertex `json:"point,omitempty"` // ForceSendFields is a list of field names (e.g. "Confidence") to // unconditionally include in API requests. By default, fields with empty or @@ -4394,6 +4493,36 @@ func (s GoogleCloudVideointelligenceV1p2beta1ExplicitContentFrame) MarshalJSON() return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudVideointelligenceV1p2beta1ExportToOutputUriStatus: Status of +// exporting annotation response to user specified `output_uri`. +type GoogleCloudVideointelligenceV1p2beta1ExportToOutputUriStatus struct { + // State: Output only. State of the `output_uri` export. + // + // Possible values: + // "STATE_UNSPECIFIED" - Default value. + // "SUCCEEDED" - Export succeeded. + // "FAILED" - Export failed. + State string `json:"state,omitempty"` + // Status: Output only. Only set if state is FAILED. + Status *GoogleRpcStatus `json:"status,omitempty"` + // ForceSendFields is a list of field names (e.g. "State") 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. "State") 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 GoogleCloudVideointelligenceV1p2beta1ExportToOutputUriStatus) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudVideointelligenceV1p2beta1ExportToOutputUriStatus + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudVideointelligenceV1p2beta1FaceAnnotation: Deprecated. No effect. type GoogleCloudVideointelligenceV1p2beta1FaceAnnotation struct { // Frames: All video frames where a face was detected. @@ -4696,7 +4825,7 @@ func (s *GoogleCloudVideointelligenceV1p2beta1NormalizedBoundingBox) UnmarshalJS // might look like: 0----1 | | 3----2 When it's clockwise rotated 180 degrees // around the top-left corner it becomes: 2----3 | | 1----0 and the vertex // order will still be (0, 1, 2, 3). Note that values can be less than 0, or -// greater than 1 due to trignometric calculations for location of the box. +// greater than 1 due to trigonometric calculations for location of the box. type GoogleCloudVideointelligenceV1p2beta1NormalizedBoundingPoly struct { // Vertices: Normalized vertices of the bounding polygon. Vertices []*GoogleCloudVideointelligenceV1p2beta1NormalizedVertex `json:"vertices,omitempty"` @@ -5121,6 +5250,9 @@ func (s *GoogleCloudVideointelligenceV1p2beta1Track) UnmarshalJSON(data []byte) // GoogleCloudVideointelligenceV1p2beta1VideoAnnotationProgress: Annotation // progress for a single video. type GoogleCloudVideointelligenceV1p2beta1VideoAnnotationProgress struct { + // ExportStatus: Status of exporting annotation response to user specified + // `output_uri`. Only set if `output_uri` is set in the request. + ExportStatus *GoogleCloudVideointelligenceV1p2beta1ExportToOutputUriStatus `json:"exportStatus,omitempty"` // Feature: Specifies which feature is being tracked if the request contains // more than one feature. // @@ -5150,13 +5282,13 @@ type GoogleCloudVideointelligenceV1p2beta1VideoAnnotationProgress struct { StartTime string `json:"startTime,omitempty"` // UpdateTime: Time of the most recent update. UpdateTime string `json:"updateTime,omitempty"` - // ForceSendFields is a list of field names (e.g. "Feature") 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. "ExportStatus") 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. "Feature") to include in API + // NullFields is a list of field names (e.g. "ExportStatus") 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. @@ -5516,7 +5648,7 @@ type GoogleCloudVideointelligenceV1p3beta1DetectedLandmark struct { // Name: The name of this landmark, for example, left_hand, right_shoulder. Name string `json:"name,omitempty"` // Point: The 2D point of the detected landmark using the normalized image - // coordindate system. The normalized coordinates have the range from 0 to 1. + // coordinate system. The normalized coordinates have the range from 0 to 1. Point *GoogleCloudVideointelligenceV1p3beta1NormalizedVertex `json:"point,omitempty"` // ForceSendFields is a list of field names (e.g. "Confidence") to // unconditionally include in API requests. By default, fields with empty or @@ -5639,6 +5771,36 @@ func (s GoogleCloudVideointelligenceV1p3beta1ExplicitContentFrame) MarshalJSON() return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudVideointelligenceV1p3beta1ExportToOutputUriStatus: Status of +// exporting annotation response to user specified `output_uri`. +type GoogleCloudVideointelligenceV1p3beta1ExportToOutputUriStatus struct { + // State: Output only. State of the `output_uri` export. + // + // Possible values: + // "STATE_UNSPECIFIED" - Default value. + // "SUCCEEDED" - Export succeeded. + // "FAILED" - Export failed. + State string `json:"state,omitempty"` + // Status: Output only. Only set if state is FAILED. + Status *GoogleRpcStatus `json:"status,omitempty"` + // ForceSendFields is a list of field names (e.g. "State") 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. "State") 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 GoogleCloudVideointelligenceV1p3beta1ExportToOutputUriStatus) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudVideointelligenceV1p3beta1ExportToOutputUriStatus + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudVideointelligenceV1p3beta1FaceAnnotation: Deprecated. No effect. type GoogleCloudVideointelligenceV1p3beta1FaceAnnotation struct { // Frames: All video frames where a face was detected. @@ -5941,7 +6103,7 @@ func (s *GoogleCloudVideointelligenceV1p3beta1NormalizedBoundingBox) UnmarshalJS // might look like: 0----1 | | 3----2 When it's clockwise rotated 180 degrees // around the top-left corner it becomes: 2----3 | | 1----0 and the vertex // order will still be (0, 1, 2, 3). Note that values can be less than 0, or -// greater than 1 due to trignometric calculations for location of the box. +// greater than 1 due to trigonometric calculations for location of the box. type GoogleCloudVideointelligenceV1p3beta1NormalizedBoundingPoly struct { // Vertices: Normalized vertices of the bounding polygon. Vertices []*GoogleCloudVideointelligenceV1p3beta1NormalizedVertex `json:"vertices,omitempty"` @@ -6472,6 +6634,9 @@ func (s *GoogleCloudVideointelligenceV1p3beta1Track) UnmarshalJSON(data []byte) // GoogleCloudVideointelligenceV1p3beta1VideoAnnotationProgress: Annotation // progress for a single video. type GoogleCloudVideointelligenceV1p3beta1VideoAnnotationProgress struct { + // ExportStatus: Status of exporting annotation response to user specified + // `output_uri`. Only set if `output_uri` is set in the request. + ExportStatus *GoogleCloudVideointelligenceV1p3beta1ExportToOutputUriStatus `json:"exportStatus,omitempty"` // Feature: Specifies which feature is being tracked if the request contains // more than one feature. // @@ -6502,13 +6667,13 @@ type GoogleCloudVideointelligenceV1p3beta1VideoAnnotationProgress struct { StartTime string `json:"startTime,omitempty"` // UpdateTime: Time of the most recent update. UpdateTime string `json:"updateTime,omitempty"` - // ForceSendFields is a list of field names (e.g. "Feature") 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. "ExportStatus") 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. "Feature") to include in API + // NullFields is a list of field names (e.g. "ExportStatus") 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/videointelligence/v1beta2/videointelligence-api.json b/videointelligence/v1beta2/videointelligence-api.json index f1222b3a9ba..d0929c05bce 100644 --- a/videointelligence/v1beta2/videointelligence-api.json +++ b/videointelligence/v1beta2/videointelligence-api.json @@ -128,7 +128,7 @@ } } }, - "revision": "20250710", + "revision": "20250724", "rootUrl": "https://videointelligence.googleapis.com/", "schemas": { "GoogleCloudVideointelligenceV1_AnnotateVideoProgress": { @@ -194,7 +194,7 @@ }, "point": { "$ref": "GoogleCloudVideointelligenceV1_NormalizedVertex", - "description": "The 2D point of the detected landmark using the normalized image coordindate system. The normalized coordinates have the range from 0 to 1." + "description": "The 2D point of the detected landmark using the normalized image coordinate system. The normalized coordinates have the range from 0 to 1." } }, "type": "object" @@ -268,6 +268,33 @@ }, "type": "object" }, + "GoogleCloudVideointelligenceV1_ExportToOutputUriStatus": { + "description": "Status of exporting annotation response to user specified `output_uri`.", + "id": "GoogleCloudVideointelligenceV1_ExportToOutputUriStatus", + "properties": { + "state": { + "description": "Output only. State of the `output_uri` export.", + "enum": [ + "STATE_UNSPECIFIED", + "SUCCEEDED", + "FAILED" + ], + "enumDescriptions": [ + "Default value.", + "Export succeeded.", + "Export failed." + ], + "readOnly": true, + "type": "string" + }, + "status": { + "$ref": "GoogleRpc_Status", + "description": "Output only. Only set if state is FAILED.", + "readOnly": true + } + }, + "type": "object" + }, "GoogleCloudVideointelligenceV1_FaceAnnotation": { "deprecated": true, "description": "Deprecated. No effect.", @@ -471,7 +498,7 @@ "type": "object" }, "GoogleCloudVideointelligenceV1_NormalizedBoundingPoly": { - "description": "Normalized bounding polygon for text (that might not be aligned with axis). Contains list of the corner points in clockwise order starting from top-left corner. For example, for a rectangular bounding box: When the text is horizontal it might look like: 0----1 | | 3----2 When it's clockwise rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertex order will still be (0, 1, 2, 3). Note that values can be less than 0, or greater than 1 due to trignometric calculations for location of the box.", + "description": "Normalized bounding polygon for text (that might not be aligned with axis). Contains list of the corner points in clockwise order starting from top-left corner. For example, for a rectangular bounding box: When the text is horizontal it might look like: 0----1 | | 3----2 When it's clockwise rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertex order will still be (0, 1, 2, 3). Note that values can be less than 0, or greater than 1 due to trigonometric calculations for location of the box.", "id": "GoogleCloudVideointelligenceV1_NormalizedBoundingPoly", "properties": { "vertices": { @@ -740,6 +767,10 @@ "description": "Annotation progress for a single video.", "id": "GoogleCloudVideointelligenceV1_VideoAnnotationProgress", "properties": { + "exportStatus": { + "$ref": "GoogleCloudVideointelligenceV1_ExportToOutputUriStatus", + "description": "Status of exporting annotation response to user specified `output_uri`. Only set if `output_uri` is set in the request." + }, "feature": { "description": "Specifies which feature is being tracked if the request contains more than one feature.", "enum": [ @@ -1081,7 +1112,7 @@ }, "point": { "$ref": "GoogleCloudVideointelligenceV1beta2_NormalizedVertex", - "description": "The 2D point of the detected landmark using the normalized image coordindate system. The normalized coordinates have the range from 0 to 1." + "description": "The 2D point of the detected landmark using the normalized image coordinate system. The normalized coordinates have the range from 0 to 1." } }, "type": "object" @@ -1166,6 +1197,33 @@ }, "type": "object" }, + "GoogleCloudVideointelligenceV1beta2_ExportToOutputUriStatus": { + "description": "Status of exporting annotation response to user specified `output_uri`.", + "id": "GoogleCloudVideointelligenceV1beta2_ExportToOutputUriStatus", + "properties": { + "state": { + "description": "Output only. State of the `output_uri` export.", + "enum": [ + "STATE_UNSPECIFIED", + "SUCCEEDED", + "FAILED" + ], + "enumDescriptions": [ + "Default value.", + "Export succeeded.", + "Export failed." + ], + "readOnly": true, + "type": "string" + }, + "status": { + "$ref": "GoogleRpc_Status", + "description": "Output only. Only set if state is FAILED.", + "readOnly": true + } + }, + "type": "object" + }, "GoogleCloudVideointelligenceV1beta2_FaceAnnotation": { "deprecated": true, "description": "Deprecated. No effect.", @@ -1429,7 +1487,7 @@ "type": "object" }, "GoogleCloudVideointelligenceV1beta2_NormalizedBoundingPoly": { - "description": "Normalized bounding polygon for text (that might not be aligned with axis). Contains list of the corner points in clockwise order starting from top-left corner. For example, for a rectangular bounding box: When the text is horizontal it might look like: 0----1 | | 3----2 When it's clockwise rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertex order will still be (0, 1, 2, 3). Note that values can be less than 0, or greater than 1 due to trignometric calculations for location of the box.", + "description": "Normalized bounding polygon for text (that might not be aligned with axis). Contains list of the corner points in clockwise order starting from top-left corner. For example, for a rectangular bounding box: When the text is horizontal it might look like: 0----1 | | 3----2 When it's clockwise rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertex order will still be (0, 1, 2, 3). Note that values can be less than 0, or greater than 1 due to trigonometric calculations for location of the box.", "id": "GoogleCloudVideointelligenceV1beta2_NormalizedBoundingPoly", "properties": { "vertices": { @@ -1823,6 +1881,10 @@ "description": "Annotation progress for a single video.", "id": "GoogleCloudVideointelligenceV1beta2_VideoAnnotationProgress", "properties": { + "exportStatus": { + "$ref": "GoogleCloudVideointelligenceV1beta2_ExportToOutputUriStatus", + "description": "Status of exporting annotation response to user specified `output_uri`. Only set if `output_uri` is set in the request." + }, "feature": { "description": "Specifies which feature is being tracked if the request contains more than one feature.", "enum": [ @@ -2151,7 +2213,7 @@ }, "point": { "$ref": "GoogleCloudVideointelligenceV1p1beta1_NormalizedVertex", - "description": "The 2D point of the detected landmark using the normalized image coordindate system. The normalized coordinates have the range from 0 to 1." + "description": "The 2D point of the detected landmark using the normalized image coordinate system. The normalized coordinates have the range from 0 to 1." } }, "type": "object" @@ -2225,6 +2287,33 @@ }, "type": "object" }, + "GoogleCloudVideointelligenceV1p1beta1_ExportToOutputUriStatus": { + "description": "Status of exporting annotation response to user specified `output_uri`.", + "id": "GoogleCloudVideointelligenceV1p1beta1_ExportToOutputUriStatus", + "properties": { + "state": { + "description": "Output only. State of the `output_uri` export.", + "enum": [ + "STATE_UNSPECIFIED", + "SUCCEEDED", + "FAILED" + ], + "enumDescriptions": [ + "Default value.", + "Export succeeded.", + "Export failed." + ], + "readOnly": true, + "type": "string" + }, + "status": { + "$ref": "GoogleRpc_Status", + "description": "Output only. Only set if state is FAILED.", + "readOnly": true + } + }, + "type": "object" + }, "GoogleCloudVideointelligenceV1p1beta1_FaceAnnotation": { "deprecated": true, "description": "Deprecated. No effect.", @@ -2428,7 +2517,7 @@ "type": "object" }, "GoogleCloudVideointelligenceV1p1beta1_NormalizedBoundingPoly": { - "description": "Normalized bounding polygon for text (that might not be aligned with axis). Contains list of the corner points in clockwise order starting from top-left corner. For example, for a rectangular bounding box: When the text is horizontal it might look like: 0----1 | | 3----2 When it's clockwise rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertex order will still be (0, 1, 2, 3). Note that values can be less than 0, or greater than 1 due to trignometric calculations for location of the box.", + "description": "Normalized bounding polygon for text (that might not be aligned with axis). Contains list of the corner points in clockwise order starting from top-left corner. For example, for a rectangular bounding box: When the text is horizontal it might look like: 0----1 | | 3----2 When it's clockwise rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertex order will still be (0, 1, 2, 3). Note that values can be less than 0, or greater than 1 due to trigonometric calculations for location of the box.", "id": "GoogleCloudVideointelligenceV1p1beta1_NormalizedBoundingPoly", "properties": { "vertices": { @@ -2697,6 +2786,10 @@ "description": "Annotation progress for a single video.", "id": "GoogleCloudVideointelligenceV1p1beta1_VideoAnnotationProgress", "properties": { + "exportStatus": { + "$ref": "GoogleCloudVideointelligenceV1p1beta1_ExportToOutputUriStatus", + "description": "Status of exporting annotation response to user specified `output_uri`. Only set if `output_uri` is set in the request." + }, "feature": { "description": "Specifies which feature is being tracked if the request contains more than one feature.", "enum": [ @@ -2979,7 +3072,7 @@ }, "point": { "$ref": "GoogleCloudVideointelligenceV1p2beta1_NormalizedVertex", - "description": "The 2D point of the detected landmark using the normalized image coordindate system. The normalized coordinates have the range from 0 to 1." + "description": "The 2D point of the detected landmark using the normalized image coordinate system. The normalized coordinates have the range from 0 to 1." } }, "type": "object" @@ -3053,6 +3146,33 @@ }, "type": "object" }, + "GoogleCloudVideointelligenceV1p2beta1_ExportToOutputUriStatus": { + "description": "Status of exporting annotation response to user specified `output_uri`.", + "id": "GoogleCloudVideointelligenceV1p2beta1_ExportToOutputUriStatus", + "properties": { + "state": { + "description": "Output only. State of the `output_uri` export.", + "enum": [ + "STATE_UNSPECIFIED", + "SUCCEEDED", + "FAILED" + ], + "enumDescriptions": [ + "Default value.", + "Export succeeded.", + "Export failed." + ], + "readOnly": true, + "type": "string" + }, + "status": { + "$ref": "GoogleRpc_Status", + "description": "Output only. Only set if state is FAILED.", + "readOnly": true + } + }, + "type": "object" + }, "GoogleCloudVideointelligenceV1p2beta1_FaceAnnotation": { "deprecated": true, "description": "Deprecated. No effect.", @@ -3256,7 +3376,7 @@ "type": "object" }, "GoogleCloudVideointelligenceV1p2beta1_NormalizedBoundingPoly": { - "description": "Normalized bounding polygon for text (that might not be aligned with axis). Contains list of the corner points in clockwise order starting from top-left corner. For example, for a rectangular bounding box: When the text is horizontal it might look like: 0----1 | | 3----2 When it's clockwise rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertex order will still be (0, 1, 2, 3). Note that values can be less than 0, or greater than 1 due to trignometric calculations for location of the box.", + "description": "Normalized bounding polygon for text (that might not be aligned with axis). Contains list of the corner points in clockwise order starting from top-left corner. For example, for a rectangular bounding box: When the text is horizontal it might look like: 0----1 | | 3----2 When it's clockwise rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertex order will still be (0, 1, 2, 3). Note that values can be less than 0, or greater than 1 due to trigonometric calculations for location of the box.", "id": "GoogleCloudVideointelligenceV1p2beta1_NormalizedBoundingPoly", "properties": { "vertices": { @@ -3525,6 +3645,10 @@ "description": "Annotation progress for a single video.", "id": "GoogleCloudVideointelligenceV1p2beta1_VideoAnnotationProgress", "properties": { + "exportStatus": { + "$ref": "GoogleCloudVideointelligenceV1p2beta1_ExportToOutputUriStatus", + "description": "Status of exporting annotation response to user specified `output_uri`. Only set if `output_uri` is set in the request." + }, "feature": { "description": "Specifies which feature is being tracked if the request contains more than one feature.", "enum": [ @@ -3862,7 +3986,7 @@ }, "point": { "$ref": "GoogleCloudVideointelligenceV1p3beta1_NormalizedVertex", - "description": "The 2D point of the detected landmark using the normalized image coordindate system. The normalized coordinates have the range from 0 to 1." + "description": "The 2D point of the detected landmark using the normalized image coordinate system. The normalized coordinates have the range from 0 to 1." } }, "type": "object" @@ -3936,6 +4060,33 @@ }, "type": "object" }, + "GoogleCloudVideointelligenceV1p3beta1_ExportToOutputUriStatus": { + "description": "Status of exporting annotation response to user specified `output_uri`.", + "id": "GoogleCloudVideointelligenceV1p3beta1_ExportToOutputUriStatus", + "properties": { + "state": { + "description": "Output only. State of the `output_uri` export.", + "enum": [ + "STATE_UNSPECIFIED", + "SUCCEEDED", + "FAILED" + ], + "enumDescriptions": [ + "Default value.", + "Export succeeded.", + "Export failed." + ], + "readOnly": true, + "type": "string" + }, + "status": { + "$ref": "GoogleRpc_Status", + "description": "Output only. Only set if state is FAILED.", + "readOnly": true + } + }, + "type": "object" + }, "GoogleCloudVideointelligenceV1p3beta1_FaceAnnotation": { "deprecated": true, "description": "Deprecated. No effect.", @@ -4139,7 +4290,7 @@ "type": "object" }, "GoogleCloudVideointelligenceV1p3beta1_NormalizedBoundingPoly": { - "description": "Normalized bounding polygon for text (that might not be aligned with axis). Contains list of the corner points in clockwise order starting from top-left corner. For example, for a rectangular bounding box: When the text is horizontal it might look like: 0----1 | | 3----2 When it's clockwise rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertex order will still be (0, 1, 2, 3). Note that values can be less than 0, or greater than 1 due to trignometric calculations for location of the box.", + "description": "Normalized bounding polygon for text (that might not be aligned with axis). Contains list of the corner points in clockwise order starting from top-left corner. For example, for a rectangular bounding box: When the text is horizontal it might look like: 0----1 | | 3----2 When it's clockwise rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertex order will still be (0, 1, 2, 3). Note that values can be less than 0, or greater than 1 due to trigonometric calculations for location of the box.", "id": "GoogleCloudVideointelligenceV1p3beta1_NormalizedBoundingPoly", "properties": { "vertices": { @@ -4480,6 +4631,10 @@ "description": "Annotation progress for a single video.", "id": "GoogleCloudVideointelligenceV1p3beta1_VideoAnnotationProgress", "properties": { + "exportStatus": { + "$ref": "GoogleCloudVideointelligenceV1p3beta1_ExportToOutputUriStatus", + "description": "Status of exporting annotation response to user specified `output_uri`. Only set if `output_uri` is set in the request." + }, "feature": { "description": "Specifies which feature is being tracked if the request contains more than one feature.", "enum": [ diff --git a/videointelligence/v1beta2/videointelligence-gen.go b/videointelligence/v1beta2/videointelligence-gen.go index 9f0b95c7da2..3016977cafa 100644 --- a/videointelligence/v1beta2/videointelligence-gen.go +++ b/videointelligence/v1beta2/videointelligence-gen.go @@ -267,7 +267,7 @@ type GoogleCloudVideointelligenceV1DetectedLandmark struct { // Name: The name of this landmark, for example, left_hand, right_shoulder. Name string `json:"name,omitempty"` // Point: The 2D point of the detected landmark using the normalized image - // coordindate system. The normalized coordinates have the range from 0 to 1. + // coordinate system. The normalized coordinates have the range from 0 to 1. Point *GoogleCloudVideointelligenceV1NormalizedVertex `json:"point,omitempty"` // ForceSendFields is a list of field names (e.g. "Confidence") to // unconditionally include in API requests. By default, fields with empty or @@ -388,6 +388,36 @@ func (s GoogleCloudVideointelligenceV1ExplicitContentFrame) MarshalJSON() ([]byt return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudVideointelligenceV1ExportToOutputUriStatus: Status of exporting +// annotation response to user specified `output_uri`. +type GoogleCloudVideointelligenceV1ExportToOutputUriStatus struct { + // State: Output only. State of the `output_uri` export. + // + // Possible values: + // "STATE_UNSPECIFIED" - Default value. + // "SUCCEEDED" - Export succeeded. + // "FAILED" - Export failed. + State string `json:"state,omitempty"` + // Status: Output only. Only set if state is FAILED. + Status *GoogleRpcStatus `json:"status,omitempty"` + // ForceSendFields is a list of field names (e.g. "State") 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. "State") 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 GoogleCloudVideointelligenceV1ExportToOutputUriStatus) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudVideointelligenceV1ExportToOutputUriStatus + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudVideointelligenceV1FaceAnnotation: Deprecated. No effect. type GoogleCloudVideointelligenceV1FaceAnnotation struct { // Frames: All video frames where a face was detected. @@ -690,7 +720,7 @@ func (s *GoogleCloudVideointelligenceV1NormalizedBoundingBox) UnmarshalJSON(data // like: 0----1 | | 3----2 When it's clockwise rotated 180 degrees around the // top-left corner it becomes: 2----3 | | 1----0 and the vertex order will // still be (0, 1, 2, 3). Note that values can be less than 0, or greater than -// 1 due to trignometric calculations for location of the box. +// 1 due to trigonometric calculations for location of the box. type GoogleCloudVideointelligenceV1NormalizedBoundingPoly struct { // Vertices: Normalized vertices of the bounding polygon. Vertices []*GoogleCloudVideointelligenceV1NormalizedVertex `json:"vertices,omitempty"` @@ -1115,6 +1145,9 @@ func (s *GoogleCloudVideointelligenceV1Track) UnmarshalJSON(data []byte) error { // GoogleCloudVideointelligenceV1VideoAnnotationProgress: Annotation progress // for a single video. type GoogleCloudVideointelligenceV1VideoAnnotationProgress struct { + // ExportStatus: Status of exporting annotation response to user specified + // `output_uri`. Only set if `output_uri` is set in the request. + ExportStatus *GoogleCloudVideointelligenceV1ExportToOutputUriStatus `json:"exportStatus,omitempty"` // Feature: Specifies which feature is being tracked if the request contains // more than one feature. // @@ -1144,13 +1177,13 @@ type GoogleCloudVideointelligenceV1VideoAnnotationProgress struct { StartTime string `json:"startTime,omitempty"` // UpdateTime: Time of the most recent update. UpdateTime string `json:"updateTime,omitempty"` - // ForceSendFields is a list of field names (e.g. "Feature") 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. "ExportStatus") 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. "Feature") to include in API + // NullFields is a list of field names (e.g. "ExportStatus") 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. @@ -1491,7 +1524,7 @@ type GoogleCloudVideointelligenceV1beta2DetectedLandmark struct { // Name: The name of this landmark, for example, left_hand, right_shoulder. Name string `json:"name,omitempty"` // Point: The 2D point of the detected landmark using the normalized image - // coordindate system. The normalized coordinates have the range from 0 to 1. + // coordinate system. The normalized coordinates have the range from 0 to 1. Point *GoogleCloudVideointelligenceV1beta2NormalizedVertex `json:"point,omitempty"` // ForceSendFields is a list of field names (e.g. "Confidence") to // unconditionally include in API requests. By default, fields with empty or @@ -1638,6 +1671,36 @@ func (s GoogleCloudVideointelligenceV1beta2ExplicitContentFrame) MarshalJSON() ( return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudVideointelligenceV1beta2ExportToOutputUriStatus: Status of +// exporting annotation response to user specified `output_uri`. +type GoogleCloudVideointelligenceV1beta2ExportToOutputUriStatus struct { + // State: Output only. State of the `output_uri` export. + // + // Possible values: + // "STATE_UNSPECIFIED" - Default value. + // "SUCCEEDED" - Export succeeded. + // "FAILED" - Export failed. + State string `json:"state,omitempty"` + // Status: Output only. Only set if state is FAILED. + Status *GoogleRpcStatus `json:"status,omitempty"` + // ForceSendFields is a list of field names (e.g. "State") 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. "State") 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 GoogleCloudVideointelligenceV1beta2ExportToOutputUriStatus) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudVideointelligenceV1beta2ExportToOutputUriStatus + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudVideointelligenceV1beta2FaceAnnotation: Deprecated. No effect. type GoogleCloudVideointelligenceV1beta2FaceAnnotation struct { // Frames: All video frames where a face was detected. @@ -2039,7 +2102,7 @@ func (s *GoogleCloudVideointelligenceV1beta2NormalizedBoundingBox) UnmarshalJSON // might look like: 0----1 | | 3----2 When it's clockwise rotated 180 degrees // around the top-left corner it becomes: 2----3 | | 1----0 and the vertex // order will still be (0, 1, 2, 3). Note that values can be less than 0, or -// greater than 1 due to trignometric calculations for location of the box. +// greater than 1 due to trigonometric calculations for location of the box. type GoogleCloudVideointelligenceV1beta2NormalizedBoundingPoly struct { // Vertices: Normalized vertices of the bounding polygon. Vertices []*GoogleCloudVideointelligenceV1beta2NormalizedVertex `json:"vertices,omitempty"` @@ -2669,6 +2732,9 @@ func (s *GoogleCloudVideointelligenceV1beta2Track) UnmarshalJSON(data []byte) er // GoogleCloudVideointelligenceV1beta2VideoAnnotationProgress: Annotation // progress for a single video. type GoogleCloudVideointelligenceV1beta2VideoAnnotationProgress struct { + // ExportStatus: Status of exporting annotation response to user specified + // `output_uri`. Only set if `output_uri` is set in the request. + ExportStatus *GoogleCloudVideointelligenceV1beta2ExportToOutputUriStatus `json:"exportStatus,omitempty"` // Feature: Specifies which feature is being tracked if the request contains // more than one feature. // @@ -2698,13 +2764,13 @@ type GoogleCloudVideointelligenceV1beta2VideoAnnotationProgress struct { StartTime string `json:"startTime,omitempty"` // UpdateTime: Time of the most recent update. UpdateTime string `json:"updateTime,omitempty"` - // ForceSendFields is a list of field names (e.g. "Feature") 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. "ExportStatus") 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. "Feature") to include in API + // NullFields is a list of field names (e.g. "ExportStatus") 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. @@ -3024,7 +3090,7 @@ type GoogleCloudVideointelligenceV1p1beta1DetectedLandmark struct { // Name: The name of this landmark, for example, left_hand, right_shoulder. Name string `json:"name,omitempty"` // Point: The 2D point of the detected landmark using the normalized image - // coordindate system. The normalized coordinates have the range from 0 to 1. + // coordinate system. The normalized coordinates have the range from 0 to 1. Point *GoogleCloudVideointelligenceV1p1beta1NormalizedVertex `json:"point,omitempty"` // ForceSendFields is a list of field names (e.g. "Confidence") to // unconditionally include in API requests. By default, fields with empty or @@ -3147,6 +3213,36 @@ func (s GoogleCloudVideointelligenceV1p1beta1ExplicitContentFrame) MarshalJSON() return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudVideointelligenceV1p1beta1ExportToOutputUriStatus: Status of +// exporting annotation response to user specified `output_uri`. +type GoogleCloudVideointelligenceV1p1beta1ExportToOutputUriStatus struct { + // State: Output only. State of the `output_uri` export. + // + // Possible values: + // "STATE_UNSPECIFIED" - Default value. + // "SUCCEEDED" - Export succeeded. + // "FAILED" - Export failed. + State string `json:"state,omitempty"` + // Status: Output only. Only set if state is FAILED. + Status *GoogleRpcStatus `json:"status,omitempty"` + // ForceSendFields is a list of field names (e.g. "State") 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. "State") 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 GoogleCloudVideointelligenceV1p1beta1ExportToOutputUriStatus) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudVideointelligenceV1p1beta1ExportToOutputUriStatus + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudVideointelligenceV1p1beta1FaceAnnotation: Deprecated. No effect. type GoogleCloudVideointelligenceV1p1beta1FaceAnnotation struct { // Frames: All video frames where a face was detected. @@ -3449,7 +3545,7 @@ func (s *GoogleCloudVideointelligenceV1p1beta1NormalizedBoundingBox) UnmarshalJS // might look like: 0----1 | | 3----2 When it's clockwise rotated 180 degrees // around the top-left corner it becomes: 2----3 | | 1----0 and the vertex // order will still be (0, 1, 2, 3). Note that values can be less than 0, or -// greater than 1 due to trignometric calculations for location of the box. +// greater than 1 due to trigonometric calculations for location of the box. type GoogleCloudVideointelligenceV1p1beta1NormalizedBoundingPoly struct { // Vertices: Normalized vertices of the bounding polygon. Vertices []*GoogleCloudVideointelligenceV1p1beta1NormalizedVertex `json:"vertices,omitempty"` @@ -3874,6 +3970,9 @@ func (s *GoogleCloudVideointelligenceV1p1beta1Track) UnmarshalJSON(data []byte) // GoogleCloudVideointelligenceV1p1beta1VideoAnnotationProgress: Annotation // progress for a single video. type GoogleCloudVideointelligenceV1p1beta1VideoAnnotationProgress struct { + // ExportStatus: Status of exporting annotation response to user specified + // `output_uri`. Only set if `output_uri` is set in the request. + ExportStatus *GoogleCloudVideointelligenceV1p1beta1ExportToOutputUriStatus `json:"exportStatus,omitempty"` // Feature: Specifies which feature is being tracked if the request contains // more than one feature. // @@ -3903,13 +4002,13 @@ type GoogleCloudVideointelligenceV1p1beta1VideoAnnotationProgress struct { StartTime string `json:"startTime,omitempty"` // UpdateTime: Time of the most recent update. UpdateTime string `json:"updateTime,omitempty"` - // ForceSendFields is a list of field names (e.g. "Feature") 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. "ExportStatus") 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. "Feature") to include in API + // NullFields is a list of field names (e.g. "ExportStatus") 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. @@ -4187,7 +4286,7 @@ type GoogleCloudVideointelligenceV1p2beta1DetectedLandmark struct { // Name: The name of this landmark, for example, left_hand, right_shoulder. Name string `json:"name,omitempty"` // Point: The 2D point of the detected landmark using the normalized image - // coordindate system. The normalized coordinates have the range from 0 to 1. + // coordinate system. The normalized coordinates have the range from 0 to 1. Point *GoogleCloudVideointelligenceV1p2beta1NormalizedVertex `json:"point,omitempty"` // ForceSendFields is a list of field names (e.g. "Confidence") to // unconditionally include in API requests. By default, fields with empty or @@ -4310,6 +4409,36 @@ func (s GoogleCloudVideointelligenceV1p2beta1ExplicitContentFrame) MarshalJSON() return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudVideointelligenceV1p2beta1ExportToOutputUriStatus: Status of +// exporting annotation response to user specified `output_uri`. +type GoogleCloudVideointelligenceV1p2beta1ExportToOutputUriStatus struct { + // State: Output only. State of the `output_uri` export. + // + // Possible values: + // "STATE_UNSPECIFIED" - Default value. + // "SUCCEEDED" - Export succeeded. + // "FAILED" - Export failed. + State string `json:"state,omitempty"` + // Status: Output only. Only set if state is FAILED. + Status *GoogleRpcStatus `json:"status,omitempty"` + // ForceSendFields is a list of field names (e.g. "State") 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. "State") 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 GoogleCloudVideointelligenceV1p2beta1ExportToOutputUriStatus) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudVideointelligenceV1p2beta1ExportToOutputUriStatus + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudVideointelligenceV1p2beta1FaceAnnotation: Deprecated. No effect. type GoogleCloudVideointelligenceV1p2beta1FaceAnnotation struct { // Frames: All video frames where a face was detected. @@ -4612,7 +4741,7 @@ func (s *GoogleCloudVideointelligenceV1p2beta1NormalizedBoundingBox) UnmarshalJS // might look like: 0----1 | | 3----2 When it's clockwise rotated 180 degrees // around the top-left corner it becomes: 2----3 | | 1----0 and the vertex // order will still be (0, 1, 2, 3). Note that values can be less than 0, or -// greater than 1 due to trignometric calculations for location of the box. +// greater than 1 due to trigonometric calculations for location of the box. type GoogleCloudVideointelligenceV1p2beta1NormalizedBoundingPoly struct { // Vertices: Normalized vertices of the bounding polygon. Vertices []*GoogleCloudVideointelligenceV1p2beta1NormalizedVertex `json:"vertices,omitempty"` @@ -5037,6 +5166,9 @@ func (s *GoogleCloudVideointelligenceV1p2beta1Track) UnmarshalJSON(data []byte) // GoogleCloudVideointelligenceV1p2beta1VideoAnnotationProgress: Annotation // progress for a single video. type GoogleCloudVideointelligenceV1p2beta1VideoAnnotationProgress struct { + // ExportStatus: Status of exporting annotation response to user specified + // `output_uri`. Only set if `output_uri` is set in the request. + ExportStatus *GoogleCloudVideointelligenceV1p2beta1ExportToOutputUriStatus `json:"exportStatus,omitempty"` // Feature: Specifies which feature is being tracked if the request contains // more than one feature. // @@ -5066,13 +5198,13 @@ type GoogleCloudVideointelligenceV1p2beta1VideoAnnotationProgress struct { StartTime string `json:"startTime,omitempty"` // UpdateTime: Time of the most recent update. UpdateTime string `json:"updateTime,omitempty"` - // ForceSendFields is a list of field names (e.g. "Feature") 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. "ExportStatus") 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. "Feature") to include in API + // NullFields is a list of field names (e.g. "ExportStatus") 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. @@ -5432,7 +5564,7 @@ type GoogleCloudVideointelligenceV1p3beta1DetectedLandmark struct { // Name: The name of this landmark, for example, left_hand, right_shoulder. Name string `json:"name,omitempty"` // Point: The 2D point of the detected landmark using the normalized image - // coordindate system. The normalized coordinates have the range from 0 to 1. + // coordinate system. The normalized coordinates have the range from 0 to 1. Point *GoogleCloudVideointelligenceV1p3beta1NormalizedVertex `json:"point,omitempty"` // ForceSendFields is a list of field names (e.g. "Confidence") to // unconditionally include in API requests. By default, fields with empty or @@ -5555,6 +5687,36 @@ func (s GoogleCloudVideointelligenceV1p3beta1ExplicitContentFrame) MarshalJSON() return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudVideointelligenceV1p3beta1ExportToOutputUriStatus: Status of +// exporting annotation response to user specified `output_uri`. +type GoogleCloudVideointelligenceV1p3beta1ExportToOutputUriStatus struct { + // State: Output only. State of the `output_uri` export. + // + // Possible values: + // "STATE_UNSPECIFIED" - Default value. + // "SUCCEEDED" - Export succeeded. + // "FAILED" - Export failed. + State string `json:"state,omitempty"` + // Status: Output only. Only set if state is FAILED. + Status *GoogleRpcStatus `json:"status,omitempty"` + // ForceSendFields is a list of field names (e.g. "State") 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. "State") 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 GoogleCloudVideointelligenceV1p3beta1ExportToOutputUriStatus) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudVideointelligenceV1p3beta1ExportToOutputUriStatus + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudVideointelligenceV1p3beta1FaceAnnotation: Deprecated. No effect. type GoogleCloudVideointelligenceV1p3beta1FaceAnnotation struct { // Frames: All video frames where a face was detected. @@ -5857,7 +6019,7 @@ func (s *GoogleCloudVideointelligenceV1p3beta1NormalizedBoundingBox) UnmarshalJS // might look like: 0----1 | | 3----2 When it's clockwise rotated 180 degrees // around the top-left corner it becomes: 2----3 | | 1----0 and the vertex // order will still be (0, 1, 2, 3). Note that values can be less than 0, or -// greater than 1 due to trignometric calculations for location of the box. +// greater than 1 due to trigonometric calculations for location of the box. type GoogleCloudVideointelligenceV1p3beta1NormalizedBoundingPoly struct { // Vertices: Normalized vertices of the bounding polygon. Vertices []*GoogleCloudVideointelligenceV1p3beta1NormalizedVertex `json:"vertices,omitempty"` @@ -6388,6 +6550,9 @@ func (s *GoogleCloudVideointelligenceV1p3beta1Track) UnmarshalJSON(data []byte) // GoogleCloudVideointelligenceV1p3beta1VideoAnnotationProgress: Annotation // progress for a single video. type GoogleCloudVideointelligenceV1p3beta1VideoAnnotationProgress struct { + // ExportStatus: Status of exporting annotation response to user specified + // `output_uri`. Only set if `output_uri` is set in the request. + ExportStatus *GoogleCloudVideointelligenceV1p3beta1ExportToOutputUriStatus `json:"exportStatus,omitempty"` // Feature: Specifies which feature is being tracked if the request contains // more than one feature. // @@ -6418,13 +6583,13 @@ type GoogleCloudVideointelligenceV1p3beta1VideoAnnotationProgress struct { StartTime string `json:"startTime,omitempty"` // UpdateTime: Time of the most recent update. UpdateTime string `json:"updateTime,omitempty"` - // ForceSendFields is a list of field names (e.g. "Feature") 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. "ExportStatus") 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. "Feature") to include in API + // NullFields is a list of field names (e.g. "ExportStatus") 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/videointelligence/v1p1beta1/videointelligence-api.json b/videointelligence/v1p1beta1/videointelligence-api.json index 1bad050bd4a..32af538eb06 100644 --- a/videointelligence/v1p1beta1/videointelligence-api.json +++ b/videointelligence/v1p1beta1/videointelligence-api.json @@ -128,7 +128,7 @@ } } }, - "revision": "20250710", + "revision": "20250724", "rootUrl": "https://videointelligence.googleapis.com/", "schemas": { "GoogleCloudVideointelligenceV1_AnnotateVideoProgress": { @@ -194,7 +194,7 @@ }, "point": { "$ref": "GoogleCloudVideointelligenceV1_NormalizedVertex", - "description": "The 2D point of the detected landmark using the normalized image coordindate system. The normalized coordinates have the range from 0 to 1." + "description": "The 2D point of the detected landmark using the normalized image coordinate system. The normalized coordinates have the range from 0 to 1." } }, "type": "object" @@ -268,6 +268,33 @@ }, "type": "object" }, + "GoogleCloudVideointelligenceV1_ExportToOutputUriStatus": { + "description": "Status of exporting annotation response to user specified `output_uri`.", + "id": "GoogleCloudVideointelligenceV1_ExportToOutputUriStatus", + "properties": { + "state": { + "description": "Output only. State of the `output_uri` export.", + "enum": [ + "STATE_UNSPECIFIED", + "SUCCEEDED", + "FAILED" + ], + "enumDescriptions": [ + "Default value.", + "Export succeeded.", + "Export failed." + ], + "readOnly": true, + "type": "string" + }, + "status": { + "$ref": "GoogleRpc_Status", + "description": "Output only. Only set if state is FAILED.", + "readOnly": true + } + }, + "type": "object" + }, "GoogleCloudVideointelligenceV1_FaceAnnotation": { "deprecated": true, "description": "Deprecated. No effect.", @@ -471,7 +498,7 @@ "type": "object" }, "GoogleCloudVideointelligenceV1_NormalizedBoundingPoly": { - "description": "Normalized bounding polygon for text (that might not be aligned with axis). Contains list of the corner points in clockwise order starting from top-left corner. For example, for a rectangular bounding box: When the text is horizontal it might look like: 0----1 | | 3----2 When it's clockwise rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertex order will still be (0, 1, 2, 3). Note that values can be less than 0, or greater than 1 due to trignometric calculations for location of the box.", + "description": "Normalized bounding polygon for text (that might not be aligned with axis). Contains list of the corner points in clockwise order starting from top-left corner. For example, for a rectangular bounding box: When the text is horizontal it might look like: 0----1 | | 3----2 When it's clockwise rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertex order will still be (0, 1, 2, 3). Note that values can be less than 0, or greater than 1 due to trigonometric calculations for location of the box.", "id": "GoogleCloudVideointelligenceV1_NormalizedBoundingPoly", "properties": { "vertices": { @@ -740,6 +767,10 @@ "description": "Annotation progress for a single video.", "id": "GoogleCloudVideointelligenceV1_VideoAnnotationProgress", "properties": { + "exportStatus": { + "$ref": "GoogleCloudVideointelligenceV1_ExportToOutputUriStatus", + "description": "Status of exporting annotation response to user specified `output_uri`. Only set if `output_uri` is set in the request." + }, "feature": { "description": "Specifies which feature is being tracked if the request contains more than one feature.", "enum": [ @@ -1022,7 +1053,7 @@ }, "point": { "$ref": "GoogleCloudVideointelligenceV1beta2_NormalizedVertex", - "description": "The 2D point of the detected landmark using the normalized image coordindate system. The normalized coordinates have the range from 0 to 1." + "description": "The 2D point of the detected landmark using the normalized image coordinate system. The normalized coordinates have the range from 0 to 1." } }, "type": "object" @@ -1096,6 +1127,33 @@ }, "type": "object" }, + "GoogleCloudVideointelligenceV1beta2_ExportToOutputUriStatus": { + "description": "Status of exporting annotation response to user specified `output_uri`.", + "id": "GoogleCloudVideointelligenceV1beta2_ExportToOutputUriStatus", + "properties": { + "state": { + "description": "Output only. State of the `output_uri` export.", + "enum": [ + "STATE_UNSPECIFIED", + "SUCCEEDED", + "FAILED" + ], + "enumDescriptions": [ + "Default value.", + "Export succeeded.", + "Export failed." + ], + "readOnly": true, + "type": "string" + }, + "status": { + "$ref": "GoogleRpc_Status", + "description": "Output only. Only set if state is FAILED.", + "readOnly": true + } + }, + "type": "object" + }, "GoogleCloudVideointelligenceV1beta2_FaceAnnotation": { "deprecated": true, "description": "Deprecated. No effect.", @@ -1299,7 +1357,7 @@ "type": "object" }, "GoogleCloudVideointelligenceV1beta2_NormalizedBoundingPoly": { - "description": "Normalized bounding polygon for text (that might not be aligned with axis). Contains list of the corner points in clockwise order starting from top-left corner. For example, for a rectangular bounding box: When the text is horizontal it might look like: 0----1 | | 3----2 When it's clockwise rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertex order will still be (0, 1, 2, 3). Note that values can be less than 0, or greater than 1 due to trignometric calculations for location of the box.", + "description": "Normalized bounding polygon for text (that might not be aligned with axis). Contains list of the corner points in clockwise order starting from top-left corner. For example, for a rectangular bounding box: When the text is horizontal it might look like: 0----1 | | 3----2 When it's clockwise rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertex order will still be (0, 1, 2, 3). Note that values can be less than 0, or greater than 1 due to trigonometric calculations for location of the box.", "id": "GoogleCloudVideointelligenceV1beta2_NormalizedBoundingPoly", "properties": { "vertices": { @@ -1568,6 +1626,10 @@ "description": "Annotation progress for a single video.", "id": "GoogleCloudVideointelligenceV1beta2_VideoAnnotationProgress", "properties": { + "exportStatus": { + "$ref": "GoogleCloudVideointelligenceV1beta2_ExportToOutputUriStatus", + "description": "Status of exporting annotation response to user specified `output_uri`. Only set if `output_uri` is set in the request." + }, "feature": { "description": "Specifies which feature is being tracked if the request contains more than one feature.", "enum": [ @@ -1909,7 +1971,7 @@ }, "point": { "$ref": "GoogleCloudVideointelligenceV1p1beta1_NormalizedVertex", - "description": "The 2D point of the detected landmark using the normalized image coordindate system. The normalized coordinates have the range from 0 to 1." + "description": "The 2D point of the detected landmark using the normalized image coordinate system. The normalized coordinates have the range from 0 to 1." } }, "type": "object" @@ -1994,6 +2056,33 @@ }, "type": "object" }, + "GoogleCloudVideointelligenceV1p1beta1_ExportToOutputUriStatus": { + "description": "Status of exporting annotation response to user specified `output_uri`.", + "id": "GoogleCloudVideointelligenceV1p1beta1_ExportToOutputUriStatus", + "properties": { + "state": { + "description": "Output only. State of the `output_uri` export.", + "enum": [ + "STATE_UNSPECIFIED", + "SUCCEEDED", + "FAILED" + ], + "enumDescriptions": [ + "Default value.", + "Export succeeded.", + "Export failed." + ], + "readOnly": true, + "type": "string" + }, + "status": { + "$ref": "GoogleRpc_Status", + "description": "Output only. Only set if state is FAILED.", + "readOnly": true + } + }, + "type": "object" + }, "GoogleCloudVideointelligenceV1p1beta1_FaceAnnotation": { "deprecated": true, "description": "Deprecated. No effect.", @@ -2257,7 +2346,7 @@ "type": "object" }, "GoogleCloudVideointelligenceV1p1beta1_NormalizedBoundingPoly": { - "description": "Normalized bounding polygon for text (that might not be aligned with axis). Contains list of the corner points in clockwise order starting from top-left corner. For example, for a rectangular bounding box: When the text is horizontal it might look like: 0----1 | | 3----2 When it's clockwise rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertex order will still be (0, 1, 2, 3). Note that values can be less than 0, or greater than 1 due to trignometric calculations for location of the box.", + "description": "Normalized bounding polygon for text (that might not be aligned with axis). Contains list of the corner points in clockwise order starting from top-left corner. For example, for a rectangular bounding box: When the text is horizontal it might look like: 0----1 | | 3----2 When it's clockwise rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertex order will still be (0, 1, 2, 3). Note that values can be less than 0, or greater than 1 due to trigonometric calculations for location of the box.", "id": "GoogleCloudVideointelligenceV1p1beta1_NormalizedBoundingPoly", "properties": { "vertices": { @@ -2651,6 +2740,10 @@ "description": "Annotation progress for a single video.", "id": "GoogleCloudVideointelligenceV1p1beta1_VideoAnnotationProgress", "properties": { + "exportStatus": { + "$ref": "GoogleCloudVideointelligenceV1p1beta1_ExportToOutputUriStatus", + "description": "Status of exporting annotation response to user specified `output_uri`. Only set if `output_uri` is set in the request." + }, "feature": { "description": "Specifies which feature is being tracked if the request contains more than one feature.", "enum": [ @@ -2979,7 +3072,7 @@ }, "point": { "$ref": "GoogleCloudVideointelligenceV1p2beta1_NormalizedVertex", - "description": "The 2D point of the detected landmark using the normalized image coordindate system. The normalized coordinates have the range from 0 to 1." + "description": "The 2D point of the detected landmark using the normalized image coordinate system. The normalized coordinates have the range from 0 to 1." } }, "type": "object" @@ -3053,6 +3146,33 @@ }, "type": "object" }, + "GoogleCloudVideointelligenceV1p2beta1_ExportToOutputUriStatus": { + "description": "Status of exporting annotation response to user specified `output_uri`.", + "id": "GoogleCloudVideointelligenceV1p2beta1_ExportToOutputUriStatus", + "properties": { + "state": { + "description": "Output only. State of the `output_uri` export.", + "enum": [ + "STATE_UNSPECIFIED", + "SUCCEEDED", + "FAILED" + ], + "enumDescriptions": [ + "Default value.", + "Export succeeded.", + "Export failed." + ], + "readOnly": true, + "type": "string" + }, + "status": { + "$ref": "GoogleRpc_Status", + "description": "Output only. Only set if state is FAILED.", + "readOnly": true + } + }, + "type": "object" + }, "GoogleCloudVideointelligenceV1p2beta1_FaceAnnotation": { "deprecated": true, "description": "Deprecated. No effect.", @@ -3256,7 +3376,7 @@ "type": "object" }, "GoogleCloudVideointelligenceV1p2beta1_NormalizedBoundingPoly": { - "description": "Normalized bounding polygon for text (that might not be aligned with axis). Contains list of the corner points in clockwise order starting from top-left corner. For example, for a rectangular bounding box: When the text is horizontal it might look like: 0----1 | | 3----2 When it's clockwise rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertex order will still be (0, 1, 2, 3). Note that values can be less than 0, or greater than 1 due to trignometric calculations for location of the box.", + "description": "Normalized bounding polygon for text (that might not be aligned with axis). Contains list of the corner points in clockwise order starting from top-left corner. For example, for a rectangular bounding box: When the text is horizontal it might look like: 0----1 | | 3----2 When it's clockwise rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertex order will still be (0, 1, 2, 3). Note that values can be less than 0, or greater than 1 due to trigonometric calculations for location of the box.", "id": "GoogleCloudVideointelligenceV1p2beta1_NormalizedBoundingPoly", "properties": { "vertices": { @@ -3525,6 +3645,10 @@ "description": "Annotation progress for a single video.", "id": "GoogleCloudVideointelligenceV1p2beta1_VideoAnnotationProgress", "properties": { + "exportStatus": { + "$ref": "GoogleCloudVideointelligenceV1p2beta1_ExportToOutputUriStatus", + "description": "Status of exporting annotation response to user specified `output_uri`. Only set if `output_uri` is set in the request." + }, "feature": { "description": "Specifies which feature is being tracked if the request contains more than one feature.", "enum": [ @@ -3862,7 +3986,7 @@ }, "point": { "$ref": "GoogleCloudVideointelligenceV1p3beta1_NormalizedVertex", - "description": "The 2D point of the detected landmark using the normalized image coordindate system. The normalized coordinates have the range from 0 to 1." + "description": "The 2D point of the detected landmark using the normalized image coordinate system. The normalized coordinates have the range from 0 to 1." } }, "type": "object" @@ -3936,6 +4060,33 @@ }, "type": "object" }, + "GoogleCloudVideointelligenceV1p3beta1_ExportToOutputUriStatus": { + "description": "Status of exporting annotation response to user specified `output_uri`.", + "id": "GoogleCloudVideointelligenceV1p3beta1_ExportToOutputUriStatus", + "properties": { + "state": { + "description": "Output only. State of the `output_uri` export.", + "enum": [ + "STATE_UNSPECIFIED", + "SUCCEEDED", + "FAILED" + ], + "enumDescriptions": [ + "Default value.", + "Export succeeded.", + "Export failed." + ], + "readOnly": true, + "type": "string" + }, + "status": { + "$ref": "GoogleRpc_Status", + "description": "Output only. Only set if state is FAILED.", + "readOnly": true + } + }, + "type": "object" + }, "GoogleCloudVideointelligenceV1p3beta1_FaceAnnotation": { "deprecated": true, "description": "Deprecated. No effect.", @@ -4139,7 +4290,7 @@ "type": "object" }, "GoogleCloudVideointelligenceV1p3beta1_NormalizedBoundingPoly": { - "description": "Normalized bounding polygon for text (that might not be aligned with axis). Contains list of the corner points in clockwise order starting from top-left corner. For example, for a rectangular bounding box: When the text is horizontal it might look like: 0----1 | | 3----2 When it's clockwise rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertex order will still be (0, 1, 2, 3). Note that values can be less than 0, or greater than 1 due to trignometric calculations for location of the box.", + "description": "Normalized bounding polygon for text (that might not be aligned with axis). Contains list of the corner points in clockwise order starting from top-left corner. For example, for a rectangular bounding box: When the text is horizontal it might look like: 0----1 | | 3----2 When it's clockwise rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertex order will still be (0, 1, 2, 3). Note that values can be less than 0, or greater than 1 due to trigonometric calculations for location of the box.", "id": "GoogleCloudVideointelligenceV1p3beta1_NormalizedBoundingPoly", "properties": { "vertices": { @@ -4480,6 +4631,10 @@ "description": "Annotation progress for a single video.", "id": "GoogleCloudVideointelligenceV1p3beta1_VideoAnnotationProgress", "properties": { + "exportStatus": { + "$ref": "GoogleCloudVideointelligenceV1p3beta1_ExportToOutputUriStatus", + "description": "Status of exporting annotation response to user specified `output_uri`. Only set if `output_uri` is set in the request." + }, "feature": { "description": "Specifies which feature is being tracked if the request contains more than one feature.", "enum": [ diff --git a/videointelligence/v1p1beta1/videointelligence-gen.go b/videointelligence/v1p1beta1/videointelligence-gen.go index 86505b608bb..b7df9e3d36a 100644 --- a/videointelligence/v1p1beta1/videointelligence-gen.go +++ b/videointelligence/v1p1beta1/videointelligence-gen.go @@ -267,7 +267,7 @@ type GoogleCloudVideointelligenceV1DetectedLandmark struct { // Name: The name of this landmark, for example, left_hand, right_shoulder. Name string `json:"name,omitempty"` // Point: The 2D point of the detected landmark using the normalized image - // coordindate system. The normalized coordinates have the range from 0 to 1. + // coordinate system. The normalized coordinates have the range from 0 to 1. Point *GoogleCloudVideointelligenceV1NormalizedVertex `json:"point,omitempty"` // ForceSendFields is a list of field names (e.g. "Confidence") to // unconditionally include in API requests. By default, fields with empty or @@ -388,6 +388,36 @@ func (s GoogleCloudVideointelligenceV1ExplicitContentFrame) MarshalJSON() ([]byt return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudVideointelligenceV1ExportToOutputUriStatus: Status of exporting +// annotation response to user specified `output_uri`. +type GoogleCloudVideointelligenceV1ExportToOutputUriStatus struct { + // State: Output only. State of the `output_uri` export. + // + // Possible values: + // "STATE_UNSPECIFIED" - Default value. + // "SUCCEEDED" - Export succeeded. + // "FAILED" - Export failed. + State string `json:"state,omitempty"` + // Status: Output only. Only set if state is FAILED. + Status *GoogleRpcStatus `json:"status,omitempty"` + // ForceSendFields is a list of field names (e.g. "State") 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. "State") 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 GoogleCloudVideointelligenceV1ExportToOutputUriStatus) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudVideointelligenceV1ExportToOutputUriStatus + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudVideointelligenceV1FaceAnnotation: Deprecated. No effect. type GoogleCloudVideointelligenceV1FaceAnnotation struct { // Frames: All video frames where a face was detected. @@ -690,7 +720,7 @@ func (s *GoogleCloudVideointelligenceV1NormalizedBoundingBox) UnmarshalJSON(data // like: 0----1 | | 3----2 When it's clockwise rotated 180 degrees around the // top-left corner it becomes: 2----3 | | 1----0 and the vertex order will // still be (0, 1, 2, 3). Note that values can be less than 0, or greater than -// 1 due to trignometric calculations for location of the box. +// 1 due to trigonometric calculations for location of the box. type GoogleCloudVideointelligenceV1NormalizedBoundingPoly struct { // Vertices: Normalized vertices of the bounding polygon. Vertices []*GoogleCloudVideointelligenceV1NormalizedVertex `json:"vertices,omitempty"` @@ -1115,6 +1145,9 @@ func (s *GoogleCloudVideointelligenceV1Track) UnmarshalJSON(data []byte) error { // GoogleCloudVideointelligenceV1VideoAnnotationProgress: Annotation progress // for a single video. type GoogleCloudVideointelligenceV1VideoAnnotationProgress struct { + // ExportStatus: Status of exporting annotation response to user specified + // `output_uri`. Only set if `output_uri` is set in the request. + ExportStatus *GoogleCloudVideointelligenceV1ExportToOutputUriStatus `json:"exportStatus,omitempty"` // Feature: Specifies which feature is being tracked if the request contains // more than one feature. // @@ -1144,13 +1177,13 @@ type GoogleCloudVideointelligenceV1VideoAnnotationProgress struct { StartTime string `json:"startTime,omitempty"` // UpdateTime: Time of the most recent update. UpdateTime string `json:"updateTime,omitempty"` - // ForceSendFields is a list of field names (e.g. "Feature") 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. "ExportStatus") 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. "Feature") to include in API + // NullFields is a list of field names (e.g. "ExportStatus") 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. @@ -1428,7 +1461,7 @@ type GoogleCloudVideointelligenceV1beta2DetectedLandmark struct { // Name: The name of this landmark, for example, left_hand, right_shoulder. Name string `json:"name,omitempty"` // Point: The 2D point of the detected landmark using the normalized image - // coordindate system. The normalized coordinates have the range from 0 to 1. + // coordinate system. The normalized coordinates have the range from 0 to 1. Point *GoogleCloudVideointelligenceV1beta2NormalizedVertex `json:"point,omitempty"` // ForceSendFields is a list of field names (e.g. "Confidence") to // unconditionally include in API requests. By default, fields with empty or @@ -1551,6 +1584,36 @@ func (s GoogleCloudVideointelligenceV1beta2ExplicitContentFrame) MarshalJSON() ( return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudVideointelligenceV1beta2ExportToOutputUriStatus: Status of +// exporting annotation response to user specified `output_uri`. +type GoogleCloudVideointelligenceV1beta2ExportToOutputUriStatus struct { + // State: Output only. State of the `output_uri` export. + // + // Possible values: + // "STATE_UNSPECIFIED" - Default value. + // "SUCCEEDED" - Export succeeded. + // "FAILED" - Export failed. + State string `json:"state,omitempty"` + // Status: Output only. Only set if state is FAILED. + Status *GoogleRpcStatus `json:"status,omitempty"` + // ForceSendFields is a list of field names (e.g. "State") 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. "State") 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 GoogleCloudVideointelligenceV1beta2ExportToOutputUriStatus) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudVideointelligenceV1beta2ExportToOutputUriStatus + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudVideointelligenceV1beta2FaceAnnotation: Deprecated. No effect. type GoogleCloudVideointelligenceV1beta2FaceAnnotation struct { // Frames: All video frames where a face was detected. @@ -1853,7 +1916,7 @@ func (s *GoogleCloudVideointelligenceV1beta2NormalizedBoundingBox) UnmarshalJSON // might look like: 0----1 | | 3----2 When it's clockwise rotated 180 degrees // around the top-left corner it becomes: 2----3 | | 1----0 and the vertex // order will still be (0, 1, 2, 3). Note that values can be less than 0, or -// greater than 1 due to trignometric calculations for location of the box. +// greater than 1 due to trigonometric calculations for location of the box. type GoogleCloudVideointelligenceV1beta2NormalizedBoundingPoly struct { // Vertices: Normalized vertices of the bounding polygon. Vertices []*GoogleCloudVideointelligenceV1beta2NormalizedVertex `json:"vertices,omitempty"` @@ -2278,6 +2341,9 @@ func (s *GoogleCloudVideointelligenceV1beta2Track) UnmarshalJSON(data []byte) er // GoogleCloudVideointelligenceV1beta2VideoAnnotationProgress: Annotation // progress for a single video. type GoogleCloudVideointelligenceV1beta2VideoAnnotationProgress struct { + // ExportStatus: Status of exporting annotation response to user specified + // `output_uri`. Only set if `output_uri` is set in the request. + ExportStatus *GoogleCloudVideointelligenceV1beta2ExportToOutputUriStatus `json:"exportStatus,omitempty"` // Feature: Specifies which feature is being tracked if the request contains // more than one feature. // @@ -2307,13 +2373,13 @@ type GoogleCloudVideointelligenceV1beta2VideoAnnotationProgress struct { StartTime string `json:"startTime,omitempty"` // UpdateTime: Time of the most recent update. UpdateTime string `json:"updateTime,omitempty"` - // ForceSendFields is a list of field names (e.g. "Feature") 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. "ExportStatus") 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. "Feature") to include in API + // NullFields is a list of field names (e.g. "ExportStatus") 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. @@ -2654,7 +2720,7 @@ type GoogleCloudVideointelligenceV1p1beta1DetectedLandmark struct { // Name: The name of this landmark, for example, left_hand, right_shoulder. Name string `json:"name,omitempty"` // Point: The 2D point of the detected landmark using the normalized image - // coordindate system. The normalized coordinates have the range from 0 to 1. + // coordinate system. The normalized coordinates have the range from 0 to 1. Point *GoogleCloudVideointelligenceV1p1beta1NormalizedVertex `json:"point,omitempty"` // ForceSendFields is a list of field names (e.g. "Confidence") to // unconditionally include in API requests. By default, fields with empty or @@ -2801,6 +2867,36 @@ func (s GoogleCloudVideointelligenceV1p1beta1ExplicitContentFrame) MarshalJSON() return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudVideointelligenceV1p1beta1ExportToOutputUriStatus: Status of +// exporting annotation response to user specified `output_uri`. +type GoogleCloudVideointelligenceV1p1beta1ExportToOutputUriStatus struct { + // State: Output only. State of the `output_uri` export. + // + // Possible values: + // "STATE_UNSPECIFIED" - Default value. + // "SUCCEEDED" - Export succeeded. + // "FAILED" - Export failed. + State string `json:"state,omitempty"` + // Status: Output only. Only set if state is FAILED. + Status *GoogleRpcStatus `json:"status,omitempty"` + // ForceSendFields is a list of field names (e.g. "State") 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. "State") 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 GoogleCloudVideointelligenceV1p1beta1ExportToOutputUriStatus) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudVideointelligenceV1p1beta1ExportToOutputUriStatus + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudVideointelligenceV1p1beta1FaceAnnotation: Deprecated. No effect. type GoogleCloudVideointelligenceV1p1beta1FaceAnnotation struct { // Frames: All video frames where a face was detected. @@ -3202,7 +3298,7 @@ func (s *GoogleCloudVideointelligenceV1p1beta1NormalizedBoundingBox) UnmarshalJS // might look like: 0----1 | | 3----2 When it's clockwise rotated 180 degrees // around the top-left corner it becomes: 2----3 | | 1----0 and the vertex // order will still be (0, 1, 2, 3). Note that values can be less than 0, or -// greater than 1 due to trignometric calculations for location of the box. +// greater than 1 due to trigonometric calculations for location of the box. type GoogleCloudVideointelligenceV1p1beta1NormalizedBoundingPoly struct { // Vertices: Normalized vertices of the bounding polygon. Vertices []*GoogleCloudVideointelligenceV1p1beta1NormalizedVertex `json:"vertices,omitempty"` @@ -3832,6 +3928,9 @@ func (s *GoogleCloudVideointelligenceV1p1beta1Track) UnmarshalJSON(data []byte) // GoogleCloudVideointelligenceV1p1beta1VideoAnnotationProgress: Annotation // progress for a single video. type GoogleCloudVideointelligenceV1p1beta1VideoAnnotationProgress struct { + // ExportStatus: Status of exporting annotation response to user specified + // `output_uri`. Only set if `output_uri` is set in the request. + ExportStatus *GoogleCloudVideointelligenceV1p1beta1ExportToOutputUriStatus `json:"exportStatus,omitempty"` // Feature: Specifies which feature is being tracked if the request contains // more than one feature. // @@ -3861,13 +3960,13 @@ type GoogleCloudVideointelligenceV1p1beta1VideoAnnotationProgress struct { StartTime string `json:"startTime,omitempty"` // UpdateTime: Time of the most recent update. UpdateTime string `json:"updateTime,omitempty"` - // ForceSendFields is a list of field names (e.g. "Feature") 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. "ExportStatus") 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. "Feature") to include in API + // NullFields is a list of field names (e.g. "ExportStatus") 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. @@ -4187,7 +4286,7 @@ type GoogleCloudVideointelligenceV1p2beta1DetectedLandmark struct { // Name: The name of this landmark, for example, left_hand, right_shoulder. Name string `json:"name,omitempty"` // Point: The 2D point of the detected landmark using the normalized image - // coordindate system. The normalized coordinates have the range from 0 to 1. + // coordinate system. The normalized coordinates have the range from 0 to 1. Point *GoogleCloudVideointelligenceV1p2beta1NormalizedVertex `json:"point,omitempty"` // ForceSendFields is a list of field names (e.g. "Confidence") to // unconditionally include in API requests. By default, fields with empty or @@ -4310,6 +4409,36 @@ func (s GoogleCloudVideointelligenceV1p2beta1ExplicitContentFrame) MarshalJSON() return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudVideointelligenceV1p2beta1ExportToOutputUriStatus: Status of +// exporting annotation response to user specified `output_uri`. +type GoogleCloudVideointelligenceV1p2beta1ExportToOutputUriStatus struct { + // State: Output only. State of the `output_uri` export. + // + // Possible values: + // "STATE_UNSPECIFIED" - Default value. + // "SUCCEEDED" - Export succeeded. + // "FAILED" - Export failed. + State string `json:"state,omitempty"` + // Status: Output only. Only set if state is FAILED. + Status *GoogleRpcStatus `json:"status,omitempty"` + // ForceSendFields is a list of field names (e.g. "State") 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. "State") 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 GoogleCloudVideointelligenceV1p2beta1ExportToOutputUriStatus) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudVideointelligenceV1p2beta1ExportToOutputUriStatus + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudVideointelligenceV1p2beta1FaceAnnotation: Deprecated. No effect. type GoogleCloudVideointelligenceV1p2beta1FaceAnnotation struct { // Frames: All video frames where a face was detected. @@ -4612,7 +4741,7 @@ func (s *GoogleCloudVideointelligenceV1p2beta1NormalizedBoundingBox) UnmarshalJS // might look like: 0----1 | | 3----2 When it's clockwise rotated 180 degrees // around the top-left corner it becomes: 2----3 | | 1----0 and the vertex // order will still be (0, 1, 2, 3). Note that values can be less than 0, or -// greater than 1 due to trignometric calculations for location of the box. +// greater than 1 due to trigonometric calculations for location of the box. type GoogleCloudVideointelligenceV1p2beta1NormalizedBoundingPoly struct { // Vertices: Normalized vertices of the bounding polygon. Vertices []*GoogleCloudVideointelligenceV1p2beta1NormalizedVertex `json:"vertices,omitempty"` @@ -5037,6 +5166,9 @@ func (s *GoogleCloudVideointelligenceV1p2beta1Track) UnmarshalJSON(data []byte) // GoogleCloudVideointelligenceV1p2beta1VideoAnnotationProgress: Annotation // progress for a single video. type GoogleCloudVideointelligenceV1p2beta1VideoAnnotationProgress struct { + // ExportStatus: Status of exporting annotation response to user specified + // `output_uri`. Only set if `output_uri` is set in the request. + ExportStatus *GoogleCloudVideointelligenceV1p2beta1ExportToOutputUriStatus `json:"exportStatus,omitempty"` // Feature: Specifies which feature is being tracked if the request contains // more than one feature. // @@ -5066,13 +5198,13 @@ type GoogleCloudVideointelligenceV1p2beta1VideoAnnotationProgress struct { StartTime string `json:"startTime,omitempty"` // UpdateTime: Time of the most recent update. UpdateTime string `json:"updateTime,omitempty"` - // ForceSendFields is a list of field names (e.g. "Feature") 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. "ExportStatus") 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. "Feature") to include in API + // NullFields is a list of field names (e.g. "ExportStatus") 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. @@ -5432,7 +5564,7 @@ type GoogleCloudVideointelligenceV1p3beta1DetectedLandmark struct { // Name: The name of this landmark, for example, left_hand, right_shoulder. Name string `json:"name,omitempty"` // Point: The 2D point of the detected landmark using the normalized image - // coordindate system. The normalized coordinates have the range from 0 to 1. + // coordinate system. The normalized coordinates have the range from 0 to 1. Point *GoogleCloudVideointelligenceV1p3beta1NormalizedVertex `json:"point,omitempty"` // ForceSendFields is a list of field names (e.g. "Confidence") to // unconditionally include in API requests. By default, fields with empty or @@ -5555,6 +5687,36 @@ func (s GoogleCloudVideointelligenceV1p3beta1ExplicitContentFrame) MarshalJSON() return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudVideointelligenceV1p3beta1ExportToOutputUriStatus: Status of +// exporting annotation response to user specified `output_uri`. +type GoogleCloudVideointelligenceV1p3beta1ExportToOutputUriStatus struct { + // State: Output only. State of the `output_uri` export. + // + // Possible values: + // "STATE_UNSPECIFIED" - Default value. + // "SUCCEEDED" - Export succeeded. + // "FAILED" - Export failed. + State string `json:"state,omitempty"` + // Status: Output only. Only set if state is FAILED. + Status *GoogleRpcStatus `json:"status,omitempty"` + // ForceSendFields is a list of field names (e.g. "State") 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. "State") 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 GoogleCloudVideointelligenceV1p3beta1ExportToOutputUriStatus) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudVideointelligenceV1p3beta1ExportToOutputUriStatus + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudVideointelligenceV1p3beta1FaceAnnotation: Deprecated. No effect. type GoogleCloudVideointelligenceV1p3beta1FaceAnnotation struct { // Frames: All video frames where a face was detected. @@ -5857,7 +6019,7 @@ func (s *GoogleCloudVideointelligenceV1p3beta1NormalizedBoundingBox) UnmarshalJS // might look like: 0----1 | | 3----2 When it's clockwise rotated 180 degrees // around the top-left corner it becomes: 2----3 | | 1----0 and the vertex // order will still be (0, 1, 2, 3). Note that values can be less than 0, or -// greater than 1 due to trignometric calculations for location of the box. +// greater than 1 due to trigonometric calculations for location of the box. type GoogleCloudVideointelligenceV1p3beta1NormalizedBoundingPoly struct { // Vertices: Normalized vertices of the bounding polygon. Vertices []*GoogleCloudVideointelligenceV1p3beta1NormalizedVertex `json:"vertices,omitempty"` @@ -6388,6 +6550,9 @@ func (s *GoogleCloudVideointelligenceV1p3beta1Track) UnmarshalJSON(data []byte) // GoogleCloudVideointelligenceV1p3beta1VideoAnnotationProgress: Annotation // progress for a single video. type GoogleCloudVideointelligenceV1p3beta1VideoAnnotationProgress struct { + // ExportStatus: Status of exporting annotation response to user specified + // `output_uri`. Only set if `output_uri` is set in the request. + ExportStatus *GoogleCloudVideointelligenceV1p3beta1ExportToOutputUriStatus `json:"exportStatus,omitempty"` // Feature: Specifies which feature is being tracked if the request contains // more than one feature. // @@ -6418,13 +6583,13 @@ type GoogleCloudVideointelligenceV1p3beta1VideoAnnotationProgress struct { StartTime string `json:"startTime,omitempty"` // UpdateTime: Time of the most recent update. UpdateTime string `json:"updateTime,omitempty"` - // ForceSendFields is a list of field names (e.g. "Feature") 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. "ExportStatus") 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. "Feature") to include in API + // NullFields is a list of field names (e.g. "ExportStatus") 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/videointelligence/v1p2beta1/videointelligence-api.json b/videointelligence/v1p2beta1/videointelligence-api.json index b81a96336ce..6690e9d1762 100644 --- a/videointelligence/v1p2beta1/videointelligence-api.json +++ b/videointelligence/v1p2beta1/videointelligence-api.json @@ -128,7 +128,7 @@ } } }, - "revision": "20250710", + "revision": "20250724", "rootUrl": "https://videointelligence.googleapis.com/", "schemas": { "GoogleCloudVideointelligenceV1_AnnotateVideoProgress": { @@ -194,7 +194,7 @@ }, "point": { "$ref": "GoogleCloudVideointelligenceV1_NormalizedVertex", - "description": "The 2D point of the detected landmark using the normalized image coordindate system. The normalized coordinates have the range from 0 to 1." + "description": "The 2D point of the detected landmark using the normalized image coordinate system. The normalized coordinates have the range from 0 to 1." } }, "type": "object" @@ -268,6 +268,33 @@ }, "type": "object" }, + "GoogleCloudVideointelligenceV1_ExportToOutputUriStatus": { + "description": "Status of exporting annotation response to user specified `output_uri`.", + "id": "GoogleCloudVideointelligenceV1_ExportToOutputUriStatus", + "properties": { + "state": { + "description": "Output only. State of the `output_uri` export.", + "enum": [ + "STATE_UNSPECIFIED", + "SUCCEEDED", + "FAILED" + ], + "enumDescriptions": [ + "Default value.", + "Export succeeded.", + "Export failed." + ], + "readOnly": true, + "type": "string" + }, + "status": { + "$ref": "GoogleRpc_Status", + "description": "Output only. Only set if state is FAILED.", + "readOnly": true + } + }, + "type": "object" + }, "GoogleCloudVideointelligenceV1_FaceAnnotation": { "deprecated": true, "description": "Deprecated. No effect.", @@ -471,7 +498,7 @@ "type": "object" }, "GoogleCloudVideointelligenceV1_NormalizedBoundingPoly": { - "description": "Normalized bounding polygon for text (that might not be aligned with axis). Contains list of the corner points in clockwise order starting from top-left corner. For example, for a rectangular bounding box: When the text is horizontal it might look like: 0----1 | | 3----2 When it's clockwise rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertex order will still be (0, 1, 2, 3). Note that values can be less than 0, or greater than 1 due to trignometric calculations for location of the box.", + "description": "Normalized bounding polygon for text (that might not be aligned with axis). Contains list of the corner points in clockwise order starting from top-left corner. For example, for a rectangular bounding box: When the text is horizontal it might look like: 0----1 | | 3----2 When it's clockwise rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertex order will still be (0, 1, 2, 3). Note that values can be less than 0, or greater than 1 due to trigonometric calculations for location of the box.", "id": "GoogleCloudVideointelligenceV1_NormalizedBoundingPoly", "properties": { "vertices": { @@ -740,6 +767,10 @@ "description": "Annotation progress for a single video.", "id": "GoogleCloudVideointelligenceV1_VideoAnnotationProgress", "properties": { + "exportStatus": { + "$ref": "GoogleCloudVideointelligenceV1_ExportToOutputUriStatus", + "description": "Status of exporting annotation response to user specified `output_uri`. Only set if `output_uri` is set in the request." + }, "feature": { "description": "Specifies which feature is being tracked if the request contains more than one feature.", "enum": [ @@ -1022,7 +1053,7 @@ }, "point": { "$ref": "GoogleCloudVideointelligenceV1beta2_NormalizedVertex", - "description": "The 2D point of the detected landmark using the normalized image coordindate system. The normalized coordinates have the range from 0 to 1." + "description": "The 2D point of the detected landmark using the normalized image coordinate system. The normalized coordinates have the range from 0 to 1." } }, "type": "object" @@ -1096,6 +1127,33 @@ }, "type": "object" }, + "GoogleCloudVideointelligenceV1beta2_ExportToOutputUriStatus": { + "description": "Status of exporting annotation response to user specified `output_uri`.", + "id": "GoogleCloudVideointelligenceV1beta2_ExportToOutputUriStatus", + "properties": { + "state": { + "description": "Output only. State of the `output_uri` export.", + "enum": [ + "STATE_UNSPECIFIED", + "SUCCEEDED", + "FAILED" + ], + "enumDescriptions": [ + "Default value.", + "Export succeeded.", + "Export failed." + ], + "readOnly": true, + "type": "string" + }, + "status": { + "$ref": "GoogleRpc_Status", + "description": "Output only. Only set if state is FAILED.", + "readOnly": true + } + }, + "type": "object" + }, "GoogleCloudVideointelligenceV1beta2_FaceAnnotation": { "deprecated": true, "description": "Deprecated. No effect.", @@ -1299,7 +1357,7 @@ "type": "object" }, "GoogleCloudVideointelligenceV1beta2_NormalizedBoundingPoly": { - "description": "Normalized bounding polygon for text (that might not be aligned with axis). Contains list of the corner points in clockwise order starting from top-left corner. For example, for a rectangular bounding box: When the text is horizontal it might look like: 0----1 | | 3----2 When it's clockwise rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertex order will still be (0, 1, 2, 3). Note that values can be less than 0, or greater than 1 due to trignometric calculations for location of the box.", + "description": "Normalized bounding polygon for text (that might not be aligned with axis). Contains list of the corner points in clockwise order starting from top-left corner. For example, for a rectangular bounding box: When the text is horizontal it might look like: 0----1 | | 3----2 When it's clockwise rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertex order will still be (0, 1, 2, 3). Note that values can be less than 0, or greater than 1 due to trigonometric calculations for location of the box.", "id": "GoogleCloudVideointelligenceV1beta2_NormalizedBoundingPoly", "properties": { "vertices": { @@ -1568,6 +1626,10 @@ "description": "Annotation progress for a single video.", "id": "GoogleCloudVideointelligenceV1beta2_VideoAnnotationProgress", "properties": { + "exportStatus": { + "$ref": "GoogleCloudVideointelligenceV1beta2_ExportToOutputUriStatus", + "description": "Status of exporting annotation response to user specified `output_uri`. Only set if `output_uri` is set in the request." + }, "feature": { "description": "Specifies which feature is being tracked if the request contains more than one feature.", "enum": [ @@ -1850,7 +1912,7 @@ }, "point": { "$ref": "GoogleCloudVideointelligenceV1p1beta1_NormalizedVertex", - "description": "The 2D point of the detected landmark using the normalized image coordindate system. The normalized coordinates have the range from 0 to 1." + "description": "The 2D point of the detected landmark using the normalized image coordinate system. The normalized coordinates have the range from 0 to 1." } }, "type": "object" @@ -1924,6 +1986,33 @@ }, "type": "object" }, + "GoogleCloudVideointelligenceV1p1beta1_ExportToOutputUriStatus": { + "description": "Status of exporting annotation response to user specified `output_uri`.", + "id": "GoogleCloudVideointelligenceV1p1beta1_ExportToOutputUriStatus", + "properties": { + "state": { + "description": "Output only. State of the `output_uri` export.", + "enum": [ + "STATE_UNSPECIFIED", + "SUCCEEDED", + "FAILED" + ], + "enumDescriptions": [ + "Default value.", + "Export succeeded.", + "Export failed." + ], + "readOnly": true, + "type": "string" + }, + "status": { + "$ref": "GoogleRpc_Status", + "description": "Output only. Only set if state is FAILED.", + "readOnly": true + } + }, + "type": "object" + }, "GoogleCloudVideointelligenceV1p1beta1_FaceAnnotation": { "deprecated": true, "description": "Deprecated. No effect.", @@ -2127,7 +2216,7 @@ "type": "object" }, "GoogleCloudVideointelligenceV1p1beta1_NormalizedBoundingPoly": { - "description": "Normalized bounding polygon for text (that might not be aligned with axis). Contains list of the corner points in clockwise order starting from top-left corner. For example, for a rectangular bounding box: When the text is horizontal it might look like: 0----1 | | 3----2 When it's clockwise rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertex order will still be (0, 1, 2, 3). Note that values can be less than 0, or greater than 1 due to trignometric calculations for location of the box.", + "description": "Normalized bounding polygon for text (that might not be aligned with axis). Contains list of the corner points in clockwise order starting from top-left corner. For example, for a rectangular bounding box: When the text is horizontal it might look like: 0----1 | | 3----2 When it's clockwise rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertex order will still be (0, 1, 2, 3). Note that values can be less than 0, or greater than 1 due to trigonometric calculations for location of the box.", "id": "GoogleCloudVideointelligenceV1p1beta1_NormalizedBoundingPoly", "properties": { "vertices": { @@ -2396,6 +2485,10 @@ "description": "Annotation progress for a single video.", "id": "GoogleCloudVideointelligenceV1p1beta1_VideoAnnotationProgress", "properties": { + "exportStatus": { + "$ref": "GoogleCloudVideointelligenceV1p1beta1_ExportToOutputUriStatus", + "description": "Status of exporting annotation response to user specified `output_uri`. Only set if `output_uri` is set in the request." + }, "feature": { "description": "Specifies which feature is being tracked if the request contains more than one feature.", "enum": [ @@ -2737,7 +2830,7 @@ }, "point": { "$ref": "GoogleCloudVideointelligenceV1p2beta1_NormalizedVertex", - "description": "The 2D point of the detected landmark using the normalized image coordindate system. The normalized coordinates have the range from 0 to 1." + "description": "The 2D point of the detected landmark using the normalized image coordinate system. The normalized coordinates have the range from 0 to 1." } }, "type": "object" @@ -2822,6 +2915,33 @@ }, "type": "object" }, + "GoogleCloudVideointelligenceV1p2beta1_ExportToOutputUriStatus": { + "description": "Status of exporting annotation response to user specified `output_uri`.", + "id": "GoogleCloudVideointelligenceV1p2beta1_ExportToOutputUriStatus", + "properties": { + "state": { + "description": "Output only. State of the `output_uri` export.", + "enum": [ + "STATE_UNSPECIFIED", + "SUCCEEDED", + "FAILED" + ], + "enumDescriptions": [ + "Default value.", + "Export succeeded.", + "Export failed." + ], + "readOnly": true, + "type": "string" + }, + "status": { + "$ref": "GoogleRpc_Status", + "description": "Output only. Only set if state is FAILED.", + "readOnly": true + } + }, + "type": "object" + }, "GoogleCloudVideointelligenceV1p2beta1_FaceAnnotation": { "deprecated": true, "description": "Deprecated. No effect.", @@ -3085,7 +3205,7 @@ "type": "object" }, "GoogleCloudVideointelligenceV1p2beta1_NormalizedBoundingPoly": { - "description": "Normalized bounding polygon for text (that might not be aligned with axis). Contains list of the corner points in clockwise order starting from top-left corner. For example, for a rectangular bounding box: When the text is horizontal it might look like: 0----1 | | 3----2 When it's clockwise rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertex order will still be (0, 1, 2, 3). Note that values can be less than 0, or greater than 1 due to trignometric calculations for location of the box.", + "description": "Normalized bounding polygon for text (that might not be aligned with axis). Contains list of the corner points in clockwise order starting from top-left corner. For example, for a rectangular bounding box: When the text is horizontal it might look like: 0----1 | | 3----2 When it's clockwise rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertex order will still be (0, 1, 2, 3). Note that values can be less than 0, or greater than 1 due to trigonometric calculations for location of the box.", "id": "GoogleCloudVideointelligenceV1p2beta1_NormalizedBoundingPoly", "properties": { "vertices": { @@ -3479,6 +3599,10 @@ "description": "Annotation progress for a single video.", "id": "GoogleCloudVideointelligenceV1p2beta1_VideoAnnotationProgress", "properties": { + "exportStatus": { + "$ref": "GoogleCloudVideointelligenceV1p2beta1_ExportToOutputUriStatus", + "description": "Status of exporting annotation response to user specified `output_uri`. Only set if `output_uri` is set in the request." + }, "feature": { "description": "Specifies which feature is being tracked if the request contains more than one feature.", "enum": [ @@ -3862,7 +3986,7 @@ }, "point": { "$ref": "GoogleCloudVideointelligenceV1p3beta1_NormalizedVertex", - "description": "The 2D point of the detected landmark using the normalized image coordindate system. The normalized coordinates have the range from 0 to 1." + "description": "The 2D point of the detected landmark using the normalized image coordinate system. The normalized coordinates have the range from 0 to 1." } }, "type": "object" @@ -3936,6 +4060,33 @@ }, "type": "object" }, + "GoogleCloudVideointelligenceV1p3beta1_ExportToOutputUriStatus": { + "description": "Status of exporting annotation response to user specified `output_uri`.", + "id": "GoogleCloudVideointelligenceV1p3beta1_ExportToOutputUriStatus", + "properties": { + "state": { + "description": "Output only. State of the `output_uri` export.", + "enum": [ + "STATE_UNSPECIFIED", + "SUCCEEDED", + "FAILED" + ], + "enumDescriptions": [ + "Default value.", + "Export succeeded.", + "Export failed." + ], + "readOnly": true, + "type": "string" + }, + "status": { + "$ref": "GoogleRpc_Status", + "description": "Output only. Only set if state is FAILED.", + "readOnly": true + } + }, + "type": "object" + }, "GoogleCloudVideointelligenceV1p3beta1_FaceAnnotation": { "deprecated": true, "description": "Deprecated. No effect.", @@ -4139,7 +4290,7 @@ "type": "object" }, "GoogleCloudVideointelligenceV1p3beta1_NormalizedBoundingPoly": { - "description": "Normalized bounding polygon for text (that might not be aligned with axis). Contains list of the corner points in clockwise order starting from top-left corner. For example, for a rectangular bounding box: When the text is horizontal it might look like: 0----1 | | 3----2 When it's clockwise rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertex order will still be (0, 1, 2, 3). Note that values can be less than 0, or greater than 1 due to trignometric calculations for location of the box.", + "description": "Normalized bounding polygon for text (that might not be aligned with axis). Contains list of the corner points in clockwise order starting from top-left corner. For example, for a rectangular bounding box: When the text is horizontal it might look like: 0----1 | | 3----2 When it's clockwise rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertex order will still be (0, 1, 2, 3). Note that values can be less than 0, or greater than 1 due to trigonometric calculations for location of the box.", "id": "GoogleCloudVideointelligenceV1p3beta1_NormalizedBoundingPoly", "properties": { "vertices": { @@ -4480,6 +4631,10 @@ "description": "Annotation progress for a single video.", "id": "GoogleCloudVideointelligenceV1p3beta1_VideoAnnotationProgress", "properties": { + "exportStatus": { + "$ref": "GoogleCloudVideointelligenceV1p3beta1_ExportToOutputUriStatus", + "description": "Status of exporting annotation response to user specified `output_uri`. Only set if `output_uri` is set in the request." + }, "feature": { "description": "Specifies which feature is being tracked if the request contains more than one feature.", "enum": [ diff --git a/videointelligence/v1p2beta1/videointelligence-gen.go b/videointelligence/v1p2beta1/videointelligence-gen.go index 606ed2ed96f..6c40c84ef5b 100644 --- a/videointelligence/v1p2beta1/videointelligence-gen.go +++ b/videointelligence/v1p2beta1/videointelligence-gen.go @@ -267,7 +267,7 @@ type GoogleCloudVideointelligenceV1DetectedLandmark struct { // Name: The name of this landmark, for example, left_hand, right_shoulder. Name string `json:"name,omitempty"` // Point: The 2D point of the detected landmark using the normalized image - // coordindate system. The normalized coordinates have the range from 0 to 1. + // coordinate system. The normalized coordinates have the range from 0 to 1. Point *GoogleCloudVideointelligenceV1NormalizedVertex `json:"point,omitempty"` // ForceSendFields is a list of field names (e.g. "Confidence") to // unconditionally include in API requests. By default, fields with empty or @@ -388,6 +388,36 @@ func (s GoogleCloudVideointelligenceV1ExplicitContentFrame) MarshalJSON() ([]byt return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudVideointelligenceV1ExportToOutputUriStatus: Status of exporting +// annotation response to user specified `output_uri`. +type GoogleCloudVideointelligenceV1ExportToOutputUriStatus struct { + // State: Output only. State of the `output_uri` export. + // + // Possible values: + // "STATE_UNSPECIFIED" - Default value. + // "SUCCEEDED" - Export succeeded. + // "FAILED" - Export failed. + State string `json:"state,omitempty"` + // Status: Output only. Only set if state is FAILED. + Status *GoogleRpcStatus `json:"status,omitempty"` + // ForceSendFields is a list of field names (e.g. "State") 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. "State") 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 GoogleCloudVideointelligenceV1ExportToOutputUriStatus) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudVideointelligenceV1ExportToOutputUriStatus + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudVideointelligenceV1FaceAnnotation: Deprecated. No effect. type GoogleCloudVideointelligenceV1FaceAnnotation struct { // Frames: All video frames where a face was detected. @@ -690,7 +720,7 @@ func (s *GoogleCloudVideointelligenceV1NormalizedBoundingBox) UnmarshalJSON(data // like: 0----1 | | 3----2 When it's clockwise rotated 180 degrees around the // top-left corner it becomes: 2----3 | | 1----0 and the vertex order will // still be (0, 1, 2, 3). Note that values can be less than 0, or greater than -// 1 due to trignometric calculations for location of the box. +// 1 due to trigonometric calculations for location of the box. type GoogleCloudVideointelligenceV1NormalizedBoundingPoly struct { // Vertices: Normalized vertices of the bounding polygon. Vertices []*GoogleCloudVideointelligenceV1NormalizedVertex `json:"vertices,omitempty"` @@ -1115,6 +1145,9 @@ func (s *GoogleCloudVideointelligenceV1Track) UnmarshalJSON(data []byte) error { // GoogleCloudVideointelligenceV1VideoAnnotationProgress: Annotation progress // for a single video. type GoogleCloudVideointelligenceV1VideoAnnotationProgress struct { + // ExportStatus: Status of exporting annotation response to user specified + // `output_uri`. Only set if `output_uri` is set in the request. + ExportStatus *GoogleCloudVideointelligenceV1ExportToOutputUriStatus `json:"exportStatus,omitempty"` // Feature: Specifies which feature is being tracked if the request contains // more than one feature. // @@ -1144,13 +1177,13 @@ type GoogleCloudVideointelligenceV1VideoAnnotationProgress struct { StartTime string `json:"startTime,omitempty"` // UpdateTime: Time of the most recent update. UpdateTime string `json:"updateTime,omitempty"` - // ForceSendFields is a list of field names (e.g. "Feature") 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. "ExportStatus") 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. "Feature") to include in API + // NullFields is a list of field names (e.g. "ExportStatus") 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. @@ -1428,7 +1461,7 @@ type GoogleCloudVideointelligenceV1beta2DetectedLandmark struct { // Name: The name of this landmark, for example, left_hand, right_shoulder. Name string `json:"name,omitempty"` // Point: The 2D point of the detected landmark using the normalized image - // coordindate system. The normalized coordinates have the range from 0 to 1. + // coordinate system. The normalized coordinates have the range from 0 to 1. Point *GoogleCloudVideointelligenceV1beta2NormalizedVertex `json:"point,omitempty"` // ForceSendFields is a list of field names (e.g. "Confidence") to // unconditionally include in API requests. By default, fields with empty or @@ -1551,6 +1584,36 @@ func (s GoogleCloudVideointelligenceV1beta2ExplicitContentFrame) MarshalJSON() ( return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudVideointelligenceV1beta2ExportToOutputUriStatus: Status of +// exporting annotation response to user specified `output_uri`. +type GoogleCloudVideointelligenceV1beta2ExportToOutputUriStatus struct { + // State: Output only. State of the `output_uri` export. + // + // Possible values: + // "STATE_UNSPECIFIED" - Default value. + // "SUCCEEDED" - Export succeeded. + // "FAILED" - Export failed. + State string `json:"state,omitempty"` + // Status: Output only. Only set if state is FAILED. + Status *GoogleRpcStatus `json:"status,omitempty"` + // ForceSendFields is a list of field names (e.g. "State") 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. "State") 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 GoogleCloudVideointelligenceV1beta2ExportToOutputUriStatus) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudVideointelligenceV1beta2ExportToOutputUriStatus + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudVideointelligenceV1beta2FaceAnnotation: Deprecated. No effect. type GoogleCloudVideointelligenceV1beta2FaceAnnotation struct { // Frames: All video frames where a face was detected. @@ -1853,7 +1916,7 @@ func (s *GoogleCloudVideointelligenceV1beta2NormalizedBoundingBox) UnmarshalJSON // might look like: 0----1 | | 3----2 When it's clockwise rotated 180 degrees // around the top-left corner it becomes: 2----3 | | 1----0 and the vertex // order will still be (0, 1, 2, 3). Note that values can be less than 0, or -// greater than 1 due to trignometric calculations for location of the box. +// greater than 1 due to trigonometric calculations for location of the box. type GoogleCloudVideointelligenceV1beta2NormalizedBoundingPoly struct { // Vertices: Normalized vertices of the bounding polygon. Vertices []*GoogleCloudVideointelligenceV1beta2NormalizedVertex `json:"vertices,omitempty"` @@ -2278,6 +2341,9 @@ func (s *GoogleCloudVideointelligenceV1beta2Track) UnmarshalJSON(data []byte) er // GoogleCloudVideointelligenceV1beta2VideoAnnotationProgress: Annotation // progress for a single video. type GoogleCloudVideointelligenceV1beta2VideoAnnotationProgress struct { + // ExportStatus: Status of exporting annotation response to user specified + // `output_uri`. Only set if `output_uri` is set in the request. + ExportStatus *GoogleCloudVideointelligenceV1beta2ExportToOutputUriStatus `json:"exportStatus,omitempty"` // Feature: Specifies which feature is being tracked if the request contains // more than one feature. // @@ -2307,13 +2373,13 @@ type GoogleCloudVideointelligenceV1beta2VideoAnnotationProgress struct { StartTime string `json:"startTime,omitempty"` // UpdateTime: Time of the most recent update. UpdateTime string `json:"updateTime,omitempty"` - // ForceSendFields is a list of field names (e.g. "Feature") 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. "ExportStatus") 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. "Feature") to include in API + // NullFields is a list of field names (e.g. "ExportStatus") 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. @@ -2591,7 +2657,7 @@ type GoogleCloudVideointelligenceV1p1beta1DetectedLandmark struct { // Name: The name of this landmark, for example, left_hand, right_shoulder. Name string `json:"name,omitempty"` // Point: The 2D point of the detected landmark using the normalized image - // coordindate system. The normalized coordinates have the range from 0 to 1. + // coordinate system. The normalized coordinates have the range from 0 to 1. Point *GoogleCloudVideointelligenceV1p1beta1NormalizedVertex `json:"point,omitempty"` // ForceSendFields is a list of field names (e.g. "Confidence") to // unconditionally include in API requests. By default, fields with empty or @@ -2714,6 +2780,36 @@ func (s GoogleCloudVideointelligenceV1p1beta1ExplicitContentFrame) MarshalJSON() return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudVideointelligenceV1p1beta1ExportToOutputUriStatus: Status of +// exporting annotation response to user specified `output_uri`. +type GoogleCloudVideointelligenceV1p1beta1ExportToOutputUriStatus struct { + // State: Output only. State of the `output_uri` export. + // + // Possible values: + // "STATE_UNSPECIFIED" - Default value. + // "SUCCEEDED" - Export succeeded. + // "FAILED" - Export failed. + State string `json:"state,omitempty"` + // Status: Output only. Only set if state is FAILED. + Status *GoogleRpcStatus `json:"status,omitempty"` + // ForceSendFields is a list of field names (e.g. "State") 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. "State") 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 GoogleCloudVideointelligenceV1p1beta1ExportToOutputUriStatus) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudVideointelligenceV1p1beta1ExportToOutputUriStatus + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudVideointelligenceV1p1beta1FaceAnnotation: Deprecated. No effect. type GoogleCloudVideointelligenceV1p1beta1FaceAnnotation struct { // Frames: All video frames where a face was detected. @@ -3016,7 +3112,7 @@ func (s *GoogleCloudVideointelligenceV1p1beta1NormalizedBoundingBox) UnmarshalJS // might look like: 0----1 | | 3----2 When it's clockwise rotated 180 degrees // around the top-left corner it becomes: 2----3 | | 1----0 and the vertex // order will still be (0, 1, 2, 3). Note that values can be less than 0, or -// greater than 1 due to trignometric calculations for location of the box. +// greater than 1 due to trigonometric calculations for location of the box. type GoogleCloudVideointelligenceV1p1beta1NormalizedBoundingPoly struct { // Vertices: Normalized vertices of the bounding polygon. Vertices []*GoogleCloudVideointelligenceV1p1beta1NormalizedVertex `json:"vertices,omitempty"` @@ -3441,6 +3537,9 @@ func (s *GoogleCloudVideointelligenceV1p1beta1Track) UnmarshalJSON(data []byte) // GoogleCloudVideointelligenceV1p1beta1VideoAnnotationProgress: Annotation // progress for a single video. type GoogleCloudVideointelligenceV1p1beta1VideoAnnotationProgress struct { + // ExportStatus: Status of exporting annotation response to user specified + // `output_uri`. Only set if `output_uri` is set in the request. + ExportStatus *GoogleCloudVideointelligenceV1p1beta1ExportToOutputUriStatus `json:"exportStatus,omitempty"` // Feature: Specifies which feature is being tracked if the request contains // more than one feature. // @@ -3470,13 +3569,13 @@ type GoogleCloudVideointelligenceV1p1beta1VideoAnnotationProgress struct { StartTime string `json:"startTime,omitempty"` // UpdateTime: Time of the most recent update. UpdateTime string `json:"updateTime,omitempty"` - // ForceSendFields is a list of field names (e.g. "Feature") 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. "ExportStatus") 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. "Feature") to include in API + // NullFields is a list of field names (e.g. "ExportStatus") 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. @@ -3817,7 +3916,7 @@ type GoogleCloudVideointelligenceV1p2beta1DetectedLandmark struct { // Name: The name of this landmark, for example, left_hand, right_shoulder. Name string `json:"name,omitempty"` // Point: The 2D point of the detected landmark using the normalized image - // coordindate system. The normalized coordinates have the range from 0 to 1. + // coordinate system. The normalized coordinates have the range from 0 to 1. Point *GoogleCloudVideointelligenceV1p2beta1NormalizedVertex `json:"point,omitempty"` // ForceSendFields is a list of field names (e.g. "Confidence") to // unconditionally include in API requests. By default, fields with empty or @@ -3964,6 +4063,36 @@ func (s GoogleCloudVideointelligenceV1p2beta1ExplicitContentFrame) MarshalJSON() return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudVideointelligenceV1p2beta1ExportToOutputUriStatus: Status of +// exporting annotation response to user specified `output_uri`. +type GoogleCloudVideointelligenceV1p2beta1ExportToOutputUriStatus struct { + // State: Output only. State of the `output_uri` export. + // + // Possible values: + // "STATE_UNSPECIFIED" - Default value. + // "SUCCEEDED" - Export succeeded. + // "FAILED" - Export failed. + State string `json:"state,omitempty"` + // Status: Output only. Only set if state is FAILED. + Status *GoogleRpcStatus `json:"status,omitempty"` + // ForceSendFields is a list of field names (e.g. "State") 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. "State") 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 GoogleCloudVideointelligenceV1p2beta1ExportToOutputUriStatus) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudVideointelligenceV1p2beta1ExportToOutputUriStatus + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudVideointelligenceV1p2beta1FaceAnnotation: Deprecated. No effect. type GoogleCloudVideointelligenceV1p2beta1FaceAnnotation struct { // Frames: All video frames where a face was detected. @@ -4365,7 +4494,7 @@ func (s *GoogleCloudVideointelligenceV1p2beta1NormalizedBoundingBox) UnmarshalJS // might look like: 0----1 | | 3----2 When it's clockwise rotated 180 degrees // around the top-left corner it becomes: 2----3 | | 1----0 and the vertex // order will still be (0, 1, 2, 3). Note that values can be less than 0, or -// greater than 1 due to trignometric calculations for location of the box. +// greater than 1 due to trigonometric calculations for location of the box. type GoogleCloudVideointelligenceV1p2beta1NormalizedBoundingPoly struct { // Vertices: Normalized vertices of the bounding polygon. Vertices []*GoogleCloudVideointelligenceV1p2beta1NormalizedVertex `json:"vertices,omitempty"` @@ -4995,6 +5124,9 @@ func (s *GoogleCloudVideointelligenceV1p2beta1Track) UnmarshalJSON(data []byte) // GoogleCloudVideointelligenceV1p2beta1VideoAnnotationProgress: Annotation // progress for a single video. type GoogleCloudVideointelligenceV1p2beta1VideoAnnotationProgress struct { + // ExportStatus: Status of exporting annotation response to user specified + // `output_uri`. Only set if `output_uri` is set in the request. + ExportStatus *GoogleCloudVideointelligenceV1p2beta1ExportToOutputUriStatus `json:"exportStatus,omitempty"` // Feature: Specifies which feature is being tracked if the request contains // more than one feature. // @@ -5024,13 +5156,13 @@ type GoogleCloudVideointelligenceV1p2beta1VideoAnnotationProgress struct { StartTime string `json:"startTime,omitempty"` // UpdateTime: Time of the most recent update. UpdateTime string `json:"updateTime,omitempty"` - // ForceSendFields is a list of field names (e.g. "Feature") 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. "ExportStatus") 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. "Feature") to include in API + // NullFields is a list of field names (e.g. "ExportStatus") 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. @@ -5432,7 +5564,7 @@ type GoogleCloudVideointelligenceV1p3beta1DetectedLandmark struct { // Name: The name of this landmark, for example, left_hand, right_shoulder. Name string `json:"name,omitempty"` // Point: The 2D point of the detected landmark using the normalized image - // coordindate system. The normalized coordinates have the range from 0 to 1. + // coordinate system. The normalized coordinates have the range from 0 to 1. Point *GoogleCloudVideointelligenceV1p3beta1NormalizedVertex `json:"point,omitempty"` // ForceSendFields is a list of field names (e.g. "Confidence") to // unconditionally include in API requests. By default, fields with empty or @@ -5555,6 +5687,36 @@ func (s GoogleCloudVideointelligenceV1p3beta1ExplicitContentFrame) MarshalJSON() return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudVideointelligenceV1p3beta1ExportToOutputUriStatus: Status of +// exporting annotation response to user specified `output_uri`. +type GoogleCloudVideointelligenceV1p3beta1ExportToOutputUriStatus struct { + // State: Output only. State of the `output_uri` export. + // + // Possible values: + // "STATE_UNSPECIFIED" - Default value. + // "SUCCEEDED" - Export succeeded. + // "FAILED" - Export failed. + State string `json:"state,omitempty"` + // Status: Output only. Only set if state is FAILED. + Status *GoogleRpcStatus `json:"status,omitempty"` + // ForceSendFields is a list of field names (e.g. "State") 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. "State") 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 GoogleCloudVideointelligenceV1p3beta1ExportToOutputUriStatus) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudVideointelligenceV1p3beta1ExportToOutputUriStatus + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudVideointelligenceV1p3beta1FaceAnnotation: Deprecated. No effect. type GoogleCloudVideointelligenceV1p3beta1FaceAnnotation struct { // Frames: All video frames where a face was detected. @@ -5857,7 +6019,7 @@ func (s *GoogleCloudVideointelligenceV1p3beta1NormalizedBoundingBox) UnmarshalJS // might look like: 0----1 | | 3----2 When it's clockwise rotated 180 degrees // around the top-left corner it becomes: 2----3 | | 1----0 and the vertex // order will still be (0, 1, 2, 3). Note that values can be less than 0, or -// greater than 1 due to trignometric calculations for location of the box. +// greater than 1 due to trigonometric calculations for location of the box. type GoogleCloudVideointelligenceV1p3beta1NormalizedBoundingPoly struct { // Vertices: Normalized vertices of the bounding polygon. Vertices []*GoogleCloudVideointelligenceV1p3beta1NormalizedVertex `json:"vertices,omitempty"` @@ -6388,6 +6550,9 @@ func (s *GoogleCloudVideointelligenceV1p3beta1Track) UnmarshalJSON(data []byte) // GoogleCloudVideointelligenceV1p3beta1VideoAnnotationProgress: Annotation // progress for a single video. type GoogleCloudVideointelligenceV1p3beta1VideoAnnotationProgress struct { + // ExportStatus: Status of exporting annotation response to user specified + // `output_uri`. Only set if `output_uri` is set in the request. + ExportStatus *GoogleCloudVideointelligenceV1p3beta1ExportToOutputUriStatus `json:"exportStatus,omitempty"` // Feature: Specifies which feature is being tracked if the request contains // more than one feature. // @@ -6418,13 +6583,13 @@ type GoogleCloudVideointelligenceV1p3beta1VideoAnnotationProgress struct { StartTime string `json:"startTime,omitempty"` // UpdateTime: Time of the most recent update. UpdateTime string `json:"updateTime,omitempty"` - // ForceSendFields is a list of field names (e.g. "Feature") 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. "ExportStatus") 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. "Feature") to include in API + // NullFields is a list of field names (e.g. "ExportStatus") 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/videointelligence/v1p3beta1/videointelligence-api.json b/videointelligence/v1p3beta1/videointelligence-api.json index eae838e41ea..d02f486f67f 100644 --- a/videointelligence/v1p3beta1/videointelligence-api.json +++ b/videointelligence/v1p3beta1/videointelligence-api.json @@ -128,7 +128,7 @@ } } }, - "revision": "20250710", + "revision": "20250724", "rootUrl": "https://videointelligence.googleapis.com/", "schemas": { "GoogleCloudVideointelligenceV1_AnnotateVideoProgress": { @@ -194,7 +194,7 @@ }, "point": { "$ref": "GoogleCloudVideointelligenceV1_NormalizedVertex", - "description": "The 2D point of the detected landmark using the normalized image coordindate system. The normalized coordinates have the range from 0 to 1." + "description": "The 2D point of the detected landmark using the normalized image coordinate system. The normalized coordinates have the range from 0 to 1." } }, "type": "object" @@ -268,6 +268,33 @@ }, "type": "object" }, + "GoogleCloudVideointelligenceV1_ExportToOutputUriStatus": { + "description": "Status of exporting annotation response to user specified `output_uri`.", + "id": "GoogleCloudVideointelligenceV1_ExportToOutputUriStatus", + "properties": { + "state": { + "description": "Output only. State of the `output_uri` export.", + "enum": [ + "STATE_UNSPECIFIED", + "SUCCEEDED", + "FAILED" + ], + "enumDescriptions": [ + "Default value.", + "Export succeeded.", + "Export failed." + ], + "readOnly": true, + "type": "string" + }, + "status": { + "$ref": "GoogleRpc_Status", + "description": "Output only. Only set if state is FAILED.", + "readOnly": true + } + }, + "type": "object" + }, "GoogleCloudVideointelligenceV1_FaceAnnotation": { "deprecated": true, "description": "Deprecated. No effect.", @@ -471,7 +498,7 @@ "type": "object" }, "GoogleCloudVideointelligenceV1_NormalizedBoundingPoly": { - "description": "Normalized bounding polygon for text (that might not be aligned with axis). Contains list of the corner points in clockwise order starting from top-left corner. For example, for a rectangular bounding box: When the text is horizontal it might look like: 0----1 | | 3----2 When it's clockwise rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertex order will still be (0, 1, 2, 3). Note that values can be less than 0, or greater than 1 due to trignometric calculations for location of the box.", + "description": "Normalized bounding polygon for text (that might not be aligned with axis). Contains list of the corner points in clockwise order starting from top-left corner. For example, for a rectangular bounding box: When the text is horizontal it might look like: 0----1 | | 3----2 When it's clockwise rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertex order will still be (0, 1, 2, 3). Note that values can be less than 0, or greater than 1 due to trigonometric calculations for location of the box.", "id": "GoogleCloudVideointelligenceV1_NormalizedBoundingPoly", "properties": { "vertices": { @@ -740,6 +767,10 @@ "description": "Annotation progress for a single video.", "id": "GoogleCloudVideointelligenceV1_VideoAnnotationProgress", "properties": { + "exportStatus": { + "$ref": "GoogleCloudVideointelligenceV1_ExportToOutputUriStatus", + "description": "Status of exporting annotation response to user specified `output_uri`. Only set if `output_uri` is set in the request." + }, "feature": { "description": "Specifies which feature is being tracked if the request contains more than one feature.", "enum": [ @@ -1022,7 +1053,7 @@ }, "point": { "$ref": "GoogleCloudVideointelligenceV1beta2_NormalizedVertex", - "description": "The 2D point of the detected landmark using the normalized image coordindate system. The normalized coordinates have the range from 0 to 1." + "description": "The 2D point of the detected landmark using the normalized image coordinate system. The normalized coordinates have the range from 0 to 1." } }, "type": "object" @@ -1096,6 +1127,33 @@ }, "type": "object" }, + "GoogleCloudVideointelligenceV1beta2_ExportToOutputUriStatus": { + "description": "Status of exporting annotation response to user specified `output_uri`.", + "id": "GoogleCloudVideointelligenceV1beta2_ExportToOutputUriStatus", + "properties": { + "state": { + "description": "Output only. State of the `output_uri` export.", + "enum": [ + "STATE_UNSPECIFIED", + "SUCCEEDED", + "FAILED" + ], + "enumDescriptions": [ + "Default value.", + "Export succeeded.", + "Export failed." + ], + "readOnly": true, + "type": "string" + }, + "status": { + "$ref": "GoogleRpc_Status", + "description": "Output only. Only set if state is FAILED.", + "readOnly": true + } + }, + "type": "object" + }, "GoogleCloudVideointelligenceV1beta2_FaceAnnotation": { "deprecated": true, "description": "Deprecated. No effect.", @@ -1299,7 +1357,7 @@ "type": "object" }, "GoogleCloudVideointelligenceV1beta2_NormalizedBoundingPoly": { - "description": "Normalized bounding polygon for text (that might not be aligned with axis). Contains list of the corner points in clockwise order starting from top-left corner. For example, for a rectangular bounding box: When the text is horizontal it might look like: 0----1 | | 3----2 When it's clockwise rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertex order will still be (0, 1, 2, 3). Note that values can be less than 0, or greater than 1 due to trignometric calculations for location of the box.", + "description": "Normalized bounding polygon for text (that might not be aligned with axis). Contains list of the corner points in clockwise order starting from top-left corner. For example, for a rectangular bounding box: When the text is horizontal it might look like: 0----1 | | 3----2 When it's clockwise rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertex order will still be (0, 1, 2, 3). Note that values can be less than 0, or greater than 1 due to trigonometric calculations for location of the box.", "id": "GoogleCloudVideointelligenceV1beta2_NormalizedBoundingPoly", "properties": { "vertices": { @@ -1568,6 +1626,10 @@ "description": "Annotation progress for a single video.", "id": "GoogleCloudVideointelligenceV1beta2_VideoAnnotationProgress", "properties": { + "exportStatus": { + "$ref": "GoogleCloudVideointelligenceV1beta2_ExportToOutputUriStatus", + "description": "Status of exporting annotation response to user specified `output_uri`. Only set if `output_uri` is set in the request." + }, "feature": { "description": "Specifies which feature is being tracked if the request contains more than one feature.", "enum": [ @@ -1850,7 +1912,7 @@ }, "point": { "$ref": "GoogleCloudVideointelligenceV1p1beta1_NormalizedVertex", - "description": "The 2D point of the detected landmark using the normalized image coordindate system. The normalized coordinates have the range from 0 to 1." + "description": "The 2D point of the detected landmark using the normalized image coordinate system. The normalized coordinates have the range from 0 to 1." } }, "type": "object" @@ -1924,6 +1986,33 @@ }, "type": "object" }, + "GoogleCloudVideointelligenceV1p1beta1_ExportToOutputUriStatus": { + "description": "Status of exporting annotation response to user specified `output_uri`.", + "id": "GoogleCloudVideointelligenceV1p1beta1_ExportToOutputUriStatus", + "properties": { + "state": { + "description": "Output only. State of the `output_uri` export.", + "enum": [ + "STATE_UNSPECIFIED", + "SUCCEEDED", + "FAILED" + ], + "enumDescriptions": [ + "Default value.", + "Export succeeded.", + "Export failed." + ], + "readOnly": true, + "type": "string" + }, + "status": { + "$ref": "GoogleRpc_Status", + "description": "Output only. Only set if state is FAILED.", + "readOnly": true + } + }, + "type": "object" + }, "GoogleCloudVideointelligenceV1p1beta1_FaceAnnotation": { "deprecated": true, "description": "Deprecated. No effect.", @@ -2127,7 +2216,7 @@ "type": "object" }, "GoogleCloudVideointelligenceV1p1beta1_NormalizedBoundingPoly": { - "description": "Normalized bounding polygon for text (that might not be aligned with axis). Contains list of the corner points in clockwise order starting from top-left corner. For example, for a rectangular bounding box: When the text is horizontal it might look like: 0----1 | | 3----2 When it's clockwise rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertex order will still be (0, 1, 2, 3). Note that values can be less than 0, or greater than 1 due to trignometric calculations for location of the box.", + "description": "Normalized bounding polygon for text (that might not be aligned with axis). Contains list of the corner points in clockwise order starting from top-left corner. For example, for a rectangular bounding box: When the text is horizontal it might look like: 0----1 | | 3----2 When it's clockwise rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertex order will still be (0, 1, 2, 3). Note that values can be less than 0, or greater than 1 due to trigonometric calculations for location of the box.", "id": "GoogleCloudVideointelligenceV1p1beta1_NormalizedBoundingPoly", "properties": { "vertices": { @@ -2396,6 +2485,10 @@ "description": "Annotation progress for a single video.", "id": "GoogleCloudVideointelligenceV1p1beta1_VideoAnnotationProgress", "properties": { + "exportStatus": { + "$ref": "GoogleCloudVideointelligenceV1p1beta1_ExportToOutputUriStatus", + "description": "Status of exporting annotation response to user specified `output_uri`. Only set if `output_uri` is set in the request." + }, "feature": { "description": "Specifies which feature is being tracked if the request contains more than one feature.", "enum": [ @@ -2678,7 +2771,7 @@ }, "point": { "$ref": "GoogleCloudVideointelligenceV1p2beta1_NormalizedVertex", - "description": "The 2D point of the detected landmark using the normalized image coordindate system. The normalized coordinates have the range from 0 to 1." + "description": "The 2D point of the detected landmark using the normalized image coordinate system. The normalized coordinates have the range from 0 to 1." } }, "type": "object" @@ -2752,6 +2845,33 @@ }, "type": "object" }, + "GoogleCloudVideointelligenceV1p2beta1_ExportToOutputUriStatus": { + "description": "Status of exporting annotation response to user specified `output_uri`.", + "id": "GoogleCloudVideointelligenceV1p2beta1_ExportToOutputUriStatus", + "properties": { + "state": { + "description": "Output only. State of the `output_uri` export.", + "enum": [ + "STATE_UNSPECIFIED", + "SUCCEEDED", + "FAILED" + ], + "enumDescriptions": [ + "Default value.", + "Export succeeded.", + "Export failed." + ], + "readOnly": true, + "type": "string" + }, + "status": { + "$ref": "GoogleRpc_Status", + "description": "Output only. Only set if state is FAILED.", + "readOnly": true + } + }, + "type": "object" + }, "GoogleCloudVideointelligenceV1p2beta1_FaceAnnotation": { "deprecated": true, "description": "Deprecated. No effect.", @@ -2955,7 +3075,7 @@ "type": "object" }, "GoogleCloudVideointelligenceV1p2beta1_NormalizedBoundingPoly": { - "description": "Normalized bounding polygon for text (that might not be aligned with axis). Contains list of the corner points in clockwise order starting from top-left corner. For example, for a rectangular bounding box: When the text is horizontal it might look like: 0----1 | | 3----2 When it's clockwise rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertex order will still be (0, 1, 2, 3). Note that values can be less than 0, or greater than 1 due to trignometric calculations for location of the box.", + "description": "Normalized bounding polygon for text (that might not be aligned with axis). Contains list of the corner points in clockwise order starting from top-left corner. For example, for a rectangular bounding box: When the text is horizontal it might look like: 0----1 | | 3----2 When it's clockwise rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertex order will still be (0, 1, 2, 3). Note that values can be less than 0, or greater than 1 due to trigonometric calculations for location of the box.", "id": "GoogleCloudVideointelligenceV1p2beta1_NormalizedBoundingPoly", "properties": { "vertices": { @@ -3224,6 +3344,10 @@ "description": "Annotation progress for a single video.", "id": "GoogleCloudVideointelligenceV1p2beta1_VideoAnnotationProgress", "properties": { + "exportStatus": { + "$ref": "GoogleCloudVideointelligenceV1p2beta1_ExportToOutputUriStatus", + "description": "Status of exporting annotation response to user specified `output_uri`. Only set if `output_uri` is set in the request." + }, "feature": { "description": "Specifies which feature is being tracked if the request contains more than one feature.", "enum": [ @@ -3622,7 +3746,7 @@ }, "point": { "$ref": "GoogleCloudVideointelligenceV1p3beta1_NormalizedVertex", - "description": "The 2D point of the detected landmark using the normalized image coordindate system. The normalized coordinates have the range from 0 to 1." + "description": "The 2D point of the detected landmark using the normalized image coordinate system. The normalized coordinates have the range from 0 to 1." } }, "type": "object" @@ -3707,6 +3831,33 @@ }, "type": "object" }, + "GoogleCloudVideointelligenceV1p3beta1_ExportToOutputUriStatus": { + "description": "Status of exporting annotation response to user specified `output_uri`.", + "id": "GoogleCloudVideointelligenceV1p3beta1_ExportToOutputUriStatus", + "properties": { + "state": { + "description": "Output only. State of the `output_uri` export.", + "enum": [ + "STATE_UNSPECIFIED", + "SUCCEEDED", + "FAILED" + ], + "enumDescriptions": [ + "Default value.", + "Export succeeded.", + "Export failed." + ], + "readOnly": true, + "type": "string" + }, + "status": { + "$ref": "GoogleRpc_Status", + "description": "Output only. Only set if state is FAILED.", + "readOnly": true + } + }, + "type": "object" + }, "GoogleCloudVideointelligenceV1p3beta1_FaceAnnotation": { "deprecated": true, "description": "Deprecated. No effect.", @@ -3970,7 +4121,7 @@ "type": "object" }, "GoogleCloudVideointelligenceV1p3beta1_NormalizedBoundingPoly": { - "description": "Normalized bounding polygon for text (that might not be aligned with axis). Contains list of the corner points in clockwise order starting from top-left corner. For example, for a rectangular bounding box: When the text is horizontal it might look like: 0----1 | | 3----2 When it's clockwise rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertex order will still be (0, 1, 2, 3). Note that values can be less than 0, or greater than 1 due to trignometric calculations for location of the box.", + "description": "Normalized bounding polygon for text (that might not be aligned with axis). Contains list of the corner points in clockwise order starting from top-left corner. For example, for a rectangular bounding box: When the text is horizontal it might look like: 0----1 | | 3----2 When it's clockwise rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertex order will still be (0, 1, 2, 3). Note that values can be less than 0, or greater than 1 due to trigonometric calculations for location of the box.", "id": "GoogleCloudVideointelligenceV1p3beta1_NormalizedBoundingPoly", "properties": { "vertices": { @@ -4436,6 +4587,10 @@ "description": "Annotation progress for a single video.", "id": "GoogleCloudVideointelligenceV1p3beta1_VideoAnnotationProgress", "properties": { + "exportStatus": { + "$ref": "GoogleCloudVideointelligenceV1p3beta1_ExportToOutputUriStatus", + "description": "Status of exporting annotation response to user specified `output_uri`. Only set if `output_uri` is set in the request." + }, "feature": { "description": "Specifies which feature is being tracked if the request contains more than one feature.", "enum": [ diff --git a/videointelligence/v1p3beta1/videointelligence-gen.go b/videointelligence/v1p3beta1/videointelligence-gen.go index f861d70a13a..23902ad13f4 100644 --- a/videointelligence/v1p3beta1/videointelligence-gen.go +++ b/videointelligence/v1p3beta1/videointelligence-gen.go @@ -267,7 +267,7 @@ type GoogleCloudVideointelligenceV1DetectedLandmark struct { // Name: The name of this landmark, for example, left_hand, right_shoulder. Name string `json:"name,omitempty"` // Point: The 2D point of the detected landmark using the normalized image - // coordindate system. The normalized coordinates have the range from 0 to 1. + // coordinate system. The normalized coordinates have the range from 0 to 1. Point *GoogleCloudVideointelligenceV1NormalizedVertex `json:"point,omitempty"` // ForceSendFields is a list of field names (e.g. "Confidence") to // unconditionally include in API requests. By default, fields with empty or @@ -388,6 +388,36 @@ func (s GoogleCloudVideointelligenceV1ExplicitContentFrame) MarshalJSON() ([]byt return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudVideointelligenceV1ExportToOutputUriStatus: Status of exporting +// annotation response to user specified `output_uri`. +type GoogleCloudVideointelligenceV1ExportToOutputUriStatus struct { + // State: Output only. State of the `output_uri` export. + // + // Possible values: + // "STATE_UNSPECIFIED" - Default value. + // "SUCCEEDED" - Export succeeded. + // "FAILED" - Export failed. + State string `json:"state,omitempty"` + // Status: Output only. Only set if state is FAILED. + Status *GoogleRpcStatus `json:"status,omitempty"` + // ForceSendFields is a list of field names (e.g. "State") 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. "State") 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 GoogleCloudVideointelligenceV1ExportToOutputUriStatus) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudVideointelligenceV1ExportToOutputUriStatus + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudVideointelligenceV1FaceAnnotation: Deprecated. No effect. type GoogleCloudVideointelligenceV1FaceAnnotation struct { // Frames: All video frames where a face was detected. @@ -690,7 +720,7 @@ func (s *GoogleCloudVideointelligenceV1NormalizedBoundingBox) UnmarshalJSON(data // like: 0----1 | | 3----2 When it's clockwise rotated 180 degrees around the // top-left corner it becomes: 2----3 | | 1----0 and the vertex order will // still be (0, 1, 2, 3). Note that values can be less than 0, or greater than -// 1 due to trignometric calculations for location of the box. +// 1 due to trigonometric calculations for location of the box. type GoogleCloudVideointelligenceV1NormalizedBoundingPoly struct { // Vertices: Normalized vertices of the bounding polygon. Vertices []*GoogleCloudVideointelligenceV1NormalizedVertex `json:"vertices,omitempty"` @@ -1115,6 +1145,9 @@ func (s *GoogleCloudVideointelligenceV1Track) UnmarshalJSON(data []byte) error { // GoogleCloudVideointelligenceV1VideoAnnotationProgress: Annotation progress // for a single video. type GoogleCloudVideointelligenceV1VideoAnnotationProgress struct { + // ExportStatus: Status of exporting annotation response to user specified + // `output_uri`. Only set if `output_uri` is set in the request. + ExportStatus *GoogleCloudVideointelligenceV1ExportToOutputUriStatus `json:"exportStatus,omitempty"` // Feature: Specifies which feature is being tracked if the request contains // more than one feature. // @@ -1144,13 +1177,13 @@ type GoogleCloudVideointelligenceV1VideoAnnotationProgress struct { StartTime string `json:"startTime,omitempty"` // UpdateTime: Time of the most recent update. UpdateTime string `json:"updateTime,omitempty"` - // ForceSendFields is a list of field names (e.g. "Feature") 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. "ExportStatus") 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. "Feature") to include in API + // NullFields is a list of field names (e.g. "ExportStatus") 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. @@ -1428,7 +1461,7 @@ type GoogleCloudVideointelligenceV1beta2DetectedLandmark struct { // Name: The name of this landmark, for example, left_hand, right_shoulder. Name string `json:"name,omitempty"` // Point: The 2D point of the detected landmark using the normalized image - // coordindate system. The normalized coordinates have the range from 0 to 1. + // coordinate system. The normalized coordinates have the range from 0 to 1. Point *GoogleCloudVideointelligenceV1beta2NormalizedVertex `json:"point,omitempty"` // ForceSendFields is a list of field names (e.g. "Confidence") to // unconditionally include in API requests. By default, fields with empty or @@ -1551,6 +1584,36 @@ func (s GoogleCloudVideointelligenceV1beta2ExplicitContentFrame) MarshalJSON() ( return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudVideointelligenceV1beta2ExportToOutputUriStatus: Status of +// exporting annotation response to user specified `output_uri`. +type GoogleCloudVideointelligenceV1beta2ExportToOutputUriStatus struct { + // State: Output only. State of the `output_uri` export. + // + // Possible values: + // "STATE_UNSPECIFIED" - Default value. + // "SUCCEEDED" - Export succeeded. + // "FAILED" - Export failed. + State string `json:"state,omitempty"` + // Status: Output only. Only set if state is FAILED. + Status *GoogleRpcStatus `json:"status,omitempty"` + // ForceSendFields is a list of field names (e.g. "State") 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. "State") 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 GoogleCloudVideointelligenceV1beta2ExportToOutputUriStatus) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudVideointelligenceV1beta2ExportToOutputUriStatus + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudVideointelligenceV1beta2FaceAnnotation: Deprecated. No effect. type GoogleCloudVideointelligenceV1beta2FaceAnnotation struct { // Frames: All video frames where a face was detected. @@ -1853,7 +1916,7 @@ func (s *GoogleCloudVideointelligenceV1beta2NormalizedBoundingBox) UnmarshalJSON // might look like: 0----1 | | 3----2 When it's clockwise rotated 180 degrees // around the top-left corner it becomes: 2----3 | | 1----0 and the vertex // order will still be (0, 1, 2, 3). Note that values can be less than 0, or -// greater than 1 due to trignometric calculations for location of the box. +// greater than 1 due to trigonometric calculations for location of the box. type GoogleCloudVideointelligenceV1beta2NormalizedBoundingPoly struct { // Vertices: Normalized vertices of the bounding polygon. Vertices []*GoogleCloudVideointelligenceV1beta2NormalizedVertex `json:"vertices,omitempty"` @@ -2278,6 +2341,9 @@ func (s *GoogleCloudVideointelligenceV1beta2Track) UnmarshalJSON(data []byte) er // GoogleCloudVideointelligenceV1beta2VideoAnnotationProgress: Annotation // progress for a single video. type GoogleCloudVideointelligenceV1beta2VideoAnnotationProgress struct { + // ExportStatus: Status of exporting annotation response to user specified + // `output_uri`. Only set if `output_uri` is set in the request. + ExportStatus *GoogleCloudVideointelligenceV1beta2ExportToOutputUriStatus `json:"exportStatus,omitempty"` // Feature: Specifies which feature is being tracked if the request contains // more than one feature. // @@ -2307,13 +2373,13 @@ type GoogleCloudVideointelligenceV1beta2VideoAnnotationProgress struct { StartTime string `json:"startTime,omitempty"` // UpdateTime: Time of the most recent update. UpdateTime string `json:"updateTime,omitempty"` - // ForceSendFields is a list of field names (e.g. "Feature") 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. "ExportStatus") 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. "Feature") to include in API + // NullFields is a list of field names (e.g. "ExportStatus") 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. @@ -2591,7 +2657,7 @@ type GoogleCloudVideointelligenceV1p1beta1DetectedLandmark struct { // Name: The name of this landmark, for example, left_hand, right_shoulder. Name string `json:"name,omitempty"` // Point: The 2D point of the detected landmark using the normalized image - // coordindate system. The normalized coordinates have the range from 0 to 1. + // coordinate system. The normalized coordinates have the range from 0 to 1. Point *GoogleCloudVideointelligenceV1p1beta1NormalizedVertex `json:"point,omitempty"` // ForceSendFields is a list of field names (e.g. "Confidence") to // unconditionally include in API requests. By default, fields with empty or @@ -2714,6 +2780,36 @@ func (s GoogleCloudVideointelligenceV1p1beta1ExplicitContentFrame) MarshalJSON() return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudVideointelligenceV1p1beta1ExportToOutputUriStatus: Status of +// exporting annotation response to user specified `output_uri`. +type GoogleCloudVideointelligenceV1p1beta1ExportToOutputUriStatus struct { + // State: Output only. State of the `output_uri` export. + // + // Possible values: + // "STATE_UNSPECIFIED" - Default value. + // "SUCCEEDED" - Export succeeded. + // "FAILED" - Export failed. + State string `json:"state,omitempty"` + // Status: Output only. Only set if state is FAILED. + Status *GoogleRpcStatus `json:"status,omitempty"` + // ForceSendFields is a list of field names (e.g. "State") 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. "State") 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 GoogleCloudVideointelligenceV1p1beta1ExportToOutputUriStatus) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudVideointelligenceV1p1beta1ExportToOutputUriStatus + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudVideointelligenceV1p1beta1FaceAnnotation: Deprecated. No effect. type GoogleCloudVideointelligenceV1p1beta1FaceAnnotation struct { // Frames: All video frames where a face was detected. @@ -3016,7 +3112,7 @@ func (s *GoogleCloudVideointelligenceV1p1beta1NormalizedBoundingBox) UnmarshalJS // might look like: 0----1 | | 3----2 When it's clockwise rotated 180 degrees // around the top-left corner it becomes: 2----3 | | 1----0 and the vertex // order will still be (0, 1, 2, 3). Note that values can be less than 0, or -// greater than 1 due to trignometric calculations for location of the box. +// greater than 1 due to trigonometric calculations for location of the box. type GoogleCloudVideointelligenceV1p1beta1NormalizedBoundingPoly struct { // Vertices: Normalized vertices of the bounding polygon. Vertices []*GoogleCloudVideointelligenceV1p1beta1NormalizedVertex `json:"vertices,omitempty"` @@ -3441,6 +3537,9 @@ func (s *GoogleCloudVideointelligenceV1p1beta1Track) UnmarshalJSON(data []byte) // GoogleCloudVideointelligenceV1p1beta1VideoAnnotationProgress: Annotation // progress for a single video. type GoogleCloudVideointelligenceV1p1beta1VideoAnnotationProgress struct { + // ExportStatus: Status of exporting annotation response to user specified + // `output_uri`. Only set if `output_uri` is set in the request. + ExportStatus *GoogleCloudVideointelligenceV1p1beta1ExportToOutputUriStatus `json:"exportStatus,omitempty"` // Feature: Specifies which feature is being tracked if the request contains // more than one feature. // @@ -3470,13 +3569,13 @@ type GoogleCloudVideointelligenceV1p1beta1VideoAnnotationProgress struct { StartTime string `json:"startTime,omitempty"` // UpdateTime: Time of the most recent update. UpdateTime string `json:"updateTime,omitempty"` - // ForceSendFields is a list of field names (e.g. "Feature") 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. "ExportStatus") 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. "Feature") to include in API + // NullFields is a list of field names (e.g. "ExportStatus") 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. @@ -3754,7 +3853,7 @@ type GoogleCloudVideointelligenceV1p2beta1DetectedLandmark struct { // Name: The name of this landmark, for example, left_hand, right_shoulder. Name string `json:"name,omitempty"` // Point: The 2D point of the detected landmark using the normalized image - // coordindate system. The normalized coordinates have the range from 0 to 1. + // coordinate system. The normalized coordinates have the range from 0 to 1. Point *GoogleCloudVideointelligenceV1p2beta1NormalizedVertex `json:"point,omitempty"` // ForceSendFields is a list of field names (e.g. "Confidence") to // unconditionally include in API requests. By default, fields with empty or @@ -3877,6 +3976,36 @@ func (s GoogleCloudVideointelligenceV1p2beta1ExplicitContentFrame) MarshalJSON() return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudVideointelligenceV1p2beta1ExportToOutputUriStatus: Status of +// exporting annotation response to user specified `output_uri`. +type GoogleCloudVideointelligenceV1p2beta1ExportToOutputUriStatus struct { + // State: Output only. State of the `output_uri` export. + // + // Possible values: + // "STATE_UNSPECIFIED" - Default value. + // "SUCCEEDED" - Export succeeded. + // "FAILED" - Export failed. + State string `json:"state,omitempty"` + // Status: Output only. Only set if state is FAILED. + Status *GoogleRpcStatus `json:"status,omitempty"` + // ForceSendFields is a list of field names (e.g. "State") 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. "State") 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 GoogleCloudVideointelligenceV1p2beta1ExportToOutputUriStatus) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudVideointelligenceV1p2beta1ExportToOutputUriStatus + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudVideointelligenceV1p2beta1FaceAnnotation: Deprecated. No effect. type GoogleCloudVideointelligenceV1p2beta1FaceAnnotation struct { // Frames: All video frames where a face was detected. @@ -4179,7 +4308,7 @@ func (s *GoogleCloudVideointelligenceV1p2beta1NormalizedBoundingBox) UnmarshalJS // might look like: 0----1 | | 3----2 When it's clockwise rotated 180 degrees // around the top-left corner it becomes: 2----3 | | 1----0 and the vertex // order will still be (0, 1, 2, 3). Note that values can be less than 0, or -// greater than 1 due to trignometric calculations for location of the box. +// greater than 1 due to trigonometric calculations for location of the box. type GoogleCloudVideointelligenceV1p2beta1NormalizedBoundingPoly struct { // Vertices: Normalized vertices of the bounding polygon. Vertices []*GoogleCloudVideointelligenceV1p2beta1NormalizedVertex `json:"vertices,omitempty"` @@ -4604,6 +4733,9 @@ func (s *GoogleCloudVideointelligenceV1p2beta1Track) UnmarshalJSON(data []byte) // GoogleCloudVideointelligenceV1p2beta1VideoAnnotationProgress: Annotation // progress for a single video. type GoogleCloudVideointelligenceV1p2beta1VideoAnnotationProgress struct { + // ExportStatus: Status of exporting annotation response to user specified + // `output_uri`. Only set if `output_uri` is set in the request. + ExportStatus *GoogleCloudVideointelligenceV1p2beta1ExportToOutputUriStatus `json:"exportStatus,omitempty"` // Feature: Specifies which feature is being tracked if the request contains // more than one feature. // @@ -4633,13 +4765,13 @@ type GoogleCloudVideointelligenceV1p2beta1VideoAnnotationProgress struct { StartTime string `json:"startTime,omitempty"` // UpdateTime: Time of the most recent update. UpdateTime string `json:"updateTime,omitempty"` - // ForceSendFields is a list of field names (e.g. "Feature") 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. "ExportStatus") 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. "Feature") to include in API + // NullFields is a list of field names (e.g. "ExportStatus") 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. @@ -5063,7 +5195,7 @@ type GoogleCloudVideointelligenceV1p3beta1DetectedLandmark struct { // Name: The name of this landmark, for example, left_hand, right_shoulder. Name string `json:"name,omitempty"` // Point: The 2D point of the detected landmark using the normalized image - // coordindate system. The normalized coordinates have the range from 0 to 1. + // coordinate system. The normalized coordinates have the range from 0 to 1. Point *GoogleCloudVideointelligenceV1p3beta1NormalizedVertex `json:"point,omitempty"` // ForceSendFields is a list of field names (e.g. "Confidence") to // unconditionally include in API requests. By default, fields with empty or @@ -5210,6 +5342,36 @@ func (s GoogleCloudVideointelligenceV1p3beta1ExplicitContentFrame) MarshalJSON() return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudVideointelligenceV1p3beta1ExportToOutputUriStatus: Status of +// exporting annotation response to user specified `output_uri`. +type GoogleCloudVideointelligenceV1p3beta1ExportToOutputUriStatus struct { + // State: Output only. State of the `output_uri` export. + // + // Possible values: + // "STATE_UNSPECIFIED" - Default value. + // "SUCCEEDED" - Export succeeded. + // "FAILED" - Export failed. + State string `json:"state,omitempty"` + // Status: Output only. Only set if state is FAILED. + Status *GoogleRpcStatus `json:"status,omitempty"` + // ForceSendFields is a list of field names (e.g. "State") 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. "State") 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 GoogleCloudVideointelligenceV1p3beta1ExportToOutputUriStatus) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudVideointelligenceV1p3beta1ExportToOutputUriStatus + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudVideointelligenceV1p3beta1FaceAnnotation: Deprecated. No effect. type GoogleCloudVideointelligenceV1p3beta1FaceAnnotation struct { // Frames: All video frames where a face was detected. @@ -5611,7 +5773,7 @@ func (s *GoogleCloudVideointelligenceV1p3beta1NormalizedBoundingBox) UnmarshalJS // might look like: 0----1 | | 3----2 When it's clockwise rotated 180 degrees // around the top-left corner it becomes: 2----3 | | 1----0 and the vertex // order will still be (0, 1, 2, 3). Note that values can be less than 0, or -// greater than 1 due to trignometric calculations for location of the box. +// greater than 1 due to trigonometric calculations for location of the box. type GoogleCloudVideointelligenceV1p3beta1NormalizedBoundingPoly struct { // Vertices: Normalized vertices of the bounding polygon. Vertices []*GoogleCloudVideointelligenceV1p3beta1NormalizedVertex `json:"vertices,omitempty"` @@ -6347,6 +6509,9 @@ func (s *GoogleCloudVideointelligenceV1p3beta1Track) UnmarshalJSON(data []byte) // GoogleCloudVideointelligenceV1p3beta1VideoAnnotationProgress: Annotation // progress for a single video. type GoogleCloudVideointelligenceV1p3beta1VideoAnnotationProgress struct { + // ExportStatus: Status of exporting annotation response to user specified + // `output_uri`. Only set if `output_uri` is set in the request. + ExportStatus *GoogleCloudVideointelligenceV1p3beta1ExportToOutputUriStatus `json:"exportStatus,omitempty"` // Feature: Specifies which feature is being tracked if the request contains // more than one feature. // @@ -6377,13 +6542,13 @@ type GoogleCloudVideointelligenceV1p3beta1VideoAnnotationProgress struct { StartTime string `json:"startTime,omitempty"` // UpdateTime: Time of the most recent update. UpdateTime string `json:"updateTime,omitempty"` - // ForceSendFields is a list of field names (e.g. "Feature") 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. "ExportStatus") 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. "Feature") to include in API + // NullFields is a list of field names (e.g. "ExportStatus") 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. From 214eb4ea568f09bb4b874216e1b4084acb93de49 Mon Sep 17 00:00:00 2001 From: Yoshi Automation Bot Date: Mon, 28 Jul 2025 00:36:26 -0700 Subject: [PATCH 06/10] feat(all): auto-regenerate discovery clients (#3249) --- alloydb/v1alpha/alloydb-api.json | 153 ++++++++++++++++-- alloydb/v1alpha/alloydb-gen.go | 137 +++++++++++++++- alloydb/v1beta/alloydb-api.json | 153 ++++++++++++++++-- alloydb/v1beta/alloydb-gen.go | 137 +++++++++++++++- batch/v1/batch-api.json | 20 ++- batch/v1/batch-gen.go | 4 + .../v1alpha1/migrationcenter-api.json | 6 +- .../v1alpha1/migrationcenter-gen.go | 2 +- 8 files changed, 571 insertions(+), 41 deletions(-) diff --git a/alloydb/v1alpha/alloydb-api.json b/alloydb/v1alpha/alloydb-api.json index 32815b4fd3f..188027eb0a4 100644 --- a/alloydb/v1alpha/alloydb-api.json +++ b/alloydb/v1alpha/alloydb-api.json @@ -1622,7 +1622,7 @@ } } }, - "revision": "20250612", + "revision": "20250723", "rootUrl": "https://alloydb.googleapis.com/", "schemas": { "AuthorizedNetwork": { @@ -4065,6 +4065,33 @@ }, "type": "object" }, + "StageSchedule": { + "description": "Timing information for the stage execution.", + "id": "StageSchedule", + "properties": { + "actualEndTime": { + "description": "Actual end time of the stage. Set only if the stage has completed.", + "format": "google-datetime", + "type": "string" + }, + "actualStartTime": { + "description": "Actual start time of the stage. Set only if the stage has started.", + "format": "google-datetime", + "type": "string" + }, + "estimatedEndTime": { + "description": "When the stage is expected to end. Set only if the stage has not completed yet.", + "format": "google-datetime", + "type": "string" + }, + "estimatedStartTime": { + "description": "When the stage is expected to start. Set only if the stage has not started yet.", + "format": "google-datetime", + "type": "string" + } + }, + "type": "object" + }, "StageStatus": { "description": "Status of an upgrade stage.", "id": "StageStatus", @@ -4073,6 +4100,11 @@ "$ref": "ReadPoolInstancesUpgradeStageStatus", "description": "Read pool instances upgrade metadata." }, + "schedule": { + "$ref": "StageSchedule", + "description": "Output only. Timing information for the stage execution.", + "readOnly": true + }, "stage": { "description": "Upgrade stage.", "enum": [ @@ -4236,6 +4268,17 @@ }, "type": "object" }, + "StorageDatabasecenterPartnerapiV1mainBackupDRConfiguration": { + "description": "BackupDRConfiguration to capture the backup and disaster recovery details of database resource.", + "id": "StorageDatabasecenterPartnerapiV1mainBackupDRConfiguration", + "properties": { + "backupdrManaged": { + "description": "Indicates if the resource is managed by BackupDR.", + "type": "boolean" + } + }, + "type": "object" + }, "StorageDatabasecenterPartnerapiV1mainBackupRun": { "description": "A backup run.", "id": "StorageDatabasecenterPartnerapiV1mainBackupRun", @@ -4286,6 +4329,50 @@ }, "type": "object" }, + "StorageDatabasecenterPartnerapiV1mainConfigBasedSignalData": { + "description": "Config based signal data. This is used to send signals to Condor which are based on the DB level configurations. These will be used to send signals for self managed databases.", + "id": "StorageDatabasecenterPartnerapiV1mainConfigBasedSignalData", + "properties": { + "fullResourceName": { + "description": "Required. Full Resource name of the source resource.", + "type": "string" + }, + "lastRefreshTime": { + "description": "Required. Last time signal was refreshed", + "format": "google-datetime", + "type": "string" + }, + "resourceId": { + "$ref": "StorageDatabasecenterPartnerapiV1mainDatabaseResourceId", + "description": "Database resource id." + }, + "signalBoolValue": { + "description": "Signal data for boolean signals.", + "type": "boolean" + }, + "signalType": { + "description": "Required. Signal type of the signal", + "enum": [ + "SIGNAL_TYPE_UNSPECIFIED", + "SIGNAL_TYPE_OUTDATED_MINOR_VERSION", + "SIGNAL_TYPE_DATABASE_AUDITING_DISABLED", + "SIGNAL_TYPE_NO_ROOT_PASSWORD", + "SIGNAL_TYPE_EXPOSED_TO_PUBLIC_ACCESS", + "SIGNAL_TYPE_UNENCRYPTED_CONNECTIONS" + ], + "enumDescriptions": [ + "Unspecified signal type.", + "Outdated Minor Version", + "Represents database auditing is disabled.", + "Represents if a database has a password configured for the root account or not.", + "Represents if a resource is exposed to public access.", + "Represents if a resources requires all incoming connections to use SSL or not." + ], + "type": "string" + } + }, + "type": "object" + }, "StorageDatabasecenterPartnerapiV1mainCustomMetadataData": { "description": "Any custom metadata associated with the resource. e.g. A spanner instance can have multiple databases with its own unique metadata. Information for these individual databases can be captured in custom metadata data", "id": "StorageDatabasecenterPartnerapiV1mainCustomMetadataData", @@ -4301,9 +4388,13 @@ "type": "object" }, "StorageDatabasecenterPartnerapiV1mainDatabaseResourceFeed": { - "description": "DatabaseResourceFeed is the top level proto to be used to ingest different database resource level events into Condor platform. Next ID: 8", + "description": "DatabaseResourceFeed is the top level proto to be used to ingest different database resource level events into Condor platform. Next ID: 9", "id": "StorageDatabasecenterPartnerapiV1mainDatabaseResourceFeed", "properties": { + "configBasedSignalData": { + "$ref": "StorageDatabasecenterPartnerapiV1mainConfigBasedSignalData", + "description": "Config based signal data is used to ingest signals that are generated based on the configuration of the database resource." + }, "feedTimestamp": { "description": "Required. Timestamp when feed is generated.", "format": "google-datetime", @@ -4316,14 +4407,16 @@ "RESOURCE_METADATA", "OBSERVABILITY_DATA", "SECURITY_FINDING_DATA", - "RECOMMENDATION_SIGNAL_DATA" + "RECOMMENDATION_SIGNAL_DATA", + "CONFIG_BASED_SIGNAL_DATA" ], "enumDescriptions": [ "", "Database resource metadata feed from control plane", "Database resource monitoring data", "Database resource security health signal data", - "Database resource recommendation signal data" + "Database resource recommendation signal data", + "Database config based signal data" ], "type": "string" }, @@ -4557,7 +4650,12 @@ "SIGNAL_TYPE_HIGH_WRITE_PRESSURE", "SIGNAL_TYPE_HIGH_READ_PRESSURE", "SIGNAL_TYPE_ENCRYPTION_ORG_POLICY_NOT_SATISFIED", - "SIGNAL_TYPE_LOCATION_ORG_POLICY_NOT_SATISFIED" + "SIGNAL_TYPE_LOCATION_ORG_POLICY_NOT_SATISFIED", + "SIGNAL_TYPE_OUTDATED_MINOR_VERSION", + "SIGNAL_TYPE_SCHEMA_NOT_OPTIMIZED", + "SIGNAL_TYPE_MANY_IDLE_CONNECTIONS", + "SIGNAL_TYPE_REPLICATION_LAG", + "SIGNAL_TYPE_OUTDATED_VERSION" ], "enumDeprecated": [ false, @@ -4655,6 +4753,11 @@ false, false, false, + false, + false, + false, + false, + false, false ], "enumDescriptions": [ @@ -4753,7 +4856,12 @@ "Heavy write pressure on the database rows.", "Heavy read pressure on the database rows.", "Encryption org policy not satisfied.", - "Location org policy not satisfied." + "Location org policy not satisfied.", + "Outdated DB minor version.", + "Schema not optimized.", + "High number of idle connections.", + "Replication delay.", + "Outdated version." ], "type": "string" }, @@ -4817,7 +4925,7 @@ "type": "object" }, "StorageDatabasecenterPartnerapiV1mainDatabaseResourceMetadata": { - "description": "Common model for database resource instance metadata. Next ID: 25", + "description": "Common model for database resource instance metadata. Next ID: 26", "id": "StorageDatabasecenterPartnerapiV1mainDatabaseResourceMetadata", "properties": { "availabilityConfiguration": { @@ -4832,6 +4940,10 @@ "$ref": "StorageDatabasecenterPartnerapiV1mainBackupRun", "description": "Latest backup run information for this instance" }, + "backupdrConfiguration": { + "$ref": "StorageDatabasecenterPartnerapiV1mainBackupDRConfiguration", + "description": "Optional. BackupDR Configuration for the resource." + }, "creationTime": { "description": "The creation time of the resource, i.e. the time when resource is created and recorded in partner service.", "format": "google-datetime", @@ -4904,6 +5016,7 @@ }, "gcbdrConfiguration": { "$ref": "StorageDatabasecenterPartnerapiV1mainGCBDRConfiguration", + "deprecated": true, "description": "GCBDR configuration for the resource." }, "id": { @@ -5170,7 +5283,12 @@ "SIGNAL_TYPE_HIGH_WRITE_PRESSURE", "SIGNAL_TYPE_HIGH_READ_PRESSURE", "SIGNAL_TYPE_ENCRYPTION_ORG_POLICY_NOT_SATISFIED", - "SIGNAL_TYPE_LOCATION_ORG_POLICY_NOT_SATISFIED" + "SIGNAL_TYPE_LOCATION_ORG_POLICY_NOT_SATISFIED", + "SIGNAL_TYPE_OUTDATED_MINOR_VERSION", + "SIGNAL_TYPE_SCHEMA_NOT_OPTIMIZED", + "SIGNAL_TYPE_MANY_IDLE_CONNECTIONS", + "SIGNAL_TYPE_REPLICATION_LAG", + "SIGNAL_TYPE_OUTDATED_VERSION" ], "enumDeprecated": [ false, @@ -5268,6 +5386,11 @@ false, false, false, + false, + false, + false, + false, + false, false ], "enumDescriptions": [ @@ -5366,7 +5489,12 @@ "Heavy write pressure on the database rows.", "Heavy read pressure on the database rows.", "Encryption org policy not satisfied.", - "Location org policy not satisfied." + "Location org policy not satisfied.", + "Outdated DB minor version.", + "Schema not optimized.", + "High number of idle connections.", + "Replication delay.", + "Outdated version." ], "type": "string" } @@ -5677,6 +5805,7 @@ "ENGINE_OTHER", "ENGINE_FIRESTORE_WITH_NATIVE_MODE", "ENGINE_FIRESTORE_WITH_DATASTORE_MODE", + "ENGINE_FIRESTORE_WITH_MONGODB_COMPATIBILITY_MODE", "ENGINE_EXADATA_ORACLE", "ENGINE_ADB_SERVERLESS_ORACLE" ], @@ -5698,6 +5827,7 @@ false, false, false, + false, false ], "enumDescriptions": [ @@ -5717,11 +5847,16 @@ "Other refers to rest of other database engine. This is to be when engine is known, but it is not present in this enum.", "Firestore with native mode.", "Firestore with datastore mode.", + "Firestore with MongoDB compatibility mode.", "Oracle Exadata engine.", "Oracle Autonomous DB Serverless engine." ], "type": "string" }, + "minorVersion": { + "description": "Minor version of the underlying database engine. Example values: For MySQL, it could be \"8.0.32\", \"5.7.32\" etc.. For Postgres, it could be \"14.3\", \"15.3\" etc..", + "type": "string" + }, "type": { "description": "Type of specific database product. It could be CloudSQL, AlloyDB etc..", "enum": [ diff --git a/alloydb/v1alpha/alloydb-gen.go b/alloydb/v1alpha/alloydb-gen.go index c10d4457481..029db150302 100644 --- a/alloydb/v1alpha/alloydb-gen.go +++ b/alloydb/v1alpha/alloydb-gen.go @@ -3049,10 +3049,44 @@ func (s StageInfo) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// StageSchedule: Timing information for the stage execution. +type StageSchedule struct { + // ActualEndTime: Actual end time of the stage. Set only if the stage has + // completed. + ActualEndTime string `json:"actualEndTime,omitempty"` + // ActualStartTime: Actual start time of the stage. Set only if the stage has + // started. + ActualStartTime string `json:"actualStartTime,omitempty"` + // EstimatedEndTime: When the stage is expected to end. Set only if the stage + // has not completed yet. + EstimatedEndTime string `json:"estimatedEndTime,omitempty"` + // EstimatedStartTime: When the stage is expected to start. Set only if the + // stage has not started yet. + EstimatedStartTime string `json:"estimatedStartTime,omitempty"` + // ForceSendFields is a list of field names (e.g. "ActualEndTime") 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. "ActualEndTime") 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 StageSchedule) MarshalJSON() ([]byte, error) { + type NoMethod StageSchedule + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // StageStatus: Status of an upgrade stage. type StageStatus struct { // ReadPoolInstancesUpgrade: Read pool instances upgrade metadata. ReadPoolInstancesUpgrade *ReadPoolInstancesUpgradeStageStatus `json:"readPoolInstancesUpgrade,omitempty"` + // Schedule: Output only. Timing information for the stage execution. + Schedule *StageSchedule `json:"schedule,omitempty"` // Stage: Upgrade stage. // // Possible values: @@ -3231,6 +3265,30 @@ func (s StorageDatabasecenterPartnerapiV1mainBackupConfiguration) MarshalJSON() return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// StorageDatabasecenterPartnerapiV1mainBackupDRConfiguration: +// BackupDRConfiguration to capture the backup and disaster recovery details of +// database resource. +type StorageDatabasecenterPartnerapiV1mainBackupDRConfiguration struct { + // BackupdrManaged: Indicates if the resource is managed by BackupDR. + BackupdrManaged bool `json:"backupdrManaged,omitempty"` + // ForceSendFields is a list of field names (e.g. "BackupdrManaged") 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. "BackupdrManaged") 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 StorageDatabasecenterPartnerapiV1mainBackupDRConfiguration) MarshalJSON() ([]byte, error) { + type NoMethod StorageDatabasecenterPartnerapiV1mainBackupDRConfiguration + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // StorageDatabasecenterPartnerapiV1mainBackupRun: A backup run. type StorageDatabasecenterPartnerapiV1mainBackupRun struct { // EndTime: The time the backup operation completed. REQUIRED @@ -3291,6 +3349,51 @@ func (s StorageDatabasecenterPartnerapiV1mainCompliance) MarshalJSON() ([]byte, return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// StorageDatabasecenterPartnerapiV1mainConfigBasedSignalData: Config based +// signal data. This is used to send signals to Condor which are based on the +// DB level configurations. These will be used to send signals for self managed +// databases. +type StorageDatabasecenterPartnerapiV1mainConfigBasedSignalData struct { + // FullResourceName: Required. Full Resource name of the source resource. + FullResourceName string `json:"fullResourceName,omitempty"` + // LastRefreshTime: Required. Last time signal was refreshed + LastRefreshTime string `json:"lastRefreshTime,omitempty"` + // ResourceId: Database resource id. + ResourceId *StorageDatabasecenterPartnerapiV1mainDatabaseResourceId `json:"resourceId,omitempty"` + // SignalBoolValue: Signal data for boolean signals. + SignalBoolValue bool `json:"signalBoolValue,omitempty"` + // SignalType: Required. Signal type of the signal + // + // Possible values: + // "SIGNAL_TYPE_UNSPECIFIED" - Unspecified signal type. + // "SIGNAL_TYPE_OUTDATED_MINOR_VERSION" - Outdated Minor Version + // "SIGNAL_TYPE_DATABASE_AUDITING_DISABLED" - Represents database auditing is + // disabled. + // "SIGNAL_TYPE_NO_ROOT_PASSWORD" - Represents if a database has a password + // configured for the root account or not. + // "SIGNAL_TYPE_EXPOSED_TO_PUBLIC_ACCESS" - Represents if a resource is + // exposed to public access. + // "SIGNAL_TYPE_UNENCRYPTED_CONNECTIONS" - Represents if a resources requires + // all incoming connections to use SSL or not. + SignalType string `json:"signalType,omitempty"` + // ForceSendFields is a list of field names (e.g. "FullResourceName") 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. "FullResourceName") 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 StorageDatabasecenterPartnerapiV1mainConfigBasedSignalData) MarshalJSON() ([]byte, error) { + type NoMethod StorageDatabasecenterPartnerapiV1mainConfigBasedSignalData + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // StorageDatabasecenterPartnerapiV1mainCustomMetadataData: Any custom metadata // associated with the resource. e.g. A spanner instance can have multiple // databases with its own unique metadata. Information for these individual @@ -3320,8 +3423,11 @@ func (s StorageDatabasecenterPartnerapiV1mainCustomMetadataData) MarshalJSON() ( // StorageDatabasecenterPartnerapiV1mainDatabaseResourceFeed: // DatabaseResourceFeed is the top level proto to be used to ingest different -// database resource level events into Condor platform. Next ID: 8 +// database resource level events into Condor platform. Next ID: 9 type StorageDatabasecenterPartnerapiV1mainDatabaseResourceFeed struct { + // ConfigBasedSignalData: Config based signal data is used to ingest signals + // that are generated based on the configuration of the database resource. + ConfigBasedSignalData *StorageDatabasecenterPartnerapiV1mainConfigBasedSignalData `json:"configBasedSignalData,omitempty"` // FeedTimestamp: Required. Timestamp when feed is generated. FeedTimestamp string `json:"feedTimestamp,omitempty"` // FeedType: Required. Type feed to be ingested into condor @@ -3333,6 +3439,7 @@ type StorageDatabasecenterPartnerapiV1mainDatabaseResourceFeed struct { // "SECURITY_FINDING_DATA" - Database resource security health signal data // "RECOMMENDATION_SIGNAL_DATA" - Database resource recommendation signal // data + // "CONFIG_BASED_SIGNAL_DATA" - Database config based signal data FeedType string `json:"feedType,omitempty"` ObservabilityMetricData *StorageDatabasecenterPartnerapiV1mainObservabilityMetricData `json:"observabilityMetricData,omitempty"` RecommendationSignalData *StorageDatabasecenterPartnerapiV1mainDatabaseResourceRecommendationSignalData `json:"recommendationSignalData,omitempty"` @@ -3341,15 +3448,15 @@ type StorageDatabasecenterPartnerapiV1mainDatabaseResourceFeed struct { // available in individual feed level as well. ResourceId *StorageDatabasecenterPartnerapiV1mainDatabaseResourceId `json:"resourceId,omitempty"` ResourceMetadata *StorageDatabasecenterPartnerapiV1mainDatabaseResourceMetadata `json:"resourceMetadata,omitempty"` - // ForceSendFields is a list of field names (e.g. "FeedTimestamp") to + // ForceSendFields is a list of field names (e.g. "ConfigBasedSignalData") 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. "FeedTimestamp") 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. "ConfigBasedSignalData") 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:"-"` } @@ -3664,6 +3771,11 @@ type StorageDatabasecenterPartnerapiV1mainDatabaseResourceHealthSignalData struc // not satisfied. // "SIGNAL_TYPE_LOCATION_ORG_POLICY_NOT_SATISFIED" - Location org policy not // satisfied. + // "SIGNAL_TYPE_OUTDATED_MINOR_VERSION" - Outdated DB minor version. + // "SIGNAL_TYPE_SCHEMA_NOT_OPTIMIZED" - Schema not optimized. + // "SIGNAL_TYPE_MANY_IDLE_CONNECTIONS" - High number of idle connections. + // "SIGNAL_TYPE_REPLICATION_LAG" - Replication delay. + // "SIGNAL_TYPE_OUTDATED_VERSION" - Outdated version. SignalType string `json:"signalType,omitempty"` // Possible values: // "STATE_UNSPECIFIED" - Unspecified state. @@ -3748,7 +3860,7 @@ func (s StorageDatabasecenterPartnerapiV1mainDatabaseResourceId) MarshalJSON() ( } // StorageDatabasecenterPartnerapiV1mainDatabaseResourceMetadata: Common model -// for database resource instance metadata. Next ID: 25 +// for database resource instance metadata. Next ID: 26 type StorageDatabasecenterPartnerapiV1mainDatabaseResourceMetadata struct { // AvailabilityConfiguration: Availability configuration for this instance AvailabilityConfiguration *StorageDatabasecenterPartnerapiV1mainAvailabilityConfiguration `json:"availabilityConfiguration,omitempty"` @@ -3756,6 +3868,8 @@ type StorageDatabasecenterPartnerapiV1mainDatabaseResourceMetadata struct { BackupConfiguration *StorageDatabasecenterPartnerapiV1mainBackupConfiguration `json:"backupConfiguration,omitempty"` // BackupRun: Latest backup run information for this instance BackupRun *StorageDatabasecenterPartnerapiV1mainBackupRun `json:"backupRun,omitempty"` + // BackupdrConfiguration: Optional. BackupDR Configuration for the resource. + BackupdrConfiguration *StorageDatabasecenterPartnerapiV1mainBackupDRConfiguration `json:"backupdrConfiguration,omitempty"` // CreationTime: The creation time of the resource, i.e. the time when resource // is created and recorded in partner service. CreationTime string `json:"creationTime,omitempty"` @@ -4148,6 +4262,11 @@ type StorageDatabasecenterPartnerapiV1mainDatabaseResourceRecommendationSignalDa // not satisfied. // "SIGNAL_TYPE_LOCATION_ORG_POLICY_NOT_SATISFIED" - Location org policy not // satisfied. + // "SIGNAL_TYPE_OUTDATED_MINOR_VERSION" - Outdated DB minor version. + // "SIGNAL_TYPE_SCHEMA_NOT_OPTIMIZED" - Schema not optimized. + // "SIGNAL_TYPE_MANY_IDLE_CONNECTIONS" - High number of idle connections. + // "SIGNAL_TYPE_REPLICATION_LAG" - Replication delay. + // "SIGNAL_TYPE_OUTDATED_VERSION" - Outdated version. SignalType string `json:"signalType,omitempty"` // ForceSendFields is a list of field names (e.g. "AdditionalMetadata") to // unconditionally include in API requests. By default, fields with empty or @@ -4525,9 +4644,15 @@ type StorageDatabasecenterProtoCommonProduct struct { // be when engine is known, but it is not present in this enum. // "ENGINE_FIRESTORE_WITH_NATIVE_MODE" - Firestore with native mode. // "ENGINE_FIRESTORE_WITH_DATASTORE_MODE" - Firestore with datastore mode. + // "ENGINE_FIRESTORE_WITH_MONGODB_COMPATIBILITY_MODE" - Firestore with + // MongoDB compatibility mode. // "ENGINE_EXADATA_ORACLE" - Oracle Exadata engine. // "ENGINE_ADB_SERVERLESS_ORACLE" - Oracle Autonomous DB Serverless engine. Engine string `json:"engine,omitempty"` + // MinorVersion: Minor version of the underlying database engine. Example + // values: For MySQL, it could be "8.0.32", "5.7.32" etc.. For Postgres, it + // could be "14.3", "15.3" etc.. + MinorVersion string `json:"minorVersion,omitempty"` // Type: Type of specific database product. It could be CloudSQL, AlloyDB etc.. // // Possible values: diff --git a/alloydb/v1beta/alloydb-api.json b/alloydb/v1beta/alloydb-api.json index 8eddb273328..d95c8ddcf66 100644 --- a/alloydb/v1beta/alloydb-api.json +++ b/alloydb/v1beta/alloydb-api.json @@ -1619,7 +1619,7 @@ } } }, - "revision": "20250612", + "revision": "20250723", "rootUrl": "https://alloydb.googleapis.com/", "schemas": { "AuthorizedNetwork": { @@ -4041,6 +4041,33 @@ }, "type": "object" }, + "StageSchedule": { + "description": "Timing information for the stage execution.", + "id": "StageSchedule", + "properties": { + "actualEndTime": { + "description": "Actual end time of the stage. Set only if the stage has completed.", + "format": "google-datetime", + "type": "string" + }, + "actualStartTime": { + "description": "Actual start time of the stage. Set only if the stage has started.", + "format": "google-datetime", + "type": "string" + }, + "estimatedEndTime": { + "description": "When the stage is expected to end. Set only if the stage has not completed yet.", + "format": "google-datetime", + "type": "string" + }, + "estimatedStartTime": { + "description": "When the stage is expected to start. Set only if the stage has not started yet.", + "format": "google-datetime", + "type": "string" + } + }, + "type": "object" + }, "StageStatus": { "description": "Status of an upgrade stage.", "id": "StageStatus", @@ -4049,6 +4076,11 @@ "$ref": "ReadPoolInstancesUpgradeStageStatus", "description": "Read pool instances upgrade metadata." }, + "schedule": { + "$ref": "StageSchedule", + "description": "Output only. Timing information for the stage execution.", + "readOnly": true + }, "stage": { "description": "Upgrade stage.", "enum": [ @@ -4212,6 +4244,17 @@ }, "type": "object" }, + "StorageDatabasecenterPartnerapiV1mainBackupDRConfiguration": { + "description": "BackupDRConfiguration to capture the backup and disaster recovery details of database resource.", + "id": "StorageDatabasecenterPartnerapiV1mainBackupDRConfiguration", + "properties": { + "backupdrManaged": { + "description": "Indicates if the resource is managed by BackupDR.", + "type": "boolean" + } + }, + "type": "object" + }, "StorageDatabasecenterPartnerapiV1mainBackupRun": { "description": "A backup run.", "id": "StorageDatabasecenterPartnerapiV1mainBackupRun", @@ -4262,6 +4305,50 @@ }, "type": "object" }, + "StorageDatabasecenterPartnerapiV1mainConfigBasedSignalData": { + "description": "Config based signal data. This is used to send signals to Condor which are based on the DB level configurations. These will be used to send signals for self managed databases.", + "id": "StorageDatabasecenterPartnerapiV1mainConfigBasedSignalData", + "properties": { + "fullResourceName": { + "description": "Required. Full Resource name of the source resource.", + "type": "string" + }, + "lastRefreshTime": { + "description": "Required. Last time signal was refreshed", + "format": "google-datetime", + "type": "string" + }, + "resourceId": { + "$ref": "StorageDatabasecenterPartnerapiV1mainDatabaseResourceId", + "description": "Database resource id." + }, + "signalBoolValue": { + "description": "Signal data for boolean signals.", + "type": "boolean" + }, + "signalType": { + "description": "Required. Signal type of the signal", + "enum": [ + "SIGNAL_TYPE_UNSPECIFIED", + "SIGNAL_TYPE_OUTDATED_MINOR_VERSION", + "SIGNAL_TYPE_DATABASE_AUDITING_DISABLED", + "SIGNAL_TYPE_NO_ROOT_PASSWORD", + "SIGNAL_TYPE_EXPOSED_TO_PUBLIC_ACCESS", + "SIGNAL_TYPE_UNENCRYPTED_CONNECTIONS" + ], + "enumDescriptions": [ + "Unspecified signal type.", + "Outdated Minor Version", + "Represents database auditing is disabled.", + "Represents if a database has a password configured for the root account or not.", + "Represents if a resource is exposed to public access.", + "Represents if a resources requires all incoming connections to use SSL or not." + ], + "type": "string" + } + }, + "type": "object" + }, "StorageDatabasecenterPartnerapiV1mainCustomMetadataData": { "description": "Any custom metadata associated with the resource. e.g. A spanner instance can have multiple databases with its own unique metadata. Information for these individual databases can be captured in custom metadata data", "id": "StorageDatabasecenterPartnerapiV1mainCustomMetadataData", @@ -4277,9 +4364,13 @@ "type": "object" }, "StorageDatabasecenterPartnerapiV1mainDatabaseResourceFeed": { - "description": "DatabaseResourceFeed is the top level proto to be used to ingest different database resource level events into Condor platform. Next ID: 8", + "description": "DatabaseResourceFeed is the top level proto to be used to ingest different database resource level events into Condor platform. Next ID: 9", "id": "StorageDatabasecenterPartnerapiV1mainDatabaseResourceFeed", "properties": { + "configBasedSignalData": { + "$ref": "StorageDatabasecenterPartnerapiV1mainConfigBasedSignalData", + "description": "Config based signal data is used to ingest signals that are generated based on the configuration of the database resource." + }, "feedTimestamp": { "description": "Required. Timestamp when feed is generated.", "format": "google-datetime", @@ -4292,14 +4383,16 @@ "RESOURCE_METADATA", "OBSERVABILITY_DATA", "SECURITY_FINDING_DATA", - "RECOMMENDATION_SIGNAL_DATA" + "RECOMMENDATION_SIGNAL_DATA", + "CONFIG_BASED_SIGNAL_DATA" ], "enumDescriptions": [ "", "Database resource metadata feed from control plane", "Database resource monitoring data", "Database resource security health signal data", - "Database resource recommendation signal data" + "Database resource recommendation signal data", + "Database config based signal data" ], "type": "string" }, @@ -4533,7 +4626,12 @@ "SIGNAL_TYPE_HIGH_WRITE_PRESSURE", "SIGNAL_TYPE_HIGH_READ_PRESSURE", "SIGNAL_TYPE_ENCRYPTION_ORG_POLICY_NOT_SATISFIED", - "SIGNAL_TYPE_LOCATION_ORG_POLICY_NOT_SATISFIED" + "SIGNAL_TYPE_LOCATION_ORG_POLICY_NOT_SATISFIED", + "SIGNAL_TYPE_OUTDATED_MINOR_VERSION", + "SIGNAL_TYPE_SCHEMA_NOT_OPTIMIZED", + "SIGNAL_TYPE_MANY_IDLE_CONNECTIONS", + "SIGNAL_TYPE_REPLICATION_LAG", + "SIGNAL_TYPE_OUTDATED_VERSION" ], "enumDeprecated": [ false, @@ -4631,6 +4729,11 @@ false, false, false, + false, + false, + false, + false, + false, false ], "enumDescriptions": [ @@ -4729,7 +4832,12 @@ "Heavy write pressure on the database rows.", "Heavy read pressure on the database rows.", "Encryption org policy not satisfied.", - "Location org policy not satisfied." + "Location org policy not satisfied.", + "Outdated DB minor version.", + "Schema not optimized.", + "High number of idle connections.", + "Replication delay.", + "Outdated version." ], "type": "string" }, @@ -4793,7 +4901,7 @@ "type": "object" }, "StorageDatabasecenterPartnerapiV1mainDatabaseResourceMetadata": { - "description": "Common model for database resource instance metadata. Next ID: 25", + "description": "Common model for database resource instance metadata. Next ID: 26", "id": "StorageDatabasecenterPartnerapiV1mainDatabaseResourceMetadata", "properties": { "availabilityConfiguration": { @@ -4808,6 +4916,10 @@ "$ref": "StorageDatabasecenterPartnerapiV1mainBackupRun", "description": "Latest backup run information for this instance" }, + "backupdrConfiguration": { + "$ref": "StorageDatabasecenterPartnerapiV1mainBackupDRConfiguration", + "description": "Optional. BackupDR Configuration for the resource." + }, "creationTime": { "description": "The creation time of the resource, i.e. the time when resource is created and recorded in partner service.", "format": "google-datetime", @@ -4880,6 +4992,7 @@ }, "gcbdrConfiguration": { "$ref": "StorageDatabasecenterPartnerapiV1mainGCBDRConfiguration", + "deprecated": true, "description": "GCBDR configuration for the resource." }, "id": { @@ -5146,7 +5259,12 @@ "SIGNAL_TYPE_HIGH_WRITE_PRESSURE", "SIGNAL_TYPE_HIGH_READ_PRESSURE", "SIGNAL_TYPE_ENCRYPTION_ORG_POLICY_NOT_SATISFIED", - "SIGNAL_TYPE_LOCATION_ORG_POLICY_NOT_SATISFIED" + "SIGNAL_TYPE_LOCATION_ORG_POLICY_NOT_SATISFIED", + "SIGNAL_TYPE_OUTDATED_MINOR_VERSION", + "SIGNAL_TYPE_SCHEMA_NOT_OPTIMIZED", + "SIGNAL_TYPE_MANY_IDLE_CONNECTIONS", + "SIGNAL_TYPE_REPLICATION_LAG", + "SIGNAL_TYPE_OUTDATED_VERSION" ], "enumDeprecated": [ false, @@ -5244,6 +5362,11 @@ false, false, false, + false, + false, + false, + false, + false, false ], "enumDescriptions": [ @@ -5342,7 +5465,12 @@ "Heavy write pressure on the database rows.", "Heavy read pressure on the database rows.", "Encryption org policy not satisfied.", - "Location org policy not satisfied." + "Location org policy not satisfied.", + "Outdated DB minor version.", + "Schema not optimized.", + "High number of idle connections.", + "Replication delay.", + "Outdated version." ], "type": "string" } @@ -5653,6 +5781,7 @@ "ENGINE_OTHER", "ENGINE_FIRESTORE_WITH_NATIVE_MODE", "ENGINE_FIRESTORE_WITH_DATASTORE_MODE", + "ENGINE_FIRESTORE_WITH_MONGODB_COMPATIBILITY_MODE", "ENGINE_EXADATA_ORACLE", "ENGINE_ADB_SERVERLESS_ORACLE" ], @@ -5674,6 +5803,7 @@ false, false, false, + false, false ], "enumDescriptions": [ @@ -5693,11 +5823,16 @@ "Other refers to rest of other database engine. This is to be when engine is known, but it is not present in this enum.", "Firestore with native mode.", "Firestore with datastore mode.", + "Firestore with MongoDB compatibility mode.", "Oracle Exadata engine.", "Oracle Autonomous DB Serverless engine." ], "type": "string" }, + "minorVersion": { + "description": "Minor version of the underlying database engine. Example values: For MySQL, it could be \"8.0.32\", \"5.7.32\" etc.. For Postgres, it could be \"14.3\", \"15.3\" etc..", + "type": "string" + }, "type": { "description": "Type of specific database product. It could be CloudSQL, AlloyDB etc..", "enum": [ diff --git a/alloydb/v1beta/alloydb-gen.go b/alloydb/v1beta/alloydb-gen.go index 62a1054b018..8cfbb25e003 100644 --- a/alloydb/v1beta/alloydb-gen.go +++ b/alloydb/v1beta/alloydb-gen.go @@ -3039,10 +3039,44 @@ func (s StageInfo) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// StageSchedule: Timing information for the stage execution. +type StageSchedule struct { + // ActualEndTime: Actual end time of the stage. Set only if the stage has + // completed. + ActualEndTime string `json:"actualEndTime,omitempty"` + // ActualStartTime: Actual start time of the stage. Set only if the stage has + // started. + ActualStartTime string `json:"actualStartTime,omitempty"` + // EstimatedEndTime: When the stage is expected to end. Set only if the stage + // has not completed yet. + EstimatedEndTime string `json:"estimatedEndTime,omitempty"` + // EstimatedStartTime: When the stage is expected to start. Set only if the + // stage has not started yet. + EstimatedStartTime string `json:"estimatedStartTime,omitempty"` + // ForceSendFields is a list of field names (e.g. "ActualEndTime") 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. "ActualEndTime") 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 StageSchedule) MarshalJSON() ([]byte, error) { + type NoMethod StageSchedule + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // StageStatus: Status of an upgrade stage. type StageStatus struct { // ReadPoolInstancesUpgrade: Read pool instances upgrade metadata. ReadPoolInstancesUpgrade *ReadPoolInstancesUpgradeStageStatus `json:"readPoolInstancesUpgrade,omitempty"` + // Schedule: Output only. Timing information for the stage execution. + Schedule *StageSchedule `json:"schedule,omitempty"` // Stage: Upgrade stage. // // Possible values: @@ -3221,6 +3255,30 @@ func (s StorageDatabasecenterPartnerapiV1mainBackupConfiguration) MarshalJSON() return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// StorageDatabasecenterPartnerapiV1mainBackupDRConfiguration: +// BackupDRConfiguration to capture the backup and disaster recovery details of +// database resource. +type StorageDatabasecenterPartnerapiV1mainBackupDRConfiguration struct { + // BackupdrManaged: Indicates if the resource is managed by BackupDR. + BackupdrManaged bool `json:"backupdrManaged,omitempty"` + // ForceSendFields is a list of field names (e.g. "BackupdrManaged") 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. "BackupdrManaged") 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 StorageDatabasecenterPartnerapiV1mainBackupDRConfiguration) MarshalJSON() ([]byte, error) { + type NoMethod StorageDatabasecenterPartnerapiV1mainBackupDRConfiguration + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // StorageDatabasecenterPartnerapiV1mainBackupRun: A backup run. type StorageDatabasecenterPartnerapiV1mainBackupRun struct { // EndTime: The time the backup operation completed. REQUIRED @@ -3281,6 +3339,51 @@ func (s StorageDatabasecenterPartnerapiV1mainCompliance) MarshalJSON() ([]byte, return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// StorageDatabasecenterPartnerapiV1mainConfigBasedSignalData: Config based +// signal data. This is used to send signals to Condor which are based on the +// DB level configurations. These will be used to send signals for self managed +// databases. +type StorageDatabasecenterPartnerapiV1mainConfigBasedSignalData struct { + // FullResourceName: Required. Full Resource name of the source resource. + FullResourceName string `json:"fullResourceName,omitempty"` + // LastRefreshTime: Required. Last time signal was refreshed + LastRefreshTime string `json:"lastRefreshTime,omitempty"` + // ResourceId: Database resource id. + ResourceId *StorageDatabasecenterPartnerapiV1mainDatabaseResourceId `json:"resourceId,omitempty"` + // SignalBoolValue: Signal data for boolean signals. + SignalBoolValue bool `json:"signalBoolValue,omitempty"` + // SignalType: Required. Signal type of the signal + // + // Possible values: + // "SIGNAL_TYPE_UNSPECIFIED" - Unspecified signal type. + // "SIGNAL_TYPE_OUTDATED_MINOR_VERSION" - Outdated Minor Version + // "SIGNAL_TYPE_DATABASE_AUDITING_DISABLED" - Represents database auditing is + // disabled. + // "SIGNAL_TYPE_NO_ROOT_PASSWORD" - Represents if a database has a password + // configured for the root account or not. + // "SIGNAL_TYPE_EXPOSED_TO_PUBLIC_ACCESS" - Represents if a resource is + // exposed to public access. + // "SIGNAL_TYPE_UNENCRYPTED_CONNECTIONS" - Represents if a resources requires + // all incoming connections to use SSL or not. + SignalType string `json:"signalType,omitempty"` + // ForceSendFields is a list of field names (e.g. "FullResourceName") 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. "FullResourceName") 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 StorageDatabasecenterPartnerapiV1mainConfigBasedSignalData) MarshalJSON() ([]byte, error) { + type NoMethod StorageDatabasecenterPartnerapiV1mainConfigBasedSignalData + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // StorageDatabasecenterPartnerapiV1mainCustomMetadataData: Any custom metadata // associated with the resource. e.g. A spanner instance can have multiple // databases with its own unique metadata. Information for these individual @@ -3310,8 +3413,11 @@ func (s StorageDatabasecenterPartnerapiV1mainCustomMetadataData) MarshalJSON() ( // StorageDatabasecenterPartnerapiV1mainDatabaseResourceFeed: // DatabaseResourceFeed is the top level proto to be used to ingest different -// database resource level events into Condor platform. Next ID: 8 +// database resource level events into Condor platform. Next ID: 9 type StorageDatabasecenterPartnerapiV1mainDatabaseResourceFeed struct { + // ConfigBasedSignalData: Config based signal data is used to ingest signals + // that are generated based on the configuration of the database resource. + ConfigBasedSignalData *StorageDatabasecenterPartnerapiV1mainConfigBasedSignalData `json:"configBasedSignalData,omitempty"` // FeedTimestamp: Required. Timestamp when feed is generated. FeedTimestamp string `json:"feedTimestamp,omitempty"` // FeedType: Required. Type feed to be ingested into condor @@ -3323,6 +3429,7 @@ type StorageDatabasecenterPartnerapiV1mainDatabaseResourceFeed struct { // "SECURITY_FINDING_DATA" - Database resource security health signal data // "RECOMMENDATION_SIGNAL_DATA" - Database resource recommendation signal // data + // "CONFIG_BASED_SIGNAL_DATA" - Database config based signal data FeedType string `json:"feedType,omitempty"` ObservabilityMetricData *StorageDatabasecenterPartnerapiV1mainObservabilityMetricData `json:"observabilityMetricData,omitempty"` RecommendationSignalData *StorageDatabasecenterPartnerapiV1mainDatabaseResourceRecommendationSignalData `json:"recommendationSignalData,omitempty"` @@ -3331,15 +3438,15 @@ type StorageDatabasecenterPartnerapiV1mainDatabaseResourceFeed struct { // available in individual feed level as well. ResourceId *StorageDatabasecenterPartnerapiV1mainDatabaseResourceId `json:"resourceId,omitempty"` ResourceMetadata *StorageDatabasecenterPartnerapiV1mainDatabaseResourceMetadata `json:"resourceMetadata,omitempty"` - // ForceSendFields is a list of field names (e.g. "FeedTimestamp") to + // ForceSendFields is a list of field names (e.g. "ConfigBasedSignalData") 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. "FeedTimestamp") 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. "ConfigBasedSignalData") 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:"-"` } @@ -3654,6 +3761,11 @@ type StorageDatabasecenterPartnerapiV1mainDatabaseResourceHealthSignalData struc // not satisfied. // "SIGNAL_TYPE_LOCATION_ORG_POLICY_NOT_SATISFIED" - Location org policy not // satisfied. + // "SIGNAL_TYPE_OUTDATED_MINOR_VERSION" - Outdated DB minor version. + // "SIGNAL_TYPE_SCHEMA_NOT_OPTIMIZED" - Schema not optimized. + // "SIGNAL_TYPE_MANY_IDLE_CONNECTIONS" - High number of idle connections. + // "SIGNAL_TYPE_REPLICATION_LAG" - Replication delay. + // "SIGNAL_TYPE_OUTDATED_VERSION" - Outdated version. SignalType string `json:"signalType,omitempty"` // Possible values: // "STATE_UNSPECIFIED" - Unspecified state. @@ -3738,7 +3850,7 @@ func (s StorageDatabasecenterPartnerapiV1mainDatabaseResourceId) MarshalJSON() ( } // StorageDatabasecenterPartnerapiV1mainDatabaseResourceMetadata: Common model -// for database resource instance metadata. Next ID: 25 +// for database resource instance metadata. Next ID: 26 type StorageDatabasecenterPartnerapiV1mainDatabaseResourceMetadata struct { // AvailabilityConfiguration: Availability configuration for this instance AvailabilityConfiguration *StorageDatabasecenterPartnerapiV1mainAvailabilityConfiguration `json:"availabilityConfiguration,omitempty"` @@ -3746,6 +3858,8 @@ type StorageDatabasecenterPartnerapiV1mainDatabaseResourceMetadata struct { BackupConfiguration *StorageDatabasecenterPartnerapiV1mainBackupConfiguration `json:"backupConfiguration,omitempty"` // BackupRun: Latest backup run information for this instance BackupRun *StorageDatabasecenterPartnerapiV1mainBackupRun `json:"backupRun,omitempty"` + // BackupdrConfiguration: Optional. BackupDR Configuration for the resource. + BackupdrConfiguration *StorageDatabasecenterPartnerapiV1mainBackupDRConfiguration `json:"backupdrConfiguration,omitempty"` // CreationTime: The creation time of the resource, i.e. the time when resource // is created and recorded in partner service. CreationTime string `json:"creationTime,omitempty"` @@ -4138,6 +4252,11 @@ type StorageDatabasecenterPartnerapiV1mainDatabaseResourceRecommendationSignalDa // not satisfied. // "SIGNAL_TYPE_LOCATION_ORG_POLICY_NOT_SATISFIED" - Location org policy not // satisfied. + // "SIGNAL_TYPE_OUTDATED_MINOR_VERSION" - Outdated DB minor version. + // "SIGNAL_TYPE_SCHEMA_NOT_OPTIMIZED" - Schema not optimized. + // "SIGNAL_TYPE_MANY_IDLE_CONNECTIONS" - High number of idle connections. + // "SIGNAL_TYPE_REPLICATION_LAG" - Replication delay. + // "SIGNAL_TYPE_OUTDATED_VERSION" - Outdated version. SignalType string `json:"signalType,omitempty"` // ForceSendFields is a list of field names (e.g. "AdditionalMetadata") to // unconditionally include in API requests. By default, fields with empty or @@ -4515,9 +4634,15 @@ type StorageDatabasecenterProtoCommonProduct struct { // be when engine is known, but it is not present in this enum. // "ENGINE_FIRESTORE_WITH_NATIVE_MODE" - Firestore with native mode. // "ENGINE_FIRESTORE_WITH_DATASTORE_MODE" - Firestore with datastore mode. + // "ENGINE_FIRESTORE_WITH_MONGODB_COMPATIBILITY_MODE" - Firestore with + // MongoDB compatibility mode. // "ENGINE_EXADATA_ORACLE" - Oracle Exadata engine. // "ENGINE_ADB_SERVERLESS_ORACLE" - Oracle Autonomous DB Serverless engine. Engine string `json:"engine,omitempty"` + // MinorVersion: Minor version of the underlying database engine. Example + // values: For MySQL, it could be "8.0.32", "5.7.32" etc.. For Postgres, it + // could be "14.3", "15.3" etc.. + MinorVersion string `json:"minorVersion,omitempty"` // Type: Type of specific database product. It could be CloudSQL, AlloyDB etc.. // // Possible values: diff --git a/batch/v1/batch-api.json b/batch/v1/batch-api.json index 48090a2212f..69536d192aa 100644 --- a/batch/v1/batch-api.json +++ b/batch/v1/batch-api.json @@ -595,7 +595,7 @@ } } }, - "revision": "20250519", + "revision": "20250721", "rootUrl": "https://batch.googleapis.com/", "schemas": { "Accelerator": { @@ -1298,19 +1298,22 @@ "PROVISIONING_MODEL_UNSPECIFIED", "STANDARD", "SPOT", - "PREEMPTIBLE" + "PREEMPTIBLE", + "RESERVATION_BOUND" ], "enumDeprecated": [ false, false, false, - true + true, + false ], "enumDescriptions": [ "Unspecified.", "Standard VM.", "SPOT VM.", - "Preemptible VM (PVM). Above SPOT VM is the preferable model for preemptible VM instances: the old preemptible VM model (indicated by this field) is the older model, and has been migrated to use the SPOT model as the underlying technology. This old model will still be supported." + "Preemptible VM (PVM). Above SPOT VM is the preferable model for preemptible VM instances: the old preemptible VM model (indicated by this field) is the older model, and has been migrated to use the SPOT model as the underlying technology. This old model will still be supported.", + "Bound to the lifecycle of the reservation in which it is provisioned." ], "type": "string" }, @@ -1366,19 +1369,22 @@ "PROVISIONING_MODEL_UNSPECIFIED", "STANDARD", "SPOT", - "PREEMPTIBLE" + "PREEMPTIBLE", + "RESERVATION_BOUND" ], "enumDeprecated": [ false, false, false, - true + true, + false ], "enumDescriptions": [ "Unspecified.", "Standard VM.", "SPOT VM.", - "Preemptible VM (PVM). Above SPOT VM is the preferable model for preemptible VM instances: the old preemptible VM model (indicated by this field) is the older model, and has been migrated to use the SPOT model as the underlying technology. This old model will still be supported." + "Preemptible VM (PVM). Above SPOT VM is the preferable model for preemptible VM instances: the old preemptible VM model (indicated by this field) is the older model, and has been migrated to use the SPOT model as the underlying technology. This old model will still be supported.", + "Bound to the lifecycle of the reservation in which it is provisioned." ], "type": "string" }, diff --git a/batch/v1/batch-gen.go b/batch/v1/batch-gen.go index 4937ea1757e..0e8b9224470 100644 --- a/batch/v1/batch-gen.go +++ b/batch/v1/batch-gen.go @@ -1216,6 +1216,8 @@ type InstancePolicy struct { // model for preemptible VM instances: the old preemptible VM model (indicated // by this field) is the older model, and has been migrated to use the SPOT // model as the underlying technology. This old model will still be supported. + // "RESERVATION_BOUND" - Bound to the lifecycle of the reservation in which + // it is provisioned. ProvisioningModel string `json:"provisioningModel,omitempty"` // Reservation: Optional. If not specified (default), VMs will consume any // applicable reservation. If "NO_RESERVATION" is specified, VMs will not @@ -1311,6 +1313,8 @@ type InstanceStatus struct { // model for preemptible VM instances: the old preemptible VM model (indicated // by this field) is the older model, and has been migrated to use the SPOT // model as the underlying technology. This old model will still be supported. + // "RESERVATION_BOUND" - Bound to the lifecycle of the reservation in which + // it is provisioned. ProvisioningModel string `json:"provisioningModel,omitempty"` // TaskPack: The max number of tasks can be assigned to this instance type. TaskPack int64 `json:"taskPack,omitempty,string"` diff --git a/migrationcenter/v1alpha1/migrationcenter-api.json b/migrationcenter/v1alpha1/migrationcenter-api.json index 0b5a3a7e5f9..d8b9a5c7011 100644 --- a/migrationcenter/v1alpha1/migrationcenter-api.json +++ b/migrationcenter/v1alpha1/migrationcenter-api.json @@ -2554,7 +2554,7 @@ } } }, - "revision": "20250710", + "revision": "20250724", "rootUrl": "https://migrationcenter.googleapis.com/", "schemas": { "AddAssetsToGroupRequest": { @@ -6874,9 +6874,9 @@ }, "fileSizeBytes": { "description": "Output only. File size in bytes.", - "format": "int32", + "format": "int64", "readOnly": true, - "type": "integer" + "type": "string" }, "xlsxOutputFile": { "$ref": "XlsxOutputFile", diff --git a/migrationcenter/v1alpha1/migrationcenter-gen.go b/migrationcenter/v1alpha1/migrationcenter-gen.go index f92f64dd100..c219a031871 100644 --- a/migrationcenter/v1alpha1/migrationcenter-gen.go +++ b/migrationcenter/v1alpha1/migrationcenter-gen.go @@ -5231,7 +5231,7 @@ 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"` + FileSizeBytes int64 `json:"fileSizeBytes,omitempty,string"` // XlsxOutputFile: Output only. XLSX output file. XlsxOutputFile *XlsxOutputFile `json:"xlsxOutputFile,omitempty"` // ForceSendFields is a list of field names (e.g. "CsvOutputFile") to From ce50789a30c76512543819a36eb0fb91b86edc44 Mon Sep 17 00:00:00 2001 From: Yoshi Automation Bot Date: Tue, 29 Jul 2025 00:36:22 -0700 Subject: [PATCH 07/10] feat(all): auto-regenerate discovery clients (#3250) --- .../v1beta1/networksecurity-api.json | 233 +++++- .../v1beta1/networksecurity-gen.go | 665 ++++++++++++++++++ 2 files changed, 897 insertions(+), 1 deletion(-) diff --git a/networksecurity/v1beta1/networksecurity-api.json b/networksecurity/v1beta1/networksecurity-api.json index f05c1130a19..9f9c3a89403 100644 --- a/networksecurity/v1beta1/networksecurity-api.json +++ b/networksecurity/v1beta1/networksecurity-api.json @@ -2420,6 +2420,163 @@ } } }, + "dnsThreatDetectors": { + "methods": { + "create": { + "description": "Creates a new DnsThreatDetector in a given project and location.", + "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/dnsThreatDetectors", + "httpMethod": "POST", + "id": "networksecurity.projects.locations.dnsThreatDetectors.create", + "parameterOrder": [ + "parent" + ], + "parameters": { + "dnsThreatDetectorId": { + "description": "Optional. Id of the requesting DnsThreatDetector object. If this field is not supplied, the service will generate an identifier.", + "location": "query", + "type": "string" + }, + "parent": { + "description": "Required. Value for parent of the DnsThreatDetector resource.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1beta1/{+parent}/dnsThreatDetectors", + "request": { + "$ref": "DnsThreatDetector" + }, + "response": { + "$ref": "DnsThreatDetector" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "delete": { + "description": "Deletes a single DnsThreatDetector.", + "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/dnsThreatDetectors/{dnsThreatDetectorsId}", + "httpMethod": "DELETE", + "id": "networksecurity.projects.locations.dnsThreatDetectors.delete", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Required. Name of the DnsThreatDetector resource.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/dnsThreatDetectors/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1beta1/{+name}", + "response": { + "$ref": "Empty" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "get": { + "description": "Gets details of a single DnsThreatDetector.", + "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/dnsThreatDetectors/{dnsThreatDetectorsId}", + "httpMethod": "GET", + "id": "networksecurity.projects.locations.dnsThreatDetectors.get", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Required. Name of the DnsThreatDetector resource", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/dnsThreatDetectors/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1beta1/{+name}", + "response": { + "$ref": "DnsThreatDetector" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "list": { + "description": "Lists DnsThreatDetectors in a given project and location.", + "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/dnsThreatDetectors", + "httpMethod": "GET", + "id": "networksecurity.projects.locations.dnsThreatDetectors.list", + "parameterOrder": [ + "parent" + ], + "parameters": { + "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 page token, received from a previous `ListDnsThreatDetectorsRequest` call. Provide this to retrieve the subsequent page.", + "location": "query", + "type": "string" + }, + "parent": { + "description": "Required. Parent value for ListDnsThreatDetectorsRequest", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1beta1/{+parent}/dnsThreatDetectors", + "response": { + "$ref": "ListDnsThreatDetectorsResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "patch": { + "description": "Updates the parameters of a single DnsThreatDetector.", + "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/dnsThreatDetectors/{dnsThreatDetectorsId}", + "httpMethod": "PATCH", + "id": "networksecurity.projects.locations.dnsThreatDetectors.patch", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Immutable. Identifier. Name of the DnsThreatDetector resource.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/dnsThreatDetectors/[^/]+$", + "required": true, + "type": "string" + }, + "updateMask": { + "description": "Optional. Field mask is used to specify the fields to be overwritten in the DnsThreatDetector 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 mask is not provided then all fields present in the request will be overwritten.", + "format": "google-fieldmask", + "location": "query", + "type": "string" + } + }, + "path": "v1beta1/{+name}", + "request": { + "$ref": "DnsThreatDetector" + }, + "response": { + "$ref": "DnsThreatDetector" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + } + } + }, "firewallEndpointAssociations": { "methods": { "create": { @@ -5356,7 +5513,7 @@ } } }, - "revision": "20250714", + "revision": "20250721", "rootUrl": "https://networksecurity.googleapis.com/", "schemas": { "AddAddressGroupItemsRequest": { @@ -6140,6 +6297,55 @@ }, "type": "object" }, + "DnsThreatDetector": { + "description": "Message describing DnsThreatDetector object", + "id": "DnsThreatDetector", + "properties": { + "createTime": { + "description": "Output only. [Output only] Create time stamp", + "format": "google-datetime", + "readOnly": true, + "type": "string" + }, + "excludedNetworks": { + "description": "Optional. A list of Network resource names which are exempt from the configuration in this DnsThreatDetector. Example: `projects/PROJECT_ID/global/networks/NETWORK_NAME`.", + "items": { + "type": "string" + }, + "type": "array" + }, + "labels": { + "additionalProperties": { + "type": "string" + }, + "description": "Optional. Labels as key value pairs", + "type": "object" + }, + "name": { + "description": "Immutable. Identifier. Name of the DnsThreatDetector resource.", + "type": "string" + }, + "provider": { + "description": "Required. The provider used for DNS threat analysis.", + "enum": [ + "PROVIDER_UNSPECIFIED", + "INFOBLOX" + ], + "enumDescriptions": [ + "An unspecified provider.", + "The Infoblox DNS threat detecter." + ], + "type": "string" + }, + "updateTime": { + "description": "Output only. [Output only] Update time stamp", + "format": "google-datetime", + "readOnly": true, + "type": "string" + } + }, + "type": "object" + }, "Empty": { "description": "A generic empty message that you can re-use to avoid defining duplicated empty messages in your APIs. A typical example is to use it as the request or the response type of an API method. For instance: service Foo { rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty); }", "id": "Empty", @@ -7249,6 +7455,31 @@ }, "type": "object" }, + "ListDnsThreatDetectorsResponse": { + "description": "Message for response to listing DnsThreatDetectors", + "id": "ListDnsThreatDetectorsResponse", + "properties": { + "dnsThreatDetectors": { + "description": "The list of DnsThreatDetector resources.", + "items": { + "$ref": "DnsThreatDetector" + }, + "type": "array" + }, + "nextPageToken": { + "description": "A token, which can be sent as `page_token` to retrieve the next page.", + "type": "string" + }, + "unreachable": { + "description": "Unordered list. Unreachable `DnsThreatDetector` resources.", + "items": { + "type": "string" + }, + "type": "array" + } + }, + "type": "object" + }, "ListFirewallEndpointAssociationsResponse": { "description": "Message for response to listing Associations", "id": "ListFirewallEndpointAssociationsResponse", diff --git a/networksecurity/v1beta1/networksecurity-gen.go b/networksecurity/v1beta1/networksecurity-gen.go index ce645142b8f..824ab8c7a8f 100644 --- a/networksecurity/v1beta1/networksecurity-gen.go +++ b/networksecurity/v1beta1/networksecurity-gen.go @@ -257,6 +257,7 @@ func NewProjectsLocationsService(s *Service) *ProjectsLocationsService { rs.AuthzPolicies = NewProjectsLocationsAuthzPoliciesService(s) rs.BackendAuthenticationConfigs = NewProjectsLocationsBackendAuthenticationConfigsService(s) rs.ClientTlsPolicies = NewProjectsLocationsClientTlsPoliciesService(s) + rs.DnsThreatDetectors = NewProjectsLocationsDnsThreatDetectorsService(s) rs.FirewallEndpointAssociations = NewProjectsLocationsFirewallEndpointAssociationsService(s) rs.GatewaySecurityPolicies = NewProjectsLocationsGatewaySecurityPoliciesService(s) rs.InterceptDeploymentGroups = NewProjectsLocationsInterceptDeploymentGroupsService(s) @@ -289,6 +290,8 @@ type ProjectsLocationsService struct { ClientTlsPolicies *ProjectsLocationsClientTlsPoliciesService + DnsThreatDetectors *ProjectsLocationsDnsThreatDetectorsService + FirewallEndpointAssociations *ProjectsLocationsFirewallEndpointAssociationsService GatewaySecurityPolicies *ProjectsLocationsGatewaySecurityPoliciesService @@ -367,6 +370,15 @@ type ProjectsLocationsClientTlsPoliciesService struct { s *Service } +func NewProjectsLocationsDnsThreatDetectorsService(s *Service) *ProjectsLocationsDnsThreatDetectorsService { + rs := &ProjectsLocationsDnsThreatDetectorsService{s: s} + return rs +} + +type ProjectsLocationsDnsThreatDetectorsService struct { + s *Service +} + func NewProjectsLocationsFirewallEndpointAssociationsService(s *Service) *ProjectsLocationsFirewallEndpointAssociationsService { rs := &ProjectsLocationsFirewallEndpointAssociationsService{s: s} return rs @@ -1558,6 +1570,47 @@ func (s Destination) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// DnsThreatDetector: Message describing DnsThreatDetector object +type DnsThreatDetector struct { + // CreateTime: Output only. [Output only] Create time stamp + CreateTime string `json:"createTime,omitempty"` + // ExcludedNetworks: Optional. A list of Network resource names which are + // exempt from the configuration in this DnsThreatDetector. Example: + // `projects/PROJECT_ID/global/networks/NETWORK_NAME`. + ExcludedNetworks []string `json:"excludedNetworks,omitempty"` + // Labels: Optional. Labels as key value pairs + Labels map[string]string `json:"labels,omitempty"` + // Name: Immutable. Identifier. Name of the DnsThreatDetector resource. + Name string `json:"name,omitempty"` + // Provider: Required. The provider used for DNS threat analysis. + // + // Possible values: + // "PROVIDER_UNSPECIFIED" - An unspecified provider. + // "INFOBLOX" - The Infoblox DNS threat detecter. + Provider string `json:"provider,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 DnsThreatDetector) MarshalJSON() ([]byte, error) { + type NoMethod DnsThreatDetector + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // Empty: A generic empty message that you can re-use to avoid defining // duplicated empty messages in your APIs. A typical example is to use it as // the request or the response type of an API method. For instance: service Foo @@ -3027,6 +3080,37 @@ func (s ListClientTlsPoliciesResponse) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// ListDnsThreatDetectorsResponse: Message for response to listing +// DnsThreatDetectors +type ListDnsThreatDetectorsResponse struct { + // DnsThreatDetectors: The list of DnsThreatDetector resources. + DnsThreatDetectors []*DnsThreatDetector `json:"dnsThreatDetectors,omitempty"` + // NextPageToken: A token, which can be sent as `page_token` to retrieve the + // next page. + NextPageToken string `json:"nextPageToken,omitempty"` + // Unreachable: Unordered list. Unreachable `DnsThreatDetector` resources. + 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. "DnsThreatDetectors") 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. "DnsThreatDetectors") 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 ListDnsThreatDetectorsResponse) MarshalJSON() ([]byte, error) { + type NoMethod ListDnsThreatDetectorsResponse + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // ListFirewallEndpointAssociationsResponse: Message for response to listing // Associations type ListFirewallEndpointAssociationsResponse struct { @@ -13790,6 +13874,587 @@ func (c *ProjectsLocationsClientTlsPoliciesTestIamPermissionsCall) Do(opts ...go return ret, nil } +type ProjectsLocationsDnsThreatDetectorsCreateCall struct { + s *Service + parent string + dnsthreatdetector *DnsThreatDetector + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Create: Creates a new DnsThreatDetector in a given project and location. +// +// - parent: Value for parent of the DnsThreatDetector resource. +func (r *ProjectsLocationsDnsThreatDetectorsService) Create(parent string, dnsthreatdetector *DnsThreatDetector) *ProjectsLocationsDnsThreatDetectorsCreateCall { + c := &ProjectsLocationsDnsThreatDetectorsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + c.dnsthreatdetector = dnsthreatdetector + return c +} + +// DnsThreatDetectorId sets the optional parameter "dnsThreatDetectorId": Id of +// the requesting DnsThreatDetector object. If this field is not supplied, the +// service will generate an identifier. +func (c *ProjectsLocationsDnsThreatDetectorsCreateCall) DnsThreatDetectorId(dnsThreatDetectorId string) *ProjectsLocationsDnsThreatDetectorsCreateCall { + c.urlParams_.Set("dnsThreatDetectorId", dnsThreatDetectorId) + 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 *ProjectsLocationsDnsThreatDetectorsCreateCall) Fields(s ...googleapi.Field) *ProjectsLocationsDnsThreatDetectorsCreateCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsDnsThreatDetectorsCreateCall) Context(ctx context.Context) *ProjectsLocationsDnsThreatDetectorsCreateCall { + 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 *ProjectsLocationsDnsThreatDetectorsCreateCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsDnsThreatDetectorsCreateCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) + body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.dnsthreatdetector) + if err != nil { + return nil, err + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+parent}/dnsThreatDetectors") + 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, + }) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "networksecurity.projects.locations.dnsThreatDetectors.create", "request", internallog.HTTPRequest(req, body.Bytes())) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "networksecurity.projects.locations.dnsThreatDetectors.create" call. +// Any non-2xx status code is an error. Response headers are in either +// *DnsThreatDetector.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 *ProjectsLocationsDnsThreatDetectorsCreateCall) Do(opts ...googleapi.CallOption) (*DnsThreatDetector, 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 := &DnsThreatDetector{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + b, err := gensupport.DecodeResponseBytes(target, res) + if err != nil { + return nil, err + } + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "networksecurity.projects.locations.dnsThreatDetectors.create", "response", internallog.HTTPResponse(res, b)) + return ret, nil +} + +type ProjectsLocationsDnsThreatDetectorsDeleteCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Delete: Deletes a single DnsThreatDetector. +// +// - name: Name of the DnsThreatDetector resource. +func (r *ProjectsLocationsDnsThreatDetectorsService) Delete(name string) *ProjectsLocationsDnsThreatDetectorsDeleteCall { + c := &ProjectsLocationsDnsThreatDetectorsDeleteCall{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 *ProjectsLocationsDnsThreatDetectorsDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsDnsThreatDetectorsDeleteCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsDnsThreatDetectorsDeleteCall) Context(ctx context.Context) *ProjectsLocationsDnsThreatDetectorsDeleteCall { + 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 *ProjectsLocationsDnsThreatDetectorsDeleteCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsDnsThreatDetectorsDeleteCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) + 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, nil) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "name": c.name, + }) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "networksecurity.projects.locations.dnsThreatDetectors.delete", "request", internallog.HTTPRequest(req, nil)) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "networksecurity.projects.locations.dnsThreatDetectors.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 *ProjectsLocationsDnsThreatDetectorsDeleteCall) 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 + b, err := gensupport.DecodeResponseBytes(target, res) + if err != nil { + return nil, err + } + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "networksecurity.projects.locations.dnsThreatDetectors.delete", "response", internallog.HTTPResponse(res, b)) + return ret, nil +} + +type ProjectsLocationsDnsThreatDetectorsGetCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// Get: Gets details of a single DnsThreatDetector. +// +// - name: Name of the DnsThreatDetector resource. +func (r *ProjectsLocationsDnsThreatDetectorsService) Get(name string) *ProjectsLocationsDnsThreatDetectorsGetCall { + c := &ProjectsLocationsDnsThreatDetectorsGetCall{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 *ProjectsLocationsDnsThreatDetectorsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsDnsThreatDetectorsGetCall { + 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 *ProjectsLocationsDnsThreatDetectorsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsDnsThreatDetectorsGetCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsDnsThreatDetectorsGetCall) Context(ctx context.Context) *ProjectsLocationsDnsThreatDetectorsGetCall { + 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 *ProjectsLocationsDnsThreatDetectorsGetCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsDnsThreatDetectorsGetCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) + } + 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, nil) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "name": c.name, + }) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "networksecurity.projects.locations.dnsThreatDetectors.get", "request", internallog.HTTPRequest(req, nil)) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "networksecurity.projects.locations.dnsThreatDetectors.get" call. +// Any non-2xx status code is an error. Response headers are in either +// *DnsThreatDetector.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 *ProjectsLocationsDnsThreatDetectorsGetCall) Do(opts ...googleapi.CallOption) (*DnsThreatDetector, 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 := &DnsThreatDetector{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + b, err := gensupport.DecodeResponseBytes(target, res) + if err != nil { + return nil, err + } + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "networksecurity.projects.locations.dnsThreatDetectors.get", "response", internallog.HTTPResponse(res, b)) + return ret, nil +} + +type ProjectsLocationsDnsThreatDetectorsListCall struct { + s *Service + parent string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// List: Lists DnsThreatDetectors in a given project and location. +// +// - parent: Parent value for ListDnsThreatDetectorsRequest. +func (r *ProjectsLocationsDnsThreatDetectorsService) List(parent string) *ProjectsLocationsDnsThreatDetectorsListCall { + c := &ProjectsLocationsDnsThreatDetectorsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + 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 *ProjectsLocationsDnsThreatDetectorsListCall) PageSize(pageSize int64) *ProjectsLocationsDnsThreatDetectorsListCall { + c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) + return c +} + +// PageToken sets the optional parameter "pageToken": A page token, received +// from a previous `ListDnsThreatDetectorsRequest` call. Provide this to +// retrieve the subsequent page. +func (c *ProjectsLocationsDnsThreatDetectorsListCall) PageToken(pageToken string) *ProjectsLocationsDnsThreatDetectorsListCall { + 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 *ProjectsLocationsDnsThreatDetectorsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsDnsThreatDetectorsListCall { + 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 *ProjectsLocationsDnsThreatDetectorsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsDnsThreatDetectorsListCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsDnsThreatDetectorsListCall) Context(ctx context.Context) *ProjectsLocationsDnsThreatDetectorsListCall { + 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 *ProjectsLocationsDnsThreatDetectorsListCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsDnsThreatDetectorsListCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+parent}/dnsThreatDetectors") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("GET", urls, nil) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "parent": c.parent, + }) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "networksecurity.projects.locations.dnsThreatDetectors.list", "request", internallog.HTTPRequest(req, nil)) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "networksecurity.projects.locations.dnsThreatDetectors.list" call. +// Any non-2xx status code is an error. Response headers are in either +// *ListDnsThreatDetectorsResponse.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 *ProjectsLocationsDnsThreatDetectorsListCall) Do(opts ...googleapi.CallOption) (*ListDnsThreatDetectorsResponse, 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 := &ListDnsThreatDetectorsResponse{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + b, err := gensupport.DecodeResponseBytes(target, res) + if err != nil { + return nil, err + } + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "networksecurity.projects.locations.dnsThreatDetectors.list", "response", internallog.HTTPResponse(res, b)) + 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 *ProjectsLocationsDnsThreatDetectorsListCall) Pages(ctx context.Context, f func(*ListDnsThreatDetectorsResponse) 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 ProjectsLocationsDnsThreatDetectorsPatchCall struct { + s *Service + name string + dnsthreatdetector *DnsThreatDetector + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Patch: Updates the parameters of a single DnsThreatDetector. +// +// - name: Immutable. Identifier. Name of the DnsThreatDetector resource. +func (r *ProjectsLocationsDnsThreatDetectorsService) Patch(name string, dnsthreatdetector *DnsThreatDetector) *ProjectsLocationsDnsThreatDetectorsPatchCall { + c := &ProjectsLocationsDnsThreatDetectorsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + c.dnsthreatdetector = dnsthreatdetector + return c +} + +// UpdateMask sets the optional parameter "updateMask": Field mask is used to +// specify the fields to be overwritten in the DnsThreatDetector 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 mask is not provided then all fields present in the request +// will be overwritten. +func (c *ProjectsLocationsDnsThreatDetectorsPatchCall) UpdateMask(updateMask string) *ProjectsLocationsDnsThreatDetectorsPatchCall { + 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 *ProjectsLocationsDnsThreatDetectorsPatchCall) Fields(s ...googleapi.Field) *ProjectsLocationsDnsThreatDetectorsPatchCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsDnsThreatDetectorsPatchCall) Context(ctx context.Context) *ProjectsLocationsDnsThreatDetectorsPatchCall { + 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 *ProjectsLocationsDnsThreatDetectorsPatchCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsDnsThreatDetectorsPatchCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) + body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.dnsthreatdetector) + 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, + }) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "networksecurity.projects.locations.dnsThreatDetectors.patch", "request", internallog.HTTPRequest(req, body.Bytes())) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "networksecurity.projects.locations.dnsThreatDetectors.patch" call. +// Any non-2xx status code is an error. Response headers are in either +// *DnsThreatDetector.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 *ProjectsLocationsDnsThreatDetectorsPatchCall) Do(opts ...googleapi.CallOption) (*DnsThreatDetector, 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 := &DnsThreatDetector{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + b, err := gensupport.DecodeResponseBytes(target, res) + if err != nil { + return nil, err + } + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "networksecurity.projects.locations.dnsThreatDetectors.patch", "response", internallog.HTTPResponse(res, b)) + return ret, nil +} + type ProjectsLocationsFirewallEndpointAssociationsCreateCall struct { s *Service parent string From e5c3e1801eaa85fa23ee046f1ffe8193c282b6fd Mon Sep 17 00:00:00 2001 From: Yoshi Automation Bot Date: Wed, 30 Jul 2025 00:36:23 -0700 Subject: [PATCH 08/10] feat(all): auto-regenerate discovery clients (#3251) --- accessapproval/v1/accessapproval-api.json | 8 +- accessapproval/v1/accessapproval-gen.go | 4 + bigtableadmin/v2/bigtableadmin-api.json | 57 +- bigtableadmin/v2/bigtableadmin-gen.go | 76 ++ chat/v1/chat-api.json | 20 +- chat/v1/chat-gen.go | 26 +- compute/v1/compute-api.json | 68 +- compute/v1/compute-gen.go | 74 +- compute/v1/compute2-gen.go | 13 +- compute/v1/compute3-gen.go | 9 + discoveryengine/v1/discoveryengine-api.json | 536 +++++++++++- discoveryengine/v1/discoveryengine-gen.go | 779 +++++++++++++++++- .../v1alpha/discoveryengine-api.json | 134 ++- .../v1alpha/discoveryengine-gen.go | 321 +++++++- .../v1beta/discoveryengine-api.json | 536 +++++++++++- discoveryengine/v1beta/discoveryengine-gen.go | 779 +++++++++++++++++- firebaseml/v2beta/firebaseml-api.json | 22 +- firebaseml/v2beta/firebaseml-gen.go | 39 + kmsinventory/v1/kmsinventory-api.json | 20 +- kmsinventory/v1/kmsinventory-gen.go | 10 + .../accounts_v1beta/merchantapi-api.json | 4 +- .../accounts_v1beta/merchantapi-gen.go | 5 +- .../inventories_v1beta/merchantapi-api.json | 14 +- .../inventories_v1beta/merchantapi-gen.go | 14 +- .../ordertracking_v1beta/merchantapi-api.json | 10 +- .../ordertracking_v1beta/merchantapi-gen.go | 36 +- .../products_v1beta/merchantapi-api.json | 12 +- .../products_v1beta/merchantapi-gen.go | 41 +- .../promotions_v1beta/merchantapi-api.json | 4 +- .../promotions_v1beta/merchantapi-gen.go | 17 +- retail/v2alpha/retail-api.json | 36 +- retail/v2alpha/retail-gen.go | 23 + 32 files changed, 3489 insertions(+), 258 deletions(-) diff --git a/accessapproval/v1/accessapproval-api.json b/accessapproval/v1/accessapproval-api.json index 2a9eaff68bb..dffe0f7a34d 100644 --- a/accessapproval/v1/accessapproval-api.json +++ b/accessapproval/v1/accessapproval-api.json @@ -913,7 +913,7 @@ } } }, - "revision": "20250617", + "revision": "20250728", "rootUrl": "https://accessapproval.googleapis.com/", "schemas": { "AccessApprovalServiceAccount": { @@ -1333,6 +1333,9 @@ "HMAC_SHA512", "HMAC_SHA224", "EXTERNAL_SYMMETRIC_ENCRYPTION", + "ML_KEM_768", + "ML_KEM_1024", + "KEM_XWING", "PQ_SIGN_ML_DSA_65", "PQ_SIGN_SLH_DSA_SHA2_128S", "PQ_SIGN_HASH_SLH_DSA_SHA2_128S_SHA256" @@ -1374,6 +1377,9 @@ "HMAC-SHA512 signing with a 512 bit key.", "HMAC-SHA224 signing with a 224 bit key.", "Algorithm representing symmetric encryption by an external key manager.", + "ML-KEM-768 (FIPS 203)", + "ML-KEM-1024 (FIPS 203)", + "X-Wing hybrid KEM combining ML-KEM-768 with X25519 following datatracker.ietf.org/doc/draft-connolly-cfrg-xwing-kem/.", "The post-quantum Module-Lattice-Based Digital Signature Algorithm, at security level 3. Randomized version.", "The post-quantum stateless hash-based digital signature algorithm, at security level 1. Randomized version.", "The post-quantum stateless hash-based digital signature algorithm, at security level 1. Randomized pre-hash version supporting SHA256 digests." diff --git a/accessapproval/v1/accessapproval-gen.go b/accessapproval/v1/accessapproval-gen.go index 2fcd9d5e0cb..529c64c3199 100644 --- a/accessapproval/v1/accessapproval-gen.go +++ b/accessapproval/v1/accessapproval-gen.go @@ -829,6 +829,10 @@ type SignatureInfo struct { // "HMAC_SHA224" - HMAC-SHA224 signing with a 224 bit key. // "EXTERNAL_SYMMETRIC_ENCRYPTION" - Algorithm representing symmetric // encryption by an external key manager. + // "ML_KEM_768" - ML-KEM-768 (FIPS 203) + // "ML_KEM_1024" - ML-KEM-1024 (FIPS 203) + // "KEM_XWING" - X-Wing hybrid KEM combining ML-KEM-768 with X25519 following + // datatracker.ietf.org/doc/draft-connolly-cfrg-xwing-kem/. // "PQ_SIGN_ML_DSA_65" - The post-quantum Module-Lattice-Based Digital // Signature Algorithm, at security level 3. Randomized version. // "PQ_SIGN_SLH_DSA_SHA2_128S" - The post-quantum stateless hash-based diff --git a/bigtableadmin/v2/bigtableadmin-api.json b/bigtableadmin/v2/bigtableadmin-api.json index f27bb2ecbdc..9e5ec826a8a 100644 --- a/bigtableadmin/v2/bigtableadmin-api.json +++ b/bigtableadmin/v2/bigtableadmin-api.json @@ -2933,6 +2933,23 @@ "pattern": "^projects/[^/]+/instances/[^/]+/tables/[^/]+$", "required": true, "type": "string" + }, + "view": { + "description": "Optional. The resource_view to be applied to the returned SchemaBundles' fields. Defaults to NAME_ONLY.", + "enum": [ + "SCHEMA_BUNDLE_VIEW_UNSPECIFIED", + "NAME_ONLY", + "BASIC", + "FULL" + ], + "enumDescriptions": [ + "Uses the default view for each method as documented in the request.", + "Only populates `name`.", + "Only populates the SchemaBundle's basic metadata. This includes: name, etag, create_time, update_time.", + "Populates every field." + ], + "location": "query", + "type": "string" } }, "path": "v2/{+parent}/schemaBundles", @@ -3151,7 +3168,7 @@ } } }, - "revision": "20250624", + "revision": "20250724", "rootUrl": "https://bigtableadmin.googleapis.com/", "schemas": { "AppProfile": { @@ -4343,6 +4360,21 @@ "properties": {}, "type": "object" }, + "GoogleBigtableAdminV2TypeEnum": { + "description": "A protobuf enum type. Values of type `Enum` are stored in `Value.int_value`.", + "id": "GoogleBigtableAdminV2TypeEnum", + "properties": { + "enumName": { + "description": "The fully qualified name of the protobuf enum message, including package. In the format of \"foo.bar.EnumMessage\".", + "type": "string" + }, + "schemaBundleId": { + "description": "The ID of the schema bundle that this enum is defined in.", + "type": "string" + } + }, + "type": "object" + }, "GoogleBigtableAdminV2TypeFloat32": { "description": "Float32 Values of type `Float32` are stored in `Value.float_value`.", "id": "GoogleBigtableAdminV2TypeFloat32", @@ -4414,6 +4446,21 @@ }, "type": "object" }, + "GoogleBigtableAdminV2TypeProto": { + "description": "A protobuf message type. Values of type `Proto` are stored in `Value.bytes_value`.", + "id": "GoogleBigtableAdminV2TypeProto", + "properties": { + "messageName": { + "description": "The fully qualified name of the protobuf message, including package. In the format of \"foo.bar.Message\".", + "type": "string" + }, + "schemaBundleId": { + "description": "The ID of the schema bundle that this proto is defined in.", + "type": "string" + } + }, + "type": "object" + }, "GoogleBigtableAdminV2TypeString": { "description": "String Values of type `String` are stored in `Value.string_value`.", "id": "GoogleBigtableAdminV2TypeString", @@ -5628,6 +5675,10 @@ "$ref": "GoogleBigtableAdminV2TypeDate", "description": "Date" }, + "enumType": { + "$ref": "GoogleBigtableAdminV2TypeEnum", + "description": "Enum" + }, "float32Type": { "$ref": "GoogleBigtableAdminV2TypeFloat32", "description": "Float32" @@ -5644,6 +5695,10 @@ "$ref": "GoogleBigtableAdminV2TypeMap", "description": "Map" }, + "protoType": { + "$ref": "GoogleBigtableAdminV2TypeProto", + "description": "Proto" + }, "stringType": { "$ref": "GoogleBigtableAdminV2TypeString", "description": "String" diff --git a/bigtableadmin/v2/bigtableadmin-gen.go b/bigtableadmin/v2/bigtableadmin-gen.go index 73edc4de59d..882b1d97184 100644 --- a/bigtableadmin/v2/bigtableadmin-gen.go +++ b/bigtableadmin/v2/bigtableadmin-gen.go @@ -2199,6 +2199,32 @@ func (s GoogleBigtableAdminV2TypeBytesEncodingRaw) MarshalJSON() ([]byte, error) type GoogleBigtableAdminV2TypeDate struct { } +// GoogleBigtableAdminV2TypeEnum: A protobuf enum type. Values of type `Enum` +// are stored in `Value.int_value`. +type GoogleBigtableAdminV2TypeEnum struct { + // EnumName: The fully qualified name of the protobuf enum message, including + // package. In the format of "foo.bar.EnumMessage". + EnumName string `json:"enumName,omitempty"` + // SchemaBundleId: The ID of the schema bundle that this enum is defined in. + SchemaBundleId string `json:"schemaBundleId,omitempty"` + // ForceSendFields is a list of field names (e.g. "EnumName") 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. "EnumName") 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 GoogleBigtableAdminV2TypeEnum) MarshalJSON() ([]byte, error) { + type NoMethod GoogleBigtableAdminV2TypeEnum + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleBigtableAdminV2TypeFloat32: Float32 Values of type `Float32` are // stored in `Value.float_value`. type GoogleBigtableAdminV2TypeFloat32 struct { @@ -2320,6 +2346,32 @@ func (s GoogleBigtableAdminV2TypeMap) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleBigtableAdminV2TypeProto: A protobuf message type. Values of type +// `Proto` are stored in `Value.bytes_value`. +type GoogleBigtableAdminV2TypeProto struct { + // MessageName: The fully qualified name of the protobuf message, including + // package. In the format of "foo.bar.Message". + MessageName string `json:"messageName,omitempty"` + // SchemaBundleId: The ID of the schema bundle that this proto is defined in. + SchemaBundleId string `json:"schemaBundleId,omitempty"` + // ForceSendFields is a list of field names (e.g. "MessageName") 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. "MessageName") 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 GoogleBigtableAdminV2TypeProto) MarshalJSON() ([]byte, error) { + type NoMethod GoogleBigtableAdminV2TypeProto + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleBigtableAdminV2TypeString: String Values of type `String` are stored // in `Value.string_value`. type GoogleBigtableAdminV2TypeString struct { @@ -4245,6 +4297,8 @@ type Type struct { BytesType *GoogleBigtableAdminV2TypeBytes `json:"bytesType,omitempty"` // DateType: Date DateType *GoogleBigtableAdminV2TypeDate `json:"dateType,omitempty"` + // EnumType: Enum + EnumType *GoogleBigtableAdminV2TypeEnum `json:"enumType,omitempty"` // Float32Type: Float32 Float32Type *GoogleBigtableAdminV2TypeFloat32 `json:"float32Type,omitempty"` // Float64Type: Float64 @@ -4253,6 +4307,8 @@ type Type struct { Int64Type *GoogleBigtableAdminV2TypeInt64 `json:"int64Type,omitempty"` // MapType: Map MapType *GoogleBigtableAdminV2TypeMap `json:"mapType,omitempty"` + // ProtoType: Proto + ProtoType *GoogleBigtableAdminV2TypeProto `json:"protoType,omitempty"` // StringType: String StringType *GoogleBigtableAdminV2TypeString `json:"stringType,omitempty"` // StructType: Struct @@ -13480,6 +13536,26 @@ func (c *ProjectsInstancesTablesSchemaBundlesListCall) PageToken(pageToken strin return c } +// View sets the optional parameter "view": The resource_view to be applied to +// the returned SchemaBundles' fields. Defaults to NAME_ONLY. +// +// Possible values: +// +// "SCHEMA_BUNDLE_VIEW_UNSPECIFIED" - Uses the default view for each method +// +// as documented in the request. +// +// "NAME_ONLY" - Only populates `name`. +// "BASIC" - Only populates the SchemaBundle's basic metadata. This includes: +// +// name, etag, create_time, update_time. +// +// "FULL" - Populates every field. +func (c *ProjectsInstancesTablesSchemaBundlesListCall) View(view string) *ProjectsInstancesTablesSchemaBundlesListCall { + 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. diff --git a/chat/v1/chat-api.json b/chat/v1/chat-api.json index f98b24cf141..eb63b049db5 100644 --- a/chat/v1/chat-api.json +++ b/chat/v1/chat-api.json @@ -1528,7 +1528,7 @@ } } }, - "revision": "20250720", + "revision": "20250724", "rootUrl": "https://chat.googleapis.com/", "schemas": { "AccessSettings": { @@ -1678,7 +1678,7 @@ "type": "object" }, "Annotation": { - "description": "Annotations can be associated with the plain-text body of the message or with chips that link to Google Workspace resources like Google Docs or Sheets with a `start_index` and `length` of 0. To add basic formatting to a text message, see [Format text messages](https://developers.google.com/workspace/chat/format-messages). Example plain-text message body: ``` Hello @FooBot how are you!\" ``` The corresponding annotations metadata: ``` \"annotations\":[{ \"type\":\"USER_MENTION\", \"startIndex\":6, \"length\":7, \"userMention\": { \"user\": { \"name\":\"users/{user}\", \"displayName\":\"FooBot\", \"avatarUrl\":\"https://goo.gl/aeDtrS/", \"type\":\"BOT\" }, \"type\":\"MENTION\" } }] ```", + "description": "Output only. Annotations can be associated with the plain-text body of the message or with chips that link to Google Workspace resources like Google Docs or Sheets with `start_index` and `length` of 0. To add basic formatting to a text message, see [Format text messages](https://developers.google.com/workspace/chat/format-messages). Example plain-text message body: ``` Hello @FooBot how are you!\" ``` The corresponding annotations metadata: ``` \"annotations\":[{ \"type\":\"USER_MENTION\", \"startIndex\":6, \"length\":7, \"userMention\": { \"user\": { \"name\":\"users/{user}\", \"displayName\":\"FooBot\", \"avatarUrl\":\"https://goo.gl/aeDtrS/", \"type\":\"BOT\" }, \"type\":\"MENTION\" } }] ```", "id": "Annotation", "properties": { "customEmojiMetadata": { @@ -4187,8 +4187,8 @@ "enumDescriptions": [ "Default value for the enum. Don't use.", "The huddle has started.", - "The huddle has ended. In this case the meet space URI and identifiers will no longer be valid.", - "The huddle has been missed. In this case the meet space URI and identifiers will no longer be valid." + "The huddle has ended. In this case the Meet space URI and identifiers will no longer be valid.", + "The huddle has been missed. In this case the Meet space URI and identifiers will no longer be valid." ], "readOnly": true, "type": "string" @@ -4206,8 +4206,8 @@ ], "enumDescriptions": [ "Default value for the enum. Don't use.", - "The meet space is a meeting.", - "The meet space is a huddle." + "The Meet space is a meeting.", + "The Meet space is a huddle." ], "type": "string" } @@ -4384,7 +4384,7 @@ "description": "Input only. Parameters that a Chat app can use to configure how its response is posted." }, "annotations": { - "description": "Output only. Annotations can be associated with the plain-text body of the message or with chips that link to Google Workspace resources like Google Docs or Sheets with a `start_index` and `length` of 0.", + "description": "Output only. Annotations can be associated with the plain-text body of the message or with chips that link to Google Workspace resources like Google Docs or Sheets with `start_index` and `length` of 0.", "items": { "$ref": "Annotation" }, @@ -4763,12 +4763,12 @@ "type": "object" }, "RichLinkMetadata": { - "description": "A rich link to a resource. Rich links can be associated with the plain-text body of the message or represent chips that link to Google Workspace resources like Google Docs or Sheets with a with `start_index` and `length` of 0.", + "description": "A rich link to a resource. Rich links can be associated with the plain-text body of the message or represent chips that link to Google Workspace resources like Google Docs or Sheets with `start_index` and `length` of 0.", "id": "RichLinkMetadata", "properties": { "calendarEventLinkData": { "$ref": "CalendarEventLinkData", - "description": "Data for a calendar event link." + "description": "Data for a Calendar event link." }, "chatSpaceLinkData": { "$ref": "ChatSpaceLinkData", @@ -4780,7 +4780,7 @@ }, "meetSpaceLinkData": { "$ref": "MeetSpaceLinkData", - "description": "Data for a meet space link." + "description": "Data for a Meet space link." }, "richLinkType": { "description": "The rich link type.", diff --git a/chat/v1/chat-gen.go b/chat/v1/chat-gen.go index d7ec9c59334..3eae36a1018 100644 --- a/chat/v1/chat-gen.go +++ b/chat/v1/chat-gen.go @@ -688,10 +688,10 @@ func (s ActionStatus) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// Annotation: Annotations can be associated with the plain-text body of the -// message or with chips that link to Google Workspace resources like Google -// Docs or Sheets with a `start_index` and `length` of 0. To add basic -// formatting to a text message, see Format text messages +// Annotation: Output only. Annotations can be associated with the plain-text +// body of the message or with chips that link to Google Workspace resources +// like Google Docs or Sheets with `start_index` and `length` of 0. To add +// basic formatting to a text message, see Format text messages // (https://developers.google.com/workspace/chat/format-messages). Example // plain-text message body: ``` Hello @FooBot how are you!" ``` The // corresponding annotations metadata: ``` "annotations":[{ @@ -4463,9 +4463,9 @@ type MeetSpaceLinkData struct { // Possible values: // "HUDDLE_STATUS_UNSPECIFIED" - Default value for the enum. Don't use. // "STARTED" - The huddle has started. - // "ENDED" - The huddle has ended. In this case the meet space URI and + // "ENDED" - The huddle has ended. In this case the Meet space URI and // identifiers will no longer be valid. - // "MISSED" - The huddle has been missed. In this case the meet space URI and + // "MISSED" - The huddle has been missed. In this case the Meet space URI and // identifiers will no longer be valid. HuddleStatus string `json:"huddleStatus,omitempty"` // MeetingCode: Meeting code of the linked Meet space. @@ -4474,8 +4474,8 @@ type MeetSpaceLinkData struct { // // Possible values: // "TYPE_UNSPECIFIED" - Default value for the enum. Don't use. - // "MEETING" - The meet space is a meeting. - // "HUDDLE" - The meet space is a huddle. + // "MEETING" - The Meet space is a meeting. + // "HUDDLE" - The Meet space is a huddle. Type string `json:"type,omitempty"` // ForceSendFields is a list of field names (e.g. "HuddleStatus") to // unconditionally include in API requests. By default, fields with empty or @@ -4752,7 +4752,7 @@ type Message struct { ActionResponse *ActionResponse `json:"actionResponse,omitempty"` // Annotations: Output only. Annotations can be associated with the plain-text // body of the message or with chips that link to Google Workspace resources - // like Google Docs or Sheets with a `start_index` and `length` of 0. + // like Google Docs or Sheets with `start_index` and `length` of 0. Annotations []*Annotation `json:"annotations,omitempty"` // ArgumentText: Output only. Plain-text body of the message with all Chat app // mentions stripped out. @@ -5306,16 +5306,16 @@ func (s ReactionDeletedEventData) MarshalJSON() ([]byte, error) { // RichLinkMetadata: A rich link to a resource. Rich links can be associated // with the plain-text body of the message or represent chips that link to -// Google Workspace resources like Google Docs or Sheets with a with -// `start_index` and `length` of 0. +// Google Workspace resources like Google Docs or Sheets with `start_index` and +// `length` of 0. type RichLinkMetadata struct { - // CalendarEventLinkData: Data for a calendar event link. + // CalendarEventLinkData: Data for a Calendar event link. CalendarEventLinkData *CalendarEventLinkData `json:"calendarEventLinkData,omitempty"` // ChatSpaceLinkData: Data for a chat space link. ChatSpaceLinkData *ChatSpaceLinkData `json:"chatSpaceLinkData,omitempty"` // DriveLinkData: Data for a drive link. DriveLinkData *DriveLinkData `json:"driveLinkData,omitempty"` - // MeetSpaceLinkData: Data for a meet space link. + // MeetSpaceLinkData: Data for a Meet space link. MeetSpaceLinkData *MeetSpaceLinkData `json:"meetSpaceLinkData,omitempty"` // RichLinkType: The rich link type. // diff --git a/compute/v1/compute-api.json b/compute/v1/compute-api.json index c9a5609bf95..e361bc3105d 100644 --- a/compute/v1/compute-api.json +++ b/compute/v1/compute-api.json @@ -2665,6 +2665,7 @@ "disk": { "description": "Name of the persistent disk to delete.", "location": "path", + "pattern": "\\S{1,66}", "required": true, "type": "string" }, @@ -5971,14 +5972,14 @@ ], "parameters": { "operation": { - "description": "Name of the Operations resource to return, or its unique numeric identifier.", + "description": "Name of the Operations resource to return. Parent is derived from this field.", "location": "path", "pattern": "[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?|[1-9][0-9]{0,19}", "required": true, "type": "string" }, "parentId": { - "description": "Parent ID for this request.", + "description": "Parent ID for this request. Not used. Parent is derived from resource_id.", "location": "query", "type": "string" } @@ -7350,10 +7351,7 @@ }, "scopes": [ "https://www.googleapis.com/auth/cloud-platform", - "https://www.googleapis.com/auth/compute", - "https://www.googleapis.com/auth/devstorage.full_control", - "https://www.googleapis.com/auth/devstorage.read_only", - "https://www.googleapis.com/auth/devstorage.read_write" + "https://www.googleapis.com/auth/compute" ] }, "list": { @@ -22622,6 +22620,7 @@ "disk": { "description": "Name of the regional persistent disk to delete.", "location": "path", + "pattern": "\\S{1,66}", "required": true, "type": "string" }, @@ -35392,6 +35391,11 @@ "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" + }, + "serviceProject": { + "description": "The project id or project number in which the subnetwork is intended to be used. Only applied for Shared VPC. See [Shared VPC documentation](https://cloud.google.com/vpc/docs/shared-vpc/)", + "location": "query", + "type": "string" } }, "path": "projects/{project}/aggregated/subnetworks/listUsable", @@ -39950,7 +39954,7 @@ } } }, - "revision": "20250717", + "revision": "20250728", "rootUrl": "https://compute.googleapis.com/", "schemas": { "AWSV4Signature": { @@ -43090,7 +43094,7 @@ "type": "number" }, "name": { - "description": "Name of a custom utilization signal. The name must be 1-64 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, period, underscore, lowercase letter, or digit, except the last character, which cannot be a dash, period, or underscore. For usage guidelines, see Custom Metrics balancing mode. This field can only be used for a global or regional backend service with the loadBalancingScheme set to EXTERNAL_MANAGED, INTERNAL_MANAGED INTERNAL_SELF_MANAGED.", + "description": "Name of a custom utilization signal. The name must be 1-64 characters long and match the regular expression [a-z]([-_.a-z0-9]*[a-z0-9])? which means that the first character must be a lowercase letter, and all following characters must be a dash, period, underscore, lowercase letter, or digit, except the last character, which cannot be a dash, period, or underscore. For usage guidelines, see Custom Metrics balancing mode. This field can only be used for a global or regional backend service with the loadBalancingScheme set to EXTERNAL_MANAGED, INTERNAL_MANAGED INTERNAL_SELF_MANAGED.", "type": "string" } }, @@ -43277,7 +43281,7 @@ "type": "array" }, "localityLbPolicy": { - "description": "The load balancing algorithm used within the scope of the locality. The possible values are: - ROUND_ROBIN: This is a simple policy in which each healthy backend is selected in round robin order. This is the default. - LEAST_REQUEST: An O(1) algorithm which selects two random healthy hosts and picks the host which has fewer active requests. - RING_HASH: The ring/modulo hash load balancer implements consistent hashing to backends. The algorithm has the property that the addition/removal of a host from a set of N hosts only affects 1/N of the requests. - RANDOM: The load balancer selects a random healthy host. - ORIGINAL_DESTINATION: Backend host is selected based on the client connection metadata, i.e., connections are opened to the same address as the destination address of the incoming connection before the connection was redirected to the load balancer. - MAGLEV: used as a drop in replacement for the ring hash load balancer. Maglev is not as stable as ring hash but has faster table lookup build times and host selection times. For more information about Maglev, see https://ai.google/research/pubs/pub44824 This field is applicable to either: - A regional backend service with the service_protocol set to HTTP, HTTPS, HTTP2 or H2C, and load_balancing_scheme set to INTERNAL_MANAGED. - A global backend service with the load_balancing_scheme set to INTERNAL_SELF_MANAGED, INTERNAL_MANAGED, or EXTERNAL_MANAGED. If sessionAffinity is not configured—that is, if session affinity remains at the default value of NONE—then the default value for localityLbPolicy is ROUND_ROBIN. If session affinity is set to a value other than NONE, then the default value for localityLbPolicy is MAGLEV. Only ROUND_ROBIN and RING_HASH are supported when the backend service is referenced by a URL map that is bound to target gRPC proxy that has validateForProxyless field set to true. localityLbPolicy cannot be specified with haPolicy.", + "description": "The load balancing algorithm used within the scope of the locality. The possible values are: - ROUND_ROBIN: This is a simple policy in which each healthy backend is selected in round robin order. This is the default. - LEAST_REQUEST: An O(1) algorithm which selects two random healthy hosts and picks the host which has fewer active requests. - RING_HASH: The ring/modulo hash load balancer implements consistent hashing to backends. The algorithm has the property that the addition/removal of a host from a set of N hosts only affects 1/N of the requests. - RANDOM: The load balancer selects a random healthy host. - ORIGINAL_DESTINATION: Backend host is selected based on the client connection metadata, i.e., connections are opened to the same address as the destination address of the incoming connection before the connection was redirected to the load balancer. - MAGLEV: used as a drop in replacement for the ring hash load balancer. Maglev is not as stable as ring hash but has faster table lookup build times and host selection times. For more information about Maglev, see https://ai.google/research/pubs/pub44824 - WEIGHTED_ROUND_ROBIN: Per-endpoint Weighted Round Robin Load Balancing using weights computed from Backend reported Custom Metrics. If set, the Backend Service responses are expected to contain non-standard HTTP response header field Endpoint-Load-Metrics. The reported metrics to use for computing the weights are specified via the customMetrics field. This field is applicable to either: - A regional backend service with the service_protocol set to HTTP, HTTPS, HTTP2 or H2C, and load_balancing_scheme set to INTERNAL_MANAGED. - A global backend service with the load_balancing_scheme set to INTERNAL_SELF_MANAGED, INTERNAL_MANAGED, or EXTERNAL_MANAGED. If sessionAffinity is not configured—that is, if session affinity remains at the default value of NONE—then the default value for localityLbPolicy is ROUND_ROBIN. If session affinity is set to a value other than NONE, then the default value for localityLbPolicy is MAGLEV. Only ROUND_ROBIN and RING_HASH are supported when the backend service is referenced by a URL map that is bound to target gRPC proxy that has validateForProxyless field set to true. localityLbPolicy cannot be specified with haPolicy.", "enum": [ "INVALID_LB_POLICY", "LEAST_REQUEST", @@ -43298,7 +43302,7 @@ "The ring/modulo hash load balancer implements consistent hashing to backends. The algorithm has the property that the addition/removal of a host from a set of N hosts only affects 1/N of the requests.", "This is a simple policy in which each healthy backend is selected in round robin order. This is the default.", "Per-instance weighted Load Balancing via health check reported weights. If set, the Backend Service must configure a non legacy HTTP-based Health Check, and health check replies are expected to contain non-standard HTTP response header field X-Load-Balancing-Endpoint-Weight to specify the per-instance weights. If set, Load Balancing is weighted based on the per-instance weights reported in the last processed health check replies, as long as every instance either reported a valid weight or had UNAVAILABLE_WEIGHT. Otherwise, Load Balancing remains equal-weight. This option is only supported in Network Load Balancing.", - "Per-endpoint weighted round-robin Load Balancing using weights computed from Backend reported Custom Metrics. If set, the Backend Service responses are expected to contain non-standard HTTP response header field X-Endpoint-Load-Metrics. The reported metrics to use for computing the weights are specified via the backends[].customMetrics fields." + "Per-endpoint weighted round-robin Load Balancing using weights computed from Backend reported Custom Metrics. If set, the Backend Service responses are expected to contain non-standard HTTP response header field Endpoint-Load-Metrics. The reported metrics to use for computing the weights are specified via the customMetrics fields." ], "type": "string" }, @@ -43771,7 +43775,7 @@ "type": "boolean" }, "name": { - "description": "Name of a custom utilization signal. The name must be 1-64 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, period, underscore, lowercase letter, or digit, except the last character, which cannot be a dash, period, or underscore. For usage guidelines, see Custom Metrics balancing mode. This field can only be used for a global or regional backend service with the loadBalancingScheme set to EXTERNAL_MANAGED, INTERNAL_MANAGED INTERNAL_SELF_MANAGED.", + "description": "Name of a custom utilization signal. The name must be 1-64 characters long and match the regular expression [a-z]([-_.a-z0-9]*[a-z0-9])? which means that the first character must be a lowercase letter, and all following characters must be a dash, period, underscore, lowercase letter, or digit, except the last character, which cannot be a dash, period, or underscore. For usage guidelines, see Custom Metrics balancing mode. This field can only be used for a global or regional backend service with the loadBalancingScheme set to EXTERNAL_MANAGED, INTERNAL_MANAGED INTERNAL_SELF_MANAGED.", "type": "string" } }, @@ -44274,7 +44278,7 @@ "The ring/modulo hash load balancer implements consistent hashing to backends. The algorithm has the property that the addition/removal of a host from a set of N hosts only affects 1/N of the requests.", "This is a simple policy in which each healthy backend is selected in round robin order. This is the default.", "Per-instance weighted Load Balancing via health check reported weights. If set, the Backend Service must configure a non legacy HTTP-based Health Check, and health check replies are expected to contain non-standard HTTP response header field X-Load-Balancing-Endpoint-Weight to specify the per-instance weights. If set, Load Balancing is weighted based on the per-instance weights reported in the last processed health check replies, as long as every instance either reported a valid weight or had UNAVAILABLE_WEIGHT. Otherwise, Load Balancing remains equal-weight. This option is only supported in Network Load Balancing.", - "Per-endpoint weighted round-robin Load Balancing using weights computed from Backend reported Custom Metrics. If set, the Backend Service responses are expected to contain non-standard HTTP response header field X-Endpoint-Load-Metrics. The reported metrics to use for computing the weights are specified via the backends[].customMetrics fields." + "Per-endpoint weighted round-robin Load Balancing using weights computed from Backend reported Custom Metrics. If set, the Backend Service responses are expected to contain non-standard HTTP response header field Endpoint-Load-Metrics. The reported metrics to use for computing the weights are specified via the customMetrics fields." ], "type": "string" } @@ -75935,11 +75939,6 @@ "type": "string" }, "tags": { - "annotations": { - "required": [ - "compute.routes.insert" - ] - }, "description": "A list of instance tags to which this route applies.", "items": { "type": "string" @@ -79774,7 +79773,7 @@ "type": "string" }, "type": { - "description": "Type of the redirect action.", + "description": "Type of the redirect action. Possible values are: - GOOGLE_RECAPTCHA: redirect to reCAPTCHA for manual challenge assessment. - EXTERNAL_302: redirect to a different URL via a 302 response. ", "enum": [ "EXTERNAL_302", "GOOGLE_RECAPTCHA" @@ -79943,7 +79942,7 @@ "type": "string" }, "consumerAcceptLists": { - "description": "Specifies which consumer projects or networks are allowed to connect to the service attachment. Each project or network has a connection limit. A given service attachment can manage connections at either the project or network level. Therefore, both the accept and reject lists for a given service attachment must contain either only projects or only networks.", + "description": "Specifies which consumer projects or networks are allowed to connect to the service attachment. Each project or network has a connection limit. A given service attachment can manage connections at either the project or network level. Therefore, both the accept and reject lists for a given service attachment must contain either only projects or only networks or only endpoints.", "items": { "$ref": "ServiceAttachmentConsumerProjectLimit" }, @@ -79990,6 +79989,13 @@ "description": "[Output Only] Type of the resource. Always compute#serviceAttachment for service attachments.", "type": "string" }, + "metadata": { + "additionalProperties": { + "type": "string" + }, + "description": "Metadata of the service attachment.", + "type": "object" + }, "name": { "annotations": { "required": [ @@ -80252,7 +80258,7 @@ "id": "ServiceAttachmentConsumerProjectLimit", "properties": { "connectionLimit": { - "description": "The value of the limit to set.", + "description": "The value of the limit to set. For endpoint_url, the limit should be no more than 1.", "format": "uint32", "type": "integer" }, @@ -82752,7 +82758,7 @@ "compute.storagePools.insert" ] }, - "description": "Size, in GiB, of the storage pool. For more information about the size limits, see https://cloud.google.com/compute/docs/disks/storage-pools.", + "description": "Size of the storage pool in GiB. For more information about the size limits, see https://cloud.google.com/compute/docs/disks/storage-pools.", "format": "int64", "type": "string" }, @@ -82762,7 +82768,7 @@ "type": "string" }, "poolProvisionedThroughput": { - "description": "Provisioned throughput of the storage pool. Only relevant if the storage pool type is hyperdisk-balanced or hyperdisk-throughput.", + "description": "Provisioned throughput of the storage pool in MiB/s. Only relevant if the storage pool type is hyperdisk-balanced or hyperdisk-throughput.", "format": "int64", "type": "string" }, @@ -83393,7 +83399,7 @@ "type": "string" }, "maxTotalProvisionedDiskCapacityGb": { - "description": "[Output Only] Maximum allowed aggregate disk size in gigabytes.", + "description": "[Output Only] Maximum allowed aggregate disk size in GiB.", "format": "int64", "type": "string" }, @@ -83408,7 +83414,7 @@ "type": "string" }, "poolUsedThroughput": { - "description": "[Output Only] Sum of all the disks' provisioned throughput in MB/s.", + "description": "[Output Only] Sum of all the disks' provisioned throughput in MiB/s.", "format": "int64", "type": "string" }, @@ -83418,7 +83424,7 @@ "type": "string" }, "totalProvisionedDiskCapacityGb": { - "description": "[Output Only] Sum of all the capacity provisioned in disks in this storage pool. A disk's provisioned capacity is the same as its total capacity.", + "description": "[Output Only] Sum of all the disks' provisioned capacity (in GiB) in this storage pool. A disk's provisioned capacity is the same as its total capacity.", "format": "int64", "type": "string" }, @@ -83428,7 +83434,7 @@ "type": "string" }, "totalProvisionedDiskThroughput": { - "description": "[Output Only] Sum of all the disks' provisioned throughput in MB/s, minus some amount that is allowed per disk that is not counted towards pool's throughput capacity.", + "description": "[Output Only] Sum of all the disks' provisioned throughput in MiB/s, minus some amount that is allowed per disk that is not counted towards pool's throughput capacity.", "format": "int64", "type": "string" } @@ -88922,7 +88928,9 @@ "FAILURE_NETWORK", "FAILURE_NVLINK", "INFRASTRUCTURE_RELOCATION", - "MAINTENANCE_REASON_UNKNOWN" + "MAINTENANCE_REASON_UNKNOWN", + "PLANNED_NETWORK_UPDATE", + "PLANNED_UPDATE" ], "enumDescriptions": [ "Maintenance due to disk errors.", @@ -88935,7 +88943,9 @@ "Maintenance due to network errors.", "Maintenance due to NVLink failure.", "Maintenance due to infrastructure relocation.", - "Unknown maintenance reason. Do not use this value." + "Unknown maintenance reason. Do not use this value.", + "Maintenance due to planned network update.", + "Maintenance due to planned update to the instance." ], "type": "string" }, @@ -88957,11 +88967,13 @@ "type": { "description": "Defines the type of maintenance.", "enum": [ + "MULTIPLE", "SCHEDULED", "UNKNOWN_TYPE", "UNSCHEDULED" ], "enumDescriptions": [ + "Multiple maintenance types in one window. This is only intended to be used for groups.", "Scheduled maintenance (e.g. maintenance after uptime guarantee is complete).", "No type specified. Do not use this value.", "Unscheduled maintenance (e.g. emergency maintenance during uptime guarantee)." diff --git a/compute/v1/compute-gen.go b/compute/v1/compute-gen.go index a2e09312939..2779332d6bf 100644 --- a/compute/v1/compute-gen.go +++ b/compute/v1/compute-gen.go @@ -5069,7 +5069,7 @@ type BackendCustomMetric struct { MaxUtilization float64 `json:"maxUtilization,omitempty"` // Name: Name of a custom utilization signal. The name must be 1-64 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 + // means that the first character must be a lowercase letter, and all following // characters must be a dash, period, underscore, lowercase letter, or digit, // except the last character, which cannot be a dash, period, or underscore. // For usage guidelines, see Custom Metrics balancing mode. This field can only @@ -5342,18 +5342,23 @@ type BackendService struct { // MAGLEV: used as a drop in replacement for the ring hash load balancer. // Maglev is not as stable as ring hash but has faster table lookup build times // and host selection times. For more information about Maglev, see - // https://ai.google/research/pubs/pub44824 This field is applicable to either: - // - A regional backend service with the service_protocol set to HTTP, HTTPS, - // HTTP2 or H2C, and load_balancing_scheme set to INTERNAL_MANAGED. - A global - // backend service with the load_balancing_scheme set to INTERNAL_SELF_MANAGED, - // INTERNAL_MANAGED, or EXTERNAL_MANAGED. If sessionAffinity is not - // configured—that is, if session affinity remains at the default value of - // NONE—then the default value for localityLbPolicy is ROUND_ROBIN. If - // session affinity is set to a value other than NONE, then the default value - // for localityLbPolicy is MAGLEV. Only ROUND_ROBIN and RING_HASH are supported - // when the backend service is referenced by a URL map that is bound to target - // gRPC proxy that has validateForProxyless field set to true. localityLbPolicy - // cannot be specified with haPolicy. + // https://ai.google/research/pubs/pub44824 - WEIGHTED_ROUND_ROBIN: + // Per-endpoint Weighted Round Robin Load Balancing using weights computed from + // Backend reported Custom Metrics. If set, the Backend Service responses are + // expected to contain non-standard HTTP response header field + // Endpoint-Load-Metrics. The reported metrics to use for computing the weights + // are specified via the customMetrics field. This field is applicable to + // either: - A regional backend service with the service_protocol set to HTTP, + // HTTPS, HTTP2 or H2C, and load_balancing_scheme set to INTERNAL_MANAGED. - A + // global backend service with the load_balancing_scheme set to + // INTERNAL_SELF_MANAGED, INTERNAL_MANAGED, or EXTERNAL_MANAGED. If + // sessionAffinity is not configured—that is, if session affinity remains at + // the default value of NONE—then the default value for localityLbPolicy is + // ROUND_ROBIN. If session affinity is set to a value other than NONE, then the + // default value for localityLbPolicy is MAGLEV. Only ROUND_ROBIN and RING_HASH + // are supported when the backend service is referenced by a URL map that is + // bound to target gRPC proxy that has validateForProxyless field set to true. + // localityLbPolicy cannot be specified with haPolicy. // // Possible values: // "INVALID_LB_POLICY" @@ -5387,8 +5392,8 @@ type BackendService struct { // "WEIGHTED_ROUND_ROBIN" - Per-endpoint weighted round-robin Load Balancing // using weights computed from Backend reported Custom Metrics. If set, the // Backend Service responses are expected to contain non-standard HTTP response - // header field X-Endpoint-Load-Metrics. The reported metrics to use for - // computing the weights are specified via the backends[].customMetrics fields. + // header field Endpoint-Load-Metrics. The reported metrics to use for + // computing the weights are specified via the customMetrics fields. LocalityLbPolicy string `json:"localityLbPolicy,omitempty"` // LogConfig: This field denotes the logging options for the load balancer // traffic served by this backend service. If logging is enabled, logs will be @@ -6018,7 +6023,7 @@ type BackendServiceCustomMetric struct { DryRun bool `json:"dryRun,omitempty"` // Name: Name of a custom utilization signal. The name must be 1-64 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 + // means that the first character must be a lowercase letter, and all following // characters must be a dash, period, underscore, lowercase letter, or digit, // except the last character, which cannot be a dash, period, or underscore. // For usage guidelines, see Custom Metrics balancing mode. This field can only @@ -6754,8 +6759,8 @@ type BackendServiceLocalityLoadBalancingPolicyConfigPolicy struct { // "WEIGHTED_ROUND_ROBIN" - Per-endpoint weighted round-robin Load Balancing // using weights computed from Backend reported Custom Metrics. If set, the // Backend Service responses are expected to contain non-standard HTTP response - // header field X-Endpoint-Load-Metrics. The reported metrics to use for - // computing the weights are specified via the backends[].customMetrics fields. + // header field Endpoint-Load-Metrics. The reported metrics to use for + // computing the weights are specified via the customMetrics fields. 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 @@ -46075,7 +46080,9 @@ type SecurityPolicyRuleRedirectOptions struct { // Target: Target for the redirect action. This is required if the type is // EXTERNAL_302 and cannot be specified for GOOGLE_RECAPTCHA. Target string `json:"target,omitempty"` - // Type: Type of the redirect action. + // Type: Type of the redirect action. Possible values are: - GOOGLE_RECAPTCHA: + // redirect to reCAPTCHA for manual challenge assessment. - EXTERNAL_302: + // redirect to a different URL via a 302 response. // // Possible values: // "EXTERNAL_302" @@ -46303,7 +46310,7 @@ type ServiceAttachment struct { // connection limit. A given service attachment can manage connections at // either the project or network level. Therefore, both the accept and reject // lists for a given service attachment must contain either only projects or - // only networks. + // only networks or only endpoints. ConsumerAcceptLists []*ServiceAttachmentConsumerProjectLimit `json:"consumerAcceptLists,omitempty"` // ConsumerRejectLists: Specifies a list of projects or networks that are not // allowed to connect to this service attachment. The project can be specified @@ -46340,6 +46347,8 @@ type ServiceAttachment struct { // Kind: [Output Only] Type of the resource. Always compute#serviceAttachment // for service attachments. Kind string `json:"kind,omitempty"` + // Metadata: Metadata of the service attachment. + Metadata map[string]string `json:"metadata,omitempty"` // Name: Name of the resource. Provided by the client when the resource is // created. The name must be 1-63 characters long, and comply with RFC1035. // Specifically, the name must be 1-63 characters long and match the regular @@ -46613,7 +46622,8 @@ func (s ServiceAttachmentConnectedEndpoint) MarshalJSON() ([]byte, error) { } type ServiceAttachmentConsumerProjectLimit struct { - // ConnectionLimit: The value of the limit to set. + // ConnectionLimit: The value of the limit to set. For endpoint_url, the limit + // should be no more than 1. ConnectionLimit int64 `json:"connectionLimit,omitempty"` // NetworkUrl: The network URL for the network to set the limit for. NetworkUrl string `json:"networkUrl,omitempty"` @@ -49275,15 +49285,15 @@ type StoragePool struct { // pool disks' exclusive use. // "UNSPECIFIED" PerformanceProvisioningType string `json:"performanceProvisioningType,omitempty"` - // PoolProvisionedCapacityGb: Size, in GiB, of the storage pool. For more + // PoolProvisionedCapacityGb: Size of the storage pool in GiB. For more // information about the size limits, see // https://cloud.google.com/compute/docs/disks/storage-pools. PoolProvisionedCapacityGb int64 `json:"poolProvisionedCapacityGb,omitempty,string"` // PoolProvisionedIops: Provisioned IOPS of the storage pool. Only relevant if // the storage pool type is hyperdisk-balanced. PoolProvisionedIops int64 `json:"poolProvisionedIops,omitempty,string"` - // PoolProvisionedThroughput: Provisioned throughput of the storage pool. Only - // relevant if the storage pool type is hyperdisk-balanced or + // PoolProvisionedThroughput: Provisioned throughput of the storage pool in + // MiB/s. Only relevant if the storage pool type is hyperdisk-balanced or // hyperdisk-throughput. PoolProvisionedThroughput int64 `json:"poolProvisionedThroughput,omitempty,string"` // ResourceStatus: [Output Only] Status information for the storage pool @@ -49873,7 +49883,7 @@ type StoragePoolResourceStatus struct { // in RFC3339 text format. LastResizeTimestamp string `json:"lastResizeTimestamp,omitempty"` // MaxTotalProvisionedDiskCapacityGb: [Output Only] Maximum allowed aggregate - // disk size in gigabytes. + // disk size in GiB. MaxTotalProvisionedDiskCapacityGb int64 `json:"maxTotalProvisionedDiskCapacityGb,omitempty,string"` // PoolUsedCapacityBytes: [Output Only] Space used by data stored in disks // within the storage pool (in bytes). This will reflect the total number of @@ -49886,20 +49896,20 @@ type StoragePoolResourceStatus struct { // https://cloud.google.com/compute/docs/disks/storage-pools. PoolUsedIops int64 `json:"poolUsedIops,omitempty,string"` // PoolUsedThroughput: [Output Only] Sum of all the disks' provisioned - // throughput in MB/s. + // throughput in MiB/s. PoolUsedThroughput int64 `json:"poolUsedThroughput,omitempty,string"` // PoolUserWrittenBytes: [Output Only] Amount of data written into the pool, // before it is compacted. PoolUserWrittenBytes int64 `json:"poolUserWrittenBytes,omitempty,string"` - // TotalProvisionedDiskCapacityGb: [Output Only] Sum of all the capacity - // provisioned in disks in this storage pool. A disk's provisioned capacity is - // the same as its total capacity. + // TotalProvisionedDiskCapacityGb: [Output Only] Sum of all the disks' + // provisioned capacity (in GiB) in this storage pool. A disk's provisioned + // capacity is the same as its total capacity. TotalProvisionedDiskCapacityGb int64 `json:"totalProvisionedDiskCapacityGb,omitempty,string"` // TotalProvisionedDiskIops: [Output Only] Sum of all the disks' provisioned // IOPS. TotalProvisionedDiskIops int64 `json:"totalProvisionedDiskIops,omitempty,string"` // TotalProvisionedDiskThroughput: [Output Only] Sum of all the disks' - // provisioned throughput in MB/s, minus some amount that is allowed per disk + // provisioned throughput in MiB/s, minus some amount that is allowed per disk // that is not counted towards pool's throughput capacity. TotalProvisionedDiskThroughput int64 `json:"totalProvisionedDiskThroughput,omitempty,string"` // ForceSendFields is a list of field names (e.g. "DiskCount") to @@ -55891,6 +55901,8 @@ type UpcomingMaintenance struct { // relocation. // "MAINTENANCE_REASON_UNKNOWN" - Unknown maintenance reason. Do not use this // value. + // "PLANNED_NETWORK_UPDATE" - Maintenance due to planned network update. + // "PLANNED_UPDATE" - Maintenance due to planned update to the instance. MaintenanceReasons []string `json:"maintenanceReasons,omitempty"` // Possible values: // "ONGOING" - There is ongoing maintenance on this VM. @@ -55900,6 +55912,8 @@ type UpcomingMaintenance struct { // Type: Defines the type of maintenance. // // Possible values: + // "MULTIPLE" - Multiple maintenance types in one window. This is only + // intended to be used for groups. // "SCHEDULED" - Scheduled maintenance (e.g. maintenance after uptime // guarantee is complete). // "UNKNOWN_TYPE" - No type specified. Do not use this value. diff --git a/compute/v1/compute2-gen.go b/compute/v1/compute2-gen.go index a74de5769a2..d2c526c4dd1 100644 --- a/compute/v1/compute2-gen.go +++ b/compute/v1/compute2-gen.go @@ -18050,7 +18050,7 @@ func (c *GlobalOrganizationOperationsDeleteCall) Do(opts ...googleapi.CallOption type GlobalOrganizationOperationsGetCall struct { s *Service - operationid string + operation string urlParams_ gensupport.URLParams ifNoneMatch_ string ctx_ context.Context @@ -18060,15 +18060,16 @@ type GlobalOrganizationOperationsGetCall struct { // Get: Retrieves the specified Operations resource. Gets a list of operations // by making a `list()` request. // -// - operation: Name of the Operations resource to return, or its unique -// numeric identifier. -func (r *GlobalOrganizationOperationsService) Get(operationid string) *GlobalOrganizationOperationsGetCall { +// - operation: Name of the Operations resource to return. Parent is derived +// from this field. +func (r *GlobalOrganizationOperationsService) Get(operation string) *GlobalOrganizationOperationsGetCall { c := &GlobalOrganizationOperationsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.operationid = operationid + c.operation = operation return c } // ParentId sets the optional parameter "parentId": Parent ID for this request. +// Not used. Parent is derived from resource_id. func (c *GlobalOrganizationOperationsGetCall) ParentId(parentId string) *GlobalOrganizationOperationsGetCall { c.urlParams_.Set("parentId", parentId) return c @@ -18120,7 +18121,7 @@ func (c *GlobalOrganizationOperationsGetCall) doRequest(alt string) (*http.Respo } req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ - "operation": c.operationid, + "operation": c.operation, }) c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "compute.globalOrganizationOperations.get", "request", internallog.HTTPRequest(req, nil)) return gensupport.SendRequest(c.ctx_, c.s.client, req) diff --git a/compute/v1/compute3-gen.go b/compute/v1/compute3-gen.go index a5d86d44ccd..c2d61c7753e 100644 --- a/compute/v1/compute3-gen.go +++ b/compute/v1/compute3-gen.go @@ -40379,6 +40379,15 @@ func (c *SubnetworksListUsableCall) ReturnPartialSuccess(returnPartialSuccess bo return c } +// ServiceProject sets the optional parameter "serviceProject": The project id +// or project number in which the subnetwork is intended to be used. Only +// applied for Shared VPC. See Shared VPC documentation +// (https://cloud.google.com/vpc/docs/shared-vpc/) +func (c *SubnetworksListUsableCall) ServiceProject(serviceProject string) *SubnetworksListUsableCall { + c.urlParams_.Set("serviceProject", serviceProject) + return c +} + // Fields allows partial responses to be retrieved. See // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more // details. diff --git a/discoveryengine/v1/discoveryengine-api.json b/discoveryengine/v1/discoveryengine-api.json index 3d74a961f57..d51b2699c54 100644 --- a/discoveryengine/v1/discoveryengine-api.json +++ b/discoveryengine/v1/discoveryengine-api.json @@ -135,6 +135,47 @@ }, "protocol": "rest", "resources": { + "media": { + "methods": { + "download": { + "description": "Downloads a file from the session.", + "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/engines/{enginesId}/sessions/{sessionsId}:downloadFile", + "httpMethod": "GET", + "id": "discoveryengine.media.download", + "parameterOrder": [ + "name" + ], + "parameters": { + "fileId": { + "description": "Required. The ID of the file to be downloaded.", + "location": "query", + "type": "string" + }, + "name": { + "description": "Required. The resource name of the Session. Format: `projects/{project}/locations/{location}/collections/{collection}/engines/{engine}/sessions/{session}`", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/engines/[^/]+/sessions/[^/]+$", + "required": true, + "type": "string" + }, + "viewId": { + "description": "Optional. The ID of the view to be downloaded.", + "location": "query", + "type": "string" + } + }, + "path": "v1/{+name}:downloadFile", + "response": { + "$ref": "GdataMedia" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ], + "supportsMediaDownload": true, + "useMediaDownloadService": true + } + } + }, "projects": { "methods": { "provision": { @@ -2175,7 +2216,7 @@ ], "parameters": { "filter": { - "description": "A comma-separated list of fields to filter by, in EBNF grammar. The supported fields are: * `user_pseudo_id` * `state` * `display_name` * `starred` * `is_pinned` * `labels` * `create_time` * `update_time` Examples: \"user_pseudo_id = some_id\" \"display_name = \\\"some_name\\\"\" \"starred = true\" \"is_pinned=true AND (NOT labels:hidden)\" \"create_time \u003e \\\"1970-01-01T12:00:00Z\\\"\"", + "description": "A comma-separated list of fields to filter by, in EBNF grammar. The supported fields are: * `user_pseudo_id` * `state` * `display_name` * `starred` * `is_pinned` * `labels` * `create_time` * `update_time` Examples: * `user_pseudo_id = some_id` * `display_name = \"some_name\"` * `starred = true` * `is_pinned=true AND (NOT labels:hidden)` * `create_time \u003e \"1970-01-01T12:00:00Z\"`", "location": "query", "type": "string" }, @@ -4041,7 +4082,7 @@ ], "parameters": { "filter": { - "description": "A comma-separated list of fields to filter by, in EBNF grammar. The supported fields are: * `user_pseudo_id` * `state` * `display_name` * `starred` * `is_pinned` * `labels` * `create_time` * `update_time` Examples: \"user_pseudo_id = some_id\" \"display_name = \\\"some_name\\\"\" \"starred = true\" \"is_pinned=true AND (NOT labels:hidden)\" \"create_time \u003e \\\"1970-01-01T12:00:00Z\\\"\"", + "description": "A comma-separated list of fields to filter by, in EBNF grammar. The supported fields are: * `user_pseudo_id` * `state` * `display_name` * `starred` * `is_pinned` * `labels` * `create_time` * `update_time` Examples: * `user_pseudo_id = some_id` * `display_name = \"some_name\"` * `starred = true` * `is_pinned=true AND (NOT labels:hidden)` * `create_time \u003e \"1970-01-01T12:00:00Z\"`", "location": "query", "type": "string" }, @@ -5847,7 +5888,7 @@ ], "parameters": { "filter": { - "description": "A comma-separated list of fields to filter by, in EBNF grammar. The supported fields are: * `user_pseudo_id` * `state` * `display_name` * `starred` * `is_pinned` * `labels` * `create_time` * `update_time` Examples: \"user_pseudo_id = some_id\" \"display_name = \\\"some_name\\\"\" \"starred = true\" \"is_pinned=true AND (NOT labels:hidden)\" \"create_time \u003e \\\"1970-01-01T12:00:00Z\\\"\"", + "description": "A comma-separated list of fields to filter by, in EBNF grammar. The supported fields are: * `user_pseudo_id` * `state` * `display_name` * `starred` * `is_pinned` * `labels` * `create_time` * `update_time` Examples: * `user_pseudo_id = some_id` * `display_name = \"some_name\"` * `starred = true` * `is_pinned=true AND (NOT labels:hidden)` * `create_time \u003e \"1970-01-01T12:00:00Z\"`", "location": "query", "type": "string" }, @@ -7250,9 +7291,439 @@ } } }, - "revision": "20250724", + "revision": "20250728", "rootUrl": "https://discoveryengine.googleapis.com/", "schemas": { + "GdataBlobstore2Info": { + "description": "Information to read/write to blobstore2.", + "id": "GdataBlobstore2Info", + "properties": { + "blobGeneration": { + "description": "The blob generation id.", + "format": "int64", + "type": "string" + }, + "blobId": { + "description": "The blob id, e.g., /blobstore/prod/playground/scotty", + "type": "string" + }, + "downloadReadHandle": { + "description": "Read handle passed from Bigstore -\u003e Scotty for a GCS download. This is a signed, serialized blobstore2.ReadHandle proto which must never be set outside of Bigstore, and is not applicable to non-GCS media downloads.", + "format": "byte", + "type": "string" + }, + "readToken": { + "description": "The blob read token. Needed to read blobs that have not been replicated. Might not be available until the final call.", + "type": "string" + }, + "uploadMetadataContainer": { + "description": "Metadata passed from Blobstore -\u003e Scotty for a new GCS upload. This is a signed, serialized blobstore2.BlobMetadataContainer proto which must never be consumed outside of Bigstore, and is not applicable to non-GCS media uploads.", + "format": "byte", + "type": "string" + } + }, + "type": "object" + }, + "GdataCompositeMedia": { + "description": "A sequence of media data references representing composite data. Introduced to support Bigstore composite objects. For details, visit http://go/bigstore-composites.", + "id": "GdataCompositeMedia", + "properties": { + "blobRef": { + "deprecated": true, + "description": "Blobstore v1 reference, set if reference_type is BLOBSTORE_REF This should be the byte representation of a blobstore.BlobRef. Since Blobstore is deprecating v1, use blobstore2_info instead. For now, any v2 blob will also be represented in this field as v1 BlobRef.", + "format": "byte", + "type": "string" + }, + "blobstore2Info": { + "$ref": "GdataBlobstore2Info", + "description": "Blobstore v2 info, set if reference_type is BLOBSTORE_REF and it refers to a v2 blob." + }, + "cosmoBinaryReference": { + "description": "A binary data reference for a media download. Serves as a technology-agnostic binary reference in some Google infrastructure. This value is a serialized storage_cosmo.BinaryReference proto. Storing it as bytes is a hack to get around the fact that the cosmo proto (as well as others it includes) doesn't support JavaScript. This prevents us from including the actual type of this field.", + "format": "byte", + "type": "string" + }, + "crc32cHash": { + "description": "crc32.c hash for the payload.", + "format": "uint32", + "type": "integer" + }, + "inline": { + "description": "Media data, set if reference_type is INLINE", + "format": "byte", + "type": "string" + }, + "length": { + "description": "Size of the data, in bytes", + "format": "int64", + "type": "string" + }, + "md5Hash": { + "description": "MD5 hash for the payload.", + "format": "byte", + "type": "string" + }, + "objectId": { + "$ref": "GdataObjectId", + "description": "Reference to a TI Blob, set if reference_type is BIGSTORE_REF." + }, + "path": { + "description": "Path to the data, set if reference_type is PATH", + "type": "string" + }, + "referenceType": { + "description": "Describes what the field reference contains.", + "enum": [ + "PATH", + "BLOB_REF", + "INLINE", + "BIGSTORE_REF", + "COSMO_BINARY_REFERENCE" + ], + "enumDescriptions": [ + "Reference contains a GFS path or a local path.", + "Reference points to a blobstore object. This could be either a v1 blob_ref or a v2 blobstore2_info. Clients should check blobstore2_info first, since v1 is being deprecated.", + "Data is included into this proto buffer", + "Reference points to a bigstore object", + "Indicates the data is stored in cosmo_binary_reference." + ], + "type": "string" + }, + "sha1Hash": { + "description": "SHA-1 hash for the payload.", + "format": "byte", + "type": "string" + } + }, + "type": "object" + }, + "GdataContentTypeInfo": { + "description": "Detailed Content-Type information from Scotty. The Content-Type of the media will typically be filled in by the header or Scotty's best_guess, but this extended information provides the backend with more information so that it can make a better decision if needed. This is only used on media upload requests from Scotty.", + "id": "GdataContentTypeInfo", + "properties": { + "bestGuess": { + "description": "Scotty's best guess of what the content type of the file is.", + "type": "string" + }, + "fromBytes": { + "description": "The content type of the file derived by looking at specific bytes (i.e. \"magic bytes\") of the actual file.", + "type": "string" + }, + "fromFileName": { + "description": "The content type of the file derived from the file extension of the original file name used by the client.", + "type": "string" + }, + "fromHeader": { + "description": "The content type of the file as specified in the request headers, multipart headers, or RUPIO start request.", + "type": "string" + }, + "fromUrlPath": { + "description": "The content type of the file derived from the file extension of the URL path. The URL path is assumed to represent a file name (which is typically only true for agents that are providing a REST API).", + "type": "string" + } + }, + "type": "object" + }, + "GdataDiffChecksumsResponse": { + "description": "Backend response for a Diff get checksums response. For details on the Scotty Diff protocol, visit http://go/scotty-diff-protocol.", + "id": "GdataDiffChecksumsResponse", + "properties": { + "checksumsLocation": { + "$ref": "GdataCompositeMedia", + "description": "Exactly one of these fields must be populated. If checksums_location is filled, the server will return the corresponding contents to the user. If object_location is filled, the server will calculate the checksums based on the content there and return that to the user. For details on the format of the checksums, see http://go/scotty-diff-protocol." + }, + "chunkSizeBytes": { + "description": "The chunk size of checksums. Must be a multiple of 256KB.", + "format": "int64", + "type": "string" + }, + "objectLocation": { + "$ref": "GdataCompositeMedia", + "description": "If set, calculate the checksums based on the contents and return them to the caller." + }, + "objectSizeBytes": { + "description": "The total size of the server object.", + "format": "int64", + "type": "string" + }, + "objectVersion": { + "description": "The object version of the object the checksums are being returned for.", + "type": "string" + } + }, + "type": "object" + }, + "GdataDiffDownloadResponse": { + "description": "Backend response for a Diff download response. For details on the Scotty Diff protocol, visit http://go/scotty-diff-protocol.", + "id": "GdataDiffDownloadResponse", + "properties": { + "objectLocation": { + "$ref": "GdataCompositeMedia", + "description": "The original object location." + } + }, + "type": "object" + }, + "GdataDiffUploadRequest": { + "description": "A Diff upload request. For details on the Scotty Diff protocol, visit http://go/scotty-diff-protocol.", + "id": "GdataDiffUploadRequest", + "properties": { + "checksumsInfo": { + "$ref": "GdataCompositeMedia", + "description": "The location of the checksums for the new object. Agents must clone the object located here, as the upload server will delete the contents once a response is received. For details on the format of the checksums, see http://go/scotty-diff-protocol." + }, + "objectInfo": { + "$ref": "GdataCompositeMedia", + "description": "The location of the new object. Agents must clone the object located here, as the upload server will delete the contents once a response is received." + }, + "objectVersion": { + "description": "The object version of the object that is the base version the incoming diff script will be applied to. This field will always be filled in.", + "type": "string" + } + }, + "type": "object" + }, + "GdataDiffUploadResponse": { + "description": "Backend response for a Diff upload request. For details on the Scotty Diff protocol, visit http://go/scotty-diff-protocol.", + "id": "GdataDiffUploadResponse", + "properties": { + "objectVersion": { + "description": "The object version of the object at the server. Must be included in the end notification response. The version in the end notification response must correspond to the new version of the object that is now stored at the server, after the upload.", + "type": "string" + }, + "originalObject": { + "$ref": "GdataCompositeMedia", + "description": "The location of the original file for a diff upload request. Must be filled in if responding to an upload start notification." + } + }, + "type": "object" + }, + "GdataDiffVersionResponse": { + "description": "Backend response for a Diff get version response. For details on the Scotty Diff protocol, visit http://go/scotty-diff-protocol.", + "id": "GdataDiffVersionResponse", + "properties": { + "objectSizeBytes": { + "description": "The total size of the server object.", + "format": "int64", + "type": "string" + }, + "objectVersion": { + "description": "The version of the object stored at the server.", + "type": "string" + } + }, + "type": "object" + }, + "GdataDownloadParameters": { + "description": "Parameters specific to media downloads.", + "id": "GdataDownloadParameters", + "properties": { + "allowGzipCompression": { + "description": "A boolean to be returned in the response to Scotty. Allows/disallows gzip encoding of the payload content when the server thinks it's advantageous (hence, does not guarantee compression) which allows Scotty to GZip the response to the client.", + "type": "boolean" + }, + "ignoreRange": { + "description": "Determining whether or not Apiary should skip the inclusion of any Content-Range header on its response to Scotty.", + "type": "boolean" + } + }, + "type": "object" + }, + "GdataMedia": { + "description": "A reference to data stored on the filesystem, on GFS or in blobstore.", + "id": "GdataMedia", + "properties": { + "algorithm": { + "deprecated": true, + "description": "Deprecated, use one of explicit hash type fields instead. Algorithm used for calculating the hash. As of 2011/01/21, \"MD5\" is the only possible value for this field. New values may be added at any time.", + "type": "string" + }, + "bigstoreObjectRef": { + "deprecated": true, + "description": "Use object_id instead.", + "format": "byte", + "type": "string" + }, + "blobRef": { + "deprecated": true, + "description": "Blobstore v1 reference, set if reference_type is BLOBSTORE_REF This should be the byte representation of a blobstore.BlobRef. Since Blobstore is deprecating v1, use blobstore2_info instead. For now, any v2 blob will also be represented in this field as v1 BlobRef.", + "format": "byte", + "type": "string" + }, + "blobstore2Info": { + "$ref": "GdataBlobstore2Info", + "description": "Blobstore v2 info, set if reference_type is BLOBSTORE_REF and it refers to a v2 blob." + }, + "compositeMedia": { + "description": "A composite media composed of one or more media objects, set if reference_type is COMPOSITE_MEDIA. The media length field must be set to the sum of the lengths of all composite media objects. Note: All composite media must have length specified.", + "items": { + "$ref": "GdataCompositeMedia" + }, + "type": "array" + }, + "contentType": { + "description": "MIME type of the data", + "type": "string" + }, + "contentTypeInfo": { + "$ref": "GdataContentTypeInfo", + "description": "Extended content type information provided for Scotty uploads." + }, + "cosmoBinaryReference": { + "description": "A binary data reference for a media download. Serves as a technology-agnostic binary reference in some Google infrastructure. This value is a serialized storage_cosmo.BinaryReference proto. Storing it as bytes is a hack to get around the fact that the cosmo proto (as well as others it includes) doesn't support JavaScript. This prevents us from including the actual type of this field.", + "format": "byte", + "type": "string" + }, + "crc32cHash": { + "description": "For Scotty Uploads: Scotty-provided hashes for uploads For Scotty Downloads: (WARNING: DO NOT USE WITHOUT PERMISSION FROM THE SCOTTY TEAM.) A Hash provided by the agent to be used to verify the data being downloaded. Currently only supported for inline payloads. Further, only crc32c_hash is currently supported.", + "format": "uint32", + "type": "integer" + }, + "diffChecksumsResponse": { + "$ref": "GdataDiffChecksumsResponse", + "description": "Set if reference_type is DIFF_CHECKSUMS_RESPONSE." + }, + "diffDownloadResponse": { + "$ref": "GdataDiffDownloadResponse", + "description": "Set if reference_type is DIFF_DOWNLOAD_RESPONSE." + }, + "diffUploadRequest": { + "$ref": "GdataDiffUploadRequest", + "description": "Set if reference_type is DIFF_UPLOAD_REQUEST." + }, + "diffUploadResponse": { + "$ref": "GdataDiffUploadResponse", + "description": "Set if reference_type is DIFF_UPLOAD_RESPONSE." + }, + "diffVersionResponse": { + "$ref": "GdataDiffVersionResponse", + "description": "Set if reference_type is DIFF_VERSION_RESPONSE." + }, + "downloadParameters": { + "$ref": "GdataDownloadParameters", + "description": "Parameters for a media download." + }, + "filename": { + "description": "Original file name", + "type": "string" + }, + "hash": { + "deprecated": true, + "description": "Deprecated, use one of explicit hash type fields instead. These two hash related fields will only be populated on Scotty based media uploads and will contain the content of the hash group in the NotificationRequest: http://cs/#google3/blobstore2/api/scotty/service/proto/upload_listener.proto\u0026q=class:Hash Hex encoded hash value of the uploaded media.", + "type": "string" + }, + "hashVerified": { + "description": "For Scotty uploads only. If a user sends a hash code and the backend has requested that Scotty verify the upload against the client hash, Scotty will perform the check on behalf of the backend and will reject it if the hashes don't match. This is set to true if Scotty performed this verification.", + "type": "boolean" + }, + "inline": { + "description": "Media data, set if reference_type is INLINE", + "format": "byte", + "type": "string" + }, + "isPotentialRetry": { + "description": "|is_potential_retry| is set false only when Scotty is certain that it has not sent the request before. When a client resumes an upload, this field must be set true in agent calls, because Scotty cannot be certain that it has never sent the request before due to potential failure in the session state persistence.", + "type": "boolean" + }, + "length": { + "description": "Size of the data, in bytes", + "format": "int64", + "type": "string" + }, + "md5Hash": { + "description": "Scotty-provided MD5 hash for an upload.", + "format": "byte", + "type": "string" + }, + "mediaId": { + "description": "Media id to forward to the operation GetMedia. Can be set if reference_type is GET_MEDIA.", + "format": "byte", + "type": "string" + }, + "objectId": { + "$ref": "GdataObjectId", + "description": "Reference to a TI Blob, set if reference_type is BIGSTORE_REF." + }, + "path": { + "description": "Path to the data, set if reference_type is PATH", + "type": "string" + }, + "referenceType": { + "description": "Describes what the field reference contains.", + "enum": [ + "PATH", + "BLOB_REF", + "INLINE", + "GET_MEDIA", + "COMPOSITE_MEDIA", + "BIGSTORE_REF", + "DIFF_VERSION_RESPONSE", + "DIFF_CHECKSUMS_RESPONSE", + "DIFF_DOWNLOAD_RESPONSE", + "DIFF_UPLOAD_REQUEST", + "DIFF_UPLOAD_RESPONSE", + "COSMO_BINARY_REFERENCE", + "ARBITRARY_BYTES" + ], + "enumDescriptions": [ + "Reference contains a GFS path or a local path.", + "Reference points to a blobstore object. This could be either a v1 blob_ref or a v2 blobstore2_info. Clients should check blobstore2_info first, since v1 is being deprecated.", + "Data is included into this proto buffer", + "Data should be accessed from the current service using the operation GetMedia.", + "The content for this media object is stored across multiple partial media objects under the composite_media field.", + "Reference points to a bigstore object", + "Indicates the data is stored in diff_version_response.", + "Indicates the data is stored in diff_checksums_response.", + "Indicates the data is stored in diff_download_response.", + "Indicates the data is stored in diff_upload_request.", + "Indicates the data is stored in diff_upload_response.", + "Indicates the data is stored in cosmo_binary_reference.", + "Informs Scotty to generate a response payload with the size specified in the length field. The contents of the payload are generated by Scotty and are undefined. This is useful for testing download speeds between the user and Scotty without involving a real payload source. Note: range is not supported when using arbitrary_bytes." + ], + "type": "string" + }, + "sha1Hash": { + "description": "Scotty-provided SHA1 hash for an upload.", + "format": "byte", + "type": "string" + }, + "sha256Hash": { + "description": "Scotty-provided SHA256 hash for an upload.", + "format": "byte", + "type": "string" + }, + "timestamp": { + "description": "Time at which the media data was last updated, in milliseconds since UNIX epoch", + "format": "uint64", + "type": "string" + }, + "token": { + "description": "A unique fingerprint/version id for the media data", + "type": "string" + } + }, + "type": "object" + }, + "GdataObjectId": { + "description": "This is a copy of the tech.blob.ObjectId proto, which could not be used directly here due to transitive closure issues with JavaScript support; see http://b/8801763.", + "id": "GdataObjectId", + "properties": { + "bucketName": { + "description": "The name of the bucket to which this object belongs.", + "type": "string" + }, + "generation": { + "description": "Generation of the object. Generations are monotonically increasing across writes, allowing them to be be compared to determine which generation is newer. If this is omitted in a request, then you are requesting the live object. See http://go/bigstore-versions", + "format": "int64", + "type": "string" + }, + "objectName": { + "description": "The name of the object.", + "type": "string" + } + }, + "type": "object" + }, "GoogleApiDistribution": { "description": "`Distribution` contains summary statistics for a population of values. It optionally contains a histogram representing the distribution of those values across a set of buckets. The summary statistics are the count, mean, sum of the squared deviation from the mean, the minimum, and the maximum of the set of population of values. The histogram is based on a sequence of buckets and gives a count of values that fall into each bucket. The boundaries of the buckets are given either explicitly or by formulas for buckets of fixed or exponentially increasing widths. Although it is not forbidden, it is generally a bad idea to include non-finite values (infinities or NaNs) in the population of values, as this will render the `mean` and `sum_of_squared_deviation` fields meaningless.", "id": "GoogleApiDistribution", @@ -18891,6 +19362,29 @@ }, "type": "object" }, + "GoogleCloudDiscoveryengineV1alphaExportMetricsMetadata": { + "description": "Metadata related to the progress of the Export operation. This is returned by the google.longrunning.Operation.metadata field.", + "id": "GoogleCloudDiscoveryengineV1alphaExportMetricsMetadata", + "properties": { + "createTime": { + "description": "Operation create time.", + "format": "google-datetime", + "type": "string" + }, + "updateTime": { + "description": "Operation last update time. If the operation is done, this is also the finish time.", + "format": "google-datetime", + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaExportMetricsResponse": { + "description": "Response of the ExportMetricsRequest. If the long running operation was successful, then this message is returned by the google.longrunning.Operations.response field.", + "id": "GoogleCloudDiscoveryengineV1alphaExportMetricsResponse", + "properties": {}, + "type": "object" + }, "GoogleCloudDiscoveryengineV1alphaFieldConfig": { "description": "Configurations for fields of a schema. For example, configuring a field is indexable, or searchable.", "id": "GoogleCloudDiscoveryengineV1alphaFieldConfig", @@ -19494,7 +19988,7 @@ "id": "GoogleCloudDiscoveryengineV1alphaListSessionsRequest", "properties": { "filter": { - "description": "A comma-separated list of fields to filter by, in EBNF grammar. The supported fields are: * `user_pseudo_id` * `state` * `display_name` * `starred` * `is_pinned` * `labels` * `create_time` * `update_time` Examples: \"user_pseudo_id = some_id\" \"display_name = \\\"some_name\\\"\" \"starred = true\" \"is_pinned=true AND (NOT labels:hidden)\" \"create_time \u003e \\\"1970-01-01T12:00:00Z\\\"\"", + "description": "A comma-separated list of fields to filter by, in EBNF grammar. The supported fields are: * `user_pseudo_id` * `state` * `display_name` * `starred` * `is_pinned` * `labels` * `create_time` * `update_time` Examples: * `user_pseudo_id = some_id` * `display_name = \"some_name\"` * `starred = true` * `is_pinned=true AND (NOT labels:hidden)` * `create_time \u003e \"1970-01-01T12:00:00Z\"`", "type": "string" }, "orderBy": { @@ -20300,7 +20794,7 @@ }, "naturalLanguageQueryUnderstandingSpec": { "$ref": "GoogleCloudDiscoveryengineV1alphaSearchRequestNaturalLanguageQueryUnderstandingSpec", - "description": "If `naturalLanguageQueryUnderstandingSpec` is not specified, no additional natural language query understanding will be done." + "description": "Config for natural language query understanding capabilities, such as extracting structured field filters from the query. Refer to [this documentation](https://cloud.google.com/generative-ai-app-builder/docs/natural-language-queries) for more information. If `naturalLanguageQueryUnderstandingSpec` is not specified, no additional natural language query understanding will be done." }, "offset": { "description": "A 0-indexed integer that specifies the current offset (that is, starting result location, amongst the Documents deemed by the API as relevant) in search results. This field is only considered if page_token is unset. If this field is negative, an `INVALID_ARGUMENT` is returned.", @@ -20909,6 +21403,20 @@ "description": "Specification to enable natural language understanding capabilities for search requests.", "id": "GoogleCloudDiscoveryengineV1alphaSearchRequestNaturalLanguageQueryUnderstandingSpec", "properties": { + "extractedFilterBehavior": { + "description": "Optional. Controls behavior of how extracted filters are applied to the search. The default behavior depends on the request. For single datastore structured search, the default is `HARD_FILTER`. For multi-datastore search, the default behavior is `SOFT_BOOST`. Location-based filters are always applied as hard filters, and the `SOFT_BOOST` setting will not affect them. This field is only used if SearchRequest.natural_language_query_understanding_spec.filter_extraction_condition is set to FilterExtractionCondition.ENABLED.", + "enum": [ + "EXTRACTED_FILTER_BEHAVIOR_UNSPECIFIED", + "HARD_FILTER", + "SOFT_BOOST" + ], + "enumDescriptions": [ + "`EXTRACTED_FILTER_BEHAVIOR_UNSPECIFIED` will use the default behavior for extracted filters. For single datastore search, the default is to apply as hard filters. For multi-datastore search, the default is to apply as soft boosts.", + "Applies all extracted filters as hard filters on the results. Results that do not pass the extracted filters will not be returned in the result set.", + "Applies all extracted filters as soft boosts. Results that pass the filters will be boosted up to higher ranks in the result set." + ], + "type": "string" + }, "filterExtractionCondition": { "description": "The condition under which filter extraction should occur. Server behavior defaults to `DISABLED`.", "enum": [ @@ -23920,7 +24428,7 @@ }, "naturalLanguageQueryUnderstandingSpec": { "$ref": "GoogleCloudDiscoveryengineV1betaSearchRequestNaturalLanguageQueryUnderstandingSpec", - "description": "If `naturalLanguageQueryUnderstandingSpec` is not specified, no additional natural language query understanding will be done." + "description": "Config for natural language query understanding capabilities, such as extracting structured field filters from the query. Refer to [this documentation](https://cloud.google.com/generative-ai-app-builder/docs/natural-language-queries) for more information. If `naturalLanguageQueryUnderstandingSpec` is not specified, no additional natural language query understanding will be done." }, "offset": { "description": "A 0-indexed integer that specifies the current offset (that is, starting result location, amongst the Documents deemed by the API as relevant) in search results. This field is only considered if page_token is unset. If this field is negative, an `INVALID_ARGUMENT` is returned.", @@ -24525,6 +25033,20 @@ "description": "Specification to enable natural language understanding capabilities for search requests.", "id": "GoogleCloudDiscoveryengineV1betaSearchRequestNaturalLanguageQueryUnderstandingSpec", "properties": { + "extractedFilterBehavior": { + "description": "Optional. Controls behavior of how extracted filters are applied to the search. The default behavior depends on the request. For single datastore structured search, the default is `HARD_FILTER`. For multi-datastore search, the default behavior is `SOFT_BOOST`. Location-based filters are always applied as hard filters, and the `SOFT_BOOST` setting will not affect them. This field is only used if SearchRequest.natural_language_query_understanding_spec.filter_extraction_condition is set to FilterExtractionCondition.ENABLED.", + "enum": [ + "EXTRACTED_FILTER_BEHAVIOR_UNSPECIFIED", + "HARD_FILTER", + "SOFT_BOOST" + ], + "enumDescriptions": [ + "`EXTRACTED_FILTER_BEHAVIOR_UNSPECIFIED` will use the default behavior for extracted filters. For single datastore search, the default is to apply as hard filters. For multi-datastore search, the default is to apply as soft boosts.", + "Applies all extracted filters as hard filters on the results. Results that do not pass the extracted filters will not be returned in the result set.", + "Applies all extracted filters as soft boosts. Results that pass the filters will be boosted up to higher ranks in the result set." + ], + "type": "string" + }, "filterExtractionCondition": { "description": "The condition under which filter extraction should occur. Server behavior defaults to `DISABLED`.", "enum": [ diff --git a/discoveryengine/v1/discoveryengine-gen.go b/discoveryengine/v1/discoveryengine-gen.go index d29fed7b460..00f65862e4f 100644 --- a/discoveryengine/v1/discoveryengine-gen.go +++ b/discoveryengine/v1/discoveryengine-gen.go @@ -128,6 +128,7 @@ func NewService(ctx context.Context, opts ...option.ClientOption) (*Service, err return nil, err } s := &Service{client: client, BasePath: basePath, logger: internaloption.GetLogger(opts)} + s.Media = NewMediaService(s) s.Projects = NewProjectsService(s) if endpoint != "" { s.BasePath = endpoint @@ -153,6 +154,8 @@ type Service struct { BasePath string // API endpoint base URL UserAgent string // optional additional User-Agent fragment + Media *MediaService + Projects *ProjectsService } @@ -163,6 +166,15 @@ func (s *Service) userAgent() string { return googleapi.UserAgent + " " + s.UserAgent } +func NewMediaService(s *Service) *MediaService { + rs := &MediaService{s: s} + return rs +} + +type MediaService struct { + s *Service +} + func NewProjectsService(s *Service) *ProjectsService { rs := &ProjectsService{s: s} rs.Locations = NewProjectsLocationsService(s) @@ -1012,6 +1024,502 @@ type ProjectsOperationsService struct { s *Service } +// GdataBlobstore2Info: Information to read/write to blobstore2. +type GdataBlobstore2Info struct { + // BlobGeneration: The blob generation id. + BlobGeneration int64 `json:"blobGeneration,omitempty,string"` + // BlobId: The blob id, e.g., /blobstore/prod/playground/scotty + BlobId string `json:"blobId,omitempty"` + // DownloadReadHandle: Read handle passed from Bigstore -> Scotty for a GCS + // download. This is a signed, serialized blobstore2.ReadHandle proto which + // must never be set outside of Bigstore, and is not applicable to non-GCS + // media downloads. + DownloadReadHandle string `json:"downloadReadHandle,omitempty"` + // ReadToken: The blob read token. Needed to read blobs that have not been + // replicated. Might not be available until the final call. + ReadToken string `json:"readToken,omitempty"` + // UploadMetadataContainer: Metadata passed from Blobstore -> Scotty for a new + // GCS upload. This is a signed, serialized blobstore2.BlobMetadataContainer + // proto which must never be consumed outside of Bigstore, and is not + // applicable to non-GCS media uploads. + UploadMetadataContainer string `json:"uploadMetadataContainer,omitempty"` + // ForceSendFields is a list of field names (e.g. "BlobGeneration") 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. "BlobGeneration") 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 GdataBlobstore2Info) MarshalJSON() ([]byte, error) { + type NoMethod GdataBlobstore2Info + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GdataCompositeMedia: A sequence of media data references representing +// composite data. Introduced to support Bigstore composite objects. For +// details, visit http://go/bigstore-composites. +type GdataCompositeMedia struct { + // BlobRef: Blobstore v1 reference, set if reference_type is BLOBSTORE_REF This + // should be the byte representation of a blobstore.BlobRef. Since Blobstore is + // deprecating v1, use blobstore2_info instead. For now, any v2 blob will also + // be represented in this field as v1 BlobRef. + BlobRef string `json:"blobRef,omitempty"` + // Blobstore2Info: Blobstore v2 info, set if reference_type is BLOBSTORE_REF + // and it refers to a v2 blob. + Blobstore2Info *GdataBlobstore2Info `json:"blobstore2Info,omitempty"` + // CosmoBinaryReference: A binary data reference for a media download. Serves + // as a technology-agnostic binary reference in some Google infrastructure. + // This value is a serialized storage_cosmo.BinaryReference proto. Storing it + // as bytes is a hack to get around the fact that the cosmo proto (as well as + // others it includes) doesn't support JavaScript. This prevents us from + // including the actual type of this field. + CosmoBinaryReference string `json:"cosmoBinaryReference,omitempty"` + // Crc32cHash: crc32.c hash for the payload. + Crc32cHash int64 `json:"crc32cHash,omitempty"` + // Inline: Media data, set if reference_type is INLINE + Inline string `json:"inline,omitempty"` + // Length: Size of the data, in bytes + Length int64 `json:"length,omitempty,string"` + // Md5Hash: MD5 hash for the payload. + Md5Hash string `json:"md5Hash,omitempty"` + // ObjectId: Reference to a TI Blob, set if reference_type is BIGSTORE_REF. + ObjectId *GdataObjectId `json:"objectId,omitempty"` + // Path: Path to the data, set if reference_type is PATH + Path string `json:"path,omitempty"` + // ReferenceType: Describes what the field reference contains. + // + // Possible values: + // "PATH" - Reference contains a GFS path or a local path. + // "BLOB_REF" - Reference points to a blobstore object. This could be either + // a v1 blob_ref or a v2 blobstore2_info. Clients should check blobstore2_info + // first, since v1 is being deprecated. + // "INLINE" - Data is included into this proto buffer + // "BIGSTORE_REF" - Reference points to a bigstore object + // "COSMO_BINARY_REFERENCE" - Indicates the data is stored in + // cosmo_binary_reference. + ReferenceType string `json:"referenceType,omitempty"` + // Sha1Hash: SHA-1 hash for the payload. + Sha1Hash string `json:"sha1Hash,omitempty"` + // ForceSendFields is a list of field names (e.g. "BlobRef") 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. "BlobRef") 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 GdataCompositeMedia) MarshalJSON() ([]byte, error) { + type NoMethod GdataCompositeMedia + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GdataContentTypeInfo: Detailed Content-Type information from Scotty. The +// Content-Type of the media will typically be filled in by the header or +// Scotty's best_guess, but this extended information provides the backend with +// more information so that it can make a better decision if needed. This is +// only used on media upload requests from Scotty. +type GdataContentTypeInfo struct { + // BestGuess: Scotty's best guess of what the content type of the file is. + BestGuess string `json:"bestGuess,omitempty"` + // FromBytes: The content type of the file derived by looking at specific bytes + // (i.e. "magic bytes") of the actual file. + FromBytes string `json:"fromBytes,omitempty"` + // FromFileName: The content type of the file derived from the file extension + // of the original file name used by the client. + FromFileName string `json:"fromFileName,omitempty"` + // FromHeader: The content type of the file as specified in the request + // headers, multipart headers, or RUPIO start request. + FromHeader string `json:"fromHeader,omitempty"` + // FromUrlPath: The content type of the file derived from the file extension of + // the URL path. The URL path is assumed to represent a file name (which is + // typically only true for agents that are providing a REST API). + FromUrlPath string `json:"fromUrlPath,omitempty"` + // ForceSendFields is a list of field names (e.g. "BestGuess") 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. "BestGuess") 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 GdataContentTypeInfo) MarshalJSON() ([]byte, error) { + type NoMethod GdataContentTypeInfo + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GdataDiffChecksumsResponse: Backend response for a Diff get checksums +// response. For details on the Scotty Diff protocol, visit +// http://go/scotty-diff-protocol. +type GdataDiffChecksumsResponse struct { + // ChecksumsLocation: Exactly one of these fields must be populated. If + // checksums_location is filled, the server will return the corresponding + // contents to the user. If object_location is filled, the server will + // calculate the checksums based on the content there and return that to the + // user. For details on the format of the checksums, see + // http://go/scotty-diff-protocol. + ChecksumsLocation *GdataCompositeMedia `json:"checksumsLocation,omitempty"` + // ChunkSizeBytes: The chunk size of checksums. Must be a multiple of 256KB. + ChunkSizeBytes int64 `json:"chunkSizeBytes,omitempty,string"` + // ObjectLocation: If set, calculate the checksums based on the contents and + // return them to the caller. + ObjectLocation *GdataCompositeMedia `json:"objectLocation,omitempty"` + // ObjectSizeBytes: The total size of the server object. + ObjectSizeBytes int64 `json:"objectSizeBytes,omitempty,string"` + // ObjectVersion: The object version of the object the checksums are being + // returned for. + ObjectVersion string `json:"objectVersion,omitempty"` + // ForceSendFields is a list of field names (e.g. "ChecksumsLocation") 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. "ChecksumsLocation") 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 GdataDiffChecksumsResponse) MarshalJSON() ([]byte, error) { + type NoMethod GdataDiffChecksumsResponse + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GdataDiffDownloadResponse: Backend response for a Diff download response. +// For details on the Scotty Diff protocol, visit +// http://go/scotty-diff-protocol. +type GdataDiffDownloadResponse struct { + // ObjectLocation: The original object location. + ObjectLocation *GdataCompositeMedia `json:"objectLocation,omitempty"` + // ForceSendFields is a list of field names (e.g. "ObjectLocation") 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. "ObjectLocation") 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 GdataDiffDownloadResponse) MarshalJSON() ([]byte, error) { + type NoMethod GdataDiffDownloadResponse + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GdataDiffUploadRequest: A Diff upload request. For details on the Scotty +// Diff protocol, visit http://go/scotty-diff-protocol. +type GdataDiffUploadRequest struct { + // ChecksumsInfo: The location of the checksums for the new object. Agents must + // clone the object located here, as the upload server will delete the contents + // once a response is received. For details on the format of the checksums, see + // http://go/scotty-diff-protocol. + ChecksumsInfo *GdataCompositeMedia `json:"checksumsInfo,omitempty"` + // ObjectInfo: The location of the new object. Agents must clone the object + // located here, as the upload server will delete the contents once a response + // is received. + ObjectInfo *GdataCompositeMedia `json:"objectInfo,omitempty"` + // ObjectVersion: The object version of the object that is the base version the + // incoming diff script will be applied to. This field will always be filled + // in. + ObjectVersion string `json:"objectVersion,omitempty"` + // ForceSendFields is a list of field names (e.g. "ChecksumsInfo") 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. "ChecksumsInfo") 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 GdataDiffUploadRequest) MarshalJSON() ([]byte, error) { + type NoMethod GdataDiffUploadRequest + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GdataDiffUploadResponse: Backend response for a Diff upload request. For +// details on the Scotty Diff protocol, visit http://go/scotty-diff-protocol. +type GdataDiffUploadResponse struct { + // ObjectVersion: The object version of the object at the server. Must be + // included in the end notification response. The version in the end + // notification response must correspond to the new version of the object that + // is now stored at the server, after the upload. + ObjectVersion string `json:"objectVersion,omitempty"` + // OriginalObject: The location of the original file for a diff upload request. + // Must be filled in if responding to an upload start notification. + OriginalObject *GdataCompositeMedia `json:"originalObject,omitempty"` + // ForceSendFields is a list of field names (e.g. "ObjectVersion") 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. "ObjectVersion") 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 GdataDiffUploadResponse) MarshalJSON() ([]byte, error) { + type NoMethod GdataDiffUploadResponse + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GdataDiffVersionResponse: Backend response for a Diff get version response. +// For details on the Scotty Diff protocol, visit +// http://go/scotty-diff-protocol. +type GdataDiffVersionResponse struct { + // ObjectSizeBytes: The total size of the server object. + ObjectSizeBytes int64 `json:"objectSizeBytes,omitempty,string"` + // ObjectVersion: The version of the object stored at the server. + ObjectVersion string `json:"objectVersion,omitempty"` + // ForceSendFields is a list of field names (e.g. "ObjectSizeBytes") 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. "ObjectSizeBytes") 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 GdataDiffVersionResponse) MarshalJSON() ([]byte, error) { + type NoMethod GdataDiffVersionResponse + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GdataDownloadParameters: Parameters specific to media downloads. +type GdataDownloadParameters struct { + // AllowGzipCompression: A boolean to be returned in the response to Scotty. + // Allows/disallows gzip encoding of the payload content when the server thinks + // it's advantageous (hence, does not guarantee compression) which allows + // Scotty to GZip the response to the client. + AllowGzipCompression bool `json:"allowGzipCompression,omitempty"` + // IgnoreRange: Determining whether or not Apiary should skip the inclusion of + // any Content-Range header on its response to Scotty. + IgnoreRange bool `json:"ignoreRange,omitempty"` + // ForceSendFields is a list of field names (e.g. "AllowGzipCompression") 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. "AllowGzipCompression") 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 GdataDownloadParameters) MarshalJSON() ([]byte, error) { + type NoMethod GdataDownloadParameters + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GdataMedia: A reference to data stored on the filesystem, on GFS or in +// blobstore. +type GdataMedia struct { + // Algorithm: Deprecated, use one of explicit hash type fields instead. + // Algorithm used for calculating the hash. As of 2011/01/21, "MD5" is the only + // possible value for this field. New values may be added at any time. + Algorithm string `json:"algorithm,omitempty"` + // BigstoreObjectRef: Use object_id instead. + BigstoreObjectRef string `json:"bigstoreObjectRef,omitempty"` + // BlobRef: Blobstore v1 reference, set if reference_type is BLOBSTORE_REF This + // should be the byte representation of a blobstore.BlobRef. Since Blobstore is + // deprecating v1, use blobstore2_info instead. For now, any v2 blob will also + // be represented in this field as v1 BlobRef. + BlobRef string `json:"blobRef,omitempty"` + // Blobstore2Info: Blobstore v2 info, set if reference_type is BLOBSTORE_REF + // and it refers to a v2 blob. + Blobstore2Info *GdataBlobstore2Info `json:"blobstore2Info,omitempty"` + // CompositeMedia: A composite media composed of one or more media objects, set + // if reference_type is COMPOSITE_MEDIA. The media length field must be set to + // the sum of the lengths of all composite media objects. Note: All composite + // media must have length specified. + CompositeMedia []*GdataCompositeMedia `json:"compositeMedia,omitempty"` + // ContentType: MIME type of the data + ContentType string `json:"contentType,omitempty"` + // ContentTypeInfo: Extended content type information provided for Scotty + // uploads. + ContentTypeInfo *GdataContentTypeInfo `json:"contentTypeInfo,omitempty"` + // CosmoBinaryReference: A binary data reference for a media download. Serves + // as a technology-agnostic binary reference in some Google infrastructure. + // This value is a serialized storage_cosmo.BinaryReference proto. Storing it + // as bytes is a hack to get around the fact that the cosmo proto (as well as + // others it includes) doesn't support JavaScript. This prevents us from + // including the actual type of this field. + CosmoBinaryReference string `json:"cosmoBinaryReference,omitempty"` + // Crc32cHash: For Scotty Uploads: Scotty-provided hashes for uploads For + // Scotty Downloads: (WARNING: DO NOT USE WITHOUT PERMISSION FROM THE SCOTTY + // TEAM.) A Hash provided by the agent to be used to verify the data being + // downloaded. Currently only supported for inline payloads. Further, only + // crc32c_hash is currently supported. + Crc32cHash int64 `json:"crc32cHash,omitempty"` + // DiffChecksumsResponse: Set if reference_type is DIFF_CHECKSUMS_RESPONSE. + DiffChecksumsResponse *GdataDiffChecksumsResponse `json:"diffChecksumsResponse,omitempty"` + // DiffDownloadResponse: Set if reference_type is DIFF_DOWNLOAD_RESPONSE. + DiffDownloadResponse *GdataDiffDownloadResponse `json:"diffDownloadResponse,omitempty"` + // DiffUploadRequest: Set if reference_type is DIFF_UPLOAD_REQUEST. + DiffUploadRequest *GdataDiffUploadRequest `json:"diffUploadRequest,omitempty"` + // DiffUploadResponse: Set if reference_type is DIFF_UPLOAD_RESPONSE. + DiffUploadResponse *GdataDiffUploadResponse `json:"diffUploadResponse,omitempty"` + // DiffVersionResponse: Set if reference_type is DIFF_VERSION_RESPONSE. + DiffVersionResponse *GdataDiffVersionResponse `json:"diffVersionResponse,omitempty"` + // DownloadParameters: Parameters for a media download. + DownloadParameters *GdataDownloadParameters `json:"downloadParameters,omitempty"` + // Filename: Original file name + Filename string `json:"filename,omitempty"` + // Hash: Deprecated, use one of explicit hash type fields instead. These two + // hash related fields will only be populated on Scotty based media uploads and + // will contain the content of the hash group in the NotificationRequest: + // http://cs/#google3/blobstore2/api/scotty/service/proto/upload_listener.proto&q=class:Hash + // Hex encoded hash value of the uploaded media. + Hash string `json:"hash,omitempty"` + // HashVerified: For Scotty uploads only. If a user sends a hash code and the + // backend has requested that Scotty verify the upload against the client hash, + // Scotty will perform the check on behalf of the backend and will reject it if + // the hashes don't match. This is set to true if Scotty performed this + // verification. + HashVerified bool `json:"hashVerified,omitempty"` + // Inline: Media data, set if reference_type is INLINE + Inline string `json:"inline,omitempty"` + // IsPotentialRetry: |is_potential_retry| is set false only when Scotty is + // certain that it has not sent the request before. When a client resumes an + // upload, this field must be set true in agent calls, because Scotty cannot be + // certain that it has never sent the request before due to potential failure + // in the session state persistence. + IsPotentialRetry bool `json:"isPotentialRetry,omitempty"` + // Length: Size of the data, in bytes + Length int64 `json:"length,omitempty,string"` + // Md5Hash: Scotty-provided MD5 hash for an upload. + Md5Hash string `json:"md5Hash,omitempty"` + // MediaId: Media id to forward to the operation GetMedia. Can be set if + // reference_type is GET_MEDIA. + MediaId string `json:"mediaId,omitempty"` + // ObjectId: Reference to a TI Blob, set if reference_type is BIGSTORE_REF. + ObjectId *GdataObjectId `json:"objectId,omitempty"` + // Path: Path to the data, set if reference_type is PATH + Path string `json:"path,omitempty"` + // ReferenceType: Describes what the field reference contains. + // + // Possible values: + // "PATH" - Reference contains a GFS path or a local path. + // "BLOB_REF" - Reference points to a blobstore object. This could be either + // a v1 blob_ref or a v2 blobstore2_info. Clients should check blobstore2_info + // first, since v1 is being deprecated. + // "INLINE" - Data is included into this proto buffer + // "GET_MEDIA" - Data should be accessed from the current service using the + // operation GetMedia. + // "COMPOSITE_MEDIA" - The content for this media object is stored across + // multiple partial media objects under the composite_media field. + // "BIGSTORE_REF" - Reference points to a bigstore object + // "DIFF_VERSION_RESPONSE" - Indicates the data is stored in + // diff_version_response. + // "DIFF_CHECKSUMS_RESPONSE" - Indicates the data is stored in + // diff_checksums_response. + // "DIFF_DOWNLOAD_RESPONSE" - Indicates the data is stored in + // diff_download_response. + // "DIFF_UPLOAD_REQUEST" - Indicates the data is stored in + // diff_upload_request. + // "DIFF_UPLOAD_RESPONSE" - Indicates the data is stored in + // diff_upload_response. + // "COSMO_BINARY_REFERENCE" - Indicates the data is stored in + // cosmo_binary_reference. + // "ARBITRARY_BYTES" - Informs Scotty to generate a response payload with the + // size specified in the length field. The contents of the payload are + // generated by Scotty and are undefined. This is useful for testing download + // speeds between the user and Scotty without involving a real payload source. + // Note: range is not supported when using arbitrary_bytes. + ReferenceType string `json:"referenceType,omitempty"` + // Sha1Hash: Scotty-provided SHA1 hash for an upload. + Sha1Hash string `json:"sha1Hash,omitempty"` + // Sha256Hash: Scotty-provided SHA256 hash for an upload. + Sha256Hash string `json:"sha256Hash,omitempty"` + // Timestamp: Time at which the media data was last updated, in milliseconds + // since UNIX epoch + Timestamp uint64 `json:"timestamp,omitempty,string"` + // Token: A unique fingerprint/version id for the media data + Token string `json:"token,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the server. + googleapi.ServerResponse `json:"-"` + // ForceSendFields is a list of field names (e.g. "Algorithm") 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. "Algorithm") 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 GdataMedia) MarshalJSON() ([]byte, error) { + type NoMethod GdataMedia + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GdataObjectId: This is a copy of the tech.blob.ObjectId proto, which could +// not be used directly here due to transitive closure issues with JavaScript +// support; see http://b/8801763. +type GdataObjectId struct { + // BucketName: The name of the bucket to which this object belongs. + BucketName string `json:"bucketName,omitempty"` + // Generation: Generation of the object. Generations are monotonically + // increasing across writes, allowing them to be be compared to determine which + // generation is newer. If this is omitted in a request, then you are + // requesting the live object. See http://go/bigstore-versions + Generation int64 `json:"generation,omitempty,string"` + // ObjectName: The name of the object. + ObjectName string `json:"objectName,omitempty"` + // ForceSendFields is a list of field names (e.g. "BucketName") 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. "BucketName") 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 GdataObjectId) MarshalJSON() ([]byte, error) { + type NoMethod GdataObjectId + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleApiDistribution: `Distribution` contains summary statistics for a // population of values. It optionally contains a histogram representing the // distribution of those values across a set of buckets. The summary statistics @@ -17158,6 +17666,40 @@ func (s GoogleCloudDiscoveryengineV1alphaEvaluationEvaluationSpecQuerySetSpec) M return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudDiscoveryengineV1alphaExportMetricsMetadata: Metadata related to +// the progress of the Export operation. This is returned by the +// google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1alphaExportMetricsMetadata struct { + // CreateTime: Operation create time. + CreateTime string `json:"createTime,omitempty"` + // UpdateTime: Operation last update time. If the operation is done, this is + // also the finish time. + UpdateTime string `json:"updateTime,omitempty"` + // 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 GoogleCloudDiscoveryengineV1alphaExportMetricsMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaExportMetricsMetadata + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaExportMetricsResponse: Response of the +// ExportMetricsRequest. If the long running operation was successful, then +// this message is returned by the google.longrunning.Operations.response +// field. +type GoogleCloudDiscoveryengineV1alphaExportMetricsResponse struct { +} + // GoogleCloudDiscoveryengineV1alphaFieldConfig: Configurations for fields of a // schema. For example, configuring a field is indexable, or searchable. type GoogleCloudDiscoveryengineV1alphaFieldConfig struct { @@ -17966,9 +18508,9 @@ type GoogleCloudDiscoveryengineV1alphaListSessionsRequest struct { // Filter: A comma-separated list of fields to filter by, in EBNF grammar. The // supported fields are: * `user_pseudo_id` * `state` * `display_name` * // `starred` * `is_pinned` * `labels` * `create_time` * `update_time` Examples: - // "user_pseudo_id = some_id" "display_name = \"some_name\"" "starred = true" - // "is_pinned=true AND (NOT labels:hidden)" "create_time > - // \"1970-01-01T12:00:00Z\"" + // * `user_pseudo_id = some_id` * `display_name = "some_name" * `starred = + // true` * `is_pinned=true AND (NOT labels:hidden)` * `create_time > + // "1970-01-01T12:00:00Z" Filter string `json:"filter,omitempty"` // OrderBy: A comma-separated list of fields to order by, sorted in ascending // order. Use "desc" after a field name for descending. Supported fields: * @@ -18981,9 +19523,12 @@ type GoogleCloudDiscoveryengineV1alphaSearchRequest struct { // better interpret the query. If a value isn't specified, the query language // code is automatically detected, which may not be accurate. LanguageCode string `json:"languageCode,omitempty"` - // NaturalLanguageQueryUnderstandingSpec: If - // `naturalLanguageQueryUnderstandingSpec` is not specified, no additional - // natural language query understanding will be done. + // NaturalLanguageQueryUnderstandingSpec: Config for natural language query + // understanding capabilities, such as extracting structured field filters from + // the query. Refer to this documentation + // (https://cloud.google.com/generative-ai-app-builder/docs/natural-language-queries) + // for more information. If `naturalLanguageQueryUnderstandingSpec` is not + // specified, no additional natural language query understanding will be done. NaturalLanguageQueryUnderstandingSpec *GoogleCloudDiscoveryengineV1alphaSearchRequestNaturalLanguageQueryUnderstandingSpec `json:"naturalLanguageQueryUnderstandingSpec,omitempty"` // Offset: A 0-indexed integer that specifies the current offset (that is, // starting result location, amongst the Documents deemed by the API as @@ -20026,6 +20571,27 @@ func (s GoogleCloudDiscoveryengineV1alphaSearchRequestImageQuery) MarshalJSON() // ngSpec: Specification to enable natural language understanding capabilities // for search requests. type GoogleCloudDiscoveryengineV1alphaSearchRequestNaturalLanguageQueryUnderstandingSpec struct { + // ExtractedFilterBehavior: Optional. Controls behavior of how extracted + // filters are applied to the search. The default behavior depends on the + // request. For single datastore structured search, the default is + // `HARD_FILTER`. For multi-datastore search, the default behavior is + // `SOFT_BOOST`. Location-based filters are always applied as hard filters, and + // the `SOFT_BOOST` setting will not affect them. This field is only used if + // SearchRequest.natural_language_query_understanding_spec.filter_extraction_con + // dition is set to FilterExtractionCondition.ENABLED. + // + // Possible values: + // "EXTRACTED_FILTER_BEHAVIOR_UNSPECIFIED" - + // `EXTRACTED_FILTER_BEHAVIOR_UNSPECIFIED` will use the default behavior for + // extracted filters. For single datastore search, the default is to apply as + // hard filters. For multi-datastore search, the default is to apply as soft + // boosts. + // "HARD_FILTER" - Applies all extracted filters as hard filters on the + // results. Results that do not pass the extracted filters will not be returned + // in the result set. + // "SOFT_BOOST" - Applies all extracted filters as soft boosts. Results that + // pass the filters will be boosted up to higher ranks in the result set. + ExtractedFilterBehavior string `json:"extractedFilterBehavior,omitempty"` // FilterExtractionCondition: The condition under which filter extraction // should occur. Server behavior defaults to `DISABLED`. // @@ -20040,13 +20606,13 @@ type GoogleCloudDiscoveryengineV1alphaSearchRequestNaturalLanguageQueryUnderstan // If this field is set, it overrides the field names set in // ServingConfig.geo_search_query_detection_field_names. GeoSearchQueryDetectionFieldNames []string `json:"geoSearchQueryDetectionFieldNames,omitempty"` - // ForceSendFields is a list of field names (e.g. "FilterExtractionCondition") - // to unconditionally include in API requests. By default, fields with empty or + // ForceSendFields is a list of field names (e.g. "ExtractedFilterBehavior") 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. "FilterExtractionCondition") to + // NullFields is a list of field names (e.g. "ExtractedFilterBehavior") 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. @@ -24116,9 +24682,12 @@ type GoogleCloudDiscoveryengineV1betaSearchRequest struct { // better interpret the query. If a value isn't specified, the query language // code is automatically detected, which may not be accurate. LanguageCode string `json:"languageCode,omitempty"` - // NaturalLanguageQueryUnderstandingSpec: If - // `naturalLanguageQueryUnderstandingSpec` is not specified, no additional - // natural language query understanding will be done. + // NaturalLanguageQueryUnderstandingSpec: Config for natural language query + // understanding capabilities, such as extracting structured field filters from + // the query. Refer to this documentation + // (https://cloud.google.com/generative-ai-app-builder/docs/natural-language-queries) + // for more information. If `naturalLanguageQueryUnderstandingSpec` is not + // specified, no additional natural language query understanding will be done. NaturalLanguageQueryUnderstandingSpec *GoogleCloudDiscoveryengineV1betaSearchRequestNaturalLanguageQueryUnderstandingSpec `json:"naturalLanguageQueryUnderstandingSpec,omitempty"` // Offset: A 0-indexed integer that specifies the current offset (that is, // starting result location, amongst the Documents deemed by the API as @@ -25156,6 +25725,27 @@ func (s GoogleCloudDiscoveryengineV1betaSearchRequestImageQuery) MarshalJSON() ( // gSpec: Specification to enable natural language understanding capabilities // for search requests. type GoogleCloudDiscoveryengineV1betaSearchRequestNaturalLanguageQueryUnderstandingSpec struct { + // ExtractedFilterBehavior: Optional. Controls behavior of how extracted + // filters are applied to the search. The default behavior depends on the + // request. For single datastore structured search, the default is + // `HARD_FILTER`. For multi-datastore search, the default behavior is + // `SOFT_BOOST`. Location-based filters are always applied as hard filters, and + // the `SOFT_BOOST` setting will not affect them. This field is only used if + // SearchRequest.natural_language_query_understanding_spec.filter_extraction_con + // dition is set to FilterExtractionCondition.ENABLED. + // + // Possible values: + // "EXTRACTED_FILTER_BEHAVIOR_UNSPECIFIED" - + // `EXTRACTED_FILTER_BEHAVIOR_UNSPECIFIED` will use the default behavior for + // extracted filters. For single datastore search, the default is to apply as + // hard filters. For multi-datastore search, the default is to apply as soft + // boosts. + // "HARD_FILTER" - Applies all extracted filters as hard filters on the + // results. Results that do not pass the extracted filters will not be returned + // in the result set. + // "SOFT_BOOST" - Applies all extracted filters as soft boosts. Results that + // pass the filters will be boosted up to higher ranks in the result set. + ExtractedFilterBehavior string `json:"extractedFilterBehavior,omitempty"` // FilterExtractionCondition: The condition under which filter extraction // should occur. Server behavior defaults to `DISABLED`. // @@ -25170,13 +25760,13 @@ type GoogleCloudDiscoveryengineV1betaSearchRequestNaturalLanguageQueryUnderstand // If this field is set, it overrides the field names set in // ServingConfig.geo_search_query_detection_field_names. GeoSearchQueryDetectionFieldNames []string `json:"geoSearchQueryDetectionFieldNames,omitempty"` - // ForceSendFields is a list of field names (e.g. "FilterExtractionCondition") - // to unconditionally include in API requests. By default, fields with empty or + // ForceSendFields is a list of field names (e.g. "ExtractedFilterBehavior") 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. "FilterExtractionCondition") to + // NullFields is a list of field names (e.g. "ExtractedFilterBehavior") 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. @@ -26380,6 +26970,147 @@ func (s GoogleTypeTimeZone) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +type MediaDownloadCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// Download: Downloads a file from the session. +// +// - name: The resource name of the Session. Format: +// `projects/{project}/locations/{location}/collections/{collection}/engines/{ +// engine}/sessions/{session}`. +func (r *MediaService) Download(name string) *MediaDownloadCall { + c := &MediaDownloadCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + return c +} + +// FileId sets the optional parameter "fileId": Required. The ID of the file to +// be downloaded. +func (c *MediaDownloadCall) FileId(fileId string) *MediaDownloadCall { + c.urlParams_.Set("fileId", fileId) + return c +} + +// ViewId sets the optional parameter "viewId": The ID of the view to be +// downloaded. +func (c *MediaDownloadCall) ViewId(viewId string) *MediaDownloadCall { + c.urlParams_.Set("viewId", viewId) + 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 *MediaDownloadCall) Fields(s ...googleapi.Field) *MediaDownloadCall { + 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 *MediaDownloadCall) IfNoneMatch(entityTag string) *MediaDownloadCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do and Download methods. +func (c *MediaDownloadCall) Context(ctx context.Context) *MediaDownloadCall { + 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 *MediaDownloadCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *MediaDownloadCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}:downloadFile") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("GET", urls, nil) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "name": c.name, + }) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "discoveryengine.media.download", "request", internallog.HTTPRequest(req, nil)) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Download fetches the API endpoint's "media" value, instead of the normal +// API response value. If the returned error is nil, the Response is guaranteed to +// have a 2xx status code. Callers must close the Response.Body as usual. +func (c *MediaDownloadCall) Download(opts ...googleapi.CallOption) (*http.Response, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("media") + if err != nil { + return nil, err + } + if err := googleapi.CheckResponse(res); err != nil { + res.Body.Close() + return nil, gensupport.WrapError(err) + } + return res, nil +} + +// Do executes the "discoveryengine.media.download" call. +// Any non-2xx status code is an error. Response headers are in either +// *GdataMedia.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 *MediaDownloadCall) Do(opts ...googleapi.CallOption) (*GdataMedia, 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 := &GdataMedia{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + b, err := gensupport.DecodeResponseBytes(target, res) + if err != nil { + return nil, err + } + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "discoveryengine.media.download", "response", internallog.HTTPResponse(res, b)) + return ret, nil +} + type ProjectsProvisionCall struct { s *Service name string @@ -33999,9 +34730,9 @@ func (r *ProjectsLocationsCollectionsDataStoresSessionsService) List(parent stri // Filter sets the optional parameter "filter": A comma-separated list of // fields to filter by, in EBNF grammar. The supported fields are: * // `user_pseudo_id` * `state` * `display_name` * `starred` * `is_pinned` * -// `labels` * `create_time` * `update_time` Examples: "user_pseudo_id = -// some_id" "display_name = \"some_name\"" "starred = true" "is_pinned=true AND -// (NOT labels:hidden)" "create_time > \"1970-01-01T12:00:00Z\"" +// `labels` * `create_time` * `update_time` Examples: * `user_pseudo_id = +// some_id` * `display_name = "some_name" * `starred = true` * `is_pinned=true +// AND (NOT labels:hidden)` * `create_time > "1970-01-01T12:00:00Z" func (c *ProjectsLocationsCollectionsDataStoresSessionsListCall) Filter(filter string) *ProjectsLocationsCollectionsDataStoresSessionsListCall { c.urlParams_.Set("filter", filter) return c @@ -40990,9 +41721,9 @@ func (r *ProjectsLocationsCollectionsEnginesSessionsService) List(parent string) // Filter sets the optional parameter "filter": A comma-separated list of // fields to filter by, in EBNF grammar. The supported fields are: * // `user_pseudo_id` * `state` * `display_name` * `starred` * `is_pinned` * -// `labels` * `create_time` * `update_time` Examples: "user_pseudo_id = -// some_id" "display_name = \"some_name\"" "starred = true" "is_pinned=true AND -// (NOT labels:hidden)" "create_time > \"1970-01-01T12:00:00Z\"" +// `labels` * `create_time` * `update_time` Examples: * `user_pseudo_id = +// some_id` * `display_name = "some_name" * `starred = true` * `is_pinned=true +// AND (NOT labels:hidden)` * `create_time > "1970-01-01T12:00:00Z" func (c *ProjectsLocationsCollectionsEnginesSessionsListCall) Filter(filter string) *ProjectsLocationsCollectionsEnginesSessionsListCall { c.urlParams_.Set("filter", filter) return c @@ -47718,9 +48449,9 @@ func (r *ProjectsLocationsDataStoresSessionsService) List(parent string) *Projec // Filter sets the optional parameter "filter": A comma-separated list of // fields to filter by, in EBNF grammar. The supported fields are: * // `user_pseudo_id` * `state` * `display_name` * `starred` * `is_pinned` * -// `labels` * `create_time` * `update_time` Examples: "user_pseudo_id = -// some_id" "display_name = \"some_name\"" "starred = true" "is_pinned=true AND -// (NOT labels:hidden)" "create_time > \"1970-01-01T12:00:00Z\"" +// `labels` * `create_time` * `update_time` Examples: * `user_pseudo_id = +// some_id` * `display_name = "some_name" * `starred = true` * `is_pinned=true +// AND (NOT labels:hidden)` * `create_time > "1970-01-01T12:00:00Z" func (c *ProjectsLocationsDataStoresSessionsListCall) Filter(filter string) *ProjectsLocationsDataStoresSessionsListCall { c.urlParams_.Set("filter", filter) return c diff --git a/discoveryengine/v1alpha/discoveryengine-api.json b/discoveryengine/v1alpha/discoveryengine-api.json index d3446351057..69796097833 100644 --- a/discoveryengine/v1alpha/discoveryengine-api.json +++ b/discoveryengine/v1alpha/discoveryengine-api.json @@ -3020,7 +3020,7 @@ ], "parameters": { "filter": { - "description": "A comma-separated list of fields to filter by, in EBNF grammar. The supported fields are: * `user_pseudo_id` * `state` * `display_name` * `starred` * `is_pinned` * `labels` * `create_time` * `update_time` Examples: \"user_pseudo_id = some_id\" \"display_name = \\\"some_name\\\"\" \"starred = true\" \"is_pinned=true AND (NOT labels:hidden)\" \"create_time \u003e \\\"1970-01-01T12:00:00Z\\\"\"", + "description": "A comma-separated list of fields to filter by, in EBNF grammar. The supported fields are: * `user_pseudo_id` * `state` * `display_name` * `starred` * `is_pinned` * `labels` * `create_time` * `update_time` Examples: * `user_pseudo_id = some_id` * `display_name = \"some_name\"` * `starred = true` * `is_pinned=true AND (NOT labels:hidden)` * `create_time \u003e \"1970-01-01T12:00:00Z\"`", "location": "query", "type": "string" }, @@ -4215,6 +4215,38 @@ } }, "resources": { + "analytics": { + "methods": { + "exportMetrics": { + "description": "Exports metrics.", + "flatPath": "v1alpha/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/engines/{enginesId}/analytics:exportMetrics", + "httpMethod": "POST", + "id": "discoveryengine.projects.locations.collections.engines.analytics.exportMetrics", + "parameterOrder": [ + "analytics" + ], + "parameters": { + "analytics": { + "description": "Required. The analytics resource name under the engine where the metrics are created. The format is `projects/{project}/locations/{location}/collections/{collection}/engines/{engine}/analytics`.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/engines/[^/]+/analytics$", + "required": true, + "type": "string" + } + }, + "path": "v1alpha/{+analytics}:exportMetrics", + "request": { + "$ref": "GoogleCloudDiscoveryengineV1alphaExportMetricsRequest" + }, + "response": { + "$ref": "GoogleLongrunningOperation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + } + } + }, "assistants": { "methods": { "get": { @@ -5123,7 +5155,7 @@ ], "parameters": { "filter": { - "description": "A comma-separated list of fields to filter by, in EBNF grammar. The supported fields are: * `user_pseudo_id` * `state` * `display_name` * `starred` * `is_pinned` * `labels` * `create_time` * `update_time` Examples: \"user_pseudo_id = some_id\" \"display_name = \\\"some_name\\\"\" \"starred = true\" \"is_pinned=true AND (NOT labels:hidden)\" \"create_time \u003e \\\"1970-01-01T12:00:00Z\\\"\"", + "description": "A comma-separated list of fields to filter by, in EBNF grammar. The supported fields are: * `user_pseudo_id` * `state` * `display_name` * `starred` * `is_pinned` * `labels` * `create_time` * `update_time` Examples: * `user_pseudo_id = some_id` * `display_name = \"some_name\"` * `starred = true` * `is_pinned=true AND (NOT labels:hidden)` * `create_time \u003e \"1970-01-01T12:00:00Z\"`", "location": "query", "type": "string" }, @@ -7262,7 +7294,7 @@ ], "parameters": { "filter": { - "description": "A comma-separated list of fields to filter by, in EBNF grammar. The supported fields are: * `user_pseudo_id` * `state` * `display_name` * `starred` * `is_pinned` * `labels` * `create_time` * `update_time` Examples: \"user_pseudo_id = some_id\" \"display_name = \\\"some_name\\\"\" \"starred = true\" \"is_pinned=true AND (NOT labels:hidden)\" \"create_time \u003e \\\"1970-01-01T12:00:00Z\\\"\"", + "description": "A comma-separated list of fields to filter by, in EBNF grammar. The supported fields are: * `user_pseudo_id` * `state` * `display_name` * `starred` * `is_pinned` * `labels` * `create_time` * `update_time` Examples: * `user_pseudo_id = some_id` * `display_name = \"some_name\"` * `starred = true` * `is_pinned=true AND (NOT labels:hidden)` * `create_time \u003e \"1970-01-01T12:00:00Z\"`", "location": "query", "type": "string" }, @@ -9420,7 +9452,7 @@ } } }, - "revision": "20250724", + "revision": "20250728", "rootUrl": "https://discoveryengine.googleapis.com/", "schemas": { "ApiservingMediaRequestInfo": { @@ -15355,6 +15387,21 @@ "properties": {}, "type": "object" }, + "GoogleCloudDiscoveryengineV1alphaBigQueryDestination": { + "description": "The BigQuery output destination configuration.", + "id": "GoogleCloudDiscoveryengineV1alphaBigQueryDestination", + "properties": { + "datasetId": { + "description": "Required. The ID of a BigQuery Dataset.", + "type": "string" + }, + "tableId": { + "description": "Required. The table_id of exported BigQuery table.", + "type": "string" + } + }, + "type": "object" + }, "GoogleCloudDiscoveryengineV1alphaBigQuerySource": { "description": "BigQuery source import data from.", "id": "GoogleCloudDiscoveryengineV1alphaBigQuerySource", @@ -18831,6 +18878,40 @@ }, "type": "object" }, + "GoogleCloudDiscoveryengineV1alphaExportMetricsMetadata": { + "description": "Metadata related to the progress of the Export operation. This is returned by the google.longrunning.Operation.metadata field.", + "id": "GoogleCloudDiscoveryengineV1alphaExportMetricsMetadata", + "properties": { + "createTime": { + "description": "Operation create time.", + "format": "google-datetime", + "type": "string" + }, + "updateTime": { + "description": "Operation last update time. If the operation is done, this is also the finish time.", + "format": "google-datetime", + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaExportMetricsRequest": { + "description": "Request message for the `ExportMetrics` method.", + "id": "GoogleCloudDiscoveryengineV1alphaExportMetricsRequest", + "properties": { + "outputConfig": { + "$ref": "GoogleCloudDiscoveryengineV1alphaOutputConfig", + "description": "Required. The output location of the data." + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaExportMetricsResponse": { + "description": "Response of the ExportMetricsRequest. If the long running operation was successful, then this message is returned by the google.longrunning.Operations.response field.", + "id": "GoogleCloudDiscoveryengineV1alphaExportMetricsResponse", + "properties": {}, + "type": "object" + }, "GoogleCloudDiscoveryengineV1alphaFactChunk": { "description": "Fact Chunk.", "id": "GoogleCloudDiscoveryengineV1alphaFactChunk", @@ -20518,7 +20599,7 @@ "id": "GoogleCloudDiscoveryengineV1alphaListSessionsRequest", "properties": { "filter": { - "description": "A comma-separated list of fields to filter by, in EBNF grammar. The supported fields are: * `user_pseudo_id` * `state` * `display_name` * `starred` * `is_pinned` * `labels` * `create_time` * `update_time` Examples: \"user_pseudo_id = some_id\" \"display_name = \\\"some_name\\\"\" \"starred = true\" \"is_pinned=true AND (NOT labels:hidden)\" \"create_time \u003e \\\"1970-01-01T12:00:00Z\\\"\"", + "description": "A comma-separated list of fields to filter by, in EBNF grammar. The supported fields are: * `user_pseudo_id` * `state` * `display_name` * `starred` * `is_pinned` * `labels` * `create_time` * `update_time` Examples: * `user_pseudo_id = some_id` * `display_name = \"some_name\"` * `starred = true` * `is_pinned=true AND (NOT labels:hidden)` * `create_time \u003e \"1970-01-01T12:00:00Z\"`", "type": "string" }, "orderBy": { @@ -20698,6 +20779,17 @@ }, "type": "object" }, + "GoogleCloudDiscoveryengineV1alphaOutputConfig": { + "description": "The output configuration setting.", + "id": "GoogleCloudDiscoveryengineV1alphaOutputConfig", + "properties": { + "bigqueryDestination": { + "$ref": "GoogleCloudDiscoveryengineV1alphaBigQueryDestination", + "description": "The BigQuery location where the output is to be written to." + } + }, + "type": "object" + }, "GoogleCloudDiscoveryengineV1alphaPageInfo": { "description": "Detailed page information.", "id": "GoogleCloudDiscoveryengineV1alphaPageInfo", @@ -22202,7 +22294,7 @@ }, "naturalLanguageQueryUnderstandingSpec": { "$ref": "GoogleCloudDiscoveryengineV1alphaSearchRequestNaturalLanguageQueryUnderstandingSpec", - "description": "If `naturalLanguageQueryUnderstandingSpec` is not specified, no additional natural language query understanding will be done." + "description": "Config for natural language query understanding capabilities, such as extracting structured field filters from the query. Refer to [this documentation](https://cloud.google.com/generative-ai-app-builder/docs/natural-language-queries) for more information. If `naturalLanguageQueryUnderstandingSpec` is not specified, no additional natural language query understanding will be done." }, "offset": { "description": "A 0-indexed integer that specifies the current offset (that is, starting result location, amongst the Documents deemed by the API as relevant) in search results. This field is only considered if page_token is unset. If this field is negative, an `INVALID_ARGUMENT` is returned.", @@ -22811,6 +22903,20 @@ "description": "Specification to enable natural language understanding capabilities for search requests.", "id": "GoogleCloudDiscoveryengineV1alphaSearchRequestNaturalLanguageQueryUnderstandingSpec", "properties": { + "extractedFilterBehavior": { + "description": "Optional. Controls behavior of how extracted filters are applied to the search. The default behavior depends on the request. For single datastore structured search, the default is `HARD_FILTER`. For multi-datastore search, the default behavior is `SOFT_BOOST`. Location-based filters are always applied as hard filters, and the `SOFT_BOOST` setting will not affect them. This field is only used if SearchRequest.natural_language_query_understanding_spec.filter_extraction_condition is set to FilterExtractionCondition.ENABLED.", + "enum": [ + "EXTRACTED_FILTER_BEHAVIOR_UNSPECIFIED", + "HARD_FILTER", + "SOFT_BOOST" + ], + "enumDescriptions": [ + "`EXTRACTED_FILTER_BEHAVIOR_UNSPECIFIED` will use the default behavior for extracted filters. For single datastore search, the default is to apply as hard filters. For multi-datastore search, the default is to apply as soft boosts.", + "Applies all extracted filters as hard filters on the results. Results that do not pass the extracted filters will not be returned in the result set.", + "Applies all extracted filters as soft boosts. Results that pass the filters will be boosted up to higher ranks in the result set." + ], + "type": "string" + }, "filterExtractionCondition": { "description": "The condition under which filter extraction should occur. Server behavior defaults to `DISABLED`.", "enum": [ @@ -28067,7 +28173,7 @@ }, "naturalLanguageQueryUnderstandingSpec": { "$ref": "GoogleCloudDiscoveryengineV1betaSearchRequestNaturalLanguageQueryUnderstandingSpec", - "description": "If `naturalLanguageQueryUnderstandingSpec` is not specified, no additional natural language query understanding will be done." + "description": "Config for natural language query understanding capabilities, such as extracting structured field filters from the query. Refer to [this documentation](https://cloud.google.com/generative-ai-app-builder/docs/natural-language-queries) for more information. If `naturalLanguageQueryUnderstandingSpec` is not specified, no additional natural language query understanding will be done." }, "offset": { "description": "A 0-indexed integer that specifies the current offset (that is, starting result location, amongst the Documents deemed by the API as relevant) in search results. This field is only considered if page_token is unset. If this field is negative, an `INVALID_ARGUMENT` is returned.", @@ -28672,6 +28778,20 @@ "description": "Specification to enable natural language understanding capabilities for search requests.", "id": "GoogleCloudDiscoveryengineV1betaSearchRequestNaturalLanguageQueryUnderstandingSpec", "properties": { + "extractedFilterBehavior": { + "description": "Optional. Controls behavior of how extracted filters are applied to the search. The default behavior depends on the request. For single datastore structured search, the default is `HARD_FILTER`. For multi-datastore search, the default behavior is `SOFT_BOOST`. Location-based filters are always applied as hard filters, and the `SOFT_BOOST` setting will not affect them. This field is only used if SearchRequest.natural_language_query_understanding_spec.filter_extraction_condition is set to FilterExtractionCondition.ENABLED.", + "enum": [ + "EXTRACTED_FILTER_BEHAVIOR_UNSPECIFIED", + "HARD_FILTER", + "SOFT_BOOST" + ], + "enumDescriptions": [ + "`EXTRACTED_FILTER_BEHAVIOR_UNSPECIFIED` will use the default behavior for extracted filters. For single datastore search, the default is to apply as hard filters. For multi-datastore search, the default is to apply as soft boosts.", + "Applies all extracted filters as hard filters on the results. Results that do not pass the extracted filters will not be returned in the result set.", + "Applies all extracted filters as soft boosts. Results that pass the filters will be boosted up to higher ranks in the result set." + ], + "type": "string" + }, "filterExtractionCondition": { "description": "The condition under which filter extraction should occur. Server behavior defaults to `DISABLED`.", "enum": [ diff --git a/discoveryengine/v1alpha/discoveryengine-gen.go b/discoveryengine/v1alpha/discoveryengine-gen.go index 99183fd32b9..3f575724bee 100644 --- a/discoveryengine/v1alpha/discoveryengine-gen.go +++ b/discoveryengine/v1alpha/discoveryengine-gen.go @@ -615,6 +615,7 @@ type ProjectsLocationsCollectionsDataStoresWidgetConfigsService struct { func NewProjectsLocationsCollectionsEnginesService(s *Service) *ProjectsLocationsCollectionsEnginesService { rs := &ProjectsLocationsCollectionsEnginesService{s: s} + rs.Analytics = NewProjectsLocationsCollectionsEnginesAnalyticsService(s) rs.Assistants = NewProjectsLocationsCollectionsEnginesAssistantsService(s) rs.CompletionConfig = NewProjectsLocationsCollectionsEnginesCompletionConfigService(s) rs.Controls = NewProjectsLocationsCollectionsEnginesControlsService(s) @@ -629,6 +630,8 @@ func NewProjectsLocationsCollectionsEnginesService(s *Service) *ProjectsLocation type ProjectsLocationsCollectionsEnginesService struct { s *Service + Analytics *ProjectsLocationsCollectionsEnginesAnalyticsService + Assistants *ProjectsLocationsCollectionsEnginesAssistantsService CompletionConfig *ProjectsLocationsCollectionsEnginesCompletionConfigService @@ -646,6 +649,15 @@ type ProjectsLocationsCollectionsEnginesService struct { WidgetConfigs *ProjectsLocationsCollectionsEnginesWidgetConfigsService } +func NewProjectsLocationsCollectionsEnginesAnalyticsService(s *Service) *ProjectsLocationsCollectionsEnginesAnalyticsService { + rs := &ProjectsLocationsCollectionsEnginesAnalyticsService{s: s} + return rs +} + +type ProjectsLocationsCollectionsEnginesAnalyticsService struct { + s *Service +} + func NewProjectsLocationsCollectionsEnginesAssistantsService(s *Service) *ProjectsLocationsCollectionsEnginesAssistantsService { rs := &ProjectsLocationsCollectionsEnginesAssistantsService{s: s} return rs @@ -9340,6 +9352,31 @@ func (s GoogleCloudDiscoveryengineV1alphaBatchUpdateUserLicensesResponse) Marsha type GoogleCloudDiscoveryengineV1alphaBatchVerifyTargetSitesRequest struct { } +// GoogleCloudDiscoveryengineV1alphaBigQueryDestination: The BigQuery output +// destination configuration. +type GoogleCloudDiscoveryengineV1alphaBigQueryDestination struct { + // DatasetId: Required. The ID of a BigQuery Dataset. + DatasetId string `json:"datasetId,omitempty"` + // TableId: Required. The table_id of exported BigQuery table. + TableId string `json:"tableId,omitempty"` + // ForceSendFields is a list of field names (e.g. "DatasetId") 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. "DatasetId") 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 GoogleCloudDiscoveryengineV1alphaBigQueryDestination) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaBigQueryDestination + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudDiscoveryengineV1alphaBigQuerySource: BigQuery source import data // from. type GoogleCloudDiscoveryengineV1alphaBigQuerySource struct { @@ -13856,6 +13893,63 @@ func (s GoogleCloudDiscoveryengineV1alphaEvaluationEvaluationSpecQuerySetSpec) M return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudDiscoveryengineV1alphaExportMetricsMetadata: Metadata related to +// the progress of the Export operation. This is returned by the +// google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1alphaExportMetricsMetadata struct { + // CreateTime: Operation create time. + CreateTime string `json:"createTime,omitempty"` + // UpdateTime: Operation last update time. If the operation is done, this is + // also the finish time. + UpdateTime string `json:"updateTime,omitempty"` + // 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 GoogleCloudDiscoveryengineV1alphaExportMetricsMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaExportMetricsMetadata + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaExportMetricsRequest: Request message for +// the `ExportMetrics` method. +type GoogleCloudDiscoveryengineV1alphaExportMetricsRequest struct { + // OutputConfig: Required. The output location of the data. + OutputConfig *GoogleCloudDiscoveryengineV1alphaOutputConfig `json:"outputConfig,omitempty"` + // ForceSendFields is a list of field names (e.g. "OutputConfig") 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. "OutputConfig") 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 GoogleCloudDiscoveryengineV1alphaExportMetricsRequest) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaExportMetricsRequest + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaExportMetricsResponse: Response of the +// ExportMetricsRequest. If the long running operation was successful, then +// this message is returned by the google.longrunning.Operations.response +// field. +type GoogleCloudDiscoveryengineV1alphaExportMetricsResponse struct { +} + // GoogleCloudDiscoveryengineV1alphaFactChunk: Fact Chunk. type GoogleCloudDiscoveryengineV1alphaFactChunk struct { // ChunkText: Text content of the fact chunk. Can be at most 10K characters @@ -16209,9 +16303,9 @@ type GoogleCloudDiscoveryengineV1alphaListSessionsRequest struct { // Filter: A comma-separated list of fields to filter by, in EBNF grammar. The // supported fields are: * `user_pseudo_id` * `state` * `display_name` * // `starred` * `is_pinned` * `labels` * `create_time` * `update_time` Examples: - // "user_pseudo_id = some_id" "display_name = \"some_name\"" "starred = true" - // "is_pinned=true AND (NOT labels:hidden)" "create_time > - // \"1970-01-01T12:00:00Z\"" + // * `user_pseudo_id = some_id` * `display_name = "some_name" * `starred = + // true` * `is_pinned=true AND (NOT labels:hidden)` * `create_time > + // "1970-01-01T12:00:00Z" Filter string `json:"filter,omitempty"` // OrderBy: A comma-separated list of fields to order by, sorted in ascending // order. Use "desc" after a field name for descending. Supported fields: * @@ -16512,6 +16606,30 @@ func (s GoogleCloudDiscoveryengineV1alphaOrganicCrawlRateTimeSeries) MarshalJSON return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudDiscoveryengineV1alphaOutputConfig: The output configuration +// setting. +type GoogleCloudDiscoveryengineV1alphaOutputConfig struct { + // BigqueryDestination: The BigQuery location where the output is to be written + // to. + BigqueryDestination *GoogleCloudDiscoveryengineV1alphaBigQueryDestination `json:"bigqueryDestination,omitempty"` + // ForceSendFields is a list of field names (e.g. "BigqueryDestination") 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. "BigqueryDestination") 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 GoogleCloudDiscoveryengineV1alphaOutputConfig) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaOutputConfig + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudDiscoveryengineV1alphaPageInfo: Detailed page information. type GoogleCloudDiscoveryengineV1alphaPageInfo struct { // PageCategory: The most specific category associated with a category page. To @@ -18645,9 +18763,12 @@ type GoogleCloudDiscoveryengineV1alphaSearchRequest struct { // better interpret the query. If a value isn't specified, the query language // code is automatically detected, which may not be accurate. LanguageCode string `json:"languageCode,omitempty"` - // NaturalLanguageQueryUnderstandingSpec: If - // `naturalLanguageQueryUnderstandingSpec` is not specified, no additional - // natural language query understanding will be done. + // NaturalLanguageQueryUnderstandingSpec: Config for natural language query + // understanding capabilities, such as extracting structured field filters from + // the query. Refer to this documentation + // (https://cloud.google.com/generative-ai-app-builder/docs/natural-language-queries) + // for more information. If `naturalLanguageQueryUnderstandingSpec` is not + // specified, no additional natural language query understanding will be done. NaturalLanguageQueryUnderstandingSpec *GoogleCloudDiscoveryengineV1alphaSearchRequestNaturalLanguageQueryUnderstandingSpec `json:"naturalLanguageQueryUnderstandingSpec,omitempty"` // Offset: A 0-indexed integer that specifies the current offset (that is, // starting result location, amongst the Documents deemed by the API as @@ -19690,6 +19811,27 @@ func (s GoogleCloudDiscoveryengineV1alphaSearchRequestImageQuery) MarshalJSON() // ngSpec: Specification to enable natural language understanding capabilities // for search requests. type GoogleCloudDiscoveryengineV1alphaSearchRequestNaturalLanguageQueryUnderstandingSpec struct { + // ExtractedFilterBehavior: Optional. Controls behavior of how extracted + // filters are applied to the search. The default behavior depends on the + // request. For single datastore structured search, the default is + // `HARD_FILTER`. For multi-datastore search, the default behavior is + // `SOFT_BOOST`. Location-based filters are always applied as hard filters, and + // the `SOFT_BOOST` setting will not affect them. This field is only used if + // SearchRequest.natural_language_query_understanding_spec.filter_extraction_con + // dition is set to FilterExtractionCondition.ENABLED. + // + // Possible values: + // "EXTRACTED_FILTER_BEHAVIOR_UNSPECIFIED" - + // `EXTRACTED_FILTER_BEHAVIOR_UNSPECIFIED` will use the default behavior for + // extracted filters. For single datastore search, the default is to apply as + // hard filters. For multi-datastore search, the default is to apply as soft + // boosts. + // "HARD_FILTER" - Applies all extracted filters as hard filters on the + // results. Results that do not pass the extracted filters will not be returned + // in the result set. + // "SOFT_BOOST" - Applies all extracted filters as soft boosts. Results that + // pass the filters will be boosted up to higher ranks in the result set. + ExtractedFilterBehavior string `json:"extractedFilterBehavior,omitempty"` // FilterExtractionCondition: The condition under which filter extraction // should occur. Server behavior defaults to `DISABLED`. // @@ -19704,13 +19846,13 @@ type GoogleCloudDiscoveryengineV1alphaSearchRequestNaturalLanguageQueryUnderstan // If this field is set, it overrides the field names set in // ServingConfig.geo_search_query_detection_field_names. GeoSearchQueryDetectionFieldNames []string `json:"geoSearchQueryDetectionFieldNames,omitempty"` - // ForceSendFields is a list of field names (e.g. "FilterExtractionCondition") - // to unconditionally include in API requests. By default, fields with empty or + // ForceSendFields is a list of field names (e.g. "ExtractedFilterBehavior") 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. "FilterExtractionCondition") to + // NullFields is a list of field names (e.g. "ExtractedFilterBehavior") 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. @@ -26585,9 +26727,12 @@ type GoogleCloudDiscoveryengineV1betaSearchRequest struct { // better interpret the query. If a value isn't specified, the query language // code is automatically detected, which may not be accurate. LanguageCode string `json:"languageCode,omitempty"` - // NaturalLanguageQueryUnderstandingSpec: If - // `naturalLanguageQueryUnderstandingSpec` is not specified, no additional - // natural language query understanding will be done. + // NaturalLanguageQueryUnderstandingSpec: Config for natural language query + // understanding capabilities, such as extracting structured field filters from + // the query. Refer to this documentation + // (https://cloud.google.com/generative-ai-app-builder/docs/natural-language-queries) + // for more information. If `naturalLanguageQueryUnderstandingSpec` is not + // specified, no additional natural language query understanding will be done. NaturalLanguageQueryUnderstandingSpec *GoogleCloudDiscoveryengineV1betaSearchRequestNaturalLanguageQueryUnderstandingSpec `json:"naturalLanguageQueryUnderstandingSpec,omitempty"` // Offset: A 0-indexed integer that specifies the current offset (that is, // starting result location, amongst the Documents deemed by the API as @@ -27625,6 +27770,27 @@ func (s GoogleCloudDiscoveryengineV1betaSearchRequestImageQuery) MarshalJSON() ( // gSpec: Specification to enable natural language understanding capabilities // for search requests. type GoogleCloudDiscoveryengineV1betaSearchRequestNaturalLanguageQueryUnderstandingSpec struct { + // ExtractedFilterBehavior: Optional. Controls behavior of how extracted + // filters are applied to the search. The default behavior depends on the + // request. For single datastore structured search, the default is + // `HARD_FILTER`. For multi-datastore search, the default behavior is + // `SOFT_BOOST`. Location-based filters are always applied as hard filters, and + // the `SOFT_BOOST` setting will not affect them. This field is only used if + // SearchRequest.natural_language_query_understanding_spec.filter_extraction_con + // dition is set to FilterExtractionCondition.ENABLED. + // + // Possible values: + // "EXTRACTED_FILTER_BEHAVIOR_UNSPECIFIED" - + // `EXTRACTED_FILTER_BEHAVIOR_UNSPECIFIED` will use the default behavior for + // extracted filters. For single datastore search, the default is to apply as + // hard filters. For multi-datastore search, the default is to apply as soft + // boosts. + // "HARD_FILTER" - Applies all extracted filters as hard filters on the + // results. Results that do not pass the extracted filters will not be returned + // in the result set. + // "SOFT_BOOST" - Applies all extracted filters as soft boosts. Results that + // pass the filters will be boosted up to higher ranks in the result set. + ExtractedFilterBehavior string `json:"extractedFilterBehavior,omitempty"` // FilterExtractionCondition: The condition under which filter extraction // should occur. Server behavior defaults to `DISABLED`. // @@ -27639,13 +27805,13 @@ type GoogleCloudDiscoveryengineV1betaSearchRequestNaturalLanguageQueryUnderstand // If this field is set, it overrides the field names set in // ServingConfig.geo_search_query_detection_field_names. GeoSearchQueryDetectionFieldNames []string `json:"geoSearchQueryDetectionFieldNames,omitempty"` - // ForceSendFields is a list of field names (e.g. "FilterExtractionCondition") - // to unconditionally include in API requests. By default, fields with empty or + // ForceSendFields is a list of field names (e.g. "ExtractedFilterBehavior") 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. "FilterExtractionCondition") to + // NullFields is a list of field names (e.g. "ExtractedFilterBehavior") 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. @@ -40122,9 +40288,9 @@ func (r *ProjectsLocationsCollectionsDataStoresSessionsService) List(parent stri // Filter sets the optional parameter "filter": A comma-separated list of // fields to filter by, in EBNF grammar. The supported fields are: * // `user_pseudo_id` * `state` * `display_name` * `starred` * `is_pinned` * -// `labels` * `create_time` * `update_time` Examples: "user_pseudo_id = -// some_id" "display_name = \"some_name\"" "starred = true" "is_pinned=true AND -// (NOT labels:hidden)" "create_time > \"1970-01-01T12:00:00Z\"" +// `labels` * `create_time` * `update_time` Examples: * `user_pseudo_id = +// some_id` * `display_name = "some_name" * `starred = true` * `is_pinned=true +// AND (NOT labels:hidden)` * `create_time > "1970-01-01T12:00:00Z" func (c *ProjectsLocationsCollectionsDataStoresSessionsListCall) Filter(filter string) *ProjectsLocationsCollectionsDataStoresSessionsListCall { c.urlParams_.Set("filter", filter) return c @@ -44586,6 +44752,113 @@ func (c *ProjectsLocationsCollectionsEnginesTuneCall) Do(opts ...googleapi.CallO return ret, nil } +type ProjectsLocationsCollectionsEnginesAnalyticsExportMetricsCall struct { + s *Service + analytics string + googleclouddiscoveryenginev1alphaexportmetricsrequest *GoogleCloudDiscoveryengineV1alphaExportMetricsRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// ExportMetrics: Exports metrics. +// +// - analytics: The analytics resource name under the engine where the metrics +// are created. The format is +// `projects/{project}/locations/{location}/collections/{collection}/engines/{ +// engine}/analytics`. +func (r *ProjectsLocationsCollectionsEnginesAnalyticsService) ExportMetrics(analytics string, googleclouddiscoveryenginev1alphaexportmetricsrequest *GoogleCloudDiscoveryengineV1alphaExportMetricsRequest) *ProjectsLocationsCollectionsEnginesAnalyticsExportMetricsCall { + c := &ProjectsLocationsCollectionsEnginesAnalyticsExportMetricsCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.analytics = analytics + c.googleclouddiscoveryenginev1alphaexportmetricsrequest = googleclouddiscoveryenginev1alphaexportmetricsrequest + 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 *ProjectsLocationsCollectionsEnginesAnalyticsExportMetricsCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsEnginesAnalyticsExportMetricsCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsCollectionsEnginesAnalyticsExportMetricsCall) Context(ctx context.Context) *ProjectsLocationsCollectionsEnginesAnalyticsExportMetricsCall { + 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 *ProjectsLocationsCollectionsEnginesAnalyticsExportMetricsCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsCollectionsEnginesAnalyticsExportMetricsCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) + body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.googleclouddiscoveryenginev1alphaexportmetricsrequest) + if err != nil { + return nil, err + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+analytics}:exportMetrics") + 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{ + "analytics": c.analytics, + }) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "discoveryengine.projects.locations.collections.engines.analytics.exportMetrics", "request", internallog.HTTPRequest(req, body.Bytes())) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "discoveryengine.projects.locations.collections.engines.analytics.exportMetrics" 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 *ProjectsLocationsCollectionsEnginesAnalyticsExportMetricsCall) 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 + b, err := gensupport.DecodeResponseBytes(target, res) + if err != nil { + return nil, err + } + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "discoveryengine.projects.locations.collections.engines.analytics.exportMetrics", "response", internallog.HTTPResponse(res, b)) + return ret, nil +} + type ProjectsLocationsCollectionsEnginesAssistantsGetCall struct { s *Service name string @@ -48047,9 +48320,9 @@ func (r *ProjectsLocationsCollectionsEnginesSessionsService) List(parent string) // Filter sets the optional parameter "filter": A comma-separated list of // fields to filter by, in EBNF grammar. The supported fields are: * // `user_pseudo_id` * `state` * `display_name` * `starred` * `is_pinned` * -// `labels` * `create_time` * `update_time` Examples: "user_pseudo_id = -// some_id" "display_name = \"some_name\"" "starred = true" "is_pinned=true AND -// (NOT labels:hidden)" "create_time > \"1970-01-01T12:00:00Z\"" +// `labels` * `create_time` * `update_time` Examples: * `user_pseudo_id = +// some_id` * `display_name = "some_name" * `starred = true` * `is_pinned=true +// AND (NOT labels:hidden)` * `create_time > "1970-01-01T12:00:00Z" func (c *ProjectsLocationsCollectionsEnginesSessionsListCall) Filter(filter string) *ProjectsLocationsCollectionsEnginesSessionsListCall { c.urlParams_.Set("filter", filter) return c @@ -56002,9 +56275,9 @@ func (r *ProjectsLocationsDataStoresSessionsService) List(parent string) *Projec // Filter sets the optional parameter "filter": A comma-separated list of // fields to filter by, in EBNF grammar. The supported fields are: * // `user_pseudo_id` * `state` * `display_name` * `starred` * `is_pinned` * -// `labels` * `create_time` * `update_time` Examples: "user_pseudo_id = -// some_id" "display_name = \"some_name\"" "starred = true" "is_pinned=true AND -// (NOT labels:hidden)" "create_time > \"1970-01-01T12:00:00Z\"" +// `labels` * `create_time` * `update_time` Examples: * `user_pseudo_id = +// some_id` * `display_name = "some_name" * `starred = true` * `is_pinned=true +// AND (NOT labels:hidden)` * `create_time > "1970-01-01T12:00:00Z" func (c *ProjectsLocationsDataStoresSessionsListCall) Filter(filter string) *ProjectsLocationsDataStoresSessionsListCall { c.urlParams_.Set("filter", filter) return c diff --git a/discoveryengine/v1beta/discoveryengine-api.json b/discoveryengine/v1beta/discoveryengine-api.json index 803bbc1a87e..40a03955cff 100644 --- a/discoveryengine/v1beta/discoveryengine-api.json +++ b/discoveryengine/v1beta/discoveryengine-api.json @@ -135,6 +135,47 @@ }, "protocol": "rest", "resources": { + "media": { + "methods": { + "download": { + "description": "Downloads a file from the session.", + "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/engines/{enginesId}/sessions/{sessionsId}:downloadFile", + "httpMethod": "GET", + "id": "discoveryengine.media.download", + "parameterOrder": [ + "name" + ], + "parameters": { + "fileId": { + "description": "Required. The ID of the file to be downloaded.", + "location": "query", + "type": "string" + }, + "name": { + "description": "Required. The resource name of the Session. Format: `projects/{project}/locations/{location}/collections/{collection}/engines/{engine}/sessions/{session}`", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/engines/[^/]+/sessions/[^/]+$", + "required": true, + "type": "string" + }, + "viewId": { + "description": "Optional. The ID of the view to be downloaded.", + "location": "query", + "type": "string" + } + }, + "path": "v1beta/{+name}:downloadFile", + "response": { + "$ref": "GdataMedia" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ], + "supportsMediaDownload": true, + "useMediaDownloadService": true + } + } + }, "projects": { "methods": { "provision": { @@ -2320,7 +2361,7 @@ ], "parameters": { "filter": { - "description": "A comma-separated list of fields to filter by, in EBNF grammar. The supported fields are: * `user_pseudo_id` * `state` * `display_name` * `starred` * `is_pinned` * `labels` * `create_time` * `update_time` Examples: \"user_pseudo_id = some_id\" \"display_name = \\\"some_name\\\"\" \"starred = true\" \"is_pinned=true AND (NOT labels:hidden)\" \"create_time \u003e \\\"1970-01-01T12:00:00Z\\\"\"", + "description": "A comma-separated list of fields to filter by, in EBNF grammar. The supported fields are: * `user_pseudo_id` * `state` * `display_name` * `starred` * `is_pinned` * `labels` * `create_time` * `update_time` Examples: * `user_pseudo_id = some_id` * `display_name = \"some_name\"` * `starred = true` * `is_pinned=true AND (NOT labels:hidden)` * `create_time \u003e \"1970-01-01T12:00:00Z\"`", "location": "query", "type": "string" }, @@ -4331,7 +4372,7 @@ ], "parameters": { "filter": { - "description": "A comma-separated list of fields to filter by, in EBNF grammar. The supported fields are: * `user_pseudo_id` * `state` * `display_name` * `starred` * `is_pinned` * `labels` * `create_time` * `update_time` Examples: \"user_pseudo_id = some_id\" \"display_name = \\\"some_name\\\"\" \"starred = true\" \"is_pinned=true AND (NOT labels:hidden)\" \"create_time \u003e \\\"1970-01-01T12:00:00Z\\\"\"", + "description": "A comma-separated list of fields to filter by, in EBNF grammar. The supported fields are: * `user_pseudo_id` * `state` * `display_name` * `starred` * `is_pinned` * `labels` * `create_time` * `update_time` Examples: * `user_pseudo_id = some_id` * `display_name = \"some_name\"` * `starred = true` * `is_pinned=true AND (NOT labels:hidden)` * `create_time \u003e \"1970-01-01T12:00:00Z\"`", "location": "query", "type": "string" }, @@ -6198,7 +6239,7 @@ ], "parameters": { "filter": { - "description": "A comma-separated list of fields to filter by, in EBNF grammar. The supported fields are: * `user_pseudo_id` * `state` * `display_name` * `starred` * `is_pinned` * `labels` * `create_time` * `update_time` Examples: \"user_pseudo_id = some_id\" \"display_name = \\\"some_name\\\"\" \"starred = true\" \"is_pinned=true AND (NOT labels:hidden)\" \"create_time \u003e \\\"1970-01-01T12:00:00Z\\\"\"", + "description": "A comma-separated list of fields to filter by, in EBNF grammar. The supported fields are: * `user_pseudo_id` * `state` * `display_name` * `starred` * `is_pinned` * `labels` * `create_time` * `update_time` Examples: * `user_pseudo_id = some_id` * `display_name = \"some_name\"` * `starred = true` * `is_pinned=true AND (NOT labels:hidden)` * `create_time \u003e \"1970-01-01T12:00:00Z\"`", "location": "query", "type": "string" }, @@ -8106,9 +8147,439 @@ } } }, - "revision": "20250724", + "revision": "20250728", "rootUrl": "https://discoveryengine.googleapis.com/", "schemas": { + "GdataBlobstore2Info": { + "description": "Information to read/write to blobstore2.", + "id": "GdataBlobstore2Info", + "properties": { + "blobGeneration": { + "description": "The blob generation id.", + "format": "int64", + "type": "string" + }, + "blobId": { + "description": "The blob id, e.g., /blobstore/prod/playground/scotty", + "type": "string" + }, + "downloadReadHandle": { + "description": "Read handle passed from Bigstore -\u003e Scotty for a GCS download. This is a signed, serialized blobstore2.ReadHandle proto which must never be set outside of Bigstore, and is not applicable to non-GCS media downloads.", + "format": "byte", + "type": "string" + }, + "readToken": { + "description": "The blob read token. Needed to read blobs that have not been replicated. Might not be available until the final call.", + "type": "string" + }, + "uploadMetadataContainer": { + "description": "Metadata passed from Blobstore -\u003e Scotty for a new GCS upload. This is a signed, serialized blobstore2.BlobMetadataContainer proto which must never be consumed outside of Bigstore, and is not applicable to non-GCS media uploads.", + "format": "byte", + "type": "string" + } + }, + "type": "object" + }, + "GdataCompositeMedia": { + "description": "A sequence of media data references representing composite data. Introduced to support Bigstore composite objects. For details, visit http://go/bigstore-composites.", + "id": "GdataCompositeMedia", + "properties": { + "blobRef": { + "deprecated": true, + "description": "Blobstore v1 reference, set if reference_type is BLOBSTORE_REF This should be the byte representation of a blobstore.BlobRef. Since Blobstore is deprecating v1, use blobstore2_info instead. For now, any v2 blob will also be represented in this field as v1 BlobRef.", + "format": "byte", + "type": "string" + }, + "blobstore2Info": { + "$ref": "GdataBlobstore2Info", + "description": "Blobstore v2 info, set if reference_type is BLOBSTORE_REF and it refers to a v2 blob." + }, + "cosmoBinaryReference": { + "description": "A binary data reference for a media download. Serves as a technology-agnostic binary reference in some Google infrastructure. This value is a serialized storage_cosmo.BinaryReference proto. Storing it as bytes is a hack to get around the fact that the cosmo proto (as well as others it includes) doesn't support JavaScript. This prevents us from including the actual type of this field.", + "format": "byte", + "type": "string" + }, + "crc32cHash": { + "description": "crc32.c hash for the payload.", + "format": "uint32", + "type": "integer" + }, + "inline": { + "description": "Media data, set if reference_type is INLINE", + "format": "byte", + "type": "string" + }, + "length": { + "description": "Size of the data, in bytes", + "format": "int64", + "type": "string" + }, + "md5Hash": { + "description": "MD5 hash for the payload.", + "format": "byte", + "type": "string" + }, + "objectId": { + "$ref": "GdataObjectId", + "description": "Reference to a TI Blob, set if reference_type is BIGSTORE_REF." + }, + "path": { + "description": "Path to the data, set if reference_type is PATH", + "type": "string" + }, + "referenceType": { + "description": "Describes what the field reference contains.", + "enum": [ + "PATH", + "BLOB_REF", + "INLINE", + "BIGSTORE_REF", + "COSMO_BINARY_REFERENCE" + ], + "enumDescriptions": [ + "Reference contains a GFS path or a local path.", + "Reference points to a blobstore object. This could be either a v1 blob_ref or a v2 blobstore2_info. Clients should check blobstore2_info first, since v1 is being deprecated.", + "Data is included into this proto buffer", + "Reference points to a bigstore object", + "Indicates the data is stored in cosmo_binary_reference." + ], + "type": "string" + }, + "sha1Hash": { + "description": "SHA-1 hash for the payload.", + "format": "byte", + "type": "string" + } + }, + "type": "object" + }, + "GdataContentTypeInfo": { + "description": "Detailed Content-Type information from Scotty. The Content-Type of the media will typically be filled in by the header or Scotty's best_guess, but this extended information provides the backend with more information so that it can make a better decision if needed. This is only used on media upload requests from Scotty.", + "id": "GdataContentTypeInfo", + "properties": { + "bestGuess": { + "description": "Scotty's best guess of what the content type of the file is.", + "type": "string" + }, + "fromBytes": { + "description": "The content type of the file derived by looking at specific bytes (i.e. \"magic bytes\") of the actual file.", + "type": "string" + }, + "fromFileName": { + "description": "The content type of the file derived from the file extension of the original file name used by the client.", + "type": "string" + }, + "fromHeader": { + "description": "The content type of the file as specified in the request headers, multipart headers, or RUPIO start request.", + "type": "string" + }, + "fromUrlPath": { + "description": "The content type of the file derived from the file extension of the URL path. The URL path is assumed to represent a file name (which is typically only true for agents that are providing a REST API).", + "type": "string" + } + }, + "type": "object" + }, + "GdataDiffChecksumsResponse": { + "description": "Backend response for a Diff get checksums response. For details on the Scotty Diff protocol, visit http://go/scotty-diff-protocol.", + "id": "GdataDiffChecksumsResponse", + "properties": { + "checksumsLocation": { + "$ref": "GdataCompositeMedia", + "description": "Exactly one of these fields must be populated. If checksums_location is filled, the server will return the corresponding contents to the user. If object_location is filled, the server will calculate the checksums based on the content there and return that to the user. For details on the format of the checksums, see http://go/scotty-diff-protocol." + }, + "chunkSizeBytes": { + "description": "The chunk size of checksums. Must be a multiple of 256KB.", + "format": "int64", + "type": "string" + }, + "objectLocation": { + "$ref": "GdataCompositeMedia", + "description": "If set, calculate the checksums based on the contents and return them to the caller." + }, + "objectSizeBytes": { + "description": "The total size of the server object.", + "format": "int64", + "type": "string" + }, + "objectVersion": { + "description": "The object version of the object the checksums are being returned for.", + "type": "string" + } + }, + "type": "object" + }, + "GdataDiffDownloadResponse": { + "description": "Backend response for a Diff download response. For details on the Scotty Diff protocol, visit http://go/scotty-diff-protocol.", + "id": "GdataDiffDownloadResponse", + "properties": { + "objectLocation": { + "$ref": "GdataCompositeMedia", + "description": "The original object location." + } + }, + "type": "object" + }, + "GdataDiffUploadRequest": { + "description": "A Diff upload request. For details on the Scotty Diff protocol, visit http://go/scotty-diff-protocol.", + "id": "GdataDiffUploadRequest", + "properties": { + "checksumsInfo": { + "$ref": "GdataCompositeMedia", + "description": "The location of the checksums for the new object. Agents must clone the object located here, as the upload server will delete the contents once a response is received. For details on the format of the checksums, see http://go/scotty-diff-protocol." + }, + "objectInfo": { + "$ref": "GdataCompositeMedia", + "description": "The location of the new object. Agents must clone the object located here, as the upload server will delete the contents once a response is received." + }, + "objectVersion": { + "description": "The object version of the object that is the base version the incoming diff script will be applied to. This field will always be filled in.", + "type": "string" + } + }, + "type": "object" + }, + "GdataDiffUploadResponse": { + "description": "Backend response for a Diff upload request. For details on the Scotty Diff protocol, visit http://go/scotty-diff-protocol.", + "id": "GdataDiffUploadResponse", + "properties": { + "objectVersion": { + "description": "The object version of the object at the server. Must be included in the end notification response. The version in the end notification response must correspond to the new version of the object that is now stored at the server, after the upload.", + "type": "string" + }, + "originalObject": { + "$ref": "GdataCompositeMedia", + "description": "The location of the original file for a diff upload request. Must be filled in if responding to an upload start notification." + } + }, + "type": "object" + }, + "GdataDiffVersionResponse": { + "description": "Backend response for a Diff get version response. For details on the Scotty Diff protocol, visit http://go/scotty-diff-protocol.", + "id": "GdataDiffVersionResponse", + "properties": { + "objectSizeBytes": { + "description": "The total size of the server object.", + "format": "int64", + "type": "string" + }, + "objectVersion": { + "description": "The version of the object stored at the server.", + "type": "string" + } + }, + "type": "object" + }, + "GdataDownloadParameters": { + "description": "Parameters specific to media downloads.", + "id": "GdataDownloadParameters", + "properties": { + "allowGzipCompression": { + "description": "A boolean to be returned in the response to Scotty. Allows/disallows gzip encoding of the payload content when the server thinks it's advantageous (hence, does not guarantee compression) which allows Scotty to GZip the response to the client.", + "type": "boolean" + }, + "ignoreRange": { + "description": "Determining whether or not Apiary should skip the inclusion of any Content-Range header on its response to Scotty.", + "type": "boolean" + } + }, + "type": "object" + }, + "GdataMedia": { + "description": "A reference to data stored on the filesystem, on GFS or in blobstore.", + "id": "GdataMedia", + "properties": { + "algorithm": { + "deprecated": true, + "description": "Deprecated, use one of explicit hash type fields instead. Algorithm used for calculating the hash. As of 2011/01/21, \"MD5\" is the only possible value for this field. New values may be added at any time.", + "type": "string" + }, + "bigstoreObjectRef": { + "deprecated": true, + "description": "Use object_id instead.", + "format": "byte", + "type": "string" + }, + "blobRef": { + "deprecated": true, + "description": "Blobstore v1 reference, set if reference_type is BLOBSTORE_REF This should be the byte representation of a blobstore.BlobRef. Since Blobstore is deprecating v1, use blobstore2_info instead. For now, any v2 blob will also be represented in this field as v1 BlobRef.", + "format": "byte", + "type": "string" + }, + "blobstore2Info": { + "$ref": "GdataBlobstore2Info", + "description": "Blobstore v2 info, set if reference_type is BLOBSTORE_REF and it refers to a v2 blob." + }, + "compositeMedia": { + "description": "A composite media composed of one or more media objects, set if reference_type is COMPOSITE_MEDIA. The media length field must be set to the sum of the lengths of all composite media objects. Note: All composite media must have length specified.", + "items": { + "$ref": "GdataCompositeMedia" + }, + "type": "array" + }, + "contentType": { + "description": "MIME type of the data", + "type": "string" + }, + "contentTypeInfo": { + "$ref": "GdataContentTypeInfo", + "description": "Extended content type information provided for Scotty uploads." + }, + "cosmoBinaryReference": { + "description": "A binary data reference for a media download. Serves as a technology-agnostic binary reference in some Google infrastructure. This value is a serialized storage_cosmo.BinaryReference proto. Storing it as bytes is a hack to get around the fact that the cosmo proto (as well as others it includes) doesn't support JavaScript. This prevents us from including the actual type of this field.", + "format": "byte", + "type": "string" + }, + "crc32cHash": { + "description": "For Scotty Uploads: Scotty-provided hashes for uploads For Scotty Downloads: (WARNING: DO NOT USE WITHOUT PERMISSION FROM THE SCOTTY TEAM.) A Hash provided by the agent to be used to verify the data being downloaded. Currently only supported for inline payloads. Further, only crc32c_hash is currently supported.", + "format": "uint32", + "type": "integer" + }, + "diffChecksumsResponse": { + "$ref": "GdataDiffChecksumsResponse", + "description": "Set if reference_type is DIFF_CHECKSUMS_RESPONSE." + }, + "diffDownloadResponse": { + "$ref": "GdataDiffDownloadResponse", + "description": "Set if reference_type is DIFF_DOWNLOAD_RESPONSE." + }, + "diffUploadRequest": { + "$ref": "GdataDiffUploadRequest", + "description": "Set if reference_type is DIFF_UPLOAD_REQUEST." + }, + "diffUploadResponse": { + "$ref": "GdataDiffUploadResponse", + "description": "Set if reference_type is DIFF_UPLOAD_RESPONSE." + }, + "diffVersionResponse": { + "$ref": "GdataDiffVersionResponse", + "description": "Set if reference_type is DIFF_VERSION_RESPONSE." + }, + "downloadParameters": { + "$ref": "GdataDownloadParameters", + "description": "Parameters for a media download." + }, + "filename": { + "description": "Original file name", + "type": "string" + }, + "hash": { + "deprecated": true, + "description": "Deprecated, use one of explicit hash type fields instead. These two hash related fields will only be populated on Scotty based media uploads and will contain the content of the hash group in the NotificationRequest: http://cs/#google3/blobstore2/api/scotty/service/proto/upload_listener.proto\u0026q=class:Hash Hex encoded hash value of the uploaded media.", + "type": "string" + }, + "hashVerified": { + "description": "For Scotty uploads only. If a user sends a hash code and the backend has requested that Scotty verify the upload against the client hash, Scotty will perform the check on behalf of the backend and will reject it if the hashes don't match. This is set to true if Scotty performed this verification.", + "type": "boolean" + }, + "inline": { + "description": "Media data, set if reference_type is INLINE", + "format": "byte", + "type": "string" + }, + "isPotentialRetry": { + "description": "|is_potential_retry| is set false only when Scotty is certain that it has not sent the request before. When a client resumes an upload, this field must be set true in agent calls, because Scotty cannot be certain that it has never sent the request before due to potential failure in the session state persistence.", + "type": "boolean" + }, + "length": { + "description": "Size of the data, in bytes", + "format": "int64", + "type": "string" + }, + "md5Hash": { + "description": "Scotty-provided MD5 hash for an upload.", + "format": "byte", + "type": "string" + }, + "mediaId": { + "description": "Media id to forward to the operation GetMedia. Can be set if reference_type is GET_MEDIA.", + "format": "byte", + "type": "string" + }, + "objectId": { + "$ref": "GdataObjectId", + "description": "Reference to a TI Blob, set if reference_type is BIGSTORE_REF." + }, + "path": { + "description": "Path to the data, set if reference_type is PATH", + "type": "string" + }, + "referenceType": { + "description": "Describes what the field reference contains.", + "enum": [ + "PATH", + "BLOB_REF", + "INLINE", + "GET_MEDIA", + "COMPOSITE_MEDIA", + "BIGSTORE_REF", + "DIFF_VERSION_RESPONSE", + "DIFF_CHECKSUMS_RESPONSE", + "DIFF_DOWNLOAD_RESPONSE", + "DIFF_UPLOAD_REQUEST", + "DIFF_UPLOAD_RESPONSE", + "COSMO_BINARY_REFERENCE", + "ARBITRARY_BYTES" + ], + "enumDescriptions": [ + "Reference contains a GFS path or a local path.", + "Reference points to a blobstore object. This could be either a v1 blob_ref or a v2 blobstore2_info. Clients should check blobstore2_info first, since v1 is being deprecated.", + "Data is included into this proto buffer", + "Data should be accessed from the current service using the operation GetMedia.", + "The content for this media object is stored across multiple partial media objects under the composite_media field.", + "Reference points to a bigstore object", + "Indicates the data is stored in diff_version_response.", + "Indicates the data is stored in diff_checksums_response.", + "Indicates the data is stored in diff_download_response.", + "Indicates the data is stored in diff_upload_request.", + "Indicates the data is stored in diff_upload_response.", + "Indicates the data is stored in cosmo_binary_reference.", + "Informs Scotty to generate a response payload with the size specified in the length field. The contents of the payload are generated by Scotty and are undefined. This is useful for testing download speeds between the user and Scotty without involving a real payload source. Note: range is not supported when using arbitrary_bytes." + ], + "type": "string" + }, + "sha1Hash": { + "description": "Scotty-provided SHA1 hash for an upload.", + "format": "byte", + "type": "string" + }, + "sha256Hash": { + "description": "Scotty-provided SHA256 hash for an upload.", + "format": "byte", + "type": "string" + }, + "timestamp": { + "description": "Time at which the media data was last updated, in milliseconds since UNIX epoch", + "format": "uint64", + "type": "string" + }, + "token": { + "description": "A unique fingerprint/version id for the media data", + "type": "string" + } + }, + "type": "object" + }, + "GdataObjectId": { + "description": "This is a copy of the tech.blob.ObjectId proto, which could not be used directly here due to transitive closure issues with JavaScript support; see http://b/8801763.", + "id": "GdataObjectId", + "properties": { + "bucketName": { + "description": "The name of the bucket to which this object belongs.", + "type": "string" + }, + "generation": { + "description": "Generation of the object. Generations are monotonically increasing across writes, allowing them to be be compared to determine which generation is newer. If this is omitted in a request, then you are requesting the live object. See http://go/bigstore-versions", + "format": "int64", + "type": "string" + }, + "objectName": { + "description": "The name of the object.", + "type": "string" + } + }, + "type": "object" + }, "GoogleApiDistribution": { "description": "`Distribution` contains summary statistics for a population of values. It optionally contains a histogram representing the distribution of those values across a set of buckets. The summary statistics are the count, mean, sum of the squared deviation from the mean, the minimum, and the maximum of the set of population of values. The histogram is based on a sequence of buckets and gives a count of values that fall into each bucket. The boundaries of the buckets are given either explicitly or by formulas for buckets of fixed or exponentially increasing widths. Although it is not forbidden, it is generally a bad idea to include non-finite values (infinities or NaNs) in the population of values, as this will render the `mean` and `sum_of_squared_deviation` fields meaningless.", "id": "GoogleApiDistribution", @@ -14227,6 +14698,29 @@ }, "type": "object" }, + "GoogleCloudDiscoveryengineV1alphaExportMetricsMetadata": { + "description": "Metadata related to the progress of the Export operation. This is returned by the google.longrunning.Operation.metadata field.", + "id": "GoogleCloudDiscoveryengineV1alphaExportMetricsMetadata", + "properties": { + "createTime": { + "description": "Operation create time.", + "format": "google-datetime", + "type": "string" + }, + "updateTime": { + "description": "Operation last update time. If the operation is done, this is also the finish time.", + "format": "google-datetime", + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaExportMetricsResponse": { + "description": "Response of the ExportMetricsRequest. If the long running operation was successful, then this message is returned by the google.longrunning.Operations.response field.", + "id": "GoogleCloudDiscoveryengineV1alphaExportMetricsResponse", + "properties": {}, + "type": "object" + }, "GoogleCloudDiscoveryengineV1alphaFieldConfig": { "description": "Configurations for fields of a schema. For example, configuring a field is indexable, or searchable.", "id": "GoogleCloudDiscoveryengineV1alphaFieldConfig", @@ -14830,7 +15324,7 @@ "id": "GoogleCloudDiscoveryengineV1alphaListSessionsRequest", "properties": { "filter": { - "description": "A comma-separated list of fields to filter by, in EBNF grammar. The supported fields are: * `user_pseudo_id` * `state` * `display_name` * `starred` * `is_pinned` * `labels` * `create_time` * `update_time` Examples: \"user_pseudo_id = some_id\" \"display_name = \\\"some_name\\\"\" \"starred = true\" \"is_pinned=true AND (NOT labels:hidden)\" \"create_time \u003e \\\"1970-01-01T12:00:00Z\\\"\"", + "description": "A comma-separated list of fields to filter by, in EBNF grammar. The supported fields are: * `user_pseudo_id` * `state` * `display_name` * `starred` * `is_pinned` * `labels` * `create_time` * `update_time` Examples: * `user_pseudo_id = some_id` * `display_name = \"some_name\"` * `starred = true` * `is_pinned=true AND (NOT labels:hidden)` * `create_time \u003e \"1970-01-01T12:00:00Z\"`", "type": "string" }, "orderBy": { @@ -15636,7 +16130,7 @@ }, "naturalLanguageQueryUnderstandingSpec": { "$ref": "GoogleCloudDiscoveryengineV1alphaSearchRequestNaturalLanguageQueryUnderstandingSpec", - "description": "If `naturalLanguageQueryUnderstandingSpec` is not specified, no additional natural language query understanding will be done." + "description": "Config for natural language query understanding capabilities, such as extracting structured field filters from the query. Refer to [this documentation](https://cloud.google.com/generative-ai-app-builder/docs/natural-language-queries) for more information. If `naturalLanguageQueryUnderstandingSpec` is not specified, no additional natural language query understanding will be done." }, "offset": { "description": "A 0-indexed integer that specifies the current offset (that is, starting result location, amongst the Documents deemed by the API as relevant) in search results. This field is only considered if page_token is unset. If this field is negative, an `INVALID_ARGUMENT` is returned.", @@ -16245,6 +16739,20 @@ "description": "Specification to enable natural language understanding capabilities for search requests.", "id": "GoogleCloudDiscoveryengineV1alphaSearchRequestNaturalLanguageQueryUnderstandingSpec", "properties": { + "extractedFilterBehavior": { + "description": "Optional. Controls behavior of how extracted filters are applied to the search. The default behavior depends on the request. For single datastore structured search, the default is `HARD_FILTER`. For multi-datastore search, the default behavior is `SOFT_BOOST`. Location-based filters are always applied as hard filters, and the `SOFT_BOOST` setting will not affect them. This field is only used if SearchRequest.natural_language_query_understanding_spec.filter_extraction_condition is set to FilterExtractionCondition.ENABLED.", + "enum": [ + "EXTRACTED_FILTER_BEHAVIOR_UNSPECIFIED", + "HARD_FILTER", + "SOFT_BOOST" + ], + "enumDescriptions": [ + "`EXTRACTED_FILTER_BEHAVIOR_UNSPECIFIED` will use the default behavior for extracted filters. For single datastore search, the default is to apply as hard filters. For multi-datastore search, the default is to apply as soft boosts.", + "Applies all extracted filters as hard filters on the results. Results that do not pass the extracted filters will not be returned in the result set.", + "Applies all extracted filters as soft boosts. Results that pass the filters will be boosted up to higher ranks in the result set." + ], + "type": "string" + }, "filterExtractionCondition": { "description": "The condition under which filter extraction should occur. Server behavior defaults to `DISABLED`.", "enum": [ @@ -23960,7 +24468,7 @@ }, "naturalLanguageQueryUnderstandingSpec": { "$ref": "GoogleCloudDiscoveryengineV1betaSearchRequestNaturalLanguageQueryUnderstandingSpec", - "description": "If `naturalLanguageQueryUnderstandingSpec` is not specified, no additional natural language query understanding will be done." + "description": "Config for natural language query understanding capabilities, such as extracting structured field filters from the query. Refer to [this documentation](https://cloud.google.com/generative-ai-app-builder/docs/natural-language-queries) for more information. If `naturalLanguageQueryUnderstandingSpec` is not specified, no additional natural language query understanding will be done." }, "offset": { "description": "A 0-indexed integer that specifies the current offset (that is, starting result location, amongst the Documents deemed by the API as relevant) in search results. This field is only considered if page_token is unset. If this field is negative, an `INVALID_ARGUMENT` is returned.", @@ -24565,6 +25073,20 @@ "description": "Specification to enable natural language understanding capabilities for search requests.", "id": "GoogleCloudDiscoveryengineV1betaSearchRequestNaturalLanguageQueryUnderstandingSpec", "properties": { + "extractedFilterBehavior": { + "description": "Optional. Controls behavior of how extracted filters are applied to the search. The default behavior depends on the request. For single datastore structured search, the default is `HARD_FILTER`. For multi-datastore search, the default behavior is `SOFT_BOOST`. Location-based filters are always applied as hard filters, and the `SOFT_BOOST` setting will not affect them. This field is only used if SearchRequest.natural_language_query_understanding_spec.filter_extraction_condition is set to FilterExtractionCondition.ENABLED.", + "enum": [ + "EXTRACTED_FILTER_BEHAVIOR_UNSPECIFIED", + "HARD_FILTER", + "SOFT_BOOST" + ], + "enumDescriptions": [ + "`EXTRACTED_FILTER_BEHAVIOR_UNSPECIFIED` will use the default behavior for extracted filters. For single datastore search, the default is to apply as hard filters. For multi-datastore search, the default is to apply as soft boosts.", + "Applies all extracted filters as hard filters on the results. Results that do not pass the extracted filters will not be returned in the result set.", + "Applies all extracted filters as soft boosts. Results that pass the filters will be boosted up to higher ranks in the result set." + ], + "type": "string" + }, "filterExtractionCondition": { "description": "The condition under which filter extraction should occur. Server behavior defaults to `DISABLED`.", "enum": [ diff --git a/discoveryengine/v1beta/discoveryengine-gen.go b/discoveryengine/v1beta/discoveryengine-gen.go index 991aaf02214..fc6ae9052a0 100644 --- a/discoveryengine/v1beta/discoveryengine-gen.go +++ b/discoveryengine/v1beta/discoveryengine-gen.go @@ -128,6 +128,7 @@ func NewService(ctx context.Context, opts ...option.ClientOption) (*Service, err return nil, err } s := &Service{client: client, BasePath: basePath, logger: internaloption.GetLogger(opts)} + s.Media = NewMediaService(s) s.Projects = NewProjectsService(s) if endpoint != "" { s.BasePath = endpoint @@ -153,6 +154,8 @@ type Service struct { BasePath string // API endpoint base URL UserAgent string // optional additional User-Agent fragment + Media *MediaService + Projects *ProjectsService } @@ -163,6 +166,15 @@ func (s *Service) userAgent() string { return googleapi.UserAgent + " " + s.UserAgent } +func NewMediaService(s *Service) *MediaService { + rs := &MediaService{s: s} + return rs +} + +type MediaService struct { + s *Service +} + func NewProjectsService(s *Service) *ProjectsService { rs := &ProjectsService{s: s} rs.Locations = NewProjectsLocationsService(s) @@ -1072,6 +1084,502 @@ type ProjectsOperationsService struct { s *Service } +// GdataBlobstore2Info: Information to read/write to blobstore2. +type GdataBlobstore2Info struct { + // BlobGeneration: The blob generation id. + BlobGeneration int64 `json:"blobGeneration,omitempty,string"` + // BlobId: The blob id, e.g., /blobstore/prod/playground/scotty + BlobId string `json:"blobId,omitempty"` + // DownloadReadHandle: Read handle passed from Bigstore -> Scotty for a GCS + // download. This is a signed, serialized blobstore2.ReadHandle proto which + // must never be set outside of Bigstore, and is not applicable to non-GCS + // media downloads. + DownloadReadHandle string `json:"downloadReadHandle,omitempty"` + // ReadToken: The blob read token. Needed to read blobs that have not been + // replicated. Might not be available until the final call. + ReadToken string `json:"readToken,omitempty"` + // UploadMetadataContainer: Metadata passed from Blobstore -> Scotty for a new + // GCS upload. This is a signed, serialized blobstore2.BlobMetadataContainer + // proto which must never be consumed outside of Bigstore, and is not + // applicable to non-GCS media uploads. + UploadMetadataContainer string `json:"uploadMetadataContainer,omitempty"` + // ForceSendFields is a list of field names (e.g. "BlobGeneration") 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. "BlobGeneration") 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 GdataBlobstore2Info) MarshalJSON() ([]byte, error) { + type NoMethod GdataBlobstore2Info + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GdataCompositeMedia: A sequence of media data references representing +// composite data. Introduced to support Bigstore composite objects. For +// details, visit http://go/bigstore-composites. +type GdataCompositeMedia struct { + // BlobRef: Blobstore v1 reference, set if reference_type is BLOBSTORE_REF This + // should be the byte representation of a blobstore.BlobRef. Since Blobstore is + // deprecating v1, use blobstore2_info instead. For now, any v2 blob will also + // be represented in this field as v1 BlobRef. + BlobRef string `json:"blobRef,omitempty"` + // Blobstore2Info: Blobstore v2 info, set if reference_type is BLOBSTORE_REF + // and it refers to a v2 blob. + Blobstore2Info *GdataBlobstore2Info `json:"blobstore2Info,omitempty"` + // CosmoBinaryReference: A binary data reference for a media download. Serves + // as a technology-agnostic binary reference in some Google infrastructure. + // This value is a serialized storage_cosmo.BinaryReference proto. Storing it + // as bytes is a hack to get around the fact that the cosmo proto (as well as + // others it includes) doesn't support JavaScript. This prevents us from + // including the actual type of this field. + CosmoBinaryReference string `json:"cosmoBinaryReference,omitempty"` + // Crc32cHash: crc32.c hash for the payload. + Crc32cHash int64 `json:"crc32cHash,omitempty"` + // Inline: Media data, set if reference_type is INLINE + Inline string `json:"inline,omitempty"` + // Length: Size of the data, in bytes + Length int64 `json:"length,omitempty,string"` + // Md5Hash: MD5 hash for the payload. + Md5Hash string `json:"md5Hash,omitempty"` + // ObjectId: Reference to a TI Blob, set if reference_type is BIGSTORE_REF. + ObjectId *GdataObjectId `json:"objectId,omitempty"` + // Path: Path to the data, set if reference_type is PATH + Path string `json:"path,omitempty"` + // ReferenceType: Describes what the field reference contains. + // + // Possible values: + // "PATH" - Reference contains a GFS path or a local path. + // "BLOB_REF" - Reference points to a blobstore object. This could be either + // a v1 blob_ref or a v2 blobstore2_info. Clients should check blobstore2_info + // first, since v1 is being deprecated. + // "INLINE" - Data is included into this proto buffer + // "BIGSTORE_REF" - Reference points to a bigstore object + // "COSMO_BINARY_REFERENCE" - Indicates the data is stored in + // cosmo_binary_reference. + ReferenceType string `json:"referenceType,omitempty"` + // Sha1Hash: SHA-1 hash for the payload. + Sha1Hash string `json:"sha1Hash,omitempty"` + // ForceSendFields is a list of field names (e.g. "BlobRef") 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. "BlobRef") 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 GdataCompositeMedia) MarshalJSON() ([]byte, error) { + type NoMethod GdataCompositeMedia + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GdataContentTypeInfo: Detailed Content-Type information from Scotty. The +// Content-Type of the media will typically be filled in by the header or +// Scotty's best_guess, but this extended information provides the backend with +// more information so that it can make a better decision if needed. This is +// only used on media upload requests from Scotty. +type GdataContentTypeInfo struct { + // BestGuess: Scotty's best guess of what the content type of the file is. + BestGuess string `json:"bestGuess,omitempty"` + // FromBytes: The content type of the file derived by looking at specific bytes + // (i.e. "magic bytes") of the actual file. + FromBytes string `json:"fromBytes,omitempty"` + // FromFileName: The content type of the file derived from the file extension + // of the original file name used by the client. + FromFileName string `json:"fromFileName,omitempty"` + // FromHeader: The content type of the file as specified in the request + // headers, multipart headers, or RUPIO start request. + FromHeader string `json:"fromHeader,omitempty"` + // FromUrlPath: The content type of the file derived from the file extension of + // the URL path. The URL path is assumed to represent a file name (which is + // typically only true for agents that are providing a REST API). + FromUrlPath string `json:"fromUrlPath,omitempty"` + // ForceSendFields is a list of field names (e.g. "BestGuess") 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. "BestGuess") 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 GdataContentTypeInfo) MarshalJSON() ([]byte, error) { + type NoMethod GdataContentTypeInfo + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GdataDiffChecksumsResponse: Backend response for a Diff get checksums +// response. For details on the Scotty Diff protocol, visit +// http://go/scotty-diff-protocol. +type GdataDiffChecksumsResponse struct { + // ChecksumsLocation: Exactly one of these fields must be populated. If + // checksums_location is filled, the server will return the corresponding + // contents to the user. If object_location is filled, the server will + // calculate the checksums based on the content there and return that to the + // user. For details on the format of the checksums, see + // http://go/scotty-diff-protocol. + ChecksumsLocation *GdataCompositeMedia `json:"checksumsLocation,omitempty"` + // ChunkSizeBytes: The chunk size of checksums. Must be a multiple of 256KB. + ChunkSizeBytes int64 `json:"chunkSizeBytes,omitempty,string"` + // ObjectLocation: If set, calculate the checksums based on the contents and + // return them to the caller. + ObjectLocation *GdataCompositeMedia `json:"objectLocation,omitempty"` + // ObjectSizeBytes: The total size of the server object. + ObjectSizeBytes int64 `json:"objectSizeBytes,omitempty,string"` + // ObjectVersion: The object version of the object the checksums are being + // returned for. + ObjectVersion string `json:"objectVersion,omitempty"` + // ForceSendFields is a list of field names (e.g. "ChecksumsLocation") 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. "ChecksumsLocation") 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 GdataDiffChecksumsResponse) MarshalJSON() ([]byte, error) { + type NoMethod GdataDiffChecksumsResponse + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GdataDiffDownloadResponse: Backend response for a Diff download response. +// For details on the Scotty Diff protocol, visit +// http://go/scotty-diff-protocol. +type GdataDiffDownloadResponse struct { + // ObjectLocation: The original object location. + ObjectLocation *GdataCompositeMedia `json:"objectLocation,omitempty"` + // ForceSendFields is a list of field names (e.g. "ObjectLocation") 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. "ObjectLocation") 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 GdataDiffDownloadResponse) MarshalJSON() ([]byte, error) { + type NoMethod GdataDiffDownloadResponse + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GdataDiffUploadRequest: A Diff upload request. For details on the Scotty +// Diff protocol, visit http://go/scotty-diff-protocol. +type GdataDiffUploadRequest struct { + // ChecksumsInfo: The location of the checksums for the new object. Agents must + // clone the object located here, as the upload server will delete the contents + // once a response is received. For details on the format of the checksums, see + // http://go/scotty-diff-protocol. + ChecksumsInfo *GdataCompositeMedia `json:"checksumsInfo,omitempty"` + // ObjectInfo: The location of the new object. Agents must clone the object + // located here, as the upload server will delete the contents once a response + // is received. + ObjectInfo *GdataCompositeMedia `json:"objectInfo,omitempty"` + // ObjectVersion: The object version of the object that is the base version the + // incoming diff script will be applied to. This field will always be filled + // in. + ObjectVersion string `json:"objectVersion,omitempty"` + // ForceSendFields is a list of field names (e.g. "ChecksumsInfo") 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. "ChecksumsInfo") 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 GdataDiffUploadRequest) MarshalJSON() ([]byte, error) { + type NoMethod GdataDiffUploadRequest + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GdataDiffUploadResponse: Backend response for a Diff upload request. For +// details on the Scotty Diff protocol, visit http://go/scotty-diff-protocol. +type GdataDiffUploadResponse struct { + // ObjectVersion: The object version of the object at the server. Must be + // included in the end notification response. The version in the end + // notification response must correspond to the new version of the object that + // is now stored at the server, after the upload. + ObjectVersion string `json:"objectVersion,omitempty"` + // OriginalObject: The location of the original file for a diff upload request. + // Must be filled in if responding to an upload start notification. + OriginalObject *GdataCompositeMedia `json:"originalObject,omitempty"` + // ForceSendFields is a list of field names (e.g. "ObjectVersion") 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. "ObjectVersion") 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 GdataDiffUploadResponse) MarshalJSON() ([]byte, error) { + type NoMethod GdataDiffUploadResponse + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GdataDiffVersionResponse: Backend response for a Diff get version response. +// For details on the Scotty Diff protocol, visit +// http://go/scotty-diff-protocol. +type GdataDiffVersionResponse struct { + // ObjectSizeBytes: The total size of the server object. + ObjectSizeBytes int64 `json:"objectSizeBytes,omitempty,string"` + // ObjectVersion: The version of the object stored at the server. + ObjectVersion string `json:"objectVersion,omitempty"` + // ForceSendFields is a list of field names (e.g. "ObjectSizeBytes") 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. "ObjectSizeBytes") 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 GdataDiffVersionResponse) MarshalJSON() ([]byte, error) { + type NoMethod GdataDiffVersionResponse + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GdataDownloadParameters: Parameters specific to media downloads. +type GdataDownloadParameters struct { + // AllowGzipCompression: A boolean to be returned in the response to Scotty. + // Allows/disallows gzip encoding of the payload content when the server thinks + // it's advantageous (hence, does not guarantee compression) which allows + // Scotty to GZip the response to the client. + AllowGzipCompression bool `json:"allowGzipCompression,omitempty"` + // IgnoreRange: Determining whether or not Apiary should skip the inclusion of + // any Content-Range header on its response to Scotty. + IgnoreRange bool `json:"ignoreRange,omitempty"` + // ForceSendFields is a list of field names (e.g. "AllowGzipCompression") 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. "AllowGzipCompression") 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 GdataDownloadParameters) MarshalJSON() ([]byte, error) { + type NoMethod GdataDownloadParameters + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GdataMedia: A reference to data stored on the filesystem, on GFS or in +// blobstore. +type GdataMedia struct { + // Algorithm: Deprecated, use one of explicit hash type fields instead. + // Algorithm used for calculating the hash. As of 2011/01/21, "MD5" is the only + // possible value for this field. New values may be added at any time. + Algorithm string `json:"algorithm,omitempty"` + // BigstoreObjectRef: Use object_id instead. + BigstoreObjectRef string `json:"bigstoreObjectRef,omitempty"` + // BlobRef: Blobstore v1 reference, set if reference_type is BLOBSTORE_REF This + // should be the byte representation of a blobstore.BlobRef. Since Blobstore is + // deprecating v1, use blobstore2_info instead. For now, any v2 blob will also + // be represented in this field as v1 BlobRef. + BlobRef string `json:"blobRef,omitempty"` + // Blobstore2Info: Blobstore v2 info, set if reference_type is BLOBSTORE_REF + // and it refers to a v2 blob. + Blobstore2Info *GdataBlobstore2Info `json:"blobstore2Info,omitempty"` + // CompositeMedia: A composite media composed of one or more media objects, set + // if reference_type is COMPOSITE_MEDIA. The media length field must be set to + // the sum of the lengths of all composite media objects. Note: All composite + // media must have length specified. + CompositeMedia []*GdataCompositeMedia `json:"compositeMedia,omitempty"` + // ContentType: MIME type of the data + ContentType string `json:"contentType,omitempty"` + // ContentTypeInfo: Extended content type information provided for Scotty + // uploads. + ContentTypeInfo *GdataContentTypeInfo `json:"contentTypeInfo,omitempty"` + // CosmoBinaryReference: A binary data reference for a media download. Serves + // as a technology-agnostic binary reference in some Google infrastructure. + // This value is a serialized storage_cosmo.BinaryReference proto. Storing it + // as bytes is a hack to get around the fact that the cosmo proto (as well as + // others it includes) doesn't support JavaScript. This prevents us from + // including the actual type of this field. + CosmoBinaryReference string `json:"cosmoBinaryReference,omitempty"` + // Crc32cHash: For Scotty Uploads: Scotty-provided hashes for uploads For + // Scotty Downloads: (WARNING: DO NOT USE WITHOUT PERMISSION FROM THE SCOTTY + // TEAM.) A Hash provided by the agent to be used to verify the data being + // downloaded. Currently only supported for inline payloads. Further, only + // crc32c_hash is currently supported. + Crc32cHash int64 `json:"crc32cHash,omitempty"` + // DiffChecksumsResponse: Set if reference_type is DIFF_CHECKSUMS_RESPONSE. + DiffChecksumsResponse *GdataDiffChecksumsResponse `json:"diffChecksumsResponse,omitempty"` + // DiffDownloadResponse: Set if reference_type is DIFF_DOWNLOAD_RESPONSE. + DiffDownloadResponse *GdataDiffDownloadResponse `json:"diffDownloadResponse,omitempty"` + // DiffUploadRequest: Set if reference_type is DIFF_UPLOAD_REQUEST. + DiffUploadRequest *GdataDiffUploadRequest `json:"diffUploadRequest,omitempty"` + // DiffUploadResponse: Set if reference_type is DIFF_UPLOAD_RESPONSE. + DiffUploadResponse *GdataDiffUploadResponse `json:"diffUploadResponse,omitempty"` + // DiffVersionResponse: Set if reference_type is DIFF_VERSION_RESPONSE. + DiffVersionResponse *GdataDiffVersionResponse `json:"diffVersionResponse,omitempty"` + // DownloadParameters: Parameters for a media download. + DownloadParameters *GdataDownloadParameters `json:"downloadParameters,omitempty"` + // Filename: Original file name + Filename string `json:"filename,omitempty"` + // Hash: Deprecated, use one of explicit hash type fields instead. These two + // hash related fields will only be populated on Scotty based media uploads and + // will contain the content of the hash group in the NotificationRequest: + // http://cs/#google3/blobstore2/api/scotty/service/proto/upload_listener.proto&q=class:Hash + // Hex encoded hash value of the uploaded media. + Hash string `json:"hash,omitempty"` + // HashVerified: For Scotty uploads only. If a user sends a hash code and the + // backend has requested that Scotty verify the upload against the client hash, + // Scotty will perform the check on behalf of the backend and will reject it if + // the hashes don't match. This is set to true if Scotty performed this + // verification. + HashVerified bool `json:"hashVerified,omitempty"` + // Inline: Media data, set if reference_type is INLINE + Inline string `json:"inline,omitempty"` + // IsPotentialRetry: |is_potential_retry| is set false only when Scotty is + // certain that it has not sent the request before. When a client resumes an + // upload, this field must be set true in agent calls, because Scotty cannot be + // certain that it has never sent the request before due to potential failure + // in the session state persistence. + IsPotentialRetry bool `json:"isPotentialRetry,omitempty"` + // Length: Size of the data, in bytes + Length int64 `json:"length,omitempty,string"` + // Md5Hash: Scotty-provided MD5 hash for an upload. + Md5Hash string `json:"md5Hash,omitempty"` + // MediaId: Media id to forward to the operation GetMedia. Can be set if + // reference_type is GET_MEDIA. + MediaId string `json:"mediaId,omitempty"` + // ObjectId: Reference to a TI Blob, set if reference_type is BIGSTORE_REF. + ObjectId *GdataObjectId `json:"objectId,omitempty"` + // Path: Path to the data, set if reference_type is PATH + Path string `json:"path,omitempty"` + // ReferenceType: Describes what the field reference contains. + // + // Possible values: + // "PATH" - Reference contains a GFS path or a local path. + // "BLOB_REF" - Reference points to a blobstore object. This could be either + // a v1 blob_ref or a v2 blobstore2_info. Clients should check blobstore2_info + // first, since v1 is being deprecated. + // "INLINE" - Data is included into this proto buffer + // "GET_MEDIA" - Data should be accessed from the current service using the + // operation GetMedia. + // "COMPOSITE_MEDIA" - The content for this media object is stored across + // multiple partial media objects under the composite_media field. + // "BIGSTORE_REF" - Reference points to a bigstore object + // "DIFF_VERSION_RESPONSE" - Indicates the data is stored in + // diff_version_response. + // "DIFF_CHECKSUMS_RESPONSE" - Indicates the data is stored in + // diff_checksums_response. + // "DIFF_DOWNLOAD_RESPONSE" - Indicates the data is stored in + // diff_download_response. + // "DIFF_UPLOAD_REQUEST" - Indicates the data is stored in + // diff_upload_request. + // "DIFF_UPLOAD_RESPONSE" - Indicates the data is stored in + // diff_upload_response. + // "COSMO_BINARY_REFERENCE" - Indicates the data is stored in + // cosmo_binary_reference. + // "ARBITRARY_BYTES" - Informs Scotty to generate a response payload with the + // size specified in the length field. The contents of the payload are + // generated by Scotty and are undefined. This is useful for testing download + // speeds between the user and Scotty without involving a real payload source. + // Note: range is not supported when using arbitrary_bytes. + ReferenceType string `json:"referenceType,omitempty"` + // Sha1Hash: Scotty-provided SHA1 hash for an upload. + Sha1Hash string `json:"sha1Hash,omitempty"` + // Sha256Hash: Scotty-provided SHA256 hash for an upload. + Sha256Hash string `json:"sha256Hash,omitempty"` + // Timestamp: Time at which the media data was last updated, in milliseconds + // since UNIX epoch + Timestamp uint64 `json:"timestamp,omitempty,string"` + // Token: A unique fingerprint/version id for the media data + Token string `json:"token,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the server. + googleapi.ServerResponse `json:"-"` + // ForceSendFields is a list of field names (e.g. "Algorithm") 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. "Algorithm") 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 GdataMedia) MarshalJSON() ([]byte, error) { + type NoMethod GdataMedia + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GdataObjectId: This is a copy of the tech.blob.ObjectId proto, which could +// not be used directly here due to transitive closure issues with JavaScript +// support; see http://b/8801763. +type GdataObjectId struct { + // BucketName: The name of the bucket to which this object belongs. + BucketName string `json:"bucketName,omitempty"` + // Generation: Generation of the object. Generations are monotonically + // increasing across writes, allowing them to be be compared to determine which + // generation is newer. If this is omitted in a request, then you are + // requesting the live object. See http://go/bigstore-versions + Generation int64 `json:"generation,omitempty,string"` + // ObjectName: The name of the object. + ObjectName string `json:"objectName,omitempty"` + // ForceSendFields is a list of field names (e.g. "BucketName") 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. "BucketName") 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 GdataObjectId) MarshalJSON() ([]byte, error) { + type NoMethod GdataObjectId + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleApiDistribution: `Distribution` contains summary statistics for a // population of values. It optionally contains a histogram representing the // distribution of those values across a set of buckets. The summary statistics @@ -9182,6 +9690,40 @@ func (s GoogleCloudDiscoveryengineV1alphaEvaluationEvaluationSpecQuerySetSpec) M return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudDiscoveryengineV1alphaExportMetricsMetadata: Metadata related to +// the progress of the Export operation. This is returned by the +// google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1alphaExportMetricsMetadata struct { + // CreateTime: Operation create time. + CreateTime string `json:"createTime,omitempty"` + // UpdateTime: Operation last update time. If the operation is done, this is + // also the finish time. + UpdateTime string `json:"updateTime,omitempty"` + // 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 GoogleCloudDiscoveryengineV1alphaExportMetricsMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaExportMetricsMetadata + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaExportMetricsResponse: Response of the +// ExportMetricsRequest. If the long running operation was successful, then +// this message is returned by the google.longrunning.Operations.response +// field. +type GoogleCloudDiscoveryengineV1alphaExportMetricsResponse struct { +} + // GoogleCloudDiscoveryengineV1alphaFieldConfig: Configurations for fields of a // schema. For example, configuring a field is indexable, or searchable. type GoogleCloudDiscoveryengineV1alphaFieldConfig struct { @@ -9990,9 +10532,9 @@ type GoogleCloudDiscoveryengineV1alphaListSessionsRequest struct { // Filter: A comma-separated list of fields to filter by, in EBNF grammar. The // supported fields are: * `user_pseudo_id` * `state` * `display_name` * // `starred` * `is_pinned` * `labels` * `create_time` * `update_time` Examples: - // "user_pseudo_id = some_id" "display_name = \"some_name\"" "starred = true" - // "is_pinned=true AND (NOT labels:hidden)" "create_time > - // \"1970-01-01T12:00:00Z\"" + // * `user_pseudo_id = some_id` * `display_name = "some_name" * `starred = + // true` * `is_pinned=true AND (NOT labels:hidden)` * `create_time > + // "1970-01-01T12:00:00Z" Filter string `json:"filter,omitempty"` // OrderBy: A comma-separated list of fields to order by, sorted in ascending // order. Use "desc" after a field name for descending. Supported fields: * @@ -11005,9 +11547,12 @@ type GoogleCloudDiscoveryengineV1alphaSearchRequest struct { // better interpret the query. If a value isn't specified, the query language // code is automatically detected, which may not be accurate. LanguageCode string `json:"languageCode,omitempty"` - // NaturalLanguageQueryUnderstandingSpec: If - // `naturalLanguageQueryUnderstandingSpec` is not specified, no additional - // natural language query understanding will be done. + // NaturalLanguageQueryUnderstandingSpec: Config for natural language query + // understanding capabilities, such as extracting structured field filters from + // the query. Refer to this documentation + // (https://cloud.google.com/generative-ai-app-builder/docs/natural-language-queries) + // for more information. If `naturalLanguageQueryUnderstandingSpec` is not + // specified, no additional natural language query understanding will be done. NaturalLanguageQueryUnderstandingSpec *GoogleCloudDiscoveryengineV1alphaSearchRequestNaturalLanguageQueryUnderstandingSpec `json:"naturalLanguageQueryUnderstandingSpec,omitempty"` // Offset: A 0-indexed integer that specifies the current offset (that is, // starting result location, amongst the Documents deemed by the API as @@ -12050,6 +12595,27 @@ func (s GoogleCloudDiscoveryengineV1alphaSearchRequestImageQuery) MarshalJSON() // ngSpec: Specification to enable natural language understanding capabilities // for search requests. type GoogleCloudDiscoveryengineV1alphaSearchRequestNaturalLanguageQueryUnderstandingSpec struct { + // ExtractedFilterBehavior: Optional. Controls behavior of how extracted + // filters are applied to the search. The default behavior depends on the + // request. For single datastore structured search, the default is + // `HARD_FILTER`. For multi-datastore search, the default behavior is + // `SOFT_BOOST`. Location-based filters are always applied as hard filters, and + // the `SOFT_BOOST` setting will not affect them. This field is only used if + // SearchRequest.natural_language_query_understanding_spec.filter_extraction_con + // dition is set to FilterExtractionCondition.ENABLED. + // + // Possible values: + // "EXTRACTED_FILTER_BEHAVIOR_UNSPECIFIED" - + // `EXTRACTED_FILTER_BEHAVIOR_UNSPECIFIED` will use the default behavior for + // extracted filters. For single datastore search, the default is to apply as + // hard filters. For multi-datastore search, the default is to apply as soft + // boosts. + // "HARD_FILTER" - Applies all extracted filters as hard filters on the + // results. Results that do not pass the extracted filters will not be returned + // in the result set. + // "SOFT_BOOST" - Applies all extracted filters as soft boosts. Results that + // pass the filters will be boosted up to higher ranks in the result set. + ExtractedFilterBehavior string `json:"extractedFilterBehavior,omitempty"` // FilterExtractionCondition: The condition under which filter extraction // should occur. Server behavior defaults to `DISABLED`. // @@ -12064,13 +12630,13 @@ type GoogleCloudDiscoveryengineV1alphaSearchRequestNaturalLanguageQueryUnderstan // If this field is set, it overrides the field names set in // ServingConfig.geo_search_query_detection_field_names. GeoSearchQueryDetectionFieldNames []string `json:"geoSearchQueryDetectionFieldNames,omitempty"` - // ForceSendFields is a list of field names (e.g. "FilterExtractionCondition") - // to unconditionally include in API requests. By default, fields with empty or + // ForceSendFields is a list of field names (e.g. "ExtractedFilterBehavior") 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. "FilterExtractionCondition") to + // NullFields is a list of field names (e.g. "ExtractedFilterBehavior") 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. @@ -22896,9 +23462,12 @@ type GoogleCloudDiscoveryengineV1betaSearchRequest struct { // better interpret the query. If a value isn't specified, the query language // code is automatically detected, which may not be accurate. LanguageCode string `json:"languageCode,omitempty"` - // NaturalLanguageQueryUnderstandingSpec: If - // `naturalLanguageQueryUnderstandingSpec` is not specified, no additional - // natural language query understanding will be done. + // NaturalLanguageQueryUnderstandingSpec: Config for natural language query + // understanding capabilities, such as extracting structured field filters from + // the query. Refer to this documentation + // (https://cloud.google.com/generative-ai-app-builder/docs/natural-language-queries) + // for more information. If `naturalLanguageQueryUnderstandingSpec` is not + // specified, no additional natural language query understanding will be done. NaturalLanguageQueryUnderstandingSpec *GoogleCloudDiscoveryengineV1betaSearchRequestNaturalLanguageQueryUnderstandingSpec `json:"naturalLanguageQueryUnderstandingSpec,omitempty"` // Offset: A 0-indexed integer that specifies the current offset (that is, // starting result location, amongst the Documents deemed by the API as @@ -23936,6 +24505,27 @@ func (s GoogleCloudDiscoveryengineV1betaSearchRequestImageQuery) MarshalJSON() ( // gSpec: Specification to enable natural language understanding capabilities // for search requests. type GoogleCloudDiscoveryengineV1betaSearchRequestNaturalLanguageQueryUnderstandingSpec struct { + // ExtractedFilterBehavior: Optional. Controls behavior of how extracted + // filters are applied to the search. The default behavior depends on the + // request. For single datastore structured search, the default is + // `HARD_FILTER`. For multi-datastore search, the default behavior is + // `SOFT_BOOST`. Location-based filters are always applied as hard filters, and + // the `SOFT_BOOST` setting will not affect them. This field is only used if + // SearchRequest.natural_language_query_understanding_spec.filter_extraction_con + // dition is set to FilterExtractionCondition.ENABLED. + // + // Possible values: + // "EXTRACTED_FILTER_BEHAVIOR_UNSPECIFIED" - + // `EXTRACTED_FILTER_BEHAVIOR_UNSPECIFIED` will use the default behavior for + // extracted filters. For single datastore search, the default is to apply as + // hard filters. For multi-datastore search, the default is to apply as soft + // boosts. + // "HARD_FILTER" - Applies all extracted filters as hard filters on the + // results. Results that do not pass the extracted filters will not be returned + // in the result set. + // "SOFT_BOOST" - Applies all extracted filters as soft boosts. Results that + // pass the filters will be boosted up to higher ranks in the result set. + ExtractedFilterBehavior string `json:"extractedFilterBehavior,omitempty"` // FilterExtractionCondition: The condition under which filter extraction // should occur. Server behavior defaults to `DISABLED`. // @@ -23950,13 +24540,13 @@ type GoogleCloudDiscoveryengineV1betaSearchRequestNaturalLanguageQueryUnderstand // If this field is set, it overrides the field names set in // ServingConfig.geo_search_query_detection_field_names. GeoSearchQueryDetectionFieldNames []string `json:"geoSearchQueryDetectionFieldNames,omitempty"` - // ForceSendFields is a list of field names (e.g. "FilterExtractionCondition") - // to unconditionally include in API requests. By default, fields with empty or + // ForceSendFields is a list of field names (e.g. "ExtractedFilterBehavior") 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. "FilterExtractionCondition") to + // NullFields is a list of field names (e.g. "ExtractedFilterBehavior") 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. @@ -27120,6 +27710,147 @@ func (s GoogleTypeTimeZone) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +type MediaDownloadCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// Download: Downloads a file from the session. +// +// - name: The resource name of the Session. Format: +// `projects/{project}/locations/{location}/collections/{collection}/engines/{ +// engine}/sessions/{session}`. +func (r *MediaService) Download(name string) *MediaDownloadCall { + c := &MediaDownloadCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + return c +} + +// FileId sets the optional parameter "fileId": Required. The ID of the file to +// be downloaded. +func (c *MediaDownloadCall) FileId(fileId string) *MediaDownloadCall { + c.urlParams_.Set("fileId", fileId) + return c +} + +// ViewId sets the optional parameter "viewId": The ID of the view to be +// downloaded. +func (c *MediaDownloadCall) ViewId(viewId string) *MediaDownloadCall { + c.urlParams_.Set("viewId", viewId) + 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 *MediaDownloadCall) Fields(s ...googleapi.Field) *MediaDownloadCall { + 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 *MediaDownloadCall) IfNoneMatch(entityTag string) *MediaDownloadCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do and Download methods. +func (c *MediaDownloadCall) Context(ctx context.Context) *MediaDownloadCall { + 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 *MediaDownloadCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *MediaDownloadCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}:downloadFile") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("GET", urls, nil) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "name": c.name, + }) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "discoveryengine.media.download", "request", internallog.HTTPRequest(req, nil)) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Download fetches the API endpoint's "media" value, instead of the normal +// API response value. If the returned error is nil, the Response is guaranteed to +// have a 2xx status code. Callers must close the Response.Body as usual. +func (c *MediaDownloadCall) Download(opts ...googleapi.CallOption) (*http.Response, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("media") + if err != nil { + return nil, err + } + if err := googleapi.CheckResponse(res); err != nil { + res.Body.Close() + return nil, gensupport.WrapError(err) + } + return res, nil +} + +// Do executes the "discoveryengine.media.download" call. +// Any non-2xx status code is an error. Response headers are in either +// *GdataMedia.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 *MediaDownloadCall) Do(opts ...googleapi.CallOption) (*GdataMedia, 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 := &GdataMedia{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + b, err := gensupport.DecodeResponseBytes(target, res) + if err != nil { + return nil, err + } + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "discoveryengine.media.download", "response", internallog.HTTPResponse(res, b)) + return ret, nil +} + type ProjectsProvisionCall struct { s *Service name string @@ -35331,9 +36062,9 @@ func (r *ProjectsLocationsCollectionsDataStoresSessionsService) List(parent stri // Filter sets the optional parameter "filter": A comma-separated list of // fields to filter by, in EBNF grammar. The supported fields are: * // `user_pseudo_id` * `state` * `display_name` * `starred` * `is_pinned` * -// `labels` * `create_time` * `update_time` Examples: "user_pseudo_id = -// some_id" "display_name = \"some_name\"" "starred = true" "is_pinned=true AND -// (NOT labels:hidden)" "create_time > \"1970-01-01T12:00:00Z\"" +// `labels` * `create_time` * `update_time` Examples: * `user_pseudo_id = +// some_id` * `display_name = "some_name" * `starred = true` * `is_pinned=true +// AND (NOT labels:hidden)` * `create_time > "1970-01-01T12:00:00Z" func (c *ProjectsLocationsCollectionsDataStoresSessionsListCall) Filter(filter string) *ProjectsLocationsCollectionsDataStoresSessionsListCall { c.urlParams_.Set("filter", filter) return c @@ -42904,9 +43635,9 @@ func (r *ProjectsLocationsCollectionsEnginesSessionsService) List(parent string) // Filter sets the optional parameter "filter": A comma-separated list of // fields to filter by, in EBNF grammar. The supported fields are: * // `user_pseudo_id` * `state` * `display_name` * `starred` * `is_pinned` * -// `labels` * `create_time` * `update_time` Examples: "user_pseudo_id = -// some_id" "display_name = \"some_name\"" "starred = true" "is_pinned=true AND -// (NOT labels:hidden)" "create_time > \"1970-01-01T12:00:00Z\"" +// `labels` * `create_time` * `update_time` Examples: * `user_pseudo_id = +// some_id` * `display_name = "some_name" * `starred = true` * `is_pinned=true +// AND (NOT labels:hidden)` * `create_time > "1970-01-01T12:00:00Z" func (c *ProjectsLocationsCollectionsEnginesSessionsListCall) Filter(filter string) *ProjectsLocationsCollectionsEnginesSessionsListCall { c.urlParams_.Set("filter", filter) return c @@ -49896,9 +50627,9 @@ func (r *ProjectsLocationsDataStoresSessionsService) List(parent string) *Projec // Filter sets the optional parameter "filter": A comma-separated list of // fields to filter by, in EBNF grammar. The supported fields are: * // `user_pseudo_id` * `state` * `display_name` * `starred` * `is_pinned` * -// `labels` * `create_time` * `update_time` Examples: "user_pseudo_id = -// some_id" "display_name = \"some_name\"" "starred = true" "is_pinned=true AND -// (NOT labels:hidden)" "create_time > \"1970-01-01T12:00:00Z\"" +// `labels` * `create_time` * `update_time` Examples: * `user_pseudo_id = +// some_id` * `display_name = "some_name" * `starred = true` * `is_pinned=true +// AND (NOT labels:hidden)` * `create_time > "1970-01-01T12:00:00Z" func (c *ProjectsLocationsDataStoresSessionsListCall) Filter(filter string) *ProjectsLocationsDataStoresSessionsListCall { c.urlParams_.Set("filter", filter) return c diff --git a/firebaseml/v2beta/firebaseml-api.json b/firebaseml/v2beta/firebaseml-api.json index 40a21f1a04a..9f7d7f092d0 100644 --- a/firebaseml/v2beta/firebaseml-api.json +++ b/firebaseml/v2beta/firebaseml-api.json @@ -206,7 +206,7 @@ } } }, - "revision": "20250723", + "revision": "20250727", "rootUrl": "https://firebaseml.googleapis.com/", "schemas": { "Date": { @@ -704,7 +704,15 @@ "GoogleCloudAiplatformV1beta1EnterpriseWebSearch": { "description": "Tool to search public web data, powered by Vertex AI Search and Sec4 compliance.", "id": "GoogleCloudAiplatformV1beta1EnterpriseWebSearch", - "properties": {}, + "properties": { + "excludeDomains": { + "description": "Optional. List of domains to be excluded from the search results. The default limit is 2000 domains.", + "items": { + "type": "string" + }, + "type": "array" + } + }, "type": "object" }, "GoogleCloudAiplatformV1beta1ExecutableCode": { @@ -2429,7 +2437,15 @@ "GoogleCloudAiplatformV1beta1ToolGoogleSearch": { "description": "GoogleSearch tool type. Tool to support Google Search in Model. Powered by Google.", "id": "GoogleCloudAiplatformV1beta1ToolGoogleSearch", - "properties": {}, + "properties": { + "excludeDomains": { + "description": "Optional. List of domains to be excluded from the search results. The default limit is 2000 domains. Example: [\"amazon.com\", \"facebook.com\"].", + "items": { + "type": "string" + }, + "type": "array" + } + }, "type": "object" }, "GoogleCloudAiplatformV1beta1UrlContext": { diff --git a/firebaseml/v2beta/firebaseml-gen.go b/firebaseml/v2beta/firebaseml-gen.go index c5a1f71875a..91c291c5adf 100644 --- a/firebaseml/v2beta/firebaseml-gen.go +++ b/firebaseml/v2beta/firebaseml-gen.go @@ -861,6 +861,25 @@ func (s *GoogleCloudAiplatformV1beta1DynamicRetrievalConfig) UnmarshalJSON(data // GoogleCloudAiplatformV1beta1EnterpriseWebSearch: Tool to search public web // data, powered by Vertex AI Search and Sec4 compliance. type GoogleCloudAiplatformV1beta1EnterpriseWebSearch struct { + // ExcludeDomains: Optional. List of domains to be excluded from the search + // results. The default limit is 2000 domains. + ExcludeDomains []string `json:"excludeDomains,omitempty"` + // ForceSendFields is a list of field names (e.g. "ExcludeDomains") 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. "ExcludeDomains") 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 GoogleCloudAiplatformV1beta1EnterpriseWebSearch) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudAiplatformV1beta1EnterpriseWebSearch + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } // GoogleCloudAiplatformV1beta1ExecutableCode: Code generated by the model that @@ -2941,6 +2960,26 @@ func (s GoogleCloudAiplatformV1beta1ToolConfig) MarshalJSON() ([]byte, error) { // GoogleCloudAiplatformV1beta1ToolGoogleSearch: GoogleSearch tool type. Tool // to support Google Search in Model. Powered by Google. type GoogleCloudAiplatformV1beta1ToolGoogleSearch struct { + // ExcludeDomains: Optional. List of domains to be excluded from the search + // results. The default limit is 2000 domains. Example: ["amazon.com", + // "facebook.com"]. + ExcludeDomains []string `json:"excludeDomains,omitempty"` + // ForceSendFields is a list of field names (e.g. "ExcludeDomains") 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. "ExcludeDomains") 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 GoogleCloudAiplatformV1beta1ToolGoogleSearch) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudAiplatformV1beta1ToolGoogleSearch + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } // GoogleCloudAiplatformV1beta1UrlContext: Tool to support URL context. diff --git a/kmsinventory/v1/kmsinventory-api.json b/kmsinventory/v1/kmsinventory-api.json index da6d7b5209c..f083c6c6b15 100644 --- a/kmsinventory/v1/kmsinventory-api.json +++ b/kmsinventory/v1/kmsinventory-api.json @@ -242,7 +242,7 @@ } } }, - "revision": "20250525", + "revision": "20250727", "rootUrl": "https://kmsinventory.googleapis.com/", "schemas": { "GoogleCloudKmsInventoryV1ListCryptoKeysResponse": { @@ -438,7 +438,8 @@ "ASYMMETRIC_SIGN", "ASYMMETRIC_DECRYPT", "RAW_ENCRYPT_DECRYPT", - "MAC" + "MAC", + "KEY_ENCAPSULATION" ], "enumDescriptions": [ "Not specified.", @@ -446,7 +447,8 @@ "CryptoKeys with this purpose may be used with AsymmetricSign and GetPublicKey.", "CryptoKeys with this purpose may be used with AsymmetricDecrypt and GetPublicKey.", "CryptoKeys with this purpose may be used with RawEncrypt and RawDecrypt. This purpose is meant to be used for interoperable symmetric encryption and does not support automatic CryptoKey rotation.", - "CryptoKeys with this purpose may be used with MacSign." + "CryptoKeys with this purpose may be used with MacSign.", + "CryptoKeys with this purpose may be used with GetPublicKey and Decapsulate." ], "type": "string" }, @@ -505,6 +507,9 @@ "HMAC_SHA512", "HMAC_SHA224", "EXTERNAL_SYMMETRIC_ENCRYPTION", + "ML_KEM_768", + "ML_KEM_1024", + "KEM_XWING", "PQ_SIGN_ML_DSA_65", "PQ_SIGN_SLH_DSA_SHA2_128S", "PQ_SIGN_HASH_SLH_DSA_SHA2_128S_SHA256" @@ -546,6 +551,9 @@ "HMAC-SHA512 signing with a 512 bit key.", "HMAC-SHA224 signing with a 224 bit key.", "Algorithm representing symmetric encryption by an external key manager.", + "ML-KEM-768 (FIPS 203)", + "ML-KEM-1024 (FIPS 203)", + "X-Wing hybrid KEM combining ML-KEM-768 with X25519 following datatracker.ietf.org/doc/draft-connolly-cfrg-xwing-kem/.", "The post-quantum Module-Lattice-Based Digital Signature Algorithm, at security level 3. Randomized version.", "The post-quantum stateless hash-based digital signature algorithm, at security level 1. Randomized version.", "The post-quantum stateless hash-based digital signature algorithm, at security level 1. Randomized pre-hash version supporting SHA256 digests." @@ -717,6 +725,9 @@ "HMAC_SHA512", "HMAC_SHA224", "EXTERNAL_SYMMETRIC_ENCRYPTION", + "ML_KEM_768", + "ML_KEM_1024", + "KEM_XWING", "PQ_SIGN_ML_DSA_65", "PQ_SIGN_SLH_DSA_SHA2_128S", "PQ_SIGN_HASH_SLH_DSA_SHA2_128S_SHA256" @@ -758,6 +769,9 @@ "HMAC-SHA512 signing with a 512 bit key.", "HMAC-SHA224 signing with a 224 bit key.", "Algorithm representing symmetric encryption by an external key manager.", + "ML-KEM-768 (FIPS 203)", + "ML-KEM-1024 (FIPS 203)", + "X-Wing hybrid KEM combining ML-KEM-768 with X25519 following datatracker.ietf.org/doc/draft-connolly-cfrg-xwing-kem/.", "The post-quantum Module-Lattice-Based Digital Signature Algorithm, at security level 3. Randomized version.", "The post-quantum stateless hash-based digital signature algorithm, at security level 1. Randomized version.", "The post-quantum stateless hash-based digital signature algorithm, at security level 1. Randomized pre-hash version supporting SHA256 digests." diff --git a/kmsinventory/v1/kmsinventory-gen.go b/kmsinventory/v1/kmsinventory-gen.go index df50d995a64..d8a745d266f 100644 --- a/kmsinventory/v1/kmsinventory-gen.go +++ b/kmsinventory/v1/kmsinventory-gen.go @@ -456,6 +456,8 @@ type GoogleCloudKmsV1CryptoKey struct { // interoperable symmetric encryption and does not support automatic CryptoKey // rotation. // "MAC" - CryptoKeys with this purpose may be used with MacSign. + // "KEY_ENCAPSULATION" - CryptoKeys with this purpose may be used with + // GetPublicKey and Decapsulate. Purpose string `json:"purpose,omitempty"` // RotationPeriod: next_rotation_time will be advanced by this period when the // service automatically rotates a key. Must be at least 24 hours and at most @@ -553,6 +555,10 @@ type GoogleCloudKmsV1CryptoKeyVersion struct { // "HMAC_SHA224" - HMAC-SHA224 signing with a 224 bit key. // "EXTERNAL_SYMMETRIC_ENCRYPTION" - Algorithm representing symmetric // encryption by an external key manager. + // "ML_KEM_768" - ML-KEM-768 (FIPS 203) + // "ML_KEM_1024" - ML-KEM-1024 (FIPS 203) + // "KEM_XWING" - X-Wing hybrid KEM combining ML-KEM-768 with X25519 following + // datatracker.ietf.org/doc/draft-connolly-cfrg-xwing-kem/. // "PQ_SIGN_ML_DSA_65" - The post-quantum Module-Lattice-Based Digital // Signature Algorithm, at security level 3. Randomized version. // "PQ_SIGN_SLH_DSA_SHA2_128S" - The post-quantum stateless hash-based @@ -739,6 +745,10 @@ type GoogleCloudKmsV1CryptoKeyVersionTemplate struct { // "HMAC_SHA224" - HMAC-SHA224 signing with a 224 bit key. // "EXTERNAL_SYMMETRIC_ENCRYPTION" - Algorithm representing symmetric // encryption by an external key manager. + // "ML_KEM_768" - ML-KEM-768 (FIPS 203) + // "ML_KEM_1024" - ML-KEM-1024 (FIPS 203) + // "KEM_XWING" - X-Wing hybrid KEM combining ML-KEM-768 with X25519 following + // datatracker.ietf.org/doc/draft-connolly-cfrg-xwing-kem/. // "PQ_SIGN_ML_DSA_65" - The post-quantum Module-Lattice-Based Digital // Signature Algorithm, at security level 3. Randomized version. // "PQ_SIGN_SLH_DSA_SHA2_128S" - The post-quantum stateless hash-based diff --git a/merchantapi/accounts_v1beta/merchantapi-api.json b/merchantapi/accounts_v1beta/merchantapi-api.json index afe957eb852..9afc4d14a31 100644 --- a/merchantapi/accounts_v1beta/merchantapi-api.json +++ b/merchantapi/accounts_v1beta/merchantapi-api.json @@ -2311,7 +2311,7 @@ } } }, - "revision": "20250721", + "revision": "20250727", "rootUrl": "https://merchantapi.googleapis.com/", "schemas": { "About": { @@ -2926,7 +2926,7 @@ "readOnly": true }, "eligibleDestinations": { - "description": "Optional. The destinations to which the checkout program applies, valid destination values are `SHOPPING_ADS`, `FREE_LISTINGS`", + "description": "Optional. The destinations (also known as [Marketing methods](https://support.google.com/merchants/answer/15130232)) to which the checkout program applies, valid destination values are `SHOPPING_ADS`, `FREE_LISTINGS`", "items": { "enum": [ "DESTINATION_ENUM_UNSPECIFIED", diff --git a/merchantapi/accounts_v1beta/merchantapi-gen.go b/merchantapi/accounts_v1beta/merchantapi-gen.go index 5673ada4d29..83767492e08 100644 --- a/merchantapi/accounts_v1beta/merchantapi-gen.go +++ b/merchantapi/accounts_v1beta/merchantapi-gen.go @@ -1299,8 +1299,9 @@ type CheckoutSettings struct { // be a copy of url settings. Otherwise, it will have the value of the parent // account (for only marketplace sellers). EffectiveUriSettings *UriSettings `json:"effectiveUriSettings,omitempty"` - // EligibleDestinations: Optional. The destinations to which the checkout - // program applies, valid destination values are `SHOPPING_ADS`, + // EligibleDestinations: Optional. The destinations (also known as Marketing + // methods (https://support.google.com/merchants/answer/15130232)) to which the + // checkout program applies, valid destination values are `SHOPPING_ADS`, // `FREE_LISTINGS` // // Possible values: diff --git a/merchantapi/inventories_v1beta/merchantapi-api.json b/merchantapi/inventories_v1beta/merchantapi-api.json index fcbcc8774f2..bc069fd4eaa 100644 --- a/merchantapi/inventories_v1beta/merchantapi-api.json +++ b/merchantapi/inventories_v1beta/merchantapi-api.json @@ -300,7 +300,7 @@ } } }, - "revision": "20250721", + "revision": "20250727", "rootUrl": "https://merchantapi.googleapis.com/", "schemas": { "CustomAttribute": { @@ -425,7 +425,7 @@ }, "price": { "$ref": "Price", - "description": "Price of the product at this store." + "description": "Optional. Price of the product at this store." }, "quantity": { "description": "Quantity of the product available at this store. Must be greater than or equal to zero.", @@ -434,11 +434,11 @@ }, "salePrice": { "$ref": "Price", - "description": "Sale price of the product at this store. Mandatory if `salePriceEffectiveDate` is defined." + "description": "Optional. Sale price of the product at this store. Mandatory if `salePriceEffectiveDate` is defined." }, "salePriceEffectiveDate": { "$ref": "Interval", - "description": "The `TimePeriod` of the sale at this store." + "description": "Optional. The `TimePeriod` of the sale at this store." }, "storeCode": { "description": "Required. Immutable. Store code (the store ID from your Business Profile) of the physical store the product is sold in. See the [Local product inventory data specification](https://support.google.com/merchants/answer/3061342) for more information.", @@ -642,7 +642,7 @@ }, "price": { "$ref": "Price", - "description": "Price of the product in this region." + "description": "Optional. Price of the product in this region." }, "region": { "description": "Required. Immutable. ID of the region for this `RegionalInventory` resource. See the [Regional availability and pricing](https://support.google.com/merchants/answer/9698880) for more details.", @@ -650,11 +650,11 @@ }, "salePrice": { "$ref": "Price", - "description": "Sale price of the product in this region. Mandatory if `salePriceEffectiveDate` is defined." + "description": "Optional. Sale price of the product in this region. Mandatory if `salePriceEffectiveDate` is defined." }, "salePriceEffectiveDate": { "$ref": "Interval", - "description": "The `TimePeriod` of the sale price in this region." + "description": "Optional. The `TimePeriod` of the sale price in this region." } }, "type": "object" diff --git a/merchantapi/inventories_v1beta/merchantapi-gen.go b/merchantapi/inventories_v1beta/merchantapi-gen.go index 2f5c7f10418..db9dc7e00e3 100644 --- a/merchantapi/inventories_v1beta/merchantapi-gen.go +++ b/merchantapi/inventories_v1beta/merchantapi-gen.go @@ -361,15 +361,16 @@ type LocalInventory struct { // inventory data specification // (https://support.google.com/merchants/answer/3061342) PickupSla string `json:"pickupSla,omitempty"` - // Price: Price of the product at this store. + // Price: Optional. Price of the product at this store. Price *Price `json:"price,omitempty"` // Quantity: Quantity of the product available at this store. Must be greater // than or equal to zero. Quantity int64 `json:"quantity,omitempty,string"` - // SalePrice: Sale price of the product at this store. Mandatory if + // SalePrice: Optional. Sale price of the product at this store. Mandatory if // `salePriceEffectiveDate` is defined. SalePrice *Price `json:"salePrice,omitempty"` - // SalePriceEffectiveDate: The `TimePeriod` of the sale at this store. + // SalePriceEffectiveDate: Optional. The `TimePeriod` of the sale at this + // store. SalePriceEffectiveDate *Interval `json:"salePriceEffectiveDate,omitempty"` // StoreCode: Required. Immutable. Store code (the store ID from your Business // Profile) of the physical store the product is sold in. See the Local product @@ -576,16 +577,17 @@ type RegionalInventory struct { // `{regional_inventory.name=accounts/{account}/products/{product}/regionalInven // tories/{region}` Name string `json:"name,omitempty"` - // Price: Price of the product in this region. + // Price: Optional. Price of the product in this region. Price *Price `json:"price,omitempty"` // Region: Required. Immutable. ID of the region for this `RegionalInventory` // resource. See the Regional availability and pricing // (https://support.google.com/merchants/answer/9698880) for more details. Region string `json:"region,omitempty"` - // SalePrice: Sale price of the product in this region. Mandatory if + // SalePrice: Optional. Sale price of the product in this region. Mandatory if // `salePriceEffectiveDate` is defined. SalePrice *Price `json:"salePrice,omitempty"` - // SalePriceEffectiveDate: The `TimePeriod` of the sale price in this region. + // SalePriceEffectiveDate: Optional. The `TimePeriod` of the sale price in this + // region. SalePriceEffectiveDate *Interval `json:"salePriceEffectiveDate,omitempty"` // ServerResponse contains the HTTP response code and headers from the server. diff --git a/merchantapi/ordertracking_v1beta/merchantapi-api.json b/merchantapi/ordertracking_v1beta/merchantapi-api.json index 6ba6582d80f..6e4cdacd8a5 100644 --- a/merchantapi/ordertracking_v1beta/merchantapi-api.json +++ b/merchantapi/ordertracking_v1beta/merchantapi-api.json @@ -107,13 +107,13 @@ "resources": { "accounts": { "resources": { - "ordertrackingsignals": { + "orderTrackingSignals": { "methods": { "create": { "description": "Creates new order tracking signal.", - "flatPath": "ordertracking/v1beta/accounts/{accountsId}/ordertrackingsignals", + "flatPath": "ordertracking/v1beta/accounts/{accountsId}/orderTrackingSignals", "httpMethod": "POST", - "id": "merchantapi.accounts.ordertrackingsignals.create", + "id": "merchantapi.accounts.orderTrackingSignals.create", "parameterOrder": [ "parent" ], @@ -131,7 +131,7 @@ "type": "string" } }, - "path": "ordertracking/v1beta/{+parent}/ordertrackingsignals", + "path": "ordertracking/v1beta/{+parent}/orderTrackingSignals", "request": { "$ref": "OrderTrackingSignal" }, @@ -147,7 +147,7 @@ } } }, - "revision": "20250621", + "revision": "20250727", "rootUrl": "https://merchantapi.googleapis.com/", "schemas": { "DateTime": { diff --git a/merchantapi/ordertracking_v1beta/merchantapi-gen.go b/merchantapi/ordertracking_v1beta/merchantapi-gen.go index bead3083993..18d850b369f 100644 --- a/merchantapi/ordertracking_v1beta/merchantapi-gen.go +++ b/merchantapi/ordertracking_v1beta/merchantapi-gen.go @@ -155,22 +155,22 @@ func (s *Service) userAgent() string { func NewAccountsService(s *Service) *AccountsService { rs := &AccountsService{s: s} - rs.Ordertrackingsignals = NewAccountsOrdertrackingsignalsService(s) + rs.OrderTrackingSignals = NewAccountsOrderTrackingSignalsService(s) return rs } type AccountsService struct { s *Service - Ordertrackingsignals *AccountsOrdertrackingsignalsService + OrderTrackingSignals *AccountsOrderTrackingSignalsService } -func NewAccountsOrdertrackingsignalsService(s *Service) *AccountsOrdertrackingsignalsService { - rs := &AccountsOrdertrackingsignalsService{s: s} +func NewAccountsOrderTrackingSignalsService(s *Service) *AccountsOrderTrackingSignalsService { + rs := &AccountsOrderTrackingSignalsService{s: s} return rs } -type AccountsOrdertrackingsignalsService struct { +type AccountsOrderTrackingSignalsService struct { s *Service } @@ -609,7 +609,7 @@ func (s TimeZone) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -type AccountsOrdertrackingsignalsCreateCall struct { +type AccountsOrderTrackingSignalsCreateCall struct { s *Service parent string ordertrackingsignal *OrderTrackingSignal @@ -622,8 +622,8 @@ type AccountsOrdertrackingsignalsCreateCall struct { // // - parent: The account of the business for which the order signal is created. // Format: accounts/{account}. -func (r *AccountsOrdertrackingsignalsService) Create(parent string, ordertrackingsignal *OrderTrackingSignal) *AccountsOrdertrackingsignalsCreateCall { - c := &AccountsOrdertrackingsignalsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)} +func (r *AccountsOrderTrackingSignalsService) Create(parent string, ordertrackingsignal *OrderTrackingSignal) *AccountsOrderTrackingSignalsCreateCall { + c := &AccountsOrderTrackingSignalsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.parent = parent c.ordertrackingsignal = ordertrackingsignal return c @@ -631,7 +631,7 @@ func (r *AccountsOrdertrackingsignalsService) Create(parent string, ordertrackin // OrderTrackingSignalId sets the optional parameter "orderTrackingSignalId": // Output only. The ID that uniquely identifies this order tracking signal. -func (c *AccountsOrdertrackingsignalsCreateCall) OrderTrackingSignalId(orderTrackingSignalId string) *AccountsOrdertrackingsignalsCreateCall { +func (c *AccountsOrderTrackingSignalsCreateCall) OrderTrackingSignalId(orderTrackingSignalId string) *AccountsOrderTrackingSignalsCreateCall { c.urlParams_.Set("orderTrackingSignalId", orderTrackingSignalId) return c } @@ -639,27 +639,27 @@ func (c *AccountsOrdertrackingsignalsCreateCall) OrderTrackingSignalId(orderTrac // Fields allows partial responses to be retrieved. See // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more // details. -func (c *AccountsOrdertrackingsignalsCreateCall) Fields(s ...googleapi.Field) *AccountsOrdertrackingsignalsCreateCall { +func (c *AccountsOrderTrackingSignalsCreateCall) Fields(s ...googleapi.Field) *AccountsOrderTrackingSignalsCreateCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } // Context sets the context to be used in this call's Do method. -func (c *AccountsOrdertrackingsignalsCreateCall) Context(ctx context.Context) *AccountsOrdertrackingsignalsCreateCall { +func (c *AccountsOrderTrackingSignalsCreateCall) Context(ctx context.Context) *AccountsOrderTrackingSignalsCreateCall { 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 *AccountsOrdertrackingsignalsCreateCall) Header() http.Header { +func (c *AccountsOrderTrackingSignalsCreateCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *AccountsOrdertrackingsignalsCreateCall) doRequest(alt string) (*http.Response, error) { +func (c *AccountsOrderTrackingSignalsCreateCall) doRequest(alt string) (*http.Response, error) { reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.ordertrackingsignal) if err != nil { @@ -667,7 +667,7 @@ func (c *AccountsOrdertrackingsignalsCreateCall) doRequest(alt string) (*http.Re } c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "ordertracking/v1beta/{+parent}/ordertrackingsignals") + urls := googleapi.ResolveRelative(c.s.BasePath, "ordertracking/v1beta/{+parent}/orderTrackingSignals") urls += "?" + c.urlParams_.Encode() req, err := http.NewRequest("POST", urls, body) if err != nil { @@ -677,17 +677,17 @@ func (c *AccountsOrdertrackingsignalsCreateCall) doRequest(alt string) (*http.Re googleapi.Expand(req.URL, map[string]string{ "parent": c.parent, }) - c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "merchantapi.accounts.ordertrackingsignals.create", "request", internallog.HTTPRequest(req, body.Bytes())) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "merchantapi.accounts.orderTrackingSignals.create", "request", internallog.HTTPRequest(req, body.Bytes())) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "merchantapi.accounts.ordertrackingsignals.create" call. +// Do executes the "merchantapi.accounts.orderTrackingSignals.create" call. // Any non-2xx status code is an error. Response headers are in either // *OrderTrackingSignal.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 *AccountsOrdertrackingsignalsCreateCall) Do(opts ...googleapi.CallOption) (*OrderTrackingSignal, error) { +func (c *AccountsOrderTrackingSignalsCreateCall) Do(opts ...googleapi.CallOption) (*OrderTrackingSignal, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -717,6 +717,6 @@ func (c *AccountsOrdertrackingsignalsCreateCall) Do(opts ...googleapi.CallOption if err != nil { return nil, err } - c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "merchantapi.accounts.ordertrackingsignals.create", "response", internallog.HTTPResponse(res, b)) + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "merchantapi.accounts.orderTrackingSignals.create", "response", internallog.HTTPResponse(res, b)) return ret, nil } diff --git a/merchantapi/products_v1beta/merchantapi-api.json b/merchantapi/products_v1beta/merchantapi-api.json index f274789c9a2..f8f3a9be417 100644 --- a/merchantapi/products_v1beta/merchantapi-api.json +++ b/merchantapi/products_v1beta/merchantapi-api.json @@ -124,7 +124,7 @@ "type": "string" }, "name": { - "description": "Required. The name of the product input resource to delete. Format: `accounts/{account}/productInputs/{product}` where the last section `product` consists of 4 parts: `channel~content_language~feed_label~offer_id` example for product name is `accounts/123/productInputs/online~en~US~sku123`.", + "description": "Required. The name of the product input resource to delete. Format: `accounts/{account}/productInputs/{product}` where the last section `product` consists of: `content_language~feed_label~offer_id` example for product name is `accounts/123/productInputs/en~US~sku123`.", "location": "path", "pattern": "^accounts/[^/]+/productInputs/[^/]+$", "required": true, @@ -187,7 +187,7 @@ "type": "string" }, "name": { - "description": "Identifier. The name of the product input. Format: `accounts/{account}/productInputs/{productinput}` where the last section `productinput` consists of 4 parts: `channel~content_language~feed_label~offer_id` example for product input name is `accounts/123/productInputs/online~en~US~sku123`", + "description": "Identifier. The name of the product input. Format: `accounts/{account}/productInputs/{productinput}` where the last section `productinput` consists of: `content_language~feed_label~offer_id` example for product input name is `accounts/123/productInputs/en~US~sku123`. A legacy local product input name would be `accounts/123/productInputs/local~en~US~sku123`. Note: For calls to the v1beta version, the `productInput` section consists of: `channel~content_language~feed_label~offer_id`, for example: `accounts/123/productInputs/online~en~US~sku123`.", "location": "path", "pattern": "^accounts/[^/]+/productInputs/[^/]+$", "required": true, @@ -225,7 +225,7 @@ ], "parameters": { "name": { - "description": "Required. The name of the product to retrieve. Format: `accounts/{account}/products/{product}` where the last section `product` consists of 4 parts: `channel~content_language~feed_label~offer_id` example for product name is `accounts/123/products/online~en~US~sku123`", + "description": "Required. The name of the product to retrieve. Format: `accounts/{account}/products/{product}` where the last section `product` consists of: `content_language~feed_label~offer_id` example for product name is `accounts/123/products/en~US~sku123`. A legacy local product name would be `accounts/123/products/local~en~US~sku123`. Note: For calls to the v1beta version, the `product` section consists of: `channel~content_language~feed_label~offer_id`, for example: `accounts/123/products/online~en~US~sku123`.", "location": "path", "pattern": "^accounts/[^/]+/products/[^/]+$", "required": true, @@ -281,7 +281,7 @@ } } }, - "revision": "20250724", + "revision": "20250727", "rootUrl": "https://merchantapi.googleapis.com/", "schemas": { "Attributes": { @@ -1283,7 +1283,7 @@ "type": "string" }, "name": { - "description": "The name of the product. Format: `accounts/{account}/products/{product}` where the last section `product` consists of 4 parts: `channel~content_language~feed_label~offer_id` example for product name is `accounts/123/products/online~en~US~sku123`", + "description": "The name of the product. Format: `accounts/{account}/products/{product}` where the last section `product` consists of: `content_language~feed_label~offer_id` example for product name is `accounts/123/products/en~US~sku123`. A legacy local product name would be `accounts/123/products/local~en~US~sku123`. Note: For calls to the v1beta version, the `product` section consists of: `channel~content_language~feed_label~offer_id`, for example: `accounts/123/products/online~en~US~sku123`.", "type": "string" }, "offerId": { @@ -1464,7 +1464,7 @@ "type": "string" }, "name": { - "description": "Identifier. The name of the product input. Format: `accounts/{account}/productInputs/{productinput}` where the last section `productinput` consists of 4 parts: `channel~content_language~feed_label~offer_id` example for product input name is `accounts/123/productInputs/online~en~US~sku123`", + "description": "Identifier. The name of the product input. Format: `accounts/{account}/productInputs/{productinput}` where the last section `productinput` consists of: `content_language~feed_label~offer_id` example for product input name is `accounts/123/productInputs/en~US~sku123`. A legacy local product input name would be `accounts/123/productInputs/local~en~US~sku123`. Note: For calls to the v1beta version, the `productInput` section consists of: `channel~content_language~feed_label~offer_id`, for example: `accounts/123/productInputs/online~en~US~sku123`.", "type": "string" }, "offerId": { diff --git a/merchantapi/products_v1beta/merchantapi-gen.go b/merchantapi/products_v1beta/merchantapi-gen.go index a12655f2a25..bd17019a5cd 100644 --- a/merchantapi/products_v1beta/merchantapi-gen.go +++ b/merchantapi/products_v1beta/merchantapi-gen.go @@ -1136,8 +1136,12 @@ type Product struct { FeedLabel string `json:"feedLabel,omitempty"` // Name: The name of the product. Format: // `accounts/{account}/products/{product}` where the last section `product` - // consists of 4 parts: `channel~content_language~feed_label~offer_id` example - // for product name is `accounts/123/products/online~en~US~sku123` + // consists of: `content_language~feed_label~offer_id` example for product name + // is `accounts/123/products/en~US~sku123`. A legacy local product name would + // be `accounts/123/products/local~en~US~sku123`. Note: For calls to the v1beta + // version, the `product` section consists of: + // `channel~content_language~feed_label~offer_id`, for example: + // `accounts/123/products/online~en~US~sku123`. Name string `json:"name,omitempty"` // OfferId: Output only. Your unique identifier for the product. This is the // same for the product input and processed product. Leading and trailing @@ -1369,9 +1373,13 @@ type ProductInput struct { FeedLabel string `json:"feedLabel,omitempty"` // Name: Identifier. The name of the product input. Format: // `accounts/{account}/productInputs/{productinput}` where the last section - // `productinput` consists of 4 parts: - // `channel~content_language~feed_label~offer_id` example for product input - // name is `accounts/123/productInputs/online~en~US~sku123` + // `productinput` consists of: `content_language~feed_label~offer_id` example + // for product input name is `accounts/123/productInputs/en~US~sku123`. A + // legacy local product input name would be + // `accounts/123/productInputs/local~en~US~sku123`. Note: For calls to the + // v1beta version, the `productInput` section consists of: + // `channel~content_language~feed_label~offer_id`, for example: + // `accounts/123/productInputs/online~en~US~sku123`. Name string `json:"name,omitempty"` // OfferId: Required. Immutable. Your unique identifier for the product. This // is the same for the product input and processed product. Leading and @@ -1957,9 +1965,8 @@ type AccountsProductInputsDeleteCall struct { // // - name: The name of the product input resource to delete. Format: // `accounts/{account}/productInputs/{product}` where the last section -// `product` consists of 4 parts: -// `channel~content_language~feed_label~offer_id` example for product name is -// `accounts/123/productInputs/online~en~US~sku123`. +// `product` consists of: `content_language~feed_label~offer_id` example for +// product name is `accounts/123/productInputs/en~US~sku123`. func (r *AccountsProductInputsService) Delete(name string) *AccountsProductInputsDeleteCall { c := &AccountsProductInputsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.name = name @@ -2194,9 +2201,13 @@ type AccountsProductInputsPatchCall struct { // // - name: Identifier. The name of the product input. Format: // `accounts/{account}/productInputs/{productinput}` where the last section -// `productinput` consists of 4 parts: -// `channel~content_language~feed_label~offer_id` example for product input -// name is `accounts/123/productInputs/online~en~US~sku123`. +// `productinput` consists of: `content_language~feed_label~offer_id` example +// for product input name is `accounts/123/productInputs/en~US~sku123`. A +// legacy local product input name would be +// `accounts/123/productInputs/local~en~US~sku123`. Note: For calls to the +// v1beta version, the `productInput` section consists of: +// `channel~content_language~feed_label~offer_id`, for example: +// `accounts/123/productInputs/online~en~US~sku123`. func (r *AccountsProductInputsService) Patch(name string, productinput *ProductInput) *AccountsProductInputsPatchCall { c := &AccountsProductInputsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.name = name @@ -2327,8 +2338,12 @@ type AccountsProductsGetCall struct { // // - name: The name of the product to retrieve. Format: // `accounts/{account}/products/{product}` where the last section `product` -// consists of 4 parts: `channel~content_language~feed_label~offer_id` -// example for product name is `accounts/123/products/online~en~US~sku123`. +// consists of: `content_language~feed_label~offer_id` example for product +// name is `accounts/123/products/en~US~sku123`. A legacy local product name +// would be `accounts/123/products/local~en~US~sku123`. Note: For calls to +// the v1beta version, the `product` section consists of: +// `channel~content_language~feed_label~offer_id`, for example: +// `accounts/123/products/online~en~US~sku123`. func (r *AccountsProductsService) Get(name string) *AccountsProductsGetCall { c := &AccountsProductsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.name = name diff --git a/merchantapi/promotions_v1beta/merchantapi-api.json b/merchantapi/promotions_v1beta/merchantapi-api.json index d3547da7e85..ab07df6c5c5 100644 --- a/merchantapi/promotions_v1beta/merchantapi-api.json +++ b/merchantapi/promotions_v1beta/merchantapi-api.json @@ -203,7 +203,7 @@ } } }, - "revision": "20250628", + "revision": "20250727", "rootUrl": "https://merchantapi.googleapis.com/", "schemas": { "Attributes": { @@ -380,7 +380,7 @@ "type": "array" }, "promotionDestinations": { - "description": "Required. The list of destinations where the promotion applies to. If you don't specify a destination by including a supported value in your data source, your promotion will display in Shopping ads and free listings by default. You may have previously submitted the following values as destinations for your products: Shopping Actions, Surfaces across Google, Local surfaces across Google. To represent these values use `FREE_LISTINGS`, `FREE_LOCAL_LISTINGS`, `LOCAL_INVENTORY_ADS`. For more details see [Promotion destination](https://support.google.com/merchants/answer/13837465?sjid=5155774230887277618-NC)", + "description": "Required. The list of destinations (also known as [Marketing methods](https://support.google.com/merchants/answer/15130232)) where the promotion applies to. If you don't specify a destination by including a supported value in your data source, your promotion will display in Shopping ads and free listings by default. You may have previously submitted the following values as destinations for your products: Shopping Actions, Surfaces across Google, Local surfaces across Google. To represent these values use `FREE_LISTINGS`, `FREE_LOCAL_LISTINGS`, `LOCAL_INVENTORY_ADS`. For more details see [Promotion destination](https://support.google.com/merchants/answer/13837465?sjid=5155774230887277618-NC)", "items": { "enum": [ "DESTINATION_ENUM_UNSPECIFIED", diff --git a/merchantapi/promotions_v1beta/merchantapi-gen.go b/merchantapi/promotions_v1beta/merchantapi-gen.go index cffe10bcfef..43eae23e180 100644 --- a/merchantapi/promotions_v1beta/merchantapi-gen.go +++ b/merchantapi/promotions_v1beta/merchantapi-gen.go @@ -327,14 +327,15 @@ type Attributes struct { // attribute is set to specific_products // (https://support.google.com/merchants/answer/13837299?ref_topic=13773355&sjid=17642868584668136159-NC). ProductTypeInclusion []string `json:"productTypeInclusion,omitempty"` - // PromotionDestinations: Required. The list of destinations where the - // promotion applies to. If you don't specify a destination by including a - // supported value in your data source, your promotion will display in Shopping - // ads and free listings by default. You may have previously submitted the - // following values as destinations for your products: Shopping Actions, - // Surfaces across Google, Local surfaces across Google. To represent these - // values use `FREE_LISTINGS`, `FREE_LOCAL_LISTINGS`, `LOCAL_INVENTORY_ADS`. - // For more details see Promotion destination + // PromotionDestinations: Required. The list of destinations (also known as + // Marketing methods (https://support.google.com/merchants/answer/15130232)) + // where the promotion applies to. If you don't specify a destination by + // including a supported value in your data source, your promotion will display + // in Shopping ads and free listings by default. You may have previously + // submitted the following values as destinations for your products: Shopping + // Actions, Surfaces across Google, Local surfaces across Google. To represent + // these values use `FREE_LISTINGS`, `FREE_LOCAL_LISTINGS`, + // `LOCAL_INVENTORY_ADS`. For more details see Promotion destination // (https://support.google.com/merchants/answer/13837465?sjid=5155774230887277618-NC) // // Possible values: diff --git a/retail/v2alpha/retail-api.json b/retail/v2alpha/retail-api.json index a1f943a70d5..3ef2b828a35 100644 --- a/retail/v2alpha/retail-api.json +++ b/retail/v2alpha/retail-api.json @@ -2859,7 +2859,7 @@ } } }, - "revision": "20250717", + "revision": "20250724", "rootUrl": "https://retail.googleapis.com/", "schemas": { "GoogleApiHttpBody": { @@ -4699,10 +4699,14 @@ "description": "Optional. Mode to control Conversational Filtering. Defaults to Mode.DISABLED if it's unset.", "enum": [ "MODE_UNSPECIFIED", + "DISABLED", + "ENABLED", "CONVERSATIONAL_FILTER_ONLY" ], "enumDescriptions": [ "Default value.", + "Disable Conversational Filtering.", + "Enabled Conversational Filtering with default Conversational Search.", "Enabled Conversational Filtering without default Conversational Search." ], "type": "string" @@ -4780,12 +4784,42 @@ "$ref": "GoogleCloudRetailV2alphaConversationalSearchResponseConversationalFilteringResult", "description": "This field specifies all related information that is needed on client side for UI rendering of conversational filtering search." }, + "conversationalTextResponse": { + "description": "The conversational answer-based text response generated by the Server.", + "type": "string" + }, + "followupQuestion": { + "$ref": "GoogleCloudRetailV2alphaConversationalSearchResponseFollowupQuestion", + "description": "The conversational followup question generated for Intent refinement." + }, "refinedSearch": { "description": "The proposed refined search queries. They can be used to fetch the relevant search results. When using CONVERSATIONAL_FILTER_ONLY mode, the refined_query from search response will be populated here.", "items": { "$ref": "GoogleCloudRetailV2alphaConversationalSearchResponseRefinedSearch" }, "type": "array" + }, + "state": { + "description": "Output only. The state of the response generation.", + "enum": [ + "STATE_UNSPECIFIED", + "STREAMING", + "SUCCEEDED" + ], + "enumDescriptions": [ + "Unknown.", + "Response generation is being streamed.", + "Response generation has succeeded." + ], + "readOnly": true, + "type": "string" + }, + "userQueryTypes": { + "description": "The types Retail classifies the search query as. Supported values are: - \"ADVERSARIAL\" - \"CHITCHAT\" - \"JAILBREAK\" - \"ORDER_SUPPORT\" - \"SIMPLE_PRODUCT_SEARCH\" - \"INTENT_REFINEMENT\" - \"PRODUCT_DETAILS\" - \"PRODUCT_COMPARISON\" - \"DEALS_AND_COUPONS\" - \"STORE_RELEVANT\" - \"BLOCKLISTED\" - \"BEST_PRODUCT\" - \"RETAIL_SUPPORT\" - \"DISABLED\" clang-format off clang-format on", + "items": { + "type": "string" + }, + "type": "array" } }, "type": "object" diff --git a/retail/v2alpha/retail-gen.go b/retail/v2alpha/retail-gen.go index 0b48e1c5888..336280e7424 100644 --- a/retail/v2alpha/retail-gen.go +++ b/retail/v2alpha/retail-gen.go @@ -3080,6 +3080,9 @@ type GoogleCloudRetailV2alphaConversationalSearchRequestConversationalFilteringS // // Possible values: // "MODE_UNSPECIFIED" - Default value. + // "DISABLED" - Disable Conversational Filtering. + // "ENABLED" - Enabled Conversational Filtering with default Conversational + // Search. // "CONVERSATIONAL_FILTER_ONLY" - Enabled Conversational Filtering without // default Conversational Search. ConversationalFilteringMode string `json:"conversationalFilteringMode,omitempty"` @@ -3209,10 +3212,30 @@ type GoogleCloudRetailV2alphaConversationalSearchResponse struct { // that is needed on client side for UI rendering of conversational filtering // search. ConversationalFilteringResult *GoogleCloudRetailV2alphaConversationalSearchResponseConversationalFilteringResult `json:"conversationalFilteringResult,omitempty"` + // ConversationalTextResponse: The conversational answer-based text response + // generated by the Server. + ConversationalTextResponse string `json:"conversationalTextResponse,omitempty"` + // FollowupQuestion: The conversational followup question generated for Intent + // refinement. + FollowupQuestion *GoogleCloudRetailV2alphaConversationalSearchResponseFollowupQuestion `json:"followupQuestion,omitempty"` // RefinedSearch: The proposed refined search queries. They can be used to // fetch the relevant search results. When using CONVERSATIONAL_FILTER_ONLY // mode, the refined_query from search response will be populated here. RefinedSearch []*GoogleCloudRetailV2alphaConversationalSearchResponseRefinedSearch `json:"refinedSearch,omitempty"` + // State: Output only. The state of the response generation. + // + // Possible values: + // "STATE_UNSPECIFIED" - Unknown. + // "STREAMING" - Response generation is being streamed. + // "SUCCEEDED" - Response generation has succeeded. + State string `json:"state,omitempty"` + // UserQueryTypes: The types Retail classifies the search query as. Supported + // values are: - "ADVERSARIAL" - "CHITCHAT" - "JAILBREAK" - "ORDER_SUPPORT" - + // "SIMPLE_PRODUCT_SEARCH" - "INTENT_REFINEMENT" - "PRODUCT_DETAILS" - + // "PRODUCT_COMPARISON" - "DEALS_AND_COUPONS" - "STORE_RELEVANT" - + // "BLOCKLISTED" - "BEST_PRODUCT" - "RETAIL_SUPPORT" - "DISABLED" clang-format + // off clang-format on + UserQueryTypes []string `json:"userQueryTypes,omitempty"` // ServerResponse contains the HTTP response code and headers from the server. googleapi.ServerResponse `json:"-"` From b92f04de550be09a39912e2d9d89765efd709a11 Mon Sep 17 00:00:00 2001 From: Mend Renovate Date: Wed, 30 Jul 2025 17:50:40 +0200 Subject: [PATCH 09/10] chore(all): update all (#3248) --- go.mod | 8 ++++---- go.sum | 16 ++++++++-------- 2 files changed, 12 insertions(+), 12 deletions(-) diff --git a/go.mod b/go.mod index 82789c1f607..c8e9a370420 100644 --- a/go.mod +++ b/go.mod @@ -17,15 +17,15 @@ require ( golang.org/x/oauth2 v0.30.0 golang.org/x/sync v0.16.0 golang.org/x/time v0.12.0 - google.golang.org/genproto/googleapis/bytestream v0.0.0-20250715232539-7130f93afb79 - google.golang.org/genproto/googleapis/rpc v0.0.0-20250715232539-7130f93afb79 - google.golang.org/grpc v1.73.0 + google.golang.org/genproto/googleapis/bytestream v0.0.0-20250728155136-f173205681a0 + google.golang.org/genproto/googleapis/rpc v0.0.0-20250728155136-f173205681a0 + google.golang.org/grpc v1.74.2 google.golang.org/protobuf v1.36.6 ) require ( github.com/felixge/httpsnoop v1.0.4 // indirect - github.com/go-logr/logr v1.4.2 // indirect + github.com/go-logr/logr v1.4.3 // indirect github.com/go-logr/stdr v1.2.2 // indirect go.opentelemetry.io/auto/sdk v1.1.0 // indirect go.opentelemetry.io/otel v1.36.0 // indirect diff --git a/go.sum b/go.sum index 6856ebb2995..f4ac4090a77 100644 --- a/go.sum +++ b/go.sum @@ -9,8 +9,8 @@ github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSs github.com/felixge/httpsnoop v1.0.4 h1:NFTV2Zj1bL4mc9sqWACXbQFVBBg2W3GPvqp8/ESS2Wg= github.com/felixge/httpsnoop v1.0.4/go.mod h1:m8KPJKqk1gH5J9DgRY2ASl2lWCfGKXixSwevea8zH2U= github.com/go-logr/logr v1.2.2/go.mod h1:jdQByPbusPIv2/zmleS9BjJVeZ6kBagPoEUsqbVz/1A= -github.com/go-logr/logr v1.4.2 h1:6pFjapn8bFcIbiKo3XT4j/BhANplGihG6tvd+8rYgrY= -github.com/go-logr/logr v1.4.2/go.mod h1:9T104GzyrTigFIr8wt5mBrctHMim0Nb2HLGrmQ40KvY= +github.com/go-logr/logr v1.4.3 h1:CjnDlHq8ikf6E492q6eKboGOC0T8CDaOvkHCIg8idEI= +github.com/go-logr/logr v1.4.3/go.mod h1:9T104GzyrTigFIr8wt5mBrctHMim0Nb2HLGrmQ40KvY= github.com/go-logr/stdr v1.2.2 h1:hSWxHoqTgW2S2qGc0LTAI563KZ5YKYRhT3MFKZMbjag= github.com/go-logr/stdr v1.2.2/go.mod h1:mMo/vtBO5dYbehREoey6XUKy/eSumjCCveDpRre4VKE= github.com/golang/protobuf v1.5.4 h1:i7eJL8qZTpSEXOPTxNKhASYpMn+8e5Q6AdndVa1dWek= @@ -63,12 +63,12 @@ google.golang.org/genproto v0.0.0-20250603155806-513f23925822 h1:rHWScKit0gvAPuO google.golang.org/genproto v0.0.0-20250603155806-513f23925822/go.mod h1:HubltRL7rMh0LfnQPkMH4NPDFEWp0jw3vixw7jEM53s= google.golang.org/genproto/googleapis/api v0.0.0-20250603155806-513f23925822 h1:oWVWY3NzT7KJppx2UKhKmzPq4SRe0LdCijVRwvGeikY= google.golang.org/genproto/googleapis/api v0.0.0-20250603155806-513f23925822/go.mod h1:h3c4v36UTKzUiuaOKQ6gr3S+0hovBtUrXzTG/i3+XEc= -google.golang.org/genproto/googleapis/bytestream v0.0.0-20250715232539-7130f93afb79 h1:IpwY95CV9qj08VMQEirHQF61g0THzlzHaj9sQ3vlExY= -google.golang.org/genproto/googleapis/bytestream v0.0.0-20250715232539-7130f93afb79/go.mod h1:h6yxum/C2qRb4txaZRLDHK8RyS0H/o2oEDeKY4onY/Y= -google.golang.org/genproto/googleapis/rpc v0.0.0-20250715232539-7130f93afb79 h1:1ZwqphdOdWYXsUHgMpU/101nCtf/kSp9hOrcvFsnl10= -google.golang.org/genproto/googleapis/rpc v0.0.0-20250715232539-7130f93afb79/go.mod h1:qQ0YXyHHx3XkvlzUtpXDkS29lDSafHMZBAZDc03LQ3A= -google.golang.org/grpc v1.73.0 h1:VIWSmpI2MegBtTuFt5/JWy2oXxtjJ/e89Z70ImfD2ok= -google.golang.org/grpc v1.73.0/go.mod h1:50sbHOUqWoCQGI8V2HQLJM0B+LMlIUjNSZmow7EVBQc= +google.golang.org/genproto/googleapis/bytestream v0.0.0-20250728155136-f173205681a0 h1:HyHZz/b6hYFm/aS2F0DOAyjK5mQw0Jh8YiZyqlXMfic= +google.golang.org/genproto/googleapis/bytestream v0.0.0-20250728155136-f173205681a0/go.mod h1:h6yxum/C2qRb4txaZRLDHK8RyS0H/o2oEDeKY4onY/Y= +google.golang.org/genproto/googleapis/rpc v0.0.0-20250728155136-f173205681a0 h1:MAKi5q709QWfnkkpNQ0M12hYJ1+e8qYVDyowc4U1XZM= +google.golang.org/genproto/googleapis/rpc v0.0.0-20250728155136-f173205681a0/go.mod h1:qQ0YXyHHx3XkvlzUtpXDkS29lDSafHMZBAZDc03LQ3A= +google.golang.org/grpc v1.74.2 h1:WoosgB65DlWVC9FqI82dGsZhWFNBSLjQ84bjROOpMu4= +google.golang.org/grpc v1.74.2/go.mod h1:CtQ+BGjaAIXHs/5YS3i473GqwBBa1zGQNevxdeBEXrM= google.golang.org/protobuf v1.36.6 h1:z1NpPI8ku2WgiWnf+t9wTPsn6eP1L7ksHUlkfLvd9xY= google.golang.org/protobuf v1.36.6/go.mod h1:jduwjTPXsFjZGTmRluh+L6NjiWu7pchiJ2/5YcXBHnY= gopkg.in/yaml.v3 v3.0.1 h1:fxVm/GzAzEWqLHuvctI91KS9hhNmmWOoWu0XTYJS7CA= From 2d71bd2db67aefe902494ac8dbe326ce4e48bbaf Mon Sep 17 00:00:00 2001 From: "release-please[bot]" <55107282+release-please[bot]@users.noreply.github.com> Date: Wed, 30 Jul 2025 14:31:57 -0400 Subject: [PATCH 10/10] chore(main): release 0.244.0 (#3242) --- CHANGES.md | 14 ++++++++++++++ internal/version.go | 2 +- 2 files changed, 15 insertions(+), 1 deletion(-) diff --git a/CHANGES.md b/CHANGES.md index ac3f26d3f16..cabec3658cc 100644 --- a/CHANGES.md +++ b/CHANGES.md @@ -1,5 +1,19 @@ # Changes +## [0.244.0](https://github.com/googleapis/google-api-go-client/compare/v0.243.0...v0.244.0) (2025-07-30) + + +### Features + +* **all:** Auto-regenerate discovery clients ([#3241](https://github.com/googleapis/google-api-go-client/issues/3241)) ([2c20485](https://github.com/googleapis/google-api-go-client/commit/2c204857ee78454d1e2cafb5df2bc3720fc0afbc)) +* **all:** Auto-regenerate discovery clients ([#3243](https://github.com/googleapis/google-api-go-client/issues/3243)) ([cac72a1](https://github.com/googleapis/google-api-go-client/commit/cac72a14582b9675f5889a346f4f195988a2c9b5)) +* **all:** Auto-regenerate discovery clients ([#3244](https://github.com/googleapis/google-api-go-client/issues/3244)) ([e6b1c87](https://github.com/googleapis/google-api-go-client/commit/e6b1c8715fbffd4598a9c80c21c274f858ea2cfe)) +* **all:** Auto-regenerate discovery clients ([#3245](https://github.com/googleapis/google-api-go-client/issues/3245)) ([2c1ff18](https://github.com/googleapis/google-api-go-client/commit/2c1ff18dfc5f5c9e422ed03c8daf571264eaec4c)) +* **all:** Auto-regenerate discovery clients ([#3247](https://github.com/googleapis/google-api-go-client/issues/3247)) ([09e5c07](https://github.com/googleapis/google-api-go-client/commit/09e5c0743dfa02b62cf54c797725b5c09744ec65)) +* **all:** Auto-regenerate discovery clients ([#3249](https://github.com/googleapis/google-api-go-client/issues/3249)) ([214eb4e](https://github.com/googleapis/google-api-go-client/commit/214eb4ea568f09bb4b874216e1b4084acb93de49)) +* **all:** Auto-regenerate discovery clients ([#3250](https://github.com/googleapis/google-api-go-client/issues/3250)) ([ce50789](https://github.com/googleapis/google-api-go-client/commit/ce50789a30c76512543819a36eb0fb91b86edc44)) +* **all:** Auto-regenerate discovery clients ([#3251](https://github.com/googleapis/google-api-go-client/issues/3251)) ([e5c3e18](https://github.com/googleapis/google-api-go-client/commit/e5c3e1801eaa85fa23ee046f1ffe8193c282b6fd)) + ## [0.243.0](https://github.com/googleapis/google-api-go-client/compare/v0.242.0...v0.243.0) (2025-07-22) diff --git a/internal/version.go b/internal/version.go index dfdef9bbb0c..11a0db6e518 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.243.0" +const Version = "0.244.0"