diff --git a/aiplatform/v1/aiplatform-api.json b/aiplatform/v1/aiplatform-api.json index 744d2831ae0..f77796737f6 100644 --- a/aiplatform/v1/aiplatform-api.json +++ b/aiplatform/v1/aiplatform-api.json @@ -3405,6 +3405,34 @@ "https://www.googleapis.com/auth/cloud-platform" ] }, + "streamRawPredict": { + "description": "", + "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/endpoints/{endpointsId}:streamRawPredict", + "httpMethod": "POST", + "id": "aiplatform.projects.locations.endpoints.streamRawPredict", + "parameterOrder": [ + "endpoint" + ], + "parameters": { + "endpoint": { + "description": "Required. The name of the Endpoint requested to serve the prediction. Format: `projects/{project}/locations/{location}/endpoints/{endpoint}`", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/endpoints/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1/{+endpoint}:streamRawPredict", + "request": { + "$ref": "GoogleCloudAiplatformV1StreamRawPredictRequest" + }, + "response": { + "$ref": "GoogleApiHttpBody" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, "undeployModel": { "description": "Undeploys a Model from an Endpoint, removing a DeployedModel from it, and freeing all resources it's using.", "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/endpoints/{endpointsId}:undeployModel", @@ -4212,7 +4240,7 @@ "type": "string" }, "parent": { - "description": "Required. The resource name of the Location to create FeatureOnlineStores. Format: `projects/{project}/locations/{location}'`", + "description": "Required. The resource name of the Location to create FeatureOnlineStores. Format: `projects/{project}/locations/{location}`", "location": "path", "pattern": "^projects/[^/]+/locations/[^/]+$", "required": true, @@ -11935,6 +11963,34 @@ "scopes": [ "https://www.googleapis.com/auth/cloud-platform" ] + }, + "streamRawPredict": { + "description": "", + "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/publishers/{publishersId}/models/{modelsId}:streamRawPredict", + "httpMethod": "POST", + "id": "aiplatform.projects.locations.publishers.models.streamRawPredict", + "parameterOrder": [ + "endpoint" + ], + "parameters": { + "endpoint": { + "description": "Required. The name of the Endpoint requested to serve the prediction. Format: `projects/{project}/locations/{location}/endpoints/{endpoint}`", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/publishers/[^/]+/models/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1/{+endpoint}:streamRawPredict", + "request": { + "$ref": "GoogleCloudAiplatformV1StreamRawPredictRequest" + }, + "response": { + "$ref": "GoogleApiHttpBody" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] } } } @@ -15332,7 +15388,7 @@ } } }, - "revision": "20240105", + "revision": "20240117", "rootUrl": "https://aiplatform.googleapis.com/", "schemas": { "CloudAiLargeModelsVisionEmbedVideoResponse": { @@ -16042,7 +16098,7 @@ "type": "boolean" }, "languageFilterResult": { - "$ref": "LearningServingLlmLanguageFilterResult", + "$ref": "LearningGenaiRootLanguageFilterResult", "description": "Language filter result from SAFT LangId." }, "raiSignals": { @@ -23820,7 +23876,7 @@ }, "modelSourceInfo": { "$ref": "GoogleCloudAiplatformV1ModelSourceInfo", - "description": "Output only. Source of a model. It can either be automl training pipeline, custom training pipeline, BigQuery ML, or existing Vertex AI Model.", + "description": "Output only. Source of a model. It can either be automl training pipeline, custom training pipeline, BigQuery ML, or saved and tuned from Genie or Model Garden.", "readOnly": true }, "name": { @@ -25290,7 +25346,12 @@ "INVALID_AVRO_SYNTAX", "INVALID_EMBEDDING_ID", "EMBEDDING_SIZE_MISMATCH", - "NAMESPACE_MISSING" + "NAMESPACE_MISSING", + "PARSING_ERROR", + "DUPLICATE_NAMESPACE", + "OP_IN_DATAPOINT", + "MULTIPLE_VALUES", + "INVALID_NUMERIC_VALUE" ], "enumDescriptions": [ "Default, shall not be used.", @@ -25300,7 +25361,12 @@ "Invalid avro format.", "The embedding id is not valid.", "The size of the embedding vectors does not match with the specified dimension.", - "The `namespace` field is missing." + "The `namespace` field is missing.", + "Generic catch-all error. Only used for validation failure where the root cause cannot be easily retrieved programmatically.", + "There are multiple restricts with the same `namespace` value.", + "Numeric restrict has operator specified in datapoint.", + "Numeric restrict has multiple values specified.", + "Numeric restrict has invalid numeric value specified." ], "type": "string" }, @@ -25903,6 +25969,10 @@ "description": "The runtime config of a PipelineJob.", "id": "GoogleCloudAiplatformV1PipelineJobRuntimeConfig", "properties": { + "defaultRuntime": { + "$ref": "GoogleCloudAiplatformV1PipelineJobRuntimeConfigDefaultRuntime", + "description": "Optional. The default runtime for the PipelineJob. If not provided, Vertex Custom Job is used as the runtime. For Vertex Custom Job, please refer to https://cloud.google.com/vertex-ai/docs/training/overview" + }, "failurePolicy": { "description": "Represents the failure policy of a pipeline. Currently, the default of a pipeline is that the pipeline will continue to run until no more tasks can be executed, also known as PIPELINE_FAILURE_POLICY_FAIL_SLOW. However, if a pipeline is set to PIPELINE_FAILURE_POLICY_FAIL_FAST, it will stop scheduling any new tasks when a task has failed. Any scheduled tasks will continue to completion.", "enum": [ @@ -25946,6 +26016,17 @@ }, "type": "object" }, + "GoogleCloudAiplatformV1PipelineJobRuntimeConfigDefaultRuntime": { + "description": "The default runtime for the PipelineJob.", + "id": "GoogleCloudAiplatformV1PipelineJobRuntimeConfigDefaultRuntime", + "properties": { + "persistentResourceRuntimeDetail": { + "$ref": "GoogleCloudAiplatformV1PipelineJobRuntimeConfigPersistentResourceRuntimeDetail", + "description": "Persistent resource based runtime detail." + } + }, + "type": "object" + }, "GoogleCloudAiplatformV1PipelineJobRuntimeConfigInputArtifact": { "description": "The type of an input artifact.", "id": "GoogleCloudAiplatformV1PipelineJobRuntimeConfigInputArtifact", @@ -25957,6 +26038,17 @@ }, "type": "object" }, + "GoogleCloudAiplatformV1PipelineJobRuntimeConfigPersistentResourceRuntimeDetail": { + "description": "Persistent resource based runtime detail. For more information, refer to https://cloud.google.com/vertex-ai/docs/training/persistent-resource-overview", + "id": "GoogleCloudAiplatformV1PipelineJobRuntimeConfigPersistentResourceRuntimeDetail", + "properties": { + "persistentResourceName": { + "description": "Persistent resource name. Format: `projects/{project}/locations/{location}/persistentResources/{persistent_resource}`", + "type": "string" + } + }, + "type": "object" + }, "GoogleCloudAiplatformV1PipelineTaskDetail": { "description": "The runtime detail of a task execution.", "id": "GoogleCloudAiplatformV1PipelineTaskDetail", @@ -31677,6 +31769,17 @@ }, "type": "object" }, + "GoogleCloudAiplatformV1StreamRawPredictRequest": { + "description": "Request message for PredictionService.StreamRawPredict.", + "id": "GoogleCloudAiplatformV1StreamRawPredictRequest", + "properties": { + "httpBody": { + "$ref": "GoogleApiHttpBody", + "description": "The prediction input. Supports HTTP headers and arbitrary data payload." + } + }, + "type": "object" + }, "GoogleCloudAiplatformV1StreamingPredictRequest": { "description": "Request message for PredictionService.StreamingPredict. The first message must contain endpoint field and optionally input. The subsequent messages must contain input.", "id": "GoogleCloudAiplatformV1StreamingPredictRequest", @@ -34054,7 +34157,7 @@ "type": "object" }, "LanguageLabsAidaTrustRecitationProtoDocAttribution": { - "description": "The proto defines the attribution information for a document using whatever fields are most applicable for that document's datasource. For example, a Wikipedia article's attribution is in the form of its article title, a website is in the form of a URL, and a Github repo is in the form of a repo name. Next id:28", + "description": "The proto defines the attribution information for a document using whatever fields are most applicable for that document's datasource. For example, a Wikipedia article's attribution is in the form of its article title, a website is in the form of a URL, and a Github repo is in the form of a repo name. Next id: 30", "id": "LanguageLabsAidaTrustRecitationProtoDocAttribution", "properties": { "amarnaId": { @@ -34069,6 +34172,10 @@ "bibkey": { "type": "string" }, + "biorxivId": { + "description": "ID of the paper in bioarxiv like ddoi.org/{biorxiv_id} eg: https://doi.org/10.1101/343517", + "type": "string" + }, "bookTitle": { "type": "string" }, @@ -34778,6 +34885,10 @@ "wikipediaArticleTitle": { "description": "Wikipedia article title. The Wikipedia TFDS dataset includes article titles but not URLs. While a URL is to the best of our knowledge a deterministic function of the title, we store the original title to reflect the information in the original dataset.", "type": "string" + }, + "youtubeVideoId": { + "description": "The unique video id from Youtube. Example: AkoGsW52Ir0", + "type": "string" } }, "type": "object" @@ -35536,7 +35647,7 @@ "type": "object" }, "LearningGenaiRecitationDocAttribution": { - "description": "The proto defines the attribution information for a document using whatever fields are most applicable for that document's datasource. For example, a Wikipedia article's attribution is in the form of its article title, a website is in the form of a URL, and a Github repo is in the form of a repo name. Next id: 28", + "description": "The proto defines the attribution information for a document using whatever fields are most applicable for that document's datasource. For example, a Wikipedia article's attribution is in the form of its article title, a website is in the form of a URL, and a Github repo is in the form of a repo name. Next id: 30", "id": "LearningGenaiRecitationDocAttribution", "properties": { "amarnaId": { @@ -35551,6 +35662,10 @@ "bibkey": { "type": "string" }, + "biorxivId": { + "description": "ID of the paper in bioarxiv like ddoi.org/{biorxiv_id} eg: https://doi.org/10.1101/343517", + "type": "string" + }, "bookTitle": { "type": "string" }, @@ -36246,6 +36361,9 @@ "wikipediaArticleTitle": { "description": "Wikipedia article title. The Wikipedia TFDS dataset includes article titles but not URLs. While a URL is to the best of our knowledge a deterministic function of the title, we store the original title to reflect the information in the original dataset.", "type": "string" + }, + "youtubeVideoId": { + "type": "string" } }, "type": "object" @@ -37205,7 +37323,7 @@ "type": "string" }, "languageFilterResult": { - "$ref": "LearningServingLlmLanguageFilterResult" + "$ref": "LearningGenaiRootLanguageFilterResult" }, "raiOutput": { "$ref": "LearningGenaiRootRAIOutput", @@ -37231,6 +37349,54 @@ }, "type": "object" }, + "LearningGenaiRootGroundingMetadata": { + "id": "LearningGenaiRootGroundingMetadata", + "properties": { + "citations": { + "items": { + "$ref": "LearningGenaiRootGroundingMetadataCitation" + }, + "type": "array" + }, + "groundingCancelled": { + "description": "True if grounding is cancelled, for example, no facts being retrieved.", + "type": "boolean" + }, + "searchQueries": { + "items": { + "type": "string" + }, + "type": "array" + } + }, + "type": "object" + }, + "LearningGenaiRootGroundingMetadataCitation": { + "id": "LearningGenaiRootGroundingMetadataCitation", + "properties": { + "endIndex": { + "description": "Index in the prediction output where the citation ends (exclusive). Must be \u003e start_index and \u003c len(output).", + "format": "int32", + "type": "integer" + }, + "factIndex": { + "description": "Index of the fact supporting this claim. Should be within the range of the `world_facts` in the GenerateResponse.", + "format": "int32", + "type": "integer" + }, + "score": { + "description": "Confidence score of this entailment. Value is [0,1] with 1 is the most confidence.", + "format": "double", + "type": "number" + }, + "startIndex": { + "description": "Index in the prediction output where the citation starts (inclusive). Must be \u003e= 0 and \u003c end_index.", + "format": "int32", + "type": "integer" + } + }, + "type": "object" + }, "LearningGenaiRootHarm": { "id": "LearningGenaiRootHarm", "properties": { @@ -37465,6 +37631,25 @@ }, "type": "object" }, + "LearningGenaiRootLanguageFilterResult": { + "id": "LearningGenaiRootLanguageFilterResult", + "properties": { + "allowed": { + "description": "False when query or response should be filtered out due to unsupported language.", + "type": "boolean" + }, + "detectedLanguage": { + "description": "Language of the query or response.", + "type": "string" + }, + "detectedLanguageProbability": { + "description": "Probability of the language predicted as returned by LangID.", + "format": "float", + "type": "number" + } + }, + "type": "object" + }, "LearningGenaiRootMetricOutput": { "id": "LearningGenaiRootMetricOutput", "properties": { @@ -37941,25 +38126,6 @@ }, "type": "object" }, - "LearningServingLlmLanguageFilterResult": { - "id": "LearningServingLlmLanguageFilterResult", - "properties": { - "allowed": { - "description": "False when query or response should be filtered out due to unsupported language.", - "type": "boolean" - }, - "detectedLanguage": { - "description": "Language of the query or response.", - "type": "string" - }, - "detectedLanguageProbability": { - "description": "Probability of the language predicted as returned by LangID.", - "format": "float", - "type": "number" - } - }, - "type": "object" - }, "LearningServingLlmMessageMetadata": { "description": "LINT.IfChange This metadata contains additional information required for debugging.", "id": "LearningServingLlmMessageMetadata", @@ -38005,6 +38171,9 @@ ], "type": "string" }, + "groundingMetadata": { + "$ref": "LearningGenaiRootGroundingMetadata" + }, "isFallback": { "description": "Applies to Response message only. Indicates whether the message is a fallback and the response would have otherwise been empty.", "type": "boolean" diff --git a/aiplatform/v1/aiplatform-gen.go b/aiplatform/v1/aiplatform-gen.go index b8f52ead878..3d086e205a5 100644 --- a/aiplatform/v1/aiplatform-gen.go +++ b/aiplatform/v1/aiplatform-gen.go @@ -2337,7 +2337,7 @@ type CloudAiNlLlmProtoServiceRaiResult struct { Filtered bool `json:"filtered,omitempty"` // LanguageFilterResult: Language filter result from SAFT LangId. - LanguageFilterResult *LearningServingLlmLanguageFilterResult `json:"languageFilterResult,omitempty"` + LanguageFilterResult *LearningGenaiRootLanguageFilterResult `json:"languageFilterResult,omitempty"` // RaiSignals: The RAI signals for the text. RaiSignals []*CloudAiNlLlmProtoServiceRaiSignal `json:"raiSignals,omitempty"` @@ -16931,7 +16931,7 @@ type GoogleCloudAiplatformV1Model struct { // ModelSourceInfo: Output only. Source of a model. It can either be // automl training pipeline, custom training pipeline, BigQuery ML, or - // existing Vertex AI Model. + // saved and tuned from Genie or Model Garden. ModelSourceInfo *GoogleCloudAiplatformV1ModelSourceInfo `json:"modelSourceInfo,omitempty"` // Name: The resource name of the Model. @@ -19440,6 +19440,16 @@ type GoogleCloudAiplatformV1NearestNeighborSearchOperationMetadataRecordError st // "EMBEDDING_SIZE_MISMATCH" - The size of the embedding vectors does // not match with the specified dimension. // "NAMESPACE_MISSING" - The `namespace` field is missing. + // "PARSING_ERROR" - Generic catch-all error. Only used for validation + // failure where the root cause cannot be easily retrieved + // programmatically. + // "DUPLICATE_NAMESPACE" - There are multiple restricts with the same + // `namespace` value. + // "OP_IN_DATAPOINT" - Numeric restrict has operator specified in + // datapoint. + // "MULTIPLE_VALUES" - Numeric restrict has multiple values specified. + // "INVALID_NUMERIC_VALUE" - Numeric restrict has invalid numeric + // value specified. ErrorType string `json:"errorType,omitempty"` // RawRecord: The original content of this record. @@ -20302,6 +20312,12 @@ func (s *GoogleCloudAiplatformV1PipelineJobDetail) MarshalJSON() ([]byte, error) // GoogleCloudAiplatformV1PipelineJobRuntimeConfig: The runtime config // of a PipelineJob. type GoogleCloudAiplatformV1PipelineJobRuntimeConfig struct { + // DefaultRuntime: Optional. The default runtime for the PipelineJob. If + // not provided, Vertex Custom Job is used as the runtime. For Vertex + // Custom Job, please refer to + // https://cloud.google.com/vertex-ai/docs/training/overview + DefaultRuntime *GoogleCloudAiplatformV1PipelineJobRuntimeConfigDefaultRuntime `json:"defaultRuntime,omitempty"` + // FailurePolicy: Represents the failure policy of a pipeline. // Currently, the default of a pipeline is that the pipeline will // continue to run until no more tasks can be executed, also known as @@ -20351,7 +20367,7 @@ type GoogleCloudAiplatformV1PipelineJobRuntimeConfig struct { // pipelines built using Kubeflow Pipelines SDK 1.8 or lower. Parameters map[string]GoogleCloudAiplatformV1Value `json:"parameters,omitempty"` - // ForceSendFields is a list of field names (e.g. "FailurePolicy") to + // ForceSendFields is a list of field names (e.g. "DefaultRuntime") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -20359,12 +20375,13 @@ type GoogleCloudAiplatformV1PipelineJobRuntimeConfig struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "FailurePolicy") to include - // in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. However, any field with - // an empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "DefaultRuntime") to + // include in API requests with the JSON null value. By default, fields + // with empty values are omitted from API requests. However, any field + // with an empty value appearing in NullFields will be sent to the + // server as null. It is an error if a field in this list has a + // non-empty value. This may be used to include null fields in Patch + // requests. NullFields []string `json:"-"` } @@ -20374,6 +20391,38 @@ func (s *GoogleCloudAiplatformV1PipelineJobRuntimeConfig) MarshalJSON() ([]byte, return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } +// GoogleCloudAiplatformV1PipelineJobRuntimeConfigDefaultRuntime: The +// default runtime for the PipelineJob. +type GoogleCloudAiplatformV1PipelineJobRuntimeConfigDefaultRuntime struct { + // PersistentResourceRuntimeDetail: Persistent resource based runtime + // detail. + PersistentResourceRuntimeDetail *GoogleCloudAiplatformV1PipelineJobRuntimeConfigPersistentResourceRuntimeDetail `json:"persistentResourceRuntimeDetail,omitempty"` + + // ForceSendFields is a list of field names (e.g. + // "PersistentResourceRuntimeDetail") to unconditionally include in API + // requests. By default, fields with empty or default values are omitted + // from API requests. However, any non-pointer, non-interface field + // appearing in ForceSendFields will be sent to the server regardless of + // whether the field is empty or not. This may be used to include empty + // fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. + // "PersistentResourceRuntimeDetail") to include in API requests with + // the JSON null value. By default, fields with empty values are omitted + // from API requests. However, any field with an empty value appearing + // in NullFields will be sent to the server as null. It is an error if a + // field in this list has a non-empty value. This may be used to include + // null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudAiplatformV1PipelineJobRuntimeConfigDefaultRuntime) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudAiplatformV1PipelineJobRuntimeConfigDefaultRuntime + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + // GoogleCloudAiplatformV1PipelineJobRuntimeConfigInputArtifact: The // type of an input artifact. type GoogleCloudAiplatformV1PipelineJobRuntimeConfigInputArtifact struct { @@ -20407,6 +20456,41 @@ func (s *GoogleCloudAiplatformV1PipelineJobRuntimeConfigInputArtifact) MarshalJS return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } +// GoogleCloudAiplatformV1PipelineJobRuntimeConfigPersistentResourceRunti +// meDetail: Persistent resource based runtime detail. For more +// information, refer to +// https://cloud.google.com/vertex-ai/docs/training/persistent-resource-overview +type GoogleCloudAiplatformV1PipelineJobRuntimeConfigPersistentResourceRuntimeDetail struct { + // PersistentResourceName: Persistent resource name. Format: + // `projects/{project}/locations/{location}/persistentResources/{persiste + // nt_resource}` + PersistentResourceName string `json:"persistentResourceName,omitempty"` + + // ForceSendFields is a list of field names (e.g. + // "PersistentResourceName") to unconditionally include in API requests. + // By default, fields with empty or default values are omitted from API + // requests. However, any non-pointer, non-interface field appearing in + // ForceSendFields will be sent to the server regardless of whether the + // field is empty or not. This may be used to include empty fields in + // Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "PersistentResourceName") + // to include in API requests with the JSON null value. By default, + // fields with empty values are omitted from API requests. However, any + // field with an empty value appearing in NullFields will be sent to the + // server as null. It is an error if a field in this list has a + // non-empty value. This may be used to include null fields in Patch + // requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudAiplatformV1PipelineJobRuntimeConfigPersistentResourceRuntimeDetail) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudAiplatformV1PipelineJobRuntimeConfigPersistentResourceRuntimeDetail + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + // GoogleCloudAiplatformV1PipelineTaskDetail: The runtime detail of a // task execution. type GoogleCloudAiplatformV1PipelineTaskDetail struct { @@ -31689,6 +31773,36 @@ func (s *GoogleCloudAiplatformV1StratifiedSplit) UnmarshalJSON(data []byte) erro return nil } +// GoogleCloudAiplatformV1StreamRawPredictRequest: Request message for +// PredictionService.StreamRawPredict. +type GoogleCloudAiplatformV1StreamRawPredictRequest struct { + // HttpBody: The prediction input. Supports HTTP headers and arbitrary + // data payload. + HttpBody *GoogleApiHttpBody `json:"httpBody,omitempty"` + + // ForceSendFields is a list of field names (e.g. "HttpBody") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "HttpBody") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudAiplatformV1StreamRawPredictRequest) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudAiplatformV1StreamRawPredictRequest + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + // GoogleCloudAiplatformV1StreamingPredictRequest: Request message for // PredictionService.StreamingPredict. The first message must contain // endpoint field and optionally input. The subsequent messages must @@ -36266,7 +36380,7 @@ func (s *IntelligenceCloudAutomlXpsReportingMetrics) MarshalJSON() ([]byte, erro // most applicable for that document's datasource. For example, a // Wikipedia article's attribution is in the form of its article title, // a website is in the form of a URL, and a Github repo is in the form -// of a repo name. Next id:28 +// of a repo name. Next id: 30 type LanguageLabsAidaTrustRecitationProtoDocAttribution struct { AmarnaId string `json:"amarnaId,omitempty"` @@ -36276,6 +36390,10 @@ type LanguageLabsAidaTrustRecitationProtoDocAttribution struct { Bibkey string `json:"bibkey,omitempty"` + // BiorxivId: ID of the paper in bioarxiv like ddoi.org/{biorxiv_id} eg: + // https://doi.org/10.1101/343517 + BiorxivId string `json:"biorxivId,omitempty"` + BookTitle string `json:"bookTitle,omitempty"` // BookVolumeId: The Oceanographers full-view books dataset uses a @@ -36775,6 +36893,10 @@ type LanguageLabsAidaTrustRecitationProtoDocAttribution struct { // dataset. WikipediaArticleTitle string `json:"wikipediaArticleTitle,omitempty"` + // YoutubeVideoId: The unique video id from Youtube. Example: + // AkoGsW52Ir0 + YoutubeVideoId string `json:"youtubeVideoId,omitempty"` + // ForceSendFields is a list of field names (e.g. "AmarnaId") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any @@ -37396,7 +37518,7 @@ func (s *LanguageLabsAidaTrustRecitationProtoStreamRecitationResult) MarshalJSON // applicable for that document's datasource. For example, a Wikipedia // article's attribution is in the form of its article title, a website // is in the form of a URL, and a Github repo is in the form of a repo -// name. Next id: 28 +// name. Next id: 30 type LearningGenaiRecitationDocAttribution struct { AmarnaId string `json:"amarnaId,omitempty"` @@ -37406,6 +37528,10 @@ type LearningGenaiRecitationDocAttribution struct { Bibkey string `json:"bibkey,omitempty"` + // BiorxivId: ID of the paper in bioarxiv like ddoi.org/{biorxiv_id} eg: + // https://doi.org/10.1101/343517 + BiorxivId string `json:"biorxivId,omitempty"` + BookTitle string `json:"bookTitle,omitempty"` // BookVolumeId: The Oceanographers full-view books dataset uses a @@ -37896,6 +38022,8 @@ type LearningGenaiRecitationDocAttribution struct { // dataset. WikipediaArticleTitle string `json:"wikipediaArticleTitle,omitempty"` + YoutubeVideoId string `json:"youtubeVideoId,omitempty"` + // ForceSendFields is a list of field names (e.g. "AmarnaId") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any @@ -38742,7 +38870,7 @@ type LearningGenaiRootFilterMetadataFilterDebugInfo struct { DefaultMetadata string `json:"defaultMetadata,omitempty"` - LanguageFilterResult *LearningServingLlmLanguageFilterResult `json:"languageFilterResult,omitempty"` + LanguageFilterResult *LearningGenaiRootLanguageFilterResult `json:"languageFilterResult,omitempty"` // RaiOutput: Safety filter output information for LLM Root RAI harm // check. @@ -38782,6 +38910,92 @@ func (s *LearningGenaiRootFilterMetadataFilterDebugInfo) MarshalJSON() ([]byte, return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } +type LearningGenaiRootGroundingMetadata struct { + Citations []*LearningGenaiRootGroundingMetadataCitation `json:"citations,omitempty"` + + // GroundingCancelled: True if grounding is cancelled, for example, no + // facts being retrieved. + GroundingCancelled bool `json:"groundingCancelled,omitempty"` + + SearchQueries []string `json:"searchQueries,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Citations") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "Citations") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *LearningGenaiRootGroundingMetadata) MarshalJSON() ([]byte, error) { + type NoMethod LearningGenaiRootGroundingMetadata + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +type LearningGenaiRootGroundingMetadataCitation struct { + // EndIndex: Index in the prediction output where the citation ends + // (exclusive). Must be > start_index and < len(output). + EndIndex int64 `json:"endIndex,omitempty"` + + // FactIndex: Index of the fact supporting this claim. Should be within + // the range of the `world_facts` in the GenerateResponse. + FactIndex int64 `json:"factIndex,omitempty"` + + // Score: Confidence score of this entailment. Value is [0,1] with 1 is + // the most confidence. + Score float64 `json:"score,omitempty"` + + // StartIndex: Index in the prediction output where the citation starts + // (inclusive). Must be >= 0 and < end_index. + StartIndex int64 `json:"startIndex,omitempty"` + + // ForceSendFields is a list of field names (e.g. "EndIndex") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "EndIndex") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *LearningGenaiRootGroundingMetadataCitation) MarshalJSON() ([]byte, error) { + type NoMethod LearningGenaiRootGroundingMetadataCitation + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +func (s *LearningGenaiRootGroundingMetadataCitation) UnmarshalJSON(data []byte) error { + type NoMethod LearningGenaiRootGroundingMetadataCitation + var s1 struct { + Score gensupport.JSONFloat64 `json:"score"` + *NoMethod + } + s1.NoMethod = (*NoMethod)(s) + if err := json.Unmarshal(data, &s1); err != nil { + return err + } + s.Score = float64(s1.Score) + return nil +} + type LearningGenaiRootHarm struct { // ContextualDangerous: Please do not use, this is still under // development. @@ -39048,6 +39262,55 @@ func (s *LearningGenaiRootInternalMetadata) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } +type LearningGenaiRootLanguageFilterResult struct { + // Allowed: False when query or response should be filtered out due to + // unsupported language. + Allowed bool `json:"allowed,omitempty"` + + // DetectedLanguage: Language of the query or response. + DetectedLanguage string `json:"detectedLanguage,omitempty"` + + // DetectedLanguageProbability: Probability of the language predicted as + // returned by LangID. + DetectedLanguageProbability float64 `json:"detectedLanguageProbability,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Allowed") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "Allowed") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *LearningGenaiRootLanguageFilterResult) MarshalJSON() ([]byte, error) { + type NoMethod LearningGenaiRootLanguageFilterResult + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +func (s *LearningGenaiRootLanguageFilterResult) UnmarshalJSON(data []byte) error { + type NoMethod LearningGenaiRootLanguageFilterResult + var s1 struct { + DetectedLanguageProbability gensupport.JSONFloat64 `json:"detectedLanguageProbability"` + *NoMethod + } + s1.NoMethod = (*NoMethod)(s) + if err := json.Unmarshal(data, &s1); err != nil { + return err + } + s.DetectedLanguageProbability = float64(s1.DetectedLanguageProbability) + return nil +} + type LearningGenaiRootMetricOutput struct { Debug string `json:"debug,omitempty"` @@ -39984,55 +40247,6 @@ func (s *LearningGenaiRootToxicitySignal) UnmarshalJSON(data []byte) error { return nil } -type LearningServingLlmLanguageFilterResult struct { - // Allowed: False when query or response should be filtered out due to - // unsupported language. - Allowed bool `json:"allowed,omitempty"` - - // DetectedLanguage: Language of the query or response. - DetectedLanguage string `json:"detectedLanguage,omitempty"` - - // DetectedLanguageProbability: Probability of the language predicted as - // returned by LangID. - DetectedLanguageProbability float64 `json:"detectedLanguageProbability,omitempty"` - - // ForceSendFields is a list of field names (e.g. "Allowed") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. - ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Allowed") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. - NullFields []string `json:"-"` -} - -func (s *LearningServingLlmLanguageFilterResult) MarshalJSON() ([]byte, error) { - type NoMethod LearningServingLlmLanguageFilterResult - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) -} - -func (s *LearningServingLlmLanguageFilterResult) UnmarshalJSON(data []byte) error { - type NoMethod LearningServingLlmLanguageFilterResult - var s1 struct { - DetectedLanguageProbability gensupport.JSONFloat64 `json:"detectedLanguageProbability"` - *NoMethod - } - s1.NoMethod = (*NoMethod)(s) - if err := json.Unmarshal(data, &s1); err != nil { - return err - } - s.DetectedLanguageProbability = float64(s1.DetectedLanguageProbability) - return nil -} - // LearningServingLlmMessageMetadata: LINT.IfChange This metadata // contains additional information required for debugging. type LearningServingLlmMessageMetadata struct { @@ -40066,6 +40280,8 @@ type LearningServingLlmMessageMetadata struct { // "FILTER" - Finished due to triggering some post-processing filter. FinishReason string `json:"finishReason,omitempty"` + GroundingMetadata *LearningGenaiRootGroundingMetadata `json:"groundingMetadata,omitempty"` + // IsFallback: Applies to Response message only. Indicates whether the // message is a fallback and the response would have otherwise been // empty. @@ -56100,6 +56316,150 @@ func (c *ProjectsLocationsEndpointsStreamGenerateContentCall) Do(opts ...googlea } +// method id "aiplatform.projects.locations.endpoints.streamRawPredict": + +type ProjectsLocationsEndpointsStreamRawPredictCall struct { + s *Service + endpoint string + googlecloudaiplatformv1streamrawpredictrequest *GoogleCloudAiplatformV1StreamRawPredictRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// StreamRawPredict: +// +// - endpoint: The name of the Endpoint requested to serve the +// prediction. Format: +// `projects/{project}/locations/{location}/endpoints/{endpoint}`. +func (r *ProjectsLocationsEndpointsService) StreamRawPredict(endpoint string, googlecloudaiplatformv1streamrawpredictrequest *GoogleCloudAiplatformV1StreamRawPredictRequest) *ProjectsLocationsEndpointsStreamRawPredictCall { + c := &ProjectsLocationsEndpointsStreamRawPredictCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.endpoint = endpoint + c.googlecloudaiplatformv1streamrawpredictrequest = googlecloudaiplatformv1streamrawpredictrequest + return c +} + +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse +// for more information. +func (c *ProjectsLocationsEndpointsStreamRawPredictCall) Fields(s ...googleapi.Field) *ProjectsLocationsEndpointsStreamRawPredictCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. Any +// pending HTTP request will be aborted if the provided context is +// canceled. +func (c *ProjectsLocationsEndpointsStreamRawPredictCall) Context(ctx context.Context) *ProjectsLocationsEndpointsStreamRawPredictCall { + c.ctx_ = ctx + return c +} + +// Header returns an http.Header that can be modified by the caller to +// add HTTP headers to the request. +func (c *ProjectsLocationsEndpointsStreamRawPredictCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsEndpointsStreamRawPredictCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := make(http.Header) + reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) + for k, v := range c.header_ { + reqHeaders[k] = v + } + reqHeaders.Set("User-Agent", c.s.userAgent()) + var body io.Reader = nil + body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudaiplatformv1streamrawpredictrequest) + if err != nil { + return nil, err + } + reqHeaders.Set("Content-Type", "application/json") + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+endpoint}:streamRawPredict") + 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{ + "endpoint": c.endpoint, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "aiplatform.projects.locations.endpoints.streamRawPredict" call. +// Exactly one of *GoogleApiHttpBody or error will be non-nil. Any +// non-2xx status code is an error. Response headers are in either +// *GoogleApiHttpBody.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 *ProjectsLocationsEndpointsStreamRawPredictCall) Do(opts ...googleapi.CallOption) (*GoogleApiHttpBody, 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 := &GoogleApiHttpBody{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil + // { + // "description": "", + // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/endpoints/{endpointsId}:streamRawPredict", + // "httpMethod": "POST", + // "id": "aiplatform.projects.locations.endpoints.streamRawPredict", + // "parameterOrder": [ + // "endpoint" + // ], + // "parameters": { + // "endpoint": { + // "description": "Required. The name of the Endpoint requested to serve the prediction. Format: `projects/{project}/locations/{location}/endpoints/{endpoint}`", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/endpoints/[^/]+$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1/{+endpoint}:streamRawPredict", + // "request": { + // "$ref": "GoogleCloudAiplatformV1StreamRawPredictRequest" + // }, + // "response": { + // "$ref": "GoogleApiHttpBody" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + // method id "aiplatform.projects.locations.endpoints.undeployModel": type ProjectsLocationsEndpointsUndeployModelCall struct { @@ -60085,7 +60445,7 @@ type ProjectsLocationsFeatureOnlineStoresCreateCall struct { // // - parent: The resource name of the Location to create // FeatureOnlineStores. Format: -// `projects/{project}/locations/{location}'`. +// `projects/{project}/locations/{location}`. func (r *ProjectsLocationsFeatureOnlineStoresService) Create(parent string, googlecloudaiplatformv1featureonlinestore *GoogleCloudAiplatformV1FeatureOnlineStore) *ProjectsLocationsFeatureOnlineStoresCreateCall { c := &ProjectsLocationsFeatureOnlineStoresCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.parent = parent @@ -60210,7 +60570,7 @@ func (c *ProjectsLocationsFeatureOnlineStoresCreateCall) Do(opts ...googleapi.Ca // "type": "string" // }, // "parent": { - // "description": "Required. The resource name of the Location to create FeatureOnlineStores. Format: `projects/{project}/locations/{location}'`", + // "description": "Required. The resource name of the Location to create FeatureOnlineStores. Format: `projects/{project}/locations/{location}`", // "location": "path", // "pattern": "^projects/[^/]+/locations/[^/]+$", // "required": true, @@ -99697,6 +100057,150 @@ func (c *ProjectsLocationsPublishersModelsStreamGenerateContentCall) Do(opts ... } +// method id "aiplatform.projects.locations.publishers.models.streamRawPredict": + +type ProjectsLocationsPublishersModelsStreamRawPredictCall struct { + s *Service + endpoint string + googlecloudaiplatformv1streamrawpredictrequest *GoogleCloudAiplatformV1StreamRawPredictRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// StreamRawPredict: +// +// - endpoint: The name of the Endpoint requested to serve the +// prediction. Format: +// `projects/{project}/locations/{location}/endpoints/{endpoint}`. +func (r *ProjectsLocationsPublishersModelsService) StreamRawPredict(endpoint string, googlecloudaiplatformv1streamrawpredictrequest *GoogleCloudAiplatformV1StreamRawPredictRequest) *ProjectsLocationsPublishersModelsStreamRawPredictCall { + c := &ProjectsLocationsPublishersModelsStreamRawPredictCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.endpoint = endpoint + c.googlecloudaiplatformv1streamrawpredictrequest = googlecloudaiplatformv1streamrawpredictrequest + return c +} + +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse +// for more information. +func (c *ProjectsLocationsPublishersModelsStreamRawPredictCall) Fields(s ...googleapi.Field) *ProjectsLocationsPublishersModelsStreamRawPredictCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. Any +// pending HTTP request will be aborted if the provided context is +// canceled. +func (c *ProjectsLocationsPublishersModelsStreamRawPredictCall) Context(ctx context.Context) *ProjectsLocationsPublishersModelsStreamRawPredictCall { + c.ctx_ = ctx + return c +} + +// Header returns an http.Header that can be modified by the caller to +// add HTTP headers to the request. +func (c *ProjectsLocationsPublishersModelsStreamRawPredictCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsPublishersModelsStreamRawPredictCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := make(http.Header) + reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) + for k, v := range c.header_ { + reqHeaders[k] = v + } + reqHeaders.Set("User-Agent", c.s.userAgent()) + var body io.Reader = nil + body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudaiplatformv1streamrawpredictrequest) + if err != nil { + return nil, err + } + reqHeaders.Set("Content-Type", "application/json") + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+endpoint}:streamRawPredict") + 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{ + "endpoint": c.endpoint, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "aiplatform.projects.locations.publishers.models.streamRawPredict" call. +// Exactly one of *GoogleApiHttpBody or error will be non-nil. Any +// non-2xx status code is an error. Response headers are in either +// *GoogleApiHttpBody.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 *ProjectsLocationsPublishersModelsStreamRawPredictCall) Do(opts ...googleapi.CallOption) (*GoogleApiHttpBody, 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 := &GoogleApiHttpBody{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil + // { + // "description": "", + // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/publishers/{publishersId}/models/{modelsId}:streamRawPredict", + // "httpMethod": "POST", + // "id": "aiplatform.projects.locations.publishers.models.streamRawPredict", + // "parameterOrder": [ + // "endpoint" + // ], + // "parameters": { + // "endpoint": { + // "description": "Required. The name of the Endpoint requested to serve the prediction. Format: `projects/{project}/locations/{location}/endpoints/{endpoint}`", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/publishers/[^/]+/models/[^/]+$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1/{+endpoint}:streamRawPredict", + // "request": { + // "$ref": "GoogleCloudAiplatformV1StreamRawPredictRequest" + // }, + // "response": { + // "$ref": "GoogleApiHttpBody" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + // method id "aiplatform.projects.locations.schedules.create": type ProjectsLocationsSchedulesCreateCall struct { diff --git a/aiplatform/v1beta1/aiplatform-api.json b/aiplatform/v1beta1/aiplatform-api.json index 07687c4e3d9..1a009579e5e 100644 --- a/aiplatform/v1beta1/aiplatform-api.json +++ b/aiplatform/v1beta1/aiplatform-api.json @@ -5072,7 +5072,7 @@ "type": "string" }, "parent": { - "description": "Required. The resource name of the Location to create FeatureOnlineStores. Format: `projects/{project}/locations/{location}'`", + "description": "Required. The resource name of the Location to create FeatureOnlineStores. Format: `projects/{project}/locations/{location}`", "location": "path", "pattern": "^projects/[^/]+/locations/[^/]+$", "required": true, @@ -17279,7 +17279,7 @@ } } }, - "revision": "20240105", + "revision": "20240117", "rootUrl": "https://aiplatform.googleapis.com/", "schemas": { "CloudAiLargeModelsVisionEmbedVideoResponse": { @@ -17989,7 +17989,7 @@ "type": "boolean" }, "languageFilterResult": { - "$ref": "LearningServingLlmLanguageFilterResult", + "$ref": "LearningGenaiRootLanguageFilterResult", "description": "Language filter result from SAFT LangId." }, "raiSignals": { @@ -20050,6 +20050,10 @@ "genericMetadata": { "$ref": "GoogleCloudAiplatformV1beta1GenericOperationMetadata", "description": "Operation metadata for PersistentResource." + }, + "progressMessage": { + "description": "Progress Message for Create LRO", + "type": "string" } }, "type": "object" @@ -26210,7 +26214,7 @@ }, "modelSourceInfo": { "$ref": "GoogleCloudAiplatformV1beta1ModelSourceInfo", - "description": "Output only. Source of a model. It can either be automl training pipeline, custom training pipeline, BigQuery ML, or existing Vertex AI Model.", + "description": "Output only. Source of a model. It can either be automl training pipeline, custom training pipeline, BigQuery ML, or saved and tuned from Genie or Model Garden.", "readOnly": true }, "name": { @@ -27772,7 +27776,12 @@ "INVALID_AVRO_SYNTAX", "INVALID_EMBEDDING_ID", "EMBEDDING_SIZE_MISMATCH", - "NAMESPACE_MISSING" + "NAMESPACE_MISSING", + "PARSING_ERROR", + "DUPLICATE_NAMESPACE", + "OP_IN_DATAPOINT", + "MULTIPLE_VALUES", + "INVALID_NUMERIC_VALUE" ], "enumDescriptions": [ "Default, shall not be used.", @@ -27782,7 +27791,12 @@ "Invalid avro format.", "The embedding id is not valid.", "The size of the embedding vectors does not match with the specified dimension.", - "The `namespace` field is missing." + "The `namespace` field is missing.", + "Generic catch-all error. Only used for validation failure where the root cause cannot be easily retrieved programmatically.", + "There are multiple restricts with the same `namespace` value.", + "Numeric restrict has operator specified in datapoint.", + "Numeric restrict has multiple values specified.", + "Numeric restrict has invalid numeric value specified." ], "type": "string" }, @@ -28514,6 +28528,10 @@ "description": "The runtime config of a PipelineJob.", "id": "GoogleCloudAiplatformV1beta1PipelineJobRuntimeConfig", "properties": { + "defaultRuntime": { + "$ref": "GoogleCloudAiplatformV1beta1PipelineJobRuntimeConfigDefaultRuntime", + "description": "Optional. The default runtime for the PipelineJob. If not provided, Vertex Custom Job is used as the runtime. For Vertex Custom Job, please refer to https://cloud.google.com/vertex-ai/docs/training/overview" + }, "failurePolicy": { "description": "Represents the failure policy of a pipeline. Currently, the default of a pipeline is that the pipeline will continue to run until no more tasks can be executed, also known as PIPELINE_FAILURE_POLICY_FAIL_SLOW. However, if a pipeline is set to PIPELINE_FAILURE_POLICY_FAIL_FAST, it will stop scheduling any new tasks when a task has failed. Any scheduled tasks will continue to completion.", "enum": [ @@ -28557,6 +28575,17 @@ }, "type": "object" }, + "GoogleCloudAiplatformV1beta1PipelineJobRuntimeConfigDefaultRuntime": { + "description": "The default runtime for the PipelineJob.", + "id": "GoogleCloudAiplatformV1beta1PipelineJobRuntimeConfigDefaultRuntime", + "properties": { + "persistentResourceRuntimeDetail": { + "$ref": "GoogleCloudAiplatformV1beta1PipelineJobRuntimeConfigPersistentResourceRuntimeDetail", + "description": "Persistent resource based runtime detail." + } + }, + "type": "object" + }, "GoogleCloudAiplatformV1beta1PipelineJobRuntimeConfigInputArtifact": { "description": "The type of an input artifact.", "id": "GoogleCloudAiplatformV1beta1PipelineJobRuntimeConfigInputArtifact", @@ -28568,6 +28597,17 @@ }, "type": "object" }, + "GoogleCloudAiplatformV1beta1PipelineJobRuntimeConfigPersistentResourceRuntimeDetail": { + "description": "Persistent resource based runtime detail. For more information, refer to https://cloud.google.com/vertex-ai/docs/training/persistent-resource-overview", + "id": "GoogleCloudAiplatformV1beta1PipelineJobRuntimeConfigPersistentResourceRuntimeDetail", + "properties": { + "persistentResourceName": { + "description": "Persistent resource name. Format: `projects/{project}/locations/{location}/persistentResources/{persistent_resource}`", + "type": "string" + } + }, + "type": "object" + }, "GoogleCloudAiplatformV1beta1PipelineTaskDetail": { "description": "The runtime detail of a task execution.", "id": "GoogleCloudAiplatformV1beta1PipelineTaskDetail", @@ -29899,7 +29939,7 @@ "type": "object" }, "GoogleCloudAiplatformV1beta1ReportRuntimeEventRequest": { - "description": "LINT.IfChange(report_event_message_types) Request message for NotebookInternalService.ReportRuntimeEvent.", + "description": "Request message for NotebookInternalService.ReportRuntimeEvent.", "id": "GoogleCloudAiplatformV1beta1ReportRuntimeEventRequest", "properties": { "eventDetails": { @@ -36187,6 +36227,10 @@ "genericMetadata": { "$ref": "GoogleCloudAiplatformV1beta1GenericOperationMetadata", "description": "Operation metadata for PersistentResource." + }, + "progressMessage": { + "description": "Progress Message for Update LRO", + "type": "string" } }, "type": "object" @@ -36924,7 +36968,7 @@ "type": "object" }, "LanguageLabsAidaTrustRecitationProtoDocAttribution": { - "description": "The proto defines the attribution information for a document using whatever fields are most applicable for that document's datasource. For example, a Wikipedia article's attribution is in the form of its article title, a website is in the form of a URL, and a Github repo is in the form of a repo name. Next id:28", + "description": "The proto defines the attribution information for a document using whatever fields are most applicable for that document's datasource. For example, a Wikipedia article's attribution is in the form of its article title, a website is in the form of a URL, and a Github repo is in the form of a repo name. Next id: 30", "id": "LanguageLabsAidaTrustRecitationProtoDocAttribution", "properties": { "amarnaId": { @@ -36939,6 +36983,10 @@ "bibkey": { "type": "string" }, + "biorxivId": { + "description": "ID of the paper in bioarxiv like ddoi.org/{biorxiv_id} eg: https://doi.org/10.1101/343517", + "type": "string" + }, "bookTitle": { "type": "string" }, @@ -37648,6 +37696,10 @@ "wikipediaArticleTitle": { "description": "Wikipedia article title. The Wikipedia TFDS dataset includes article titles but not URLs. While a URL is to the best of our knowledge a deterministic function of the title, we store the original title to reflect the information in the original dataset.", "type": "string" + }, + "youtubeVideoId": { + "description": "The unique video id from Youtube. Example: AkoGsW52Ir0", + "type": "string" } }, "type": "object" @@ -38406,7 +38458,7 @@ "type": "object" }, "LearningGenaiRecitationDocAttribution": { - "description": "The proto defines the attribution information for a document using whatever fields are most applicable for that document's datasource. For example, a Wikipedia article's attribution is in the form of its article title, a website is in the form of a URL, and a Github repo is in the form of a repo name. Next id: 28", + "description": "The proto defines the attribution information for a document using whatever fields are most applicable for that document's datasource. For example, a Wikipedia article's attribution is in the form of its article title, a website is in the form of a URL, and a Github repo is in the form of a repo name. Next id: 30", "id": "LearningGenaiRecitationDocAttribution", "properties": { "amarnaId": { @@ -38421,6 +38473,10 @@ "bibkey": { "type": "string" }, + "biorxivId": { + "description": "ID of the paper in bioarxiv like ddoi.org/{biorxiv_id} eg: https://doi.org/10.1101/343517", + "type": "string" + }, "bookTitle": { "type": "string" }, @@ -39116,6 +39172,9 @@ "wikipediaArticleTitle": { "description": "Wikipedia article title. The Wikipedia TFDS dataset includes article titles but not URLs. While a URL is to the best of our knowledge a deterministic function of the title, we store the original title to reflect the information in the original dataset.", "type": "string" + }, + "youtubeVideoId": { + "type": "string" } }, "type": "object" @@ -40075,7 +40134,7 @@ "type": "string" }, "languageFilterResult": { - "$ref": "LearningServingLlmLanguageFilterResult" + "$ref": "LearningGenaiRootLanguageFilterResult" }, "raiOutput": { "$ref": "LearningGenaiRootRAIOutput", @@ -40101,6 +40160,54 @@ }, "type": "object" }, + "LearningGenaiRootGroundingMetadata": { + "id": "LearningGenaiRootGroundingMetadata", + "properties": { + "citations": { + "items": { + "$ref": "LearningGenaiRootGroundingMetadataCitation" + }, + "type": "array" + }, + "groundingCancelled": { + "description": "True if grounding is cancelled, for example, no facts being retrieved.", + "type": "boolean" + }, + "searchQueries": { + "items": { + "type": "string" + }, + "type": "array" + } + }, + "type": "object" + }, + "LearningGenaiRootGroundingMetadataCitation": { + "id": "LearningGenaiRootGroundingMetadataCitation", + "properties": { + "endIndex": { + "description": "Index in the prediction output where the citation ends (exclusive). Must be \u003e start_index and \u003c len(output).", + "format": "int32", + "type": "integer" + }, + "factIndex": { + "description": "Index of the fact supporting this claim. Should be within the range of the `world_facts` in the GenerateResponse.", + "format": "int32", + "type": "integer" + }, + "score": { + "description": "Confidence score of this entailment. Value is [0,1] with 1 is the most confidence.", + "format": "double", + "type": "number" + }, + "startIndex": { + "description": "Index in the prediction output where the citation starts (inclusive). Must be \u003e= 0 and \u003c end_index.", + "format": "int32", + "type": "integer" + } + }, + "type": "object" + }, "LearningGenaiRootHarm": { "id": "LearningGenaiRootHarm", "properties": { @@ -40335,6 +40442,25 @@ }, "type": "object" }, + "LearningGenaiRootLanguageFilterResult": { + "id": "LearningGenaiRootLanguageFilterResult", + "properties": { + "allowed": { + "description": "False when query or response should be filtered out due to unsupported language.", + "type": "boolean" + }, + "detectedLanguage": { + "description": "Language of the query or response.", + "type": "string" + }, + "detectedLanguageProbability": { + "description": "Probability of the language predicted as returned by LangID.", + "format": "float", + "type": "number" + } + }, + "type": "object" + }, "LearningGenaiRootMetricOutput": { "id": "LearningGenaiRootMetricOutput", "properties": { @@ -40811,25 +40937,6 @@ }, "type": "object" }, - "LearningServingLlmLanguageFilterResult": { - "id": "LearningServingLlmLanguageFilterResult", - "properties": { - "allowed": { - "description": "False when query or response should be filtered out due to unsupported language.", - "type": "boolean" - }, - "detectedLanguage": { - "description": "Language of the query or response.", - "type": "string" - }, - "detectedLanguageProbability": { - "description": "Probability of the language predicted as returned by LangID.", - "format": "float", - "type": "number" - } - }, - "type": "object" - }, "LearningServingLlmMessageMetadata": { "description": "LINT.IfChange This metadata contains additional information required for debugging.", "id": "LearningServingLlmMessageMetadata", @@ -40875,6 +40982,9 @@ ], "type": "string" }, + "groundingMetadata": { + "$ref": "LearningGenaiRootGroundingMetadata" + }, "isFallback": { "description": "Applies to Response message only. Indicates whether the message is a fallback and the response would have otherwise been empty.", "type": "boolean" diff --git a/aiplatform/v1beta1/aiplatform-gen.go b/aiplatform/v1beta1/aiplatform-gen.go index 6b97857449b..dd51c64fdc0 100644 --- a/aiplatform/v1beta1/aiplatform-gen.go +++ b/aiplatform/v1beta1/aiplatform-gen.go @@ -2565,7 +2565,7 @@ type CloudAiNlLlmProtoServiceRaiResult struct { Filtered bool `json:"filtered,omitempty"` // LanguageFilterResult: Language filter result from SAFT LangId. - LanguageFilterResult *LearningServingLlmLanguageFilterResult `json:"languageFilterResult,omitempty"` + LanguageFilterResult *LearningGenaiRootLanguageFilterResult `json:"languageFilterResult,omitempty"` // RaiSignals: The RAI signals for the text. RaiSignals []*CloudAiNlLlmProtoServiceRaiSignal `json:"raiSignals,omitempty"` @@ -6446,6 +6446,9 @@ type GoogleCloudAiplatformV1beta1CreatePersistentResourceOperationMetadata struc // GenericMetadata: Operation metadata for PersistentResource. GenericMetadata *GoogleCloudAiplatformV1beta1GenericOperationMetadata `json:"genericMetadata,omitempty"` + // ProgressMessage: Progress Message for Create LRO + ProgressMessage string `json:"progressMessage,omitempty"` + // ForceSendFields is a list of field names (e.g. "GenericMetadata") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any @@ -18003,7 +18006,7 @@ type GoogleCloudAiplatformV1beta1Model struct { // ModelSourceInfo: Output only. Source of a model. It can either be // automl training pipeline, custom training pipeline, BigQuery ML, or - // existing Vertex AI Model. + // saved and tuned from Genie or Model Garden. ModelSourceInfo *GoogleCloudAiplatformV1beta1ModelSourceInfo `json:"modelSourceInfo,omitempty"` // Name: The resource name of the Model. @@ -20726,6 +20729,16 @@ type GoogleCloudAiplatformV1beta1NearestNeighborSearchOperationMetadataRecordErr // "EMBEDDING_SIZE_MISMATCH" - The size of the embedding vectors does // not match with the specified dimension. // "NAMESPACE_MISSING" - The `namespace` field is missing. + // "PARSING_ERROR" - Generic catch-all error. Only used for validation + // failure where the root cause cannot be easily retrieved + // programmatically. + // "DUPLICATE_NAMESPACE" - There are multiple restricts with the same + // `namespace` value. + // "OP_IN_DATAPOINT" - Numeric restrict has operator specified in + // datapoint. + // "MULTIPLE_VALUES" - Numeric restrict has multiple values specified. + // "INVALID_NUMERIC_VALUE" - Numeric restrict has invalid numeric + // value specified. ErrorType string `json:"errorType,omitempty"` // RawRecord: The original content of this record. @@ -21786,6 +21799,12 @@ func (s *GoogleCloudAiplatformV1beta1PipelineJobDetail) MarshalJSON() ([]byte, e // GoogleCloudAiplatformV1beta1PipelineJobRuntimeConfig: The runtime // config of a PipelineJob. type GoogleCloudAiplatformV1beta1PipelineJobRuntimeConfig struct { + // DefaultRuntime: Optional. The default runtime for the PipelineJob. If + // not provided, Vertex Custom Job is used as the runtime. For Vertex + // Custom Job, please refer to + // https://cloud.google.com/vertex-ai/docs/training/overview + DefaultRuntime *GoogleCloudAiplatformV1beta1PipelineJobRuntimeConfigDefaultRuntime `json:"defaultRuntime,omitempty"` + // FailurePolicy: Represents the failure policy of a pipeline. // Currently, the default of a pipeline is that the pipeline will // continue to run until no more tasks can be executed, also known as @@ -21835,7 +21854,7 @@ type GoogleCloudAiplatformV1beta1PipelineJobRuntimeConfig struct { // pipelines built using Kubeflow Pipelines SDK 1.8 or lower. Parameters map[string]GoogleCloudAiplatformV1beta1Value `json:"parameters,omitempty"` - // ForceSendFields is a list of field names (e.g. "FailurePolicy") to + // ForceSendFields is a list of field names (e.g. "DefaultRuntime") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -21843,12 +21862,13 @@ type GoogleCloudAiplatformV1beta1PipelineJobRuntimeConfig struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "FailurePolicy") to include - // in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. However, any field with - // an empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "DefaultRuntime") to + // include in API requests with the JSON null value. By default, fields + // with empty values are omitted from API requests. However, any field + // with an empty value appearing in NullFields will be sent to the + // server as null. It is an error if a field in this list has a + // non-empty value. This may be used to include null fields in Patch + // requests. NullFields []string `json:"-"` } @@ -21858,6 +21878,38 @@ func (s *GoogleCloudAiplatformV1beta1PipelineJobRuntimeConfig) MarshalJSON() ([] return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } +// GoogleCloudAiplatformV1beta1PipelineJobRuntimeConfigDefaultRuntime: +// The default runtime for the PipelineJob. +type GoogleCloudAiplatformV1beta1PipelineJobRuntimeConfigDefaultRuntime struct { + // PersistentResourceRuntimeDetail: Persistent resource based runtime + // detail. + PersistentResourceRuntimeDetail *GoogleCloudAiplatformV1beta1PipelineJobRuntimeConfigPersistentResourceRuntimeDetail `json:"persistentResourceRuntimeDetail,omitempty"` + + // ForceSendFields is a list of field names (e.g. + // "PersistentResourceRuntimeDetail") to unconditionally include in API + // requests. By default, fields with empty or default values are omitted + // from API requests. However, any non-pointer, non-interface field + // appearing in ForceSendFields will be sent to the server regardless of + // whether the field is empty or not. This may be used to include empty + // fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. + // "PersistentResourceRuntimeDetail") to include in API requests with + // the JSON null value. By default, fields with empty values are omitted + // from API requests. However, any field with an empty value appearing + // in NullFields will be sent to the server as null. It is an error if a + // field in this list has a non-empty value. This may be used to include + // null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudAiplatformV1beta1PipelineJobRuntimeConfigDefaultRuntime) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudAiplatformV1beta1PipelineJobRuntimeConfigDefaultRuntime + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + // GoogleCloudAiplatformV1beta1PipelineJobRuntimeConfigInputArtifact: // The type of an input artifact. type GoogleCloudAiplatformV1beta1PipelineJobRuntimeConfigInputArtifact struct { @@ -21891,6 +21943,41 @@ func (s *GoogleCloudAiplatformV1beta1PipelineJobRuntimeConfigInputArtifact) Mars return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } +// GoogleCloudAiplatformV1beta1PipelineJobRuntimeConfigPersistentResource +// RuntimeDetail: Persistent resource based runtime detail. For more +// information, refer to +// https://cloud.google.com/vertex-ai/docs/training/persistent-resource-overview +type GoogleCloudAiplatformV1beta1PipelineJobRuntimeConfigPersistentResourceRuntimeDetail struct { + // PersistentResourceName: Persistent resource name. Format: + // `projects/{project}/locations/{location}/persistentResources/{persiste + // nt_resource}` + PersistentResourceName string `json:"persistentResourceName,omitempty"` + + // ForceSendFields is a list of field names (e.g. + // "PersistentResourceName") to unconditionally include in API requests. + // By default, fields with empty or default values are omitted from API + // requests. However, any non-pointer, non-interface field appearing in + // ForceSendFields will be sent to the server regardless of whether the + // field is empty or not. This may be used to include empty fields in + // Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "PersistentResourceName") + // to include in API requests with the JSON null value. By default, + // fields with empty values are omitted from API requests. However, any + // field with an empty value appearing in NullFields will be sent to the + // server as null. It is an error if a field in this list has a + // non-empty value. This may be used to include null fields in Patch + // requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudAiplatformV1beta1PipelineJobRuntimeConfigPersistentResourceRuntimeDetail) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudAiplatformV1beta1PipelineJobRuntimeConfigPersistentResourceRuntimeDetail + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + // GoogleCloudAiplatformV1beta1PipelineTaskDetail: The runtime detail of // a task execution. type GoogleCloudAiplatformV1beta1PipelineTaskDetail struct { @@ -24281,9 +24368,8 @@ type GoogleCloudAiplatformV1beta1ReportExecutionEventResponse struct { googleapi.ServerResponse `json:"-"` } -// GoogleCloudAiplatformV1beta1ReportRuntimeEventRequest: -// LINT.IfChange(report_event_message_types) Request message for -// NotebookInternalService.ReportRuntimeEvent. +// GoogleCloudAiplatformV1beta1ReportRuntimeEventRequest: Request +// message for NotebookInternalService.ReportRuntimeEvent. type GoogleCloudAiplatformV1beta1ReportRuntimeEventRequest struct { // EventDetails: Optional. The details of the request for debug. EventDetails map[string]string `json:"eventDetails,omitempty"` @@ -36666,6 +36752,9 @@ type GoogleCloudAiplatformV1beta1UpdatePersistentResourceOperationMetadata struc // GenericMetadata: Operation metadata for PersistentResource. GenericMetadata *GoogleCloudAiplatformV1beta1GenericOperationMetadata `json:"genericMetadata,omitempty"` + // ProgressMessage: Progress Message for Update LRO + ProgressMessage string `json:"progressMessage,omitempty"` + // ForceSendFields is a list of field names (e.g. "GenericMetadata") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any @@ -38389,7 +38478,7 @@ func (s *IntelligenceCloudAutomlXpsReportingMetrics) MarshalJSON() ([]byte, erro // most applicable for that document's datasource. For example, a // Wikipedia article's attribution is in the form of its article title, // a website is in the form of a URL, and a Github repo is in the form -// of a repo name. Next id:28 +// of a repo name. Next id: 30 type LanguageLabsAidaTrustRecitationProtoDocAttribution struct { AmarnaId string `json:"amarnaId,omitempty"` @@ -38399,6 +38488,10 @@ type LanguageLabsAidaTrustRecitationProtoDocAttribution struct { Bibkey string `json:"bibkey,omitempty"` + // BiorxivId: ID of the paper in bioarxiv like ddoi.org/{biorxiv_id} eg: + // https://doi.org/10.1101/343517 + BiorxivId string `json:"biorxivId,omitempty"` + BookTitle string `json:"bookTitle,omitempty"` // BookVolumeId: The Oceanographers full-view books dataset uses a @@ -38898,6 +38991,10 @@ type LanguageLabsAidaTrustRecitationProtoDocAttribution struct { // dataset. WikipediaArticleTitle string `json:"wikipediaArticleTitle,omitempty"` + // YoutubeVideoId: The unique video id from Youtube. Example: + // AkoGsW52Ir0 + YoutubeVideoId string `json:"youtubeVideoId,omitempty"` + // ForceSendFields is a list of field names (e.g. "AmarnaId") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any @@ -39519,7 +39616,7 @@ func (s *LanguageLabsAidaTrustRecitationProtoStreamRecitationResult) MarshalJSON // applicable for that document's datasource. For example, a Wikipedia // article's attribution is in the form of its article title, a website // is in the form of a URL, and a Github repo is in the form of a repo -// name. Next id: 28 +// name. Next id: 30 type LearningGenaiRecitationDocAttribution struct { AmarnaId string `json:"amarnaId,omitempty"` @@ -39529,6 +39626,10 @@ type LearningGenaiRecitationDocAttribution struct { Bibkey string `json:"bibkey,omitempty"` + // BiorxivId: ID of the paper in bioarxiv like ddoi.org/{biorxiv_id} eg: + // https://doi.org/10.1101/343517 + BiorxivId string `json:"biorxivId,omitempty"` + BookTitle string `json:"bookTitle,omitempty"` // BookVolumeId: The Oceanographers full-view books dataset uses a @@ -40019,6 +40120,8 @@ type LearningGenaiRecitationDocAttribution struct { // dataset. WikipediaArticleTitle string `json:"wikipediaArticleTitle,omitempty"` + YoutubeVideoId string `json:"youtubeVideoId,omitempty"` + // ForceSendFields is a list of field names (e.g. "AmarnaId") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any @@ -40865,7 +40968,7 @@ type LearningGenaiRootFilterMetadataFilterDebugInfo struct { DefaultMetadata string `json:"defaultMetadata,omitempty"` - LanguageFilterResult *LearningServingLlmLanguageFilterResult `json:"languageFilterResult,omitempty"` + LanguageFilterResult *LearningGenaiRootLanguageFilterResult `json:"languageFilterResult,omitempty"` // RaiOutput: Safety filter output information for LLM Root RAI harm // check. @@ -40905,6 +41008,92 @@ func (s *LearningGenaiRootFilterMetadataFilterDebugInfo) MarshalJSON() ([]byte, return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } +type LearningGenaiRootGroundingMetadata struct { + Citations []*LearningGenaiRootGroundingMetadataCitation `json:"citations,omitempty"` + + // GroundingCancelled: True if grounding is cancelled, for example, no + // facts being retrieved. + GroundingCancelled bool `json:"groundingCancelled,omitempty"` + + SearchQueries []string `json:"searchQueries,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Citations") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "Citations") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *LearningGenaiRootGroundingMetadata) MarshalJSON() ([]byte, error) { + type NoMethod LearningGenaiRootGroundingMetadata + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +type LearningGenaiRootGroundingMetadataCitation struct { + // EndIndex: Index in the prediction output where the citation ends + // (exclusive). Must be > start_index and < len(output). + EndIndex int64 `json:"endIndex,omitempty"` + + // FactIndex: Index of the fact supporting this claim. Should be within + // the range of the `world_facts` in the GenerateResponse. + FactIndex int64 `json:"factIndex,omitempty"` + + // Score: Confidence score of this entailment. Value is [0,1] with 1 is + // the most confidence. + Score float64 `json:"score,omitempty"` + + // StartIndex: Index in the prediction output where the citation starts + // (inclusive). Must be >= 0 and < end_index. + StartIndex int64 `json:"startIndex,omitempty"` + + // ForceSendFields is a list of field names (e.g. "EndIndex") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "EndIndex") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *LearningGenaiRootGroundingMetadataCitation) MarshalJSON() ([]byte, error) { + type NoMethod LearningGenaiRootGroundingMetadataCitation + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +func (s *LearningGenaiRootGroundingMetadataCitation) UnmarshalJSON(data []byte) error { + type NoMethod LearningGenaiRootGroundingMetadataCitation + var s1 struct { + Score gensupport.JSONFloat64 `json:"score"` + *NoMethod + } + s1.NoMethod = (*NoMethod)(s) + if err := json.Unmarshal(data, &s1); err != nil { + return err + } + s.Score = float64(s1.Score) + return nil +} + type LearningGenaiRootHarm struct { // ContextualDangerous: Please do not use, this is still under // development. @@ -41171,6 +41360,55 @@ func (s *LearningGenaiRootInternalMetadata) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } +type LearningGenaiRootLanguageFilterResult struct { + // Allowed: False when query or response should be filtered out due to + // unsupported language. + Allowed bool `json:"allowed,omitempty"` + + // DetectedLanguage: Language of the query or response. + DetectedLanguage string `json:"detectedLanguage,omitempty"` + + // DetectedLanguageProbability: Probability of the language predicted as + // returned by LangID. + DetectedLanguageProbability float64 `json:"detectedLanguageProbability,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Allowed") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "Allowed") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *LearningGenaiRootLanguageFilterResult) MarshalJSON() ([]byte, error) { + type NoMethod LearningGenaiRootLanguageFilterResult + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +func (s *LearningGenaiRootLanguageFilterResult) UnmarshalJSON(data []byte) error { + type NoMethod LearningGenaiRootLanguageFilterResult + var s1 struct { + DetectedLanguageProbability gensupport.JSONFloat64 `json:"detectedLanguageProbability"` + *NoMethod + } + s1.NoMethod = (*NoMethod)(s) + if err := json.Unmarshal(data, &s1); err != nil { + return err + } + s.DetectedLanguageProbability = float64(s1.DetectedLanguageProbability) + return nil +} + type LearningGenaiRootMetricOutput struct { Debug string `json:"debug,omitempty"` @@ -42107,55 +42345,6 @@ func (s *LearningGenaiRootToxicitySignal) UnmarshalJSON(data []byte) error { return nil } -type LearningServingLlmLanguageFilterResult struct { - // Allowed: False when query or response should be filtered out due to - // unsupported language. - Allowed bool `json:"allowed,omitempty"` - - // DetectedLanguage: Language of the query or response. - DetectedLanguage string `json:"detectedLanguage,omitempty"` - - // DetectedLanguageProbability: Probability of the language predicted as - // returned by LangID. - DetectedLanguageProbability float64 `json:"detectedLanguageProbability,omitempty"` - - // ForceSendFields is a list of field names (e.g. "Allowed") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. - ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Allowed") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. - NullFields []string `json:"-"` -} - -func (s *LearningServingLlmLanguageFilterResult) MarshalJSON() ([]byte, error) { - type NoMethod LearningServingLlmLanguageFilterResult - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) -} - -func (s *LearningServingLlmLanguageFilterResult) UnmarshalJSON(data []byte) error { - type NoMethod LearningServingLlmLanguageFilterResult - var s1 struct { - DetectedLanguageProbability gensupport.JSONFloat64 `json:"detectedLanguageProbability"` - *NoMethod - } - s1.NoMethod = (*NoMethod)(s) - if err := json.Unmarshal(data, &s1); err != nil { - return err - } - s.DetectedLanguageProbability = float64(s1.DetectedLanguageProbability) - return nil -} - // LearningServingLlmMessageMetadata: LINT.IfChange This metadata // contains additional information required for debugging. type LearningServingLlmMessageMetadata struct { @@ -42189,6 +42378,8 @@ type LearningServingLlmMessageMetadata struct { // "FILTER" - Finished due to triggering some post-processing filter. FinishReason string `json:"finishReason,omitempty"` + GroundingMetadata *LearningGenaiRootGroundingMetadata `json:"groundingMetadata,omitempty"` + // IsFallback: Applies to Response message only. Indicates whether the // message is a fallback and the response would have otherwise been // empty. @@ -66606,7 +66797,7 @@ type ProjectsLocationsFeatureOnlineStoresCreateCall struct { // // - parent: The resource name of the Location to create // FeatureOnlineStores. Format: -// `projects/{project}/locations/{location}'`. +// `projects/{project}/locations/{location}`. func (r *ProjectsLocationsFeatureOnlineStoresService) Create(parent string, googlecloudaiplatformv1beta1featureonlinestore *GoogleCloudAiplatformV1beta1FeatureOnlineStore) *ProjectsLocationsFeatureOnlineStoresCreateCall { c := &ProjectsLocationsFeatureOnlineStoresCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.parent = parent @@ -66731,7 +66922,7 @@ func (c *ProjectsLocationsFeatureOnlineStoresCreateCall) Do(opts ...googleapi.Ca // "type": "string" // }, // "parent": { - // "description": "Required. The resource name of the Location to create FeatureOnlineStores. Format: `projects/{project}/locations/{location}'`", + // "description": "Required. The resource name of the Location to create FeatureOnlineStores. Format: `projects/{project}/locations/{location}`", // "location": "path", // "pattern": "^projects/[^/]+/locations/[^/]+$", // "required": true, diff --git a/apigee/v1/apigee-api.json b/apigee/v1/apigee-api.json index ba9e835410d..ac09cce6277 100644 --- a/apigee/v1/apigee-api.json +++ b/apigee/v1/apigee-api.json @@ -9814,7 +9814,7 @@ } } }, - "revision": "20240112", + "revision": "20240122", "rootUrl": "https://apigee.googleapis.com/", "schemas": { "EdgeConfigstoreBundleBadBundle": { @@ -16090,7 +16090,7 @@ "id": "GoogleCloudApigeeV1SecurityActionConditionConfig", "properties": { "botReasons": { - "description": "Optional. A list of Bot Reasons. Current options: Flooder, Brute Guessor, Static Content Scraper, OAuth Abuser, Robot Abuser, TorListRule, Advanced Anomaly Detection, Advanced API Scraper, Search Engine Crawlers, Public Cloud, Public Cloud AWS, Public Cloud Azure, and Public Cloud GCP.", + "description": "Optional. A list of Bot Reasons. Current options: Flooder, Brute Guessor, Static Content Scraper, OAuth Abuser, Robot Abuser, TorListRule, Advanced Anomaly Detection, Advanced API Scraper, Search Engine Crawlers, Public Clouds, Public Cloud AWS, Public Cloud Azure, and Public Cloud Google.", "items": { "type": "string" }, @@ -17357,7 +17357,7 @@ "type": "array" }, "role": { - "description": "Role that is assigned to the list of `members`, or principals. For example, `roles/viewer`, `roles/editor`, or `roles/owner`.", + "description": "Role that is assigned to the list of `members`, or principals. For example, `roles/viewer`, `roles/editor`, or `roles/owner`. For an overview of the IAM roles and permissions, see the [IAM documentation](https://cloud.google.com/iam/docs/roles-overview). For a list of the available pre-defined roles, see [here](https://cloud.google.com/iam/docs/understanding-roles).", "type": "string" } }, diff --git a/apigee/v1/apigee-gen.go b/apigee/v1/apigee-gen.go index c0854fd6065..d474bded7cc 100644 --- a/apigee/v1/apigee-gen.go +++ b/apigee/v1/apigee-gen.go @@ -10946,8 +10946,8 @@ type GoogleCloudApigeeV1SecurityActionConditionConfig struct { // BotReasons: Optional. A list of Bot Reasons. Current options: // Flooder, Brute Guessor, Static Content Scraper, OAuth Abuser, Robot // Abuser, TorListRule, Advanced Anomaly Detection, Advanced API - // Scraper, Search Engine Crawlers, Public Cloud, Public Cloud AWS, - // Public Cloud Azure, and Public Cloud GCP. + // Scraper, Search Engine Crawlers, Public Clouds, Public Cloud AWS, + // Public Cloud Azure, and Public Cloud Google. BotReasons []string `json:"botReasons,omitempty"` // IpAddressRanges: Optional. A list of IP addresses. This could be @@ -13092,7 +13092,11 @@ type GoogleIamV1Binding struct { Members []string `json:"members,omitempty"` // Role: Role that is assigned to the list of `members`, or principals. - // For example, `roles/viewer`, `roles/editor`, or `roles/owner`. + // For example, `roles/viewer`, `roles/editor`, or `roles/owner`. For an + // overview of the IAM roles and permissions, see the IAM documentation + // (https://cloud.google.com/iam/docs/roles-overview). For a list of the + // available pre-defined roles, see here + // (https://cloud.google.com/iam/docs/understanding-roles). Role string `json:"role,omitempty"` // ForceSendFields is a list of field names (e.g. "Condition") to diff --git a/cloudsupport/v2beta/cloudsupport-api.json b/cloudsupport/v2beta/cloudsupport-api.json index 609d8894016..0a39e2cf1f3 100644 --- a/cloudsupport/v2beta/cloudsupport-api.json +++ b/cloudsupport/v2beta/cloudsupport-api.json @@ -283,6 +283,21 @@ "pattern": "^[^/]+/[^/]+$", "required": true, "type": "string" + }, + "productLine": { + "description": "The product line to request cases for.", + "enum": [ + "PRODUCT_LINE_UNSPECIFIED", + "GOOGLE_CLOUD", + "GOOGLE_MAPS" + ], + "enumDescriptions": [ + "Unknown product type.", + "Google Cloud", + "Google Maps" + ], + "location": "query", + "type": "string" } }, "path": "v2beta/{+parent}/cases", @@ -548,7 +563,7 @@ } } }, - "revision": "20231217", + "revision": "20240120", "rootUrl": "https://cloudsupport.googleapis.com/", "schemas": { "Actor": { @@ -783,6 +798,10 @@ "id": { "description": "The unique ID for a classification. Must be specified for case creation. To retrieve valid classification IDs for case creation, use `caseClassifications.search`. Classification IDs returned by `caseClassifications.search` are guaranteed to be valid for at least 6 months. If a given classification is deactiveated, it will immediately stop being returned. After 6 months, `case.create` requests using the classification ID will fail.", "type": "string" + }, + "product": { + "$ref": "Product", + "description": "The full product the classification corresponds to." } }, "type": "object" @@ -1328,6 +1347,31 @@ }, "type": "object" }, + "Product": { + "description": "The full product a case may be associated with, including Product Line and Product Subline.", + "id": "Product", + "properties": { + "productLine": { + "description": "The Product Line of the Product.", + "enum": [ + "PRODUCT_LINE_UNSPECIFIED", + "GOOGLE_CLOUD", + "GOOGLE_MAPS" + ], + "enumDescriptions": [ + "Unknown product type.", + "Google Cloud", + "Google Maps" + ], + "type": "string" + }, + "productSubline": { + "description": "The Product Subline of the Product, such as \"Maps Billing\".", + "type": "string" + } + }, + "type": "object" + }, "SearchCaseClassificationsResponse": { "description": "The response message for SearchCaseClassifications endpoint.", "id": "SearchCaseClassificationsResponse", diff --git a/cloudsupport/v2beta/cloudsupport-gen.go b/cloudsupport/v2beta/cloudsupport-gen.go index 5a5e0e9e9ac..aab34163885 100644 --- a/cloudsupport/v2beta/cloudsupport-gen.go +++ b/cloudsupport/v2beta/cloudsupport-gen.go @@ -526,6 +526,9 @@ type CaseClassification struct { // requests using the classification ID will fail. Id string `json:"id,omitempty"` + // Product: The full product the classification corresponds to. + Product *Product `json:"product,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. However, any @@ -1332,6 +1335,44 @@ func (s *ObjectId) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } +// Product: The full product a case may be associated with, including +// Product Line and Product Subline. +type Product struct { + // ProductLine: The Product Line of the Product. + // + // Possible values: + // "PRODUCT_LINE_UNSPECIFIED" - Unknown product type. + // "GOOGLE_CLOUD" - Google Cloud + // "GOOGLE_MAPS" - Google Maps + ProductLine string `json:"productLine,omitempty"` + + // ProductSubline: The Product Subline of the Product, such as "Maps + // Billing". + ProductSubline string `json:"productSubline,omitempty"` + + // ForceSendFields is a list of field names (e.g. "ProductLine") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "ProductLine") to include + // in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. However, any field with + // an empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *Product) MarshalJSON() ([]byte, error) { + type NoMethod Product + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + // SearchCaseClassificationsResponse: The response message for // SearchCaseClassifications endpoint. type SearchCaseClassificationsResponse struct { @@ -2375,6 +2416,19 @@ func (c *CasesListCall) PageToken(pageToken string) *CasesListCall { return c } +// ProductLine sets the optional parameter "productLine": The product +// line to request cases for. +// +// Possible values: +// +// "PRODUCT_LINE_UNSPECIFIED" - Unknown product type. +// "GOOGLE_CLOUD" - Google Cloud +// "GOOGLE_MAPS" - Google Maps +func (c *CasesListCall) ProductLine(productLine string) *CasesListCall { + c.urlParams_.Set("productLine", productLine) + return c +} + // Fields allows partial responses to be retrieved. See // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse // for more information. @@ -2504,6 +2558,21 @@ func (c *CasesListCall) Do(opts ...googleapi.CallOption) (*ListCasesResponse, er // "pattern": "^[^/]+/[^/]+$", // "required": true, // "type": "string" + // }, + // "productLine": { + // "description": "The product line to request cases for.", + // "enum": [ + // "PRODUCT_LINE_UNSPECIFIED", + // "GOOGLE_CLOUD", + // "GOOGLE_MAPS" + // ], + // "enumDescriptions": [ + // "Unknown product type.", + // "Google Cloud", + // "Google Maps" + // ], + // "location": "query", + // "type": "string" // } // }, // "path": "v2beta/{+parent}/cases", diff --git a/discoveryengine/v1alpha/discoveryengine-api.json b/discoveryengine/v1alpha/discoveryengine-api.json index 5c9c6c9f87d..1e4d81b3795 100644 --- a/discoveryengine/v1alpha/discoveryengine-api.json +++ b/discoveryengine/v1alpha/discoveryengine-api.json @@ -360,7 +360,7 @@ "type": "string" }, "queryModel": { - "description": "Selects data model of query suggestions for serving. Currently supported values: * `document` - Using suggestions generated from user-imported documents. * `search-history` - Using suggestions generated from the past history of SearchService.Search API calls. Do not use it when there is no traffic for Search API. * `user-event` - Using suggestions generated from user-imported search events. * `document-completable` - Using suggestions taken directly from user-imported document fields marked as completable. Default values: * `document` is the default model for regular dataStores. * `search-history` is the default model for site search dataStores.", + "description": "Specifies the autocomplete data model. This overrides any model specified in the Configuration \u003e Autocomplete section of the Cloud console. Currently supported values: * `document` - Using suggestions generated from user-imported documents. * `search-history` - Using suggestions generated from the past history of SearchService.Search API calls. Do not use it when there is no traffic for Search API. * `user-event` - Using suggestions generated from user-imported search events. * `document-completable` - Using suggestions taken directly from user-imported document fields marked as completable. Default values: * `document` is the default model for regular dataStores. * `search-history` is the default model for site search dataStores.", "location": "query", "type": "string" }, @@ -2893,7 +2893,7 @@ "type": "string" }, "queryModel": { - "description": "Selects data model of query suggestions for serving. Currently supported values: * `document` - Using suggestions generated from user-imported documents. * `search-history` - Using suggestions generated from the past history of SearchService.Search API calls. Do not use it when there is no traffic for Search API. * `user-event` - Using suggestions generated from user-imported search events. * `document-completable` - Using suggestions taken directly from user-imported document fields marked as completable. Default values: * `document` is the default model for regular dataStores. * `search-history` is the default model for site search dataStores.", + "description": "Specifies the autocomplete data model. This overrides any model specified in the Configuration \u003e Autocomplete section of the Cloud console. Currently supported values: * `document` - Using suggestions generated from user-imported documents. * `search-history` - Using suggestions generated from the past history of SearchService.Search API calls. Do not use it when there is no traffic for Search API. * `user-event` - Using suggestions generated from user-imported search events. * `document-completable` - Using suggestions taken directly from user-imported document fields marked as completable. Default values: * `document` is the default model for regular dataStores. * `search-history` is the default model for site search dataStores.", "location": "query", "type": "string" }, @@ -4596,7 +4596,7 @@ } } }, - "revision": "20240111", + "revision": "20240118", "rootUrl": "https://discoveryengine.googleapis.com/", "schemas": { "GoogleApiHttpBody": { @@ -4745,9 +4745,9 @@ }, "type": "object" }, - "GoogleCloudDiscoveryengineV1CreateSchemaMetadata": { - "description": "Metadata for Create Schema LRO.", - "id": "GoogleCloudDiscoveryengineV1CreateSchemaMetadata", + "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", "properties": { "createTime": { "description": "Operation create time.", @@ -4762,9 +4762,23 @@ }, "type": "object" }, - "GoogleCloudDiscoveryengineV1DeleteSchemaMetadata": { - "description": "Metadata for DeleteSchema LRO.", - "id": "GoogleCloudDiscoveryengineV1DeleteSchemaMetadata", + "GoogleCloudDiscoveryengineV1BatchCreateTargetSitesResponse": { + "description": "Response message for SiteSearchEngineService.BatchCreateTargetSites method.", + "id": "GoogleCloudDiscoveryengineV1BatchCreateTargetSitesResponse", + "properties": { + "targetSites": { + "description": "TargetSites created.", + "items": { + "$ref": "GoogleCloudDiscoveryengineV1TargetSite" + }, + "type": "array" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1CreateDataStoreMetadata": { + "description": "Metadata related to the progress of the DataStoreService.CreateDataStore operation. This will be returned by the google.longrunning.Operation.metadata field.", + "id": "GoogleCloudDiscoveryengineV1CreateDataStoreMetadata", "properties": { "createTime": { "description": "Operation create time.", @@ -4779,25 +4793,15 @@ }, "type": "object" }, - "GoogleCloudDiscoveryengineV1ImportDocumentsMetadata": { - "description": "Metadata related to the progress of the ImportDocuments operation. This is returned by the google.longrunning.Operation.metadata field.", - "id": "GoogleCloudDiscoveryengineV1ImportDocumentsMetadata", + "GoogleCloudDiscoveryengineV1CreateEngineMetadata": { + "description": "Metadata related to the progress of the EngineService.CreateEngine operation. This will be returned by the google.longrunning.Operation.metadata field.", + "id": "GoogleCloudDiscoveryengineV1CreateEngineMetadata", "properties": { "createTime": { "description": "Operation create time.", "format": "google-datetime", "type": "string" }, - "failureCount": { - "description": "Count of entries that encountered errors while processing.", - "format": "int64", - "type": "string" - }, - "successCount": { - "description": "Count of entries that were processed successfully.", - "format": "int64", - "type": "string" - }, "updateTime": { "description": "Operation last update time. If the operation is done, this is also the finish time.", "format": "google-datetime", @@ -4806,38 +4810,26 @@ }, "type": "object" }, - "GoogleCloudDiscoveryengineV1ImportDocumentsResponse": { - "description": "Response of the ImportDocumentsRequest. If the long running operation is done, then this message is returned by the google.longrunning.Operations.response field if the operation was successful.", - "id": "GoogleCloudDiscoveryengineV1ImportDocumentsResponse", + "GoogleCloudDiscoveryengineV1CreateSchemaMetadata": { + "description": "Metadata for Create Schema LRO.", + "id": "GoogleCloudDiscoveryengineV1CreateSchemaMetadata", "properties": { - "errorConfig": { - "$ref": "GoogleCloudDiscoveryengineV1ImportErrorConfig", - "description": "Echoes the destination for the complete errors in the request if set." + "createTime": { + "description": "Operation create time.", + "format": "google-datetime", + "type": "string" }, - "errorSamples": { - "description": "A sample of errors encountered while processing the request.", - "items": { - "$ref": "GoogleRpcStatus" - }, - "type": "array" - } - }, - "type": "object" - }, - "GoogleCloudDiscoveryengineV1ImportErrorConfig": { - "description": "Configuration of destination for Import related errors.", - "id": "GoogleCloudDiscoveryengineV1ImportErrorConfig", - "properties": { - "gcsPrefix": { - "description": "Cloud Storage prefix for import errors. This must be an empty, existing Cloud Storage directory. Import errors are written to sharded files in this directory, one per line, as a JSON-encoded `google.rpc.Status` message.", + "updateTime": { + "description": "Operation last update time. If the operation is done, this is also the finish time.", + "format": "google-datetime", "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1ImportSuggestionDenyListEntriesMetadata": { - "description": "Metadata related to the progress of the ImportSuggestionDenyListEntries operation. This is returned by the google.longrunning.Operation.metadata field.", - "id": "GoogleCloudDiscoveryengineV1ImportSuggestionDenyListEntriesMetadata", + "GoogleCloudDiscoveryengineV1CreateTargetSiteMetadata": { + "description": "Metadata related to the progress of the SiteSearchEngineService.CreateTargetSite operation. This will be returned by the google.longrunning.Operation.metadata field.", + "id": "GoogleCloudDiscoveryengineV1CreateTargetSiteMetadata", "properties": { "createTime": { "description": "Operation create time.", @@ -4852,49 +4844,90 @@ }, "type": "object" }, - "GoogleCloudDiscoveryengineV1ImportSuggestionDenyListEntriesResponse": { - "description": "Response message for CompletionService.ImportSuggestionDenyListEntries method.", - "id": "GoogleCloudDiscoveryengineV1ImportSuggestionDenyListEntriesResponse", + "GoogleCloudDiscoveryengineV1DataStore": { + "description": "DataStore captures global settings and configs at the DataStore level.", + "id": "GoogleCloudDiscoveryengineV1DataStore", "properties": { - "errorSamples": { - "description": "A sample of errors encountered while processing the request.", - "items": { - "$ref": "GoogleRpcStatus" - }, - "type": "array" + "contentConfig": { + "description": "Immutable. The content config of the data store. If this field is unset, the server behavior defaults to ContentConfig.NO_CONTENT.", + "enum": [ + "CONTENT_CONFIG_UNSPECIFIED", + "NO_CONTENT", + "CONTENT_REQUIRED", + "PUBLIC_WEBSITE" + ], + "enumDescriptions": [ + "Default value.", + "Only contains documents without any Document.content.", + "Only contains documents with Document.content.", + "The data store is used for public website search." + ], + "type": "string" }, - "failedEntriesCount": { - "description": "Count of deny list entries that failed to be imported.", - "format": "int64", + "createTime": { + "description": "Output only. Timestamp the DataStore was created at.", + "format": "google-datetime", + "readOnly": true, "type": "string" }, - "importedEntriesCount": { - "description": "Count of deny list entries successfully imported.", - "format": "int64", + "defaultSchemaId": { + "description": "Output only. The id of the default Schema asscociated to this data store.", + "readOnly": true, + "type": "string" + }, + "displayName": { + "description": "Required. The data store display name. This field must be a UTF-8 encoded string with a length limit of 128 characters. Otherwise, an INVALID_ARGUMENT error is returned.", + "type": "string" + }, + "industryVertical": { + "description": "Immutable. The industry vertical that the data store registers.", + "enum": [ + "INDUSTRY_VERTICAL_UNSPECIFIED", + "GENERIC", + "MEDIA" + ], + "enumDescriptions": [ + "Value used when unset.", + "The generic vertical for documents that are not specific to any industry vertical.", + "The media industry vertical." + ], + "type": "string" + }, + "name": { + "description": "Immutable. The full resource name of the data store. Format: `projects/{project}/locations/{location}/collections/{collection_id}/dataStores/{data_store_id}`. This field must be a UTF-8 encoded string with a length limit of 1024 characters.", "type": "string" + }, + "solutionTypes": { + "description": "The solutions that the data store enrolls. Available solutions for each industry_vertical: * `MEDIA`: `SOLUTION_TYPE_RECOMMENDATION` and `SOLUTION_TYPE_SEARCH`. * `SITE_SEARCH`: `SOLUTION_TYPE_SEARCH` is automatically enrolled. Other solutions cannot be enrolled.", + "items": { + "enum": [ + "SOLUTION_TYPE_UNSPECIFIED", + "SOLUTION_TYPE_RECOMMENDATION", + "SOLUTION_TYPE_SEARCH", + "SOLUTION_TYPE_CHAT" + ], + "enumDescriptions": [ + "Default value.", + "Used for Recommendations AI.", + "Used for Discovery Search.", + "Used for use cases related to the Generative AI agent." + ], + "type": "string" + }, + "type": "array" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1ImportUserEventsMetadata": { - "description": "Metadata related to the progress of the Import operation. This is returned by the google.longrunning.Operation.metadata field.", - "id": "GoogleCloudDiscoveryengineV1ImportUserEventsMetadata", + "GoogleCloudDiscoveryengineV1DeleteDataStoreMetadata": { + "description": "Metadata related to the progress of the DataStoreService.DeleteDataStore operation. This will be returned by the google.longrunning.Operation.metadata field.", + "id": "GoogleCloudDiscoveryengineV1DeleteDataStoreMetadata", "properties": { "createTime": { "description": "Operation create time.", "format": "google-datetime", "type": "string" }, - "failureCount": { - "description": "Count of entries that encountered errors while processing.", - "format": "int64", - "type": "string" - }, - "successCount": { - "description": "Count of entries that were processed successfully.", - "format": "int64", - "type": "string" - }, "updateTime": { "description": "Operation last update time. If the operation is done, this is also the finish time.", "format": "google-datetime", @@ -4903,53 +4936,32 @@ }, "type": "object" }, - "GoogleCloudDiscoveryengineV1ImportUserEventsResponse": { - "description": "Response of the ImportUserEventsRequest. If the long running operation was successful, then this message is returned by the google.longrunning.Operations.response field if the operation was successful.", - "id": "GoogleCloudDiscoveryengineV1ImportUserEventsResponse", + "GoogleCloudDiscoveryengineV1DeleteEngineMetadata": { + "description": "Metadata related to the progress of the EngineService.DeleteEngine operation. This will be returned by the google.longrunning.Operation.metadata field.", + "id": "GoogleCloudDiscoveryengineV1DeleteEngineMetadata", "properties": { - "errorConfig": { - "$ref": "GoogleCloudDiscoveryengineV1ImportErrorConfig", - "description": "Echoes the destination for the complete errors if this field was set in the request." - }, - "errorSamples": { - "description": "A sample of errors encountered while processing the request.", - "items": { - "$ref": "GoogleRpcStatus" - }, - "type": "array" - }, - "joinedEventsCount": { - "description": "Count of user events imported with complete existing Documents.", - "format": "int64", + "createTime": { + "description": "Operation create time.", + "format": "google-datetime", "type": "string" }, - "unjoinedEventsCount": { - "description": "Count of user events imported, but with Document information not found in the existing Branch.", - "format": "int64", + "updateTime": { + "description": "Operation last update time. If the operation is done, this is also the finish time.", + "format": "google-datetime", "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1PurgeDocumentsMetadata": { - "description": "Metadata related to the progress of the PurgeDocuments operation. This will be returned by the google.longrunning.Operation.metadata field.", - "id": "GoogleCloudDiscoveryengineV1PurgeDocumentsMetadata", + "GoogleCloudDiscoveryengineV1DeleteSchemaMetadata": { + "description": "Metadata for DeleteSchema LRO.", + "id": "GoogleCloudDiscoveryengineV1DeleteSchemaMetadata", "properties": { "createTime": { "description": "Operation create time.", "format": "google-datetime", "type": "string" }, - "failureCount": { - "description": "Count of entries that encountered errors while processing.", - "format": "int64", - "type": "string" - }, - "successCount": { - "description": "Count of entries that were deleted successfully.", - "format": "int64", - "type": "string" - }, "updateTime": { "description": "Operation last update time. If the operation is done, this is also the finish time.", "format": "google-datetime", @@ -4958,28 +4970,26 @@ }, "type": "object" }, - "GoogleCloudDiscoveryengineV1PurgeDocumentsResponse": { - "description": "Response message for DocumentService.PurgeDocuments method. If the long running operation is successfully done, then this message is returned by the google.longrunning.Operations.response field.", - "id": "GoogleCloudDiscoveryengineV1PurgeDocumentsResponse", + "GoogleCloudDiscoveryengineV1DeleteTargetSiteMetadata": { + "description": "Metadata related to the progress of the SiteSearchEngineService.DeleteTargetSite operation. This will be returned by the google.longrunning.Operation.metadata field.", + "id": "GoogleCloudDiscoveryengineV1DeleteTargetSiteMetadata", "properties": { - "purgeCount": { - "description": "The total count of documents purged as a result of the operation.", - "format": "int64", + "createTime": { + "description": "Operation create time.", + "format": "google-datetime", "type": "string" }, - "purgeSample": { - "description": "A sample of document names that will be deleted. Only populated if `force` is set to false. A max of 100 names will be returned and the names are chosen at random.", - "items": { - "type": "string" - }, - "type": "array" + "updateTime": { + "description": "Operation last update time. If the operation is done, this is also the finish time.", + "format": "google-datetime", + "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1PurgeSuggestionDenyListEntriesMetadata": { - "description": "Metadata related to the progress of the PurgeSuggestionDenyListEntries operation. This is returned by the google.longrunning.Operation.metadata field.", - "id": "GoogleCloudDiscoveryengineV1PurgeSuggestionDenyListEntriesMetadata", + "GoogleCloudDiscoveryengineV1DisableAdvancedSiteSearchMetadata": { + "description": "Metadata related to the progress of the SiteSearchEngineService.DisableAdvancedSiteSearch operation. This will be returned by the google.longrunning.Operation.metadata field.", + "id": "GoogleCloudDiscoveryengineV1DisableAdvancedSiteSearchMetadata", "properties": { "createTime": { "description": "Operation create time.", @@ -4994,419 +5004,381 @@ }, "type": "object" }, - "GoogleCloudDiscoveryengineV1PurgeSuggestionDenyListEntriesResponse": { - "description": "Response message for CompletionService.PurgeSuggestionDenyListEntries method.", - "id": "GoogleCloudDiscoveryengineV1PurgeSuggestionDenyListEntriesResponse", + "GoogleCloudDiscoveryengineV1DisableAdvancedSiteSearchResponse": { + "description": "Response message for SiteSearchEngineService.DisableAdvancedSiteSearch method.", + "id": "GoogleCloudDiscoveryengineV1DisableAdvancedSiteSearchResponse", + "properties": {}, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1EnableAdvancedSiteSearchMetadata": { + "description": "Metadata related to the progress of the SiteSearchEngineService.EnableAdvancedSiteSearch operation. This will be returned by the google.longrunning.Operation.metadata field.", + "id": "GoogleCloudDiscoveryengineV1EnableAdvancedSiteSearchMetadata", "properties": { - "errorSamples": { - "description": "A sample of errors encountered while processing the request.", - "items": { - "$ref": "GoogleRpcStatus" - }, - "type": "array" + "createTime": { + "description": "Operation create time.", + "format": "google-datetime", + "type": "string" }, - "purgeCount": { - "description": "Number of suggestion deny list entries purged.", - "format": "int64", + "updateTime": { + "description": "Operation last update time. If the operation is done, this is also the finish time.", + "format": "google-datetime", "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1Schema": { - "description": "Defines the structure and layout of a type of document data.", - "id": "GoogleCloudDiscoveryengineV1Schema", + "GoogleCloudDiscoveryengineV1EnableAdvancedSiteSearchResponse": { + "description": "Response message for SiteSearchEngineService.EnableAdvancedSiteSearch method.", + "id": "GoogleCloudDiscoveryengineV1EnableAdvancedSiteSearchResponse", + "properties": {}, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1Engine": { + "description": "Metadata that describes the training and serving parameters of an Engine.", + "id": "GoogleCloudDiscoveryengineV1Engine", "properties": { - "jsonSchema": { - "description": "The JSON representation of the schema.", + "chatEngineConfig": { + "$ref": "GoogleCloudDiscoveryengineV1EngineChatEngineConfig", + "description": "Configurations for the Chat Engine. Only applicable if solution_type is SOLUTION_TYPE_CHAT." + }, + "chatEngineMetadata": { + "$ref": "GoogleCloudDiscoveryengineV1EngineChatEngineMetadata", + "description": "Output only. Additional information of the Chat Engine. Only applicable if solution_type is SOLUTION_TYPE_CHAT.", + "readOnly": true + }, + "commonConfig": { + "$ref": "GoogleCloudDiscoveryengineV1EngineCommonConfig", + "description": "Common config spec that specifies the metadata of the engine." + }, + "createTime": { + "description": "Output only. Timestamp the Recommendation Engine was created at.", + "format": "google-datetime", + "readOnly": true, + "type": "string" + }, + "dataStoreIds": { + "description": "The data stores associated with this engine. For SOLUTION_TYPE_SEARCH and SOLUTION_TYPE_RECOMMENDATION type of engines, they can only associate with at most one data store. If solution_type is SOLUTION_TYPE_CHAT, multiple DataStores in the same Collection can be associated here. Note that when used in CreateEngineRequest, one DataStore id must be provided as the system will use it for necessary initializations.", + "items": { + "type": "string" + }, + "type": "array" + }, + "displayName": { + "description": "Required. The display name of the engine. Should be human readable. UTF-8 encoded string with limit of 1024 characters.", + "type": "string" + }, + "industryVertical": { + "description": "The industry vertical that the engine registers. The restriction of the Engine industry vertical is based on DataStore: If unspecified, default to `GENERIC`. Vertical on Engine has to match vertical of the DataStore liniked to the engine.", + "enum": [ + "INDUSTRY_VERTICAL_UNSPECIFIED", + "GENERIC", + "MEDIA" + ], + "enumDescriptions": [ + "Value used when unset.", + "The generic vertical for documents that are not specific to any industry vertical.", + "The media industry vertical." + ], "type": "string" }, "name": { - "description": "Immutable. The full resource name of the schema, in the format of `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/schemas/{schema}`. This field must be a UTF-8 encoded string with a length limit of 1024 characters.", + "description": "Immutable. The fully qualified resource name of the engine. This field must be a UTF-8 encoded string with a length limit of 1024 characters. Format: `projects/{project_number}/locations/{location}/collections/{collection}/engines/{engine}` engine should be 1-63 characters, and valid characters are /a-z0-9*/. Otherwise, an INVALID_ARGUMENT error is returned.", "type": "string" }, - "structSchema": { - "additionalProperties": { - "description": "Properties of the object.", - "type": "any" - }, - "description": "The structured representation of the schema.", - "type": "object" - } - }, - "type": "object" - }, - "GoogleCloudDiscoveryengineV1UpdateSchemaMetadata": { - "description": "Metadata for UpdateSchema LRO.", - "id": "GoogleCloudDiscoveryengineV1UpdateSchemaMetadata", - "properties": { - "createTime": { - "description": "Operation create time.", - "format": "google-datetime", + "searchEngineConfig": { + "$ref": "GoogleCloudDiscoveryengineV1EngineSearchEngineConfig", + "description": "Configurations for the Search Engine. Only applicable if solution_type is SOLUTION_TYPE_SEARCH." + }, + "solutionType": { + "description": "Required. The solutions of the engine.", + "enum": [ + "SOLUTION_TYPE_UNSPECIFIED", + "SOLUTION_TYPE_RECOMMENDATION", + "SOLUTION_TYPE_SEARCH", + "SOLUTION_TYPE_CHAT" + ], + "enumDescriptions": [ + "Default value.", + "Used for Recommendations AI.", + "Used for Discovery Search.", + "Used for use cases related to the Generative AI agent." + ], "type": "string" }, "updateTime": { - "description": "Operation last update time. If the operation is done, this is also the finish time.", + "description": "Output only. Timestamp the Recommendation Engine was last updated.", "format": "google-datetime", + "readOnly": true, "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaAdditionalParams": { - "description": "AdditionalParams message for WidgetService methods for security and privacy enhancement.", - "id": "GoogleCloudDiscoveryengineV1alphaAdditionalParams", + "GoogleCloudDiscoveryengineV1EngineChatEngineConfig": { + "description": "Configurations for a Chat Engine.", + "id": "GoogleCloudDiscoveryengineV1EngineChatEngineConfig", "properties": { - "token": { - "description": "Token that used for non-human user check.", + "agentCreationConfig": { + "$ref": "GoogleCloudDiscoveryengineV1EngineChatEngineConfigAgentCreationConfig", + "description": "The configurationt generate the Dialogflow agent that is associated to this Engine. Note that these configurations are one-time consumed by and passed to Dialogflow service. It means they cannot be retrieved using EngineService.GetEngine or EngineService.ListEngines API after engine creation." + }, + "dialogflowAgentToLink": { + "description": "The resource name of an exist Dialogflow agent to link to this Chat Engine. Customers can either provide `agent_creation_config` to create agent or provide an agent name that links the agent with the Chat engine. Format: `projects//locations//agents/`. Note that the `dialogflow_agent_to_link` are one-time consumed by and passed to Dialogflow service. It means they cannot be retrieved using EngineService.GetEngine or EngineService.ListEngines API after engine creation. Please use ChatEngineMetadata.dialogflow_agent for actual agent association after Engine is created.", "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaBatchCreateTargetSiteMetadata": { - "description": "Metadata related to the progress of the SiteSearchEngineService.BatchCreateTargetSites operation. This will be returned by the google.longrunning.Operation.metadata field.", - "id": "GoogleCloudDiscoveryengineV1alphaBatchCreateTargetSiteMetadata", + "GoogleCloudDiscoveryengineV1EngineChatEngineConfigAgentCreationConfig": { + "description": "Configurations for generating a Dialogflow agent. Note that these configurations are one-time consumed by and passed to Dialogflow service. It means they cannot be retrieved using EngineService.GetEngine or EngineService.ListEngines API after engine creation.", + "id": "GoogleCloudDiscoveryengineV1EngineChatEngineConfigAgentCreationConfig", "properties": { - "createTime": { - "description": "Operation create time.", - "format": "google-datetime", + "business": { + "description": "Name of the company, organization or other entity that the agent represents. Used for knowledge connector LLM prompt and for knowledge search.", "type": "string" }, - "updateTime": { - "description": "Operation last update time. If the operation is done, this is also the finish time.", - "format": "google-datetime", + "defaultLanguageCode": { + "description": "Required. The default language of the agent as a language tag. See [Language Support](https://cloud.google.com/dialogflow/docs/reference/language) for a list of the currently supported language codes.", + "type": "string" + }, + "location": { + "description": "Agent location for Agent creation, supported values: global/us/eu. If not provided, us Engine will create Agent using us-central-1 by default; eu Engine will create Agent using eu-west-1 by default.", + "type": "string" + }, + "timeZone": { + "description": "Required. The time zone of the agent from the [time zone database](https://www.iana.org/time-zones), e.g., America/New_York, Europe/Paris.", "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaBatchCreateTargetSitesRequest": { - "description": "Request message for SiteSearchEngineService.BatchCreateTargetSites method.", - "id": "GoogleCloudDiscoveryengineV1alphaBatchCreateTargetSitesRequest", + "GoogleCloudDiscoveryengineV1EngineChatEngineMetadata": { + "description": "Additional information of a Chat Engine. Fields in this message are output only.", + "id": "GoogleCloudDiscoveryengineV1EngineChatEngineMetadata", "properties": { - "requests": { - "description": "Required. The request message specifying the resources to create. A maximum of 20 TargetSites can be created in a batch.", - "items": { - "$ref": "GoogleCloudDiscoveryengineV1alphaCreateTargetSiteRequest" - }, - "type": "array" + "dialogflowAgent": { + "description": "The resource name of a Dialogflow agent, that this Chat Engine refers to. Format: `projects//locations//agents/`.", + "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaBatchCreateTargetSitesResponse": { - "description": "Response message for SiteSearchEngineService.BatchCreateTargetSites method.", - "id": "GoogleCloudDiscoveryengineV1alphaBatchCreateTargetSitesResponse", + "GoogleCloudDiscoveryengineV1EngineCommonConfig": { + "description": "Common configurations for an Engine.", + "id": "GoogleCloudDiscoveryengineV1EngineCommonConfig", "properties": { - "targetSites": { - "description": "TargetSites created.", - "items": { - "$ref": "GoogleCloudDiscoveryengineV1alphaTargetSite" - }, - "type": "array" + "companyName": { + "description": "Immutable. The name of the company, business or entity that is associated with the engine. Setting this may help improve LLM related features.", + "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaBatchVerifyTargetSitesRequest": { - "description": "Request message for SiteSearchEngineService.BatchVerifyTargetSites method.", - "id": "GoogleCloudDiscoveryengineV1alphaBatchVerifyTargetSitesRequest", - "properties": {}, - "type": "object" - }, - "GoogleCloudDiscoveryengineV1alphaBigQuerySource": { - "description": "BigQuery source import data from.", - "id": "GoogleCloudDiscoveryengineV1alphaBigQuerySource", + "GoogleCloudDiscoveryengineV1EngineSearchEngineConfig": { + "description": "Configurations for a Search Engine.", + "id": "GoogleCloudDiscoveryengineV1EngineSearchEngineConfig", "properties": { - "dataSchema": { - "description": "The schema to use when parsing the data from the source. Supported values for user event imports: * `user_event` (default): One UserEvent per row. Supported values for document imports: * `document` (default): One Document format per row. Each document must have a valid Document.id and one of Document.json_data or Document.struct_data. * `custom`: One custom data per row in arbitrary format that conforms to the defined Schema of the data store. This can only be used by Gen App Builder.", - "type": "string" - }, - "datasetId": { - "description": "Required. The BigQuery data set to copy the data from with a length limit of 1,024 characters.", - "type": "string" - }, - "gcsStagingDir": { - "description": "Intermediate Cloud Storage directory used for the import with a length limit of 2,000 characters. Can be specified if one wants to have the BigQuery export to a specific Cloud Storage directory.", - "type": "string" - }, - "partitionDate": { - "$ref": "GoogleTypeDate", - "description": "BigQuery time partitioned table's _PARTITIONDATE in YYYY-MM-DD format." - }, - "projectId": { - "description": "The project ID (can be project # or ID) that the BigQuery source is in with a length limit of 128 characters. If not specified, inherits the project ID from the parent request.", - "type": "string" + "searchAddOns": { + "description": "The add-on that this search engine enables.", + "items": { + "enum": [ + "SEARCH_ADD_ON_UNSPECIFIED", + "SEARCH_ADD_ON_LLM" + ], + "enumDescriptions": [ + "Default value when the enum is unspecified. This is invalid to use.", + "Large language model add-on." + ], + "type": "string" + }, + "type": "array" }, - "tableId": { - "description": "Required. The BigQuery table to copy the data from with a length limit of 1,024 characters.", + "searchTier": { + "description": "The search feature tier of this engine. Different tiers might have different pricing. To learn more, please check the pricing documentation. Defaults to SearchTier.SEARCH_TIER_STANDARD if not specified.", + "enum": [ + "SEARCH_TIER_UNSPECIFIED", + "SEARCH_TIER_STANDARD", + "SEARCH_TIER_ENTERPRISE" + ], + "enumDescriptions": [ + "Default value when the enum is unspecified. This is invalid to use.", + "Standard tier.", + "Enterprise tier." + ], "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaCompleteQueryRequest": { - "description": "Request message for CompletionService.CompleteQuery method.", - "id": "GoogleCloudDiscoveryengineV1alphaCompleteQueryRequest", + "GoogleCloudDiscoveryengineV1ImportDocumentsMetadata": { + "description": "Metadata related to the progress of the ImportDocuments operation. This is returned by the google.longrunning.Operation.metadata field.", + "id": "GoogleCloudDiscoveryengineV1ImportDocumentsMetadata", "properties": { - "dataStore": { - "description": "Required. The parent data store resource name for which the completion is performed, such as `projects/*/locations/global/collections/default_collection/dataStores/default_data_store`.", + "createTime": { + "description": "Operation create time.", + "format": "google-datetime", "type": "string" }, - "includeTailSuggestions": { - "description": "Indicates if tail suggestions should be returned if there are no suggestions that match the full query. Even if set to true, if there are suggestions that match the full query, those are returned and no tail suggestions are returned.", - "type": "boolean" - }, - "query": { - "description": "Required. The typeahead input used to fetch suggestions. Maximum length is 128 characters.", + "failureCount": { + "description": "Count of entries that encountered errors while processing.", + "format": "int64", "type": "string" }, - "queryModel": { - "description": "Selects data model of query suggestions for serving. Currently supported values: * `document` - Using suggestions generated from user-imported documents. * `search-history` - Using suggestions generated from the past history of SearchService.Search API calls. Do not use it when there is no traffic for Search API. * `user-event` - Using suggestions generated from user-imported search events. * `document-completable` - Using suggestions taken directly from user-imported document fields marked as completable. Default values: * `document` is the default model for regular dataStores. * `search-history` is the default model for site search dataStores.", + "successCount": { + "description": "Count of entries that were processed successfully.", + "format": "int64", "type": "string" }, - "userPseudoId": { - "description": "A unique identifier for tracking visitors. For example, this could be implemented with an HTTP cookie, which should be able to uniquely identify a visitor on a single device. This unique identifier should not change if the visitor logs in or out of the website. This field should NOT have a fixed value such as `unknown_visitor`. This should be the same identifier as UserEvent.user_pseudo_id and SearchRequest.user_pseudo_id. The field must be a UTF-8 encoded string with a length limit of 128 characters. Otherwise, an `INVALID_ARGUMENT` error is returned.", + "updateTime": { + "description": "Operation last update time. If the operation is done, this is also the finish time.", + "format": "google-datetime", "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaCompleteQueryResponse": { - "description": "Response message for CompletionService.CompleteQuery method.", - "id": "GoogleCloudDiscoveryengineV1alphaCompleteQueryResponse", + "GoogleCloudDiscoveryengineV1ImportDocumentsResponse": { + "description": "Response of the ImportDocumentsRequest. If the long running operation is done, then this message is returned by the google.longrunning.Operations.response field if the operation was successful.", + "id": "GoogleCloudDiscoveryengineV1ImportDocumentsResponse", "properties": { - "querySuggestions": { - "description": "Results of the matched query suggestions. The result list is ordered and the first result is a top suggestion.", + "errorConfig": { + "$ref": "GoogleCloudDiscoveryengineV1ImportErrorConfig", + "description": "Echoes the destination for the complete errors in the request if set." + }, + "errorSamples": { + "description": "A sample of errors encountered while processing the request.", "items": { - "$ref": "GoogleCloudDiscoveryengineV1alphaCompleteQueryResponseQuerySuggestion" + "$ref": "GoogleRpcStatus" }, "type": "array" - }, - "tailMatchTriggered": { - "description": "True if the returned suggestions are all tail suggestions. For tail matching to be triggered, include_tail_suggestions in the request must be true and there must be no suggestions that match the full query.", - "type": "boolean" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaCompleteQueryResponseQuerySuggestion": { - "description": "Suggestions as search queries.", - "id": "GoogleCloudDiscoveryengineV1alphaCompleteQueryResponseQuerySuggestion", + "GoogleCloudDiscoveryengineV1ImportErrorConfig": { + "description": "Configuration of destination for Import related errors.", + "id": "GoogleCloudDiscoveryengineV1ImportErrorConfig", "properties": { - "completableFieldPaths": { - "description": "The unique document field paths that serve as the source of this suggestion if it was generated from completable fields. This field is only populated for the document-completable model.", - "items": { - "type": "string" - }, - "type": "array" - }, - "suggestion": { - "description": "The suggestion for the query.", + "gcsPrefix": { + "description": "Cloud Storage prefix for import errors. This must be an empty, existing Cloud Storage directory. Import errors are written to sharded files in this directory, one per line, as a JSON-encoded `google.rpc.Status` message.", "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaCompletionInfo": { - "description": "Detailed completion information including completion attribution token and clicked completion info.", - "id": "GoogleCloudDiscoveryengineV1alphaCompletionInfo", + "GoogleCloudDiscoveryengineV1ImportSuggestionDenyListEntriesMetadata": { + "description": "Metadata related to the progress of the ImportSuggestionDenyListEntries operation. This is returned by the google.longrunning.Operation.metadata field.", + "id": "GoogleCloudDiscoveryengineV1ImportSuggestionDenyListEntriesMetadata", "properties": { - "selectedPosition": { - "description": "End user selected CompleteQueryResponse.QuerySuggestion.suggestion position, starting from 0.", - "format": "int32", - "type": "integer" + "createTime": { + "description": "Operation create time.", + "format": "google-datetime", + "type": "string" }, - "selectedSuggestion": { - "description": "End user selected CompleteQueryResponse.QuerySuggestion.suggestion.", + "updateTime": { + "description": "Operation last update time. If the operation is done, this is also the finish time.", + "format": "google-datetime", "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaConversation": { - "description": "External conversation proto definition.", - "id": "GoogleCloudDiscoveryengineV1alphaConversation", + "GoogleCloudDiscoveryengineV1ImportSuggestionDenyListEntriesResponse": { + "description": "Response message for CompletionService.ImportSuggestionDenyListEntries method.", + "id": "GoogleCloudDiscoveryengineV1ImportSuggestionDenyListEntriesResponse", "properties": { - "endTime": { - "description": "Output only. The time the conversation finished.", - "format": "google-datetime", - "readOnly": true, - "type": "string" - }, - "messages": { - "description": "Conversation messages.", + "errorSamples": { + "description": "A sample of errors encountered while processing the request.", "items": { - "$ref": "GoogleCloudDiscoveryengineV1alphaConversationMessage" + "$ref": "GoogleRpcStatus" }, "type": "array" }, - "name": { - "description": "Immutable. Fully qualified name `project/*/locations/global/collections/{collection}/dataStore/*/conversations/*` or `project/*/locations/global/collections/{collection}/engines/*/conversations/*`.", - "type": "string" - }, - "startTime": { - "description": "Output only. The time the conversation started.", - "format": "google-datetime", - "readOnly": true, - "type": "string" - }, - "state": { - "description": "The state of the Conversation.", - "enum": [ - "STATE_UNSPECIFIED", - "IN_PROGRESS", - "COMPLETED" - ], - "enumDescriptions": [ - "Unknown.", - "Conversation is currently open.", - "Conversation has been completed." - ], + "failedEntriesCount": { + "description": "Count of deny list entries that failed to be imported.", + "format": "int64", "type": "string" }, - "userPseudoId": { - "description": "A unique identifier for tracking users.", - "type": "string" - } - }, - "type": "object" - }, - "GoogleCloudDiscoveryengineV1alphaConversationContext": { - "description": "Defines context of the conversation", - "id": "GoogleCloudDiscoveryengineV1alphaConversationContext", - "properties": { - "activeDocument": { - "description": "The current active document the user opened. It contains the document resource reference.", + "importedEntriesCount": { + "description": "Count of deny list entries successfully imported.", + "format": "int64", "type": "string" - }, - "contextDocuments": { - "description": "The current list of documents the user is seeing. It contains the document resource references.", - "items": { - "type": "string" - }, - "type": "array" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaConversationMessage": { - "description": "Defines a conversation message.", - "id": "GoogleCloudDiscoveryengineV1alphaConversationMessage", + "GoogleCloudDiscoveryengineV1ImportUserEventsMetadata": { + "description": "Metadata related to the progress of the Import operation. This is returned by the google.longrunning.Operation.metadata field.", + "id": "GoogleCloudDiscoveryengineV1ImportUserEventsMetadata", "properties": { "createTime": { - "description": "Output only. Message creation timestamp.", + "description": "Operation create time.", "format": "google-datetime", - "readOnly": true, "type": "string" }, - "reply": { - "$ref": "GoogleCloudDiscoveryengineV1alphaReply", - "description": "Search reply." - }, - "userInput": { - "$ref": "GoogleCloudDiscoveryengineV1alphaTextInput", - "description": "User text input." - } - }, - "type": "object" - }, - "GoogleCloudDiscoveryengineV1alphaConverseConversationRequest": { - "description": "Request message for ConversationalSearchService.ConverseConversation method.", - "id": "GoogleCloudDiscoveryengineV1alphaConverseConversationRequest", - "properties": { - "conversation": { - "$ref": "GoogleCloudDiscoveryengineV1alphaConversation", - "description": "The conversation to be used by auto session only. The name field will be ignored as we automatically assign new name for the conversation in auto session." - }, - "filter": { - "description": "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. This will be used to filter search results which may affect the summary response. 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)", + "failureCount": { + "description": "Count of entries that encountered errors while processing.", + "format": "int64", "type": "string" }, - "name": { - "description": "Required. The resource name of the Conversation to get. Format: `projects/{project_number}/locations/{location_id}/collections/{collection}/dataStores/{data_store_id}/conversations/{conversation_id}`. Use `projects/{project_number}/locations/{location_id}/collections/{collection}/dataStores/{data_store_id}/conversations/-` to activate auto session mode, which automatically creates a new conversation inside a ConverseConversation session.", + "successCount": { + "description": "Count of entries that were processed successfully.", + "format": "int64", "type": "string" }, - "query": { - "$ref": "GoogleCloudDiscoveryengineV1alphaTextInput", - "description": "Required. Current user input." - }, - "safeSearch": { - "description": "Whether to turn on safe search.", - "type": "boolean" - }, - "servingConfig": { - "description": "The resource name of the Serving Config to use. Format: `projects/{project_number}/locations/{location_id}/collections/{collection}/dataStores/{data_store_id}/servingConfigs/{serving_config_id}` If this is not set, the default serving config will be used.", + "updateTime": { + "description": "Operation last update time. If the operation is done, this is also the finish time.", + "format": "google-datetime", "type": "string" - }, - "summarySpec": { - "$ref": "GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSummarySpec", - "description": "A specification for configuring the summary returned in the response." - }, - "userLabels": { - "additionalProperties": { - "type": "string" - }, - "description": "The user labels applied to a resource must meet the following requirements: * Each resource can have multiple labels, up to a maximum of 64. * Each label must be a key-value pair. * Keys have a minimum length of 1 character and a maximum length of 63 characters and cannot be empty. Values can be empty and have a maximum length of 63 characters. * Keys and values can contain only lowercase letters, numeric characters, underscores, and dashes. All characters must use UTF-8 encoding, and international characters are allowed. * The key portion of a label must be unique. However, you can use the same key with multiple resources. * Keys must start with a lowercase letter or international character. See [Google Cloud Document](https://cloud.google.com/resource-manager/docs/creating-managing-labels#requirements) for more details.", - "type": "object" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaConverseConversationResponse": { - "description": "Response message for ConversationalSearchService.ConverseConversation method.", - "id": "GoogleCloudDiscoveryengineV1alphaConverseConversationResponse", + "GoogleCloudDiscoveryengineV1ImportUserEventsResponse": { + "description": "Response of the ImportUserEventsRequest. If the long running operation was successful, then this message is returned by the google.longrunning.Operations.response field if the operation was successful.", + "id": "GoogleCloudDiscoveryengineV1ImportUserEventsResponse", "properties": { - "conversation": { - "$ref": "GoogleCloudDiscoveryengineV1alphaConversation", - "description": "Updated conversation including the answer." + "errorConfig": { + "$ref": "GoogleCloudDiscoveryengineV1ImportErrorConfig", + "description": "Echoes the destination for the complete errors if this field was set in the request." }, - "relatedQuestions": { - "description": "Suggested related questions.", + "errorSamples": { + "description": "A sample of errors encountered while processing the request.", "items": { - "type": "string" + "$ref": "GoogleRpcStatus" }, "type": "array" }, - "reply": { - "$ref": "GoogleCloudDiscoveryengineV1alphaReply", - "description": "Answer to the current query." + "joinedEventsCount": { + "description": "Count of user events imported with complete existing Documents.", + "format": "int64", + "type": "string" }, - "searchResults": { - "description": "Search Results.", - "items": { - "$ref": "GoogleCloudDiscoveryengineV1alphaSearchResponseSearchResult" - }, - "type": "array" + "unjoinedEventsCount": { + "description": "Count of user events imported, but with Document information not found in the existing Branch.", + "format": "int64", + "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaCreateDataStoreMetadata": { - "description": "Metadata related to the progress of the DataStoreService.CreateDataStore operation. This will be returned by the google.longrunning.Operation.metadata field.", - "id": "GoogleCloudDiscoveryengineV1alphaCreateDataStoreMetadata", + "GoogleCloudDiscoveryengineV1PurgeDocumentsMetadata": { + "description": "Metadata related to the progress of the PurgeDocuments operation. This will be returned by the google.longrunning.Operation.metadata field.", + "id": "GoogleCloudDiscoveryengineV1PurgeDocumentsMetadata", "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", + "failureCount": { + "description": "Count of entries that encountered errors while processing.", + "format": "int64", "type": "string" - } - }, - "type": "object" - }, - "GoogleCloudDiscoveryengineV1alphaCreateEngineMetadata": { - "description": "Metadata related to the progress of the EngineService.CreateEngine operation. This will be returned by the google.longrunning.Operation.metadata field.", - "id": "GoogleCloudDiscoveryengineV1alphaCreateEngineMetadata", - "properties": { - "createTime": { - "description": "Operation create time.", - "format": "google-datetime", + }, + "successCount": { + "description": "Count of entries that were deleted successfully.", + "format": "int64", "type": "string" }, "updateTime": { @@ -5417,26 +5389,28 @@ }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaCreateSchemaMetadata": { - "description": "Metadata for Create Schema LRO.", - "id": "GoogleCloudDiscoveryengineV1alphaCreateSchemaMetadata", + "GoogleCloudDiscoveryengineV1PurgeDocumentsResponse": { + "description": "Response message for DocumentService.PurgeDocuments method. If the long running operation is successfully done, then this message is returned by the google.longrunning.Operations.response field.", + "id": "GoogleCloudDiscoveryengineV1PurgeDocumentsResponse", "properties": { - "createTime": { - "description": "Operation create time.", - "format": "google-datetime", + "purgeCount": { + "description": "The total count of documents purged as a result of the operation.", + "format": "int64", "type": "string" }, - "updateTime": { - "description": "Operation last update time. If the operation is done, this is also the finish time.", - "format": "google-datetime", - "type": "string" + "purgeSample": { + "description": "A sample of document names that will be deleted. Only populated if `force` is set to false. A max of 100 names will be returned and the names are chosen at random.", + "items": { + "type": "string" + }, + "type": "array" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaCreateTargetSiteMetadata": { - "description": "Metadata related to the progress of the SiteSearchEngineService.CreateTargetSite operation. This will be returned by the google.longrunning.Operation.metadata field.", - "id": "GoogleCloudDiscoveryengineV1alphaCreateTargetSiteMetadata", + "GoogleCloudDiscoveryengineV1PurgeSuggestionDenyListEntriesMetadata": { + "description": "Metadata related to the progress of the PurgeSuggestionDenyListEntries operation. This is returned by the google.longrunning.Operation.metadata field.", + "id": "GoogleCloudDiscoveryengineV1PurgeSuggestionDenyListEntriesMetadata", "properties": { "createTime": { "description": "Operation create time.", @@ -5451,138 +5425,175 @@ }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaCreateTargetSiteRequest": { - "description": "Request message for SiteSearchEngineService.CreateTargetSite method.", - "id": "GoogleCloudDiscoveryengineV1alphaCreateTargetSiteRequest", + "GoogleCloudDiscoveryengineV1PurgeSuggestionDenyListEntriesResponse": { + "description": "Response message for CompletionService.PurgeSuggestionDenyListEntries method.", + "id": "GoogleCloudDiscoveryengineV1PurgeSuggestionDenyListEntriesResponse", "properties": { - "parent": { - "description": "Required. Parent resource name of TargetSite, such as `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/siteSearchEngine`.", - "type": "string" + "errorSamples": { + "description": "A sample of errors encountered while processing the request.", + "items": { + "$ref": "GoogleRpcStatus" + }, + "type": "array" }, - "targetSite": { - "$ref": "GoogleCloudDiscoveryengineV1alphaTargetSite", - "description": "Required. The TargetSite to create." + "purgeCount": { + "description": "Number of suggestion deny list entries purged.", + "format": "int64", + "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaCustomAttribute": { - "description": "A custom attribute that is not explicitly modeled in a resource, e.g. UserEvent.", - "id": "GoogleCloudDiscoveryengineV1alphaCustomAttribute", + "GoogleCloudDiscoveryengineV1Schema": { + "description": "Defines the structure and layout of a type of document data.", + "id": "GoogleCloudDiscoveryengineV1Schema", "properties": { - "numbers": { - "description": "The numerical values of this custom attribute. For example, `[2.3, 15.4]` when the key is \"lengths_cm\". Exactly one of CustomAttribute.text or CustomAttribute.numbers should be set. Otherwise, an `INVALID_ARGUMENT` error is returned.", - "items": { - "format": "double", - "type": "number" - }, - "type": "array" + "jsonSchema": { + "description": "The JSON representation of the schema.", + "type": "string" }, - "text": { - "description": "The textual values of this custom attribute. For example, `[\"yellow\", \"green\"]` when the key is \"color\". Empty string is not allowed. Otherwise, an `INVALID_ARGUMENT` error is returned. Exactly one of CustomAttribute.text or CustomAttribute.numbers should be set. Otherwise, an `INVALID_ARGUMENT` error is returned.", - "items": { - "type": "string" + "name": { + "description": "Immutable. The full resource name of the schema, in the format of `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/schemas/{schema}`. This field must be a UTF-8 encoded string with a length limit of 1024 characters.", + "type": "string" + }, + "structSchema": { + "additionalProperties": { + "description": "Properties of the object.", + "type": "any" }, - "type": "array" + "description": "The structured representation of the schema.", + "type": "object" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaDataStore": { - "description": "DataStore captures global settings and configs at the DataStore level.", - "id": "GoogleCloudDiscoveryengineV1alphaDataStore", + "GoogleCloudDiscoveryengineV1SiteVerificationInfo": { + "description": "Verification information for target sites in advanced site search.", + "id": "GoogleCloudDiscoveryengineV1SiteVerificationInfo", "properties": { - "contentConfig": { - "description": "Immutable. The content config of the data store. If this field is unset, the server behavior defaults to ContentConfig.NO_CONTENT.", + "siteVerificationState": { + "description": "Site verification state indicating the ownership and validity.", "enum": [ - "CONTENT_CONFIG_UNSPECIFIED", - "NO_CONTENT", - "CONTENT_REQUIRED", - "PUBLIC_WEBSITE" + "SITE_VERIFICATION_STATE_UNSPECIFIED", + "VERIFIED", + "UNVERIFIED", + "EXEMPTED" ], "enumDescriptions": [ - "Default value.", - "Only contains documents without any Document.content.", - "Only contains documents with Document.content.", - "The data store is used for public website search." + "Defaults to VERIFIED.", + "Site ownership verified.", + "Site ownership pending verification or verification failed.", + "Site exempt from verification, e.g., a public website that opens to all." ], "type": "string" }, - "createTime": { - "description": "Output only. Timestamp the DataStore was created at.", + "verifyTime": { + "description": "Latest site verification time.", "format": "google-datetime", + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1TargetSite": { + "description": "A target site for the SiteSearchEngine.", + "id": "GoogleCloudDiscoveryengineV1TargetSite", + "properties": { + "exactMatch": { + "description": "Input only. If set to false, a uri_pattern is generated to include all pages whose address contains the provided_uri_pattern. If set to true, an uri_pattern is generated to try to be an exact match of the provided_uri_pattern or just the specific page if the provided_uri_pattern is a specific one. provided_uri_pattern is always normalized to generate the URI pattern to be used by the search engine.", + "type": "boolean" + }, + "failureReason": { + "$ref": "GoogleCloudDiscoveryengineV1TargetSiteFailureReason", + "description": "Output only. Failure reason.", + "readOnly": true + }, + "generatedUriPattern": { + "description": "Output only. This is system-generated based on the provided_uri_pattern.", "readOnly": true, "type": "string" }, - "defaultSchemaId": { - "description": "Output only. The id of the default Schema asscociated to this data store.", + "indexingStatus": { + "description": "Output only. Indexing status.", + "enum": [ + "INDEXING_STATUS_UNSPECIFIED", + "PENDING", + "FAILED", + "SUCCEEDED", + "DELETING" + ], + "enumDescriptions": [ + "Defaults to SUCCEEDED.", + "The target site is in the update queue and will be picked up by indexing pipeline.", + "The target site fails to be indexed.", + "The target site has been indexed.", + "The previously indexed target site has been marked to be deleted. This is a transitioning state which will resulted in either: 1. target site deleted if unindexing is successful; 2. state reverts to SUCCEEDED if the unindexing fails." + ], "readOnly": true, "type": "string" }, - "displayName": { - "description": "Required. The data store display name. This field must be a UTF-8 encoded string with a length limit of 128 characters. Otherwise, an INVALID_ARGUMENT error is returned.", + "name": { + "description": "Output only. The fully qualified resource name of the target site. `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/siteSearchEngine/targetSites/{target_site}` The `target_site_id` is system-generated.", + "readOnly": true, "type": "string" }, - "industryVertical": { - "description": "Immutable. The industry vertical that the data store registers.", + "providedUriPattern": { + "description": "Required. Input only. The user provided URI pattern from which the `generated_uri_pattern` is generated.", + "type": "string" + }, + "siteVerificationInfo": { + "$ref": "GoogleCloudDiscoveryengineV1SiteVerificationInfo", + "description": "Output only. Site ownership and validity verification status.", + "readOnly": true + }, + "type": { + "description": "The type of the target site, e.g., whether the site is to be included or excluded.", "enum": [ - "INDUSTRY_VERTICAL_UNSPECIFIED", - "GENERIC", - "MEDIA" + "TYPE_UNSPECIFIED", + "INCLUDE", + "EXCLUDE" ], "enumDescriptions": [ - "Value used when unset.", - "The generic vertical for documents that are not specific to any industry vertical.", - "The media industry vertical." + "This value is unused. In this case, server behavior defaults to Type.INCLUDE.", + "Include the target site.", + "Exclude the target site." ], "type": "string" }, - "name": { - "description": "Immutable. The full resource name of the data store. Format: `projects/{project}/locations/{location}/collections/{collection_id}/dataStores/{data_store_id}`. This field must be a UTF-8 encoded string with a length limit of 1024 characters.", + "updateTime": { + "description": "Output only. The target site's last updated time.", + "format": "google-datetime", + "readOnly": true, "type": "string" - }, - "solutionTypes": { - "description": "The solutions that the data store enrolls. Available solutions for each industry_vertical: * `MEDIA`: `SOLUTION_TYPE_RECOMMENDATION` and `SOLUTION_TYPE_SEARCH`. * `SITE_SEARCH`: `SOLUTION_TYPE_SEARCH` is automatically enrolled. Other solutions cannot be enrolled.", - "items": { - "enum": [ - "SOLUTION_TYPE_UNSPECIFIED", - "SOLUTION_TYPE_RECOMMENDATION", - "SOLUTION_TYPE_SEARCH", - "SOLUTION_TYPE_CHAT" - ], - "enumDescriptions": [ - "Default value.", - "Used for Recommendations AI.", - "Used for Discovery Search.", - "Used for use cases related to the Generative AI agent." - ], - "type": "string" - }, - "type": "array" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaDeleteDataStoreMetadata": { - "description": "Metadata related to the progress of the DataStoreService.DeleteDataStore operation. This will be returned by the google.longrunning.Operation.metadata field.", - "id": "GoogleCloudDiscoveryengineV1alphaDeleteDataStoreMetadata", + "GoogleCloudDiscoveryengineV1TargetSiteFailureReason": { + "description": "Site search indexing failure reasons.", + "id": "GoogleCloudDiscoveryengineV1TargetSiteFailureReason", "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", + "quotaFailure": { + "$ref": "GoogleCloudDiscoveryengineV1TargetSiteFailureReasonQuotaFailure", + "description": "Failed due to insufficient quota." + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1TargetSiteFailureReasonQuotaFailure": { + "id": "GoogleCloudDiscoveryengineV1TargetSiteFailureReasonQuotaFailure", + "properties": { + "totalRequiredQuota": { + "description": "This number is an estimation on how much total quota this project needs to successfully complete indexing.", + "format": "int64", "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaDeleteEngineMetadata": { - "description": "Metadata related to the progress of the EngineService.DeleteEngine operation. This will be returned by the google.longrunning.Operation.metadata field.", - "id": "GoogleCloudDiscoveryengineV1alphaDeleteEngineMetadata", + "GoogleCloudDiscoveryengineV1UpdateSchemaMetadata": { + "description": "Metadata for UpdateSchema LRO.", + "id": "GoogleCloudDiscoveryengineV1UpdateSchemaMetadata", "properties": { "createTime": { "description": "Operation create time.", @@ -5597,9 +5608,9 @@ }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaDeleteSchemaMetadata": { - "description": "Metadata for DeleteSchema LRO.", - "id": "GoogleCloudDiscoveryengineV1alphaDeleteSchemaMetadata", + "GoogleCloudDiscoveryengineV1UpdateTargetSiteMetadata": { + "description": "Metadata related to the progress of the SiteSearchEngineService.UpdateTargetSite operation. This will be returned by the google.longrunning.Operation.metadata field.", + "id": "GoogleCloudDiscoveryengineV1UpdateTargetSiteMetadata", "properties": { "createTime": { "description": "Operation create time.", @@ -5614,26 +5625,20 @@ }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaDeleteTargetSiteMetadata": { - "description": "Metadata related to the progress of the SiteSearchEngineService.DeleteTargetSite operation. This will be returned by the google.longrunning.Operation.metadata field.", - "id": "GoogleCloudDiscoveryengineV1alphaDeleteTargetSiteMetadata", + "GoogleCloudDiscoveryengineV1alphaAdditionalParams": { + "description": "AdditionalParams message for WidgetService methods for security and privacy enhancement.", + "id": "GoogleCloudDiscoveryengineV1alphaAdditionalParams", "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", + "token": { + "description": "Token that used for non-human user check.", "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaDisableAdvancedSiteSearchMetadata": { - "description": "Metadata related to the progress of the SiteSearchEngineService.DisableAdvancedSiteSearch operation. This will be returned by the google.longrunning.Operation.metadata field.", - "id": "GoogleCloudDiscoveryengineV1alphaDisableAdvancedSiteSearchMetadata", + "GoogleCloudDiscoveryengineV1alphaBatchCreateTargetSiteMetadata": { + "description": "Metadata related to the progress of the SiteSearchEngineService.BatchCreateTargetSites operation. This will be returned by the google.longrunning.Operation.metadata field.", + "id": "GoogleCloudDiscoveryengineV1alphaBatchCreateTargetSiteMetadata", "properties": { "createTime": { "description": "Operation create time.", @@ -5648,749 +5653,724 @@ }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaDisableAdvancedSiteSearchRequest": { - "description": "Request message for SiteSearchEngineService.DisableAdvancedSiteSearch method.", - "id": "GoogleCloudDiscoveryengineV1alphaDisableAdvancedSiteSearchRequest", - "properties": {}, + "GoogleCloudDiscoveryengineV1alphaBatchCreateTargetSitesRequest": { + "description": "Request message for SiteSearchEngineService.BatchCreateTargetSites method.", + "id": "GoogleCloudDiscoveryengineV1alphaBatchCreateTargetSitesRequest", + "properties": { + "requests": { + "description": "Required. The request message specifying the resources to create. A maximum of 20 TargetSites can be created in a batch.", + "items": { + "$ref": "GoogleCloudDiscoveryengineV1alphaCreateTargetSiteRequest" + }, + "type": "array" + } + }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaDisableAdvancedSiteSearchResponse": { - "description": "Response message for SiteSearchEngineService.DisableAdvancedSiteSearch method.", - "id": "GoogleCloudDiscoveryengineV1alphaDisableAdvancedSiteSearchResponse", + "GoogleCloudDiscoveryengineV1alphaBatchCreateTargetSitesResponse": { + "description": "Response message for SiteSearchEngineService.BatchCreateTargetSites method.", + "id": "GoogleCloudDiscoveryengineV1alphaBatchCreateTargetSitesResponse", + "properties": { + "targetSites": { + "description": "TargetSites created.", + "items": { + "$ref": "GoogleCloudDiscoveryengineV1alphaTargetSite" + }, + "type": "array" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaBatchVerifyTargetSitesRequest": { + "description": "Request message for SiteSearchEngineService.BatchVerifyTargetSites method.", + "id": "GoogleCloudDiscoveryengineV1alphaBatchVerifyTargetSitesRequest", "properties": {}, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaDocument": { - "description": "Document captures all raw metadata information of items to be recommended or searched.", - "id": "GoogleCloudDiscoveryengineV1alphaDocument", + "GoogleCloudDiscoveryengineV1alphaBigQuerySource": { + "description": "BigQuery source import data from.", + "id": "GoogleCloudDiscoveryengineV1alphaBigQuerySource", "properties": { - "content": { - "$ref": "GoogleCloudDiscoveryengineV1alphaDocumentContent", - "description": "The unstructured data linked to this document. Content must be set if this document is under a `CONTENT_REQUIRED` data store." - }, - "derivedStructData": { - "additionalProperties": { - "description": "Properties of the object.", - "type": "any" - }, - "description": "Output only. This field is OUTPUT_ONLY. It contains derived data that are not in the original input document.", - "readOnly": true, - "type": "object" - }, - "id": { - "description": "Immutable. The identifier of the document. Id should conform to [RFC-1034](https://tools.ietf.org/html/rfc1034) standard with a length limit of 63 characters.", + "dataSchema": { + "description": "The schema to use when parsing the data from the source. Supported values for user event imports: * `user_event` (default): One UserEvent per row. Supported values for document imports: * `document` (default): One Document format per row. Each document must have a valid Document.id and one of Document.json_data or Document.struct_data. * `custom`: One custom data per row in arbitrary format that conforms to the defined Schema of the data store. This can only be used by Gen App Builder.", "type": "string" }, - "jsonData": { - "description": "The JSON string representation of the document. It should conform to the registered Schema or an `INVALID_ARGUMENT` error is thrown.", + "datasetId": { + "description": "Required. The BigQuery data set to copy the data from with a length limit of 1,024 characters.", "type": "string" }, - "name": { - "description": "Immutable. The full resource name of the document. Format: `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/branches/{branch}/documents/{document_id}`. This field must be a UTF-8 encoded string with a length limit of 1024 characters.", + "gcsStagingDir": { + "description": "Intermediate Cloud Storage directory used for the import with a length limit of 2,000 characters. Can be specified if one wants to have the BigQuery export to a specific Cloud Storage directory.", "type": "string" }, - "parentDocumentId": { - "description": "The identifier of the parent document. Currently supports at most two level document hierarchy. Id should conform to [RFC-1034](https://tools.ietf.org/html/rfc1034) standard with a length limit of 63 characters.", - "type": "string" + "partitionDate": { + "$ref": "GoogleTypeDate", + "description": "BigQuery time partitioned table's _PARTITIONDATE in YYYY-MM-DD format." }, - "schemaId": { - "description": "The identifier of the schema located in the same data store.", + "projectId": { + "description": "The project ID (can be project # or ID) that the BigQuery source is in with a length limit of 128 characters. If not specified, inherits the project ID from the parent request.", "type": "string" }, - "structData": { - "additionalProperties": { - "description": "Properties of the object.", - "type": "any" - }, - "description": "The structured JSON data for the document. It should conform to the registered Schema or an `INVALID_ARGUMENT` error is thrown.", - "type": "object" + "tableId": { + "description": "Required. The BigQuery table to copy the data from with a length limit of 1,024 characters.", + "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaDocumentContent": { - "description": "Unstructured data linked to this document.", - "id": "GoogleCloudDiscoveryengineV1alphaDocumentContent", + "GoogleCloudDiscoveryengineV1alphaCompleteQueryRequest": { + "description": "Request message for CompletionService.CompleteQuery method.", + "id": "GoogleCloudDiscoveryengineV1alphaCompleteQueryRequest", "properties": { - "mimeType": { - "description": "The MIME type of the content. Supported types: * `application/pdf` (PDF, only native PDFs are supported for now) * `text/html` (HTML) * `application/vnd.openxmlformats-officedocument.wordprocessingml.document` (DOCX) * `application/vnd.openxmlformats-officedocument.presentationml.presentation` (PPTX) * `text/plain` (TXT) See https://www.iana.org/assignments/media-types/media-types.xhtml.", + "dataStore": { + "description": "Required. The parent data store resource name for which the completion is performed, such as `projects/*/locations/global/collections/default_collection/dataStores/default_data_store`.", "type": "string" }, - "rawBytes": { - "description": "The content represented as a stream of bytes. The maximum length is 1,000,000 bytes (1 MB / ~0.95 MiB). Note: As with all `bytes` fields, this field is represented as pure binary in Protocol Buffers and base64-encoded string in JSON. For example, `abc123!?$*\u0026()'-=@~` should be represented as `YWJjMTIzIT8kKiYoKSctPUB+` in JSON. See https://developers.google.com/protocol-buffers/docs/proto3#json.", - "format": "byte", - "type": "string" + "includeTailSuggestions": { + "description": "Indicates if tail suggestions should be returned if there are no suggestions that match the full query. Even if set to true, if there are suggestions that match the full query, those are returned and no tail suggestions are returned.", + "type": "boolean" }, - "uri": { - "description": "The URI of the content. Only Cloud Storage URIs (e.g. `gs://bucket-name/path/to/file`) are supported. The maximum file size is 2.5 MB for text-based formats, 100 MB for other formats.", - "type": "string" - } - }, - "type": "object" - }, - "GoogleCloudDiscoveryengineV1alphaDocumentInfo": { - "description": "Detailed document information associated with a user event.", - "id": "GoogleCloudDiscoveryengineV1alphaDocumentInfo", - "properties": { - "id": { - "description": "The Document resource ID.", + "query": { + "description": "Required. The typeahead input used to fetch suggestions. Maximum length is 128 characters.", "type": "string" }, - "name": { - "description": "The Document resource full name, of the form: `projects/{project_id}/locations/{location}/collections/{collection_id}/dataStores/{data_store_id}/branches/{branch_id}/documents/{document_id}`", + "queryModel": { + "description": "Specifies the autocomplete data model. This overrides any model specified in the Configuration \u003e Autocomplete section of the Cloud console. Currently supported values: * `document` - Using suggestions generated from user-imported documents. * `search-history` - Using suggestions generated from the past history of SearchService.Search API calls. Do not use it when there is no traffic for Search API. * `user-event` - Using suggestions generated from user-imported search events. * `document-completable` - Using suggestions taken directly from user-imported document fields marked as completable. Default values: * `document` is the default model for regular dataStores. * `search-history` is the default model for site search dataStores.", "type": "string" }, - "promotionIds": { - "description": "The promotion IDs associated with this Document. Currently, this field is restricted to at most one ID.", - "items": { - "type": "string" - }, - "type": "array" - }, - "quantity": { - "description": "Quantity of the Document associated with the user event. Defaults to 1. For example, this field will be 2 if two quantities of the same Document are involved in a `add-to-cart` event. Required for events of the following event types: * `add-to-cart` * `purchase`", - "format": "int32", - "type": "integer" - }, - "uri": { - "description": "The Document URI - only allowed for website data stores.", + "userPseudoId": { + "description": "A unique identifier for tracking visitors. For example, this could be implemented with an HTTP cookie, which should be able to uniquely identify a visitor on a single device. This unique identifier should not change if the visitor logs in or out of the website. This field should NOT have a fixed value such as `unknown_visitor`. This should be the same identifier as UserEvent.user_pseudo_id and SearchRequest.user_pseudo_id. The field must be a UTF-8 encoded string with a length limit of 128 characters. Otherwise, an `INVALID_ARGUMENT` error is returned.", "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaDocumentProcessingConfig": { - "description": "A singleton resource of DataStore. It's empty when DataStore is created, which defaults to digital parser. The first call to DataStoreService.UpdateDocumentProcessingConfig method will initialize the config.", - "id": "GoogleCloudDiscoveryengineV1alphaDocumentProcessingConfig", + "GoogleCloudDiscoveryengineV1alphaCompleteQueryResponse": { + "description": "Response message for CompletionService.CompleteQuery method.", + "id": "GoogleCloudDiscoveryengineV1alphaCompleteQueryResponse", "properties": { - "name": { - "description": "Output only. The full resource name of the Document Processing Config. Format: `projects/*/locations/*/collections/*/dataStores/*/documentProcessingConfig`.", - "readOnly": true, - "type": "string" + "querySuggestions": { + "description": "Results of the matched query suggestions. The result list is ordered and the first result is a top suggestion.", + "items": { + "$ref": "GoogleCloudDiscoveryengineV1alphaCompleteQueryResponseQuerySuggestion" + }, + "type": "array" }, - "ocrConfig": { - "$ref": "GoogleCloudDiscoveryengineV1alphaOcrConfig", - "description": "The OCR config. Currently it only applies to PDFs." + "tailMatchTriggered": { + "description": "True if the returned suggestions are all tail suggestions. For tail matching to be triggered, include_tail_suggestions in the request must be true and there must be no suggestions that match the full query.", + "type": "boolean" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaDoubleList": { - "description": "Double list.", - "id": "GoogleCloudDiscoveryengineV1alphaDoubleList", + "GoogleCloudDiscoveryengineV1alphaCompleteQueryResponseQuerySuggestion": { + "description": "Suggestions as search queries.", + "id": "GoogleCloudDiscoveryengineV1alphaCompleteQueryResponseQuerySuggestion", "properties": { - "values": { - "description": "Double values.", + "completableFieldPaths": { + "description": "The unique document field paths that serve as the source of this suggestion if it was generated from completable fields. This field is only populated for the document-completable model.", "items": { - "format": "double", - "type": "number" + "type": "string" }, "type": "array" + }, + "suggestion": { + "description": "The suggestion for the query.", + "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaEnableAdvancedSiteSearchMetadata": { - "description": "Metadata related to the progress of the SiteSearchEngineService.EnableAdvancedSiteSearch operation. This will be returned by the google.longrunning.Operation.metadata field.", - "id": "GoogleCloudDiscoveryengineV1alphaEnableAdvancedSiteSearchMetadata", + "GoogleCloudDiscoveryengineV1alphaCompletionInfo": { + "description": "Detailed completion information including completion attribution token and clicked completion info.", + "id": "GoogleCloudDiscoveryengineV1alphaCompletionInfo", "properties": { - "createTime": { - "description": "Operation create time.", - "format": "google-datetime", - "type": "string" + "selectedPosition": { + "description": "End user selected CompleteQueryResponse.QuerySuggestion.suggestion position, starting from 0.", + "format": "int32", + "type": "integer" }, - "updateTime": { - "description": "Operation last update time. If the operation is done, this is also the finish time.", - "format": "google-datetime", + "selectedSuggestion": { + "description": "End user selected CompleteQueryResponse.QuerySuggestion.suggestion.", "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaEnableAdvancedSiteSearchRequest": { - "description": "Request message for SiteSearchEngineService.EnableAdvancedSiteSearch method.", - "id": "GoogleCloudDiscoveryengineV1alphaEnableAdvancedSiteSearchRequest", - "properties": {}, - "type": "object" - }, - "GoogleCloudDiscoveryengineV1alphaEnableAdvancedSiteSearchResponse": { - "description": "Response message for SiteSearchEngineService.EnableAdvancedSiteSearch method.", - "id": "GoogleCloudDiscoveryengineV1alphaEnableAdvancedSiteSearchResponse", - "properties": {}, - "type": "object" - }, - "GoogleCloudDiscoveryengineV1alphaEngine": { - "description": "Metadata that describes the training and serving parameters of an Engine.", - "id": "GoogleCloudDiscoveryengineV1alphaEngine", + "GoogleCloudDiscoveryengineV1alphaConversation": { + "description": "External conversation proto definition.", + "id": "GoogleCloudDiscoveryengineV1alphaConversation", "properties": { - "chatEngineConfig": { - "$ref": "GoogleCloudDiscoveryengineV1alphaEngineChatEngineConfig", - "description": "Configurations for the Chat Engine. Only applicable if solution_type is SOLUTION_TYPE_CHAT." - }, - "chatEngineMetadata": { - "$ref": "GoogleCloudDiscoveryengineV1alphaEngineChatEngineMetadata", - "description": "Output only. Additional information of the Chat Engine. Only applicable if solution_type is SOLUTION_TYPE_CHAT.", - "readOnly": true - }, - "commonConfig": { - "$ref": "GoogleCloudDiscoveryengineV1alphaEngineCommonConfig", - "description": "Common config spec that specifies the metadata of the engine." - }, - "createTime": { - "description": "Output only. Timestamp the Recommendation Engine was created at.", + "endTime": { + "description": "Output only. The time the conversation finished.", "format": "google-datetime", "readOnly": true, "type": "string" }, - "dataStoreIds": { - "description": "The data stores associated with this engine. For SOLUTION_TYPE_SEARCH and SOLUTION_TYPE_RECOMMENDATION type of engines, they can only associate with at most one data store. If solution_type is SOLUTION_TYPE_CHAT, multiple DataStores in the same Collection can be associated here. Note that when used in CreateEngineRequest, one DataStore id must be provided as the system will use it for necessary intializations.", + "messages": { + "description": "Conversation messages.", "items": { - "type": "string" + "$ref": "GoogleCloudDiscoveryengineV1alphaConversationMessage" }, "type": "array" }, - "displayName": { - "description": "Required. The display name of the engine. Should be human readable. UTF-8 encoded string with limit of 1024 characters.", - "type": "string" - }, - "industryVertical": { - "description": "The industry vertical that the engine registers. The restriction of the Engine industry vertical is based on DataStore: If unspecified, default to `GENERIC`. Vertical on Engine has to match vertical of the DataStore liniked to the engine.", - "enum": [ - "INDUSTRY_VERTICAL_UNSPECIFIED", - "GENERIC", - "MEDIA" - ], - "enumDescriptions": [ - "Value used when unset.", - "The generic vertical for documents that are not specific to any industry vertical.", - "The media industry vertical." - ], - "type": "string" - }, - "mediaRecommendationEngineConfig": { - "$ref": "GoogleCloudDiscoveryengineV1alphaEngineMediaRecommendationEngineConfig", - "description": "Configurations for the Media Engine. Only applicable on the data stores with solution_type SOLUTION_TYPE_RECOMMENDATION and IndustryVertical.MEDIA vertical." - }, "name": { - "description": "Immutable. The fully qualified resource name of the engine. This field must be a UTF-8 encoded string with a length limit of 1024 characters. Format: `projects/{project_number}/locations/{location}/collections/{collection}/engines/{engine}` engine should be 1-63 characters, and valid characters are /a-z0-9*/. Otherwise, an INVALID_ARGUMENT error is returned.", + "description": "Immutable. Fully qualified name `project/*/locations/global/collections/{collection}/dataStore/*/conversations/*` or `project/*/locations/global/collections/{collection}/engines/*/conversations/*`.", "type": "string" }, - "recommendationMetadata": { - "$ref": "GoogleCloudDiscoveryengineV1alphaEngineRecommendationMetadata", - "description": "Output only. Additional information of a recommendation engine. Only applicable if solution_type is SOLUTION_TYPE_RECOMMENDATION.", - "readOnly": true - }, - "searchEngineConfig": { - "$ref": "GoogleCloudDiscoveryengineV1alphaEngineSearchEngineConfig", - "description": "Configurations for the Search Engine. Only applicable if solution_type is SOLUTION_TYPE_SEARCH." - }, - "similarDocumentsConfig": { - "$ref": "GoogleCloudDiscoveryengineV1alphaEngineSimilarDocumentsEngineConfig", - "description": "Additional config specs for a `similar-items` engine." + "startTime": { + "description": "Output only. The time the conversation started.", + "format": "google-datetime", + "readOnly": true, + "type": "string" }, - "solutionType": { - "description": "Required. The solutions of the engine.", + "state": { + "description": "The state of the Conversation.", "enum": [ - "SOLUTION_TYPE_UNSPECIFIED", - "SOLUTION_TYPE_RECOMMENDATION", - "SOLUTION_TYPE_SEARCH", - "SOLUTION_TYPE_CHAT" + "STATE_UNSPECIFIED", + "IN_PROGRESS", + "COMPLETED" ], "enumDescriptions": [ - "Default value.", - "Used for Recommendations AI.", - "Used for Discovery Search.", - "Used for use cases related to the Generative AI agent." + "Unknown.", + "Conversation is currently open.", + "Conversation has been completed." ], "type": "string" }, - "updateTime": { - "description": "Output only. Timestamp the Recommendation Engine was last updated.", - "format": "google-datetime", - "readOnly": true, + "userPseudoId": { + "description": "A unique identifier for tracking users.", "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaEngineChatEngineConfig": { - "description": "Configurations for a Chat Engine.", - "id": "GoogleCloudDiscoveryengineV1alphaEngineChatEngineConfig", + "GoogleCloudDiscoveryengineV1alphaConversationContext": { + "description": "Defines context of the conversation", + "id": "GoogleCloudDiscoveryengineV1alphaConversationContext", "properties": { - "agentCreationConfig": { - "$ref": "GoogleCloudDiscoveryengineV1alphaEngineChatEngineConfigAgentCreationConfig", - "description": "The configurationt generate the Dialogflow agent that is associated to this Engine. Note that these configurations are one-time consumed by and passed to Dialogflow service. It means they cannot be retrieved using EngineService.GetEngine or EngineService.ListEngines API after engine creation." - }, - "dialogflowAgentToLink": { - "description": "The resource name of an exist Dialogflow agent to link to this Chat Engine. Customers can either provide `agent_creation_config` to create agent or provide an agent name that links the agent with the Chat engine. Format: `projects//locations//agents/`. Note that the `dialogflow_agent_to_link` are one-time consumed by and passed to Dialogflow service. It means they cannot be retrieved using EngineService.GetEngine or EngineService.ListEngines API after engine creation. Please use ChatEngineMetadata.dialogflow_agent for actual agent association after Engine is created.", + "activeDocument": { + "description": "The current active document the user opened. It contains the document resource reference.", "type": "string" + }, + "contextDocuments": { + "description": "The current list of documents the user is seeing. It contains the document resource references.", + "items": { + "type": "string" + }, + "type": "array" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaEngineChatEngineConfigAgentCreationConfig": { - "description": "Configurations for generating a Dialogflow agent. Note that these configurations are one-time consumed by and passed to Dialogflow service. It means they cannot be retrieved using EngineService.GetEngine or EngineService.ListEngines API after engine creation.", - "id": "GoogleCloudDiscoveryengineV1alphaEngineChatEngineConfigAgentCreationConfig", + "GoogleCloudDiscoveryengineV1alphaConversationMessage": { + "description": "Defines a conversation message.", + "id": "GoogleCloudDiscoveryengineV1alphaConversationMessage", "properties": { - "business": { - "description": "Name of the company, organization or other entity that the agent represents. Used for knowledge connector LLM prompt and for knowledge search.", + "createTime": { + "description": "Output only. Message creation timestamp.", + "format": "google-datetime", + "readOnly": true, "type": "string" }, - "defaultLanguageCode": { - "description": "Required. The default language of the agent as a language tag. See [Language Support](https://cloud.google.com/dialogflow/docs/reference/language) for a list of the currently supported language codes.", + "reply": { + "$ref": "GoogleCloudDiscoveryengineV1alphaReply", + "description": "Search reply." + }, + "userInput": { + "$ref": "GoogleCloudDiscoveryengineV1alphaTextInput", + "description": "User text input." + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaConverseConversationRequest": { + "description": "Request message for ConversationalSearchService.ConverseConversation method.", + "id": "GoogleCloudDiscoveryengineV1alphaConverseConversationRequest", + "properties": { + "conversation": { + "$ref": "GoogleCloudDiscoveryengineV1alphaConversation", + "description": "The conversation to be used by auto session only. The name field will be ignored as we automatically assign new name for the conversation in auto session." + }, + "filter": { + "description": "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. This will be used to filter search results which may affect the summary response. 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" }, - "location": { - "description": "Agent location for Agent creation, supported values: global/us/eu. If not provided, us Engine will create Agent using us-central-1 by default; eu Engine will create Agent using eu-west-1 by default.", + "name": { + "description": "Required. The resource name of the Conversation to get. Format: `projects/{project_number}/locations/{location_id}/collections/{collection}/dataStores/{data_store_id}/conversations/{conversation_id}`. Use `projects/{project_number}/locations/{location_id}/collections/{collection}/dataStores/{data_store_id}/conversations/-` to activate auto session mode, which automatically creates a new conversation inside a ConverseConversation session.", "type": "string" }, - "timeZone": { - "description": "Required. The time zone of the agent from the [time zone database](https://www.iana.org/time-zones), e.g., America/New_York, Europe/Paris.", + "query": { + "$ref": "GoogleCloudDiscoveryengineV1alphaTextInput", + "description": "Required. Current user input." + }, + "safeSearch": { + "description": "Whether to turn on safe search.", + "type": "boolean" + }, + "servingConfig": { + "description": "The resource name of the Serving Config to use. Format: `projects/{project_number}/locations/{location_id}/collections/{collection}/dataStores/{data_store_id}/servingConfigs/{serving_config_id}` If this is not set, the default serving config will be used.", "type": "string" + }, + "summarySpec": { + "$ref": "GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSummarySpec", + "description": "A specification for configuring the summary returned in the response." + }, + "userLabels": { + "additionalProperties": { + "type": "string" + }, + "description": "The user labels applied to a resource must meet the following requirements: * Each resource can have multiple labels, up to a maximum of 64. * Each label must be a key-value pair. * Keys have a minimum length of 1 character and a maximum length of 63 characters and cannot be empty. Values can be empty and have a maximum length of 63 characters. * Keys and values can contain only lowercase letters, numeric characters, underscores, and dashes. All characters must use UTF-8 encoding, and international characters are allowed. * The key portion of a label must be unique. However, you can use the same key with multiple resources. * Keys must start with a lowercase letter or international character. See [Google Cloud Document](https://cloud.google.com/resource-manager/docs/creating-managing-labels#requirements) for more details.", + "type": "object" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaEngineChatEngineMetadata": { - "description": "Additional information of a Chat Engine. Fields in this message are output only.", - "id": "GoogleCloudDiscoveryengineV1alphaEngineChatEngineMetadata", + "GoogleCloudDiscoveryengineV1alphaConverseConversationResponse": { + "description": "Response message for ConversationalSearchService.ConverseConversation method.", + "id": "GoogleCloudDiscoveryengineV1alphaConverseConversationResponse", "properties": { - "dialogflowAgent": { - "description": "The resource name of a Dialogflow agent, that this Chat Engine refers to. Format: `projects//locations//agents/`.", - "type": "string" + "conversation": { + "$ref": "GoogleCloudDiscoveryengineV1alphaConversation", + "description": "Updated conversation including the answer." + }, + "relatedQuestions": { + "description": "Suggested related questions.", + "items": { + "type": "string" + }, + "type": "array" + }, + "reply": { + "$ref": "GoogleCloudDiscoveryengineV1alphaReply", + "description": "Answer to the current query." + }, + "searchResults": { + "description": "Search Results.", + "items": { + "$ref": "GoogleCloudDiscoveryengineV1alphaSearchResponseSearchResult" + }, + "type": "array" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaEngineCommonConfig": { - "description": "Common configurations for an Engine.", - "id": "GoogleCloudDiscoveryengineV1alphaEngineCommonConfig", + "GoogleCloudDiscoveryengineV1alphaCreateDataStoreMetadata": { + "description": "Metadata related to the progress of the DataStoreService.CreateDataStore operation. This will be returned by the google.longrunning.Operation.metadata field.", + "id": "GoogleCloudDiscoveryengineV1alphaCreateDataStoreMetadata", "properties": { - "companyName": { - "description": "The name of the company, business or entity that is associated with the engine. Setting this may help improve LLM related features.", + "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" }, - "GoogleCloudDiscoveryengineV1alphaEngineMediaRecommendationEngineConfig": { - "description": "Additional config specs for a Media Recommendation engine.", - "id": "GoogleCloudDiscoveryengineV1alphaEngineMediaRecommendationEngineConfig", + "GoogleCloudDiscoveryengineV1alphaCreateEngineMetadata": { + "description": "Metadata related to the progress of the EngineService.CreateEngine operation. This will be returned by the google.longrunning.Operation.metadata field.", + "id": "GoogleCloudDiscoveryengineV1alphaCreateEngineMetadata", "properties": { - "optimizationObjective": { - "description": "The optimization objective e.g. `cvr`. This field together with optimization_objective describe engine metadata to use to control engine training and serving. Currently supported values: `ctr`, `cvr`. If not specified, we choose default based on engine type. Default depends on type of recommendation: `recommended-for-you` =\u003e `ctr` `others-you-may-like` =\u003e `ctr`", + "createTime": { + "description": "Operation create time.", + "format": "google-datetime", "type": "string" }, - "optimizationObjectiveConfig": { - "$ref": "GoogleCloudDiscoveryengineV1alphaEngineMediaRecommendationEngineConfigOptimizationObjectiveConfig", - "description": "Name and value of the custom threshold for cvr optimization_objective. For target_field `watch-time`, target_field_value must be an integer value indicating the media progress time in seconds between (0, 86400] (excludes 0, includes 86400) (e.g., 90). For target_field `watch-percentage`, the target_field_value must be a valid float value between (0, 1.0] (excludes 0, includes 1.0) (e.g., 0.5)." + "updateTime": { + "description": "Operation last update time. If the operation is done, this is also the finish time.", + "format": "google-datetime", + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaCreateSchemaMetadata": { + "description": "Metadata for Create Schema LRO.", + "id": "GoogleCloudDiscoveryengineV1alphaCreateSchemaMetadata", + "properties": { + "createTime": { + "description": "Operation create time.", + "format": "google-datetime", + "type": "string" }, - "trainingState": { - "description": "The training state that the engine is in (e.g. `TRAINING` or `PAUSED`). Since part of the cost of running the service is frequency of training - this can be used to determine when to train engine in order to control cost. If not specified: the default value for `CreateEngine` method is `TRAINING`. The default value for `UpdateEngine` method is to keep the state the same as before.", - "enum": [ - "TRAINING_STATE_UNSPECIFIED", - "PAUSED", - "TRAINING" - ], - "enumDescriptions": [ - "Unspecified training state.", - "The engine training is paused.", - "The engine is training." - ], + "updateTime": { + "description": "Operation last update time. If the operation is done, this is also the finish time.", + "format": "google-datetime", + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaCreateTargetSiteMetadata": { + "description": "Metadata related to the progress of the SiteSearchEngineService.CreateTargetSite operation. This will be returned by the google.longrunning.Operation.metadata field.", + "id": "GoogleCloudDiscoveryengineV1alphaCreateTargetSiteMetadata", + "properties": { + "createTime": { + "description": "Operation create time.", + "format": "google-datetime", "type": "string" }, - "type": { - "description": "Required. The type of engine e.g. `recommended-for-you`. This field together with optimization_objective describe engine metadata to use to control engine training and serving. Currently supported values: `recommended-for-you`, `others-you-may-like`, `more-like-this`, `most-popular-items`.", + "updateTime": { + "description": "Operation last update time. If the operation is done, this is also the finish time.", + "format": "google-datetime", "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaEngineMediaRecommendationEngineConfigOptimizationObjectiveConfig": { - "description": "Custom threshold for `cvr` optimization_objective.", - "id": "GoogleCloudDiscoveryengineV1alphaEngineMediaRecommendationEngineConfigOptimizationObjectiveConfig", + "GoogleCloudDiscoveryengineV1alphaCreateTargetSiteRequest": { + "description": "Request message for SiteSearchEngineService.CreateTargetSite method.", + "id": "GoogleCloudDiscoveryengineV1alphaCreateTargetSiteRequest", "properties": { - "targetField": { - "description": "Required. The name of the field to target. Currently supported values: `watch-percentage`, `watch-time`.", + "parent": { + "description": "Required. Parent resource name of TargetSite, such as `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/siteSearchEngine`.", "type": "string" }, - "targetFieldValueFloat": { - "description": "Required. The threshold to be applied to the target (e.g., 0.5).", - "format": "float", - "type": "number" + "targetSite": { + "$ref": "GoogleCloudDiscoveryengineV1alphaTargetSite", + "description": "Required. The TargetSite to create." } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaEngineRecommendationMetadata": { - "description": "Additional information of a recommendation engine.", - "id": "GoogleCloudDiscoveryengineV1alphaEngineRecommendationMetadata", + "GoogleCloudDiscoveryengineV1alphaCustomAttribute": { + "description": "A custom attribute that is not explicitly modeled in a resource, e.g. UserEvent.", + "id": "GoogleCloudDiscoveryengineV1alphaCustomAttribute", "properties": { - "dataState": { - "description": "Output only. The state of data requirements for this engine: `DATA_OK` and `DATA_ERROR`. Engine cannot be trained if the data is in `DATA_ERROR` state. Engine can have `DATA_ERROR` state even if serving state is `ACTIVE`: engines were trained successfully before, but cannot be refreshed because the underlying engine no longer has sufficient data for training.", + "numbers": { + "description": "The numerical values of this custom attribute. For example, `[2.3, 15.4]` when the key is \"lengths_cm\". Exactly one of CustomAttribute.text or CustomAttribute.numbers should be set. Otherwise, an `INVALID_ARGUMENT` error is returned.", + "items": { + "format": "double", + "type": "number" + }, + "type": "array" + }, + "text": { + "description": "The textual values of this custom attribute. For example, `[\"yellow\", \"green\"]` when the key is \"color\". Empty string is not allowed. Otherwise, an `INVALID_ARGUMENT` error is returned. Exactly one of CustomAttribute.text or CustomAttribute.numbers should be set. Otherwise, an `INVALID_ARGUMENT` error is returned.", + "items": { + "type": "string" + }, + "type": "array" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaDataStore": { + "description": "DataStore captures global settings and configs at the DataStore level.", + "id": "GoogleCloudDiscoveryengineV1alphaDataStore", + "properties": { + "contentConfig": { + "description": "Immutable. The content config of the data store. If this field is unset, the server behavior defaults to ContentConfig.NO_CONTENT.", "enum": [ - "DATA_STATE_UNSPECIFIED", - "DATA_OK", - "DATA_ERROR" + "CONTENT_CONFIG_UNSPECIFIED", + "NO_CONTENT", + "CONTENT_REQUIRED", + "PUBLIC_WEBSITE" ], "enumDescriptions": [ - "Unspecified default value, should never be explicitly set.", - "The engine has sufficient training data.", - "The engine does not have sufficient training data. Error messages can be queried via Stackdriver." + "Default value.", + "Only contains documents without any Document.content.", + "Only contains documents with Document.content.", + "The data store is used for public website search." ], - "readOnly": true, "type": "string" }, - "lastTuneTime": { - "description": "Output only. The timestamp when the latest successful tune finished. Only applicable on Media Recommendation engines.", + "createTime": { + "description": "Output only. Timestamp the DataStore was created at.", "format": "google-datetime", "readOnly": true, "type": "string" }, - "servingState": { - "description": "Output only. The serving state of the engine: `ACTIVE`, `NOT_ACTIVE`.", + "defaultSchemaId": { + "description": "Output only. The id of the default Schema asscociated to this data store.", + "readOnly": true, + "type": "string" + }, + "displayName": { + "description": "Required. The data store display name. This field must be a UTF-8 encoded string with a length limit of 128 characters. Otherwise, an INVALID_ARGUMENT error is returned.", + "type": "string" + }, + "industryVertical": { + "description": "Immutable. The industry vertical that the data store registers.", "enum": [ - "SERVING_STATE_UNSPECIFIED", - "INACTIVE", - "ACTIVE", - "TUNED" + "INDUSTRY_VERTICAL_UNSPECIFIED", + "GENERIC", + "MEDIA" ], "enumDescriptions": [ - "Unspecified serving state.", - "The engine is not serving.", - "The engine is serving and can be queried.", - "The engine is trained on tuned hyperparameters and can be queried." + "Value used when unset.", + "The generic vertical for documents that are not specific to any industry vertical.", + "The media industry vertical." ], - "readOnly": true, "type": "string" }, - "tuningOperation": { - "description": "Output only. The latest tune operation id associated with the engine. Only applicable on Media Recommendation engines. If present, this operation id can be used to determine if there is an ongoing tune for this engine. To check the operation status, send the GetOperation request with this operation id in the engine resource format. If no tuning has happened for this engine, the string is empty.", - "readOnly": true, + "name": { + "description": "Immutable. The full resource name of the data store. Format: `projects/{project}/locations/{location}/collections/{collection_id}/dataStores/{data_store_id}`. This field must be a UTF-8 encoded string with a length limit of 1024 characters.", "type": "string" - } - }, - "type": "object" - }, - "GoogleCloudDiscoveryengineV1alphaEngineSearchEngineConfig": { - "description": "Configurations for a Search Engine.", - "id": "GoogleCloudDiscoveryengineV1alphaEngineSearchEngineConfig", - "properties": { - "searchAddOns": { - "description": "The add-on that this search engine enables.", + }, + "solutionTypes": { + "description": "The solutions that the data store enrolls. Available solutions for each industry_vertical: * `MEDIA`: `SOLUTION_TYPE_RECOMMENDATION` and `SOLUTION_TYPE_SEARCH`. * `SITE_SEARCH`: `SOLUTION_TYPE_SEARCH` is automatically enrolled. Other solutions cannot be enrolled.", "items": { "enum": [ - "SEARCH_ADD_ON_UNSPECIFIED", - "SEARCH_ADD_ON_LLM" + "SOLUTION_TYPE_UNSPECIFIED", + "SOLUTION_TYPE_RECOMMENDATION", + "SOLUTION_TYPE_SEARCH", + "SOLUTION_TYPE_CHAT" ], "enumDescriptions": [ - "Default value when the enum is unspecified. This is invalid to use.", - "Large language model add-on." + "Default value.", + "Used for Recommendations AI.", + "Used for Discovery Search.", + "Used for use cases related to the Generative AI agent." ], "type": "string" }, "type": "array" - }, - "searchTier": { - "description": "The search feature tier of this engine. Different tiers might have different pricing. To learn more, please check the pricing documentation. Defaults to SearchTier.SEARCH_TIER_STANDARD if not specified.", - "enum": [ - "SEARCH_TIER_UNSPECIFIED", - "SEARCH_TIER_STANDARD", - "SEARCH_TIER_ENTERPRISE" - ], - "enumDescriptions": [ - "Default value when the enum is unspecified. This is invalid to use.", - "Standard tier.", - "Enterprise tier." - ], - "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaEngineSimilarDocumentsEngineConfig": { - "description": "Additional config specs for a `similar-items` engine.", - "id": "GoogleCloudDiscoveryengineV1alphaEngineSimilarDocumentsEngineConfig", - "properties": {}, - "type": "object" - }, - "GoogleCloudDiscoveryengineV1alphaEstimateDataSizeMetadata": { - "description": "Metadata related to the progress of the EstimateDataSize operation. This is returned by the google.longrunning.Operation.metadata field.", - "id": "GoogleCloudDiscoveryengineV1alphaEstimateDataSizeMetadata", + "GoogleCloudDiscoveryengineV1alphaDeleteDataStoreMetadata": { + "description": "Metadata related to the progress of the DataStoreService.DeleteDataStore operation. This will be returned by the google.longrunning.Operation.metadata field.", + "id": "GoogleCloudDiscoveryengineV1alphaDeleteDataStoreMetadata", "properties": { "createTime": { "description": "Operation create time.", "format": "google-datetime", "type": "string" - } - }, - "type": "object" - }, - "GoogleCloudDiscoveryengineV1alphaEstimateDataSizeRequest": { - "description": "Request message for EstimateBillingService.EstimateDataSize method", - "id": "GoogleCloudDiscoveryengineV1alphaEstimateDataSizeRequest", - "properties": { - "fileDataSource": { - "$ref": "GoogleCloudDiscoveryengineV1alphaEstimateDataSizeRequestFileDataSource", - "description": "Structured or unstructured data." }, - "websiteDataSource": { - "$ref": "GoogleCloudDiscoveryengineV1alphaEstimateDataSizeRequestWebsiteDataSource", - "description": "Website data." + "updateTime": { + "description": "Operation last update time. If the operation is done, this is also the finish time.", + "format": "google-datetime", + "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaEstimateDataSizeRequestFileDataSource": { - "description": "Data source contains files either in Cloud Storage or BigQuery.", - "id": "GoogleCloudDiscoveryengineV1alphaEstimateDataSizeRequestFileDataSource", + "GoogleCloudDiscoveryengineV1alphaDeleteEngineMetadata": { + "description": "Metadata related to the progress of the EngineService.DeleteEngine operation. This will be returned by the google.longrunning.Operation.metadata field.", + "id": "GoogleCloudDiscoveryengineV1alphaDeleteEngineMetadata", "properties": { - "bigquerySource": { - "$ref": "GoogleCloudDiscoveryengineV1alphaBigQuerySource", - "description": "BigQuery input source." + "createTime": { + "description": "Operation create time.", + "format": "google-datetime", + "type": "string" }, - "gcsSource": { - "$ref": "GoogleCloudDiscoveryengineV1alphaGcsSource", - "description": "Cloud Storage location for the input content." + "updateTime": { + "description": "Operation last update time. If the operation is done, this is also the finish time.", + "format": "google-datetime", + "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaEstimateDataSizeRequestWebsiteDataSource": { - "description": "Data source is a set of website patterns that we crawl to get the total number of websites.", - "id": "GoogleCloudDiscoveryengineV1alphaEstimateDataSizeRequestWebsiteDataSource", + "GoogleCloudDiscoveryengineV1alphaDeleteSchemaMetadata": { + "description": "Metadata for DeleteSchema LRO.", + "id": "GoogleCloudDiscoveryengineV1alphaDeleteSchemaMetadata", "properties": { - "estimatorUriPatterns": { - "description": "Required. The URI patterns to estimate the data sizes. At most 10 patterns are allowed, otherwise an INVALID_ARGUMENT error is thrown.", - "items": { - "$ref": "GoogleCloudDiscoveryengineV1alphaEstimateDataSizeRequestWebsiteDataSourceEstimatorUriPattern" - }, - "type": "array" + "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" }, - "GoogleCloudDiscoveryengineV1alphaEstimateDataSizeRequestWebsiteDataSourceEstimatorUriPattern": { - "description": "URI patterns that we use to crawl.", - "id": "GoogleCloudDiscoveryengineV1alphaEstimateDataSizeRequestWebsiteDataSourceEstimatorUriPattern", + "GoogleCloudDiscoveryengineV1alphaDeleteTargetSiteMetadata": { + "description": "Metadata related to the progress of the SiteSearchEngineService.DeleteTargetSite operation. This will be returned by the google.longrunning.Operation.metadata field.", + "id": "GoogleCloudDiscoveryengineV1alphaDeleteTargetSiteMetadata", "properties": { - "exactMatch": { - "description": "Whether we infer the generated URI or use the exact provided one.", - "type": "boolean" - }, - "exclusive": { - "description": "Whether the pattern is exclusive or not. If set to true, the pattern is considered exclusive. If unset or set to false, the pattern is considered inclusive by default.", - "type": "boolean" + "createTime": { + "description": "Operation create time.", + "format": "google-datetime", + "type": "string" }, - "providedUriPattern": { - "description": "User provided URI pattern. For example, `foo.com/bar/*`.", + "updateTime": { + "description": "Operation last update time. If the operation is done, this is also the finish time.", + "format": "google-datetime", "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaEstimateDataSizeResponse": { - "description": "Response of the EstimateDataSize request. If the long running operation was successful, then this message is returned by the google.longrunning.Operations.response field if the operation was successful.", - "id": "GoogleCloudDiscoveryengineV1alphaEstimateDataSizeResponse", + "GoogleCloudDiscoveryengineV1alphaDisableAdvancedSiteSearchMetadata": { + "description": "Metadata related to the progress of the SiteSearchEngineService.DisableAdvancedSiteSearch operation. This will be returned by the google.longrunning.Operation.metadata field.", + "id": "GoogleCloudDiscoveryengineV1alphaDisableAdvancedSiteSearchMetadata", "properties": { - "dataSizeBytes": { - "description": "Data size in terms of bytes.", - "format": "int64", + "createTime": { + "description": "Operation create time.", + "format": "google-datetime", "type": "string" }, - "documentCount": { - "description": "Total number of documents.", - "format": "int64", + "updateTime": { + "description": "Operation last update time. If the operation is done, this is also the finish time.", + "format": "google-datetime", "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaFetchDomainVerificationStatusResponse": { - "description": "Response message for SiteSearchEngineService.FetchDomainVerificationStatus method.", - "id": "GoogleCloudDiscoveryengineV1alphaFetchDomainVerificationStatusResponse", + "GoogleCloudDiscoveryengineV1alphaDisableAdvancedSiteSearchRequest": { + "description": "Request message for SiteSearchEngineService.DisableAdvancedSiteSearch method.", + "id": "GoogleCloudDiscoveryengineV1alphaDisableAdvancedSiteSearchRequest", + "properties": {}, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaDisableAdvancedSiteSearchResponse": { + "description": "Response message for SiteSearchEngineService.DisableAdvancedSiteSearch method.", + "id": "GoogleCloudDiscoveryengineV1alphaDisableAdvancedSiteSearchResponse", + "properties": {}, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaDocument": { + "description": "Document captures all raw metadata information of items to be recommended or searched.", + "id": "GoogleCloudDiscoveryengineV1alphaDocument", "properties": { - "nextPageToken": { - "description": "A token that can be sent as `page_token` to retrieve the next page. If this field is omitted, there are no subsequent pages.", - "type": "string" + "content": { + "$ref": "GoogleCloudDiscoveryengineV1alphaDocumentContent", + "description": "The unstructured data linked to this document. Content must be set if this document is under a `CONTENT_REQUIRED` data store." }, - "targetSites": { - "description": "List of TargetSites containing the site verification status.", - "items": { - "$ref": "GoogleCloudDiscoveryengineV1alphaTargetSite" + "derivedStructData": { + "additionalProperties": { + "description": "Properties of the object.", + "type": "any" }, - "type": "array" + "description": "Output only. This field is OUTPUT_ONLY. It contains derived data that are not in the original input document.", + "readOnly": true, + "type": "object" }, - "totalSize": { - "description": "The total number of items matching the request. This will always be populated in the response.", - "format": "int32", - "type": "integer" + "id": { + "description": "Immutable. The identifier of the document. Id should conform to [RFC-1034](https://tools.ietf.org/html/rfc1034) standard with a length limit of 63 characters.", + "type": "string" + }, + "jsonData": { + "description": "The JSON string representation of the document. It should conform to the registered Schema or an `INVALID_ARGUMENT` error is thrown.", + "type": "string" + }, + "name": { + "description": "Immutable. The full resource name of the document. Format: `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/branches/{branch}/documents/{document_id}`. This field must be a UTF-8 encoded string with a length limit of 1024 characters.", + "type": "string" + }, + "parentDocumentId": { + "description": "The identifier of the parent document. Currently supports at most two level document hierarchy. Id should conform to [RFC-1034](https://tools.ietf.org/html/rfc1034) standard with a length limit of 63 characters.", + "type": "string" + }, + "schemaId": { + "description": "The identifier of the schema located in the same data store.", + "type": "string" + }, + "structData": { + "additionalProperties": { + "description": "Properties of the object.", + "type": "any" + }, + "description": "The structured JSON data for the document. It should conform to the registered Schema or an `INVALID_ARGUMENT` error is thrown.", + "type": "object" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaFieldConfig": { - "description": "Configurations for fields of a schema. For example, configuring a field is indexable, or searchable.", - "id": "GoogleCloudDiscoveryengineV1alphaFieldConfig", + "GoogleCloudDiscoveryengineV1alphaDocumentContent": { + "description": "Unstructured data linked to this document.", + "id": "GoogleCloudDiscoveryengineV1alphaDocumentContent", "properties": { - "completableOption": { - "description": "If completable_option is COMPLETABLE_ENABLED, field values are directly used and returned as suggestions for Autocomplete in CompletionService.CompleteQuery. If completable_option is unset, the server behavior defaults to COMPLETABLE_DISABLED for fields that support setting completable options, which are just `string` fields. For those fields that do not support setting completable options, the server will skip completable option setting, and setting completable_option for those fields will throw `INVALID_ARGUMENT` error.", - "enum": [ - "COMPLETABLE_OPTION_UNSPECIFIED", - "COMPLETABLE_ENABLED", - "COMPLETABLE_DISABLED" - ], - "enumDescriptions": [ - "Value used when unset.", - "Completable option enabled for a schema field.", - "Completable option disabled for a schema field." - ], - "type": "string" - }, - "dynamicFacetableOption": { - "description": "If dynamic_facetable_option is DYNAMIC_FACETABLE_ENABLED, field values are available for dynamic facet. Could only be DYNAMIC_FACETABLE_DISABLED if FieldConfig.indexable_option is INDEXABLE_DISABLED. Otherwise, an `INVALID_ARGUMENT` error will be returned. If dynamic_facetable_option is unset, the server behavior defaults to DYNAMIC_FACETABLE_DISABLED for fields that support setting dynamic facetable options. For those fields that do not support setting dynamic facetable options, such as `object` and `boolean`, the server will skip dynamic facetable option setting, and setting dynamic_facetable_option for those fields will throw `INVALID_ARGUMENT` error.", - "enum": [ - "DYNAMIC_FACETABLE_OPTION_UNSPECIFIED", - "DYNAMIC_FACETABLE_ENABLED", - "DYNAMIC_FACETABLE_DISABLED" - ], - "enumDescriptions": [ - "Value used when unset.", - "Dynamic facetable option enabled for a schema field.", - "Dynamic facetable option disabled for a schema field." - ], + "mimeType": { + "description": "The MIME type of the content. Supported types: * `application/pdf` (PDF, only native PDFs are supported for now) * `text/html` (HTML) * `application/vnd.openxmlformats-officedocument.wordprocessingml.document` (DOCX) * `application/vnd.openxmlformats-officedocument.presentationml.presentation` (PPTX) * `text/plain` (TXT) See https://www.iana.org/assignments/media-types/media-types.xhtml.", "type": "string" }, - "fieldPath": { - "description": "Required. Field path of the schema field. For example: `title`, `description`, `release_info.release_year`.", + "rawBytes": { + "description": "The content represented as a stream of bytes. The maximum length is 1,000,000 bytes (1 MB / ~0.95 MiB). Note: As with all `bytes` fields, this field is represented as pure binary in Protocol Buffers and base64-encoded string in JSON. For example, `abc123!?$*\u0026()'-=@~` should be represented as `YWJjMTIzIT8kKiYoKSctPUB+` in JSON. See https://developers.google.com/protocol-buffers/docs/proto3#json.", + "format": "byte", "type": "string" }, - "fieldType": { - "description": "Output only. Raw type of the field.", - "enum": [ - "FIELD_TYPE_UNSPECIFIED", - "OBJECT", - "STRING", - "NUMBER", - "INTEGER", - "BOOLEAN", - "GEOLOCATION", - "DATETIME" - ], - "enumDescriptions": [ - "Field type is unspecified.", - "Field value type is Object.", - "Field value type is String.", - "Field value type is Number.", - "Field value type is Integer.", - "Field value type is Boolean.", - "Field value type is Geolocation.", - "Field value type is Datetime." - ], - "readOnly": true, + "uri": { + "description": "The URI of the content. Only Cloud Storage URIs (e.g. `gs://bucket-name/path/to/file`) are supported. The maximum file size is 2.5 MB for text-based formats, 100 MB for other formats.", "type": "string" - }, - "indexableOption": { - "description": "If indexable_option is INDEXABLE_ENABLED, field values are indexed so that it can be filtered or faceted in SearchService.Search. If indexable_option is unset, the server behavior defaults to INDEXABLE_DISABLED for fields that support setting indexable options. For those fields that do not support setting indexable options, such as `object` and `boolean` and key properties, the server will skip indexable_option setting, and setting indexable_option for those fields will throw `INVALID_ARGUMENT` error.", - "enum": [ - "INDEXABLE_OPTION_UNSPECIFIED", - "INDEXABLE_ENABLED", - "INDEXABLE_DISABLED" - ], - "enumDescriptions": [ - "Value used when unset.", - "Indexable option enabled for a schema field.", - "Indexable option disabled for a schema field." - ], + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaDocumentInfo": { + "description": "Detailed document information associated with a user event.", + "id": "GoogleCloudDiscoveryengineV1alphaDocumentInfo", + "properties": { + "id": { + "description": "The Document resource ID.", "type": "string" }, - "keyPropertyType": { - "description": "Output only. Type of the key property that this field is mapped to. Empty string if this is not annotated as mapped to a key property. Example types are `title`, `description`. Full list is defined by `keyPropertyMapping` in the schema field annotation. If the schema field has a `KeyPropertyMapping` annotation, `indexable_option` and `searchable_option` of this field cannot be modified.", - "readOnly": true, + "name": { + "description": "The Document resource full name, of the form: `projects/{project_id}/locations/{location}/collections/{collection_id}/dataStores/{data_store_id}/branches/{branch_id}/documents/{document_id}`", "type": "string" }, - "recsFilterableOption": { - "description": "If recs_filterable_option is FILTERABLE_ENABLED, field values are filterable by filter expression in RecommendationService.Recommend. If FILTERABLE_ENABLED but the field type is numerical, field values are not filterable by text queries in RecommendationService.Recommend. Only textual fields are supported. If recs_filterable_option is unset, the default setting is FILTERABLE_DISABLED for fields that support setting filterable options. When a field set to [FILTERABLE_DISABLED] is filtered, a warning is generated and an empty result is returned.", - "enum": [ - "FILTERABLE_OPTION_UNSPECIFIED", - "FILTERABLE_ENABLED", - "FILTERABLE_DISABLED" - ], - "enumDescriptions": [ - "Value used when unset.", - "Filterable option enabled for a schema field.", - "Filterable option disabled for a schema field." - ], - "type": "string" + "promotionIds": { + "description": "The promotion IDs associated with this Document. Currently, this field is restricted to at most one ID.", + "items": { + "type": "string" + }, + "type": "array" }, - "retrievableOption": { - "description": "If retrievable_option is RETRIEVABLE_ENABLED, field values are included in the search results. If retrievable_option is unset, the server behavior defaults to RETRIEVABLE_DISABLED for fields that support setting retrievable options. For those fields that do not support setting retrievable options, such as `object` and `boolean`, the server will skip retrievable option setting, and setting retrievable_option for those fields will throw `INVALID_ARGUMENT` error.", - "enum": [ - "RETRIEVABLE_OPTION_UNSPECIFIED", - "RETRIEVABLE_ENABLED", - "RETRIEVABLE_DISABLED" - ], - "enumDescriptions": [ - "Value used when unset.", - "Retrievable option enabled for a schema field.", - "Retrievable option disabled for a schema field." - ], - "type": "string" + "quantity": { + "description": "Quantity of the Document associated with the user event. Defaults to 1. For example, this field will be 2 if two quantities of the same Document are involved in a `add-to-cart` event. Required for events of the following event types: * `add-to-cart` * `purchase`", + "format": "int32", + "type": "integer" }, - "searchableOption": { - "description": "If searchable_option is SEARCHABLE_ENABLED, field values are searchable by text queries in SearchService.Search. If SEARCHABLE_ENABLED but field type is numerical, field values will not be searchable by text queries in SearchService.Search, as there are no text values associated to numerical fields. If searchable_option is unset, the server behavior defaults to SEARCHABLE_DISABLED for fields that support setting searchable options. Only `string` fields that have no key property mapping support setting searchable_option. For those fields that do not support setting searchable options, the server will skip searchable option setting, and setting searchable_option for those fields will throw `INVALID_ARGUMENT` error.", - "enum": [ - "SEARCHABLE_OPTION_UNSPECIFIED", - "SEARCHABLE_ENABLED", - "SEARCHABLE_DISABLED" - ], - "enumDescriptions": [ - "Value used when unset.", - "Searchable option enabled for a schema field.", - "Searchable option disabled for a schema field." - ], + "uri": { + "description": "The Document URI - only allowed for website data stores.", "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaGcsSource": { - "description": "Cloud Storage location for input content.", - "id": "GoogleCloudDiscoveryengineV1alphaGcsSource", + "GoogleCloudDiscoveryengineV1alphaDocumentProcessingConfig": { + "description": "A singleton resource of DataStore. It's empty when DataStore is created, which defaults to digital parser. The first call to DataStoreService.UpdateDocumentProcessingConfig method will initialize the config.", + "id": "GoogleCloudDiscoveryengineV1alphaDocumentProcessingConfig", "properties": { - "dataSchema": { - "description": "The schema to use when parsing the data from the source. Supported values for document imports: * `document` (default): One JSON Document per line. Each document must have a valid Document.id. * `content`: Unstructured data (e.g. PDF, HTML). Each file matched by `input_uris` becomes a document, with the ID set to the first 128 bits of SHA256(URI) encoded as a hex string. * `custom`: One custom data JSON per row in arbitrary format that conforms to the defined Schema of the data store. This can only be used by Gen App Builder. * `csv`: A CSV file with header conforming to the defined Schema of the data store. Each entry after the header is imported as a Document. This can only be used by Gen App Builder. Supported values for user even imports: * `user_event` (default): One JSON UserEvent per line.", + "name": { + "description": "Output only. The full resource name of the Document Processing Config. Format: `projects/*/locations/*/collections/*/dataStores/*/documentProcessingConfig`.", + "readOnly": true, "type": "string" }, - "inputUris": { - "description": "Required. Cloud Storage URIs to input files. URI can be up to 2000 characters long. URIs can match the full object path (for example, `gs://bucket/directory/object.json`) or a pattern matching one or more files, such as `gs://bucket/directory/*.json`. A request can contain at most 100 files (or 100,000 files if `data_schema` is `content`). Each file can be up to 2 GB (or 100 MB if `data_schema` is `content`).", + "ocrConfig": { + "$ref": "GoogleCloudDiscoveryengineV1alphaOcrConfig", + "description": "The OCR config. Currently it only applies to PDFs." + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaDoubleList": { + "description": "Double list.", + "id": "GoogleCloudDiscoveryengineV1alphaDoubleList", + "properties": { + "values": { + "description": "Double values.", "items": { - "type": "string" + "format": "double", + "type": "number" }, "type": "array" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaImportDocumentsMetadata": { - "description": "Metadata related to the progress of the ImportDocuments operation. This is returned by the google.longrunning.Operation.metadata field.", - "id": "GoogleCloudDiscoveryengineV1alphaImportDocumentsMetadata", + "GoogleCloudDiscoveryengineV1alphaEnableAdvancedSiteSearchMetadata": { + "description": "Metadata related to the progress of the SiteSearchEngineService.EnableAdvancedSiteSearch operation. This will be returned by the google.longrunning.Operation.metadata field.", + "id": "GoogleCloudDiscoveryengineV1alphaEnableAdvancedSiteSearchMetadata", "properties": { "createTime": { "description": "Operation create time.", "format": "google-datetime", "type": "string" }, - "failureCount": { - "description": "Count of entries that encountered errors while processing.", - "format": "int64", - "type": "string" - }, - "successCount": { - "description": "Count of entries that were processed successfully.", - "format": "int64", - "type": "string" - }, "updateTime": { "description": "Operation last update time. If the operation is done, this is also the finish time.", "format": "google-datetime", @@ -6399,383 +6379,415 @@ }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaImportDocumentsRequest": { - "description": "Request message for Import methods.", - "id": "GoogleCloudDiscoveryengineV1alphaImportDocumentsRequest", + "GoogleCloudDiscoveryengineV1alphaEnableAdvancedSiteSearchRequest": { + "description": "Request message for SiteSearchEngineService.EnableAdvancedSiteSearch method.", + "id": "GoogleCloudDiscoveryengineV1alphaEnableAdvancedSiteSearchRequest", + "properties": {}, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaEnableAdvancedSiteSearchResponse": { + "description": "Response message for SiteSearchEngineService.EnableAdvancedSiteSearch method.", + "id": "GoogleCloudDiscoveryengineV1alphaEnableAdvancedSiteSearchResponse", + "properties": {}, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaEngine": { + "description": "Metadata that describes the training and serving parameters of an Engine.", + "id": "GoogleCloudDiscoveryengineV1alphaEngine", "properties": { - "autoGenerateIds": { - "description": "Whether to automatically generate IDs for the documents if absent. If set to `true`, Document.ids are automatically generated based on the hash of the payload, where IDs may not be consistent during multiple imports. In which case ReconciliationMode.FULL is highly recommended to avoid duplicate contents. If unset or set to `false`, Document.ids have to be specified using id_field, otherwise, documents without IDs fail to be imported. Only set this field when using GcsSource or BigQuerySource, and when GcsSource.data_schema or BigQuerySource.data_schema is `custom` or `csv`. Otherwise, an INVALID_ARGUMENT error is thrown.", - "type": "boolean" - }, - "bigquerySource": { - "$ref": "GoogleCloudDiscoveryengineV1alphaBigQuerySource", - "description": "BigQuery input source." + "chatEngineConfig": { + "$ref": "GoogleCloudDiscoveryengineV1alphaEngineChatEngineConfig", + "description": "Configurations for the Chat Engine. Only applicable if solution_type is SOLUTION_TYPE_CHAT." }, - "errorConfig": { - "$ref": "GoogleCloudDiscoveryengineV1alphaImportErrorConfig", - "description": "The desired location of errors incurred during the Import." + "chatEngineMetadata": { + "$ref": "GoogleCloudDiscoveryengineV1alphaEngineChatEngineMetadata", + "description": "Output only. Additional information of the Chat Engine. Only applicable if solution_type is SOLUTION_TYPE_CHAT.", + "readOnly": true }, - "gcsSource": { - "$ref": "GoogleCloudDiscoveryengineV1alphaGcsSource", - "description": "Cloud Storage location for the input content." + "commonConfig": { + "$ref": "GoogleCloudDiscoveryengineV1alphaEngineCommonConfig", + "description": "Common config spec that specifies the metadata of the engine." }, - "idField": { - "description": "The field in the Cloud Storage and BigQuery sources that indicates the unique IDs of the documents. For GcsSource it is the key of the JSON field. For instance, `my_id` for JSON `{\"my_id\": \"some_uuid\"}`. For BigQuerySource it is the column name of the BigQuery table where the unique ids are stored. The values of the JSON field or the BigQuery column are used as the Document.ids. The JSON field or the BigQuery column must be of string type, and the values must be set as valid strings conform to [RFC-1034](https://tools.ietf.org/html/rfc1034) with 1-63 characters. Otherwise, documents without valid IDs fail to be imported. Only set this field when using GcsSource or BigQuerySource, and when GcsSource.data_schema or BigQuerySource.data_schema is `custom`. And only set this field when auto_generate_ids is unset or set as `false`. Otherwise, an INVALID_ARGUMENT error is thrown. If it is unset, a default value `_id` is used when importing from the allowed data sources.", + "createTime": { + "description": "Output only. Timestamp the Recommendation Engine was created at.", + "format": "google-datetime", + "readOnly": true, "type": "string" }, - "inlineSource": { - "$ref": "GoogleCloudDiscoveryengineV1alphaImportDocumentsRequestInlineSource", - "description": "The Inline source for the input content for documents." + "dataStoreIds": { + "description": "The data stores associated with this engine. For SOLUTION_TYPE_SEARCH and SOLUTION_TYPE_RECOMMENDATION type of engines, they can only associate with at most one data store. If solution_type is SOLUTION_TYPE_CHAT, multiple DataStores in the same Collection can be associated here. Note that when used in CreateEngineRequest, one DataStore id must be provided as the system will use it for necessary initializations.", + "items": { + "type": "string" + }, + "type": "array" }, - "reconciliationMode": { - "description": "The mode of reconciliation between existing documents and the documents to be imported. Defaults to ReconciliationMode.INCREMENTAL.", + "displayName": { + "description": "Required. The display name of the engine. Should be human readable. UTF-8 encoded string with limit of 1024 characters.", + "type": "string" + }, + "industryVertical": { + "description": "The industry vertical that the engine registers. The restriction of the Engine industry vertical is based on DataStore: If unspecified, default to `GENERIC`. Vertical on Engine has to match vertical of the DataStore liniked to the engine.", "enum": [ - "RECONCILIATION_MODE_UNSPECIFIED", - "INCREMENTAL", - "FULL" + "INDUSTRY_VERTICAL_UNSPECIFIED", + "GENERIC", + "MEDIA" ], "enumDescriptions": [ - "Defaults to `INCREMENTAL`.", - "Inserts new documents or updates existing documents.", - "Calculates diff and replaces the entire document dataset. Existing documents may be deleted if they are not present in the source location." + "Value used when unset.", + "The generic vertical for documents that are not specific to any industry vertical.", + "The media industry vertical." ], "type": "string" + }, + "mediaRecommendationEngineConfig": { + "$ref": "GoogleCloudDiscoveryengineV1alphaEngineMediaRecommendationEngineConfig", + "description": "Configurations for the Media Engine. Only applicable on the data stores with solution_type SOLUTION_TYPE_RECOMMENDATION and IndustryVertical.MEDIA vertical." + }, + "name": { + "description": "Immutable. The fully qualified resource name of the engine. This field must be a UTF-8 encoded string with a length limit of 1024 characters. Format: `projects/{project_number}/locations/{location}/collections/{collection}/engines/{engine}` engine should be 1-63 characters, and valid characters are /a-z0-9*/. Otherwise, an INVALID_ARGUMENT error is returned.", + "type": "string" + }, + "recommendationMetadata": { + "$ref": "GoogleCloudDiscoveryengineV1alphaEngineRecommendationMetadata", + "description": "Output only. Additional information of a recommendation engine. Only applicable if solution_type is SOLUTION_TYPE_RECOMMENDATION.", + "readOnly": true + }, + "searchEngineConfig": { + "$ref": "GoogleCloudDiscoveryengineV1alphaEngineSearchEngineConfig", + "description": "Configurations for the Search Engine. Only applicable if solution_type is SOLUTION_TYPE_SEARCH." + }, + "similarDocumentsConfig": { + "$ref": "GoogleCloudDiscoveryengineV1alphaEngineSimilarDocumentsEngineConfig", + "description": "Additional config specs for a `similar-items` engine." + }, + "solutionType": { + "description": "Required. The solutions of the engine.", + "enum": [ + "SOLUTION_TYPE_UNSPECIFIED", + "SOLUTION_TYPE_RECOMMENDATION", + "SOLUTION_TYPE_SEARCH", + "SOLUTION_TYPE_CHAT" + ], + "enumDescriptions": [ + "Default value.", + "Used for Recommendations AI.", + "Used for Discovery Search.", + "Used for use cases related to the Generative AI agent." + ], + "type": "string" + }, + "updateTime": { + "description": "Output only. Timestamp the Recommendation Engine was last updated.", + "format": "google-datetime", + "readOnly": true, + "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaImportDocumentsRequestInlineSource": { - "description": "The inline source for the input config for ImportDocuments method.", - "id": "GoogleCloudDiscoveryengineV1alphaImportDocumentsRequestInlineSource", + "GoogleCloudDiscoveryengineV1alphaEngineChatEngineConfig": { + "description": "Configurations for a Chat Engine.", + "id": "GoogleCloudDiscoveryengineV1alphaEngineChatEngineConfig", "properties": { - "documents": { - "description": "Required. A list of documents to update/create. Each document must have a valid Document.id. Recommended max of 100 items.", - "items": { - "$ref": "GoogleCloudDiscoveryengineV1alphaDocument" - }, - "type": "array" + "agentCreationConfig": { + "$ref": "GoogleCloudDiscoveryengineV1alphaEngineChatEngineConfigAgentCreationConfig", + "description": "The configurationt generate the Dialogflow agent that is associated to this Engine. Note that these configurations are one-time consumed by and passed to Dialogflow service. It means they cannot be retrieved using EngineService.GetEngine or EngineService.ListEngines API after engine creation." + }, + "dialogflowAgentToLink": { + "description": "The resource name of an exist Dialogflow agent to link to this Chat Engine. Customers can either provide `agent_creation_config` to create agent or provide an agent name that links the agent with the Chat engine. Format: `projects//locations//agents/`. Note that the `dialogflow_agent_to_link` are one-time consumed by and passed to Dialogflow service. It means they cannot be retrieved using EngineService.GetEngine or EngineService.ListEngines API after engine creation. Please use ChatEngineMetadata.dialogflow_agent for actual agent association after Engine is created.", + "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaImportDocumentsResponse": { - "description": "Response of the ImportDocumentsRequest. If the long running operation is done, then this message is returned by the google.longrunning.Operations.response field if the operation was successful.", - "id": "GoogleCloudDiscoveryengineV1alphaImportDocumentsResponse", + "GoogleCloudDiscoveryengineV1alphaEngineChatEngineConfigAgentCreationConfig": { + "description": "Configurations for generating a Dialogflow agent. Note that these configurations are one-time consumed by and passed to Dialogflow service. It means they cannot be retrieved using EngineService.GetEngine or EngineService.ListEngines API after engine creation.", + "id": "GoogleCloudDiscoveryengineV1alphaEngineChatEngineConfigAgentCreationConfig", "properties": { - "errorConfig": { - "$ref": "GoogleCloudDiscoveryengineV1alphaImportErrorConfig", - "description": "Echoes the destination for the complete errors in the request if set." + "business": { + "description": "Name of the company, organization or other entity that the agent represents. Used for knowledge connector LLM prompt and for knowledge search.", + "type": "string" }, - "errorSamples": { - "description": "A sample of errors encountered while processing the request.", - "items": { - "$ref": "GoogleRpcStatus" - }, - "type": "array" + "defaultLanguageCode": { + "description": "Required. The default language of the agent as a language tag. See [Language Support](https://cloud.google.com/dialogflow/docs/reference/language) for a list of the currently supported language codes.", + "type": "string" + }, + "location": { + "description": "Agent location for Agent creation, supported values: global/us/eu. If not provided, us Engine will create Agent using us-central-1 by default; eu Engine will create Agent using eu-west-1 by default.", + "type": "string" + }, + "timeZone": { + "description": "Required. The time zone of the agent from the [time zone database](https://www.iana.org/time-zones), e.g., America/New_York, Europe/Paris.", + "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaImportErrorConfig": { - "description": "Configuration of destination for Import related errors.", - "id": "GoogleCloudDiscoveryengineV1alphaImportErrorConfig", + "GoogleCloudDiscoveryengineV1alphaEngineChatEngineMetadata": { + "description": "Additional information of a Chat Engine. Fields in this message are output only.", + "id": "GoogleCloudDiscoveryengineV1alphaEngineChatEngineMetadata", "properties": { - "gcsPrefix": { - "description": "Cloud Storage prefix for import errors. This must be an empty, existing Cloud Storage directory. Import errors are written to sharded files in this directory, one per line, as a JSON-encoded `google.rpc.Status` message.", + "dialogflowAgent": { + "description": "The resource name of a Dialogflow agent, that this Chat Engine refers to. Format: `projects//locations//agents/`.", "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesMetadata": { - "description": "Metadata related to the progress of the ImportSuggestionDenyListEntries operation. This is returned by the google.longrunning.Operation.metadata field.", - "id": "GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesMetadata", + "GoogleCloudDiscoveryengineV1alphaEngineCommonConfig": { + "description": "Common configurations for an Engine.", + "id": "GoogleCloudDiscoveryengineV1alphaEngineCommonConfig", "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", + "companyName": { + "description": "Immutable. The name of the company, business or entity that is associated with the engine. Setting this may help improve LLM related features.", "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesRequest": { - "description": "Request message for CompletionService.ImportSuggestionDenyListEntries method.", - "id": "GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesRequest", + "GoogleCloudDiscoveryengineV1alphaEngineMediaRecommendationEngineConfig": { + "description": "Additional config specs for a Media Recommendation engine.", + "id": "GoogleCloudDiscoveryengineV1alphaEngineMediaRecommendationEngineConfig", "properties": { - "gcsSource": { - "$ref": "GoogleCloudDiscoveryengineV1alphaGcsSource", - "description": "Cloud Storage location for the input content. Only 1 file can be specified that contains all entries to import. Supported values `gcs_source.schema` for autocomplete suggestion deny list entry imports: * `suggestion_deny_list` (default): One JSON [SuggestionDenyListEntry] per line." + "optimizationObjective": { + "description": "The optimization objective. e.g., `cvr`. This field together with optimization_objective describe engine metadata to use to control engine training and serving. Currently supported values: `ctr`, `cvr`. If not specified, we choose default based on engine type. Default depends on type of recommendation: `recommended-for-you` =\u003e `ctr` `others-you-may-like` =\u003e `ctr`", + "type": "string" }, - "inlineSource": { - "$ref": "GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesRequestInlineSource", - "description": "The Inline source for the input content for suggestion deny list entries." - } - }, - "type": "object" - }, - "GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesRequestInlineSource": { - "description": "The inline source for SuggestionDenyListEntry.", - "id": "GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesRequestInlineSource", - "properties": { - "entries": { - "description": "Required. A list of all denylist entries to import. Max of 1000 items.", - "items": { - "$ref": "GoogleCloudDiscoveryengineV1alphaSuggestionDenyListEntry" - }, - "type": "array" + "optimizationObjectiveConfig": { + "$ref": "GoogleCloudDiscoveryengineV1alphaEngineMediaRecommendationEngineConfigOptimizationObjectiveConfig", + "description": "Name and value of the custom threshold for cvr optimization_objective. For target_field `watch-time`, target_field_value must be an integer value indicating the media progress time in seconds between (0, 86400] (excludes 0, includes 86400) (e.g., 90). For target_field `watch-percentage`, the target_field_value must be a valid float value between (0, 1.0] (excludes 0, includes 1.0) (e.g., 0.5)." + }, + "trainingState": { + "description": "The training state that the engine is in (e.g. `TRAINING` or `PAUSED`). Since part of the cost of running the service is frequency of training - this can be used to determine when to train engine in order to control cost. If not specified: the default value for `CreateEngine` method is `TRAINING`. The default value for `UpdateEngine` method is to keep the state the same as before.", + "enum": [ + "TRAINING_STATE_UNSPECIFIED", + "PAUSED", + "TRAINING" + ], + "enumDescriptions": [ + "Unspecified training state.", + "The engine training is paused.", + "The engine is training." + ], + "type": "string" + }, + "type": { + "description": "Required. The type of engine. e.g., `recommended-for-you`. This field together with optimization_objective describe engine metadata to use to control engine training and serving. Currently supported values: `recommended-for-you`, `others-you-may-like`, `more-like-this`, `most-popular-items`.", + "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesResponse": { - "description": "Response message for CompletionService.ImportSuggestionDenyListEntries method.", - "id": "GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesResponse", + "GoogleCloudDiscoveryengineV1alphaEngineMediaRecommendationEngineConfigOptimizationObjectiveConfig": { + "description": "Custom threshold for `cvr` optimization_objective.", + "id": "GoogleCloudDiscoveryengineV1alphaEngineMediaRecommendationEngineConfigOptimizationObjectiveConfig", "properties": { - "errorSamples": { - "description": "A sample of errors encountered while processing the request.", - "items": { - "$ref": "GoogleRpcStatus" - }, - "type": "array" - }, - "failedEntriesCount": { - "description": "Count of deny list entries that failed to be imported.", - "format": "int64", + "targetField": { + "description": "Required. The name of the field to target. Currently supported values: `watch-percentage`, `watch-time`.", "type": "string" }, - "importedEntriesCount": { - "description": "Count of deny list entries successfully imported.", - "format": "int64", - "type": "string" + "targetFieldValueFloat": { + "description": "Required. The threshold to be applied to the target (e.g., 0.5).", + "format": "float", + "type": "number" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaImportUserEventsMetadata": { - "description": "Metadata related to the progress of the Import operation. This is returned by the google.longrunning.Operation.metadata field.", - "id": "GoogleCloudDiscoveryengineV1alphaImportUserEventsMetadata", + "GoogleCloudDiscoveryengineV1alphaEngineRecommendationMetadata": { + "description": "Additional information of a recommendation engine.", + "id": "GoogleCloudDiscoveryengineV1alphaEngineRecommendationMetadata", "properties": { - "createTime": { - "description": "Operation create time.", - "format": "google-datetime", + "dataState": { + "description": "Output only. The state of data requirements for this engine: `DATA_OK` and `DATA_ERROR`. Engine cannot be trained if the data is in `DATA_ERROR` state. Engine can have `DATA_ERROR` state even if serving state is `ACTIVE`: engines were trained successfully before, but cannot be refreshed because the underlying engine no longer has sufficient data for training.", + "enum": [ + "DATA_STATE_UNSPECIFIED", + "DATA_OK", + "DATA_ERROR" + ], + "enumDescriptions": [ + "Unspecified default value, should never be explicitly set.", + "The engine has sufficient training data.", + "The engine does not have sufficient training data. Error messages can be queried via Stackdriver." + ], + "readOnly": true, "type": "string" }, - "failureCount": { - "description": "Count of entries that encountered errors while processing.", - "format": "int64", + "lastTuneTime": { + "description": "Output only. The timestamp when the latest successful tune finished. Only applicable on Media Recommendation engines.", + "format": "google-datetime", + "readOnly": true, "type": "string" }, - "successCount": { - "description": "Count of entries that were processed successfully.", - "format": "int64", + "servingState": { + "description": "Output only. The serving state of the engine: `ACTIVE`, `NOT_ACTIVE`.", + "enum": [ + "SERVING_STATE_UNSPECIFIED", + "INACTIVE", + "ACTIVE", + "TUNED" + ], + "enumDescriptions": [ + "Unspecified serving state.", + "The engine is not serving.", + "The engine is serving and can be queried.", + "The engine is trained on tuned hyperparameters and can be queried." + ], + "readOnly": true, "type": "string" }, - "updateTime": { - "description": "Operation last update time. If the operation is done, this is also the finish time.", - "format": "google-datetime", + "tuningOperation": { + "description": "Output only. The latest tune operation id associated with the engine. Only applicable on Media Recommendation engines. If present, this operation id can be used to determine if there is an ongoing tune for this engine. To check the operation status, send the GetOperation request with this operation id in the engine resource format. If no tuning has happened for this engine, the string is empty.", + "readOnly": true, "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaImportUserEventsRequest": { - "description": "Request message for the ImportUserEvents request.", - "id": "GoogleCloudDiscoveryengineV1alphaImportUserEventsRequest", + "GoogleCloudDiscoveryengineV1alphaEngineSearchEngineConfig": { + "description": "Configurations for a Search Engine.", + "id": "GoogleCloudDiscoveryengineV1alphaEngineSearchEngineConfig", "properties": { - "bigquerySource": { - "$ref": "GoogleCloudDiscoveryengineV1alphaBigQuerySource", - "description": "BigQuery input source." - }, - "errorConfig": { - "$ref": "GoogleCloudDiscoveryengineV1alphaImportErrorConfig", - "description": "The desired location of errors incurred during the Import. Cannot be set for inline user event imports." - }, - "gcsSource": { - "$ref": "GoogleCloudDiscoveryengineV1alphaGcsSource", - "description": "Cloud Storage location for the input content." - }, - "inlineSource": { - "$ref": "GoogleCloudDiscoveryengineV1alphaImportUserEventsRequestInlineSource", - "description": "The Inline source for the input content for UserEvents." - } - }, - "type": "object" - }, - "GoogleCloudDiscoveryengineV1alphaImportUserEventsRequestInlineSource": { - "description": "The inline source for the input config for ImportUserEvents method.", - "id": "GoogleCloudDiscoveryengineV1alphaImportUserEventsRequestInlineSource", - "properties": { - "userEvents": { - "description": "Required. A list of user events to import. Recommended max of 10k items.", - "items": { - "$ref": "GoogleCloudDiscoveryengineV1alphaUserEvent" - }, - "type": "array" - } - }, - "type": "object" - }, - "GoogleCloudDiscoveryengineV1alphaImportUserEventsResponse": { - "description": "Response of the ImportUserEventsRequest. If the long running operation was successful, then this message is returned by the google.longrunning.Operations.response field if the operation was successful.", - "id": "GoogleCloudDiscoveryengineV1alphaImportUserEventsResponse", - "properties": { - "errorConfig": { - "$ref": "GoogleCloudDiscoveryengineV1alphaImportErrorConfig", - "description": "Echoes the destination for the complete errors if this field was set in the request." - }, - "errorSamples": { - "description": "A sample of errors encountered while processing the request.", + "searchAddOns": { + "description": "The add-on that this search engine enables.", "items": { - "$ref": "GoogleRpcStatus" + "enum": [ + "SEARCH_ADD_ON_UNSPECIFIED", + "SEARCH_ADD_ON_LLM" + ], + "enumDescriptions": [ + "Default value when the enum is unspecified. This is invalid to use.", + "Large language model add-on." + ], + "type": "string" }, "type": "array" }, - "joinedEventsCount": { - "description": "Count of user events imported with complete existing Documents.", - "format": "int64", - "type": "string" - }, - "unjoinedEventsCount": { - "description": "Count of user events imported, but with Document information not found in the existing Branch.", - "format": "int64", + "searchTier": { + "description": "The search feature tier of this engine. Different tiers might have different pricing. To learn more, please check the pricing documentation. Defaults to SearchTier.SEARCH_TIER_STANDARD if not specified.", + "enum": [ + "SEARCH_TIER_UNSPECIFIED", + "SEARCH_TIER_STANDARD", + "SEARCH_TIER_ENTERPRISE" + ], + "enumDescriptions": [ + "Default value when the enum is unspecified. This is invalid to use.", + "Standard tier.", + "Enterprise tier." + ], "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaInterval": { - "description": "A floating point interval.", - "id": "GoogleCloudDiscoveryengineV1alphaInterval", + "GoogleCloudDiscoveryengineV1alphaEngineSimilarDocumentsEngineConfig": { + "description": "Additional config specs for a `similar-items` engine.", + "id": "GoogleCloudDiscoveryengineV1alphaEngineSimilarDocumentsEngineConfig", + "properties": {}, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaEstimateDataSizeMetadata": { + "description": "Metadata related to the progress of the EstimateDataSize operation. This is returned by the google.longrunning.Operation.metadata field.", + "id": "GoogleCloudDiscoveryengineV1alphaEstimateDataSizeMetadata", "properties": { - "exclusiveMaximum": { - "description": "Exclusive upper bound.", - "format": "double", - "type": "number" - }, - "exclusiveMinimum": { - "description": "Exclusive lower bound.", - "format": "double", - "type": "number" - }, - "maximum": { - "description": "Inclusive upper bound.", - "format": "double", - "type": "number" - }, - "minimum": { - "description": "Inclusive lower bound.", - "format": "double", - "type": "number" + "createTime": { + "description": "Operation create time.", + "format": "google-datetime", + "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaListConversationsResponse": { - "description": "Response for ListConversations method.", - "id": "GoogleCloudDiscoveryengineV1alphaListConversationsResponse", + "GoogleCloudDiscoveryengineV1alphaEstimateDataSizeRequest": { + "description": "Request message for EstimateBillingService.EstimateDataSize method", + "id": "GoogleCloudDiscoveryengineV1alphaEstimateDataSizeRequest", "properties": { - "conversations": { - "description": "All the Conversations for a given data store.", - "items": { - "$ref": "GoogleCloudDiscoveryengineV1alphaConversation" - }, - "type": "array" + "fileDataSource": { + "$ref": "GoogleCloudDiscoveryengineV1alphaEstimateDataSizeRequestFileDataSource", + "description": "Structured or unstructured data." }, - "nextPageToken": { - "description": "Pagination token, if not returned indicates the last page.", - "type": "string" + "websiteDataSource": { + "$ref": "GoogleCloudDiscoveryengineV1alphaEstimateDataSizeRequestWebsiteDataSource", + "description": "Website data." } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaListDataStoresResponse": { - "description": "Response message for DataStoreService.ListDataStores method.", - "id": "GoogleCloudDiscoveryengineV1alphaListDataStoresResponse", + "GoogleCloudDiscoveryengineV1alphaEstimateDataSizeRequestFileDataSource": { + "description": "Data source contains files either in Cloud Storage or BigQuery.", + "id": "GoogleCloudDiscoveryengineV1alphaEstimateDataSizeRequestFileDataSource", "properties": { - "dataStores": { - "description": "All the customer's DataStores.", - "items": { - "$ref": "GoogleCloudDiscoveryengineV1alphaDataStore" - }, - "type": "array" + "bigquerySource": { + "$ref": "GoogleCloudDiscoveryengineV1alphaBigQuerySource", + "description": "BigQuery input source." }, - "nextPageToken": { - "description": "A token that can be sent as ListDataStoresRequest.page_token to retrieve the next page. If this field is omitted, there are no subsequent pages.", - "type": "string" + "gcsSource": { + "$ref": "GoogleCloudDiscoveryengineV1alphaGcsSource", + "description": "Cloud Storage location for the input content." } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaListDocumentsResponse": { - "description": "Response message for DocumentService.ListDocuments method.", - "id": "GoogleCloudDiscoveryengineV1alphaListDocumentsResponse", + "GoogleCloudDiscoveryengineV1alphaEstimateDataSizeRequestWebsiteDataSource": { + "description": "Data source is a set of website patterns that we crawl to get the total number of websites.", + "id": "GoogleCloudDiscoveryengineV1alphaEstimateDataSizeRequestWebsiteDataSource", "properties": { - "documents": { - "description": "The Documents.", + "estimatorUriPatterns": { + "description": "Required. The URI patterns to estimate the data sizes. At most 10 patterns are allowed, otherwise an INVALID_ARGUMENT error is thrown.", "items": { - "$ref": "GoogleCloudDiscoveryengineV1alphaDocument" + "$ref": "GoogleCloudDiscoveryengineV1alphaEstimateDataSizeRequestWebsiteDataSourceEstimatorUriPattern" }, "type": "array" - }, - "nextPageToken": { - "description": "A token that can be sent as ListDocumentsRequest.page_token to retrieve the next page. If this field is omitted, there are no subsequent pages.", - "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaListEnginesResponse": { - "description": "Response message for EngineService.ListEngines method.", - "id": "GoogleCloudDiscoveryengineV1alphaListEnginesResponse", + "GoogleCloudDiscoveryengineV1alphaEstimateDataSizeRequestWebsiteDataSourceEstimatorUriPattern": { + "description": "URI patterns that we use to crawl.", + "id": "GoogleCloudDiscoveryengineV1alphaEstimateDataSizeRequestWebsiteDataSourceEstimatorUriPattern", "properties": { - "engines": { - "description": "All the customer's Engines.", - "items": { - "$ref": "GoogleCloudDiscoveryengineV1alphaEngine" - }, - "type": "array" + "exactMatch": { + "description": "Whether we infer the generated URI or use the exact provided one.", + "type": "boolean" }, - "nextPageToken": { - "description": "Not supported.", + "exclusive": { + "description": "Whether the pattern is exclusive or not. If set to true, the pattern is considered exclusive. If unset or set to false, the pattern is considered inclusive by default.", + "type": "boolean" + }, + "providedUriPattern": { + "description": "User provided URI pattern. For example, `foo.com/bar/*`.", "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaListSchemasResponse": { - "description": "Response message for SchemaService.ListSchemas method.", - "id": "GoogleCloudDiscoveryengineV1alphaListSchemasResponse", + "GoogleCloudDiscoveryengineV1alphaEstimateDataSizeResponse": { + "description": "Response of the EstimateDataSize request. If the long running operation was successful, then this message is returned by the google.longrunning.Operations.response field if the operation was successful.", + "id": "GoogleCloudDiscoveryengineV1alphaEstimateDataSizeResponse", "properties": { - "nextPageToken": { - "description": "A token that can be sent as ListSchemasRequest.page_token to retrieve the next page. If this field is omitted, there are no subsequent pages.", + "dataSizeBytes": { + "description": "Data size in terms of bytes.", + "format": "int64", "type": "string" }, - "schemas": { - "description": "The Schemas.", - "items": { - "$ref": "GoogleCloudDiscoveryengineV1alphaSchema" - }, - "type": "array" + "documentCount": { + "description": "Total number of documents.", + "format": "int64", + "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaListTargetSitesResponse": { - "description": "Response message for SiteSearchEngineService.ListTargetSites method.", - "id": "GoogleCloudDiscoveryengineV1alphaListTargetSitesResponse", + "GoogleCloudDiscoveryengineV1alphaFetchDomainVerificationStatusResponse": { + "description": "Response message for SiteSearchEngineService.FetchDomainVerificationStatus method.", + "id": "GoogleCloudDiscoveryengineV1alphaFetchDomainVerificationStatusResponse", "properties": { "nextPageToken": { "description": "A token that can be sent as `page_token` to retrieve the next page. If this field is omitted, there are no subsequent pages.", "type": "string" }, "targetSites": { - "description": "List of TargetSites.", + "description": "List of TargetSites containing the site verification status.", "items": { "$ref": "GoogleCloudDiscoveryengineV1alphaTargetSite" }, @@ -6789,124 +6801,152 @@ }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaLookupWidgetConfigRequest": { - "description": "Request message for WidgetService.LookupWidgetConfig method.", - "id": "GoogleCloudDiscoveryengineV1alphaLookupWidgetConfigRequest", - "properties": { - "widgetConfigId": { - "description": "Required. The UUID of the Widget Config.", - "type": "string" - } - }, - "type": "object" - }, - "GoogleCloudDiscoveryengineV1alphaLookupWidgetConfigResponse": { - "description": "Response message for WidgetService.LookupWidgetConfig method.", - "id": "GoogleCloudDiscoveryengineV1alphaLookupWidgetConfigResponse", - "properties": { - "anonymousWidgetConfig": { - "$ref": "GoogleCloudDiscoveryengineV1alphaWidgetConfig", - "description": "The Anonymous Widget Config associated with the UUID." - } - }, - "type": "object" - }, - "GoogleCloudDiscoveryengineV1alphaMediaInfo": { - "description": "Media-specific user event information.", - "id": "GoogleCloudDiscoveryengineV1alphaMediaInfo", + "GoogleCloudDiscoveryengineV1alphaFieldConfig": { + "description": "Configurations for fields of a schema. For example, configuring a field is indexable, or searchable.", + "id": "GoogleCloudDiscoveryengineV1alphaFieldConfig", "properties": { - "mediaProgressDuration": { - "description": "The media progress time in seconds, if applicable. For example, if the end user has finished 90 seconds of a playback video, then MediaInfo.media_progress_duration.seconds should be set to 90.", - "format": "google-duration", + "completableOption": { + "description": "If completable_option is COMPLETABLE_ENABLED, field values are directly used and returned as suggestions for Autocomplete in CompletionService.CompleteQuery. If completable_option is unset, the server behavior defaults to COMPLETABLE_DISABLED for fields that support setting completable options, which are just `string` fields. For those fields that do not support setting completable options, the server will skip completable option setting, and setting completable_option for those fields will throw `INVALID_ARGUMENT` error.", + "enum": [ + "COMPLETABLE_OPTION_UNSPECIFIED", + "COMPLETABLE_ENABLED", + "COMPLETABLE_DISABLED" + ], + "enumDescriptions": [ + "Value used when unset.", + "Completable option enabled for a schema field.", + "Completable option disabled for a schema field." + ], "type": "string" }, - "mediaProgressPercentage": { - "description": "Media progress should be computed using only the media_progress_duration relative to the media total length. This value must be between `[0, 1.0]` inclusive. If this is not a playback or the progress cannot be computed (e.g. ongoing livestream), this field should be unset.", - "format": "float", - "type": "number" - } - }, - "type": "object" - }, - "GoogleCloudDiscoveryengineV1alphaOcrConfig": { - "description": "The OCR options for parsing documents.", - "id": "GoogleCloudDiscoveryengineV1alphaOcrConfig", - "properties": { - "enabled": { - "description": "Required. If OCR is enabled or not. OCR must be enabled for other OcrConfig options to apply. We will only perform OCR on the first 80 pages of the PDF files.", - "type": "boolean" + "dynamicFacetableOption": { + "description": "If dynamic_facetable_option is DYNAMIC_FACETABLE_ENABLED, field values are available for dynamic facet. Could only be DYNAMIC_FACETABLE_DISABLED if FieldConfig.indexable_option is INDEXABLE_DISABLED. Otherwise, an `INVALID_ARGUMENT` error will be returned. If dynamic_facetable_option is unset, the server behavior defaults to DYNAMIC_FACETABLE_DISABLED for fields that support setting dynamic facetable options. For those fields that do not support setting dynamic facetable options, such as `object` and `boolean`, the server will skip dynamic facetable option setting, and setting dynamic_facetable_option for those fields will throw `INVALID_ARGUMENT` error.", + "enum": [ + "DYNAMIC_FACETABLE_OPTION_UNSPECIFIED", + "DYNAMIC_FACETABLE_ENABLED", + "DYNAMIC_FACETABLE_DISABLED" + ], + "enumDescriptions": [ + "Value used when unset.", + "Dynamic facetable option enabled for a schema field.", + "Dynamic facetable option disabled for a schema field." + ], + "type": "string" }, - "enhancedDocumentElements": { - "description": "Apply additional enhanced OCR processing to a list of document elements. Supported values: * `table`: advanced table parsing model.", - "items": { - "type": "string" - }, - "type": "array" + "fieldPath": { + "description": "Required. Field path of the schema field. For example: `title`, `description`, `release_info.release_year`.", + "type": "string" }, - "useNativeText": { - "description": "If true, will use native text instead of OCR text on pages containing native text.", - "type": "boolean" - } - }, - "type": "object" - }, - "GoogleCloudDiscoveryengineV1alphaPageInfo": { - "description": "Detailed page information.", - "id": "GoogleCloudDiscoveryengineV1alphaPageInfo", - "properties": { - "pageCategory": { - "description": "The most specific category associated with a category page. To represent full path of category, use '\u003e' sign to separate different hierarchies. If '\u003e' is part of the category name, please replace it with other character(s). Category pages include special pages such as sales or promotions. For instance, a special sale page may have the category hierarchy: `\"pageCategory\" : \"Sales \u003e 2017 Black Friday Deals\"`. Required for `view-category-page` events. Other event types should not set this field. Otherwise, an `INVALID_ARGUMENT` error is returned.", + "fieldType": { + "description": "Output only. Raw type of the field.", + "enum": [ + "FIELD_TYPE_UNSPECIFIED", + "OBJECT", + "STRING", + "NUMBER", + "INTEGER", + "BOOLEAN", + "GEOLOCATION", + "DATETIME" + ], + "enumDescriptions": [ + "Field type is unspecified.", + "Field value type is Object.", + "Field value type is String.", + "Field value type is Number.", + "Field value type is Integer.", + "Field value type is Boolean.", + "Field value type is Geolocation.", + "Field value type is Datetime." + ], + "readOnly": true, "type": "string" }, - "pageviewId": { - "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 `pageview_id` 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.", + "indexableOption": { + "description": "If indexable_option is INDEXABLE_ENABLED, field values are indexed so that it can be filtered or faceted in SearchService.Search. If indexable_option is unset, the server behavior defaults to INDEXABLE_DISABLED for fields that support setting indexable options. For those fields that do not support setting indexable options, such as `object` and `boolean` and key properties, the server will skip indexable_option setting, and setting indexable_option for those fields will throw `INVALID_ARGUMENT` error.", + "enum": [ + "INDEXABLE_OPTION_UNSPECIFIED", + "INDEXABLE_ENABLED", + "INDEXABLE_DISABLED" + ], + "enumDescriptions": [ + "Value used when unset.", + "Indexable option enabled for a schema field.", + "Indexable option disabled for a schema field." + ], "type": "string" }, - "referrerUri": { - "description": "The referrer URL of the current page. When using the client side event reporting with JavaScript pixel and Google Tag Manager, this value is filled in automatically. However, some browser privacy restrictions may cause this field to be empty.", + "keyPropertyType": { + "description": "Output only. Type of the key property that this field is mapped to. Empty string if this is not annotated as mapped to a key property. Example types are `title`, `description`. Full list is defined by `keyPropertyMapping` in the schema field annotation. If the schema field has a `KeyPropertyMapping` annotation, `indexable_option` and `searchable_option` of this field cannot be modified.", + "readOnly": true, "type": "string" }, - "uri": { - "description": "Complete URL (window.location.href) of the user's current page. When using the client side event reporting with JavaScript pixel and Google Tag Manager, this value is filled in automatically. Maximum length 5,000 characters.", + "recsFilterableOption": { + "description": "If recs_filterable_option is FILTERABLE_ENABLED, field values are filterable by filter expression in RecommendationService.Recommend. If FILTERABLE_ENABLED but the field type is numerical, field values are not filterable by text queries in RecommendationService.Recommend. Only textual fields are supported. If recs_filterable_option is unset, the default setting is FILTERABLE_DISABLED for fields that support setting filterable options. When a field set to [FILTERABLE_DISABLED] is filtered, a warning is generated and an empty result is returned.", + "enum": [ + "FILTERABLE_OPTION_UNSPECIFIED", + "FILTERABLE_ENABLED", + "FILTERABLE_DISABLED" + ], + "enumDescriptions": [ + "Value used when unset.", + "Filterable option enabled for a schema field.", + "Filterable option disabled for a schema field." + ], + "type": "string" + }, + "retrievableOption": { + "description": "If retrievable_option is RETRIEVABLE_ENABLED, field values are included in the search results. If retrievable_option is unset, the server behavior defaults to RETRIEVABLE_DISABLED for fields that support setting retrievable options. For those fields that do not support setting retrievable options, such as `object` and `boolean`, the server will skip retrievable option setting, and setting retrievable_option for those fields will throw `INVALID_ARGUMENT` error.", + "enum": [ + "RETRIEVABLE_OPTION_UNSPECIFIED", + "RETRIEVABLE_ENABLED", + "RETRIEVABLE_DISABLED" + ], + "enumDescriptions": [ + "Value used when unset.", + "Retrievable option enabled for a schema field.", + "Retrievable option disabled for a schema field." + ], + "type": "string" + }, + "searchableOption": { + "description": "If searchable_option is SEARCHABLE_ENABLED, field values are searchable by text queries in SearchService.Search. If SEARCHABLE_ENABLED but field type is numerical, field values will not be searchable by text queries in SearchService.Search, as there are no text values associated to numerical fields. If searchable_option is unset, the server behavior defaults to SEARCHABLE_DISABLED for fields that support setting searchable options. Only `string` fields that have no key property mapping support setting searchable_option. For those fields that do not support setting searchable options, the server will skip searchable option setting, and setting searchable_option for those fields will throw `INVALID_ARGUMENT` error.", + "enum": [ + "SEARCHABLE_OPTION_UNSPECIFIED", + "SEARCHABLE_ENABLED", + "SEARCHABLE_DISABLED" + ], + "enumDescriptions": [ + "Value used when unset.", + "Searchable option enabled for a schema field.", + "Searchable option disabled for a schema field." + ], "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaPanelInfo": { - "description": "Detailed panel information associated with a user event.", - "id": "GoogleCloudDiscoveryengineV1alphaPanelInfo", + "GoogleCloudDiscoveryengineV1alphaGcsSource": { + "description": "Cloud Storage location for input content.", + "id": "GoogleCloudDiscoveryengineV1alphaGcsSource", "properties": { - "displayName": { - "description": "The display name of the panel.", - "type": "string" - }, - "panelId": { - "description": "Required. The panel ID.", + "dataSchema": { + "description": "The schema to use when parsing the data from the source. Supported values for document imports: * `document` (default): One JSON Document per line. Each document must have a valid Document.id. * `content`: Unstructured data (e.g. PDF, HTML). Each file matched by `input_uris` becomes a document, with the ID set to the first 128 bits of SHA256(URI) encoded as a hex string. * `custom`: One custom data JSON per row in arbitrary format that conforms to the defined Schema of the data store. This can only be used by Gen App Builder. * `csv`: A CSV file with header conforming to the defined Schema of the data store. Each entry after the header is imported as a Document. This can only be used by Gen App Builder. Supported values for user even imports: * `user_event` (default): One JSON UserEvent per line.", "type": "string" }, - "panelPosition": { - "description": "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" - }, - "totalPanels": { - "description": "The total number of panels, including this one, shown to the user. Must be set if panel_position is set.", - "format": "int32", - "type": "integer" + "inputUris": { + "description": "Required. Cloud Storage URIs to input files. URI can be up to 2000 characters long. URIs can match the full object path (for example, `gs://bucket/directory/object.json`) or a pattern matching one or more files, such as `gs://bucket/directory/*.json`. A request can contain at most 100 files (or 100,000 files if `data_schema` is `content`). Each file can be up to 2 GB (or 100 MB if `data_schema` is `content`).", + "items": { + "type": "string" + }, + "type": "array" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaPauseEngineRequest": { - "description": "Request for pausing training of an engine.", - "id": "GoogleCloudDiscoveryengineV1alphaPauseEngineRequest", - "properties": {}, - "type": "object" - }, - "GoogleCloudDiscoveryengineV1alphaPurgeDocumentsMetadata": { - "description": "Metadata related to the progress of the PurgeDocuments operation. This will be returned by the google.longrunning.Operation.metadata field.", - "id": "GoogleCloudDiscoveryengineV1alphaPurgeDocumentsMetadata", + "GoogleCloudDiscoveryengineV1alphaImportDocumentsMetadata": { + "description": "Metadata related to the progress of the ImportDocuments operation. This is returned by the google.longrunning.Operation.metadata field.", + "id": "GoogleCloudDiscoveryengineV1alphaImportDocumentsMetadata", "properties": { "createTime": { "description": "Operation create time.", @@ -6919,7 +6959,7 @@ "type": "string" }, "successCount": { - "description": "Count of entries that were deleted successfully.", + "description": "Count of entries that were processed successfully.", "format": "int64", "type": "string" }, @@ -6931,66 +6971,143 @@ }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaPurgeDocumentsRequest": { - "description": "Request message for DocumentService.PurgeDocuments method.", - "id": "GoogleCloudDiscoveryengineV1alphaPurgeDocumentsRequest", + "GoogleCloudDiscoveryengineV1alphaImportDocumentsRequest": { + "description": "Request message for Import methods.", + "id": "GoogleCloudDiscoveryengineV1alphaImportDocumentsRequest", "properties": { - "filter": { - "description": "Required. Filter matching documents to purge. Only currently supported value is `*` (all items).", + "autoGenerateIds": { + "description": "Whether to automatically generate IDs for the documents if absent. If set to `true`, Document.ids are automatically generated based on the hash of the payload, where IDs may not be consistent during multiple imports. In which case ReconciliationMode.FULL is highly recommended to avoid duplicate contents. If unset or set to `false`, Document.ids have to be specified using id_field, otherwise, documents without IDs fail to be imported. Only set this field when using GcsSource or BigQuerySource, and when GcsSource.data_schema or BigQuerySource.data_schema is `custom` or `csv`. Otherwise, an INVALID_ARGUMENT error is thrown.", + "type": "boolean" + }, + "bigquerySource": { + "$ref": "GoogleCloudDiscoveryengineV1alphaBigQuerySource", + "description": "BigQuery input source." + }, + "errorConfig": { + "$ref": "GoogleCloudDiscoveryengineV1alphaImportErrorConfig", + "description": "The desired location of errors incurred during the Import." + }, + "gcsSource": { + "$ref": "GoogleCloudDiscoveryengineV1alphaGcsSource", + "description": "Cloud Storage location for the input content." + }, + "idField": { + "description": "The field in the Cloud Storage and BigQuery sources that indicates the unique IDs of the documents. For GcsSource it is the key of the JSON field. For instance, `my_id` for JSON `{\"my_id\": \"some_uuid\"}`. For BigQuerySource it is the column name of the BigQuery table where the unique ids are stored. The values of the JSON field or the BigQuery column are used as the Document.ids. The JSON field or the BigQuery column must be of string type, and the values must be set as valid strings conform to [RFC-1034](https://tools.ietf.org/html/rfc1034) with 1-63 characters. Otherwise, documents without valid IDs fail to be imported. Only set this field when using GcsSource or BigQuerySource, and when GcsSource.data_schema or BigQuerySource.data_schema is `custom`. And only set this field when auto_generate_ids is unset or set as `false`. Otherwise, an INVALID_ARGUMENT error is thrown. If it is unset, a default value `_id` is used when importing from the allowed data sources.", "type": "string" }, - "force": { - "description": "Actually performs the purge. If `force` is set to false, return the expected purge count without deleting any documents.", - "type": "boolean" + "inlineSource": { + "$ref": "GoogleCloudDiscoveryengineV1alphaImportDocumentsRequestInlineSource", + "description": "The Inline source for the input content for documents." + }, + "reconciliationMode": { + "description": "The mode of reconciliation between existing documents and the documents to be imported. Defaults to ReconciliationMode.INCREMENTAL.", + "enum": [ + "RECONCILIATION_MODE_UNSPECIFIED", + "INCREMENTAL", + "FULL" + ], + "enumDescriptions": [ + "Defaults to `INCREMENTAL`.", + "Inserts new documents or updates existing documents.", + "Calculates diff and replaces the entire document dataset. Existing documents may be deleted if they are not present in the source location." + ], + "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaPurgeDocumentsResponse": { - "description": "Response message for DocumentService.PurgeDocuments method. If the long running operation is successfully done, then this message is returned by the google.longrunning.Operations.response field.", - "id": "GoogleCloudDiscoveryengineV1alphaPurgeDocumentsResponse", + "GoogleCloudDiscoveryengineV1alphaImportDocumentsRequestInlineSource": { + "description": "The inline source for the input config for ImportDocuments method.", + "id": "GoogleCloudDiscoveryengineV1alphaImportDocumentsRequestInlineSource", "properties": { - "purgeCount": { - "description": "The total count of documents purged as a result of the operation.", - "format": "int64", - "type": "string" - }, - "purgeSample": { - "description": "A sample of document names that will be deleted. Only populated if `force` is set to false. A max of 100 names will be returned and the names are chosen at random.", + "documents": { + "description": "Required. A list of documents to update/create. Each document must have a valid Document.id. Recommended max of 100 items.", "items": { - "type": "string" + "$ref": "GoogleCloudDiscoveryengineV1alphaDocument" }, "type": "array" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaPurgeSuggestionDenyListEntriesMetadata": { - "description": "Metadata related to the progress of the PurgeSuggestionDenyListEntries operation. This is returned by the google.longrunning.Operation.metadata field.", - "id": "GoogleCloudDiscoveryengineV1alphaPurgeSuggestionDenyListEntriesMetadata", + "GoogleCloudDiscoveryengineV1alphaImportDocumentsResponse": { + "description": "Response of the ImportDocumentsRequest. If the long running operation is done, then this message is returned by the google.longrunning.Operations.response field if the operation was successful.", + "id": "GoogleCloudDiscoveryengineV1alphaImportDocumentsResponse", "properties": { - "createTime": { - "description": "Operation create time.", - "format": "google-datetime", - "type": "string" + "errorConfig": { + "$ref": "GoogleCloudDiscoveryengineV1alphaImportErrorConfig", + "description": "Echoes the destination for the complete errors in the request if set." }, - "updateTime": { - "description": "Operation last update time. If the operation is done, this is also the finish time.", - "format": "google-datetime", + "errorSamples": { + "description": "A sample of errors encountered while processing the request.", + "items": { + "$ref": "GoogleRpcStatus" + }, + "type": "array" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaImportErrorConfig": { + "description": "Configuration of destination for Import related errors.", + "id": "GoogleCloudDiscoveryengineV1alphaImportErrorConfig", + "properties": { + "gcsPrefix": { + "description": "Cloud Storage prefix for import errors. This must be an empty, existing Cloud Storage directory. Import errors are written to sharded files in this directory, one per line, as a JSON-encoded `google.rpc.Status` message.", "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaPurgeSuggestionDenyListEntriesRequest": { - "description": "Request message for CompletionService.PurgeSuggestionDenyListEntries method.", - "id": "GoogleCloudDiscoveryengineV1alphaPurgeSuggestionDenyListEntriesRequest", - "properties": {}, + "GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesMetadata": { + "description": "Metadata related to the progress of the ImportSuggestionDenyListEntries operation. This is returned by the google.longrunning.Operation.metadata field.", + "id": "GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesMetadata", + "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" }, - "GoogleCloudDiscoveryengineV1alphaPurgeSuggestionDenyListEntriesResponse": { - "description": "Response message for CompletionService.PurgeSuggestionDenyListEntries method.", - "id": "GoogleCloudDiscoveryengineV1alphaPurgeSuggestionDenyListEntriesResponse", + "GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesRequest": { + "description": "Request message for CompletionService.ImportSuggestionDenyListEntries method.", + "id": "GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesRequest", + "properties": { + "gcsSource": { + "$ref": "GoogleCloudDiscoveryengineV1alphaGcsSource", + "description": "Cloud Storage location for the input content. Only 1 file can be specified that contains all entries to import. Supported values `gcs_source.schema` for autocomplete suggestion deny list entry imports: * `suggestion_deny_list` (default): One JSON [SuggestionDenyListEntry] per line." + }, + "inlineSource": { + "$ref": "GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesRequestInlineSource", + "description": "The Inline source for the input content for suggestion deny list entries." + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesRequestInlineSource": { + "description": "The inline source for SuggestionDenyListEntry.", + "id": "GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesRequestInlineSource", + "properties": { + "entries": { + "description": "Required. A list of all denylist entries to import. Max of 1000 items.", + "items": { + "$ref": "GoogleCloudDiscoveryengineV1alphaSuggestionDenyListEntry" + }, + "type": "array" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesResponse": { + "description": "Response message for CompletionService.ImportSuggestionDenyListEntries method.", + "id": "GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesResponse", "properties": { "errorSamples": { "description": "A sample of errors encountered while processing the request.", @@ -6999,17 +7116,22 @@ }, "type": "array" }, - "purgeCount": { - "description": "Number of suggestion deny list entries purged.", + "failedEntriesCount": { + "description": "Count of deny list entries that failed to be imported.", + "format": "int64", + "type": "string" + }, + "importedEntriesCount": { + "description": "Count of deny list entries successfully imported.", "format": "int64", "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaPurgeUserEventsMetadata": { - "description": "Metadata related to the progress of the PurgeUserEvents operation. This will be returned by the google.longrunning.Operation.metadata field.", - "id": "GoogleCloudDiscoveryengineV1alphaPurgeUserEventsMetadata", + "GoogleCloudDiscoveryengineV1alphaImportUserEventsMetadata": { + "description": "Metadata related to the progress of the Import operation. This is returned by the google.longrunning.Operation.metadata field.", + "id": "GoogleCloudDiscoveryengineV1alphaImportUserEventsMetadata", "properties": { "createTime": { "description": "Operation create time.", @@ -7022,7 +7144,7 @@ "type": "string" }, "successCount": { - "description": "Count of entries that were deleted successfully.", + "description": "Count of entries that were processed successfully.", "format": "int64", "type": "string" }, @@ -7034,1260 +7156,2238 @@ }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaPurgeUserEventsRequest": { - "description": "Request message for PurgeUserEvents method.", - "id": "GoogleCloudDiscoveryengineV1alphaPurgeUserEventsRequest", + "GoogleCloudDiscoveryengineV1alphaImportUserEventsRequest": { + "description": "Request message for the ImportUserEvents request.", + "id": "GoogleCloudDiscoveryengineV1alphaImportUserEventsRequest", "properties": { - "filter": { - "description": "Required. The filter string to specify the events to be deleted with a length limit of 5,000 characters. The eligible fields for filtering are: * `eventType`: Double quoted UserEvent.event_type string. * `eventTime`: in ISO 8601 \"zulu\" format. * `userPseudoId`: Double quoted string. Specifying this will delete all events associated with a visitor. * `userId`: Double quoted string. Specifying this will delete all events associated with a user. Examples: * Deleting all events in a time range: `eventTime \u003e \"2012-04-23T18:25:43.511Z\" eventTime \u003c \"2012-04-23T18:30:43.511Z\"` * Deleting specific eventType: `eventType = \"search\"` * Deleting all events for a specific visitor: `userPseudoId = \"visitor1024\"` * Deleting all events inside a DataStore: `*` The filtering fields are assumed to have an implicit AND.", - "type": "string" + "bigquerySource": { + "$ref": "GoogleCloudDiscoveryengineV1alphaBigQuerySource", + "description": "BigQuery input source." }, - "force": { - "description": "The `force` field is currently not supported. Purge user event requests will permanently delete all purgeable events. Once the development is complete: If `force` is set to false, the method will return the expected purge count without deleting any user events. This field will default to false if not included in the request.", - "type": "boolean" + "errorConfig": { + "$ref": "GoogleCloudDiscoveryengineV1alphaImportErrorConfig", + "description": "The desired location of errors incurred during the Import. Cannot be set for inline user event imports." + }, + "gcsSource": { + "$ref": "GoogleCloudDiscoveryengineV1alphaGcsSource", + "description": "Cloud Storage location for the input content." + }, + "inlineSource": { + "$ref": "GoogleCloudDiscoveryengineV1alphaImportUserEventsRequestInlineSource", + "description": "The Inline source for the input content for UserEvents." } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaPurgeUserEventsResponse": { - "description": "Response of the PurgeUserEventsRequest. If the long running operation is successfully done, then this message is returned by the google.longrunning.Operations.response field.", - "id": "GoogleCloudDiscoveryengineV1alphaPurgeUserEventsResponse", + "GoogleCloudDiscoveryengineV1alphaImportUserEventsRequestInlineSource": { + "description": "The inline source for the input config for ImportUserEvents method.", + "id": "GoogleCloudDiscoveryengineV1alphaImportUserEventsRequestInlineSource", "properties": { - "purgeCount": { - "description": "The total count of events purged as a result of the operation.", - "format": "int64", - "type": "string" + "userEvents": { + "description": "Required. A list of user events to import. Recommended max of 10k items.", + "items": { + "$ref": "GoogleCloudDiscoveryengineV1alphaUserEvent" + }, + "type": "array" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaRecommendRequest": { - "description": "Request message for Recommend method.", - "id": "GoogleCloudDiscoveryengineV1alphaRecommendRequest", + "GoogleCloudDiscoveryengineV1alphaImportUserEventsResponse": { + "description": "Response of the ImportUserEventsRequest. If the long running operation was successful, then this message is returned by the google.longrunning.Operations.response field if the operation was successful.", + "id": "GoogleCloudDiscoveryengineV1alphaImportUserEventsResponse", "properties": { - "filter": { - "description": "Filter for restricting recommendation results with a length limit of 5,000 characters. Currently, only filter expressions on the `filter_tags` attribute is supported. Examples: * `(filter_tags: ANY(\"Red\", \"Blue\") OR filter_tags: ANY(\"Hot\", \"Cold\"))` * `(filter_tags: ANY(\"Red\", \"Blue\")) AND NOT (filter_tags: ANY(\"Green\"))` If `attributeFilteringSyntax` is set to true under the `params` field, then attribute-based expressions are expected instead of the above described tag-based syntax. Examples: * (launguage: ANY(\"en\", \"es\")) AND NOT (categories: ANY(\"Movie\")) * (available: true) AND (launguage: ANY(\"en\", \"es\")) OR (categories: ANY(\"Movie\")) If your filter blocks all results, the API will return generic (unfiltered) popular Documents. If you only want results strictly matching the filters, set `strictFiltering` to True in RecommendRequest.params to receive empty results instead. Note that the API will never return Documents with `storageStatus` of `EXPIRED` or `DELETED` regardless of filter choices.", - "type": "string" - }, - "pageSize": { - "description": "Maximum number of results to return. Set this property to the number of recommendation results needed. If zero, the service will choose a reasonable default. The maximum allowed value is 100. Values above 100 will be coerced to 100.", - "format": "int32", - "type": "integer" + "errorConfig": { + "$ref": "GoogleCloudDiscoveryengineV1alphaImportErrorConfig", + "description": "Echoes the destination for the complete errors if this field was set in the request." }, - "params": { - "additionalProperties": { - "type": "any" + "errorSamples": { + "description": "A sample of errors encountered while processing the request.", + "items": { + "$ref": "GoogleRpcStatus" }, - "description": "Additional domain specific parameters for the recommendations. Allowed values: * `returnDocument`: Boolean. If set to true, the associated Document object will be returned in RecommendResponse.RecommendationResult.document. * `returnScore`: Boolean. If set to true, the recommendation 'score' corresponding to each returned Document will be set in RecommendResponse.RecommendationResult.metadata. The given 'score' indicates the probability of a Document conversion given the user's context and history. * `strictFiltering`: Boolean. True by default. If set to false, the service will return generic (unfiltered) popular Documents instead of empty if your filter blocks all recommendation results. * `diversityLevel`: String. Default empty. If set to be non-empty, then it needs to be one of: * `no-diversity` * `low-diversity` * `medium-diversity` * `high-diversity` * `auto-diversity` This gives request-level control and adjusts recommendation results based on Document category. * `attributeFilteringSyntax`: Boolean. False by default. If set to true, the `filter` field is interpreted according to the new, attribute-based syntax.", - "type": "object" - }, - "userEvent": { - "$ref": "GoogleCloudDiscoveryengineV1alphaUserEvent", - "description": "Required. Context about the user, what they are looking at and what action they took to trigger the Recommend request. Note that this user event detail won't be ingested to userEvent logs. Thus, a separate userEvent write request is required for event logging. Don't set UserEvent.user_pseudo_id or UserEvent.user_info.user_id to the same fixed ID for different users. If you are trying to receive non-personalized recommendations (not recommended; this can negatively impact model performance), instead set UserEvent.user_pseudo_id to a random unique ID and leave UserEvent.user_info.user_id unset." + "type": "array" }, - "userLabels": { - "additionalProperties": { - "type": "string" - }, - "description": "The user labels applied to a resource must meet the following requirements: * Each resource can have multiple labels, up to a maximum of 64. * Each label must be a key-value pair. * Keys have a minimum length of 1 character and a maximum length of 63 characters and cannot be empty. Values can be empty and have a maximum length of 63 characters. * Keys and values can contain only lowercase letters, numeric characters, underscores, and dashes. All characters must use UTF-8 encoding, and international characters are allowed. * The key portion of a label must be unique. However, you can use the same key with multiple resources. * Keys must start with a lowercase letter or international character. See [Requirements for labels](https://cloud.google.com/resource-manager/docs/creating-managing-labels#requirements) for more details.", - "type": "object" + "joinedEventsCount": { + "description": "Count of user events imported with complete existing Documents.", + "format": "int64", + "type": "string" }, - "validateOnly": { - "description": "Use validate only mode for this recommendation query. If set to true, a fake model will be used that returns arbitrary Document IDs. Note that the validate only mode should only be used for testing the API, or if the model is not ready.", - "type": "boolean" + "unjoinedEventsCount": { + "description": "Count of user events imported, but with Document information not found in the existing Branch.", + "format": "int64", + "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaRecommendResponse": { - "description": "Response message for Recommend method.", - "id": "GoogleCloudDiscoveryengineV1alphaRecommendResponse", + "GoogleCloudDiscoveryengineV1alphaInterval": { + "description": "A floating point interval.", + "id": "GoogleCloudDiscoveryengineV1alphaInterval", "properties": { - "attributionToken": { - "description": "A unique attribution token. This should be included in the UserEvent logs resulting from this recommendation, which enables accurate attribution of recommendation model performance.", - "type": "string" + "exclusiveMaximum": { + "description": "Exclusive upper bound.", + "format": "double", + "type": "number" }, - "missingIds": { - "description": "IDs of documents in the request that were missing from the default Branch associated with the requested ServingConfig.", - "items": { - "type": "string" - }, - "type": "array" + "exclusiveMinimum": { + "description": "Exclusive lower bound.", + "format": "double", + "type": "number" }, - "results": { - "description": "A list of recommended Documents. The order represents the ranking (from the most relevant Document to the least).", + "maximum": { + "description": "Inclusive upper bound.", + "format": "double", + "type": "number" + }, + "minimum": { + "description": "Inclusive lower bound.", + "format": "double", + "type": "number" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaListConversationsResponse": { + "description": "Response for ListConversations method.", + "id": "GoogleCloudDiscoveryengineV1alphaListConversationsResponse", + "properties": { + "conversations": { + "description": "All the Conversations for a given data store.", "items": { - "$ref": "GoogleCloudDiscoveryengineV1alphaRecommendResponseRecommendationResult" + "$ref": "GoogleCloudDiscoveryengineV1alphaConversation" }, "type": "array" }, - "validateOnly": { - "description": "True if RecommendRequest.validate_only was set.", - "type": "boolean" + "nextPageToken": { + "description": "Pagination token, if not returned indicates the last page.", + "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaRecommendResponseRecommendationResult": { - "description": "RecommendationResult represents a generic recommendation result with associated metadata.", - "id": "GoogleCloudDiscoveryengineV1alphaRecommendResponseRecommendationResult", + "GoogleCloudDiscoveryengineV1alphaListDataStoresResponse": { + "description": "Response message for DataStoreService.ListDataStores method.", + "id": "GoogleCloudDiscoveryengineV1alphaListDataStoresResponse", "properties": { - "document": { - "$ref": "GoogleCloudDiscoveryengineV1alphaDocument", - "description": "Set if `returnDocument` is set to true in RecommendRequest.params." + "dataStores": { + "description": "All the customer's DataStores.", + "items": { + "$ref": "GoogleCloudDiscoveryengineV1alphaDataStore" + }, + "type": "array" }, - "id": { - "description": "Resource ID of the recommended Document.", + "nextPageToken": { + "description": "A token that can be sent as ListDataStoresRequest.page_token to retrieve the next page. If this field is omitted, there are no subsequent pages.", "type": "string" - }, - "metadata": { - "additionalProperties": { - "type": "any" - }, - "description": "Additional Document metadata / annotations. Possible values: * `score`: Recommendation score in double value. Is set if `returnScore` is set to true in RecommendRequest.params.", - "type": "object" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaRecrawlUrisMetadata": { - "description": "Metadata related to the progress of the SiteSearchEngineService.RecrawlUris operation. This will be returned by the google.longrunning.Operation.metadata field.", - "id": "GoogleCloudDiscoveryengineV1alphaRecrawlUrisMetadata", + "GoogleCloudDiscoveryengineV1alphaListDocumentsResponse": { + "description": "Response message for DocumentService.ListDocuments method.", + "id": "GoogleCloudDiscoveryengineV1alphaListDocumentsResponse", "properties": { - "createTime": { - "description": "Operation create time.", - "format": "google-datetime", - "type": "string" - }, - "invalidUris": { - "description": "Unique URIs in the request that don't match any TargetSite in the DataStore, only match TargetSites that haven't been fully indexed, or match a TargetSite with type EXCLUDE.", + "documents": { + "description": "The Documents.", "items": { - "type": "string" + "$ref": "GoogleCloudDiscoveryengineV1alphaDocument" }, "type": "array" }, - "pendingCount": { - "description": "Total number of URIs that have yet to be crawled.", - "format": "int32", - "type": "integer" - }, - "quotaExceededCount": { - "description": "Total number of URIs that were rejected due to insufficient indexing resources.", - "format": "int32", - "type": "integer" - }, - "successCount": { - "description": "Total number of URIs that have been crawled so far.", - "format": "int32", - "type": "integer" - }, - "updateTime": { - "description": "Operation last update time. If the operation is done, this is also the finish time.", - "format": "google-datetime", + "nextPageToken": { + "description": "A token that can be sent as ListDocumentsRequest.page_token to retrieve the next page. If this field is omitted, there are no subsequent pages.", "type": "string" - }, - "validUrisCount": { - "description": "Total number of unique URIs in the request that are not in invalid_uris.", - "format": "int32", - "type": "integer" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaRecrawlUrisRequest": { - "description": "Request message for SiteSearchEngineService.RecrawlUris method.", - "id": "GoogleCloudDiscoveryengineV1alphaRecrawlUrisRequest", + "GoogleCloudDiscoveryengineV1alphaListEnginesResponse": { + "description": "Response message for EngineService.ListEngines method.", + "id": "GoogleCloudDiscoveryengineV1alphaListEnginesResponse", "properties": { - "uris": { - "description": "Required. List of URIs to crawl. At most 10K URIs are supported, otherwise an INVALID_ARGUMENT error is thrown. Each URI should match at least one TargetSite in `site_search_engine`.", + "engines": { + "description": "All the customer's Engines.", "items": { - "type": "string" + "$ref": "GoogleCloudDiscoveryengineV1alphaEngine" }, "type": "array" + }, + "nextPageToken": { + "description": "Not supported.", + "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponse": { - "description": "Response message for SiteSearchEngineService.RecrawlUris method.", - "id": "GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponse", + "GoogleCloudDiscoveryengineV1alphaListSchemasResponse": { + "description": "Response message for SchemaService.ListSchemas method.", + "id": "GoogleCloudDiscoveryengineV1alphaListSchemasResponse", "properties": { - "failedUris": { - "description": "URIs that were not crawled before the LRO terminated.", - "items": { - "type": "string" - }, - "type": "array" + "nextPageToken": { + "description": "A token that can be sent as ListSchemasRequest.page_token to retrieve the next page. If this field is omitted, there are no subsequent pages.", + "type": "string" }, - "failureSamples": { - "description": "Details for a sample of up to 10 `failed_uris`.", + "schemas": { + "description": "The Schemas.", "items": { - "$ref": "GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfo" + "$ref": "GoogleCloudDiscoveryengineV1alphaSchema" }, "type": "array" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfo": { - "description": "Details about why a particular URI failed to be crawled. Each FailureInfo contains one FailureReason per CorpusType.", - "id": "GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfo", + "GoogleCloudDiscoveryengineV1alphaListTargetSitesResponse": { + "description": "Response message for SiteSearchEngineService.ListTargetSites method.", + "id": "GoogleCloudDiscoveryengineV1alphaListTargetSitesResponse", "properties": { - "failureReasons": { - "description": "List of failure reasons by corpus type (e.g. desktop, mobile).", + "nextPageToken": { + "description": "A token that can be sent as `page_token` to retrieve the next page. If this field is omitted, there are no subsequent pages.", + "type": "string" + }, + "targetSites": { + "description": "List of TargetSites.", "items": { - "$ref": "GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfoFailureReason" + "$ref": "GoogleCloudDiscoveryengineV1alphaTargetSite" }, "type": "array" }, - "uri": { - "description": "URI that failed to be crawled.", + "totalSize": { + "description": "The total number of items matching the request. This will always be populated in the response.", + "format": "int32", + "type": "integer" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaLookupWidgetConfigRequest": { + "description": "Request message for WidgetService.LookupWidgetConfig method.", + "id": "GoogleCloudDiscoveryengineV1alphaLookupWidgetConfigRequest", + "properties": { + "widgetConfigId": { + "description": "Required. The UUID of the Widget Config.", "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfoFailureReason": { - "description": "Details about why crawling failed for a particular CorpusType, e.g. DESKTOP and MOBILE crawling may fail for different reasons.", - "id": "GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfoFailureReason", + "GoogleCloudDiscoveryengineV1alphaLookupWidgetConfigResponse": { + "description": "Response message for WidgetService.LookupWidgetConfig method.", + "id": "GoogleCloudDiscoveryengineV1alphaLookupWidgetConfigResponse", "properties": { - "corpusType": { - "description": "DESKTOP, MOBILE, or CORPUS_TYPE_UNSPECIFIED.", - "enum": [ - "CORPUS_TYPE_UNSPECIFIED", - "DESKTOP", - "MOBILE" - ], - "enumDescriptions": [ - "Default value.", - "Denotes a crawling attempt for the desktop version of a page.", - "Denotes a crawling attempt for the mobile version of a page." - ], + "anonymousWidgetConfig": { + "$ref": "GoogleCloudDiscoveryengineV1alphaWidgetConfig", + "description": "The Anonymous Widget Config associated with the UUID." + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaMediaInfo": { + "description": "Media-specific user event information.", + "id": "GoogleCloudDiscoveryengineV1alphaMediaInfo", + "properties": { + "mediaProgressDuration": { + "description": "The media progress time in seconds, if applicable. For example, if the end user has finished 90 seconds of a playback video, then MediaInfo.media_progress_duration.seconds should be set to 90.", + "format": "google-duration", "type": "string" }, - "errorMessage": { - "description": "Reason why the URI was not crawled.", - "type": "string" + "mediaProgressPercentage": { + "description": "Media progress should be computed using only the media_progress_duration relative to the media total length. This value must be between `[0, 1.0]` inclusive. If this is not a playback or the progress cannot be computed (e.g. ongoing livestream), this field should be unset.", + "format": "float", + "type": "number" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaReply": { - "description": "Defines a reply message to user.", - "id": "GoogleCloudDiscoveryengineV1alphaReply", + "GoogleCloudDiscoveryengineV1alphaOcrConfig": { + "description": "The OCR options for parsing documents.", + "id": "GoogleCloudDiscoveryengineV1alphaOcrConfig", "properties": { - "references": { - "deprecated": true, - "description": "References in the reply.", + "enabled": { + "description": "Required. If OCR is enabled or not. OCR must be enabled for other OcrConfig options to apply. We will only perform OCR on the first 80 pages of the PDF files.", + "type": "boolean" + }, + "enhancedDocumentElements": { + "description": "Apply additional enhanced OCR processing to a list of document elements. Supported values: * `table`: advanced table parsing model.", "items": { - "$ref": "GoogleCloudDiscoveryengineV1alphaReplyReference" + "type": "string" }, "type": "array" }, - "reply": { - "deprecated": true, - "description": "DEPRECATED: use `summary` instead. Text reply.", + "useNativeText": { + "description": "If true, will use native text instead of OCR text on pages containing native text.", + "type": "boolean" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaPageInfo": { + "description": "Detailed page information.", + "id": "GoogleCloudDiscoveryengineV1alphaPageInfo", + "properties": { + "pageCategory": { + "description": "The most specific category associated with a category page. To represent full path of category, use '\u003e' sign to separate different hierarchies. If '\u003e' is part of the category name, please replace it with other character(s). Category pages include special pages such as sales or promotions. For instance, a special sale page may have the category hierarchy: `\"pageCategory\" : \"Sales \u003e 2017 Black Friday Deals\"`. Required for `view-category-page` events. Other event types should not set this field. Otherwise, an `INVALID_ARGUMENT` error is returned.", "type": "string" }, - "summary": { - "$ref": "GoogleCloudDiscoveryengineV1alphaSearchResponseSummary", - "description": "Summary based on search results." + "pageviewId": { + "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 `pageview_id` 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" + }, + "referrerUri": { + "description": "The referrer URL of the current page. When using the client side event reporting with JavaScript pixel and Google Tag Manager, this value is filled in automatically. However, some browser privacy restrictions may cause this field to be empty.", + "type": "string" + }, + "uri": { + "description": "Complete URL (window.location.href) of the user's current page. When using the client side event reporting with JavaScript pixel and Google Tag Manager, this value is filled in automatically. Maximum length 5,000 characters.", + "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaReplyReference": { - "deprecated": true, - "description": "Defines reference in reply.", - "id": "GoogleCloudDiscoveryengineV1alphaReplyReference", + "GoogleCloudDiscoveryengineV1alphaPanelInfo": { + "description": "Detailed panel information associated with a user event.", + "id": "GoogleCloudDiscoveryengineV1alphaPanelInfo", "properties": { - "anchorText": { - "description": "Anchor text.", + "displayName": { + "description": "The display name of the panel.", "type": "string" }, - "end": { - "description": "Anchor text end index.", + "panelId": { + "description": "Required. The panel ID.", + "type": "string" + }, + "panelPosition": { + "description": "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" }, - "start": { - "description": "Anchor text start index.", + "totalPanels": { + "description": "The total number of panels, including this one, shown to the user. Must be set if panel_position is set.", "format": "int32", "type": "integer" - }, - "uri": { - "description": "URI link reference.", - "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaResumeEngineRequest": { - "description": "Request for resuming training of an engine.", - "id": "GoogleCloudDiscoveryengineV1alphaResumeEngineRequest", + "GoogleCloudDiscoveryengineV1alphaPauseEngineRequest": { + "description": "Request for pausing training of an engine.", + "id": "GoogleCloudDiscoveryengineV1alphaPauseEngineRequest", "properties": {}, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaSchema": { - "description": "Defines the structure and layout of a type of document data.", - "id": "GoogleCloudDiscoveryengineV1alphaSchema", + "GoogleCloudDiscoveryengineV1alphaPurgeDocumentsMetadata": { + "description": "Metadata related to the progress of the PurgeDocuments operation. This will be returned by the google.longrunning.Operation.metadata field.", + "id": "GoogleCloudDiscoveryengineV1alphaPurgeDocumentsMetadata", "properties": { - "fieldConfigs": { - "description": "Output only. Configurations for fields of the schema.", - "items": { - "$ref": "GoogleCloudDiscoveryengineV1alphaFieldConfig" - }, - "readOnly": true, - "type": "array" + "createTime": { + "description": "Operation create time.", + "format": "google-datetime", + "type": "string" }, - "jsonSchema": { - "description": "The JSON representation of the schema.", + "failureCount": { + "description": "Count of entries that encountered errors while processing.", + "format": "int64", "type": "string" }, - "name": { - "description": "Immutable. The full resource name of the schema, in the format of `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/schemas/{schema}`. This field must be a UTF-8 encoded string with a length limit of 1024 characters.", + "successCount": { + "description": "Count of entries that were deleted successfully.", + "format": "int64", "type": "string" }, - "structSchema": { - "additionalProperties": { - "description": "Properties of the object.", - "type": "any" - }, - "description": "The structured representation of the schema.", - "type": "object" + "updateTime": { + "description": "Operation last update time. If the operation is done, this is also the finish time.", + "format": "google-datetime", + "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaSearchInfo": { - "description": "Detailed search information.", - "id": "GoogleCloudDiscoveryengineV1alphaSearchInfo", + "GoogleCloudDiscoveryengineV1alphaPurgeDocumentsRequest": { + "description": "Request message for DocumentService.PurgeDocuments method.", + "id": "GoogleCloudDiscoveryengineV1alphaPurgeDocumentsRequest", "properties": { - "offset": { - "description": "An integer that specifies the current offset for pagination (the 0-indexed starting location, amongst the products deemed by the API as relevant). See SearchRequest.offset for definition. If this field is negative, an `INVALID_ARGUMENT` is returned. This can only be set for `search` events. Other event types should not set this field. Otherwise, an `INVALID_ARGUMENT` error is returned.", - "format": "int32", - "type": "integer" - }, - "orderBy": { - "description": "The order in which products are returned, if applicable. See SearchRequest.order_by for definition and syntax. The value must be a UTF-8 encoded string with a length limit of 1,000 characters. Otherwise, an `INVALID_ARGUMENT` error is returned. This can only be set for `search` events. Other event types should not set this field. Otherwise, an `INVALID_ARGUMENT` error is returned.", + "filter": { + "description": "Required. Filter matching documents to purge. Only currently supported value is `*` (all items).", "type": "string" }, - "searchQuery": { - "description": "The user's search query. See SearchRequest.query for definition. The value must be a UTF-8 encoded string with a length limit of 5,000 characters. Otherwise, an `INVALID_ARGUMENT` error is returned. At least one of search_query or PageInfo.page_category is required for `search` events. Other event types should not set this field. Otherwise, an `INVALID_ARGUMENT` error is returned.", - "type": "string" + "force": { + "description": "Actually performs the purge. If `force` is set to false, return the expected purge count without deleting any documents.", + "type": "boolean" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaSearchRequest": { - "description": "Request message for SearchService.Search method.", - "id": "GoogleCloudDiscoveryengineV1alphaSearchRequest", + "GoogleCloudDiscoveryengineV1alphaPurgeDocumentsResponse": { + "description": "Response message for DocumentService.PurgeDocuments method. If the long running operation is successfully done, then this message is returned by the google.longrunning.Operations.response field.", + "id": "GoogleCloudDiscoveryengineV1alphaPurgeDocumentsResponse", "properties": { - "boostSpec": { - "$ref": "GoogleCloudDiscoveryengineV1alphaSearchRequestBoostSpec", - "description": "Boost specification to boost certain documents. For more information on boosting, see [Boosting](https://cloud.google.com/retail/docs/boosting#boost)" - }, - "branch": { - "description": "The branch resource name, such as `projects/*/locations/global/collections/default_collection/dataStores/default_data_store/branches/0`. Use `default_branch` as the branch ID or leave this field empty, to search documents under the default branch.", + "purgeCount": { + "description": "The total count of documents purged as a result of the operation.", + "format": "int64", "type": "string" }, - "canonicalFilter": { - "description": "The default filter that is applied when a user performs a search without checking any filters on the search page. The filter applied to every search request when quality improvement such as query expansion is needed. In the case a query does not have a sufficient amount of results this filter will be used to determine whether or not to enable the query expansion flow. The original filter will still be used for the query expanded search. This field is strongly recommended to achieve high search quality. For more information about filter syntax, see SearchRequest.filter.", + "purgeSample": { + "description": "A sample of document names that will be deleted. Only populated if `force` is set to false. A max of 100 names will be returned and the names are chosen at random.", + "items": { + "type": "string" + }, + "type": "array" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaPurgeSuggestionDenyListEntriesMetadata": { + "description": "Metadata related to the progress of the PurgeSuggestionDenyListEntries operation. This is returned by the google.longrunning.Operation.metadata field.", + "id": "GoogleCloudDiscoveryengineV1alphaPurgeSuggestionDenyListEntriesMetadata", + "properties": { + "createTime": { + "description": "Operation create time.", + "format": "google-datetime", "type": "string" }, - "contentSearchSpec": { - "$ref": "GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpec", - "description": "A specification for configuring the behavior of content search." - }, - "embeddingSpec": { - "$ref": "GoogleCloudDiscoveryengineV1alphaSearchRequestEmbeddingSpec", - "description": "Uses the provided embedding to do additional semantic document retrieval. The retrieval is based on the dot product of SearchRequest.EmbeddingSpec.EmbeddingVector.vector and the document embedding that is provided in SearchRequest.EmbeddingSpec.EmbeddingVector.field_path. If SearchRequest.EmbeddingSpec.EmbeddingVector.field_path is not provided, it will use ServingConfig.EmbeddingConfig.field_paths." - }, - "facetSpecs": { - "description": "Facet specifications for faceted search. If empty, no facets are returned. A maximum of 100 values are allowed. Otherwise, an `INVALID_ARGUMENT` error is returned.", + "updateTime": { + "description": "Operation last update time. If the operation is done, this is also the finish time.", + "format": "google-datetime", + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaPurgeSuggestionDenyListEntriesRequest": { + "description": "Request message for CompletionService.PurgeSuggestionDenyListEntries method.", + "id": "GoogleCloudDiscoveryengineV1alphaPurgeSuggestionDenyListEntriesRequest", + "properties": {}, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaPurgeSuggestionDenyListEntriesResponse": { + "description": "Response message for CompletionService.PurgeSuggestionDenyListEntries method.", + "id": "GoogleCloudDiscoveryengineV1alphaPurgeSuggestionDenyListEntriesResponse", + "properties": { + "errorSamples": { + "description": "A sample of errors encountered while processing the request.", "items": { - "$ref": "GoogleCloudDiscoveryengineV1alphaSearchRequestFacetSpec" + "$ref": "GoogleRpcStatus" }, "type": "array" }, - "filter": { - "description": "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)", + "purgeCount": { + "description": "Number of suggestion deny list entries purged.", + "format": "int64", + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaPurgeUserEventsMetadata": { + "description": "Metadata related to the progress of the PurgeUserEvents operation. This will be returned by the google.longrunning.Operation.metadata field.", + "id": "GoogleCloudDiscoveryengineV1alphaPurgeUserEventsMetadata", + "properties": { + "createTime": { + "description": "Operation create time.", + "format": "google-datetime", "type": "string" }, - "imageQuery": { - "$ref": "GoogleCloudDiscoveryengineV1alphaSearchRequestImageQuery", - "description": "Raw image query." + "failureCount": { + "description": "Count of entries that encountered errors while processing.", + "format": "int64", + "type": "string" }, - "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.", - "format": "int32", - "type": "integer" + "successCount": { + "description": "Count of entries that were deleted successfully.", + "format": "int64", + "type": "string" }, - "orderBy": { - "description": "The order in which documents are returned. Documents can be ordered by a field in an Document object. Leave it unset if ordered by relevance. `order_by` expression is case-sensitive. For more information on ordering, see [Ordering](https://cloud.google.com/retail/docs/filter-and-order#order) If this field is unrecognizable, an `INVALID_ARGUMENT` is returned.", + "updateTime": { + "description": "Operation last update time. If the operation is done, this is also the finish time.", + "format": "google-datetime", + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaPurgeUserEventsRequest": { + "description": "Request message for PurgeUserEvents method.", + "id": "GoogleCloudDiscoveryengineV1alphaPurgeUserEventsRequest", + "properties": { + "filter": { + "description": "Required. The filter string to specify the events to be deleted with a length limit of 5,000 characters. The eligible fields for filtering are: * `eventType`: Double quoted UserEvent.event_type string. * `eventTime`: in ISO 8601 \"zulu\" format. * `userPseudoId`: Double quoted string. Specifying this will delete all events associated with a visitor. * `userId`: Double quoted string. Specifying this will delete all events associated with a user. Examples: * Deleting all events in a time range: `eventTime \u003e \"2012-04-23T18:25:43.511Z\" eventTime \u003c \"2012-04-23T18:30:43.511Z\"` * Deleting specific eventType: `eventType = \"search\"` * Deleting all events for a specific visitor: `userPseudoId = \"visitor1024\"` * Deleting all events inside a DataStore: `*` The filtering fields are assumed to have an implicit AND.", + "type": "string" + }, + "force": { + "description": "The `force` field is currently not supported. Purge user event requests will permanently delete all purgeable events. Once the development is complete: If `force` is set to false, the method will return the expected purge count without deleting any user events. This field will default to false if not included in the request.", + "type": "boolean" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaPurgeUserEventsResponse": { + "description": "Response of the PurgeUserEventsRequest. If the long running operation is successfully done, then this message is returned by the google.longrunning.Operations.response field.", + "id": "GoogleCloudDiscoveryengineV1alphaPurgeUserEventsResponse", + "properties": { + "purgeCount": { + "description": "The total count of events purged as a result of the operation.", + "format": "int64", + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaRecommendRequest": { + "description": "Request message for Recommend method.", + "id": "GoogleCloudDiscoveryengineV1alphaRecommendRequest", + "properties": { + "filter": { + "description": "Filter for restricting recommendation results with a length limit of 5,000 characters. Currently, only filter expressions on the `filter_tags` attribute is supported. Examples: * `(filter_tags: ANY(\"Red\", \"Blue\") OR filter_tags: ANY(\"Hot\", \"Cold\"))` * `(filter_tags: ANY(\"Red\", \"Blue\")) AND NOT (filter_tags: ANY(\"Green\"))` If `attributeFilteringSyntax` is set to true under the `params` field, then attribute-based expressions are expected instead of the above described tag-based syntax. Examples: * (launguage: ANY(\"en\", \"es\")) AND NOT (categories: ANY(\"Movie\")) * (available: true) AND (launguage: ANY(\"en\", \"es\")) OR (categories: ANY(\"Movie\")) If your filter blocks all results, the API will return generic (unfiltered) popular Documents. If you only want results strictly matching the filters, set `strictFiltering` to True in RecommendRequest.params to receive empty results instead. Note that the API will never return Documents with `storageStatus` of `EXPIRED` or `DELETED` regardless of filter choices.", "type": "string" }, "pageSize": { - "description": "Maximum number of Documents to return. If unspecified, defaults to a reasonable value. The maximum allowed value is 100. Values above 100 are coerced to 100. If this field is negative, an `INVALID_ARGUMENT` is returned.", + "description": "Maximum number of results to return. Set this property to the number of recommendation results needed. If zero, the service will choose a reasonable default. The maximum allowed value is 100. Values above 100 will be coerced to 100.", "format": "int32", "type": "integer" }, - "pageToken": { - "description": "A page token received from a previous SearchService.Search call. Provide this to retrieve the subsequent page. When paginating, all other parameters provided to SearchService.Search must match the call that provided the page token. Otherwise, an `INVALID_ARGUMENT` error is returned.", - "type": "string" - }, "params": { "additionalProperties": { "type": "any" }, - "description": "Additional search parameters. For public website search only, supported values are: * `user_country_code`: string. Default empty. If set to non-empty, results are restricted or boosted based on the location provided. Example: user_country_code: \"au\" For available codes see [Country Codes](https://developers.google.com/custom-search/docs/json_api_reference#countryCodes) * `search_type`: double. Default empty. Enables non-webpage searching depending on the value. The only valid non-default value is 1, which enables image searching. Example: search_type: 1", + "description": "Additional domain specific parameters for the recommendations. Allowed values: * `returnDocument`: Boolean. If set to true, the associated Document object will be returned in RecommendResponse.RecommendationResult.document. * `returnScore`: Boolean. If set to true, the recommendation 'score' corresponding to each returned Document will be set in RecommendResponse.RecommendationResult.metadata. The given 'score' indicates the probability of a Document conversion given the user's context and history. * `strictFiltering`: Boolean. True by default. If set to false, the service will return generic (unfiltered) popular Documents instead of empty if your filter blocks all recommendation results. * `diversityLevel`: String. Default empty. If set to be non-empty, then it needs to be one of: * `no-diversity` * `low-diversity` * `medium-diversity` * `high-diversity` * `auto-diversity` This gives request-level control and adjusts recommendation results based on Document category. * `attributeFilteringSyntax`: Boolean. False by default. If set to true, the `filter` field is interpreted according to the new, attribute-based syntax.", "type": "object" }, - "query": { - "description": "Raw search query.", - "type": "string" - }, - "queryExpansionSpec": { - "$ref": "GoogleCloudDiscoveryengineV1alphaSearchRequestQueryExpansionSpec", - "description": "The query expansion specification that specifies the conditions under which query expansion occurs." - }, - "rankingExpression": { - "description": "The ranking expression controls the customized ranking on retrieval documents. This overrides ServingConfig.ranking_expression. The ranking expression is a single function or multiple functions that are joint by \"+\". * ranking_expression = function, { \" + \", function }; Supported functions: * double * relevance_score * double * dotProduct(embedding_field_path) Function variables: `relevance_score`: pre-defined keywords, used for measure relevance between query and document. `embedding_field_path`: the document embedding field used with query embedding vector. `dotProduct`: embedding function between embedding_field_path and query embedding vector. Example ranking expression: If document has an embedding field doc_embedding, the ranking expression could be `0.5 * relevance_score + 0.3 * dotProduct(doc_embedding)`.", - "type": "string" - }, - "safeSearch": { - "description": "Whether to turn on safe search. This is only supported for website search.", - "type": "boolean" - }, - "servingConfig": { - "description": "Required. The resource name of the Search serving config, such as `projects/*/locations/global/collections/default_collection/engines/*/servingConfigs/default_serving_config`, or `projects/*/locations/global/collections/default_collection/dataStores/default_data_store/servingConfigs/default_serving_config`. This field is used to identify the serving configuration name, set of models used to make the search.", - "type": "string" - }, - "spellCorrectionSpec": { - "$ref": "GoogleCloudDiscoveryengineV1alphaSearchRequestSpellCorrectionSpec", - "description": "The spell correction specification that specifies the mode under which spell correction takes effect." - }, - "userInfo": { - "$ref": "GoogleCloudDiscoveryengineV1alphaUserInfo", - "description": "Information about the end user. Highly recommended for analytics. UserInfo.user_agent is used to deduce `device_type` for analytics." + "userEvent": { + "$ref": "GoogleCloudDiscoveryengineV1alphaUserEvent", + "description": "Required. Context about the user, what they are looking at and what action they took to trigger the Recommend request. Note that this user event detail won't be ingested to userEvent logs. Thus, a separate userEvent write request is required for event logging. Don't set UserEvent.user_pseudo_id or UserEvent.user_info.user_id to the same fixed ID for different users. If you are trying to receive non-personalized recommendations (not recommended; this can negatively impact model performance), instead set UserEvent.user_pseudo_id to a random unique ID and leave UserEvent.user_info.user_id unset." }, "userLabels": { "additionalProperties": { "type": "string" }, - "description": "The user labels applied to a resource must meet the following requirements: * Each resource can have multiple labels, up to a maximum of 64. * Each label must be a key-value pair. * Keys have a minimum length of 1 character and a maximum length of 63 characters and cannot be empty. Values can be empty and have a maximum length of 63 characters. * Keys and values can contain only lowercase letters, numeric characters, underscores, and dashes. All characters must use UTF-8 encoding, and international characters are allowed. * The key portion of a label must be unique. However, you can use the same key with multiple resources. * Keys must start with a lowercase letter or international character. See [Google Cloud Document](https://cloud.google.com/resource-manager/docs/creating-managing-labels#requirements) for more details.", + "description": "The user labels applied to a resource must meet the following requirements: * Each resource can have multiple labels, up to a maximum of 64. * Each label must be a key-value pair. * Keys have a minimum length of 1 character and a maximum length of 63 characters and cannot be empty. Values can be empty and have a maximum length of 63 characters. * Keys and values can contain only lowercase letters, numeric characters, underscores, and dashes. All characters must use UTF-8 encoding, and international characters are allowed. * The key portion of a label must be unique. However, you can use the same key with multiple resources. * Keys must start with a lowercase letter or international character. See [Requirements for labels](https://cloud.google.com/resource-manager/docs/creating-managing-labels#requirements) for more details.", "type": "object" }, - "userPseudoId": { - "description": "A unique identifier for tracking visitors. For example, this could be implemented with an HTTP cookie, which should be able to uniquely identify a visitor on a single device. This unique identifier should not change if the visitor logs in or out of the website. This field should NOT have a fixed value such as `unknown_visitor`. This should be the same identifier as UserEvent.user_pseudo_id and CompleteQueryRequest.user_pseudo_id The field must be a UTF-8 encoded string with a length limit of 128 characters. Otherwise, an `INVALID_ARGUMENT` error is returned.", - "type": "string" + "validateOnly": { + "description": "Use validate only mode for this recommendation query. If set to true, a fake model will be used that returns arbitrary Document IDs. Note that the validate only mode should only be used for testing the API, or if the model is not ready.", + "type": "boolean" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaSearchRequestBoostSpec": { - "description": "Boost specification to boost certain documents.", - "id": "GoogleCloudDiscoveryengineV1alphaSearchRequestBoostSpec", + "GoogleCloudDiscoveryengineV1alphaRecommendResponse": { + "description": "Response message for Recommend method.", + "id": "GoogleCloudDiscoveryengineV1alphaRecommendResponse", "properties": { - "conditionBoostSpecs": { - "description": "Condition boost specifications. If a document matches multiple conditions in the specifictions, boost scores from these specifications are all applied and combined in a non-linear way. Maximum number of specifications is 20.", + "attributionToken": { + "description": "A unique attribution token. This should be included in the UserEvent logs resulting from this recommendation, which enables accurate attribution of recommendation model performance.", + "type": "string" + }, + "missingIds": { + "description": "IDs of documents in the request that were missing from the default Branch associated with the requested ServingConfig.", "items": { - "$ref": "GoogleCloudDiscoveryengineV1alphaSearchRequestBoostSpecConditionBoostSpec" + "type": "string" + }, + "type": "array" + }, + "results": { + "description": "A list of recommended Documents. The order represents the ranking (from the most relevant Document to the least).", + "items": { + "$ref": "GoogleCloudDiscoveryengineV1alphaRecommendResponseRecommendationResult" }, "type": "array" + }, + "validateOnly": { + "description": "True if RecommendRequest.validate_only was set.", + "type": "boolean" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaSearchRequestBoostSpecConditionBoostSpec": { - "description": "Boost applies to documents which match a condition.", - "id": "GoogleCloudDiscoveryengineV1alphaSearchRequestBoostSpecConditionBoostSpec", + "GoogleCloudDiscoveryengineV1alphaRecommendResponseRecommendationResult": { + "description": "RecommendationResult represents a generic recommendation result with associated metadata.", + "id": "GoogleCloudDiscoveryengineV1alphaRecommendResponseRecommendationResult", "properties": { - "boost": { - "description": "Strength of the condition boost, which should be in [-1, 1]. Negative boost means demotion. Default is 0.0. Setting to 1.0 gives the document a big promotion. However, it does not necessarily mean that the boosted document will be the top result at all times, nor that other documents will be excluded. Results could still be shown even when none of them matches the condition. And results that are significantly more relevant to the search query can still trump your heavily favored but irrelevant documents. Setting to -1.0 gives the document a big demotion. However, results that are deeply relevant might still be shown. The document will have an upstream battle to get a fairly high ranking, but it is not blocked out completely. Setting to 0.0 means no boost applied. The boosting condition is ignored.", - "format": "float", - "type": "number" - }, - "condition": { - "description": "An expression which specifies a boost condition. The syntax and supported fields are the same as a filter expression. See SearchRequest.filter for detail syntax and limitations. Examples: * To boost documents with document ID \"doc_1\" or \"doc_2\", and color \"Red\" or \"Blue\": * (id: ANY(\"doc_1\", \"doc_2\")) AND (color: ANY(\"Red\",\"Blue\"))", + "document": { + "$ref": "GoogleCloudDiscoveryengineV1alphaDocument", + "description": "Set if `returnDocument` is set to true in RecommendRequest.params." + }, + "id": { + "description": "Resource ID of the recommended Document.", "type": "string" + }, + "metadata": { + "additionalProperties": { + "type": "any" + }, + "description": "Additional Document metadata / annotations. Possible values: * `score`: Recommendation score in double value. Is set if `returnScore` is set to true in RecommendRequest.params.", + "type": "object" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpec": { - "description": "A specification for configuring the behavior of content search.", - "id": "GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpec", + "GoogleCloudDiscoveryengineV1alphaRecrawlUrisMetadata": { + "description": "Metadata related to the progress of the SiteSearchEngineService.RecrawlUris operation. This will be returned by the google.longrunning.Operation.metadata field.", + "id": "GoogleCloudDiscoveryengineV1alphaRecrawlUrisMetadata", "properties": { - "extractiveContentSpec": { - "$ref": "GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecExtractiveContentSpec", - "description": "If there is no extractive_content_spec provided, there will be no extractive answer in the search response." + "createTime": { + "description": "Operation create time.", + "format": "google-datetime", + "type": "string" }, - "snippetSpec": { - "$ref": "GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSnippetSpec", - "description": "If `snippetSpec` is not specified, snippets are not included in the search response." + "invalidUris": { + "description": "Unique URIs in the request that don't match any TargetSite in the DataStore, only match TargetSites that haven't been fully indexed, or match a TargetSite with type EXCLUDE.", + "items": { + "type": "string" + }, + "type": "array" }, - "summarySpec": { - "$ref": "GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSummarySpec", - "description": "If `summarySpec` is not specified, summaries are not included in the search response." + "pendingCount": { + "description": "Total number of URIs that have yet to be crawled.", + "format": "int32", + "type": "integer" + }, + "quotaExceededCount": { + "description": "Total number of URIs that were rejected due to insufficient indexing resources.", + "format": "int32", + "type": "integer" + }, + "successCount": { + "description": "Total number of URIs that have been crawled so far.", + "format": "int32", + "type": "integer" + }, + "updateTime": { + "description": "Operation last update time. If the operation is done, this is also the finish time.", + "format": "google-datetime", + "type": "string" + }, + "validUrisCount": { + "description": "Total number of unique URIs in the request that are not in invalid_uris.", + "format": "int32", + "type": "integer" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecExtractiveContentSpec": { - "description": "A specification for configuring the extractive content in a search response.", - "id": "GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecExtractiveContentSpec", + "GoogleCloudDiscoveryengineV1alphaRecrawlUrisRequest": { + "description": "Request message for SiteSearchEngineService.RecrawlUris method.", + "id": "GoogleCloudDiscoveryengineV1alphaRecrawlUrisRequest", "properties": { - "maxExtractiveAnswerCount": { - "description": "The maximum number of extractive answers returned in each search result. An extractive answer is a verbatim answer extracted from the original document, which provides a precise and contextually relevant answer to the search query. If the number of matching answers is less than the `max_extractive_answer_count`, return all of the answers. Otherwise, return the `max_extractive_answer_count`. At most five answers are returned for each SearchResult.", + "uris": { + "description": "Required. List of URIs to crawl. At most 10K URIs are supported, otherwise an INVALID_ARGUMENT error is thrown. Each URI should match at least one TargetSite in `site_search_engine`.", + "items": { + "type": "string" + }, + "type": "array" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponse": { + "description": "Response message for SiteSearchEngineService.RecrawlUris method.", + "id": "GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponse", + "properties": { + "failedUris": { + "description": "URIs that were not crawled before the LRO terminated.", + "items": { + "type": "string" + }, + "type": "array" + }, + "failureSamples": { + "description": "Details for a sample of up to 10 `failed_uris`.", + "items": { + "$ref": "GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfo" + }, + "type": "array" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfo": { + "description": "Details about why a particular URI failed to be crawled. Each FailureInfo contains one FailureReason per CorpusType.", + "id": "GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfo", + "properties": { + "failureReasons": { + "description": "List of failure reasons by corpus type (e.g. desktop, mobile).", + "items": { + "$ref": "GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfoFailureReason" + }, + "type": "array" + }, + "uri": { + "description": "URI that failed to be crawled.", + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfoFailureReason": { + "description": "Details about why crawling failed for a particular CorpusType, e.g., DESKTOP and MOBILE crawling may fail for different reasons.", + "id": "GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfoFailureReason", + "properties": { + "corpusType": { + "description": "DESKTOP, MOBILE, or CORPUS_TYPE_UNSPECIFIED.", + "enum": [ + "CORPUS_TYPE_UNSPECIFIED", + "DESKTOP", + "MOBILE" + ], + "enumDescriptions": [ + "Default value.", + "Denotes a crawling attempt for the desktop version of a page.", + "Denotes a crawling attempt for the mobile version of a page." + ], + "type": "string" + }, + "errorMessage": { + "description": "Reason why the URI was not crawled.", + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaReply": { + "description": "Defines a reply message to user.", + "id": "GoogleCloudDiscoveryengineV1alphaReply", + "properties": { + "references": { + "deprecated": true, + "description": "References in the reply.", + "items": { + "$ref": "GoogleCloudDiscoveryengineV1alphaReplyReference" + }, + "type": "array" + }, + "reply": { + "deprecated": true, + "description": "DEPRECATED: use `summary` instead. Text reply.", + "type": "string" + }, + "summary": { + "$ref": "GoogleCloudDiscoveryengineV1alphaSearchResponseSummary", + "description": "Summary based on search results." + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaReplyReference": { + "deprecated": true, + "description": "Defines reference in reply.", + "id": "GoogleCloudDiscoveryengineV1alphaReplyReference", + "properties": { + "anchorText": { + "description": "Anchor text.", + "type": "string" + }, + "end": { + "description": "Anchor text end index.", "format": "int32", "type": "integer" }, - "maxExtractiveSegmentCount": { - "description": "The max number of extractive segments returned in each search result. Only applied if the DataStore is set to DataStore.ContentConfig.CONTENT_REQUIRED or DataStore.solution_types is SOLUTION_TYPE_CHAT. An extractive segment is a text segment extracted from the original document that is relevant to the search query, and, in general, more verbose than an extractive answer. The segment could then be used as input for LLMs to generate summaries and answers. If the number of matching segments is less than `max_extractive_segment_count`, return all of the segments. Otherwise, return the `max_extractive_segment_count`.", + "start": { + "description": "Anchor text start index.", + "format": "int32", + "type": "integer" + }, + "uri": { + "description": "URI link reference.", + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaResumeEngineRequest": { + "description": "Request for resuming training of an engine.", + "id": "GoogleCloudDiscoveryengineV1alphaResumeEngineRequest", + "properties": {}, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaSchema": { + "description": "Defines the structure and layout of a type of document data.", + "id": "GoogleCloudDiscoveryengineV1alphaSchema", + "properties": { + "fieldConfigs": { + "description": "Output only. Configurations for fields of the schema.", + "items": { + "$ref": "GoogleCloudDiscoveryengineV1alphaFieldConfig" + }, + "readOnly": true, + "type": "array" + }, + "jsonSchema": { + "description": "The JSON representation of the schema.", + "type": "string" + }, + "name": { + "description": "Immutable. The full resource name of the schema, in the format of `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/schemas/{schema}`. This field must be a UTF-8 encoded string with a length limit of 1024 characters.", + "type": "string" + }, + "structSchema": { + "additionalProperties": { + "description": "Properties of the object.", + "type": "any" + }, + "description": "The structured representation of the schema.", + "type": "object" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaSearchInfo": { + "description": "Detailed search information.", + "id": "GoogleCloudDiscoveryengineV1alphaSearchInfo", + "properties": { + "offset": { + "description": "An integer that specifies the current offset for pagination (the 0-indexed starting location, amongst the products deemed by the API as relevant). See SearchRequest.offset for definition. If this field is negative, an `INVALID_ARGUMENT` is returned. This can only be set for `search` events. Other event types should not set this field. Otherwise, an `INVALID_ARGUMENT` error is returned.", "format": "int32", "type": "integer" }, - "numNextSegments": { - "description": "Return at most `num_next_segments` segments after each selected segments.", - "format": "int32", - "type": "integer" + "orderBy": { + "description": "The order in which products are returned, if applicable. See SearchRequest.order_by for definition and syntax. The value must be a UTF-8 encoded string with a length limit of 1,000 characters. Otherwise, an `INVALID_ARGUMENT` error is returned. This can only be set for `search` events. Other event types should not set this field. Otherwise, an `INVALID_ARGUMENT` error is returned.", + "type": "string" + }, + "searchQuery": { + "description": "The user's search query. See SearchRequest.query for definition. The value must be a UTF-8 encoded string with a length limit of 5,000 characters. Otherwise, an `INVALID_ARGUMENT` error is returned. At least one of search_query or PageInfo.page_category is required for `search` events. Other event types should not set this field. Otherwise, an `INVALID_ARGUMENT` error is returned.", + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaSearchRequest": { + "description": "Request message for SearchService.Search method.", + "id": "GoogleCloudDiscoveryengineV1alphaSearchRequest", + "properties": { + "boostSpec": { + "$ref": "GoogleCloudDiscoveryengineV1alphaSearchRequestBoostSpec", + "description": "Boost specification to boost certain documents. For more information on boosting, see [Boosting](https://cloud.google.com/retail/docs/boosting#boost)" + }, + "branch": { + "description": "The branch resource name, such as `projects/*/locations/global/collections/default_collection/dataStores/default_data_store/branches/0`. Use `default_branch` as the branch ID or leave this field empty, to search documents under the default branch.", + "type": "string" + }, + "canonicalFilter": { + "description": "The default filter that is applied when a user performs a search without checking any filters on the search page. The filter applied to every search request when quality improvement such as query expansion is needed. In the case a query does not have a sufficient amount of results this filter will be used to determine whether or not to enable the query expansion flow. The original filter will still be used for the query expanded search. This field is strongly recommended to achieve high search quality. For more information about filter syntax, see SearchRequest.filter.", + "type": "string" + }, + "contentSearchSpec": { + "$ref": "GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpec", + "description": "A specification for configuring the behavior of content search." + }, + "embeddingSpec": { + "$ref": "GoogleCloudDiscoveryengineV1alphaSearchRequestEmbeddingSpec", + "description": "Uses the provided embedding to do additional semantic document retrieval. The retrieval is based on the dot product of SearchRequest.EmbeddingSpec.EmbeddingVector.vector and the document embedding that is provided in SearchRequest.EmbeddingSpec.EmbeddingVector.field_path. If SearchRequest.EmbeddingSpec.EmbeddingVector.field_path is not provided, it will use ServingConfig.EmbeddingConfig.field_paths." + }, + "facetSpecs": { + "description": "Facet specifications for faceted search. If empty, no facets are returned. A maximum of 100 values are allowed. Otherwise, an `INVALID_ARGUMENT` error is returned.", + "items": { + "$ref": "GoogleCloudDiscoveryengineV1alphaSearchRequestFacetSpec" + }, + "type": "array" + }, + "filter": { + "description": "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" + }, + "imageQuery": { + "$ref": "GoogleCloudDiscoveryengineV1alphaSearchRequestImageQuery", + "description": "Raw image query." + }, + "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.", + "format": "int32", + "type": "integer" + }, + "orderBy": { + "description": "The order in which documents are returned. Documents can be ordered by a field in an Document object. Leave it unset if ordered by relevance. `order_by` expression is case-sensitive. For more information on ordering, see [Ordering](https://cloud.google.com/retail/docs/filter-and-order#order) If this field is unrecognizable, an `INVALID_ARGUMENT` is returned.", + "type": "string" + }, + "pageSize": { + "description": "Maximum number of Documents to return. If unspecified, defaults to a reasonable value. The maximum allowed value is 100. Values above 100 are coerced to 100. If this field is negative, an `INVALID_ARGUMENT` is returned.", + "format": "int32", + "type": "integer" + }, + "pageToken": { + "description": "A page token received from a previous SearchService.Search call. Provide this to retrieve the subsequent page. When paginating, all other parameters provided to SearchService.Search must match the call that provided the page token. Otherwise, an `INVALID_ARGUMENT` error is returned.", + "type": "string" + }, + "params": { + "additionalProperties": { + "type": "any" + }, + "description": "Additional search parameters. For public website search only, supported values are: * `user_country_code`: string. Default empty. If set to non-empty, results are restricted or boosted based on the location provided. Example: user_country_code: \"au\" For available codes see [Country Codes](https://developers.google.com/custom-search/docs/json_api_reference#countryCodes) * `search_type`: double. Default empty. Enables non-webpage searching depending on the value. The only valid non-default value is 1, which enables image searching. Example: search_type: 1", + "type": "object" + }, + "query": { + "description": "Raw search query.", + "type": "string" + }, + "queryExpansionSpec": { + "$ref": "GoogleCloudDiscoveryengineV1alphaSearchRequestQueryExpansionSpec", + "description": "The query expansion specification that specifies the conditions under which query expansion occurs." + }, + "rankingExpression": { + "description": "The ranking expression controls the customized ranking on retrieval documents. This overrides ServingConfig.ranking_expression. The ranking expression is a single function or multiple functions that are joint by \"+\". * ranking_expression = function, { \" + \", function }; Supported functions: * double * relevance_score * double * dotProduct(embedding_field_path) Function variables: `relevance_score`: pre-defined keywords, used for measure relevance between query and document. `embedding_field_path`: the document embedding field used with query embedding vector. `dotProduct`: embedding function between embedding_field_path and query embedding vector. Example ranking expression: If document has an embedding field doc_embedding, the ranking expression could be `0.5 * relevance_score + 0.3 * dotProduct(doc_embedding)`.", + "type": "string" + }, + "safeSearch": { + "description": "Whether to turn on safe search. This is only supported for website search.", + "type": "boolean" + }, + "servingConfig": { + "description": "Required. The resource name of the Search serving config, such as `projects/*/locations/global/collections/default_collection/engines/*/servingConfigs/default_serving_config`, or `projects/*/locations/global/collections/default_collection/dataStores/default_data_store/servingConfigs/default_serving_config`. This field is used to identify the serving configuration name, set of models used to make the search.", + "type": "string" + }, + "spellCorrectionSpec": { + "$ref": "GoogleCloudDiscoveryengineV1alphaSearchRequestSpellCorrectionSpec", + "description": "The spell correction specification that specifies the mode under which spell correction takes effect." + }, + "userInfo": { + "$ref": "GoogleCloudDiscoveryengineV1alphaUserInfo", + "description": "Information about the end user. Highly recommended for analytics. UserInfo.user_agent is used to deduce `device_type` for analytics." + }, + "userLabels": { + "additionalProperties": { + "type": "string" + }, + "description": "The user labels applied to a resource must meet the following requirements: * Each resource can have multiple labels, up to a maximum of 64. * Each label must be a key-value pair. * Keys have a minimum length of 1 character and a maximum length of 63 characters and cannot be empty. Values can be empty and have a maximum length of 63 characters. * Keys and values can contain only lowercase letters, numeric characters, underscores, and dashes. All characters must use UTF-8 encoding, and international characters are allowed. * The key portion of a label must be unique. However, you can use the same key with multiple resources. * Keys must start with a lowercase letter or international character. See [Google Cloud Document](https://cloud.google.com/resource-manager/docs/creating-managing-labels#requirements) for more details.", + "type": "object" + }, + "userPseudoId": { + "description": "A unique identifier for tracking visitors. For example, this could be implemented with an HTTP cookie, which should be able to uniquely identify a visitor on a single device. This unique identifier should not change if the visitor logs in or out of the website. This field should NOT have a fixed value such as `unknown_visitor`. This should be the same identifier as UserEvent.user_pseudo_id and CompleteQueryRequest.user_pseudo_id The field must be a UTF-8 encoded string with a length limit of 128 characters. Otherwise, an `INVALID_ARGUMENT` error is returned.", + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaSearchRequestBoostSpec": { + "description": "Boost specification to boost certain documents.", + "id": "GoogleCloudDiscoveryengineV1alphaSearchRequestBoostSpec", + "properties": { + "conditionBoostSpecs": { + "description": "Condition boost specifications. If a document matches multiple conditions in the specifictions, boost scores from these specifications are all applied and combined in a non-linear way. Maximum number of specifications is 20.", + "items": { + "$ref": "GoogleCloudDiscoveryengineV1alphaSearchRequestBoostSpecConditionBoostSpec" + }, + "type": "array" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaSearchRequestBoostSpecConditionBoostSpec": { + "description": "Boost applies to documents which match a condition.", + "id": "GoogleCloudDiscoveryengineV1alphaSearchRequestBoostSpecConditionBoostSpec", + "properties": { + "boost": { + "description": "Strength of the condition boost, which should be in [-1, 1]. Negative boost means demotion. Default is 0.0. Setting to 1.0 gives the document a big promotion. However, it does not necessarily mean that the boosted document will be the top result at all times, nor that other documents will be excluded. Results could still be shown even when none of them matches the condition. And results that are significantly more relevant to the search query can still trump your heavily favored but irrelevant documents. Setting to -1.0 gives the document a big demotion. However, results that are deeply relevant might still be shown. The document will have an upstream battle to get a fairly high ranking, but it is not blocked out completely. Setting to 0.0 means no boost applied. The boosting condition is ignored.", + "format": "float", + "type": "number" + }, + "condition": { + "description": "An expression which specifies a boost condition. The syntax and supported fields are the same as a filter expression. See SearchRequest.filter for detail syntax and limitations. Examples: * To boost documents with document ID \"doc_1\" or \"doc_2\", and color \"Red\" or \"Blue\": * (id: ANY(\"doc_1\", \"doc_2\")) AND (color: ANY(\"Red\",\"Blue\"))", + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpec": { + "description": "A specification for configuring the behavior of content search.", + "id": "GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpec", + "properties": { + "extractiveContentSpec": { + "$ref": "GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecExtractiveContentSpec", + "description": "If there is no extractive_content_spec provided, there will be no extractive answer in the search response." + }, + "snippetSpec": { + "$ref": "GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSnippetSpec", + "description": "If `snippetSpec` is not specified, snippets are not included in the search response." + }, + "summarySpec": { + "$ref": "GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSummarySpec", + "description": "If `summarySpec` is not specified, summaries are not included in the search response." + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecExtractiveContentSpec": { + "description": "A specification for configuring the extractive content in a search response.", + "id": "GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecExtractiveContentSpec", + "properties": { + "maxExtractiveAnswerCount": { + "description": "The maximum number of extractive answers returned in each search result. An extractive answer is a verbatim answer extracted from the original document, which provides a precise and contextually relevant answer to the search query. If the number of matching answers is less than the `max_extractive_answer_count`, return all of the answers. Otherwise, return the `max_extractive_answer_count`. At most five answers are returned for each SearchResult.", + "format": "int32", + "type": "integer" + }, + "maxExtractiveSegmentCount": { + "description": "The max number of extractive segments returned in each search result. Only applied if the DataStore is set to DataStore.ContentConfig.CONTENT_REQUIRED or DataStore.solution_types is SOLUTION_TYPE_CHAT. An extractive segment is a text segment extracted from the original document that is relevant to the search query, and, in general, more verbose than an extractive answer. The segment could then be used as input for LLMs to generate summaries and answers. If the number of matching segments is less than `max_extractive_segment_count`, return all of the segments. Otherwise, return the `max_extractive_segment_count`.", + "format": "int32", + "type": "integer" + }, + "numNextSegments": { + "description": "Return at most `num_next_segments` segments after each selected segments.", + "format": "int32", + "type": "integer" + }, + "numPreviousSegments": { + "description": "Specifies whether to also include the adjacent from each selected segments. Return at most `num_previous_segments` segments before each selected segments.", + "format": "int32", + "type": "integer" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSnippetSpec": { + "description": "A specification for configuring snippets in a search response.", + "id": "GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSnippetSpec", + "properties": { + "maxSnippetCount": { + "deprecated": true, + "description": "[DEPRECATED] This field is deprecated. To control snippet return, use `return_snippet` field. For backwards compatibility, we will return snippet if max_snippet_count \u003e 0.", + "format": "int32", + "type": "integer" + }, + "referenceOnly": { + "deprecated": true, + "description": "[DEPRECATED] This field is deprecated and will have no affect on the snippet.", + "type": "boolean" + }, + "returnSnippet": { + "description": "If `true`, then return snippet. If no snippet can be generated, we return \"No snippet is available for this page.\" A `snippet_status` with `SUCCESS` or `NO_SNIPPET_AVAILABLE` will also be returned.", + "type": "boolean" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSummarySpec": { + "description": "A specification for configuring a summary returned in a search response.", + "id": "GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSummarySpec", + "properties": { + "ignoreAdversarialQuery": { + "description": "Specifies whether to filter out adversarial queries. The default value is `false`. Google employs search-query classification to detect adversarial queries. No summary is returned if the search query is classified as an adversarial query. For example, a user might ask a question regarding negative comments about the company or submit a query designed to generate unsafe, policy-violating output. If this field is set to `true`, we skip generating summaries for adversarial queries and return fallback messages instead.", + "type": "boolean" + }, + "ignoreNonSummarySeekingQuery": { + "description": "Specifies whether to filter out queries that are not summary-seeking. The default value is `false`. Google employs search-query classification to detect summary-seeking queries. No summary is returned if the search query is classified as a non-summary seeking query. For example, `why is the sky blue` and `Who is the best soccer player in the world?` are summary-seeking queries, but `SFO airport` and `world cup 2026` are not. They are most likely navigational queries. If this field is set to `true`, we skip generating summaries for non-summary seeking queries and return fallback messages instead.", + "type": "boolean" + }, + "includeCitations": { + "description": "Specifies whether to include citations in the summary. The default value is `false`. When this field is set to `true`, summaries include in-line citation numbers. Example summary including citations: BigQuery is Google Cloud's fully managed and completely serverless enterprise data warehouse [1]. BigQuery supports all data types, works across clouds, and has built-in machine learning and business intelligence, all within a unified platform [2, 3]. The citation numbers refer to the returned search results and are 1-indexed. For example, [1] means that the sentence is attributed to the first search result. [2, 3] means that the sentence is attributed to both the second and third search results.", + "type": "boolean" + }, + "languageCode": { + "description": "Language code for Summary. Use language tags defined by [BCP47](https://www.rfc-editor.org/rfc/bcp/bcp47.txt). Note: This is an experimental feature.", + "type": "string" + }, + "modelPromptSpec": { + "$ref": "GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSummarySpecModelPromptSpec", + "description": "If specified, the spec will be used to modify the prompt provided to the LLM." + }, + "modelSpec": { + "$ref": "GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSummarySpecModelSpec", + "description": "If specified, the spec will be used to modify the model specification provided to the LLM." + }, + "summaryResultCount": { + "description": "The number of top results to generate the summary from. If the number of results returned is less than `summaryResultCount`, the summary is generated from all of the results. At most five results can be used to generate a summary.", + "format": "int32", + "type": "integer" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSummarySpecModelPromptSpec": { + "description": "Specification of the prompt to use with the model.", + "id": "GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSummarySpecModelPromptSpec", + "properties": { + "preamble": { + "description": "Text at the beginning of the prompt that instructs the assistant. Examples are available in the user guide.", + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSummarySpecModelSpec": { + "description": "Specification of the model.", + "id": "GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSummarySpecModelSpec", + "properties": { + "version": { + "description": "The model version used to generate the summary. Supported values are: * `stable`: string. Default value when no value is specified. Uses a generally available, fine-tuned version of the text-bison@001 model. * `preview`: string. (Public preview) Uses a fine-tuned version of the text-bison@002 model. This model works only for summaries in English.", + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaSearchRequestEmbeddingSpec": { + "description": "The specification that uses customized query embedding vector to do semantic document retrieval.", + "id": "GoogleCloudDiscoveryengineV1alphaSearchRequestEmbeddingSpec", + "properties": { + "embeddingVectors": { + "description": "The embedding vector used for retrieval. Limit to 1.", + "items": { + "$ref": "GoogleCloudDiscoveryengineV1alphaSearchRequestEmbeddingSpecEmbeddingVector" + }, + "type": "array" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaSearchRequestEmbeddingSpecEmbeddingVector": { + "description": "Embedding vector.", + "id": "GoogleCloudDiscoveryengineV1alphaSearchRequestEmbeddingSpecEmbeddingVector", + "properties": { + "fieldPath": { + "description": "Embedding field path in schema.", + "type": "string" + }, + "vector": { + "description": "Query embedding vector.", + "items": { + "format": "float", + "type": "number" + }, + "type": "array" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaSearchRequestFacetSpec": { + "description": "A facet specification to perform faceted search.", + "id": "GoogleCloudDiscoveryengineV1alphaSearchRequestFacetSpec", + "properties": { + "enableDynamicPosition": { + "description": "Enables dynamic position for this facet. If set to true, the position of this facet among all facets in the response is determined automatically. If dynamic facets are enabled, it is ordered together. If set to false, the position of this facet in the response is the same as in the request, and it is ranked before the facets with dynamic position enable and all dynamic facets. For example, you may always want to have rating facet returned in the response, but it's not necessarily to always display the rating facet at the top. In that case, you can set enable_dynamic_position to true so that the position of rating facet in response is determined automatically. Another example, assuming you have the following facets in the request: * \"rating\", enable_dynamic_position = true * \"price\", enable_dynamic_position = false * \"brands\", enable_dynamic_position = false And also you have a dynamic facets enabled, which generates a facet `gender`. Then the final order of the facets in the response can be (\"price\", \"brands\", \"rating\", \"gender\") or (\"price\", \"brands\", \"gender\", \"rating\") depends on how API orders \"gender\" and \"rating\" facets. However, notice that \"price\" and \"brands\" are always ranked at first and second position because their enable_dynamic_position is false.", + "type": "boolean" + }, + "excludedFilterKeys": { + "description": "List of keys to exclude when faceting. By default, FacetKey.key is not excluded from the filter unless it is listed in this field. Listing a facet key in this field allows its values to appear as facet results, even when they are filtered out of search results. Using this field does not affect what search results are returned. For example, suppose there are 100 documents with the color facet \"Red\" and 200 documents with the color facet \"Blue\". A query containing the filter \"color:ANY(\"Red\")\" and having \"color\" as FacetKey.key would by default return only \"Red\" documents in the search results, and also return \"Red\" with count 100 as the only color facet. Although there are also blue documents available, \"Blue\" would not be shown as an available facet value. If \"color\" is listed in \"excludedFilterKeys\", then the query returns the facet values \"Red\" with count 100 and \"Blue\" with count 200, because the \"color\" key is now excluded from the filter. Because this field doesn't affect search results, the search results are still correctly filtered to return only \"Red\" documents. A maximum of 100 values are allowed. Otherwise, an `INVALID_ARGUMENT` error is returned.", + "items": { + "type": "string" + }, + "type": "array" + }, + "facetKey": { + "$ref": "GoogleCloudDiscoveryengineV1alphaSearchRequestFacetSpecFacetKey", + "description": "Required. The facet key specification." + }, + "limit": { + "description": "Maximum of facet values that should be returned for this facet. If unspecified, defaults to 20. The maximum allowed value is 300. Values above 300 are coerced to 300. If this field is negative, an `INVALID_ARGUMENT` is returned.", + "format": "int32", + "type": "integer" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaSearchRequestFacetSpecFacetKey": { + "description": "Specifies how a facet is computed.", + "id": "GoogleCloudDiscoveryengineV1alphaSearchRequestFacetSpecFacetKey", + "properties": { + "caseInsensitive": { + "description": "True to make facet keys case insensitive when getting faceting values with prefixes or contains; false otherwise.", + "type": "boolean" + }, + "contains": { + "description": "Only get facet values that contains the given strings. For example, suppose \"category\" has three values \"Action \u003e 2022\", \"Action \u003e 2021\" and \"Sci-Fi \u003e 2022\". If set \"contains\" to \"2022\", the \"category\" facet only contains \"Action \u003e 2022\" and \"Sci-Fi \u003e 2022\". Only supported on textual fields. Maximum is 10.", + "items": { + "type": "string" + }, + "type": "array" + }, + "intervals": { + "description": "Set only if values should be bucketed into intervals. Must be set for facets with numerical values. Must not be set for facet with text values. Maximum number of intervals is 30.", + "items": { + "$ref": "GoogleCloudDiscoveryengineV1alphaInterval" + }, + "type": "array" + }, + "key": { + "description": "Required. Supported textual and numerical facet keys in Document object, over which the facet values are computed. Facet key is case-sensitive.", + "type": "string" + }, + "orderBy": { + "description": "The order in which documents are returned. Allowed values are: * \"count desc\", which means order by SearchResponse.Facet.values.count descending. * \"value desc\", which means order by SearchResponse.Facet.values.value descending. Only applies to textual facets. If not set, textual values are sorted in [natural order](https://en.wikipedia.org/wiki/Natural_sort_order); numerical intervals are sorted in the order given by FacetSpec.FacetKey.intervals.", + "type": "string" + }, + "prefixes": { + "description": "Only get facet values that start with the given string prefix. For example, suppose \"category\" has three values \"Action \u003e 2022\", \"Action \u003e 2021\" and \"Sci-Fi \u003e 2022\". If set \"prefixes\" to \"Action\", the \"category\" facet only contains \"Action \u003e 2022\" and \"Action \u003e 2021\". Only supported on textual fields. Maximum is 10.", + "items": { + "type": "string" + }, + "type": "array" + }, + "restrictedValues": { + "description": "Only get facet for the given restricted values. Only supported on textual fields. For example, suppose \"category\" has three values \"Action \u003e 2022\", \"Action \u003e 2021\" and \"Sci-Fi \u003e 2022\". If set \"restricted_values\" to \"Action \u003e 2022\", the \"category\" facet only contains \"Action \u003e 2022\". Only supported on textual fields. Maximum is 10.", + "items": { + "type": "string" + }, + "type": "array" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaSearchRequestImageQuery": { + "description": "Specifies the image query input.", + "id": "GoogleCloudDiscoveryengineV1alphaSearchRequestImageQuery", + "properties": { + "imageBytes": { + "description": "Base64 encoded image bytes. Supported image formats: JPEG, PNG, and BMP.", + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaSearchRequestQueryExpansionSpec": { + "description": "Specification to determine under which conditions query expansion should occur.", + "id": "GoogleCloudDiscoveryengineV1alphaSearchRequestQueryExpansionSpec", + "properties": { + "condition": { + "description": "The condition under which query expansion should occur. Default to Condition.DISABLED.", + "enum": [ + "CONDITION_UNSPECIFIED", + "DISABLED", + "AUTO" + ], + "enumDescriptions": [ + "Unspecified query expansion condition. In this case, server behavior defaults to Condition.DISABLED.", + "Disabled query expansion. Only the exact search query is used, even if SearchResponse.total_size is zero.", + "Automatic query expansion built by the Search API." + ], + "type": "string" + }, + "pinUnexpandedResults": { + "description": "Whether to pin unexpanded results. If this field is set to true, unexpanded products are always at the top of the search results, followed by the expanded results.", + "type": "boolean" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaSearchRequestSpellCorrectionSpec": { + "description": "The specification for query spell correction.", + "id": "GoogleCloudDiscoveryengineV1alphaSearchRequestSpellCorrectionSpec", + "properties": { + "mode": { + "description": "The mode under which spell correction should take effect to replace the original search query. Default to Mode.AUTO.", + "enum": [ + "MODE_UNSPECIFIED", + "SUGGESTION_ONLY", + "AUTO" + ], + "enumDescriptions": [ + "Unspecified spell correction mode. In this case, server behavior defaults to Mode.AUTO.", + "Search API will try to find a spell suggestion if there is any and put in the SearchResponse.corrected_query. The spell suggestion will not be used as the search query.", + "Automatic spell correction built by the Search API. Search will be based on the corrected query if found." + ], + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaSearchResponse": { + "description": "Response message for SearchService.Search method.", + "id": "GoogleCloudDiscoveryengineV1alphaSearchResponse", + "properties": { + "appliedControls": { + "description": "Controls applied as part of the Control service.", + "items": { + "type": "string" + }, + "type": "array" + }, + "attributionToken": { + "description": "A unique search token. This should be included in the UserEvent logs resulting from this search, which enables accurate attribution of search model performance.", + "type": "string" + }, + "correctedQuery": { + "description": "Contains the spell corrected query, if found. If the spell correction type is AUTOMATIC, then the search results are based on corrected_query. Otherwise the original query is used for search.", + "type": "string" + }, + "facets": { + "description": "Results of facets requested by user.", + "items": { + "$ref": "GoogleCloudDiscoveryengineV1alphaSearchResponseFacet" + }, + "type": "array" + }, + "geoSearchDebugInfo": { + "items": { + "$ref": "GoogleCloudDiscoveryengineV1alphaSearchResponseGeoSearchDebugInfo" + }, + "type": "array" + }, + "guidedSearchResult": { + "$ref": "GoogleCloudDiscoveryengineV1alphaSearchResponseGuidedSearchResult", + "description": "Guided search result." + }, + "nextPageToken": { + "description": "A token that can be sent as SearchRequest.page_token to retrieve the next page. If this field is omitted, there are no subsequent pages.", + "type": "string" + }, + "queryExpansionInfo": { + "$ref": "GoogleCloudDiscoveryengineV1alphaSearchResponseQueryExpansionInfo", + "description": "Query expansion information for the returned results." + }, + "redirectUri": { + "description": "The URI of a customer-defined redirect page. If redirect action is triggered, no search is performed, and only redirect_uri and attribution_token are set in the response.", + "type": "string" + }, + "results": { + "description": "A list of matched documents. The order represents the ranking.", + "items": { + "$ref": "GoogleCloudDiscoveryengineV1alphaSearchResponseSearchResult" + }, + "type": "array" + }, + "summary": { + "$ref": "GoogleCloudDiscoveryengineV1alphaSearchResponseSummary", + "description": "A summary as part of the search results. This field is only returned if SearchRequest.ContentSearchSpec.summary_spec is set." + }, + "totalSize": { + "description": "The estimated total count of matched items irrespective of pagination. The count of results returned by pagination may be less than the total_size that matches.", + "format": "int32", + "type": "integer" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaSearchResponseFacet": { + "description": "A facet result.", + "id": "GoogleCloudDiscoveryengineV1alphaSearchResponseFacet", + "properties": { + "dynamicFacet": { + "description": "Whether the facet is dynamically generated.", + "type": "boolean" + }, + "key": { + "description": "The key for this facet. E.g., \"colors\" or \"price\". It matches SearchRequest.FacetSpec.FacetKey.key.", + "type": "string" + }, + "values": { + "description": "The facet values for this field.", + "items": { + "$ref": "GoogleCloudDiscoveryengineV1alphaSearchResponseFacetFacetValue" + }, + "type": "array" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaSearchResponseFacetFacetValue": { + "description": "A facet value which contains value names and their count.", + "id": "GoogleCloudDiscoveryengineV1alphaSearchResponseFacetFacetValue", + "properties": { + "count": { + "description": "Number of items that have this facet value.", + "format": "int64", + "type": "string" + }, + "interval": { + "$ref": "GoogleCloudDiscoveryengineV1alphaInterval", + "description": "Interval value for a facet, such as 10, 20) for facet \"price\". It matches [SearchRequest.FacetSpec.FacetKey.intervals." }, - "numPreviousSegments": { - "description": "Specifies whether to also include the adjacent from each selected segments. Return at most `num_previous_segments` segments before each selected segments.", - "format": "int32", - "type": "integer" + "value": { + "description": "Text value of a facet, such as \"Black\" for facet \"colors\".", + "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSnippetSpec": { - "description": "A specification for configuring snippets in a search response.", - "id": "GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSnippetSpec", + "GoogleCloudDiscoveryengineV1alphaSearchResponseGeoSearchDebugInfo": { + "description": "Debug information specifically related to forward geocoding issues arising from Geolocation Search.", + "id": "GoogleCloudDiscoveryengineV1alphaSearchResponseGeoSearchDebugInfo", "properties": { - "maxSnippetCount": { - "deprecated": true, - "description": "[DEPRECATED] This field is deprecated. To control snippet return, use `return_snippet` field. For backwards compatibility, we will return snippet if max_snippet_count \u003e 0.", - "format": "int32", - "type": "integer" - }, - "referenceOnly": { - "deprecated": true, - "description": "[DEPRECATED] This field is deprecated and will have no affect on the snippet.", - "type": "boolean" + "errorMessage": { + "description": "The error produced.", + "type": "string" }, - "returnSnippet": { - "description": "If `true`, then return snippet. If no snippet can be generated, we return \"No snippet is available for this page.\" A `snippet_status` with `SUCCESS` or `NO_SNIPPET_AVAILABLE` will also be returned.", - "type": "boolean" + "originalAddressQuery": { + "description": "The address from which forward geocoding ingestion produced issues.", + "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSummarySpec": { - "description": "A specification for configuring a summary returned in a search response.", - "id": "GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSummarySpec", + "GoogleCloudDiscoveryengineV1alphaSearchResponseGuidedSearchResult": { + "description": "Guided search result. The guided search helps user to refine the search results and narrow down to the real needs from a broaded search results.", + "id": "GoogleCloudDiscoveryengineV1alphaSearchResponseGuidedSearchResult", "properties": { - "ignoreAdversarialQuery": { - "description": "Specifies whether to filter out adversarial queries. The default value is `false`. Google employs search-query classification to detect adversarial queries. No summary is returned if the search query is classified as an adversarial query. For example, a user might ask a question regarding negative comments about the company or submit a query designed to generate unsafe, policy-violating output. If this field is set to `true`, we skip generating summaries for adversarial queries and return fallback messages instead.", - "type": "boolean" - }, - "ignoreNonSummarySeekingQuery": { - "description": "Specifies whether to filter out queries that are not summary-seeking. The default value is `false`. Google employs search-query classification to detect summary-seeking queries. No summary is returned if the search query is classified as a non-summary seeking query. For example, `why is the sky blue` and `Who is the best soccer player in the world?` are summary-seeking queries, but `SFO airport` and `world cup 2026` are not. They are most likely navigational queries. If this field is set to `true`, we skip generating summaries for non-summary seeking queries and return fallback messages instead.", - "type": "boolean" - }, - "includeCitations": { - "description": "Specifies whether to include citations in the summary. The default value is `false`. When this field is set to `true`, summaries include in-line citation numbers. Example summary including citations: BigQuery is Google Cloud's fully managed and completely serverless enterprise data warehouse [1]. BigQuery supports all data types, works across clouds, and has built-in machine learning and business intelligence, all within a unified platform [2, 3]. The citation numbers refer to the returned search results and are 1-indexed. For example, [1] means that the sentence is attributed to the first search result. [2, 3] means that the sentence is attributed to both the second and third search results.", - "type": "boolean" + "followUpQuestions": { + "description": "Suggested follow-up questions.", + "items": { + "type": "string" + }, + "type": "array" }, - "languageCode": { - "description": "Language code for Summary. Use language tags defined by [BCP47](https://www.rfc-editor.org/rfc/bcp/bcp47.txt). Note: This is an experimental feature.", + "refinementAttributes": { + "description": "A list of ranked refinement attributes.", + "items": { + "$ref": "GoogleCloudDiscoveryengineV1alphaSearchResponseGuidedSearchResultRefinementAttribute" + }, + "type": "array" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaSearchResponseGuidedSearchResultRefinementAttribute": { + "description": "Useful attribute for search result refinements.", + "id": "GoogleCloudDiscoveryengineV1alphaSearchResponseGuidedSearchResultRefinementAttribute", + "properties": { + "attributeKey": { + "description": "Attribute key used to refine the results e.g. 'movie_type'.", "type": "string" }, - "modelPromptSpec": { - "$ref": "GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSummarySpecModelPromptSpec", - "description": "If specified, the spec will be used to modify the prompt provided to the LLM." - }, - "modelSpec": { - "$ref": "GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSummarySpecModelSpec", - "description": "If specified, the spec will be used to modify the model specification provided to the LLM." - }, - "summaryResultCount": { - "description": "The number of top results to generate the summary from. If the number of results returned is less than `summaryResultCount`, the summary is generated from all of the results. At most five results can be used to generate a summary.", - "format": "int32", - "type": "integer" + "attributeValue": { + "description": "Attribute value used to refine the results e.g. 'drama'.", + "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSummarySpecModelPromptSpec": { - "description": "Specification of the prompt to use with the model.", - "id": "GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSummarySpecModelPromptSpec", + "GoogleCloudDiscoveryengineV1alphaSearchResponseQueryExpansionInfo": { + "description": "Information describing query expansion including whether expansion has occurred.", + "id": "GoogleCloudDiscoveryengineV1alphaSearchResponseQueryExpansionInfo", "properties": { - "preamble": { - "description": "Text at the beginning of the prompt that instructs the assistant. Examples are available in the user guide.", + "expandedQuery": { + "description": "Bool describing whether query expansion has occurred.", + "type": "boolean" + }, + "pinnedResultCount": { + "description": "Number of pinned results. This field will only be set when expansion happens and SearchRequest.QueryExpansionSpec.pin_unexpanded_results is set to true.", + "format": "int64", "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSummarySpecModelSpec": { - "description": "Specification of the model.", - "id": "GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSummarySpecModelSpec", + "GoogleCloudDiscoveryengineV1alphaSearchResponseSearchResult": { + "description": "Represents the search results.", + "id": "GoogleCloudDiscoveryengineV1alphaSearchResponseSearchResult", "properties": { - "version": { - "description": "The model version used to generate the summary. Supported values are: * `stable`: string. Default value when no value is specified. Uses a generally available, fine-tuned version of the text-bison@001 model. * `preview`: string. (Public preview) Uses a fine-tuned version of the text-bison@002 model. This model works only for summaries in English.", + "document": { + "$ref": "GoogleCloudDiscoveryengineV1alphaDocument", + "description": "The document data snippet in the search response. Only fields that are marked as retrievable are populated." + }, + "id": { + "description": "Document.id of the searched Document.", "type": "string" + }, + "modelScores": { + "additionalProperties": { + "$ref": "GoogleCloudDiscoveryengineV1alphaDoubleList" + }, + "description": "Google provided available scores.", + "type": "object" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaSearchRequestEmbeddingSpec": { - "description": "The specification that uses customized query embedding vector to do semantic document retrieval.", - "id": "GoogleCloudDiscoveryengineV1alphaSearchRequestEmbeddingSpec", + "GoogleCloudDiscoveryengineV1alphaSearchResponseSummary": { + "description": "Summary of the top N search result specified by the summary spec.", + "id": "GoogleCloudDiscoveryengineV1alphaSearchResponseSummary", "properties": { - "embeddingVectors": { - "description": "The embedding vector used for retrieval. Limit to 1.", + "safetyAttributes": { + "$ref": "GoogleCloudDiscoveryengineV1alphaSearchResponseSummarySafetyAttributes", + "description": "A collection of Safety Attribute categories and their associated confidence scores." + }, + "summarySkippedReasons": { + "description": "Additional summary-skipped reasons. This provides the reason for ignored cases. If nothing is skipped, this field is not set.", "items": { - "$ref": "GoogleCloudDiscoveryengineV1alphaSearchRequestEmbeddingSpecEmbeddingVector" + "enum": [ + "SUMMARY_SKIPPED_REASON_UNSPECIFIED", + "ADVERSARIAL_QUERY_IGNORED", + "NON_SUMMARY_SEEKING_QUERY_IGNORED", + "OUT_OF_DOMAIN_QUERY_IGNORED", + "POTENTIAL_POLICY_VIOLATION", + "LLM_ADDON_NOT_ENABLED" + ], + "enumDescriptions": [ + "Default value. The summary skipped reason is not specified.", + "The adversarial query ignored case. Only populated when SummarySpec.ignore_adversarial_query is set to `true`.", + "The non-summary seeking query ignored case. Only populated when SummarySpec.ignore_non_summary_seeking_query is set to `true`.", + "The out-of-domain query ignored case. Google skips the summary if there are no high-relevance search results. For example, the data store contains facts about company A but the user query is asking questions about company B.", + "The potential policy violation case. Google skips the summary if there is a potential policy violation detected. This includes content that may be violent or toxic.", + "The LLM addon not enabled case. Google skips the summary if the LLM addon is not enabled." + ], + "type": "string" }, "type": "array" + }, + "summaryText": { + "description": "The summary content.", + "type": "string" + }, + "summaryWithMetadata": { + "$ref": "GoogleCloudDiscoveryengineV1alphaSearchResponseSummarySummaryWithMetadata" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaSearchRequestEmbeddingSpecEmbeddingVector": { - "description": "Embedding vector.", - "id": "GoogleCloudDiscoveryengineV1alphaSearchRequestEmbeddingSpecEmbeddingVector", + "GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryCitation": { + "description": "Citation info for a segment.", + "id": "GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryCitation", "properties": { - "fieldPath": { - "description": "Embedding field path in schema.", + "endIndex": { + "description": "End of the attributed segment, exclusive.", + "format": "int64", "type": "string" }, - "vector": { - "description": "Query embedding vector.", + "sources": { + "description": "Citation sources for the attributed segment.", "items": { - "format": "float", - "type": "number" + "$ref": "GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryCitationSource" }, "type": "array" + }, + "startIndex": { + "description": "Index indicates the start of the segment, measured in bytes/unicode.", + "format": "int64", + "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaSearchRequestFacetSpec": { - "description": "A facet specification to perform faceted search.", - "id": "GoogleCloudDiscoveryengineV1alphaSearchRequestFacetSpec", + "GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryCitationMetadata": { + "description": "Citation metadata.", + "id": "GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryCitationMetadata", "properties": { - "enableDynamicPosition": { - "description": "Enables dynamic position for this facet. If set to true, the position of this facet among all facets in the response is determined automatically. If dynamic facets are enabled, it is ordered together. If set to false, the position of this facet in the response is the same as in the request, and it is ranked before the facets with dynamic position enable and all dynamic facets. For example, you may always want to have rating facet returned in the response, but it's not necessarily to always display the rating facet at the top. In that case, you can set enable_dynamic_position to true so that the position of rating facet in response is determined automatically. Another example, assuming you have the following facets in the request: * \"rating\", enable_dynamic_position = true * \"price\", enable_dynamic_position = false * \"brands\", enable_dynamic_position = false And also you have a dynamic facets enabled, which generates a facet `gender`. Then the final order of the facets in the response can be (\"price\", \"brands\", \"rating\", \"gender\") or (\"price\", \"brands\", \"gender\", \"rating\") depends on how API orders \"gender\" and \"rating\" facets. However, notice that \"price\" and \"brands\" are always ranked at first and second position because their enable_dynamic_position is false.", - "type": "boolean" - }, - "excludedFilterKeys": { - "description": "List of keys to exclude when faceting. By default, FacetKey.key is not excluded from the filter unless it is listed in this field. Listing a facet key in this field allows its values to appear as facet results, even when they are filtered out of search results. Using this field does not affect what search results are returned. For example, suppose there are 100 documents with the color facet \"Red\" and 200 documents with the color facet \"Blue\". A query containing the filter \"color:ANY(\"Red\")\" and having \"color\" as FacetKey.key would by default return only \"Red\" documents in the search results, and also return \"Red\" with count 100 as the only color facet. Although there are also blue documents available, \"Blue\" would not be shown as an available facet value. If \"color\" is listed in \"excludedFilterKeys\", then the query returns the facet values \"Red\" with count 100 and \"Blue\" with count 200, because the \"color\" key is now excluded from the filter. Because this field doesn't affect search results, the search results are still correctly filtered to return only \"Red\" documents. A maximum of 100 values are allowed. Otherwise, an `INVALID_ARGUMENT` error is returned.", + "citations": { + "description": "Citations for segments.", "items": { - "type": "string" + "$ref": "GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryCitation" }, "type": "array" - }, - "facetKey": { - "$ref": "GoogleCloudDiscoveryengineV1alphaSearchRequestFacetSpecFacetKey", - "description": "Required. The facet key specification." - }, - "limit": { - "description": "Maximum of facet values that should be returned for this facet. If unspecified, defaults to 20. The maximum allowed value is 300. Values above 300 are coerced to 300. If this field is negative, an `INVALID_ARGUMENT` is returned.", - "format": "int32", - "type": "integer" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaSearchRequestFacetSpecFacetKey": { - "description": "Specifies how a facet is computed.", - "id": "GoogleCloudDiscoveryengineV1alphaSearchRequestFacetSpecFacetKey", + "GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryCitationSource": { + "description": "Citation source.", + "id": "GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryCitationSource", "properties": { - "caseInsensitive": { - "description": "True to make facet keys case insensitive when getting faceting values with prefixes or contains; false otherwise.", - "type": "boolean" + "referenceIndex": { + "description": "Document reference index from SummaryWithMetadata.references. It is 0-indexed and the value will be zero if the reference_index is not set explicitly.", + "format": "int64", + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryReference": { + "description": "Document reference.", + "id": "GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryReference", + "properties": { + "document": { + "description": "Required. Document.name of the document. Full resource name of the referenced document, in the format `projects/*/locations/*/collections/*/dataStores/*/branches/*/documents/*`.", + "type": "string" }, - "contains": { - "description": "Only get facet values that contains the given strings. For example, suppose \"category\" has three values \"Action \u003e 2022\", \"Action \u003e 2021\" and \"Sci-Fi \u003e 2022\". If set \"contains\" to \"2022\", the \"category\" facet only contains \"Action \u003e 2022\" and \"Sci-Fi \u003e 2022\". Only supported on textual fields. Maximum is 10.", + "title": { + "description": "Title of the document.", + "type": "string" + }, + "uri": { + "description": "Cloud Storage or HTTP uri for the document.", + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaSearchResponseSummarySafetyAttributes": { + "description": "Safety Attribute categories and their associated confidence scores.", + "id": "GoogleCloudDiscoveryengineV1alphaSearchResponseSummarySafetyAttributes", + "properties": { + "categories": { + "description": "The display names of Safety Attribute categories associated with the generated content. Order matches the Scores.", "items": { "type": "string" }, "type": "array" }, - "intervals": { - "description": "Set only if values should be bucketed into intervals. Must be set for facets with numerical values. Must not be set for facet with text values. Maximum number of intervals is 30.", + "scores": { + "description": "The confidence scores of the each category, higher value means higher confidence. Order matches the Categories.", "items": { - "$ref": "GoogleCloudDiscoveryengineV1alphaInterval" + "format": "float", + "type": "number" }, "type": "array" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaSearchResponseSummarySummaryWithMetadata": { + "description": "Summary with metadata information.", + "id": "GoogleCloudDiscoveryengineV1alphaSearchResponseSummarySummaryWithMetadata", + "properties": { + "citationMetadata": { + "$ref": "GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryCitationMetadata", + "description": "Citation metadata for given summary." }, - "key": { - "description": "Required. Supported textual and numerical facet keys in Document object, over which the facet values are computed. Facet key is case-sensitive.", - "type": "string" - }, - "orderBy": { - "description": "The order in which documents are returned. Allowed values are: * \"count desc\", which means order by SearchResponse.Facet.values.count descending. * \"value desc\", which means order by SearchResponse.Facet.values.value descending. Only applies to textual facets. If not set, textual values are sorted in [natural order](https://en.wikipedia.org/wiki/Natural_sort_order); numerical intervals are sorted in the order given by FacetSpec.FacetKey.intervals.", - "type": "string" - }, - "prefixes": { - "description": "Only get facet values that start with the given string prefix. For example, suppose \"category\" has three values \"Action \u003e 2022\", \"Action \u003e 2021\" and \"Sci-Fi \u003e 2022\". If set \"prefixes\" to \"Action\", the \"category\" facet only contains \"Action \u003e 2022\" and \"Action \u003e 2021\". Only supported on textual fields. Maximum is 10.", + "references": { + "description": "Document References.", "items": { - "type": "string" + "$ref": "GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryReference" }, "type": "array" }, - "restrictedValues": { - "description": "Only get facet for the given restricted values. Only supported on textual fields. For example, suppose \"category\" has three values \"Action \u003e 2022\", \"Action \u003e 2021\" and \"Sci-Fi \u003e 2022\". If set \"restricted_values\" to \"Action \u003e 2022\", the \"category\" facet only contains \"Action \u003e 2022\". Only supported on textual fields. Maximum is 10.", - "items": { - "type": "string" - }, - "type": "array" + "summary": { + "description": "Summary text with no citation information.", + "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaSearchRequestImageQuery": { - "description": "Specifies the image query input.", - "id": "GoogleCloudDiscoveryengineV1alphaSearchRequestImageQuery", + "GoogleCloudDiscoveryengineV1alphaSiteSearchEngine": { + "description": "SiteSearchEngine captures DataStore level site search persisting configurations. It is a singleton value per data store.", + "id": "GoogleCloudDiscoveryengineV1alphaSiteSearchEngine", "properties": { - "imageBytes": { - "description": "Base64 encoded image bytes. Supported image formats: JPEG, PNG, and BMP.", + "name": { + "description": "The fully qualified resource name of the site search engine. Format: `projects/*/locations/*/dataStores/*/siteSearchEngine`", "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaSearchRequestQueryExpansionSpec": { - "description": "Specification to determine under which conditions query expansion should occur.", - "id": "GoogleCloudDiscoveryengineV1alphaSearchRequestQueryExpansionSpec", + "GoogleCloudDiscoveryengineV1alphaSiteVerificationInfo": { + "description": "Verification information for target sites in advanced site search.", + "id": "GoogleCloudDiscoveryengineV1alphaSiteVerificationInfo", "properties": { - "condition": { - "description": "The condition under which query expansion should occur. Default to Condition.DISABLED.", + "siteVerificationState": { + "description": "Site verification state indicating the ownership and validity.", "enum": [ - "CONDITION_UNSPECIFIED", - "DISABLED", - "AUTO" + "SITE_VERIFICATION_STATE_UNSPECIFIED", + "VERIFIED", + "UNVERIFIED", + "EXEMPTED" ], "enumDescriptions": [ - "Unspecified query expansion condition. In this case, server behavior defaults to Condition.DISABLED.", - "Disabled query expansion. Only the exact search query is used, even if SearchResponse.total_size is zero.", - "Automatic query expansion built by the Search API." + "Defaults to VERIFIED.", + "Site ownership verified.", + "Site ownership pending verification or verification failed.", + "Site exempt from verification, e.g., a public website that opens to all." ], "type": "string" }, - "pinUnexpandedResults": { - "description": "Whether to pin unexpanded results. If this field is set to true, unexpanded products are always at the top of the search results, followed by the expanded results.", - "type": "boolean" + "verifyTime": { + "description": "Latest site verification time.", + "format": "google-datetime", + "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaSearchRequestSpellCorrectionSpec": { - "description": "The specification for query spell correction.", - "id": "GoogleCloudDiscoveryengineV1alphaSearchRequestSpellCorrectionSpec", + "GoogleCloudDiscoveryengineV1alphaSuggestionDenyListEntry": { + "description": "Suggestion deny list entry identifying the phrase to block from suggestions and the applied operation for the phrase.", + "id": "GoogleCloudDiscoveryengineV1alphaSuggestionDenyListEntry", "properties": { - "mode": { - "description": "The mode under which spell correction should take effect to replace the original search query. Default to Mode.AUTO.", + "blockPhrase": { + "description": "Required. Phrase to block from suggestions served. Can be maximum 125 characters.", + "type": "string" + }, + "matchOperator": { + "description": "Required. The match operator to apply for this phrase. Whether to block the exact phrase, or block any suggestions containing this phrase.", "enum": [ - "MODE_UNSPECIFIED", - "SUGGESTION_ONLY", - "AUTO" + "MATCH_OPERATOR_UNSPECIFIED", + "EXACT_MATCH", + "CONTAINS" ], "enumDescriptions": [ - "Unspecified spell correction mode. In this case, server behavior defaults to Mode.AUTO.", - "Search API will try to find a spell suggestion if there is any and put in the SearchResponse.corrected_query. The spell suggestion will not be used as the search query.", - "Automatic spell correction built by the Search API. Search will be based on the corrected query if found." + "Default value. Should not be used", + "If the suggestion is an exact match to the block_phrase, then block it.", + "If the suggestion contains the block_phrase, then block it." ], "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaSearchResponse": { - "description": "Response message for SearchService.Search method.", - "id": "GoogleCloudDiscoveryengineV1alphaSearchResponse", + "GoogleCloudDiscoveryengineV1alphaTargetSite": { + "description": "A target site for the SiteSearchEngine.", + "id": "GoogleCloudDiscoveryengineV1alphaTargetSite", "properties": { - "appliedControls": { - "description": "Controls applied as part of the Control service.", - "items": { - "type": "string" - }, - "type": "array" + "exactMatch": { + "description": "Input only. If set to false, a uri_pattern is generated to include all pages whose address contains the provided_uri_pattern. If set to true, an uri_pattern is generated to try to be an exact match of the provided_uri_pattern or just the specific page if the provided_uri_pattern is a specific one. provided_uri_pattern is always normalized to generate the URI pattern to be used by the search engine.", + "type": "boolean" }, - "attributionToken": { - "description": "A unique search token. This should be included in the UserEvent logs resulting from this search, which enables accurate attribution of search model performance.", - "type": "string" + "failureReason": { + "$ref": "GoogleCloudDiscoveryengineV1alphaTargetSiteFailureReason", + "description": "Output only. Failure reason.", + "readOnly": true }, - "correctedQuery": { - "description": "Contains the spell corrected query, if found. If the spell correction type is AUTOMATIC, then the search results are based on corrected_query. Otherwise the original query is used for search.", + "generatedUriPattern": { + "description": "Output only. This is system-generated based on the provided_uri_pattern.", + "readOnly": true, "type": "string" }, - "facets": { - "description": "Results of facets requested by user.", - "items": { - "$ref": "GoogleCloudDiscoveryengineV1alphaSearchResponseFacet" - }, - "type": "array" - }, - "geoSearchDebugInfo": { - "items": { - "$ref": "GoogleCloudDiscoveryengineV1alphaSearchResponseGeoSearchDebugInfo" - }, - "type": "array" - }, - "guidedSearchResult": { - "$ref": "GoogleCloudDiscoveryengineV1alphaSearchResponseGuidedSearchResult", - "description": "Guided search result." - }, - "nextPageToken": { - "description": "A token that can be sent as SearchRequest.page_token to retrieve the next page. If this field is omitted, there are no subsequent pages.", + "indexingStatus": { + "description": "Output only. Indexing status.", + "enum": [ + "INDEXING_STATUS_UNSPECIFIED", + "PENDING", + "FAILED", + "SUCCEEDED", + "DELETING" + ], + "enumDescriptions": [ + "Defaults to SUCCEEDED.", + "The target site is in the update queue and will be picked up by indexing pipeline.", + "The target site fails to be indexed.", + "The target site has been indexed.", + "The previously indexed target site has been marked to be deleted. This is a transitioning state which will resulted in either: 1. target site deleted if unindexing is successful; 2. state reverts to SUCCEEDED if the unindexing fails." + ], + "readOnly": true, "type": "string" }, - "queryExpansionInfo": { - "$ref": "GoogleCloudDiscoveryengineV1alphaSearchResponseQueryExpansionInfo", - "description": "Query expansion information for the returned results." + "name": { + "description": "Output only. The fully qualified resource name of the target site. `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/siteSearchEngine/targetSites/{target_site}` The `target_site_id` is system-generated.", + "readOnly": true, + "type": "string" }, - "redirectUri": { - "description": "The URI of a customer-defined redirect page. If redirect action is triggered, no search is performed, and only redirect_uri and attribution_token are set in the response.", + "providedUriPattern": { + "description": "Required. Input only. The user provided URI pattern from which the `generated_uri_pattern` is generated.", "type": "string" }, - "results": { - "description": "A list of matched documents. The order represents the ranking.", - "items": { - "$ref": "GoogleCloudDiscoveryengineV1alphaSearchResponseSearchResult" - }, - "type": "array" + "siteVerificationInfo": { + "$ref": "GoogleCloudDiscoveryengineV1alphaSiteVerificationInfo", + "description": "Output only. Site ownership and validity verification status.", + "readOnly": true }, - "summary": { - "$ref": "GoogleCloudDiscoveryengineV1alphaSearchResponseSummary", - "description": "A summary as part of the search results. This field is only returned if SearchRequest.ContentSearchSpec.summary_spec is set." + "type": { + "description": "The type of the target site, e.g., whether the site is to be included or excluded.", + "enum": [ + "TYPE_UNSPECIFIED", + "INCLUDE", + "EXCLUDE" + ], + "enumDescriptions": [ + "This value is unused. In this case, server behavior defaults to Type.INCLUDE.", + "Include the target site.", + "Exclude the target site." + ], + "type": "string" }, - "totalSize": { - "description": "The estimated total count of matched items irrespective of pagination. The count of results returned by pagination may be less than the total_size that matches.", - "format": "int32", - "type": "integer" + "updateTime": { + "description": "Output only. The target site's last updated time.", + "format": "google-datetime", + "readOnly": true, + "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaSearchResponseFacet": { - "description": "A facet result.", - "id": "GoogleCloudDiscoveryengineV1alphaSearchResponseFacet", + "GoogleCloudDiscoveryengineV1alphaTargetSiteFailureReason": { + "description": "Site search indexing failure reasons.", + "id": "GoogleCloudDiscoveryengineV1alphaTargetSiteFailureReason", + "properties": { + "quotaFailure": { + "$ref": "GoogleCloudDiscoveryengineV1alphaTargetSiteFailureReasonQuotaFailure", + "description": "Failed due to insufficient quota." + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaTargetSiteFailureReasonQuotaFailure": { + "id": "GoogleCloudDiscoveryengineV1alphaTargetSiteFailureReasonQuotaFailure", + "properties": { + "totalRequiredQuota": { + "description": "This number is an estimation on how much total quota this project needs to successfully complete indexing.", + "format": "int64", + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaTextInput": { + "description": "Defines text input.", + "id": "GoogleCloudDiscoveryengineV1alphaTextInput", + "properties": { + "context": { + "$ref": "GoogleCloudDiscoveryengineV1alphaConversationContext", + "description": "Conversation context of the input." + }, + "input": { + "description": "Text input.", + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaTrainCustomModelMetadata": { + "description": "Metadata related to the progress of the TrainCustomModel operation. This is returned by the google.longrunning.Operation.metadata field.", + "id": "GoogleCloudDiscoveryengineV1alphaTrainCustomModelMetadata", "properties": { - "dynamicFacet": { - "description": "Whether the facet is dynamically generated.", - "type": "boolean" - }, - "key": { - "description": "The key for this facet. E.g., \"colors\" or \"price\". It matches SearchRequest.FacetSpec.FacetKey.key.", + "createTime": { + "description": "Operation create time.", + "format": "google-datetime", "type": "string" }, - "values": { - "description": "The facet values for this field.", - "items": { - "$ref": "GoogleCloudDiscoveryengineV1alphaSearchResponseFacetFacetValue" - }, - "type": "array" + "updateTime": { + "description": "Operation last update time. If the operation is done, this is also the finish time.", + "format": "google-datetime", + "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaSearchResponseFacetFacetValue": { - "description": "A facet value which contains value names and their count.", - "id": "GoogleCloudDiscoveryengineV1alphaSearchResponseFacetFacetValue", + "GoogleCloudDiscoveryengineV1alphaTrainCustomModelRequest": { + "description": "Request message for SearchTuningService.TrainCustomModel method.", + "id": "GoogleCloudDiscoveryengineV1alphaTrainCustomModelRequest", "properties": { - "count": { - "description": "Number of items that have this facet value.", - "format": "int64", - "type": "string" + "errorConfig": { + "$ref": "GoogleCloudDiscoveryengineV1alphaImportErrorConfig", + "description": "The desired location of errors incurred during the data ingestion and training." }, - "interval": { - "$ref": "GoogleCloudDiscoveryengineV1alphaInterval", - "description": "Interval value for a facet, such as 10, 20) for facet \"price\". It matches [SearchRequest.FacetSpec.FacetKey.intervals." + "gcsTrainingInput": { + "$ref": "GoogleCloudDiscoveryengineV1alphaTrainCustomModelRequestGcsTrainingInput", + "description": "Cloud Storage training input." }, - "value": { - "description": "Text value of a facet, such as \"Black\" for facet \"colors\".", + "modelType": { + "description": "Model to be trained. Supported values are: * **search-tuning**: Fine tuning the search system based on data provided.", "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaSearchResponseGeoSearchDebugInfo": { - "description": "Debug information specifically related to forward geocoding issues arising from Geolocation Search.", - "id": "GoogleCloudDiscoveryengineV1alphaSearchResponseGeoSearchDebugInfo", + "GoogleCloudDiscoveryengineV1alphaTrainCustomModelRequestGcsTrainingInput": { + "description": "Cloud Storage training data input.", + "id": "GoogleCloudDiscoveryengineV1alphaTrainCustomModelRequestGcsTrainingInput", "properties": { - "errorMessage": { - "description": "The error produced.", + "corpusDataPath": { + "description": "The Cloud Storage corpus data which could be associated in train data. The data path format is gs:///. A newline delimited jsonl/ndjson file. For search-tuning model, each line should have the _id, title and text. Example: {\"_id\": \"doc1\", title: \"relevant doc\", \"text\": \"relevant text\"}", "type": "string" }, - "originalAddressQuery": { - "description": "The address from which forward geocoding ingestion produced issues.", + "queryDataPath": { + "description": "The gcs query data which could be associated in train data. The data path format is gs:///. A newline delimited jsonl/ndjson file. For search-tuning model, each line should have the _id and text. Example: {\"_id\": \"query1\", \"text\": \"example query\"}", + "type": "string" + }, + "testDataPath": { + "description": "Cloud Storage test data. Same format as train_data_path. If not provided, a random 80/20 train/test split will be performed on train_data_path.", + "type": "string" + }, + "trainDataPath": { + "description": "Cloud Storage training data path whose format should be gs:///. The file should be in tsv format. Each line should have the doc_id and query_id and score (number). For search-tuning model, it should have the query-id corpus-id score as tsv file header. The score should be a number in [0, inf+). The larger the number is, the more relevant the pair is. Example: query-id\\tcorpus-id\\tscore query1\\tdoc1\\t1", "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaSearchResponseGuidedSearchResult": { - "description": "Guided search result. The guided search helps user to refine the search results and narrow down to the real needs from a broaded search results.", - "id": "GoogleCloudDiscoveryengineV1alphaSearchResponseGuidedSearchResult", + "GoogleCloudDiscoveryengineV1alphaTrainCustomModelResponse": { + "description": "Response of the TrainCustomModelRequest. This message is returned by the google.longrunning.Operations.response field.", + "id": "GoogleCloudDiscoveryengineV1alphaTrainCustomModelResponse", "properties": { - "followUpQuestions": { - "description": "Suggested follow-up questions.", - "items": { - "type": "string" - }, - "type": "array" + "errorConfig": { + "$ref": "GoogleCloudDiscoveryengineV1alphaImportErrorConfig", + "description": "Echoes the destination for the complete errors in the request if set." }, - "refinementAttributes": { - "description": "A list of ranked refinement attributes.", + "errorSamples": { + "description": "A sample of errors encountered while processing the data.", "items": { - "$ref": "GoogleCloudDiscoveryengineV1alphaSearchResponseGuidedSearchResultRefinementAttribute" + "$ref": "GoogleRpcStatus" }, "type": "array" + }, + "modelStatus": { + "description": "The trained model status. Possible values are: * **bad-data**: The training data quality is bad. * **no-improvement**: Tuning didn't improve performance. Won't deploy. * **in-progress**: Model training is in progress. * **ready**: The model is ready for serving.", + "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaSearchResponseGuidedSearchResultRefinementAttribute": { - "description": "Useful attribute for search result refinements.", - "id": "GoogleCloudDiscoveryengineV1alphaSearchResponseGuidedSearchResultRefinementAttribute", + "GoogleCloudDiscoveryengineV1alphaTransactionInfo": { + "description": "A transaction represents the entire purchase transaction.", + "id": "GoogleCloudDiscoveryengineV1alphaTransactionInfo", "properties": { - "attributeKey": { - "description": "Attribute key used to refine the results e.g. 'movie_type'.", + "cost": { + "description": "All the costs associated with the products. These can be manufacturing costs, shipping expenses not borne by the end user, or any other costs, such that: * Profit = value - tax - cost", + "format": "float", + "type": "number" + }, + "currency": { + "description": "Required. Currency code. Use three-character ISO-4217 code.", "type": "string" }, - "attributeValue": { - "description": "Attribute value used to refine the results e.g. 'drama'.", + "discountValue": { + "description": "The total discount(s) value applied to this transaction. This figure should be excluded from TransactionInfo.value For example, if a user paid TransactionInfo.value amount, then nominal (pre-discount) value of the transaction is the sum of TransactionInfo.value and TransactionInfo.discount_value This means that profit is calculated the same way, regardless of the discount value, and that TransactionInfo.discount_value can be larger than TransactionInfo.value: * Profit = value - tax - cost", + "format": "float", + "type": "number" + }, + "tax": { + "description": "All the taxes associated with the transaction.", + "format": "float", + "type": "number" + }, + "transactionId": { + "description": "The transaction ID with a length limit of 128 characters.", + "type": "string" + }, + "value": { + "description": "Required. Total non-zero value associated with the transaction. This value may include shipping, tax, or other adjustments to the total value that you want to include.", + "format": "float", + "type": "number" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaTuneEngineMetadata": { + "description": "Metadata associated with a tune operation.", + "id": "GoogleCloudDiscoveryengineV1alphaTuneEngineMetadata", + "properties": { + "engine": { + "description": "Required. The resource name of the engine that this tune applies to. Format: `projects/{project_number}/locations/{location_id}/collections/{collection_id}/engines/{engine_id}`", "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaSearchResponseQueryExpansionInfo": { - "description": "Information describing query expansion including whether expansion has occurred.", - "id": "GoogleCloudDiscoveryengineV1alphaSearchResponseQueryExpansionInfo", + "GoogleCloudDiscoveryengineV1alphaTuneEngineRequest": { + "description": "Request to manually start a tuning process now (instead of waiting for the periodically scheduled tuning to happen).", + "id": "GoogleCloudDiscoveryengineV1alphaTuneEngineRequest", + "properties": {}, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaTuneEngineResponse": { + "description": "Response associated with a tune operation.", + "id": "GoogleCloudDiscoveryengineV1alphaTuneEngineResponse", + "properties": {}, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaUpdateSchemaMetadata": { + "description": "Metadata for UpdateSchema LRO.", + "id": "GoogleCloudDiscoveryengineV1alphaUpdateSchemaMetadata", "properties": { - "expandedQuery": { - "description": "Bool describing whether query expansion has occurred.", - "type": "boolean" + "createTime": { + "description": "Operation create time.", + "format": "google-datetime", + "type": "string" }, - "pinnedResultCount": { - "description": "Number of pinned results. This field will only be set when expansion happens and SearchRequest.QueryExpansionSpec.pin_unexpanded_results is set to true.", - "format": "int64", + "updateTime": { + "description": "Operation last update time. If the operation is done, this is also the finish time.", + "format": "google-datetime", "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaSearchResponseSearchResult": { - "description": "Represents the search results.", - "id": "GoogleCloudDiscoveryengineV1alphaSearchResponseSearchResult", + "GoogleCloudDiscoveryengineV1alphaUpdateTargetSiteMetadata": { + "description": "Metadata related to the progress of the SiteSearchEngineService.UpdateTargetSite operation. This will be returned by the google.longrunning.Operation.metadata field.", + "id": "GoogleCloudDiscoveryengineV1alphaUpdateTargetSiteMetadata", "properties": { - "document": { - "$ref": "GoogleCloudDiscoveryengineV1alphaDocument", - "description": "The document data snippet in the search response. Only fields that are marked as retrievable are populated." - }, - "id": { - "description": "Document.id of the searched Document.", + "createTime": { + "description": "Operation create time.", + "format": "google-datetime", "type": "string" }, - "modelScores": { - "additionalProperties": { - "$ref": "GoogleCloudDiscoveryengineV1alphaDoubleList" - }, - "description": "Google provided available scores.", - "type": "object" + "updateTime": { + "description": "Operation last update time. If the operation is done, this is also the finish time.", + "format": "google-datetime", + "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaSearchResponseSummary": { - "description": "Summary of the top N search result specified by the summary spec.", - "id": "GoogleCloudDiscoveryengineV1alphaSearchResponseSummary", + "GoogleCloudDiscoveryengineV1alphaUserEvent": { + "description": "UserEvent captures all metadata information Discovery Engine API needs to know about how end users interact with customers' website.", + "id": "GoogleCloudDiscoveryengineV1alphaUserEvent", "properties": { - "safetyAttributes": { - "$ref": "GoogleCloudDiscoveryengineV1alphaSearchResponseSummarySafetyAttributes", - "description": "A collection of Safety Attribute categories and their associated confidence scores." + "attributes": { + "additionalProperties": { + "$ref": "GoogleCloudDiscoveryengineV1alphaCustomAttribute" + }, + "description": "Extra user event features to include in the recommendation model. These attributes must NOT contain data that needs to be parsed or processed further, e.g. JSON or other encodings. If you provide custom attributes for ingested user events, also include them in the user events that you associate with prediction requests. Custom attribute formatting must be consistent between imported events and events provided with prediction requests. This lets the Discovery Engine API use those custom attributes when training models and serving predictions, which helps improve recommendation quality. This field needs to pass all below criteria, otherwise an `INVALID_ARGUMENT` error is returned: * The key must be a UTF-8 encoded string with a length limit of 5,000 characters. * For text attributes, at most 400 values are allowed. Empty values are not allowed. Each value must be a UTF-8 encoded string with a length limit of 256 characters. * For number attributes, at most 400 values are allowed. For product recommendations, an example of extra user information is `traffic_channel`, which is how a user arrives at the site. Users can arrive at the site by coming to the site directly, coming through Google search, or in other ways.", + "type": "object" }, - "summarySkippedReasons": { - "description": "Additional summary-skipped reasons. This provides the reason for ignored cases. If nothing is skipped, this field is not set.", + "attributionToken": { + "description": "Token to attribute an API response to user action(s) to trigger the event. Highly recommended for user events that are the result of RecommendationService.Recommend. This field enables accurate attribution of recommendation model performance. The value must be one of: * RecommendResponse.attribution_token for events that are the result of RecommendationService.Recommend. * SearchResponse.attribution_token for events that are the result of SearchService.Search. This token enables us to accurately attribute page view or conversion completion back to the event and the particular predict response containing this clicked/purchased product. If user clicks on product K in the recommendation results, pass RecommendResponse.attribution_token as a URL parameter to product K's page. When recording events on product K's page, log the RecommendResponse.attribution_token to this field.", + "type": "string" + }, + "completionInfo": { + "$ref": "GoogleCloudDiscoveryengineV1alphaCompletionInfo", + "description": "CompletionService.CompleteQuery details related to the event. This field should be set for `search` event when autocomplete function is enabled and the user clicks a suggestion for search." + }, + "directUserRequest": { + "description": "Should set to true if the request is made directly from the end user, in which case the UserEvent.user_info.user_agent can be populated from the HTTP request. This flag should be set only if the API request is made directly from the end user such as a mobile app (and not if a gateway or a server is processing and pushing the user events). This should not be set when using the JavaScript tag in UserEventService.CollectUserEvent.", + "type": "boolean" + }, + "documents": { + "description": "List of Documents associated with this user event. This field is optional except for the following event types: * `view-item` * `add-to-cart` * `purchase` * `media-play` * `media-complete` In a `search` event, this field represents the documents 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 UserEvent.documents is desired.", + "items": { + "$ref": "GoogleCloudDiscoveryengineV1alphaDocumentInfo" + }, + "type": "array" + }, + "eventTime": { + "description": "Only required for UserEventService.ImportUserEvents method. Timestamp of when the user event happened.", + "format": "google-datetime", + "type": "string" + }, + "eventType": { + "description": "Required. User event type. Allowed values are: Generic values: * `search`: Search for Documents. * `view-item`: Detailed page view of a Document. * `view-item-list`: View of a panel or ordered list of Documents. * `view-home-page`: View of the home page. * `view-category-page`: View of a category page, e.g. Home \u003e Men \u003e Jeans Retail-related values: * `add-to-cart`: Add an item(s) to cart, e.g. in Retail online shopping * `purchase`: Purchase an item(s) Media-related values: * `media-play`: Start/resume watching a video, playing a song, etc. * `media-complete`: Finished or stopped midway through a video, song, etc.", + "type": "string" + }, + "filter": { + "description": "The filter syntax consists of an expression language for constructing a predicate from one or more fields of the documents being filtered. One example is for `search` events, the associated SearchRequest may contain a filter expression in SearchRequest.filter conforming to https://google.aip.dev/160#filtering. Similarly, for `view-item-list` events that are generated from a RecommendRequest, this field may be populated directly from RecommendRequest.filter conforming to https://google.aip.dev/160#filtering. The value must be a UTF-8 encoded string with a length limit of 1,000 characters. Otherwise, an `INVALID_ARGUMENT` error is returned.", + "type": "string" + }, + "mediaInfo": { + "$ref": "GoogleCloudDiscoveryengineV1alphaMediaInfo", + "description": "Media-specific info." + }, + "pageInfo": { + "$ref": "GoogleCloudDiscoveryengineV1alphaPageInfo", + "description": "Page metadata such as categories and other critical information for certain event types such as `view-category-page`." + }, + "panel": { + "$ref": "GoogleCloudDiscoveryengineV1alphaPanelInfo", + "description": "Panel metadata associated with this user event." + }, + "promotionIds": { + "description": "The promotion IDs if this is an event associated with promotions. Currently, this field is restricted to at most one ID.", "items": { - "enum": [ - "SUMMARY_SKIPPED_REASON_UNSPECIFIED", - "ADVERSARIAL_QUERY_IGNORED", - "NON_SUMMARY_SEEKING_QUERY_IGNORED", - "OUT_OF_DOMAIN_QUERY_IGNORED", - "POTENTIAL_POLICY_VIOLATION", - "LLM_ADDON_NOT_ENABLED" - ], - "enumDescriptions": [ - "Default value. The summary skipped reason is not specified.", - "The adversarial query ignored case. Only populated when SummarySpec.ignore_adversarial_query is set to `true`.", - "The non-summary seeking query ignored case. Only populated when SummarySpec.ignore_non_summary_seeking_query is set to `true`.", - "The out-of-domain query ignored case. Google skips the summary if there are no high-relevance search results. For example, the data store contains facts about company A but the user query is asking questions about company B.", - "The potential policy violation case. Google skips the summary if there is a potential policy violation detected. This includes content that may be violent or toxic.", - "The LLM addon not enabled case. Google skips the summary if the LLM addon is not enabled." - ], "type": "string" }, "type": "array" }, - "summaryText": { - "description": "The summary content.", - "type": "string" + "searchInfo": { + "$ref": "GoogleCloudDiscoveryengineV1alphaSearchInfo", + "description": "SearchService.Search details related to the event. This field should be set for `search` event." }, - "summaryWithMetadata": { - "$ref": "GoogleCloudDiscoveryengineV1alphaSearchResponseSummarySummaryWithMetadata" - } - }, - "type": "object" - }, - "GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryCitation": { - "description": "Citation info for a segment.", - "id": "GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryCitation", - "properties": { - "endIndex": { - "description": "End of the attributed segment, exclusive.", - "format": "int64", + "sessionId": { + "description": "A unique identifier for tracking a visitor session with a length limit of 128 bytes. A session is an aggregation of an end user behavior in a time span. A general guideline to populate the session_id: 1. If user has no activity for 30 min, a new session_id should be assigned. 2. The session_id should be unique across users, suggest use uuid or add UserEvent.user_pseudo_id as prefix.", "type": "string" }, - "sources": { - "description": "Citation sources for the attributed segment.", + "tagIds": { + "description": "A list of identifiers for the independent experiment groups this user event belongs to. This is used to distinguish between user events associated with different experiment setups on the customer end.", "items": { - "$ref": "GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryCitationSource" + "type": "string" }, "type": "array" }, - "startIndex": { - "description": "Index indicates the start of the segment, measured in bytes/unicode.", - "format": "int64", + "transactionInfo": { + "$ref": "GoogleCloudDiscoveryengineV1alphaTransactionInfo", + "description": "The transaction metadata (if any) associated with this user event." + }, + "userInfo": { + "$ref": "GoogleCloudDiscoveryengineV1alphaUserInfo", + "description": "Information about the end user." + }, + "userPseudoId": { + "description": "Required. A unique identifier for tracking visitors. For example, this could be implemented with an HTTP cookie, which should be able to uniquely identify a visitor on a single device. This unique identifier should not change if the visitor log in/out of the website. Do not set the field to the same fixed ID for different users. This mixes the event history of those users together, which results in degraded model quality. The field must be a UTF-8 encoded string with a length limit of 128 characters. Otherwise, an `INVALID_ARGUMENT` error is returned. The field should not contain PII or user-data. We recommend to use Google Analytics [Client ID](https://developers.google.com/analytics/devguides/collection/analyticsjs/field-reference#clientId) for this field.", "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryCitationMetadata": { - "description": "Citation metadata.", - "id": "GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryCitationMetadata", - "properties": { - "citations": { - "description": "Citations for segments.", - "items": { - "$ref": "GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryCitation" - }, - "type": "array" - } - }, - "type": "object" - }, - "GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryCitationSource": { - "description": "Citation source.", - "id": "GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryCitationSource", + "GoogleCloudDiscoveryengineV1alphaUserInfo": { + "description": "Information of an end user.", + "id": "GoogleCloudDiscoveryengineV1alphaUserInfo", "properties": { - "referenceIndex": { - "description": "Document reference index from SummaryWithMetadata.references. It is 0-indexed and the value will be zero if the reference_index is not set explicitly.", - "format": "int64", + "userAgent": { + "description": "User agent as included in the HTTP header. The field must be a UTF-8 encoded string with a length limit of 1,000 characters. Otherwise, an `INVALID_ARGUMENT` error is returned. This should not be set when using the client side event reporting with GTM or JavaScript tag in UserEventService.CollectUserEvent or if UserEvent.direct_user_request is set.", + "type": "string" + }, + "userId": { + "description": "Highly recommended for logged-in users. Unique identifier for logged-in user, such as a user name. Don't set for anonymous users. Always use a hashed value for this ID. Don't set the field to the same fixed ID for different users. This mixes the event history of those users together, which results in degraded model quality. The field must be a UTF-8 encoded string with a length limit of 128 characters. Otherwise, an `INVALID_ARGUMENT` error is returned.", "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryReference": { - "description": "Document reference.", - "id": "GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryReference", + "GoogleCloudDiscoveryengineV1alphaWidgetCompleteQueryRequest": { + "description": "Request message for WidgetService.WidgetCompleteQuery method.", + "id": "GoogleCloudDiscoveryengineV1alphaWidgetCompleteQueryRequest", "properties": { - "document": { - "description": "Required. Document.name of the document. Full resource name of the referenced document, in the format `projects/*/locations/*/collections/*/dataStores/*/branches/*/documents/*`.", - "type": "string" + "additionalParams": { + "$ref": "GoogleCloudDiscoveryengineV1alphaAdditionalParams", + "description": "Additional params for security and privacy enhancement." }, - "title": { - "description": "Title of the document.", - "type": "string" + "completeQueryRequest": { + "$ref": "GoogleCloudDiscoveryengineV1alphaCompleteQueryRequest", + "description": "Required. The CompleteQuery request to perform auto-complete suggestion query." }, - "uri": { - "description": "Cloud Storage or HTTP uri for the document.", + "configId": { + "description": "Required. The UUID of the WidgetConfig. This field is used to identify the widget configuration, set of models used to make the auto complete query.", "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaSearchResponseSummarySafetyAttributes": { - "description": "Safety Attribute categories and their associated confidence scores.", - "id": "GoogleCloudDiscoveryengineV1alphaSearchResponseSummarySafetyAttributes", + "GoogleCloudDiscoveryengineV1alphaWidgetCompleteQueryResponse": { + "description": "Response message for WidgetService.WidgetCompleteQuery method.", + "id": "GoogleCloudDiscoveryengineV1alphaWidgetCompleteQueryResponse", "properties": { - "categories": { - "description": "The display names of Safety Attribute categories associated with the generated content. Order matches the Scores.", - "items": { - "type": "string" - }, - "type": "array" + "uToken": { + "description": "The token in response.", + "type": "string" }, - "scores": { - "description": "The confidence scores of the each category, higher value means higher confidence. Order matches the Categories.", + "widgetQuerySuggestions": { + "description": "Results of the matched query suggestions in widget. The result list is ordered and the first result is a top suggestion.", "items": { - "format": "float", - "type": "number" + "$ref": "GoogleCloudDiscoveryengineV1alphaWidgetCompleteQueryResponseWidgetQuerySuggestion" }, "type": "array" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaSearchResponseSummarySummaryWithMetadata": { - "description": "Summary with metadata information.", - "id": "GoogleCloudDiscoveryengineV1alphaSearchResponseSummarySummaryWithMetadata", + "GoogleCloudDiscoveryengineV1alphaWidgetCompleteQueryResponseWidgetQuerySuggestion": { + "description": "Suggestions as search queries.", + "id": "GoogleCloudDiscoveryengineV1alphaWidgetCompleteQueryResponseWidgetQuerySuggestion", "properties": { - "citationMetadata": { - "$ref": "GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryCitationMetadata", - "description": "Citation metadata for given summary." - }, - "references": { - "description": "Document References.", - "items": { - "$ref": "GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryReference" - }, - "type": "array" - }, - "summary": { - "description": "Summary text with no citation information.", + "suggestion": { + "description": "The suggestion for the query.", "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaSiteSearchEngine": { - "description": "SiteSearchEngine captures DataStore level site search persisting configurations. It is a singleton value per data store.", - "id": "GoogleCloudDiscoveryengineV1alphaSiteSearchEngine", + "GoogleCloudDiscoveryengineV1alphaWidgetConfig": { + "description": "WidgetConfig captures configs at the Widget level.", + "id": "GoogleCloudDiscoveryengineV1alphaWidgetConfig", "properties": { - "name": { - "description": "The fully qualified resource name of the site search engine. Format: `projects/*/locations/*/dataStores/*/siteSearchEngine`", + "allowPublicAccess": { + "description": "Whether allow no-auth integration with widget. If set true, public access to search or other solutions from widget is allowed without authenication token provided by customer hosted backend server.", + "type": "boolean" + }, + "allowlistedDomains": { + "description": "Allowlisted domains that can load this widget.", + "items": { + "type": "string" + }, + "type": "array" + }, + "configId": { + "description": "Output only. Unique obfuscated identifier of a WidgetConfig.", + "readOnly": true, "type": "string" - } - }, - "type": "object" - }, - "GoogleCloudDiscoveryengineV1alphaSiteVerificationInfo": { - "description": "Verification information for target sites in advanced site search.", - "id": "GoogleCloudDiscoveryengineV1alphaSiteVerificationInfo", - "properties": { - "siteVerificationState": { - "description": "Site verification state indicating the ownership and validity.", + }, + "contentSearchSpec": { + "$ref": "GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpec", + "description": "The content search spec that configs the desired behavior of content search." + }, + "createTime": { + "description": "Output only. Timestamp the WidgetConfig was created.", + "format": "google-datetime", + "readOnly": true, + "type": "string" + }, + "dataStoreType": { + "description": "Output only. The type of the parent data store.", "enum": [ - "SITE_VERIFICATION_STATE_UNSPECIFIED", - "VERIFIED", - "UNVERIFIED", - "EXEMPTED" + "DATA_STORE_TYPE_UNSPECIFIED", + "SITE_SEARCH", + "STRUCTURED", + "UNSTRUCTURED", + "BLENDED" ], "enumDescriptions": [ - "Defaults to VERIFIED.", - "Site ownership verified.", - "Site ownership pending verification or verification failed.", - "Site exempt from verification, e.g. a public website that opens to all." + "Unspecified data store type.", + "The parent data store contains a site search engine.", + "The parent data store contains a search engine for structured data.", + "The parent data store contains a search engine for unstructured data.", + "The parent data store is served for blended search with multiple data stores." ], + "readOnly": true, "type": "string" }, - "verifyTime": { - "description": "Latest site verification time.", - "format": "google-datetime", - "type": "string" - } - }, - "type": "object" - }, - "GoogleCloudDiscoveryengineV1alphaSuggestionDenyListEntry": { - "description": "Suggestion deny list entry identifying the phrase to block from suggestions and the applied operation for the phrase.", - "id": "GoogleCloudDiscoveryengineV1alphaSuggestionDenyListEntry", - "properties": { - "blockPhrase": { - "description": "Required. Phrase to block from suggestions served. Can be maximum 125 characters.", + "displayName": { + "description": "Required. The human readable widget config display name. Used in Discovery UI. This field must be a UTF-8 encoded string with a length limit of 128 characters. Otherwise, an INVALID_ARGUMENT error is returned.", "type": "string" }, - "matchOperator": { - "description": "Required. The match operator to apply for this phrase. Whether to block the exact phrase, or block any suggestions containing this phrase.", + "enableAutocomplete": { + "description": "Whether or not to enable autocomplete.", + "type": "boolean" + }, + "enableConversationalSearch": { + "description": "Whether to allow conversational search (LLM, multi-turn) or not (non-LLM, single-turn).", + "type": "boolean" + }, + "enableQualityFeedback": { + "description": "Turn on or off collecting the search result quality feedback from end users.", + "type": "boolean" + }, + "enableResultScore": { + "description": "Whether to show the result score.", + "type": "boolean" + }, + "enableSafeSearch": { + "description": "Whether to enable safe search.", + "type": "boolean" + }, + "enableSnippetResultSummary": { + "description": "Turn on or off summary for each snippets result.", + "type": "boolean" + }, + "enableSummarization": { + "description": "Turn on or off summarization for the search response.", + "type": "boolean" + }, + "facetField": { + "description": "The configuration and appearance of facets in the end user view.", + "items": { + "$ref": "GoogleCloudDiscoveryengineV1alphaWidgetConfigFacetField" + }, + "type": "array" + }, + "fieldsUiComponentsMap": { + "additionalProperties": { + "$ref": "GoogleCloudDiscoveryengineV1alphaWidgetConfigUIComponentField" + }, + "description": "The key is the UI component. Mock. Currently supported `title`, `thumbnail`, `url`, `custom1`, `custom2`, `custom3`. The value is the name of the field along with its device visibility. The 3 custom fields are optional and can be added or removed. `title`, `thumbnail`, `url` are required UI components that cannot be removed.", + "type": "object" + }, + "industryVertical": { + "description": "Output only. The industry vertical that the WidgetConfig registers. The WidgetConfig industry vertical is based on the associated Engine.", "enum": [ - "MATCH_OPERATOR_UNSPECIFIED", - "EXACT_MATCH", - "CONTAINS" + "INDUSTRY_VERTICAL_UNSPECIFIED", + "GENERIC", + "MEDIA" ], "enumDescriptions": [ - "Default value. Should not be used", - "If the suggestion is an exact match to the block_phrase, then block it.", - "If the suggestion contains the block_phrase, then block it." + "Value used when unset.", + "The generic vertical for documents that are not specific to any industry vertical.", + "The media industry vertical." ], + "readOnly": true, "type": "string" - } - }, - "type": "object" - }, - "GoogleCloudDiscoveryengineV1alphaTargetSite": { - "description": "A target site for the SiteSearchEngine.", - "id": "GoogleCloudDiscoveryengineV1alphaTargetSite", - "properties": { - "exactMatch": { - "description": "Input only. If set to false, a uri_pattern is generated to include all pages whose address contains the provided_uri_pattern. If set to true, an uri_pattern is generated to try to be an exact match of the provided_uri_pattern or just the specific page if the provided_uri_pattern is a specific one. provided_uri_pattern is always normalized to generate the URI pattern to be used by the search engine.", - "type": "boolean" }, - "failureReason": { - "$ref": "GoogleCloudDiscoveryengineV1alphaTargetSiteFailureReason", - "description": "Output only. Failure reason.", - "readOnly": true + "llmEnabled": { + "description": "Output only. Whether LLM is enabled in the corresponding data store.", + "readOnly": true, + "type": "boolean" }, - "generatedUriPattern": { - "description": "Output only. This is system-generated based on the provided_uri_pattern.", + "minimumDataTermAccepted": { + "description": "Output only. Whether the customer accepted data use terms.", "readOnly": true, + "type": "boolean" + }, + "name": { + "description": "Immutable. The full resource name of the widget config. Format: `projects/{project}/locations/{location}/collections/{collection_id}/dataStores/{data_store_id}/widgetConfigs/{widget_config_id}`. This field must be a UTF-8 encoded string with a length limit of 1024 characters.", "type": "string" }, - "indexingStatus": { - "description": "Output only. Indexing status.", + "resultDisplayType": { + "description": "The type of snippet to display in UCS widget. - RESULT_DISPLAY_TYPE_UNSPECIFIED for existing users. - SNIPPET for new non-enterprise search users. - EXTRACTIVE_ANSWER for new enterprise search users.", "enum": [ - "INDEXING_STATUS_UNSPECIFIED", - "PENDING", - "FAILED", - "SUCCEEDED", - "DELETING" + "RESULT_DISPLAY_TYPE_UNSPECIFIED", + "SNIPPET", + "EXTRACTIVE_ANSWER" ], "enumDescriptions": [ - "Defaults to SUCCEEDED.", - "The target site is in the update queue and will be picked up by indexing pipeline.", - "The target site fails to be indexed.", - "The target site has been indexed.", - "The previously indexed target site has been marked to be deleted. This is a transitioning state which will resulted in either: 1. target site deleted if unindexing is successful; 2. state reverts to SUCCEEDED if the unindexing fails." + "Unspecified display type (default to showing snippet).", + "Display results from the snippet field.", + "Display results from extractive answers field." ], - "readOnly": true, - "type": "string" - }, - "name": { - "description": "Output only. The fully qualified resource name of the target site. `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/siteSearchEngine/targetSites/{target_site}` The `target_site_id` is system-generated.", - "readOnly": true, - "type": "string" - }, - "providedUriPattern": { - "description": "Required. Input only. The user provided URI pattern from which the `generated_uri_pattern` is generated.", "type": "string" }, - "siteVerificationInfo": { - "$ref": "GoogleCloudDiscoveryengineV1alphaSiteVerificationInfo", - "description": "Output only. Site ownership and validity verification status.", - "readOnly": true - }, - "type": { - "description": "The type of the target site, e.g. whether the site is to be included or excluded.", + "solutionType": { + "description": "Required. Immutable. Specifies the solution type that this WidgetConfig can be used for.", "enum": [ - "TYPE_UNSPECIFIED", - "INCLUDE", - "EXCLUDE" + "SOLUTION_TYPE_UNSPECIFIED", + "SOLUTION_TYPE_RECOMMENDATION", + "SOLUTION_TYPE_SEARCH", + "SOLUTION_TYPE_CHAT" ], "enumDescriptions": [ - "This value is unused. In this case, server behavior defaults to Type.INCLUDE.", - "Include the target site.", - "Exclude the target site." + "Default value.", + "Used for Recommendations AI.", + "Used for Discovery Search.", + "Used for use cases related to the Generative AI agent." ], "type": "string" }, "updateTime": { - "description": "Output only. The target site's last updated time.", + "description": "Output only. Timestamp the WidgetConfig was updated.", "format": "google-datetime", "readOnly": true, "type": "string" @@ -8295,179 +9395,197 @@ }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaTargetSiteFailureReason": { - "description": "Site search indexing failure reasons.", - "id": "GoogleCloudDiscoveryengineV1alphaTargetSiteFailureReason", + "GoogleCloudDiscoveryengineV1alphaWidgetConfigFacetField": { + "description": "Facet fields that store the mapping of fields to end user widget appearance.", + "id": "GoogleCloudDiscoveryengineV1alphaWidgetConfigFacetField", "properties": { - "quotaFailure": { - "$ref": "GoogleCloudDiscoveryengineV1alphaTargetSiteFailureReasonQuotaFailure", - "description": "Failed due to insufficient quota." + "displayName": { + "description": "Optional. The field name that end users will see.", + "type": "string" + }, + "field": { + "description": "Required. Registered field name. The format is `field.abc`.", + "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaTargetSiteFailureReasonQuotaFailure": { - "id": "GoogleCloudDiscoveryengineV1alphaTargetSiteFailureReasonQuotaFailure", - "properties": {}, - "type": "object" - }, - "GoogleCloudDiscoveryengineV1alphaTextInput": { - "description": "Defines text input.", - "id": "GoogleCloudDiscoveryengineV1alphaTextInput", + "GoogleCloudDiscoveryengineV1alphaWidgetConfigUIComponentField": { + "description": "Facet field that maps to a UI Component.", + "id": "GoogleCloudDiscoveryengineV1alphaWidgetConfigUIComponentField", "properties": { - "context": { - "$ref": "GoogleCloudDiscoveryengineV1alphaConversationContext", - "description": "Conversation context of the input." + "deviceVisibility": { + "description": "The field visibility on different types of devices.", + "items": { + "enum": [ + "DEVICE_VISIBILITY_UNSPECIFIED", + "MOBILE", + "DESKTOP" + ], + "enumDescriptions": [ + "Default value when not specified. Server returns INVALID_ARGUMENT if used in requests.", + "The UI component is visible on Mobile devices.", + "The UI component is visible on Browser-based client." + ], + "type": "string" + }, + "type": "array" }, - "input": { - "description": "Text input.", + "displayTemplate": { + "description": "The template to customize how the field is displayed. An example value would be a string that looks like: \"Price: {value}\".", + "type": "string" + }, + "field": { + "description": "Required. Registered field name. The format is `field.abc`.", "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaTrainCustomModelMetadata": { - "description": "Metadata related to the progress of the TrainCustomModel operation. This is returned by the google.longrunning.Operation.metadata field.", - "id": "GoogleCloudDiscoveryengineV1alphaTrainCustomModelMetadata", + "GoogleCloudDiscoveryengineV1alphaWidgetConverseConversationRequest": { + "description": "Request message for WidgetService.WidgetConverseConversation method.", + "id": "GoogleCloudDiscoveryengineV1alphaWidgetConverseConversationRequest", "properties": { - "createTime": { - "description": "Operation create time.", - "format": "google-datetime", + "additionalParams": { + "$ref": "GoogleCloudDiscoveryengineV1alphaAdditionalParams", + "description": "Additional params for security and privacy enhancement." + }, + "configId": { + "description": "Required. The UUID of the WidgetConfig. This field is used to identify the widget configuration, set of models used to make the user event collection.", "type": "string" }, - "updateTime": { - "description": "Operation last update time. If the operation is done, this is also the finish time.", - "format": "google-datetime", + "conversationId": { + "description": "The id of the Conversation to get. Use \"-\" to activate auto session mode, which automatically creates a new conversation inside a ConverseConversation session.", "type": "string" + }, + "converseConversationRequest": { + "$ref": "GoogleCloudDiscoveryengineV1alphaConverseConversationRequest", + "description": "Required. The ConverseConversationRequest request to perform converse a conversation. The ServingConfig id will be `default_search` by default." } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaTrainCustomModelRequest": { - "description": "Request message for SearchTuningService.TrainCustomModel method.", - "id": "GoogleCloudDiscoveryengineV1alphaTrainCustomModelRequest", + "GoogleCloudDiscoveryengineV1alphaWidgetConverseConversationResponse": { + "description": "Response message for WidgetService.WidgetConverseConversation method.", + "id": "GoogleCloudDiscoveryengineV1alphaWidgetConverseConversationResponse", "properties": { - "errorConfig": { - "$ref": "GoogleCloudDiscoveryengineV1alphaImportErrorConfig", - "description": "The desired location of errors incurred during the data ingestion and training." + "conversationId": { + "description": "The id of the Conversation returned.", + "type": "string" }, - "gcsTrainingInput": { - "$ref": "GoogleCloudDiscoveryengineV1alphaTrainCustomModelRequestGcsTrainingInput", - "description": "Cloud Storage training input." + "converseConversationResponse": { + "$ref": "GoogleCloudDiscoveryengineV1alphaConverseConversationResponse", + "description": "ConverseConversationResponse returned from ConversationalSearchService.ConverseConversation." }, - "modelType": { - "description": "Model to be trained. Supported values are: * **search-tuning**: Fine tuning the search system based on data provided.", + "uToken": { + "description": "The token in response.", "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaTrainCustomModelRequestGcsTrainingInput": { - "description": "Cloud Storage training data input.", - "id": "GoogleCloudDiscoveryengineV1alphaTrainCustomModelRequestGcsTrainingInput", + "GoogleCloudDiscoveryengineV1alphaWidgetSearchRequest": { + "description": "Request message for WidgetService.WidgetSearch method.", + "id": "GoogleCloudDiscoveryengineV1alphaWidgetSearchRequest", "properties": { - "corpusDataPath": { - "description": "The Cloud Storage corpus data which could be associated in train data. The data path format is gs:///. A newline delimited jsonl/ndjson file. For search-tuning model, each line should have the _id, title and text. Example: {\"_id\": \"doc1\", title: \"relevant doc\", \"text\": \"relevant text\"}", - "type": "string" + "additionalParams": { + "$ref": "GoogleCloudDiscoveryengineV1alphaAdditionalParams", + "description": "Additional params for security and privacy enhancement." }, - "queryDataPath": { - "description": "The gcs query data which could be associated in train data. The data path format is gs:///. A newline delimited jsonl/ndjson file. For search-tuning model, each line should have the _id and text. Example: {\"_id\": \"query1\", \"text\": \"example query\"}", + "configId": { + "description": "Required. The UUID of the Search WidgetConfig. This field is used to identify the search widget configuration, set of models used to make the search.", "type": "string" }, - "testDataPath": { - "description": "Cloud Storage test data. Same format as train_data_path. If not provided, a random 80/20 train/test split will be performed on train_data_path.", + "searchRequest": { + "$ref": "GoogleCloudDiscoveryengineV1alphaSearchRequest", + "description": "Required. The search request to perform search." + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaWidgetSearchResponse": { + "description": "Response message for WidgetService.WidgetSearch method.", + "id": "GoogleCloudDiscoveryengineV1alphaWidgetSearchResponse", + "properties": { + "searchResponse": { + "$ref": "GoogleCloudDiscoveryengineV1alphaSearchResponse", + "description": "The search response after performing search." + }, + "uToken": { + "description": "The token in response.", + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1betaBatchCreateTargetSiteMetadata": { + "description": "Metadata related to the progress of the SiteSearchEngineService.BatchCreateTargetSites operation. This will be returned by the google.longrunning.Operation.metadata field.", + "id": "GoogleCloudDiscoveryengineV1betaBatchCreateTargetSiteMetadata", + "properties": { + "createTime": { + "description": "Operation create time.", + "format": "google-datetime", "type": "string" }, - "trainDataPath": { - "description": "Cloud Storage training data path whose format should be gs:///. The file should be in tsv format. Each line should have the doc_id and query_id and score (number). For search-tuning model, it should have the query-id corpus-id score as tsv file header. The score should be a number in [0, inf+). The larger the number is, the more relevant the pair is. Example: query-id\\tcorpus-id\\tscore query1\\tdoc1\\t1", + "updateTime": { + "description": "Operation last update time. If the operation is done, this is also the finish time.", + "format": "google-datetime", "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaTrainCustomModelResponse": { - "description": "Response of the TrainCustomModelRequest. This message is returned by the google.longrunning.Operations.response field.", - "id": "GoogleCloudDiscoveryengineV1alphaTrainCustomModelResponse", + "GoogleCloudDiscoveryengineV1betaBatchCreateTargetSitesResponse": { + "description": "Response message for SiteSearchEngineService.BatchCreateTargetSites method.", + "id": "GoogleCloudDiscoveryengineV1betaBatchCreateTargetSitesResponse", "properties": { - "errorConfig": { - "$ref": "GoogleCloudDiscoveryengineV1alphaImportErrorConfig", - "description": "Echoes the destination for the complete errors in the request if set." - }, - "errorSamples": { - "description": "A sample of errors encountered while processing the data.", + "targetSites": { + "description": "TargetSites created.", "items": { - "$ref": "GoogleRpcStatus" + "$ref": "GoogleCloudDiscoveryengineV1betaTargetSite" }, "type": "array" - }, - "modelStatus": { - "description": "The trained model status. Possible values are: * **bad-data**: The training data quality is bad. * **no-improvement**: Tuning didn't improve performance. Won't deploy. * **in-progress**: Model training is in progress. * **ready**: The model is ready for serving.", - "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaTransactionInfo": { - "description": "A transaction represents the entire purchase transaction.", - "id": "GoogleCloudDiscoveryengineV1alphaTransactionInfo", + "GoogleCloudDiscoveryengineV1betaCreateDataStoreMetadata": { + "description": "Metadata related to the progress of the DataStoreService.CreateDataStore operation. This will be returned by the google.longrunning.Operation.metadata field.", + "id": "GoogleCloudDiscoveryengineV1betaCreateDataStoreMetadata", "properties": { - "cost": { - "description": "All the costs associated with the products. These can be manufacturing costs, shipping expenses not borne by the end user, or any other costs, such that: * Profit = value - tax - cost", - "format": "float", - "type": "number" - }, - "currency": { - "description": "Required. Currency code. Use three-character ISO-4217 code.", + "createTime": { + "description": "Operation create time.", + "format": "google-datetime", "type": "string" }, - "discountValue": { - "description": "The total discount(s) value applied to this transaction. This figure should be excluded from TransactionInfo.value For example, if a user paid TransactionInfo.value amount, then nominal (pre-discount) value of the transaction is the sum of TransactionInfo.value and TransactionInfo.discount_value This means that profit is calculated the same way, regardless of the discount value, and that TransactionInfo.discount_value can be larger than TransactionInfo.value: * Profit = value - tax - cost", - "format": "float", - "type": "number" - }, - "tax": { - "description": "All the taxes associated with the transaction.", - "format": "float", - "type": "number" - }, - "transactionId": { - "description": "The transaction ID with a length limit of 128 characters.", + "updateTime": { + "description": "Operation last update time. If the operation is done, this is also the finish time.", + "format": "google-datetime", "type": "string" - }, - "value": { - "description": "Required. Total non-zero value associated with the transaction. This value may include shipping, tax, or other adjustments to the total value that you want to include.", - "format": "float", - "type": "number" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaTuneEngineMetadata": { - "description": "Metadata associated with a tune operation.", - "id": "GoogleCloudDiscoveryengineV1alphaTuneEngineMetadata", + "GoogleCloudDiscoveryengineV1betaCreateEngineMetadata": { + "description": "Metadata related to the progress of the EngineService.CreateEngine operation. This will be returned by the google.longrunning.Operation.metadata field.", + "id": "GoogleCloudDiscoveryengineV1betaCreateEngineMetadata", "properties": { - "engine": { - "description": "Required. The resource name of the engine that this tune applies to. Format: `projects/{project_number}/locations/{location_id}/collections/{collection_id}/engines/{engine_id}`", + "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" }, - "GoogleCloudDiscoveryengineV1alphaTuneEngineRequest": { - "description": "Request to manually start a tuning process now (instead of waiting for the periodically scheduled tuning to happen).", - "id": "GoogleCloudDiscoveryengineV1alphaTuneEngineRequest", - "properties": {}, - "type": "object" - }, - "GoogleCloudDiscoveryengineV1alphaTuneEngineResponse": { - "description": "Response associated with a tune operation.", - "id": "GoogleCloudDiscoveryengineV1alphaTuneEngineResponse", - "properties": {}, - "type": "object" - }, - "GoogleCloudDiscoveryengineV1alphaUpdateSchemaMetadata": { - "description": "Metadata for UpdateSchema LRO.", - "id": "GoogleCloudDiscoveryengineV1alphaUpdateSchemaMetadata", + "GoogleCloudDiscoveryengineV1betaCreateSchemaMetadata": { + "description": "Metadata for Create Schema LRO.", + "id": "GoogleCloudDiscoveryengineV1betaCreateSchemaMetadata", "properties": { "createTime": { "description": "Operation create time.", @@ -8482,9 +9600,9 @@ }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaUpdateTargetSiteMetadata": { - "description": "Metadata related to the progress of the SiteSearchEngineService.UpdateTargetSite operation. This will be returned by the google.longrunning.Operation.metadata field.", - "id": "GoogleCloudDiscoveryengineV1alphaUpdateTargetSiteMetadata", + "GoogleCloudDiscoveryengineV1betaCreateTargetSiteMetadata": { + "description": "Metadata related to the progress of the SiteSearchEngineService.CreateTargetSite operation. This will be returned by the google.longrunning.Operation.metadata field.", + "id": "GoogleCloudDiscoveryengineV1betaCreateTargetSiteMetadata", "properties": { "createTime": { "description": "Operation create time.", @@ -8499,461 +9617,367 @@ }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaUserEvent": { - "description": "UserEvent captures all metadata information Discovery Engine API needs to know about how end users interact with customers' website.", - "id": "GoogleCloudDiscoveryengineV1alphaUserEvent", + "GoogleCloudDiscoveryengineV1betaDataStore": { + "description": "DataStore captures global settings and configs at the DataStore level.", + "id": "GoogleCloudDiscoveryengineV1betaDataStore", "properties": { - "attributes": { - "additionalProperties": { - "$ref": "GoogleCloudDiscoveryengineV1alphaCustomAttribute" - }, - "description": "Extra user event features to include in the recommendation model. These attributes must NOT contain data that needs to be parsed or processed further, e.g. JSON or other encodings. If you provide custom attributes for ingested user events, also include them in the user events that you associate with prediction requests. Custom attribute formatting must be consistent between imported events and events provided with prediction requests. This lets the Discovery Engine API use those custom attributes when training models and serving predictions, which helps improve recommendation quality. This field needs to pass all below criteria, otherwise an `INVALID_ARGUMENT` error is returned: * The key must be a UTF-8 encoded string with a length limit of 5,000 characters. * For text attributes, at most 400 values are allowed. Empty values are not allowed. Each value must be a UTF-8 encoded string with a length limit of 256 characters. * For number attributes, at most 400 values are allowed. For product recommendations, an example of extra user information is `traffic_channel`, which is how a user arrives at the site. Users can arrive at the site by coming to the site directly, coming through Google search, or in other ways.", - "type": "object" - }, - "attributionToken": { - "description": "Token to attribute an API response to user action(s) to trigger the event. Highly recommended for user events that are the result of RecommendationService.Recommend. This field enables accurate attribution of recommendation model performance. The value must be one of: * RecommendResponse.attribution_token for events that are the result of RecommendationService.Recommend. * SearchResponse.attribution_token for events that are the result of SearchService.Search. This token enables us to accurately attribute page view or conversion completion back to the event and the particular predict response containing this clicked/purchased product. If user clicks on product K in the recommendation results, pass RecommendResponse.attribution_token as a URL parameter to product K's page. When recording events on product K's page, log the RecommendResponse.attribution_token to this field.", + "contentConfig": { + "description": "Immutable. The content config of the data store. If this field is unset, the server behavior defaults to ContentConfig.NO_CONTENT.", + "enum": [ + "CONTENT_CONFIG_UNSPECIFIED", + "NO_CONTENT", + "CONTENT_REQUIRED", + "PUBLIC_WEBSITE" + ], + "enumDescriptions": [ + "Default value.", + "Only contains documents without any Document.content.", + "Only contains documents with Document.content.", + "The data store is used for public website search." + ], "type": "string" }, - "completionInfo": { - "$ref": "GoogleCloudDiscoveryengineV1alphaCompletionInfo", - "description": "CompletionService.CompleteQuery details related to the event. This field should be set for `search` event when autocomplete function is enabled and the user clicks a suggestion for search." - }, - "directUserRequest": { - "description": "Should set to true if the request is made directly from the end user, in which case the UserEvent.user_info.user_agent can be populated from the HTTP request. This flag should be set only if the API request is made directly from the end user such as a mobile app (and not if a gateway or a server is processing and pushing the user events). This should not be set when using the JavaScript tag in UserEventService.CollectUserEvent.", - "type": "boolean" - }, - "documents": { - "description": "List of Documents associated with this user event. This field is optional except for the following event types: * `view-item` * `add-to-cart` * `purchase` * `media-play` * `media-complete` In a `search` event, this field represents the documents 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 UserEvent.documents is desired.", - "items": { - "$ref": "GoogleCloudDiscoveryengineV1alphaDocumentInfo" - }, - "type": "array" - }, - "eventTime": { - "description": "Only required for UserEventService.ImportUserEvents method. Timestamp of when the user event happened.", + "createTime": { + "description": "Output only. Timestamp the DataStore was created at.", "format": "google-datetime", + "readOnly": true, "type": "string" }, - "eventType": { - "description": "Required. User event type. Allowed values are: Generic values: * `search`: Search for Documents. * `view-item`: Detailed page view of a Document. * `view-item-list`: View of a panel or ordered list of Documents. * `view-home-page`: View of the home page. * `view-category-page`: View of a category page, e.g. Home \u003e Men \u003e Jeans Retail-related values: * `add-to-cart`: Add an item(s) to cart, e.g. in Retail online shopping * `purchase`: Purchase an item(s) Media-related values: * `media-play`: Start/resume watching a video, playing a song, etc. * `media-complete`: Finished or stopped midway through a video, song, etc.", + "defaultSchemaId": { + "description": "Output only. The id of the default Schema asscociated to this data store.", + "readOnly": true, "type": "string" }, - "filter": { - "description": "The filter syntax consists of an expression language for constructing a predicate from one or more fields of the documents being filtered. One example is for `search` events, the associated SearchRequest may contain a filter expression in SearchRequest.filter conforming to https://google.aip.dev/160#filtering. Similarly, for `view-item-list` events that are generated from a RecommendRequest, this field may be populated directly from RecommendRequest.filter conforming to https://google.aip.dev/160#filtering. The value must be a UTF-8 encoded string with a length limit of 1,000 characters. Otherwise, an `INVALID_ARGUMENT` error is returned.", + "displayName": { + "description": "Required. The data store display name. This field must be a UTF-8 encoded string with a length limit of 128 characters. Otherwise, an INVALID_ARGUMENT error is returned.", "type": "string" }, - "mediaInfo": { - "$ref": "GoogleCloudDiscoveryengineV1alphaMediaInfo", - "description": "Media-specific info." - }, - "pageInfo": { - "$ref": "GoogleCloudDiscoveryengineV1alphaPageInfo", - "description": "Page metadata such as categories and other critical information for certain event types such as `view-category-page`." - }, - "panel": { - "$ref": "GoogleCloudDiscoveryengineV1alphaPanelInfo", - "description": "Panel metadata associated with this user event." - }, - "promotionIds": { - "description": "The promotion IDs if this is an event associated with promotions. Currently, this field is restricted to at most one ID.", - "items": { - "type": "string" - }, - "type": "array" - }, - "searchInfo": { - "$ref": "GoogleCloudDiscoveryengineV1alphaSearchInfo", - "description": "SearchService.Search details related to the event. This field should be set for `search` event." + "industryVertical": { + "description": "Immutable. The industry vertical that the data store registers.", + "enum": [ + "INDUSTRY_VERTICAL_UNSPECIFIED", + "GENERIC", + "MEDIA" + ], + "enumDescriptions": [ + "Value used when unset.", + "The generic vertical for documents that are not specific to any industry vertical.", + "The media industry vertical." + ], + "type": "string" }, - "sessionId": { - "description": "A unique identifier for tracking a visitor session with a length limit of 128 bytes. A session is an aggregation of an end user behavior in a time span. A general guideline to populate the session_id: 1. If user has no activity for 30 min, a new session_id should be assigned. 2. The session_id should be unique across users, suggest use uuid or add UserEvent.user_pseudo_id as prefix.", + "name": { + "description": "Immutable. The full resource name of the data store. Format: `projects/{project}/locations/{location}/collections/{collection_id}/dataStores/{data_store_id}`. This field must be a UTF-8 encoded string with a length limit of 1024 characters.", "type": "string" }, - "tagIds": { - "description": "A list of identifiers for the independent experiment groups this user event belongs to. This is used to distinguish between user events associated with different experiment setups on the customer end.", + "solutionTypes": { + "description": "The solutions that the data store enrolls. Available solutions for each industry_vertical: * `MEDIA`: `SOLUTION_TYPE_RECOMMENDATION` and `SOLUTION_TYPE_SEARCH`. * `SITE_SEARCH`: `SOLUTION_TYPE_SEARCH` is automatically enrolled. Other solutions cannot be enrolled.", "items": { + "enum": [ + "SOLUTION_TYPE_UNSPECIFIED", + "SOLUTION_TYPE_RECOMMENDATION", + "SOLUTION_TYPE_SEARCH", + "SOLUTION_TYPE_CHAT" + ], + "enumDescriptions": [ + "Default value.", + "Used for Recommendations AI.", + "Used for Discovery Search.", + "Used for use cases related to the Generative AI agent." + ], "type": "string" }, "type": "array" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1betaDeleteDataStoreMetadata": { + "description": "Metadata related to the progress of the DataStoreService.DeleteDataStore operation. This will be returned by the google.longrunning.Operation.metadata field.", + "id": "GoogleCloudDiscoveryengineV1betaDeleteDataStoreMetadata", + "properties": { + "createTime": { + "description": "Operation create time.", + "format": "google-datetime", + "type": "string" }, - "transactionInfo": { - "$ref": "GoogleCloudDiscoveryengineV1alphaTransactionInfo", - "description": "The transaction metadata (if any) associated with this user event." + "updateTime": { + "description": "Operation last update time. If the operation is done, this is also the finish time.", + "format": "google-datetime", + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1betaDeleteEngineMetadata": { + "description": "Metadata related to the progress of the EngineService.DeleteEngine operation. This will be returned by the google.longrunning.Operation.metadata field.", + "id": "GoogleCloudDiscoveryengineV1betaDeleteEngineMetadata", + "properties": { + "createTime": { + "description": "Operation create time.", + "format": "google-datetime", + "type": "string" }, - "userInfo": { - "$ref": "GoogleCloudDiscoveryengineV1alphaUserInfo", - "description": "Information about the end user." + "updateTime": { + "description": "Operation last update time. If the operation is done, this is also the finish time.", + "format": "google-datetime", + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1betaDeleteSchemaMetadata": { + "description": "Metadata for DeleteSchema LRO.", + "id": "GoogleCloudDiscoveryengineV1betaDeleteSchemaMetadata", + "properties": { + "createTime": { + "description": "Operation create time.", + "format": "google-datetime", + "type": "string" }, - "userPseudoId": { - "description": "Required. A unique identifier for tracking visitors. For example, this could be implemented with an HTTP cookie, which should be able to uniquely identify a visitor on a single device. This unique identifier should not change if the visitor log in/out of the website. Do not set the field to the same fixed ID for different users. This mixes the event history of those users together, which results in degraded model quality. The field must be a UTF-8 encoded string with a length limit of 128 characters. Otherwise, an `INVALID_ARGUMENT` error is returned. The field should not contain PII or user-data. We recommend to use Google Analytics [Client ID](https://developers.google.com/analytics/devguides/collection/analyticsjs/field-reference#clientId) for this field.", + "updateTime": { + "description": "Operation last update time. If the operation is done, this is also the finish time.", + "format": "google-datetime", "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaUserInfo": { - "description": "Information of an end user.", - "id": "GoogleCloudDiscoveryengineV1alphaUserInfo", + "GoogleCloudDiscoveryengineV1betaDeleteTargetSiteMetadata": { + "description": "Metadata related to the progress of the SiteSearchEngineService.DeleteTargetSite operation. This will be returned by the google.longrunning.Operation.metadata field.", + "id": "GoogleCloudDiscoveryengineV1betaDeleteTargetSiteMetadata", "properties": { - "userAgent": { - "description": "User agent as included in the HTTP header. The field must be a UTF-8 encoded string with a length limit of 1,000 characters. Otherwise, an `INVALID_ARGUMENT` error is returned. This should not be set when using the client side event reporting with GTM or JavaScript tag in UserEventService.CollectUserEvent or if UserEvent.direct_user_request is set.", + "createTime": { + "description": "Operation create time.", + "format": "google-datetime", "type": "string" }, - "userId": { - "description": "Highly recommended for logged-in users. Unique identifier for logged-in user, such as a user name. Don't set for anonymous users. Always use a hashed value for this ID. Don't set the field to the same fixed ID for different users. This mixes the event history of those users together, which results in degraded model quality. The field must be a UTF-8 encoded string with a length limit of 128 characters. Otherwise, an `INVALID_ARGUMENT` error is returned.", + "updateTime": { + "description": "Operation last update time. If the operation is done, this is also the finish time.", + "format": "google-datetime", "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaWidgetCompleteQueryRequest": { - "description": "Request message for WidgetService.WidgetCompleteQuery method.", - "id": "GoogleCloudDiscoveryengineV1alphaWidgetCompleteQueryRequest", + "GoogleCloudDiscoveryengineV1betaDisableAdvancedSiteSearchMetadata": { + "description": "Metadata related to the progress of the SiteSearchEngineService.DisableAdvancedSiteSearch operation. This will be returned by the google.longrunning.Operation.metadata field.", + "id": "GoogleCloudDiscoveryengineV1betaDisableAdvancedSiteSearchMetadata", "properties": { - "additionalParams": { - "$ref": "GoogleCloudDiscoveryengineV1alphaAdditionalParams", - "description": "Additional params for security and privacy enhancement." - }, - "completeQueryRequest": { - "$ref": "GoogleCloudDiscoveryengineV1alphaCompleteQueryRequest", - "description": "Required. The CompleteQuery request to perform auto-complete suggestion query." + "createTime": { + "description": "Operation create time.", + "format": "google-datetime", + "type": "string" }, - "configId": { - "description": "Required. The UUID of the WidgetConfig. This field is used to identify the widget configuration, set of models used to make the auto complete query.", + "updateTime": { + "description": "Operation last update time. If the operation is done, this is also the finish time.", + "format": "google-datetime", "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaWidgetCompleteQueryResponse": { - "description": "Response message for WidgetService.WidgetCompleteQuery method.", - "id": "GoogleCloudDiscoveryengineV1alphaWidgetCompleteQueryResponse", + "GoogleCloudDiscoveryengineV1betaDisableAdvancedSiteSearchResponse": { + "description": "Response message for SiteSearchEngineService.DisableAdvancedSiteSearch method.", + "id": "GoogleCloudDiscoveryengineV1betaDisableAdvancedSiteSearchResponse", + "properties": {}, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1betaEnableAdvancedSiteSearchMetadata": { + "description": "Metadata related to the progress of the SiteSearchEngineService.EnableAdvancedSiteSearch operation. This will be returned by the google.longrunning.Operation.metadata field.", + "id": "GoogleCloudDiscoveryengineV1betaEnableAdvancedSiteSearchMetadata", "properties": { - "uToken": { - "description": "The token in response.", + "createTime": { + "description": "Operation create time.", + "format": "google-datetime", "type": "string" }, - "widgetQuerySuggestions": { - "description": "Results of the matched query suggestions in widget. The result list is ordered and the first result is a top suggestion.", - "items": { - "$ref": "GoogleCloudDiscoveryengineV1alphaWidgetCompleteQueryResponseWidgetQuerySuggestion" - }, - "type": "array" + "updateTime": { + "description": "Operation last update time. If the operation is done, this is also the finish time.", + "format": "google-datetime", + "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaWidgetCompleteQueryResponseWidgetQuerySuggestion": { - "description": "Suggestions as search queries.", - "id": "GoogleCloudDiscoveryengineV1alphaWidgetCompleteQueryResponseWidgetQuerySuggestion", - "properties": { - "suggestion": { - "description": "The suggestion for the query.", - "type": "string" - } - }, + "GoogleCloudDiscoveryengineV1betaEnableAdvancedSiteSearchResponse": { + "description": "Response message for SiteSearchEngineService.EnableAdvancedSiteSearch method.", + "id": "GoogleCloudDiscoveryengineV1betaEnableAdvancedSiteSearchResponse", + "properties": {}, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaWidgetConfig": { - "description": "WidgetConfig captures configs at the Widget level.", - "id": "GoogleCloudDiscoveryengineV1alphaWidgetConfig", + "GoogleCloudDiscoveryengineV1betaEngine": { + "description": "Metadata that describes the training and serving parameters of an Engine.", + "id": "GoogleCloudDiscoveryengineV1betaEngine", "properties": { - "allowPublicAccess": { - "description": "Whether allow no-auth integration with widget. If set true, public access to search or other solutions from widget is allowed without authenication token provided by customer hosted backend server.", - "type": "boolean" - }, - "allowlistedDomains": { - "description": "Allowlisted domains that can load this widget.", - "items": { - "type": "string" - }, - "type": "array" + "chatEngineConfig": { + "$ref": "GoogleCloudDiscoveryengineV1betaEngineChatEngineConfig", + "description": "Configurations for the Chat Engine. Only applicable if solution_type is SOLUTION_TYPE_CHAT." }, - "configId": { - "description": "Output only. Unique obfuscated identifier of a WidgetConfig.", - "readOnly": true, - "type": "string" + "chatEngineMetadata": { + "$ref": "GoogleCloudDiscoveryengineV1betaEngineChatEngineMetadata", + "description": "Output only. Additional information of the Chat Engine. Only applicable if solution_type is SOLUTION_TYPE_CHAT.", + "readOnly": true }, - "contentSearchSpec": { - "$ref": "GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpec", - "description": "The content search spec that configs the desired behavior of content search." + "commonConfig": { + "$ref": "GoogleCloudDiscoveryengineV1betaEngineCommonConfig", + "description": "Common config spec that specifies the metadata of the engine." }, "createTime": { - "description": "Output only. Timestamp the WidgetConfig was created.", + "description": "Output only. Timestamp the Recommendation Engine was created at.", "format": "google-datetime", "readOnly": true, "type": "string" }, - "dataStoreType": { - "description": "Output only. The type of the parent data store.", - "enum": [ - "DATA_STORE_TYPE_UNSPECIFIED", - "SITE_SEARCH", - "STRUCTURED", - "UNSTRUCTURED", - "BLENDED" - ], - "enumDescriptions": [ - "Unspecified data store type.", - "The parent data store contains a site search engine.", - "The parent data store contains a search engine for structured data.", - "The parent data store contains a search engine for unstructured data.", - "The parent data store is served for blended search with multiple data stores." - ], - "readOnly": true, - "type": "string" - }, - "displayName": { - "description": "Required. The human readable widget config display name. Used in Discovery UI. This field must be a UTF-8 encoded string with a length limit of 128 characters. Otherwise, an INVALID_ARGUMENT error is returned.", - "type": "string" - }, - "enableAutocomplete": { - "description": "Whether or not to enable autocomplete.", - "type": "boolean" - }, - "enableConversationalSearch": { - "description": "Whether to allow conversational search (LLM, multi-turn) or not (non-LLM, single-turn).", - "type": "boolean" - }, - "enableQualityFeedback": { - "description": "Turn on or off collecting the search result quality feedback from end users.", - "type": "boolean" - }, - "enableResultScore": { - "description": "Whether to show the result score.", - "type": "boolean" - }, - "enableSafeSearch": { - "description": "Whether to enable safe search.", - "type": "boolean" - }, - "enableSnippetResultSummary": { - "description": "Turn on or off summary for each snippets result.", - "type": "boolean" - }, - "enableSummarization": { - "description": "Turn on or off summarization for the search response.", - "type": "boolean" - }, - "facetField": { - "description": "The configuration and appearance of facets in the end user view.", + "dataStoreIds": { + "description": "The data stores associated with this engine. For SOLUTION_TYPE_SEARCH and SOLUTION_TYPE_RECOMMENDATION type of engines, they can only associate with at most one data store. If solution_type is SOLUTION_TYPE_CHAT, multiple DataStores in the same Collection can be associated here. Note that when used in CreateEngineRequest, one DataStore id must be provided as the system will use it for necessary initializations.", "items": { - "$ref": "GoogleCloudDiscoveryengineV1alphaWidgetConfigFacetField" + "type": "string" }, "type": "array" }, - "fieldsUiComponentsMap": { - "additionalProperties": { - "$ref": "GoogleCloudDiscoveryengineV1alphaWidgetConfigUIComponentField" - }, - "description": "The key is the UI component. Mock. Currently supported `title`, `thumbnail`, `url`, `custom1`, `custom2`, `custom3`. The value is the name of the field along with its device visibility. The 3 custom fields are optional and can be added or removed. `title`, `thumbnail`, `url` are required UI components that cannot be removed.", - "type": "object" - }, - "llmEnabled": { - "description": "Output only. Whether LLM is enabled in the corresponding data store.", - "readOnly": true, - "type": "boolean" - }, - "minimumDataTermAccepted": { - "description": "Output only. Whether the customer accepted data use terms.", - "readOnly": true, - "type": "boolean" - }, - "name": { - "description": "Immutable. The full resource name of the widget config. Format: `projects/{project}/locations/{location}/collections/{collection_id}/dataStores/{data_store_id}/widgetConfigs/{widget_config_id}`. This field must be a UTF-8 encoded string with a length limit of 1024 characters.", + "displayName": { + "description": "Required. The display name of the engine. Should be human readable. UTF-8 encoded string with limit of 1024 characters.", "type": "string" }, - "resultDisplayType": { - "description": "The type of snippet to display in UCS widget. - RESULT_DISPLAY_TYPE_UNSPECIFIED for existing users. - SNIPPET for new non-enterprise search users. - EXTRACTIVE_ANSWER for new enterprise search users.", + "industryVertical": { + "description": "The industry vertical that the engine registers. The restriction of the Engine industry vertical is based on DataStore: If unspecified, default to `GENERIC`. Vertical on Engine has to match vertical of the DataStore liniked to the engine.", "enum": [ - "RESULT_DISPLAY_TYPE_UNSPECIFIED", - "SNIPPET", - "EXTRACTIVE_ANSWER" + "INDUSTRY_VERTICAL_UNSPECIFIED", + "GENERIC", + "MEDIA" ], "enumDescriptions": [ - "Unspecified display type (default to showing snippet).", - "Display results from the snippet field.", - "Display results from extractive answers field." + "Value used when unset.", + "The generic vertical for documents that are not specific to any industry vertical.", + "The media industry vertical." ], "type": "string" }, + "name": { + "description": "Immutable. The fully qualified resource name of the engine. This field must be a UTF-8 encoded string with a length limit of 1024 characters. Format: `projects/{project_number}/locations/{location}/collections/{collection}/engines/{engine}` engine should be 1-63 characters, and valid characters are /a-z0-9*/. Otherwise, an INVALID_ARGUMENT error is returned.", + "type": "string" + }, + "searchEngineConfig": { + "$ref": "GoogleCloudDiscoveryengineV1betaEngineSearchEngineConfig", + "description": "Configurations for the Search Engine. Only applicable if solution_type is SOLUTION_TYPE_SEARCH." + }, "solutionType": { - "description": "Required. Immutable. Specifies the solution type that this WidgetConfig can be used for.", + "description": "Required. The solutions of the engine.", "enum": [ "SOLUTION_TYPE_UNSPECIFIED", "SOLUTION_TYPE_RECOMMENDATION", "SOLUTION_TYPE_SEARCH", "SOLUTION_TYPE_CHAT" ], - "enumDescriptions": [ - "Default value.", - "Used for Recommendations AI.", - "Used for Discovery Search.", - "Used for use cases related to the Generative AI agent." - ], - "type": "string" - }, - "updateTime": { - "description": "Output only. Timestamp the WidgetConfig was updated.", - "format": "google-datetime", - "readOnly": true, - "type": "string" - } - }, - "type": "object" - }, - "GoogleCloudDiscoveryengineV1alphaWidgetConfigFacetField": { - "description": "Facet fields that store the mapping of fields to end user widget appearance.", - "id": "GoogleCloudDiscoveryengineV1alphaWidgetConfigFacetField", - "properties": { - "displayName": { - "description": "Optional. The field name that end users will see.", - "type": "string" - }, - "field": { - "description": "Required. Registered field name. The format is `field.abc`.", - "type": "string" - } - }, - "type": "object" - }, - "GoogleCloudDiscoveryengineV1alphaWidgetConfigUIComponentField": { - "description": "Facet field that maps to a UI Component.", - "id": "GoogleCloudDiscoveryengineV1alphaWidgetConfigUIComponentField", - "properties": { - "deviceVisibility": { - "description": "The field visibility on different types of devices.", - "items": { - "enum": [ - "DEVICE_VISIBILITY_UNSPECIFIED", - "MOBILE", - "DESKTOP" - ], - "enumDescriptions": [ - "Default value when not specified. Server returns INVALID_ARGUMENT if used in requests.", - "The UI component is visible on Mobile devices.", - "The UI component is visible on Browser-based client." - ], - "type": "string" - }, - "type": "array" - }, - "displayTemplate": { - "description": "The template to customize how the field is displayed. An example value would be a string that looks like: \"Price: {value}\".", + "enumDescriptions": [ + "Default value.", + "Used for Recommendations AI.", + "Used for Discovery Search.", + "Used for use cases related to the Generative AI agent." + ], "type": "string" }, - "field": { - "description": "Required. Registered field name. The format is `field.abc`.", + "updateTime": { + "description": "Output only. Timestamp the Recommendation Engine was last updated.", + "format": "google-datetime", + "readOnly": true, "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaWidgetConverseConversationRequest": { - "description": "Request message for WidgetService.WidgetConverseConversation method.", - "id": "GoogleCloudDiscoveryengineV1alphaWidgetConverseConversationRequest", + "GoogleCloudDiscoveryengineV1betaEngineChatEngineConfig": { + "description": "Configurations for a Chat Engine.", + "id": "GoogleCloudDiscoveryengineV1betaEngineChatEngineConfig", "properties": { - "additionalParams": { - "$ref": "GoogleCloudDiscoveryengineV1alphaAdditionalParams", - "description": "Additional params for security and privacy enhancement." - }, - "configId": { - "description": "Required. The UUID of the WidgetConfig. This field is used to identify the widget configuration, set of models used to make the user event collection.", - "type": "string" + "agentCreationConfig": { + "$ref": "GoogleCloudDiscoveryengineV1betaEngineChatEngineConfigAgentCreationConfig", + "description": "The configurationt generate the Dialogflow agent that is associated to this Engine. Note that these configurations are one-time consumed by and passed to Dialogflow service. It means they cannot be retrieved using EngineService.GetEngine or EngineService.ListEngines API after engine creation." }, - "conversationId": { - "description": "The id of the Conversation to get. Use \"-\" to activate auto session mode, which automatically creates a new conversation inside a ConverseConversation session.", + "dialogflowAgentToLink": { + "description": "The resource name of an exist Dialogflow agent to link to this Chat Engine. Customers can either provide `agent_creation_config` to create agent or provide an agent name that links the agent with the Chat engine. Format: `projects//locations//agents/`. Note that the `dialogflow_agent_to_link` are one-time consumed by and passed to Dialogflow service. It means they cannot be retrieved using EngineService.GetEngine or EngineService.ListEngines API after engine creation. Please use ChatEngineMetadata.dialogflow_agent for actual agent association after Engine is created.", "type": "string" - }, - "converseConversationRequest": { - "$ref": "GoogleCloudDiscoveryengineV1alphaConverseConversationRequest", - "description": "Required. The ConverseConversationRequest request to perform converse a conversation. The ServingConfig id will be `default_search` by default." } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaWidgetConverseConversationResponse": { - "description": "Response message for WidgetService.WidgetConverseConversation method.", - "id": "GoogleCloudDiscoveryengineV1alphaWidgetConverseConversationResponse", + "GoogleCloudDiscoveryengineV1betaEngineChatEngineConfigAgentCreationConfig": { + "description": "Configurations for generating a Dialogflow agent. Note that these configurations are one-time consumed by and passed to Dialogflow service. It means they cannot be retrieved using EngineService.GetEngine or EngineService.ListEngines API after engine creation.", + "id": "GoogleCloudDiscoveryengineV1betaEngineChatEngineConfigAgentCreationConfig", "properties": { - "conversationId": { - "description": "The id of the Conversation returned.", + "business": { + "description": "Name of the company, organization or other entity that the agent represents. Used for knowledge connector LLM prompt and for knowledge search.", "type": "string" }, - "converseConversationResponse": { - "$ref": "GoogleCloudDiscoveryengineV1alphaConverseConversationResponse", - "description": "ConverseConversationResponse returned from ConversationalSearchService.ConverseConversation." - }, - "uToken": { - "description": "The token in response.", + "defaultLanguageCode": { + "description": "Required. The default language of the agent as a language tag. See [Language Support](https://cloud.google.com/dialogflow/docs/reference/language) for a list of the currently supported language codes.", "type": "string" - } - }, - "type": "object" - }, - "GoogleCloudDiscoveryengineV1alphaWidgetSearchRequest": { - "description": "Request message for WidgetService.WidgetSearch method.", - "id": "GoogleCloudDiscoveryengineV1alphaWidgetSearchRequest", - "properties": { - "additionalParams": { - "$ref": "GoogleCloudDiscoveryengineV1alphaAdditionalParams", - "description": "Additional params for security and privacy enhancement." }, - "configId": { - "description": "Required. The UUID of the Search WidgetConfig. This field is used to identify the search widget configuration, set of models used to make the search.", + "location": { + "description": "Agent location for Agent creation, supported values: global/us/eu. If not provided, us Engine will create Agent using us-central-1 by default; eu Engine will create Agent using eu-west-1 by default.", "type": "string" }, - "searchRequest": { - "$ref": "GoogleCloudDiscoveryengineV1alphaSearchRequest", - "description": "Required. The search request to perform search." + "timeZone": { + "description": "Required. The time zone of the agent from the [time zone database](https://www.iana.org/time-zones), e.g., America/New_York, Europe/Paris.", + "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaWidgetSearchResponse": { - "description": "Response message for WidgetService.WidgetSearch method.", - "id": "GoogleCloudDiscoveryengineV1alphaWidgetSearchResponse", + "GoogleCloudDiscoveryengineV1betaEngineChatEngineMetadata": { + "description": "Additional information of a Chat Engine. Fields in this message are output only.", + "id": "GoogleCloudDiscoveryengineV1betaEngineChatEngineMetadata", "properties": { - "searchResponse": { - "$ref": "GoogleCloudDiscoveryengineV1alphaSearchResponse", - "description": "The search response after performing search." - }, - "uToken": { - "description": "The token in response.", + "dialogflowAgent": { + "description": "The resource name of a Dialogflow agent, that this Chat Engine refers to. Format: `projects//locations//agents/`.", "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1betaCreateSchemaMetadata": { - "description": "Metadata for Create Schema LRO.", - "id": "GoogleCloudDiscoveryengineV1betaCreateSchemaMetadata", + "GoogleCloudDiscoveryengineV1betaEngineCommonConfig": { + "description": "Common configurations for an Engine.", + "id": "GoogleCloudDiscoveryengineV1betaEngineCommonConfig", "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", + "companyName": { + "description": "Immutable. The name of the company, business or entity that is associated with the engine. Setting this may help improve LLM related features.", "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1betaDeleteSchemaMetadata": { - "description": "Metadata for DeleteSchema LRO.", - "id": "GoogleCloudDiscoveryengineV1betaDeleteSchemaMetadata", + "GoogleCloudDiscoveryengineV1betaEngineSearchEngineConfig": { + "description": "Configurations for a Search Engine.", + "id": "GoogleCloudDiscoveryengineV1betaEngineSearchEngineConfig", "properties": { - "createTime": { - "description": "Operation create time.", - "format": "google-datetime", - "type": "string" + "searchAddOns": { + "description": "The add-on that this search engine enables.", + "items": { + "enum": [ + "SEARCH_ADD_ON_UNSPECIFIED", + "SEARCH_ADD_ON_LLM" + ], + "enumDescriptions": [ + "Default value when the enum is unspecified. This is invalid to use.", + "Large language model add-on." + ], + "type": "string" + }, + "type": "array" }, - "updateTime": { - "description": "Operation last update time. If the operation is done, this is also the finish time.", - "format": "google-datetime", + "searchTier": { + "description": "The search feature tier of this engine. Different tiers might have different pricing. To learn more, please check the pricing documentation. Defaults to SearchTier.SEARCH_TIER_STANDARD if not specified.", + "enum": [ + "SEARCH_TIER_UNSPECIFIED", + "SEARCH_TIER_STANDARD", + "SEARCH_TIER_ENTERPRISE" + ], + "enumDescriptions": [ + "Default value when the enum is unspecified. This is invalid to use.", + "Standard tier.", + "Enterprise tier." + ], "type": "string" } }, @@ -9216,6 +10240,130 @@ }, "type": "object" }, + "GoogleCloudDiscoveryengineV1betaSiteVerificationInfo": { + "description": "Verification information for target sites in advanced site search.", + "id": "GoogleCloudDiscoveryengineV1betaSiteVerificationInfo", + "properties": { + "siteVerificationState": { + "description": "Site verification state indicating the ownership and validity.", + "enum": [ + "SITE_VERIFICATION_STATE_UNSPECIFIED", + "VERIFIED", + "UNVERIFIED", + "EXEMPTED" + ], + "enumDescriptions": [ + "Defaults to VERIFIED.", + "Site ownership verified.", + "Site ownership pending verification or verification failed.", + "Site exempt from verification, e.g., a public website that opens to all." + ], + "type": "string" + }, + "verifyTime": { + "description": "Latest site verification time.", + "format": "google-datetime", + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1betaTargetSite": { + "description": "A target site for the SiteSearchEngine.", + "id": "GoogleCloudDiscoveryengineV1betaTargetSite", + "properties": { + "exactMatch": { + "description": "Input only. If set to false, a uri_pattern is generated to include all pages whose address contains the provided_uri_pattern. If set to true, an uri_pattern is generated to try to be an exact match of the provided_uri_pattern or just the specific page if the provided_uri_pattern is a specific one. provided_uri_pattern is always normalized to generate the URI pattern to be used by the search engine.", + "type": "boolean" + }, + "failureReason": { + "$ref": "GoogleCloudDiscoveryengineV1betaTargetSiteFailureReason", + "description": "Output only. Failure reason.", + "readOnly": true + }, + "generatedUriPattern": { + "description": "Output only. This is system-generated based on the provided_uri_pattern.", + "readOnly": true, + "type": "string" + }, + "indexingStatus": { + "description": "Output only. Indexing status.", + "enum": [ + "INDEXING_STATUS_UNSPECIFIED", + "PENDING", + "FAILED", + "SUCCEEDED", + "DELETING" + ], + "enumDescriptions": [ + "Defaults to SUCCEEDED.", + "The target site is in the update queue and will be picked up by indexing pipeline.", + "The target site fails to be indexed.", + "The target site has been indexed.", + "The previously indexed target site has been marked to be deleted. This is a transitioning state which will resulted in either: 1. target site deleted if unindexing is successful; 2. state reverts to SUCCEEDED if the unindexing fails." + ], + "readOnly": true, + "type": "string" + }, + "name": { + "description": "Output only. The fully qualified resource name of the target site. `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/siteSearchEngine/targetSites/{target_site}` The `target_site_id` is system-generated.", + "readOnly": true, + "type": "string" + }, + "providedUriPattern": { + "description": "Required. Input only. The user provided URI pattern from which the `generated_uri_pattern` is generated.", + "type": "string" + }, + "siteVerificationInfo": { + "$ref": "GoogleCloudDiscoveryengineV1betaSiteVerificationInfo", + "description": "Output only. Site ownership and validity verification status.", + "readOnly": true + }, + "type": { + "description": "The type of the target site, e.g., whether the site is to be included or excluded.", + "enum": [ + "TYPE_UNSPECIFIED", + "INCLUDE", + "EXCLUDE" + ], + "enumDescriptions": [ + "This value is unused. In this case, server behavior defaults to Type.INCLUDE.", + "Include the target site.", + "Exclude the target site." + ], + "type": "string" + }, + "updateTime": { + "description": "Output only. The target site's last updated time.", + "format": "google-datetime", + "readOnly": true, + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1betaTargetSiteFailureReason": { + "description": "Site search indexing failure reasons.", + "id": "GoogleCloudDiscoveryengineV1betaTargetSiteFailureReason", + "properties": { + "quotaFailure": { + "$ref": "GoogleCloudDiscoveryengineV1betaTargetSiteFailureReasonQuotaFailure", + "description": "Failed due to insufficient quota." + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1betaTargetSiteFailureReasonQuotaFailure": { + "id": "GoogleCloudDiscoveryengineV1betaTargetSiteFailureReasonQuotaFailure", + "properties": { + "totalRequiredQuota": { + "description": "This number is an estimation on how much total quota this project needs to successfully complete indexing.", + "format": "int64", + "type": "string" + } + }, + "type": "object" + }, "GoogleCloudDiscoveryengineV1betaUpdateSchemaMetadata": { "description": "Metadata for UpdateSchema LRO.", "id": "GoogleCloudDiscoveryengineV1betaUpdateSchemaMetadata", @@ -9233,6 +10381,23 @@ }, "type": "object" }, + "GoogleCloudDiscoveryengineV1betaUpdateTargetSiteMetadata": { + "description": "Metadata related to the progress of the SiteSearchEngineService.UpdateTargetSite operation. This will be returned by the google.longrunning.Operation.metadata field.", + "id": "GoogleCloudDiscoveryengineV1betaUpdateTargetSiteMetadata", + "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" + }, "GoogleLongrunningListOperationsResponse": { "description": "The response message for Operations.ListOperations.", "id": "GoogleLongrunningListOperationsResponse", diff --git a/discoveryengine/v1alpha/discoveryengine-gen.go b/discoveryengine/v1alpha/discoveryengine-gen.go index 0b2d2a70d1f..a58a536feab 100644 --- a/discoveryengine/v1alpha/discoveryengine-gen.go +++ b/discoveryengine/v1alpha/discoveryengine-gen.go @@ -978,9 +978,11 @@ func (s *GoogleCloudDiscoveryengineLoggingSourceLocation) MarshalJSON() ([]byte, return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1CreateSchemaMetadata: Metadata for Create -// Schema LRO. -type GoogleCloudDiscoveryengineV1CreateSchemaMetadata struct { +// GoogleCloudDiscoveryengineV1BatchCreateTargetSiteMetadata: Metadata +// related to the progress of the +// SiteSearchEngineService.BatchCreateTargetSites operation. This will +// be returned by the google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1BatchCreateTargetSiteMetadata struct { // CreateTime: Operation create time. CreateTime string `json:"createTime,omitempty"` @@ -1005,23 +1007,19 @@ type GoogleCloudDiscoveryengineV1CreateSchemaMetadata struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1CreateSchemaMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1CreateSchemaMetadata +func (s *GoogleCloudDiscoveryengineV1BatchCreateTargetSiteMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1BatchCreateTargetSiteMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1DeleteSchemaMetadata: Metadata for -// DeleteSchema LRO. -type GoogleCloudDiscoveryengineV1DeleteSchemaMetadata 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"` +// GoogleCloudDiscoveryengineV1BatchCreateTargetSitesResponse: Response +// message for SiteSearchEngineService.BatchCreateTargetSites method. +type GoogleCloudDiscoveryengineV1BatchCreateTargetSitesResponse struct { + // TargetSites: TargetSites created. + TargetSites []*GoogleCloudDiscoveryengineV1TargetSite `json:"targetSites,omitempty"` - // ForceSendFields is a list of field names (e.g. "CreateTime") to + // ForceSendFields is a list of field names (e.g. "TargetSites") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -1029,35 +1027,29 @@ type GoogleCloudDiscoveryengineV1DeleteSchemaMetadata struct { // This may be used to include empty fields in Patch requests. 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. However, any field with an - // empty value appearing in NullFields will be sent to the server as + // NullFields is a list of field names (e.g. "TargetSites") to include + // in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. However, any field with + // an empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1DeleteSchemaMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1DeleteSchemaMetadata +func (s *GoogleCloudDiscoveryengineV1BatchCreateTargetSitesResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1BatchCreateTargetSitesResponse raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1ImportDocumentsMetadata: Metadata related -// to the progress of the ImportDocuments operation. This is returned by -// the google.longrunning.Operation.metadata field. -type GoogleCloudDiscoveryengineV1ImportDocumentsMetadata struct { +// GoogleCloudDiscoveryengineV1CreateDataStoreMetadata: Metadata related +// to the progress of the DataStoreService.CreateDataStore operation. +// This will be returned by the google.longrunning.Operation.metadata +// field. +type GoogleCloudDiscoveryengineV1CreateDataStoreMetadata struct { // CreateTime: Operation create time. CreateTime string `json:"createTime,omitempty"` - // FailureCount: Count of entries that encountered errors while - // processing. - FailureCount int64 `json:"failureCount,omitempty,string"` - - // SuccessCount: Count of entries that were processed successfully. - SuccessCount int64 `json:"successCount,omitempty,string"` - // UpdateTime: Operation last update time. If the operation is done, // this is also the finish time. UpdateTime string `json:"updateTime,omitempty"` @@ -1079,27 +1071,24 @@ type GoogleCloudDiscoveryengineV1ImportDocumentsMetadata struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1ImportDocumentsMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1ImportDocumentsMetadata +func (s *GoogleCloudDiscoveryengineV1CreateDataStoreMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1CreateDataStoreMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1ImportDocumentsResponse: Response of the -// ImportDocumentsRequest. If the long running operation is done, then -// this message is returned by the -// google.longrunning.Operations.response field if the operation was -// successful. -type GoogleCloudDiscoveryengineV1ImportDocumentsResponse struct { - // ErrorConfig: Echoes the destination for the complete errors in the - // request if set. - ErrorConfig *GoogleCloudDiscoveryengineV1ImportErrorConfig `json:"errorConfig,omitempty"` +// GoogleCloudDiscoveryengineV1CreateEngineMetadata: Metadata related to +// the progress of the EngineService.CreateEngine operation. This will +// be returned by the google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1CreateEngineMetadata struct { + // CreateTime: Operation create time. + CreateTime string `json:"createTime,omitempty"` - // ErrorSamples: A sample of errors encountered while processing the - // request. - ErrorSamples []*GoogleRpcStatus `json:"errorSamples,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. "ErrorConfig") to + // 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. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -1107,31 +1096,32 @@ type GoogleCloudDiscoveryengineV1ImportDocumentsResponse struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "ErrorConfig") to include - // in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. However, any field with - // an empty value appearing in NullFields will be sent to the server as + // 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. However, any field with an + // empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1ImportDocumentsResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1ImportDocumentsResponse +func (s *GoogleCloudDiscoveryengineV1CreateEngineMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1CreateEngineMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1ImportErrorConfig: Configuration of -// destination for Import related errors. -type GoogleCloudDiscoveryengineV1ImportErrorConfig struct { - // GcsPrefix: Cloud Storage prefix for import errors. This must be an - // empty, existing Cloud Storage directory. Import errors are written to - // sharded files in this directory, one per line, as a JSON-encoded - // `google.rpc.Status` message. - GcsPrefix string `json:"gcsPrefix,omitempty"` +// GoogleCloudDiscoveryengineV1CreateSchemaMetadata: Metadata for Create +// Schema LRO. +type GoogleCloudDiscoveryengineV1CreateSchemaMetadata struct { + // CreateTime: Operation create time. + CreateTime string `json:"createTime,omitempty"` - // ForceSendFields is a list of field names (e.g. "GcsPrefix") to + // 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. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -1139,7 +1129,7 @@ type GoogleCloudDiscoveryengineV1ImportErrorConfig struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "GcsPrefix") to include in + // 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. However, any field with an // empty value appearing in NullFields will be sent to the server as @@ -1148,17 +1138,17 @@ type GoogleCloudDiscoveryengineV1ImportErrorConfig struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1ImportErrorConfig) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1ImportErrorConfig +func (s *GoogleCloudDiscoveryengineV1CreateSchemaMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1CreateSchemaMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1ImportSuggestionDenyListEntriesMetadata: -// Metadata related to the progress of the -// ImportSuggestionDenyListEntries operation. This is returned by the -// google.longrunning.Operation.metadata field. -type GoogleCloudDiscoveryengineV1ImportSuggestionDenyListEntriesMetadata struct { +// GoogleCloudDiscoveryengineV1CreateTargetSiteMetadata: Metadata +// related to the progress of the +// SiteSearchEngineService.CreateTargetSite operation. This will be +// returned by the google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1CreateTargetSiteMetadata struct { // CreateTime: Operation create time. CreateTime string `json:"createTime,omitempty"` @@ -1183,29 +1173,71 @@ type GoogleCloudDiscoveryengineV1ImportSuggestionDenyListEntriesMetadata struct NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1ImportSuggestionDenyListEntriesMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1ImportSuggestionDenyListEntriesMetadata +func (s *GoogleCloudDiscoveryengineV1CreateTargetSiteMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1CreateTargetSiteMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1ImportSuggestionDenyListEntriesResponse: -// Response message for -// CompletionService.ImportSuggestionDenyListEntries method. -type GoogleCloudDiscoveryengineV1ImportSuggestionDenyListEntriesResponse struct { - // ErrorSamples: A sample of errors encountered while processing the - // request. - ErrorSamples []*GoogleRpcStatus `json:"errorSamples,omitempty"` +// GoogleCloudDiscoveryengineV1DataStore: DataStore captures global +// settings and configs at the DataStore level. +type GoogleCloudDiscoveryengineV1DataStore struct { + // ContentConfig: Immutable. The content config of the data store. If + // this field is unset, the server behavior defaults to + // ContentConfig.NO_CONTENT. + // + // Possible values: + // "CONTENT_CONFIG_UNSPECIFIED" - Default value. + // "NO_CONTENT" - Only contains documents without any + // Document.content. + // "CONTENT_REQUIRED" - Only contains documents with Document.content. + // "PUBLIC_WEBSITE" - The data store is used for public website + // search. + ContentConfig string `json:"contentConfig,omitempty"` - // FailedEntriesCount: Count of deny list entries that failed to be - // imported. - FailedEntriesCount int64 `json:"failedEntriesCount,omitempty,string"` + // CreateTime: Output only. Timestamp the DataStore was created at. + CreateTime string `json:"createTime,omitempty"` - // ImportedEntriesCount: Count of deny list entries successfully - // imported. - ImportedEntriesCount int64 `json:"importedEntriesCount,omitempty,string"` + // DefaultSchemaId: Output only. The id of the default Schema + // asscociated to this data store. + DefaultSchemaId string `json:"defaultSchemaId,omitempty"` - // ForceSendFields is a list of field names (e.g. "ErrorSamples") to + // DisplayName: Required. The data store display name. This field must + // be a UTF-8 encoded string with a length limit of 128 characters. + // Otherwise, an INVALID_ARGUMENT error is returned. + DisplayName string `json:"displayName,omitempty"` + + // IndustryVertical: Immutable. The industry vertical that the data + // store registers. + // + // Possible values: + // "INDUSTRY_VERTICAL_UNSPECIFIED" - Value used when unset. + // "GENERIC" - The generic vertical for documents that are not + // specific to any industry vertical. + // "MEDIA" - The media industry vertical. + IndustryVertical string `json:"industryVertical,omitempty"` + + // Name: Immutable. The full resource name of the data store. Format: + // `projects/{project}/locations/{location}/collections/{collection_id}/d + // ataStores/{data_store_id}`. This field must be a UTF-8 encoded string + // with a length limit of 1024 characters. + Name string `json:"name,omitempty"` + + // SolutionTypes: The solutions that the data store enrolls. Available + // solutions for each industry_vertical: * `MEDIA`: + // `SOLUTION_TYPE_RECOMMENDATION` and `SOLUTION_TYPE_SEARCH`. * + // `SITE_SEARCH`: `SOLUTION_TYPE_SEARCH` is automatically enrolled. + // Other solutions cannot be enrolled. + // + // Possible values: + // "SOLUTION_TYPE_UNSPECIFIED" - Default value. + // "SOLUTION_TYPE_RECOMMENDATION" - Used for Recommendations AI. + // "SOLUTION_TYPE_SEARCH" - Used for Discovery Search. + // "SOLUTION_TYPE_CHAT" - Used for use cases related to the Generative + // AI agent. + SolutionTypes []string `json:"solutionTypes,omitempty"` + + // ForceSendFields is a list of field names (e.g. "ContentConfig") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -1213,7 +1245,7 @@ type GoogleCloudDiscoveryengineV1ImportSuggestionDenyListEntriesResponse struct // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "ErrorSamples") to include + // NullFields is a list of field names (e.g. "ContentConfig") to include // in API requests with the JSON null value. By default, fields with // empty values are omitted from API requests. However, any field with // an empty value appearing in NullFields will be sent to the server as @@ -1222,26 +1254,20 @@ type GoogleCloudDiscoveryengineV1ImportSuggestionDenyListEntriesResponse struct NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1ImportSuggestionDenyListEntriesResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1ImportSuggestionDenyListEntriesResponse +func (s *GoogleCloudDiscoveryengineV1DataStore) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1DataStore raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1ImportUserEventsMetadata: Metadata -// related to the progress of the Import operation. This is returned by -// the google.longrunning.Operation.metadata field. -type GoogleCloudDiscoveryengineV1ImportUserEventsMetadata struct { +// GoogleCloudDiscoveryengineV1DeleteDataStoreMetadata: Metadata related +// to the progress of the DataStoreService.DeleteDataStore operation. +// This will be returned by the google.longrunning.Operation.metadata +// field. +type GoogleCloudDiscoveryengineV1DeleteDataStoreMetadata struct { // CreateTime: Operation create time. CreateTime string `json:"createTime,omitempty"` - // FailureCount: Count of entries that encountered errors while - // processing. - FailureCount int64 `json:"failureCount,omitempty,string"` - - // SuccessCount: Count of entries that were processed successfully. - SuccessCount int64 `json:"successCount,omitempty,string"` - // UpdateTime: Operation last update time. If the operation is done, // this is also the finish time. UpdateTime string `json:"updateTime,omitempty"` @@ -1263,35 +1289,24 @@ type GoogleCloudDiscoveryengineV1ImportUserEventsMetadata struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1ImportUserEventsMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1ImportUserEventsMetadata +func (s *GoogleCloudDiscoveryengineV1DeleteDataStoreMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1DeleteDataStoreMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1ImportUserEventsResponse: Response of the -// ImportUserEventsRequest. If the long running operation was -// successful, then this message is returned by the -// google.longrunning.Operations.response field if the operation was -// successful. -type GoogleCloudDiscoveryengineV1ImportUserEventsResponse struct { - // ErrorConfig: Echoes the destination for the complete errors if this - // field was set in the request. - ErrorConfig *GoogleCloudDiscoveryengineV1ImportErrorConfig `json:"errorConfig,omitempty"` - - // ErrorSamples: A sample of errors encountered while processing the - // request. - ErrorSamples []*GoogleRpcStatus `json:"errorSamples,omitempty"` - - // JoinedEventsCount: Count of user events imported with complete - // existing Documents. - JoinedEventsCount int64 `json:"joinedEventsCount,omitempty,string"` +// GoogleCloudDiscoveryengineV1DeleteEngineMetadata: Metadata related to +// the progress of the EngineService.DeleteEngine operation. This will +// be returned by the google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1DeleteEngineMetadata struct { + // CreateTime: Operation create time. + CreateTime string `json:"createTime,omitempty"` - // UnjoinedEventsCount: Count of user events imported, but with Document - // information not found in the existing Branch. - UnjoinedEventsCount int64 `json:"unjoinedEventsCount,omitempty,string"` + // 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. "ErrorConfig") to + // 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. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -1299,35 +1314,27 @@ type GoogleCloudDiscoveryengineV1ImportUserEventsResponse struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "ErrorConfig") to include - // in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. However, any field with - // an empty value appearing in NullFields will be sent to the server as + // 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. However, any field with an + // empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1ImportUserEventsResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1ImportUserEventsResponse +func (s *GoogleCloudDiscoveryengineV1DeleteEngineMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1DeleteEngineMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1PurgeDocumentsMetadata: Metadata related -// to the progress of the PurgeDocuments operation. This will be -// returned by the google.longrunning.Operation.metadata field. -type GoogleCloudDiscoveryengineV1PurgeDocumentsMetadata struct { +// GoogleCloudDiscoveryengineV1DeleteSchemaMetadata: Metadata for +// DeleteSchema LRO. +type GoogleCloudDiscoveryengineV1DeleteSchemaMetadata struct { // CreateTime: Operation create time. CreateTime string `json:"createTime,omitempty"` - // FailureCount: Count of entries that encountered errors while - // processing. - FailureCount int64 `json:"failureCount,omitempty,string"` - - // SuccessCount: Count of entries that were deleted successfully. - SuccessCount int64 `json:"successCount,omitempty,string"` - // UpdateTime: Operation last update time. If the operation is done, // this is also the finish time. UpdateTime string `json:"updateTime,omitempty"` @@ -1349,27 +1356,25 @@ type GoogleCloudDiscoveryengineV1PurgeDocumentsMetadata struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1PurgeDocumentsMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1PurgeDocumentsMetadata +func (s *GoogleCloudDiscoveryengineV1DeleteSchemaMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1DeleteSchemaMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1PurgeDocumentsResponse: Response message -// for DocumentService.PurgeDocuments method. If the long running -// operation is successfully done, then this message is returned by the -// google.longrunning.Operations.response field. -type GoogleCloudDiscoveryengineV1PurgeDocumentsResponse struct { - // PurgeCount: The total count of documents purged as a result of the - // operation. - PurgeCount int64 `json:"purgeCount,omitempty,string"` +// GoogleCloudDiscoveryengineV1DeleteTargetSiteMetadata: Metadata +// related to the progress of the +// SiteSearchEngineService.DeleteTargetSite operation. This will be +// returned by the google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1DeleteTargetSiteMetadata struct { + // CreateTime: Operation create time. + CreateTime string `json:"createTime,omitempty"` - // PurgeSample: A sample of document names that will be deleted. Only - // populated if `force` is set to false. A max of 100 names will be - // returned and the names are chosen at random. - PurgeSample []string `json:"purgeSample,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. "PurgeCount") to + // 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. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -1377,7 +1382,7 @@ type GoogleCloudDiscoveryengineV1PurgeDocumentsResponse struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "PurgeCount") to include in + // 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. However, any field with an // empty value appearing in NullFields will be sent to the server as @@ -1386,17 +1391,17 @@ type GoogleCloudDiscoveryengineV1PurgeDocumentsResponse struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1PurgeDocumentsResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1PurgeDocumentsResponse +func (s *GoogleCloudDiscoveryengineV1DeleteTargetSiteMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1DeleteTargetSiteMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1PurgeSuggestionDenyListEntriesMetadata: +// GoogleCloudDiscoveryengineV1DisableAdvancedSiteSearchMetadata: // Metadata related to the progress of the -// PurgeSuggestionDenyListEntries operation. This is returned by the -// google.longrunning.Operation.metadata field. -type GoogleCloudDiscoveryengineV1PurgeSuggestionDenyListEntriesMetadata struct { +// SiteSearchEngineService.DisableAdvancedSiteSearch operation. This +// will be returned by the google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1DisableAdvancedSiteSearchMetadata struct { // CreateTime: Operation create time. CreateTime string `json:"createTime,omitempty"` @@ -1421,24 +1426,31 @@ type GoogleCloudDiscoveryengineV1PurgeSuggestionDenyListEntriesMetadata struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1PurgeSuggestionDenyListEntriesMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1PurgeSuggestionDenyListEntriesMetadata +func (s *GoogleCloudDiscoveryengineV1DisableAdvancedSiteSearchMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1DisableAdvancedSiteSearchMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1PurgeSuggestionDenyListEntriesResponse: -// Response message for CompletionService.PurgeSuggestionDenyListEntries -// method. -type GoogleCloudDiscoveryengineV1PurgeSuggestionDenyListEntriesResponse struct { - // ErrorSamples: A sample of errors encountered while processing the - // request. - ErrorSamples []*GoogleRpcStatus `json:"errorSamples,omitempty"` +// GoogleCloudDiscoveryengineV1DisableAdvancedSiteSearchResponse: +// Response message for +// SiteSearchEngineService.DisableAdvancedSiteSearch method. +type GoogleCloudDiscoveryengineV1DisableAdvancedSiteSearchResponse struct { +} - // PurgeCount: Number of suggestion deny list entries purged. - PurgeCount int64 `json:"purgeCount,omitempty,string"` +// GoogleCloudDiscoveryengineV1EnableAdvancedSiteSearchMetadata: +// Metadata related to the progress of the +// SiteSearchEngineService.EnableAdvancedSiteSearch operation. This will +// be returned by the google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1EnableAdvancedSiteSearchMetadata struct { + // CreateTime: Operation create time. + CreateTime string `json:"createTime,omitempty"` - // ForceSendFields is a list of field names (e.g. "ErrorSamples") to + // 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. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -1446,38 +1458,99 @@ type GoogleCloudDiscoveryengineV1PurgeSuggestionDenyListEntriesResponse struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "ErrorSamples") to include - // in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. However, any field with - // an empty value appearing in NullFields will be sent to the server as + // 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. However, any field with an + // empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1PurgeSuggestionDenyListEntriesResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1PurgeSuggestionDenyListEntriesResponse +func (s *GoogleCloudDiscoveryengineV1EnableAdvancedSiteSearchMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1EnableAdvancedSiteSearchMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1Schema: Defines the structure and layout -// of a type of document data. -type GoogleCloudDiscoveryengineV1Schema struct { - // JsonSchema: The JSON representation of the schema. - JsonSchema string `json:"jsonSchema,omitempty"` +// GoogleCloudDiscoveryengineV1EnableAdvancedSiteSearchResponse: +// Response message for SiteSearchEngineService.EnableAdvancedSiteSearch +// method. +type GoogleCloudDiscoveryengineV1EnableAdvancedSiteSearchResponse struct { +} - // Name: Immutable. The full resource name of the schema, in the format - // of - // `projects/{project}/locations/{location}/collections/{collection}/data - // Stores/{data_store}/schemas/{schema}`. This field must be a UTF-8 - // encoded string with a length limit of 1024 characters. +// GoogleCloudDiscoveryengineV1Engine: Metadata that describes the +// training and serving parameters of an Engine. +type GoogleCloudDiscoveryengineV1Engine struct { + // ChatEngineConfig: Configurations for the Chat Engine. Only applicable + // if solution_type is SOLUTION_TYPE_CHAT. + ChatEngineConfig *GoogleCloudDiscoveryengineV1EngineChatEngineConfig `json:"chatEngineConfig,omitempty"` + + // ChatEngineMetadata: Output only. Additional information of the Chat + // Engine. Only applicable if solution_type is SOLUTION_TYPE_CHAT. + ChatEngineMetadata *GoogleCloudDiscoveryengineV1EngineChatEngineMetadata `json:"chatEngineMetadata,omitempty"` + + // CommonConfig: Common config spec that specifies the metadata of the + // engine. + CommonConfig *GoogleCloudDiscoveryengineV1EngineCommonConfig `json:"commonConfig,omitempty"` + + // CreateTime: Output only. Timestamp the Recommendation Engine was + // created at. + CreateTime string `json:"createTime,omitempty"` + + // DataStoreIds: The data stores associated with this engine. For + // SOLUTION_TYPE_SEARCH and SOLUTION_TYPE_RECOMMENDATION type of + // engines, they can only associate with at most one data store. If + // solution_type is SOLUTION_TYPE_CHAT, multiple DataStores in the same + // Collection can be associated here. Note that when used in + // CreateEngineRequest, one DataStore id must be provided as the system + // will use it for necessary initializations. + DataStoreIds []string `json:"dataStoreIds,omitempty"` + + // DisplayName: Required. The display name of the engine. Should be + // human readable. UTF-8 encoded string with limit of 1024 characters. + DisplayName string `json:"displayName,omitempty"` + + // IndustryVertical: The industry vertical that the engine registers. + // The restriction of the Engine industry vertical is based on + // DataStore: If unspecified, default to `GENERIC`. Vertical on Engine + // has to match vertical of the DataStore liniked to the engine. + // + // Possible values: + // "INDUSTRY_VERTICAL_UNSPECIFIED" - Value used when unset. + // "GENERIC" - The generic vertical for documents that are not + // specific to any industry vertical. + // "MEDIA" - The media industry vertical. + IndustryVertical string `json:"industryVertical,omitempty"` + + // Name: Immutable. The fully qualified resource name of the engine. + // This field must be a UTF-8 encoded string with a length limit of 1024 + // characters. Format: + // `projects/{project_number}/locations/{location}/collections/{collectio + // n}/engines/{engine}` engine should be 1-63 characters, and valid + // characters are /a-z0-9*/. Otherwise, an INVALID_ARGUMENT error is + // returned. Name string `json:"name,omitempty"` - // StructSchema: The structured representation of the schema. - StructSchema googleapi.RawMessage `json:"structSchema,omitempty"` + // SearchEngineConfig: Configurations for the Search Engine. Only + // applicable if solution_type is SOLUTION_TYPE_SEARCH. + SearchEngineConfig *GoogleCloudDiscoveryengineV1EngineSearchEngineConfig `json:"searchEngineConfig,omitempty"` - // ForceSendFields is a list of field names (e.g. "JsonSchema") to + // SolutionType: Required. The solutions of the engine. + // + // Possible values: + // "SOLUTION_TYPE_UNSPECIFIED" - Default value. + // "SOLUTION_TYPE_RECOMMENDATION" - Used for Recommendations AI. + // "SOLUTION_TYPE_SEARCH" - Used for Discovery Search. + // "SOLUTION_TYPE_CHAT" - Used for use cases related to the Generative + // AI agent. + SolutionType string `json:"solutionType,omitempty"` + + // UpdateTime: Output only. Timestamp the Recommendation Engine was last + // updated. + UpdateTime string `json:"updateTime,omitempty"` + + // ForceSendFields is a list of field names (e.g. "ChatEngineConfig") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -1485,62 +1558,100 @@ type GoogleCloudDiscoveryengineV1Schema struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "JsonSchema") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "ChatEngineConfig") to + // include in API requests with the JSON null value. By default, fields + // with empty values are omitted from API requests. However, any field + // with an empty value appearing in NullFields will be sent to the + // server as null. It is an error if a field in this list has a + // non-empty value. This may be used to include null fields in Patch + // requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1Schema) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1Schema +func (s *GoogleCloudDiscoveryengineV1Engine) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1Engine raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1UpdateSchemaMetadata: Metadata for -// UpdateSchema LRO. -type GoogleCloudDiscoveryengineV1UpdateSchemaMetadata struct { - // CreateTime: Operation create time. - CreateTime string `json:"createTime,omitempty"` +// GoogleCloudDiscoveryengineV1EngineChatEngineConfig: Configurations +// for a Chat Engine. +type GoogleCloudDiscoveryengineV1EngineChatEngineConfig struct { + // AgentCreationConfig: The configurationt generate the Dialogflow agent + // that is associated to this Engine. Note that these configurations are + // one-time consumed by and passed to Dialogflow service. It means they + // cannot be retrieved using EngineService.GetEngine or + // EngineService.ListEngines API after engine creation. + AgentCreationConfig *GoogleCloudDiscoveryengineV1EngineChatEngineConfigAgentCreationConfig `json:"agentCreationConfig,omitempty"` - // UpdateTime: Operation last update time. If the operation is done, - // this is also the finish time. - UpdateTime string `json:"updateTime,omitempty"` + // DialogflowAgentToLink: The resource name of an exist Dialogflow agent + // to link to this Chat Engine. Customers can either provide + // `agent_creation_config` to create agent or provide an agent name that + // links the agent with the Chat engine. Format: + // `projects//locations//agents/`. Note that the + // `dialogflow_agent_to_link` are one-time consumed by and passed to + // Dialogflow service. It means they cannot be retrieved using + // EngineService.GetEngine or EngineService.ListEngines API after engine + // creation. Please use ChatEngineMetadata.dialogflow_agent for actual + // agent association after Engine is created. + DialogflowAgentToLink string `json:"dialogflowAgentToLink,omitempty"` - // ForceSendFields is a list of field names (e.g. "CreateTime") to - // unconditionally include in API requests. By default, fields with + // ForceSendFields is a list of field names (e.g. "AgentCreationConfig") + // to unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be // sent to the server regardless of whether the field is empty or not. // This may be used to include empty fields in Patch requests. 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. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "AgentCreationConfig") to + // include in API requests with the JSON null value. By default, fields + // with empty values are omitted from API requests. However, any field + // with an empty value appearing in NullFields will be sent to the + // server as null. It is an error if a field in this list has a + // non-empty value. This may be used to include null fields in Patch + // requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1UpdateSchemaMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1UpdateSchemaMetadata +func (s *GoogleCloudDiscoveryengineV1EngineChatEngineConfig) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1EngineChatEngineConfig raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaAdditionalParams: AdditionalParams -// message for WidgetService methods for security and privacy -// enhancement. -type GoogleCloudDiscoveryengineV1alphaAdditionalParams struct { - // Token: Token that used for non-human user check. - Token string `json:"token,omitempty"` +// GoogleCloudDiscoveryengineV1EngineChatEngineConfigAgentCreationConfig: +// +// Configurations for generating a Dialogflow agent. Note that these +// +// configurations are one-time consumed by and passed to Dialogflow +// service. It means they cannot be retrieved using +// EngineService.GetEngine or EngineService.ListEngines API after engine +// creation. +type GoogleCloudDiscoveryengineV1EngineChatEngineConfigAgentCreationConfig struct { + // Business: Name of the company, organization or other entity that the + // agent represents. Used for knowledge connector LLM prompt and for + // knowledge search. + Business string `json:"business,omitempty"` - // ForceSendFields is a list of field names (e.g. "Token") to + // DefaultLanguageCode: Required. The default language of the agent as a + // language tag. See Language Support + // (https://cloud.google.com/dialogflow/docs/reference/language) for a + // list of the currently supported language codes. + DefaultLanguageCode string `json:"defaultLanguageCode,omitempty"` + + // Location: Agent location for Agent creation, supported values: + // global/us/eu. If not provided, us Engine will create Agent using + // us-central-1 by default; eu Engine will create Agent using eu-west-1 + // by default. + Location string `json:"location,omitempty"` + + // TimeZone: Required. The time zone of the agent from the time zone + // database (https://www.iana.org/time-zones), e.g., America/New_York, + // Europe/Paris. + TimeZone string `json:"timeZone,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Business") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -1548,8 +1659,8 @@ type GoogleCloudDiscoveryengineV1alphaAdditionalParams struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Token") to include in API - // requests with the JSON null value. By default, fields with empty + // NullFields is a list of field names (e.g. "Business") to include in + // API requests with the JSON null value. By default, fields with empty // values are omitted from API requests. However, any field with an // empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. @@ -1557,25 +1668,20 @@ type GoogleCloudDiscoveryengineV1alphaAdditionalParams struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaAdditionalParams) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaAdditionalParams +func (s *GoogleCloudDiscoveryengineV1EngineChatEngineConfigAgentCreationConfig) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1EngineChatEngineConfigAgentCreationConfig raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaBatchCreateTargetSiteMetadata: -// Metadata related to the progress of the -// SiteSearchEngineService.BatchCreateTargetSites operation. This will -// be returned by the google.longrunning.Operation.metadata field. -type GoogleCloudDiscoveryengineV1alphaBatchCreateTargetSiteMetadata 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"` +// GoogleCloudDiscoveryengineV1EngineChatEngineMetadata: Additional +// information of a Chat Engine. Fields in this message are output only. +type GoogleCloudDiscoveryengineV1EngineChatEngineMetadata struct { + // DialogflowAgent: The resource name of a Dialogflow agent, that this + // Chat Engine refers to. Format: `projects//locations//agents/`. + DialogflowAgent string `json:"dialogflowAgent,omitempty"` - // ForceSendFields is a list of field names (e.g. "CreateTime") to + // ForceSendFields is a list of field names (e.g. "DialogflowAgent") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -1583,30 +1689,31 @@ type GoogleCloudDiscoveryengineV1alphaBatchCreateTargetSiteMetadata struct { // This may be used to include empty fields in Patch requests. 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. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "DialogflowAgent") to + // include in API requests with the JSON null value. By default, fields + // with empty values are omitted from API requests. However, any field + // with an empty value appearing in NullFields will be sent to the + // server as null. It is an error if a field in this list has a + // non-empty value. This may be used to include null fields in Patch + // requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaBatchCreateTargetSiteMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaBatchCreateTargetSiteMetadata +func (s *GoogleCloudDiscoveryengineV1EngineChatEngineMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1EngineChatEngineMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaBatchCreateTargetSitesRequest: -// Request message for SiteSearchEngineService.BatchCreateTargetSites -// method. -type GoogleCloudDiscoveryengineV1alphaBatchCreateTargetSitesRequest struct { - // Requests: Required. The request message specifying the resources to - // create. A maximum of 20 TargetSites can be created in a batch. - Requests []*GoogleCloudDiscoveryengineV1alphaCreateTargetSiteRequest `json:"requests,omitempty"` +// GoogleCloudDiscoveryengineV1EngineCommonConfig: Common configurations +// for an Engine. +type GoogleCloudDiscoveryengineV1EngineCommonConfig struct { + // CompanyName: Immutable. The name of the company, business or entity + // that is associated with the engine. Setting this may help improve LLM + // related features. + CompanyName string `json:"companyName,omitempty"` - // ForceSendFields is a list of field names (e.g. "Requests") to + // ForceSendFields is a list of field names (e.g. "CompanyName") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -1614,29 +1721,45 @@ type GoogleCloudDiscoveryengineV1alphaBatchCreateTargetSitesRequest struct { // This may be used to include empty fields in Patch requests. 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. However, any field with an - // empty value appearing in NullFields will be sent to the server as + // NullFields is a list of field names (e.g. "CompanyName") to include + // in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. However, any field with + // an empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaBatchCreateTargetSitesRequest) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaBatchCreateTargetSitesRequest +func (s *GoogleCloudDiscoveryengineV1EngineCommonConfig) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1EngineCommonConfig raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaBatchCreateTargetSitesResponse: -// Response message for SiteSearchEngineService.BatchCreateTargetSites -// method. -type GoogleCloudDiscoveryengineV1alphaBatchCreateTargetSitesResponse struct { - // TargetSites: TargetSites created. - TargetSites []*GoogleCloudDiscoveryengineV1alphaTargetSite `json:"targetSites,omitempty"` +// GoogleCloudDiscoveryengineV1EngineSearchEngineConfig: Configurations +// for a Search Engine. +type GoogleCloudDiscoveryengineV1EngineSearchEngineConfig struct { + // SearchAddOns: The add-on that this search engine enables. + // + // Possible values: + // "SEARCH_ADD_ON_UNSPECIFIED" - Default value when the enum is + // unspecified. This is invalid to use. + // "SEARCH_ADD_ON_LLM" - Large language model add-on. + SearchAddOns []string `json:"searchAddOns,omitempty"` - // ForceSendFields is a list of field names (e.g. "TargetSites") to + // SearchTier: The search feature tier of this engine. Different tiers + // might have different pricing. To learn more, please check the pricing + // documentation. Defaults to SearchTier.SEARCH_TIER_STANDARD if not + // specified. + // + // Possible values: + // "SEARCH_TIER_UNSPECIFIED" - Default value when the enum is + // unspecified. This is invalid to use. + // "SEARCH_TIER_STANDARD" - Standard tier. + // "SEARCH_TIER_ENTERPRISE" - Enterprise tier. + SearchTier string `json:"searchTier,omitempty"` + + // ForceSendFields is a list of field names (e.g. "SearchAddOns") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -1644,7 +1767,7 @@ type GoogleCloudDiscoveryengineV1alphaBatchCreateTargetSitesResponse struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "TargetSites") to include + // NullFields is a list of field names (e.g. "SearchAddOns") to include // in API requests with the JSON null value. By default, fields with // empty values are omitted from API requests. However, any field with // an empty value appearing in NullFields will be sent to the server as @@ -1653,55 +1776,31 @@ type GoogleCloudDiscoveryengineV1alphaBatchCreateTargetSitesResponse struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaBatchCreateTargetSitesResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaBatchCreateTargetSitesResponse +func (s *GoogleCloudDiscoveryengineV1EngineSearchEngineConfig) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1EngineSearchEngineConfig raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaBatchVerifyTargetSitesRequest: -// Request message for SiteSearchEngineService.BatchVerifyTargetSites -// method. -type GoogleCloudDiscoveryengineV1alphaBatchVerifyTargetSitesRequest struct { -} - -// GoogleCloudDiscoveryengineV1alphaBigQuerySource: BigQuery source -// import data from. -type GoogleCloudDiscoveryengineV1alphaBigQuerySource struct { - // DataSchema: The schema to use when parsing the data from the source. - // Supported values for user event imports: * `user_event` (default): - // One UserEvent per row. Supported values for document imports: * - // `document` (default): One Document format per row. Each document must - // have a valid Document.id and one of Document.json_data or - // Document.struct_data. * `custom`: One custom data per row in - // arbitrary format that conforms to the defined Schema of the data - // store. This can only be used by Gen App Builder. - DataSchema string `json:"dataSchema,omitempty"` - - // DatasetId: Required. The BigQuery data set to copy the data from with - // a length limit of 1,024 characters. - DatasetId string `json:"datasetId,omitempty"` - - // GcsStagingDir: Intermediate Cloud Storage directory used for the - // import with a length limit of 2,000 characters. Can be specified if - // one wants to have the BigQuery export to a specific Cloud Storage - // directory. - GcsStagingDir string `json:"gcsStagingDir,omitempty"` +// GoogleCloudDiscoveryengineV1ImportDocumentsMetadata: Metadata related +// to the progress of the ImportDocuments operation. This is returned by +// the google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1ImportDocumentsMetadata struct { + // CreateTime: Operation create time. + CreateTime string `json:"createTime,omitempty"` - // PartitionDate: BigQuery time partitioned table's _PARTITIONDATE in - // YYYY-MM-DD format. - PartitionDate *GoogleTypeDate `json:"partitionDate,omitempty"` + // FailureCount: Count of entries that encountered errors while + // processing. + FailureCount int64 `json:"failureCount,omitempty,string"` - // ProjectId: The project ID (can be project # or ID) that the BigQuery - // source is in with a length limit of 128 characters. If not specified, - // inherits the project ID from the parent request. - ProjectId string `json:"projectId,omitempty"` + // SuccessCount: Count of entries that were processed successfully. + SuccessCount int64 `json:"successCount,omitempty,string"` - // TableId: Required. The BigQuery table to copy the data from with a - // length limit of 1,024 characters. - TableId string `json:"tableId,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. "DataSchema") to + // 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. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -1709,7 +1808,7 @@ type GoogleCloudDiscoveryengineV1alphaBigQuerySource struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "DataSchema") to include in + // 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. However, any field with an // empty value appearing in NullFields will be sent to the server as @@ -1718,55 +1817,59 @@ type GoogleCloudDiscoveryengineV1alphaBigQuerySource struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaBigQuerySource) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaBigQuerySource +func (s *GoogleCloudDiscoveryengineV1ImportDocumentsMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1ImportDocumentsMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaCompleteQueryRequest: Request -// message for CompletionService.CompleteQuery method. -type GoogleCloudDiscoveryengineV1alphaCompleteQueryRequest struct { - // DataStore: Required. The parent data store resource name for which - // the completion is performed, such as - // `projects/*/locations/global/collections/default_collection/dataStores - // /default_data_store`. - DataStore string `json:"dataStore,omitempty"` +// GoogleCloudDiscoveryengineV1ImportDocumentsResponse: Response of the +// ImportDocumentsRequest. If the long running operation is done, then +// this message is returned by the +// google.longrunning.Operations.response field if the operation was +// successful. +type GoogleCloudDiscoveryengineV1ImportDocumentsResponse struct { + // ErrorConfig: Echoes the destination for the complete errors in the + // request if set. + ErrorConfig *GoogleCloudDiscoveryengineV1ImportErrorConfig `json:"errorConfig,omitempty"` - // IncludeTailSuggestions: Indicates if tail suggestions should be - // returned if there are no suggestions that match the full query. Even - // if set to true, if there are suggestions that match the full query, - // those are returned and no tail suggestions are returned. - IncludeTailSuggestions bool `json:"includeTailSuggestions,omitempty"` + // ErrorSamples: A sample of errors encountered while processing the + // request. + ErrorSamples []*GoogleRpcStatus `json:"errorSamples,omitempty"` - // Query: Required. The typeahead input used to fetch suggestions. - // Maximum length is 128 characters. - Query string `json:"query,omitempty"` + // ForceSendFields is a list of field names (e.g. "ErrorConfig") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` - // QueryModel: Selects data model of query suggestions for serving. - // Currently supported values: * `document` - Using suggestions - // generated from user-imported documents. * `search-history` - Using - // suggestions generated from the past history of SearchService.Search - // API calls. Do not use it when there is no traffic for Search API. * - // `user-event` - Using suggestions generated from user-imported search - // events. * `document-completable` - Using suggestions taken directly - // from user-imported document fields marked as completable. Default - // values: * `document` is the default model for regular dataStores. * - // `search-history` is the default model for site search dataStores. - QueryModel string `json:"queryModel,omitempty"` + // NullFields is a list of field names (e.g. "ErrorConfig") to include + // in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. However, any field with + // an empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} - // UserPseudoId: A unique identifier for tracking visitors. For example, - // this could be implemented with an HTTP cookie, which should be able - // to uniquely identify a visitor on a single device. This unique - // identifier should not change if the visitor logs in or out of the - // website. This field should NOT have a fixed value such as - // `unknown_visitor`. This should be the same identifier as - // UserEvent.user_pseudo_id and SearchRequest.user_pseudo_id. The field - // must be a UTF-8 encoded string with a length limit of 128 characters. - // Otherwise, an `INVALID_ARGUMENT` error is returned. - UserPseudoId string `json:"userPseudoId,omitempty"` +func (s *GoogleCloudDiscoveryengineV1ImportDocumentsResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1ImportDocumentsResponse + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} - // ForceSendFields is a list of field names (e.g. "DataStore") to +// GoogleCloudDiscoveryengineV1ImportErrorConfig: Configuration of +// destination for Import related errors. +type GoogleCloudDiscoveryengineV1ImportErrorConfig struct { + // GcsPrefix: Cloud Storage prefix for import errors. This must be an + // empty, existing Cloud Storage directory. Import errors are written to + // sharded files in this directory, one per line, as a JSON-encoded + // `google.rpc.Status` message. + GcsPrefix string `json:"gcsPrefix,omitempty"` + + // ForceSendFields is a list of field names (e.g. "GcsPrefix") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -1774,7 +1877,7 @@ type GoogleCloudDiscoveryengineV1alphaCompleteQueryRequest struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "DataStore") to include in + // NullFields is a list of field names (e.g. "GcsPrefix") to include in // API requests with the JSON null value. By default, fields with empty // values are omitted from API requests. However, any field with an // empty value appearing in NullFields will be sent to the server as @@ -1783,30 +1886,25 @@ type GoogleCloudDiscoveryengineV1alphaCompleteQueryRequest struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaCompleteQueryRequest) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaCompleteQueryRequest +func (s *GoogleCloudDiscoveryengineV1ImportErrorConfig) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1ImportErrorConfig raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaCompleteQueryResponse: Response -// message for CompletionService.CompleteQuery method. -type GoogleCloudDiscoveryengineV1alphaCompleteQueryResponse struct { - // QuerySuggestions: Results of the matched query suggestions. The - // result list is ordered and the first result is a top suggestion. - QuerySuggestions []*GoogleCloudDiscoveryengineV1alphaCompleteQueryResponseQuerySuggestion `json:"querySuggestions,omitempty"` - - // TailMatchTriggered: True if the returned suggestions are all tail - // suggestions. For tail matching to be triggered, - // include_tail_suggestions in the request must be true and there must - // be no suggestions that match the full query. - TailMatchTriggered bool `json:"tailMatchTriggered,omitempty"` +// GoogleCloudDiscoveryengineV1ImportSuggestionDenyListEntriesMetadata: +// Metadata related to the progress of the +// ImportSuggestionDenyListEntries operation. This is returned by the +// google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1ImportSuggestionDenyListEntriesMetadata struct { + // CreateTime: Operation create time. + CreateTime string `json:"createTime,omitempty"` - // ServerResponse contains the HTTP response code and headers from the - // server. - googleapi.ServerResponse `json:"-"` + // 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. "QuerySuggestions") to + // 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. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -1814,74 +1912,79 @@ type GoogleCloudDiscoveryengineV1alphaCompleteQueryResponse struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "QuerySuggestions") to - // include in API requests with the JSON null value. By default, fields - // with empty values are omitted from API requests. However, any field - // with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. + // 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. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaCompleteQueryResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaCompleteQueryResponse +func (s *GoogleCloudDiscoveryengineV1ImportSuggestionDenyListEntriesMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1ImportSuggestionDenyListEntriesMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaCompleteQueryResponseQuerySuggestion: -// -// Suggestions as search queries. -type GoogleCloudDiscoveryengineV1alphaCompleteQueryResponseQuerySuggestion struct { - // CompletableFieldPaths: The unique document field paths that serve as - // the source of this suggestion if it was generated from completable - // fields. This field is only populated for the document-completable - // model. - CompletableFieldPaths []string `json:"completableFieldPaths,omitempty"` - - // Suggestion: The suggestion for the query. - Suggestion string `json:"suggestion,omitempty"` +// GoogleCloudDiscoveryengineV1ImportSuggestionDenyListEntriesResponse: +// Response message for +// CompletionService.ImportSuggestionDenyListEntries method. +type GoogleCloudDiscoveryengineV1ImportSuggestionDenyListEntriesResponse struct { + // ErrorSamples: A sample of errors encountered while processing the + // request. + ErrorSamples []*GoogleRpcStatus `json:"errorSamples,omitempty"` - // ForceSendFields is a list of field names (e.g. - // "CompletableFieldPaths") to unconditionally include in API requests. - // By default, fields with empty or default values are omitted from API - // requests. However, any non-pointer, non-interface field appearing in - // ForceSendFields will be sent to the server regardless of whether the - // field is empty or not. This may be used to include empty fields in - // Patch requests. + // FailedEntriesCount: Count of deny list entries that failed to be + // imported. + FailedEntriesCount int64 `json:"failedEntriesCount,omitempty,string"` + + // ImportedEntriesCount: Count of deny list entries successfully + // imported. + ImportedEntriesCount int64 `json:"importedEntriesCount,omitempty,string"` + + // ForceSendFields is a list of field names (e.g. "ErrorSamples") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "CompletableFieldPaths") to - // include in API requests with the JSON null value. By default, fields - // with empty values are omitted from API requests. However, any field - // with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. + // NullFields is a list of field names (e.g. "ErrorSamples") to include + // in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. However, any field with + // an empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaCompleteQueryResponseQuerySuggestion) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaCompleteQueryResponseQuerySuggestion +func (s *GoogleCloudDiscoveryengineV1ImportSuggestionDenyListEntriesResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1ImportSuggestionDenyListEntriesResponse raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaCompletionInfo: Detailed completion -// information including completion attribution token and clicked -// completion info. -type GoogleCloudDiscoveryengineV1alphaCompletionInfo struct { - // SelectedPosition: End user selected - // CompleteQueryResponse.QuerySuggestion.suggestion position, starting - // from 0. - SelectedPosition int64 `json:"selectedPosition,omitempty"` +// GoogleCloudDiscoveryengineV1ImportUserEventsMetadata: Metadata +// related to the progress of the Import operation. This is returned by +// the google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1ImportUserEventsMetadata struct { + // CreateTime: Operation create time. + CreateTime string `json:"createTime,omitempty"` - // SelectedSuggestion: End user selected - // CompleteQueryResponse.QuerySuggestion.suggestion. - SelectedSuggestion string `json:"selectedSuggestion,omitempty"` + // FailureCount: Count of entries that encountered errors while + // processing. + FailureCount int64 `json:"failureCount,omitempty,string"` - // ForceSendFields is a list of field names (e.g. "SelectedPosition") to + // SuccessCount: Count of entries that were processed successfully. + SuccessCount int64 `json:"successCount,omitempty,string"` + + // 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. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -1889,57 +1992,85 @@ type GoogleCloudDiscoveryengineV1alphaCompletionInfo struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "SelectedPosition") to - // include in API requests with the JSON null value. By default, fields - // with empty values are omitted from API requests. However, any field - // with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. + // 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. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaCompletionInfo) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaCompletionInfo +func (s *GoogleCloudDiscoveryengineV1ImportUserEventsMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1ImportUserEventsMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaConversation: External conversation -// proto definition. -type GoogleCloudDiscoveryengineV1alphaConversation struct { - // EndTime: Output only. The time the conversation finished. - EndTime string `json:"endTime,omitempty"` +// GoogleCloudDiscoveryengineV1ImportUserEventsResponse: Response of the +// ImportUserEventsRequest. If the long running operation was +// successful, then this message is returned by the +// google.longrunning.Operations.response field if the operation was +// successful. +type GoogleCloudDiscoveryengineV1ImportUserEventsResponse struct { + // ErrorConfig: Echoes the destination for the complete errors if this + // field was set in the request. + ErrorConfig *GoogleCloudDiscoveryengineV1ImportErrorConfig `json:"errorConfig,omitempty"` - // Messages: Conversation messages. - Messages []*GoogleCloudDiscoveryengineV1alphaConversationMessage `json:"messages,omitempty"` + // ErrorSamples: A sample of errors encountered while processing the + // request. + ErrorSamples []*GoogleRpcStatus `json:"errorSamples,omitempty"` - // Name: Immutable. Fully qualified name - // `project/*/locations/global/collections/{collection}/dataStore/*/conve - // rsations/*` or - // `project/*/locations/global/collections/{collection}/engines/*/convers - // ations/*`. - Name string `json:"name,omitempty"` + // JoinedEventsCount: Count of user events imported with complete + // existing Documents. + JoinedEventsCount int64 `json:"joinedEventsCount,omitempty,string"` - // StartTime: Output only. The time the conversation started. - StartTime string `json:"startTime,omitempty"` + // UnjoinedEventsCount: Count of user events imported, but with Document + // information not found in the existing Branch. + UnjoinedEventsCount int64 `json:"unjoinedEventsCount,omitempty,string"` - // State: The state of the Conversation. - // - // Possible values: - // "STATE_UNSPECIFIED" - Unknown. - // "IN_PROGRESS" - Conversation is currently open. - // "COMPLETED" - Conversation has been completed. - State string `json:"state,omitempty"` + // ForceSendFields is a list of field names (e.g. "ErrorConfig") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` - // UserPseudoId: A unique identifier for tracking users. - UserPseudoId string `json:"userPseudoId,omitempty"` + // NullFields is a list of field names (e.g. "ErrorConfig") to include + // in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. However, any field with + // an empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} - // ServerResponse contains the HTTP response code and headers from the - // server. - googleapi.ServerResponse `json:"-"` +func (s *GoogleCloudDiscoveryengineV1ImportUserEventsResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1ImportUserEventsResponse + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} - // ForceSendFields is a list of field names (e.g. "EndTime") to +// GoogleCloudDiscoveryengineV1PurgeDocumentsMetadata: Metadata related +// to the progress of the PurgeDocuments operation. This will be +// returned by the google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1PurgeDocumentsMetadata struct { + // CreateTime: Operation create time. + CreateTime string `json:"createTime,omitempty"` + + // FailureCount: Count of entries that encountered errors while + // processing. + FailureCount int64 `json:"failureCount,omitempty,string"` + + // SuccessCount: Count of entries that were deleted successfully. + SuccessCount int64 `json:"successCount,omitempty,string"` + + // 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. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -1947,7 +2078,7 @@ type GoogleCloudDiscoveryengineV1alphaConversation struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "EndTime") to include in + // 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. However, any field with an // empty value appearing in NullFields will be sent to the server as @@ -1956,24 +2087,27 @@ type GoogleCloudDiscoveryengineV1alphaConversation struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaConversation) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaConversation +func (s *GoogleCloudDiscoveryengineV1PurgeDocumentsMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1PurgeDocumentsMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaConversationContext: Defines context -// of the conversation -type GoogleCloudDiscoveryengineV1alphaConversationContext struct { - // ActiveDocument: The current active document the user opened. It - // contains the document resource reference. - ActiveDocument string `json:"activeDocument,omitempty"` +// GoogleCloudDiscoveryengineV1PurgeDocumentsResponse: Response message +// for DocumentService.PurgeDocuments method. If the long running +// operation is successfully done, then this message is returned by the +// google.longrunning.Operations.response field. +type GoogleCloudDiscoveryengineV1PurgeDocumentsResponse struct { + // PurgeCount: The total count of documents purged as a result of the + // operation. + PurgeCount int64 `json:"purgeCount,omitempty,string"` - // ContextDocuments: The current list of documents the user is seeing. - // It contains the document resource references. - ContextDocuments []string `json:"contextDocuments,omitempty"` + // PurgeSample: A sample of document names that will be deleted. Only + // populated if `force` is set to false. A max of 100 names will be + // returned and the names are chosen at random. + PurgeSample []string `json:"purgeSample,omitempty"` - // ForceSendFields is a list of field names (e.g. "ActiveDocument") to + // ForceSendFields is a list of field names (e.g. "PurgeCount") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -1981,33 +2115,32 @@ type GoogleCloudDiscoveryengineV1alphaConversationContext struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "ActiveDocument") to - // include in API requests with the JSON null value. By default, fields - // with empty values are omitted from API requests. However, any field - // with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. + // NullFields is a list of field names (e.g. "PurgeCount") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaConversationContext) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaConversationContext +func (s *GoogleCloudDiscoveryengineV1PurgeDocumentsResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1PurgeDocumentsResponse raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaConversationMessage: Defines a -// conversation message. -type GoogleCloudDiscoveryengineV1alphaConversationMessage struct { - // CreateTime: Output only. Message creation timestamp. +// GoogleCloudDiscoveryengineV1PurgeSuggestionDenyListEntriesMetadata: +// Metadata related to the progress of the +// PurgeSuggestionDenyListEntries operation. This is returned by the +// google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1PurgeSuggestionDenyListEntriesMetadata struct { + // CreateTime: Operation create time. CreateTime string `json:"createTime,omitempty"` - // Reply: Search reply. - Reply *GoogleCloudDiscoveryengineV1alphaReply `json:"reply,omitempty"` - - // UserInput: User text input. - UserInput *GoogleCloudDiscoveryengineV1alphaTextInput `json:"userInput,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 @@ -2026,79 +2159,24 @@ type GoogleCloudDiscoveryengineV1alphaConversationMessage struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaConversationMessage) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaConversationMessage +func (s *GoogleCloudDiscoveryengineV1PurgeSuggestionDenyListEntriesMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1PurgeSuggestionDenyListEntriesMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaConverseConversationRequest: Request -// message for ConversationalSearchService.ConverseConversation method. -type GoogleCloudDiscoveryengineV1alphaConverseConversationRequest struct { - // Conversation: The conversation to be used by auto session only. The - // name field will be ignored as we automatically assign new name for - // the conversation in auto session. - Conversation *GoogleCloudDiscoveryengineV1alphaConversation `json:"conversation,omitempty"` - - // Filter: 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. This will be - // used to filter search results which may affect the summary response. - // 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 --> 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) - Filter string `json:"filter,omitempty"` - - // Name: Required. The resource name of the Conversation to get. Format: - // `projects/{project_number}/locations/{location_id}/collections/{collec - // tion}/dataStores/{data_store_id}/conversations/{conversation_id}`. - // Use - // `projects/{project_number}/locations/{location_id}/collections/{collec - // tion}/dataStores/{data_store_id}/conversations/-` to activate auto - // session mode, which automatically creates a new conversation inside a - // ConverseConversation session. - Name string `json:"name,omitempty"` - - // Query: Required. Current user input. - Query *GoogleCloudDiscoveryengineV1alphaTextInput `json:"query,omitempty"` - - // SafeSearch: Whether to turn on safe search. - SafeSearch bool `json:"safeSearch,omitempty"` - - // ServingConfig: The resource name of the Serving Config to use. - // Format: - // `projects/{project_number}/locations/{location_id}/collections/{collec - // tion}/dataStores/{data_store_id}/servingConfigs/{serving_config_id}` - // If this is not set, the default serving config will be used. - ServingConfig string `json:"servingConfig,omitempty"` - - // SummarySpec: A specification for configuring the summary returned in - // the response. - SummarySpec *GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSummarySpec `json:"summarySpec,omitempty"` +// GoogleCloudDiscoveryengineV1PurgeSuggestionDenyListEntriesResponse: +// Response message for CompletionService.PurgeSuggestionDenyListEntries +// method. +type GoogleCloudDiscoveryengineV1PurgeSuggestionDenyListEntriesResponse struct { + // ErrorSamples: A sample of errors encountered while processing the + // request. + ErrorSamples []*GoogleRpcStatus `json:"errorSamples,omitempty"` - // UserLabels: The user labels applied to a resource must meet the - // following requirements: * Each resource can have multiple labels, up - // to a maximum of 64. * Each label must be a key-value pair. * Keys - // have a minimum length of 1 character and a maximum length of 63 - // characters and cannot be empty. Values can be empty and have a - // maximum length of 63 characters. * Keys and values can contain only - // lowercase letters, numeric characters, underscores, and dashes. All - // characters must use UTF-8 encoding, and international characters are - // allowed. * The key portion of a label must be unique. However, you - // can use the same key with multiple resources. * Keys must start with - // a lowercase letter or international character. See Google Cloud - // Document - // (https://cloud.google.com/resource-manager/docs/creating-managing-labels#requirements) - // for more details. - UserLabels map[string]string `json:"userLabels,omitempty"` + // PurgeCount: Number of suggestion deny list entries purged. + PurgeCount int64 `json:"purgeCount,omitempty,string"` - // ForceSendFields is a list of field names (e.g. "Conversation") to + // ForceSendFields is a list of field names (e.g. "ErrorSamples") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -2106,7 +2184,7 @@ type GoogleCloudDiscoveryengineV1alphaConverseConversationRequest struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Conversation") to include + // NullFields is a list of field names (e.g. "ErrorSamples") to include // in API requests with the JSON null value. By default, fields with // empty values are omitted from API requests. However, any field with // an empty value appearing in NullFields will be sent to the server as @@ -2115,33 +2193,29 @@ type GoogleCloudDiscoveryengineV1alphaConverseConversationRequest struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaConverseConversationRequest) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaConverseConversationRequest +func (s *GoogleCloudDiscoveryengineV1PurgeSuggestionDenyListEntriesResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1PurgeSuggestionDenyListEntriesResponse raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaConverseConversationResponse: -// Response message for ConversationalSearchService.ConverseConversation -// method. -type GoogleCloudDiscoveryengineV1alphaConverseConversationResponse struct { - // Conversation: Updated conversation including the answer. - Conversation *GoogleCloudDiscoveryengineV1alphaConversation `json:"conversation,omitempty"` - - // RelatedQuestions: Suggested related questions. - RelatedQuestions []string `json:"relatedQuestions,omitempty"` - - // Reply: Answer to the current query. - Reply *GoogleCloudDiscoveryengineV1alphaReply `json:"reply,omitempty"` +// GoogleCloudDiscoveryengineV1Schema: Defines the structure and layout +// of a type of document data. +type GoogleCloudDiscoveryengineV1Schema struct { + // JsonSchema: The JSON representation of the schema. + JsonSchema string `json:"jsonSchema,omitempty"` - // SearchResults: Search Results. - SearchResults []*GoogleCloudDiscoveryengineV1alphaSearchResponseSearchResult `json:"searchResults,omitempty"` + // Name: Immutable. The full resource name of the schema, in the format + // of + // `projects/{project}/locations/{location}/collections/{collection}/data + // Stores/{data_store}/schemas/{schema}`. This field 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:"-"` + // StructSchema: The structured representation of the schema. + StructSchema googleapi.RawMessage `json:"structSchema,omitempty"` - // ForceSendFields is a list of field names (e.g. "Conversation") to + // ForceSendFields is a list of field names (e.g. "JsonSchema") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -2149,69 +2223,126 @@ type GoogleCloudDiscoveryengineV1alphaConverseConversationResponse struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Conversation") to include - // in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. However, any field with - // an empty value appearing in NullFields will be sent to the server as + // NullFields is a list of field names (e.g. "JsonSchema") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaConverseConversationResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaConverseConversationResponse +func (s *GoogleCloudDiscoveryengineV1Schema) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1Schema raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaCreateDataStoreMetadata: Metadata -// related to the progress of the DataStoreService.CreateDataStore -// operation. This will be returned by the -// google.longrunning.Operation.metadata field. -type GoogleCloudDiscoveryengineV1alphaCreateDataStoreMetadata struct { - // CreateTime: Operation create time. - CreateTime string `json:"createTime,omitempty"` +// GoogleCloudDiscoveryengineV1SiteVerificationInfo: Verification +// information for target sites in advanced site search. +type GoogleCloudDiscoveryengineV1SiteVerificationInfo struct { + // SiteVerificationState: Site verification state indicating the + // ownership and validity. + // + // Possible values: + // "SITE_VERIFICATION_STATE_UNSPECIFIED" - Defaults to VERIFIED. + // "VERIFIED" - Site ownership verified. + // "UNVERIFIED" - Site ownership pending verification or verification + // failed. + // "EXEMPTED" - Site exempt from verification, e.g., a public website + // that opens to all. + SiteVerificationState string `json:"siteVerificationState,omitempty"` - // UpdateTime: Operation last update time. If the operation is done, - // this is also the finish time. - UpdateTime string `json:"updateTime,omitempty"` + // VerifyTime: Latest site verification time. + VerifyTime string `json:"verifyTime,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. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. + // "SiteVerificationState") to unconditionally include in API requests. + // By default, fields with empty or default values are omitted from API + // requests. However, any non-pointer, non-interface field appearing in + // ForceSendFields will be sent to the server regardless of whether the + // field is empty or not. This may be used to include empty fields in + // Patch requests. 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. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "SiteVerificationState") to + // include in API requests with the JSON null value. By default, fields + // with empty values are omitted from API requests. However, any field + // with an empty value appearing in NullFields will be sent to the + // server as null. It is an error if a field in this list has a + // non-empty value. This may be used to include null fields in Patch + // requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaCreateDataStoreMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaCreateDataStoreMetadata +func (s *GoogleCloudDiscoveryengineV1SiteVerificationInfo) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1SiteVerificationInfo raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaCreateEngineMetadata: Metadata -// related to the progress of the EngineService.CreateEngine operation. -// This will be returned by the google.longrunning.Operation.metadata -// field. -type GoogleCloudDiscoveryengineV1alphaCreateEngineMetadata struct { - // CreateTime: Operation create time. - CreateTime string `json:"createTime,omitempty"` +// GoogleCloudDiscoveryengineV1TargetSite: A target site for the +// SiteSearchEngine. +type GoogleCloudDiscoveryengineV1TargetSite struct { + // ExactMatch: Input only. If set to false, a uri_pattern is generated + // to include all pages whose address contains the provided_uri_pattern. + // If set to true, an uri_pattern is generated to try to be an exact + // match of the provided_uri_pattern or just the specific page if the + // provided_uri_pattern is a specific one. provided_uri_pattern is + // always normalized to generate the URI pattern to be used by the + // search engine. + ExactMatch bool `json:"exactMatch,omitempty"` - // UpdateTime: Operation last update time. If the operation is done, - // this is also the finish time. + // FailureReason: Output only. Failure reason. + FailureReason *GoogleCloudDiscoveryengineV1TargetSiteFailureReason `json:"failureReason,omitempty"` + + // GeneratedUriPattern: Output only. This is system-generated based on + // the provided_uri_pattern. + GeneratedUriPattern string `json:"generatedUriPattern,omitempty"` + + // IndexingStatus: Output only. Indexing status. + // + // Possible values: + // "INDEXING_STATUS_UNSPECIFIED" - Defaults to SUCCEEDED. + // "PENDING" - The target site is in the update queue and will be + // picked up by indexing pipeline. + // "FAILED" - The target site fails to be indexed. + // "SUCCEEDED" - The target site has been indexed. + // "DELETING" - The previously indexed target site has been marked to + // be deleted. This is a transitioning state which will resulted in + // either: 1. target site deleted if unindexing is successful; 2. state + // reverts to SUCCEEDED if the unindexing fails. + IndexingStatus string `json:"indexingStatus,omitempty"` + + // Name: Output only. The fully qualified resource name of the target + // site. + // `projects/{project}/locations/{location}/collections/{collection}/data + // Stores/{data_store}/siteSearchEngine/targetSites/{target_site}` The + // `target_site_id` is system-generated. + Name string `json:"name,omitempty"` + + // ProvidedUriPattern: Required. Input only. The user provided URI + // pattern from which the `generated_uri_pattern` is generated. + ProvidedUriPattern string `json:"providedUriPattern,omitempty"` + + // SiteVerificationInfo: Output only. Site ownership and validity + // verification status. + SiteVerificationInfo *GoogleCloudDiscoveryengineV1SiteVerificationInfo `json:"siteVerificationInfo,omitempty"` + + // Type: The type of the target site, e.g., whether the site is to be + // included or excluded. + // + // Possible values: + // "TYPE_UNSPECIFIED" - This value is unused. In this case, server + // behavior defaults to Type.INCLUDE. + // "INCLUDE" - Include the target site. + // "EXCLUDE" - Exclude the target site. + Type string `json:"type,omitempty"` + + // UpdateTime: Output only. The target site's last updated time. UpdateTime string `json:"updateTime,omitempty"` - // ForceSendFields is a list of field names (e.g. "CreateTime") to + // ForceSendFields is a list of field names (e.g. "ExactMatch") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -2219,7 +2350,7 @@ type GoogleCloudDiscoveryengineV1alphaCreateEngineMetadata struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "CreateTime") to include in + // NullFields is a list of field names (e.g. "ExactMatch") to include in // API requests with the JSON null value. By default, fields with empty // values are omitted from API requests. However, any field with an // empty value appearing in NullFields will be sent to the server as @@ -2228,23 +2359,19 @@ type GoogleCloudDiscoveryengineV1alphaCreateEngineMetadata struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaCreateEngineMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaCreateEngineMetadata +func (s *GoogleCloudDiscoveryengineV1TargetSite) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1TargetSite raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaCreateSchemaMetadata: Metadata for -// Create Schema LRO. -type GoogleCloudDiscoveryengineV1alphaCreateSchemaMetadata 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"` +// GoogleCloudDiscoveryengineV1TargetSiteFailureReason: Site search +// indexing failure reasons. +type GoogleCloudDiscoveryengineV1TargetSiteFailureReason struct { + // QuotaFailure: Failed due to insufficient quota. + QuotaFailure *GoogleCloudDiscoveryengineV1TargetSiteFailureReasonQuotaFailure `json:"quotaFailure,omitempty"` - // ForceSendFields is a list of field names (e.g. "CreateTime") to + // ForceSendFields is a list of field names (e.g. "QuotaFailure") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -2252,68 +2379,61 @@ type GoogleCloudDiscoveryengineV1alphaCreateSchemaMetadata struct { // This may be used to include empty fields in Patch requests. 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. However, any field with an - // empty value appearing in NullFields will be sent to the server as + // NullFields is a list of field names (e.g. "QuotaFailure") to include + // in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. However, any field with + // an empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaCreateSchemaMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaCreateSchemaMetadata +func (s *GoogleCloudDiscoveryengineV1TargetSiteFailureReason) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1TargetSiteFailureReason raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaCreateTargetSiteMetadata: Metadata -// related to the progress of the -// SiteSearchEngineService.CreateTargetSite operation. This will be -// returned by the google.longrunning.Operation.metadata field. -type GoogleCloudDiscoveryengineV1alphaCreateTargetSiteMetadata 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"` +type GoogleCloudDiscoveryengineV1TargetSiteFailureReasonQuotaFailure struct { + // TotalRequiredQuota: This number is an estimation on how much total + // quota this project needs to successfully complete indexing. + TotalRequiredQuota int64 `json:"totalRequiredQuota,omitempty,string"` - // ForceSendFields is a list of field names (e.g. "CreateTime") to - // unconditionally include in API requests. By default, fields with + // ForceSendFields is a list of field names (e.g. "TotalRequiredQuota") + // to unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be // sent to the server regardless of whether the field is empty or not. // This may be used to include empty fields in Patch requests. 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. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "TotalRequiredQuota") to + // include in API requests with the JSON null value. By default, fields + // with empty values are omitted from API requests. However, any field + // with an empty value appearing in NullFields will be sent to the + // server as null. It is an error if a field in this list has a + // non-empty value. This may be used to include null fields in Patch + // requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaCreateTargetSiteMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaCreateTargetSiteMetadata +func (s *GoogleCloudDiscoveryengineV1TargetSiteFailureReasonQuotaFailure) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1TargetSiteFailureReasonQuotaFailure raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaCreateTargetSiteRequest: Request -// message for SiteSearchEngineService.CreateTargetSite method. -type GoogleCloudDiscoveryengineV1alphaCreateTargetSiteRequest struct { - // Parent: Required. Parent resource name of TargetSite, such as - // `projects/{project}/locations/{location}/collections/{collection}/data - // Stores/{data_store}/siteSearchEngine`. - Parent string `json:"parent,omitempty"` +// GoogleCloudDiscoveryengineV1UpdateSchemaMetadata: Metadata for +// UpdateSchema LRO. +type GoogleCloudDiscoveryengineV1UpdateSchemaMetadata struct { + // CreateTime: Operation create time. + CreateTime string `json:"createTime,omitempty"` - // TargetSite: Required. The TargetSite to create. - TargetSite *GoogleCloudDiscoveryengineV1alphaTargetSite `json:"targetSite,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. "Parent") to + // 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. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -2321,8 +2441,8 @@ type GoogleCloudDiscoveryengineV1alphaCreateTargetSiteRequest struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Parent") to include in API - // requests with the JSON null value. By default, fields with empty + // 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. However, any field with an // empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. @@ -2330,29 +2450,25 @@ type GoogleCloudDiscoveryengineV1alphaCreateTargetSiteRequest struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaCreateTargetSiteRequest) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaCreateTargetSiteRequest +func (s *GoogleCloudDiscoveryengineV1UpdateSchemaMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1UpdateSchemaMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaCustomAttribute: A custom attribute -// that is not explicitly modeled in a resource, e.g. UserEvent. -type GoogleCloudDiscoveryengineV1alphaCustomAttribute struct { - // Numbers: The numerical values of this custom attribute. For example, - // `[2.3, 15.4]` when the key is "lengths_cm". Exactly one of - // CustomAttribute.text or CustomAttribute.numbers should be set. - // Otherwise, an `INVALID_ARGUMENT` error is returned. - Numbers []float64 `json:"numbers,omitempty"` +// GoogleCloudDiscoveryengineV1UpdateTargetSiteMetadata: Metadata +// related to the progress of the +// SiteSearchEngineService.UpdateTargetSite operation. This will be +// returned by the google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1UpdateTargetSiteMetadata struct { + // CreateTime: Operation create time. + CreateTime string `json:"createTime,omitempty"` - // Text: The textual values of this custom attribute. For example, - // `["yellow", "green"]` when the key is "color". Empty string is not - // allowed. Otherwise, an `INVALID_ARGUMENT` error is returned. Exactly - // one of CustomAttribute.text or CustomAttribute.numbers should be set. - // Otherwise, an `INVALID_ARGUMENT` error is returned. - Text []string `json:"text,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. "Numbers") to + // 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. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -2360,7 +2476,7 @@ type GoogleCloudDiscoveryengineV1alphaCustomAttribute struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Numbers") to include in + // 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. However, any field with an // empty value appearing in NullFields will be sent to the server as @@ -2369,92 +2485,20 @@ type GoogleCloudDiscoveryengineV1alphaCustomAttribute struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaCustomAttribute) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaCustomAttribute +func (s *GoogleCloudDiscoveryengineV1UpdateTargetSiteMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1UpdateTargetSiteMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -func (s *GoogleCloudDiscoveryengineV1alphaCustomAttribute) UnmarshalJSON(data []byte) error { - type NoMethod GoogleCloudDiscoveryengineV1alphaCustomAttribute - var s1 struct { - Numbers []gensupport.JSONFloat64 `json:"numbers"` - *NoMethod - } - s1.NoMethod = (*NoMethod)(s) - if err := json.Unmarshal(data, &s1); err != nil { - return err - } - s.Numbers = make([]float64, len(s1.Numbers)) - for i := range s1.Numbers { - s.Numbers[i] = float64(s1.Numbers[i]) - } - return nil -} - -// GoogleCloudDiscoveryengineV1alphaDataStore: DataStore captures global -// settings and configs at the DataStore level. -type GoogleCloudDiscoveryengineV1alphaDataStore struct { - // ContentConfig: Immutable. The content config of the data store. If - // this field is unset, the server behavior defaults to - // ContentConfig.NO_CONTENT. - // - // Possible values: - // "CONTENT_CONFIG_UNSPECIFIED" - Default value. - // "NO_CONTENT" - Only contains documents without any - // Document.content. - // "CONTENT_REQUIRED" - Only contains documents with Document.content. - // "PUBLIC_WEBSITE" - The data store is used for public website - // search. - ContentConfig string `json:"contentConfig,omitempty"` - - // CreateTime: Output only. Timestamp the DataStore was created at. - CreateTime string `json:"createTime,omitempty"` - - // DefaultSchemaId: Output only. The id of the default Schema - // asscociated to this data store. - DefaultSchemaId string `json:"defaultSchemaId,omitempty"` - - // DisplayName: Required. The data store display name. This field must - // be a UTF-8 encoded string with a length limit of 128 characters. - // Otherwise, an INVALID_ARGUMENT error is returned. - DisplayName string `json:"displayName,omitempty"` - - // IndustryVertical: Immutable. The industry vertical that the data - // store registers. - // - // Possible values: - // "INDUSTRY_VERTICAL_UNSPECIFIED" - Value used when unset. - // "GENERIC" - The generic vertical for documents that are not - // specific to any industry vertical. - // "MEDIA" - The media industry vertical. - IndustryVertical string `json:"industryVertical,omitempty"` - - // Name: Immutable. The full resource name of the data store. Format: - // `projects/{project}/locations/{location}/collections/{collection_id}/d - // ataStores/{data_store_id}`. This field must be a UTF-8 encoded string - // with a length limit of 1024 characters. - Name string `json:"name,omitempty"` - - // SolutionTypes: The solutions that the data store enrolls. Available - // solutions for each industry_vertical: * `MEDIA`: - // `SOLUTION_TYPE_RECOMMENDATION` and `SOLUTION_TYPE_SEARCH`. * - // `SITE_SEARCH`: `SOLUTION_TYPE_SEARCH` is automatically enrolled. - // Other solutions cannot be enrolled. - // - // Possible values: - // "SOLUTION_TYPE_UNSPECIFIED" - Default value. - // "SOLUTION_TYPE_RECOMMENDATION" - Used for Recommendations AI. - // "SOLUTION_TYPE_SEARCH" - Used for Discovery Search. - // "SOLUTION_TYPE_CHAT" - Used for use cases related to the Generative - // AI agent. - SolutionTypes []string `json:"solutionTypes,omitempty"` - - // ServerResponse contains the HTTP response code and headers from the - // server. - googleapi.ServerResponse `json:"-"` +// GoogleCloudDiscoveryengineV1alphaAdditionalParams: AdditionalParams +// message for WidgetService methods for security and privacy +// enhancement. +type GoogleCloudDiscoveryengineV1alphaAdditionalParams struct { + // Token: Token that used for non-human user check. + Token string `json:"token,omitempty"` - // ForceSendFields is a list of field names (e.g. "ContentConfig") to + // ForceSendFields is a list of field names (e.g. "Token") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -2462,26 +2506,26 @@ type GoogleCloudDiscoveryengineV1alphaDataStore struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "ContentConfig") to include - // in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. However, any field with - // an empty value appearing in NullFields will be sent to the server as + // NullFields is a list of field names (e.g. "Token") to include in API + // requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaDataStore) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaDataStore +func (s *GoogleCloudDiscoveryengineV1alphaAdditionalParams) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaAdditionalParams raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaDeleteDataStoreMetadata: Metadata -// related to the progress of the DataStoreService.DeleteDataStore -// operation. This will be returned by the -// google.longrunning.Operation.metadata field. -type GoogleCloudDiscoveryengineV1alphaDeleteDataStoreMetadata struct { +// GoogleCloudDiscoveryengineV1alphaBatchCreateTargetSiteMetadata: +// Metadata related to the progress of the +// SiteSearchEngineService.BatchCreateTargetSites operation. This will +// be returned by the google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1alphaBatchCreateTargetSiteMetadata struct { // CreateTime: Operation create time. CreateTime string `json:"createTime,omitempty"` @@ -2506,25 +2550,21 @@ type GoogleCloudDiscoveryengineV1alphaDeleteDataStoreMetadata struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaDeleteDataStoreMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaDeleteDataStoreMetadata +func (s *GoogleCloudDiscoveryengineV1alphaBatchCreateTargetSiteMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaBatchCreateTargetSiteMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaDeleteEngineMetadata: Metadata -// related to the progress of the EngineService.DeleteEngine operation. -// This will be returned by the google.longrunning.Operation.metadata -// field. -type GoogleCloudDiscoveryengineV1alphaDeleteEngineMetadata 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"` +// GoogleCloudDiscoveryengineV1alphaBatchCreateTargetSitesRequest: +// Request message for SiteSearchEngineService.BatchCreateTargetSites +// method. +type GoogleCloudDiscoveryengineV1alphaBatchCreateTargetSitesRequest struct { + // Requests: Required. The request message specifying the resources to + // create. A maximum of 20 TargetSites can be created in a batch. + Requests []*GoogleCloudDiscoveryengineV1alphaCreateTargetSiteRequest `json:"requests,omitempty"` - // ForceSendFields is a list of field names (e.g. "CreateTime") to + // 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. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -2532,7 +2572,7 @@ type GoogleCloudDiscoveryengineV1alphaDeleteEngineMetadata struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "CreateTime") to include in + // 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. However, any field with an // empty value appearing in NullFields will be sent to the server as @@ -2541,23 +2581,20 @@ type GoogleCloudDiscoveryengineV1alphaDeleteEngineMetadata struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaDeleteEngineMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaDeleteEngineMetadata +func (s *GoogleCloudDiscoveryengineV1alphaBatchCreateTargetSitesRequest) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaBatchCreateTargetSitesRequest raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaDeleteSchemaMetadata: Metadata for -// DeleteSchema LRO. -type GoogleCloudDiscoveryengineV1alphaDeleteSchemaMetadata 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"` +// GoogleCloudDiscoveryengineV1alphaBatchCreateTargetSitesResponse: +// Response message for SiteSearchEngineService.BatchCreateTargetSites +// method. +type GoogleCloudDiscoveryengineV1alphaBatchCreateTargetSitesResponse struct { + // TargetSites: TargetSites created. + TargetSites []*GoogleCloudDiscoveryengineV1alphaTargetSite `json:"targetSites,omitempty"` - // ForceSendFields is a list of field names (e.g. "CreateTime") to + // ForceSendFields is a list of field names (e.g. "TargetSites") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -2565,34 +2602,64 @@ type GoogleCloudDiscoveryengineV1alphaDeleteSchemaMetadata struct { // This may be used to include empty fields in Patch requests. 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. However, any field with an - // empty value appearing in NullFields will be sent to the server as + // NullFields is a list of field names (e.g. "TargetSites") to include + // in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. However, any field with + // an empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaDeleteSchemaMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaDeleteSchemaMetadata +func (s *GoogleCloudDiscoveryengineV1alphaBatchCreateTargetSitesResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaBatchCreateTargetSitesResponse raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaDeleteTargetSiteMetadata: Metadata -// related to the progress of the -// SiteSearchEngineService.DeleteTargetSite operation. This will be -// returned by the google.longrunning.Operation.metadata field. -type GoogleCloudDiscoveryengineV1alphaDeleteTargetSiteMetadata struct { - // CreateTime: Operation create time. - CreateTime string `json:"createTime,omitempty"` +// GoogleCloudDiscoveryengineV1alphaBatchVerifyTargetSitesRequest: +// Request message for SiteSearchEngineService.BatchVerifyTargetSites +// method. +type GoogleCloudDiscoveryengineV1alphaBatchVerifyTargetSitesRequest struct { +} - // UpdateTime: Operation last update time. If the operation is done, - // this is also the finish time. - UpdateTime string `json:"updateTime,omitempty"` +// GoogleCloudDiscoveryengineV1alphaBigQuerySource: BigQuery source +// import data from. +type GoogleCloudDiscoveryengineV1alphaBigQuerySource struct { + // DataSchema: The schema to use when parsing the data from the source. + // Supported values for user event imports: * `user_event` (default): + // One UserEvent per row. Supported values for document imports: * + // `document` (default): One Document format per row. Each document must + // have a valid Document.id and one of Document.json_data or + // Document.struct_data. * `custom`: One custom data per row in + // arbitrary format that conforms to the defined Schema of the data + // store. This can only be used by Gen App Builder. + DataSchema string `json:"dataSchema,omitempty"` - // ForceSendFields is a list of field names (e.g. "CreateTime") to + // DatasetId: Required. The BigQuery data set to copy the data from with + // a length limit of 1,024 characters. + DatasetId string `json:"datasetId,omitempty"` + + // GcsStagingDir: Intermediate Cloud Storage directory used for the + // import with a length limit of 2,000 characters. Can be specified if + // one wants to have the BigQuery export to a specific Cloud Storage + // directory. + GcsStagingDir string `json:"gcsStagingDir,omitempty"` + + // PartitionDate: BigQuery time partitioned table's _PARTITIONDATE in + // YYYY-MM-DD format. + PartitionDate *GoogleTypeDate `json:"partitionDate,omitempty"` + + // ProjectId: The project ID (can be project # or ID) that the BigQuery + // source is in with a length limit of 128 characters. If not specified, + // inherits the project ID from the parent request. + ProjectId string `json:"projectId,omitempty"` + + // TableId: Required. The BigQuery table to copy the data from with a + // length limit of 1,024 characters. + TableId string `json:"tableId,omitempty"` + + // ForceSendFields is a list of field names (e.g. "DataSchema") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -2600,7 +2667,7 @@ type GoogleCloudDiscoveryengineV1alphaDeleteTargetSiteMetadata struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "CreateTime") to include in + // NullFields is a list of field names (e.g. "DataSchema") to include in // API requests with the JSON null value. By default, fields with empty // values are omitted from API requests. However, any field with an // empty value appearing in NullFields will be sent to the server as @@ -2609,25 +2676,57 @@ type GoogleCloudDiscoveryengineV1alphaDeleteTargetSiteMetadata struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaDeleteTargetSiteMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaDeleteTargetSiteMetadata +func (s *GoogleCloudDiscoveryengineV1alphaBigQuerySource) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaBigQuerySource raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaDisableAdvancedSiteSearchMetadata: -// Metadata related to the progress of the -// SiteSearchEngineService.DisableAdvancedSiteSearch operation. This -// will be returned by the google.longrunning.Operation.metadata field. -type GoogleCloudDiscoveryengineV1alphaDisableAdvancedSiteSearchMetadata struct { - // CreateTime: Operation create time. - CreateTime string `json:"createTime,omitempty"` +// GoogleCloudDiscoveryengineV1alphaCompleteQueryRequest: Request +// message for CompletionService.CompleteQuery method. +type GoogleCloudDiscoveryengineV1alphaCompleteQueryRequest struct { + // DataStore: Required. The parent data store resource name for which + // the completion is performed, such as + // `projects/*/locations/global/collections/default_collection/dataStores + // /default_data_store`. + DataStore string `json:"dataStore,omitempty"` - // UpdateTime: Operation last update time. If the operation is done, - // this is also the finish time. - UpdateTime string `json:"updateTime,omitempty"` + // IncludeTailSuggestions: Indicates if tail suggestions should be + // returned if there are no suggestions that match the full query. Even + // if set to true, if there are suggestions that match the full query, + // those are returned and no tail suggestions are returned. + IncludeTailSuggestions bool `json:"includeTailSuggestions,omitempty"` - // ForceSendFields is a list of field names (e.g. "CreateTime") to + // Query: Required. The typeahead input used to fetch suggestions. + // Maximum length is 128 characters. + Query string `json:"query,omitempty"` + + // QueryModel: Specifies the autocomplete data model. This overrides any + // model specified in the Configuration > Autocomplete section of the + // Cloud console. Currently supported values: * `document` - Using + // suggestions generated from user-imported documents. * + // `search-history` - Using suggestions generated from the past history + // of SearchService.Search API calls. Do not use it when there is no + // traffic for Search API. * `user-event` - Using suggestions generated + // from user-imported search events. * `document-completable` - Using + // suggestions taken directly from user-imported document fields marked + // as completable. Default values: * `document` is the default model for + // regular dataStores. * `search-history` is the default model for site + // search dataStores. + QueryModel string `json:"queryModel,omitempty"` + + // UserPseudoId: A unique identifier for tracking visitors. For example, + // this could be implemented with an HTTP cookie, which should be able + // to uniquely identify a visitor on a single device. This unique + // identifier should not change if the visitor logs in or out of the + // website. This field should NOT have a fixed value such as + // `unknown_visitor`. This should be the same identifier as + // UserEvent.user_pseudo_id and SearchRequest.user_pseudo_id. The field + // must be a UTF-8 encoded string with a length limit of 128 characters. + // Otherwise, an `INVALID_ARGUMENT` error is returned. + UserPseudoId string `json:"userPseudoId,omitempty"` + + // ForceSendFields is a list of field names (e.g. "DataStore") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -2635,7 +2734,7 @@ type GoogleCloudDiscoveryengineV1alphaDisableAdvancedSiteSearchMetadata struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "CreateTime") to include in + // NullFields is a list of field names (e.g. "DataStore") to include in // API requests with the JSON null value. By default, fields with empty // values are omitted from API requests. However, any field with an // empty value appearing in NullFields will be sent to the server as @@ -2644,72 +2743,30 @@ type GoogleCloudDiscoveryengineV1alphaDisableAdvancedSiteSearchMetadata struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaDisableAdvancedSiteSearchMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaDisableAdvancedSiteSearchMetadata +func (s *GoogleCloudDiscoveryengineV1alphaCompleteQueryRequest) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaCompleteQueryRequest raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaDisableAdvancedSiteSearchRequest: -// Request message for SiteSearchEngineService.DisableAdvancedSiteSearch -// method. -type GoogleCloudDiscoveryengineV1alphaDisableAdvancedSiteSearchRequest struct { -} - -// GoogleCloudDiscoveryengineV1alphaDisableAdvancedSiteSearchResponse: -// Response message for -// SiteSearchEngineService.DisableAdvancedSiteSearch method. -type GoogleCloudDiscoveryengineV1alphaDisableAdvancedSiteSearchResponse struct { -} - -// GoogleCloudDiscoveryengineV1alphaDocument: Document captures all raw -// metadata information of items to be recommended or searched. -type GoogleCloudDiscoveryengineV1alphaDocument struct { - // Content: The unstructured data linked to this document. Content must - // be set if this document is under a `CONTENT_REQUIRED` data store. - Content *GoogleCloudDiscoveryengineV1alphaDocumentContent `json:"content,omitempty"` - - // DerivedStructData: Output only. This field is OUTPUT_ONLY. It - // contains derived data that are not in the original input document. - DerivedStructData googleapi.RawMessage `json:"derivedStructData,omitempty"` - - // Id: Immutable. The identifier of the document. Id should conform to - // RFC-1034 (https://tools.ietf.org/html/rfc1034) standard with a length - // limit of 63 characters. - Id string `json:"id,omitempty"` - - // JsonData: The JSON string representation of the document. It should - // conform to the registered Schema or an `INVALID_ARGUMENT` error is - // thrown. - JsonData string `json:"jsonData,omitempty"` - - // Name: Immutable. The full resource name of the document. Format: - // `projects/{project}/locations/{location}/collections/{collection}/data - // Stores/{data_store}/branches/{branch}/documents/{document_id}`. This - // field must be a UTF-8 encoded string with a length limit of 1024 - // characters. - Name string `json:"name,omitempty"` - - // ParentDocumentId: The identifier of the parent document. Currently - // supports at most two level document hierarchy. Id should conform to - // RFC-1034 (https://tools.ietf.org/html/rfc1034) standard with a length - // limit of 63 characters. - ParentDocumentId string `json:"parentDocumentId,omitempty"` - - // SchemaId: The identifier of the schema located in the same data - // store. - SchemaId string `json:"schemaId,omitempty"` +// GoogleCloudDiscoveryengineV1alphaCompleteQueryResponse: Response +// message for CompletionService.CompleteQuery method. +type GoogleCloudDiscoveryengineV1alphaCompleteQueryResponse struct { + // QuerySuggestions: Results of the matched query suggestions. The + // result list is ordered and the first result is a top suggestion. + QuerySuggestions []*GoogleCloudDiscoveryengineV1alphaCompleteQueryResponseQuerySuggestion `json:"querySuggestions,omitempty"` - // StructData: The structured JSON data for the document. It should - // conform to the registered Schema or an `INVALID_ARGUMENT` error is - // thrown. - StructData googleapi.RawMessage `json:"structData,omitempty"` + // TailMatchTriggered: True if the returned suggestions are all tail + // suggestions. For tail matching to be triggered, + // include_tail_suggestions in the request must be true and there must + // be no suggestions that match the full query. + TailMatchTriggered bool `json:"tailMatchTriggered,omitempty"` // ServerResponse contains the HTTP response code and headers from the // server. googleapi.ServerResponse `json:"-"` - // ForceSendFields is a list of field names (e.g. "Content") to + // ForceSendFields is a list of field names (e.g. "QuerySuggestions") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -2717,97 +2774,74 @@ type GoogleCloudDiscoveryengineV1alphaDocument struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Content") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "QuerySuggestions") to + // include in API requests with the JSON null value. By default, fields + // with empty values are omitted from API requests. However, any field + // with an empty value appearing in NullFields will be sent to the + // server as null. It is an error if a field in this list has a + // non-empty value. This may be used to include null fields in Patch + // requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaDocument) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaDocument +func (s *GoogleCloudDiscoveryengineV1alphaCompleteQueryResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaCompleteQueryResponse raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaDocumentContent: Unstructured data -// linked to this document. -type GoogleCloudDiscoveryengineV1alphaDocumentContent struct { - // MimeType: The MIME type of the content. Supported types: * - // `application/pdf` (PDF, only native PDFs are supported for now) * - // `text/html` (HTML) * - // `application/vnd.openxmlformats-officedocument.wordprocessingml.docume - // nt` (DOCX) * - // `application/vnd.openxmlformats-officedocument.presentationml.presenta - // tion` (PPTX) * `text/plain` (TXT) See - // https://www.iana.org/assignments/media-types/media-types.xhtml. - MimeType string `json:"mimeType,omitempty"` - - // RawBytes: The content represented as a stream of bytes. The maximum - // length is 1,000,000 bytes (1 MB / ~0.95 MiB). Note: As with all - // `bytes` fields, this field is represented as pure binary in Protocol - // Buffers and base64-encoded string in JSON. For example, - // `abc123!?$*&()'-=@~` should be represented as - // `YWJjMTIzIT8kKiYoKSctPUB+` in JSON. See - // https://developers.google.com/protocol-buffers/docs/proto3#json. - RawBytes string `json:"rawBytes,omitempty"` +// GoogleCloudDiscoveryengineV1alphaCompleteQueryResponseQuerySuggestion: +// +// Suggestions as search queries. +type GoogleCloudDiscoveryengineV1alphaCompleteQueryResponseQuerySuggestion struct { + // CompletableFieldPaths: The unique document field paths that serve as + // the source of this suggestion if it was generated from completable + // fields. This field is only populated for the document-completable + // model. + CompletableFieldPaths []string `json:"completableFieldPaths,omitempty"` - // Uri: The URI of the content. Only Cloud Storage URIs (e.g. - // `gs://bucket-name/path/to/file`) are supported. The maximum file size - // is 2.5 MB for text-based formats, 100 MB for other formats. - Uri string `json:"uri,omitempty"` + // Suggestion: The suggestion for the query. + Suggestion string `json:"suggestion,omitempty"` - // ForceSendFields is a list of field names (e.g. "MimeType") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. + // "CompletableFieldPaths") to unconditionally include in API requests. + // By default, fields with empty or default values are omitted from API + // requests. However, any non-pointer, non-interface field appearing in + // ForceSendFields will be sent to the server regardless of whether the + // field is empty or not. This may be used to include empty fields in + // Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "MimeType") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "CompletableFieldPaths") to + // include in API requests with the JSON null value. By default, fields + // with empty values are omitted from API requests. However, any field + // with an empty value appearing in NullFields will be sent to the + // server as null. It is an error if a field in this list has a + // non-empty value. This may be used to include null fields in Patch + // requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaDocumentContent) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaDocumentContent +func (s *GoogleCloudDiscoveryengineV1alphaCompleteQueryResponseQuerySuggestion) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaCompleteQueryResponseQuerySuggestion raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaDocumentInfo: Detailed document -// information associated with a user event. -type GoogleCloudDiscoveryengineV1alphaDocumentInfo struct { - // Id: The Document resource ID. - Id string `json:"id,omitempty"` - - // Name: The Document resource full name, of the form: - // `projects/{project_id}/locations/{location}/collections/{collection_id - // }/dataStores/{data_store_id}/branches/{branch_id}/documents/{document_ - // id}` - Name string `json:"name,omitempty"` - - // PromotionIds: The promotion IDs associated with this Document. - // Currently, this field is restricted to at most one ID. - PromotionIds []string `json:"promotionIds,omitempty"` - - // Quantity: Quantity of the Document associated with the user event. - // Defaults to 1. For example, this field will be 2 if two quantities of - // the same Document are involved in a `add-to-cart` event. Required for - // events of the following event types: * `add-to-cart` * `purchase` - Quantity int64 `json:"quantity,omitempty"` +// GoogleCloudDiscoveryengineV1alphaCompletionInfo: Detailed completion +// information including completion attribution token and clicked +// completion info. +type GoogleCloudDiscoveryengineV1alphaCompletionInfo struct { + // SelectedPosition: End user selected + // CompleteQueryResponse.QuerySuggestion.suggestion position, starting + // from 0. + SelectedPosition int64 `json:"selectedPosition,omitempty"` - // Uri: The Document URI - only allowed for website data stores. - Uri string `json:"uri,omitempty"` + // SelectedSuggestion: End user selected + // CompleteQueryResponse.QuerySuggestion.suggestion. + SelectedSuggestion string `json:"selectedSuggestion,omitempty"` - // ForceSendFields is a list of field names (e.g. "Id") to + // ForceSendFields is a list of field names (e.g. "SelectedPosition") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -2815,41 +2849,57 @@ type GoogleCloudDiscoveryengineV1alphaDocumentInfo struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Id") to include in API - // requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "SelectedPosition") to + // include in API requests with the JSON null value. By default, fields + // with empty values are omitted from API requests. However, any field + // with an empty value appearing in NullFields will be sent to the + // server as null. It is an error if a field in this list has a + // non-empty value. This may be used to include null fields in Patch + // requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaDocumentInfo) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaDocumentInfo +func (s *GoogleCloudDiscoveryengineV1alphaCompletionInfo) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaCompletionInfo raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaDocumentProcessingConfig: A -// singleton resource of DataStore. It's empty when DataStore is -// created, which defaults to digital parser. The first call to -// DataStoreService.UpdateDocumentProcessingConfig method will -// initialize the config. -type GoogleCloudDiscoveryengineV1alphaDocumentProcessingConfig struct { - // Name: Output only. The full resource name of the Document Processing - // Config. Format: - // `projects/*/locations/*/collections/*/dataStores/*/documentProcessingC - // onfig`. +// GoogleCloudDiscoveryengineV1alphaConversation: External conversation +// proto definition. +type GoogleCloudDiscoveryengineV1alphaConversation struct { + // EndTime: Output only. The time the conversation finished. + EndTime string `json:"endTime,omitempty"` + + // Messages: Conversation messages. + Messages []*GoogleCloudDiscoveryengineV1alphaConversationMessage `json:"messages,omitempty"` + + // Name: Immutable. Fully qualified name + // `project/*/locations/global/collections/{collection}/dataStore/*/conve + // rsations/*` or + // `project/*/locations/global/collections/{collection}/engines/*/convers + // ations/*`. Name string `json:"name,omitempty"` - // OcrConfig: The OCR config. Currently it only applies to PDFs. - OcrConfig *GoogleCloudDiscoveryengineV1alphaOcrConfig `json:"ocrConfig,omitempty"` + // StartTime: Output only. The time the conversation started. + StartTime string `json:"startTime,omitempty"` + + // State: The state of the Conversation. + // + // Possible values: + // "STATE_UNSPECIFIED" - Unknown. + // "IN_PROGRESS" - Conversation is currently open. + // "COMPLETED" - Conversation has been completed. + State string `json:"state,omitempty"` + + // UserPseudoId: A unique identifier for tracking users. + UserPseudoId string `json:"userPseudoId,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 + // 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. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -2857,8 +2907,8 @@ type GoogleCloudDiscoveryengineV1alphaDocumentProcessingConfig struct { // This may be used to include empty fields in Patch requests. 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 + // 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. However, any field with an // empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. @@ -2866,18 +2916,24 @@ type GoogleCloudDiscoveryengineV1alphaDocumentProcessingConfig struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaDocumentProcessingConfig) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaDocumentProcessingConfig +func (s *GoogleCloudDiscoveryengineV1alphaConversation) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaConversation raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaDoubleList: Double list. -type GoogleCloudDiscoveryengineV1alphaDoubleList struct { - // Values: Double values. - Values []float64 `json:"values,omitempty"` +// GoogleCloudDiscoveryengineV1alphaConversationContext: Defines context +// of the conversation +type GoogleCloudDiscoveryengineV1alphaConversationContext struct { + // ActiveDocument: The current active document the user opened. It + // contains the document resource reference. + ActiveDocument string `json:"activeDocument,omitempty"` - // ForceSendFields is a list of field names (e.g. "Values") to + // ContextDocuments: The current list of documents the user is seeing. + // It contains the document resource references. + ContextDocuments []string `json:"contextDocuments,omitempty"` + + // ForceSendFields is a list of field names (e.g. "ActiveDocument") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -2885,49 +2941,33 @@ type GoogleCloudDiscoveryengineV1alphaDoubleList struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Values") to include in API - // requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "ActiveDocument") to + // include in API requests with the JSON null value. By default, fields + // with empty values are omitted from API requests. However, any field + // with an empty value appearing in NullFields will be sent to the + // server as null. It is an error if a field in this list has a + // non-empty value. This may be used to include null fields in Patch + // requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaDoubleList) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaDoubleList +func (s *GoogleCloudDiscoveryengineV1alphaConversationContext) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaConversationContext raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -func (s *GoogleCloudDiscoveryengineV1alphaDoubleList) UnmarshalJSON(data []byte) error { - type NoMethod GoogleCloudDiscoveryengineV1alphaDoubleList - var s1 struct { - Values []gensupport.JSONFloat64 `json:"values"` - *NoMethod - } - s1.NoMethod = (*NoMethod)(s) - if err := json.Unmarshal(data, &s1); err != nil { - return err - } - s.Values = make([]float64, len(s1.Values)) - for i := range s1.Values { - s.Values[i] = float64(s1.Values[i]) - } - return nil -} - -// GoogleCloudDiscoveryengineV1alphaEnableAdvancedSiteSearchMetadata: -// Metadata related to the progress of the -// SiteSearchEngineService.EnableAdvancedSiteSearch operation. This will -// be returned by the google.longrunning.Operation.metadata field. -type GoogleCloudDiscoveryengineV1alphaEnableAdvancedSiteSearchMetadata struct { - // CreateTime: Operation create time. +// GoogleCloudDiscoveryengineV1alphaConversationMessage: Defines a +// conversation message. +type GoogleCloudDiscoveryengineV1alphaConversationMessage struct { + // CreateTime: Output only. Message creation timestamp. 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"` + // Reply: Search reply. + Reply *GoogleCloudDiscoveryengineV1alphaReply `json:"reply,omitempty"` + + // UserInput: User text input. + UserInput *GoogleCloudDiscoveryengineV1alphaTextInput `json:"userInput,omitempty"` // ForceSendFields is a list of field names (e.g. "CreateTime") to // unconditionally include in API requests. By default, fields with @@ -2946,114 +2986,122 @@ type GoogleCloudDiscoveryengineV1alphaEnableAdvancedSiteSearchMetadata struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaEnableAdvancedSiteSearchMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaEnableAdvancedSiteSearchMetadata +func (s *GoogleCloudDiscoveryengineV1alphaConversationMessage) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaConversationMessage raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaEnableAdvancedSiteSearchRequest: -// Request message for SiteSearchEngineService.EnableAdvancedSiteSearch -// method. -type GoogleCloudDiscoveryengineV1alphaEnableAdvancedSiteSearchRequest struct { -} - -// GoogleCloudDiscoveryengineV1alphaEnableAdvancedSiteSearchResponse: -// Response message for SiteSearchEngineService.EnableAdvancedSiteSearch -// method. -type GoogleCloudDiscoveryengineV1alphaEnableAdvancedSiteSearchResponse struct { -} +// GoogleCloudDiscoveryengineV1alphaConverseConversationRequest: Request +// message for ConversationalSearchService.ConverseConversation method. +type GoogleCloudDiscoveryengineV1alphaConverseConversationRequest struct { + // Conversation: The conversation to be used by auto session only. The + // name field will be ignored as we automatically assign new name for + // the conversation in auto session. + Conversation *GoogleCloudDiscoveryengineV1alphaConversation `json:"conversation,omitempty"` -// GoogleCloudDiscoveryengineV1alphaEngine: Metadata that describes the -// training and serving parameters of an Engine. -type GoogleCloudDiscoveryengineV1alphaEngine struct { - // ChatEngineConfig: Configurations for the Chat Engine. Only applicable - // if solution_type is SOLUTION_TYPE_CHAT. - ChatEngineConfig *GoogleCloudDiscoveryengineV1alphaEngineChatEngineConfig `json:"chatEngineConfig,omitempty"` + // Filter: 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. This will be + // used to filter search results which may affect the summary response. + // 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 --> 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) + Filter string `json:"filter,omitempty"` - // ChatEngineMetadata: Output only. Additional information of the Chat - // Engine. Only applicable if solution_type is SOLUTION_TYPE_CHAT. - ChatEngineMetadata *GoogleCloudDiscoveryengineV1alphaEngineChatEngineMetadata `json:"chatEngineMetadata,omitempty"` + // Name: Required. The resource name of the Conversation to get. Format: + // `projects/{project_number}/locations/{location_id}/collections/{collec + // tion}/dataStores/{data_store_id}/conversations/{conversation_id}`. + // Use + // `projects/{project_number}/locations/{location_id}/collections/{collec + // tion}/dataStores/{data_store_id}/conversations/-` to activate auto + // session mode, which automatically creates a new conversation inside a + // ConverseConversation session. + Name string `json:"name,omitempty"` - // CommonConfig: Common config spec that specifies the metadata of the - // engine. - CommonConfig *GoogleCloudDiscoveryengineV1alphaEngineCommonConfig `json:"commonConfig,omitempty"` + // Query: Required. Current user input. + Query *GoogleCloudDiscoveryengineV1alphaTextInput `json:"query,omitempty"` - // CreateTime: Output only. Timestamp the Recommendation Engine was - // created at. - CreateTime string `json:"createTime,omitempty"` + // SafeSearch: Whether to turn on safe search. + SafeSearch bool `json:"safeSearch,omitempty"` - // DataStoreIds: The data stores associated with this engine. For - // SOLUTION_TYPE_SEARCH and SOLUTION_TYPE_RECOMMENDATION type of - // engines, they can only associate with at most one data store. If - // solution_type is SOLUTION_TYPE_CHAT, multiple DataStores in the same - // Collection can be associated here. Note that when used in - // CreateEngineRequest, one DataStore id must be provided as the system - // will use it for necessary intializations. - DataStoreIds []string `json:"dataStoreIds,omitempty"` + // ServingConfig: The resource name of the Serving Config to use. + // Format: + // `projects/{project_number}/locations/{location_id}/collections/{collec + // tion}/dataStores/{data_store_id}/servingConfigs/{serving_config_id}` + // If this is not set, the default serving config will be used. + ServingConfig string `json:"servingConfig,omitempty"` - // DisplayName: Required. The display name of the engine. Should be - // human readable. UTF-8 encoded string with limit of 1024 characters. - DisplayName string `json:"displayName,omitempty"` + // SummarySpec: A specification for configuring the summary returned in + // the response. + SummarySpec *GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSummarySpec `json:"summarySpec,omitempty"` - // IndustryVertical: The industry vertical that the engine registers. - // The restriction of the Engine industry vertical is based on - // DataStore: If unspecified, default to `GENERIC`. Vertical on Engine - // has to match vertical of the DataStore liniked to the engine. - // - // Possible values: - // "INDUSTRY_VERTICAL_UNSPECIFIED" - Value used when unset. - // "GENERIC" - The generic vertical for documents that are not - // specific to any industry vertical. - // "MEDIA" - The media industry vertical. - IndustryVertical string `json:"industryVertical,omitempty"` + // UserLabels: The user labels applied to a resource must meet the + // following requirements: * Each resource can have multiple labels, up + // to a maximum of 64. * Each label must be a key-value pair. * Keys + // have a minimum length of 1 character and a maximum length of 63 + // characters and cannot be empty. Values can be empty and have a + // maximum length of 63 characters. * Keys and values can contain only + // lowercase letters, numeric characters, underscores, and dashes. All + // characters must use UTF-8 encoding, and international characters are + // allowed. * The key portion of a label must be unique. However, you + // can use the same key with multiple resources. * Keys must start with + // a lowercase letter or international character. See Google Cloud + // Document + // (https://cloud.google.com/resource-manager/docs/creating-managing-labels#requirements) + // for more details. + UserLabels map[string]string `json:"userLabels,omitempty"` - // MediaRecommendationEngineConfig: Configurations for the Media Engine. - // Only applicable on the data stores with solution_type - // SOLUTION_TYPE_RECOMMENDATION and IndustryVertical.MEDIA vertical. - MediaRecommendationEngineConfig *GoogleCloudDiscoveryengineV1alphaEngineMediaRecommendationEngineConfig `json:"mediaRecommendationEngineConfig,omitempty"` + // ForceSendFields is a list of field names (e.g. "Conversation") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` - // Name: Immutable. The fully qualified resource name of the engine. - // This field must be a UTF-8 encoded string with a length limit of 1024 - // characters. Format: - // `projects/{project_number}/locations/{location}/collections/{collectio - // n}/engines/{engine}` engine should be 1-63 characters, and valid - // characters are /a-z0-9*/. Otherwise, an INVALID_ARGUMENT error is - // returned. - Name string `json:"name,omitempty"` + // NullFields is a list of field names (e.g. "Conversation") to include + // in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. However, any field with + // an empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} - // RecommendationMetadata: Output only. Additional information of a - // recommendation engine. Only applicable if solution_type is - // SOLUTION_TYPE_RECOMMENDATION. - RecommendationMetadata *GoogleCloudDiscoveryengineV1alphaEngineRecommendationMetadata `json:"recommendationMetadata,omitempty"` +func (s *GoogleCloudDiscoveryengineV1alphaConverseConversationRequest) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaConverseConversationRequest + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} - // SearchEngineConfig: Configurations for the Search Engine. Only - // applicable if solution_type is SOLUTION_TYPE_SEARCH. - SearchEngineConfig *GoogleCloudDiscoveryengineV1alphaEngineSearchEngineConfig `json:"searchEngineConfig,omitempty"` +// GoogleCloudDiscoveryengineV1alphaConverseConversationResponse: +// Response message for ConversationalSearchService.ConverseConversation +// method. +type GoogleCloudDiscoveryengineV1alphaConverseConversationResponse struct { + // Conversation: Updated conversation including the answer. + Conversation *GoogleCloudDiscoveryengineV1alphaConversation `json:"conversation,omitempty"` - // SimilarDocumentsConfig: Additional config specs for a `similar-items` - // engine. - SimilarDocumentsConfig *GoogleCloudDiscoveryengineV1alphaEngineSimilarDocumentsEngineConfig `json:"similarDocumentsConfig,omitempty"` + // RelatedQuestions: Suggested related questions. + RelatedQuestions []string `json:"relatedQuestions,omitempty"` - // SolutionType: Required. The solutions of the engine. - // - // Possible values: - // "SOLUTION_TYPE_UNSPECIFIED" - Default value. - // "SOLUTION_TYPE_RECOMMENDATION" - Used for Recommendations AI. - // "SOLUTION_TYPE_SEARCH" - Used for Discovery Search. - // "SOLUTION_TYPE_CHAT" - Used for use cases related to the Generative - // AI agent. - SolutionType string `json:"solutionType,omitempty"` + // Reply: Answer to the current query. + Reply *GoogleCloudDiscoveryengineV1alphaReply `json:"reply,omitempty"` - // UpdateTime: Output only. Timestamp the Recommendation Engine was last - // updated. - UpdateTime string `json:"updateTime,omitempty"` + // SearchResults: Search Results. + SearchResults []*GoogleCloudDiscoveryengineV1alphaSearchResponseSearchResult `json:"searchResults,omitempty"` // ServerResponse contains the HTTP response code and headers from the // server. googleapi.ServerResponse `json:"-"` - // ForceSendFields is a list of field names (e.g. "ChatEngineConfig") to + // ForceSendFields is a list of field names (e.g. "Conversation") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -3061,98 +3109,69 @@ type GoogleCloudDiscoveryengineV1alphaEngine struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "ChatEngineConfig") to - // include in API requests with the JSON null value. By default, fields - // with empty values are omitted from API requests. However, any field - // with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. + // NullFields is a list of field names (e.g. "Conversation") to include + // in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. However, any field with + // an empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaEngine) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaEngine +func (s *GoogleCloudDiscoveryengineV1alphaConverseConversationResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaConverseConversationResponse raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaEngineChatEngineConfig: -// Configurations for a Chat Engine. -type GoogleCloudDiscoveryengineV1alphaEngineChatEngineConfig struct { - // AgentCreationConfig: The configurationt generate the Dialogflow agent - // that is associated to this Engine. Note that these configurations are - // one-time consumed by and passed to Dialogflow service. It means they - // cannot be retrieved using EngineService.GetEngine or - // EngineService.ListEngines API after engine creation. - AgentCreationConfig *GoogleCloudDiscoveryengineV1alphaEngineChatEngineConfigAgentCreationConfig `json:"agentCreationConfig,omitempty"` +// GoogleCloudDiscoveryengineV1alphaCreateDataStoreMetadata: Metadata +// related to the progress of the DataStoreService.CreateDataStore +// operation. This will be returned by the +// google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1alphaCreateDataStoreMetadata struct { + // CreateTime: Operation create time. + CreateTime string `json:"createTime,omitempty"` - // DialogflowAgentToLink: The resource name of an exist Dialogflow agent - // to link to this Chat Engine. Customers can either provide - // `agent_creation_config` to create agent or provide an agent name that - // links the agent with the Chat engine. Format: - // `projects//locations//agents/`. Note that the - // `dialogflow_agent_to_link` are one-time consumed by and passed to - // Dialogflow service. It means they cannot be retrieved using - // EngineService.GetEngine or EngineService.ListEngines API after engine - // creation. Please use ChatEngineMetadata.dialogflow_agent for actual - // agent association after Engine is created. - DialogflowAgentToLink string `json:"dialogflowAgentToLink,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. "AgentCreationConfig") - // to unconditionally include in API requests. By default, fields with + // 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. However, any // non-pointer, non-interface field appearing in ForceSendFields will be // sent to the server regardless of whether the field is empty or not. // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "AgentCreationConfig") to - // include in API requests with the JSON null value. By default, fields - // with empty values are omitted from API requests. However, any field - // with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. + // 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. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaEngineChatEngineConfig) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaEngineChatEngineConfig +func (s *GoogleCloudDiscoveryengineV1alphaCreateDataStoreMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaCreateDataStoreMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaEngineChatEngineConfigAgentCreationCo -// nfig: Configurations for generating a Dialogflow agent. Note that -// these configurations are one-time consumed by and passed to -// Dialogflow service. It means they cannot be retrieved using -// EngineService.GetEngine or EngineService.ListEngines API after engine -// creation. -type GoogleCloudDiscoveryengineV1alphaEngineChatEngineConfigAgentCreationConfig struct { - // Business: Name of the company, organization or other entity that the - // agent represents. Used for knowledge connector LLM prompt and for - // knowledge search. - Business string `json:"business,omitempty"` - - // DefaultLanguageCode: Required. The default language of the agent as a - // language tag. See Language Support - // (https://cloud.google.com/dialogflow/docs/reference/language) for a - // list of the currently supported language codes. - DefaultLanguageCode string `json:"defaultLanguageCode,omitempty"` - - // Location: Agent location for Agent creation, supported values: - // global/us/eu. If not provided, us Engine will create Agent using - // us-central-1 by default; eu Engine will create Agent using eu-west-1 - // by default. - Location string `json:"location,omitempty"` +// GoogleCloudDiscoveryengineV1alphaCreateEngineMetadata: Metadata +// related to the progress of the EngineService.CreateEngine operation. +// This will be returned by the google.longrunning.Operation.metadata +// field. +type GoogleCloudDiscoveryengineV1alphaCreateEngineMetadata struct { + // CreateTime: Operation create time. + CreateTime string `json:"createTime,omitempty"` - // TimeZone: Required. The time zone of the agent from the time zone - // database (https://www.iana.org/time-zones), e.g., America/New_York, - // Europe/Paris. - TimeZone string `json:"timeZone,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. "Business") to + // 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. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -3160,7 +3179,7 @@ type GoogleCloudDiscoveryengineV1alphaEngineChatEngineConfigAgentCreationConfig // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Business") to include in + // 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. However, any field with an // empty value appearing in NullFields will be sent to the server as @@ -3169,20 +3188,23 @@ type GoogleCloudDiscoveryengineV1alphaEngineChatEngineConfigAgentCreationConfig NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaEngineChatEngineConfigAgentCreationConfig) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaEngineChatEngineConfigAgentCreationConfig +func (s *GoogleCloudDiscoveryengineV1alphaCreateEngineMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaCreateEngineMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaEngineChatEngineMetadata: Additional -// information of a Chat Engine. Fields in this message are output only. -type GoogleCloudDiscoveryengineV1alphaEngineChatEngineMetadata struct { - // DialogflowAgent: The resource name of a Dialogflow agent, that this - // Chat Engine refers to. Format: `projects//locations//agents/`. - DialogflowAgent string `json:"dialogflowAgent,omitempty"` +// GoogleCloudDiscoveryengineV1alphaCreateSchemaMetadata: Metadata for +// Create Schema LRO. +type GoogleCloudDiscoveryengineV1alphaCreateSchemaMetadata struct { + // CreateTime: Operation create time. + CreateTime string `json:"createTime,omitempty"` - // ForceSendFields is a list of field names (e.g. "DialogflowAgent") to + // 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. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -3190,31 +3212,34 @@ type GoogleCloudDiscoveryengineV1alphaEngineChatEngineMetadata struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "DialogflowAgent") to - // include in API requests with the JSON null value. By default, fields - // with empty values are omitted from API requests. However, any field - // with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. + // 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. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaEngineChatEngineMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaEngineChatEngineMetadata +func (s *GoogleCloudDiscoveryengineV1alphaCreateSchemaMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaCreateSchemaMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaEngineCommonConfig: Common -// configurations for an Engine. -type GoogleCloudDiscoveryengineV1alphaEngineCommonConfig struct { - // CompanyName: The name of the company, business or entity that is - // associated with the engine. Setting this may help improve LLM related - // features. - CompanyName string `json:"companyName,omitempty"` +// GoogleCloudDiscoveryengineV1alphaCreateTargetSiteMetadata: Metadata +// related to the progress of the +// SiteSearchEngineService.CreateTargetSite operation. This will be +// returned by the google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1alphaCreateTargetSiteMetadata struct { + // CreateTime: Operation create time. + CreateTime string `json:"createTime,omitempty"` - // ForceSendFields is a list of field names (e.g. "CompanyName") to + // 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. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -3222,100 +3247,72 @@ type GoogleCloudDiscoveryengineV1alphaEngineCommonConfig struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "CompanyName") to include - // in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. However, any field with - // an empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. - NullFields []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. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaEngineCommonConfig) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaEngineCommonConfig +func (s *GoogleCloudDiscoveryengineV1alphaCreateTargetSiteMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaCreateTargetSiteMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaEngineMediaRecommendationEngineConfig -// : Additional config specs for a Media Recommendation engine. -type GoogleCloudDiscoveryengineV1alphaEngineMediaRecommendationEngineConfig struct { - // OptimizationObjective: The optimization objective e.g. `cvr`. This - // field together with optimization_objective describe engine metadata - // to use to control engine training and serving. Currently supported - // values: `ctr`, `cvr`. If not specified, we choose default based on - // engine type. Default depends on type of recommendation: - // `recommended-for-you` => `ctr` `others-you-may-like` => `ctr` - OptimizationObjective string `json:"optimizationObjective,omitempty"` - - // OptimizationObjectiveConfig: Name and value of the custom threshold - // for cvr optimization_objective. For target_field `watch-time`, - // target_field_value must be an integer value indicating the media - // progress time in seconds between (0, 86400] (excludes 0, includes - // 86400) (e.g., 90). For target_field `watch-percentage`, the - // target_field_value must be a valid float value between (0, 1.0] - // (excludes 0, includes 1.0) (e.g., 0.5). - OptimizationObjectiveConfig *GoogleCloudDiscoveryengineV1alphaEngineMediaRecommendationEngineConfigOptimizationObjectiveConfig `json:"optimizationObjectiveConfig,omitempty"` - - // TrainingState: The training state that the engine is in (e.g. - // `TRAINING` or `PAUSED`). Since part of the cost of running the - // service is frequency of training - this can be used to determine when - // to train engine in order to control cost. If not specified: the - // default value for `CreateEngine` method is `TRAINING`. The default - // value for `UpdateEngine` method is to keep the state the same as - // before. - // - // Possible values: - // "TRAINING_STATE_UNSPECIFIED" - Unspecified training state. - // "PAUSED" - The engine training is paused. - // "TRAINING" - The engine is training. - TrainingState string `json:"trainingState,omitempty"` +// GoogleCloudDiscoveryengineV1alphaCreateTargetSiteRequest: Request +// message for SiteSearchEngineService.CreateTargetSite method. +type GoogleCloudDiscoveryengineV1alphaCreateTargetSiteRequest struct { + // Parent: Required. Parent resource name of TargetSite, such as + // `projects/{project}/locations/{location}/collections/{collection}/data + // Stores/{data_store}/siteSearchEngine`. + Parent string `json:"parent,omitempty"` - // Type: Required. The type of engine e.g. `recommended-for-you`. This - // field together with optimization_objective describe engine metadata - // to use to control engine training and serving. Currently supported - // values: `recommended-for-you`, `others-you-may-like`, - // `more-like-this`, `most-popular-items`. - Type string `json:"type,omitempty"` + // TargetSite: Required. The TargetSite to create. + TargetSite *GoogleCloudDiscoveryengineV1alphaTargetSite `json:"targetSite,omitempty"` - // ForceSendFields is a list of field names (e.g. - // "OptimizationObjective") to unconditionally include in API requests. - // By default, fields with empty or default values are omitted from API - // requests. However, any non-pointer, non-interface field appearing in - // ForceSendFields will be sent to the server regardless of whether the - // field is empty or not. This may be used to include empty fields in - // Patch requests. + // ForceSendFields is a list of field names (e.g. "Parent") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "OptimizationObjective") to - // include in API requests with the JSON null value. By default, fields - // with empty values are omitted from API requests. However, any field - // with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. + // NullFields is a list of field names (e.g. "Parent") to include in API + // requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaEngineMediaRecommendationEngineConfig) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaEngineMediaRecommendationEngineConfig +func (s *GoogleCloudDiscoveryengineV1alphaCreateTargetSiteRequest) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaCreateTargetSiteRequest raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaEngineMediaRecommendationEngineConfig -// OptimizationObjectiveConfig: Custom threshold for `cvr` -// optimization_objective. -type GoogleCloudDiscoveryengineV1alphaEngineMediaRecommendationEngineConfigOptimizationObjectiveConfig struct { - // TargetField: Required. The name of the field to target. Currently - // supported values: `watch-percentage`, `watch-time`. - TargetField string `json:"targetField,omitempty"` +// GoogleCloudDiscoveryengineV1alphaCustomAttribute: A custom attribute +// that is not explicitly modeled in a resource, e.g. UserEvent. +type GoogleCloudDiscoveryengineV1alphaCustomAttribute struct { + // Numbers: The numerical values of this custom attribute. For example, + // `[2.3, 15.4]` when the key is "lengths_cm". Exactly one of + // CustomAttribute.text or CustomAttribute.numbers should be set. + // Otherwise, an `INVALID_ARGUMENT` error is returned. + Numbers []float64 `json:"numbers,omitempty"` - // TargetFieldValueFloat: Required. The threshold to be applied to the - // target (e.g., 0.5). - TargetFieldValueFloat float64 `json:"targetFieldValueFloat,omitempty"` + // Text: The textual values of this custom attribute. For example, + // `["yellow", "green"]` when the key is "color". Empty string is not + // allowed. Otherwise, an `INVALID_ARGUMENT` error is returned. Exactly + // one of CustomAttribute.text or CustomAttribute.numbers should be set. + // Otherwise, an `INVALID_ARGUMENT` error is returned. + Text []string `json:"text,omitempty"` - // ForceSendFields is a list of field names (e.g. "TargetField") to + // ForceSendFields is a list of field names (e.g. "Numbers") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -3323,78 +3320,101 @@ type GoogleCloudDiscoveryengineV1alphaEngineMediaRecommendationEngineConfigOptim // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "TargetField") to include - // in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. However, any field with - // an empty value appearing in NullFields will be sent to the server as + // NullFields is a list of field names (e.g. "Numbers") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaEngineMediaRecommendationEngineConfigOptimizationObjectiveConfig) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaEngineMediaRecommendationEngineConfigOptimizationObjectiveConfig +func (s *GoogleCloudDiscoveryengineV1alphaCustomAttribute) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaCustomAttribute raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -func (s *GoogleCloudDiscoveryengineV1alphaEngineMediaRecommendationEngineConfigOptimizationObjectiveConfig) UnmarshalJSON(data []byte) error { - type NoMethod GoogleCloudDiscoveryengineV1alphaEngineMediaRecommendationEngineConfigOptimizationObjectiveConfig +func (s *GoogleCloudDiscoveryengineV1alphaCustomAttribute) UnmarshalJSON(data []byte) error { + type NoMethod GoogleCloudDiscoveryengineV1alphaCustomAttribute var s1 struct { - TargetFieldValueFloat gensupport.JSONFloat64 `json:"targetFieldValueFloat"` + Numbers []gensupport.JSONFloat64 `json:"numbers"` *NoMethod } s1.NoMethod = (*NoMethod)(s) if err := json.Unmarshal(data, &s1); err != nil { return err } - s.TargetFieldValueFloat = float64(s1.TargetFieldValueFloat) + s.Numbers = make([]float64, len(s1.Numbers)) + for i := range s1.Numbers { + s.Numbers[i] = float64(s1.Numbers[i]) + } return nil } -// GoogleCloudDiscoveryengineV1alphaEngineRecommendationMetadata: -// Additional information of a recommendation engine. -type GoogleCloudDiscoveryengineV1alphaEngineRecommendationMetadata struct { - // DataState: Output only. The state of data requirements for this - // engine: `DATA_OK` and `DATA_ERROR`. Engine cannot be trained if the - // data is in `DATA_ERROR` state. Engine can have `DATA_ERROR` state - // even if serving state is `ACTIVE`: engines were trained successfully - // before, but cannot be refreshed because the underlying engine no - // longer has sufficient data for training. +// GoogleCloudDiscoveryengineV1alphaDataStore: DataStore captures global +// settings and configs at the DataStore level. +type GoogleCloudDiscoveryengineV1alphaDataStore struct { + // ContentConfig: Immutable. The content config of the data store. If + // this field is unset, the server behavior defaults to + // ContentConfig.NO_CONTENT. // // Possible values: - // "DATA_STATE_UNSPECIFIED" - Unspecified default value, should never - // be explicitly set. - // "DATA_OK" - The engine has sufficient training data. - // "DATA_ERROR" - The engine does not have sufficient training data. - // Error messages can be queried via Stackdriver. - DataState string `json:"dataState,omitempty"` + // "CONTENT_CONFIG_UNSPECIFIED" - Default value. + // "NO_CONTENT" - Only contains documents without any + // Document.content. + // "CONTENT_REQUIRED" - Only contains documents with Document.content. + // "PUBLIC_WEBSITE" - The data store is used for public website + // search. + ContentConfig string `json:"contentConfig,omitempty"` - // LastTuneTime: Output only. The timestamp when the latest successful - // tune finished. Only applicable on Media Recommendation engines. - LastTuneTime string `json:"lastTuneTime,omitempty"` + // CreateTime: Output only. Timestamp the DataStore was created at. + CreateTime string `json:"createTime,omitempty"` - // ServingState: Output only. The serving state of the engine: `ACTIVE`, - // `NOT_ACTIVE`. + // DefaultSchemaId: Output only. The id of the default Schema + // asscociated to this data store. + DefaultSchemaId string `json:"defaultSchemaId,omitempty"` + + // DisplayName: Required. The data store display name. This field must + // be a UTF-8 encoded string with a length limit of 128 characters. + // Otherwise, an INVALID_ARGUMENT error is returned. + DisplayName string `json:"displayName,omitempty"` + + // IndustryVertical: Immutable. The industry vertical that the data + // store registers. // // Possible values: - // "SERVING_STATE_UNSPECIFIED" - Unspecified serving state. - // "INACTIVE" - The engine is not serving. - // "ACTIVE" - The engine is serving and can be queried. - // "TUNED" - The engine is trained on tuned hyperparameters and can be - // queried. - ServingState string `json:"servingState,omitempty"` + // "INDUSTRY_VERTICAL_UNSPECIFIED" - Value used when unset. + // "GENERIC" - The generic vertical for documents that are not + // specific to any industry vertical. + // "MEDIA" - The media industry vertical. + IndustryVertical string `json:"industryVertical,omitempty"` - // TuningOperation: Output only. The latest tune operation id associated - // with the engine. Only applicable on Media Recommendation engines. If - // present, this operation id can be used to determine if there is an - // ongoing tune for this engine. To check the operation status, send the - // GetOperation request with this operation id in the engine resource - // format. If no tuning has happened for this engine, the string is - // empty. - TuningOperation string `json:"tuningOperation,omitempty"` + // Name: Immutable. The full resource name of the data store. Format: + // `projects/{project}/locations/{location}/collections/{collection_id}/d + // ataStores/{data_store_id}`. This field 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. "DataState") to + // SolutionTypes: The solutions that the data store enrolls. Available + // solutions for each industry_vertical: * `MEDIA`: + // `SOLUTION_TYPE_RECOMMENDATION` and `SOLUTION_TYPE_SEARCH`. * + // `SITE_SEARCH`: `SOLUTION_TYPE_SEARCH` is automatically enrolled. + // Other solutions cannot be enrolled. + // + // Possible values: + // "SOLUTION_TYPE_UNSPECIFIED" - Default value. + // "SOLUTION_TYPE_RECOMMENDATION" - Used for Recommendations AI. + // "SOLUTION_TYPE_SEARCH" - Used for Discovery Search. + // "SOLUTION_TYPE_CHAT" - Used for use cases related to the Generative + // AI agent. + SolutionTypes []string `json:"solutionTypes,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the + // server. + googleapi.ServerResponse `json:"-"` + + // ForceSendFields is a list of field names (e.g. "ContentConfig") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -3402,45 +3422,34 @@ type GoogleCloudDiscoveryengineV1alphaEngineRecommendationMetadata struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "DataState") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as + // NullFields is a list of field names (e.g. "ContentConfig") to include + // in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. However, any field with + // an empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaEngineRecommendationMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaEngineRecommendationMetadata +func (s *GoogleCloudDiscoveryengineV1alphaDataStore) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaDataStore raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaEngineSearchEngineConfig: -// Configurations for a Search Engine. -type GoogleCloudDiscoveryengineV1alphaEngineSearchEngineConfig struct { - // SearchAddOns: The add-on that this search engine enables. - // - // Possible values: - // "SEARCH_ADD_ON_UNSPECIFIED" - Default value when the enum is - // unspecified. This is invalid to use. - // "SEARCH_ADD_ON_LLM" - Large language model add-on. - SearchAddOns []string `json:"searchAddOns,omitempty"` +// GoogleCloudDiscoveryengineV1alphaDeleteDataStoreMetadata: Metadata +// related to the progress of the DataStoreService.DeleteDataStore +// operation. This will be returned by the +// google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1alphaDeleteDataStoreMetadata struct { + // CreateTime: Operation create time. + CreateTime string `json:"createTime,omitempty"` - // SearchTier: The search feature tier of this engine. Different tiers - // might have different pricing. To learn more, please check the pricing - // documentation. Defaults to SearchTier.SEARCH_TIER_STANDARD if not - // specified. - // - // Possible values: - // "SEARCH_TIER_UNSPECIFIED" - Default value when the enum is - // unspecified. This is invalid to use. - // "SEARCH_TIER_STANDARD" - Standard tier. - // "SEARCH_TIER_ENTERPRISE" - Enterprise tier. - SearchTier string `json:"searchTier,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. "SearchAddOns") to + // 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. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -3448,33 +3457,33 @@ type GoogleCloudDiscoveryengineV1alphaEngineSearchEngineConfig struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "SearchAddOns") to include - // in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. However, any field with - // an empty value appearing in NullFields will be sent to the server as + // 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. However, any field with an + // empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaEngineSearchEngineConfig) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaEngineSearchEngineConfig +func (s *GoogleCloudDiscoveryengineV1alphaDeleteDataStoreMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaDeleteDataStoreMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaEngineSimilarDocumentsEngineConfig: -// Additional config specs for a `similar-items` engine. -type GoogleCloudDiscoveryengineV1alphaEngineSimilarDocumentsEngineConfig struct { -} - -// GoogleCloudDiscoveryengineV1alphaEstimateDataSizeMetadata: Metadata -// related to the progress of the EstimateDataSize operation. This is -// returned by the google.longrunning.Operation.metadata field. -type GoogleCloudDiscoveryengineV1alphaEstimateDataSizeMetadata struct { +// GoogleCloudDiscoveryengineV1alphaDeleteEngineMetadata: Metadata +// related to the progress of the EngineService.DeleteEngine operation. +// This will be returned by the google.longrunning.Operation.metadata +// field. +type GoogleCloudDiscoveryengineV1alphaDeleteEngineMetadata 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. However, any @@ -3492,22 +3501,23 @@ type GoogleCloudDiscoveryengineV1alphaEstimateDataSizeMetadata struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaEstimateDataSizeMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaEstimateDataSizeMetadata +func (s *GoogleCloudDiscoveryengineV1alphaDeleteEngineMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaDeleteEngineMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaEstimateDataSizeRequest: Request -// message for EstimateBillingService.EstimateDataSize method -type GoogleCloudDiscoveryengineV1alphaEstimateDataSizeRequest struct { - // FileDataSource: Structured or unstructured data. - FileDataSource *GoogleCloudDiscoveryengineV1alphaEstimateDataSizeRequestFileDataSource `json:"fileDataSource,omitempty"` +// GoogleCloudDiscoveryengineV1alphaDeleteSchemaMetadata: Metadata for +// DeleteSchema LRO. +type GoogleCloudDiscoveryengineV1alphaDeleteSchemaMetadata struct { + // CreateTime: Operation create time. + CreateTime string `json:"createTime,omitempty"` - // WebsiteDataSource: Website data. - WebsiteDataSource *GoogleCloudDiscoveryengineV1alphaEstimateDataSizeRequestWebsiteDataSource `json:"websiteDataSource,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. "FileDataSource") to + // 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. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -3515,32 +3525,34 @@ type GoogleCloudDiscoveryengineV1alphaEstimateDataSizeRequest struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "FileDataSource") to - // include in API requests with the JSON null value. By default, fields - // with empty values are omitted from API requests. However, any field - // with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. + // 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. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaEstimateDataSizeRequest) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaEstimateDataSizeRequest +func (s *GoogleCloudDiscoveryengineV1alphaDeleteSchemaMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaDeleteSchemaMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaEstimateDataSizeRequestFileDataSource -// : Data source contains files either in Cloud Storage or BigQuery. -type GoogleCloudDiscoveryengineV1alphaEstimateDataSizeRequestFileDataSource struct { - // BigquerySource: BigQuery input source. - BigquerySource *GoogleCloudDiscoveryengineV1alphaBigQuerySource `json:"bigquerySource,omitempty"` +// GoogleCloudDiscoveryengineV1alphaDeleteTargetSiteMetadata: Metadata +// related to the progress of the +// SiteSearchEngineService.DeleteTargetSite operation. This will be +// returned by the google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1alphaDeleteTargetSiteMetadata struct { + // CreateTime: Operation create time. + CreateTime string `json:"createTime,omitempty"` - // GcsSource: Cloud Storage location for the input content. - GcsSource *GoogleCloudDiscoveryengineV1alphaGcsSource `json:"gcsSource,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. "BigquerySource") to + // 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. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -3548,73 +3560,116 @@ type GoogleCloudDiscoveryengineV1alphaEstimateDataSizeRequestFileDataSource stru // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "BigquerySource") to - // include in API requests with the JSON null value. By default, fields - // with empty values are omitted from API requests. However, any field - // with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. + // 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. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaEstimateDataSizeRequestFileDataSource) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaEstimateDataSizeRequestFileDataSource +func (s *GoogleCloudDiscoveryengineV1alphaDeleteTargetSiteMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaDeleteTargetSiteMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaEstimateDataSizeRequestWebsiteDataSou -// rce: Data source is a set of website patterns that we crawl to get -// the total number of websites. -type GoogleCloudDiscoveryengineV1alphaEstimateDataSizeRequestWebsiteDataSource struct { - // EstimatorUriPatterns: Required. The URI patterns to estimate the data - // sizes. At most 10 patterns are allowed, otherwise an INVALID_ARGUMENT - // error is thrown. - EstimatorUriPatterns []*GoogleCloudDiscoveryengineV1alphaEstimateDataSizeRequestWebsiteDataSourceEstimatorUriPattern `json:"estimatorUriPatterns,omitempty"` +// GoogleCloudDiscoveryengineV1alphaDisableAdvancedSiteSearchMetadata: +// Metadata related to the progress of the +// SiteSearchEngineService.DisableAdvancedSiteSearch operation. This +// will be returned by the google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1alphaDisableAdvancedSiteSearchMetadata struct { + // CreateTime: Operation create time. + CreateTime string `json:"createTime,omitempty"` - // ForceSendFields is a list of field names (e.g. - // "EstimatorUriPatterns") to unconditionally include in API requests. - // By default, fields with empty or default values are omitted from API - // requests. However, any non-pointer, non-interface field appearing in - // ForceSendFields will be sent to the server regardless of whether the - // field is empty or not. This may be used to include empty fields in - // Patch requests. + // 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. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "EstimatorUriPatterns") to - // include in API requests with the JSON null value. By default, fields - // with empty values are omitted from API requests. However, any field - // with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. + // 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. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaEstimateDataSizeRequestWebsiteDataSource) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaEstimateDataSizeRequestWebsiteDataSource +func (s *GoogleCloudDiscoveryengineV1alphaDisableAdvancedSiteSearchMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaDisableAdvancedSiteSearchMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaEstimateDataSizeRequestWebsiteDataSou -// rceEstimatorUriPattern: URI patterns that we use to crawl. -type GoogleCloudDiscoveryengineV1alphaEstimateDataSizeRequestWebsiteDataSourceEstimatorUriPattern struct { - // ExactMatch: Whether we infer the generated URI or use the exact - // provided one. - ExactMatch bool `json:"exactMatch,omitempty"` +// GoogleCloudDiscoveryengineV1alphaDisableAdvancedSiteSearchRequest: +// Request message for SiteSearchEngineService.DisableAdvancedSiteSearch +// method. +type GoogleCloudDiscoveryengineV1alphaDisableAdvancedSiteSearchRequest struct { +} - // Exclusive: Whether the pattern is exclusive or not. If set to true, - // the pattern is considered exclusive. If unset or set to false, the - // pattern is considered inclusive by default. - Exclusive bool `json:"exclusive,omitempty"` +// GoogleCloudDiscoveryengineV1alphaDisableAdvancedSiteSearchResponse: +// Response message for +// SiteSearchEngineService.DisableAdvancedSiteSearch method. +type GoogleCloudDiscoveryengineV1alphaDisableAdvancedSiteSearchResponse struct { +} - // ProvidedUriPattern: User provided URI pattern. For example, - // `foo.com/bar/*`. - ProvidedUriPattern string `json:"providedUriPattern,omitempty"` +// GoogleCloudDiscoveryengineV1alphaDocument: Document captures all raw +// metadata information of items to be recommended or searched. +type GoogleCloudDiscoveryengineV1alphaDocument struct { + // Content: The unstructured data linked to this document. Content must + // be set if this document is under a `CONTENT_REQUIRED` data store. + Content *GoogleCloudDiscoveryengineV1alphaDocumentContent `json:"content,omitempty"` - // ForceSendFields is a list of field names (e.g. "ExactMatch") to + // DerivedStructData: Output only. This field is OUTPUT_ONLY. It + // contains derived data that are not in the original input document. + DerivedStructData googleapi.RawMessage `json:"derivedStructData,omitempty"` + + // Id: Immutable. The identifier of the document. Id should conform to + // RFC-1034 (https://tools.ietf.org/html/rfc1034) standard with a length + // limit of 63 characters. + Id string `json:"id,omitempty"` + + // JsonData: The JSON string representation of the document. It should + // conform to the registered Schema or an `INVALID_ARGUMENT` error is + // thrown. + JsonData string `json:"jsonData,omitempty"` + + // Name: Immutable. The full resource name of the document. Format: + // `projects/{project}/locations/{location}/collections/{collection}/data + // Stores/{data_store}/branches/{branch}/documents/{document_id}`. This + // field must be a UTF-8 encoded string with a length limit of 1024 + // characters. + Name string `json:"name,omitempty"` + + // ParentDocumentId: The identifier of the parent document. Currently + // supports at most two level document hierarchy. Id should conform to + // RFC-1034 (https://tools.ietf.org/html/rfc1034) standard with a length + // limit of 63 characters. + ParentDocumentId string `json:"parentDocumentId,omitempty"` + + // SchemaId: The identifier of the schema located in the same data + // store. + SchemaId string `json:"schemaId,omitempty"` + + // StructData: The structured JSON data for the document. It should + // conform to the registered Schema or an `INVALID_ARGUMENT` error is + // thrown. + StructData googleapi.RawMessage `json:"structData,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the + // server. + googleapi.ServerResponse `json:"-"` + + // ForceSendFields is a list of field names (e.g. "Content") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -3622,7 +3677,7 @@ type GoogleCloudDiscoveryengineV1alphaEstimateDataSizeRequestWebsiteDataSourceEs // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "ExactMatch") to include in + // NullFields is a list of field names (e.g. "Content") to include in // API requests with the JSON null value. By default, fields with empty // values are omitted from API requests. However, any field with an // empty value appearing in NullFields will be sent to the server as @@ -3631,25 +3686,40 @@ type GoogleCloudDiscoveryengineV1alphaEstimateDataSizeRequestWebsiteDataSourceEs NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaEstimateDataSizeRequestWebsiteDataSourceEstimatorUriPattern) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaEstimateDataSizeRequestWebsiteDataSourceEstimatorUriPattern +func (s *GoogleCloudDiscoveryengineV1alphaDocument) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaDocument raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaEstimateDataSizeResponse: Response -// of the EstimateDataSize request. If the long running operation was -// successful, then this message is returned by the -// google.longrunning.Operations.response field if the operation was -// successful. -type GoogleCloudDiscoveryengineV1alphaEstimateDataSizeResponse struct { - // DataSizeBytes: Data size in terms of bytes. - DataSizeBytes int64 `json:"dataSizeBytes,omitempty,string"` - - // DocumentCount: Total number of documents. - DocumentCount int64 `json:"documentCount,omitempty,string"` +// GoogleCloudDiscoveryengineV1alphaDocumentContent: Unstructured data +// linked to this document. +type GoogleCloudDiscoveryengineV1alphaDocumentContent struct { + // MimeType: The MIME type of the content. Supported types: * + // `application/pdf` (PDF, only native PDFs are supported for now) * + // `text/html` (HTML) * + // `application/vnd.openxmlformats-officedocument.wordprocessingml.docume + // nt` (DOCX) * + // `application/vnd.openxmlformats-officedocument.presentationml.presenta + // tion` (PPTX) * `text/plain` (TXT) See + // https://www.iana.org/assignments/media-types/media-types.xhtml. + MimeType string `json:"mimeType,omitempty"` - // ForceSendFields is a list of field names (e.g. "DataSizeBytes") to + // RawBytes: The content represented as a stream of bytes. The maximum + // length is 1,000,000 bytes (1 MB / ~0.95 MiB). Note: As with all + // `bytes` fields, this field is represented as pure binary in Protocol + // Buffers and base64-encoded string in JSON. For example, + // `abc123!?$*&()'-=@~` should be represented as + // `YWJjMTIzIT8kKiYoKSctPUB+` in JSON. See + // https://developers.google.com/protocol-buffers/docs/proto3#json. + RawBytes string `json:"rawBytes,omitempty"` + + // Uri: The URI of the content. Only Cloud Storage URIs (e.g. + // `gs://bucket-name/path/to/file`) are supported. The maximum file size + // is 2.5 MB for text-based formats, 100 MB for other formats. + Uri string `json:"uri,omitempty"` + + // ForceSendFields is a list of field names (e.g. "MimeType") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -3657,43 +3727,47 @@ type GoogleCloudDiscoveryengineV1alphaEstimateDataSizeResponse struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "DataSizeBytes") to include - // in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. However, any field with - // an empty value appearing in NullFields will be sent to the server as + // NullFields is a list of field names (e.g. "MimeType") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaEstimateDataSizeResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaEstimateDataSizeResponse +func (s *GoogleCloudDiscoveryengineV1alphaDocumentContent) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaDocumentContent raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaFetchDomainVerificationStatusResponse -// : Response message for -// SiteSearchEngineService.FetchDomainVerificationStatus method. -type GoogleCloudDiscoveryengineV1alphaFetchDomainVerificationStatusResponse struct { - // NextPageToken: A token that 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"` +// GoogleCloudDiscoveryengineV1alphaDocumentInfo: Detailed document +// information associated with a user event. +type GoogleCloudDiscoveryengineV1alphaDocumentInfo struct { + // Id: The Document resource ID. + Id string `json:"id,omitempty"` - // TargetSites: List of TargetSites containing the site verification - // status. - TargetSites []*GoogleCloudDiscoveryengineV1alphaTargetSite `json:"targetSites,omitempty"` + // Name: The Document resource full name, of the form: + // `projects/{project_id}/locations/{location}/collections/{collection_id + // }/dataStores/{data_store_id}/branches/{branch_id}/documents/{document_ + // id}` + Name string `json:"name,omitempty"` - // TotalSize: The total number of items matching the request. This will - // always be populated in the response. - TotalSize int64 `json:"totalSize,omitempty"` + // PromotionIds: The promotion IDs associated with this Document. + // Currently, this field is restricted to at most one ID. + PromotionIds []string `json:"promotionIds,omitempty"` - // ServerResponse contains the HTTP response code and headers from the - // server. - googleapi.ServerResponse `json:"-"` + // Quantity: Quantity of the Document associated with the user event. + // Defaults to 1. For example, this field will be 2 if two quantities of + // the same Document are involved in a `add-to-cart` event. Required for + // events of the following event types: * `add-to-cart` * `purchase` + Quantity int64 `json:"quantity,omitempty"` - // ForceSendFields is a list of field names (e.g. "NextPageToken") to + // Uri: The Document URI - only allowed for website data stores. + Uri string `json:"uri,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. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -3701,214 +3775,69 @@ type GoogleCloudDiscoveryengineV1alphaFetchDomainVerificationStatusResponse stru // This may be used to include empty fields in Patch requests. 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. However, any field with - // an empty value appearing in NullFields will be sent to the server as + // NullFields is a list of field names (e.g. "Id") to include in API + // requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaFetchDomainVerificationStatusResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaFetchDomainVerificationStatusResponse +func (s *GoogleCloudDiscoveryengineV1alphaDocumentInfo) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaDocumentInfo raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaFieldConfig: Configurations for -// fields of a schema. For example, configuring a field is indexable, or -// searchable. -type GoogleCloudDiscoveryengineV1alphaFieldConfig struct { - // CompletableOption: If completable_option is COMPLETABLE_ENABLED, - // field values are directly used and returned as suggestions for - // Autocomplete in CompletionService.CompleteQuery. If - // completable_option is unset, the server behavior defaults to - // COMPLETABLE_DISABLED for fields that support setting completable - // options, which are just `string` fields. For those fields that do not - // support setting completable options, the server will skip completable - // option setting, and setting completable_option for those fields will - // throw `INVALID_ARGUMENT` error. - // - // Possible values: - // "COMPLETABLE_OPTION_UNSPECIFIED" - Value used when unset. - // "COMPLETABLE_ENABLED" - Completable option enabled for a schema - // field. - // "COMPLETABLE_DISABLED" - Completable option disabled for a schema - // field. - CompletableOption string `json:"completableOption,omitempty"` - - // DynamicFacetableOption: If dynamic_facetable_option is - // DYNAMIC_FACETABLE_ENABLED, field values are available for dynamic - // facet. Could only be DYNAMIC_FACETABLE_DISABLED if - // FieldConfig.indexable_option is INDEXABLE_DISABLED. Otherwise, an - // `INVALID_ARGUMENT` error will be returned. If - // dynamic_facetable_option is unset, the server behavior defaults to - // DYNAMIC_FACETABLE_DISABLED for fields that support setting dynamic - // facetable options. For those fields that do not support setting - // dynamic facetable options, such as `object` and `boolean`, the server - // will skip dynamic facetable option setting, and setting - // dynamic_facetable_option for those fields will throw - // `INVALID_ARGUMENT` error. - // - // Possible values: - // "DYNAMIC_FACETABLE_OPTION_UNSPECIFIED" - Value used when unset. - // "DYNAMIC_FACETABLE_ENABLED" - Dynamic facetable option enabled for - // a schema field. - // "DYNAMIC_FACETABLE_DISABLED" - Dynamic facetable option disabled - // for a schema field. - DynamicFacetableOption string `json:"dynamicFacetableOption,omitempty"` - - // FieldPath: Required. Field path of the schema field. For example: - // `title`, `description`, `release_info.release_year`. - FieldPath string `json:"fieldPath,omitempty"` - - // FieldType: Output only. Raw type of the field. - // - // Possible values: - // "FIELD_TYPE_UNSPECIFIED" - Field type is unspecified. - // "OBJECT" - Field value type is Object. - // "STRING" - Field value type is String. - // "NUMBER" - Field value type is Number. - // "INTEGER" - Field value type is Integer. - // "BOOLEAN" - Field value type is Boolean. - // "GEOLOCATION" - Field value type is Geolocation. - // "DATETIME" - Field value type is Datetime. - FieldType string `json:"fieldType,omitempty"` - - // IndexableOption: If indexable_option is INDEXABLE_ENABLED, field - // values are indexed so that it can be filtered or faceted in - // SearchService.Search. If indexable_option is unset, the server - // behavior defaults to INDEXABLE_DISABLED for fields that support - // setting indexable options. For those fields that do not support - // setting indexable options, such as `object` and `boolean` and key - // properties, the server will skip indexable_option setting, and - // setting indexable_option for those fields will throw - // `INVALID_ARGUMENT` error. - // - // Possible values: - // "INDEXABLE_OPTION_UNSPECIFIED" - Value used when unset. - // "INDEXABLE_ENABLED" - Indexable option enabled for a schema field. - // "INDEXABLE_DISABLED" - Indexable option disabled for a schema - // field. - IndexableOption string `json:"indexableOption,omitempty"` - - // KeyPropertyType: Output only. Type of the key property that this - // field is mapped to. Empty string if this is not annotated as mapped - // to a key property. Example types are `title`, `description`. Full - // list is defined by `keyPropertyMapping` in the schema field - // annotation. If the schema field has a `KeyPropertyMapping` - // annotation, `indexable_option` and `searchable_option` of this field - // cannot be modified. - KeyPropertyType string `json:"keyPropertyType,omitempty"` - - // RecsFilterableOption: If recs_filterable_option is - // FILTERABLE_ENABLED, field values are filterable by filter expression - // in RecommendationService.Recommend. If FILTERABLE_ENABLED but the - // field type is numerical, field values are not filterable by text - // queries in RecommendationService.Recommend. Only textual fields are - // supported. If recs_filterable_option is unset, the default setting is - // FILTERABLE_DISABLED for fields that support setting filterable - // options. When a field set to [FILTERABLE_DISABLED] is filtered, a - // warning is generated and an empty result is returned. - // - // Possible values: - // "FILTERABLE_OPTION_UNSPECIFIED" - Value used when unset. - // "FILTERABLE_ENABLED" - Filterable option enabled for a schema - // field. - // "FILTERABLE_DISABLED" - Filterable option disabled for a schema - // field. - RecsFilterableOption string `json:"recsFilterableOption,omitempty"` +// GoogleCloudDiscoveryengineV1alphaDocumentProcessingConfig: A +// singleton resource of DataStore. It's empty when DataStore is +// created, which defaults to digital parser. The first call to +// DataStoreService.UpdateDocumentProcessingConfig method will +// initialize the config. +type GoogleCloudDiscoveryengineV1alphaDocumentProcessingConfig struct { + // Name: Output only. The full resource name of the Document Processing + // Config. Format: + // `projects/*/locations/*/collections/*/dataStores/*/documentProcessingC + // onfig`. + Name string `json:"name,omitempty"` - // RetrievableOption: If retrievable_option is RETRIEVABLE_ENABLED, - // field values are included in the search results. If - // retrievable_option is unset, the server behavior defaults to - // RETRIEVABLE_DISABLED for fields that support setting retrievable - // options. For those fields that do not support setting retrievable - // options, such as `object` and `boolean`, the server will skip - // retrievable option setting, and setting retrievable_option for those - // fields will throw `INVALID_ARGUMENT` error. - // - // Possible values: - // "RETRIEVABLE_OPTION_UNSPECIFIED" - Value used when unset. - // "RETRIEVABLE_ENABLED" - Retrievable option enabled for a schema - // field. - // "RETRIEVABLE_DISABLED" - Retrievable option disabled for a schema - // field. - RetrievableOption string `json:"retrievableOption,omitempty"` + // OcrConfig: The OCR config. Currently it only applies to PDFs. + OcrConfig *GoogleCloudDiscoveryengineV1alphaOcrConfig `json:"ocrConfig,omitempty"` - // SearchableOption: If searchable_option is SEARCHABLE_ENABLED, field - // values are searchable by text queries in SearchService.Search. If - // SEARCHABLE_ENABLED but field type is numerical, field values will not - // be searchable by text queries in SearchService.Search, as there are - // no text values associated to numerical fields. If searchable_option - // is unset, the server behavior defaults to SEARCHABLE_DISABLED for - // fields that support setting searchable options. Only `string` fields - // that have no key property mapping support setting searchable_option. - // For those fields that do not support setting searchable options, the - // server will skip searchable option setting, and setting - // searchable_option for those fields will throw `INVALID_ARGUMENT` - // error. - // - // Possible values: - // "SEARCHABLE_OPTION_UNSPECIFIED" - Value used when unset. - // "SEARCHABLE_ENABLED" - Searchable option enabled for a schema - // field. - // "SEARCHABLE_DISABLED" - Searchable option disabled for a schema - // field. - SearchableOption string `json:"searchableOption,omitempty"` + // ServerResponse contains the HTTP response code and headers from the + // server. + googleapi.ServerResponse `json:"-"` - // ForceSendFields is a list of field names (e.g. "CompletableOption") - // to unconditionally include in API requests. By default, fields with + // 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. However, any // non-pointer, non-interface field appearing in ForceSendFields will be // sent to the server regardless of whether the field is empty or not. // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "CompletableOption") to - // include in API requests with the JSON null value. By default, fields - // with empty values are omitted from API requests. However, any field - // with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. + // 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. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaFieldConfig) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaFieldConfig +func (s *GoogleCloudDiscoveryengineV1alphaDocumentProcessingConfig) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaDocumentProcessingConfig raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaGcsSource: Cloud Storage location -// for input content. -type GoogleCloudDiscoveryengineV1alphaGcsSource struct { - // DataSchema: The schema to use when parsing the data from the source. - // Supported values for document imports: * `document` (default): One - // JSON Document per line. Each document must have a valid Document.id. - // * `content`: Unstructured data (e.g. PDF, HTML). Each file matched by - // `input_uris` becomes a document, with the ID set to the first 128 - // bits of SHA256(URI) encoded as a hex string. * `custom`: One custom - // data JSON per row in arbitrary format that conforms to the defined - // Schema of the data store. This can only be used by Gen App Builder. * - // `csv`: A CSV file with header conforming to the defined Schema of the - // data store. Each entry after the header is imported as a Document. - // This can only be used by Gen App Builder. Supported values for user - // even imports: * `user_event` (default): One JSON UserEvent per line. - DataSchema string `json:"dataSchema,omitempty"` - - // InputUris: Required. Cloud Storage URIs to input files. URI can be up - // to 2000 characters long. URIs can match the full object path (for - // example, `gs://bucket/directory/object.json`) or a pattern matching - // one or more files, such as `gs://bucket/directory/*.json`. A request - // can contain at most 100 files (or 100,000 files if `data_schema` is - // `content`). Each file can be up to 2 GB (or 100 MB if `data_schema` - // is `content`). - InputUris []string `json:"inputUris,omitempty"` +// GoogleCloudDiscoveryengineV1alphaDoubleList: Double list. +type GoogleCloudDiscoveryengineV1alphaDoubleList struct { + // Values: Double values. + Values []float64 `json:"values,omitempty"` - // ForceSendFields is a list of field names (e.g. "DataSchema") to + // ForceSendFields is a list of field names (e.g. "Values") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -3916,8 +3845,8 @@ type GoogleCloudDiscoveryengineV1alphaGcsSource struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "DataSchema") to include in - // API requests with the JSON null value. By default, fields with empty + // NullFields is a list of field names (e.g. "Values") to include in API + // requests with the JSON null value. By default, fields with empty // values are omitted from API requests. However, any field with an // empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. @@ -3925,26 +3854,37 @@ type GoogleCloudDiscoveryengineV1alphaGcsSource struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaGcsSource) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaGcsSource +func (s *GoogleCloudDiscoveryengineV1alphaDoubleList) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaDoubleList raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaImportDocumentsMetadata: Metadata -// related to the progress of the ImportDocuments operation. This is -// returned by the google.longrunning.Operation.metadata field. -type GoogleCloudDiscoveryengineV1alphaImportDocumentsMetadata struct { +func (s *GoogleCloudDiscoveryengineV1alphaDoubleList) UnmarshalJSON(data []byte) error { + type NoMethod GoogleCloudDiscoveryengineV1alphaDoubleList + var s1 struct { + Values []gensupport.JSONFloat64 `json:"values"` + *NoMethod + } + s1.NoMethod = (*NoMethod)(s) + if err := json.Unmarshal(data, &s1); err != nil { + return err + } + s.Values = make([]float64, len(s1.Values)) + for i := range s1.Values { + s.Values[i] = float64(s1.Values[i]) + } + return nil +} + +// GoogleCloudDiscoveryengineV1alphaEnableAdvancedSiteSearchMetadata: +// Metadata related to the progress of the +// SiteSearchEngineService.EnableAdvancedSiteSearch operation. This will +// be returned by the google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1alphaEnableAdvancedSiteSearchMetadata struct { // CreateTime: Operation create time. CreateTime string `json:"createTime,omitempty"` - // FailureCount: Count of entries that encountered errors while - // processing. - FailureCount int64 `json:"failureCount,omitempty,string"` - - // SuccessCount: Count of entries that were processed successfully. - SuccessCount int64 `json:"successCount,omitempty,string"` - // UpdateTime: Operation last update time. If the operation is done, // this is also the finish time. UpdateTime string `json:"updateTime,omitempty"` @@ -3966,72 +3906,114 @@ type GoogleCloudDiscoveryengineV1alphaImportDocumentsMetadata struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaImportDocumentsMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaImportDocumentsMetadata +func (s *GoogleCloudDiscoveryengineV1alphaEnableAdvancedSiteSearchMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaEnableAdvancedSiteSearchMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaImportDocumentsRequest: Request -// message for Import methods. -type GoogleCloudDiscoveryengineV1alphaImportDocumentsRequest struct { - // AutoGenerateIds: Whether to automatically generate IDs for the - // documents if absent. If set to `true`, Document.ids are automatically - // generated based on the hash of the payload, where IDs may not be - // consistent during multiple imports. In which case - // ReconciliationMode.FULL is highly recommended to avoid duplicate - // contents. If unset or set to `false`, Document.ids have to be - // specified using id_field, otherwise, documents without IDs fail to be - // imported. Only set this field when using GcsSource or BigQuerySource, - // and when GcsSource.data_schema or BigQuerySource.data_schema is - // `custom` or `csv`. Otherwise, an INVALID_ARGUMENT error is thrown. - AutoGenerateIds bool `json:"autoGenerateIds,omitempty"` +// GoogleCloudDiscoveryengineV1alphaEnableAdvancedSiteSearchRequest: +// Request message for SiteSearchEngineService.EnableAdvancedSiteSearch +// method. +type GoogleCloudDiscoveryengineV1alphaEnableAdvancedSiteSearchRequest struct { +} - // BigquerySource: BigQuery input source. - BigquerySource *GoogleCloudDiscoveryengineV1alphaBigQuerySource `json:"bigquerySource,omitempty"` +// GoogleCloudDiscoveryengineV1alphaEnableAdvancedSiteSearchResponse: +// Response message for SiteSearchEngineService.EnableAdvancedSiteSearch +// method. +type GoogleCloudDiscoveryengineV1alphaEnableAdvancedSiteSearchResponse struct { +} - // ErrorConfig: The desired location of errors incurred during the - // Import. - ErrorConfig *GoogleCloudDiscoveryengineV1alphaImportErrorConfig `json:"errorConfig,omitempty"` +// GoogleCloudDiscoveryengineV1alphaEngine: Metadata that describes the +// training and serving parameters of an Engine. +type GoogleCloudDiscoveryengineV1alphaEngine struct { + // ChatEngineConfig: Configurations for the Chat Engine. Only applicable + // if solution_type is SOLUTION_TYPE_CHAT. + ChatEngineConfig *GoogleCloudDiscoveryengineV1alphaEngineChatEngineConfig `json:"chatEngineConfig,omitempty"` - // GcsSource: Cloud Storage location for the input content. - GcsSource *GoogleCloudDiscoveryengineV1alphaGcsSource `json:"gcsSource,omitempty"` + // ChatEngineMetadata: Output only. Additional information of the Chat + // Engine. Only applicable if solution_type is SOLUTION_TYPE_CHAT. + ChatEngineMetadata *GoogleCloudDiscoveryengineV1alphaEngineChatEngineMetadata `json:"chatEngineMetadata,omitempty"` - // IdField: The field in the Cloud Storage and BigQuery sources that - // indicates the unique IDs of the documents. For GcsSource it is the - // key of the JSON field. For instance, `my_id` for JSON `{"my_id": - // "some_uuid"}`. For BigQuerySource it is the column name of the - // BigQuery table where the unique ids are stored. The values of the - // JSON field or the BigQuery column are used as the Document.ids. The - // JSON field or the BigQuery column must be of string type, and the - // values must be set as valid strings conform to RFC-1034 - // (https://tools.ietf.org/html/rfc1034) with 1-63 characters. - // Otherwise, documents without valid IDs fail to be imported. Only set - // this field when using GcsSource or BigQuerySource, and when - // GcsSource.data_schema or BigQuerySource.data_schema is `custom`. And - // only set this field when auto_generate_ids is unset or set as - // `false`. Otherwise, an INVALID_ARGUMENT error is thrown. If it is - // unset, a default value `_id` is used when importing from the allowed - // data sources. - IdField string `json:"idField,omitempty"` + // CommonConfig: Common config spec that specifies the metadata of the + // engine. + CommonConfig *GoogleCloudDiscoveryengineV1alphaEngineCommonConfig `json:"commonConfig,omitempty"` - // InlineSource: The Inline source for the input content for documents. - InlineSource *GoogleCloudDiscoveryengineV1alphaImportDocumentsRequestInlineSource `json:"inlineSource,omitempty"` + // CreateTime: Output only. Timestamp the Recommendation Engine was + // created at. + CreateTime string `json:"createTime,omitempty"` - // ReconciliationMode: The mode of reconciliation between existing - // documents and the documents to be imported. Defaults to - // ReconciliationMode.INCREMENTAL. + // DataStoreIds: The data stores associated with this engine. For + // SOLUTION_TYPE_SEARCH and SOLUTION_TYPE_RECOMMENDATION type of + // engines, they can only associate with at most one data store. If + // solution_type is SOLUTION_TYPE_CHAT, multiple DataStores in the same + // Collection can be associated here. Note that when used in + // CreateEngineRequest, one DataStore id must be provided as the system + // will use it for necessary initializations. + DataStoreIds []string `json:"dataStoreIds,omitempty"` + + // DisplayName: Required. The display name of the engine. Should be + // human readable. UTF-8 encoded string with limit of 1024 characters. + DisplayName string `json:"displayName,omitempty"` + + // IndustryVertical: The industry vertical that the engine registers. + // The restriction of the Engine industry vertical is based on + // DataStore: If unspecified, default to `GENERIC`. Vertical on Engine + // has to match vertical of the DataStore liniked to the engine. // // Possible values: - // "RECONCILIATION_MODE_UNSPECIFIED" - Defaults to `INCREMENTAL`. - // "INCREMENTAL" - Inserts new documents or updates existing - // documents. - // "FULL" - Calculates diff and replaces the entire document dataset. - // Existing documents may be deleted if they are not present in the - // source location. - ReconciliationMode string `json:"reconciliationMode,omitempty"` + // "INDUSTRY_VERTICAL_UNSPECIFIED" - Value used when unset. + // "GENERIC" - The generic vertical for documents that are not + // specific to any industry vertical. + // "MEDIA" - The media industry vertical. + IndustryVertical string `json:"industryVertical,omitempty"` - // ForceSendFields is a list of field names (e.g. "AutoGenerateIds") to + // MediaRecommendationEngineConfig: Configurations for the Media Engine. + // Only applicable on the data stores with solution_type + // SOLUTION_TYPE_RECOMMENDATION and IndustryVertical.MEDIA vertical. + MediaRecommendationEngineConfig *GoogleCloudDiscoveryengineV1alphaEngineMediaRecommendationEngineConfig `json:"mediaRecommendationEngineConfig,omitempty"` + + // Name: Immutable. The fully qualified resource name of the engine. + // This field must be a UTF-8 encoded string with a length limit of 1024 + // characters. Format: + // `projects/{project_number}/locations/{location}/collections/{collectio + // n}/engines/{engine}` engine should be 1-63 characters, and valid + // characters are /a-z0-9*/. Otherwise, an INVALID_ARGUMENT error is + // returned. + Name string `json:"name,omitempty"` + + // RecommendationMetadata: Output only. Additional information of a + // recommendation engine. Only applicable if solution_type is + // SOLUTION_TYPE_RECOMMENDATION. + RecommendationMetadata *GoogleCloudDiscoveryengineV1alphaEngineRecommendationMetadata `json:"recommendationMetadata,omitempty"` + + // SearchEngineConfig: Configurations for the Search Engine. Only + // applicable if solution_type is SOLUTION_TYPE_SEARCH. + SearchEngineConfig *GoogleCloudDiscoveryengineV1alphaEngineSearchEngineConfig `json:"searchEngineConfig,omitempty"` + + // SimilarDocumentsConfig: Additional config specs for a `similar-items` + // engine. + SimilarDocumentsConfig *GoogleCloudDiscoveryengineV1alphaEngineSimilarDocumentsEngineConfig `json:"similarDocumentsConfig,omitempty"` + + // SolutionType: Required. The solutions of the engine. + // + // Possible values: + // "SOLUTION_TYPE_UNSPECIFIED" - Default value. + // "SOLUTION_TYPE_RECOMMENDATION" - Used for Recommendations AI. + // "SOLUTION_TYPE_SEARCH" - Used for Discovery Search. + // "SOLUTION_TYPE_CHAT" - Used for use cases related to the Generative + // AI agent. + SolutionType string `json:"solutionType,omitempty"` + + // UpdateTime: Output only. Timestamp the Recommendation Engine was last + // updated. + UpdateTime string `json:"updateTime,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the + // server. + googleapi.ServerResponse `json:"-"` + + // ForceSendFields is a list of field names (e.g. "ChatEngineConfig") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -4039,7 +4021,7 @@ type GoogleCloudDiscoveryengineV1alphaImportDocumentsRequest struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "AutoGenerateIds") to + // NullFields is a list of field names (e.g. "ChatEngineConfig") to // include in API requests with the JSON null value. By default, fields // with empty values are omitted from API requests. However, any field // with an empty value appearing in NullFields will be sent to the @@ -4049,57 +4031,88 @@ type GoogleCloudDiscoveryengineV1alphaImportDocumentsRequest struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaImportDocumentsRequest) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaImportDocumentsRequest +func (s *GoogleCloudDiscoveryengineV1alphaEngine) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaEngine raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaImportDocumentsRequestInlineSource: -// The inline source for the input config for ImportDocuments method. -type GoogleCloudDiscoveryengineV1alphaImportDocumentsRequestInlineSource struct { - // Documents: Required. A list of documents to update/create. Each - // document must have a valid Document.id. Recommended max of 100 items. - Documents []*GoogleCloudDiscoveryengineV1alphaDocument `json:"documents,omitempty"` +// GoogleCloudDiscoveryengineV1alphaEngineChatEngineConfig: +// Configurations for a Chat Engine. +type GoogleCloudDiscoveryengineV1alphaEngineChatEngineConfig struct { + // AgentCreationConfig: The configurationt generate the Dialogflow agent + // that is associated to this Engine. Note that these configurations are + // one-time consumed by and passed to Dialogflow service. It means they + // cannot be retrieved using EngineService.GetEngine or + // EngineService.ListEngines API after engine creation. + AgentCreationConfig *GoogleCloudDiscoveryengineV1alphaEngineChatEngineConfigAgentCreationConfig `json:"agentCreationConfig,omitempty"` - // ForceSendFields is a list of field names (e.g. "Documents") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be + // DialogflowAgentToLink: The resource name of an exist Dialogflow agent + // to link to this Chat Engine. Customers can either provide + // `agent_creation_config` to create agent or provide an agent name that + // links the agent with the Chat engine. Format: + // `projects//locations//agents/`. Note that the + // `dialogflow_agent_to_link` are one-time consumed by and passed to + // Dialogflow service. It means they cannot be retrieved using + // EngineService.GetEngine or EngineService.ListEngines API after engine + // creation. Please use ChatEngineMetadata.dialogflow_agent for actual + // agent association after Engine is created. + DialogflowAgentToLink string `json:"dialogflowAgentToLink,omitempty"` + + // ForceSendFields is a list of field names (e.g. "AgentCreationConfig") + // to unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be // sent to the server regardless of whether the field is empty or not. // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Documents") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "AgentCreationConfig") to + // include in API requests with the JSON null value. By default, fields + // with empty values are omitted from API requests. However, any field + // with an empty value appearing in NullFields will be sent to the + // server as null. It is an error if a field in this list has a + // non-empty value. This may be used to include null fields in Patch + // requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaImportDocumentsRequestInlineSource) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaImportDocumentsRequestInlineSource +func (s *GoogleCloudDiscoveryengineV1alphaEngineChatEngineConfig) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaEngineChatEngineConfig raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaImportDocumentsResponse: Response of -// the ImportDocumentsRequest. If the long running operation is done, -// then this message is returned by the -// google.longrunning.Operations.response field if the operation was -// successful. -type GoogleCloudDiscoveryengineV1alphaImportDocumentsResponse struct { - // ErrorConfig: Echoes the destination for the complete errors in the - // request if set. - ErrorConfig *GoogleCloudDiscoveryengineV1alphaImportErrorConfig `json:"errorConfig,omitempty"` +// GoogleCloudDiscoveryengineV1alphaEngineChatEngineConfigAgentCreationCo +// nfig: Configurations for generating a Dialogflow agent. Note that +// these configurations are one-time consumed by and passed to +// Dialogflow service. It means they cannot be retrieved using +// EngineService.GetEngine or EngineService.ListEngines API after engine +// creation. +type GoogleCloudDiscoveryengineV1alphaEngineChatEngineConfigAgentCreationConfig struct { + // Business: Name of the company, organization or other entity that the + // agent represents. Used for knowledge connector LLM prompt and for + // knowledge search. + Business string `json:"business,omitempty"` - // ErrorSamples: A sample of errors encountered while processing the - // request. - ErrorSamples []*GoogleRpcStatus `json:"errorSamples,omitempty"` + // DefaultLanguageCode: Required. The default language of the agent as a + // language tag. See Language Support + // (https://cloud.google.com/dialogflow/docs/reference/language) for a + // list of the currently supported language codes. + DefaultLanguageCode string `json:"defaultLanguageCode,omitempty"` - // ForceSendFields is a list of field names (e.g. "ErrorConfig") to + // Location: Agent location for Agent creation, supported values: + // global/us/eu. If not provided, us Engine will create Agent using + // us-central-1 by default; eu Engine will create Agent using eu-west-1 + // by default. + Location string `json:"location,omitempty"` + + // TimeZone: Required. The time zone of the agent from the time zone + // database (https://www.iana.org/time-zones), e.g., America/New_York, + // Europe/Paris. + TimeZone string `json:"timeZone,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Business") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -4107,31 +4120,29 @@ type GoogleCloudDiscoveryengineV1alphaImportDocumentsResponse struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "ErrorConfig") to include - // in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. However, any field with - // an empty value appearing in NullFields will be sent to the server as + // NullFields is a list of field names (e.g. "Business") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaImportDocumentsResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaImportDocumentsResponse +func (s *GoogleCloudDiscoveryengineV1alphaEngineChatEngineConfigAgentCreationConfig) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaEngineChatEngineConfigAgentCreationConfig raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaImportErrorConfig: Configuration of -// destination for Import related errors. -type GoogleCloudDiscoveryengineV1alphaImportErrorConfig struct { - // GcsPrefix: Cloud Storage prefix for import errors. This must be an - // empty, existing Cloud Storage directory. Import errors are written to - // sharded files in this directory, one per line, as a JSON-encoded - // `google.rpc.Status` message. - GcsPrefix string `json:"gcsPrefix,omitempty"` +// GoogleCloudDiscoveryengineV1alphaEngineChatEngineMetadata: Additional +// information of a Chat Engine. Fields in this message are output only. +type GoogleCloudDiscoveryengineV1alphaEngineChatEngineMetadata struct { + // DialogflowAgent: The resource name of a Dialogflow agent, that this + // Chat Engine refers to. Format: `projects//locations//agents/`. + DialogflowAgent string `json:"dialogflowAgent,omitempty"` - // ForceSendFields is a list of field names (e.g. "GcsPrefix") to + // ForceSendFields is a list of field names (e.g. "DialogflowAgent") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -4139,34 +4150,31 @@ type GoogleCloudDiscoveryengineV1alphaImportErrorConfig struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "GcsPrefix") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "DialogflowAgent") to + // include in API requests with the JSON null value. By default, fields + // with empty values are omitted from API requests. However, any field + // with an empty value appearing in NullFields will be sent to the + // server as null. It is an error if a field in this list has a + // non-empty value. This may be used to include null fields in Patch + // requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaImportErrorConfig) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaImportErrorConfig +func (s *GoogleCloudDiscoveryengineV1alphaEngineChatEngineMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaEngineChatEngineMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesMetada -// ta: Metadata related to the progress of the -// ImportSuggestionDenyListEntries operation. This is returned by the -// google.longrunning.Operation.metadata field. -type GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesMetadata 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"` +// GoogleCloudDiscoveryengineV1alphaEngineCommonConfig: Common +// configurations for an Engine. +type GoogleCloudDiscoveryengineV1alphaEngineCommonConfig struct { + // CompanyName: Immutable. The name of the company, business or entity + // that is associated with the engine. Setting this may help improve LLM + // related features. + CompanyName string `json:"companyName,omitempty"` - // ForceSendFields is a list of field names (e.g. "CreateTime") to + // ForceSendFields is a list of field names (e.g. "CompanyName") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -4174,67 +4182,100 @@ type GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesMetadata st // This may be used to include empty fields in Patch requests. 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. However, any field with an - // empty value appearing in NullFields will be sent to the server as + // NullFields is a list of field names (e.g. "CompanyName") to include + // in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. However, any field with + // an empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesMetadata +func (s *GoogleCloudDiscoveryengineV1alphaEngineCommonConfig) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaEngineCommonConfig raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesReques -// t: Request message for -// CompletionService.ImportSuggestionDenyListEntries method. -type GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesRequest struct { - // GcsSource: Cloud Storage location for the input content. Only 1 file - // can be specified that contains all entries to import. Supported - // values `gcs_source.schema` for autocomplete suggestion deny list - // entry imports: * `suggestion_deny_list` (default): One JSON - // [SuggestionDenyListEntry] per line. - GcsSource *GoogleCloudDiscoveryengineV1alphaGcsSource `json:"gcsSource,omitempty"` +// GoogleCloudDiscoveryengineV1alphaEngineMediaRecommendationEngineConfig +// : Additional config specs for a Media Recommendation engine. +type GoogleCloudDiscoveryengineV1alphaEngineMediaRecommendationEngineConfig struct { + // OptimizationObjective: The optimization objective. e.g., `cvr`. This + // field together with optimization_objective describe engine metadata + // to use to control engine training and serving. Currently supported + // values: `ctr`, `cvr`. If not specified, we choose default based on + // engine type. Default depends on type of recommendation: + // `recommended-for-you` => `ctr` `others-you-may-like` => `ctr` + OptimizationObjective string `json:"optimizationObjective,omitempty"` - // InlineSource: The Inline source for the input content for suggestion - // deny list entries. - InlineSource *GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesRequestInlineSource `json:"inlineSource,omitempty"` + // OptimizationObjectiveConfig: Name and value of the custom threshold + // for cvr optimization_objective. For target_field `watch-time`, + // target_field_value must be an integer value indicating the media + // progress time in seconds between (0, 86400] (excludes 0, includes + // 86400) (e.g., 90). For target_field `watch-percentage`, the + // target_field_value must be a valid float value between (0, 1.0] + // (excludes 0, includes 1.0) (e.g., 0.5). + OptimizationObjectiveConfig *GoogleCloudDiscoveryengineV1alphaEngineMediaRecommendationEngineConfigOptimizationObjectiveConfig `json:"optimizationObjectiveConfig,omitempty"` - // ForceSendFields is a list of field names (e.g. "GcsSource") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // TrainingState: The training state that the engine is in (e.g. + // `TRAINING` or `PAUSED`). Since part of the cost of running the + // service is frequency of training - this can be used to determine when + // to train engine in order to control cost. If not specified: the + // default value for `CreateEngine` method is `TRAINING`. The default + // value for `UpdateEngine` method is to keep the state the same as + // before. + // + // Possible values: + // "TRAINING_STATE_UNSPECIFIED" - Unspecified training state. + // "PAUSED" - The engine training is paused. + // "TRAINING" - The engine is training. + TrainingState string `json:"trainingState,omitempty"` + + // Type: Required. The type of engine. e.g., `recommended-for-you`. This + // field together with optimization_objective describe engine metadata + // to use to control engine training and serving. Currently supported + // values: `recommended-for-you`, `others-you-may-like`, + // `more-like-this`, `most-popular-items`. + Type string `json:"type,omitempty"` + + // ForceSendFields is a list of field names (e.g. + // "OptimizationObjective") to unconditionally include in API requests. + // By default, fields with empty or default values are omitted from API + // requests. However, any non-pointer, non-interface field appearing in + // ForceSendFields will be sent to the server regardless of whether the + // field is empty or not. This may be used to include empty fields in + // Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "GcsSource") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "OptimizationObjective") to + // include in API requests with the JSON null value. By default, fields + // with empty values are omitted from API requests. However, any field + // with an empty value appearing in NullFields will be sent to the + // server as null. It is an error if a field in this list has a + // non-empty value. This may be used to include null fields in Patch + // requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesRequest) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesRequest +func (s *GoogleCloudDiscoveryengineV1alphaEngineMediaRecommendationEngineConfig) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaEngineMediaRecommendationEngineConfig raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesReques -// tInlineSource: The inline source for SuggestionDenyListEntry. -type GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesRequestInlineSource struct { - // Entries: Required. A list of all denylist entries to import. Max of - // 1000 items. - Entries []*GoogleCloudDiscoveryengineV1alphaSuggestionDenyListEntry `json:"entries,omitempty"` +// GoogleCloudDiscoveryengineV1alphaEngineMediaRecommendationEngineConfig +// OptimizationObjectiveConfig: Custom threshold for `cvr` +// optimization_objective. +type GoogleCloudDiscoveryengineV1alphaEngineMediaRecommendationEngineConfigOptimizationObjectiveConfig struct { + // TargetField: Required. The name of the field to target. Currently + // supported values: `watch-percentage`, `watch-time`. + TargetField string `json:"targetField,omitempty"` - // ForceSendFields is a list of field names (e.g. "Entries") to + // TargetFieldValueFloat: Required. The threshold to be applied to the + // target (e.g., 0.5). + TargetFieldValueFloat float64 `json:"targetFieldValueFloat,omitempty"` + + // ForceSendFields is a list of field names (e.g. "TargetField") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -4242,38 +4283,78 @@ type GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesRequestInli // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Entries") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as + // NullFields is a list of field names (e.g. "TargetField") to include + // in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. However, any field with + // an empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesRequestInlineSource) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesRequestInlineSource +func (s *GoogleCloudDiscoveryengineV1alphaEngineMediaRecommendationEngineConfigOptimizationObjectiveConfig) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaEngineMediaRecommendationEngineConfigOptimizationObjectiveConfig raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesRespon -// se: Response message for -// CompletionService.ImportSuggestionDenyListEntries method. -type GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesResponse struct { - // ErrorSamples: A sample of errors encountered while processing the - // request. - ErrorSamples []*GoogleRpcStatus `json:"errorSamples,omitempty"` +func (s *GoogleCloudDiscoveryengineV1alphaEngineMediaRecommendationEngineConfigOptimizationObjectiveConfig) UnmarshalJSON(data []byte) error { + type NoMethod GoogleCloudDiscoveryengineV1alphaEngineMediaRecommendationEngineConfigOptimizationObjectiveConfig + var s1 struct { + TargetFieldValueFloat gensupport.JSONFloat64 `json:"targetFieldValueFloat"` + *NoMethod + } + s1.NoMethod = (*NoMethod)(s) + if err := json.Unmarshal(data, &s1); err != nil { + return err + } + s.TargetFieldValueFloat = float64(s1.TargetFieldValueFloat) + return nil +} - // FailedEntriesCount: Count of deny list entries that failed to be - // imported. - FailedEntriesCount int64 `json:"failedEntriesCount,omitempty,string"` +// GoogleCloudDiscoveryengineV1alphaEngineRecommendationMetadata: +// Additional information of a recommendation engine. +type GoogleCloudDiscoveryengineV1alphaEngineRecommendationMetadata struct { + // DataState: Output only. The state of data requirements for this + // engine: `DATA_OK` and `DATA_ERROR`. Engine cannot be trained if the + // data is in `DATA_ERROR` state. Engine can have `DATA_ERROR` state + // even if serving state is `ACTIVE`: engines were trained successfully + // before, but cannot be refreshed because the underlying engine no + // longer has sufficient data for training. + // + // Possible values: + // "DATA_STATE_UNSPECIFIED" - Unspecified default value, should never + // be explicitly set. + // "DATA_OK" - The engine has sufficient training data. + // "DATA_ERROR" - The engine does not have sufficient training data. + // Error messages can be queried via Stackdriver. + DataState string `json:"dataState,omitempty"` - // ImportedEntriesCount: Count of deny list entries successfully - // imported. - ImportedEntriesCount int64 `json:"importedEntriesCount,omitempty,string"` + // LastTuneTime: Output only. The timestamp when the latest successful + // tune finished. Only applicable on Media Recommendation engines. + LastTuneTime string `json:"lastTuneTime,omitempty"` - // ForceSendFields is a list of field names (e.g. "ErrorSamples") to + // ServingState: Output only. The serving state of the engine: `ACTIVE`, + // `NOT_ACTIVE`. + // + // Possible values: + // "SERVING_STATE_UNSPECIFIED" - Unspecified serving state. + // "INACTIVE" - The engine is not serving. + // "ACTIVE" - The engine is serving and can be queried. + // "TUNED" - The engine is trained on tuned hyperparameters and can be + // queried. + ServingState string `json:"servingState,omitempty"` + + // TuningOperation: Output only. The latest tune operation id associated + // with the engine. Only applicable on Media Recommendation engines. If + // present, this operation id can be used to determine if there is an + // ongoing tune for this engine. To check the operation status, send the + // GetOperation request with this operation id in the engine resource + // format. If no tuning has happened for this engine, the string is + // empty. + TuningOperation string `json:"tuningOperation,omitempty"` + + // ForceSendFields is a list of field names (e.g. "DataState") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -4281,7 +4362,53 @@ type GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesResponse st // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "ErrorSamples") to include + // NullFields is a list of field names (e.g. "DataState") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1alphaEngineRecommendationMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaEngineRecommendationMetadata + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaEngineSearchEngineConfig: +// Configurations for a Search Engine. +type GoogleCloudDiscoveryengineV1alphaEngineSearchEngineConfig struct { + // SearchAddOns: The add-on that this search engine enables. + // + // Possible values: + // "SEARCH_ADD_ON_UNSPECIFIED" - Default value when the enum is + // unspecified. This is invalid to use. + // "SEARCH_ADD_ON_LLM" - Large language model add-on. + SearchAddOns []string `json:"searchAddOns,omitempty"` + + // SearchTier: The search feature tier of this engine. Different tiers + // might have different pricing. To learn more, please check the pricing + // documentation. Defaults to SearchTier.SEARCH_TIER_STANDARD if not + // specified. + // + // Possible values: + // "SEARCH_TIER_UNSPECIFIED" - Default value when the enum is + // unspecified. This is invalid to use. + // "SEARCH_TIER_STANDARD" - Standard tier. + // "SEARCH_TIER_ENTERPRISE" - Enterprise tier. + SearchTier string `json:"searchTier,omitempty"` + + // ForceSendFields is a list of field names (e.g. "SearchAddOns") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "SearchAddOns") to include // in API requests with the JSON null value. By default, fields with // empty values are omitted from API requests. However, any field with // an empty value appearing in NullFields will be sent to the server as @@ -4290,30 +4417,24 @@ type GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesResponse st NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesResponse +func (s *GoogleCloudDiscoveryengineV1alphaEngineSearchEngineConfig) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaEngineSearchEngineConfig raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaImportUserEventsMetadata: Metadata -// related to the progress of the Import operation. This is returned by -// the google.longrunning.Operation.metadata field. -type GoogleCloudDiscoveryengineV1alphaImportUserEventsMetadata struct { +// GoogleCloudDiscoveryengineV1alphaEngineSimilarDocumentsEngineConfig: +// Additional config specs for a `similar-items` engine. +type GoogleCloudDiscoveryengineV1alphaEngineSimilarDocumentsEngineConfig struct { +} + +// GoogleCloudDiscoveryengineV1alphaEstimateDataSizeMetadata: Metadata +// related to the progress of the EstimateDataSize operation. This is +// returned by the google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1alphaEstimateDataSizeMetadata struct { // CreateTime: Operation create time. CreateTime string `json:"createTime,omitempty"` - // FailureCount: Count of entries that encountered errors while - // processing. - FailureCount int64 `json:"failureCount,omitempty,string"` - - // SuccessCount: Count of entries that were processed successfully. - SuccessCount int64 `json:"successCount,omitempty,string"` - - // 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. However, any @@ -4331,29 +4452,22 @@ type GoogleCloudDiscoveryengineV1alphaImportUserEventsMetadata struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaImportUserEventsMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaImportUserEventsMetadata +func (s *GoogleCloudDiscoveryengineV1alphaEstimateDataSizeMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaEstimateDataSizeMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaImportUserEventsRequest: Request -// message for the ImportUserEvents request. -type GoogleCloudDiscoveryengineV1alphaImportUserEventsRequest struct { - // BigquerySource: BigQuery input source. - BigquerySource *GoogleCloudDiscoveryengineV1alphaBigQuerySource `json:"bigquerySource,omitempty"` - - // ErrorConfig: The desired location of errors incurred during the - // Import. Cannot be set for inline user event imports. - ErrorConfig *GoogleCloudDiscoveryengineV1alphaImportErrorConfig `json:"errorConfig,omitempty"` - - // GcsSource: Cloud Storage location for the input content. - GcsSource *GoogleCloudDiscoveryengineV1alphaGcsSource `json:"gcsSource,omitempty"` +// GoogleCloudDiscoveryengineV1alphaEstimateDataSizeRequest: Request +// message for EstimateBillingService.EstimateDataSize method +type GoogleCloudDiscoveryengineV1alphaEstimateDataSizeRequest struct { + // FileDataSource: Structured or unstructured data. + FileDataSource *GoogleCloudDiscoveryengineV1alphaEstimateDataSizeRequestFileDataSource `json:"fileDataSource,omitempty"` - // InlineSource: The Inline source for the input content for UserEvents. - InlineSource *GoogleCloudDiscoveryengineV1alphaImportUserEventsRequestInlineSource `json:"inlineSource,omitempty"` + // WebsiteDataSource: Website data. + WebsiteDataSource *GoogleCloudDiscoveryengineV1alphaEstimateDataSizeRequestWebsiteDataSource `json:"websiteDataSource,omitempty"` - // ForceSendFields is a list of field names (e.g. "BigquerySource") to + // ForceSendFields is a list of field names (e.g. "FileDataSource") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -4361,7 +4475,7 @@ type GoogleCloudDiscoveryengineV1alphaImportUserEventsRequest struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "BigquerySource") to + // NullFields is a list of field names (e.g. "FileDataSource") to // include in API requests with the JSON null value. By default, fields // with empty values are omitted from API requests. However, any field // with an empty value appearing in NullFields will be sent to the @@ -4371,20 +4485,22 @@ type GoogleCloudDiscoveryengineV1alphaImportUserEventsRequest struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaImportUserEventsRequest) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaImportUserEventsRequest +func (s *GoogleCloudDiscoveryengineV1alphaEstimateDataSizeRequest) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaEstimateDataSizeRequest raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaImportUserEventsRequestInlineSource: -// The inline source for the input config for ImportUserEvents method. -type GoogleCloudDiscoveryengineV1alphaImportUserEventsRequestInlineSource struct { - // UserEvents: Required. A list of user events to import. Recommended - // max of 10k items. - UserEvents []*GoogleCloudDiscoveryengineV1alphaUserEvent `json:"userEvents,omitempty"` +// GoogleCloudDiscoveryengineV1alphaEstimateDataSizeRequestFileDataSource +// : Data source contains files either in Cloud Storage or BigQuery. +type GoogleCloudDiscoveryengineV1alphaEstimateDataSizeRequestFileDataSource struct { + // BigquerySource: BigQuery input source. + BigquerySource *GoogleCloudDiscoveryengineV1alphaBigQuerySource `json:"bigquerySource,omitempty"` - // ForceSendFields is a list of field names (e.g. "UserEvents") to + // GcsSource: Cloud Storage location for the input content. + GcsSource *GoogleCloudDiscoveryengineV1alphaGcsSource `json:"gcsSource,omitempty"` + + // ForceSendFields is a list of field names (e.g. "BigquerySource") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -4392,89 +4508,41 @@ type GoogleCloudDiscoveryengineV1alphaImportUserEventsRequestInlineSource struct // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "UserEvents") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "BigquerySource") to + // include in API requests with the JSON null value. By default, fields + // with empty values are omitted from API requests. However, any field + // with an empty value appearing in NullFields will be sent to the + // server as null. It is an error if a field in this list has a + // non-empty value. This may be used to include null fields in Patch + // requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaImportUserEventsRequestInlineSource) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaImportUserEventsRequestInlineSource +func (s *GoogleCloudDiscoveryengineV1alphaEstimateDataSizeRequestFileDataSource) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaEstimateDataSizeRequestFileDataSource raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaImportUserEventsResponse: Response -// of the ImportUserEventsRequest. If the long running operation was -// successful, then this message is returned by the -// google.longrunning.Operations.response field if the operation was -// successful. -type GoogleCloudDiscoveryengineV1alphaImportUserEventsResponse struct { - // ErrorConfig: Echoes the destination for the complete errors if this - // field was set in the request. - ErrorConfig *GoogleCloudDiscoveryengineV1alphaImportErrorConfig `json:"errorConfig,omitempty"` - - // ErrorSamples: A sample of errors encountered while processing the - // request. - ErrorSamples []*GoogleRpcStatus `json:"errorSamples,omitempty"` - - // JoinedEventsCount: Count of user events imported with complete - // existing Documents. - JoinedEventsCount int64 `json:"joinedEventsCount,omitempty,string"` - - // UnjoinedEventsCount: Count of user events imported, but with Document - // information not found in the existing Branch. - UnjoinedEventsCount int64 `json:"unjoinedEventsCount,omitempty,string"` +// GoogleCloudDiscoveryengineV1alphaEstimateDataSizeRequestWebsiteDataSou +// rce: Data source is a set of website patterns that we crawl to get +// the total number of websites. +type GoogleCloudDiscoveryengineV1alphaEstimateDataSizeRequestWebsiteDataSource struct { + // EstimatorUriPatterns: Required. The URI patterns to estimate the data + // sizes. At most 10 patterns are allowed, otherwise an INVALID_ARGUMENT + // error is thrown. + EstimatorUriPatterns []*GoogleCloudDiscoveryengineV1alphaEstimateDataSizeRequestWebsiteDataSourceEstimatorUriPattern `json:"estimatorUriPatterns,omitempty"` - // ForceSendFields is a list of field names (e.g. "ErrorConfig") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. + // "EstimatorUriPatterns") to unconditionally include in API requests. + // By default, fields with empty or default values are omitted from API + // requests. However, any non-pointer, non-interface field appearing in + // ForceSendFields will be sent to the server regardless of whether the + // field is empty or not. This may be used to include empty fields in + // Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "ErrorConfig") to include - // in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. However, any field with - // an empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. - NullFields []string `json:"-"` -} - -func (s *GoogleCloudDiscoveryengineV1alphaImportUserEventsResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaImportUserEventsResponse - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) -} - -// GoogleCloudDiscoveryengineV1alphaInterval: A floating point interval. -type GoogleCloudDiscoveryengineV1alphaInterval struct { - // ExclusiveMaximum: Exclusive upper bound. - ExclusiveMaximum float64 `json:"exclusiveMaximum,omitempty"` - - // ExclusiveMinimum: Exclusive lower bound. - ExclusiveMinimum float64 `json:"exclusiveMinimum,omitempty"` - - // Maximum: Inclusive upper bound. - Maximum float64 `json:"maximum,omitempty"` - - // Minimum: Inclusive lower bound. - Minimum float64 `json:"minimum,omitempty"` - - // ForceSendFields is a list of field names (e.g. "ExclusiveMaximum") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. - ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "ExclusiveMaximum") to + // NullFields is a list of field names (e.g. "EstimatorUriPatterns") to // include in API requests with the JSON null value. By default, fields // with empty values are omitted from API requests. However, any field // with an empty value appearing in NullFields will be sent to the @@ -4484,159 +4552,29 @@ type GoogleCloudDiscoveryengineV1alphaInterval struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaInterval) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaInterval - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) -} - -func (s *GoogleCloudDiscoveryengineV1alphaInterval) UnmarshalJSON(data []byte) error { - type NoMethod GoogleCloudDiscoveryengineV1alphaInterval - var s1 struct { - ExclusiveMaximum gensupport.JSONFloat64 `json:"exclusiveMaximum"` - ExclusiveMinimum gensupport.JSONFloat64 `json:"exclusiveMinimum"` - Maximum gensupport.JSONFloat64 `json:"maximum"` - Minimum gensupport.JSONFloat64 `json:"minimum"` - *NoMethod - } - s1.NoMethod = (*NoMethod)(s) - if err := json.Unmarshal(data, &s1); err != nil { - return err - } - s.ExclusiveMaximum = float64(s1.ExclusiveMaximum) - s.ExclusiveMinimum = float64(s1.ExclusiveMinimum) - s.Maximum = float64(s1.Maximum) - s.Minimum = float64(s1.Minimum) - return nil -} - -// GoogleCloudDiscoveryengineV1alphaListConversationsResponse: Response -// for ListConversations method. -type GoogleCloudDiscoveryengineV1alphaListConversationsResponse struct { - // Conversations: All the Conversations for a given data store. - Conversations []*GoogleCloudDiscoveryengineV1alphaConversation `json:"conversations,omitempty"` - - // NextPageToken: Pagination token, if not returned indicates the last - // page. - 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. "Conversations") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. - ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Conversations") to include - // in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. However, any field with - // an empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. - NullFields []string `json:"-"` -} - -func (s *GoogleCloudDiscoveryengineV1alphaListConversationsResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaListConversationsResponse - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) -} - -// GoogleCloudDiscoveryengineV1alphaListDataStoresResponse: Response -// message for DataStoreService.ListDataStores method. -type GoogleCloudDiscoveryengineV1alphaListDataStoresResponse struct { - // DataStores: All the customer's DataStores. - DataStores []*GoogleCloudDiscoveryengineV1alphaDataStore `json:"dataStores,omitempty"` - - // NextPageToken: A token that can be sent as - // ListDataStoresRequest.page_token to retrieve the next page. If this - // field is omitted, there are no subsequent pages. - 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. "DataStores") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. - ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "DataStores") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. - NullFields []string `json:"-"` -} - -func (s *GoogleCloudDiscoveryengineV1alphaListDataStoresResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaListDataStoresResponse - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) -} - -// GoogleCloudDiscoveryengineV1alphaListDocumentsResponse: Response -// message for DocumentService.ListDocuments method. -type GoogleCloudDiscoveryengineV1alphaListDocumentsResponse struct { - // Documents: The Documents. - Documents []*GoogleCloudDiscoveryengineV1alphaDocument `json:"documents,omitempty"` - - // NextPageToken: A token that can be sent as - // ListDocumentsRequest.page_token to retrieve the next page. If this - // field is omitted, there are no subsequent pages. - 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. "Documents") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. - ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Documents") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. - NullFields []string `json:"-"` -} - -func (s *GoogleCloudDiscoveryengineV1alphaListDocumentsResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaListDocumentsResponse +func (s *GoogleCloudDiscoveryengineV1alphaEstimateDataSizeRequestWebsiteDataSource) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaEstimateDataSizeRequestWebsiteDataSource raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaListEnginesResponse: Response -// message for EngineService.ListEngines method. -type GoogleCloudDiscoveryengineV1alphaListEnginesResponse struct { - // Engines: All the customer's Engines. - Engines []*GoogleCloudDiscoveryengineV1alphaEngine `json:"engines,omitempty"` +// GoogleCloudDiscoveryengineV1alphaEstimateDataSizeRequestWebsiteDataSou +// rceEstimatorUriPattern: URI patterns that we use to crawl. +type GoogleCloudDiscoveryengineV1alphaEstimateDataSizeRequestWebsiteDataSourceEstimatorUriPattern struct { + // ExactMatch: Whether we infer the generated URI or use the exact + // provided one. + ExactMatch bool `json:"exactMatch,omitempty"` - // NextPageToken: Not supported. - NextPageToken string `json:"nextPageToken,omitempty"` + // Exclusive: Whether the pattern is exclusive or not. If set to true, + // the pattern is considered exclusive. If unset or set to false, the + // pattern is considered inclusive by default. + Exclusive bool `json:"exclusive,omitempty"` - // ServerResponse contains the HTTP response code and headers from the - // server. - googleapi.ServerResponse `json:"-"` + // ProvidedUriPattern: User provided URI pattern. For example, + // `foo.com/bar/*`. + ProvidedUriPattern string `json:"providedUriPattern,omitempty"` - // ForceSendFields is a list of field names (e.g. "Engines") to + // ForceSendFields is a list of field names (e.g. "ExactMatch") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -4644,7 +4582,7 @@ type GoogleCloudDiscoveryengineV1alphaListEnginesResponse struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Engines") to include in + // NullFields is a list of field names (e.g. "ExactMatch") to include in // API requests with the JSON null value. By default, fields with empty // values are omitted from API requests. However, any field with an // empty value appearing in NullFields will be sent to the server as @@ -4653,28 +4591,25 @@ type GoogleCloudDiscoveryengineV1alphaListEnginesResponse struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaListEnginesResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaListEnginesResponse +func (s *GoogleCloudDiscoveryengineV1alphaEstimateDataSizeRequestWebsiteDataSourceEstimatorUriPattern) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaEstimateDataSizeRequestWebsiteDataSourceEstimatorUriPattern raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaListSchemasResponse: Response -// message for SchemaService.ListSchemas method. -type GoogleCloudDiscoveryengineV1alphaListSchemasResponse struct { - // NextPageToken: A token that can be sent as - // ListSchemasRequest.page_token to retrieve the next page. If this - // field is omitted, there are no subsequent pages. - NextPageToken string `json:"nextPageToken,omitempty"` - - // Schemas: The Schemas. - Schemas []*GoogleCloudDiscoveryengineV1alphaSchema `json:"schemas,omitempty"` +// GoogleCloudDiscoveryengineV1alphaEstimateDataSizeResponse: Response +// of the EstimateDataSize request. If the long running operation was +// successful, then this message is returned by the +// google.longrunning.Operations.response field if the operation was +// successful. +type GoogleCloudDiscoveryengineV1alphaEstimateDataSizeResponse struct { + // DataSizeBytes: Data size in terms of bytes. + DataSizeBytes int64 `json:"dataSizeBytes,omitempty,string"` - // ServerResponse contains the HTTP response code and headers from the - // server. - googleapi.ServerResponse `json:"-"` + // DocumentCount: Total number of documents. + DocumentCount int64 `json:"documentCount,omitempty,string"` - // ForceSendFields is a list of field names (e.g. "NextPageToken") to + // ForceSendFields is a list of field names (e.g. "DataSizeBytes") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -4682,7 +4617,7 @@ type GoogleCloudDiscoveryengineV1alphaListSchemasResponse struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "NextPageToken") to include + // NullFields is a list of field names (e.g. "DataSizeBytes") to include // in API requests with the JSON null value. By default, fields with // empty values are omitted from API requests. However, any field with // an empty value appearing in NullFields will be sent to the server as @@ -4691,21 +4626,23 @@ type GoogleCloudDiscoveryengineV1alphaListSchemasResponse struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaListSchemasResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaListSchemasResponse +func (s *GoogleCloudDiscoveryengineV1alphaEstimateDataSizeResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaEstimateDataSizeResponse raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaListTargetSitesResponse: Response -// message for SiteSearchEngineService.ListTargetSites method. -type GoogleCloudDiscoveryengineV1alphaListTargetSitesResponse struct { +// GoogleCloudDiscoveryengineV1alphaFetchDomainVerificationStatusResponse +// : Response message for +// SiteSearchEngineService.FetchDomainVerificationStatus method. +type GoogleCloudDiscoveryengineV1alphaFetchDomainVerificationStatusResponse struct { // NextPageToken: A token that 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"` - // TargetSites: List of TargetSites. + // TargetSites: List of TargetSites containing the site verification + // status. TargetSites []*GoogleCloudDiscoveryengineV1alphaTargetSite `json:"targetSites,omitempty"` // TotalSize: The total number of items matching the request. This will @@ -4733,19 +4670,1830 @@ type GoogleCloudDiscoveryengineV1alphaListTargetSitesResponse struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaListTargetSitesResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaListTargetSitesResponse +func (s *GoogleCloudDiscoveryengineV1alphaFetchDomainVerificationStatusResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaFetchDomainVerificationStatusResponse raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaLookupWidgetConfigRequest: Request -// message for WidgetService.LookupWidgetConfig method. -type GoogleCloudDiscoveryengineV1alphaLookupWidgetConfigRequest struct { - // WidgetConfigId: Required. The UUID of the Widget Config. - WidgetConfigId string `json:"widgetConfigId,omitempty"` +// GoogleCloudDiscoveryengineV1alphaFieldConfig: Configurations for +// fields of a schema. For example, configuring a field is indexable, or +// searchable. +type GoogleCloudDiscoveryengineV1alphaFieldConfig struct { + // CompletableOption: If completable_option is COMPLETABLE_ENABLED, + // field values are directly used and returned as suggestions for + // Autocomplete in CompletionService.CompleteQuery. If + // completable_option is unset, the server behavior defaults to + // COMPLETABLE_DISABLED for fields that support setting completable + // options, which are just `string` fields. For those fields that do not + // support setting completable options, the server will skip completable + // option setting, and setting completable_option for those fields will + // throw `INVALID_ARGUMENT` error. + // + // Possible values: + // "COMPLETABLE_OPTION_UNSPECIFIED" - Value used when unset. + // "COMPLETABLE_ENABLED" - Completable option enabled for a schema + // field. + // "COMPLETABLE_DISABLED" - Completable option disabled for a schema + // field. + CompletableOption string `json:"completableOption,omitempty"` + + // DynamicFacetableOption: If dynamic_facetable_option is + // DYNAMIC_FACETABLE_ENABLED, field values are available for dynamic + // facet. Could only be DYNAMIC_FACETABLE_DISABLED if + // FieldConfig.indexable_option is INDEXABLE_DISABLED. Otherwise, an + // `INVALID_ARGUMENT` error will be returned. If + // dynamic_facetable_option is unset, the server behavior defaults to + // DYNAMIC_FACETABLE_DISABLED for fields that support setting dynamic + // facetable options. For those fields that do not support setting + // dynamic facetable options, such as `object` and `boolean`, the server + // will skip dynamic facetable option setting, and setting + // dynamic_facetable_option for those fields will throw + // `INVALID_ARGUMENT` error. + // + // Possible values: + // "DYNAMIC_FACETABLE_OPTION_UNSPECIFIED" - Value used when unset. + // "DYNAMIC_FACETABLE_ENABLED" - Dynamic facetable option enabled for + // a schema field. + // "DYNAMIC_FACETABLE_DISABLED" - Dynamic facetable option disabled + // for a schema field. + DynamicFacetableOption string `json:"dynamicFacetableOption,omitempty"` + + // FieldPath: Required. Field path of the schema field. For example: + // `title`, `description`, `release_info.release_year`. + FieldPath string `json:"fieldPath,omitempty"` + + // FieldType: Output only. Raw type of the field. + // + // Possible values: + // "FIELD_TYPE_UNSPECIFIED" - Field type is unspecified. + // "OBJECT" - Field value type is Object. + // "STRING" - Field value type is String. + // "NUMBER" - Field value type is Number. + // "INTEGER" - Field value type is Integer. + // "BOOLEAN" - Field value type is Boolean. + // "GEOLOCATION" - Field value type is Geolocation. + // "DATETIME" - Field value type is Datetime. + FieldType string `json:"fieldType,omitempty"` + + // IndexableOption: If indexable_option is INDEXABLE_ENABLED, field + // values are indexed so that it can be filtered or faceted in + // SearchService.Search. If indexable_option is unset, the server + // behavior defaults to INDEXABLE_DISABLED for fields that support + // setting indexable options. For those fields that do not support + // setting indexable options, such as `object` and `boolean` and key + // properties, the server will skip indexable_option setting, and + // setting indexable_option for those fields will throw + // `INVALID_ARGUMENT` error. + // + // Possible values: + // "INDEXABLE_OPTION_UNSPECIFIED" - Value used when unset. + // "INDEXABLE_ENABLED" - Indexable option enabled for a schema field. + // "INDEXABLE_DISABLED" - Indexable option disabled for a schema + // field. + IndexableOption string `json:"indexableOption,omitempty"` + + // KeyPropertyType: Output only. Type of the key property that this + // field is mapped to. Empty string if this is not annotated as mapped + // to a key property. Example types are `title`, `description`. Full + // list is defined by `keyPropertyMapping` in the schema field + // annotation. If the schema field has a `KeyPropertyMapping` + // annotation, `indexable_option` and `searchable_option` of this field + // cannot be modified. + KeyPropertyType string `json:"keyPropertyType,omitempty"` + + // RecsFilterableOption: If recs_filterable_option is + // FILTERABLE_ENABLED, field values are filterable by filter expression + // in RecommendationService.Recommend. If FILTERABLE_ENABLED but the + // field type is numerical, field values are not filterable by text + // queries in RecommendationService.Recommend. Only textual fields are + // supported. If recs_filterable_option is unset, the default setting is + // FILTERABLE_DISABLED for fields that support setting filterable + // options. When a field set to [FILTERABLE_DISABLED] is filtered, a + // warning is generated and an empty result is returned. + // + // Possible values: + // "FILTERABLE_OPTION_UNSPECIFIED" - Value used when unset. + // "FILTERABLE_ENABLED" - Filterable option enabled for a schema + // field. + // "FILTERABLE_DISABLED" - Filterable option disabled for a schema + // field. + RecsFilterableOption string `json:"recsFilterableOption,omitempty"` + + // RetrievableOption: If retrievable_option is RETRIEVABLE_ENABLED, + // field values are included in the search results. If + // retrievable_option is unset, the server behavior defaults to + // RETRIEVABLE_DISABLED for fields that support setting retrievable + // options. For those fields that do not support setting retrievable + // options, such as `object` and `boolean`, the server will skip + // retrievable option setting, and setting retrievable_option for those + // fields will throw `INVALID_ARGUMENT` error. + // + // Possible values: + // "RETRIEVABLE_OPTION_UNSPECIFIED" - Value used when unset. + // "RETRIEVABLE_ENABLED" - Retrievable option enabled for a schema + // field. + // "RETRIEVABLE_DISABLED" - Retrievable option disabled for a schema + // field. + RetrievableOption string `json:"retrievableOption,omitempty"` + + // SearchableOption: If searchable_option is SEARCHABLE_ENABLED, field + // values are searchable by text queries in SearchService.Search. If + // SEARCHABLE_ENABLED but field type is numerical, field values will not + // be searchable by text queries in SearchService.Search, as there are + // no text values associated to numerical fields. If searchable_option + // is unset, the server behavior defaults to SEARCHABLE_DISABLED for + // fields that support setting searchable options. Only `string` fields + // that have no key property mapping support setting searchable_option. + // For those fields that do not support setting searchable options, the + // server will skip searchable option setting, and setting + // searchable_option for those fields will throw `INVALID_ARGUMENT` + // error. + // + // Possible values: + // "SEARCHABLE_OPTION_UNSPECIFIED" - Value used when unset. + // "SEARCHABLE_ENABLED" - Searchable option enabled for a schema + // field. + // "SEARCHABLE_DISABLED" - Searchable option disabled for a schema + // field. + SearchableOption string `json:"searchableOption,omitempty"` + + // ForceSendFields is a list of field names (e.g. "CompletableOption") + // to unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "CompletableOption") to + // include in API requests with the JSON null value. By default, fields + // with empty values are omitted from API requests. However, any field + // with an empty value appearing in NullFields will be sent to the + // server as null. It is an error if a field in this list has a + // non-empty value. This may be used to include null fields in Patch + // requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1alphaFieldConfig) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaFieldConfig + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaGcsSource: Cloud Storage location +// for input content. +type GoogleCloudDiscoveryengineV1alphaGcsSource struct { + // DataSchema: The schema to use when parsing the data from the source. + // Supported values for document imports: * `document` (default): One + // JSON Document per line. Each document must have a valid Document.id. + // * `content`: Unstructured data (e.g. PDF, HTML). Each file matched by + // `input_uris` becomes a document, with the ID set to the first 128 + // bits of SHA256(URI) encoded as a hex string. * `custom`: One custom + // data JSON per row in arbitrary format that conforms to the defined + // Schema of the data store. This can only be used by Gen App Builder. * + // `csv`: A CSV file with header conforming to the defined Schema of the + // data store. Each entry after the header is imported as a Document. + // This can only be used by Gen App Builder. Supported values for user + // even imports: * `user_event` (default): One JSON UserEvent per line. + DataSchema string `json:"dataSchema,omitempty"` + + // InputUris: Required. Cloud Storage URIs to input files. URI can be up + // to 2000 characters long. URIs can match the full object path (for + // example, `gs://bucket/directory/object.json`) or a pattern matching + // one or more files, such as `gs://bucket/directory/*.json`. A request + // can contain at most 100 files (or 100,000 files if `data_schema` is + // `content`). Each file can be up to 2 GB (or 100 MB if `data_schema` + // is `content`). + InputUris []string `json:"inputUris,omitempty"` + + // ForceSendFields is a list of field names (e.g. "DataSchema") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "DataSchema") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1alphaGcsSource) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaGcsSource + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaImportDocumentsMetadata: Metadata +// related to the progress of the ImportDocuments operation. This is +// returned by the google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1alphaImportDocumentsMetadata struct { + // CreateTime: Operation create time. + CreateTime string `json:"createTime,omitempty"` + + // FailureCount: Count of entries that encountered errors while + // processing. + FailureCount int64 `json:"failureCount,omitempty,string"` + + // SuccessCount: Count of entries that were processed successfully. + SuccessCount int64 `json:"successCount,omitempty,string"` + + // 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. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + 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. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1alphaImportDocumentsMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaImportDocumentsMetadata + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaImportDocumentsRequest: Request +// message for Import methods. +type GoogleCloudDiscoveryengineV1alphaImportDocumentsRequest struct { + // AutoGenerateIds: Whether to automatically generate IDs for the + // documents if absent. If set to `true`, Document.ids are automatically + // generated based on the hash of the payload, where IDs may not be + // consistent during multiple imports. In which case + // ReconciliationMode.FULL is highly recommended to avoid duplicate + // contents. If unset or set to `false`, Document.ids have to be + // specified using id_field, otherwise, documents without IDs fail to be + // imported. Only set this field when using GcsSource or BigQuerySource, + // and when GcsSource.data_schema or BigQuerySource.data_schema is + // `custom` or `csv`. Otherwise, an INVALID_ARGUMENT error is thrown. + AutoGenerateIds bool `json:"autoGenerateIds,omitempty"` + + // BigquerySource: BigQuery input source. + BigquerySource *GoogleCloudDiscoveryengineV1alphaBigQuerySource `json:"bigquerySource,omitempty"` + + // ErrorConfig: The desired location of errors incurred during the + // Import. + ErrorConfig *GoogleCloudDiscoveryengineV1alphaImportErrorConfig `json:"errorConfig,omitempty"` + + // GcsSource: Cloud Storage location for the input content. + GcsSource *GoogleCloudDiscoveryengineV1alphaGcsSource `json:"gcsSource,omitempty"` + + // IdField: The field in the Cloud Storage and BigQuery sources that + // indicates the unique IDs of the documents. For GcsSource it is the + // key of the JSON field. For instance, `my_id` for JSON `{"my_id": + // "some_uuid"}`. For BigQuerySource it is the column name of the + // BigQuery table where the unique ids are stored. The values of the + // JSON field or the BigQuery column are used as the Document.ids. The + // JSON field or the BigQuery column must be of string type, and the + // values must be set as valid strings conform to RFC-1034 + // (https://tools.ietf.org/html/rfc1034) with 1-63 characters. + // Otherwise, documents without valid IDs fail to be imported. Only set + // this field when using GcsSource or BigQuerySource, and when + // GcsSource.data_schema or BigQuerySource.data_schema is `custom`. And + // only set this field when auto_generate_ids is unset or set as + // `false`. Otherwise, an INVALID_ARGUMENT error is thrown. If it is + // unset, a default value `_id` is used when importing from the allowed + // data sources. + IdField string `json:"idField,omitempty"` + + // InlineSource: The Inline source for the input content for documents. + InlineSource *GoogleCloudDiscoveryengineV1alphaImportDocumentsRequestInlineSource `json:"inlineSource,omitempty"` + + // ReconciliationMode: The mode of reconciliation between existing + // documents and the documents to be imported. Defaults to + // ReconciliationMode.INCREMENTAL. + // + // Possible values: + // "RECONCILIATION_MODE_UNSPECIFIED" - Defaults to `INCREMENTAL`. + // "INCREMENTAL" - Inserts new documents or updates existing + // documents. + // "FULL" - Calculates diff and replaces the entire document dataset. + // Existing documents may be deleted if they are not present in the + // source location. + ReconciliationMode string `json:"reconciliationMode,omitempty"` + + // ForceSendFields is a list of field names (e.g. "AutoGenerateIds") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "AutoGenerateIds") to + // include in API requests with the JSON null value. By default, fields + // with empty values are omitted from API requests. However, any field + // with an empty value appearing in NullFields will be sent to the + // server as null. It is an error if a field in this list has a + // non-empty value. This may be used to include null fields in Patch + // requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1alphaImportDocumentsRequest) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaImportDocumentsRequest + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaImportDocumentsRequestInlineSource: +// The inline source for the input config for ImportDocuments method. +type GoogleCloudDiscoveryengineV1alphaImportDocumentsRequestInlineSource struct { + // Documents: Required. A list of documents to update/create. Each + // document must have a valid Document.id. Recommended max of 100 items. + Documents []*GoogleCloudDiscoveryengineV1alphaDocument `json:"documents,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Documents") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "Documents") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1alphaImportDocumentsRequestInlineSource) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaImportDocumentsRequestInlineSource + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaImportDocumentsResponse: Response of +// the ImportDocumentsRequest. If the long running operation is done, +// then this message is returned by the +// google.longrunning.Operations.response field if the operation was +// successful. +type GoogleCloudDiscoveryengineV1alphaImportDocumentsResponse struct { + // ErrorConfig: Echoes the destination for the complete errors in the + // request if set. + ErrorConfig *GoogleCloudDiscoveryengineV1alphaImportErrorConfig `json:"errorConfig,omitempty"` + + // ErrorSamples: A sample of errors encountered while processing the + // request. + ErrorSamples []*GoogleRpcStatus `json:"errorSamples,omitempty"` + + // ForceSendFields is a list of field names (e.g. "ErrorConfig") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "ErrorConfig") to include + // in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. However, any field with + // an empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1alphaImportDocumentsResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaImportDocumentsResponse + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaImportErrorConfig: Configuration of +// destination for Import related errors. +type GoogleCloudDiscoveryengineV1alphaImportErrorConfig struct { + // GcsPrefix: Cloud Storage prefix for import errors. This must be an + // empty, existing Cloud Storage directory. Import errors are written to + // sharded files in this directory, one per line, as a JSON-encoded + // `google.rpc.Status` message. + GcsPrefix string `json:"gcsPrefix,omitempty"` + + // ForceSendFields is a list of field names (e.g. "GcsPrefix") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "GcsPrefix") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1alphaImportErrorConfig) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaImportErrorConfig + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesMetada +// ta: Metadata related to the progress of the +// ImportSuggestionDenyListEntries operation. This is returned by the +// google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesMetadata 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. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + 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. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesMetadata + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesReques +// t: Request message for +// CompletionService.ImportSuggestionDenyListEntries method. +type GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesRequest struct { + // GcsSource: Cloud Storage location for the input content. Only 1 file + // can be specified that contains all entries to import. Supported + // values `gcs_source.schema` for autocomplete suggestion deny list + // entry imports: * `suggestion_deny_list` (default): One JSON + // [SuggestionDenyListEntry] per line. + GcsSource *GoogleCloudDiscoveryengineV1alphaGcsSource `json:"gcsSource,omitempty"` + + // InlineSource: The Inline source for the input content for suggestion + // deny list entries. + InlineSource *GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesRequestInlineSource `json:"inlineSource,omitempty"` + + // ForceSendFields is a list of field names (e.g. "GcsSource") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "GcsSource") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesRequest) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesRequest + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesReques +// tInlineSource: The inline source for SuggestionDenyListEntry. +type GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesRequestInlineSource struct { + // Entries: Required. A list of all denylist entries to import. Max of + // 1000 items. + Entries []*GoogleCloudDiscoveryengineV1alphaSuggestionDenyListEntry `json:"entries,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Entries") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "Entries") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesRequestInlineSource) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesRequestInlineSource + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesRespon +// se: Response message for +// CompletionService.ImportSuggestionDenyListEntries method. +type GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesResponse struct { + // ErrorSamples: A sample of errors encountered while processing the + // request. + ErrorSamples []*GoogleRpcStatus `json:"errorSamples,omitempty"` + + // FailedEntriesCount: Count of deny list entries that failed to be + // imported. + FailedEntriesCount int64 `json:"failedEntriesCount,omitempty,string"` + + // ImportedEntriesCount: Count of deny list entries successfully + // imported. + ImportedEntriesCount int64 `json:"importedEntriesCount,omitempty,string"` + + // ForceSendFields is a list of field names (e.g. "ErrorSamples") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "ErrorSamples") to include + // in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. However, any field with + // an empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesResponse + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaImportUserEventsMetadata: Metadata +// related to the progress of the Import operation. This is returned by +// the google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1alphaImportUserEventsMetadata struct { + // CreateTime: Operation create time. + CreateTime string `json:"createTime,omitempty"` + + // FailureCount: Count of entries that encountered errors while + // processing. + FailureCount int64 `json:"failureCount,omitempty,string"` + + // SuccessCount: Count of entries that were processed successfully. + SuccessCount int64 `json:"successCount,omitempty,string"` + + // 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. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + 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. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1alphaImportUserEventsMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaImportUserEventsMetadata + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaImportUserEventsRequest: Request +// message for the ImportUserEvents request. +type GoogleCloudDiscoveryengineV1alphaImportUserEventsRequest struct { + // BigquerySource: BigQuery input source. + BigquerySource *GoogleCloudDiscoveryengineV1alphaBigQuerySource `json:"bigquerySource,omitempty"` + + // ErrorConfig: The desired location of errors incurred during the + // Import. Cannot be set for inline user event imports. + ErrorConfig *GoogleCloudDiscoveryengineV1alphaImportErrorConfig `json:"errorConfig,omitempty"` + + // GcsSource: Cloud Storage location for the input content. + GcsSource *GoogleCloudDiscoveryengineV1alphaGcsSource `json:"gcsSource,omitempty"` + + // InlineSource: The Inline source for the input content for UserEvents. + InlineSource *GoogleCloudDiscoveryengineV1alphaImportUserEventsRequestInlineSource `json:"inlineSource,omitempty"` + + // ForceSendFields is a list of field names (e.g. "BigquerySource") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "BigquerySource") to + // include in API requests with the JSON null value. By default, fields + // with empty values are omitted from API requests. However, any field + // with an empty value appearing in NullFields will be sent to the + // server as null. It is an error if a field in this list has a + // non-empty value. This may be used to include null fields in Patch + // requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1alphaImportUserEventsRequest) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaImportUserEventsRequest + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaImportUserEventsRequestInlineSource: +// The inline source for the input config for ImportUserEvents method. +type GoogleCloudDiscoveryengineV1alphaImportUserEventsRequestInlineSource struct { + // UserEvents: Required. A list of user events to import. Recommended + // max of 10k items. + UserEvents []*GoogleCloudDiscoveryengineV1alphaUserEvent `json:"userEvents,omitempty"` + + // ForceSendFields is a list of field names (e.g. "UserEvents") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "UserEvents") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1alphaImportUserEventsRequestInlineSource) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaImportUserEventsRequestInlineSource + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaImportUserEventsResponse: Response +// of the ImportUserEventsRequest. If the long running operation was +// successful, then this message is returned by the +// google.longrunning.Operations.response field if the operation was +// successful. +type GoogleCloudDiscoveryengineV1alphaImportUserEventsResponse struct { + // ErrorConfig: Echoes the destination for the complete errors if this + // field was set in the request. + ErrorConfig *GoogleCloudDiscoveryengineV1alphaImportErrorConfig `json:"errorConfig,omitempty"` + + // ErrorSamples: A sample of errors encountered while processing the + // request. + ErrorSamples []*GoogleRpcStatus `json:"errorSamples,omitempty"` + + // JoinedEventsCount: Count of user events imported with complete + // existing Documents. + JoinedEventsCount int64 `json:"joinedEventsCount,omitempty,string"` + + // UnjoinedEventsCount: Count of user events imported, but with Document + // information not found in the existing Branch. + UnjoinedEventsCount int64 `json:"unjoinedEventsCount,omitempty,string"` + + // ForceSendFields is a list of field names (e.g. "ErrorConfig") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "ErrorConfig") to include + // in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. However, any field with + // an empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1alphaImportUserEventsResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaImportUserEventsResponse + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaInterval: A floating point interval. +type GoogleCloudDiscoveryengineV1alphaInterval struct { + // ExclusiveMaximum: Exclusive upper bound. + ExclusiveMaximum float64 `json:"exclusiveMaximum,omitempty"` + + // ExclusiveMinimum: Exclusive lower bound. + ExclusiveMinimum float64 `json:"exclusiveMinimum,omitempty"` + + // Maximum: Inclusive upper bound. + Maximum float64 `json:"maximum,omitempty"` + + // Minimum: Inclusive lower bound. + Minimum float64 `json:"minimum,omitempty"` + + // ForceSendFields is a list of field names (e.g. "ExclusiveMaximum") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "ExclusiveMaximum") to + // include in API requests with the JSON null value. By default, fields + // with empty values are omitted from API requests. However, any field + // with an empty value appearing in NullFields will be sent to the + // server as null. It is an error if a field in this list has a + // non-empty value. This may be used to include null fields in Patch + // requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1alphaInterval) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaInterval + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +func (s *GoogleCloudDiscoveryengineV1alphaInterval) UnmarshalJSON(data []byte) error { + type NoMethod GoogleCloudDiscoveryengineV1alphaInterval + var s1 struct { + ExclusiveMaximum gensupport.JSONFloat64 `json:"exclusiveMaximum"` + ExclusiveMinimum gensupport.JSONFloat64 `json:"exclusiveMinimum"` + Maximum gensupport.JSONFloat64 `json:"maximum"` + Minimum gensupport.JSONFloat64 `json:"minimum"` + *NoMethod + } + s1.NoMethod = (*NoMethod)(s) + if err := json.Unmarshal(data, &s1); err != nil { + return err + } + s.ExclusiveMaximum = float64(s1.ExclusiveMaximum) + s.ExclusiveMinimum = float64(s1.ExclusiveMinimum) + s.Maximum = float64(s1.Maximum) + s.Minimum = float64(s1.Minimum) + return nil +} + +// GoogleCloudDiscoveryengineV1alphaListConversationsResponse: Response +// for ListConversations method. +type GoogleCloudDiscoveryengineV1alphaListConversationsResponse struct { + // Conversations: All the Conversations for a given data store. + Conversations []*GoogleCloudDiscoveryengineV1alphaConversation `json:"conversations,omitempty"` + + // NextPageToken: Pagination token, if not returned indicates the last + // page. + 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. "Conversations") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "Conversations") to include + // in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. However, any field with + // an empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1alphaListConversationsResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaListConversationsResponse + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaListDataStoresResponse: Response +// message for DataStoreService.ListDataStores method. +type GoogleCloudDiscoveryengineV1alphaListDataStoresResponse struct { + // DataStores: All the customer's DataStores. + DataStores []*GoogleCloudDiscoveryengineV1alphaDataStore `json:"dataStores,omitempty"` + + // NextPageToken: A token that can be sent as + // ListDataStoresRequest.page_token to retrieve the next page. If this + // field is omitted, there are no subsequent pages. + 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. "DataStores") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "DataStores") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1alphaListDataStoresResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaListDataStoresResponse + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaListDocumentsResponse: Response +// message for DocumentService.ListDocuments method. +type GoogleCloudDiscoveryengineV1alphaListDocumentsResponse struct { + // Documents: The Documents. + Documents []*GoogleCloudDiscoveryengineV1alphaDocument `json:"documents,omitempty"` + + // NextPageToken: A token that can be sent as + // ListDocumentsRequest.page_token to retrieve the next page. If this + // field is omitted, there are no subsequent pages. + 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. "Documents") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "Documents") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1alphaListDocumentsResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaListDocumentsResponse + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaListEnginesResponse: Response +// message for EngineService.ListEngines method. +type GoogleCloudDiscoveryengineV1alphaListEnginesResponse struct { + // Engines: All the customer's Engines. + Engines []*GoogleCloudDiscoveryengineV1alphaEngine `json:"engines,omitempty"` + + // NextPageToken: Not supported. + 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. "Engines") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "Engines") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1alphaListEnginesResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaListEnginesResponse + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaListSchemasResponse: Response +// message for SchemaService.ListSchemas method. +type GoogleCloudDiscoveryengineV1alphaListSchemasResponse struct { + // NextPageToken: A token that can be sent as + // ListSchemasRequest.page_token to retrieve the next page. If this + // field is omitted, there are no subsequent pages. + NextPageToken string `json:"nextPageToken,omitempty"` + + // Schemas: The Schemas. + Schemas []*GoogleCloudDiscoveryengineV1alphaSchema `json:"schemas,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. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + 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. However, any field with + // an empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1alphaListSchemasResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaListSchemasResponse + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaListTargetSitesResponse: Response +// message for SiteSearchEngineService.ListTargetSites method. +type GoogleCloudDiscoveryengineV1alphaListTargetSitesResponse struct { + // NextPageToken: A token that 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"` + + // TargetSites: List of TargetSites. + TargetSites []*GoogleCloudDiscoveryengineV1alphaTargetSite `json:"targetSites,omitempty"` + + // TotalSize: The total number of items matching the request. This will + // always be populated in the response. + TotalSize int64 `json:"totalSize,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. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + 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. However, any field with + // an empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1alphaListTargetSitesResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaListTargetSitesResponse + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaLookupWidgetConfigRequest: Request +// message for WidgetService.LookupWidgetConfig method. +type GoogleCloudDiscoveryengineV1alphaLookupWidgetConfigRequest struct { + // WidgetConfigId: Required. The UUID of the Widget Config. + WidgetConfigId string `json:"widgetConfigId,omitempty"` + + // ForceSendFields is a list of field names (e.g. "WidgetConfigId") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "WidgetConfigId") to + // include in API requests with the JSON null value. By default, fields + // with empty values are omitted from API requests. However, any field + // with an empty value appearing in NullFields will be sent to the + // server as null. It is an error if a field in this list has a + // non-empty value. This may be used to include null fields in Patch + // requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1alphaLookupWidgetConfigRequest) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaLookupWidgetConfigRequest + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaLookupWidgetConfigResponse: Response +// message for WidgetService.LookupWidgetConfig method. +type GoogleCloudDiscoveryengineV1alphaLookupWidgetConfigResponse struct { + // AnonymousWidgetConfig: The Anonymous Widget Config associated with + // the UUID. + AnonymousWidgetConfig *GoogleCloudDiscoveryengineV1alphaWidgetConfig `json:"anonymousWidgetConfig,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the + // server. + googleapi.ServerResponse `json:"-"` + + // ForceSendFields is a list of field names (e.g. + // "AnonymousWidgetConfig") to unconditionally include in API requests. + // By default, fields with empty or default values are omitted from API + // requests. However, any non-pointer, non-interface field appearing in + // ForceSendFields will be sent to the server regardless of whether the + // field is empty or not. This may be used to include empty fields in + // Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "AnonymousWidgetConfig") to + // include in API requests with the JSON null value. By default, fields + // with empty values are omitted from API requests. However, any field + // with an empty value appearing in NullFields will be sent to the + // server as null. It is an error if a field in this list has a + // non-empty value. This may be used to include null fields in Patch + // requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1alphaLookupWidgetConfigResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaLookupWidgetConfigResponse + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaMediaInfo: Media-specific user event +// information. +type GoogleCloudDiscoveryengineV1alphaMediaInfo struct { + // MediaProgressDuration: The media progress time in seconds, if + // applicable. For example, if the end user has finished 90 seconds of a + // playback video, then MediaInfo.media_progress_duration.seconds should + // be set to 90. + MediaProgressDuration string `json:"mediaProgressDuration,omitempty"` + + // MediaProgressPercentage: Media progress should be computed using only + // the media_progress_duration relative to the media total length. This + // value must be between `[0, 1.0]` inclusive. If this is not a playback + // or the progress cannot be computed (e.g. ongoing livestream), this + // field should be unset. + MediaProgressPercentage float64 `json:"mediaProgressPercentage,omitempty"` + + // ForceSendFields is a list of field names (e.g. + // "MediaProgressDuration") to unconditionally include in API requests. + // By default, fields with empty or default values are omitted from API + // requests. However, any non-pointer, non-interface field appearing in + // ForceSendFields will be sent to the server regardless of whether the + // field is empty or not. This may be used to include empty fields in + // Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "MediaProgressDuration") to + // include in API requests with the JSON null value. By default, fields + // with empty values are omitted from API requests. However, any field + // with an empty value appearing in NullFields will be sent to the + // server as null. It is an error if a field in this list has a + // non-empty value. This may be used to include null fields in Patch + // requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1alphaMediaInfo) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaMediaInfo + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +func (s *GoogleCloudDiscoveryengineV1alphaMediaInfo) UnmarshalJSON(data []byte) error { + type NoMethod GoogleCloudDiscoveryengineV1alphaMediaInfo + var s1 struct { + MediaProgressPercentage gensupport.JSONFloat64 `json:"mediaProgressPercentage"` + *NoMethod + } + s1.NoMethod = (*NoMethod)(s) + if err := json.Unmarshal(data, &s1); err != nil { + return err + } + s.MediaProgressPercentage = float64(s1.MediaProgressPercentage) + return nil +} + +// GoogleCloudDiscoveryengineV1alphaOcrConfig: The OCR options for +// parsing documents. +type GoogleCloudDiscoveryengineV1alphaOcrConfig struct { + // Enabled: Required. If OCR is enabled or not. OCR must be enabled for + // other OcrConfig options to apply. We will only perform OCR on the + // first 80 pages of the PDF files. + Enabled bool `json:"enabled,omitempty"` + + // EnhancedDocumentElements: Apply additional enhanced OCR processing to + // a list of document elements. Supported values: * `table`: advanced + // table parsing model. + EnhancedDocumentElements []string `json:"enhancedDocumentElements,omitempty"` + + // UseNativeText: If true, will use native text instead of OCR text on + // pages containing native text. + UseNativeText bool `json:"useNativeText,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. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + 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. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1alphaOcrConfig) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaOcrConfig + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaPageInfo: Detailed page information. +type GoogleCloudDiscoveryengineV1alphaPageInfo struct { + // PageCategory: The most specific category associated with a category + // page. To represent full path of category, use '>' sign to separate + // different hierarchies. If '>' is part of the category name, please + // replace it with other character(s). Category pages include special + // pages such as sales or promotions. For instance, a special sale page + // may have the category hierarchy: "pageCategory" : "Sales > 2017 + // Black Friday Deals". Required for `view-category-page` events. Other + // event types should not set this field. Otherwise, an + // `INVALID_ARGUMENT` error is returned. + PageCategory string `json:"pageCategory,omitempty"` + + // PageviewId: 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 `pageview_id` 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. + PageviewId string `json:"pageviewId,omitempty"` + + // ReferrerUri: The referrer URL of the current page. When using the + // client side event reporting with JavaScript pixel and Google Tag + // Manager, this value is filled in automatically. However, some browser + // privacy restrictions may cause this field to be empty. + ReferrerUri string `json:"referrerUri,omitempty"` + + // Uri: Complete URL (window.location.href) of the user's current page. + // When using the client side event reporting with JavaScript pixel and + // Google Tag Manager, this value is filled in automatically. Maximum + // length 5,000 characters. + Uri string `json:"uri,omitempty"` + + // ForceSendFields is a list of field names (e.g. "PageCategory") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "PageCategory") to include + // in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. However, any field with + // an empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1alphaPageInfo) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaPageInfo + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaPanelInfo: Detailed panel +// information associated with a user event. +type GoogleCloudDiscoveryengineV1alphaPanelInfo struct { + // DisplayName: The display name of the panel. + DisplayName string `json:"displayName,omitempty"` + + // PanelId: Required. The panel ID. + PanelId string `json:"panelId,omitempty"` + + // PanelPosition: 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"` + + // TotalPanels: 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. "DisplayName") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + 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. However, any field with + // an empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1alphaPanelInfo) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaPanelInfo + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaPauseEngineRequest: Request for +// pausing training of an engine. +type GoogleCloudDiscoveryengineV1alphaPauseEngineRequest struct { +} + +// GoogleCloudDiscoveryengineV1alphaPurgeDocumentsMetadata: Metadata +// related to the progress of the PurgeDocuments operation. This will be +// returned by the google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1alphaPurgeDocumentsMetadata struct { + // CreateTime: Operation create time. + CreateTime string `json:"createTime,omitempty"` + + // FailureCount: Count of entries that encountered errors while + // processing. + FailureCount int64 `json:"failureCount,omitempty,string"` + + // SuccessCount: Count of entries that were deleted successfully. + SuccessCount int64 `json:"successCount,omitempty,string"` + + // 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. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + 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. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1alphaPurgeDocumentsMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaPurgeDocumentsMetadata + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaPurgeDocumentsRequest: Request +// message for DocumentService.PurgeDocuments method. +type GoogleCloudDiscoveryengineV1alphaPurgeDocumentsRequest struct { + // Filter: Required. Filter matching documents to purge. Only currently + // supported value is `*` (all items). + Filter string `json:"filter,omitempty"` + + // Force: Actually performs the purge. If `force` is set to false, + // return the expected purge count without deleting any documents. + Force bool `json:"force,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Filter") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "Filter") to include in API + // requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1alphaPurgeDocumentsRequest) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaPurgeDocumentsRequest + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaPurgeDocumentsResponse: Response +// message for DocumentService.PurgeDocuments method. If the long +// running operation is successfully done, then this message is returned +// by the google.longrunning.Operations.response field. +type GoogleCloudDiscoveryengineV1alphaPurgeDocumentsResponse struct { + // PurgeCount: The total count of documents purged as a result of the + // operation. + PurgeCount int64 `json:"purgeCount,omitempty,string"` + + // PurgeSample: A sample of document names that will be deleted. Only + // populated if `force` is set to false. A max of 100 names will be + // returned and the names are chosen at random. + PurgeSample []string `json:"purgeSample,omitempty"` + + // ForceSendFields is a list of field names (e.g. "PurgeCount") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "PurgeCount") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1alphaPurgeDocumentsResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaPurgeDocumentsResponse + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaPurgeSuggestionDenyListEntriesMetadat +// a: Metadata related to the progress of the +// PurgeSuggestionDenyListEntries operation. This is returned by the +// google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1alphaPurgeSuggestionDenyListEntriesMetadata 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. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + 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. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1alphaPurgeSuggestionDenyListEntriesMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaPurgeSuggestionDenyListEntriesMetadata + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaPurgeSuggestionDenyListEntriesRequest +// : Request message for +// CompletionService.PurgeSuggestionDenyListEntries method. +type GoogleCloudDiscoveryengineV1alphaPurgeSuggestionDenyListEntriesRequest struct { +} + +// GoogleCloudDiscoveryengineV1alphaPurgeSuggestionDenyListEntriesRespons +// e: Response message for +// CompletionService.PurgeSuggestionDenyListEntries method. +type GoogleCloudDiscoveryengineV1alphaPurgeSuggestionDenyListEntriesResponse struct { + // ErrorSamples: A sample of errors encountered while processing the + // request. + ErrorSamples []*GoogleRpcStatus `json:"errorSamples,omitempty"` + + // PurgeCount: Number of suggestion deny list entries purged. + PurgeCount int64 `json:"purgeCount,omitempty,string"` + + // ForceSendFields is a list of field names (e.g. "ErrorSamples") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "ErrorSamples") to include + // in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. However, any field with + // an empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1alphaPurgeSuggestionDenyListEntriesResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaPurgeSuggestionDenyListEntriesResponse + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaPurgeUserEventsMetadata: Metadata +// related to the progress of the PurgeUserEvents operation. This will +// be returned by the google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1alphaPurgeUserEventsMetadata struct { + // CreateTime: Operation create time. + CreateTime string `json:"createTime,omitempty"` + + // FailureCount: Count of entries that encountered errors while + // processing. + FailureCount int64 `json:"failureCount,omitempty,string"` + + // SuccessCount: Count of entries that were deleted successfully. + SuccessCount int64 `json:"successCount,omitempty,string"` + + // 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. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + 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. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1alphaPurgeUserEventsMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaPurgeUserEventsMetadata + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaPurgeUserEventsRequest: Request +// message for PurgeUserEvents method. +type GoogleCloudDiscoveryengineV1alphaPurgeUserEventsRequest struct { + // Filter: Required. The filter string to specify the events to be + // deleted with a length limit of 5,000 characters. The eligible fields + // for filtering are: * `eventType`: Double quoted UserEvent.event_type + // string. * `eventTime`: in ISO 8601 "zulu" format. * `userPseudoId`: + // Double quoted string. Specifying this will delete all events + // associated with a visitor. * `userId`: Double quoted string. + // Specifying this will delete all events associated with a user. + // Examples: * Deleting all events in a time range: `eventTime > + // "2012-04-23T18:25:43.511Z" eventTime < "2012-04-23T18:30:43.511Z" * + // Deleting specific eventType: `eventType = "search" * Deleting all + // events for a specific visitor: `userPseudoId = "visitor1024" * + // Deleting all events inside a DataStore: `*` The filtering fields are + // assumed to have an implicit AND. + Filter string `json:"filter,omitempty"` + + // Force: The `force` field is currently not supported. Purge user event + // requests will permanently delete all purgeable events. Once the + // development is complete: If `force` is set to false, the method will + // return the expected purge count without deleting any user events. + // This field will default to false if not included in the request. + Force bool `json:"force,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Filter") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "Filter") to include in API + // requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1alphaPurgeUserEventsRequest) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaPurgeUserEventsRequest + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaPurgeUserEventsResponse: Response of +// the PurgeUserEventsRequest. If the long running operation is +// successfully done, then this message is returned by the +// google.longrunning.Operations.response field. +type GoogleCloudDiscoveryengineV1alphaPurgeUserEventsResponse struct { + // PurgeCount: The total count of events purged as a result of the + // operation. + PurgeCount int64 `json:"purgeCount,omitempty,string"` + + // ForceSendFields is a list of field names (e.g. "PurgeCount") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "PurgeCount") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1alphaPurgeUserEventsResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaPurgeUserEventsResponse + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaRecommendRequest: Request message +// for Recommend method. +type GoogleCloudDiscoveryengineV1alphaRecommendRequest struct { + // Filter: Filter for restricting recommendation results with a length + // limit of 5,000 characters. Currently, only filter expressions on the + // `filter_tags` attribute is supported. Examples: * `(filter_tags: + // ANY("Red", "Blue") OR filter_tags: ANY("Hot", "Cold"))` * + // `(filter_tags: ANY("Red", "Blue")) AND NOT (filter_tags: + // ANY("Green"))` If `attributeFilteringSyntax` is set to true under the + // `params` field, then attribute-based expressions are expected instead + // of the above described tag-based syntax. Examples: * (launguage: + // ANY("en", "es")) AND NOT (categories: ANY("Movie")) * (available: + // true) AND (launguage: ANY("en", "es")) OR (categories: ANY("Movie")) + // If your filter blocks all results, the API will return generic + // (unfiltered) popular Documents. If you only want results strictly + // matching the filters, set `strictFiltering` to True in + // RecommendRequest.params to receive empty results instead. Note that + // the API will never return Documents with `storageStatus` of `EXPIRED` + // or `DELETED` regardless of filter choices. + Filter string `json:"filter,omitempty"` + + // PageSize: Maximum number of results to return. Set this property to + // the number of recommendation results needed. If zero, the service + // will choose a reasonable default. The maximum allowed value is 100. + // Values above 100 will be coerced to 100. + PageSize int64 `json:"pageSize,omitempty"` + + // Params: Additional domain specific parameters for the + // recommendations. Allowed values: * `returnDocument`: Boolean. If set + // to true, the associated Document object will be returned in + // RecommendResponse.RecommendationResult.document. * `returnScore`: + // Boolean. If set to true, the recommendation 'score' corresponding to + // each returned Document will be set in + // RecommendResponse.RecommendationResult.metadata. The given 'score' + // indicates the probability of a Document conversion given the user's + // context and history. * `strictFiltering`: Boolean. True by default. + // If set to false, the service will return generic (unfiltered) popular + // Documents instead of empty if your filter blocks all recommendation + // results. * `diversityLevel`: String. Default empty. If set to be + // non-empty, then it needs to be one of: * `no-diversity` * + // `low-diversity` * `medium-diversity` * `high-diversity` * + // `auto-diversity` This gives request-level control and adjusts + // recommendation results based on Document category. * + // `attributeFilteringSyntax`: Boolean. False by default. If set to + // true, the `filter` field is interpreted according to the new, + // attribute-based syntax. + Params googleapi.RawMessage `json:"params,omitempty"` + + // UserEvent: Required. Context about the user, what they are looking at + // and what action they took to trigger the Recommend request. Note that + // this user event detail won't be ingested to userEvent logs. Thus, a + // separate userEvent write request is required for event logging. Don't + // set UserEvent.user_pseudo_id or UserEvent.user_info.user_id to the + // same fixed ID for different users. If you are trying to receive + // non-personalized recommendations (not recommended; this can + // negatively impact model performance), instead set + // UserEvent.user_pseudo_id to a random unique ID and leave + // UserEvent.user_info.user_id unset. + UserEvent *GoogleCloudDiscoveryengineV1alphaUserEvent `json:"userEvent,omitempty"` + + // UserLabels: The user labels applied to a resource must meet the + // following requirements: * Each resource can have multiple labels, up + // to a maximum of 64. * Each label must be a key-value pair. * Keys + // have a minimum length of 1 character and a maximum length of 63 + // characters and cannot be empty. Values can be empty and have a + // maximum length of 63 characters. * Keys and values can contain only + // lowercase letters, numeric characters, underscores, and dashes. All + // characters must use UTF-8 encoding, and international characters are + // allowed. * The key portion of a label must be unique. However, you + // can use the same key with multiple resources. * Keys must start with + // a lowercase letter or international character. See Requirements for + // labels + // (https://cloud.google.com/resource-manager/docs/creating-managing-labels#requirements) + // for more details. + UserLabels map[string]string `json:"userLabels,omitempty"` + + // ValidateOnly: Use validate only mode for this recommendation query. + // If set to true, a fake model will be used that returns arbitrary + // Document IDs. Note that the validate only mode should only be used + // for testing the API, or if the model is not ready. + ValidateOnly bool `json:"validateOnly,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Filter") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "Filter") to include in API + // requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1alphaRecommendRequest) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaRecommendRequest + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaRecommendResponse: Response message +// for Recommend method. +type GoogleCloudDiscoveryengineV1alphaRecommendResponse struct { + // AttributionToken: A unique attribution token. This should be included + // in the UserEvent logs resulting from this recommendation, which + // enables accurate attribution of recommendation model performance. + AttributionToken string `json:"attributionToken,omitempty"` + + // MissingIds: IDs of documents in the request that were missing from + // the default Branch associated with the requested ServingConfig. + MissingIds []string `json:"missingIds,omitempty"` + + // Results: A list of recommended Documents. The order represents the + // ranking (from the most relevant Document to the least). + Results []*GoogleCloudDiscoveryengineV1alphaRecommendResponseRecommendationResult `json:"results,omitempty"` + + // ValidateOnly: True if RecommendRequest.validate_only was set. + ValidateOnly bool `json:"validateOnly,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the + // server. + googleapi.ServerResponse `json:"-"` + + // 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. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + 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. However, any field + // with an empty value appearing in NullFields will be sent to the + // server as null. It is an error if a field in this list has a + // non-empty value. This may be used to include null fields in Patch + // requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1alphaRecommendResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaRecommendResponse + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaRecommendResponseRecommendationResult +// : RecommendationResult represents a generic recommendation result +// with associated metadata. +type GoogleCloudDiscoveryengineV1alphaRecommendResponseRecommendationResult struct { + // Document: Set if `returnDocument` is set to true in + // RecommendRequest.params. + Document *GoogleCloudDiscoveryengineV1alphaDocument `json:"document,omitempty"` + + // Id: Resource ID of the recommended Document. + Id string `json:"id,omitempty"` + + // Metadata: Additional Document metadata / annotations. Possible + // values: * `score`: Recommendation score in double value. Is set if + // `returnScore` is set to true in RecommendRequest.params. + Metadata googleapi.RawMessage `json:"metadata,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Document") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "Document") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1alphaRecommendResponseRecommendationResult) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaRecommendResponseRecommendationResult + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaRecrawlUrisMetadata: Metadata +// related to the progress of the SiteSearchEngineService.RecrawlUris +// operation. This will be returned by the +// google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1alphaRecrawlUrisMetadata struct { + // CreateTime: Operation create time. + CreateTime string `json:"createTime,omitempty"` + + // InvalidUris: Unique URIs in the request that don't match any + // TargetSite in the DataStore, only match TargetSites that haven't been + // fully indexed, or match a TargetSite with type EXCLUDE. + InvalidUris []string `json:"invalidUris,omitempty"` + + // PendingCount: Total number of URIs that have yet to be crawled. + PendingCount int64 `json:"pendingCount,omitempty"` + + // QuotaExceededCount: Total number of URIs that were rejected due to + // insufficient indexing resources. + QuotaExceededCount int64 `json:"quotaExceededCount,omitempty"` + + // SuccessCount: Total number of URIs that have been crawled so far. + SuccessCount int64 `json:"successCount,omitempty"` + + // UpdateTime: Operation last update time. If the operation is done, + // this is also the finish time. + UpdateTime string `json:"updateTime,omitempty"` + + // ValidUrisCount: Total number of unique URIs in the request that are + // not in invalid_uris. + ValidUrisCount int64 `json:"validUrisCount,omitempty"` - // ForceSendFields is a list of field names (e.g. "WidgetConfigId") to + // 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. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -4753,84 +6501,104 @@ type GoogleCloudDiscoveryengineV1alphaLookupWidgetConfigRequest struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "WidgetConfigId") to - // include in API requests with the JSON null value. By default, fields - // with empty values are omitted from API requests. However, any field - // with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. + // 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. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaLookupWidgetConfigRequest) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaLookupWidgetConfigRequest +func (s *GoogleCloudDiscoveryengineV1alphaRecrawlUrisMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaRecrawlUrisMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaLookupWidgetConfigResponse: Response -// message for WidgetService.LookupWidgetConfig method. -type GoogleCloudDiscoveryengineV1alphaLookupWidgetConfigResponse struct { - // AnonymousWidgetConfig: The Anonymous Widget Config associated with - // the UUID. - AnonymousWidgetConfig *GoogleCloudDiscoveryengineV1alphaWidgetConfig `json:"anonymousWidgetConfig,omitempty"` +// GoogleCloudDiscoveryengineV1alphaRecrawlUrisRequest: Request message +// for SiteSearchEngineService.RecrawlUris method. +type GoogleCloudDiscoveryengineV1alphaRecrawlUrisRequest struct { + // Uris: Required. List of URIs to crawl. At most 10K URIs are + // supported, otherwise an INVALID_ARGUMENT error is thrown. Each URI + // should match at least one TargetSite in `site_search_engine`. + Uris []string `json:"uris,omitempty"` - // ServerResponse contains the HTTP response code and headers from the - // server. - googleapi.ServerResponse `json:"-"` + // ForceSendFields is a list of field names (e.g. "Uris") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` - // ForceSendFields is a list of field names (e.g. - // "AnonymousWidgetConfig") to unconditionally include in API requests. - // By default, fields with empty or default values are omitted from API - // requests. However, any non-pointer, non-interface field appearing in - // ForceSendFields will be sent to the server regardless of whether the - // field is empty or not. This may be used to include empty fields in - // Patch requests. + // NullFields is a list of field names (e.g. "Uris") to include in API + // requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1alphaRecrawlUrisRequest) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaRecrawlUrisRequest + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponse: Response +// message for SiteSearchEngineService.RecrawlUris method. +type GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponse struct { + // FailedUris: URIs that were not crawled before the LRO terminated. + FailedUris []string `json:"failedUris,omitempty"` + + // FailureSamples: Details for a sample of up to 10 `failed_uris`. + FailureSamples []*GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfo `json:"failureSamples,omitempty"` + + // ForceSendFields is a list of field names (e.g. "FailedUris") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "AnonymousWidgetConfig") to - // include in API requests with the JSON null value. By default, fields - // with empty values are omitted from API requests. However, any field - // with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. + // NullFields is a list of field names (e.g. "FailedUris") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaLookupWidgetConfigResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaLookupWidgetConfigResponse +func (s *GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponse raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaMediaInfo: Media-specific user event -// information. -type GoogleCloudDiscoveryengineV1alphaMediaInfo struct { - // MediaProgressDuration: The media progress time in seconds, if - // applicable. For example, if the end user has finished 90 seconds of a - // playback video, then MediaInfo.media_progress_duration.seconds should - // be set to 90. - MediaProgressDuration string `json:"mediaProgressDuration,omitempty"` +// GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfo: +// Details about why a particular URI failed to be crawled. Each +// FailureInfo contains one FailureReason per CorpusType. +type GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfo struct { + // FailureReasons: List of failure reasons by corpus type (e.g. desktop, + // mobile). + FailureReasons []*GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfoFailureReason `json:"failureReasons,omitempty"` - // MediaProgressPercentage: Media progress should be computed using only - // the media_progress_duration relative to the media total length. This - // value must be between `[0, 1.0]` inclusive. If this is not a playback - // or the progress cannot be computed (e.g. ongoing livestream), this - // field should be unset. - MediaProgressPercentage float64 `json:"mediaProgressPercentage,omitempty"` + // Uri: URI that failed to be crawled. + Uri string `json:"uri,omitempty"` - // ForceSendFields is a list of field names (e.g. - // "MediaProgressDuration") to unconditionally include in API requests. - // By default, fields with empty or default values are omitted from API - // requests. However, any non-pointer, non-interface field appearing in - // ForceSendFields will be sent to the server regardless of whether the - // field is empty or not. This may be used to include empty fields in - // Patch requests. + // ForceSendFields is a list of field names (e.g. "FailureReasons") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "MediaProgressDuration") to + // NullFields is a list of field names (e.g. "FailureReasons") to // include in API requests with the JSON null value. By default, fields // with empty values are omitted from API requests. However, any field // with an empty value appearing in NullFields will be sent to the @@ -4840,44 +6608,31 @@ type GoogleCloudDiscoveryengineV1alphaMediaInfo struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaMediaInfo) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaMediaInfo +func (s *GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfo) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfo raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -func (s *GoogleCloudDiscoveryengineV1alphaMediaInfo) UnmarshalJSON(data []byte) error { - type NoMethod GoogleCloudDiscoveryengineV1alphaMediaInfo - var s1 struct { - MediaProgressPercentage gensupport.JSONFloat64 `json:"mediaProgressPercentage"` - *NoMethod - } - s1.NoMethod = (*NoMethod)(s) - if err := json.Unmarshal(data, &s1); err != nil { - return err - } - s.MediaProgressPercentage = float64(s1.MediaProgressPercentage) - return nil -} - -// GoogleCloudDiscoveryengineV1alphaOcrConfig: The OCR options for -// parsing documents. -type GoogleCloudDiscoveryengineV1alphaOcrConfig struct { - // Enabled: Required. If OCR is enabled or not. OCR must be enabled for - // other OcrConfig options to apply. We will only perform OCR on the - // first 80 pages of the PDF files. - Enabled bool `json:"enabled,omitempty"` - - // EnhancedDocumentElements: Apply additional enhanced OCR processing to - // a list of document elements. Supported values: * `table`: advanced - // table parsing model. - EnhancedDocumentElements []string `json:"enhancedDocumentElements,omitempty"` +// GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfoFailure +// Reason: Details about why crawling failed for a particular +// CorpusType, e.g., DESKTOP and MOBILE crawling may fail for different +// reasons. +type GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfoFailureReason struct { + // CorpusType: DESKTOP, MOBILE, or CORPUS_TYPE_UNSPECIFIED. + // + // Possible values: + // "CORPUS_TYPE_UNSPECIFIED" - Default value. + // "DESKTOP" - Denotes a crawling attempt for the desktop version of a + // page. + // "MOBILE" - Denotes a crawling attempt for the mobile version of a + // page. + CorpusType string `json:"corpusType,omitempty"` - // UseNativeText: If true, will use native text instead of OCR text on - // pages containing native text. - UseNativeText bool `json:"useNativeText,omitempty"` + // ErrorMessage: Reason why the URI was not crawled. + ErrorMessage string `json:"errorMessage,omitempty"` - // ForceSendFields is a list of field names (e.g. "Enabled") to + // ForceSendFields is a list of field names (e.g. "CorpusType") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -4885,7 +6640,7 @@ type GoogleCloudDiscoveryengineV1alphaOcrConfig struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Enabled") to include in + // NullFields is a list of field names (e.g. "CorpusType") to include in // API requests with the JSON null value. By default, fields with empty // values are omitted from API requests. However, any field with an // empty value appearing in NullFields will be sent to the server as @@ -4894,48 +6649,25 @@ type GoogleCloudDiscoveryengineV1alphaOcrConfig struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaOcrConfig) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaOcrConfig +func (s *GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfoFailureReason) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfoFailureReason raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaPageInfo: Detailed page information. -type GoogleCloudDiscoveryengineV1alphaPageInfo struct { - // PageCategory: The most specific category associated with a category - // page. To represent full path of category, use '>' sign to separate - // different hierarchies. If '>' is part of the category name, please - // replace it with other character(s). Category pages include special - // pages such as sales or promotions. For instance, a special sale page - // may have the category hierarchy: "pageCategory" : "Sales > 2017 - // Black Friday Deals". Required for `view-category-page` events. Other - // event types should not set this field. Otherwise, an - // `INVALID_ARGUMENT` error is returned. - PageCategory string `json:"pageCategory,omitempty"` - - // PageviewId: 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 `pageview_id` 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. - PageviewId string `json:"pageviewId,omitempty"` +// GoogleCloudDiscoveryengineV1alphaReply: Defines a reply message to +// user. +type GoogleCloudDiscoveryengineV1alphaReply struct { + // References: References in the reply. + References []*GoogleCloudDiscoveryengineV1alphaReplyReference `json:"references,omitempty"` - // ReferrerUri: The referrer URL of the current page. When using the - // client side event reporting with JavaScript pixel and Google Tag - // Manager, this value is filled in automatically. However, some browser - // privacy restrictions may cause this field to be empty. - ReferrerUri string `json:"referrerUri,omitempty"` + // Reply: DEPRECATED: use `summary` instead. Text reply. + Reply string `json:"reply,omitempty"` - // Uri: Complete URL (window.location.href) of the user's current page. - // When using the client side event reporting with JavaScript pixel and - // Google Tag Manager, this value is filled in automatically. Maximum - // length 5,000 characters. - Uri string `json:"uri,omitempty"` + // Summary: Summary based on search results. + Summary *GoogleCloudDiscoveryengineV1alphaSearchResponseSummary `json:"summary,omitempty"` - // ForceSendFields is a list of field names (e.g. "PageCategory") to + // ForceSendFields is a list of field names (e.g. "References") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -4943,39 +6675,37 @@ type GoogleCloudDiscoveryengineV1alphaPageInfo struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "PageCategory") to include - // in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. However, any field with - // an empty value appearing in NullFields will be sent to the server as + // NullFields is a list of field names (e.g. "References") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaPageInfo) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaPageInfo - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) -} - -// GoogleCloudDiscoveryengineV1alphaPanelInfo: Detailed panel -// information associated with a user event. -type GoogleCloudDiscoveryengineV1alphaPanelInfo struct { - // DisplayName: The display name of the panel. - DisplayName string `json:"displayName,omitempty"` +func (s *GoogleCloudDiscoveryengineV1alphaReply) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaReply + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} - // PanelId: Required. The panel ID. - PanelId string `json:"panelId,omitempty"` +// GoogleCloudDiscoveryengineV1alphaReplyReference: Defines reference in +// reply. +type GoogleCloudDiscoveryengineV1alphaReplyReference struct { + // AnchorText: Anchor text. + AnchorText string `json:"anchorText,omitempty"` - // PanelPosition: 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"` + // End: Anchor text end index. + End int64 `json:"end,omitempty"` - // TotalPanels: 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"` + // Start: Anchor text start index. + Start int64 `json:"start,omitempty"` - // ForceSendFields is a list of field names (e.g. "DisplayName") to + // Uri: URI link reference. + Uri string `json:"uri,omitempty"` + + // ForceSendFields is a list of field names (e.g. "AnchorText") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -4983,45 +6713,50 @@ type GoogleCloudDiscoveryengineV1alphaPanelInfo struct { // This may be used to include empty fields in Patch requests. 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. However, any field with - // an empty value appearing in NullFields will be sent to the server as + // NullFields is a list of field names (e.g. "AnchorText") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaPanelInfo) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaPanelInfo +func (s *GoogleCloudDiscoveryengineV1alphaReplyReference) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaReplyReference raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaPauseEngineRequest: Request for -// pausing training of an engine. -type GoogleCloudDiscoveryengineV1alphaPauseEngineRequest struct { +// GoogleCloudDiscoveryengineV1alphaResumeEngineRequest: Request for +// resuming training of an engine. +type GoogleCloudDiscoveryengineV1alphaResumeEngineRequest struct { } -// GoogleCloudDiscoveryengineV1alphaPurgeDocumentsMetadata: Metadata -// related to the progress of the PurgeDocuments operation. This will be -// returned by the google.longrunning.Operation.metadata field. -type GoogleCloudDiscoveryengineV1alphaPurgeDocumentsMetadata struct { - // CreateTime: Operation create time. - CreateTime string `json:"createTime,omitempty"` +// GoogleCloudDiscoveryengineV1alphaSchema: Defines the structure and +// layout of a type of document data. +type GoogleCloudDiscoveryengineV1alphaSchema struct { + // FieldConfigs: Output only. Configurations for fields of the schema. + FieldConfigs []*GoogleCloudDiscoveryengineV1alphaFieldConfig `json:"fieldConfigs,omitempty"` - // FailureCount: Count of entries that encountered errors while - // processing. - FailureCount int64 `json:"failureCount,omitempty,string"` + // JsonSchema: The JSON representation of the schema. + JsonSchema string `json:"jsonSchema,omitempty"` - // SuccessCount: Count of entries that were deleted successfully. - SuccessCount int64 `json:"successCount,omitempty,string"` + // Name: Immutable. The full resource name of the schema, in the format + // of + // `projects/{project}/locations/{location}/collections/{collection}/data + // Stores/{data_store}/schemas/{schema}`. This field must be a UTF-8 + // encoded string with a length limit of 1024 characters. + Name string `json:"name,omitempty"` - // UpdateTime: Operation last update time. If the operation is done, - // this is also the finish time. - UpdateTime string `json:"updateTime,omitempty"` + // StructSchema: The structured representation of the schema. + StructSchema googleapi.RawMessage `json:"structSchema,omitempty"` - // ForceSendFields is a list of field names (e.g. "CreateTime") to + // ServerResponse contains the HTTP response code and headers from the + // server. + googleapi.ServerResponse `json:"-"` + + // ForceSendFields is a list of field names (e.g. "FieldConfigs") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -5029,33 +6764,49 @@ type GoogleCloudDiscoveryengineV1alphaPurgeDocumentsMetadata struct { // This may be used to include empty fields in Patch requests. 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. However, any field with an - // empty value appearing in NullFields will be sent to the server as + // NullFields is a list of field names (e.g. "FieldConfigs") to include + // in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. However, any field with + // an empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaPurgeDocumentsMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaPurgeDocumentsMetadata +func (s *GoogleCloudDiscoveryengineV1alphaSchema) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSchema raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaPurgeDocumentsRequest: Request -// message for DocumentService.PurgeDocuments method. -type GoogleCloudDiscoveryengineV1alphaPurgeDocumentsRequest struct { - // Filter: Required. Filter matching documents to purge. Only currently - // supported value is `*` (all items). - Filter string `json:"filter,omitempty"` +// GoogleCloudDiscoveryengineV1alphaSearchInfo: Detailed search +// information. +type GoogleCloudDiscoveryengineV1alphaSearchInfo struct { + // Offset: An integer that specifies the current offset for pagination + // (the 0-indexed starting location, amongst the products deemed by the + // API as relevant). See SearchRequest.offset for definition. If this + // field is negative, an `INVALID_ARGUMENT` is returned. This can only + // be set for `search` events. Other event types should not set this + // field. Otherwise, an `INVALID_ARGUMENT` error is returned. + Offset int64 `json:"offset,omitempty"` - // Force: Actually performs the purge. If `force` is set to false, - // return the expected purge count without deleting any documents. - Force bool `json:"force,omitempty"` + // OrderBy: The order in which products are returned, if applicable. See + // SearchRequest.order_by for definition and syntax. The value must be a + // UTF-8 encoded string with a length limit of 1,000 characters. + // Otherwise, an `INVALID_ARGUMENT` error is returned. This can only be + // set for `search` events. Other event types should not set this field. + // Otherwise, an `INVALID_ARGUMENT` error is returned. + OrderBy string `json:"orderBy,omitempty"` - // ForceSendFields is a list of field names (e.g. "Filter") to + // SearchQuery: The user's search query. See SearchRequest.query for + // definition. The value must be a UTF-8 encoded string with a length + // limit of 5,000 characters. Otherwise, an `INVALID_ARGUMENT` error is + // returned. At least one of search_query or PageInfo.page_category is + // required for `search` events. Other event types should not set this + // field. Otherwise, an `INVALID_ARGUMENT` error is returned. + SearchQuery string `json:"searchQuery,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Offset") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -5063,7 +6814,7 @@ type GoogleCloudDiscoveryengineV1alphaPurgeDocumentsRequest struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Filter") to include in API + // NullFields is a list of field names (e.g. "Offset") to include in API // requests with the JSON null value. By default, fields with empty // values are omitted from API requests. However, any field with an // empty value appearing in NullFields will be sent to the server as @@ -5072,62 +6823,186 @@ type GoogleCloudDiscoveryengineV1alphaPurgeDocumentsRequest struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaPurgeDocumentsRequest) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaPurgeDocumentsRequest +func (s *GoogleCloudDiscoveryengineV1alphaSearchInfo) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSearchInfo raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaPurgeDocumentsResponse: Response -// message for DocumentService.PurgeDocuments method. If the long -// running operation is successfully done, then this message is returned -// by the google.longrunning.Operations.response field. -type GoogleCloudDiscoveryengineV1alphaPurgeDocumentsResponse struct { - // PurgeCount: The total count of documents purged as a result of the - // operation. - PurgeCount int64 `json:"purgeCount,omitempty,string"` +// GoogleCloudDiscoveryengineV1alphaSearchRequest: Request message for +// SearchService.Search method. +type GoogleCloudDiscoveryengineV1alphaSearchRequest struct { + // BoostSpec: Boost specification to boost certain documents. For more + // information on boosting, see Boosting + // (https://cloud.google.com/retail/docs/boosting#boost) + BoostSpec *GoogleCloudDiscoveryengineV1alphaSearchRequestBoostSpec `json:"boostSpec,omitempty"` + + // Branch: The branch resource name, such as + // `projects/*/locations/global/collections/default_collection/dataStores + // /default_data_store/branches/0`. Use `default_branch` as the branch + // ID or leave this field empty, to search documents under the default + // branch. + Branch string `json:"branch,omitempty"` + + // CanonicalFilter: The default filter that is applied when a user + // performs a search without checking any filters on the search page. + // The filter applied to every search request when quality improvement + // such as query expansion is needed. In the case a query does not have + // a sufficient amount of results this filter will be used to determine + // whether or not to enable the query expansion flow. The original + // filter will still be used for the query expanded search. This field + // is strongly recommended to achieve high search quality. For more + // information about filter syntax, see SearchRequest.filter. + CanonicalFilter string `json:"canonicalFilter,omitempty"` + + // ContentSearchSpec: A specification for configuring the behavior of + // content search. + ContentSearchSpec *GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpec `json:"contentSearchSpec,omitempty"` + + // EmbeddingSpec: Uses the provided embedding to do additional semantic + // document retrieval. The retrieval is based on the dot product of + // SearchRequest.EmbeddingSpec.EmbeddingVector.vector and the document + // embedding that is provided in + // SearchRequest.EmbeddingSpec.EmbeddingVector.field_path. If + // SearchRequest.EmbeddingSpec.EmbeddingVector.field_path is not + // provided, it will use ServingConfig.EmbeddingConfig.field_paths. + EmbeddingSpec *GoogleCloudDiscoveryengineV1alphaSearchRequestEmbeddingSpec `json:"embeddingSpec,omitempty"` + + // FacetSpecs: Facet specifications for faceted search. If empty, no + // facets are returned. A maximum of 100 values are allowed. Otherwise, + // an `INVALID_ARGUMENT` error is returned. + FacetSpecs []*GoogleCloudDiscoveryengineV1alphaSearchRequestFacetSpec `json:"facetSpecs,omitempty"` + + // Filter: 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 --> 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) + Filter string `json:"filter,omitempty"` + + // ImageQuery: Raw image query. + ImageQuery *GoogleCloudDiscoveryengineV1alphaSearchRequestImageQuery `json:"imageQuery,omitempty"` + + // Offset: 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. + Offset int64 `json:"offset,omitempty"` + + // OrderBy: The order in which documents are returned. Documents can be + // ordered by a field in an Document object. Leave it unset if ordered + // by relevance. `order_by` expression is case-sensitive. For more + // information on ordering, see Ordering + // (https://cloud.google.com/retail/docs/filter-and-order#order) If this + // field is unrecognizable, an `INVALID_ARGUMENT` is returned. + OrderBy string `json:"orderBy,omitempty"` + + // PageSize: Maximum number of Documents to return. If unspecified, + // defaults to a reasonable value. The maximum allowed value is 100. + // Values above 100 are coerced to 100. If this field is negative, an + // `INVALID_ARGUMENT` is returned. + PageSize int64 `json:"pageSize,omitempty"` + + // PageToken: A page token received from a previous SearchService.Search + // call. Provide this to retrieve the subsequent page. When paginating, + // all other parameters provided to SearchService.Search must match the + // call that provided the page token. Otherwise, an `INVALID_ARGUMENT` + // error is returned. + PageToken string `json:"pageToken,omitempty"` + + // Params: Additional search parameters. For public website search only, + // supported values are: * `user_country_code`: string. Default empty. + // If set to non-empty, results are restricted or boosted based on the + // location provided. Example: user_country_code: "au" For available + // codes see Country Codes + // (https://developers.google.com/custom-search/docs/json_api_reference#countryCodes) + // * `search_type`: double. Default empty. Enables non-webpage searching + // depending on the value. The only valid non-default value is 1, which + // enables image searching. Example: search_type: 1 + Params googleapi.RawMessage `json:"params,omitempty"` + + // Query: Raw search query. + Query string `json:"query,omitempty"` + + // QueryExpansionSpec: The query expansion specification that specifies + // the conditions under which query expansion occurs. + QueryExpansionSpec *GoogleCloudDiscoveryengineV1alphaSearchRequestQueryExpansionSpec `json:"queryExpansionSpec,omitempty"` + + // RankingExpression: The ranking expression controls the customized + // ranking on retrieval documents. This overrides + // ServingConfig.ranking_expression. The ranking expression is a single + // function or multiple functions that are joint by "+". * + // ranking_expression = function, { " + ", function }; Supported + // functions: * double * relevance_score * double * + // dotProduct(embedding_field_path) Function variables: + // `relevance_score`: pre-defined keywords, used for measure relevance + // between query and document. `embedding_field_path`: the document + // embedding field used with query embedding vector. `dotProduct`: + // embedding function between embedding_field_path and query embedding + // vector. Example ranking expression: If document has an embedding + // field doc_embedding, the ranking expression could be `0.5 * + // relevance_score + 0.3 * dotProduct(doc_embedding)`. + RankingExpression string `json:"rankingExpression,omitempty"` - // PurgeSample: A sample of document names that will be deleted. Only - // populated if `force` is set to false. A max of 100 names will be - // returned and the names are chosen at random. - PurgeSample []string `json:"purgeSample,omitempty"` + // SafeSearch: Whether to turn on safe search. This is only supported + // for website search. + SafeSearch bool `json:"safeSearch,omitempty"` - // ForceSendFields is a list of field names (e.g. "PurgeCount") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. - ForceSendFields []string `json:"-"` + // ServingConfig: Required. The resource name of the Search serving + // config, such as + // `projects/*/locations/global/collections/default_collection/engines/*/ + // servingConfigs/default_serving_config`, or + // `projects/*/locations/global/collections/default_collection/dataStores + // /default_data_store/servingConfigs/default_serving_config`. This + // field is used to identify the serving configuration name, set of + // models used to make the search. + ServingConfig string `json:"servingConfig,omitempty"` - // NullFields is a list of field names (e.g. "PurgeCount") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. - NullFields []string `json:"-"` -} + // SpellCorrectionSpec: The spell correction specification that + // specifies the mode under which spell correction takes effect. + SpellCorrectionSpec *GoogleCloudDiscoveryengineV1alphaSearchRequestSpellCorrectionSpec `json:"spellCorrectionSpec,omitempty"` -func (s *GoogleCloudDiscoveryengineV1alphaPurgeDocumentsResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaPurgeDocumentsResponse - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) -} + // UserInfo: Information about the end user. Highly recommended for + // analytics. UserInfo.user_agent is used to deduce `device_type` for + // analytics. + UserInfo *GoogleCloudDiscoveryengineV1alphaUserInfo `json:"userInfo,omitempty"` -// GoogleCloudDiscoveryengineV1alphaPurgeSuggestionDenyListEntriesMetadat -// a: Metadata related to the progress of the -// PurgeSuggestionDenyListEntries operation. This is returned by the -// google.longrunning.Operation.metadata field. -type GoogleCloudDiscoveryengineV1alphaPurgeSuggestionDenyListEntriesMetadata struct { - // CreateTime: Operation create time. - CreateTime string `json:"createTime,omitempty"` + // UserLabels: The user labels applied to a resource must meet the + // following requirements: * Each resource can have multiple labels, up + // to a maximum of 64. * Each label must be a key-value pair. * Keys + // have a minimum length of 1 character and a maximum length of 63 + // characters and cannot be empty. Values can be empty and have a + // maximum length of 63 characters. * Keys and values can contain only + // lowercase letters, numeric characters, underscores, and dashes. All + // characters must use UTF-8 encoding, and international characters are + // allowed. * The key portion of a label must be unique. However, you + // can use the same key with multiple resources. * Keys must start with + // a lowercase letter or international character. See Google Cloud + // Document + // (https://cloud.google.com/resource-manager/docs/creating-managing-labels#requirements) + // for more details. + UserLabels map[string]string `json:"userLabels,omitempty"` - // UpdateTime: Operation last update time. If the operation is done, - // this is also the finish time. - UpdateTime string `json:"updateTime,omitempty"` + // UserPseudoId: A unique identifier for tracking visitors. For example, + // this could be implemented with an HTTP cookie, which should be able + // to uniquely identify a visitor on a single device. This unique + // identifier should not change if the visitor logs in or out of the + // website. This field should NOT have a fixed value such as + // `unknown_visitor`. This should be the same identifier as + // UserEvent.user_pseudo_id and CompleteQueryRequest.user_pseudo_id The + // field must be a UTF-8 encoded string with a length limit of 128 + // characters. Otherwise, an `INVALID_ARGUMENT` error is returned. + UserPseudoId string `json:"userPseudoId,omitempty"` - // ForceSendFields is a list of field names (e.g. "CreateTime") to + // ForceSendFields is a list of field names (e.g. "BoostSpec") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -5135,7 +7010,7 @@ type GoogleCloudDiscoveryengineV1alphaPurgeSuggestionDenyListEntriesMetadata str // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "CreateTime") to include in + // NullFields is a list of field names (e.g. "BoostSpec") to include in // API requests with the JSON null value. By default, fields with empty // values are omitted from API requests. However, any field with an // empty value appearing in NullFields will be sent to the server as @@ -5144,71 +7019,72 @@ type GoogleCloudDiscoveryengineV1alphaPurgeSuggestionDenyListEntriesMetadata str NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaPurgeSuggestionDenyListEntriesMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaPurgeSuggestionDenyListEntriesMetadata +func (s *GoogleCloudDiscoveryengineV1alphaSearchRequest) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSearchRequest raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaPurgeSuggestionDenyListEntriesRequest -// : Request message for -// CompletionService.PurgeSuggestionDenyListEntries method. -type GoogleCloudDiscoveryengineV1alphaPurgeSuggestionDenyListEntriesRequest struct { -} - -// GoogleCloudDiscoveryengineV1alphaPurgeSuggestionDenyListEntriesRespons -// e: Response message for -// CompletionService.PurgeSuggestionDenyListEntries method. -type GoogleCloudDiscoveryengineV1alphaPurgeSuggestionDenyListEntriesResponse struct { - // ErrorSamples: A sample of errors encountered while processing the - // request. - ErrorSamples []*GoogleRpcStatus `json:"errorSamples,omitempty"` - - // PurgeCount: Number of suggestion deny list entries purged. - PurgeCount int64 `json:"purgeCount,omitempty,string"` +// GoogleCloudDiscoveryengineV1alphaSearchRequestBoostSpec: Boost +// specification to boost certain documents. +type GoogleCloudDiscoveryengineV1alphaSearchRequestBoostSpec struct { + // ConditionBoostSpecs: Condition boost specifications. If a document + // matches multiple conditions in the specifictions, boost scores from + // these specifications are all applied and combined in a non-linear + // way. Maximum number of specifications is 20. + ConditionBoostSpecs []*GoogleCloudDiscoveryengineV1alphaSearchRequestBoostSpecConditionBoostSpec `json:"conditionBoostSpecs,omitempty"` - // ForceSendFields is a list of field names (e.g. "ErrorSamples") to - // unconditionally include in API requests. By default, fields with + // ForceSendFields is a list of field names (e.g. "ConditionBoostSpecs") + // to unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be // sent to the server regardless of whether the field is empty or not. // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "ErrorSamples") to include - // in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. However, any field with - // an empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "ConditionBoostSpecs") to + // include in API requests with the JSON null value. By default, fields + // with empty values are omitted from API requests. However, any field + // with an empty value appearing in NullFields will be sent to the + // server as null. It is an error if a field in this list has a + // non-empty value. This may be used to include null fields in Patch + // requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaPurgeSuggestionDenyListEntriesResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaPurgeSuggestionDenyListEntriesResponse +func (s *GoogleCloudDiscoveryengineV1alphaSearchRequestBoostSpec) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSearchRequestBoostSpec raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaPurgeUserEventsMetadata: Metadata -// related to the progress of the PurgeUserEvents operation. This will -// be returned by the google.longrunning.Operation.metadata field. -type GoogleCloudDiscoveryengineV1alphaPurgeUserEventsMetadata struct { - // CreateTime: Operation create time. - CreateTime string `json:"createTime,omitempty"` - - // FailureCount: Count of entries that encountered errors while - // processing. - FailureCount int64 `json:"failureCount,omitempty,string"` - - // SuccessCount: Count of entries that were deleted successfully. - SuccessCount int64 `json:"successCount,omitempty,string"` +// GoogleCloudDiscoveryengineV1alphaSearchRequestBoostSpecConditionBoostS +// pec: Boost applies to documents which match a condition. +type GoogleCloudDiscoveryengineV1alphaSearchRequestBoostSpecConditionBoostSpec struct { + // Boost: Strength of the condition boost, which should be in [-1, 1]. + // Negative boost means demotion. Default is 0.0. Setting to 1.0 gives + // the document a big promotion. However, it does not necessarily mean + // that the boosted document will be the top result at all times, nor + // that other documents will be excluded. Results could still be shown + // even when none of them matches the condition. And results that are + // significantly more relevant to the search query can still trump your + // heavily favored but irrelevant documents. Setting to -1.0 gives the + // document a big demotion. However, results that are deeply relevant + // might still be shown. The document will have an upstream battle to + // get a fairly high ranking, but it is not blocked out completely. + // Setting to 0.0 means no boost applied. The boosting condition is + // ignored. + Boost float64 `json:"boost,omitempty"` - // UpdateTime: Operation last update time. If the operation is done, - // this is also the finish time. - UpdateTime string `json:"updateTime,omitempty"` + // Condition: An expression which specifies a boost condition. The + // syntax and supported fields are the same as a filter expression. See + // SearchRequest.filter for detail syntax and limitations. Examples: * + // To boost documents with document ID "doc_1" or "doc_2", and color + // "Red" or "Blue": * (id: ANY("doc_1", "doc_2")) AND (color: + // ANY("Red","Blue")) + Condition string `json:"condition,omitempty"` - // ForceSendFields is a list of field names (e.g. "CreateTime") to + // ForceSendFields is a list of field names (e.g. "Boost") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -5216,8 +7092,8 @@ type GoogleCloudDiscoveryengineV1alphaPurgeUserEventsMetadata struct { // This may be used to include empty fields in Patch requests. 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 + // NullFields is a list of field names (e.g. "Boost") to include in API + // requests with the JSON null value. By default, fields with empty // values are omitted from API requests. However, any field with an // empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. @@ -5225,175 +7101,145 @@ type GoogleCloudDiscoveryengineV1alphaPurgeUserEventsMetadata struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaPurgeUserEventsMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaPurgeUserEventsMetadata +func (s *GoogleCloudDiscoveryengineV1alphaSearchRequestBoostSpecConditionBoostSpec) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSearchRequestBoostSpecConditionBoostSpec raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaPurgeUserEventsRequest: Request -// message for PurgeUserEvents method. -type GoogleCloudDiscoveryengineV1alphaPurgeUserEventsRequest struct { - // Filter: Required. The filter string to specify the events to be - // deleted with a length limit of 5,000 characters. The eligible fields - // for filtering are: * `eventType`: Double quoted UserEvent.event_type - // string. * `eventTime`: in ISO 8601 "zulu" format. * `userPseudoId`: - // Double quoted string. Specifying this will delete all events - // associated with a visitor. * `userId`: Double quoted string. - // Specifying this will delete all events associated with a user. - // Examples: * Deleting all events in a time range: `eventTime > - // "2012-04-23T18:25:43.511Z" eventTime < "2012-04-23T18:30:43.511Z" * - // Deleting specific eventType: `eventType = "search" * Deleting all - // events for a specific visitor: `userPseudoId = "visitor1024" * - // Deleting all events inside a DataStore: `*` The filtering fields are - // assumed to have an implicit AND. - Filter string `json:"filter,omitempty"` +func (s *GoogleCloudDiscoveryengineV1alphaSearchRequestBoostSpecConditionBoostSpec) UnmarshalJSON(data []byte) error { + type NoMethod GoogleCloudDiscoveryengineV1alphaSearchRequestBoostSpecConditionBoostSpec + var s1 struct { + Boost gensupport.JSONFloat64 `json:"boost"` + *NoMethod + } + s1.NoMethod = (*NoMethod)(s) + if err := json.Unmarshal(data, &s1); err != nil { + return err + } + s.Boost = float64(s1.Boost) + return nil +} - // Force: The `force` field is currently not supported. Purge user event - // requests will permanently delete all purgeable events. Once the - // development is complete: If `force` is set to false, the method will - // return the expected purge count without deleting any user events. - // This field will default to false if not included in the request. - Force bool `json:"force,omitempty"` +// GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpec: A +// specification for configuring the behavior of content search. +type GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpec struct { + // ExtractiveContentSpec: If there is no extractive_content_spec + // provided, there will be no extractive answer in the search response. + ExtractiveContentSpec *GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecExtractiveContentSpec `json:"extractiveContentSpec,omitempty"` - // ForceSendFields is a list of field names (e.g. "Filter") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. - ForceSendFields []string `json:"-"` + // SnippetSpec: If `snippetSpec` is not specified, snippets are not + // included in the search response. + SnippetSpec *GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSnippetSpec `json:"snippetSpec,omitempty"` - // NullFields is a list of field names (e.g. "Filter") to include in API - // requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // SummarySpec: If `summarySpec` is not specified, summaries are not + // included in the search response. + SummarySpec *GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSummarySpec `json:"summarySpec,omitempty"` + + // ForceSendFields is a list of field names (e.g. + // "ExtractiveContentSpec") to unconditionally include in API requests. + // By default, fields with empty or default values are omitted from API + // requests. However, any non-pointer, non-interface field appearing in + // ForceSendFields will be sent to the server regardless of whether the + // field is empty or not. This may be used to include empty fields in + // Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "ExtractiveContentSpec") to + // include in API requests with the JSON null value. By default, fields + // with empty values are omitted from API requests. However, any field + // with an empty value appearing in NullFields will be sent to the + // server as null. It is an error if a field in this list has a + // non-empty value. This may be used to include null fields in Patch + // requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaPurgeUserEventsRequest) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaPurgeUserEventsRequest +func (s *GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpec) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpec raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaPurgeUserEventsResponse: Response of -// the PurgeUserEventsRequest. If the long running operation is -// successfully done, then this message is returned by the -// google.longrunning.Operations.response field. -type GoogleCloudDiscoveryengineV1alphaPurgeUserEventsResponse struct { - // PurgeCount: The total count of events purged as a result of the - // operation. - PurgeCount int64 `json:"purgeCount,omitempty,string"` +// GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecExtract +// iveContentSpec: A specification for configuring the extractive +// content in a search response. +type GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecExtractiveContentSpec struct { + // MaxExtractiveAnswerCount: The maximum number of extractive answers + // returned in each search result. An extractive answer is a verbatim + // answer extracted from the original document, which provides a precise + // and contextually relevant answer to the search query. If the number + // of matching answers is less than the `max_extractive_answer_count`, + // return all of the answers. Otherwise, return the + // `max_extractive_answer_count`. At most five answers are returned for + // each SearchResult. + MaxExtractiveAnswerCount int64 `json:"maxExtractiveAnswerCount,omitempty"` - // ForceSendFields is a list of field names (e.g. "PurgeCount") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // MaxExtractiveSegmentCount: The max number of extractive segments + // returned in each search result. Only applied if the DataStore is set + // to DataStore.ContentConfig.CONTENT_REQUIRED or + // DataStore.solution_types is SOLUTION_TYPE_CHAT. An extractive segment + // is a text segment extracted from the original document that is + // relevant to the search query, and, in general, more verbose than an + // extractive answer. The segment could then be used as input for LLMs + // to generate summaries and answers. If the number of matching segments + // is less than `max_extractive_segment_count`, return all of the + // segments. Otherwise, return the `max_extractive_segment_count`. + MaxExtractiveSegmentCount int64 `json:"maxExtractiveSegmentCount,omitempty"` + + // NumNextSegments: Return at most `num_next_segments` segments after + // each selected segments. + NumNextSegments int64 `json:"numNextSegments,omitempty"` + + // NumPreviousSegments: Specifies whether to also include the adjacent + // from each selected segments. Return at most `num_previous_segments` + // segments before each selected segments. + NumPreviousSegments int64 `json:"numPreviousSegments,omitempty"` + + // ForceSendFields is a list of field names (e.g. + // "MaxExtractiveAnswerCount") to unconditionally include in API + // requests. By default, fields with empty or default values are omitted + // from API requests. However, any non-pointer, non-interface field + // appearing in ForceSendFields will be sent to the server regardless of + // whether the field is empty or not. This may be used to include empty + // fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "PurgeCount") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "MaxExtractiveAnswerCount") + // to include in API requests with the JSON null value. By default, + // fields with empty values are omitted from API requests. However, any + // field with an empty value appearing in NullFields will be sent to the + // server as null. It is an error if a field in this list has a + // non-empty value. This may be used to include null fields in Patch + // requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaPurgeUserEventsResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaPurgeUserEventsResponse +func (s *GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecExtractiveContentSpec) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecExtractiveContentSpec raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaRecommendRequest: Request message -// for Recommend method. -type GoogleCloudDiscoveryengineV1alphaRecommendRequest struct { - // Filter: Filter for restricting recommendation results with a length - // limit of 5,000 characters. Currently, only filter expressions on the - // `filter_tags` attribute is supported. Examples: * `(filter_tags: - // ANY("Red", "Blue") OR filter_tags: ANY("Hot", "Cold"))` * - // `(filter_tags: ANY("Red", "Blue")) AND NOT (filter_tags: - // ANY("Green"))` If `attributeFilteringSyntax` is set to true under the - // `params` field, then attribute-based expressions are expected instead - // of the above described tag-based syntax. Examples: * (launguage: - // ANY("en", "es")) AND NOT (categories: ANY("Movie")) * (available: - // true) AND (launguage: ANY("en", "es")) OR (categories: ANY("Movie")) - // If your filter blocks all results, the API will return generic - // (unfiltered) popular Documents. If you only want results strictly - // matching the filters, set `strictFiltering` to True in - // RecommendRequest.params to receive empty results instead. Note that - // the API will never return Documents with `storageStatus` of `EXPIRED` - // or `DELETED` regardless of filter choices. - Filter string `json:"filter,omitempty"` - - // PageSize: Maximum number of results to return. Set this property to - // the number of recommendation results needed. If zero, the service - // will choose a reasonable default. The maximum allowed value is 100. - // Values above 100 will be coerced to 100. - PageSize int64 `json:"pageSize,omitempty"` - - // Params: Additional domain specific parameters for the - // recommendations. Allowed values: * `returnDocument`: Boolean. If set - // to true, the associated Document object will be returned in - // RecommendResponse.RecommendationResult.document. * `returnScore`: - // Boolean. If set to true, the recommendation 'score' corresponding to - // each returned Document will be set in - // RecommendResponse.RecommendationResult.metadata. The given 'score' - // indicates the probability of a Document conversion given the user's - // context and history. * `strictFiltering`: Boolean. True by default. - // If set to false, the service will return generic (unfiltered) popular - // Documents instead of empty if your filter blocks all recommendation - // results. * `diversityLevel`: String. Default empty. If set to be - // non-empty, then it needs to be one of: * `no-diversity` * - // `low-diversity` * `medium-diversity` * `high-diversity` * - // `auto-diversity` This gives request-level control and adjusts - // recommendation results based on Document category. * - // `attributeFilteringSyntax`: Boolean. False by default. If set to - // true, the `filter` field is interpreted according to the new, - // attribute-based syntax. - Params googleapi.RawMessage `json:"params,omitempty"` - - // UserEvent: Required. Context about the user, what they are looking at - // and what action they took to trigger the Recommend request. Note that - // this user event detail won't be ingested to userEvent logs. Thus, a - // separate userEvent write request is required for event logging. Don't - // set UserEvent.user_pseudo_id or UserEvent.user_info.user_id to the - // same fixed ID for different users. If you are trying to receive - // non-personalized recommendations (not recommended; this can - // negatively impact model performance), instead set - // UserEvent.user_pseudo_id to a random unique ID and leave - // UserEvent.user_info.user_id unset. - UserEvent *GoogleCloudDiscoveryengineV1alphaUserEvent `json:"userEvent,omitempty"` +// GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSnippet +// Spec: A specification for configuring snippets in a search response. +type GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSnippetSpec struct { + // MaxSnippetCount: [DEPRECATED] This field is deprecated. To control + // snippet return, use `return_snippet` field. For backwards + // compatibility, we will return snippet if max_snippet_count > 0. + MaxSnippetCount int64 `json:"maxSnippetCount,omitempty"` - // UserLabels: The user labels applied to a resource must meet the - // following requirements: * Each resource can have multiple labels, up - // to a maximum of 64. * Each label must be a key-value pair. * Keys - // have a minimum length of 1 character and a maximum length of 63 - // characters and cannot be empty. Values can be empty and have a - // maximum length of 63 characters. * Keys and values can contain only - // lowercase letters, numeric characters, underscores, and dashes. All - // characters must use UTF-8 encoding, and international characters are - // allowed. * The key portion of a label must be unique. However, you - // can use the same key with multiple resources. * Keys must start with - // a lowercase letter or international character. See Requirements for - // labels - // (https://cloud.google.com/resource-manager/docs/creating-managing-labels#requirements) - // for more details. - UserLabels map[string]string `json:"userLabels,omitempty"` + // ReferenceOnly: [DEPRECATED] This field is deprecated and will have no + // affect on the snippet. + ReferenceOnly bool `json:"referenceOnly,omitempty"` - // ValidateOnly: Use validate only mode for this recommendation query. - // If set to true, a fake model will be used that returns arbitrary - // Document IDs. Note that the validate only mode should only be used - // for testing the API, or if the model is not ready. - ValidateOnly bool `json:"validateOnly,omitempty"` + // ReturnSnippet: If `true`, then return snippet. If no snippet can be + // generated, we return "No snippet is available for this page." A + // `snippet_status` with `SUCCESS` or `NO_SNIPPET_AVAILABLE` will also + // be returned. + ReturnSnippet bool `json:"returnSnippet,omitempty"` - // ForceSendFields is a list of field names (e.g. "Filter") to + // ForceSendFields is a list of field names (e.g. "MaxSnippetCount") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -5401,85 +7247,115 @@ type GoogleCloudDiscoveryengineV1alphaRecommendRequest struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Filter") to include in API - // requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "MaxSnippetCount") to + // include in API requests with the JSON null value. By default, fields + // with empty values are omitted from API requests. However, any field + // with an empty value appearing in NullFields will be sent to the + // server as null. It is an error if a field in this list has a + // non-empty value. This may be used to include null fields in Patch + // requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaRecommendRequest) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaRecommendRequest +func (s *GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSnippetSpec) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSnippetSpec raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaRecommendResponse: Response message -// for Recommend method. -type GoogleCloudDiscoveryengineV1alphaRecommendResponse struct { - // AttributionToken: A unique attribution token. This should be included - // in the UserEvent logs resulting from this recommendation, which - // enables accurate attribution of recommendation model performance. - AttributionToken string `json:"attributionToken,omitempty"` +// GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSummary +// Spec: A specification for configuring a summary returned in a search +// response. +type GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSummarySpec struct { + // IgnoreAdversarialQuery: Specifies whether to filter out adversarial + // queries. The default value is `false`. Google employs search-query + // classification to detect adversarial queries. No summary is returned + // if the search query is classified as an adversarial query. For + // example, a user might ask a question regarding negative comments + // about the company or submit a query designed to generate unsafe, + // policy-violating output. If this field is set to `true`, we skip + // generating summaries for adversarial queries and return fallback + // messages instead. + IgnoreAdversarialQuery bool `json:"ignoreAdversarialQuery,omitempty"` - // MissingIds: IDs of documents in the request that were missing from - // the default Branch associated with the requested ServingConfig. - MissingIds []string `json:"missingIds,omitempty"` + // IgnoreNonSummarySeekingQuery: Specifies whether to filter out queries + // that are not summary-seeking. The default value is `false`. Google + // employs search-query classification to detect summary-seeking + // queries. No summary is returned if the search query is classified as + // a non-summary seeking query. For example, `why is the sky blue` and + // `Who is the best soccer player in the world?` are summary-seeking + // queries, but `SFO airport` and `world cup 2026` are not. They are + // most likely navigational queries. If this field is set to `true`, we + // skip generating summaries for non-summary seeking queries and return + // fallback messages instead. + IgnoreNonSummarySeekingQuery bool `json:"ignoreNonSummarySeekingQuery,omitempty"` - // Results: A list of recommended Documents. The order represents the - // ranking (from the most relevant Document to the least). - Results []*GoogleCloudDiscoveryengineV1alphaRecommendResponseRecommendationResult `json:"results,omitempty"` + // IncludeCitations: Specifies whether to include citations in the + // summary. The default value is `false`. When this field is set to + // `true`, summaries include in-line citation numbers. Example summary + // including citations: BigQuery is Google Cloud's fully managed and + // completely serverless enterprise data warehouse [1]. BigQuery + // supports all data types, works across clouds, and has built-in + // machine learning and business intelligence, all within a unified + // platform [2, 3]. The citation numbers refer to the returned search + // results and are 1-indexed. For example, [1] means that the sentence + // is attributed to the first search result. [2, 3] means that the + // sentence is attributed to both the second and third search results. + IncludeCitations bool `json:"includeCitations,omitempty"` + + // LanguageCode: Language code for Summary. Use language tags defined by + // BCP47 (https://www.rfc-editor.org/rfc/bcp/bcp47.txt). Note: This is + // an experimental feature. + LanguageCode string `json:"languageCode,omitempty"` + + // ModelPromptSpec: If specified, the spec will be used to modify the + // prompt provided to the LLM. + ModelPromptSpec *GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSummarySpecModelPromptSpec `json:"modelPromptSpec,omitempty"` - // ValidateOnly: True if RecommendRequest.validate_only was set. - ValidateOnly bool `json:"validateOnly,omitempty"` + // ModelSpec: If specified, the spec will be used to modify the model + // specification provided to the LLM. + ModelSpec *GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSummarySpecModelSpec `json:"modelSpec,omitempty"` - // ServerResponse contains the HTTP response code and headers from the - // server. - googleapi.ServerResponse `json:"-"` + // SummaryResultCount: The number of top results to generate the summary + // from. If the number of results returned is less than + // `summaryResultCount`, the summary is generated from all of the + // results. At most five results can be used to generate a summary. + SummaryResultCount int64 `json:"summaryResultCount,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. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. + // "IgnoreAdversarialQuery") to unconditionally include in API requests. + // By default, fields with empty or default values are omitted from API + // requests. However, any non-pointer, non-interface field appearing in + // ForceSendFields will be sent to the server regardless of whether the + // field is empty or not. This may be used to include empty fields in + // Patch requests. 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. However, any field - // with an empty value appearing in NullFields will be sent to the + // NullFields is a list of field names (e.g. "IgnoreAdversarialQuery") + // to include in API requests with the JSON null value. By default, + // fields with empty values are omitted from API requests. However, any + // field with an empty value appearing in NullFields will be sent to the // server as null. It is an error if a field in this list has a // non-empty value. This may be used to include null fields in Patch // requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaRecommendResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaRecommendResponse +func (s *GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSummarySpec) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSummarySpec raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaRecommendResponseRecommendationResult -// : RecommendationResult represents a generic recommendation result -// with associated metadata. -type GoogleCloudDiscoveryengineV1alphaRecommendResponseRecommendationResult struct { - // Document: Set if `returnDocument` is set to true in - // RecommendRequest.params. - Document *GoogleCloudDiscoveryengineV1alphaDocument `json:"document,omitempty"` - - // Id: Resource ID of the recommended Document. - Id string `json:"id,omitempty"` - - // Metadata: Additional Document metadata / annotations. Possible - // values: * `score`: Recommendation score in double value. Is set if - // `returnScore` is set to true in RecommendRequest.params. - Metadata googleapi.RawMessage `json:"metadata,omitempty"` +// GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSummary +// SpecModelPromptSpec: Specification of the prompt to use with the +// model. +type GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSummarySpecModelPromptSpec struct { + // Preamble: Text at the beginning of the prompt that instructs the + // assistant. Examples are available in the user guide. + Preamble string `json:"preamble,omitempty"` - // ForceSendFields is a list of field names (e.g. "Document") to + // ForceSendFields is a list of field names (e.g. "Preamble") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -5487,7 +7363,7 @@ type GoogleCloudDiscoveryengineV1alphaRecommendResponseRecommendationResult stru // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Document") to include in + // NullFields is a list of field names (e.g. "Preamble") to include in // API requests with the JSON null value. By default, fields with empty // values are omitted from API requests. However, any field with an // empty value appearing in NullFields will be sent to the server as @@ -5496,44 +7372,24 @@ type GoogleCloudDiscoveryengineV1alphaRecommendResponseRecommendationResult stru NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaRecommendResponseRecommendationResult) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaRecommendResponseRecommendationResult +func (s *GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSummarySpecModelPromptSpec) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSummarySpecModelPromptSpec raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaRecrawlUrisMetadata: Metadata -// related to the progress of the SiteSearchEngineService.RecrawlUris -// operation. This will be returned by the -// google.longrunning.Operation.metadata field. -type GoogleCloudDiscoveryengineV1alphaRecrawlUrisMetadata struct { - // CreateTime: Operation create time. - CreateTime string `json:"createTime,omitempty"` - - // InvalidUris: Unique URIs in the request that don't match any - // TargetSite in the DataStore, only match TargetSites that haven't been - // fully indexed, or match a TargetSite with type EXCLUDE. - InvalidUris []string `json:"invalidUris,omitempty"` - - // PendingCount: Total number of URIs that have yet to be crawled. - PendingCount int64 `json:"pendingCount,omitempty"` - - // QuotaExceededCount: Total number of URIs that were rejected due to - // insufficient indexing resources. - QuotaExceededCount int64 `json:"quotaExceededCount,omitempty"` - - // SuccessCount: Total number of URIs that have been crawled so far. - SuccessCount int64 `json:"successCount,omitempty"` - - // UpdateTime: Operation last update time. If the operation is done, - // this is also the finish time. - UpdateTime string `json:"updateTime,omitempty"` - - // ValidUrisCount: Total number of unique URIs in the request that are - // not in invalid_uris. - ValidUrisCount int64 `json:"validUrisCount,omitempty"` +// GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSummary +// SpecModelSpec: Specification of the model. +type GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSummarySpecModelSpec struct { + // Version: The model version used to generate the summary. Supported + // values are: * `stable`: string. Default value when no value is + // specified. Uses a generally available, fine-tuned version of the + // text-bison@001 model. * `preview`: string. (Public preview) Uses a + // fine-tuned version of the text-bison@002 model. This model works only + // for summaries in English. + Version string `json:"version,omitempty"` - // ForceSendFields is a list of field names (e.g. "CreateTime") to + // 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. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -5541,7 +7397,7 @@ type GoogleCloudDiscoveryengineV1alphaRecrawlUrisMetadata struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "CreateTime") to include in + // 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. However, any field with an // empty value appearing in NullFields will be sent to the server as @@ -5550,21 +7406,21 @@ type GoogleCloudDiscoveryengineV1alphaRecrawlUrisMetadata struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaRecrawlUrisMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaRecrawlUrisMetadata +func (s *GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSummarySpecModelSpec) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSummarySpecModelSpec raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaRecrawlUrisRequest: Request message -// for SiteSearchEngineService.RecrawlUris method. -type GoogleCloudDiscoveryengineV1alphaRecrawlUrisRequest struct { - // Uris: Required. List of URIs to crawl. At most 10K URIs are - // supported, otherwise an INVALID_ARGUMENT error is thrown. Each URI - // should match at least one TargetSite in `site_search_engine`. - Uris []string `json:"uris,omitempty"` +// GoogleCloudDiscoveryengineV1alphaSearchRequestEmbeddingSpec: The +// specification that uses customized query embedding vector to do +// semantic document retrieval. +type GoogleCloudDiscoveryengineV1alphaSearchRequestEmbeddingSpec struct { + // EmbeddingVectors: The embedding vector used for retrieval. Limit to + // 1. + EmbeddingVectors []*GoogleCloudDiscoveryengineV1alphaSearchRequestEmbeddingSpecEmbeddingVector `json:"embeddingVectors,omitempty"` - // ForceSendFields is a list of field names (e.g. "Uris") to + // ForceSendFields is a list of field names (e.g. "EmbeddingVectors") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -5572,31 +7428,32 @@ type GoogleCloudDiscoveryengineV1alphaRecrawlUrisRequest struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Uris") to include in API - // requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "EmbeddingVectors") to + // include in API requests with the JSON null value. By default, fields + // with empty values are omitted from API requests. However, any field + // with an empty value appearing in NullFields will be sent to the + // server as null. It is an error if a field in this list has a + // non-empty value. This may be used to include null fields in Patch + // requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaRecrawlUrisRequest) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaRecrawlUrisRequest +func (s *GoogleCloudDiscoveryengineV1alphaSearchRequestEmbeddingSpec) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSearchRequestEmbeddingSpec raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponse: Response -// message for SiteSearchEngineService.RecrawlUris method. -type GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponse struct { - // FailedUris: URIs that were not crawled before the LRO terminated. - FailedUris []string `json:"failedUris,omitempty"` +// GoogleCloudDiscoveryengineV1alphaSearchRequestEmbeddingSpecEmbeddingVe +// ctor: Embedding vector. +type GoogleCloudDiscoveryengineV1alphaSearchRequestEmbeddingSpecEmbeddingVector struct { + // FieldPath: Embedding field path in schema. + FieldPath string `json:"fieldPath,omitempty"` - // FailureSamples: Details for a sample of up to 10 `failed_uris`. - FailureSamples []*GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfo `json:"failureSamples,omitempty"` + // Vector: Query embedding vector. + Vector []float64 `json:"vector,omitempty"` - // ForceSendFields is a list of field names (e.g. "FailedUris") to + // ForceSendFields is a list of field names (e.g. "FieldPath") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -5604,7 +7461,7 @@ type GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponse struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "FailedUris") to include in + // NullFields is a list of field names (e.g. "FieldPath") to include in // API requests with the JSON null value. By default, fields with empty // values are omitted from API requests. However, any field with an // empty value appearing in NullFields will be sent to the server as @@ -5613,24 +7470,158 @@ type GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponse struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponse +func (s *GoogleCloudDiscoveryengineV1alphaSearchRequestEmbeddingSpecEmbeddingVector) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSearchRequestEmbeddingSpecEmbeddingVector + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +func (s *GoogleCloudDiscoveryengineV1alphaSearchRequestEmbeddingSpecEmbeddingVector) UnmarshalJSON(data []byte) error { + type NoMethod GoogleCloudDiscoveryengineV1alphaSearchRequestEmbeddingSpecEmbeddingVector + var s1 struct { + Vector []gensupport.JSONFloat64 `json:"vector"` + *NoMethod + } + s1.NoMethod = (*NoMethod)(s) + if err := json.Unmarshal(data, &s1); err != nil { + return err + } + s.Vector = make([]float64, len(s1.Vector)) + for i := range s1.Vector { + s.Vector[i] = float64(s1.Vector[i]) + } + return nil +} + +// GoogleCloudDiscoveryengineV1alphaSearchRequestFacetSpec: A facet +// specification to perform faceted search. +type GoogleCloudDiscoveryengineV1alphaSearchRequestFacetSpec struct { + // EnableDynamicPosition: Enables dynamic position for this facet. If + // set to true, the position of this facet among all facets in the + // response is determined automatically. If dynamic facets are enabled, + // it is ordered together. If set to false, the position of this facet + // in the response is the same as in the request, and it is ranked + // before the facets with dynamic position enable and all dynamic + // facets. For example, you may always want to have rating facet + // returned in the response, but it's not necessarily to always display + // the rating facet at the top. In that case, you can set + // enable_dynamic_position to true so that the position of rating facet + // in response is determined automatically. Another example, assuming + // you have the following facets in the request: * "rating", + // enable_dynamic_position = true * "price", enable_dynamic_position = + // false * "brands", enable_dynamic_position = false And also you have a + // dynamic facets enabled, which generates a facet `gender`. Then the + // final order of the facets in the response can be ("price", "brands", + // "rating", "gender") or ("price", "brands", "gender", "rating") + // depends on how API orders "gender" and "rating" facets. However, + // notice that "price" and "brands" are always ranked at first and + // second position because their enable_dynamic_position is false. + EnableDynamicPosition bool `json:"enableDynamicPosition,omitempty"` + + // ExcludedFilterKeys: List of keys to exclude when faceting. By + // default, FacetKey.key is not excluded from the filter unless it is + // listed in this field. Listing a facet key in this field allows its + // values to appear as facet results, even when they are filtered out of + // search results. Using this field does not affect what search results + // are returned. For example, suppose there are 100 documents with the + // color facet "Red" and 200 documents with the color facet "Blue". A + // query containing the filter "color:ANY("Red")" and having "color" as + // FacetKey.key would by default return only "Red" documents in the + // search results, and also return "Red" with count 100 as the only + // color facet. Although there are also blue documents available, "Blue" + // would not be shown as an available facet value. If "color" is listed + // in "excludedFilterKeys", then the query returns the facet values + // "Red" with count 100 and "Blue" with count 200, because the "color" + // key is now excluded from the filter. Because this field doesn't + // affect search results, the search results are still correctly + // filtered to return only "Red" documents. A maximum of 100 values are + // allowed. Otherwise, an `INVALID_ARGUMENT` error is returned. + ExcludedFilterKeys []string `json:"excludedFilterKeys,omitempty"` + + // FacetKey: Required. The facet key specification. + FacetKey *GoogleCloudDiscoveryengineV1alphaSearchRequestFacetSpecFacetKey `json:"facetKey,omitempty"` + + // Limit: Maximum of facet values that should be returned for this + // facet. If unspecified, defaults to 20. The maximum allowed value is + // 300. Values above 300 are coerced to 300. If this field is negative, + // an `INVALID_ARGUMENT` is returned. + Limit int64 `json:"limit,omitempty"` + + // ForceSendFields is a list of field names (e.g. + // "EnableDynamicPosition") to unconditionally include in API requests. + // By default, fields with empty or default values are omitted from API + // requests. However, any non-pointer, non-interface field appearing in + // ForceSendFields will be sent to the server regardless of whether the + // field is empty or not. This may be used to include empty fields in + // Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "EnableDynamicPosition") to + // include in API requests with the JSON null value. By default, fields + // with empty values are omitted from API requests. However, any field + // with an empty value appearing in NullFields will be sent to the + // server as null. It is an error if a field in this list has a + // non-empty value. This may be used to include null fields in Patch + // requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1alphaSearchRequestFacetSpec) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSearchRequestFacetSpec raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfo: -// Details about why a particular URI failed to be crawled. Each -// FailureInfo contains one FailureReason per CorpusType. -type GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfo struct { - // FailureReasons: List of failure reasons by corpus type (e.g. desktop, - // mobile). - FailureReasons []*GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfoFailureReason `json:"failureReasons,omitempty"` +// GoogleCloudDiscoveryengineV1alphaSearchRequestFacetSpecFacetKey: +// Specifies how a facet is computed. +type GoogleCloudDiscoveryengineV1alphaSearchRequestFacetSpecFacetKey struct { + // CaseInsensitive: True to make facet keys case insensitive when + // getting faceting values with prefixes or contains; false otherwise. + CaseInsensitive bool `json:"caseInsensitive,omitempty"` - // Uri: URI that failed to be crawled. - Uri string `json:"uri,omitempty"` + // Contains: Only get facet values that contains the given strings. For + // example, suppose "category" has three values "Action > 2022", "Action + // > 2021" and "Sci-Fi > 2022". If set "contains" to "2022", the + // "category" facet only contains "Action > 2022" and "Sci-Fi > 2022". + // Only supported on textual fields. Maximum is 10. + Contains []string `json:"contains,omitempty"` - // ForceSendFields is a list of field names (e.g. "FailureReasons") to + // Intervals: Set only if values should be bucketed into intervals. Must + // be set for facets with numerical values. Must not be set for facet + // with text values. Maximum number of intervals is 30. + Intervals []*GoogleCloudDiscoveryengineV1alphaInterval `json:"intervals,omitempty"` + + // Key: Required. Supported textual and numerical facet keys in Document + // object, over which the facet values are computed. Facet key is + // case-sensitive. + Key string `json:"key,omitempty"` + + // OrderBy: The order in which documents are returned. Allowed values + // are: * "count desc", which means order by + // SearchResponse.Facet.values.count descending. * "value desc", which + // means order by SearchResponse.Facet.values.value descending. Only + // applies to textual facets. If not set, textual values are sorted in + // natural order (https://en.wikipedia.org/wiki/Natural_sort_order); + // numerical intervals are sorted in the order given by + // FacetSpec.FacetKey.intervals. + OrderBy string `json:"orderBy,omitempty"` + + // Prefixes: Only get facet values that start with the given string + // prefix. For example, suppose "category" has three values "Action > + // 2022", "Action > 2021" and "Sci-Fi > 2022". If set "prefixes" to + // "Action", the "category" facet only contains "Action > 2022" and + // "Action > 2021". Only supported on textual fields. Maximum is 10. + Prefixes []string `json:"prefixes,omitempty"` + + // RestrictedValues: Only get facet for the given restricted values. + // Only supported on textual fields. For example, suppose "category" has + // three values "Action > 2022", "Action > 2021" and "Sci-Fi > 2022". If + // set "restricted_values" to "Action > 2022", the "category" facet only + // contains "Action > 2022". Only supported on textual fields. Maximum + // is 10. + RestrictedValues []string `json:"restrictedValues,omitempty"` + + // ForceSendFields is a list of field names (e.g. "CaseInsensitive") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -5638,7 +7629,7 @@ type GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfo struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "FailureReasons") to + // NullFields is a list of field names (e.g. "CaseInsensitive") to // include in API requests with the JSON null value. By default, fields // with empty values are omitted from API requests. However, any field // with an empty value appearing in NullFields will be sent to the @@ -5648,31 +7639,20 @@ type GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfo struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfo) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfo +func (s *GoogleCloudDiscoveryengineV1alphaSearchRequestFacetSpecFacetKey) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSearchRequestFacetSpecFacetKey raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfoFailure -// Reason: Details about why crawling failed for a particular -// CorpusType, e.g. DESKTOP and MOBILE crawling may fail for different -// reasons. -type GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfoFailureReason struct { - // CorpusType: DESKTOP, MOBILE, or CORPUS_TYPE_UNSPECIFIED. - // - // Possible values: - // "CORPUS_TYPE_UNSPECIFIED" - Default value. - // "DESKTOP" - Denotes a crawling attempt for the desktop version of a - // page. - // "MOBILE" - Denotes a crawling attempt for the mobile version of a - // page. - CorpusType string `json:"corpusType,omitempty"` - - // ErrorMessage: Reason why the URI was not crawled. - ErrorMessage string `json:"errorMessage,omitempty"` +// GoogleCloudDiscoveryengineV1alphaSearchRequestImageQuery: Specifies +// the image query input. +type GoogleCloudDiscoveryengineV1alphaSearchRequestImageQuery struct { + // ImageBytes: Base64 encoded image bytes. Supported image formats: + // JPEG, PNG, and BMP. + ImageBytes string `json:"imageBytes,omitempty"` - // ForceSendFields is a list of field names (e.g. "CorpusType") to + // ForceSendFields is a list of field names (e.g. "ImageBytes") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -5680,7 +7660,7 @@ type GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfoFailureReaso // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "CorpusType") to include in + // NullFields is a list of field names (e.g. "ImageBytes") to include in // API requests with the JSON null value. By default, fields with empty // values are omitted from API requests. However, any field with an // empty value appearing in NullFields will be sent to the server as @@ -5689,25 +7669,33 @@ type GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfoFailureReaso NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfoFailureReason) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfoFailureReason +func (s *GoogleCloudDiscoveryengineV1alphaSearchRequestImageQuery) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSearchRequestImageQuery raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaReply: Defines a reply message to -// user. -type GoogleCloudDiscoveryengineV1alphaReply struct { - // References: References in the reply. - References []*GoogleCloudDiscoveryengineV1alphaReplyReference `json:"references,omitempty"` - - // Reply: DEPRECATED: use `summary` instead. Text reply. - Reply string `json:"reply,omitempty"` +// GoogleCloudDiscoveryengineV1alphaSearchRequestQueryExpansionSpec: +// Specification to determine under which conditions query expansion +// should occur. +type GoogleCloudDiscoveryengineV1alphaSearchRequestQueryExpansionSpec struct { + // Condition: The condition under which query expansion should occur. + // Default to Condition.DISABLED. + // + // Possible values: + // "CONDITION_UNSPECIFIED" - Unspecified query expansion condition. In + // this case, server behavior defaults to Condition.DISABLED. + // "DISABLED" - Disabled query expansion. Only the exact search query + // is used, even if SearchResponse.total_size is zero. + // "AUTO" - Automatic query expansion built by the Search API. + Condition string `json:"condition,omitempty"` - // Summary: Summary based on search results. - Summary *GoogleCloudDiscoveryengineV1alphaSearchResponseSummary `json:"summary,omitempty"` + // PinUnexpandedResults: Whether to pin unexpanded results. If this + // field is set to true, unexpanded products are always at the top of + // the search results, followed by the expanded results. + PinUnexpandedResults bool `json:"pinUnexpandedResults,omitempty"` - // ForceSendFields is a list of field names (e.g. "References") to + // ForceSendFields is a list of field names (e.g. "Condition") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -5715,7 +7703,7 @@ type GoogleCloudDiscoveryengineV1alphaReply struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "References") to include in + // NullFields is a list of field names (e.g. "Condition") to include in // API requests with the JSON null value. By default, fields with empty // values are omitted from API requests. However, any field with an // empty value appearing in NullFields will be sent to the server as @@ -5724,28 +7712,29 @@ type GoogleCloudDiscoveryengineV1alphaReply struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaReply) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaReply +func (s *GoogleCloudDiscoveryengineV1alphaSearchRequestQueryExpansionSpec) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSearchRequestQueryExpansionSpec raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaReplyReference: Defines reference in -// reply. -type GoogleCloudDiscoveryengineV1alphaReplyReference struct { - // AnchorText: Anchor text. - AnchorText string `json:"anchorText,omitempty"` - - // End: Anchor text end index. - End int64 `json:"end,omitempty"` - - // Start: Anchor text start index. - Start int64 `json:"start,omitempty"` - - // Uri: URI link reference. - Uri string `json:"uri,omitempty"` +// GoogleCloudDiscoveryengineV1alphaSearchRequestSpellCorrectionSpec: +// The specification for query spell correction. +type GoogleCloudDiscoveryengineV1alphaSearchRequestSpellCorrectionSpec struct { + // Mode: The mode under which spell correction should take effect to + // replace the original search query. Default to Mode.AUTO. + // + // Possible values: + // "MODE_UNSPECIFIED" - Unspecified spell correction mode. In this + // case, server behavior defaults to Mode.AUTO. + // "SUGGESTION_ONLY" - Search API will try to find a spell suggestion + // if there is any and put in the SearchResponse.corrected_query. The + // spell suggestion will not be used as the search query. + // "AUTO" - Automatic spell correction built by the Search API. Search + // will be based on the corrected query if found. + Mode string `json:"mode,omitempty"` - // ForceSendFields is a list of field names (e.g. "AnchorText") to + // ForceSendFields is a list of field names (e.g. "Mode") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -5753,8 +7742,8 @@ type GoogleCloudDiscoveryengineV1alphaReplyReference struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "AnchorText") to include in - // API requests with the JSON null value. By default, fields with empty + // NullFields is a list of field names (e.g. "Mode") to include in API + // requests with the JSON null value. By default, fields with empty // values are omitted from API requests. However, any field with an // empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. @@ -5762,41 +7751,104 @@ type GoogleCloudDiscoveryengineV1alphaReplyReference struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaReplyReference) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaReplyReference +func (s *GoogleCloudDiscoveryengineV1alphaSearchRequestSpellCorrectionSpec) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSearchRequestSpellCorrectionSpec raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaResumeEngineRequest: Request for -// resuming training of an engine. -type GoogleCloudDiscoveryengineV1alphaResumeEngineRequest struct { -} +// GoogleCloudDiscoveryengineV1alphaSearchResponse: Response message for +// SearchService.Search method. +type GoogleCloudDiscoveryengineV1alphaSearchResponse struct { + // AppliedControls: Controls applied as part of the Control service. + AppliedControls []string `json:"appliedControls,omitempty"` -// GoogleCloudDiscoveryengineV1alphaSchema: Defines the structure and -// layout of a type of document data. -type GoogleCloudDiscoveryengineV1alphaSchema struct { - // FieldConfigs: Output only. Configurations for fields of the schema. - FieldConfigs []*GoogleCloudDiscoveryengineV1alphaFieldConfig `json:"fieldConfigs,omitempty"` + // AttributionToken: A unique search token. This should be included in + // the UserEvent logs resulting from this search, which enables accurate + // attribution of search model performance. + AttributionToken string `json:"attributionToken,omitempty"` + + // CorrectedQuery: Contains the spell corrected query, if found. If the + // spell correction type is AUTOMATIC, then the search results are based + // on corrected_query. Otherwise the original query is used for search. + CorrectedQuery string `json:"correctedQuery,omitempty"` + + // Facets: Results of facets requested by user. + Facets []*GoogleCloudDiscoveryengineV1alphaSearchResponseFacet `json:"facets,omitempty"` + + GeoSearchDebugInfo []*GoogleCloudDiscoveryengineV1alphaSearchResponseGeoSearchDebugInfo `json:"geoSearchDebugInfo,omitempty"` + + // GuidedSearchResult: Guided search result. + GuidedSearchResult *GoogleCloudDiscoveryengineV1alphaSearchResponseGuidedSearchResult `json:"guidedSearchResult,omitempty"` + + // NextPageToken: A token that can be sent as SearchRequest.page_token + // to retrieve the next page. If this field is omitted, there are no + // subsequent pages. + NextPageToken string `json:"nextPageToken,omitempty"` + + // QueryExpansionInfo: Query expansion information for the returned + // results. + QueryExpansionInfo *GoogleCloudDiscoveryengineV1alphaSearchResponseQueryExpansionInfo `json:"queryExpansionInfo,omitempty"` + + // RedirectUri: The URI of a customer-defined redirect page. If redirect + // action is triggered, no search is performed, and only redirect_uri + // and attribution_token are set in the response. + RedirectUri string `json:"redirectUri,omitempty"` + + // Results: A list of matched documents. The order represents the + // ranking. + Results []*GoogleCloudDiscoveryengineV1alphaSearchResponseSearchResult `json:"results,omitempty"` + + // Summary: A summary as part of the search results. This field is only + // returned if SearchRequest.ContentSearchSpec.summary_spec is set. + Summary *GoogleCloudDiscoveryengineV1alphaSearchResponseSummary `json:"summary,omitempty"` + + // TotalSize: The estimated total count of matched items irrespective of + // pagination. The count of results returned by pagination may be less + // than the total_size that matches. + TotalSize int64 `json:"totalSize,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the + // server. + googleapi.ServerResponse `json:"-"` + + // ForceSendFields is a list of field names (e.g. "AppliedControls") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "AppliedControls") to + // include in API requests with the JSON null value. By default, fields + // with empty values are omitted from API requests. However, any field + // with an empty value appearing in NullFields will be sent to the + // server as null. It is an error if a field in this list has a + // non-empty value. This may be used to include null fields in Patch + // requests. + NullFields []string `json:"-"` +} - // JsonSchema: The JSON representation of the schema. - JsonSchema string `json:"jsonSchema,omitempty"` +func (s *GoogleCloudDiscoveryengineV1alphaSearchResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSearchResponse + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} - // Name: Immutable. The full resource name of the schema, in the format - // of - // `projects/{project}/locations/{location}/collections/{collection}/data - // Stores/{data_store}/schemas/{schema}`. This field must be a UTF-8 - // encoded string with a length limit of 1024 characters. - Name string `json:"name,omitempty"` +// GoogleCloudDiscoveryengineV1alphaSearchResponseFacet: A facet result. +type GoogleCloudDiscoveryengineV1alphaSearchResponseFacet struct { + // DynamicFacet: Whether the facet is dynamically generated. + DynamicFacet bool `json:"dynamicFacet,omitempty"` - // StructSchema: The structured representation of the schema. - StructSchema googleapi.RawMessage `json:"structSchema,omitempty"` + // Key: The key for this facet. E.g., "colors" or "price". It matches + // SearchRequest.FacetSpec.FacetKey.key. + Key string `json:"key,omitempty"` - // ServerResponse contains the HTTP response code and headers from the - // server. - googleapi.ServerResponse `json:"-"` + // Values: The facet values for this field. + Values []*GoogleCloudDiscoveryengineV1alphaSearchResponseFacetFacetValue `json:"values,omitempty"` - // ForceSendFields is a list of field names (e.g. "FieldConfigs") to + // ForceSendFields is a list of field names (e.g. "DynamicFacet") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -5804,7 +7856,7 @@ type GoogleCloudDiscoveryengineV1alphaSchema struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "FieldConfigs") to include + // NullFields is a list of field names (e.g. "DynamicFacet") to include // in API requests with the JSON null value. By default, fields with // empty values are omitted from API requests. However, any field with // an empty value appearing in NullFields will be sent to the server as @@ -5813,40 +7865,26 @@ type GoogleCloudDiscoveryengineV1alphaSchema struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaSchema) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSchema +func (s *GoogleCloudDiscoveryengineV1alphaSearchResponseFacet) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSearchResponseFacet raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaSearchInfo: Detailed search -// information. -type GoogleCloudDiscoveryengineV1alphaSearchInfo struct { - // Offset: An integer that specifies the current offset for pagination - // (the 0-indexed starting location, amongst the products deemed by the - // API as relevant). See SearchRequest.offset for definition. If this - // field is negative, an `INVALID_ARGUMENT` is returned. This can only - // be set for `search` events. Other event types should not set this - // field. Otherwise, an `INVALID_ARGUMENT` error is returned. - Offset int64 `json:"offset,omitempty"` +// GoogleCloudDiscoveryengineV1alphaSearchResponseFacetFacetValue: A +// facet value which contains value names and their count. +type GoogleCloudDiscoveryengineV1alphaSearchResponseFacetFacetValue struct { + // Count: Number of items that have this facet value. + Count int64 `json:"count,omitempty,string"` - // OrderBy: The order in which products are returned, if applicable. See - // SearchRequest.order_by for definition and syntax. The value must be a - // UTF-8 encoded string with a length limit of 1,000 characters. - // Otherwise, an `INVALID_ARGUMENT` error is returned. This can only be - // set for `search` events. Other event types should not set this field. - // Otherwise, an `INVALID_ARGUMENT` error is returned. - OrderBy string `json:"orderBy,omitempty"` + // Interval: Interval value for a facet, such as 10, 20) for facet + // "price". It matches [SearchRequest.FacetSpec.FacetKey.intervals. + Interval *GoogleCloudDiscoveryengineV1alphaInterval `json:"interval,omitempty"` - // SearchQuery: The user's search query. See SearchRequest.query for - // definition. The value must be a UTF-8 encoded string with a length - // limit of 5,000 characters. Otherwise, an `INVALID_ARGUMENT` error is - // returned. At least one of search_query or PageInfo.page_category is - // required for `search` events. Other event types should not set this - // field. Otherwise, an `INVALID_ARGUMENT` error is returned. - SearchQuery string `json:"searchQuery,omitempty"` + // Value: Text value of a facet, such as "Black" for facet "colors". + Value string `json:"value,omitempty"` - // ForceSendFields is a list of field names (e.g. "Offset") to + // ForceSendFields is a list of field names (e.g. "Count") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -5854,7 +7892,7 @@ type GoogleCloudDiscoveryengineV1alphaSearchInfo struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Offset") to include in API + // NullFields is a list of field names (e.g. "Count") to include in API // requests with the JSON null value. By default, fields with empty // values are omitted from API requests. However, any field with an // empty value appearing in NullFields will be sent to the server as @@ -5863,186 +7901,24 @@ type GoogleCloudDiscoveryengineV1alphaSearchInfo struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaSearchInfo) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSearchInfo +func (s *GoogleCloudDiscoveryengineV1alphaSearchResponseFacetFacetValue) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSearchResponseFacetFacetValue raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaSearchRequest: Request message for -// SearchService.Search method. -type GoogleCloudDiscoveryengineV1alphaSearchRequest struct { - // BoostSpec: Boost specification to boost certain documents. For more - // information on boosting, see Boosting - // (https://cloud.google.com/retail/docs/boosting#boost) - BoostSpec *GoogleCloudDiscoveryengineV1alphaSearchRequestBoostSpec `json:"boostSpec,omitempty"` - - // Branch: The branch resource name, such as - // `projects/*/locations/global/collections/default_collection/dataStores - // /default_data_store/branches/0`. Use `default_branch` as the branch - // ID or leave this field empty, to search documents under the default - // branch. - Branch string `json:"branch,omitempty"` - - // CanonicalFilter: The default filter that is applied when a user - // performs a search without checking any filters on the search page. - // The filter applied to every search request when quality improvement - // such as query expansion is needed. In the case a query does not have - // a sufficient amount of results this filter will be used to determine - // whether or not to enable the query expansion flow. The original - // filter will still be used for the query expanded search. This field - // is strongly recommended to achieve high search quality. For more - // information about filter syntax, see SearchRequest.filter. - CanonicalFilter string `json:"canonicalFilter,omitempty"` - - // ContentSearchSpec: A specification for configuring the behavior of - // content search. - ContentSearchSpec *GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpec `json:"contentSearchSpec,omitempty"` - - // EmbeddingSpec: Uses the provided embedding to do additional semantic - // document retrieval. The retrieval is based on the dot product of - // SearchRequest.EmbeddingSpec.EmbeddingVector.vector and the document - // embedding that is provided in - // SearchRequest.EmbeddingSpec.EmbeddingVector.field_path. If - // SearchRequest.EmbeddingSpec.EmbeddingVector.field_path is not - // provided, it will use ServingConfig.EmbeddingConfig.field_paths. - EmbeddingSpec *GoogleCloudDiscoveryengineV1alphaSearchRequestEmbeddingSpec `json:"embeddingSpec,omitempty"` - - // FacetSpecs: Facet specifications for faceted search. If empty, no - // facets are returned. A maximum of 100 values are allowed. Otherwise, - // an `INVALID_ARGUMENT` error is returned. - FacetSpecs []*GoogleCloudDiscoveryengineV1alphaSearchRequestFacetSpec `json:"facetSpecs,omitempty"` - - // Filter: 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 --> 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) - Filter string `json:"filter,omitempty"` - - // ImageQuery: Raw image query. - ImageQuery *GoogleCloudDiscoveryengineV1alphaSearchRequestImageQuery `json:"imageQuery,omitempty"` - - // Offset: 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. - Offset int64 `json:"offset,omitempty"` - - // OrderBy: The order in which documents are returned. Documents can be - // ordered by a field in an Document object. Leave it unset if ordered - // by relevance. `order_by` expression is case-sensitive. For more - // information on ordering, see Ordering - // (https://cloud.google.com/retail/docs/filter-and-order#order) If this - // field is unrecognizable, an `INVALID_ARGUMENT` is returned. - OrderBy string `json:"orderBy,omitempty"` - - // PageSize: Maximum number of Documents to return. If unspecified, - // defaults to a reasonable value. The maximum allowed value is 100. - // Values above 100 are coerced to 100. If this field is negative, an - // `INVALID_ARGUMENT` is returned. - PageSize int64 `json:"pageSize,omitempty"` - - // PageToken: A page token received from a previous SearchService.Search - // call. Provide this to retrieve the subsequent page. When paginating, - // all other parameters provided to SearchService.Search must match the - // call that provided the page token. Otherwise, an `INVALID_ARGUMENT` - // error is returned. - PageToken string `json:"pageToken,omitempty"` - - // Params: Additional search parameters. For public website search only, - // supported values are: * `user_country_code`: string. Default empty. - // If set to non-empty, results are restricted or boosted based on the - // location provided. Example: user_country_code: "au" For available - // codes see Country Codes - // (https://developers.google.com/custom-search/docs/json_api_reference#countryCodes) - // * `search_type`: double. Default empty. Enables non-webpage searching - // depending on the value. The only valid non-default value is 1, which - // enables image searching. Example: search_type: 1 - Params googleapi.RawMessage `json:"params,omitempty"` - - // Query: Raw search query. - Query string `json:"query,omitempty"` - - // QueryExpansionSpec: The query expansion specification that specifies - // the conditions under which query expansion occurs. - QueryExpansionSpec *GoogleCloudDiscoveryengineV1alphaSearchRequestQueryExpansionSpec `json:"queryExpansionSpec,omitempty"` - - // RankingExpression: The ranking expression controls the customized - // ranking on retrieval documents. This overrides - // ServingConfig.ranking_expression. The ranking expression is a single - // function or multiple functions that are joint by "+". * - // ranking_expression = function, { " + ", function }; Supported - // functions: * double * relevance_score * double * - // dotProduct(embedding_field_path) Function variables: - // `relevance_score`: pre-defined keywords, used for measure relevance - // between query and document. `embedding_field_path`: the document - // embedding field used with query embedding vector. `dotProduct`: - // embedding function between embedding_field_path and query embedding - // vector. Example ranking expression: If document has an embedding - // field doc_embedding, the ranking expression could be `0.5 * - // relevance_score + 0.3 * dotProduct(doc_embedding)`. - RankingExpression string `json:"rankingExpression,omitempty"` - - // SafeSearch: Whether to turn on safe search. This is only supported - // for website search. - SafeSearch bool `json:"safeSearch,omitempty"` - - // ServingConfig: Required. The resource name of the Search serving - // config, such as - // `projects/*/locations/global/collections/default_collection/engines/*/ - // servingConfigs/default_serving_config`, or - // `projects/*/locations/global/collections/default_collection/dataStores - // /default_data_store/servingConfigs/default_serving_config`. This - // field is used to identify the serving configuration name, set of - // models used to make the search. - ServingConfig string `json:"servingConfig,omitempty"` - - // SpellCorrectionSpec: The spell correction specification that - // specifies the mode under which spell correction takes effect. - SpellCorrectionSpec *GoogleCloudDiscoveryengineV1alphaSearchRequestSpellCorrectionSpec `json:"spellCorrectionSpec,omitempty"` - - // UserInfo: Information about the end user. Highly recommended for - // analytics. UserInfo.user_agent is used to deduce `device_type` for - // analytics. - UserInfo *GoogleCloudDiscoveryengineV1alphaUserInfo `json:"userInfo,omitempty"` - - // UserLabels: The user labels applied to a resource must meet the - // following requirements: * Each resource can have multiple labels, up - // to a maximum of 64. * Each label must be a key-value pair. * Keys - // have a minimum length of 1 character and a maximum length of 63 - // characters and cannot be empty. Values can be empty and have a - // maximum length of 63 characters. * Keys and values can contain only - // lowercase letters, numeric characters, underscores, and dashes. All - // characters must use UTF-8 encoding, and international characters are - // allowed. * The key portion of a label must be unique. However, you - // can use the same key with multiple resources. * Keys must start with - // a lowercase letter or international character. See Google Cloud - // Document - // (https://cloud.google.com/resource-manager/docs/creating-managing-labels#requirements) - // for more details. - UserLabels map[string]string `json:"userLabels,omitempty"` - - // UserPseudoId: A unique identifier for tracking visitors. For example, - // this could be implemented with an HTTP cookie, which should be able - // to uniquely identify a visitor on a single device. This unique - // identifier should not change if the visitor logs in or out of the - // website. This field should NOT have a fixed value such as - // `unknown_visitor`. This should be the same identifier as - // UserEvent.user_pseudo_id and CompleteQueryRequest.user_pseudo_id The - // field must be a UTF-8 encoded string with a length limit of 128 - // characters. Otherwise, an `INVALID_ARGUMENT` error is returned. - UserPseudoId string `json:"userPseudoId,omitempty"` +// GoogleCloudDiscoveryengineV1alphaSearchResponseGeoSearchDebugInfo: +// Debug information specifically related to forward geocoding issues +// arising from Geolocation Search. +type GoogleCloudDiscoveryengineV1alphaSearchResponseGeoSearchDebugInfo struct { + // ErrorMessage: The error produced. + ErrorMessage string `json:"errorMessage,omitempty"` - // ForceSendFields is a list of field names (e.g. "BoostSpec") to + // OriginalAddressQuery: The address from which forward geocoding + // ingestion produced issues. + OriginalAddressQuery string `json:"originalAddressQuery,omitempty"` + + // ForceSendFields is a list of field names (e.g. "ErrorMessage") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -6050,31 +7926,33 @@ type GoogleCloudDiscoveryengineV1alphaSearchRequest struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "BoostSpec") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as + // NullFields is a list of field names (e.g. "ErrorMessage") to include + // in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. However, any field with + // an empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaSearchRequest) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSearchRequest +func (s *GoogleCloudDiscoveryengineV1alphaSearchResponseGeoSearchDebugInfo) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSearchResponseGeoSearchDebugInfo raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaSearchRequestBoostSpec: Boost -// specification to boost certain documents. -type GoogleCloudDiscoveryengineV1alphaSearchRequestBoostSpec struct { - // ConditionBoostSpecs: Condition boost specifications. If a document - // matches multiple conditions in the specifictions, boost scores from - // these specifications are all applied and combined in a non-linear - // way. Maximum number of specifications is 20. - ConditionBoostSpecs []*GoogleCloudDiscoveryengineV1alphaSearchRequestBoostSpecConditionBoostSpec `json:"conditionBoostSpecs,omitempty"` +// GoogleCloudDiscoveryengineV1alphaSearchResponseGuidedSearchResult: +// Guided search result. The guided search helps user to refine the +// search results and narrow down to the real needs from a broaded +// search results. +type GoogleCloudDiscoveryengineV1alphaSearchResponseGuidedSearchResult struct { + // FollowUpQuestions: Suggested follow-up questions. + FollowUpQuestions []string `json:"followUpQuestions,omitempty"` - // ForceSendFields is a list of field names (e.g. "ConditionBoostSpecs") + // RefinementAttributes: A list of ranked refinement attributes. + RefinementAttributes []*GoogleCloudDiscoveryengineV1alphaSearchResponseGuidedSearchResultRefinementAttribute `json:"refinementAttributes,omitempty"` + + // ForceSendFields is a list of field names (e.g. "FollowUpQuestions") // to unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -6082,7 +7960,7 @@ type GoogleCloudDiscoveryengineV1alphaSearchRequestBoostSpec struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "ConditionBoostSpecs") to + // NullFields is a list of field names (e.g. "FollowUpQuestions") to // include in API requests with the JSON null value. By default, fields // with empty values are omitted from API requests. However, any field // with an empty value appearing in NullFields will be sent to the @@ -6092,39 +7970,24 @@ type GoogleCloudDiscoveryengineV1alphaSearchRequestBoostSpec struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaSearchRequestBoostSpec) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSearchRequestBoostSpec +func (s *GoogleCloudDiscoveryengineV1alphaSearchResponseGuidedSearchResult) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSearchResponseGuidedSearchResult raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaSearchRequestBoostSpecConditionBoostS -// pec: Boost applies to documents which match a condition. -type GoogleCloudDiscoveryengineV1alphaSearchRequestBoostSpecConditionBoostSpec struct { - // Boost: Strength of the condition boost, which should be in [-1, 1]. - // Negative boost means demotion. Default is 0.0. Setting to 1.0 gives - // the document a big promotion. However, it does not necessarily mean - // that the boosted document will be the top result at all times, nor - // that other documents will be excluded. Results could still be shown - // even when none of them matches the condition. And results that are - // significantly more relevant to the search query can still trump your - // heavily favored but irrelevant documents. Setting to -1.0 gives the - // document a big demotion. However, results that are deeply relevant - // might still be shown. The document will have an upstream battle to - // get a fairly high ranking, but it is not blocked out completely. - // Setting to 0.0 means no boost applied. The boosting condition is - // ignored. - Boost float64 `json:"boost,omitempty"` +// GoogleCloudDiscoveryengineV1alphaSearchResponseGuidedSearchResultRefin +// ementAttribute: Useful attribute for search result refinements. +type GoogleCloudDiscoveryengineV1alphaSearchResponseGuidedSearchResultRefinementAttribute struct { + // AttributeKey: Attribute key used to refine the results e.g. + // 'movie_type'. + AttributeKey string `json:"attributeKey,omitempty"` - // Condition: An expression which specifies a boost condition. The - // syntax and supported fields are the same as a filter expression. See - // SearchRequest.filter for detail syntax and limitations. Examples: * - // To boost documents with document ID "doc_1" or "doc_2", and color - // "Red" or "Blue": * (id: ANY("doc_1", "doc_2")) AND (color: - // ANY("Red","Blue")) - Condition string `json:"condition,omitempty"` + // AttributeValue: Attribute value used to refine the results e.g. + // 'drama'. + AttributeValue string `json:"attributeValue,omitempty"` - // ForceSendFields is a list of field names (e.g. "Boost") to + // ForceSendFields is a list of field names (e.g. "AttributeKey") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -6132,154 +7995,167 @@ type GoogleCloudDiscoveryengineV1alphaSearchRequestBoostSpecConditionBoostSpec s // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Boost") to include in API - // requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as + // NullFields is a list of field names (e.g. "AttributeKey") to include + // in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. However, any field with + // an empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaSearchRequestBoostSpecConditionBoostSpec) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSearchRequestBoostSpecConditionBoostSpec +func (s *GoogleCloudDiscoveryengineV1alphaSearchResponseGuidedSearchResultRefinementAttribute) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSearchResponseGuidedSearchResultRefinementAttribute raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -func (s *GoogleCloudDiscoveryengineV1alphaSearchRequestBoostSpecConditionBoostSpec) UnmarshalJSON(data []byte) error { - type NoMethod GoogleCloudDiscoveryengineV1alphaSearchRequestBoostSpecConditionBoostSpec - var s1 struct { - Boost gensupport.JSONFloat64 `json:"boost"` - *NoMethod - } - s1.NoMethod = (*NoMethod)(s) - if err := json.Unmarshal(data, &s1); err != nil { - return err - } - s.Boost = float64(s1.Boost) - return nil +// GoogleCloudDiscoveryengineV1alphaSearchResponseQueryExpansionInfo: +// Information describing query expansion including whether expansion +// has occurred. +type GoogleCloudDiscoveryengineV1alphaSearchResponseQueryExpansionInfo struct { + // ExpandedQuery: Bool describing whether query expansion has occurred. + ExpandedQuery bool `json:"expandedQuery,omitempty"` + + // PinnedResultCount: Number of pinned results. This field will only be + // set when expansion happens and + // SearchRequest.QueryExpansionSpec.pin_unexpanded_results is set to + // true. + PinnedResultCount int64 `json:"pinnedResultCount,omitempty,string"` + + // ForceSendFields is a list of field names (e.g. "ExpandedQuery") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "ExpandedQuery") to include + // in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. However, any field with + // an empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` } -// GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpec: A -// specification for configuring the behavior of content search. -type GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpec struct { - // ExtractiveContentSpec: If there is no extractive_content_spec - // provided, there will be no extractive answer in the search response. - ExtractiveContentSpec *GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecExtractiveContentSpec `json:"extractiveContentSpec,omitempty"` +func (s *GoogleCloudDiscoveryengineV1alphaSearchResponseQueryExpansionInfo) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSearchResponseQueryExpansionInfo + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} - // SnippetSpec: If `snippetSpec` is not specified, snippets are not - // included in the search response. - SnippetSpec *GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSnippetSpec `json:"snippetSpec,omitempty"` +// GoogleCloudDiscoveryengineV1alphaSearchResponseSearchResult: +// Represents the search results. +type GoogleCloudDiscoveryengineV1alphaSearchResponseSearchResult struct { + // Document: The document data snippet in the search response. Only + // fields that are marked as retrievable are populated. + Document *GoogleCloudDiscoveryengineV1alphaDocument `json:"document,omitempty"` - // SummarySpec: If `summarySpec` is not specified, summaries are not - // included in the search response. - SummarySpec *GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSummarySpec `json:"summarySpec,omitempty"` + // Id: Document.id of the searched Document. + Id string `json:"id,omitempty"` - // ForceSendFields is a list of field names (e.g. - // "ExtractiveContentSpec") to unconditionally include in API requests. - // By default, fields with empty or default values are omitted from API - // requests. However, any non-pointer, non-interface field appearing in - // ForceSendFields will be sent to the server regardless of whether the - // field is empty or not. This may be used to include empty fields in - // Patch requests. + // ModelScores: Google provided available scores. + ModelScores map[string]GoogleCloudDiscoveryengineV1alphaDoubleList `json:"modelScores,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Document") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "ExtractiveContentSpec") to - // include in API requests with the JSON null value. By default, fields - // with empty values are omitted from API requests. However, any field - // with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. + // NullFields is a list of field names (e.g. "Document") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpec) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpec +func (s *GoogleCloudDiscoveryengineV1alphaSearchResponseSearchResult) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSearchResponseSearchResult raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecExtract -// iveContentSpec: A specification for configuring the extractive -// content in a search response. -type GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecExtractiveContentSpec struct { - // MaxExtractiveAnswerCount: The maximum number of extractive answers - // returned in each search result. An extractive answer is a verbatim - // answer extracted from the original document, which provides a precise - // and contextually relevant answer to the search query. If the number - // of matching answers is less than the `max_extractive_answer_count`, - // return all of the answers. Otherwise, return the - // `max_extractive_answer_count`. At most five answers are returned for - // each SearchResult. - MaxExtractiveAnswerCount int64 `json:"maxExtractiveAnswerCount,omitempty"` - - // MaxExtractiveSegmentCount: The max number of extractive segments - // returned in each search result. Only applied if the DataStore is set - // to DataStore.ContentConfig.CONTENT_REQUIRED or - // DataStore.solution_types is SOLUTION_TYPE_CHAT. An extractive segment - // is a text segment extracted from the original document that is - // relevant to the search query, and, in general, more verbose than an - // extractive answer. The segment could then be used as input for LLMs - // to generate summaries and answers. If the number of matching segments - // is less than `max_extractive_segment_count`, return all of the - // segments. Otherwise, return the `max_extractive_segment_count`. - MaxExtractiveSegmentCount int64 `json:"maxExtractiveSegmentCount,omitempty"` +// GoogleCloudDiscoveryengineV1alphaSearchResponseSummary: Summary of +// the top N search result specified by the summary spec. +type GoogleCloudDiscoveryengineV1alphaSearchResponseSummary struct { + // SafetyAttributes: A collection of Safety Attribute categories and + // their associated confidence scores. + SafetyAttributes *GoogleCloudDiscoveryengineV1alphaSearchResponseSummarySafetyAttributes `json:"safetyAttributes,omitempty"` - // NumNextSegments: Return at most `num_next_segments` segments after - // each selected segments. - NumNextSegments int64 `json:"numNextSegments,omitempty"` + // SummarySkippedReasons: Additional summary-skipped reasons. This + // provides the reason for ignored cases. If nothing is skipped, this + // field is not set. + // + // Possible values: + // "SUMMARY_SKIPPED_REASON_UNSPECIFIED" - Default value. The summary + // skipped reason is not specified. + // "ADVERSARIAL_QUERY_IGNORED" - The adversarial query ignored case. + // Only populated when SummarySpec.ignore_adversarial_query is set to + // `true`. + // "NON_SUMMARY_SEEKING_QUERY_IGNORED" - The non-summary seeking query + // ignored case. Only populated when + // SummarySpec.ignore_non_summary_seeking_query is set to `true`. + // "OUT_OF_DOMAIN_QUERY_IGNORED" - The out-of-domain query ignored + // case. Google skips the summary if there are no high-relevance search + // results. For example, the data store contains facts about company A + // but the user query is asking questions about company B. + // "POTENTIAL_POLICY_VIOLATION" - The potential policy violation case. + // Google skips the summary if there is a potential policy violation + // detected. This includes content that may be violent or toxic. + // "LLM_ADDON_NOT_ENABLED" - The LLM addon not enabled case. Google + // skips the summary if the LLM addon is not enabled. + SummarySkippedReasons []string `json:"summarySkippedReasons,omitempty"` - // NumPreviousSegments: Specifies whether to also include the adjacent - // from each selected segments. Return at most `num_previous_segments` - // segments before each selected segments. - NumPreviousSegments int64 `json:"numPreviousSegments,omitempty"` + // SummaryText: The summary content. + SummaryText string `json:"summaryText,omitempty"` - // ForceSendFields is a list of field names (e.g. - // "MaxExtractiveAnswerCount") to unconditionally include in API - // requests. By default, fields with empty or default values are omitted - // from API requests. However, any non-pointer, non-interface field - // appearing in ForceSendFields will be sent to the server regardless of - // whether the field is empty or not. This may be used to include empty - // fields in Patch requests. + SummaryWithMetadata *GoogleCloudDiscoveryengineV1alphaSearchResponseSummarySummaryWithMetadata `json:"summaryWithMetadata,omitempty"` + + // ForceSendFields is a list of field names (e.g. "SafetyAttributes") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "MaxExtractiveAnswerCount") - // to include in API requests with the JSON null value. By default, - // fields with empty values are omitted from API requests. However, any - // field with an empty value appearing in NullFields will be sent to the + // NullFields is a list of field names (e.g. "SafetyAttributes") to + // include in API requests with the JSON null value. By default, fields + // with empty values are omitted from API requests. However, any field + // with an empty value appearing in NullFields will be sent to the // server as null. It is an error if a field in this list has a // non-empty value. This may be used to include null fields in Patch // requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecExtractiveContentSpec) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecExtractiveContentSpec +func (s *GoogleCloudDiscoveryengineV1alphaSearchResponseSummary) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSearchResponseSummary raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSnippet -// Spec: A specification for configuring snippets in a search response. -type GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSnippetSpec struct { - // MaxSnippetCount: [DEPRECATED] This field is deprecated. To control - // snippet return, use `return_snippet` field. For backwards - // compatibility, we will return snippet if max_snippet_count > 0. - MaxSnippetCount int64 `json:"maxSnippetCount,omitempty"` +// GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryCitation: +// Citation info for a segment. +type GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryCitation struct { + // EndIndex: End of the attributed segment, exclusive. + EndIndex int64 `json:"endIndex,omitempty,string"` - // ReferenceOnly: [DEPRECATED] This field is deprecated and will have no - // affect on the snippet. - ReferenceOnly bool `json:"referenceOnly,omitempty"` + // Sources: Citation sources for the attributed segment. + Sources []*GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryCitationSource `json:"sources,omitempty"` - // ReturnSnippet: If `true`, then return snippet. If no snippet can be - // generated, we return "No snippet is available for this page." A - // `snippet_status` with `SUCCESS` or `NO_SNIPPET_AVAILABLE` will also - // be returned. - ReturnSnippet bool `json:"returnSnippet,omitempty"` + // StartIndex: Index indicates the start of the segment, measured in + // bytes/unicode. + StartIndex int64 `json:"startIndex,omitempty,string"` - // ForceSendFields is a list of field names (e.g. "MaxSnippetCount") to + // ForceSendFields is a list of field names (e.g. "EndIndex") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -6287,115 +8163,98 @@ type GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSnippetSpec // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "MaxSnippetCount") to - // include in API requests with the JSON null value. By default, fields - // with empty values are omitted from API requests. However, any field - // with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. + // NullFields is a list of field names (e.g. "EndIndex") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSnippetSpec) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSnippetSpec +func (s *GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryCitation) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryCitation raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSummary -// Spec: A specification for configuring a summary returned in a search -// response. -type GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSummarySpec struct { - // IgnoreAdversarialQuery: Specifies whether to filter out adversarial - // queries. The default value is `false`. Google employs search-query - // classification to detect adversarial queries. No summary is returned - // if the search query is classified as an adversarial query. For - // example, a user might ask a question regarding negative comments - // about the company or submit a query designed to generate unsafe, - // policy-violating output. If this field is set to `true`, we skip - // generating summaries for adversarial queries and return fallback - // messages instead. - IgnoreAdversarialQuery bool `json:"ignoreAdversarialQuery,omitempty"` - - // IgnoreNonSummarySeekingQuery: Specifies whether to filter out queries - // that are not summary-seeking. The default value is `false`. Google - // employs search-query classification to detect summary-seeking - // queries. No summary is returned if the search query is classified as - // a non-summary seeking query. For example, `why is the sky blue` and - // `Who is the best soccer player in the world?` are summary-seeking - // queries, but `SFO airport` and `world cup 2026` are not. They are - // most likely navigational queries. If this field is set to `true`, we - // skip generating summaries for non-summary seeking queries and return - // fallback messages instead. - IgnoreNonSummarySeekingQuery bool `json:"ignoreNonSummarySeekingQuery,omitempty"` - - // IncludeCitations: Specifies whether to include citations in the - // summary. The default value is `false`. When this field is set to - // `true`, summaries include in-line citation numbers. Example summary - // including citations: BigQuery is Google Cloud's fully managed and - // completely serverless enterprise data warehouse [1]. BigQuery - // supports all data types, works across clouds, and has built-in - // machine learning and business intelligence, all within a unified - // platform [2, 3]. The citation numbers refer to the returned search - // results and are 1-indexed. For example, [1] means that the sentence - // is attributed to the first search result. [2, 3] means that the - // sentence is attributed to both the second and third search results. - IncludeCitations bool `json:"includeCitations,omitempty"` +// GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryCitationMetadata +// : Citation metadata. +type GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryCitationMetadata struct { + // Citations: Citations for segments. + Citations []*GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryCitation `json:"citations,omitempty"` - // LanguageCode: Language code for Summary. Use language tags defined by - // BCP47 (https://www.rfc-editor.org/rfc/bcp/bcp47.txt). Note: This is - // an experimental feature. - LanguageCode string `json:"languageCode,omitempty"` + // ForceSendFields is a list of field names (e.g. "Citations") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` - // ModelPromptSpec: If specified, the spec will be used to modify the - // prompt provided to the LLM. - ModelPromptSpec *GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSummarySpecModelPromptSpec `json:"modelPromptSpec,omitempty"` + // NullFields is a list of field names (e.g. "Citations") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} - // ModelSpec: If specified, the spec will be used to modify the model - // specification provided to the LLM. - ModelSpec *GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSummarySpecModelSpec `json:"modelSpec,omitempty"` +func (s *GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryCitationMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryCitationMetadata + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} - // SummaryResultCount: The number of top results to generate the summary - // from. If the number of results returned is less than - // `summaryResultCount`, the summary is generated from all of the - // results. At most five results can be used to generate a summary. - SummaryResultCount int64 `json:"summaryResultCount,omitempty"` +// GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryCitationSource: +// Citation source. +type GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryCitationSource struct { + // ReferenceIndex: Document reference index from + // SummaryWithMetadata.references. It is 0-indexed and the value will be + // zero if the reference_index is not set explicitly. + ReferenceIndex int64 `json:"referenceIndex,omitempty,string"` - // ForceSendFields is a list of field names (e.g. - // "IgnoreAdversarialQuery") to unconditionally include in API requests. - // By default, fields with empty or default values are omitted from API - // requests. However, any non-pointer, non-interface field appearing in - // ForceSendFields will be sent to the server regardless of whether the - // field is empty or not. This may be used to include empty fields in - // Patch requests. + // ForceSendFields is a list of field names (e.g. "ReferenceIndex") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "IgnoreAdversarialQuery") - // to include in API requests with the JSON null value. By default, - // fields with empty values are omitted from API requests. However, any - // field with an empty value appearing in NullFields will be sent to the + // NullFields is a list of field names (e.g. "ReferenceIndex") to + // include in API requests with the JSON null value. By default, fields + // with empty values are omitted from API requests. However, any field + // with an empty value appearing in NullFields will be sent to the // server as null. It is an error if a field in this list has a // non-empty value. This may be used to include null fields in Patch // requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSummarySpec) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSummarySpec +func (s *GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryCitationSource) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryCitationSource raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSummary -// SpecModelPromptSpec: Specification of the prompt to use with the -// model. -type GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSummarySpecModelPromptSpec struct { - // Preamble: Text at the beginning of the prompt that instructs the - // assistant. Examples are available in the user guide. - Preamble string `json:"preamble,omitempty"` +// GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryReference: +// Document reference. +type GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryReference struct { + // Document: Required. Document.name of the document. Full resource name + // of the referenced document, in the format + // `projects/*/locations/*/collections/*/dataStores/*/branches/*/document + // s/*`. + Document string `json:"document,omitempty"` - // ForceSendFields is a list of field names (e.g. "Preamble") to + // Title: Title of the document. + Title string `json:"title,omitempty"` + + // Uri: Cloud Storage or HTTP uri for the document. + Uri string `json:"uri,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Document") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -6403,7 +8262,7 @@ type GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSummarySpecM // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Preamble") to include in + // NullFields is a list of field names (e.g. "Document") to include in // API requests with the JSON null value. By default, fields with empty // values are omitted from API requests. However, any field with an // empty value appearing in NullFields will be sent to the server as @@ -6412,24 +8271,24 @@ type GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSummarySpecM NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSummarySpecModelPromptSpec) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSummarySpecModelPromptSpec +func (s *GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryReference) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryReference raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSummary -// SpecModelSpec: Specification of the model. -type GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSummarySpecModelSpec struct { - // Version: The model version used to generate the summary. Supported - // values are: * `stable`: string. Default value when no value is - // specified. Uses a generally available, fine-tuned version of the - // text-bison@001 model. * `preview`: string. (Public preview) Uses a - // fine-tuned version of the text-bison@002 model. This model works only - // for summaries in English. - Version string `json:"version,omitempty"` +// GoogleCloudDiscoveryengineV1alphaSearchResponseSummarySafetyAttributes +// : Safety Attribute categories and their associated confidence scores. +type GoogleCloudDiscoveryengineV1alphaSearchResponseSummarySafetyAttributes struct { + // Categories: The display names of Safety Attribute categories + // associated with the generated content. Order matches the Scores. + Categories []string `json:"categories,omitempty"` - // ForceSendFields is a list of field names (e.g. "Version") to + // Scores: The confidence scores of the each category, higher value + // means higher confidence. Order matches the Categories. + Scores []float64 `json:"scores,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Categories") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -6437,7 +8296,7 @@ type GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSummarySpecM // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Version") to include in + // NullFields is a list of field names (e.g. "Categories") to include in // API requests with the JSON null value. By default, fields with empty // values are omitted from API requests. However, any field with an // empty value appearing in NullFields will be sent to the server as @@ -6446,21 +8305,42 @@ type GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSummarySpecM NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSummarySpecModelSpec) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSummarySpecModelSpec +func (s *GoogleCloudDiscoveryengineV1alphaSearchResponseSummarySafetyAttributes) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSearchResponseSummarySafetyAttributes raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaSearchRequestEmbeddingSpec: The -// specification that uses customized query embedding vector to do -// semantic document retrieval. -type GoogleCloudDiscoveryengineV1alphaSearchRequestEmbeddingSpec struct { - // EmbeddingVectors: The embedding vector used for retrieval. Limit to - // 1. - EmbeddingVectors []*GoogleCloudDiscoveryengineV1alphaSearchRequestEmbeddingSpecEmbeddingVector `json:"embeddingVectors,omitempty"` +func (s *GoogleCloudDiscoveryengineV1alphaSearchResponseSummarySafetyAttributes) UnmarshalJSON(data []byte) error { + type NoMethod GoogleCloudDiscoveryengineV1alphaSearchResponseSummarySafetyAttributes + var s1 struct { + Scores []gensupport.JSONFloat64 `json:"scores"` + *NoMethod + } + s1.NoMethod = (*NoMethod)(s) + if err := json.Unmarshal(data, &s1); err != nil { + return err + } + s.Scores = make([]float64, len(s1.Scores)) + for i := range s1.Scores { + s.Scores[i] = float64(s1.Scores[i]) + } + return nil +} + +// GoogleCloudDiscoveryengineV1alphaSearchResponseSummarySummaryWithMetad +// ata: Summary with metadata information. +type GoogleCloudDiscoveryengineV1alphaSearchResponseSummarySummaryWithMetadata struct { + // CitationMetadata: Citation metadata for given summary. + CitationMetadata *GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryCitationMetadata `json:"citationMetadata,omitempty"` - // ForceSendFields is a list of field names (e.g. "EmbeddingVectors") to + // References: Document References. + References []*GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryReference `json:"references,omitempty"` + + // Summary: Summary text with no citation information. + Summary string `json:"summary,omitempty"` + + // ForceSendFields is a list of field names (e.g. "CitationMetadata") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -6468,7 +8348,7 @@ type GoogleCloudDiscoveryengineV1alphaSearchRequestEmbeddingSpec struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "EmbeddingVectors") to + // NullFields is a list of field names (e.g. "CitationMetadata") to // include in API requests with the JSON null value. By default, fields // with empty values are omitted from API requests. However, any field // with an empty value appearing in NullFields will be sent to the @@ -6478,22 +8358,25 @@ type GoogleCloudDiscoveryengineV1alphaSearchRequestEmbeddingSpec struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaSearchRequestEmbeddingSpec) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSearchRequestEmbeddingSpec +func (s *GoogleCloudDiscoveryengineV1alphaSearchResponseSummarySummaryWithMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSearchResponseSummarySummaryWithMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaSearchRequestEmbeddingSpecEmbeddingVe -// ctor: Embedding vector. -type GoogleCloudDiscoveryengineV1alphaSearchRequestEmbeddingSpecEmbeddingVector struct { - // FieldPath: Embedding field path in schema. - FieldPath string `json:"fieldPath,omitempty"` +// GoogleCloudDiscoveryengineV1alphaSiteSearchEngine: SiteSearchEngine +// captures DataStore level site search persisting configurations. It is +// a singleton value per data store. +type GoogleCloudDiscoveryengineV1alphaSiteSearchEngine struct { + // Name: The fully qualified resource name of the site search engine. + // Format: `projects/*/locations/*/dataStores/*/siteSearchEngine` + Name string `json:"name,omitempty"` - // Vector: Query embedding vector. - Vector []float64 `json:"vector,omitempty"` + // ServerResponse contains the HTTP response code and headers from the + // server. + googleapi.ServerResponse `json:"-"` - // ForceSendFields is a list of field names (e.g. "FieldPath") to + // 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. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -6501,8 +8384,8 @@ type GoogleCloudDiscoveryengineV1alphaSearchRequestEmbeddingSpecEmbeddingVector // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "FieldPath") to include in - // API requests with the JSON null value. By default, fields with empty + // 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. However, any field with an // empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. @@ -6510,85 +8393,32 @@ type GoogleCloudDiscoveryengineV1alphaSearchRequestEmbeddingSpecEmbeddingVector NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaSearchRequestEmbeddingSpecEmbeddingVector) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSearchRequestEmbeddingSpecEmbeddingVector +func (s *GoogleCloudDiscoveryengineV1alphaSiteSearchEngine) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSiteSearchEngine raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -func (s *GoogleCloudDiscoveryengineV1alphaSearchRequestEmbeddingSpecEmbeddingVector) UnmarshalJSON(data []byte) error { - type NoMethod GoogleCloudDiscoveryengineV1alphaSearchRequestEmbeddingSpecEmbeddingVector - var s1 struct { - Vector []gensupport.JSONFloat64 `json:"vector"` - *NoMethod - } - s1.NoMethod = (*NoMethod)(s) - if err := json.Unmarshal(data, &s1); err != nil { - return err - } - s.Vector = make([]float64, len(s1.Vector)) - for i := range s1.Vector { - s.Vector[i] = float64(s1.Vector[i]) - } - return nil -} - -// GoogleCloudDiscoveryengineV1alphaSearchRequestFacetSpec: A facet -// specification to perform faceted search. -type GoogleCloudDiscoveryengineV1alphaSearchRequestFacetSpec struct { - // EnableDynamicPosition: Enables dynamic position for this facet. If - // set to true, the position of this facet among all facets in the - // response is determined automatically. If dynamic facets are enabled, - // it is ordered together. If set to false, the position of this facet - // in the response is the same as in the request, and it is ranked - // before the facets with dynamic position enable and all dynamic - // facets. For example, you may always want to have rating facet - // returned in the response, but it's not necessarily to always display - // the rating facet at the top. In that case, you can set - // enable_dynamic_position to true so that the position of rating facet - // in response is determined automatically. Another example, assuming - // you have the following facets in the request: * "rating", - // enable_dynamic_position = true * "price", enable_dynamic_position = - // false * "brands", enable_dynamic_position = false And also you have a - // dynamic facets enabled, which generates a facet `gender`. Then the - // final order of the facets in the response can be ("price", "brands", - // "rating", "gender") or ("price", "brands", "gender", "rating") - // depends on how API orders "gender" and "rating" facets. However, - // notice that "price" and "brands" are always ranked at first and - // second position because their enable_dynamic_position is false. - EnableDynamicPosition bool `json:"enableDynamicPosition,omitempty"` - - // ExcludedFilterKeys: List of keys to exclude when faceting. By - // default, FacetKey.key is not excluded from the filter unless it is - // listed in this field. Listing a facet key in this field allows its - // values to appear as facet results, even when they are filtered out of - // search results. Using this field does not affect what search results - // are returned. For example, suppose there are 100 documents with the - // color facet "Red" and 200 documents with the color facet "Blue". A - // query containing the filter "color:ANY("Red")" and having "color" as - // FacetKey.key would by default return only "Red" documents in the - // search results, and also return "Red" with count 100 as the only - // color facet. Although there are also blue documents available, "Blue" - // would not be shown as an available facet value. If "color" is listed - // in "excludedFilterKeys", then the query returns the facet values - // "Red" with count 100 and "Blue" with count 200, because the "color" - // key is now excluded from the filter. Because this field doesn't - // affect search results, the search results are still correctly - // filtered to return only "Red" documents. A maximum of 100 values are - // allowed. Otherwise, an `INVALID_ARGUMENT` error is returned. - ExcludedFilterKeys []string `json:"excludedFilterKeys,omitempty"` - - // FacetKey: Required. The facet key specification. - FacetKey *GoogleCloudDiscoveryengineV1alphaSearchRequestFacetSpecFacetKey `json:"facetKey,omitempty"` +// GoogleCloudDiscoveryengineV1alphaSiteVerificationInfo: Verification +// information for target sites in advanced site search. +type GoogleCloudDiscoveryengineV1alphaSiteVerificationInfo struct { + // SiteVerificationState: Site verification state indicating the + // ownership and validity. + // + // Possible values: + // "SITE_VERIFICATION_STATE_UNSPECIFIED" - Defaults to VERIFIED. + // "VERIFIED" - Site ownership verified. + // "UNVERIFIED" - Site ownership pending verification or verification + // failed. + // "EXEMPTED" - Site exempt from verification, e.g., a public website + // that opens to all. + SiteVerificationState string `json:"siteVerificationState,omitempty"` - // Limit: Maximum of facet values that should be returned for this - // facet. If unspecified, defaults to 20. The maximum allowed value is - // 300. Values above 300 are coerced to 300. If this field is negative, - // an `INVALID_ARGUMENT` is returned. - Limit int64 `json:"limit,omitempty"` + // VerifyTime: Latest site verification time. + VerifyTime string `json:"verifyTime,omitempty"` // ForceSendFields is a list of field names (e.g. - // "EnableDynamicPosition") to unconditionally include in API requests. + // "SiteVerificationState") to unconditionally include in API requests. // By default, fields with empty or default values are omitted from API // requests. However, any non-pointer, non-interface field appearing in // ForceSendFields will be sent to the server regardless of whether the @@ -6596,7 +8426,7 @@ type GoogleCloudDiscoveryengineV1alphaSearchRequestFacetSpec struct { // Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "EnableDynamicPosition") to + // NullFields is a list of field names (e.g. "SiteVerificationState") to // include in API requests with the JSON null value. By default, fields // with empty values are omitted from API requests. However, any field // with an empty value appearing in NullFields will be sent to the @@ -6606,62 +8436,33 @@ type GoogleCloudDiscoveryengineV1alphaSearchRequestFacetSpec struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaSearchRequestFacetSpec) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSearchRequestFacetSpec +func (s *GoogleCloudDiscoveryengineV1alphaSiteVerificationInfo) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSiteVerificationInfo raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaSearchRequestFacetSpecFacetKey: -// Specifies how a facet is computed. -type GoogleCloudDiscoveryengineV1alphaSearchRequestFacetSpecFacetKey struct { - // CaseInsensitive: True to make facet keys case insensitive when - // getting faceting values with prefixes or contains; false otherwise. - CaseInsensitive bool `json:"caseInsensitive,omitempty"` - - // Contains: Only get facet values that contains the given strings. For - // example, suppose "category" has three values "Action > 2022", "Action - // > 2021" and "Sci-Fi > 2022". If set "contains" to "2022", the - // "category" facet only contains "Action > 2022" and "Sci-Fi > 2022". - // Only supported on textual fields. Maximum is 10. - Contains []string `json:"contains,omitempty"` - - // Intervals: Set only if values should be bucketed into intervals. Must - // be set for facets with numerical values. Must not be set for facet - // with text values. Maximum number of intervals is 30. - Intervals []*GoogleCloudDiscoveryengineV1alphaInterval `json:"intervals,omitempty"` - - // Key: Required. Supported textual and numerical facet keys in Document - // object, over which the facet values are computed. Facet key is - // case-sensitive. - Key string `json:"key,omitempty"` - - // OrderBy: The order in which documents are returned. Allowed values - // are: * "count desc", which means order by - // SearchResponse.Facet.values.count descending. * "value desc", which - // means order by SearchResponse.Facet.values.value descending. Only - // applies to textual facets. If not set, textual values are sorted in - // natural order (https://en.wikipedia.org/wiki/Natural_sort_order); - // numerical intervals are sorted in the order given by - // FacetSpec.FacetKey.intervals. - OrderBy string `json:"orderBy,omitempty"` - - // Prefixes: Only get facet values that start with the given string - // prefix. For example, suppose "category" has three values "Action > - // 2022", "Action > 2021" and "Sci-Fi > 2022". If set "prefixes" to - // "Action", the "category" facet only contains "Action > 2022" and - // "Action > 2021". Only supported on textual fields. Maximum is 10. - Prefixes []string `json:"prefixes,omitempty"` +// GoogleCloudDiscoveryengineV1alphaSuggestionDenyListEntry: Suggestion +// deny list entry identifying the phrase to block from suggestions and +// the applied operation for the phrase. +type GoogleCloudDiscoveryengineV1alphaSuggestionDenyListEntry struct { + // BlockPhrase: Required. Phrase to block from suggestions served. Can + // be maximum 125 characters. + BlockPhrase string `json:"blockPhrase,omitempty"` - // RestrictedValues: Only get facet for the given restricted values. - // Only supported on textual fields. For example, suppose "category" has - // three values "Action > 2022", "Action > 2021" and "Sci-Fi > 2022". If - // set "restricted_values" to "Action > 2022", the "category" facet only - // contains "Action > 2022". Only supported on textual fields. Maximum - // is 10. - RestrictedValues []string `json:"restrictedValues,omitempty"` + // MatchOperator: Required. The match operator to apply for this phrase. + // Whether to block the exact phrase, or block any suggestions + // containing this phrase. + // + // Possible values: + // "MATCH_OPERATOR_UNSPECIFIED" - Default value. Should not be used + // "EXACT_MATCH" - If the suggestion is an exact match to the + // block_phrase, then block it. + // "CONTAINS" - If the suggestion contains the block_phrase, then + // block it. + MatchOperator string `json:"matchOperator,omitempty"` - // ForceSendFields is a list of field names (e.g. "CaseInsensitive") to + // ForceSendFields is a list of field names (e.g. "BlockPhrase") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -6669,73 +8470,87 @@ type GoogleCloudDiscoveryengineV1alphaSearchRequestFacetSpecFacetKey struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "CaseInsensitive") to - // include in API requests with the JSON null value. By default, fields - // with empty values are omitted from API requests. However, any field - // with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. + // NullFields is a list of field names (e.g. "BlockPhrase") to include + // in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. However, any field with + // an empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaSearchRequestFacetSpecFacetKey) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSearchRequestFacetSpecFacetKey +func (s *GoogleCloudDiscoveryengineV1alphaSuggestionDenyListEntry) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSuggestionDenyListEntry raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaSearchRequestImageQuery: Specifies -// the image query input. -type GoogleCloudDiscoveryengineV1alphaSearchRequestImageQuery struct { - // ImageBytes: Base64 encoded image bytes. Supported image formats: - // JPEG, PNG, and BMP. - ImageBytes string `json:"imageBytes,omitempty"` +// GoogleCloudDiscoveryengineV1alphaTargetSite: A target site for the +// SiteSearchEngine. +type GoogleCloudDiscoveryengineV1alphaTargetSite struct { + // ExactMatch: Input only. If set to false, a uri_pattern is generated + // to include all pages whose address contains the provided_uri_pattern. + // If set to true, an uri_pattern is generated to try to be an exact + // match of the provided_uri_pattern or just the specific page if the + // provided_uri_pattern is a specific one. provided_uri_pattern is + // always normalized to generate the URI pattern to be used by the + // search engine. + ExactMatch bool `json:"exactMatch,omitempty"` + + // FailureReason: Output only. Failure reason. + FailureReason *GoogleCloudDiscoveryengineV1alphaTargetSiteFailureReason `json:"failureReason,omitempty"` + + // GeneratedUriPattern: Output only. This is system-generated based on + // the provided_uri_pattern. + GeneratedUriPattern string `json:"generatedUriPattern,omitempty"` + + // IndexingStatus: Output only. Indexing status. + // + // Possible values: + // "INDEXING_STATUS_UNSPECIFIED" - Defaults to SUCCEEDED. + // "PENDING" - The target site is in the update queue and will be + // picked up by indexing pipeline. + // "FAILED" - The target site fails to be indexed. + // "SUCCEEDED" - The target site has been indexed. + // "DELETING" - The previously indexed target site has been marked to + // be deleted. This is a transitioning state which will resulted in + // either: 1. target site deleted if unindexing is successful; 2. state + // reverts to SUCCEEDED if the unindexing fails. + IndexingStatus string `json:"indexingStatus,omitempty"` - // ForceSendFields is a list of field names (e.g. "ImageBytes") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. - ForceSendFields []string `json:"-"` + // Name: Output only. The fully qualified resource name of the target + // site. + // `projects/{project}/locations/{location}/collections/{collection}/data + // Stores/{data_store}/siteSearchEngine/targetSites/{target_site}` The + // `target_site_id` is system-generated. + Name string `json:"name,omitempty"` - // NullFields is a list of field names (e.g. "ImageBytes") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. - NullFields []string `json:"-"` -} + // ProvidedUriPattern: Required. Input only. The user provided URI + // pattern from which the `generated_uri_pattern` is generated. + ProvidedUriPattern string `json:"providedUriPattern,omitempty"` -func (s *GoogleCloudDiscoveryengineV1alphaSearchRequestImageQuery) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSearchRequestImageQuery - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) -} + // SiteVerificationInfo: Output only. Site ownership and validity + // verification status. + SiteVerificationInfo *GoogleCloudDiscoveryengineV1alphaSiteVerificationInfo `json:"siteVerificationInfo,omitempty"` -// GoogleCloudDiscoveryengineV1alphaSearchRequestQueryExpansionSpec: -// Specification to determine under which conditions query expansion -// should occur. -type GoogleCloudDiscoveryengineV1alphaSearchRequestQueryExpansionSpec struct { - // Condition: The condition under which query expansion should occur. - // Default to Condition.DISABLED. + // Type: The type of the target site, e.g., whether the site is to be + // included or excluded. // // Possible values: - // "CONDITION_UNSPECIFIED" - Unspecified query expansion condition. In - // this case, server behavior defaults to Condition.DISABLED. - // "DISABLED" - Disabled query expansion. Only the exact search query - // is used, even if SearchResponse.total_size is zero. - // "AUTO" - Automatic query expansion built by the Search API. - Condition string `json:"condition,omitempty"` + // "TYPE_UNSPECIFIED" - This value is unused. In this case, server + // behavior defaults to Type.INCLUDE. + // "INCLUDE" - Include the target site. + // "EXCLUDE" - Exclude the target site. + Type string `json:"type,omitempty"` - // PinUnexpandedResults: Whether to pin unexpanded results. If this - // field is set to true, unexpanded products are always at the top of - // the search results, followed by the expanded results. - PinUnexpandedResults bool `json:"pinUnexpandedResults,omitempty"` + // UpdateTime: Output only. The target site's last updated time. + UpdateTime string `json:"updateTime,omitempty"` - // ForceSendFields is a list of field names (e.g. "Condition") to + // ServerResponse contains the HTTP response code and headers from the + // server. + googleapi.ServerResponse `json:"-"` + + // ForceSendFields is a list of field names (e.g. "ExactMatch") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -6743,7 +8558,7 @@ type GoogleCloudDiscoveryengineV1alphaSearchRequestQueryExpansionSpec struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Condition") to include in + // NullFields is a list of field names (e.g. "ExactMatch") to include in // API requests with the JSON null value. By default, fields with empty // values are omitted from API requests. However, any field with an // empty value appearing in NullFields will be sent to the server as @@ -6752,29 +8567,19 @@ type GoogleCloudDiscoveryengineV1alphaSearchRequestQueryExpansionSpec struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaSearchRequestQueryExpansionSpec) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSearchRequestQueryExpansionSpec +func (s *GoogleCloudDiscoveryengineV1alphaTargetSite) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaTargetSite raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaSearchRequestSpellCorrectionSpec: -// The specification for query spell correction. -type GoogleCloudDiscoveryengineV1alphaSearchRequestSpellCorrectionSpec struct { - // Mode: The mode under which spell correction should take effect to - // replace the original search query. Default to Mode.AUTO. - // - // Possible values: - // "MODE_UNSPECIFIED" - Unspecified spell correction mode. In this - // case, server behavior defaults to Mode.AUTO. - // "SUGGESTION_ONLY" - Search API will try to find a spell suggestion - // if there is any and put in the SearchResponse.corrected_query. The - // spell suggestion will not be used as the search query. - // "AUTO" - Automatic spell correction built by the Search API. Search - // will be based on the corrected query if found. - Mode string `json:"mode,omitempty"` +// GoogleCloudDiscoveryengineV1alphaTargetSiteFailureReason: Site search +// indexing failure reasons. +type GoogleCloudDiscoveryengineV1alphaTargetSiteFailureReason struct { + // QuotaFailure: Failed due to insufficient quota. + QuotaFailure *GoogleCloudDiscoveryengineV1alphaTargetSiteFailureReasonQuotaFailure `json:"quotaFailure,omitempty"` - // ForceSendFields is a list of field names (e.g. "Mode") to + // ForceSendFields is a list of field names (e.g. "QuotaFailure") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -6782,85 +8587,35 @@ type GoogleCloudDiscoveryengineV1alphaSearchRequestSpellCorrectionSpec struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Mode") to include in API - // requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as + // NullFields is a list of field names (e.g. "QuotaFailure") to include + // in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. However, any field with + // an empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaSearchRequestSpellCorrectionSpec) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSearchRequestSpellCorrectionSpec +func (s *GoogleCloudDiscoveryengineV1alphaTargetSiteFailureReason) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaTargetSiteFailureReason raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaSearchResponse: Response message for -// SearchService.Search method. -type GoogleCloudDiscoveryengineV1alphaSearchResponse struct { - // AppliedControls: Controls applied as part of the Control service. - AppliedControls []string `json:"appliedControls,omitempty"` - - // AttributionToken: A unique search token. This should be included in - // the UserEvent logs resulting from this search, which enables accurate - // attribution of search model performance. - AttributionToken string `json:"attributionToken,omitempty"` - - // CorrectedQuery: Contains the spell corrected query, if found. If the - // spell correction type is AUTOMATIC, then the search results are based - // on corrected_query. Otherwise the original query is used for search. - CorrectedQuery string `json:"correctedQuery,omitempty"` - - // Facets: Results of facets requested by user. - Facets []*GoogleCloudDiscoveryengineV1alphaSearchResponseFacet `json:"facets,omitempty"` - - GeoSearchDebugInfo []*GoogleCloudDiscoveryengineV1alphaSearchResponseGeoSearchDebugInfo `json:"geoSearchDebugInfo,omitempty"` - - // GuidedSearchResult: Guided search result. - GuidedSearchResult *GoogleCloudDiscoveryengineV1alphaSearchResponseGuidedSearchResult `json:"guidedSearchResult,omitempty"` - - // NextPageToken: A token that can be sent as SearchRequest.page_token - // to retrieve the next page. If this field is omitted, there are no - // subsequent pages. - NextPageToken string `json:"nextPageToken,omitempty"` - - // QueryExpansionInfo: Query expansion information for the returned - // results. - QueryExpansionInfo *GoogleCloudDiscoveryengineV1alphaSearchResponseQueryExpansionInfo `json:"queryExpansionInfo,omitempty"` - - // RedirectUri: The URI of a customer-defined redirect page. If redirect - // action is triggered, no search is performed, and only redirect_uri - // and attribution_token are set in the response. - RedirectUri string `json:"redirectUri,omitempty"` - - // Results: A list of matched documents. The order represents the - // ranking. - Results []*GoogleCloudDiscoveryengineV1alphaSearchResponseSearchResult `json:"results,omitempty"` - - // Summary: A summary as part of the search results. This field is only - // returned if SearchRequest.ContentSearchSpec.summary_spec is set. - Summary *GoogleCloudDiscoveryengineV1alphaSearchResponseSummary `json:"summary,omitempty"` - - // TotalSize: The estimated total count of matched items irrespective of - // pagination. The count of results returned by pagination may be less - // than the total_size that matches. - TotalSize int64 `json:"totalSize,omitempty"` - - // ServerResponse contains the HTTP response code and headers from the - // server. - googleapi.ServerResponse `json:"-"` +type GoogleCloudDiscoveryengineV1alphaTargetSiteFailureReasonQuotaFailure struct { + // TotalRequiredQuota: This number is an estimation on how much total + // quota this project needs to successfully complete indexing. + TotalRequiredQuota int64 `json:"totalRequiredQuota,omitempty,string"` - // ForceSendFields is a list of field names (e.g. "AppliedControls") to - // unconditionally include in API requests. By default, fields with + // ForceSendFields is a list of field names (e.g. "TotalRequiredQuota") + // to unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be // sent to the server regardless of whether the field is empty or not. // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "AppliedControls") to + // NullFields is a list of field names (e.g. "TotalRequiredQuota") to // include in API requests with the JSON null value. By default, fields // with empty values are omitted from API requests. However, any field // with an empty value appearing in NullFields will be sent to the @@ -6870,25 +8625,21 @@ type GoogleCloudDiscoveryengineV1alphaSearchResponse struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaSearchResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSearchResponse +func (s *GoogleCloudDiscoveryengineV1alphaTargetSiteFailureReasonQuotaFailure) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaTargetSiteFailureReasonQuotaFailure raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaSearchResponseFacet: A facet result. -type GoogleCloudDiscoveryengineV1alphaSearchResponseFacet struct { - // DynamicFacet: Whether the facet is dynamically generated. - DynamicFacet bool `json:"dynamicFacet,omitempty"` - - // Key: The key for this facet. E.g., "colors" or "price". It matches - // SearchRequest.FacetSpec.FacetKey.key. - Key string `json:"key,omitempty"` +// GoogleCloudDiscoveryengineV1alphaTextInput: Defines text input. +type GoogleCloudDiscoveryengineV1alphaTextInput struct { + // Context: Conversation context of the input. + Context *GoogleCloudDiscoveryengineV1alphaConversationContext `json:"context,omitempty"` - // Values: The facet values for this field. - Values []*GoogleCloudDiscoveryengineV1alphaSearchResponseFacetFacetValue `json:"values,omitempty"` + // Input: Text input. + Input string `json:"input,omitempty"` - // ForceSendFields is a list of field names (e.g. "DynamicFacet") to + // ForceSendFields is a list of field names (e.g. "Context") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -6896,35 +8647,33 @@ type GoogleCloudDiscoveryengineV1alphaSearchResponseFacet struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "DynamicFacet") to include - // in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. However, any field with - // an empty value appearing in NullFields will be sent to the server as + // NullFields is a list of field names (e.g. "Context") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaSearchResponseFacet) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSearchResponseFacet +func (s *GoogleCloudDiscoveryengineV1alphaTextInput) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaTextInput raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaSearchResponseFacetFacetValue: A -// facet value which contains value names and their count. -type GoogleCloudDiscoveryengineV1alphaSearchResponseFacetFacetValue struct { - // Count: Number of items that have this facet value. - Count int64 `json:"count,omitempty,string"` - - // Interval: Interval value for a facet, such as 10, 20) for facet - // "price". It matches [SearchRequest.FacetSpec.FacetKey.intervals. - Interval *GoogleCloudDiscoveryengineV1alphaInterval `json:"interval,omitempty"` +// GoogleCloudDiscoveryengineV1alphaTrainCustomModelMetadata: Metadata +// related to the progress of the TrainCustomModel operation. This is +// returned by the google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1alphaTrainCustomModelMetadata struct { + // CreateTime: Operation create time. + CreateTime string `json:"createTime,omitempty"` - // Value: Text value of a facet, such as "Black" for facet "colors". - Value string `json:"value,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. "Count") to + // 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. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -6932,8 +8681,8 @@ type GoogleCloudDiscoveryengineV1alphaSearchResponseFacetFacetValue struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Count") to include in API - // requests with the JSON null value. By default, fields with empty + // 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. However, any field with an // empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. @@ -6941,24 +8690,28 @@ type GoogleCloudDiscoveryengineV1alphaSearchResponseFacetFacetValue struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaSearchResponseFacetFacetValue) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSearchResponseFacetFacetValue +func (s *GoogleCloudDiscoveryengineV1alphaTrainCustomModelMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaTrainCustomModelMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaSearchResponseGeoSearchDebugInfo: -// Debug information specifically related to forward geocoding issues -// arising from Geolocation Search. -type GoogleCloudDiscoveryengineV1alphaSearchResponseGeoSearchDebugInfo struct { - // ErrorMessage: The error produced. - ErrorMessage string `json:"errorMessage,omitempty"` +// GoogleCloudDiscoveryengineV1alphaTrainCustomModelRequest: Request +// message for SearchTuningService.TrainCustomModel method. +type GoogleCloudDiscoveryengineV1alphaTrainCustomModelRequest struct { + // ErrorConfig: The desired location of errors incurred during the data + // ingestion and training. + ErrorConfig *GoogleCloudDiscoveryengineV1alphaImportErrorConfig `json:"errorConfig,omitempty"` - // OriginalAddressQuery: The address from which forward geocoding - // ingestion produced issues. - OriginalAddressQuery string `json:"originalAddressQuery,omitempty"` + // GcsTrainingInput: Cloud Storage training input. + GcsTrainingInput *GoogleCloudDiscoveryengineV1alphaTrainCustomModelRequestGcsTrainingInput `json:"gcsTrainingInput,omitempty"` + + // ModelType: Model to be trained. Supported values are: * + // **search-tuning**: Fine tuning the search system based on data + // provided. + ModelType string `json:"modelType,omitempty"` - // ForceSendFields is a list of field names (e.g. "ErrorMessage") to + // ForceSendFields is a list of field names (e.g. "ErrorConfig") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -6966,7 +8719,7 @@ type GoogleCloudDiscoveryengineV1alphaSearchResponseGeoSearchDebugInfo struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "ErrorMessage") to include + // NullFields is a list of field names (e.g. "ErrorConfig") to include // in API requests with the JSON null value. By default, fields with // empty values are omitted from API requests. However, any field with // an empty value appearing in NullFields will be sent to the server as @@ -6975,32 +8728,51 @@ type GoogleCloudDiscoveryengineV1alphaSearchResponseGeoSearchDebugInfo struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaSearchResponseGeoSearchDebugInfo) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSearchResponseGeoSearchDebugInfo +func (s *GoogleCloudDiscoveryengineV1alphaTrainCustomModelRequest) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaTrainCustomModelRequest raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaSearchResponseGuidedSearchResult: -// Guided search result. The guided search helps user to refine the -// search results and narrow down to the real needs from a broaded -// search results. -type GoogleCloudDiscoveryengineV1alphaSearchResponseGuidedSearchResult struct { - // FollowUpQuestions: Suggested follow-up questions. - FollowUpQuestions []string `json:"followUpQuestions,omitempty"` +// GoogleCloudDiscoveryengineV1alphaTrainCustomModelRequestGcsTrainingInp +// ut: Cloud Storage training data input. +type GoogleCloudDiscoveryengineV1alphaTrainCustomModelRequestGcsTrainingInput struct { + // CorpusDataPath: The Cloud Storage corpus data which could be + // associated in train data. The data path format is gs:///. A newline + // delimited jsonl/ndjson file. For search-tuning model, each line + // should have the _id, title and text. Example: {"_id": "doc1", title: + // "relevant doc", "text": "relevant text"} + CorpusDataPath string `json:"corpusDataPath,omitempty"` - // RefinementAttributes: A list of ranked refinement attributes. - RefinementAttributes []*GoogleCloudDiscoveryengineV1alphaSearchResponseGuidedSearchResultRefinementAttribute `json:"refinementAttributes,omitempty"` + // QueryDataPath: The gcs query data which could be associated in train + // data. The data path format is gs:///. A newline delimited + // jsonl/ndjson file. For search-tuning model, each line should have the + // _id and text. Example: {"_id": "query1", "text": "example query"} + QueryDataPath string `json:"queryDataPath,omitempty"` - // ForceSendFields is a list of field names (e.g. "FollowUpQuestions") - // to unconditionally include in API requests. By default, fields with + // TestDataPath: Cloud Storage test data. Same format as + // train_data_path. If not provided, a random 80/20 train/test split + // will be performed on train_data_path. + TestDataPath string `json:"testDataPath,omitempty"` + + // TrainDataPath: Cloud Storage training data path whose format should + // be gs:///. The file should be in tsv format. Each line should have + // the doc_id and query_id and score (number). For search-tuning model, + // it should have the query-id corpus-id score as tsv file header. The + // score should be a number in [0, inf+). The larger the number is, the + // more relevant the pair is. Example: query-id\tcorpus-id\tscore + // query1\tdoc1\t1 + TrainDataPath string `json:"trainDataPath,omitempty"` + + // ForceSendFields is a list of field names (e.g. "CorpusDataPath") to + // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be // sent to the server regardless of whether the field is empty or not. // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "FollowUpQuestions") to + // NullFields is a list of field names (e.g. "CorpusDataPath") to // include in API requests with the JSON null value. By default, fields // with empty values are omitted from API requests. However, any field // with an empty value appearing in NullFields will be sent to the @@ -7010,24 +8782,32 @@ type GoogleCloudDiscoveryengineV1alphaSearchResponseGuidedSearchResult struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaSearchResponseGuidedSearchResult) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSearchResponseGuidedSearchResult +func (s *GoogleCloudDiscoveryengineV1alphaTrainCustomModelRequestGcsTrainingInput) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaTrainCustomModelRequestGcsTrainingInput raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaSearchResponseGuidedSearchResultRefin -// ementAttribute: Useful attribute for search result refinements. -type GoogleCloudDiscoveryengineV1alphaSearchResponseGuidedSearchResultRefinementAttribute struct { - // AttributeKey: Attribute key used to refine the results e.g. - // 'movie_type'. - AttributeKey string `json:"attributeKey,omitempty"` +// GoogleCloudDiscoveryengineV1alphaTrainCustomModelResponse: Response +// of the TrainCustomModelRequest. This message is returned by the +// google.longrunning.Operations.response field. +type GoogleCloudDiscoveryengineV1alphaTrainCustomModelResponse struct { + // ErrorConfig: Echoes the destination for the complete errors in the + // request if set. + ErrorConfig *GoogleCloudDiscoveryengineV1alphaImportErrorConfig `json:"errorConfig,omitempty"` - // AttributeValue: Attribute value used to refine the results e.g. - // 'drama'. - AttributeValue string `json:"attributeValue,omitempty"` + // ErrorSamples: A sample of errors encountered while processing the + // data. + ErrorSamples []*GoogleRpcStatus `json:"errorSamples,omitempty"` - // ForceSendFields is a list of field names (e.g. "AttributeKey") to + // ModelStatus: The trained model status. Possible values are: * + // **bad-data**: The training data quality is bad. * **no-improvement**: + // Tuning didn't improve performance. Won't deploy. * **in-progress**: + // Model training is in progress. * **ready**: The model is ready for + // serving. + ModelStatus string `json:"modelStatus,omitempty"` + + // ForceSendFields is a list of field names (e.g. "ErrorConfig") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -7035,7 +8815,7 @@ type GoogleCloudDiscoveryengineV1alphaSearchResponseGuidedSearchResultRefinement // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "AttributeKey") to include + // NullFields is a list of field names (e.g. "ErrorConfig") to include // in API requests with the JSON null value. By default, fields with // empty values are omitted from API requests. However, any field with // an empty value appearing in NullFields will be sent to the server as @@ -7044,26 +8824,47 @@ type GoogleCloudDiscoveryengineV1alphaSearchResponseGuidedSearchResultRefinement NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaSearchResponseGuidedSearchResultRefinementAttribute) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSearchResponseGuidedSearchResultRefinementAttribute +func (s *GoogleCloudDiscoveryengineV1alphaTrainCustomModelResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaTrainCustomModelResponse raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaSearchResponseQueryExpansionInfo: -// Information describing query expansion including whether expansion -// has occurred. -type GoogleCloudDiscoveryengineV1alphaSearchResponseQueryExpansionInfo struct { - // ExpandedQuery: Bool describing whether query expansion has occurred. - ExpandedQuery bool `json:"expandedQuery,omitempty"` +// GoogleCloudDiscoveryengineV1alphaTransactionInfo: A transaction +// represents the entire purchase transaction. +type GoogleCloudDiscoveryengineV1alphaTransactionInfo struct { + // Cost: All the costs associated with the products. These can be + // manufacturing costs, shipping expenses not borne by the end user, or + // any other costs, such that: * Profit = value - tax - cost + Cost float64 `json:"cost,omitempty"` - // PinnedResultCount: Number of pinned results. This field will only be - // set when expansion happens and - // SearchRequest.QueryExpansionSpec.pin_unexpanded_results is set to - // true. - PinnedResultCount int64 `json:"pinnedResultCount,omitempty,string"` + // Currency: Required. Currency code. Use three-character ISO-4217 code. + Currency string `json:"currency,omitempty"` - // ForceSendFields is a list of field names (e.g. "ExpandedQuery") to + // DiscountValue: The total discount(s) value applied to this + // transaction. This figure should be excluded from + // TransactionInfo.value For example, if a user paid + // TransactionInfo.value amount, then nominal (pre-discount) value of + // the transaction is the sum of TransactionInfo.value and + // TransactionInfo.discount_value This means that profit is calculated + // the same way, regardless of the discount value, and that + // TransactionInfo.discount_value can be larger than + // TransactionInfo.value: * Profit = value - tax - cost + DiscountValue float64 `json:"discountValue,omitempty"` + + // Tax: All the taxes associated with the transaction. + Tax float64 `json:"tax,omitempty"` + + // TransactionId: The transaction ID with a length limit of 128 + // characters. + TransactionId string `json:"transactionId,omitempty"` + + // Value: Required. Total non-zero value associated with the + // transaction. This value may include shipping, tax, or other + // adjustments to the total value that you want to include. + Value float64 `json:"value,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Cost") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -7071,35 +8872,51 @@ type GoogleCloudDiscoveryengineV1alphaSearchResponseQueryExpansionInfo struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "ExpandedQuery") to include - // in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. However, any field with - // an empty value appearing in NullFields will be sent to the server as + // NullFields is a list of field names (e.g. "Cost") to include in API + // requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaSearchResponseQueryExpansionInfo) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSearchResponseQueryExpansionInfo +func (s *GoogleCloudDiscoveryengineV1alphaTransactionInfo) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaTransactionInfo raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaSearchResponseSearchResult: -// Represents the search results. -type GoogleCloudDiscoveryengineV1alphaSearchResponseSearchResult struct { - // Document: The document data snippet in the search response. Only - // fields that are marked as retrievable are populated. - Document *GoogleCloudDiscoveryengineV1alphaDocument `json:"document,omitempty"` - - // Id: Document.id of the searched Document. - Id string `json:"id,omitempty"` +func (s *GoogleCloudDiscoveryengineV1alphaTransactionInfo) UnmarshalJSON(data []byte) error { + type NoMethod GoogleCloudDiscoveryengineV1alphaTransactionInfo + var s1 struct { + Cost gensupport.JSONFloat64 `json:"cost"` + DiscountValue gensupport.JSONFloat64 `json:"discountValue"` + Tax gensupport.JSONFloat64 `json:"tax"` + Value gensupport.JSONFloat64 `json:"value"` + *NoMethod + } + s1.NoMethod = (*NoMethod)(s) + if err := json.Unmarshal(data, &s1); err != nil { + return err + } + s.Cost = float64(s1.Cost) + s.DiscountValue = float64(s1.DiscountValue) + s.Tax = float64(s1.Tax) + s.Value = float64(s1.Value) + return nil +} - // ModelScores: Google provided available scores. - ModelScores map[string]GoogleCloudDiscoveryengineV1alphaDoubleList `json:"modelScores,omitempty"` +// GoogleCloudDiscoveryengineV1alphaTuneEngineMetadata: Metadata +// associated with a tune operation. +type GoogleCloudDiscoveryengineV1alphaTuneEngineMetadata struct { + // Engine: Required. The resource name of the engine that this tune + // applies to. Format: + // `projects/{project_number}/locations/{location_id}/collections/{collec + // tion_id}/engines/{engine_id}` + Engine string `json:"engine,omitempty"` - // ForceSendFields is a list of field names (e.g. "Document") to + // ForceSendFields is a list of field names (e.g. "Engine") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -7107,8 +8924,8 @@ type GoogleCloudDiscoveryengineV1alphaSearchResponseSearchResult struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Document") to include in - // API requests with the JSON null value. By default, fields with empty + // NullFields is a list of field names (e.g. "Engine") to include in API + // requests with the JSON null value. By default, fields with empty // values are omitted from API requests. However, any field with an // empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. @@ -7116,49 +8933,69 @@ type GoogleCloudDiscoveryengineV1alphaSearchResponseSearchResult struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaSearchResponseSearchResult) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSearchResponseSearchResult +func (s *GoogleCloudDiscoveryengineV1alphaTuneEngineMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaTuneEngineMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaSearchResponseSummary: Summary of -// the top N search result specified by the summary spec. -type GoogleCloudDiscoveryengineV1alphaSearchResponseSummary struct { - // SafetyAttributes: A collection of Safety Attribute categories and - // their associated confidence scores. - SafetyAttributes *GoogleCloudDiscoveryengineV1alphaSearchResponseSummarySafetyAttributes `json:"safetyAttributes,omitempty"` +// GoogleCloudDiscoveryengineV1alphaTuneEngineRequest: Request to +// manually start a tuning process now (instead of waiting for the +// periodically scheduled tuning to happen). +type GoogleCloudDiscoveryengineV1alphaTuneEngineRequest struct { +} - // SummarySkippedReasons: Additional summary-skipped reasons. This - // provides the reason for ignored cases. If nothing is skipped, this - // field is not set. - // - // Possible values: - // "SUMMARY_SKIPPED_REASON_UNSPECIFIED" - Default value. The summary - // skipped reason is not specified. - // "ADVERSARIAL_QUERY_IGNORED" - The adversarial query ignored case. - // Only populated when SummarySpec.ignore_adversarial_query is set to - // `true`. - // "NON_SUMMARY_SEEKING_QUERY_IGNORED" - The non-summary seeking query - // ignored case. Only populated when - // SummarySpec.ignore_non_summary_seeking_query is set to `true`. - // "OUT_OF_DOMAIN_QUERY_IGNORED" - The out-of-domain query ignored - // case. Google skips the summary if there are no high-relevance search - // results. For example, the data store contains facts about company A - // but the user query is asking questions about company B. - // "POTENTIAL_POLICY_VIOLATION" - The potential policy violation case. - // Google skips the summary if there is a potential policy violation - // detected. This includes content that may be violent or toxic. - // "LLM_ADDON_NOT_ENABLED" - The LLM addon not enabled case. Google - // skips the summary if the LLM addon is not enabled. - SummarySkippedReasons []string `json:"summarySkippedReasons,omitempty"` +// GoogleCloudDiscoveryengineV1alphaTuneEngineResponse: Response +// associated with a tune operation. +type GoogleCloudDiscoveryengineV1alphaTuneEngineResponse struct { +} + +// GoogleCloudDiscoveryengineV1alphaUpdateSchemaMetadata: Metadata for +// UpdateSchema LRO. +type GoogleCloudDiscoveryengineV1alphaUpdateSchemaMetadata 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. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + 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. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} - // SummaryText: The summary content. - SummaryText string `json:"summaryText,omitempty"` +func (s *GoogleCloudDiscoveryengineV1alphaUpdateSchemaMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaUpdateSchemaMetadata + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} - SummaryWithMetadata *GoogleCloudDiscoveryengineV1alphaSearchResponseSummarySummaryWithMetadata `json:"summaryWithMetadata,omitempty"` +// GoogleCloudDiscoveryengineV1alphaUpdateTargetSiteMetadata: Metadata +// related to the progress of the +// SiteSearchEngineService.UpdateTargetSite operation. This will be +// returned by the google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1alphaUpdateTargetSiteMetadata struct { + // CreateTime: Operation create time. + CreateTime string `json:"createTime,omitempty"` - // ForceSendFields is a list of field names (e.g. "SafetyAttributes") to + // 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. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -7166,36 +9003,173 @@ type GoogleCloudDiscoveryengineV1alphaSearchResponseSummary struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "SafetyAttributes") to - // include in API requests with the JSON null value. By default, fields - // with empty values are omitted from API requests. However, any field - // with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. + // 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. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaSearchResponseSummary) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSearchResponseSummary +func (s *GoogleCloudDiscoveryengineV1alphaUpdateTargetSiteMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaUpdateTargetSiteMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryCitation: -// Citation info for a segment. -type GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryCitation struct { - // EndIndex: End of the attributed segment, exclusive. - EndIndex int64 `json:"endIndex,omitempty,string"` +// GoogleCloudDiscoveryengineV1alphaUserEvent: UserEvent captures all +// metadata information Discovery Engine API needs to know about how end +// users interact with customers' website. +type GoogleCloudDiscoveryengineV1alphaUserEvent struct { + // Attributes: Extra user event features to include in the + // recommendation model. These attributes must NOT contain data that + // needs to be parsed or processed further, e.g. JSON or other + // encodings. If you provide custom attributes for ingested user events, + // also include them in the user events that you associate with + // prediction requests. Custom attribute formatting must be consistent + // between imported events and events provided with prediction requests. + // This lets the Discovery Engine API use those custom attributes when + // training models and serving predictions, which helps improve + // recommendation quality. This field needs to pass all below criteria, + // otherwise an `INVALID_ARGUMENT` error is returned: * The key must be + // a UTF-8 encoded string with a length limit of 5,000 characters. * For + // text attributes, at most 400 values are allowed. Empty values are not + // allowed. Each value must be a UTF-8 encoded string with a length + // limit of 256 characters. * For number attributes, at most 400 values + // are allowed. For product recommendations, an example of extra user + // information is `traffic_channel`, which is how a user arrives at the + // site. Users can arrive at the site by coming to the site directly, + // coming through Google search, or in other ways. + Attributes map[string]GoogleCloudDiscoveryengineV1alphaCustomAttribute `json:"attributes,omitempty"` - // Sources: Citation sources for the attributed segment. - Sources []*GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryCitationSource `json:"sources,omitempty"` + // AttributionToken: Token to attribute an API response to user + // action(s) to trigger the event. Highly recommended for user events + // that are the result of RecommendationService.Recommend. This field + // enables accurate attribution of recommendation model performance. The + // value must be one of: * RecommendResponse.attribution_token for + // events that are the result of RecommendationService.Recommend. * + // SearchResponse.attribution_token for events that are the result of + // SearchService.Search. This token enables us to accurately attribute + // page view or conversion completion back to the event and the + // particular predict response containing this clicked/purchased + // product. If user clicks on product K in the recommendation results, + // pass RecommendResponse.attribution_token as a URL parameter to + // product K's page. When recording events on product K's page, log the + // RecommendResponse.attribution_token to this field. + AttributionToken string `json:"attributionToken,omitempty"` - // StartIndex: Index indicates the start of the segment, measured in - // bytes/unicode. - StartIndex int64 `json:"startIndex,omitempty,string"` + // CompletionInfo: CompletionService.CompleteQuery details related to + // the event. This field should be set for `search` event when + // autocomplete function is enabled and the user clicks a suggestion for + // search. + CompletionInfo *GoogleCloudDiscoveryengineV1alphaCompletionInfo `json:"completionInfo,omitempty"` - // ForceSendFields is a list of field names (e.g. "EndIndex") to + // DirectUserRequest: Should set to true if the request is made directly + // from the end user, in which case the UserEvent.user_info.user_agent + // can be populated from the HTTP request. This flag should be set only + // if the API request is made directly from the end user such as a + // mobile app (and not if a gateway or a server is processing and + // pushing the user events). This should not be set when using the + // JavaScript tag in UserEventService.CollectUserEvent. + DirectUserRequest bool `json:"directUserRequest,omitempty"` + + // Documents: List of Documents associated with this user event. This + // field is optional except for the following event types: * `view-item` + // * `add-to-cart` * `purchase` * `media-play` * `media-complete` In a + // `search` event, this field represents the documents 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 UserEvent.documents is desired. + Documents []*GoogleCloudDiscoveryengineV1alphaDocumentInfo `json:"documents,omitempty"` + + // EventTime: Only required for UserEventService.ImportUserEvents + // method. Timestamp of when the user event happened. + EventTime string `json:"eventTime,omitempty"` + + // EventType: Required. User event type. Allowed values are: Generic + // values: * `search`: Search for Documents. * `view-item`: Detailed + // page view of a Document. * `view-item-list`: View of a panel or + // ordered list of Documents. * `view-home-page`: View of the home page. + // * `view-category-page`: View of a category page, e.g. Home > Men > + // Jeans Retail-related values: * `add-to-cart`: Add an item(s) to cart, + // e.g. in Retail online shopping * `purchase`: Purchase an item(s) + // Media-related values: * `media-play`: Start/resume watching a video, + // playing a song, etc. * `media-complete`: Finished or stopped midway + // through a video, song, etc. + EventType string `json:"eventType,omitempty"` + + // Filter: The filter syntax consists of an expression language for + // constructing a predicate from one or more fields of the documents + // being filtered. One example is for `search` events, the associated + // SearchRequest may contain a filter expression in SearchRequest.filter + // conforming to https://google.aip.dev/160#filtering. Similarly, for + // `view-item-list` events that are generated from a RecommendRequest, + // this field may be populated directly from RecommendRequest.filter + // conforming to https://google.aip.dev/160#filtering. The value must be + // a UTF-8 encoded string with a length limit of 1,000 characters. + // Otherwise, an `INVALID_ARGUMENT` error is returned. + Filter string `json:"filter,omitempty"` + + // MediaInfo: Media-specific info. + MediaInfo *GoogleCloudDiscoveryengineV1alphaMediaInfo `json:"mediaInfo,omitempty"` + + // PageInfo: Page metadata such as categories and other critical + // information for certain event types such as `view-category-page`. + PageInfo *GoogleCloudDiscoveryengineV1alphaPageInfo `json:"pageInfo,omitempty"` + + // Panel: Panel metadata associated with this user event. + Panel *GoogleCloudDiscoveryengineV1alphaPanelInfo `json:"panel,omitempty"` + + // PromotionIds: The promotion IDs if this is an event associated with + // promotions. Currently, this field is restricted to at most one ID. + PromotionIds []string `json:"promotionIds,omitempty"` + + // SearchInfo: SearchService.Search details related to the event. This + // field should be set for `search` event. + SearchInfo *GoogleCloudDiscoveryengineV1alphaSearchInfo `json:"searchInfo,omitempty"` + + // SessionId: A unique identifier for tracking a visitor session with a + // length limit of 128 bytes. A session is an aggregation of an end user + // behavior in a time span. A general guideline to populate the + // session_id: 1. If user has no activity for 30 min, a new session_id + // should be assigned. 2. The session_id should be unique across users, + // suggest use uuid or add UserEvent.user_pseudo_id as prefix. + SessionId string `json:"sessionId,omitempty"` + + // TagIds: A list of identifiers for the independent experiment groups + // this user event belongs to. This is used to distinguish between user + // events associated with different experiment setups on the customer + // end. + TagIds []string `json:"tagIds,omitempty"` + + // TransactionInfo: The transaction metadata (if any) associated with + // this user event. + TransactionInfo *GoogleCloudDiscoveryengineV1alphaTransactionInfo `json:"transactionInfo,omitempty"` + + // UserInfo: Information about the end user. + UserInfo *GoogleCloudDiscoveryengineV1alphaUserInfo `json:"userInfo,omitempty"` + + // UserPseudoId: Required. A unique identifier for tracking visitors. + // For example, this could be implemented with an HTTP cookie, which + // should be able to uniquely identify a visitor on a single device. + // This unique identifier should not change if the visitor log in/out of + // the website. Do not set the field to the same fixed ID for different + // users. This mixes the event history of those users together, which + // results in degraded model quality. The field must be a UTF-8 encoded + // string with a length limit of 128 characters. Otherwise, an + // `INVALID_ARGUMENT` error is returned. The field should not contain + // PII or user-data. We recommend to use Google Analytics Client ID + // (https://developers.google.com/analytics/devguides/collection/analyticsjs/field-reference#clientId) + // for this field. + UserPseudoId string `json:"userPseudoId,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the + // server. + googleapi.ServerResponse `json:"-"` + + // ForceSendFields is a list of field names (e.g. "Attributes") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -7203,7 +9177,7 @@ type GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryCitation struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "EndIndex") to include in + // NullFields is a list of field names (e.g. "Attributes") to include in // API requests with the JSON null value. By default, fields with empty // values are omitted from API requests. However, any field with an // empty value appearing in NullFields will be sent to the server as @@ -7212,19 +9186,33 @@ type GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryCitation struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryCitation) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryCitation +func (s *GoogleCloudDiscoveryengineV1alphaUserEvent) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaUserEvent raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryCitationMetadata -// : Citation metadata. -type GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryCitationMetadata struct { - // Citations: Citations for segments. - Citations []*GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryCitation `json:"citations,omitempty"` +// GoogleCloudDiscoveryengineV1alphaUserInfo: Information of an end +// user. +type GoogleCloudDiscoveryengineV1alphaUserInfo struct { + // UserAgent: User agent as included in the HTTP header. The field must + // be a UTF-8 encoded string with a length limit of 1,000 characters. + // Otherwise, an `INVALID_ARGUMENT` error is returned. This should not + // be set when using the client side event reporting with GTM or + // JavaScript tag in UserEventService.CollectUserEvent or if + // UserEvent.direct_user_request is set. + UserAgent string `json:"userAgent,omitempty"` - // ForceSendFields is a list of field names (e.g. "Citations") to + // UserId: Highly recommended for logged-in users. Unique identifier for + // logged-in user, such as a user name. Don't set for anonymous users. + // Always use a hashed value for this ID. Don't set the field to the + // same fixed ID for different users. This mixes the event history of + // those users together, which results in degraded model quality. The + // field must be a UTF-8 encoded string with a length limit of 128 + // characters. Otherwise, an `INVALID_ARGUMENT` error is returned. + UserId string `json:"userId,omitempty"` + + // ForceSendFields is a list of field names (e.g. "UserAgent") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -7232,7 +9220,7 @@ type GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryCitationMetadata stru // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Citations") to include in + // NullFields is a list of field names (e.g. "UserAgent") to include in // API requests with the JSON null value. By default, fields with empty // values are omitted from API requests. However, any field with an // empty value appearing in NullFields will be sent to the server as @@ -7241,21 +9229,29 @@ type GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryCitationMetadata stru NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryCitationMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryCitationMetadata +func (s *GoogleCloudDiscoveryengineV1alphaUserInfo) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaUserInfo raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryCitationSource: -// Citation source. -type GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryCitationSource struct { - // ReferenceIndex: Document reference index from - // SummaryWithMetadata.references. It is 0-indexed and the value will be - // zero if the reference_index is not set explicitly. - ReferenceIndex int64 `json:"referenceIndex,omitempty,string"` +// GoogleCloudDiscoveryengineV1alphaWidgetCompleteQueryRequest: Request +// message for WidgetService.WidgetCompleteQuery method. +type GoogleCloudDiscoveryengineV1alphaWidgetCompleteQueryRequest struct { + // AdditionalParams: Additional params for security and privacy + // enhancement. + AdditionalParams *GoogleCloudDiscoveryengineV1alphaAdditionalParams `json:"additionalParams,omitempty"` + + // CompleteQueryRequest: Required. The CompleteQuery request to perform + // auto-complete suggestion query. + CompleteQueryRequest *GoogleCloudDiscoveryengineV1alphaCompleteQueryRequest `json:"completeQueryRequest,omitempty"` - // ForceSendFields is a list of field names (e.g. "ReferenceIndex") to + // ConfigId: Required. The UUID of the WidgetConfig. This field is used + // to identify the widget configuration, set of models used to make the + // auto complete query. + ConfigId string `json:"configId,omitempty"` + + // ForceSendFields is a list of field names (e.g. "AdditionalParams") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -7263,7 +9259,7 @@ type GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryCitationSource struct // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "ReferenceIndex") to + // NullFields is a list of field names (e.g. "AdditionalParams") to // include in API requests with the JSON null value. By default, fields // with empty values are omitted from API requests. However, any field // with an empty value appearing in NullFields will be sent to the @@ -7273,28 +9269,28 @@ type GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryCitationSource struct NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryCitationSource) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryCitationSource +func (s *GoogleCloudDiscoveryengineV1alphaWidgetCompleteQueryRequest) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaWidgetCompleteQueryRequest raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryReference: -// Document reference. -type GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryReference struct { - // Document: Required. Document.name of the document. Full resource name - // of the referenced document, in the format - // `projects/*/locations/*/collections/*/dataStores/*/branches/*/document - // s/*`. - Document string `json:"document,omitempty"` +// GoogleCloudDiscoveryengineV1alphaWidgetCompleteQueryResponse: +// Response message for WidgetService.WidgetCompleteQuery method. +type GoogleCloudDiscoveryengineV1alphaWidgetCompleteQueryResponse struct { + // UToken: The token in response. + UToken string `json:"uToken,omitempty"` - // Title: Title of the document. - Title string `json:"title,omitempty"` + // WidgetQuerySuggestions: Results of the matched query suggestions in + // widget. The result list is ordered and the first result is a top + // suggestion. + WidgetQuerySuggestions []*GoogleCloudDiscoveryengineV1alphaWidgetCompleteQueryResponseWidgetQuerySuggestion `json:"widgetQuerySuggestions,omitempty"` - // Uri: Cloud Storage or HTTP uri for the document. - Uri string `json:"uri,omitempty"` + // ServerResponse contains the HTTP response code and headers from the + // server. + googleapi.ServerResponse `json:"-"` - // ForceSendFields is a list of field names (e.g. "Document") to + // ForceSendFields is a list of field names (e.g. "UToken") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -7302,8 +9298,8 @@ type GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryReference struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Document") to include in - // API requests with the JSON null value. By default, fields with empty + // NullFields is a list of field names (e.g. "UToken") to include in API + // requests with the JSON null value. By default, fields with empty // values are omitted from API requests. However, any field with an // empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. @@ -7311,24 +9307,19 @@ type GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryReference struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryReference) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryReference +func (s *GoogleCloudDiscoveryengineV1alphaWidgetCompleteQueryResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaWidgetCompleteQueryResponse raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaSearchResponseSummarySafetyAttributes -// : Safety Attribute categories and their associated confidence scores. -type GoogleCloudDiscoveryengineV1alphaSearchResponseSummarySafetyAttributes struct { - // Categories: The display names of Safety Attribute categories - // associated with the generated content. Order matches the Scores. - Categories []string `json:"categories,omitempty"` - - // Scores: The confidence scores of the each category, higher value - // means higher confidence. Order matches the Categories. - Scores []float64 `json:"scores,omitempty"` +// GoogleCloudDiscoveryengineV1alphaWidgetCompleteQueryResponseWidgetQuer +// ySuggestion: Suggestions as search queries. +type GoogleCloudDiscoveryengineV1alphaWidgetCompleteQueryResponseWidgetQuerySuggestion struct { + // Suggestion: The suggestion for the query. + Suggestion string `json:"suggestion,omitempty"` - // ForceSendFields is a list of field names (e.g. "Categories") to + // ForceSendFields is a list of field names (e.g. "Suggestion") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -7336,7 +9327,7 @@ type GoogleCloudDiscoveryengineV1alphaSearchResponseSummarySafetyAttributes stru // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Categories") to include in + // NullFields is a list of field names (e.g. "Suggestion") to include in // API requests with the JSON null value. By default, fields with empty // values are omitted from API requests. However, any field with an // empty value appearing in NullFields will be sent to the server as @@ -7345,128 +9336,154 @@ type GoogleCloudDiscoveryengineV1alphaSearchResponseSummarySafetyAttributes stru NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaSearchResponseSummarySafetyAttributes) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSearchResponseSummarySafetyAttributes +func (s *GoogleCloudDiscoveryengineV1alphaWidgetCompleteQueryResponseWidgetQuerySuggestion) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaWidgetCompleteQueryResponseWidgetQuerySuggestion raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -func (s *GoogleCloudDiscoveryengineV1alphaSearchResponseSummarySafetyAttributes) UnmarshalJSON(data []byte) error { - type NoMethod GoogleCloudDiscoveryengineV1alphaSearchResponseSummarySafetyAttributes - var s1 struct { - Scores []gensupport.JSONFloat64 `json:"scores"` - *NoMethod - } - s1.NoMethod = (*NoMethod)(s) - if err := json.Unmarshal(data, &s1); err != nil { - return err - } - s.Scores = make([]float64, len(s1.Scores)) - for i := range s1.Scores { - s.Scores[i] = float64(s1.Scores[i]) - } - return nil -} +// GoogleCloudDiscoveryengineV1alphaWidgetConfig: WidgetConfig captures +// configs at the Widget level. +type GoogleCloudDiscoveryengineV1alphaWidgetConfig struct { + // AllowPublicAccess: Whether allow no-auth integration with widget. If + // set true, public access to search or other solutions from widget is + // allowed without authenication token provided by customer hosted + // backend server. + AllowPublicAccess bool `json:"allowPublicAccess,omitempty"` -// GoogleCloudDiscoveryengineV1alphaSearchResponseSummarySummaryWithMetad -// ata: Summary with metadata information. -type GoogleCloudDiscoveryengineV1alphaSearchResponseSummarySummaryWithMetadata struct { - // CitationMetadata: Citation metadata for given summary. - CitationMetadata *GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryCitationMetadata `json:"citationMetadata,omitempty"` + // AllowlistedDomains: Allowlisted domains that can load this widget. + AllowlistedDomains []string `json:"allowlistedDomains,omitempty"` - // References: Document References. - References []*GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryReference `json:"references,omitempty"` + // ConfigId: Output only. Unique obfuscated identifier of a + // WidgetConfig. + ConfigId string `json:"configId,omitempty"` - // Summary: Summary text with no citation information. - Summary string `json:"summary,omitempty"` + // ContentSearchSpec: The content search spec that configs the desired + // behavior of content search. + ContentSearchSpec *GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpec `json:"contentSearchSpec,omitempty"` - // ForceSendFields is a list of field names (e.g. "CitationMetadata") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. - ForceSendFields []string `json:"-"` + // CreateTime: Output only. Timestamp the WidgetConfig was created. + CreateTime string `json:"createTime,omitempty"` - // NullFields is a list of field names (e.g. "CitationMetadata") to - // include in API requests with the JSON null value. By default, fields - // with empty values are omitted from API requests. However, any field - // with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. - NullFields []string `json:"-"` -} + // DataStoreType: Output only. The type of the parent data store. + // + // Possible values: + // "DATA_STORE_TYPE_UNSPECIFIED" - Unspecified data store type. + // "SITE_SEARCH" - The parent data store contains a site search + // engine. + // "STRUCTURED" - The parent data store contains a search engine for + // structured data. + // "UNSTRUCTURED" - The parent data store contains a search engine for + // unstructured data. + // "BLENDED" - The parent data store is served for blended search with + // multiple data stores. + DataStoreType string `json:"dataStoreType,omitempty"` -func (s *GoogleCloudDiscoveryengineV1alphaSearchResponseSummarySummaryWithMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSearchResponseSummarySummaryWithMetadata - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) -} + // DisplayName: Required. The human readable widget config display name. + // Used in Discovery UI. This field must be a UTF-8 encoded string with + // a length limit of 128 characters. Otherwise, an INVALID_ARGUMENT + // error is returned. + DisplayName string `json:"displayName,omitempty"` -// GoogleCloudDiscoveryengineV1alphaSiteSearchEngine: SiteSearchEngine -// captures DataStore level site search persisting configurations. It is -// a singleton value per data store. -type GoogleCloudDiscoveryengineV1alphaSiteSearchEngine struct { - // Name: The fully qualified resource name of the site search engine. - // Format: `projects/*/locations/*/dataStores/*/siteSearchEngine` - Name string `json:"name,omitempty"` + // EnableAutocomplete: Whether or not to enable autocomplete. + EnableAutocomplete bool `json:"enableAutocomplete,omitempty"` - // ServerResponse contains the HTTP response code and headers from the - // server. - googleapi.ServerResponse `json:"-"` + // EnableConversationalSearch: Whether to allow conversational search + // (LLM, multi-turn) or not (non-LLM, single-turn). + EnableConversationalSearch bool `json:"enableConversationalSearch,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. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. - ForceSendFields []string `json:"-"` + // EnableQualityFeedback: Turn on or off collecting the search result + // quality feedback from end users. + EnableQualityFeedback bool `json:"enableQualityFeedback,omitempty"` - // 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. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. - NullFields []string `json:"-"` -} + // EnableResultScore: Whether to show the result score. + EnableResultScore bool `json:"enableResultScore,omitempty"` -func (s *GoogleCloudDiscoveryengineV1alphaSiteSearchEngine) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSiteSearchEngine - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) -} + // EnableSafeSearch: Whether to enable safe search. + EnableSafeSearch bool `json:"enableSafeSearch,omitempty"` -// GoogleCloudDiscoveryengineV1alphaSiteVerificationInfo: Verification -// information for target sites in advanced site search. -type GoogleCloudDiscoveryengineV1alphaSiteVerificationInfo struct { - // SiteVerificationState: Site verification state indicating the - // ownership and validity. + // EnableSnippetResultSummary: Turn on or off summary for each snippets + // result. + EnableSnippetResultSummary bool `json:"enableSnippetResultSummary,omitempty"` + + // EnableSummarization: Turn on or off summarization for the search + // response. + EnableSummarization bool `json:"enableSummarization,omitempty"` + + // FacetField: The configuration and appearance of facets in the end + // user view. + FacetField []*GoogleCloudDiscoveryengineV1alphaWidgetConfigFacetField `json:"facetField,omitempty"` + + // FieldsUiComponentsMap: The key is the UI component. Mock. Currently + // supported `title`, `thumbnail`, `url`, `custom1`, `custom2`, + // `custom3`. The value is the name of the field along with its device + // visibility. The 3 custom fields are optional and can be added or + // removed. `title`, `thumbnail`, `url` are required UI components that + // cannot be removed. + FieldsUiComponentsMap map[string]GoogleCloudDiscoveryengineV1alphaWidgetConfigUIComponentField `json:"fieldsUiComponentsMap,omitempty"` + + // IndustryVertical: Output only. The industry vertical that the + // WidgetConfig registers. The WidgetConfig industry vertical is based + // on the associated Engine. + // + // Possible values: + // "INDUSTRY_VERTICAL_UNSPECIFIED" - Value used when unset. + // "GENERIC" - The generic vertical for documents that are not + // specific to any industry vertical. + // "MEDIA" - The media industry vertical. + IndustryVertical string `json:"industryVertical,omitempty"` + + // LlmEnabled: Output only. Whether LLM is enabled in the corresponding + // data store. + LlmEnabled bool `json:"llmEnabled,omitempty"` + + // MinimumDataTermAccepted: Output only. Whether the customer accepted + // data use terms. + MinimumDataTermAccepted bool `json:"minimumDataTermAccepted,omitempty"` + + // Name: Immutable. The full resource name of the widget config. Format: + // `projects/{project}/locations/{location}/collections/{collection_id}/d + // ataStores/{data_store_id}/widgetConfigs/{widget_config_id}`. This + // field must be a UTF-8 encoded string with a length limit of 1024 + // characters. + Name string `json:"name,omitempty"` + + // ResultDisplayType: The type of snippet to display in UCS widget. - + // RESULT_DISPLAY_TYPE_UNSPECIFIED for existing users. - SNIPPET for new + // non-enterprise search users. - EXTRACTIVE_ANSWER for new enterprise + // search users. + // + // Possible values: + // "RESULT_DISPLAY_TYPE_UNSPECIFIED" - Unspecified display type + // (default to showing snippet). + // "SNIPPET" - Display results from the snippet field. + // "EXTRACTIVE_ANSWER" - Display results from extractive answers + // field. + ResultDisplayType string `json:"resultDisplayType,omitempty"` + + // SolutionType: Required. Immutable. Specifies the solution type that + // this WidgetConfig can be used for. // // Possible values: - // "SITE_VERIFICATION_STATE_UNSPECIFIED" - Defaults to VERIFIED. - // "VERIFIED" - Site ownership verified. - // "UNVERIFIED" - Site ownership pending verification or verification - // failed. - // "EXEMPTED" - Site exempt from verification, e.g. a public website - // that opens to all. - SiteVerificationState string `json:"siteVerificationState,omitempty"` + // "SOLUTION_TYPE_UNSPECIFIED" - Default value. + // "SOLUTION_TYPE_RECOMMENDATION" - Used for Recommendations AI. + // "SOLUTION_TYPE_SEARCH" - Used for Discovery Search. + // "SOLUTION_TYPE_CHAT" - Used for use cases related to the Generative + // AI agent. + SolutionType string `json:"solutionType,omitempty"` - // VerifyTime: Latest site verification time. - VerifyTime string `json:"verifyTime,omitempty"` + // UpdateTime: Output only. Timestamp the WidgetConfig was updated. + UpdateTime string `json:"updateTime,omitempty"` - // ForceSendFields is a list of field names (e.g. - // "SiteVerificationState") to unconditionally include in API requests. - // By default, fields with empty or default values are omitted from API - // requests. However, any non-pointer, non-interface field appearing in - // ForceSendFields will be sent to the server regardless of whether the - // field is empty or not. This may be used to include empty fields in - // Patch requests. + // ForceSendFields is a list of field names (e.g. "AllowPublicAccess") + // to unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "SiteVerificationState") to + // NullFields is a list of field names (e.g. "AllowPublicAccess") to // include in API requests with the JSON null value. By default, fields // with empty values are omitted from API requests. However, any field // with an empty value appearing in NullFields will be sent to the @@ -7476,33 +9493,22 @@ type GoogleCloudDiscoveryengineV1alphaSiteVerificationInfo struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaSiteVerificationInfo) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSiteVerificationInfo +func (s *GoogleCloudDiscoveryengineV1alphaWidgetConfig) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaWidgetConfig raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaSuggestionDenyListEntry: Suggestion -// deny list entry identifying the phrase to block from suggestions and -// the applied operation for the phrase. -type GoogleCloudDiscoveryengineV1alphaSuggestionDenyListEntry struct { - // BlockPhrase: Required. Phrase to block from suggestions served. Can - // be maximum 125 characters. - BlockPhrase string `json:"blockPhrase,omitempty"` +// GoogleCloudDiscoveryengineV1alphaWidgetConfigFacetField: Facet fields +// that store the mapping of fields to end user widget appearance. +type GoogleCloudDiscoveryengineV1alphaWidgetConfigFacetField struct { + // DisplayName: Optional. The field name that end users will see. + DisplayName string `json:"displayName,omitempty"` - // MatchOperator: Required. The match operator to apply for this phrase. - // Whether to block the exact phrase, or block any suggestions - // containing this phrase. - // - // Possible values: - // "MATCH_OPERATOR_UNSPECIFIED" - Default value. Should not be used - // "EXACT_MATCH" - If the suggestion is an exact match to the - // block_phrase, then block it. - // "CONTAINS" - If the suggestion contains the block_phrase, then - // block it. - MatchOperator string `json:"matchOperator,omitempty"` + // Field: Required. Registered field name. The format is `field.abc`. + Field string `json:"field,omitempty"` - // ForceSendFields is a list of field names (e.g. "BlockPhrase") to + // 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. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -7510,7 +9516,7 @@ type GoogleCloudDiscoveryengineV1alphaSuggestionDenyListEntry struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "BlockPhrase") to include + // 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. However, any field with // an empty value appearing in NullFields will be sent to the server as @@ -7519,78 +9525,33 @@ type GoogleCloudDiscoveryengineV1alphaSuggestionDenyListEntry struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaSuggestionDenyListEntry) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSuggestionDenyListEntry +func (s *GoogleCloudDiscoveryengineV1alphaWidgetConfigFacetField) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaWidgetConfigFacetField raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaTargetSite: A target site for the -// SiteSearchEngine. -type GoogleCloudDiscoveryengineV1alphaTargetSite struct { - // ExactMatch: Input only. If set to false, a uri_pattern is generated - // to include all pages whose address contains the provided_uri_pattern. - // If set to true, an uri_pattern is generated to try to be an exact - // match of the provided_uri_pattern or just the specific page if the - // provided_uri_pattern is a specific one. provided_uri_pattern is - // always normalized to generate the URI pattern to be used by the - // search engine. - ExactMatch bool `json:"exactMatch,omitempty"` - - // FailureReason: Output only. Failure reason. - FailureReason *GoogleCloudDiscoveryengineV1alphaTargetSiteFailureReason `json:"failureReason,omitempty"` - - // GeneratedUriPattern: Output only. This is system-generated based on - // the provided_uri_pattern. - GeneratedUriPattern string `json:"generatedUriPattern,omitempty"` - - // IndexingStatus: Output only. Indexing status. - // - // Possible values: - // "INDEXING_STATUS_UNSPECIFIED" - Defaults to SUCCEEDED. - // "PENDING" - The target site is in the update queue and will be - // picked up by indexing pipeline. - // "FAILED" - The target site fails to be indexed. - // "SUCCEEDED" - The target site has been indexed. - // "DELETING" - The previously indexed target site has been marked to - // be deleted. This is a transitioning state which will resulted in - // either: 1. target site deleted if unindexing is successful; 2. state - // reverts to SUCCEEDED if the unindexing fails. - IndexingStatus string `json:"indexingStatus,omitempty"` - - // Name: Output only. The fully qualified resource name of the target - // site. - // `projects/{project}/locations/{location}/collections/{collection}/data - // Stores/{data_store}/siteSearchEngine/targetSites/{target_site}` The - // `target_site_id` is system-generated. - Name string `json:"name,omitempty"` - - // ProvidedUriPattern: Required. Input only. The user provided URI - // pattern from which the `generated_uri_pattern` is generated. - ProvidedUriPattern string `json:"providedUriPattern,omitempty"` - - // SiteVerificationInfo: Output only. Site ownership and validity - // verification status. - SiteVerificationInfo *GoogleCloudDiscoveryengineV1alphaSiteVerificationInfo `json:"siteVerificationInfo,omitempty"` - - // Type: The type of the target site, e.g. whether the site is to be - // included or excluded. +// GoogleCloudDiscoveryengineV1alphaWidgetConfigUIComponentField: Facet +// field that maps to a UI Component. +type GoogleCloudDiscoveryengineV1alphaWidgetConfigUIComponentField struct { + // DeviceVisibility: The field visibility on different types of devices. // // Possible values: - // "TYPE_UNSPECIFIED" - This value is unused. In this case, server - // behavior defaults to Type.INCLUDE. - // "INCLUDE" - Include the target site. - // "EXCLUDE" - Exclude the target site. - Type string `json:"type,omitempty"` + // "DEVICE_VISIBILITY_UNSPECIFIED" - Default value when not specified. + // Server returns INVALID_ARGUMENT if used in requests. + // "MOBILE" - The UI component is visible on Mobile devices. + // "DESKTOP" - The UI component is visible on Browser-based client. + DeviceVisibility []string `json:"deviceVisibility,omitempty"` - // UpdateTime: Output only. The target site's last updated time. - UpdateTime string `json:"updateTime,omitempty"` + // DisplayTemplate: The template to customize how the field is + // displayed. An example value would be a string that looks like: + // "Price: {value}". + DisplayTemplate string `json:"displayTemplate,omitempty"` - // ServerResponse contains the HTTP response code and headers from the - // server. - googleapi.ServerResponse `json:"-"` + // Field: Required. Registered field name. The format is `field.abc`. + Field string `json:"field,omitempty"` - // ForceSendFields is a list of field names (e.g. "ExactMatch") to + // ForceSendFields is a list of field names (e.g. "DeviceVisibility") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -7598,62 +9559,46 @@ type GoogleCloudDiscoveryengineV1alphaTargetSite struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "ExactMatch") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "DeviceVisibility") to + // include in API requests with the JSON null value. By default, fields + // with empty values are omitted from API requests. However, any field + // with an empty value appearing in NullFields will be sent to the + // server as null. It is an error if a field in this list has a + // non-empty value. This may be used to include null fields in Patch + // requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaTargetSite) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaTargetSite +func (s *GoogleCloudDiscoveryengineV1alphaWidgetConfigUIComponentField) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaWidgetConfigUIComponentField raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaTargetSiteFailureReason: Site search -// indexing failure reasons. -type GoogleCloudDiscoveryengineV1alphaTargetSiteFailureReason struct { - // QuotaFailure: Failed due to insufficient quota. - QuotaFailure *GoogleCloudDiscoveryengineV1alphaTargetSiteFailureReasonQuotaFailure `json:"quotaFailure,omitempty"` - - // ForceSendFields is a list of field names (e.g. "QuotaFailure") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. - ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "QuotaFailure") to include - // in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. However, any field with - // an empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. - NullFields []string `json:"-"` -} - -func (s *GoogleCloudDiscoveryengineV1alphaTargetSiteFailureReason) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaTargetSiteFailureReason - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) -} +// GoogleCloudDiscoveryengineV1alphaWidgetConverseConversationRequest: +// Request message for WidgetService.WidgetConverseConversation method. +type GoogleCloudDiscoveryengineV1alphaWidgetConverseConversationRequest struct { + // AdditionalParams: Additional params for security and privacy + // enhancement. + AdditionalParams *GoogleCloudDiscoveryengineV1alphaAdditionalParams `json:"additionalParams,omitempty"` -type GoogleCloudDiscoveryengineV1alphaTargetSiteFailureReasonQuotaFailure struct { -} + // ConfigId: Required. The UUID of the WidgetConfig. This field is used + // to identify the widget configuration, set of models used to make the + // user event collection. + ConfigId string `json:"configId,omitempty"` -// GoogleCloudDiscoveryengineV1alphaTextInput: Defines text input. -type GoogleCloudDiscoveryengineV1alphaTextInput struct { - // Context: Conversation context of the input. - Context *GoogleCloudDiscoveryengineV1alphaConversationContext `json:"context,omitempty"` + // ConversationId: The id of the Conversation to get. Use "-" to + // activate auto session mode, which automatically creates a new + // conversation inside a ConverseConversation session. + ConversationId string `json:"conversationId,omitempty"` - // Input: Text input. - Input string `json:"input,omitempty"` + // ConverseConversationRequest: Required. The + // ConverseConversationRequest request to perform converse a + // conversation. The ServingConfig id will be `default_search` by + // default. + ConverseConversationRequest *GoogleCloudDiscoveryengineV1alphaConverseConversationRequest `json:"converseConversationRequest,omitempty"` - // ForceSendFields is a list of field names (e.g. "Context") to + // ForceSendFields is a list of field names (e.g. "AdditionalParams") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -7661,33 +9606,40 @@ type GoogleCloudDiscoveryengineV1alphaTextInput struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Context") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "AdditionalParams") to + // include in API requests with the JSON null value. By default, fields + // with empty values are omitted from API requests. However, any field + // with an empty value appearing in NullFields will be sent to the + // server as null. It is an error if a field in this list has a + // non-empty value. This may be used to include null fields in Patch + // requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaTextInput) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaTextInput +func (s *GoogleCloudDiscoveryengineV1alphaWidgetConverseConversationRequest) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaWidgetConverseConversationRequest raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaTrainCustomModelMetadata: Metadata -// related to the progress of the TrainCustomModel operation. This is -// returned by the google.longrunning.Operation.metadata field. -type GoogleCloudDiscoveryengineV1alphaTrainCustomModelMetadata struct { - // CreateTime: Operation create time. - CreateTime string `json:"createTime,omitempty"` +// GoogleCloudDiscoveryengineV1alphaWidgetConverseConversationResponse: +// Response message for WidgetService.WidgetConverseConversation method. +type GoogleCloudDiscoveryengineV1alphaWidgetConverseConversationResponse struct { + // ConversationId: The id of the Conversation returned. + ConversationId string `json:"conversationId,omitempty"` - // UpdateTime: Operation last update time. If the operation is done, - // this is also the finish time. - UpdateTime string `json:"updateTime,omitempty"` + // ConverseConversationResponse: ConverseConversationResponse returned + // from ConversationalSearchService.ConverseConversation. + ConverseConversationResponse *GoogleCloudDiscoveryengineV1alphaConverseConversationResponse `json:"converseConversationResponse,omitempty"` + + // UToken: The token in response. + UToken string `json:"uToken,omitempty"` - // ForceSendFields is a list of field names (e.g. "CreateTime") to + // ServerResponse contains the HTTP response code and headers from the + // server. + googleapi.ServerResponse `json:"-"` + + // ForceSendFields is a list of field names (e.g. "ConversationId") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -7695,37 +9647,38 @@ type GoogleCloudDiscoveryengineV1alphaTrainCustomModelMetadata struct { // This may be used to include empty fields in Patch requests. 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. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "ConversationId") to + // include in API requests with the JSON null value. By default, fields + // with empty values are omitted from API requests. However, any field + // with an empty value appearing in NullFields will be sent to the + // server as null. It is an error if a field in this list has a + // non-empty value. This may be used to include null fields in Patch + // requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaTrainCustomModelMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaTrainCustomModelMetadata +func (s *GoogleCloudDiscoveryengineV1alphaWidgetConverseConversationResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaWidgetConverseConversationResponse raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaTrainCustomModelRequest: Request -// message for SearchTuningService.TrainCustomModel method. -type GoogleCloudDiscoveryengineV1alphaTrainCustomModelRequest struct { - // ErrorConfig: The desired location of errors incurred during the data - // ingestion and training. - ErrorConfig *GoogleCloudDiscoveryengineV1alphaImportErrorConfig `json:"errorConfig,omitempty"` +// GoogleCloudDiscoveryengineV1alphaWidgetSearchRequest: Request message +// for WidgetService.WidgetSearch method. +type GoogleCloudDiscoveryengineV1alphaWidgetSearchRequest struct { + // AdditionalParams: Additional params for security and privacy + // enhancement. + AdditionalParams *GoogleCloudDiscoveryengineV1alphaAdditionalParams `json:"additionalParams,omitempty"` - // GcsTrainingInput: Cloud Storage training input. - GcsTrainingInput *GoogleCloudDiscoveryengineV1alphaTrainCustomModelRequestGcsTrainingInput `json:"gcsTrainingInput,omitempty"` + // ConfigId: Required. The UUID of the Search WidgetConfig. This field + // is used to identify the search widget configuration, set of models + // used to make the search. + ConfigId string `json:"configId,omitempty"` - // ModelType: Model to be trained. Supported values are: * - // **search-tuning**: Fine tuning the search system based on data - // provided. - ModelType string `json:"modelType,omitempty"` + // SearchRequest: Required. The search request to perform search. + SearchRequest *GoogleCloudDiscoveryengineV1alphaSearchRequest `json:"searchRequest,omitempty"` - // ForceSendFields is a list of field names (e.g. "ErrorConfig") to + // ForceSendFields is a list of field names (e.g. "AdditionalParams") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -7733,52 +9686,36 @@ type GoogleCloudDiscoveryengineV1alphaTrainCustomModelRequest struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "ErrorConfig") to include - // in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. However, any field with - // an empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "AdditionalParams") to + // include in API requests with the JSON null value. By default, fields + // with empty values are omitted from API requests. However, any field + // with an empty value appearing in NullFields will be sent to the + // server as null. It is an error if a field in this list has a + // non-empty value. This may be used to include null fields in Patch + // requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaTrainCustomModelRequest) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaTrainCustomModelRequest +func (s *GoogleCloudDiscoveryengineV1alphaWidgetSearchRequest) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaWidgetSearchRequest raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaTrainCustomModelRequestGcsTrainingInp -// ut: Cloud Storage training data input. -type GoogleCloudDiscoveryengineV1alphaTrainCustomModelRequestGcsTrainingInput struct { - // CorpusDataPath: The Cloud Storage corpus data which could be - // associated in train data. The data path format is gs:///. A newline - // delimited jsonl/ndjson file. For search-tuning model, each line - // should have the _id, title and text. Example: {"_id": "doc1", title: - // "relevant doc", "text": "relevant text"} - CorpusDataPath string `json:"corpusDataPath,omitempty"` - - // QueryDataPath: The gcs query data which could be associated in train - // data. The data path format is gs:///. A newline delimited - // jsonl/ndjson file. For search-tuning model, each line should have the - // _id and text. Example: {"_id": "query1", "text": "example query"} - QueryDataPath string `json:"queryDataPath,omitempty"` +// GoogleCloudDiscoveryengineV1alphaWidgetSearchResponse: Response +// message for WidgetService.WidgetSearch method. +type GoogleCloudDiscoveryengineV1alphaWidgetSearchResponse struct { + // SearchResponse: The search response after performing search. + SearchResponse *GoogleCloudDiscoveryengineV1alphaSearchResponse `json:"searchResponse,omitempty"` - // TestDataPath: Cloud Storage test data. Same format as - // train_data_path. If not provided, a random 80/20 train/test split - // will be performed on train_data_path. - TestDataPath string `json:"testDataPath,omitempty"` + // UToken: The token in response. + UToken string `json:"uToken,omitempty"` - // TrainDataPath: Cloud Storage training data path whose format should - // be gs:///. The file should be in tsv format. Each line should have - // the doc_id and query_id and score (number). For search-tuning model, - // it should have the query-id corpus-id score as tsv file header. The - // score should be a number in [0, inf+). The larger the number is, the - // more relevant the pair is. Example: query-id\tcorpus-id\tscore - // query1\tdoc1\t1 - TrainDataPath string `json:"trainDataPath,omitempty"` + // ServerResponse contains the HTTP response code and headers from the + // server. + googleapi.ServerResponse `json:"-"` - // ForceSendFields is a list of field names (e.g. "CorpusDataPath") to + // ForceSendFields is a list of field names (e.g. "SearchResponse") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -7786,7 +9723,7 @@ type GoogleCloudDiscoveryengineV1alphaTrainCustomModelRequestGcsTrainingInput st // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "CorpusDataPath") to + // NullFields is a list of field names (e.g. "SearchResponse") to // include in API requests with the JSON null value. By default, fields // with empty values are omitted from API requests. However, any field // with an empty value appearing in NullFields will be sent to the @@ -7796,32 +9733,25 @@ type GoogleCloudDiscoveryengineV1alphaTrainCustomModelRequestGcsTrainingInput st NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaTrainCustomModelRequestGcsTrainingInput) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaTrainCustomModelRequestGcsTrainingInput +func (s *GoogleCloudDiscoveryengineV1alphaWidgetSearchResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaWidgetSearchResponse raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaTrainCustomModelResponse: Response -// of the TrainCustomModelRequest. This message is returned by the -// google.longrunning.Operations.response field. -type GoogleCloudDiscoveryengineV1alphaTrainCustomModelResponse struct { - // ErrorConfig: Echoes the destination for the complete errors in the - // request if set. - ErrorConfig *GoogleCloudDiscoveryengineV1alphaImportErrorConfig `json:"errorConfig,omitempty"` - - // ErrorSamples: A sample of errors encountered while processing the - // data. - ErrorSamples []*GoogleRpcStatus `json:"errorSamples,omitempty"` +// GoogleCloudDiscoveryengineV1betaBatchCreateTargetSiteMetadata: +// Metadata related to the progress of the +// SiteSearchEngineService.BatchCreateTargetSites operation. This will +// be returned by the google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1betaBatchCreateTargetSiteMetadata struct { + // CreateTime: Operation create time. + CreateTime string `json:"createTime,omitempty"` - // ModelStatus: The trained model status. Possible values are: * - // **bad-data**: The training data quality is bad. * **no-improvement**: - // Tuning didn't improve performance. Won't deploy. * **in-progress**: - // Model training is in progress. * **ready**: The model is ready for - // serving. - ModelStatus string `json:"modelStatus,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. "ErrorConfig") to + // 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. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -7829,56 +9759,29 @@ type GoogleCloudDiscoveryengineV1alphaTrainCustomModelResponse struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "ErrorConfig") to include - // in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. However, any field with - // an empty value appearing in NullFields will be sent to the server as + // 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. However, any field with an + // empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaTrainCustomModelResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaTrainCustomModelResponse +func (s *GoogleCloudDiscoveryengineV1betaBatchCreateTargetSiteMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaBatchCreateTargetSiteMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaTransactionInfo: A transaction -// represents the entire purchase transaction. -type GoogleCloudDiscoveryengineV1alphaTransactionInfo struct { - // Cost: All the costs associated with the products. These can be - // manufacturing costs, shipping expenses not borne by the end user, or - // any other costs, such that: * Profit = value - tax - cost - Cost float64 `json:"cost,omitempty"` - - // Currency: Required. Currency code. Use three-character ISO-4217 code. - Currency string `json:"currency,omitempty"` - - // DiscountValue: The total discount(s) value applied to this - // transaction. This figure should be excluded from - // TransactionInfo.value For example, if a user paid - // TransactionInfo.value amount, then nominal (pre-discount) value of - // the transaction is the sum of TransactionInfo.value and - // TransactionInfo.discount_value This means that profit is calculated - // the same way, regardless of the discount value, and that - // TransactionInfo.discount_value can be larger than - // TransactionInfo.value: * Profit = value - tax - cost - DiscountValue float64 `json:"discountValue,omitempty"` - - // Tax: All the taxes associated with the transaction. - Tax float64 `json:"tax,omitempty"` - - // TransactionId: The transaction ID with a length limit of 128 - // characters. - TransactionId string `json:"transactionId,omitempty"` - - // Value: Required. Total non-zero value associated with the - // transaction. This value may include shipping, tax, or other - // adjustments to the total value that you want to include. - Value float64 `json:"value,omitempty"` +// GoogleCloudDiscoveryengineV1betaBatchCreateTargetSitesResponse: +// Response message for SiteSearchEngineService.BatchCreateTargetSites +// method. +type GoogleCloudDiscoveryengineV1betaBatchCreateTargetSitesResponse struct { + // TargetSites: TargetSites created. + TargetSites []*GoogleCloudDiscoveryengineV1betaTargetSite `json:"targetSites,omitempty"` - // ForceSendFields is a list of field names (e.g. "Cost") to + // ForceSendFields is a list of field names (e.g. "TargetSites") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -7886,51 +9789,34 @@ type GoogleCloudDiscoveryengineV1alphaTransactionInfo struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Cost") to include in API - // requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as + // NullFields is a list of field names (e.g. "TargetSites") to include + // in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. However, any field with + // an empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaTransactionInfo) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaTransactionInfo +func (s *GoogleCloudDiscoveryengineV1betaBatchCreateTargetSitesResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaBatchCreateTargetSitesResponse raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -func (s *GoogleCloudDiscoveryengineV1alphaTransactionInfo) UnmarshalJSON(data []byte) error { - type NoMethod GoogleCloudDiscoveryengineV1alphaTransactionInfo - var s1 struct { - Cost gensupport.JSONFloat64 `json:"cost"` - DiscountValue gensupport.JSONFloat64 `json:"discountValue"` - Tax gensupport.JSONFloat64 `json:"tax"` - Value gensupport.JSONFloat64 `json:"value"` - *NoMethod - } - s1.NoMethod = (*NoMethod)(s) - if err := json.Unmarshal(data, &s1); err != nil { - return err - } - s.Cost = float64(s1.Cost) - s.DiscountValue = float64(s1.DiscountValue) - s.Tax = float64(s1.Tax) - s.Value = float64(s1.Value) - return nil -} +// GoogleCloudDiscoveryengineV1betaCreateDataStoreMetadata: Metadata +// related to the progress of the DataStoreService.CreateDataStore +// operation. This will be returned by the +// google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1betaCreateDataStoreMetadata struct { + // CreateTime: Operation create time. + CreateTime string `json:"createTime,omitempty"` -// GoogleCloudDiscoveryengineV1alphaTuneEngineMetadata: Metadata -// associated with a tune operation. -type GoogleCloudDiscoveryengineV1alphaTuneEngineMetadata struct { - // Engine: Required. The resource name of the engine that this tune - // applies to. Format: - // `projects/{project_number}/locations/{location_id}/collections/{collec - // tion_id}/engines/{engine_id}` - Engine string `json:"engine,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. "Engine") to + // 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. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -7938,8 +9824,8 @@ type GoogleCloudDiscoveryengineV1alphaTuneEngineMetadata struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Engine") to include in API - // requests with the JSON null value. By default, fields with empty + // 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. However, any field with an // empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. @@ -7947,26 +9833,17 @@ type GoogleCloudDiscoveryengineV1alphaTuneEngineMetadata struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaTuneEngineMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaTuneEngineMetadata +func (s *GoogleCloudDiscoveryengineV1betaCreateDataStoreMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaCreateDataStoreMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaTuneEngineRequest: Request to -// manually start a tuning process now (instead of waiting for the -// periodically scheduled tuning to happen). -type GoogleCloudDiscoveryengineV1alphaTuneEngineRequest struct { -} - -// GoogleCloudDiscoveryengineV1alphaTuneEngineResponse: Response -// associated with a tune operation. -type GoogleCloudDiscoveryengineV1alphaTuneEngineResponse struct { -} - -// GoogleCloudDiscoveryengineV1alphaUpdateSchemaMetadata: Metadata for -// UpdateSchema LRO. -type GoogleCloudDiscoveryengineV1alphaUpdateSchemaMetadata struct { +// GoogleCloudDiscoveryengineV1betaCreateEngineMetadata: Metadata +// related to the progress of the EngineService.CreateEngine operation. +// This will be returned by the google.longrunning.Operation.metadata +// field. +type GoogleCloudDiscoveryengineV1betaCreateEngineMetadata struct { // CreateTime: Operation create time. CreateTime string `json:"createTime,omitempty"` @@ -7991,17 +9868,15 @@ type GoogleCloudDiscoveryengineV1alphaUpdateSchemaMetadata struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaUpdateSchemaMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaUpdateSchemaMetadata +func (s *GoogleCloudDiscoveryengineV1betaCreateEngineMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaCreateEngineMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaUpdateTargetSiteMetadata: Metadata -// related to the progress of the -// SiteSearchEngineService.UpdateTargetSite operation. This will be -// returned by the google.longrunning.Operation.metadata field. -type GoogleCloudDiscoveryengineV1alphaUpdateTargetSiteMetadata struct { +// GoogleCloudDiscoveryengineV1betaCreateSchemaMetadata: Metadata for +// Create Schema LRO. +type GoogleCloudDiscoveryengineV1betaCreateSchemaMetadata struct { // CreateTime: Operation create time. CreateTime string `json:"createTime,omitempty"` @@ -8026,164 +9901,25 @@ type GoogleCloudDiscoveryengineV1alphaUpdateTargetSiteMetadata struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaUpdateTargetSiteMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaUpdateTargetSiteMetadata +func (s *GoogleCloudDiscoveryengineV1betaCreateSchemaMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaCreateSchemaMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaUserEvent: UserEvent captures all -// metadata information Discovery Engine API needs to know about how end -// users interact with customers' website. -type GoogleCloudDiscoveryengineV1alphaUserEvent struct { - // Attributes: Extra user event features to include in the - // recommendation model. These attributes must NOT contain data that - // needs to be parsed or processed further, e.g. JSON or other - // encodings. If you provide custom attributes for ingested user events, - // also include them in the user events that you associate with - // prediction requests. Custom attribute formatting must be consistent - // between imported events and events provided with prediction requests. - // This lets the Discovery Engine API use those custom attributes when - // training models and serving predictions, which helps improve - // recommendation quality. This field needs to pass all below criteria, - // otherwise an `INVALID_ARGUMENT` error is returned: * The key must be - // a UTF-8 encoded string with a length limit of 5,000 characters. * For - // text attributes, at most 400 values are allowed. Empty values are not - // allowed. Each value must be a UTF-8 encoded string with a length - // limit of 256 characters. * For number attributes, at most 400 values - // are allowed. For product recommendations, an example of extra user - // information is `traffic_channel`, which is how a user arrives at the - // site. Users can arrive at the site by coming to the site directly, - // coming through Google search, or in other ways. - Attributes map[string]GoogleCloudDiscoveryengineV1alphaCustomAttribute `json:"attributes,omitempty"` - - // AttributionToken: Token to attribute an API response to user - // action(s) to trigger the event. Highly recommended for user events - // that are the result of RecommendationService.Recommend. This field - // enables accurate attribution of recommendation model performance. The - // value must be one of: * RecommendResponse.attribution_token for - // events that are the result of RecommendationService.Recommend. * - // SearchResponse.attribution_token for events that are the result of - // SearchService.Search. This token enables us to accurately attribute - // page view or conversion completion back to the event and the - // particular predict response containing this clicked/purchased - // product. If user clicks on product K in the recommendation results, - // pass RecommendResponse.attribution_token as a URL parameter to - // product K's page. When recording events on product K's page, log the - // RecommendResponse.attribution_token to this field. - AttributionToken string `json:"attributionToken,omitempty"` - - // CompletionInfo: CompletionService.CompleteQuery details related to - // the event. This field should be set for `search` event when - // autocomplete function is enabled and the user clicks a suggestion for - // search. - CompletionInfo *GoogleCloudDiscoveryengineV1alphaCompletionInfo `json:"completionInfo,omitempty"` - - // DirectUserRequest: Should set to true if the request is made directly - // from the end user, in which case the UserEvent.user_info.user_agent - // can be populated from the HTTP request. This flag should be set only - // if the API request is made directly from the end user such as a - // mobile app (and not if a gateway or a server is processing and - // pushing the user events). This should not be set when using the - // JavaScript tag in UserEventService.CollectUserEvent. - DirectUserRequest bool `json:"directUserRequest,omitempty"` - - // Documents: List of Documents associated with this user event. This - // field is optional except for the following event types: * `view-item` - // * `add-to-cart` * `purchase` * `media-play` * `media-complete` In a - // `search` event, this field represents the documents 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 UserEvent.documents is desired. - Documents []*GoogleCloudDiscoveryengineV1alphaDocumentInfo `json:"documents,omitempty"` - - // EventTime: Only required for UserEventService.ImportUserEvents - // method. Timestamp of when the user event happened. - EventTime string `json:"eventTime,omitempty"` - - // EventType: Required. User event type. Allowed values are: Generic - // values: * `search`: Search for Documents. * `view-item`: Detailed - // page view of a Document. * `view-item-list`: View of a panel or - // ordered list of Documents. * `view-home-page`: View of the home page. - // * `view-category-page`: View of a category page, e.g. Home > Men > - // Jeans Retail-related values: * `add-to-cart`: Add an item(s) to cart, - // e.g. in Retail online shopping * `purchase`: Purchase an item(s) - // Media-related values: * `media-play`: Start/resume watching a video, - // playing a song, etc. * `media-complete`: Finished or stopped midway - // through a video, song, etc. - EventType string `json:"eventType,omitempty"` - - // Filter: The filter syntax consists of an expression language for - // constructing a predicate from one or more fields of the documents - // being filtered. One example is for `search` events, the associated - // SearchRequest may contain a filter expression in SearchRequest.filter - // conforming to https://google.aip.dev/160#filtering. Similarly, for - // `view-item-list` events that are generated from a RecommendRequest, - // this field may be populated directly from RecommendRequest.filter - // conforming to https://google.aip.dev/160#filtering. The value must be - // a UTF-8 encoded string with a length limit of 1,000 characters. - // Otherwise, an `INVALID_ARGUMENT` error is returned. - Filter string `json:"filter,omitempty"` - - // MediaInfo: Media-specific info. - MediaInfo *GoogleCloudDiscoveryengineV1alphaMediaInfo `json:"mediaInfo,omitempty"` - - // PageInfo: Page metadata such as categories and other critical - // information for certain event types such as `view-category-page`. - PageInfo *GoogleCloudDiscoveryengineV1alphaPageInfo `json:"pageInfo,omitempty"` - - // Panel: Panel metadata associated with this user event. - Panel *GoogleCloudDiscoveryengineV1alphaPanelInfo `json:"panel,omitempty"` - - // PromotionIds: The promotion IDs if this is an event associated with - // promotions. Currently, this field is restricted to at most one ID. - PromotionIds []string `json:"promotionIds,omitempty"` - - // SearchInfo: SearchService.Search details related to the event. This - // field should be set for `search` event. - SearchInfo *GoogleCloudDiscoveryengineV1alphaSearchInfo `json:"searchInfo,omitempty"` - - // SessionId: A unique identifier for tracking a visitor session with a - // length limit of 128 bytes. A session is an aggregation of an end user - // behavior in a time span. A general guideline to populate the - // session_id: 1. If user has no activity for 30 min, a new session_id - // should be assigned. 2. The session_id should be unique across users, - // suggest use uuid or add UserEvent.user_pseudo_id as prefix. - SessionId string `json:"sessionId,omitempty"` - - // TagIds: A list of identifiers for the independent experiment groups - // this user event belongs to. This is used to distinguish between user - // events associated with different experiment setups on the customer - // end. - TagIds []string `json:"tagIds,omitempty"` - - // TransactionInfo: The transaction metadata (if any) associated with - // this user event. - TransactionInfo *GoogleCloudDiscoveryengineV1alphaTransactionInfo `json:"transactionInfo,omitempty"` - - // UserInfo: Information about the end user. - UserInfo *GoogleCloudDiscoveryengineV1alphaUserInfo `json:"userInfo,omitempty"` - - // UserPseudoId: Required. A unique identifier for tracking visitors. - // For example, this could be implemented with an HTTP cookie, which - // should be able to uniquely identify a visitor on a single device. - // This unique identifier should not change if the visitor log in/out of - // the website. Do not set the field to the same fixed ID for different - // users. This mixes the event history of those users together, which - // results in degraded model quality. The field must be a UTF-8 encoded - // string with a length limit of 128 characters. Otherwise, an - // `INVALID_ARGUMENT` error is returned. The field should not contain - // PII or user-data. We recommend to use Google Analytics Client ID - // (https://developers.google.com/analytics/devguides/collection/analyticsjs/field-reference#clientId) - // for this field. - UserPseudoId string `json:"userPseudoId,omitempty"` +// GoogleCloudDiscoveryengineV1betaCreateTargetSiteMetadata: Metadata +// related to the progress of the +// SiteSearchEngineService.CreateTargetSite operation. This will be +// returned by the google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1betaCreateTargetSiteMetadata struct { + // CreateTime: Operation create time. + CreateTime string `json:"createTime,omitempty"` - // ServerResponse contains the HTTP response code and headers from the - // server. - googleapi.ServerResponse `json:"-"` + // 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. "Attributes") to + // 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. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -8191,7 +9927,7 @@ type GoogleCloudDiscoveryengineV1alphaUserEvent struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Attributes") to include in + // 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. However, any field with an // empty value appearing in NullFields will be sent to the server as @@ -8200,72 +9936,106 @@ type GoogleCloudDiscoveryengineV1alphaUserEvent struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaUserEvent) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaUserEvent +func (s *GoogleCloudDiscoveryengineV1betaCreateTargetSiteMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaCreateTargetSiteMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaUserInfo: Information of an end -// user. -type GoogleCloudDiscoveryengineV1alphaUserInfo struct { - // UserAgent: User agent as included in the HTTP header. The field must - // be a UTF-8 encoded string with a length limit of 1,000 characters. - // Otherwise, an `INVALID_ARGUMENT` error is returned. This should not - // be set when using the client side event reporting with GTM or - // JavaScript tag in UserEventService.CollectUserEvent or if - // UserEvent.direct_user_request is set. - UserAgent string `json:"userAgent,omitempty"` +// GoogleCloudDiscoveryengineV1betaDataStore: DataStore captures global +// settings and configs at the DataStore level. +type GoogleCloudDiscoveryengineV1betaDataStore struct { + // ContentConfig: Immutable. The content config of the data store. If + // this field is unset, the server behavior defaults to + // ContentConfig.NO_CONTENT. + // + // Possible values: + // "CONTENT_CONFIG_UNSPECIFIED" - Default value. + // "NO_CONTENT" - Only contains documents without any + // Document.content. + // "CONTENT_REQUIRED" - Only contains documents with Document.content. + // "PUBLIC_WEBSITE" - The data store is used for public website + // search. + ContentConfig string `json:"contentConfig,omitempty"` - // UserId: Highly recommended for logged-in users. Unique identifier for - // logged-in user, such as a user name. Don't set for anonymous users. - // Always use a hashed value for this ID. Don't set the field to the - // same fixed ID for different users. This mixes the event history of - // those users together, which results in degraded model quality. The - // field must be a UTF-8 encoded string with a length limit of 128 - // characters. Otherwise, an `INVALID_ARGUMENT` error is returned. - UserId string `json:"userId,omitempty"` + // CreateTime: Output only. Timestamp the DataStore was created at. + CreateTime string `json:"createTime,omitempty"` - // ForceSendFields is a list of field names (e.g. "UserAgent") to + // DefaultSchemaId: Output only. The id of the default Schema + // asscociated to this data store. + DefaultSchemaId string `json:"defaultSchemaId,omitempty"` + + // DisplayName: Required. The data store display name. This field must + // be a UTF-8 encoded string with a length limit of 128 characters. + // Otherwise, an INVALID_ARGUMENT error is returned. + DisplayName string `json:"displayName,omitempty"` + + // IndustryVertical: Immutable. The industry vertical that the data + // store registers. + // + // Possible values: + // "INDUSTRY_VERTICAL_UNSPECIFIED" - Value used when unset. + // "GENERIC" - The generic vertical for documents that are not + // specific to any industry vertical. + // "MEDIA" - The media industry vertical. + IndustryVertical string `json:"industryVertical,omitempty"` + + // Name: Immutable. The full resource name of the data store. Format: + // `projects/{project}/locations/{location}/collections/{collection_id}/d + // ataStores/{data_store_id}`. This field must be a UTF-8 encoded string + // with a length limit of 1024 characters. + Name string `json:"name,omitempty"` + + // SolutionTypes: The solutions that the data store enrolls. Available + // solutions for each industry_vertical: * `MEDIA`: + // `SOLUTION_TYPE_RECOMMENDATION` and `SOLUTION_TYPE_SEARCH`. * + // `SITE_SEARCH`: `SOLUTION_TYPE_SEARCH` is automatically enrolled. + // Other solutions cannot be enrolled. + // + // Possible values: + // "SOLUTION_TYPE_UNSPECIFIED" - Default value. + // "SOLUTION_TYPE_RECOMMENDATION" - Used for Recommendations AI. + // "SOLUTION_TYPE_SEARCH" - Used for Discovery Search. + // "SOLUTION_TYPE_CHAT" - Used for use cases related to the Generative + // AI agent. + SolutionTypes []string `json:"solutionTypes,omitempty"` + + // ForceSendFields is a list of field names (e.g. "ContentConfig") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be // sent to the server regardless of whether the field is empty or not. // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "UserAgent") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as + + // NullFields is a list of field names (e.g. "ContentConfig") to include + // in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. However, any field with + // an empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaUserInfo) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaUserInfo +func (s *GoogleCloudDiscoveryengineV1betaDataStore) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaDataStore raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaWidgetCompleteQueryRequest: Request -// message for WidgetService.WidgetCompleteQuery method. -type GoogleCloudDiscoveryengineV1alphaWidgetCompleteQueryRequest struct { - // AdditionalParams: Additional params for security and privacy - // enhancement. - AdditionalParams *GoogleCloudDiscoveryengineV1alphaAdditionalParams `json:"additionalParams,omitempty"` - - // CompleteQueryRequest: Required. The CompleteQuery request to perform - // auto-complete suggestion query. - CompleteQueryRequest *GoogleCloudDiscoveryengineV1alphaCompleteQueryRequest `json:"completeQueryRequest,omitempty"` +// GoogleCloudDiscoveryengineV1betaDeleteDataStoreMetadata: Metadata +// related to the progress of the DataStoreService.DeleteDataStore +// operation. This will be returned by the +// google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1betaDeleteDataStoreMetadata struct { + // CreateTime: Operation create time. + CreateTime string `json:"createTime,omitempty"` - // ConfigId: Required. The UUID of the WidgetConfig. This field is used - // to identify the widget configuration, set of models used to make the - // auto complete query. - ConfigId string `json:"configId,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. "AdditionalParams") to + // 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. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -8273,38 +10043,34 @@ type GoogleCloudDiscoveryengineV1alphaWidgetCompleteQueryRequest struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "AdditionalParams") to - // include in API requests with the JSON null value. By default, fields - // with empty values are omitted from API requests. However, any field - // with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. + // 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. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaWidgetCompleteQueryRequest) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaWidgetCompleteQueryRequest +func (s *GoogleCloudDiscoveryengineV1betaDeleteDataStoreMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaDeleteDataStoreMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaWidgetCompleteQueryResponse: -// Response message for WidgetService.WidgetCompleteQuery method. -type GoogleCloudDiscoveryengineV1alphaWidgetCompleteQueryResponse struct { - // UToken: The token in response. - UToken string `json:"uToken,omitempty"` - - // WidgetQuerySuggestions: Results of the matched query suggestions in - // widget. The result list is ordered and the first result is a top - // suggestion. - WidgetQuerySuggestions []*GoogleCloudDiscoveryengineV1alphaWidgetCompleteQueryResponseWidgetQuerySuggestion `json:"widgetQuerySuggestions,omitempty"` +// GoogleCloudDiscoveryengineV1betaDeleteEngineMetadata: Metadata +// related to the progress of the EngineService.DeleteEngine operation. +// This will be returned by the google.longrunning.Operation.metadata +// field. +type GoogleCloudDiscoveryengineV1betaDeleteEngineMetadata struct { + // CreateTime: Operation create time. + CreateTime string `json:"createTime,omitempty"` - // ServerResponse contains the HTTP response code and headers from the - // server. - googleapi.ServerResponse `json:"-"` + // 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. "UToken") to + // 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. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -8312,8 +10078,8 @@ type GoogleCloudDiscoveryengineV1alphaWidgetCompleteQueryResponse struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "UToken") to include in API - // requests with the JSON null value. By default, fields with empty + // 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. However, any field with an // empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. @@ -8321,19 +10087,23 @@ type GoogleCloudDiscoveryengineV1alphaWidgetCompleteQueryResponse struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaWidgetCompleteQueryResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaWidgetCompleteQueryResponse +func (s *GoogleCloudDiscoveryengineV1betaDeleteEngineMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaDeleteEngineMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaWidgetCompleteQueryResponseWidgetQuer -// ySuggestion: Suggestions as search queries. -type GoogleCloudDiscoveryengineV1alphaWidgetCompleteQueryResponseWidgetQuerySuggestion struct { - // Suggestion: The suggestion for the query. - Suggestion string `json:"suggestion,omitempty"` +// GoogleCloudDiscoveryengineV1betaDeleteSchemaMetadata: Metadata for +// DeleteSchema LRO. +type GoogleCloudDiscoveryengineV1betaDeleteSchemaMetadata struct { + // CreateTime: Operation create time. + CreateTime string `json:"createTime,omitempty"` - // ForceSendFields is a list of field names (e.g. "Suggestion") to + // 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. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -8341,7 +10111,7 @@ type GoogleCloudDiscoveryengineV1alphaWidgetCompleteQueryResponseWidgetQuerySugg // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Suggestion") to include in + // 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. However, any field with an // empty value appearing in NullFields will be sent to the server as @@ -8350,168 +10120,60 @@ type GoogleCloudDiscoveryengineV1alphaWidgetCompleteQueryResponseWidgetQuerySugg NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaWidgetCompleteQueryResponseWidgetQuerySuggestion) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaWidgetCompleteQueryResponseWidgetQuerySuggestion +func (s *GoogleCloudDiscoveryengineV1betaDeleteSchemaMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaDeleteSchemaMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaWidgetConfig: WidgetConfig captures -// configs at the Widget level. -type GoogleCloudDiscoveryengineV1alphaWidgetConfig struct { - // AllowPublicAccess: Whether allow no-auth integration with widget. If - // set true, public access to search or other solutions from widget is - // allowed without authenication token provided by customer hosted - // backend server. - AllowPublicAccess bool `json:"allowPublicAccess,omitempty"` - - // AllowlistedDomains: Allowlisted domains that can load this widget. - AllowlistedDomains []string `json:"allowlistedDomains,omitempty"` - - // ConfigId: Output only. Unique obfuscated identifier of a - // WidgetConfig. - ConfigId string `json:"configId,omitempty"` - - // ContentSearchSpec: The content search spec that configs the desired - // behavior of content search. - ContentSearchSpec *GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpec `json:"contentSearchSpec,omitempty"` - - // CreateTime: Output only. Timestamp the WidgetConfig was created. +// GoogleCloudDiscoveryengineV1betaDeleteTargetSiteMetadata: Metadata +// related to the progress of the +// SiteSearchEngineService.DeleteTargetSite operation. This will be +// returned by the google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1betaDeleteTargetSiteMetadata struct { + // CreateTime: Operation create time. CreateTime string `json:"createTime,omitempty"` - // DataStoreType: Output only. The type of the parent data store. - // - // Possible values: - // "DATA_STORE_TYPE_UNSPECIFIED" - Unspecified data store type. - // "SITE_SEARCH" - The parent data store contains a site search - // engine. - // "STRUCTURED" - The parent data store contains a search engine for - // structured data. - // "UNSTRUCTURED" - The parent data store contains a search engine for - // unstructured data. - // "BLENDED" - The parent data store is served for blended search with - // multiple data stores. - DataStoreType string `json:"dataStoreType,omitempty"` - - // DisplayName: Required. The human readable widget config display name. - // Used in Discovery UI. This field must be a UTF-8 encoded string with - // a length limit of 128 characters. Otherwise, an INVALID_ARGUMENT - // error is returned. - DisplayName string `json:"displayName,omitempty"` - - // EnableAutocomplete: Whether or not to enable autocomplete. - EnableAutocomplete bool `json:"enableAutocomplete,omitempty"` - - // EnableConversationalSearch: Whether to allow conversational search - // (LLM, multi-turn) or not (non-LLM, single-turn). - EnableConversationalSearch bool `json:"enableConversationalSearch,omitempty"` - - // EnableQualityFeedback: Turn on or off collecting the search result - // quality feedback from end users. - EnableQualityFeedback bool `json:"enableQualityFeedback,omitempty"` - - // EnableResultScore: Whether to show the result score. - EnableResultScore bool `json:"enableResultScore,omitempty"` - - // EnableSafeSearch: Whether to enable safe search. - EnableSafeSearch bool `json:"enableSafeSearch,omitempty"` - - // EnableSnippetResultSummary: Turn on or off summary for each snippets - // result. - EnableSnippetResultSummary bool `json:"enableSnippetResultSummary,omitempty"` - - // EnableSummarization: Turn on or off summarization for the search - // response. - EnableSummarization bool `json:"enableSummarization,omitempty"` - - // FacetField: The configuration and appearance of facets in the end - // user view. - FacetField []*GoogleCloudDiscoveryengineV1alphaWidgetConfigFacetField `json:"facetField,omitempty"` - - // FieldsUiComponentsMap: The key is the UI component. Mock. Currently - // supported `title`, `thumbnail`, `url`, `custom1`, `custom2`, - // `custom3`. The value is the name of the field along with its device - // visibility. The 3 custom fields are optional and can be added or - // removed. `title`, `thumbnail`, `url` are required UI components that - // cannot be removed. - FieldsUiComponentsMap map[string]GoogleCloudDiscoveryengineV1alphaWidgetConfigUIComponentField `json:"fieldsUiComponentsMap,omitempty"` - - // LlmEnabled: Output only. Whether LLM is enabled in the corresponding - // data store. - LlmEnabled bool `json:"llmEnabled,omitempty"` - - // MinimumDataTermAccepted: Output only. Whether the customer accepted - // data use terms. - MinimumDataTermAccepted bool `json:"minimumDataTermAccepted,omitempty"` - - // Name: Immutable. The full resource name of the widget config. Format: - // `projects/{project}/locations/{location}/collections/{collection_id}/d - // ataStores/{data_store_id}/widgetConfigs/{widget_config_id}`. This - // field must be a UTF-8 encoded string with a length limit of 1024 - // characters. - Name string `json:"name,omitempty"` - - // ResultDisplayType: The type of snippet to display in UCS widget. - - // RESULT_DISPLAY_TYPE_UNSPECIFIED for existing users. - SNIPPET for new - // non-enterprise search users. - EXTRACTIVE_ANSWER for new enterprise - // search users. - // - // Possible values: - // "RESULT_DISPLAY_TYPE_UNSPECIFIED" - Unspecified display type - // (default to showing snippet). - // "SNIPPET" - Display results from the snippet field. - // "EXTRACTIVE_ANSWER" - Display results from extractive answers - // field. - ResultDisplayType string `json:"resultDisplayType,omitempty"` - - // SolutionType: Required. Immutable. Specifies the solution type that - // this WidgetConfig can be used for. - // - // Possible values: - // "SOLUTION_TYPE_UNSPECIFIED" - Default value. - // "SOLUTION_TYPE_RECOMMENDATION" - Used for Recommendations AI. - // "SOLUTION_TYPE_SEARCH" - Used for Discovery Search. - // "SOLUTION_TYPE_CHAT" - Used for use cases related to the Generative - // AI agent. - SolutionType string `json:"solutionType,omitempty"` - - // UpdateTime: Output only. Timestamp the WidgetConfig was updated. + // 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. "AllowPublicAccess") - // to unconditionally include in API requests. By default, fields with + // 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. However, any // non-pointer, non-interface field appearing in ForceSendFields will be // sent to the server regardless of whether the field is empty or not. // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "AllowPublicAccess") to - // include in API requests with the JSON null value. By default, fields - // with empty values are omitted from API requests. However, any field - // with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. + // 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. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaWidgetConfig) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaWidgetConfig +func (s *GoogleCloudDiscoveryengineV1betaDeleteTargetSiteMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaDeleteTargetSiteMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaWidgetConfigFacetField: Facet fields -// that store the mapping of fields to end user widget appearance. -type GoogleCloudDiscoveryengineV1alphaWidgetConfigFacetField struct { - // DisplayName: Optional. The field name that end users will see. - DisplayName string `json:"displayName,omitempty"` +// GoogleCloudDiscoveryengineV1betaDisableAdvancedSiteSearchMetadata: +// Metadata related to the progress of the +// SiteSearchEngineService.DisableAdvancedSiteSearch operation. This +// will be returned by the google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1betaDisableAdvancedSiteSearchMetadata struct { + // CreateTime: Operation create time. + CreateTime string `json:"createTime,omitempty"` - // Field: Required. Registered field name. The format is `field.abc`. - Field string `json:"field,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. "DisplayName") to + // 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. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -8519,42 +10181,40 @@ type GoogleCloudDiscoveryengineV1alphaWidgetConfigFacetField struct { // This may be used to include empty fields in Patch requests. 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. However, any field with - // an empty value appearing in NullFields will be sent to the server as + // 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. However, any field with an + // empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaWidgetConfigFacetField) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaWidgetConfigFacetField +func (s *GoogleCloudDiscoveryengineV1betaDisableAdvancedSiteSearchMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaDisableAdvancedSiteSearchMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaWidgetConfigUIComponentField: Facet -// field that maps to a UI Component. -type GoogleCloudDiscoveryengineV1alphaWidgetConfigUIComponentField struct { - // DeviceVisibility: The field visibility on different types of devices. - // - // Possible values: - // "DEVICE_VISIBILITY_UNSPECIFIED" - Default value when not specified. - // Server returns INVALID_ARGUMENT if used in requests. - // "MOBILE" - The UI component is visible on Mobile devices. - // "DESKTOP" - The UI component is visible on Browser-based client. - DeviceVisibility []string `json:"deviceVisibility,omitempty"` +// GoogleCloudDiscoveryengineV1betaDisableAdvancedSiteSearchResponse: +// Response message for +// SiteSearchEngineService.DisableAdvancedSiteSearch method. +type GoogleCloudDiscoveryengineV1betaDisableAdvancedSiteSearchResponse struct { +} - // DisplayTemplate: The template to customize how the field is - // displayed. An example value would be a string that looks like: - // "Price: {value}". - DisplayTemplate string `json:"displayTemplate,omitempty"` +// GoogleCloudDiscoveryengineV1betaEnableAdvancedSiteSearchMetadata: +// Metadata related to the progress of the +// SiteSearchEngineService.EnableAdvancedSiteSearch operation. This will +// be returned by the google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1betaEnableAdvancedSiteSearchMetadata struct { + // CreateTime: Operation create time. + CreateTime string `json:"createTime,omitempty"` - // Field: Required. Registered field name. The format is `field.abc`. - Field string `json:"field,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. "DeviceVisibility") to + // 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. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -8562,46 +10222,99 @@ type GoogleCloudDiscoveryengineV1alphaWidgetConfigUIComponentField struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "DeviceVisibility") to - // include in API requests with the JSON null value. By default, fields - // with empty values are omitted from API requests. However, any field - // with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. + // 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. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaWidgetConfigUIComponentField) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaWidgetConfigUIComponentField +func (s *GoogleCloudDiscoveryengineV1betaEnableAdvancedSiteSearchMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaEnableAdvancedSiteSearchMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaWidgetConverseConversationRequest: -// Request message for WidgetService.WidgetConverseConversation method. -type GoogleCloudDiscoveryengineV1alphaWidgetConverseConversationRequest struct { - // AdditionalParams: Additional params for security and privacy - // enhancement. - AdditionalParams *GoogleCloudDiscoveryengineV1alphaAdditionalParams `json:"additionalParams,omitempty"` +// GoogleCloudDiscoveryengineV1betaEnableAdvancedSiteSearchResponse: +// Response message for SiteSearchEngineService.EnableAdvancedSiteSearch +// method. +type GoogleCloudDiscoveryengineV1betaEnableAdvancedSiteSearchResponse struct { +} - // ConfigId: Required. The UUID of the WidgetConfig. This field is used - // to identify the widget configuration, set of models used to make the - // user event collection. - ConfigId string `json:"configId,omitempty"` +// GoogleCloudDiscoveryengineV1betaEngine: Metadata that describes the +// training and serving parameters of an Engine. +type GoogleCloudDiscoveryengineV1betaEngine struct { + // ChatEngineConfig: Configurations for the Chat Engine. Only applicable + // if solution_type is SOLUTION_TYPE_CHAT. + ChatEngineConfig *GoogleCloudDiscoveryengineV1betaEngineChatEngineConfig `json:"chatEngineConfig,omitempty"` - // ConversationId: The id of the Conversation to get. Use "-" to - // activate auto session mode, which automatically creates a new - // conversation inside a ConverseConversation session. - ConversationId string `json:"conversationId,omitempty"` + // ChatEngineMetadata: Output only. Additional information of the Chat + // Engine. Only applicable if solution_type is SOLUTION_TYPE_CHAT. + ChatEngineMetadata *GoogleCloudDiscoveryengineV1betaEngineChatEngineMetadata `json:"chatEngineMetadata,omitempty"` - // ConverseConversationRequest: Required. The - // ConverseConversationRequest request to perform converse a - // conversation. The ServingConfig id will be `default_search` by - // default. - ConverseConversationRequest *GoogleCloudDiscoveryengineV1alphaConverseConversationRequest `json:"converseConversationRequest,omitempty"` + // CommonConfig: Common config spec that specifies the metadata of the + // engine. + CommonConfig *GoogleCloudDiscoveryengineV1betaEngineCommonConfig `json:"commonConfig,omitempty"` - // ForceSendFields is a list of field names (e.g. "AdditionalParams") to + // CreateTime: Output only. Timestamp the Recommendation Engine was + // created at. + CreateTime string `json:"createTime,omitempty"` + + // DataStoreIds: The data stores associated with this engine. For + // SOLUTION_TYPE_SEARCH and SOLUTION_TYPE_RECOMMENDATION type of + // engines, they can only associate with at most one data store. If + // solution_type is SOLUTION_TYPE_CHAT, multiple DataStores in the same + // Collection can be associated here. Note that when used in + // CreateEngineRequest, one DataStore id must be provided as the system + // will use it for necessary initializations. + DataStoreIds []string `json:"dataStoreIds,omitempty"` + + // DisplayName: Required. The display name of the engine. Should be + // human readable. UTF-8 encoded string with limit of 1024 characters. + DisplayName string `json:"displayName,omitempty"` + + // IndustryVertical: The industry vertical that the engine registers. + // The restriction of the Engine industry vertical is based on + // DataStore: If unspecified, default to `GENERIC`. Vertical on Engine + // has to match vertical of the DataStore liniked to the engine. + // + // Possible values: + // "INDUSTRY_VERTICAL_UNSPECIFIED" - Value used when unset. + // "GENERIC" - The generic vertical for documents that are not + // specific to any industry vertical. + // "MEDIA" - The media industry vertical. + IndustryVertical string `json:"industryVertical,omitempty"` + + // Name: Immutable. The fully qualified resource name of the engine. + // This field must be a UTF-8 encoded string with a length limit of 1024 + // characters. Format: + // `projects/{project_number}/locations/{location}/collections/{collectio + // n}/engines/{engine}` engine should be 1-63 characters, and valid + // characters are /a-z0-9*/. Otherwise, an INVALID_ARGUMENT error is + // returned. + Name string `json:"name,omitempty"` + + // SearchEngineConfig: Configurations for the Search Engine. Only + // applicable if solution_type is SOLUTION_TYPE_SEARCH. + SearchEngineConfig *GoogleCloudDiscoveryengineV1betaEngineSearchEngineConfig `json:"searchEngineConfig,omitempty"` + + // SolutionType: Required. The solutions of the engine. + // + // Possible values: + // "SOLUTION_TYPE_UNSPECIFIED" - Default value. + // "SOLUTION_TYPE_RECOMMENDATION" - Used for Recommendations AI. + // "SOLUTION_TYPE_SEARCH" - Used for Discovery Search. + // "SOLUTION_TYPE_CHAT" - Used for use cases related to the Generative + // AI agent. + SolutionType string `json:"solutionType,omitempty"` + + // UpdateTime: Output only. Timestamp the Recommendation Engine was last + // updated. + UpdateTime string `json:"updateTime,omitempty"` + + // ForceSendFields is a list of field names (e.g. "ChatEngineConfig") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -8609,7 +10322,7 @@ type GoogleCloudDiscoveryengineV1alphaWidgetConverseConversationRequest struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "AdditionalParams") to + // NullFields is a list of field names (e.g. "ChatEngineConfig") to // include in API requests with the JSON null value. By default, fields // with empty values are omitted from API requests. However, any field // with an empty value appearing in NullFields will be sent to the @@ -8619,38 +10332,43 @@ type GoogleCloudDiscoveryengineV1alphaWidgetConverseConversationRequest struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaWidgetConverseConversationRequest) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaWidgetConverseConversationRequest +func (s *GoogleCloudDiscoveryengineV1betaEngine) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaEngine raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaWidgetConverseConversationResponse: -// Response message for WidgetService.WidgetConverseConversation method. -type GoogleCloudDiscoveryengineV1alphaWidgetConverseConversationResponse struct { - // ConversationId: The id of the Conversation returned. - ConversationId string `json:"conversationId,omitempty"` - - // ConverseConversationResponse: ConverseConversationResponse returned - // from ConversationalSearchService.ConverseConversation. - ConverseConversationResponse *GoogleCloudDiscoveryengineV1alphaConverseConversationResponse `json:"converseConversationResponse,omitempty"` - - // UToken: The token in response. - UToken string `json:"uToken,omitempty"` +// GoogleCloudDiscoveryengineV1betaEngineChatEngineConfig: +// Configurations for a Chat Engine. +type GoogleCloudDiscoveryengineV1betaEngineChatEngineConfig struct { + // AgentCreationConfig: The configurationt generate the Dialogflow agent + // that is associated to this Engine. Note that these configurations are + // one-time consumed by and passed to Dialogflow service. It means they + // cannot be retrieved using EngineService.GetEngine or + // EngineService.ListEngines API after engine creation. + AgentCreationConfig *GoogleCloudDiscoveryengineV1betaEngineChatEngineConfigAgentCreationConfig `json:"agentCreationConfig,omitempty"` - // ServerResponse contains the HTTP response code and headers from the - // server. - googleapi.ServerResponse `json:"-"` + // DialogflowAgentToLink: The resource name of an exist Dialogflow agent + // to link to this Chat Engine. Customers can either provide + // `agent_creation_config` to create agent or provide an agent name that + // links the agent with the Chat engine. Format: + // `projects//locations//agents/`. Note that the + // `dialogflow_agent_to_link` are one-time consumed by and passed to + // Dialogflow service. It means they cannot be retrieved using + // EngineService.GetEngine or EngineService.ListEngines API after engine + // creation. Please use ChatEngineMetadata.dialogflow_agent for actual + // agent association after Engine is created. + DialogflowAgentToLink string `json:"dialogflowAgentToLink,omitempty"` - // ForceSendFields is a list of field names (e.g. "ConversationId") to - // unconditionally include in API requests. By default, fields with + // ForceSendFields is a list of field names (e.g. "AgentCreationConfig") + // to unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be // sent to the server regardless of whether the field is empty or not. // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "ConversationId") to + // NullFields is a list of field names (e.g. "AgentCreationConfig") to // include in API requests with the JSON null value. By default, fields // with empty values are omitted from API requests. However, any field // with an empty value appearing in NullFields will be sent to the @@ -8660,28 +10378,42 @@ type GoogleCloudDiscoveryengineV1alphaWidgetConverseConversationResponse struct NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaWidgetConverseConversationResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaWidgetConverseConversationResponse +func (s *GoogleCloudDiscoveryengineV1betaEngineChatEngineConfig) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaEngineChatEngineConfig raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaWidgetSearchRequest: Request message -// for WidgetService.WidgetSearch method. -type GoogleCloudDiscoveryengineV1alphaWidgetSearchRequest struct { - // AdditionalParams: Additional params for security and privacy - // enhancement. - AdditionalParams *GoogleCloudDiscoveryengineV1alphaAdditionalParams `json:"additionalParams,omitempty"` +// GoogleCloudDiscoveryengineV1betaEngineChatEngineConfigAgentCreationCon +// fig: Configurations for generating a Dialogflow agent. Note that +// these configurations are one-time consumed by and passed to +// Dialogflow service. It means they cannot be retrieved using +// EngineService.GetEngine or EngineService.ListEngines API after engine +// creation. +type GoogleCloudDiscoveryengineV1betaEngineChatEngineConfigAgentCreationConfig struct { + // Business: Name of the company, organization or other entity that the + // agent represents. Used for knowledge connector LLM prompt and for + // knowledge search. + Business string `json:"business,omitempty"` - // ConfigId: Required. The UUID of the Search WidgetConfig. This field - // is used to identify the search widget configuration, set of models - // used to make the search. - ConfigId string `json:"configId,omitempty"` + // DefaultLanguageCode: Required. The default language of the agent as a + // language tag. See Language Support + // (https://cloud.google.com/dialogflow/docs/reference/language) for a + // list of the currently supported language codes. + DefaultLanguageCode string `json:"defaultLanguageCode,omitempty"` - // SearchRequest: Required. The search request to perform search. - SearchRequest *GoogleCloudDiscoveryengineV1alphaSearchRequest `json:"searchRequest,omitempty"` + // Location: Agent location for Agent creation, supported values: + // global/us/eu. If not provided, us Engine will create Agent using + // us-central-1 by default; eu Engine will create Agent using eu-west-1 + // by default. + Location string `json:"location,omitempty"` - // ForceSendFields is a list of field names (e.g. "AdditionalParams") to + // TimeZone: Required. The time zone of the agent from the time zone + // database (https://www.iana.org/time-zones), e.g., America/New_York, + // Europe/Paris. + TimeZone string `json:"timeZone,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Business") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -8689,36 +10421,29 @@ type GoogleCloudDiscoveryengineV1alphaWidgetSearchRequest struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "AdditionalParams") to - // include in API requests with the JSON null value. By default, fields - // with empty values are omitted from API requests. However, any field - // with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. + // NullFields is a list of field names (e.g. "Business") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaWidgetSearchRequest) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaWidgetSearchRequest +func (s *GoogleCloudDiscoveryengineV1betaEngineChatEngineConfigAgentCreationConfig) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaEngineChatEngineConfigAgentCreationConfig raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaWidgetSearchResponse: Response -// message for WidgetService.WidgetSearch method. -type GoogleCloudDiscoveryengineV1alphaWidgetSearchResponse struct { - // SearchResponse: The search response after performing search. - SearchResponse *GoogleCloudDiscoveryengineV1alphaSearchResponse `json:"searchResponse,omitempty"` - - // UToken: The token in response. - UToken string `json:"uToken,omitempty"` - - // ServerResponse contains the HTTP response code and headers from the - // server. - googleapi.ServerResponse `json:"-"` +// GoogleCloudDiscoveryengineV1betaEngineChatEngineMetadata: Additional +// information of a Chat Engine. Fields in this message are output only. +type GoogleCloudDiscoveryengineV1betaEngineChatEngineMetadata struct { + // DialogflowAgent: The resource name of a Dialogflow agent, that this + // Chat Engine refers to. Format: `projects//locations//agents/`. + DialogflowAgent string `json:"dialogflowAgent,omitempty"` - // ForceSendFields is a list of field names (e.g. "SearchResponse") to + // ForceSendFields is a list of field names (e.g. "DialogflowAgent") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -8726,7 +10451,7 @@ type GoogleCloudDiscoveryengineV1alphaWidgetSearchResponse struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "SearchResponse") to + // NullFields is a list of field names (e.g. "DialogflowAgent") to // include in API requests with the JSON null value. By default, fields // with empty values are omitted from API requests. However, any field // with an empty value appearing in NullFields will be sent to the @@ -8736,23 +10461,21 @@ type GoogleCloudDiscoveryengineV1alphaWidgetSearchResponse struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaWidgetSearchResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaWidgetSearchResponse +func (s *GoogleCloudDiscoveryengineV1betaEngineChatEngineMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaEngineChatEngineMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaCreateSchemaMetadata: Metadata for -// Create Schema LRO. -type GoogleCloudDiscoveryengineV1betaCreateSchemaMetadata 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"` +// GoogleCloudDiscoveryengineV1betaEngineCommonConfig: Common +// configurations for an Engine. +type GoogleCloudDiscoveryengineV1betaEngineCommonConfig struct { + // CompanyName: Immutable. The name of the company, business or entity + // that is associated with the engine. Setting this may help improve LLM + // related features. + CompanyName string `json:"companyName,omitempty"` - // ForceSendFields is a list of field names (e.g. "CreateTime") to + // ForceSendFields is a list of field names (e.g. "CompanyName") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -8760,32 +10483,45 @@ type GoogleCloudDiscoveryengineV1betaCreateSchemaMetadata struct { // This may be used to include empty fields in Patch requests. 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. However, any field with an - // empty value appearing in NullFields will be sent to the server as + // NullFields is a list of field names (e.g. "CompanyName") to include + // in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. However, any field with + // an empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1betaCreateSchemaMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaCreateSchemaMetadata +func (s *GoogleCloudDiscoveryengineV1betaEngineCommonConfig) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaEngineCommonConfig raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaDeleteSchemaMetadata: Metadata for -// DeleteSchema LRO. -type GoogleCloudDiscoveryengineV1betaDeleteSchemaMetadata struct { - // CreateTime: Operation create time. - CreateTime string `json:"createTime,omitempty"` +// GoogleCloudDiscoveryengineV1betaEngineSearchEngineConfig: +// Configurations for a Search Engine. +type GoogleCloudDiscoveryengineV1betaEngineSearchEngineConfig struct { + // SearchAddOns: The add-on that this search engine enables. + // + // Possible values: + // "SEARCH_ADD_ON_UNSPECIFIED" - Default value when the enum is + // unspecified. This is invalid to use. + // "SEARCH_ADD_ON_LLM" - Large language model add-on. + SearchAddOns []string `json:"searchAddOns,omitempty"` - // UpdateTime: Operation last update time. If the operation is done, - // this is also the finish time. - UpdateTime string `json:"updateTime,omitempty"` + // SearchTier: The search feature tier of this engine. Different tiers + // might have different pricing. To learn more, please check the pricing + // documentation. Defaults to SearchTier.SEARCH_TIER_STANDARD if not + // specified. + // + // Possible values: + // "SEARCH_TIER_UNSPECIFIED" - Default value when the enum is + // unspecified. This is invalid to use. + // "SEARCH_TIER_STANDARD" - Standard tier. + // "SEARCH_TIER_ENTERPRISE" - Enterprise tier. + SearchTier string `json:"searchTier,omitempty"` - // ForceSendFields is a list of field names (e.g. "CreateTime") to + // ForceSendFields is a list of field names (e.g. "SearchAddOns") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -8793,17 +10529,17 @@ type GoogleCloudDiscoveryengineV1betaDeleteSchemaMetadata struct { // This may be used to include empty fields in Patch requests. 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. However, any field with an - // empty value appearing in NullFields will be sent to the server as + // NullFields is a list of field names (e.g. "SearchAddOns") to include + // in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. However, any field with + // an empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1betaDeleteSchemaMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaDeleteSchemaMetadata +func (s *GoogleCloudDiscoveryengineV1betaEngineSearchEngineConfig) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaEngineSearchEngineConfig raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } @@ -9264,6 +11000,191 @@ func (s *GoogleCloudDiscoveryengineV1betaSchema) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } +// GoogleCloudDiscoveryengineV1betaSiteVerificationInfo: Verification +// information for target sites in advanced site search. +type GoogleCloudDiscoveryengineV1betaSiteVerificationInfo struct { + // SiteVerificationState: Site verification state indicating the + // ownership and validity. + // + // Possible values: + // "SITE_VERIFICATION_STATE_UNSPECIFIED" - Defaults to VERIFIED. + // "VERIFIED" - Site ownership verified. + // "UNVERIFIED" - Site ownership pending verification or verification + // failed. + // "EXEMPTED" - Site exempt from verification, e.g., a public website + // that opens to all. + SiteVerificationState string `json:"siteVerificationState,omitempty"` + + // VerifyTime: Latest site verification time. + VerifyTime string `json:"verifyTime,omitempty"` + + // ForceSendFields is a list of field names (e.g. + // "SiteVerificationState") to unconditionally include in API requests. + // By default, fields with empty or default values are omitted from API + // requests. However, any non-pointer, non-interface field appearing in + // ForceSendFields will be sent to the server regardless of whether the + // field is empty or not. This may be used to include empty fields in + // Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "SiteVerificationState") to + // include in API requests with the JSON null value. By default, fields + // with empty values are omitted from API requests. However, any field + // with an empty value appearing in NullFields will be sent to the + // server as null. It is an error if a field in this list has a + // non-empty value. This may be used to include null fields in Patch + // requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1betaSiteVerificationInfo) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaSiteVerificationInfo + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1betaTargetSite: A target site for the +// SiteSearchEngine. +type GoogleCloudDiscoveryengineV1betaTargetSite struct { + // ExactMatch: Input only. If set to false, a uri_pattern is generated + // to include all pages whose address contains the provided_uri_pattern. + // If set to true, an uri_pattern is generated to try to be an exact + // match of the provided_uri_pattern or just the specific page if the + // provided_uri_pattern is a specific one. provided_uri_pattern is + // always normalized to generate the URI pattern to be used by the + // search engine. + ExactMatch bool `json:"exactMatch,omitempty"` + + // FailureReason: Output only. Failure reason. + FailureReason *GoogleCloudDiscoveryengineV1betaTargetSiteFailureReason `json:"failureReason,omitempty"` + + // GeneratedUriPattern: Output only. This is system-generated based on + // the provided_uri_pattern. + GeneratedUriPattern string `json:"generatedUriPattern,omitempty"` + + // IndexingStatus: Output only. Indexing status. + // + // Possible values: + // "INDEXING_STATUS_UNSPECIFIED" - Defaults to SUCCEEDED. + // "PENDING" - The target site is in the update queue and will be + // picked up by indexing pipeline. + // "FAILED" - The target site fails to be indexed. + // "SUCCEEDED" - The target site has been indexed. + // "DELETING" - The previously indexed target site has been marked to + // be deleted. This is a transitioning state which will resulted in + // either: 1. target site deleted if unindexing is successful; 2. state + // reverts to SUCCEEDED if the unindexing fails. + IndexingStatus string `json:"indexingStatus,omitempty"` + + // Name: Output only. The fully qualified resource name of the target + // site. + // `projects/{project}/locations/{location}/collections/{collection}/data + // Stores/{data_store}/siteSearchEngine/targetSites/{target_site}` The + // `target_site_id` is system-generated. + Name string `json:"name,omitempty"` + + // ProvidedUriPattern: Required. Input only. The user provided URI + // pattern from which the `generated_uri_pattern` is generated. + ProvidedUriPattern string `json:"providedUriPattern,omitempty"` + + // SiteVerificationInfo: Output only. Site ownership and validity + // verification status. + SiteVerificationInfo *GoogleCloudDiscoveryengineV1betaSiteVerificationInfo `json:"siteVerificationInfo,omitempty"` + + // Type: The type of the target site, e.g., whether the site is to be + // included or excluded. + // + // Possible values: + // "TYPE_UNSPECIFIED" - This value is unused. In this case, server + // behavior defaults to Type.INCLUDE. + // "INCLUDE" - Include the target site. + // "EXCLUDE" - Exclude the target site. + Type string `json:"type,omitempty"` + + // UpdateTime: Output only. The target site's last updated time. + UpdateTime string `json:"updateTime,omitempty"` + + // ForceSendFields is a list of field names (e.g. "ExactMatch") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "ExactMatch") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1betaTargetSite) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaTargetSite + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1betaTargetSiteFailureReason: Site search +// indexing failure reasons. +type GoogleCloudDiscoveryengineV1betaTargetSiteFailureReason struct { + // QuotaFailure: Failed due to insufficient quota. + QuotaFailure *GoogleCloudDiscoveryengineV1betaTargetSiteFailureReasonQuotaFailure `json:"quotaFailure,omitempty"` + + // ForceSendFields is a list of field names (e.g. "QuotaFailure") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "QuotaFailure") to include + // in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. However, any field with + // an empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1betaTargetSiteFailureReason) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaTargetSiteFailureReason + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +type GoogleCloudDiscoveryengineV1betaTargetSiteFailureReasonQuotaFailure struct { + // TotalRequiredQuota: This number is an estimation on how much total + // quota this project needs to successfully complete indexing. + TotalRequiredQuota int64 `json:"totalRequiredQuota,omitempty,string"` + + // ForceSendFields is a list of field names (e.g. "TotalRequiredQuota") + // to unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "TotalRequiredQuota") to + // include in API requests with the JSON null value. By default, fields + // with empty values are omitted from API requests. However, any field + // with an empty value appearing in NullFields will be sent to the + // server as null. It is an error if a field in this list has a + // non-empty value. This may be used to include null fields in Patch + // requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1betaTargetSiteFailureReasonQuotaFailure) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaTargetSiteFailureReasonQuotaFailure + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + // GoogleCloudDiscoveryengineV1betaUpdateSchemaMetadata: Metadata for // UpdateSchema LRO. type GoogleCloudDiscoveryengineV1betaUpdateSchemaMetadata struct { @@ -9297,6 +11218,41 @@ func (s *GoogleCloudDiscoveryengineV1betaUpdateSchemaMetadata) MarshalJSON() ([] return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } +// GoogleCloudDiscoveryengineV1betaUpdateTargetSiteMetadata: Metadata +// related to the progress of the +// SiteSearchEngineService.UpdateTargetSite operation. This will be +// returned by the google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1betaUpdateTargetSiteMetadata 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. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + 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. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1betaUpdateTargetSiteMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaUpdateTargetSiteMetadata + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + // GoogleLongrunningListOperationsResponse: The response message for // Operations.ListOperations. type GoogleLongrunningListOperationsResponse struct { @@ -10625,13 +12581,14 @@ func (c *ProjectsLocationsCollectionsDataStoresCompleteQueryCall) Query(query st return c } -// QueryModel sets the optional parameter "queryModel": Selects data -// model of query suggestions for serving. Currently supported values: * -// `document` - Using suggestions generated from user-imported -// documents. * `search-history` - Using suggestions generated from the -// past history of SearchService.Search API calls. Do not use it when -// there is no traffic for Search API. * `user-event` - Using -// suggestions generated from user-imported search events. * +// QueryModel sets the optional parameter "queryModel": Specifies the +// autocomplete data model. This overrides any model specified in the +// Configuration > Autocomplete section of the Cloud console. Currently +// supported values: * `document` - Using suggestions generated from +// user-imported documents. * `search-history` - Using suggestions +// generated from the past history of SearchService.Search API calls. Do +// not use it when there is no traffic for Search API. * `user-event` - +// Using suggestions generated from user-imported search events. * // `document-completable` - Using suggestions taken directly from // user-imported document fields marked as completable. Default values: // * `document` is the default model for regular dataStores. * @@ -10784,7 +12741,7 @@ func (c *ProjectsLocationsCollectionsDataStoresCompleteQueryCall) Do(opts ...goo // "type": "string" // }, // "queryModel": { - // "description": "Selects data model of query suggestions for serving. Currently supported values: * `document` - Using suggestions generated from user-imported documents. * `search-history` - Using suggestions generated from the past history of SearchService.Search API calls. Do not use it when there is no traffic for Search API. * `user-event` - Using suggestions generated from user-imported search events. * `document-completable` - Using suggestions taken directly from user-imported document fields marked as completable. Default values: * `document` is the default model for regular dataStores. * `search-history` is the default model for site search dataStores.", + // "description": "Specifies the autocomplete data model. This overrides any model specified in the Configuration \u003e Autocomplete section of the Cloud console. Currently supported values: * `document` - Using suggestions generated from user-imported documents. * `search-history` - Using suggestions generated from the past history of SearchService.Search API calls. Do not use it when there is no traffic for Search API. * `user-event` - Using suggestions generated from user-imported search events. * `document-completable` - Using suggestions taken directly from user-imported document fields marked as completable. Default values: * `document` is the default model for regular dataStores. * `search-history` is the default model for site search dataStores.", // "location": "query", // "type": "string" // }, @@ -23579,13 +25536,14 @@ func (c *ProjectsLocationsDataStoresCompleteQueryCall) Query(query string) *Proj return c } -// QueryModel sets the optional parameter "queryModel": Selects data -// model of query suggestions for serving. Currently supported values: * -// `document` - Using suggestions generated from user-imported -// documents. * `search-history` - Using suggestions generated from the -// past history of SearchService.Search API calls. Do not use it when -// there is no traffic for Search API. * `user-event` - Using -// suggestions generated from user-imported search events. * +// QueryModel sets the optional parameter "queryModel": Specifies the +// autocomplete data model. This overrides any model specified in the +// Configuration > Autocomplete section of the Cloud console. Currently +// supported values: * `document` - Using suggestions generated from +// user-imported documents. * `search-history` - Using suggestions +// generated from the past history of SearchService.Search API calls. Do +// not use it when there is no traffic for Search API. * `user-event` - +// Using suggestions generated from user-imported search events. * // `document-completable` - Using suggestions taken directly from // user-imported document fields marked as completable. Default values: // * `document` is the default model for regular dataStores. * @@ -23738,7 +25696,7 @@ func (c *ProjectsLocationsDataStoresCompleteQueryCall) Do(opts ...googleapi.Call // "type": "string" // }, // "queryModel": { - // "description": "Selects data model of query suggestions for serving. Currently supported values: * `document` - Using suggestions generated from user-imported documents. * `search-history` - Using suggestions generated from the past history of SearchService.Search API calls. Do not use it when there is no traffic for Search API. * `user-event` - Using suggestions generated from user-imported search events. * `document-completable` - Using suggestions taken directly from user-imported document fields marked as completable. Default values: * `document` is the default model for regular dataStores. * `search-history` is the default model for site search dataStores.", + // "description": "Specifies the autocomplete data model. This overrides any model specified in the Configuration \u003e Autocomplete section of the Cloud console. Currently supported values: * `document` - Using suggestions generated from user-imported documents. * `search-history` - Using suggestions generated from the past history of SearchService.Search API calls. Do not use it when there is no traffic for Search API. * `user-event` - Using suggestions generated from user-imported search events. * `document-completable` - Using suggestions taken directly from user-imported document fields marked as completable. Default values: * `document` is the default model for regular dataStores. * `search-history` is the default model for site search dataStores.", // "location": "query", // "type": "string" // }, diff --git a/discoveryengine/v1beta/discoveryengine-api.json b/discoveryengine/v1beta/discoveryengine-api.json index 94bf0b75c5b..097de550bb1 100644 --- a/discoveryengine/v1beta/discoveryengine-api.json +++ b/discoveryengine/v1beta/discoveryengine-api.json @@ -214,7 +214,7 @@ "type": "string" }, "queryModel": { - "description": "Selects data model of query suggestions for serving. Currently supported values: * `document` - Using suggestions generated from user-imported documents. * `search-history` - Using suggestions generated from the past history of SearchService.Search API calls. Do not use it when there is no traffic for Search API. * `user-event` - Using suggestions generated from user-imported search events. * `document-completable` - Using suggestions taken directly from user-imported document fields marked as completable. Default values: * `document` is the default model for regular dataStores. * `search-history` is the default model for site search dataStores.", + "description": "Specifies the autocomplete data model. This overrides any model specified in the Configuration \u003e Autocomplete section of the Cloud console. Currently supported values: * `document` - Using suggestions generated from user-imported documents. * `search-history` - Using suggestions generated from the past history of SearchService.Search API calls. Do not use it when there is no traffic for Search API. * `user-event` - Using suggestions generated from user-imported search events. * `document-completable` - Using suggestions taken directly from user-imported document fields marked as completable. Default values: * `document` is the default model for regular dataStores. * `search-history` is the default model for site search dataStores.", "location": "query", "type": "string" }, @@ -231,6 +231,194 @@ "scopes": [ "https://www.googleapis.com/auth/cloud-platform" ] + }, + "create": { + "description": "Creates a DataStore. DataStore is for storing Documents. To serve these documents for Search, or Recommendation use case, an Engine needs to be created separately.", + "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores", + "httpMethod": "POST", + "id": "discoveryengine.projects.locations.collections.dataStores.create", + "parameterOrder": [ + "parent" + ], + "parameters": { + "createAdvancedSiteSearch": { + "description": "A boolean flag indicating whether user want to directly create an advanced data store for site search. If the data store is not configured as site search (GENERIC vertical and PUBLIC_WEBSITE content_config), this flag will be ignored.", + "location": "query", + "type": "boolean" + }, + "dataStoreId": { + "description": "Required. The ID to use for the DataStore, which will become the final component of the DataStore's resource name. This field must conform to [RFC-1034](https://tools.ietf.org/html/rfc1034) standard with a length limit of 63 characters. Otherwise, an INVALID_ARGUMENT error is returned.", + "location": "query", + "type": "string" + }, + "parent": { + "description": "Required. The parent resource name, such as `projects/{project}/locations/{location}/collections/{collection}`.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1beta/{+parent}/dataStores", + "request": { + "$ref": "GoogleCloudDiscoveryengineV1betaDataStore" + }, + "response": { + "$ref": "GoogleLongrunningOperation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "delete": { + "description": "Deletes a DataStore.", + "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}", + "httpMethod": "DELETE", + "id": "discoveryengine.projects.locations.collections.dataStores.delete", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Required. Full resource name of DataStore, such as `projects/{project}/locations/{location}/collections/{collection_id}/dataStores/{data_store_id}`. If the caller does not have permission to delete the DataStore, regardless of whether or not it exists, a PERMISSION_DENIED error is returned. If the DataStore to delete does not exist, a NOT_FOUND error is returned.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1beta/{+name}", + "response": { + "$ref": "GoogleLongrunningOperation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "get": { + "description": "Gets a DataStore.", + "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}", + "httpMethod": "GET", + "id": "discoveryengine.projects.locations.collections.dataStores.get", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Required. Full resource name of DataStore, such as `projects/{project}/locations/{location}/collections/{collection_id}/dataStores/{data_store_id}`. If the caller does not have permission to access the DataStore, regardless of whether or not it exists, a PERMISSION_DENIED error is returned. If the requested DataStore does not exist, a NOT_FOUND error is returned.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1beta/{+name}", + "response": { + "$ref": "GoogleCloudDiscoveryengineV1betaDataStore" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "getSiteSearchEngine": { + "description": "Gets the SiteSearchEngine.", + "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/siteSearchEngine", + "httpMethod": "GET", + "id": "discoveryengine.projects.locations.collections.dataStores.getSiteSearchEngine", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Required. Resource name of SiteSearchEngine, such as `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/siteSearchEngine`. If the caller does not have permission to access the [SiteSearchEngine], regardless of whether or not it exists, a PERMISSION_DENIED error is returned.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/siteSearchEngine$", + "required": true, + "type": "string" + } + }, + "path": "v1beta/{+name}", + "response": { + "$ref": "GoogleCloudDiscoveryengineV1betaSiteSearchEngine" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "list": { + "description": "Lists all the DataStores associated with the project.", + "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores", + "httpMethod": "GET", + "id": "discoveryengine.projects.locations.collections.dataStores.list", + "parameterOrder": [ + "parent" + ], + "parameters": { + "filter": { + "description": "Filter by solution type. For example: filter = 'solution_type:SOLUTION_TYPE_SEARCH'", + "location": "query", + "type": "string" + }, + "pageSize": { + "description": "Maximum number of DataStores to return. If unspecified, defaults to 10. The maximum allowed value is 50. Values above 50 will be coerced to 50. If this field is negative, an INVALID_ARGUMENT is returned.", + "format": "int32", + "location": "query", + "type": "integer" + }, + "pageToken": { + "description": "A page token ListDataStoresResponse.next_page_token, received from a previous DataStoreService.ListDataStores call. Provide this to retrieve the subsequent page. When paginating, all other parameters provided to DataStoreService.ListDataStores must match the call that provided the page token. Otherwise, an INVALID_ARGUMENT error is returned.", + "location": "query", + "type": "string" + }, + "parent": { + "description": "Required. The parent branch resource name, such as `projects/{project}/locations/{location}/collections/{collection_id}`. If the caller does not have permission to list DataStores under this location, regardless of whether or not this data store exists, a PERMISSION_DENIED error is returned.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1beta/{+parent}/dataStores", + "response": { + "$ref": "GoogleCloudDiscoveryengineV1betaListDataStoresResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "patch": { + "description": "Updates a DataStore", + "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}", + "httpMethod": "PATCH", + "id": "discoveryengine.projects.locations.collections.dataStores.patch", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Immutable. The full resource name of the data store. Format: `projects/{project}/locations/{location}/collections/{collection_id}/dataStores/{data_store_id}`. This field must be a UTF-8 encoded string with a length limit of 1024 characters.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+$", + "required": true, + "type": "string" + }, + "updateMask": { + "description": "Indicates which fields in the provided DataStore to update. If an unsupported or unknown field is provided, an INVALID_ARGUMENT error is returned.", + "format": "google-fieldmask", + "location": "query", + "type": "string" + } + }, + "path": "v1beta/{+name}", + "request": { + "$ref": "GoogleCloudDiscoveryengineV1betaDataStore" + }, + "response": { + "$ref": "GoogleCloudDiscoveryengineV1betaDataStore" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] } }, "resources": { @@ -1143,6 +1331,156 @@ } }, "siteSearchEngine": { + "methods": { + "batchVerifyTargetSites": { + "description": "Verify target sites' ownership and validity. This API sends all the target sites under site search engine for verification.", + "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/siteSearchEngine:batchVerifyTargetSites", + "httpMethod": "POST", + "id": "discoveryengine.projects.locations.collections.dataStores.siteSearchEngine.batchVerifyTargetSites", + "parameterOrder": [ + "parent" + ], + "parameters": { + "parent": { + "description": "Required. The parent resource shared by all TargetSites being verified. `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/siteSearchEngine`.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/siteSearchEngine$", + "required": true, + "type": "string" + } + }, + "path": "v1beta/{+parent}:batchVerifyTargetSites", + "request": { + "$ref": "GoogleCloudDiscoveryengineV1betaBatchVerifyTargetSitesRequest" + }, + "response": { + "$ref": "GoogleLongrunningOperation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "disableAdvancedSiteSearch": { + "description": "Downgrade from advanced site search to basic site search.", + "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/siteSearchEngine:disableAdvancedSiteSearch", + "httpMethod": "POST", + "id": "discoveryengine.projects.locations.collections.dataStores.siteSearchEngine.disableAdvancedSiteSearch", + "parameterOrder": [ + "siteSearchEngine" + ], + "parameters": { + "siteSearchEngine": { + "description": "Required. Full resource name of the SiteSearchEngine, such as `projects/{project}/locations/{location}/dataStores/{data_store_id}/siteSearchEngine`.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/siteSearchEngine$", + "required": true, + "type": "string" + } + }, + "path": "v1beta/{+siteSearchEngine}:disableAdvancedSiteSearch", + "request": { + "$ref": "GoogleCloudDiscoveryengineV1betaDisableAdvancedSiteSearchRequest" + }, + "response": { + "$ref": "GoogleLongrunningOperation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "enableAdvancedSiteSearch": { + "description": "Upgrade from basic site search to advanced site search.", + "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/siteSearchEngine:enableAdvancedSiteSearch", + "httpMethod": "POST", + "id": "discoveryengine.projects.locations.collections.dataStores.siteSearchEngine.enableAdvancedSiteSearch", + "parameterOrder": [ + "siteSearchEngine" + ], + "parameters": { + "siteSearchEngine": { + "description": "Required. Full resource name of the SiteSearchEngine, such as `projects/{project}/locations/{location}/dataStores/{data_store_id}/siteSearchEngine`.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/siteSearchEngine$", + "required": true, + "type": "string" + } + }, + "path": "v1beta/{+siteSearchEngine}:enableAdvancedSiteSearch", + "request": { + "$ref": "GoogleCloudDiscoveryengineV1betaEnableAdvancedSiteSearchRequest" + }, + "response": { + "$ref": "GoogleLongrunningOperation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "fetchDomainVerificationStatus": { + "description": "Returns list of target sites with its domain verification status. This method can only be called under data store with BASIC_SITE_SEARCH state at the moment.", + "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/siteSearchEngine:fetchDomainVerificationStatus", + "httpMethod": "GET", + "id": "discoveryengine.projects.locations.collections.dataStores.siteSearchEngine.fetchDomainVerificationStatus", + "parameterOrder": [ + "siteSearchEngine" + ], + "parameters": { + "pageSize": { + "description": "Requested page size. Server may return fewer items than requested. If unspecified, server will pick an appropriate default. The maximum value is 1000; values above 1000 will be coerced to 1000. If this field is negative, an INVALID_ARGUMENT error is returned.", + "format": "int32", + "location": "query", + "type": "integer" + }, + "pageToken": { + "description": "A page token, received from a previous `FetchDomainVerificationStatus` call. Provide this to retrieve the subsequent page. When paginating, all other parameters provided to `FetchDomainVerificationStatus` must match the call that provided the page token.", + "location": "query", + "type": "string" + }, + "siteSearchEngine": { + "description": "Required. The site search engine resource under which we fetch all the domain verification status. `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/siteSearchEngine`.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/siteSearchEngine$", + "required": true, + "type": "string" + } + }, + "path": "v1beta/{+siteSearchEngine}:fetchDomainVerificationStatus", + "response": { + "$ref": "GoogleCloudDiscoveryengineV1betaFetchDomainVerificationStatusResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "recrawlUris": { + "description": "Request on-demand recrawl for a list of URIs.", + "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/siteSearchEngine:recrawlUris", + "httpMethod": "POST", + "id": "discoveryengine.projects.locations.collections.dataStores.siteSearchEngine.recrawlUris", + "parameterOrder": [ + "siteSearchEngine" + ], + "parameters": { + "siteSearchEngine": { + "description": "Required. Full resource name of the SiteSearchEngine, such as `projects/*/locations/*/collections/*/dataStores/*/siteSearchEngine`.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/siteSearchEngine$", + "required": true, + "type": "string" + } + }, + "path": "v1beta/{+siteSearchEngine}:recrawlUris", + "request": { + "$ref": "GoogleCloudDiscoveryengineV1betaRecrawlUrisRequest" + }, + "response": { + "$ref": "GoogleLongrunningOperation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + } + }, "resources": { "operations": { "methods": { @@ -1215,16 +1553,188 @@ } }, "targetSites": { - "resources": { - "operations": { - "methods": { - "get": { - "description": "Gets the latest state of a long-running operation. Clients can use this method to poll the operation result at intervals as recommended by the API service.", - "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/siteSearchEngine/targetSites/operations/{operationsId}", - "httpMethod": "GET", - "id": "discoveryengine.projects.locations.collections.dataStores.siteSearchEngine.targetSites.operations.get", - "parameterOrder": [ - "name" + "methods": { + "batchCreate": { + "description": "Creates TargetSite in a batch.", + "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/siteSearchEngine/targetSites:batchCreate", + "httpMethod": "POST", + "id": "discoveryengine.projects.locations.collections.dataStores.siteSearchEngine.targetSites.batchCreate", + "parameterOrder": [ + "parent" + ], + "parameters": { + "parent": { + "description": "Required. The parent resource shared by all TargetSites being created. `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/siteSearchEngine`. The parent field in the CreateBookRequest messages must either be empty or match this field.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/siteSearchEngine$", + "required": true, + "type": "string" + } + }, + "path": "v1beta/{+parent}/targetSites:batchCreate", + "request": { + "$ref": "GoogleCloudDiscoveryengineV1betaBatchCreateTargetSitesRequest" + }, + "response": { + "$ref": "GoogleLongrunningOperation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "create": { + "description": "Creates a TargetSite.", + "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/siteSearchEngine/targetSites", + "httpMethod": "POST", + "id": "discoveryengine.projects.locations.collections.dataStores.siteSearchEngine.targetSites.create", + "parameterOrder": [ + "parent" + ], + "parameters": { + "parent": { + "description": "Required. Parent resource name of TargetSite, such as `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/siteSearchEngine`.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/siteSearchEngine$", + "required": true, + "type": "string" + } + }, + "path": "v1beta/{+parent}/targetSites", + "request": { + "$ref": "GoogleCloudDiscoveryengineV1betaTargetSite" + }, + "response": { + "$ref": "GoogleLongrunningOperation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "delete": { + "description": "Deletes a TargetSite.", + "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/siteSearchEngine/targetSites/{targetSitesId}", + "httpMethod": "DELETE", + "id": "discoveryengine.projects.locations.collections.dataStores.siteSearchEngine.targetSites.delete", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Required. Full resource name of TargetSite, such as `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/siteSearchEngine/targetSites/{target_site}`. If the caller does not have permission to access the TargetSite, regardless of whether or not it exists, a PERMISSION_DENIED error is returned. If the requested TargetSite does not exist, a NOT_FOUND error is returned.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/siteSearchEngine/targetSites/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1beta/{+name}", + "response": { + "$ref": "GoogleLongrunningOperation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "get": { + "description": "Gets a TargetSite.", + "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/siteSearchEngine/targetSites/{targetSitesId}", + "httpMethod": "GET", + "id": "discoveryengine.projects.locations.collections.dataStores.siteSearchEngine.targetSites.get", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Required. Full resource name of TargetSite, such as `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/siteSearchEngine/targetSites/{target_site}`. If the caller does not have permission to access the TargetSite, regardless of whether or not it exists, a PERMISSION_DENIED error is returned. If the requested TargetSite does not exist, a NOT_FOUND error is returned.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/siteSearchEngine/targetSites/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1beta/{+name}", + "response": { + "$ref": "GoogleCloudDiscoveryengineV1betaTargetSite" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "list": { + "description": "Gets a list of TargetSites.", + "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/siteSearchEngine/targetSites", + "httpMethod": "GET", + "id": "discoveryengine.projects.locations.collections.dataStores.siteSearchEngine.targetSites.list", + "parameterOrder": [ + "parent" + ], + "parameters": { + "pageSize": { + "description": "Requested page size. Server may return fewer items than requested. If unspecified, server will pick an appropriate default. The maximum value is 1000; values above 1000 will be coerced to 1000. If this field is negative, an INVALID_ARGUMENT error is returned.", + "format": "int32", + "location": "query", + "type": "integer" + }, + "pageToken": { + "description": "A page token, received from a previous `ListTargetSites` call. Provide this to retrieve the subsequent page. When paginating, all other parameters provided to `ListTargetSites` must match the call that provided the page token.", + "location": "query", + "type": "string" + }, + "parent": { + "description": "Required. The parent site search engine resource name, such as `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/siteSearchEngine`. If the caller does not have permission to list TargetSites under this site search engine, regardless of whether or not this branch exists, a PERMISSION_DENIED error is returned.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/siteSearchEngine$", + "required": true, + "type": "string" + } + }, + "path": "v1beta/{+parent}/targetSites", + "response": { + "$ref": "GoogleCloudDiscoveryengineV1betaListTargetSitesResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "patch": { + "description": "Updates a TargetSite.", + "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/siteSearchEngine/targetSites/{targetSitesId}", + "httpMethod": "PATCH", + "id": "discoveryengine.projects.locations.collections.dataStores.siteSearchEngine.targetSites.patch", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Output only. The fully qualified resource name of the target site. `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/siteSearchEngine/targetSites/{target_site}` The `target_site_id` is system-generated.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/siteSearchEngine/targetSites/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1beta/{+name}", + "request": { + "$ref": "GoogleCloudDiscoveryengineV1betaTargetSite" + }, + "response": { + "$ref": "GoogleLongrunningOperation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + } + }, + "resources": { + "operations": { + "methods": { + "get": { + "description": "Gets the latest state of a long-running operation. Clients can use this method to poll the operation result at intervals as recommended by the API service.", + "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/siteSearchEngine/targetSites/operations/{operationsId}", + "httpMethod": "GET", + "id": "discoveryengine.projects.locations.collections.dataStores.siteSearchEngine.targetSites.operations.get", + "parameterOrder": [ + "name" ], "parameters": { "name": { @@ -1454,110 +1964,270 @@ } }, "engines": { - "resources": { - "conversations": { - "methods": { - "converse": { - "description": "Converses a conversation.", - "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/engines/{enginesId}/conversations/{conversationsId}:converse", - "httpMethod": "POST", - "id": "discoveryengine.projects.locations.collections.engines.conversations.converse", - "parameterOrder": [ - "name" - ], - "parameters": { - "name": { - "description": "Required. The resource name of the Conversation to get. Format: `projects/{project_number}/locations/{location_id}/collections/{collection}/dataStores/{data_store_id}/conversations/{conversation_id}`. Use `projects/{project_number}/locations/{location_id}/collections/{collection}/dataStores/{data_store_id}/conversations/-` to activate auto session mode, which automatically creates a new conversation inside a ConverseConversation session.", - "location": "path", - "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/engines/[^/]+/conversations/[^/]+$", - "required": true, - "type": "string" - } - }, - "path": "v1beta/{+name}:converse", - "request": { - "$ref": "GoogleCloudDiscoveryengineV1betaConverseConversationRequest" - }, - "response": { - "$ref": "GoogleCloudDiscoveryengineV1betaConverseConversationResponse" - }, - "scopes": [ - "https://www.googleapis.com/auth/cloud-platform" - ] - }, - "create": { - "description": "Creates a Conversation. If the Conversation to create already exists, an ALREADY_EXISTS error is returned.", - "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/engines/{enginesId}/conversations", - "httpMethod": "POST", - "id": "discoveryengine.projects.locations.collections.engines.conversations.create", - "parameterOrder": [ - "parent" - ], - "parameters": { - "parent": { - "description": "Required. Full resource name of parent data store. Format: `projects/{project_number}/locations/{location_id}/collections/{collection}/dataStores/{data_store_id}`", - "location": "path", - "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/engines/[^/]+$", - "required": true, - "type": "string" - } - }, - "path": "v1beta/{+parent}/conversations", - "request": { - "$ref": "GoogleCloudDiscoveryengineV1betaConversation" - }, - "response": { - "$ref": "GoogleCloudDiscoveryengineV1betaConversation" - }, - "scopes": [ - "https://www.googleapis.com/auth/cloud-platform" - ] - }, - "delete": { - "description": "Deletes a Conversation. If the Conversation to delete does not exist, a NOT_FOUND error is returned.", - "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/engines/{enginesId}/conversations/{conversationsId}", - "httpMethod": "DELETE", - "id": "discoveryengine.projects.locations.collections.engines.conversations.delete", - "parameterOrder": [ - "name" - ], - "parameters": { - "name": { - "description": "Required. The resource name of the Conversation to delete. Format: `projects/{project_number}/locations/{location_id}/collections/{collection}/dataStores/{data_store_id}/conversations/{conversation_id}`", - "location": "path", - "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/engines/[^/]+/conversations/[^/]+$", - "required": true, - "type": "string" - } - }, - "path": "v1beta/{+name}", - "response": { - "$ref": "GoogleProtobufEmpty" - }, - "scopes": [ - "https://www.googleapis.com/auth/cloud-platform" - ] + "methods": { + "create": { + "description": "Creates a Engine.", + "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/engines", + "httpMethod": "POST", + "id": "discoveryengine.projects.locations.collections.engines.create", + "parameterOrder": [ + "parent" + ], + "parameters": { + "engineId": { + "description": "Required. The ID to use for the Engine, which will become the final component of the Engine's resource name. This field must conform to [RFC-1034](https://tools.ietf.org/html/rfc1034) standard with a length limit of 63 characters. Otherwise, an INVALID_ARGUMENT error is returned.", + "location": "query", + "type": "string" }, - "get": { - "description": "Gets a Conversation.", - "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/engines/{enginesId}/conversations/{conversationsId}", - "httpMethod": "GET", - "id": "discoveryengine.projects.locations.collections.engines.conversations.get", - "parameterOrder": [ - "name" - ], - "parameters": { - "name": { - "description": "Required. The resource name of the Conversation to get. Format: `projects/{project_number}/locations/{location_id}/collections/{collection}/dataStores/{data_store_id}/conversations/{conversation_id}`", - "location": "path", - "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/engines/[^/]+/conversations/[^/]+$", - "required": true, - "type": "string" - } - }, - "path": "v1beta/{+name}", - "response": { - "$ref": "GoogleCloudDiscoveryengineV1betaConversation" + "parent": { + "description": "Required. The parent resource name, such as `projects/{project}/locations/{location}/collections/{collection}`.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1beta/{+parent}/engines", + "request": { + "$ref": "GoogleCloudDiscoveryengineV1betaEngine" + }, + "response": { + "$ref": "GoogleLongrunningOperation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "delete": { + "description": "Deletes a Engine.", + "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/engines/{enginesId}", + "httpMethod": "DELETE", + "id": "discoveryengine.projects.locations.collections.engines.delete", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Required. Full resource name of Engine, such as `projects/{project}/locations/{location}/collections/{collection_id}/engines/{engine_id}`. If the caller does not have permission to delete the Engine, regardless of whether or not it exists, a PERMISSION_DENIED error is returned. If the Engine to delete does not exist, a NOT_FOUND error is returned.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/engines/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1beta/{+name}", + "response": { + "$ref": "GoogleLongrunningOperation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "get": { + "description": "Gets a Engine.", + "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/engines/{enginesId}", + "httpMethod": "GET", + "id": "discoveryengine.projects.locations.collections.engines.get", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Required. Full resource name of Engine, such as `projects/{project}/locations/{location}/collections/{collection_id}/engines/{engine_id}`.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/engines/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1beta/{+name}", + "response": { + "$ref": "GoogleCloudDiscoveryengineV1betaEngine" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "list": { + "description": "Lists all the Engines associated with the project.", + "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/engines", + "httpMethod": "GET", + "id": "discoveryengine.projects.locations.collections.engines.list", + "parameterOrder": [ + "parent" + ], + "parameters": { + "filter": { + "description": "Optional. Filter by solution type. For example: solution_type=SOLUTION_TYPE_SEARCH", + "location": "query", + "type": "string" + }, + "pageSize": { + "description": "Optional. Not supported.", + "format": "int32", + "location": "query", + "type": "integer" + }, + "pageToken": { + "description": "Optional. Not supported.", + "location": "query", + "type": "string" + }, + "parent": { + "description": "Required. The parent resource name, such as `projects/{project}/locations/{location}/collections/{collection_id}`.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1beta/{+parent}/engines", + "response": { + "$ref": "GoogleCloudDiscoveryengineV1betaListEnginesResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "patch": { + "description": "Updates an Engine", + "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/engines/{enginesId}", + "httpMethod": "PATCH", + "id": "discoveryengine.projects.locations.collections.engines.patch", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Immutable. The fully qualified resource name of the engine. This field must be a UTF-8 encoded string with a length limit of 1024 characters. Format: `projects/{project_number}/locations/{location}/collections/{collection}/engines/{engine}` engine should be 1-63 characters, and valid characters are /a-z0-9*/. Otherwise, an INVALID_ARGUMENT error is returned.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/engines/[^/]+$", + "required": true, + "type": "string" + }, + "updateMask": { + "description": "Indicates which fields in the provided Engine to update. If an unsupported or unknown field is provided, an INVALID_ARGUMENT error is returned.", + "format": "google-fieldmask", + "location": "query", + "type": "string" + } + }, + "path": "v1beta/{+name}", + "request": { + "$ref": "GoogleCloudDiscoveryengineV1betaEngine" + }, + "response": { + "$ref": "GoogleCloudDiscoveryengineV1betaEngine" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + } + }, + "resources": { + "conversations": { + "methods": { + "converse": { + "description": "Converses a conversation.", + "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/engines/{enginesId}/conversations/{conversationsId}:converse", + "httpMethod": "POST", + "id": "discoveryengine.projects.locations.collections.engines.conversations.converse", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Required. The resource name of the Conversation to get. Format: `projects/{project_number}/locations/{location_id}/collections/{collection}/dataStores/{data_store_id}/conversations/{conversation_id}`. Use `projects/{project_number}/locations/{location_id}/collections/{collection}/dataStores/{data_store_id}/conversations/-` to activate auto session mode, which automatically creates a new conversation inside a ConverseConversation session.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/engines/[^/]+/conversations/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1beta/{+name}:converse", + "request": { + "$ref": "GoogleCloudDiscoveryengineV1betaConverseConversationRequest" + }, + "response": { + "$ref": "GoogleCloudDiscoveryengineV1betaConverseConversationResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "create": { + "description": "Creates a Conversation. If the Conversation to create already exists, an ALREADY_EXISTS error is returned.", + "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/engines/{enginesId}/conversations", + "httpMethod": "POST", + "id": "discoveryengine.projects.locations.collections.engines.conversations.create", + "parameterOrder": [ + "parent" + ], + "parameters": { + "parent": { + "description": "Required. Full resource name of parent data store. Format: `projects/{project_number}/locations/{location_id}/collections/{collection}/dataStores/{data_store_id}`", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/engines/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1beta/{+parent}/conversations", + "request": { + "$ref": "GoogleCloudDiscoveryengineV1betaConversation" + }, + "response": { + "$ref": "GoogleCloudDiscoveryengineV1betaConversation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "delete": { + "description": "Deletes a Conversation. If the Conversation to delete does not exist, a NOT_FOUND error is returned.", + "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/engines/{enginesId}/conversations/{conversationsId}", + "httpMethod": "DELETE", + "id": "discoveryengine.projects.locations.collections.engines.conversations.delete", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Required. The resource name of the Conversation to delete. Format: `projects/{project_number}/locations/{location_id}/collections/{collection}/dataStores/{data_store_id}/conversations/{conversation_id}`", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/engines/[^/]+/conversations/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1beta/{+name}", + "response": { + "$ref": "GoogleProtobufEmpty" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "get": { + "description": "Gets a Conversation.", + "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/engines/{enginesId}/conversations/{conversationsId}", + "httpMethod": "GET", + "id": "discoveryengine.projects.locations.collections.engines.conversations.get", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Required. The resource name of the Conversation to get. Format: `projects/{project_number}/locations/{location_id}/collections/{collection}/dataStores/{data_store_id}/conversations/{conversation_id}`", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/engines/[^/]+/conversations/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1beta/{+name}", + "response": { + "$ref": "GoogleCloudDiscoveryengineV1betaConversation" }, "scopes": [ "https://www.googleapis.com/auth/cloud-platform" @@ -1878,7 +2548,7 @@ "type": "string" }, "queryModel": { - "description": "Selects data model of query suggestions for serving. Currently supported values: * `document` - Using suggestions generated from user-imported documents. * `search-history` - Using suggestions generated from the past history of SearchService.Search API calls. Do not use it when there is no traffic for Search API. * `user-event` - Using suggestions generated from user-imported search events. * `document-completable` - Using suggestions taken directly from user-imported document fields marked as completable. Default values: * `document` is the default model for regular dataStores. * `search-history` is the default model for site search dataStores.", + "description": "Specifies the autocomplete data model. This overrides any model specified in the Configuration \u003e Autocomplete section of the Cloud console. Currently supported values: * `document` - Using suggestions generated from user-imported documents. * `search-history` - Using suggestions generated from the past history of SearchService.Search API calls. Do not use it when there is no traffic for Search API. * `user-event` - Using suggestions generated from user-imported search events. * `document-completable` - Using suggestions taken directly from user-imported document fields marked as completable. Default values: * `document` is the default model for regular dataStores. * `search-history` is the default model for site search dataStores.", "location": "query", "type": "string" }, @@ -1895,44 +2565,232 @@ "scopes": [ "https://www.googleapis.com/auth/cloud-platform" ] - } - }, - "resources": { - "branches": { - "resources": { - "documents": { - "methods": { - "create": { - "description": "Creates a Document.", - "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/branches/{branchesId}/documents", - "httpMethod": "POST", - "id": "discoveryengine.projects.locations.dataStores.branches.documents.create", - "parameterOrder": [ - "parent" - ], - "parameters": { - "documentId": { - "description": "Required. The ID to use for the Document, which will become the final component of the Document.name. If the caller does not have permission to create the Document, regardless of whether or not it exists, a `PERMISSION_DENIED` error is returned. This field must be unique among all Documents with the same parent. Otherwise, an `ALREADY_EXISTS` error is returned. This field must conform to [RFC-1034](https://tools.ietf.org/html/rfc1034) standard with a length limit of 63 characters. Otherwise, an `INVALID_ARGUMENT` error is returned.", - "location": "query", - "type": "string" - }, - "parent": { - "description": "Required. The parent resource name, such as `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/branches/{branch}`.", - "location": "path", - "pattern": "^projects/[^/]+/locations/[^/]+/dataStores/[^/]+/branches/[^/]+$", - "required": true, - "type": "string" - } - }, - "path": "v1beta/{+parent}/documents", - "request": { - "$ref": "GoogleCloudDiscoveryengineV1betaDocument" - }, - "response": { - "$ref": "GoogleCloudDiscoveryengineV1betaDocument" - }, - "scopes": [ - "https://www.googleapis.com/auth/cloud-platform" + }, + "create": { + "description": "Creates a DataStore. DataStore is for storing Documents. To serve these documents for Search, or Recommendation use case, an Engine needs to be created separately.", + "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores", + "httpMethod": "POST", + "id": "discoveryengine.projects.locations.dataStores.create", + "parameterOrder": [ + "parent" + ], + "parameters": { + "createAdvancedSiteSearch": { + "description": "A boolean flag indicating whether user want to directly create an advanced data store for site search. If the data store is not configured as site search (GENERIC vertical and PUBLIC_WEBSITE content_config), this flag will be ignored.", + "location": "query", + "type": "boolean" + }, + "dataStoreId": { + "description": "Required. The ID to use for the DataStore, which will become the final component of the DataStore's resource name. This field must conform to [RFC-1034](https://tools.ietf.org/html/rfc1034) standard with a length limit of 63 characters. Otherwise, an INVALID_ARGUMENT error is returned.", + "location": "query", + "type": "string" + }, + "parent": { + "description": "Required. The parent resource name, such as `projects/{project}/locations/{location}/collections/{collection}`.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1beta/{+parent}/dataStores", + "request": { + "$ref": "GoogleCloudDiscoveryengineV1betaDataStore" + }, + "response": { + "$ref": "GoogleLongrunningOperation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "delete": { + "description": "Deletes a DataStore.", + "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}", + "httpMethod": "DELETE", + "id": "discoveryengine.projects.locations.dataStores.delete", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Required. Full resource name of DataStore, such as `projects/{project}/locations/{location}/collections/{collection_id}/dataStores/{data_store_id}`. If the caller does not have permission to delete the DataStore, regardless of whether or not it exists, a PERMISSION_DENIED error is returned. If the DataStore to delete does not exist, a NOT_FOUND error is returned.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/dataStores/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1beta/{+name}", + "response": { + "$ref": "GoogleLongrunningOperation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "get": { + "description": "Gets a DataStore.", + "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}", + "httpMethod": "GET", + "id": "discoveryengine.projects.locations.dataStores.get", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Required. Full resource name of DataStore, such as `projects/{project}/locations/{location}/collections/{collection_id}/dataStores/{data_store_id}`. If the caller does not have permission to access the DataStore, regardless of whether or not it exists, a PERMISSION_DENIED error is returned. If the requested DataStore does not exist, a NOT_FOUND error is returned.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/dataStores/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1beta/{+name}", + "response": { + "$ref": "GoogleCloudDiscoveryengineV1betaDataStore" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "getSiteSearchEngine": { + "description": "Gets the SiteSearchEngine.", + "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/siteSearchEngine", + "httpMethod": "GET", + "id": "discoveryengine.projects.locations.dataStores.getSiteSearchEngine", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Required. Resource name of SiteSearchEngine, such as `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/siteSearchEngine`. If the caller does not have permission to access the [SiteSearchEngine], regardless of whether or not it exists, a PERMISSION_DENIED error is returned.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/dataStores/[^/]+/siteSearchEngine$", + "required": true, + "type": "string" + } + }, + "path": "v1beta/{+name}", + "response": { + "$ref": "GoogleCloudDiscoveryengineV1betaSiteSearchEngine" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "list": { + "description": "Lists all the DataStores associated with the project.", + "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores", + "httpMethod": "GET", + "id": "discoveryengine.projects.locations.dataStores.list", + "parameterOrder": [ + "parent" + ], + "parameters": { + "filter": { + "description": "Filter by solution type. For example: filter = 'solution_type:SOLUTION_TYPE_SEARCH'", + "location": "query", + "type": "string" + }, + "pageSize": { + "description": "Maximum number of DataStores to return. If unspecified, defaults to 10. The maximum allowed value is 50. Values above 50 will be coerced to 50. If this field is negative, an INVALID_ARGUMENT is returned.", + "format": "int32", + "location": "query", + "type": "integer" + }, + "pageToken": { + "description": "A page token ListDataStoresResponse.next_page_token, received from a previous DataStoreService.ListDataStores call. Provide this to retrieve the subsequent page. When paginating, all other parameters provided to DataStoreService.ListDataStores must match the call that provided the page token. Otherwise, an INVALID_ARGUMENT error is returned.", + "location": "query", + "type": "string" + }, + "parent": { + "description": "Required. The parent branch resource name, such as `projects/{project}/locations/{location}/collections/{collection_id}`. If the caller does not have permission to list DataStores under this location, regardless of whether or not this data store exists, a PERMISSION_DENIED error is returned.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1beta/{+parent}/dataStores", + "response": { + "$ref": "GoogleCloudDiscoveryengineV1betaListDataStoresResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "patch": { + "description": "Updates a DataStore", + "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}", + "httpMethod": "PATCH", + "id": "discoveryengine.projects.locations.dataStores.patch", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Immutable. The full resource name of the data store. Format: `projects/{project}/locations/{location}/collections/{collection_id}/dataStores/{data_store_id}`. This field must be a UTF-8 encoded string with a length limit of 1024 characters.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/dataStores/[^/]+$", + "required": true, + "type": "string" + }, + "updateMask": { + "description": "Indicates which fields in the provided DataStore to update. If an unsupported or unknown field is provided, an INVALID_ARGUMENT error is returned.", + "format": "google-fieldmask", + "location": "query", + "type": "string" + } + }, + "path": "v1beta/{+name}", + "request": { + "$ref": "GoogleCloudDiscoveryengineV1betaDataStore" + }, + "response": { + "$ref": "GoogleCloudDiscoveryengineV1betaDataStore" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + } + }, + "resources": { + "branches": { + "resources": { + "documents": { + "methods": { + "create": { + "description": "Creates a Document.", + "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/branches/{branchesId}/documents", + "httpMethod": "POST", + "id": "discoveryengine.projects.locations.dataStores.branches.documents.create", + "parameterOrder": [ + "parent" + ], + "parameters": { + "documentId": { + "description": "Required. The ID to use for the Document, which will become the final component of the Document.name. If the caller does not have permission to create the Document, regardless of whether or not it exists, a `PERMISSION_DENIED` error is returned. This field must be unique among all Documents with the same parent. Otherwise, an `ALREADY_EXISTS` error is returned. This field must conform to [RFC-1034](https://tools.ietf.org/html/rfc1034) standard with a length limit of 63 characters. Otherwise, an `INVALID_ARGUMENT` error is returned.", + "location": "query", + "type": "string" + }, + "parent": { + "description": "Required. The parent resource name, such as `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/branches/{branch}`.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/dataStores/[^/]+/branches/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1beta/{+parent}/documents", + "request": { + "$ref": "GoogleCloudDiscoveryengineV1betaDocument" + }, + "response": { + "$ref": "GoogleCloudDiscoveryengineV1betaDocument" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" ] }, "delete": { @@ -2734,28 +3592,28 @@ } } }, - "suggestionDenyListEntries": { + "siteSearchEngine": { "methods": { - "import": { - "description": "Imports all SuggestionDenyListEntry for a DataStore.", - "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/suggestionDenyListEntries:import", + "disableAdvancedSiteSearch": { + "description": "Downgrade from advanced site search to basic site search.", + "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/siteSearchEngine:disableAdvancedSiteSearch", "httpMethod": "POST", - "id": "discoveryengine.projects.locations.dataStores.suggestionDenyListEntries.import", + "id": "discoveryengine.projects.locations.dataStores.siteSearchEngine.disableAdvancedSiteSearch", "parameterOrder": [ - "parent" + "siteSearchEngine" ], "parameters": { - "parent": { - "description": "Required. The parent data store resource name for which to import denylist entries. Follows pattern projects/*/locations/*/collections/*/dataStores/*.", + "siteSearchEngine": { + "description": "Required. Full resource name of the SiteSearchEngine, such as `projects/{project}/locations/{location}/dataStores/{data_store_id}/siteSearchEngine`.", "location": "path", - "pattern": "^projects/[^/]+/locations/[^/]+/dataStores/[^/]+$", + "pattern": "^projects/[^/]+/locations/[^/]+/dataStores/[^/]+/siteSearchEngine$", "required": true, "type": "string" } }, - "path": "v1beta/{+parent}/suggestionDenyListEntries:import", + "path": "v1beta/{+siteSearchEngine}:disableAdvancedSiteSearch", "request": { - "$ref": "GoogleCloudDiscoveryengineV1betaImportSuggestionDenyListEntriesRequest" + "$ref": "GoogleCloudDiscoveryengineV1betaDisableAdvancedSiteSearchRequest" }, "response": { "$ref": "GoogleLongrunningOperation" @@ -2764,26 +3622,26 @@ "https://www.googleapis.com/auth/cloud-platform" ] }, - "purge": { - "description": "Permanently deletes all SuggestionDenyListEntry for a DataStore.", - "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/suggestionDenyListEntries:purge", + "enableAdvancedSiteSearch": { + "description": "Upgrade from basic site search to advanced site search.", + "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/siteSearchEngine:enableAdvancedSiteSearch", "httpMethod": "POST", - "id": "discoveryengine.projects.locations.dataStores.suggestionDenyListEntries.purge", + "id": "discoveryengine.projects.locations.dataStores.siteSearchEngine.enableAdvancedSiteSearch", "parameterOrder": [ - "parent" + "siteSearchEngine" ], "parameters": { - "parent": { - "description": "Required. The parent data store resource name for which to import denylist entries. Follows pattern projects/*/locations/*/collections/*/dataStores/*.", + "siteSearchEngine": { + "description": "Required. Full resource name of the SiteSearchEngine, such as `projects/{project}/locations/{location}/dataStores/{data_store_id}/siteSearchEngine`.", "location": "path", - "pattern": "^projects/[^/]+/locations/[^/]+/dataStores/.*$", + "pattern": "^projects/[^/]+/locations/[^/]+/dataStores/[^/]+/siteSearchEngine$", "required": true, "type": "string" } }, - "path": "v1beta/{+parent}/suggestionDenyListEntries:purge", + "path": "v1beta/{+siteSearchEngine}:enableAdvancedSiteSearch", "request": { - "$ref": "GoogleCloudDiscoveryengineV1betaPurgeSuggestionDenyListEntriesRequest" + "$ref": "GoogleCloudDiscoveryengineV1betaEnableAdvancedSiteSearchRequest" }, "response": { "$ref": "GoogleLongrunningOperation" @@ -2791,72 +3649,27 @@ "scopes": [ "https://www.googleapis.com/auth/cloud-platform" ] - } - } - }, - "userEvents": { - "methods": { - "collect": { - "description": "Writes a single user event from the browser. This uses a GET request to due to browser restriction of POST-ing to a third-party domain. This method is used only by the Discovery Engine API JavaScript pixel and Google Tag Manager. Users should not call this method directly.", - "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/userEvents:collect", - "httpMethod": "GET", - "id": "discoveryengine.projects.locations.dataStores.userEvents.collect", - "parameterOrder": [ - "parent" - ], - "parameters": { - "ets": { - "description": "The event timestamp in milliseconds. This prevents browser caching of otherwise identical get requests. The name is abbreviated to reduce the payload bytes.", - "format": "int64", - "location": "query", - "type": "string" - }, - "parent": { - "description": "Required. The parent DataStore resource name, such as `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}`.", - "location": "path", - "pattern": "^projects/[^/]+/locations/[^/]+/dataStores/[^/]+$", - "required": true, - "type": "string" - }, - "uri": { - "description": "The URL including cgi-parameters but excluding the hash fragment with a length limit of 5,000 characters. This is often more useful than the referer URL, because many browsers only send the domain for third-party requests.", - "location": "query", - "type": "string" - }, - "userEvent": { - "description": "Required. URL encoded UserEvent proto with a length limit of 2,000,000 characters.", - "location": "query", - "type": "string" - } - }, - "path": "v1beta/{+parent}/userEvents:collect", - "response": { - "$ref": "GoogleApiHttpBody" - }, - "scopes": [ - "https://www.googleapis.com/auth/cloud-platform" - ] }, - "import": { - "description": "Bulk import of User events. Request processing might be synchronous. Events that already exist are skipped. Use this method for backfilling historical user events. Operation.response is of type ImportResponse. Note that it is possible for a subset of the items to be successfully inserted. Operation.metadata is of type ImportMetadata.", - "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/userEvents:import", + "recrawlUris": { + "description": "Request on-demand recrawl for a list of URIs.", + "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/siteSearchEngine:recrawlUris", "httpMethod": "POST", - "id": "discoveryengine.projects.locations.dataStores.userEvents.import", + "id": "discoveryengine.projects.locations.dataStores.siteSearchEngine.recrawlUris", "parameterOrder": [ - "parent" + "siteSearchEngine" ], "parameters": { - "parent": { - "description": "Required. Parent DataStore resource name, of the form `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}`", + "siteSearchEngine": { + "description": "Required. Full resource name of the SiteSearchEngine, such as `projects/*/locations/*/collections/*/dataStores/*/siteSearchEngine`.", "location": "path", - "pattern": "^projects/[^/]+/locations/[^/]+/dataStores/[^/]+$", + "pattern": "^projects/[^/]+/locations/[^/]+/dataStores/[^/]+/siteSearchEngine$", "required": true, "type": "string" } }, - "path": "v1beta/{+parent}/userEvents:import", + "path": "v1beta/{+siteSearchEngine}:recrawlUris", "request": { - "$ref": "GoogleCloudDiscoveryengineV1betaImportUserEventsRequest" + "$ref": "GoogleCloudDiscoveryengineV1betaRecrawlUrisRequest" }, "response": { "$ref": "GoogleLongrunningOperation" @@ -2864,16 +3677,325 @@ "scopes": [ "https://www.googleapis.com/auth/cloud-platform" ] - }, - "write": { - "description": "Writes a single user event.", - "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/userEvents:write", - "httpMethod": "POST", - "id": "discoveryengine.projects.locations.dataStores.userEvents.write", - "parameterOrder": [ - "parent" - ], - "parameters": { + } + }, + "resources": { + "targetSites": { + "methods": { + "batchCreate": { + "description": "Creates TargetSite in a batch.", + "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/siteSearchEngine/targetSites:batchCreate", + "httpMethod": "POST", + "id": "discoveryengine.projects.locations.dataStores.siteSearchEngine.targetSites.batchCreate", + "parameterOrder": [ + "parent" + ], + "parameters": { + "parent": { + "description": "Required. The parent resource shared by all TargetSites being created. `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/siteSearchEngine`. The parent field in the CreateBookRequest messages must either be empty or match this field.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/dataStores/[^/]+/siteSearchEngine$", + "required": true, + "type": "string" + } + }, + "path": "v1beta/{+parent}/targetSites:batchCreate", + "request": { + "$ref": "GoogleCloudDiscoveryengineV1betaBatchCreateTargetSitesRequest" + }, + "response": { + "$ref": "GoogleLongrunningOperation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "create": { + "description": "Creates a TargetSite.", + "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/siteSearchEngine/targetSites", + "httpMethod": "POST", + "id": "discoveryengine.projects.locations.dataStores.siteSearchEngine.targetSites.create", + "parameterOrder": [ + "parent" + ], + "parameters": { + "parent": { + "description": "Required. Parent resource name of TargetSite, such as `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/siteSearchEngine`.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/dataStores/[^/]+/siteSearchEngine$", + "required": true, + "type": "string" + } + }, + "path": "v1beta/{+parent}/targetSites", + "request": { + "$ref": "GoogleCloudDiscoveryengineV1betaTargetSite" + }, + "response": { + "$ref": "GoogleLongrunningOperation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "delete": { + "description": "Deletes a TargetSite.", + "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/siteSearchEngine/targetSites/{targetSitesId}", + "httpMethod": "DELETE", + "id": "discoveryengine.projects.locations.dataStores.siteSearchEngine.targetSites.delete", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Required. Full resource name of TargetSite, such as `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/siteSearchEngine/targetSites/{target_site}`. If the caller does not have permission to access the TargetSite, regardless of whether or not it exists, a PERMISSION_DENIED error is returned. If the requested TargetSite does not exist, a NOT_FOUND error is returned.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/dataStores/[^/]+/siteSearchEngine/targetSites/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1beta/{+name}", + "response": { + "$ref": "GoogleLongrunningOperation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "get": { + "description": "Gets a TargetSite.", + "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/siteSearchEngine/targetSites/{targetSitesId}", + "httpMethod": "GET", + "id": "discoveryengine.projects.locations.dataStores.siteSearchEngine.targetSites.get", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Required. Full resource name of TargetSite, such as `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/siteSearchEngine/targetSites/{target_site}`. If the caller does not have permission to access the TargetSite, regardless of whether or not it exists, a PERMISSION_DENIED error is returned. If the requested TargetSite does not exist, a NOT_FOUND error is returned.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/dataStores/[^/]+/siteSearchEngine/targetSites/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1beta/{+name}", + "response": { + "$ref": "GoogleCloudDiscoveryengineV1betaTargetSite" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "list": { + "description": "Gets a list of TargetSites.", + "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/siteSearchEngine/targetSites", + "httpMethod": "GET", + "id": "discoveryengine.projects.locations.dataStores.siteSearchEngine.targetSites.list", + "parameterOrder": [ + "parent" + ], + "parameters": { + "pageSize": { + "description": "Requested page size. Server may return fewer items than requested. If unspecified, server will pick an appropriate default. The maximum value is 1000; values above 1000 will be coerced to 1000. If this field is negative, an INVALID_ARGUMENT error is returned.", + "format": "int32", + "location": "query", + "type": "integer" + }, + "pageToken": { + "description": "A page token, received from a previous `ListTargetSites` call. Provide this to retrieve the subsequent page. When paginating, all other parameters provided to `ListTargetSites` must match the call that provided the page token.", + "location": "query", + "type": "string" + }, + "parent": { + "description": "Required. The parent site search engine resource name, such as `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/siteSearchEngine`. If the caller does not have permission to list TargetSites under this site search engine, regardless of whether or not this branch exists, a PERMISSION_DENIED error is returned.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/dataStores/[^/]+/siteSearchEngine$", + "required": true, + "type": "string" + } + }, + "path": "v1beta/{+parent}/targetSites", + "response": { + "$ref": "GoogleCloudDiscoveryengineV1betaListTargetSitesResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "patch": { + "description": "Updates a TargetSite.", + "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/siteSearchEngine/targetSites/{targetSitesId}", + "httpMethod": "PATCH", + "id": "discoveryengine.projects.locations.dataStores.siteSearchEngine.targetSites.patch", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Output only. The fully qualified resource name of the target site. `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/siteSearchEngine/targetSites/{target_site}` The `target_site_id` is system-generated.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/dataStores/[^/]+/siteSearchEngine/targetSites/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1beta/{+name}", + "request": { + "$ref": "GoogleCloudDiscoveryengineV1betaTargetSite" + }, + "response": { + "$ref": "GoogleLongrunningOperation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + } + } + } + } + }, + "suggestionDenyListEntries": { + "methods": { + "import": { + "description": "Imports all SuggestionDenyListEntry for a DataStore.", + "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/suggestionDenyListEntries:import", + "httpMethod": "POST", + "id": "discoveryengine.projects.locations.dataStores.suggestionDenyListEntries.import", + "parameterOrder": [ + "parent" + ], + "parameters": { + "parent": { + "description": "Required. The parent data store resource name for which to import denylist entries. Follows pattern projects/*/locations/*/collections/*/dataStores/*.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/dataStores/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1beta/{+parent}/suggestionDenyListEntries:import", + "request": { + "$ref": "GoogleCloudDiscoveryengineV1betaImportSuggestionDenyListEntriesRequest" + }, + "response": { + "$ref": "GoogleLongrunningOperation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "purge": { + "description": "Permanently deletes all SuggestionDenyListEntry for a DataStore.", + "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/suggestionDenyListEntries:purge", + "httpMethod": "POST", + "id": "discoveryengine.projects.locations.dataStores.suggestionDenyListEntries.purge", + "parameterOrder": [ + "parent" + ], + "parameters": { + "parent": { + "description": "Required. The parent data store resource name for which to import denylist entries. Follows pattern projects/*/locations/*/collections/*/dataStores/*.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/dataStores/.*$", + "required": true, + "type": "string" + } + }, + "path": "v1beta/{+parent}/suggestionDenyListEntries:purge", + "request": { + "$ref": "GoogleCloudDiscoveryengineV1betaPurgeSuggestionDenyListEntriesRequest" + }, + "response": { + "$ref": "GoogleLongrunningOperation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + } + } + }, + "userEvents": { + "methods": { + "collect": { + "description": "Writes a single user event from the browser. This uses a GET request to due to browser restriction of POST-ing to a third-party domain. This method is used only by the Discovery Engine API JavaScript pixel and Google Tag Manager. Users should not call this method directly.", + "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/userEvents:collect", + "httpMethod": "GET", + "id": "discoveryengine.projects.locations.dataStores.userEvents.collect", + "parameterOrder": [ + "parent" + ], + "parameters": { + "ets": { + "description": "The event timestamp in milliseconds. This prevents browser caching of otherwise identical get requests. The name is abbreviated to reduce the payload bytes.", + "format": "int64", + "location": "query", + "type": "string" + }, + "parent": { + "description": "Required. The parent DataStore resource name, such as `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}`.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/dataStores/[^/]+$", + "required": true, + "type": "string" + }, + "uri": { + "description": "The URL including cgi-parameters but excluding the hash fragment with a length limit of 5,000 characters. This is often more useful than the referer URL, because many browsers only send the domain for third-party requests.", + "location": "query", + "type": "string" + }, + "userEvent": { + "description": "Required. URL encoded UserEvent proto with a length limit of 2,000,000 characters.", + "location": "query", + "type": "string" + } + }, + "path": "v1beta/{+parent}/userEvents:collect", + "response": { + "$ref": "GoogleApiHttpBody" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "import": { + "description": "Bulk import of User events. Request processing might be synchronous. Events that already exist are skipped. Use this method for backfilling historical user events. Operation.response is of type ImportResponse. Note that it is possible for a subset of the items to be successfully inserted. Operation.metadata is of type ImportMetadata.", + "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/userEvents:import", + "httpMethod": "POST", + "id": "discoveryengine.projects.locations.dataStores.userEvents.import", + "parameterOrder": [ + "parent" + ], + "parameters": { + "parent": { + "description": "Required. Parent DataStore resource name, of the form `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}`", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/dataStores/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1beta/{+parent}/userEvents:import", + "request": { + "$ref": "GoogleCloudDiscoveryengineV1betaImportUserEventsRequest" + }, + "response": { + "$ref": "GoogleLongrunningOperation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "write": { + "description": "Writes a single user event.", + "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/userEvents:write", + "httpMethod": "POST", + "id": "discoveryengine.projects.locations.dataStores.userEvents.write", + "parameterOrder": [ + "parent" + ], + "parameters": { "parent": { "description": "Required. The parent DataStore resource name, such as `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}`.", "location": "path", @@ -3039,187 +4161,618 @@ } } } - } - } - }, - "revision": "20240111", - "rootUrl": "https://discoveryengine.googleapis.com/", - "schemas": { - "GoogleApiHttpBody": { - "description": "Message that represents an arbitrary HTTP body. It should only be used for payload formats that can't be represented as JSON, such as raw binary or an HTML page. This message can be used both in streaming and non-streaming API methods in the request as well as the response. It can be used as a top-level request field, which is convenient if one wants to extract parameters from either the URL or HTTP template into the request fields and also want access to the raw HTTP body. Example: message GetResourceRequest { // A unique request id. string request_id = 1; // The raw HTTP body is bound to this field. google.api.HttpBody http_body = 2; } service ResourceService { rpc GetResource(GetResourceRequest) returns (google.api.HttpBody); rpc UpdateResource(google.api.HttpBody) returns (google.protobuf.Empty); } Example with streaming methods: service CaldavService { rpc GetCalendar(stream google.api.HttpBody) returns (stream google.api.HttpBody); rpc UpdateCalendar(stream google.api.HttpBody) returns (stream google.api.HttpBody); } Use of this type only changes how the request and response bodies are handled, all other features will continue to work unchanged.", - "id": "GoogleApiHttpBody", + } + } + }, + "revision": "20240118", + "rootUrl": "https://discoveryengine.googleapis.com/", + "schemas": { + "GoogleApiHttpBody": { + "description": "Message that represents an arbitrary HTTP body. It should only be used for payload formats that can't be represented as JSON, such as raw binary or an HTML page. This message can be used both in streaming and non-streaming API methods in the request as well as the response. It can be used as a top-level request field, which is convenient if one wants to extract parameters from either the URL or HTTP template into the request fields and also want access to the raw HTTP body. Example: message GetResourceRequest { // A unique request id. string request_id = 1; // The raw HTTP body is bound to this field. google.api.HttpBody http_body = 2; } service ResourceService { rpc GetResource(GetResourceRequest) returns (google.api.HttpBody); rpc UpdateResource(google.api.HttpBody) returns (google.protobuf.Empty); } Example with streaming methods: service CaldavService { rpc GetCalendar(stream google.api.HttpBody) returns (stream google.api.HttpBody); rpc UpdateCalendar(stream google.api.HttpBody) returns (stream google.api.HttpBody); } Use of this type only changes how the request and response bodies are handled, all other features will continue to work unchanged.", + "id": "GoogleApiHttpBody", + "properties": { + "contentType": { + "description": "The HTTP Content-Type header value specifying the content type of the body.", + "type": "string" + }, + "data": { + "description": "The HTTP request/response body as raw binary.", + "format": "byte", + "type": "string" + }, + "extensions": { + "description": "Application specific response metadata. Must be set in the first response for streaming APIs.", + "items": { + "additionalProperties": { + "description": "Properties of the object. Contains field @type with type URL.", + "type": "any" + }, + "type": "object" + }, + "type": "array" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineLoggingErrorContext": { + "description": "A description of the context in which an error occurred.", + "id": "GoogleCloudDiscoveryengineLoggingErrorContext", + "properties": { + "httpRequest": { + "$ref": "GoogleCloudDiscoveryengineLoggingHttpRequestContext", + "description": "The HTTP request which was processed when the error was triggered." + }, + "reportLocation": { + "$ref": "GoogleCloudDiscoveryengineLoggingSourceLocation", + "description": "The location in the source code where the decision was made to report the error, usually the place where it was logged." + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineLoggingErrorLog": { + "description": "An error log which is reported to the Error Reporting system.", + "id": "GoogleCloudDiscoveryengineLoggingErrorLog", + "properties": { + "context": { + "$ref": "GoogleCloudDiscoveryengineLoggingErrorContext", + "description": "A description of the context in which the error occurred." + }, + "importPayload": { + "$ref": "GoogleCloudDiscoveryengineLoggingImportErrorContext", + "description": "The error payload that is populated on LRO import APIs." + }, + "message": { + "description": "A message describing the error.", + "type": "string" + }, + "requestPayload": { + "additionalProperties": { + "description": "Properties of the object.", + "type": "any" + }, + "description": "The API request payload, represented as a protocol buffer. Most API request types are supported—for example: * `type.googleapis.com/google.cloud.discoveryengine.v1alpha.DocumentService.CreateDocumentRequest` * `type.googleapis.com/google.cloud.discoveryengine.v1alpha.UserEventService.WriteUserEventRequest`", + "type": "object" + }, + "responsePayload": { + "additionalProperties": { + "description": "Properties of the object.", + "type": "any" + }, + "description": "The API response payload, represented as a protocol buffer. This is used to log some \"soft errors\", where the response is valid but we consider there are some quality issues like unjoined events. The following API responses are supported, and no PII is included: * `google.cloud.discoveryengine.v1alpha.RecommendationService.Recommend` * `google.cloud.discoveryengine.v1alpha.UserEventService.WriteUserEvent` * `google.cloud.discoveryengine.v1alpha.UserEventService.CollectUserEvent`", + "type": "object" + }, + "serviceContext": { + "$ref": "GoogleCloudDiscoveryengineLoggingServiceContext", + "description": "The service context in which this error has occurred." + }, + "status": { + "$ref": "GoogleRpcStatus", + "description": "The RPC status associated with the error log." + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineLoggingHttpRequestContext": { + "description": "HTTP request data that is related to a reported error.", + "id": "GoogleCloudDiscoveryengineLoggingHttpRequestContext", + "properties": { + "responseStatusCode": { + "description": "The HTTP response status code for the request.", + "format": "int32", + "type": "integer" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineLoggingImportErrorContext": { + "description": "The error payload that is populated on LRO import APIs, including the following: * `google.cloud.discoveryengine.v1alpha.DocumentService.ImportDocuments` * `google.cloud.discoveryengine.v1alpha.UserEventService.ImportUserEvents`", + "id": "GoogleCloudDiscoveryengineLoggingImportErrorContext", + "properties": { + "document": { + "description": "The detailed content which caused the error on importing a document.", + "type": "string" + }, + "gcsPath": { + "description": "Google Cloud Storage file path of the import source. Can be set for batch operation error.", + "type": "string" + }, + "lineNumber": { + "description": "Line number of the content in file. Should be empty for permission or batch operation error.", + "type": "string" + }, + "operation": { + "description": "The operation resource name of the LRO.", + "type": "string" + }, + "userEvent": { + "description": "The detailed content which caused the error on importing a user event.", + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineLoggingServiceContext": { + "description": "Describes a running service that sends errors.", + "id": "GoogleCloudDiscoveryengineLoggingServiceContext", + "properties": { + "service": { + "description": "An identifier of the service—for example, `discoveryengine.googleapis.com`.", + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineLoggingSourceLocation": { + "description": "Indicates a location in the source code of the service for which errors are reported.", + "id": "GoogleCloudDiscoveryengineLoggingSourceLocation", + "properties": { + "functionName": { + "description": "Human-readable name of a function or method—for example, `google.cloud.discoveryengine.v1alpha.RecommendationService.Recommend`.", + "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", + "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" + }, + "GoogleCloudDiscoveryengineV1BatchCreateTargetSitesResponse": { + "description": "Response message for SiteSearchEngineService.BatchCreateTargetSites method.", + "id": "GoogleCloudDiscoveryengineV1BatchCreateTargetSitesResponse", + "properties": { + "targetSites": { + "description": "TargetSites created.", + "items": { + "$ref": "GoogleCloudDiscoveryengineV1TargetSite" + }, + "type": "array" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1CreateDataStoreMetadata": { + "description": "Metadata related to the progress of the DataStoreService.CreateDataStore operation. This will be returned by the google.longrunning.Operation.metadata field.", + "id": "GoogleCloudDiscoveryengineV1CreateDataStoreMetadata", + "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" + }, + "GoogleCloudDiscoveryengineV1CreateEngineMetadata": { + "description": "Metadata related to the progress of the EngineService.CreateEngine operation. This will be returned by the google.longrunning.Operation.metadata field.", + "id": "GoogleCloudDiscoveryengineV1CreateEngineMetadata", + "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" + }, + "GoogleCloudDiscoveryengineV1CreateSchemaMetadata": { + "description": "Metadata for Create Schema LRO.", + "id": "GoogleCloudDiscoveryengineV1CreateSchemaMetadata", + "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" + }, + "GoogleCloudDiscoveryengineV1CreateTargetSiteMetadata": { + "description": "Metadata related to the progress of the SiteSearchEngineService.CreateTargetSite operation. This will be returned by the google.longrunning.Operation.metadata field.", + "id": "GoogleCloudDiscoveryengineV1CreateTargetSiteMetadata", "properties": { - "contentType": { - "description": "The HTTP Content-Type header value specifying the content type of the body.", + "createTime": { + "description": "Operation create time.", + "format": "google-datetime", "type": "string" }, - "data": { - "description": "The HTTP request/response body as raw binary.", - "format": "byte", + "updateTime": { + "description": "Operation last update time. If the operation is done, this is also the finish time.", + "format": "google-datetime", + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1DataStore": { + "description": "DataStore captures global settings and configs at the DataStore level.", + "id": "GoogleCloudDiscoveryengineV1DataStore", + "properties": { + "contentConfig": { + "description": "Immutable. The content config of the data store. If this field is unset, the server behavior defaults to ContentConfig.NO_CONTENT.", + "enum": [ + "CONTENT_CONFIG_UNSPECIFIED", + "NO_CONTENT", + "CONTENT_REQUIRED", + "PUBLIC_WEBSITE" + ], + "enumDescriptions": [ + "Default value.", + "Only contains documents without any Document.content.", + "Only contains documents with Document.content.", + "The data store is used for public website search." + ], "type": "string" }, - "extensions": { - "description": "Application specific response metadata. Must be set in the first response for streaming APIs.", + "createTime": { + "description": "Output only. Timestamp the DataStore was created at.", + "format": "google-datetime", + "readOnly": true, + "type": "string" + }, + "defaultSchemaId": { + "description": "Output only. The id of the default Schema asscociated to this data store.", + "readOnly": true, + "type": "string" + }, + "displayName": { + "description": "Required. The data store display name. This field must be a UTF-8 encoded string with a length limit of 128 characters. Otherwise, an INVALID_ARGUMENT error is returned.", + "type": "string" + }, + "industryVertical": { + "description": "Immutable. The industry vertical that the data store registers.", + "enum": [ + "INDUSTRY_VERTICAL_UNSPECIFIED", + "GENERIC", + "MEDIA" + ], + "enumDescriptions": [ + "Value used when unset.", + "The generic vertical for documents that are not specific to any industry vertical.", + "The media industry vertical." + ], + "type": "string" + }, + "name": { + "description": "Immutable. The full resource name of the data store. Format: `projects/{project}/locations/{location}/collections/{collection_id}/dataStores/{data_store_id}`. This field must be a UTF-8 encoded string with a length limit of 1024 characters.", + "type": "string" + }, + "solutionTypes": { + "description": "The solutions that the data store enrolls. Available solutions for each industry_vertical: * `MEDIA`: `SOLUTION_TYPE_RECOMMENDATION` and `SOLUTION_TYPE_SEARCH`. * `SITE_SEARCH`: `SOLUTION_TYPE_SEARCH` is automatically enrolled. Other solutions cannot be enrolled.", "items": { - "additionalProperties": { - "description": "Properties of the object. Contains field @type with type URL.", - "type": "any" - }, - "type": "object" + "enum": [ + "SOLUTION_TYPE_UNSPECIFIED", + "SOLUTION_TYPE_RECOMMENDATION", + "SOLUTION_TYPE_SEARCH", + "SOLUTION_TYPE_CHAT" + ], + "enumDescriptions": [ + "Default value.", + "Used for Recommendations AI.", + "Used for Discovery Search.", + "Used for use cases related to the Generative AI agent." + ], + "type": "string" }, "type": "array" } }, "type": "object" }, - "GoogleCloudDiscoveryengineLoggingErrorContext": { - "description": "A description of the context in which an error occurred.", - "id": "GoogleCloudDiscoveryengineLoggingErrorContext", + "GoogleCloudDiscoveryengineV1DeleteDataStoreMetadata": { + "description": "Metadata related to the progress of the DataStoreService.DeleteDataStore operation. This will be returned by the google.longrunning.Operation.metadata field.", + "id": "GoogleCloudDiscoveryengineV1DeleteDataStoreMetadata", "properties": { - "httpRequest": { - "$ref": "GoogleCloudDiscoveryengineLoggingHttpRequestContext", - "description": "The HTTP request which was processed when the error was triggered." + "createTime": { + "description": "Operation create time.", + "format": "google-datetime", + "type": "string" }, - "reportLocation": { - "$ref": "GoogleCloudDiscoveryengineLoggingSourceLocation", - "description": "The location in the source code where the decision was made to report the error, usually the place where it was logged." + "updateTime": { + "description": "Operation last update time. If the operation is done, this is also the finish time.", + "format": "google-datetime", + "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineLoggingErrorLog": { - "description": "An error log which is reported to the Error Reporting system.", - "id": "GoogleCloudDiscoveryengineLoggingErrorLog", + "GoogleCloudDiscoveryengineV1DeleteEngineMetadata": { + "description": "Metadata related to the progress of the EngineService.DeleteEngine operation. This will be returned by the google.longrunning.Operation.metadata field.", + "id": "GoogleCloudDiscoveryengineV1DeleteEngineMetadata", "properties": { - "context": { - "$ref": "GoogleCloudDiscoveryengineLoggingErrorContext", - "description": "A description of the context in which the error occurred." + "createTime": { + "description": "Operation create time.", + "format": "google-datetime", + "type": "string" }, - "importPayload": { - "$ref": "GoogleCloudDiscoveryengineLoggingImportErrorContext", - "description": "The error payload that is populated on LRO import APIs." + "updateTime": { + "description": "Operation last update time. If the operation is done, this is also the finish time.", + "format": "google-datetime", + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1DeleteSchemaMetadata": { + "description": "Metadata for DeleteSchema LRO.", + "id": "GoogleCloudDiscoveryengineV1DeleteSchemaMetadata", + "properties": { + "createTime": { + "description": "Operation create time.", + "format": "google-datetime", + "type": "string" }, - "message": { - "description": "A message describing the error.", + "updateTime": { + "description": "Operation last update time. If the operation is done, this is also the finish time.", + "format": "google-datetime", + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1DeleteTargetSiteMetadata": { + "description": "Metadata related to the progress of the SiteSearchEngineService.DeleteTargetSite operation. This will be returned by the google.longrunning.Operation.metadata field.", + "id": "GoogleCloudDiscoveryengineV1DeleteTargetSiteMetadata", + "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" + }, + "GoogleCloudDiscoveryengineV1DisableAdvancedSiteSearchMetadata": { + "description": "Metadata related to the progress of the SiteSearchEngineService.DisableAdvancedSiteSearch operation. This will be returned by the google.longrunning.Operation.metadata field.", + "id": "GoogleCloudDiscoveryengineV1DisableAdvancedSiteSearchMetadata", + "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" + }, + "GoogleCloudDiscoveryengineV1DisableAdvancedSiteSearchResponse": { + "description": "Response message for SiteSearchEngineService.DisableAdvancedSiteSearch method.", + "id": "GoogleCloudDiscoveryengineV1DisableAdvancedSiteSearchResponse", + "properties": {}, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1EnableAdvancedSiteSearchMetadata": { + "description": "Metadata related to the progress of the SiteSearchEngineService.EnableAdvancedSiteSearch operation. This will be returned by the google.longrunning.Operation.metadata field.", + "id": "GoogleCloudDiscoveryengineV1EnableAdvancedSiteSearchMetadata", + "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" + }, + "GoogleCloudDiscoveryengineV1EnableAdvancedSiteSearchResponse": { + "description": "Response message for SiteSearchEngineService.EnableAdvancedSiteSearch method.", + "id": "GoogleCloudDiscoveryengineV1EnableAdvancedSiteSearchResponse", + "properties": {}, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1Engine": { + "description": "Metadata that describes the training and serving parameters of an Engine.", + "id": "GoogleCloudDiscoveryengineV1Engine", + "properties": { + "chatEngineConfig": { + "$ref": "GoogleCloudDiscoveryengineV1EngineChatEngineConfig", + "description": "Configurations for the Chat Engine. Only applicable if solution_type is SOLUTION_TYPE_CHAT." + }, + "chatEngineMetadata": { + "$ref": "GoogleCloudDiscoveryengineV1EngineChatEngineMetadata", + "description": "Output only. Additional information of the Chat Engine. Only applicable if solution_type is SOLUTION_TYPE_CHAT.", + "readOnly": true + }, + "commonConfig": { + "$ref": "GoogleCloudDiscoveryengineV1EngineCommonConfig", + "description": "Common config spec that specifies the metadata of the engine." + }, + "createTime": { + "description": "Output only. Timestamp the Recommendation Engine was created at.", + "format": "google-datetime", + "readOnly": true, + "type": "string" + }, + "dataStoreIds": { + "description": "The data stores associated with this engine. For SOLUTION_TYPE_SEARCH and SOLUTION_TYPE_RECOMMENDATION type of engines, they can only associate with at most one data store. If solution_type is SOLUTION_TYPE_CHAT, multiple DataStores in the same Collection can be associated here. Note that when used in CreateEngineRequest, one DataStore id must be provided as the system will use it for necessary initializations.", + "items": { + "type": "string" + }, + "type": "array" + }, + "displayName": { + "description": "Required. The display name of the engine. Should be human readable. UTF-8 encoded string with limit of 1024 characters.", + "type": "string" + }, + "industryVertical": { + "description": "The industry vertical that the engine registers. The restriction of the Engine industry vertical is based on DataStore: If unspecified, default to `GENERIC`. Vertical on Engine has to match vertical of the DataStore liniked to the engine.", + "enum": [ + "INDUSTRY_VERTICAL_UNSPECIFIED", + "GENERIC", + "MEDIA" + ], + "enumDescriptions": [ + "Value used when unset.", + "The generic vertical for documents that are not specific to any industry vertical.", + "The media industry vertical." + ], "type": "string" }, - "requestPayload": { - "additionalProperties": { - "description": "Properties of the object.", - "type": "any" - }, - "description": "The API request payload, represented as a protocol buffer. Most API request types are supported—for example: * `type.googleapis.com/google.cloud.discoveryengine.v1alpha.DocumentService.CreateDocumentRequest` * `type.googleapis.com/google.cloud.discoveryengine.v1alpha.UserEventService.WriteUserEventRequest`", - "type": "object" + "name": { + "description": "Immutable. The fully qualified resource name of the engine. This field must be a UTF-8 encoded string with a length limit of 1024 characters. Format: `projects/{project_number}/locations/{location}/collections/{collection}/engines/{engine}` engine should be 1-63 characters, and valid characters are /a-z0-9*/. Otherwise, an INVALID_ARGUMENT error is returned.", + "type": "string" }, - "responsePayload": { - "additionalProperties": { - "description": "Properties of the object.", - "type": "any" - }, - "description": "The API response payload, represented as a protocol buffer. This is used to log some \"soft errors\", where the response is valid but we consider there are some quality issues like unjoined events. The following API responses are supported, and no PII is included: * `google.cloud.discoveryengine.v1alpha.RecommendationService.Recommend` * `google.cloud.discoveryengine.v1alpha.UserEventService.WriteUserEvent` * `google.cloud.discoveryengine.v1alpha.UserEventService.CollectUserEvent`", - "type": "object" + "searchEngineConfig": { + "$ref": "GoogleCloudDiscoveryengineV1EngineSearchEngineConfig", + "description": "Configurations for the Search Engine. Only applicable if solution_type is SOLUTION_TYPE_SEARCH." }, - "serviceContext": { - "$ref": "GoogleCloudDiscoveryengineLoggingServiceContext", - "description": "The service context in which this error has occurred." + "solutionType": { + "description": "Required. The solutions of the engine.", + "enum": [ + "SOLUTION_TYPE_UNSPECIFIED", + "SOLUTION_TYPE_RECOMMENDATION", + "SOLUTION_TYPE_SEARCH", + "SOLUTION_TYPE_CHAT" + ], + "enumDescriptions": [ + "Default value.", + "Used for Recommendations AI.", + "Used for Discovery Search.", + "Used for use cases related to the Generative AI agent." + ], + "type": "string" }, - "status": { - "$ref": "GoogleRpcStatus", - "description": "The RPC status associated with the error log." + "updateTime": { + "description": "Output only. Timestamp the Recommendation Engine was last updated.", + "format": "google-datetime", + "readOnly": true, + "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineLoggingHttpRequestContext": { - "description": "HTTP request data that is related to a reported error.", - "id": "GoogleCloudDiscoveryengineLoggingHttpRequestContext", + "GoogleCloudDiscoveryengineV1EngineChatEngineConfig": { + "description": "Configurations for a Chat Engine.", + "id": "GoogleCloudDiscoveryengineV1EngineChatEngineConfig", "properties": { - "responseStatusCode": { - "description": "The HTTP response status code for the request.", - "format": "int32", - "type": "integer" + "agentCreationConfig": { + "$ref": "GoogleCloudDiscoveryengineV1EngineChatEngineConfigAgentCreationConfig", + "description": "The configurationt generate the Dialogflow agent that is associated to this Engine. Note that these configurations are one-time consumed by and passed to Dialogflow service. It means they cannot be retrieved using EngineService.GetEngine or EngineService.ListEngines API after engine creation." + }, + "dialogflowAgentToLink": { + "description": "The resource name of an exist Dialogflow agent to link to this Chat Engine. Customers can either provide `agent_creation_config` to create agent or provide an agent name that links the agent with the Chat engine. Format: `projects//locations//agents/`. Note that the `dialogflow_agent_to_link` are one-time consumed by and passed to Dialogflow service. It means they cannot be retrieved using EngineService.GetEngine or EngineService.ListEngines API after engine creation. Please use ChatEngineMetadata.dialogflow_agent for actual agent association after Engine is created.", + "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineLoggingImportErrorContext": { - "description": "The error payload that is populated on LRO import APIs, including the following: * `google.cloud.discoveryengine.v1alpha.DocumentService.ImportDocuments` * `google.cloud.discoveryengine.v1alpha.UserEventService.ImportUserEvents`", - "id": "GoogleCloudDiscoveryengineLoggingImportErrorContext", + "GoogleCloudDiscoveryengineV1EngineChatEngineConfigAgentCreationConfig": { + "description": "Configurations for generating a Dialogflow agent. Note that these configurations are one-time consumed by and passed to Dialogflow service. It means they cannot be retrieved using EngineService.GetEngine or EngineService.ListEngines API after engine creation.", + "id": "GoogleCloudDiscoveryengineV1EngineChatEngineConfigAgentCreationConfig", "properties": { - "document": { - "description": "The detailed content which caused the error on importing a document.", - "type": "string" - }, - "gcsPath": { - "description": "Google Cloud Storage file path of the import source. Can be set for batch operation error.", + "business": { + "description": "Name of the company, organization or other entity that the agent represents. Used for knowledge connector LLM prompt and for knowledge search.", "type": "string" }, - "lineNumber": { - "description": "Line number of the content in file. Should be empty for permission or batch operation error.", + "defaultLanguageCode": { + "description": "Required. The default language of the agent as a language tag. See [Language Support](https://cloud.google.com/dialogflow/docs/reference/language) for a list of the currently supported language codes.", "type": "string" }, - "operation": { - "description": "The operation resource name of the LRO.", + "location": { + "description": "Agent location for Agent creation, supported values: global/us/eu. If not provided, us Engine will create Agent using us-central-1 by default; eu Engine will create Agent using eu-west-1 by default.", "type": "string" }, - "userEvent": { - "description": "The detailed content which caused the error on importing a user event.", - "type": "string" - } - }, - "type": "object" - }, - "GoogleCloudDiscoveryengineLoggingServiceContext": { - "description": "Describes a running service that sends errors.", - "id": "GoogleCloudDiscoveryengineLoggingServiceContext", - "properties": { - "service": { - "description": "An identifier of the service—for example, `discoveryengine.googleapis.com`.", + "timeZone": { + "description": "Required. The time zone of the agent from the [time zone database](https://www.iana.org/time-zones), e.g., America/New_York, Europe/Paris.", "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineLoggingSourceLocation": { - "description": "Indicates a location in the source code of the service for which errors are reported.", - "id": "GoogleCloudDiscoveryengineLoggingSourceLocation", + "GoogleCloudDiscoveryengineV1EngineChatEngineMetadata": { + "description": "Additional information of a Chat Engine. Fields in this message are output only.", + "id": "GoogleCloudDiscoveryengineV1EngineChatEngineMetadata", "properties": { - "functionName": { - "description": "Human-readable name of a function or method—for example, `google.cloud.discoveryengine.v1alpha.RecommendationService.Recommend`.", + "dialogflowAgent": { + "description": "The resource name of a Dialogflow agent, that this Chat Engine refers to. Format: `projects//locations//agents/`.", "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1CreateSchemaMetadata": { - "description": "Metadata for Create Schema LRO.", - "id": "GoogleCloudDiscoveryengineV1CreateSchemaMetadata", + "GoogleCloudDiscoveryengineV1EngineCommonConfig": { + "description": "Common configurations for an Engine.", + "id": "GoogleCloudDiscoveryengineV1EngineCommonConfig", "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", + "companyName": { + "description": "Immutable. The name of the company, business or entity that is associated with the engine. Setting this may help improve LLM related features.", "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1DeleteSchemaMetadata": { - "description": "Metadata for DeleteSchema LRO.", - "id": "GoogleCloudDiscoveryengineV1DeleteSchemaMetadata", + "GoogleCloudDiscoveryengineV1EngineSearchEngineConfig": { + "description": "Configurations for a Search Engine.", + "id": "GoogleCloudDiscoveryengineV1EngineSearchEngineConfig", "properties": { - "createTime": { - "description": "Operation create time.", - "format": "google-datetime", - "type": "string" + "searchAddOns": { + "description": "The add-on that this search engine enables.", + "items": { + "enum": [ + "SEARCH_ADD_ON_UNSPECIFIED", + "SEARCH_ADD_ON_LLM" + ], + "enumDescriptions": [ + "Default value when the enum is unspecified. This is invalid to use.", + "Large language model add-on." + ], + "type": "string" + }, + "type": "array" }, - "updateTime": { - "description": "Operation last update time. If the operation is done, this is also the finish time.", - "format": "google-datetime", + "searchTier": { + "description": "The search feature tier of this engine. Different tiers might have different pricing. To learn more, please check the pricing documentation. Defaults to SearchTier.SEARCH_TIER_STANDARD if not specified.", + "enum": [ + "SEARCH_TIER_UNSPECIFIED", + "SEARCH_TIER_STANDARD", + "SEARCH_TIER_ENTERPRISE" + ], + "enumDescriptions": [ + "Default value when the enum is unspecified. This is invalid to use.", + "Standard tier.", + "Enterprise tier." + ], "type": "string" } }, @@ -3482,6 +5035,130 @@ }, "type": "object" }, + "GoogleCloudDiscoveryengineV1SiteVerificationInfo": { + "description": "Verification information for target sites in advanced site search.", + "id": "GoogleCloudDiscoveryengineV1SiteVerificationInfo", + "properties": { + "siteVerificationState": { + "description": "Site verification state indicating the ownership and validity.", + "enum": [ + "SITE_VERIFICATION_STATE_UNSPECIFIED", + "VERIFIED", + "UNVERIFIED", + "EXEMPTED" + ], + "enumDescriptions": [ + "Defaults to VERIFIED.", + "Site ownership verified.", + "Site ownership pending verification or verification failed.", + "Site exempt from verification, e.g., a public website that opens to all." + ], + "type": "string" + }, + "verifyTime": { + "description": "Latest site verification time.", + "format": "google-datetime", + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1TargetSite": { + "description": "A target site for the SiteSearchEngine.", + "id": "GoogleCloudDiscoveryengineV1TargetSite", + "properties": { + "exactMatch": { + "description": "Input only. If set to false, a uri_pattern is generated to include all pages whose address contains the provided_uri_pattern. If set to true, an uri_pattern is generated to try to be an exact match of the provided_uri_pattern or just the specific page if the provided_uri_pattern is a specific one. provided_uri_pattern is always normalized to generate the URI pattern to be used by the search engine.", + "type": "boolean" + }, + "failureReason": { + "$ref": "GoogleCloudDiscoveryengineV1TargetSiteFailureReason", + "description": "Output only. Failure reason.", + "readOnly": true + }, + "generatedUriPattern": { + "description": "Output only. This is system-generated based on the provided_uri_pattern.", + "readOnly": true, + "type": "string" + }, + "indexingStatus": { + "description": "Output only. Indexing status.", + "enum": [ + "INDEXING_STATUS_UNSPECIFIED", + "PENDING", + "FAILED", + "SUCCEEDED", + "DELETING" + ], + "enumDescriptions": [ + "Defaults to SUCCEEDED.", + "The target site is in the update queue and will be picked up by indexing pipeline.", + "The target site fails to be indexed.", + "The target site has been indexed.", + "The previously indexed target site has been marked to be deleted. This is a transitioning state which will resulted in either: 1. target site deleted if unindexing is successful; 2. state reverts to SUCCEEDED if the unindexing fails." + ], + "readOnly": true, + "type": "string" + }, + "name": { + "description": "Output only. The fully qualified resource name of the target site. `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/siteSearchEngine/targetSites/{target_site}` The `target_site_id` is system-generated.", + "readOnly": true, + "type": "string" + }, + "providedUriPattern": { + "description": "Required. Input only. The user provided URI pattern from which the `generated_uri_pattern` is generated.", + "type": "string" + }, + "siteVerificationInfo": { + "$ref": "GoogleCloudDiscoveryengineV1SiteVerificationInfo", + "description": "Output only. Site ownership and validity verification status.", + "readOnly": true + }, + "type": { + "description": "The type of the target site, e.g., whether the site is to be included or excluded.", + "enum": [ + "TYPE_UNSPECIFIED", + "INCLUDE", + "EXCLUDE" + ], + "enumDescriptions": [ + "This value is unused. In this case, server behavior defaults to Type.INCLUDE.", + "Include the target site.", + "Exclude the target site." + ], + "type": "string" + }, + "updateTime": { + "description": "Output only. The target site's last updated time.", + "format": "google-datetime", + "readOnly": true, + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1TargetSiteFailureReason": { + "description": "Site search indexing failure reasons.", + "id": "GoogleCloudDiscoveryengineV1TargetSiteFailureReason", + "properties": { + "quotaFailure": { + "$ref": "GoogleCloudDiscoveryengineV1TargetSiteFailureReasonQuotaFailure", + "description": "Failed due to insufficient quota." + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1TargetSiteFailureReasonQuotaFailure": { + "id": "GoogleCloudDiscoveryengineV1TargetSiteFailureReasonQuotaFailure", + "properties": { + "totalRequiredQuota": { + "description": "This number is an estimation on how much total quota this project needs to successfully complete indexing.", + "format": "int64", + "type": "string" + } + }, + "type": "object" + }, "GoogleCloudDiscoveryengineV1UpdateSchemaMetadata": { "description": "Metadata for UpdateSchema LRO.", "id": "GoogleCloudDiscoveryengineV1UpdateSchemaMetadata", @@ -3499,6 +5176,23 @@ }, "type": "object" }, + "GoogleCloudDiscoveryengineV1UpdateTargetSiteMetadata": { + "description": "Metadata related to the progress of the SiteSearchEngineService.UpdateTargetSite operation. This will be returned by the google.longrunning.Operation.metadata field.", + "id": "GoogleCloudDiscoveryengineV1UpdateTargetSiteMetadata", + "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" + }, "GoogleCloudDiscoveryengineV1alphaBatchCreateTargetSiteMetadata": { "description": "Metadata related to the progress of the SiteSearchEngineService.BatchCreateTargetSites operation. This will be returned by the google.longrunning.Operation.metadata field.", "id": "GoogleCloudDiscoveryengineV1alphaBatchCreateTargetSiteMetadata", @@ -3827,7 +5521,7 @@ "type": "string" }, "dataStoreIds": { - "description": "The data stores associated with this engine. For SOLUTION_TYPE_SEARCH and SOLUTION_TYPE_RECOMMENDATION type of engines, they can only associate with at most one data store. If solution_type is SOLUTION_TYPE_CHAT, multiple DataStores in the same Collection can be associated here. Note that when used in CreateEngineRequest, one DataStore id must be provided as the system will use it for necessary intializations.", + "description": "The data stores associated with this engine. For SOLUTION_TYPE_SEARCH and SOLUTION_TYPE_RECOMMENDATION type of engines, they can only associate with at most one data store. If solution_type is SOLUTION_TYPE_CHAT, multiple DataStores in the same Collection can be associated here. Note that when used in CreateEngineRequest, one DataStore id must be provided as the system will use it for necessary initializations.", "items": { "type": "string" }, @@ -3951,7 +5645,7 @@ "id": "GoogleCloudDiscoveryengineV1alphaEngineCommonConfig", "properties": { "companyName": { - "description": "The name of the company, business or entity that is associated with the engine. Setting this may help improve LLM related features.", + "description": "Immutable. The name of the company, business or entity that is associated with the engine. Setting this may help improve LLM related features.", "type": "string" } }, @@ -3962,7 +5656,7 @@ "id": "GoogleCloudDiscoveryengineV1alphaEngineMediaRecommendationEngineConfig", "properties": { "optimizationObjective": { - "description": "The optimization objective e.g. `cvr`. This field together with optimization_objective describe engine metadata to use to control engine training and serving. Currently supported values: `ctr`, `cvr`. If not specified, we choose default based on engine type. Default depends on type of recommendation: `recommended-for-you` =\u003e `ctr` `others-you-may-like` =\u003e `ctr`", + "description": "The optimization objective. e.g., `cvr`. This field together with optimization_objective describe engine metadata to use to control engine training and serving. Currently supported values: `ctr`, `cvr`. If not specified, we choose default based on engine type. Default depends on type of recommendation: `recommended-for-you` =\u003e `ctr` `others-you-may-like` =\u003e `ctr`", "type": "string" }, "optimizationObjectiveConfig": { @@ -3984,7 +5678,7 @@ "type": "string" }, "type": { - "description": "Required. The type of engine e.g. `recommended-for-you`. This field together with optimization_objective describe engine metadata to use to control engine training and serving. Currently supported values: `recommended-for-you`, `others-you-may-like`, `more-like-this`, `most-popular-items`.", + "description": "Required. The type of engine. e.g., `recommended-for-you`. This field together with optimization_objective describe engine metadata to use to control engine training and serving. Currently supported values: `recommended-for-you`, `others-you-may-like`, `more-like-this`, `most-popular-items`.", "type": "string" } }, @@ -4631,7 +6325,7 @@ "type": "object" }, "GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfoFailureReason": { - "description": "Details about why crawling failed for a particular CorpusType, e.g. DESKTOP and MOBILE crawling may fail for different reasons.", + "description": "Details about why crawling failed for a particular CorpusType, e.g., DESKTOP and MOBILE crawling may fail for different reasons.", "id": "GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfoFailureReason", "properties": { "corpusType": { @@ -4702,7 +6396,7 @@ "Defaults to VERIFIED.", "Site ownership verified.", "Site ownership pending verification or verification failed.", - "Site exempt from verification, e.g. a public website that opens to all." + "Site exempt from verification, e.g., a public website that opens to all." ], "type": "string" }, @@ -4766,7 +6460,7 @@ "readOnly": true }, "type": { - "description": "The type of the target site, e.g. whether the site is to be included or excluded.", + "description": "The type of the target site, e.g., whether the site is to be included or excluded.", "enum": [ "TYPE_UNSPECIFIED", "INCLUDE", @@ -4801,7 +6495,13 @@ }, "GoogleCloudDiscoveryengineV1alphaTargetSiteFailureReasonQuotaFailure": { "id": "GoogleCloudDiscoveryengineV1alphaTargetSiteFailureReasonQuotaFailure", - "properties": {}, + "properties": { + "totalRequiredQuota": { + "description": "This number is an estimation on how much total quota this project needs to successfully complete indexing.", + "format": "int64", + "type": "string" + } + }, "type": "object" }, "GoogleCloudDiscoveryengineV1alphaTrainCustomModelMetadata": { @@ -4894,6 +6594,57 @@ }, "type": "object" }, + "GoogleCloudDiscoveryengineV1betaBatchCreateTargetSiteMetadata": { + "description": "Metadata related to the progress of the SiteSearchEngineService.BatchCreateTargetSites operation. This will be returned by the google.longrunning.Operation.metadata field.", + "id": "GoogleCloudDiscoveryengineV1betaBatchCreateTargetSiteMetadata", + "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" + }, + "GoogleCloudDiscoveryengineV1betaBatchCreateTargetSitesRequest": { + "description": "Request message for SiteSearchEngineService.BatchCreateTargetSites method.", + "id": "GoogleCloudDiscoveryengineV1betaBatchCreateTargetSitesRequest", + "properties": { + "requests": { + "description": "Required. The request message specifying the resources to create. A maximum of 20 TargetSites can be created in a batch.", + "items": { + "$ref": "GoogleCloudDiscoveryengineV1betaCreateTargetSiteRequest" + }, + "type": "array" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1betaBatchCreateTargetSitesResponse": { + "description": "Response message for SiteSearchEngineService.BatchCreateTargetSites method.", + "id": "GoogleCloudDiscoveryengineV1betaBatchCreateTargetSitesResponse", + "properties": { + "targetSites": { + "description": "TargetSites created.", + "items": { + "$ref": "GoogleCloudDiscoveryengineV1betaTargetSite" + }, + "type": "array" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1betaBatchVerifyTargetSitesRequest": { + "description": "Request message for SiteSearchEngineService.BatchVerifyTargetSites method.", + "id": "GoogleCloudDiscoveryengineV1betaBatchVerifyTargetSitesRequest", + "properties": {}, + "type": "object" + }, "GoogleCloudDiscoveryengineV1betaBigQuerySource": { "description": "BigQuery source import data from.", "id": "GoogleCloudDiscoveryengineV1betaBigQuerySource", @@ -5121,19 +6872,233 @@ "$ref": "GoogleCloudDiscoveryengineV1betaReply", "description": "Answer to the current query." }, - "searchResults": { - "description": "Search Results.", - "items": { - "$ref": "GoogleCloudDiscoveryengineV1betaSearchResponseSearchResult" - }, - "type": "array" + "searchResults": { + "description": "Search Results.", + "items": { + "$ref": "GoogleCloudDiscoveryengineV1betaSearchResponseSearchResult" + }, + "type": "array" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1betaCreateDataStoreMetadata": { + "description": "Metadata related to the progress of the DataStoreService.CreateDataStore operation. This will be returned by the google.longrunning.Operation.metadata field.", + "id": "GoogleCloudDiscoveryengineV1betaCreateDataStoreMetadata", + "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" + }, + "GoogleCloudDiscoveryengineV1betaCreateEngineMetadata": { + "description": "Metadata related to the progress of the EngineService.CreateEngine operation. This will be returned by the google.longrunning.Operation.metadata field.", + "id": "GoogleCloudDiscoveryengineV1betaCreateEngineMetadata", + "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" + }, + "GoogleCloudDiscoveryengineV1betaCreateSchemaMetadata": { + "description": "Metadata for Create Schema LRO.", + "id": "GoogleCloudDiscoveryengineV1betaCreateSchemaMetadata", + "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" + }, + "GoogleCloudDiscoveryengineV1betaCreateTargetSiteMetadata": { + "description": "Metadata related to the progress of the SiteSearchEngineService.CreateTargetSite operation. This will be returned by the google.longrunning.Operation.metadata field.", + "id": "GoogleCloudDiscoveryengineV1betaCreateTargetSiteMetadata", + "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" + }, + "GoogleCloudDiscoveryengineV1betaCreateTargetSiteRequest": { + "description": "Request message for SiteSearchEngineService.CreateTargetSite method.", + "id": "GoogleCloudDiscoveryengineV1betaCreateTargetSiteRequest", + "properties": { + "parent": { + "description": "Required. Parent resource name of TargetSite, such as `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/siteSearchEngine`.", + "type": "string" + }, + "targetSite": { + "$ref": "GoogleCloudDiscoveryengineV1betaTargetSite", + "description": "Required. The TargetSite to create." + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1betaCustomAttribute": { + "description": "A custom attribute that is not explicitly modeled in a resource, e.g. UserEvent.", + "id": "GoogleCloudDiscoveryengineV1betaCustomAttribute", + "properties": { + "numbers": { + "description": "The numerical values of this custom attribute. For example, `[2.3, 15.4]` when the key is \"lengths_cm\". Exactly one of CustomAttribute.text or CustomAttribute.numbers should be set. Otherwise, an `INVALID_ARGUMENT` error is returned.", + "items": { + "format": "double", + "type": "number" + }, + "type": "array" + }, + "text": { + "description": "The textual values of this custom attribute. For example, `[\"yellow\", \"green\"]` when the key is \"color\". Empty string is not allowed. Otherwise, an `INVALID_ARGUMENT` error is returned. Exactly one of CustomAttribute.text or CustomAttribute.numbers should be set. Otherwise, an `INVALID_ARGUMENT` error is returned.", + "items": { + "type": "string" + }, + "type": "array" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1betaDataStore": { + "description": "DataStore captures global settings and configs at the DataStore level.", + "id": "GoogleCloudDiscoveryengineV1betaDataStore", + "properties": { + "contentConfig": { + "description": "Immutable. The content config of the data store. If this field is unset, the server behavior defaults to ContentConfig.NO_CONTENT.", + "enum": [ + "CONTENT_CONFIG_UNSPECIFIED", + "NO_CONTENT", + "CONTENT_REQUIRED", + "PUBLIC_WEBSITE" + ], + "enumDescriptions": [ + "Default value.", + "Only contains documents without any Document.content.", + "Only contains documents with Document.content.", + "The data store is used for public website search." + ], + "type": "string" + }, + "createTime": { + "description": "Output only. Timestamp the DataStore was created at.", + "format": "google-datetime", + "readOnly": true, + "type": "string" + }, + "defaultSchemaId": { + "description": "Output only. The id of the default Schema asscociated to this data store.", + "readOnly": true, + "type": "string" + }, + "displayName": { + "description": "Required. The data store display name. This field must be a UTF-8 encoded string with a length limit of 128 characters. Otherwise, an INVALID_ARGUMENT error is returned.", + "type": "string" + }, + "industryVertical": { + "description": "Immutable. The industry vertical that the data store registers.", + "enum": [ + "INDUSTRY_VERTICAL_UNSPECIFIED", + "GENERIC", + "MEDIA" + ], + "enumDescriptions": [ + "Value used when unset.", + "The generic vertical for documents that are not specific to any industry vertical.", + "The media industry vertical." + ], + "type": "string" + }, + "name": { + "description": "Immutable. The full resource name of the data store. Format: `projects/{project}/locations/{location}/collections/{collection_id}/dataStores/{data_store_id}`. This field must be a UTF-8 encoded string with a length limit of 1024 characters.", + "type": "string" + }, + "solutionTypes": { + "description": "The solutions that the data store enrolls. Available solutions for each industry_vertical: * `MEDIA`: `SOLUTION_TYPE_RECOMMENDATION` and `SOLUTION_TYPE_SEARCH`. * `SITE_SEARCH`: `SOLUTION_TYPE_SEARCH` is automatically enrolled. Other solutions cannot be enrolled.", + "items": { + "enum": [ + "SOLUTION_TYPE_UNSPECIFIED", + "SOLUTION_TYPE_RECOMMENDATION", + "SOLUTION_TYPE_SEARCH", + "SOLUTION_TYPE_CHAT" + ], + "enumDescriptions": [ + "Default value.", + "Used for Recommendations AI.", + "Used for Discovery Search.", + "Used for use cases related to the Generative AI agent." + ], + "type": "string" + }, + "type": "array" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1betaDeleteDataStoreMetadata": { + "description": "Metadata related to the progress of the DataStoreService.DeleteDataStore operation. This will be returned by the google.longrunning.Operation.metadata field.", + "id": "GoogleCloudDiscoveryengineV1betaDeleteDataStoreMetadata", + "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" + }, + "GoogleCloudDiscoveryengineV1betaDeleteEngineMetadata": { + "description": "Metadata related to the progress of the EngineService.DeleteEngine operation. This will be returned by the google.longrunning.Operation.metadata field.", + "id": "GoogleCloudDiscoveryengineV1betaDeleteEngineMetadata", + "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" }, - "GoogleCloudDiscoveryengineV1betaCreateSchemaMetadata": { - "description": "Metadata for Create Schema LRO.", - "id": "GoogleCloudDiscoveryengineV1betaCreateSchemaMetadata", + "GoogleCloudDiscoveryengineV1betaDeleteSchemaMetadata": { + "description": "Metadata for DeleteSchema LRO.", + "id": "GoogleCloudDiscoveryengineV1betaDeleteSchemaMetadata", "properties": { "createTime": { "description": "Operation create time.", @@ -5148,31 +7113,26 @@ }, "type": "object" }, - "GoogleCloudDiscoveryengineV1betaCustomAttribute": { - "description": "A custom attribute that is not explicitly modeled in a resource, e.g. UserEvent.", - "id": "GoogleCloudDiscoveryengineV1betaCustomAttribute", + "GoogleCloudDiscoveryengineV1betaDeleteTargetSiteMetadata": { + "description": "Metadata related to the progress of the SiteSearchEngineService.DeleteTargetSite operation. This will be returned by the google.longrunning.Operation.metadata field.", + "id": "GoogleCloudDiscoveryengineV1betaDeleteTargetSiteMetadata", "properties": { - "numbers": { - "description": "The numerical values of this custom attribute. For example, `[2.3, 15.4]` when the key is \"lengths_cm\". Exactly one of CustomAttribute.text or CustomAttribute.numbers should be set. Otherwise, an `INVALID_ARGUMENT` error is returned.", - "items": { - "format": "double", - "type": "number" - }, - "type": "array" + "createTime": { + "description": "Operation create time.", + "format": "google-datetime", + "type": "string" }, - "text": { - "description": "The textual values of this custom attribute. For example, `[\"yellow\", \"green\"]` when the key is \"color\". Empty string is not allowed. Otherwise, an `INVALID_ARGUMENT` error is returned. Exactly one of CustomAttribute.text or CustomAttribute.numbers should be set. Otherwise, an `INVALID_ARGUMENT` error is returned.", - "items": { - "type": "string" - }, - "type": "array" + "updateTime": { + "description": "Operation last update time. If the operation is done, this is also the finish time.", + "format": "google-datetime", + "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1betaDeleteSchemaMetadata": { - "description": "Metadata for DeleteSchema LRO.", - "id": "GoogleCloudDiscoveryengineV1betaDeleteSchemaMetadata", + "GoogleCloudDiscoveryengineV1betaDisableAdvancedSiteSearchMetadata": { + "description": "Metadata related to the progress of the SiteSearchEngineService.DisableAdvancedSiteSearch operation. This will be returned by the google.longrunning.Operation.metadata field.", + "id": "GoogleCloudDiscoveryengineV1betaDisableAdvancedSiteSearchMetadata", "properties": { "createTime": { "description": "Operation create time.", @@ -5187,6 +7147,18 @@ }, "type": "object" }, + "GoogleCloudDiscoveryengineV1betaDisableAdvancedSiteSearchRequest": { + "description": "Request message for SiteSearchEngineService.DisableAdvancedSiteSearch method.", + "id": "GoogleCloudDiscoveryengineV1betaDisableAdvancedSiteSearchRequest", + "properties": {}, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1betaDisableAdvancedSiteSearchResponse": { + "description": "Response message for SiteSearchEngineService.DisableAdvancedSiteSearch method.", + "id": "GoogleCloudDiscoveryengineV1betaDisableAdvancedSiteSearchResponse", + "properties": {}, + "type": "object" + }, "GoogleCloudDiscoveryengineV1betaDocument": { "description": "Document captures all raw metadata information of items to be recommended or searched.", "id": "GoogleCloudDiscoveryengineV1betaDocument", @@ -5235,68 +7207,297 @@ }, "type": "object" }, - "GoogleCloudDiscoveryengineV1betaDocumentContent": { - "description": "Unstructured data linked to this document.", - "id": "GoogleCloudDiscoveryengineV1betaDocumentContent", + "GoogleCloudDiscoveryengineV1betaDocumentContent": { + "description": "Unstructured data linked to this document.", + "id": "GoogleCloudDiscoveryengineV1betaDocumentContent", + "properties": { + "mimeType": { + "description": "The MIME type of the content. Supported types: * `application/pdf` (PDF, only native PDFs are supported for now) * `text/html` (HTML) * `application/vnd.openxmlformats-officedocument.wordprocessingml.document` (DOCX) * `application/vnd.openxmlformats-officedocument.presentationml.presentation` (PPTX) * `text/plain` (TXT) See https://www.iana.org/assignments/media-types/media-types.xhtml.", + "type": "string" + }, + "rawBytes": { + "description": "The content represented as a stream of bytes. The maximum length is 1,000,000 bytes (1 MB / ~0.95 MiB). Note: As with all `bytes` fields, this field is represented as pure binary in Protocol Buffers and base64-encoded string in JSON. For example, `abc123!?$*\u0026()'-=@~` should be represented as `YWJjMTIzIT8kKiYoKSctPUB+` in JSON. See https://developers.google.com/protocol-buffers/docs/proto3#json.", + "format": "byte", + "type": "string" + }, + "uri": { + "description": "The URI of the content. Only Cloud Storage URIs (e.g. `gs://bucket-name/path/to/file`) are supported. The maximum file size is 2.5 MB for text-based formats, 100 MB for other formats.", + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1betaDocumentInfo": { + "description": "Detailed document information associated with a user event.", + "id": "GoogleCloudDiscoveryengineV1betaDocumentInfo", + "properties": { + "id": { + "description": "The Document resource ID.", + "type": "string" + }, + "name": { + "description": "The Document resource full name, of the form: `projects/{project_id}/locations/{location}/collections/{collection_id}/dataStores/{data_store_id}/branches/{branch_id}/documents/{document_id}`", + "type": "string" + }, + "promotionIds": { + "description": "The promotion IDs associated with this Document. Currently, this field is restricted to at most one ID.", + "items": { + "type": "string" + }, + "type": "array" + }, + "quantity": { + "description": "Quantity of the Document associated with the user event. Defaults to 1. For example, this field will be 2 if two quantities of the same Document are involved in a `add-to-cart` event. Required for events of the following event types: * `add-to-cart` * `purchase`", + "format": "int32", + "type": "integer" + }, + "uri": { + "description": "The Document URI - only allowed for website data stores.", + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1betaDoubleList": { + "description": "Double list.", + "id": "GoogleCloudDiscoveryengineV1betaDoubleList", + "properties": { + "values": { + "description": "Double values.", + "items": { + "format": "double", + "type": "number" + }, + "type": "array" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1betaEnableAdvancedSiteSearchMetadata": { + "description": "Metadata related to the progress of the SiteSearchEngineService.EnableAdvancedSiteSearch operation. This will be returned by the google.longrunning.Operation.metadata field.", + "id": "GoogleCloudDiscoveryengineV1betaEnableAdvancedSiteSearchMetadata", + "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" + }, + "GoogleCloudDiscoveryengineV1betaEnableAdvancedSiteSearchRequest": { + "description": "Request message for SiteSearchEngineService.EnableAdvancedSiteSearch method.", + "id": "GoogleCloudDiscoveryengineV1betaEnableAdvancedSiteSearchRequest", + "properties": {}, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1betaEnableAdvancedSiteSearchResponse": { + "description": "Response message for SiteSearchEngineService.EnableAdvancedSiteSearch method.", + "id": "GoogleCloudDiscoveryengineV1betaEnableAdvancedSiteSearchResponse", + "properties": {}, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1betaEngine": { + "description": "Metadata that describes the training and serving parameters of an Engine.", + "id": "GoogleCloudDiscoveryengineV1betaEngine", + "properties": { + "chatEngineConfig": { + "$ref": "GoogleCloudDiscoveryengineV1betaEngineChatEngineConfig", + "description": "Configurations for the Chat Engine. Only applicable if solution_type is SOLUTION_TYPE_CHAT." + }, + "chatEngineMetadata": { + "$ref": "GoogleCloudDiscoveryengineV1betaEngineChatEngineMetadata", + "description": "Output only. Additional information of the Chat Engine. Only applicable if solution_type is SOLUTION_TYPE_CHAT.", + "readOnly": true + }, + "commonConfig": { + "$ref": "GoogleCloudDiscoveryengineV1betaEngineCommonConfig", + "description": "Common config spec that specifies the metadata of the engine." + }, + "createTime": { + "description": "Output only. Timestamp the Recommendation Engine was created at.", + "format": "google-datetime", + "readOnly": true, + "type": "string" + }, + "dataStoreIds": { + "description": "The data stores associated with this engine. For SOLUTION_TYPE_SEARCH and SOLUTION_TYPE_RECOMMENDATION type of engines, they can only associate with at most one data store. If solution_type is SOLUTION_TYPE_CHAT, multiple DataStores in the same Collection can be associated here. Note that when used in CreateEngineRequest, one DataStore id must be provided as the system will use it for necessary initializations.", + "items": { + "type": "string" + }, + "type": "array" + }, + "displayName": { + "description": "Required. The display name of the engine. Should be human readable. UTF-8 encoded string with limit of 1024 characters.", + "type": "string" + }, + "industryVertical": { + "description": "The industry vertical that the engine registers. The restriction of the Engine industry vertical is based on DataStore: If unspecified, default to `GENERIC`. Vertical on Engine has to match vertical of the DataStore liniked to the engine.", + "enum": [ + "INDUSTRY_VERTICAL_UNSPECIFIED", + "GENERIC", + "MEDIA" + ], + "enumDescriptions": [ + "Value used when unset.", + "The generic vertical for documents that are not specific to any industry vertical.", + "The media industry vertical." + ], + "type": "string" + }, + "name": { + "description": "Immutable. The fully qualified resource name of the engine. This field must be a UTF-8 encoded string with a length limit of 1024 characters. Format: `projects/{project_number}/locations/{location}/collections/{collection}/engines/{engine}` engine should be 1-63 characters, and valid characters are /a-z0-9*/. Otherwise, an INVALID_ARGUMENT error is returned.", + "type": "string" + }, + "searchEngineConfig": { + "$ref": "GoogleCloudDiscoveryengineV1betaEngineSearchEngineConfig", + "description": "Configurations for the Search Engine. Only applicable if solution_type is SOLUTION_TYPE_SEARCH." + }, + "solutionType": { + "description": "Required. The solutions of the engine.", + "enum": [ + "SOLUTION_TYPE_UNSPECIFIED", + "SOLUTION_TYPE_RECOMMENDATION", + "SOLUTION_TYPE_SEARCH", + "SOLUTION_TYPE_CHAT" + ], + "enumDescriptions": [ + "Default value.", + "Used for Recommendations AI.", + "Used for Discovery Search.", + "Used for use cases related to the Generative AI agent." + ], + "type": "string" + }, + "updateTime": { + "description": "Output only. Timestamp the Recommendation Engine was last updated.", + "format": "google-datetime", + "readOnly": true, + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1betaEngineChatEngineConfig": { + "description": "Configurations for a Chat Engine.", + "id": "GoogleCloudDiscoveryengineV1betaEngineChatEngineConfig", + "properties": { + "agentCreationConfig": { + "$ref": "GoogleCloudDiscoveryengineV1betaEngineChatEngineConfigAgentCreationConfig", + "description": "The configurationt generate the Dialogflow agent that is associated to this Engine. Note that these configurations are one-time consumed by and passed to Dialogflow service. It means they cannot be retrieved using EngineService.GetEngine or EngineService.ListEngines API after engine creation." + }, + "dialogflowAgentToLink": { + "description": "The resource name of an exist Dialogflow agent to link to this Chat Engine. Customers can either provide `agent_creation_config` to create agent or provide an agent name that links the agent with the Chat engine. Format: `projects//locations//agents/`. Note that the `dialogflow_agent_to_link` are one-time consumed by and passed to Dialogflow service. It means they cannot be retrieved using EngineService.GetEngine or EngineService.ListEngines API after engine creation. Please use ChatEngineMetadata.dialogflow_agent for actual agent association after Engine is created.", + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1betaEngineChatEngineConfigAgentCreationConfig": { + "description": "Configurations for generating a Dialogflow agent. Note that these configurations are one-time consumed by and passed to Dialogflow service. It means they cannot be retrieved using EngineService.GetEngine or EngineService.ListEngines API after engine creation.", + "id": "GoogleCloudDiscoveryengineV1betaEngineChatEngineConfigAgentCreationConfig", + "properties": { + "business": { + "description": "Name of the company, organization or other entity that the agent represents. Used for knowledge connector LLM prompt and for knowledge search.", + "type": "string" + }, + "defaultLanguageCode": { + "description": "Required. The default language of the agent as a language tag. See [Language Support](https://cloud.google.com/dialogflow/docs/reference/language) for a list of the currently supported language codes.", + "type": "string" + }, + "location": { + "description": "Agent location for Agent creation, supported values: global/us/eu. If not provided, us Engine will create Agent using us-central-1 by default; eu Engine will create Agent using eu-west-1 by default.", + "type": "string" + }, + "timeZone": { + "description": "Required. The time zone of the agent from the [time zone database](https://www.iana.org/time-zones), e.g., America/New_York, Europe/Paris.", + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1betaEngineChatEngineMetadata": { + "description": "Additional information of a Chat Engine. Fields in this message are output only.", + "id": "GoogleCloudDiscoveryengineV1betaEngineChatEngineMetadata", + "properties": { + "dialogflowAgent": { + "description": "The resource name of a Dialogflow agent, that this Chat Engine refers to. Format: `projects//locations//agents/`.", + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1betaEngineCommonConfig": { + "description": "Common configurations for an Engine.", + "id": "GoogleCloudDiscoveryengineV1betaEngineCommonConfig", "properties": { - "mimeType": { - "description": "The MIME type of the content. Supported types: * `application/pdf` (PDF, only native PDFs are supported for now) * `text/html` (HTML) * `application/vnd.openxmlformats-officedocument.wordprocessingml.document` (DOCX) * `application/vnd.openxmlformats-officedocument.presentationml.presentation` (PPTX) * `text/plain` (TXT) See https://www.iana.org/assignments/media-types/media-types.xhtml.", - "type": "string" - }, - "rawBytes": { - "description": "The content represented as a stream of bytes. The maximum length is 1,000,000 bytes (1 MB / ~0.95 MiB). Note: As with all `bytes` fields, this field is represented as pure binary in Protocol Buffers and base64-encoded string in JSON. For example, `abc123!?$*\u0026()'-=@~` should be represented as `YWJjMTIzIT8kKiYoKSctPUB+` in JSON. See https://developers.google.com/protocol-buffers/docs/proto3#json.", - "format": "byte", - "type": "string" - }, - "uri": { - "description": "The URI of the content. Only Cloud Storage URIs (e.g. `gs://bucket-name/path/to/file`) are supported. The maximum file size is 2.5 MB for text-based formats, 100 MB for other formats.", + "companyName": { + "description": "Immutable. The name of the company, business or entity that is associated with the engine. Setting this may help improve LLM related features.", "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1betaDocumentInfo": { - "description": "Detailed document information associated with a user event.", - "id": "GoogleCloudDiscoveryengineV1betaDocumentInfo", + "GoogleCloudDiscoveryengineV1betaEngineSearchEngineConfig": { + "description": "Configurations for a Search Engine.", + "id": "GoogleCloudDiscoveryengineV1betaEngineSearchEngineConfig", "properties": { - "id": { - "description": "The Document resource ID.", - "type": "string" - }, - "name": { - "description": "The Document resource full name, of the form: `projects/{project_id}/locations/{location}/collections/{collection_id}/dataStores/{data_store_id}/branches/{branch_id}/documents/{document_id}`", - "type": "string" - }, - "promotionIds": { - "description": "The promotion IDs associated with this Document. Currently, this field is restricted to at most one ID.", + "searchAddOns": { + "description": "The add-on that this search engine enables.", "items": { + "enum": [ + "SEARCH_ADD_ON_UNSPECIFIED", + "SEARCH_ADD_ON_LLM" + ], + "enumDescriptions": [ + "Default value when the enum is unspecified. This is invalid to use.", + "Large language model add-on." + ], "type": "string" }, "type": "array" }, - "quantity": { - "description": "Quantity of the Document associated with the user event. Defaults to 1. For example, this field will be 2 if two quantities of the same Document are involved in a `add-to-cart` event. Required for events of the following event types: * `add-to-cart` * `purchase`", - "format": "int32", - "type": "integer" - }, - "uri": { - "description": "The Document URI - only allowed for website data stores.", + "searchTier": { + "description": "The search feature tier of this engine. Different tiers might have different pricing. To learn more, please check the pricing documentation. Defaults to SearchTier.SEARCH_TIER_STANDARD if not specified.", + "enum": [ + "SEARCH_TIER_UNSPECIFIED", + "SEARCH_TIER_STANDARD", + "SEARCH_TIER_ENTERPRISE" + ], + "enumDescriptions": [ + "Default value when the enum is unspecified. This is invalid to use.", + "Standard tier.", + "Enterprise tier." + ], "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1betaDoubleList": { - "description": "Double list.", - "id": "GoogleCloudDiscoveryengineV1betaDoubleList", + "GoogleCloudDiscoveryengineV1betaFetchDomainVerificationStatusResponse": { + "description": "Response message for SiteSearchEngineService.FetchDomainVerificationStatus method.", + "id": "GoogleCloudDiscoveryengineV1betaFetchDomainVerificationStatusResponse", "properties": { - "values": { - "description": "Double values.", + "nextPageToken": { + "description": "A token that can be sent as `page_token` to retrieve the next page. If this field is omitted, there are no subsequent pages.", + "type": "string" + }, + "targetSites": { + "description": "List of TargetSites containing the site verification status.", "items": { - "format": "double", - "type": "number" + "$ref": "GoogleCloudDiscoveryengineV1betaTargetSite" }, "type": "array" + }, + "totalSize": { + "description": "The total number of items matching the request. This will always be populated in the response.", + "format": "int32", + "type": "integer" } }, "type": "object" @@ -5641,6 +7842,24 @@ }, "type": "object" }, + "GoogleCloudDiscoveryengineV1betaListDataStoresResponse": { + "description": "Response message for DataStoreService.ListDataStores method.", + "id": "GoogleCloudDiscoveryengineV1betaListDataStoresResponse", + "properties": { + "dataStores": { + "description": "All the customer's DataStores.", + "items": { + "$ref": "GoogleCloudDiscoveryengineV1betaDataStore" + }, + "type": "array" + }, + "nextPageToken": { + "description": "A token that can be sent as ListDataStoresRequest.page_token to retrieve the next page. If this field is omitted, there are no subsequent pages.", + "type": "string" + } + }, + "type": "object" + }, "GoogleCloudDiscoveryengineV1betaListDocumentsResponse": { "description": "Response message for DocumentService.ListDocuments method.", "id": "GoogleCloudDiscoveryengineV1betaListDocumentsResponse", @@ -5659,6 +7878,24 @@ }, "type": "object" }, + "GoogleCloudDiscoveryengineV1betaListEnginesResponse": { + "description": "Response message for EngineService.ListEngines method.", + "id": "GoogleCloudDiscoveryengineV1betaListEnginesResponse", + "properties": { + "engines": { + "description": "All the customer's Engines.", + "items": { + "$ref": "GoogleCloudDiscoveryengineV1betaEngine" + }, + "type": "array" + }, + "nextPageToken": { + "description": "Not supported.", + "type": "string" + } + }, + "type": "object" + }, "GoogleCloudDiscoveryengineV1betaListSchemasResponse": { "description": "Response message for SchemaService.ListSchemas method.", "id": "GoogleCloudDiscoveryengineV1betaListSchemasResponse", @@ -5677,6 +7914,29 @@ }, "type": "object" }, + "GoogleCloudDiscoveryengineV1betaListTargetSitesResponse": { + "description": "Response message for SiteSearchEngineService.ListTargetSites method.", + "id": "GoogleCloudDiscoveryengineV1betaListTargetSitesResponse", + "properties": { + "nextPageToken": { + "description": "A token that can be sent as `page_token` to retrieve the next page. If this field is omitted, there are no subsequent pages.", + "type": "string" + }, + "targetSites": { + "description": "List of TargetSites.", + "items": { + "$ref": "GoogleCloudDiscoveryengineV1betaTargetSite" + }, + "type": "array" + }, + "totalSize": { + "description": "The total number of items matching the request. This will always be populated in the response.", + "format": "int32", + "type": "integer" + } + }, + "type": "object" + }, "GoogleCloudDiscoveryengineV1betaMediaInfo": { "description": "Media-specific user event information.", "id": "GoogleCloudDiscoveryengineV1betaMediaInfo", @@ -5934,6 +8194,20 @@ }, "type": "object" }, + "GoogleCloudDiscoveryengineV1betaRecrawlUrisRequest": { + "description": "Request message for SiteSearchEngineService.RecrawlUris method.", + "id": "GoogleCloudDiscoveryengineV1betaRecrawlUrisRequest", + "properties": { + "uris": { + "description": "Required. List of URIs to crawl. At most 10K URIs are supported, otherwise an INVALID_ARGUMENT error is thrown. Each URI should match at least one TargetSite in `site_search_engine`.", + "items": { + "type": "string" + }, + "type": "array" + } + }, + "type": "object" + }, "GoogleCloudDiscoveryengineV1betaReply": { "description": "Defines a reply message to user.", "id": "GoogleCloudDiscoveryengineV1betaReply", @@ -6801,6 +9075,45 @@ }, "type": "object" }, + "GoogleCloudDiscoveryengineV1betaSiteSearchEngine": { + "description": "SiteSearchEngine captures DataStore level site search persisting configurations. It is a singleton value per data store.", + "id": "GoogleCloudDiscoveryengineV1betaSiteSearchEngine", + "properties": { + "name": { + "description": "The fully qualified resource name of the site search engine. Format: `projects/*/locations/*/dataStores/*/siteSearchEngine`", + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1betaSiteVerificationInfo": { + "description": "Verification information for target sites in advanced site search.", + "id": "GoogleCloudDiscoveryengineV1betaSiteVerificationInfo", + "properties": { + "siteVerificationState": { + "description": "Site verification state indicating the ownership and validity.", + "enum": [ + "SITE_VERIFICATION_STATE_UNSPECIFIED", + "VERIFIED", + "UNVERIFIED", + "EXEMPTED" + ], + "enumDescriptions": [ + "Defaults to VERIFIED.", + "Site ownership verified.", + "Site ownership pending verification or verification failed.", + "Site exempt from verification, e.g., a public website that opens to all." + ], + "type": "string" + }, + "verifyTime": { + "description": "Latest site verification time.", + "format": "google-datetime", + "type": "string" + } + }, + "type": "object" + }, "GoogleCloudDiscoveryengineV1betaSuggestionDenyListEntry": { "description": "Suggestion deny list entry identifying the phrase to block from suggestions and the applied operation for the phrase.", "id": "GoogleCloudDiscoveryengineV1betaSuggestionDenyListEntry", @@ -6826,6 +9139,102 @@ }, "type": "object" }, + "GoogleCloudDiscoveryengineV1betaTargetSite": { + "description": "A target site for the SiteSearchEngine.", + "id": "GoogleCloudDiscoveryengineV1betaTargetSite", + "properties": { + "exactMatch": { + "description": "Input only. If set to false, a uri_pattern is generated to include all pages whose address contains the provided_uri_pattern. If set to true, an uri_pattern is generated to try to be an exact match of the provided_uri_pattern or just the specific page if the provided_uri_pattern is a specific one. provided_uri_pattern is always normalized to generate the URI pattern to be used by the search engine.", + "type": "boolean" + }, + "failureReason": { + "$ref": "GoogleCloudDiscoveryengineV1betaTargetSiteFailureReason", + "description": "Output only. Failure reason.", + "readOnly": true + }, + "generatedUriPattern": { + "description": "Output only. This is system-generated based on the provided_uri_pattern.", + "readOnly": true, + "type": "string" + }, + "indexingStatus": { + "description": "Output only. Indexing status.", + "enum": [ + "INDEXING_STATUS_UNSPECIFIED", + "PENDING", + "FAILED", + "SUCCEEDED", + "DELETING" + ], + "enumDescriptions": [ + "Defaults to SUCCEEDED.", + "The target site is in the update queue and will be picked up by indexing pipeline.", + "The target site fails to be indexed.", + "The target site has been indexed.", + "The previously indexed target site has been marked to be deleted. This is a transitioning state which will resulted in either: 1. target site deleted if unindexing is successful; 2. state reverts to SUCCEEDED if the unindexing fails." + ], + "readOnly": true, + "type": "string" + }, + "name": { + "description": "Output only. The fully qualified resource name of the target site. `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/siteSearchEngine/targetSites/{target_site}` The `target_site_id` is system-generated.", + "readOnly": true, + "type": "string" + }, + "providedUriPattern": { + "description": "Required. Input only. The user provided URI pattern from which the `generated_uri_pattern` is generated.", + "type": "string" + }, + "siteVerificationInfo": { + "$ref": "GoogleCloudDiscoveryengineV1betaSiteVerificationInfo", + "description": "Output only. Site ownership and validity verification status.", + "readOnly": true + }, + "type": { + "description": "The type of the target site, e.g., whether the site is to be included or excluded.", + "enum": [ + "TYPE_UNSPECIFIED", + "INCLUDE", + "EXCLUDE" + ], + "enumDescriptions": [ + "This value is unused. In this case, server behavior defaults to Type.INCLUDE.", + "Include the target site.", + "Exclude the target site." + ], + "type": "string" + }, + "updateTime": { + "description": "Output only. The target site's last updated time.", + "format": "google-datetime", + "readOnly": true, + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1betaTargetSiteFailureReason": { + "description": "Site search indexing failure reasons.", + "id": "GoogleCloudDiscoveryengineV1betaTargetSiteFailureReason", + "properties": { + "quotaFailure": { + "$ref": "GoogleCloudDiscoveryengineV1betaTargetSiteFailureReasonQuotaFailure", + "description": "Failed due to insufficient quota." + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1betaTargetSiteFailureReasonQuotaFailure": { + "id": "GoogleCloudDiscoveryengineV1betaTargetSiteFailureReasonQuotaFailure", + "properties": { + "totalRequiredQuota": { + "description": "This number is an estimation on how much total quota this project needs to successfully complete indexing.", + "format": "int64", + "type": "string" + } + }, + "type": "object" + }, "GoogleCloudDiscoveryengineV1betaTextInput": { "description": "Defines text input.", "id": "GoogleCloudDiscoveryengineV1betaTextInput", @@ -6893,6 +9302,23 @@ }, "type": "object" }, + "GoogleCloudDiscoveryengineV1betaUpdateTargetSiteMetadata": { + "description": "Metadata related to the progress of the SiteSearchEngineService.UpdateTargetSite operation. This will be returned by the google.longrunning.Operation.metadata field.", + "id": "GoogleCloudDiscoveryengineV1betaUpdateTargetSiteMetadata", + "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" + }, "GoogleCloudDiscoveryengineV1betaUserEvent": { "description": "UserEvent captures all metadata information Discovery Engine API needs to know about how end users interact with customers' website.", "id": "GoogleCloudDiscoveryengineV1betaUserEvent", diff --git a/discoveryengine/v1beta/discoveryengine-gen.go b/discoveryengine/v1beta/discoveryengine-gen.go index 77860246b56..ca60f57d1ad 100644 --- a/discoveryengine/v1beta/discoveryengine-gen.go +++ b/discoveryengine/v1beta/discoveryengine-gen.go @@ -493,6 +493,7 @@ func NewProjectsLocationsDataStoresService(s *Service) *ProjectsLocationsDataSto rs.Operations = NewProjectsLocationsDataStoresOperationsService(s) rs.Schemas = NewProjectsLocationsDataStoresSchemasService(s) rs.ServingConfigs = NewProjectsLocationsDataStoresServingConfigsService(s) + rs.SiteSearchEngine = NewProjectsLocationsDataStoresSiteSearchEngineService(s) rs.SuggestionDenyListEntries = NewProjectsLocationsDataStoresSuggestionDenyListEntriesService(s) rs.UserEvents = NewProjectsLocationsDataStoresUserEventsService(s) return rs @@ -513,6 +514,8 @@ type ProjectsLocationsDataStoresService struct { ServingConfigs *ProjectsLocationsDataStoresServingConfigsService + SiteSearchEngine *ProjectsLocationsDataStoresSiteSearchEngineService + SuggestionDenyListEntries *ProjectsLocationsDataStoresSuggestionDenyListEntriesService UserEvents *ProjectsLocationsDataStoresUserEventsService @@ -608,6 +611,27 @@ type ProjectsLocationsDataStoresServingConfigsService struct { s *Service } +func NewProjectsLocationsDataStoresSiteSearchEngineService(s *Service) *ProjectsLocationsDataStoresSiteSearchEngineService { + rs := &ProjectsLocationsDataStoresSiteSearchEngineService{s: s} + rs.TargetSites = NewProjectsLocationsDataStoresSiteSearchEngineTargetSitesService(s) + return rs +} + +type ProjectsLocationsDataStoresSiteSearchEngineService struct { + s *Service + + TargetSites *ProjectsLocationsDataStoresSiteSearchEngineTargetSitesService +} + +func NewProjectsLocationsDataStoresSiteSearchEngineTargetSitesService(s *Service) *ProjectsLocationsDataStoresSiteSearchEngineTargetSitesService { + rs := &ProjectsLocationsDataStoresSiteSearchEngineTargetSitesService{s: s} + return rs +} + +type ProjectsLocationsDataStoresSiteSearchEngineTargetSitesService struct { + s *Service +} + func NewProjectsLocationsDataStoresSuggestionDenyListEntriesService(s *Service) *ProjectsLocationsDataStoresSuggestionDenyListEntriesService { rs := &ProjectsLocationsDataStoresSuggestionDenyListEntriesService{s: s} return rs @@ -942,9 +966,11 @@ func (s *GoogleCloudDiscoveryengineLoggingSourceLocation) MarshalJSON() ([]byte, return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1CreateSchemaMetadata: Metadata for Create -// Schema LRO. -type GoogleCloudDiscoveryengineV1CreateSchemaMetadata struct { +// GoogleCloudDiscoveryengineV1BatchCreateTargetSiteMetadata: Metadata +// related to the progress of the +// SiteSearchEngineService.BatchCreateTargetSites operation. This will +// be returned by the google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1BatchCreateTargetSiteMetadata struct { // CreateTime: Operation create time. CreateTime string `json:"createTime,omitempty"` @@ -969,23 +995,19 @@ type GoogleCloudDiscoveryengineV1CreateSchemaMetadata struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1CreateSchemaMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1CreateSchemaMetadata +func (s *GoogleCloudDiscoveryengineV1BatchCreateTargetSiteMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1BatchCreateTargetSiteMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1DeleteSchemaMetadata: Metadata for -// DeleteSchema LRO. -type GoogleCloudDiscoveryengineV1DeleteSchemaMetadata 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"` +// GoogleCloudDiscoveryengineV1BatchCreateTargetSitesResponse: Response +// message for SiteSearchEngineService.BatchCreateTargetSites method. +type GoogleCloudDiscoveryengineV1BatchCreateTargetSitesResponse struct { + // TargetSites: TargetSites created. + TargetSites []*GoogleCloudDiscoveryengineV1TargetSite `json:"targetSites,omitempty"` - // ForceSendFields is a list of field names (e.g. "CreateTime") to + // ForceSendFields is a list of field names (e.g. "TargetSites") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -993,35 +1015,29 @@ type GoogleCloudDiscoveryengineV1DeleteSchemaMetadata struct { // This may be used to include empty fields in Patch requests. 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. However, any field with an - // empty value appearing in NullFields will be sent to the server as + // NullFields is a list of field names (e.g. "TargetSites") to include + // in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. However, any field with + // an empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1DeleteSchemaMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1DeleteSchemaMetadata +func (s *GoogleCloudDiscoveryengineV1BatchCreateTargetSitesResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1BatchCreateTargetSitesResponse raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1ImportDocumentsMetadata: Metadata related -// to the progress of the ImportDocuments operation. This is returned by -// the google.longrunning.Operation.metadata field. -type GoogleCloudDiscoveryengineV1ImportDocumentsMetadata struct { +// GoogleCloudDiscoveryengineV1CreateDataStoreMetadata: Metadata related +// to the progress of the DataStoreService.CreateDataStore operation. +// This will be returned by the google.longrunning.Operation.metadata +// field. +type GoogleCloudDiscoveryengineV1CreateDataStoreMetadata struct { // CreateTime: Operation create time. CreateTime string `json:"createTime,omitempty"` - // FailureCount: Count of entries that encountered errors while - // processing. - FailureCount int64 `json:"failureCount,omitempty,string"` - - // SuccessCount: Count of entries that were processed successfully. - SuccessCount int64 `json:"successCount,omitempty,string"` - // UpdateTime: Operation last update time. If the operation is done, // this is also the finish time. UpdateTime string `json:"updateTime,omitempty"` @@ -1043,27 +1059,24 @@ type GoogleCloudDiscoveryengineV1ImportDocumentsMetadata struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1ImportDocumentsMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1ImportDocumentsMetadata +func (s *GoogleCloudDiscoveryengineV1CreateDataStoreMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1CreateDataStoreMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1ImportDocumentsResponse: Response of the -// ImportDocumentsRequest. If the long running operation is done, then -// this message is returned by the -// google.longrunning.Operations.response field if the operation was -// successful. -type GoogleCloudDiscoveryengineV1ImportDocumentsResponse struct { - // ErrorConfig: Echoes the destination for the complete errors in the - // request if set. - ErrorConfig *GoogleCloudDiscoveryengineV1ImportErrorConfig `json:"errorConfig,omitempty"` +// GoogleCloudDiscoveryengineV1CreateEngineMetadata: Metadata related to +// the progress of the EngineService.CreateEngine operation. This will +// be returned by the google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1CreateEngineMetadata struct { + // CreateTime: Operation create time. + CreateTime string `json:"createTime,omitempty"` - // ErrorSamples: A sample of errors encountered while processing the - // request. - ErrorSamples []*GoogleRpcStatus `json:"errorSamples,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. "ErrorConfig") to + // 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. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -1071,31 +1084,32 @@ type GoogleCloudDiscoveryengineV1ImportDocumentsResponse struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "ErrorConfig") to include - // in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. However, any field with - // an empty value appearing in NullFields will be sent to the server as + // 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. However, any field with an + // empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1ImportDocumentsResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1ImportDocumentsResponse +func (s *GoogleCloudDiscoveryengineV1CreateEngineMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1CreateEngineMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1ImportErrorConfig: Configuration of -// destination for Import related errors. -type GoogleCloudDiscoveryengineV1ImportErrorConfig struct { - // GcsPrefix: Cloud Storage prefix for import errors. This must be an - // empty, existing Cloud Storage directory. Import errors are written to - // sharded files in this directory, one per line, as a JSON-encoded - // `google.rpc.Status` message. - GcsPrefix string `json:"gcsPrefix,omitempty"` +// GoogleCloudDiscoveryengineV1CreateSchemaMetadata: Metadata for Create +// Schema LRO. +type GoogleCloudDiscoveryengineV1CreateSchemaMetadata struct { + // CreateTime: Operation create time. + CreateTime string `json:"createTime,omitempty"` - // ForceSendFields is a list of field names (e.g. "GcsPrefix") to + // 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. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -1103,7 +1117,7 @@ type GoogleCloudDiscoveryengineV1ImportErrorConfig struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "GcsPrefix") to include in + // 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. However, any field with an // empty value appearing in NullFields will be sent to the server as @@ -1112,17 +1126,17 @@ type GoogleCloudDiscoveryengineV1ImportErrorConfig struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1ImportErrorConfig) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1ImportErrorConfig +func (s *GoogleCloudDiscoveryengineV1CreateSchemaMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1CreateSchemaMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1ImportSuggestionDenyListEntriesMetadata: -// Metadata related to the progress of the -// ImportSuggestionDenyListEntries operation. This is returned by the -// google.longrunning.Operation.metadata field. -type GoogleCloudDiscoveryengineV1ImportSuggestionDenyListEntriesMetadata struct { +// GoogleCloudDiscoveryengineV1CreateTargetSiteMetadata: Metadata +// related to the progress of the +// SiteSearchEngineService.CreateTargetSite operation. This will be +// returned by the google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1CreateTargetSiteMetadata struct { // CreateTime: Operation create time. CreateTime string `json:"createTime,omitempty"` @@ -1147,29 +1161,71 @@ type GoogleCloudDiscoveryengineV1ImportSuggestionDenyListEntriesMetadata struct NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1ImportSuggestionDenyListEntriesMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1ImportSuggestionDenyListEntriesMetadata +func (s *GoogleCloudDiscoveryengineV1CreateTargetSiteMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1CreateTargetSiteMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1ImportSuggestionDenyListEntriesResponse: -// Response message for -// CompletionService.ImportSuggestionDenyListEntries method. -type GoogleCloudDiscoveryengineV1ImportSuggestionDenyListEntriesResponse struct { - // ErrorSamples: A sample of errors encountered while processing the - // request. - ErrorSamples []*GoogleRpcStatus `json:"errorSamples,omitempty"` +// GoogleCloudDiscoveryengineV1DataStore: DataStore captures global +// settings and configs at the DataStore level. +type GoogleCloudDiscoveryengineV1DataStore struct { + // ContentConfig: Immutable. The content config of the data store. If + // this field is unset, the server behavior defaults to + // ContentConfig.NO_CONTENT. + // + // Possible values: + // "CONTENT_CONFIG_UNSPECIFIED" - Default value. + // "NO_CONTENT" - Only contains documents without any + // Document.content. + // "CONTENT_REQUIRED" - Only contains documents with Document.content. + // "PUBLIC_WEBSITE" - The data store is used for public website + // search. + ContentConfig string `json:"contentConfig,omitempty"` - // FailedEntriesCount: Count of deny list entries that failed to be - // imported. - FailedEntriesCount int64 `json:"failedEntriesCount,omitempty,string"` + // CreateTime: Output only. Timestamp the DataStore was created at. + CreateTime string `json:"createTime,omitempty"` - // ImportedEntriesCount: Count of deny list entries successfully - // imported. - ImportedEntriesCount int64 `json:"importedEntriesCount,omitempty,string"` + // DefaultSchemaId: Output only. The id of the default Schema + // asscociated to this data store. + DefaultSchemaId string `json:"defaultSchemaId,omitempty"` - // ForceSendFields is a list of field names (e.g. "ErrorSamples") to + // DisplayName: Required. The data store display name. This field must + // be a UTF-8 encoded string with a length limit of 128 characters. + // Otherwise, an INVALID_ARGUMENT error is returned. + DisplayName string `json:"displayName,omitempty"` + + // IndustryVertical: Immutable. The industry vertical that the data + // store registers. + // + // Possible values: + // "INDUSTRY_VERTICAL_UNSPECIFIED" - Value used when unset. + // "GENERIC" - The generic vertical for documents that are not + // specific to any industry vertical. + // "MEDIA" - The media industry vertical. + IndustryVertical string `json:"industryVertical,omitempty"` + + // Name: Immutable. The full resource name of the data store. Format: + // `projects/{project}/locations/{location}/collections/{collection_id}/d + // ataStores/{data_store_id}`. This field must be a UTF-8 encoded string + // with a length limit of 1024 characters. + Name string `json:"name,omitempty"` + + // SolutionTypes: The solutions that the data store enrolls. Available + // solutions for each industry_vertical: * `MEDIA`: + // `SOLUTION_TYPE_RECOMMENDATION` and `SOLUTION_TYPE_SEARCH`. * + // `SITE_SEARCH`: `SOLUTION_TYPE_SEARCH` is automatically enrolled. + // Other solutions cannot be enrolled. + // + // Possible values: + // "SOLUTION_TYPE_UNSPECIFIED" - Default value. + // "SOLUTION_TYPE_RECOMMENDATION" - Used for Recommendations AI. + // "SOLUTION_TYPE_SEARCH" - Used for Discovery Search. + // "SOLUTION_TYPE_CHAT" - Used for use cases related to the Generative + // AI agent. + SolutionTypes []string `json:"solutionTypes,omitempty"` + + // ForceSendFields is a list of field names (e.g. "ContentConfig") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -1177,7 +1233,7 @@ type GoogleCloudDiscoveryengineV1ImportSuggestionDenyListEntriesResponse struct // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "ErrorSamples") to include + // NullFields is a list of field names (e.g. "ContentConfig") to include // in API requests with the JSON null value. By default, fields with // empty values are omitted from API requests. However, any field with // an empty value appearing in NullFields will be sent to the server as @@ -1186,26 +1242,20 @@ type GoogleCloudDiscoveryengineV1ImportSuggestionDenyListEntriesResponse struct NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1ImportSuggestionDenyListEntriesResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1ImportSuggestionDenyListEntriesResponse +func (s *GoogleCloudDiscoveryengineV1DataStore) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1DataStore raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1ImportUserEventsMetadata: Metadata -// related to the progress of the Import operation. This is returned by -// the google.longrunning.Operation.metadata field. -type GoogleCloudDiscoveryengineV1ImportUserEventsMetadata struct { +// GoogleCloudDiscoveryengineV1DeleteDataStoreMetadata: Metadata related +// to the progress of the DataStoreService.DeleteDataStore operation. +// This will be returned by the google.longrunning.Operation.metadata +// field. +type GoogleCloudDiscoveryengineV1DeleteDataStoreMetadata struct { // CreateTime: Operation create time. CreateTime string `json:"createTime,omitempty"` - // FailureCount: Count of entries that encountered errors while - // processing. - FailureCount int64 `json:"failureCount,omitempty,string"` - - // SuccessCount: Count of entries that were processed successfully. - SuccessCount int64 `json:"successCount,omitempty,string"` - // UpdateTime: Operation last update time. If the operation is done, // this is also the finish time. UpdateTime string `json:"updateTime,omitempty"` @@ -1227,35 +1277,24 @@ type GoogleCloudDiscoveryengineV1ImportUserEventsMetadata struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1ImportUserEventsMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1ImportUserEventsMetadata +func (s *GoogleCloudDiscoveryengineV1DeleteDataStoreMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1DeleteDataStoreMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1ImportUserEventsResponse: Response of the -// ImportUserEventsRequest. If the long running operation was -// successful, then this message is returned by the -// google.longrunning.Operations.response field if the operation was -// successful. -type GoogleCloudDiscoveryengineV1ImportUserEventsResponse struct { - // ErrorConfig: Echoes the destination for the complete errors if this - // field was set in the request. - ErrorConfig *GoogleCloudDiscoveryengineV1ImportErrorConfig `json:"errorConfig,omitempty"` - - // ErrorSamples: A sample of errors encountered while processing the - // request. - ErrorSamples []*GoogleRpcStatus `json:"errorSamples,omitempty"` - - // JoinedEventsCount: Count of user events imported with complete - // existing Documents. - JoinedEventsCount int64 `json:"joinedEventsCount,omitempty,string"` +// GoogleCloudDiscoveryengineV1DeleteEngineMetadata: Metadata related to +// the progress of the EngineService.DeleteEngine operation. This will +// be returned by the google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1DeleteEngineMetadata struct { + // CreateTime: Operation create time. + CreateTime string `json:"createTime,omitempty"` - // UnjoinedEventsCount: Count of user events imported, but with Document - // information not found in the existing Branch. - UnjoinedEventsCount int64 `json:"unjoinedEventsCount,omitempty,string"` + // 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. "ErrorConfig") to + // 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. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -1263,35 +1302,27 @@ type GoogleCloudDiscoveryengineV1ImportUserEventsResponse struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "ErrorConfig") to include - // in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. However, any field with - // an empty value appearing in NullFields will be sent to the server as + // 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. However, any field with an + // empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1ImportUserEventsResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1ImportUserEventsResponse +func (s *GoogleCloudDiscoveryengineV1DeleteEngineMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1DeleteEngineMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1PurgeDocumentsMetadata: Metadata related -// to the progress of the PurgeDocuments operation. This will be -// returned by the google.longrunning.Operation.metadata field. -type GoogleCloudDiscoveryengineV1PurgeDocumentsMetadata struct { +// GoogleCloudDiscoveryengineV1DeleteSchemaMetadata: Metadata for +// DeleteSchema LRO. +type GoogleCloudDiscoveryengineV1DeleteSchemaMetadata struct { // CreateTime: Operation create time. CreateTime string `json:"createTime,omitempty"` - // FailureCount: Count of entries that encountered errors while - // processing. - FailureCount int64 `json:"failureCount,omitempty,string"` - - // SuccessCount: Count of entries that were deleted successfully. - SuccessCount int64 `json:"successCount,omitempty,string"` - // UpdateTime: Operation last update time. If the operation is done, // this is also the finish time. UpdateTime string `json:"updateTime,omitempty"` @@ -1313,27 +1344,25 @@ type GoogleCloudDiscoveryengineV1PurgeDocumentsMetadata struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1PurgeDocumentsMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1PurgeDocumentsMetadata +func (s *GoogleCloudDiscoveryengineV1DeleteSchemaMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1DeleteSchemaMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1PurgeDocumentsResponse: Response message -// for DocumentService.PurgeDocuments method. If the long running -// operation is successfully done, then this message is returned by the -// google.longrunning.Operations.response field. -type GoogleCloudDiscoveryengineV1PurgeDocumentsResponse struct { - // PurgeCount: The total count of documents purged as a result of the - // operation. - PurgeCount int64 `json:"purgeCount,omitempty,string"` +// GoogleCloudDiscoveryengineV1DeleteTargetSiteMetadata: Metadata +// related to the progress of the +// SiteSearchEngineService.DeleteTargetSite operation. This will be +// returned by the google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1DeleteTargetSiteMetadata struct { + // CreateTime: Operation create time. + CreateTime string `json:"createTime,omitempty"` - // PurgeSample: A sample of document names that will be deleted. Only - // populated if `force` is set to false. A max of 100 names will be - // returned and the names are chosen at random. - PurgeSample []string `json:"purgeSample,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. "PurgeCount") to + // 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. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -1341,7 +1370,7 @@ type GoogleCloudDiscoveryengineV1PurgeDocumentsResponse struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "PurgeCount") to include in + // 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. However, any field with an // empty value appearing in NullFields will be sent to the server as @@ -1350,17 +1379,17 @@ type GoogleCloudDiscoveryengineV1PurgeDocumentsResponse struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1PurgeDocumentsResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1PurgeDocumentsResponse +func (s *GoogleCloudDiscoveryengineV1DeleteTargetSiteMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1DeleteTargetSiteMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1PurgeSuggestionDenyListEntriesMetadata: +// GoogleCloudDiscoveryengineV1DisableAdvancedSiteSearchMetadata: // Metadata related to the progress of the -// PurgeSuggestionDenyListEntries operation. This is returned by the -// google.longrunning.Operation.metadata field. -type GoogleCloudDiscoveryengineV1PurgeSuggestionDenyListEntriesMetadata struct { +// SiteSearchEngineService.DisableAdvancedSiteSearch operation. This +// will be returned by the google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1DisableAdvancedSiteSearchMetadata struct { // CreateTime: Operation create time. CreateTime string `json:"createTime,omitempty"` @@ -1385,24 +1414,31 @@ type GoogleCloudDiscoveryengineV1PurgeSuggestionDenyListEntriesMetadata struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1PurgeSuggestionDenyListEntriesMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1PurgeSuggestionDenyListEntriesMetadata +func (s *GoogleCloudDiscoveryengineV1DisableAdvancedSiteSearchMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1DisableAdvancedSiteSearchMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1PurgeSuggestionDenyListEntriesResponse: -// Response message for CompletionService.PurgeSuggestionDenyListEntries -// method. -type GoogleCloudDiscoveryengineV1PurgeSuggestionDenyListEntriesResponse struct { - // ErrorSamples: A sample of errors encountered while processing the - // request. - ErrorSamples []*GoogleRpcStatus `json:"errorSamples,omitempty"` +// GoogleCloudDiscoveryengineV1DisableAdvancedSiteSearchResponse: +// Response message for +// SiteSearchEngineService.DisableAdvancedSiteSearch method. +type GoogleCloudDiscoveryengineV1DisableAdvancedSiteSearchResponse struct { +} - // PurgeCount: Number of suggestion deny list entries purged. - PurgeCount int64 `json:"purgeCount,omitempty,string"` +// GoogleCloudDiscoveryengineV1EnableAdvancedSiteSearchMetadata: +// Metadata related to the progress of the +// SiteSearchEngineService.EnableAdvancedSiteSearch operation. This will +// be returned by the google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1EnableAdvancedSiteSearchMetadata struct { + // CreateTime: Operation create time. + CreateTime string `json:"createTime,omitempty"` - // ForceSendFields is a list of field names (e.g. "ErrorSamples") to + // 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. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -1410,38 +1446,99 @@ type GoogleCloudDiscoveryengineV1PurgeSuggestionDenyListEntriesResponse struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "ErrorSamples") to include - // in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. However, any field with - // an empty value appearing in NullFields will be sent to the server as + // 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. However, any field with an + // empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1PurgeSuggestionDenyListEntriesResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1PurgeSuggestionDenyListEntriesResponse +func (s *GoogleCloudDiscoveryengineV1EnableAdvancedSiteSearchMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1EnableAdvancedSiteSearchMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1Schema: Defines the structure and layout -// of a type of document data. -type GoogleCloudDiscoveryengineV1Schema struct { - // JsonSchema: The JSON representation of the schema. - JsonSchema string `json:"jsonSchema,omitempty"` +// GoogleCloudDiscoveryengineV1EnableAdvancedSiteSearchResponse: +// Response message for SiteSearchEngineService.EnableAdvancedSiteSearch +// method. +type GoogleCloudDiscoveryengineV1EnableAdvancedSiteSearchResponse struct { +} - // Name: Immutable. The full resource name of the schema, in the format - // of - // `projects/{project}/locations/{location}/collections/{collection}/data - // Stores/{data_store}/schemas/{schema}`. This field must be a UTF-8 - // encoded string with a length limit of 1024 characters. +// GoogleCloudDiscoveryengineV1Engine: Metadata that describes the +// training and serving parameters of an Engine. +type GoogleCloudDiscoveryengineV1Engine struct { + // ChatEngineConfig: Configurations for the Chat Engine. Only applicable + // if solution_type is SOLUTION_TYPE_CHAT. + ChatEngineConfig *GoogleCloudDiscoveryengineV1EngineChatEngineConfig `json:"chatEngineConfig,omitempty"` + + // ChatEngineMetadata: Output only. Additional information of the Chat + // Engine. Only applicable if solution_type is SOLUTION_TYPE_CHAT. + ChatEngineMetadata *GoogleCloudDiscoveryengineV1EngineChatEngineMetadata `json:"chatEngineMetadata,omitempty"` + + // CommonConfig: Common config spec that specifies the metadata of the + // engine. + CommonConfig *GoogleCloudDiscoveryengineV1EngineCommonConfig `json:"commonConfig,omitempty"` + + // CreateTime: Output only. Timestamp the Recommendation Engine was + // created at. + CreateTime string `json:"createTime,omitempty"` + + // DataStoreIds: The data stores associated with this engine. For + // SOLUTION_TYPE_SEARCH and SOLUTION_TYPE_RECOMMENDATION type of + // engines, they can only associate with at most one data store. If + // solution_type is SOLUTION_TYPE_CHAT, multiple DataStores in the same + // Collection can be associated here. Note that when used in + // CreateEngineRequest, one DataStore id must be provided as the system + // will use it for necessary initializations. + DataStoreIds []string `json:"dataStoreIds,omitempty"` + + // DisplayName: Required. The display name of the engine. Should be + // human readable. UTF-8 encoded string with limit of 1024 characters. + DisplayName string `json:"displayName,omitempty"` + + // IndustryVertical: The industry vertical that the engine registers. + // The restriction of the Engine industry vertical is based on + // DataStore: If unspecified, default to `GENERIC`. Vertical on Engine + // has to match vertical of the DataStore liniked to the engine. + // + // Possible values: + // "INDUSTRY_VERTICAL_UNSPECIFIED" - Value used when unset. + // "GENERIC" - The generic vertical for documents that are not + // specific to any industry vertical. + // "MEDIA" - The media industry vertical. + IndustryVertical string `json:"industryVertical,omitempty"` + + // Name: Immutable. The fully qualified resource name of the engine. + // This field must be a UTF-8 encoded string with a length limit of 1024 + // characters. Format: + // `projects/{project_number}/locations/{location}/collections/{collectio + // n}/engines/{engine}` engine should be 1-63 characters, and valid + // characters are /a-z0-9*/. Otherwise, an INVALID_ARGUMENT error is + // returned. Name string `json:"name,omitempty"` - // StructSchema: The structured representation of the schema. - StructSchema googleapi.RawMessage `json:"structSchema,omitempty"` + // SearchEngineConfig: Configurations for the Search Engine. Only + // applicable if solution_type is SOLUTION_TYPE_SEARCH. + SearchEngineConfig *GoogleCloudDiscoveryengineV1EngineSearchEngineConfig `json:"searchEngineConfig,omitempty"` - // ForceSendFields is a list of field names (e.g. "JsonSchema") to + // SolutionType: Required. The solutions of the engine. + // + // Possible values: + // "SOLUTION_TYPE_UNSPECIFIED" - Default value. + // "SOLUTION_TYPE_RECOMMENDATION" - Used for Recommendations AI. + // "SOLUTION_TYPE_SEARCH" - Used for Discovery Search. + // "SOLUTION_TYPE_CHAT" - Used for use cases related to the Generative + // AI agent. + SolutionType string `json:"solutionType,omitempty"` + + // UpdateTime: Output only. Timestamp the Recommendation Engine was last + // updated. + UpdateTime string `json:"updateTime,omitempty"` + + // ForceSendFields is a list of field names (e.g. "ChatEngineConfig") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -1449,67 +1546,100 @@ type GoogleCloudDiscoveryengineV1Schema struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "JsonSchema") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "ChatEngineConfig") to + // include in API requests with the JSON null value. By default, fields + // with empty values are omitted from API requests. However, any field + // with an empty value appearing in NullFields will be sent to the + // server as null. It is an error if a field in this list has a + // non-empty value. This may be used to include null fields in Patch + // requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1Schema) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1Schema +func (s *GoogleCloudDiscoveryengineV1Engine) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1Engine raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1UpdateSchemaMetadata: Metadata for -// UpdateSchema LRO. -type GoogleCloudDiscoveryengineV1UpdateSchemaMetadata struct { - // CreateTime: Operation create time. - CreateTime string `json:"createTime,omitempty"` +// GoogleCloudDiscoveryengineV1EngineChatEngineConfig: Configurations +// for a Chat Engine. +type GoogleCloudDiscoveryengineV1EngineChatEngineConfig struct { + // AgentCreationConfig: The configurationt generate the Dialogflow agent + // that is associated to this Engine. Note that these configurations are + // one-time consumed by and passed to Dialogflow service. It means they + // cannot be retrieved using EngineService.GetEngine or + // EngineService.ListEngines API after engine creation. + AgentCreationConfig *GoogleCloudDiscoveryengineV1EngineChatEngineConfigAgentCreationConfig `json:"agentCreationConfig,omitempty"` - // UpdateTime: Operation last update time. If the operation is done, - // this is also the finish time. - UpdateTime string `json:"updateTime,omitempty"` + // DialogflowAgentToLink: The resource name of an exist Dialogflow agent + // to link to this Chat Engine. Customers can either provide + // `agent_creation_config` to create agent or provide an agent name that + // links the agent with the Chat engine. Format: + // `projects//locations//agents/`. Note that the + // `dialogflow_agent_to_link` are one-time consumed by and passed to + // Dialogflow service. It means they cannot be retrieved using + // EngineService.GetEngine or EngineService.ListEngines API after engine + // creation. Please use ChatEngineMetadata.dialogflow_agent for actual + // agent association after Engine is created. + DialogflowAgentToLink string `json:"dialogflowAgentToLink,omitempty"` - // ForceSendFields is a list of field names (e.g. "CreateTime") to - // unconditionally include in API requests. By default, fields with + // ForceSendFields is a list of field names (e.g. "AgentCreationConfig") + // to unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be // sent to the server regardless of whether the field is empty or not. // This may be used to include empty fields in Patch requests. 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. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "AgentCreationConfig") to + // include in API requests with the JSON null value. By default, fields + // with empty values are omitted from API requests. However, any field + // with an empty value appearing in NullFields will be sent to the + // server as null. It is an error if a field in this list has a + // non-empty value. This may be used to include null fields in Patch + // requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1UpdateSchemaMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1UpdateSchemaMetadata +func (s *GoogleCloudDiscoveryengineV1EngineChatEngineConfig) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1EngineChatEngineConfig raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaBatchCreateTargetSiteMetadata: -// Metadata related to the progress of the -// SiteSearchEngineService.BatchCreateTargetSites operation. This will -// be returned by the google.longrunning.Operation.metadata field. -type GoogleCloudDiscoveryengineV1alphaBatchCreateTargetSiteMetadata struct { - // CreateTime: Operation create time. - CreateTime string `json:"createTime,omitempty"` +// GoogleCloudDiscoveryengineV1EngineChatEngineConfigAgentCreationConfig: +// +// Configurations for generating a Dialogflow agent. Note that these +// +// configurations are one-time consumed by and passed to Dialogflow +// service. It means they cannot be retrieved using +// EngineService.GetEngine or EngineService.ListEngines API after engine +// creation. +type GoogleCloudDiscoveryengineV1EngineChatEngineConfigAgentCreationConfig struct { + // Business: Name of the company, organization or other entity that the + // agent represents. Used for knowledge connector LLM prompt and for + // knowledge search. + Business string `json:"business,omitempty"` - // UpdateTime: Operation last update time. If the operation is done, - // this is also the finish time. - UpdateTime string `json:"updateTime,omitempty"` + // DefaultLanguageCode: Required. The default language of the agent as a + // language tag. See Language Support + // (https://cloud.google.com/dialogflow/docs/reference/language) for a + // list of the currently supported language codes. + DefaultLanguageCode string `json:"defaultLanguageCode,omitempty"` - // ForceSendFields is a list of field names (e.g. "CreateTime") to + // Location: Agent location for Agent creation, supported values: + // global/us/eu. If not provided, us Engine will create Agent using + // us-central-1 by default; eu Engine will create Agent using eu-west-1 + // by default. + Location string `json:"location,omitempty"` + + // TimeZone: Required. The time zone of the agent from the time zone + // database (https://www.iana.org/time-zones), e.g., America/New_York, + // Europe/Paris. + TimeZone string `json:"timeZone,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Business") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -1517,7 +1647,7 @@ type GoogleCloudDiscoveryengineV1alphaBatchCreateTargetSiteMetadata struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "CreateTime") to include in + // NullFields is a list of field names (e.g. "Business") to include in // API requests with the JSON null value. By default, fields with empty // values are omitted from API requests. However, any field with an // empty value appearing in NullFields will be sent to the server as @@ -1526,20 +1656,20 @@ type GoogleCloudDiscoveryengineV1alphaBatchCreateTargetSiteMetadata struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaBatchCreateTargetSiteMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaBatchCreateTargetSiteMetadata +func (s *GoogleCloudDiscoveryengineV1EngineChatEngineConfigAgentCreationConfig) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1EngineChatEngineConfigAgentCreationConfig raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaBatchCreateTargetSitesResponse: -// Response message for SiteSearchEngineService.BatchCreateTargetSites -// method. -type GoogleCloudDiscoveryengineV1alphaBatchCreateTargetSitesResponse struct { - // TargetSites: TargetSites created. - TargetSites []*GoogleCloudDiscoveryengineV1alphaTargetSite `json:"targetSites,omitempty"` +// GoogleCloudDiscoveryengineV1EngineChatEngineMetadata: Additional +// information of a Chat Engine. Fields in this message are output only. +type GoogleCloudDiscoveryengineV1EngineChatEngineMetadata struct { + // DialogflowAgent: The resource name of a Dialogflow agent, that this + // Chat Engine refers to. Format: `projects//locations//agents/`. + DialogflowAgent string `json:"dialogflowAgent,omitempty"` - // ForceSendFields is a list of field names (e.g. "TargetSites") to + // ForceSendFields is a list of field names (e.g. "DialogflowAgent") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -1547,34 +1677,31 @@ type GoogleCloudDiscoveryengineV1alphaBatchCreateTargetSitesResponse struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "TargetSites") to include - // in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. However, any field with - // an empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "DialogflowAgent") to + // include in API requests with the JSON null value. By default, fields + // with empty values are omitted from API requests. However, any field + // with an empty value appearing in NullFields will be sent to the + // server as null. It is an error if a field in this list has a + // non-empty value. This may be used to include null fields in Patch + // requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaBatchCreateTargetSitesResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaBatchCreateTargetSitesResponse +func (s *GoogleCloudDiscoveryengineV1EngineChatEngineMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1EngineChatEngineMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaCreateDataStoreMetadata: Metadata -// related to the progress of the DataStoreService.CreateDataStore -// operation. This will be returned by the -// google.longrunning.Operation.metadata field. -type GoogleCloudDiscoveryengineV1alphaCreateDataStoreMetadata 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"` +// GoogleCloudDiscoveryengineV1EngineCommonConfig: Common configurations +// for an Engine. +type GoogleCloudDiscoveryengineV1EngineCommonConfig struct { + // CompanyName: Immutable. The name of the company, business or entity + // that is associated with the engine. Setting this may help improve LLM + // related features. + CompanyName string `json:"companyName,omitempty"` - // ForceSendFields is a list of field names (e.g. "CreateTime") to + // ForceSendFields is a list of field names (e.g. "CompanyName") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -1582,34 +1709,45 @@ type GoogleCloudDiscoveryengineV1alphaCreateDataStoreMetadata struct { // This may be used to include empty fields in Patch requests. 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. However, any field with an - // empty value appearing in NullFields will be sent to the server as + // NullFields is a list of field names (e.g. "CompanyName") to include + // in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. However, any field with + // an empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaCreateDataStoreMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaCreateDataStoreMetadata +func (s *GoogleCloudDiscoveryengineV1EngineCommonConfig) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1EngineCommonConfig raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaCreateEngineMetadata: Metadata -// related to the progress of the EngineService.CreateEngine operation. -// This will be returned by the google.longrunning.Operation.metadata -// field. -type GoogleCloudDiscoveryengineV1alphaCreateEngineMetadata struct { - // CreateTime: Operation create time. - CreateTime string `json:"createTime,omitempty"` +// GoogleCloudDiscoveryengineV1EngineSearchEngineConfig: Configurations +// for a Search Engine. +type GoogleCloudDiscoveryengineV1EngineSearchEngineConfig struct { + // SearchAddOns: The add-on that this search engine enables. + // + // Possible values: + // "SEARCH_ADD_ON_UNSPECIFIED" - Default value when the enum is + // unspecified. This is invalid to use. + // "SEARCH_ADD_ON_LLM" - Large language model add-on. + SearchAddOns []string `json:"searchAddOns,omitempty"` - // UpdateTime: Operation last update time. If the operation is done, - // this is also the finish time. - UpdateTime string `json:"updateTime,omitempty"` + // SearchTier: The search feature tier of this engine. Different tiers + // might have different pricing. To learn more, please check the pricing + // documentation. Defaults to SearchTier.SEARCH_TIER_STANDARD if not + // specified. + // + // Possible values: + // "SEARCH_TIER_UNSPECIFIED" - Default value when the enum is + // unspecified. This is invalid to use. + // "SEARCH_TIER_STANDARD" - Standard tier. + // "SEARCH_TIER_ENTERPRISE" - Enterprise tier. + SearchTier string `json:"searchTier,omitempty"` - // ForceSendFields is a list of field names (e.g. "CreateTime") to + // ForceSendFields is a list of field names (e.g. "SearchAddOns") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -1617,61 +1755,34 @@ type GoogleCloudDiscoveryengineV1alphaCreateEngineMetadata struct { // This may be used to include empty fields in Patch requests. 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. However, any field with an - // empty value appearing in NullFields will be sent to the server as + // NullFields is a list of field names (e.g. "SearchAddOns") to include + // in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. However, any field with + // an empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaCreateEngineMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaCreateEngineMetadata +func (s *GoogleCloudDiscoveryengineV1EngineSearchEngineConfig) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1EngineSearchEngineConfig raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaCreateSchemaMetadata: Metadata for -// Create Schema LRO. -type GoogleCloudDiscoveryengineV1alphaCreateSchemaMetadata struct { +// GoogleCloudDiscoveryengineV1ImportDocumentsMetadata: Metadata related +// to the progress of the ImportDocuments operation. This is returned by +// the google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1ImportDocumentsMetadata 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. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. - 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. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. - NullFields []string `json:"-"` -} - -func (s *GoogleCloudDiscoveryengineV1alphaCreateSchemaMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaCreateSchemaMetadata - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) -} + // FailureCount: Count of entries that encountered errors while + // processing. + FailureCount int64 `json:"failureCount,omitempty,string"` -// GoogleCloudDiscoveryengineV1alphaCreateTargetSiteMetadata: Metadata -// related to the progress of the -// SiteSearchEngineService.CreateTargetSite operation. This will be -// returned by the google.longrunning.Operation.metadata field. -type GoogleCloudDiscoveryengineV1alphaCreateTargetSiteMetadata struct { - // CreateTime: Operation create time. - CreateTime string `json:"createTime,omitempty"` + // SuccessCount: Count of entries that were processed successfully. + SuccessCount int64 `json:"successCount,omitempty,string"` // UpdateTime: Operation last update time. If the operation is done, // this is also the finish time. @@ -1694,71 +1805,27 @@ type GoogleCloudDiscoveryengineV1alphaCreateTargetSiteMetadata struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaCreateTargetSiteMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaCreateTargetSiteMetadata +func (s *GoogleCloudDiscoveryengineV1ImportDocumentsMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1ImportDocumentsMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaDataStore: DataStore captures global -// settings and configs at the DataStore level. -type GoogleCloudDiscoveryengineV1alphaDataStore struct { - // ContentConfig: Immutable. The content config of the data store. If - // this field is unset, the server behavior defaults to - // ContentConfig.NO_CONTENT. - // - // Possible values: - // "CONTENT_CONFIG_UNSPECIFIED" - Default value. - // "NO_CONTENT" - Only contains documents without any - // Document.content. - // "CONTENT_REQUIRED" - Only contains documents with Document.content. - // "PUBLIC_WEBSITE" - The data store is used for public website - // search. - ContentConfig string `json:"contentConfig,omitempty"` - - // CreateTime: Output only. Timestamp the DataStore was created at. - CreateTime string `json:"createTime,omitempty"` - - // DefaultSchemaId: Output only. The id of the default Schema - // asscociated to this data store. - DefaultSchemaId string `json:"defaultSchemaId,omitempty"` - - // DisplayName: Required. The data store display name. This field must - // be a UTF-8 encoded string with a length limit of 128 characters. - // Otherwise, an INVALID_ARGUMENT error is returned. - DisplayName string `json:"displayName,omitempty"` - - // IndustryVertical: Immutable. The industry vertical that the data - // store registers. - // - // Possible values: - // "INDUSTRY_VERTICAL_UNSPECIFIED" - Value used when unset. - // "GENERIC" - The generic vertical for documents that are not - // specific to any industry vertical. - // "MEDIA" - The media industry vertical. - IndustryVertical string `json:"industryVertical,omitempty"` - - // Name: Immutable. The full resource name of the data store. Format: - // `projects/{project}/locations/{location}/collections/{collection_id}/d - // ataStores/{data_store_id}`. This field must be a UTF-8 encoded string - // with a length limit of 1024 characters. - Name string `json:"name,omitempty"` +// GoogleCloudDiscoveryengineV1ImportDocumentsResponse: Response of the +// ImportDocumentsRequest. If the long running operation is done, then +// this message is returned by the +// google.longrunning.Operations.response field if the operation was +// successful. +type GoogleCloudDiscoveryengineV1ImportDocumentsResponse struct { + // ErrorConfig: Echoes the destination for the complete errors in the + // request if set. + ErrorConfig *GoogleCloudDiscoveryengineV1ImportErrorConfig `json:"errorConfig,omitempty"` - // SolutionTypes: The solutions that the data store enrolls. Available - // solutions for each industry_vertical: * `MEDIA`: - // `SOLUTION_TYPE_RECOMMENDATION` and `SOLUTION_TYPE_SEARCH`. * - // `SITE_SEARCH`: `SOLUTION_TYPE_SEARCH` is automatically enrolled. - // Other solutions cannot be enrolled. - // - // Possible values: - // "SOLUTION_TYPE_UNSPECIFIED" - Default value. - // "SOLUTION_TYPE_RECOMMENDATION" - Used for Recommendations AI. - // "SOLUTION_TYPE_SEARCH" - Used for Discovery Search. - // "SOLUTION_TYPE_CHAT" - Used for use cases related to the Generative - // AI agent. - SolutionTypes []string `json:"solutionTypes,omitempty"` + // ErrorSamples: A sample of errors encountered while processing the + // request. + ErrorSamples []*GoogleRpcStatus `json:"errorSamples,omitempty"` - // ForceSendFields is a list of field names (e.g. "ContentConfig") to + // ForceSendFields is a list of field names (e.g. "ErrorConfig") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -1766,7 +1833,7 @@ type GoogleCloudDiscoveryengineV1alphaDataStore struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "ContentConfig") to include + // NullFields is a list of field names (e.g. "ErrorConfig") to include // in API requests with the JSON null value. By default, fields with // empty values are omitted from API requests. However, any field with // an empty value appearing in NullFields will be sent to the server as @@ -1775,25 +1842,22 @@ type GoogleCloudDiscoveryengineV1alphaDataStore struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaDataStore) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaDataStore +func (s *GoogleCloudDiscoveryengineV1ImportDocumentsResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1ImportDocumentsResponse raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaDeleteDataStoreMetadata: Metadata -// related to the progress of the DataStoreService.DeleteDataStore -// operation. This will be returned by the -// google.longrunning.Operation.metadata field. -type GoogleCloudDiscoveryengineV1alphaDeleteDataStoreMetadata 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"` +// GoogleCloudDiscoveryengineV1ImportErrorConfig: Configuration of +// destination for Import related errors. +type GoogleCloudDiscoveryengineV1ImportErrorConfig struct { + // GcsPrefix: Cloud Storage prefix for import errors. This must be an + // empty, existing Cloud Storage directory. Import errors are written to + // sharded files in this directory, one per line, as a JSON-encoded + // `google.rpc.Status` message. + GcsPrefix string `json:"gcsPrefix,omitempty"` - // ForceSendFields is a list of field names (e.g. "CreateTime") to + // ForceSendFields is a list of field names (e.g. "GcsPrefix") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -1801,7 +1865,7 @@ type GoogleCloudDiscoveryengineV1alphaDeleteDataStoreMetadata struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "CreateTime") to include in + // NullFields is a list of field names (e.g. "GcsPrefix") to include in // API requests with the JSON null value. By default, fields with empty // values are omitted from API requests. However, any field with an // empty value appearing in NullFields will be sent to the server as @@ -1810,17 +1874,17 @@ type GoogleCloudDiscoveryengineV1alphaDeleteDataStoreMetadata struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaDeleteDataStoreMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaDeleteDataStoreMetadata +func (s *GoogleCloudDiscoveryengineV1ImportErrorConfig) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1ImportErrorConfig raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaDeleteEngineMetadata: Metadata -// related to the progress of the EngineService.DeleteEngine operation. -// This will be returned by the google.longrunning.Operation.metadata -// field. -type GoogleCloudDiscoveryengineV1alphaDeleteEngineMetadata struct { +// GoogleCloudDiscoveryengineV1ImportSuggestionDenyListEntriesMetadata: +// Metadata related to the progress of the +// ImportSuggestionDenyListEntries operation. This is returned by the +// google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1ImportSuggestionDenyListEntriesMetadata struct { // CreateTime: Operation create time. CreateTime string `json:"createTime,omitempty"` @@ -1845,23 +1909,29 @@ type GoogleCloudDiscoveryengineV1alphaDeleteEngineMetadata struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaDeleteEngineMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaDeleteEngineMetadata +func (s *GoogleCloudDiscoveryengineV1ImportSuggestionDenyListEntriesMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1ImportSuggestionDenyListEntriesMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaDeleteSchemaMetadata: Metadata for -// DeleteSchema LRO. -type GoogleCloudDiscoveryengineV1alphaDeleteSchemaMetadata struct { - // CreateTime: Operation create time. - CreateTime string `json:"createTime,omitempty"` +// GoogleCloudDiscoveryengineV1ImportSuggestionDenyListEntriesResponse: +// Response message for +// CompletionService.ImportSuggestionDenyListEntries method. +type GoogleCloudDiscoveryengineV1ImportSuggestionDenyListEntriesResponse struct { + // ErrorSamples: A sample of errors encountered while processing the + // request. + ErrorSamples []*GoogleRpcStatus `json:"errorSamples,omitempty"` - // UpdateTime: Operation last update time. If the operation is done, - // this is also the finish time. - UpdateTime string `json:"updateTime,omitempty"` + // FailedEntriesCount: Count of deny list entries that failed to be + // imported. + FailedEntriesCount int64 `json:"failedEntriesCount,omitempty,string"` - // ForceSendFields is a list of field names (e.g. "CreateTime") to + // ImportedEntriesCount: Count of deny list entries successfully + // imported. + ImportedEntriesCount int64 `json:"importedEntriesCount,omitempty,string"` + + // ForceSendFields is a list of field names (e.g. "ErrorSamples") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -1869,29 +1939,35 @@ type GoogleCloudDiscoveryengineV1alphaDeleteSchemaMetadata struct { // This may be used to include empty fields in Patch requests. 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. However, any field with an - // empty value appearing in NullFields will be sent to the server as + // NullFields is a list of field names (e.g. "ErrorSamples") to include + // in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. However, any field with + // an empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaDeleteSchemaMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaDeleteSchemaMetadata +func (s *GoogleCloudDiscoveryengineV1ImportSuggestionDenyListEntriesResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1ImportSuggestionDenyListEntriesResponse raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaDeleteTargetSiteMetadata: Metadata -// related to the progress of the -// SiteSearchEngineService.DeleteTargetSite operation. This will be -// returned by the google.longrunning.Operation.metadata field. -type GoogleCloudDiscoveryengineV1alphaDeleteTargetSiteMetadata struct { +// GoogleCloudDiscoveryengineV1ImportUserEventsMetadata: Metadata +// related to the progress of the Import operation. This is returned by +// the google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1ImportUserEventsMetadata struct { // CreateTime: Operation create time. CreateTime string `json:"createTime,omitempty"` + // FailureCount: Count of entries that encountered errors while + // processing. + FailureCount int64 `json:"failureCount,omitempty,string"` + + // SuccessCount: Count of entries that were processed successfully. + SuccessCount int64 `json:"successCount,omitempty,string"` + // UpdateTime: Operation last update time. If the operation is done, // this is also the finish time. UpdateTime string `json:"updateTime,omitempty"` @@ -1913,20 +1989,71 @@ type GoogleCloudDiscoveryengineV1alphaDeleteTargetSiteMetadata struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaDeleteTargetSiteMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaDeleteTargetSiteMetadata +func (s *GoogleCloudDiscoveryengineV1ImportUserEventsMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1ImportUserEventsMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaDisableAdvancedSiteSearchMetadata: -// Metadata related to the progress of the -// SiteSearchEngineService.DisableAdvancedSiteSearch operation. This -// will be returned by the google.longrunning.Operation.metadata field. -type GoogleCloudDiscoveryengineV1alphaDisableAdvancedSiteSearchMetadata struct { +// GoogleCloudDiscoveryengineV1ImportUserEventsResponse: Response of the +// ImportUserEventsRequest. If the long running operation was +// successful, then this message is returned by the +// google.longrunning.Operations.response field if the operation was +// successful. +type GoogleCloudDiscoveryengineV1ImportUserEventsResponse struct { + // ErrorConfig: Echoes the destination for the complete errors if this + // field was set in the request. + ErrorConfig *GoogleCloudDiscoveryengineV1ImportErrorConfig `json:"errorConfig,omitempty"` + + // ErrorSamples: A sample of errors encountered while processing the + // request. + ErrorSamples []*GoogleRpcStatus `json:"errorSamples,omitempty"` + + // JoinedEventsCount: Count of user events imported with complete + // existing Documents. + JoinedEventsCount int64 `json:"joinedEventsCount,omitempty,string"` + + // UnjoinedEventsCount: Count of user events imported, but with Document + // information not found in the existing Branch. + UnjoinedEventsCount int64 `json:"unjoinedEventsCount,omitempty,string"` + + // ForceSendFields is a list of field names (e.g. "ErrorConfig") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "ErrorConfig") to include + // in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. However, any field with + // an empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1ImportUserEventsResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1ImportUserEventsResponse + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1PurgeDocumentsMetadata: Metadata related +// to the progress of the PurgeDocuments operation. This will be +// returned by the google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1PurgeDocumentsMetadata struct { // CreateTime: Operation create time. CreateTime string `json:"createTime,omitempty"` + // FailureCount: Count of entries that encountered errors while + // processing. + FailureCount int64 `json:"failureCount,omitempty,string"` + + // SuccessCount: Count of entries that were deleted successfully. + SuccessCount int64 `json:"successCount,omitempty,string"` + // UpdateTime: Operation last update time. If the operation is done, // this is also the finish time. UpdateTime string `json:"updateTime,omitempty"` @@ -1948,34 +2075,27 @@ type GoogleCloudDiscoveryengineV1alphaDisableAdvancedSiteSearchMetadata struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaDisableAdvancedSiteSearchMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaDisableAdvancedSiteSearchMetadata +func (s *GoogleCloudDiscoveryengineV1PurgeDocumentsMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1PurgeDocumentsMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaDisableAdvancedSiteSearchResponse: -// Response message for -// SiteSearchEngineService.DisableAdvancedSiteSearch method. -type GoogleCloudDiscoveryengineV1alphaDisableAdvancedSiteSearchResponse struct { -} - -// GoogleCloudDiscoveryengineV1alphaDocumentProcessingConfig: A -// singleton resource of DataStore. It's empty when DataStore is -// created, which defaults to digital parser. The first call to -// DataStoreService.UpdateDocumentProcessingConfig method will -// initialize the config. -type GoogleCloudDiscoveryengineV1alphaDocumentProcessingConfig struct { - // Name: Output only. The full resource name of the Document Processing - // Config. Format: - // `projects/*/locations/*/collections/*/dataStores/*/documentProcessingC - // onfig`. - Name string `json:"name,omitempty"` +// GoogleCloudDiscoveryengineV1PurgeDocumentsResponse: Response message +// for DocumentService.PurgeDocuments method. If the long running +// operation is successfully done, then this message is returned by the +// google.longrunning.Operations.response field. +type GoogleCloudDiscoveryengineV1PurgeDocumentsResponse struct { + // PurgeCount: The total count of documents purged as a result of the + // operation. + PurgeCount int64 `json:"purgeCount,omitempty,string"` - // OcrConfig: The OCR config. Currently it only applies to PDFs. - OcrConfig *GoogleCloudDiscoveryengineV1alphaOcrConfig `json:"ocrConfig,omitempty"` + // PurgeSample: A sample of document names that will be deleted. Only + // populated if `force` is set to false. A max of 100 names will be + // returned and the names are chosen at random. + PurgeSample []string `json:"purgeSample,omitempty"` - // ForceSendFields is a list of field names (e.g. "Name") to + // ForceSendFields is a list of field names (e.g. "PurgeCount") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -1983,8 +2103,8 @@ type GoogleCloudDiscoveryengineV1alphaDocumentProcessingConfig struct { // This may be used to include empty fields in Patch requests. 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 + // NullFields is a list of field names (e.g. "PurgeCount") to include in + // API requests with the JSON null value. By default, fields with empty // values are omitted from API requests. However, any field with an // empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. @@ -1992,17 +2112,17 @@ type GoogleCloudDiscoveryengineV1alphaDocumentProcessingConfig struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaDocumentProcessingConfig) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaDocumentProcessingConfig +func (s *GoogleCloudDiscoveryengineV1PurgeDocumentsResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1PurgeDocumentsResponse raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaEnableAdvancedSiteSearchMetadata: +// GoogleCloudDiscoveryengineV1PurgeSuggestionDenyListEntriesMetadata: // Metadata related to the progress of the -// SiteSearchEngineService.EnableAdvancedSiteSearch operation. This will -// be returned by the google.longrunning.Operation.metadata field. -type GoogleCloudDiscoveryengineV1alphaEnableAdvancedSiteSearchMetadata struct { +// PurgeSuggestionDenyListEntries operation. This is returned by the +// google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1PurgeSuggestionDenyListEntriesMetadata struct { // CreateTime: Operation create time. CreateTime string `json:"createTime,omitempty"` @@ -2027,104 +2147,63 @@ type GoogleCloudDiscoveryengineV1alphaEnableAdvancedSiteSearchMetadata struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaEnableAdvancedSiteSearchMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaEnableAdvancedSiteSearchMetadata +func (s *GoogleCloudDiscoveryengineV1PurgeSuggestionDenyListEntriesMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1PurgeSuggestionDenyListEntriesMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaEnableAdvancedSiteSearchResponse: -// Response message for SiteSearchEngineService.EnableAdvancedSiteSearch +// GoogleCloudDiscoveryengineV1PurgeSuggestionDenyListEntriesResponse: +// Response message for CompletionService.PurgeSuggestionDenyListEntries // method. -type GoogleCloudDiscoveryengineV1alphaEnableAdvancedSiteSearchResponse struct { -} +type GoogleCloudDiscoveryengineV1PurgeSuggestionDenyListEntriesResponse struct { + // ErrorSamples: A sample of errors encountered while processing the + // request. + ErrorSamples []*GoogleRpcStatus `json:"errorSamples,omitempty"` -// GoogleCloudDiscoveryengineV1alphaEngine: Metadata that describes the -// training and serving parameters of an Engine. -type GoogleCloudDiscoveryengineV1alphaEngine struct { - // ChatEngineConfig: Configurations for the Chat Engine. Only applicable - // if solution_type is SOLUTION_TYPE_CHAT. - ChatEngineConfig *GoogleCloudDiscoveryengineV1alphaEngineChatEngineConfig `json:"chatEngineConfig,omitempty"` + // PurgeCount: Number of suggestion deny list entries purged. + PurgeCount int64 `json:"purgeCount,omitempty,string"` - // ChatEngineMetadata: Output only. Additional information of the Chat - // Engine. Only applicable if solution_type is SOLUTION_TYPE_CHAT. - ChatEngineMetadata *GoogleCloudDiscoveryengineV1alphaEngineChatEngineMetadata `json:"chatEngineMetadata,omitempty"` + // ForceSendFields is a list of field names (e.g. "ErrorSamples") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` - // CommonConfig: Common config spec that specifies the metadata of the - // engine. - CommonConfig *GoogleCloudDiscoveryengineV1alphaEngineCommonConfig `json:"commonConfig,omitempty"` + // NullFields is a list of field names (e.g. "ErrorSamples") to include + // in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. However, any field with + // an empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} - // CreateTime: Output only. Timestamp the Recommendation Engine was - // created at. - CreateTime string `json:"createTime,omitempty"` +func (s *GoogleCloudDiscoveryengineV1PurgeSuggestionDenyListEntriesResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1PurgeSuggestionDenyListEntriesResponse + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} - // DataStoreIds: The data stores associated with this engine. For - // SOLUTION_TYPE_SEARCH and SOLUTION_TYPE_RECOMMENDATION type of - // engines, they can only associate with at most one data store. If - // solution_type is SOLUTION_TYPE_CHAT, multiple DataStores in the same - // Collection can be associated here. Note that when used in - // CreateEngineRequest, one DataStore id must be provided as the system - // will use it for necessary intializations. - DataStoreIds []string `json:"dataStoreIds,omitempty"` +// GoogleCloudDiscoveryengineV1Schema: Defines the structure and layout +// of a type of document data. +type GoogleCloudDiscoveryengineV1Schema struct { + // JsonSchema: The JSON representation of the schema. + JsonSchema string `json:"jsonSchema,omitempty"` - // DisplayName: Required. The display name of the engine. Should be - // human readable. UTF-8 encoded string with limit of 1024 characters. - DisplayName string `json:"displayName,omitempty"` + // Name: Immutable. The full resource name of the schema, in the format + // of + // `projects/{project}/locations/{location}/collections/{collection}/data + // Stores/{data_store}/schemas/{schema}`. This field must be a UTF-8 + // encoded string with a length limit of 1024 characters. + Name string `json:"name,omitempty"` - // IndustryVertical: The industry vertical that the engine registers. - // The restriction of the Engine industry vertical is based on - // DataStore: If unspecified, default to `GENERIC`. Vertical on Engine - // has to match vertical of the DataStore liniked to the engine. - // - // Possible values: - // "INDUSTRY_VERTICAL_UNSPECIFIED" - Value used when unset. - // "GENERIC" - The generic vertical for documents that are not - // specific to any industry vertical. - // "MEDIA" - The media industry vertical. - IndustryVertical string `json:"industryVertical,omitempty"` + // StructSchema: The structured representation of the schema. + StructSchema googleapi.RawMessage `json:"structSchema,omitempty"` - // MediaRecommendationEngineConfig: Configurations for the Media Engine. - // Only applicable on the data stores with solution_type - // SOLUTION_TYPE_RECOMMENDATION and IndustryVertical.MEDIA vertical. - MediaRecommendationEngineConfig *GoogleCloudDiscoveryengineV1alphaEngineMediaRecommendationEngineConfig `json:"mediaRecommendationEngineConfig,omitempty"` - - // Name: Immutable. The fully qualified resource name of the engine. - // This field must be a UTF-8 encoded string with a length limit of 1024 - // characters. Format: - // `projects/{project_number}/locations/{location}/collections/{collectio - // n}/engines/{engine}` engine should be 1-63 characters, and valid - // characters are /a-z0-9*/. Otherwise, an INVALID_ARGUMENT error is - // returned. - Name string `json:"name,omitempty"` - - // RecommendationMetadata: Output only. Additional information of a - // recommendation engine. Only applicable if solution_type is - // SOLUTION_TYPE_RECOMMENDATION. - RecommendationMetadata *GoogleCloudDiscoveryengineV1alphaEngineRecommendationMetadata `json:"recommendationMetadata,omitempty"` - - // SearchEngineConfig: Configurations for the Search Engine. Only - // applicable if solution_type is SOLUTION_TYPE_SEARCH. - SearchEngineConfig *GoogleCloudDiscoveryengineV1alphaEngineSearchEngineConfig `json:"searchEngineConfig,omitempty"` - - // SimilarDocumentsConfig: Additional config specs for a `similar-items` - // engine. - SimilarDocumentsConfig *GoogleCloudDiscoveryengineV1alphaEngineSimilarDocumentsEngineConfig `json:"similarDocumentsConfig,omitempty"` - - // SolutionType: Required. The solutions of the engine. - // - // Possible values: - // "SOLUTION_TYPE_UNSPECIFIED" - Default value. - // "SOLUTION_TYPE_RECOMMENDATION" - Used for Recommendations AI. - // "SOLUTION_TYPE_SEARCH" - Used for Discovery Search. - // "SOLUTION_TYPE_CHAT" - Used for use cases related to the Generative - // AI agent. - SolutionType string `json:"solutionType,omitempty"` - - // UpdateTime: Output only. Timestamp the Recommendation Engine was last - // updated. - UpdateTime string `json:"updateTime,omitempty"` - - // ForceSendFields is a list of field names (e.g. "ChatEngineConfig") to + // ForceSendFields is a list of field names (e.g. "JsonSchema") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -2132,53 +2211,49 @@ type GoogleCloudDiscoveryengineV1alphaEngine struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "ChatEngineConfig") to - // include in API requests with the JSON null value. By default, fields - // with empty values are omitted from API requests. However, any field - // with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. + // NullFields is a list of field names (e.g. "JsonSchema") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaEngine) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaEngine +func (s *GoogleCloudDiscoveryengineV1Schema) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1Schema raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaEngineChatEngineConfig: -// Configurations for a Chat Engine. -type GoogleCloudDiscoveryengineV1alphaEngineChatEngineConfig struct { - // AgentCreationConfig: The configurationt generate the Dialogflow agent - // that is associated to this Engine. Note that these configurations are - // one-time consumed by and passed to Dialogflow service. It means they - // cannot be retrieved using EngineService.GetEngine or - // EngineService.ListEngines API after engine creation. - AgentCreationConfig *GoogleCloudDiscoveryengineV1alphaEngineChatEngineConfigAgentCreationConfig `json:"agentCreationConfig,omitempty"` +// GoogleCloudDiscoveryengineV1SiteVerificationInfo: Verification +// information for target sites in advanced site search. +type GoogleCloudDiscoveryengineV1SiteVerificationInfo struct { + // SiteVerificationState: Site verification state indicating the + // ownership and validity. + // + // Possible values: + // "SITE_VERIFICATION_STATE_UNSPECIFIED" - Defaults to VERIFIED. + // "VERIFIED" - Site ownership verified. + // "UNVERIFIED" - Site ownership pending verification or verification + // failed. + // "EXEMPTED" - Site exempt from verification, e.g., a public website + // that opens to all. + SiteVerificationState string `json:"siteVerificationState,omitempty"` - // DialogflowAgentToLink: The resource name of an exist Dialogflow agent - // to link to this Chat Engine. Customers can either provide - // `agent_creation_config` to create agent or provide an agent name that - // links the agent with the Chat engine. Format: - // `projects//locations//agents/`. Note that the - // `dialogflow_agent_to_link` are one-time consumed by and passed to - // Dialogflow service. It means they cannot be retrieved using - // EngineService.GetEngine or EngineService.ListEngines API after engine - // creation. Please use ChatEngineMetadata.dialogflow_agent for actual - // agent association after Engine is created. - DialogflowAgentToLink string `json:"dialogflowAgentToLink,omitempty"` + // VerifyTime: Latest site verification time. + VerifyTime string `json:"verifyTime,omitempty"` - // ForceSendFields is a list of field names (e.g. "AgentCreationConfig") - // to unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. + // ForceSendFields is a list of field names (e.g. + // "SiteVerificationState") to unconditionally include in API requests. + // By default, fields with empty or default values are omitted from API + // requests. However, any non-pointer, non-interface field appearing in + // ForceSendFields will be sent to the server regardless of whether the + // field is empty or not. This may be used to include empty fields in + // Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "AgentCreationConfig") to + // NullFields is a list of field names (e.g. "SiteVerificationState") to // include in API requests with the JSON null value. By default, fields // with empty values are omitted from API requests. However, any field // with an empty value appearing in NullFields will be sent to the @@ -2188,42 +2263,74 @@ type GoogleCloudDiscoveryengineV1alphaEngineChatEngineConfig struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaEngineChatEngineConfig) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaEngineChatEngineConfig +func (s *GoogleCloudDiscoveryengineV1SiteVerificationInfo) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1SiteVerificationInfo raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaEngineChatEngineConfigAgentCreationCo -// nfig: Configurations for generating a Dialogflow agent. Note that -// these configurations are one-time consumed by and passed to -// Dialogflow service. It means they cannot be retrieved using -// EngineService.GetEngine or EngineService.ListEngines API after engine -// creation. -type GoogleCloudDiscoveryengineV1alphaEngineChatEngineConfigAgentCreationConfig struct { - // Business: Name of the company, organization or other entity that the - // agent represents. Used for knowledge connector LLM prompt and for - // knowledge search. - Business string `json:"business,omitempty"` +// GoogleCloudDiscoveryengineV1TargetSite: A target site for the +// SiteSearchEngine. +type GoogleCloudDiscoveryengineV1TargetSite struct { + // ExactMatch: Input only. If set to false, a uri_pattern is generated + // to include all pages whose address contains the provided_uri_pattern. + // If set to true, an uri_pattern is generated to try to be an exact + // match of the provided_uri_pattern or just the specific page if the + // provided_uri_pattern is a specific one. provided_uri_pattern is + // always normalized to generate the URI pattern to be used by the + // search engine. + ExactMatch bool `json:"exactMatch,omitempty"` - // DefaultLanguageCode: Required. The default language of the agent as a - // language tag. See Language Support - // (https://cloud.google.com/dialogflow/docs/reference/language) for a - // list of the currently supported language codes. - DefaultLanguageCode string `json:"defaultLanguageCode,omitempty"` + // FailureReason: Output only. Failure reason. + FailureReason *GoogleCloudDiscoveryengineV1TargetSiteFailureReason `json:"failureReason,omitempty"` - // Location: Agent location for Agent creation, supported values: - // global/us/eu. If not provided, us Engine will create Agent using - // us-central-1 by default; eu Engine will create Agent using eu-west-1 - // by default. - Location string `json:"location,omitempty"` + // GeneratedUriPattern: Output only. This is system-generated based on + // the provided_uri_pattern. + GeneratedUriPattern string `json:"generatedUriPattern,omitempty"` - // TimeZone: Required. The time zone of the agent from the time zone - // database (https://www.iana.org/time-zones), e.g., America/New_York, - // Europe/Paris. - TimeZone string `json:"timeZone,omitempty"` + // IndexingStatus: Output only. Indexing status. + // + // Possible values: + // "INDEXING_STATUS_UNSPECIFIED" - Defaults to SUCCEEDED. + // "PENDING" - The target site is in the update queue and will be + // picked up by indexing pipeline. + // "FAILED" - The target site fails to be indexed. + // "SUCCEEDED" - The target site has been indexed. + // "DELETING" - The previously indexed target site has been marked to + // be deleted. This is a transitioning state which will resulted in + // either: 1. target site deleted if unindexing is successful; 2. state + // reverts to SUCCEEDED if the unindexing fails. + IndexingStatus string `json:"indexingStatus,omitempty"` - // ForceSendFields is a list of field names (e.g. "Business") to + // Name: Output only. The fully qualified resource name of the target + // site. + // `projects/{project}/locations/{location}/collections/{collection}/data + // Stores/{data_store}/siteSearchEngine/targetSites/{target_site}` The + // `target_site_id` is system-generated. + Name string `json:"name,omitempty"` + + // ProvidedUriPattern: Required. Input only. The user provided URI + // pattern from which the `generated_uri_pattern` is generated. + ProvidedUriPattern string `json:"providedUriPattern,omitempty"` + + // SiteVerificationInfo: Output only. Site ownership and validity + // verification status. + SiteVerificationInfo *GoogleCloudDiscoveryengineV1SiteVerificationInfo `json:"siteVerificationInfo,omitempty"` + + // Type: The type of the target site, e.g., whether the site is to be + // included or excluded. + // + // Possible values: + // "TYPE_UNSPECIFIED" - This value is unused. In this case, server + // behavior defaults to Type.INCLUDE. + // "INCLUDE" - Include the target site. + // "EXCLUDE" - Exclude the target site. + Type string `json:"type,omitempty"` + + // UpdateTime: Output only. The target site's last updated time. + UpdateTime string `json:"updateTime,omitempty"` + + // ForceSendFields is a list of field names (e.g. "ExactMatch") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -2231,7 +2338,7 @@ type GoogleCloudDiscoveryengineV1alphaEngineChatEngineConfigAgentCreationConfig // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Business") to include in + // NullFields is a list of field names (e.g. "ExactMatch") to include in // API requests with the JSON null value. By default, fields with empty // values are omitted from API requests. However, any field with an // empty value appearing in NullFields will be sent to the server as @@ -2240,20 +2347,19 @@ type GoogleCloudDiscoveryengineV1alphaEngineChatEngineConfigAgentCreationConfig NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaEngineChatEngineConfigAgentCreationConfig) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaEngineChatEngineConfigAgentCreationConfig +func (s *GoogleCloudDiscoveryengineV1TargetSite) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1TargetSite raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaEngineChatEngineMetadata: Additional -// information of a Chat Engine. Fields in this message are output only. -type GoogleCloudDiscoveryengineV1alphaEngineChatEngineMetadata struct { - // DialogflowAgent: The resource name of a Dialogflow agent, that this - // Chat Engine refers to. Format: `projects//locations//agents/`. - DialogflowAgent string `json:"dialogflowAgent,omitempty"` +// GoogleCloudDiscoveryengineV1TargetSiteFailureReason: Site search +// indexing failure reasons. +type GoogleCloudDiscoveryengineV1TargetSiteFailureReason struct { + // QuotaFailure: Failed due to insufficient quota. + QuotaFailure *GoogleCloudDiscoveryengineV1TargetSiteFailureReasonQuotaFailure `json:"quotaFailure,omitempty"` - // ForceSendFields is a list of field names (e.g. "DialogflowAgent") to + // ForceSendFields is a list of field names (e.g. "QuotaFailure") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -2261,7 +2367,35 @@ type GoogleCloudDiscoveryengineV1alphaEngineChatEngineMetadata struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "DialogflowAgent") to + // NullFields is a list of field names (e.g. "QuotaFailure") to include + // in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. However, any field with + // an empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1TargetSiteFailureReason) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1TargetSiteFailureReason + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +type GoogleCloudDiscoveryengineV1TargetSiteFailureReasonQuotaFailure struct { + // TotalRequiredQuota: This number is an estimation on how much total + // quota this project needs to successfully complete indexing. + TotalRequiredQuota int64 `json:"totalRequiredQuota,omitempty,string"` + + // ForceSendFields is a list of field names (e.g. "TotalRequiredQuota") + // to unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "TotalRequiredQuota") to // include in API requests with the JSON null value. By default, fields // with empty values are omitted from API requests. However, any field // with an empty value appearing in NullFields will be sent to the @@ -2271,21 +2405,23 @@ type GoogleCloudDiscoveryengineV1alphaEngineChatEngineMetadata struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaEngineChatEngineMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaEngineChatEngineMetadata +func (s *GoogleCloudDiscoveryengineV1TargetSiteFailureReasonQuotaFailure) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1TargetSiteFailureReasonQuotaFailure raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaEngineCommonConfig: Common -// configurations for an Engine. -type GoogleCloudDiscoveryengineV1alphaEngineCommonConfig struct { - // CompanyName: The name of the company, business or entity that is - // associated with the engine. Setting this may help improve LLM related - // features. - CompanyName string `json:"companyName,omitempty"` +// GoogleCloudDiscoveryengineV1UpdateSchemaMetadata: Metadata for +// UpdateSchema LRO. +type GoogleCloudDiscoveryengineV1UpdateSchemaMetadata struct { + // CreateTime: Operation create time. + CreateTime string `json:"createTime,omitempty"` - // ForceSendFields is a list of field names (e.g. "CompanyName") to + // 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. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -2293,100 +2429,34 @@ type GoogleCloudDiscoveryengineV1alphaEngineCommonConfig struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "CompanyName") to include - // in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. However, any field with - // an empty value appearing in NullFields will be sent to the server as + // 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. However, any field with an + // empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaEngineCommonConfig) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaEngineCommonConfig +func (s *GoogleCloudDiscoveryengineV1UpdateSchemaMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1UpdateSchemaMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaEngineMediaRecommendationEngineConfig -// : Additional config specs for a Media Recommendation engine. -type GoogleCloudDiscoveryengineV1alphaEngineMediaRecommendationEngineConfig struct { - // OptimizationObjective: The optimization objective e.g. `cvr`. This - // field together with optimization_objective describe engine metadata - // to use to control engine training and serving. Currently supported - // values: `ctr`, `cvr`. If not specified, we choose default based on - // engine type. Default depends on type of recommendation: - // `recommended-for-you` => `ctr` `others-you-may-like` => `ctr` - OptimizationObjective string `json:"optimizationObjective,omitempty"` - - // OptimizationObjectiveConfig: Name and value of the custom threshold - // for cvr optimization_objective. For target_field `watch-time`, - // target_field_value must be an integer value indicating the media - // progress time in seconds between (0, 86400] (excludes 0, includes - // 86400) (e.g., 90). For target_field `watch-percentage`, the - // target_field_value must be a valid float value between (0, 1.0] - // (excludes 0, includes 1.0) (e.g., 0.5). - OptimizationObjectiveConfig *GoogleCloudDiscoveryengineV1alphaEngineMediaRecommendationEngineConfigOptimizationObjectiveConfig `json:"optimizationObjectiveConfig,omitempty"` - - // TrainingState: The training state that the engine is in (e.g. - // `TRAINING` or `PAUSED`). Since part of the cost of running the - // service is frequency of training - this can be used to determine when - // to train engine in order to control cost. If not specified: the - // default value for `CreateEngine` method is `TRAINING`. The default - // value for `UpdateEngine` method is to keep the state the same as - // before. - // - // Possible values: - // "TRAINING_STATE_UNSPECIFIED" - Unspecified training state. - // "PAUSED" - The engine training is paused. - // "TRAINING" - The engine is training. - TrainingState string `json:"trainingState,omitempty"` - - // Type: Required. The type of engine e.g. `recommended-for-you`. This - // field together with optimization_objective describe engine metadata - // to use to control engine training and serving. Currently supported - // values: `recommended-for-you`, `others-you-may-like`, - // `more-like-this`, `most-popular-items`. - Type string `json:"type,omitempty"` - - // ForceSendFields is a list of field names (e.g. - // "OptimizationObjective") to unconditionally include in API requests. - // By default, fields with empty or default values are omitted from API - // requests. However, any non-pointer, non-interface field appearing in - // ForceSendFields will be sent to the server regardless of whether the - // field is empty or not. This may be used to include empty fields in - // Patch requests. - ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "OptimizationObjective") to - // include in API requests with the JSON null value. By default, fields - // with empty values are omitted from API requests. However, any field - // with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. - NullFields []string `json:"-"` -} - -func (s *GoogleCloudDiscoveryengineV1alphaEngineMediaRecommendationEngineConfig) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaEngineMediaRecommendationEngineConfig - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) -} - -// GoogleCloudDiscoveryengineV1alphaEngineMediaRecommendationEngineConfig -// OptimizationObjectiveConfig: Custom threshold for `cvr` -// optimization_objective. -type GoogleCloudDiscoveryengineV1alphaEngineMediaRecommendationEngineConfigOptimizationObjectiveConfig struct { - // TargetField: Required. The name of the field to target. Currently - // supported values: `watch-percentage`, `watch-time`. - TargetField string `json:"targetField,omitempty"` +// GoogleCloudDiscoveryengineV1UpdateTargetSiteMetadata: Metadata +// related to the progress of the +// SiteSearchEngineService.UpdateTargetSite operation. This will be +// returned by the google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1UpdateTargetSiteMetadata struct { + // CreateTime: Operation create time. + CreateTime string `json:"createTime,omitempty"` - // TargetFieldValueFloat: Required. The threshold to be applied to the - // target (e.g., 0.5). - TargetFieldValueFloat float64 `json:"targetFieldValueFloat,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. "TargetField") to + // 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. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -2394,78 +2464,34 @@ type GoogleCloudDiscoveryengineV1alphaEngineMediaRecommendationEngineConfigOptim // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "TargetField") to include - // in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. However, any field with - // an empty value appearing in NullFields will be sent to the server as + // 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. However, any field with an + // empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaEngineMediaRecommendationEngineConfigOptimizationObjectiveConfig) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaEngineMediaRecommendationEngineConfigOptimizationObjectiveConfig +func (s *GoogleCloudDiscoveryengineV1UpdateTargetSiteMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1UpdateTargetSiteMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -func (s *GoogleCloudDiscoveryengineV1alphaEngineMediaRecommendationEngineConfigOptimizationObjectiveConfig) UnmarshalJSON(data []byte) error { - type NoMethod GoogleCloudDiscoveryengineV1alphaEngineMediaRecommendationEngineConfigOptimizationObjectiveConfig - var s1 struct { - TargetFieldValueFloat gensupport.JSONFloat64 `json:"targetFieldValueFloat"` - *NoMethod - } - s1.NoMethod = (*NoMethod)(s) - if err := json.Unmarshal(data, &s1); err != nil { - return err - } - s.TargetFieldValueFloat = float64(s1.TargetFieldValueFloat) - return nil -} - -// GoogleCloudDiscoveryengineV1alphaEngineRecommendationMetadata: -// Additional information of a recommendation engine. -type GoogleCloudDiscoveryengineV1alphaEngineRecommendationMetadata struct { - // DataState: Output only. The state of data requirements for this - // engine: `DATA_OK` and `DATA_ERROR`. Engine cannot be trained if the - // data is in `DATA_ERROR` state. Engine can have `DATA_ERROR` state - // even if serving state is `ACTIVE`: engines were trained successfully - // before, but cannot be refreshed because the underlying engine no - // longer has sufficient data for training. - // - // Possible values: - // "DATA_STATE_UNSPECIFIED" - Unspecified default value, should never - // be explicitly set. - // "DATA_OK" - The engine has sufficient training data. - // "DATA_ERROR" - The engine does not have sufficient training data. - // Error messages can be queried via Stackdriver. - DataState string `json:"dataState,omitempty"` - - // LastTuneTime: Output only. The timestamp when the latest successful - // tune finished. Only applicable on Media Recommendation engines. - LastTuneTime string `json:"lastTuneTime,omitempty"` - - // ServingState: Output only. The serving state of the engine: `ACTIVE`, - // `NOT_ACTIVE`. - // - // Possible values: - // "SERVING_STATE_UNSPECIFIED" - Unspecified serving state. - // "INACTIVE" - The engine is not serving. - // "ACTIVE" - The engine is serving and can be queried. - // "TUNED" - The engine is trained on tuned hyperparameters and can be - // queried. - ServingState string `json:"servingState,omitempty"` +// GoogleCloudDiscoveryengineV1alphaBatchCreateTargetSiteMetadata: +// Metadata related to the progress of the +// SiteSearchEngineService.BatchCreateTargetSites operation. This will +// be returned by the google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1alphaBatchCreateTargetSiteMetadata struct { + // CreateTime: Operation create time. + CreateTime string `json:"createTime,omitempty"` - // TuningOperation: Output only. The latest tune operation id associated - // with the engine. Only applicable on Media Recommendation engines. If - // present, this operation id can be used to determine if there is an - // ongoing tune for this engine. To check the operation status, send the - // GetOperation request with this operation id in the engine resource - // format. If no tuning has happened for this engine, the string is - // empty. - TuningOperation string `json:"tuningOperation,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. "DataState") to + // 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. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -2473,7 +2499,7 @@ type GoogleCloudDiscoveryengineV1alphaEngineRecommendationMetadata struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "DataState") to include in + // 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. However, any field with an // empty value appearing in NullFields will be sent to the server as @@ -2482,36 +2508,20 @@ type GoogleCloudDiscoveryengineV1alphaEngineRecommendationMetadata struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaEngineRecommendationMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaEngineRecommendationMetadata +func (s *GoogleCloudDiscoveryengineV1alphaBatchCreateTargetSiteMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaBatchCreateTargetSiteMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaEngineSearchEngineConfig: -// Configurations for a Search Engine. -type GoogleCloudDiscoveryengineV1alphaEngineSearchEngineConfig struct { - // SearchAddOns: The add-on that this search engine enables. - // - // Possible values: - // "SEARCH_ADD_ON_UNSPECIFIED" - Default value when the enum is - // unspecified. This is invalid to use. - // "SEARCH_ADD_ON_LLM" - Large language model add-on. - SearchAddOns []string `json:"searchAddOns,omitempty"` - - // SearchTier: The search feature tier of this engine. Different tiers - // might have different pricing. To learn more, please check the pricing - // documentation. Defaults to SearchTier.SEARCH_TIER_STANDARD if not - // specified. - // - // Possible values: - // "SEARCH_TIER_UNSPECIFIED" - Default value when the enum is - // unspecified. This is invalid to use. - // "SEARCH_TIER_STANDARD" - Standard tier. - // "SEARCH_TIER_ENTERPRISE" - Enterprise tier. - SearchTier string `json:"searchTier,omitempty"` +// GoogleCloudDiscoveryengineV1alphaBatchCreateTargetSitesResponse: +// Response message for SiteSearchEngineService.BatchCreateTargetSites +// method. +type GoogleCloudDiscoveryengineV1alphaBatchCreateTargetSitesResponse struct { + // TargetSites: TargetSites created. + TargetSites []*GoogleCloudDiscoveryengineV1alphaTargetSite `json:"targetSites,omitempty"` - // ForceSendFields is a list of field names (e.g. "SearchAddOns") to + // ForceSendFields is a list of field names (e.g. "TargetSites") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -2519,7 +2529,7 @@ type GoogleCloudDiscoveryengineV1alphaEngineSearchEngineConfig struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "SearchAddOns") to include + // NullFields is a list of field names (e.g. "TargetSites") to include // in API requests with the JSON null value. By default, fields with // empty values are omitted from API requests. However, any field with // an empty value appearing in NullFields will be sent to the server as @@ -2528,24 +2538,24 @@ type GoogleCloudDiscoveryengineV1alphaEngineSearchEngineConfig struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaEngineSearchEngineConfig) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaEngineSearchEngineConfig +func (s *GoogleCloudDiscoveryengineV1alphaBatchCreateTargetSitesResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaBatchCreateTargetSitesResponse raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaEngineSimilarDocumentsEngineConfig: -// Additional config specs for a `similar-items` engine. -type GoogleCloudDiscoveryengineV1alphaEngineSimilarDocumentsEngineConfig struct { -} - -// GoogleCloudDiscoveryengineV1alphaEstimateDataSizeMetadata: Metadata -// related to the progress of the EstimateDataSize operation. This is -// returned by the google.longrunning.Operation.metadata field. -type GoogleCloudDiscoveryengineV1alphaEstimateDataSizeMetadata struct { +// GoogleCloudDiscoveryengineV1alphaCreateDataStoreMetadata: Metadata +// related to the progress of the DataStoreService.CreateDataStore +// operation. This will be returned by the +// google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1alphaCreateDataStoreMetadata 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. However, any @@ -2563,25 +2573,25 @@ type GoogleCloudDiscoveryengineV1alphaEstimateDataSizeMetadata struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaEstimateDataSizeMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaEstimateDataSizeMetadata +func (s *GoogleCloudDiscoveryengineV1alphaCreateDataStoreMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaCreateDataStoreMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaEstimateDataSizeResponse: Response -// of the EstimateDataSize request. If the long running operation was -// successful, then this message is returned by the -// google.longrunning.Operations.response field if the operation was -// successful. -type GoogleCloudDiscoveryengineV1alphaEstimateDataSizeResponse struct { - // DataSizeBytes: Data size in terms of bytes. - DataSizeBytes int64 `json:"dataSizeBytes,omitempty,string"` +// GoogleCloudDiscoveryengineV1alphaCreateEngineMetadata: Metadata +// related to the progress of the EngineService.CreateEngine operation. +// This will be returned by the google.longrunning.Operation.metadata +// field. +type GoogleCloudDiscoveryengineV1alphaCreateEngineMetadata struct { + // CreateTime: Operation create time. + CreateTime string `json:"createTime,omitempty"` - // DocumentCount: Total number of documents. - DocumentCount int64 `json:"documentCount,omitempty,string"` + // 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. "DataSizeBytes") to + // 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. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -2589,201 +2599,62 @@ type GoogleCloudDiscoveryengineV1alphaEstimateDataSizeResponse struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "DataSizeBytes") to include - // in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. However, any field with - // an empty value appearing in NullFields will be sent to the server as + // 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. However, any field with an + // empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaEstimateDataSizeResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaEstimateDataSizeResponse +func (s *GoogleCloudDiscoveryengineV1alphaCreateEngineMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaCreateEngineMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaFieldConfig: Configurations for -// fields of a schema. For example, configuring a field is indexable, or -// searchable. -type GoogleCloudDiscoveryengineV1alphaFieldConfig struct { - // CompletableOption: If completable_option is COMPLETABLE_ENABLED, - // field values are directly used and returned as suggestions for - // Autocomplete in CompletionService.CompleteQuery. If - // completable_option is unset, the server behavior defaults to - // COMPLETABLE_DISABLED for fields that support setting completable - // options, which are just `string` fields. For those fields that do not - // support setting completable options, the server will skip completable - // option setting, and setting completable_option for those fields will - // throw `INVALID_ARGUMENT` error. - // - // Possible values: - // "COMPLETABLE_OPTION_UNSPECIFIED" - Value used when unset. - // "COMPLETABLE_ENABLED" - Completable option enabled for a schema - // field. - // "COMPLETABLE_DISABLED" - Completable option disabled for a schema - // field. - CompletableOption string `json:"completableOption,omitempty"` - - // DynamicFacetableOption: If dynamic_facetable_option is - // DYNAMIC_FACETABLE_ENABLED, field values are available for dynamic - // facet. Could only be DYNAMIC_FACETABLE_DISABLED if - // FieldConfig.indexable_option is INDEXABLE_DISABLED. Otherwise, an - // `INVALID_ARGUMENT` error will be returned. If - // dynamic_facetable_option is unset, the server behavior defaults to - // DYNAMIC_FACETABLE_DISABLED for fields that support setting dynamic - // facetable options. For those fields that do not support setting - // dynamic facetable options, such as `object` and `boolean`, the server - // will skip dynamic facetable option setting, and setting - // dynamic_facetable_option for those fields will throw - // `INVALID_ARGUMENT` error. - // - // Possible values: - // "DYNAMIC_FACETABLE_OPTION_UNSPECIFIED" - Value used when unset. - // "DYNAMIC_FACETABLE_ENABLED" - Dynamic facetable option enabled for - // a schema field. - // "DYNAMIC_FACETABLE_DISABLED" - Dynamic facetable option disabled - // for a schema field. - DynamicFacetableOption string `json:"dynamicFacetableOption,omitempty"` - - // FieldPath: Required. Field path of the schema field. For example: - // `title`, `description`, `release_info.release_year`. - FieldPath string `json:"fieldPath,omitempty"` - - // FieldType: Output only. Raw type of the field. - // - // Possible values: - // "FIELD_TYPE_UNSPECIFIED" - Field type is unspecified. - // "OBJECT" - Field value type is Object. - // "STRING" - Field value type is String. - // "NUMBER" - Field value type is Number. - // "INTEGER" - Field value type is Integer. - // "BOOLEAN" - Field value type is Boolean. - // "GEOLOCATION" - Field value type is Geolocation. - // "DATETIME" - Field value type is Datetime. - FieldType string `json:"fieldType,omitempty"` - - // IndexableOption: If indexable_option is INDEXABLE_ENABLED, field - // values are indexed so that it can be filtered or faceted in - // SearchService.Search. If indexable_option is unset, the server - // behavior defaults to INDEXABLE_DISABLED for fields that support - // setting indexable options. For those fields that do not support - // setting indexable options, such as `object` and `boolean` and key - // properties, the server will skip indexable_option setting, and - // setting indexable_option for those fields will throw - // `INVALID_ARGUMENT` error. - // - // Possible values: - // "INDEXABLE_OPTION_UNSPECIFIED" - Value used when unset. - // "INDEXABLE_ENABLED" - Indexable option enabled for a schema field. - // "INDEXABLE_DISABLED" - Indexable option disabled for a schema - // field. - IndexableOption string `json:"indexableOption,omitempty"` - - // KeyPropertyType: Output only. Type of the key property that this - // field is mapped to. Empty string if this is not annotated as mapped - // to a key property. Example types are `title`, `description`. Full - // list is defined by `keyPropertyMapping` in the schema field - // annotation. If the schema field has a `KeyPropertyMapping` - // annotation, `indexable_option` and `searchable_option` of this field - // cannot be modified. - KeyPropertyType string `json:"keyPropertyType,omitempty"` - - // RecsFilterableOption: If recs_filterable_option is - // FILTERABLE_ENABLED, field values are filterable by filter expression - // in RecommendationService.Recommend. If FILTERABLE_ENABLED but the - // field type is numerical, field values are not filterable by text - // queries in RecommendationService.Recommend. Only textual fields are - // supported. If recs_filterable_option is unset, the default setting is - // FILTERABLE_DISABLED for fields that support setting filterable - // options. When a field set to [FILTERABLE_DISABLED] is filtered, a - // warning is generated and an empty result is returned. - // - // Possible values: - // "FILTERABLE_OPTION_UNSPECIFIED" - Value used when unset. - // "FILTERABLE_ENABLED" - Filterable option enabled for a schema - // field. - // "FILTERABLE_DISABLED" - Filterable option disabled for a schema - // field. - RecsFilterableOption string `json:"recsFilterableOption,omitempty"` - - // RetrievableOption: If retrievable_option is RETRIEVABLE_ENABLED, - // field values are included in the search results. If - // retrievable_option is unset, the server behavior defaults to - // RETRIEVABLE_DISABLED for fields that support setting retrievable - // options. For those fields that do not support setting retrievable - // options, such as `object` and `boolean`, the server will skip - // retrievable option setting, and setting retrievable_option for those - // fields will throw `INVALID_ARGUMENT` error. - // - // Possible values: - // "RETRIEVABLE_OPTION_UNSPECIFIED" - Value used when unset. - // "RETRIEVABLE_ENABLED" - Retrievable option enabled for a schema - // field. - // "RETRIEVABLE_DISABLED" - Retrievable option disabled for a schema - // field. - RetrievableOption string `json:"retrievableOption,omitempty"` +// GoogleCloudDiscoveryengineV1alphaCreateSchemaMetadata: Metadata for +// Create Schema LRO. +type GoogleCloudDiscoveryengineV1alphaCreateSchemaMetadata struct { + // CreateTime: Operation create time. + CreateTime string `json:"createTime,omitempty"` - // SearchableOption: If searchable_option is SEARCHABLE_ENABLED, field - // values are searchable by text queries in SearchService.Search. If - // SEARCHABLE_ENABLED but field type is numerical, field values will not - // be searchable by text queries in SearchService.Search, as there are - // no text values associated to numerical fields. If searchable_option - // is unset, the server behavior defaults to SEARCHABLE_DISABLED for - // fields that support setting searchable options. Only `string` fields - // that have no key property mapping support setting searchable_option. - // For those fields that do not support setting searchable options, the - // server will skip searchable option setting, and setting - // searchable_option for those fields will throw `INVALID_ARGUMENT` - // error. - // - // Possible values: - // "SEARCHABLE_OPTION_UNSPECIFIED" - Value used when unset. - // "SEARCHABLE_ENABLED" - Searchable option enabled for a schema - // field. - // "SEARCHABLE_DISABLED" - Searchable option disabled for a schema - // field. - SearchableOption string `json:"searchableOption,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. "CompletableOption") - // to unconditionally include in API requests. By default, fields with + // 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. However, any // non-pointer, non-interface field appearing in ForceSendFields will be // sent to the server regardless of whether the field is empty or not. // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "CompletableOption") to - // include in API requests with the JSON null value. By default, fields - // with empty values are omitted from API requests. However, any field - // with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. + // 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. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaFieldConfig) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaFieldConfig +func (s *GoogleCloudDiscoveryengineV1alphaCreateSchemaMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaCreateSchemaMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaImportDocumentsMetadata: Metadata -// related to the progress of the ImportDocuments operation. This is +// GoogleCloudDiscoveryengineV1alphaCreateTargetSiteMetadata: Metadata +// related to the progress of the +// SiteSearchEngineService.CreateTargetSite operation. This will be // returned by the google.longrunning.Operation.metadata field. -type GoogleCloudDiscoveryengineV1alphaImportDocumentsMetadata struct { +type GoogleCloudDiscoveryengineV1alphaCreateTargetSiteMetadata struct { // CreateTime: Operation create time. CreateTime string `json:"createTime,omitempty"` - // FailureCount: Count of entries that encountered errors while - // processing. - FailureCount int64 `json:"failureCount,omitempty,string"` - - // SuccessCount: Count of entries that were processed successfully. - SuccessCount int64 `json:"successCount,omitempty,string"` - // UpdateTime: Operation last update time. If the operation is done, // this is also the finish time. UpdateTime string `json:"updateTime,omitempty"` @@ -2805,27 +2676,71 @@ type GoogleCloudDiscoveryengineV1alphaImportDocumentsMetadata struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaImportDocumentsMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaImportDocumentsMetadata +func (s *GoogleCloudDiscoveryengineV1alphaCreateTargetSiteMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaCreateTargetSiteMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaImportDocumentsResponse: Response of -// the ImportDocumentsRequest. If the long running operation is done, -// then this message is returned by the -// google.longrunning.Operations.response field if the operation was -// successful. -type GoogleCloudDiscoveryengineV1alphaImportDocumentsResponse struct { - // ErrorConfig: Echoes the destination for the complete errors in the - // request if set. - ErrorConfig *GoogleCloudDiscoveryengineV1alphaImportErrorConfig `json:"errorConfig,omitempty"` +// GoogleCloudDiscoveryengineV1alphaDataStore: DataStore captures global +// settings and configs at the DataStore level. +type GoogleCloudDiscoveryengineV1alphaDataStore struct { + // ContentConfig: Immutable. The content config of the data store. If + // this field is unset, the server behavior defaults to + // ContentConfig.NO_CONTENT. + // + // Possible values: + // "CONTENT_CONFIG_UNSPECIFIED" - Default value. + // "NO_CONTENT" - Only contains documents without any + // Document.content. + // "CONTENT_REQUIRED" - Only contains documents with Document.content. + // "PUBLIC_WEBSITE" - The data store is used for public website + // search. + ContentConfig string `json:"contentConfig,omitempty"` - // ErrorSamples: A sample of errors encountered while processing the - // request. - ErrorSamples []*GoogleRpcStatus `json:"errorSamples,omitempty"` + // CreateTime: Output only. Timestamp the DataStore was created at. + CreateTime string `json:"createTime,omitempty"` - // ForceSendFields is a list of field names (e.g. "ErrorConfig") to + // DefaultSchemaId: Output only. The id of the default Schema + // asscociated to this data store. + DefaultSchemaId string `json:"defaultSchemaId,omitempty"` + + // DisplayName: Required. The data store display name. This field must + // be a UTF-8 encoded string with a length limit of 128 characters. + // Otherwise, an INVALID_ARGUMENT error is returned. + DisplayName string `json:"displayName,omitempty"` + + // IndustryVertical: Immutable. The industry vertical that the data + // store registers. + // + // Possible values: + // "INDUSTRY_VERTICAL_UNSPECIFIED" - Value used when unset. + // "GENERIC" - The generic vertical for documents that are not + // specific to any industry vertical. + // "MEDIA" - The media industry vertical. + IndustryVertical string `json:"industryVertical,omitempty"` + + // Name: Immutable. The full resource name of the data store. Format: + // `projects/{project}/locations/{location}/collections/{collection_id}/d + // ataStores/{data_store_id}`. This field must be a UTF-8 encoded string + // with a length limit of 1024 characters. + Name string `json:"name,omitempty"` + + // SolutionTypes: The solutions that the data store enrolls. Available + // solutions for each industry_vertical: * `MEDIA`: + // `SOLUTION_TYPE_RECOMMENDATION` and `SOLUTION_TYPE_SEARCH`. * + // `SITE_SEARCH`: `SOLUTION_TYPE_SEARCH` is automatically enrolled. + // Other solutions cannot be enrolled. + // + // Possible values: + // "SOLUTION_TYPE_UNSPECIFIED" - Default value. + // "SOLUTION_TYPE_RECOMMENDATION" - Used for Recommendations AI. + // "SOLUTION_TYPE_SEARCH" - Used for Discovery Search. + // "SOLUTION_TYPE_CHAT" - Used for use cases related to the Generative + // AI agent. + SolutionTypes []string `json:"solutionTypes,omitempty"` + + // ForceSendFields is a list of field names (e.g. "ContentConfig") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -2833,7 +2748,7 @@ type GoogleCloudDiscoveryengineV1alphaImportDocumentsResponse struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "ErrorConfig") to include + // NullFields is a list of field names (e.g. "ContentConfig") to include // in API requests with the JSON null value. By default, fields with // empty values are omitted from API requests. However, any field with // an empty value appearing in NullFields will be sent to the server as @@ -2842,22 +2757,25 @@ type GoogleCloudDiscoveryengineV1alphaImportDocumentsResponse struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaImportDocumentsResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaImportDocumentsResponse +func (s *GoogleCloudDiscoveryengineV1alphaDataStore) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaDataStore raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaImportErrorConfig: Configuration of -// destination for Import related errors. -type GoogleCloudDiscoveryengineV1alphaImportErrorConfig struct { - // GcsPrefix: Cloud Storage prefix for import errors. This must be an - // empty, existing Cloud Storage directory. Import errors are written to - // sharded files in this directory, one per line, as a JSON-encoded - // `google.rpc.Status` message. - GcsPrefix string `json:"gcsPrefix,omitempty"` +// GoogleCloudDiscoveryengineV1alphaDeleteDataStoreMetadata: Metadata +// related to the progress of the DataStoreService.DeleteDataStore +// operation. This will be returned by the +// google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1alphaDeleteDataStoreMetadata struct { + // CreateTime: Operation create time. + CreateTime string `json:"createTime,omitempty"` - // ForceSendFields is a list of field names (e.g. "GcsPrefix") to + // 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. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -2865,7 +2783,7 @@ type GoogleCloudDiscoveryengineV1alphaImportErrorConfig struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "GcsPrefix") to include in + // 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. However, any field with an // empty value appearing in NullFields will be sent to the server as @@ -2874,17 +2792,17 @@ type GoogleCloudDiscoveryengineV1alphaImportErrorConfig struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaImportErrorConfig) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaImportErrorConfig +func (s *GoogleCloudDiscoveryengineV1alphaDeleteDataStoreMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaDeleteDataStoreMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesMetada -// ta: Metadata related to the progress of the -// ImportSuggestionDenyListEntries operation. This is returned by the -// google.longrunning.Operation.metadata field. -type GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesMetadata struct { +// GoogleCloudDiscoveryengineV1alphaDeleteEngineMetadata: Metadata +// related to the progress of the EngineService.DeleteEngine operation. +// This will be returned by the google.longrunning.Operation.metadata +// field. +type GoogleCloudDiscoveryengineV1alphaDeleteEngineMetadata struct { // CreateTime: Operation create time. CreateTime string `json:"createTime,omitempty"` @@ -2909,65 +2827,18 @@ type GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesMetadata st NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesMetadata - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) -} - -// GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesRespon -// se: Response message for -// CompletionService.ImportSuggestionDenyListEntries method. -type GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesResponse struct { - // ErrorSamples: A sample of errors encountered while processing the - // request. - ErrorSamples []*GoogleRpcStatus `json:"errorSamples,omitempty"` - - // FailedEntriesCount: Count of deny list entries that failed to be - // imported. - FailedEntriesCount int64 `json:"failedEntriesCount,omitempty,string"` - - // ImportedEntriesCount: Count of deny list entries successfully - // imported. - ImportedEntriesCount int64 `json:"importedEntriesCount,omitempty,string"` - - // ForceSendFields is a list of field names (e.g. "ErrorSamples") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. - ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "ErrorSamples") to include - // in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. However, any field with - // an empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. - NullFields []string `json:"-"` -} - -func (s *GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesResponse +func (s *GoogleCloudDiscoveryengineV1alphaDeleteEngineMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaDeleteEngineMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaImportUserEventsMetadata: Metadata -// related to the progress of the Import operation. This is returned by -// the google.longrunning.Operation.metadata field. -type GoogleCloudDiscoveryengineV1alphaImportUserEventsMetadata struct { +// GoogleCloudDiscoveryengineV1alphaDeleteSchemaMetadata: Metadata for +// DeleteSchema LRO. +type GoogleCloudDiscoveryengineV1alphaDeleteSchemaMetadata struct { // CreateTime: Operation create time. CreateTime string `json:"createTime,omitempty"` - // FailureCount: Count of entries that encountered errors while - // processing. - FailureCount int64 `json:"failureCount,omitempty,string"` - - // SuccessCount: Count of entries that were processed successfully. - SuccessCount int64 `json:"successCount,omitempty,string"` - // UpdateTime: Operation last update time. If the operation is done, // this is also the finish time. UpdateTime string `json:"updateTime,omitempty"` @@ -2989,75 +2860,25 @@ type GoogleCloudDiscoveryengineV1alphaImportUserEventsMetadata struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaImportUserEventsMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaImportUserEventsMetadata - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) -} - -// GoogleCloudDiscoveryengineV1alphaImportUserEventsResponse: Response -// of the ImportUserEventsRequest. If the long running operation was -// successful, then this message is returned by the -// google.longrunning.Operations.response field if the operation was -// successful. -type GoogleCloudDiscoveryengineV1alphaImportUserEventsResponse struct { - // ErrorConfig: Echoes the destination for the complete errors if this - // field was set in the request. - ErrorConfig *GoogleCloudDiscoveryengineV1alphaImportErrorConfig `json:"errorConfig,omitempty"` - - // ErrorSamples: A sample of errors encountered while processing the - // request. - ErrorSamples []*GoogleRpcStatus `json:"errorSamples,omitempty"` - - // JoinedEventsCount: Count of user events imported with complete - // existing Documents. - JoinedEventsCount int64 `json:"joinedEventsCount,omitempty,string"` - - // UnjoinedEventsCount: Count of user events imported, but with Document - // information not found in the existing Branch. - UnjoinedEventsCount int64 `json:"unjoinedEventsCount,omitempty,string"` - - // ForceSendFields is a list of field names (e.g. "ErrorConfig") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. - ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "ErrorConfig") to include - // in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. However, any field with - // an empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. - NullFields []string `json:"-"` -} - -func (s *GoogleCloudDiscoveryengineV1alphaImportUserEventsResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaImportUserEventsResponse +func (s *GoogleCloudDiscoveryengineV1alphaDeleteSchemaMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaDeleteSchemaMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaOcrConfig: The OCR options for -// parsing documents. -type GoogleCloudDiscoveryengineV1alphaOcrConfig struct { - // Enabled: Required. If OCR is enabled or not. OCR must be enabled for - // other OcrConfig options to apply. We will only perform OCR on the - // first 80 pages of the PDF files. - Enabled bool `json:"enabled,omitempty"` - - // EnhancedDocumentElements: Apply additional enhanced OCR processing to - // a list of document elements. Supported values: * `table`: advanced - // table parsing model. - EnhancedDocumentElements []string `json:"enhancedDocumentElements,omitempty"` +// GoogleCloudDiscoveryengineV1alphaDeleteTargetSiteMetadata: Metadata +// related to the progress of the +// SiteSearchEngineService.DeleteTargetSite operation. This will be +// returned by the google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1alphaDeleteTargetSiteMetadata struct { + // CreateTime: Operation create time. + CreateTime string `json:"createTime,omitempty"` - // UseNativeText: If true, will use native text instead of OCR text on - // pages containing native text. - UseNativeText bool `json:"useNativeText,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. "Enabled") to + // 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. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -3065,7 +2886,7 @@ type GoogleCloudDiscoveryengineV1alphaOcrConfig struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Enabled") to include in + // 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. However, any field with an // empty value appearing in NullFields will be sent to the server as @@ -3074,26 +2895,20 @@ type GoogleCloudDiscoveryengineV1alphaOcrConfig struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaOcrConfig) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaOcrConfig +func (s *GoogleCloudDiscoveryengineV1alphaDeleteTargetSiteMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaDeleteTargetSiteMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaPurgeDocumentsMetadata: Metadata -// related to the progress of the PurgeDocuments operation. This will be -// returned by the google.longrunning.Operation.metadata field. -type GoogleCloudDiscoveryengineV1alphaPurgeDocumentsMetadata struct { +// GoogleCloudDiscoveryengineV1alphaDisableAdvancedSiteSearchMetadata: +// Metadata related to the progress of the +// SiteSearchEngineService.DisableAdvancedSiteSearch operation. This +// will be returned by the google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1alphaDisableAdvancedSiteSearchMetadata struct { // CreateTime: Operation create time. CreateTime string `json:"createTime,omitempty"` - // FailureCount: Count of entries that encountered errors while - // processing. - FailureCount int64 `json:"failureCount,omitempty,string"` - - // SuccessCount: Count of entries that were deleted successfully. - SuccessCount int64 `json:"successCount,omitempty,string"` - // UpdateTime: Operation last update time. If the operation is done, // this is also the finish time. UpdateTime string `json:"updateTime,omitempty"` @@ -3115,27 +2930,34 @@ type GoogleCloudDiscoveryengineV1alphaPurgeDocumentsMetadata struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaPurgeDocumentsMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaPurgeDocumentsMetadata +func (s *GoogleCloudDiscoveryengineV1alphaDisableAdvancedSiteSearchMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaDisableAdvancedSiteSearchMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaPurgeDocumentsResponse: Response -// message for DocumentService.PurgeDocuments method. If the long -// running operation is successfully done, then this message is returned -// by the google.longrunning.Operations.response field. -type GoogleCloudDiscoveryengineV1alphaPurgeDocumentsResponse struct { - // PurgeCount: The total count of documents purged as a result of the - // operation. - PurgeCount int64 `json:"purgeCount,omitempty,string"` +// GoogleCloudDiscoveryengineV1alphaDisableAdvancedSiteSearchResponse: +// Response message for +// SiteSearchEngineService.DisableAdvancedSiteSearch method. +type GoogleCloudDiscoveryengineV1alphaDisableAdvancedSiteSearchResponse struct { +} - // PurgeSample: A sample of document names that will be deleted. Only - // populated if `force` is set to false. A max of 100 names will be - // returned and the names are chosen at random. - PurgeSample []string `json:"purgeSample,omitempty"` +// GoogleCloudDiscoveryengineV1alphaDocumentProcessingConfig: A +// singleton resource of DataStore. It's empty when DataStore is +// created, which defaults to digital parser. The first call to +// DataStoreService.UpdateDocumentProcessingConfig method will +// initialize the config. +type GoogleCloudDiscoveryengineV1alphaDocumentProcessingConfig struct { + // Name: Output only. The full resource name of the Document Processing + // Config. Format: + // `projects/*/locations/*/collections/*/dataStores/*/documentProcessingC + // onfig`. + Name string `json:"name,omitempty"` - // ForceSendFields is a list of field names (e.g. "PurgeCount") to + // OcrConfig: The OCR config. Currently it only applies to PDFs. + OcrConfig *GoogleCloudDiscoveryengineV1alphaOcrConfig `json:"ocrConfig,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. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -3143,8 +2965,8 @@ type GoogleCloudDiscoveryengineV1alphaPurgeDocumentsResponse struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "PurgeCount") to include in - // API requests with the JSON null value. By default, fields with empty + // 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. However, any field with an // empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. @@ -3152,17 +2974,17 @@ type GoogleCloudDiscoveryengineV1alphaPurgeDocumentsResponse struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaPurgeDocumentsResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaPurgeDocumentsResponse +func (s *GoogleCloudDiscoveryengineV1alphaDocumentProcessingConfig) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaDocumentProcessingConfig raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaPurgeSuggestionDenyListEntriesMetadat -// a: Metadata related to the progress of the -// PurgeSuggestionDenyListEntries operation. This is returned by the -// google.longrunning.Operation.metadata field. -type GoogleCloudDiscoveryengineV1alphaPurgeSuggestionDenyListEntriesMetadata struct { +// GoogleCloudDiscoveryengineV1alphaEnableAdvancedSiteSearchMetadata: +// Metadata related to the progress of the +// SiteSearchEngineService.EnableAdvancedSiteSearch operation. This will +// be returned by the google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1alphaEnableAdvancedSiteSearchMetadata struct { // CreateTime: Operation create time. CreateTime string `json:"createTime,omitempty"` @@ -3187,65 +3009,104 @@ type GoogleCloudDiscoveryengineV1alphaPurgeSuggestionDenyListEntriesMetadata str NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaPurgeSuggestionDenyListEntriesMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaPurgeSuggestionDenyListEntriesMetadata +func (s *GoogleCloudDiscoveryengineV1alphaEnableAdvancedSiteSearchMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaEnableAdvancedSiteSearchMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaPurgeSuggestionDenyListEntriesRespons -// e: Response message for -// CompletionService.PurgeSuggestionDenyListEntries method. -type GoogleCloudDiscoveryengineV1alphaPurgeSuggestionDenyListEntriesResponse struct { - // ErrorSamples: A sample of errors encountered while processing the - // request. - ErrorSamples []*GoogleRpcStatus `json:"errorSamples,omitempty"` - - // PurgeCount: Number of suggestion deny list entries purged. - PurgeCount int64 `json:"purgeCount,omitempty,string"` +// GoogleCloudDiscoveryengineV1alphaEnableAdvancedSiteSearchResponse: +// Response message for SiteSearchEngineService.EnableAdvancedSiteSearch +// method. +type GoogleCloudDiscoveryengineV1alphaEnableAdvancedSiteSearchResponse struct { +} - // ForceSendFields is a list of field names (e.g. "ErrorSamples") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. - ForceSendFields []string `json:"-"` +// GoogleCloudDiscoveryengineV1alphaEngine: Metadata that describes the +// training and serving parameters of an Engine. +type GoogleCloudDiscoveryengineV1alphaEngine struct { + // ChatEngineConfig: Configurations for the Chat Engine. Only applicable + // if solution_type is SOLUTION_TYPE_CHAT. + ChatEngineConfig *GoogleCloudDiscoveryengineV1alphaEngineChatEngineConfig `json:"chatEngineConfig,omitempty"` - // NullFields is a list of field names (e.g. "ErrorSamples") to include - // in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. However, any field with - // an empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. - NullFields []string `json:"-"` -} + // ChatEngineMetadata: Output only. Additional information of the Chat + // Engine. Only applicable if solution_type is SOLUTION_TYPE_CHAT. + ChatEngineMetadata *GoogleCloudDiscoveryengineV1alphaEngineChatEngineMetadata `json:"chatEngineMetadata,omitempty"` -func (s *GoogleCloudDiscoveryengineV1alphaPurgeSuggestionDenyListEntriesResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaPurgeSuggestionDenyListEntriesResponse - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) -} + // CommonConfig: Common config spec that specifies the metadata of the + // engine. + CommonConfig *GoogleCloudDiscoveryengineV1alphaEngineCommonConfig `json:"commonConfig,omitempty"` -// GoogleCloudDiscoveryengineV1alphaPurgeUserEventsMetadata: Metadata -// related to the progress of the PurgeUserEvents operation. This will -// be returned by the google.longrunning.Operation.metadata field. -type GoogleCloudDiscoveryengineV1alphaPurgeUserEventsMetadata struct { - // CreateTime: Operation create time. + // CreateTime: Output only. Timestamp the Recommendation Engine was + // created at. CreateTime string `json:"createTime,omitempty"` - // FailureCount: Count of entries that encountered errors while - // processing. - FailureCount int64 `json:"failureCount,omitempty,string"` + // DataStoreIds: The data stores associated with this engine. For + // SOLUTION_TYPE_SEARCH and SOLUTION_TYPE_RECOMMENDATION type of + // engines, they can only associate with at most one data store. If + // solution_type is SOLUTION_TYPE_CHAT, multiple DataStores in the same + // Collection can be associated here. Note that when used in + // CreateEngineRequest, one DataStore id must be provided as the system + // will use it for necessary initializations. + DataStoreIds []string `json:"dataStoreIds,omitempty"` - // SuccessCount: Count of entries that were deleted successfully. - SuccessCount int64 `json:"successCount,omitempty,string"` + // DisplayName: Required. The display name of the engine. Should be + // human readable. UTF-8 encoded string with limit of 1024 characters. + DisplayName string `json:"displayName,omitempty"` - // UpdateTime: Operation last update time. If the operation is done, - // this is also the finish time. + // IndustryVertical: The industry vertical that the engine registers. + // The restriction of the Engine industry vertical is based on + // DataStore: If unspecified, default to `GENERIC`. Vertical on Engine + // has to match vertical of the DataStore liniked to the engine. + // + // Possible values: + // "INDUSTRY_VERTICAL_UNSPECIFIED" - Value used when unset. + // "GENERIC" - The generic vertical for documents that are not + // specific to any industry vertical. + // "MEDIA" - The media industry vertical. + IndustryVertical string `json:"industryVertical,omitempty"` + + // MediaRecommendationEngineConfig: Configurations for the Media Engine. + // Only applicable on the data stores with solution_type + // SOLUTION_TYPE_RECOMMENDATION and IndustryVertical.MEDIA vertical. + MediaRecommendationEngineConfig *GoogleCloudDiscoveryengineV1alphaEngineMediaRecommendationEngineConfig `json:"mediaRecommendationEngineConfig,omitempty"` + + // Name: Immutable. The fully qualified resource name of the engine. + // This field must be a UTF-8 encoded string with a length limit of 1024 + // characters. Format: + // `projects/{project_number}/locations/{location}/collections/{collectio + // n}/engines/{engine}` engine should be 1-63 characters, and valid + // characters are /a-z0-9*/. Otherwise, an INVALID_ARGUMENT error is + // returned. + Name string `json:"name,omitempty"` + + // RecommendationMetadata: Output only. Additional information of a + // recommendation engine. Only applicable if solution_type is + // SOLUTION_TYPE_RECOMMENDATION. + RecommendationMetadata *GoogleCloudDiscoveryengineV1alphaEngineRecommendationMetadata `json:"recommendationMetadata,omitempty"` + + // SearchEngineConfig: Configurations for the Search Engine. Only + // applicable if solution_type is SOLUTION_TYPE_SEARCH. + SearchEngineConfig *GoogleCloudDiscoveryengineV1alphaEngineSearchEngineConfig `json:"searchEngineConfig,omitempty"` + + // SimilarDocumentsConfig: Additional config specs for a `similar-items` + // engine. + SimilarDocumentsConfig *GoogleCloudDiscoveryengineV1alphaEngineSimilarDocumentsEngineConfig `json:"similarDocumentsConfig,omitempty"` + + // SolutionType: Required. The solutions of the engine. + // + // Possible values: + // "SOLUTION_TYPE_UNSPECIFIED" - Default value. + // "SOLUTION_TYPE_RECOMMENDATION" - Used for Recommendations AI. + // "SOLUTION_TYPE_SEARCH" - Used for Discovery Search. + // "SOLUTION_TYPE_CHAT" - Used for use cases related to the Generative + // AI agent. + SolutionType string `json:"solutionType,omitempty"` + + // UpdateTime: Output only. Timestamp the Recommendation Engine was last + // updated. UpdateTime string `json:"updateTime,omitempty"` - // ForceSendFields is a list of field names (e.g. "CreateTime") to + // ForceSendFields is a list of field names (e.g. "ChatEngineConfig") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -3253,85 +3114,98 @@ type GoogleCloudDiscoveryengineV1alphaPurgeUserEventsMetadata struct { // This may be used to include empty fields in Patch requests. 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. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "ChatEngineConfig") to + // include in API requests with the JSON null value. By default, fields + // with empty values are omitted from API requests. However, any field + // with an empty value appearing in NullFields will be sent to the + // server as null. It is an error if a field in this list has a + // non-empty value. This may be used to include null fields in Patch + // requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaPurgeUserEventsMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaPurgeUserEventsMetadata +func (s *GoogleCloudDiscoveryengineV1alphaEngine) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaEngine raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaPurgeUserEventsResponse: Response of -// the PurgeUserEventsRequest. If the long running operation is -// successfully done, then this message is returned by the -// google.longrunning.Operations.response field. -type GoogleCloudDiscoveryengineV1alphaPurgeUserEventsResponse struct { - // PurgeCount: The total count of events purged as a result of the - // operation. - PurgeCount int64 `json:"purgeCount,omitempty,string"` +// GoogleCloudDiscoveryengineV1alphaEngineChatEngineConfig: +// Configurations for a Chat Engine. +type GoogleCloudDiscoveryengineV1alphaEngineChatEngineConfig struct { + // AgentCreationConfig: The configurationt generate the Dialogflow agent + // that is associated to this Engine. Note that these configurations are + // one-time consumed by and passed to Dialogflow service. It means they + // cannot be retrieved using EngineService.GetEngine or + // EngineService.ListEngines API after engine creation. + AgentCreationConfig *GoogleCloudDiscoveryengineV1alphaEngineChatEngineConfigAgentCreationConfig `json:"agentCreationConfig,omitempty"` - // ForceSendFields is a list of field names (e.g. "PurgeCount") to - // unconditionally include in API requests. By default, fields with + // DialogflowAgentToLink: The resource name of an exist Dialogflow agent + // to link to this Chat Engine. Customers can either provide + // `agent_creation_config` to create agent or provide an agent name that + // links the agent with the Chat engine. Format: + // `projects//locations//agents/`. Note that the + // `dialogflow_agent_to_link` are one-time consumed by and passed to + // Dialogflow service. It means they cannot be retrieved using + // EngineService.GetEngine or EngineService.ListEngines API after engine + // creation. Please use ChatEngineMetadata.dialogflow_agent for actual + // agent association after Engine is created. + DialogflowAgentToLink string `json:"dialogflowAgentToLink,omitempty"` + + // ForceSendFields is a list of field names (e.g. "AgentCreationConfig") + // to unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be // sent to the server regardless of whether the field is empty or not. // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "PurgeCount") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "AgentCreationConfig") to + // include in API requests with the JSON null value. By default, fields + // with empty values are omitted from API requests. However, any field + // with an empty value appearing in NullFields will be sent to the + // server as null. It is an error if a field in this list has a + // non-empty value. This may be used to include null fields in Patch + // requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaPurgeUserEventsResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaPurgeUserEventsResponse +func (s *GoogleCloudDiscoveryengineV1alphaEngineChatEngineConfig) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaEngineChatEngineConfig raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaRecrawlUrisMetadata: Metadata -// related to the progress of the SiteSearchEngineService.RecrawlUris -// operation. This will be returned by the -// google.longrunning.Operation.metadata field. -type GoogleCloudDiscoveryengineV1alphaRecrawlUrisMetadata struct { - // CreateTime: Operation create time. - CreateTime string `json:"createTime,omitempty"` - - // InvalidUris: Unique URIs in the request that don't match any - // TargetSite in the DataStore, only match TargetSites that haven't been - // fully indexed, or match a TargetSite with type EXCLUDE. - InvalidUris []string `json:"invalidUris,omitempty"` - - // PendingCount: Total number of URIs that have yet to be crawled. - PendingCount int64 `json:"pendingCount,omitempty"` - - // QuotaExceededCount: Total number of URIs that were rejected due to - // insufficient indexing resources. - QuotaExceededCount int64 `json:"quotaExceededCount,omitempty"` +// GoogleCloudDiscoveryengineV1alphaEngineChatEngineConfigAgentCreationCo +// nfig: Configurations for generating a Dialogflow agent. Note that +// these configurations are one-time consumed by and passed to +// Dialogflow service. It means they cannot be retrieved using +// EngineService.GetEngine or EngineService.ListEngines API after engine +// creation. +type GoogleCloudDiscoveryengineV1alphaEngineChatEngineConfigAgentCreationConfig struct { + // Business: Name of the company, organization or other entity that the + // agent represents. Used for knowledge connector LLM prompt and for + // knowledge search. + Business string `json:"business,omitempty"` - // SuccessCount: Total number of URIs that have been crawled so far. - SuccessCount int64 `json:"successCount,omitempty"` + // DefaultLanguageCode: Required. The default language of the agent as a + // language tag. See Language Support + // (https://cloud.google.com/dialogflow/docs/reference/language) for a + // list of the currently supported language codes. + DefaultLanguageCode string `json:"defaultLanguageCode,omitempty"` - // UpdateTime: Operation last update time. If the operation is done, - // this is also the finish time. - UpdateTime string `json:"updateTime,omitempty"` + // Location: Agent location for Agent creation, supported values: + // global/us/eu. If not provided, us Engine will create Agent using + // us-central-1 by default; eu Engine will create Agent using eu-west-1 + // by default. + Location string `json:"location,omitempty"` - // ValidUrisCount: Total number of unique URIs in the request that are - // not in invalid_uris. - ValidUrisCount int64 `json:"validUrisCount,omitempty"` + // TimeZone: Required. The time zone of the agent from the time zone + // database (https://www.iana.org/time-zones), e.g., America/New_York, + // Europe/Paris. + TimeZone string `json:"timeZone,omitempty"` - // ForceSendFields is a list of field names (e.g. "CreateTime") to + // ForceSendFields is a list of field names (e.g. "Business") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -3339,7 +3213,7 @@ type GoogleCloudDiscoveryengineV1alphaRecrawlUrisMetadata struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "CreateTime") to include in + // NullFields is a list of field names (e.g. "Business") to include in // API requests with the JSON null value. By default, fields with empty // values are omitted from API requests. However, any field with an // empty value appearing in NullFields will be sent to the server as @@ -3348,56 +3222,20 @@ type GoogleCloudDiscoveryengineV1alphaRecrawlUrisMetadata struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaRecrawlUrisMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaRecrawlUrisMetadata +func (s *GoogleCloudDiscoveryengineV1alphaEngineChatEngineConfigAgentCreationConfig) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaEngineChatEngineConfigAgentCreationConfig raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponse: Response -// message for SiteSearchEngineService.RecrawlUris method. -type GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponse struct { - // FailedUris: URIs that were not crawled before the LRO terminated. - FailedUris []string `json:"failedUris,omitempty"` - - // FailureSamples: Details for a sample of up to 10 `failed_uris`. - FailureSamples []*GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfo `json:"failureSamples,omitempty"` - - // ForceSendFields is a list of field names (e.g. "FailedUris") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. - ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "FailedUris") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. - NullFields []string `json:"-"` -} - -func (s *GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponse - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) -} - -// GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfo: -// Details about why a particular URI failed to be crawled. Each -// FailureInfo contains one FailureReason per CorpusType. -type GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfo struct { - // FailureReasons: List of failure reasons by corpus type (e.g. desktop, - // mobile). - FailureReasons []*GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfoFailureReason `json:"failureReasons,omitempty"` - - // Uri: URI that failed to be crawled. - Uri string `json:"uri,omitempty"` +// GoogleCloudDiscoveryengineV1alphaEngineChatEngineMetadata: Additional +// information of a Chat Engine. Fields in this message are output only. +type GoogleCloudDiscoveryengineV1alphaEngineChatEngineMetadata struct { + // DialogflowAgent: The resource name of a Dialogflow agent, that this + // Chat Engine refers to. Format: `projects//locations//agents/`. + DialogflowAgent string `json:"dialogflowAgent,omitempty"` - // ForceSendFields is a list of field names (e.g. "FailureReasons") to + // ForceSendFields is a list of field names (e.g. "DialogflowAgent") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -3405,7 +3243,7 @@ type GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfo struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "FailureReasons") to + // NullFields is a list of field names (e.g. "DialogflowAgent") to // include in API requests with the JSON null value. By default, fields // with empty values are omitted from API requests. However, any field // with an empty value appearing in NullFields will be sent to the @@ -3415,73 +3253,21 @@ type GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfo struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfo) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfo - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) -} - -// GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfoFailure -// Reason: Details about why crawling failed for a particular -// CorpusType, e.g. DESKTOP and MOBILE crawling may fail for different -// reasons. -type GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfoFailureReason struct { - // CorpusType: DESKTOP, MOBILE, or CORPUS_TYPE_UNSPECIFIED. - // - // Possible values: - // "CORPUS_TYPE_UNSPECIFIED" - Default value. - // "DESKTOP" - Denotes a crawling attempt for the desktop version of a - // page. - // "MOBILE" - Denotes a crawling attempt for the mobile version of a - // page. - CorpusType string `json:"corpusType,omitempty"` - - // ErrorMessage: Reason why the URI was not crawled. - ErrorMessage string `json:"errorMessage,omitempty"` - - // ForceSendFields is a list of field names (e.g. "CorpusType") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. - ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "CorpusType") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. - NullFields []string `json:"-"` -} - -func (s *GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfoFailureReason) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfoFailureReason +func (s *GoogleCloudDiscoveryengineV1alphaEngineChatEngineMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaEngineChatEngineMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaSchema: Defines the structure and -// layout of a type of document data. -type GoogleCloudDiscoveryengineV1alphaSchema struct { - // FieldConfigs: Output only. Configurations for fields of the schema. - FieldConfigs []*GoogleCloudDiscoveryengineV1alphaFieldConfig `json:"fieldConfigs,omitempty"` - - // JsonSchema: The JSON representation of the schema. - JsonSchema string `json:"jsonSchema,omitempty"` - - // Name: Immutable. The full resource name of the schema, in the format - // of - // `projects/{project}/locations/{location}/collections/{collection}/data - // Stores/{data_store}/schemas/{schema}`. This field must be a UTF-8 - // encoded string with a length limit of 1024 characters. - Name string `json:"name,omitempty"` - - // StructSchema: The structured representation of the schema. - StructSchema googleapi.RawMessage `json:"structSchema,omitempty"` +// GoogleCloudDiscoveryengineV1alphaEngineCommonConfig: Common +// configurations for an Engine. +type GoogleCloudDiscoveryengineV1alphaEngineCommonConfig struct { + // CompanyName: Immutable. The name of the company, business or entity + // that is associated with the engine. Setting this may help improve LLM + // related features. + CompanyName string `json:"companyName,omitempty"` - // ForceSendFields is a list of field names (e.g. "FieldConfigs") to + // ForceSendFields is a list of field names (e.g. "CompanyName") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -3489,7 +3275,7 @@ type GoogleCloudDiscoveryengineV1alphaSchema struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "FieldConfigs") to include + // NullFields is a list of field names (e.g. "CompanyName") to include // in API requests with the JSON null value. By default, fields with // empty values are omitted from API requests. However, any field with // an empty value appearing in NullFields will be sent to the server as @@ -3498,32 +3284,55 @@ type GoogleCloudDiscoveryengineV1alphaSchema struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaSchema) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSchema +func (s *GoogleCloudDiscoveryengineV1alphaEngineCommonConfig) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaEngineCommonConfig raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaSiteVerificationInfo: Verification -// information for target sites in advanced site search. -type GoogleCloudDiscoveryengineV1alphaSiteVerificationInfo struct { - // SiteVerificationState: Site verification state indicating the - // ownership and validity. +// GoogleCloudDiscoveryengineV1alphaEngineMediaRecommendationEngineConfig +// : Additional config specs for a Media Recommendation engine. +type GoogleCloudDiscoveryengineV1alphaEngineMediaRecommendationEngineConfig struct { + // OptimizationObjective: The optimization objective. e.g., `cvr`. This + // field together with optimization_objective describe engine metadata + // to use to control engine training and serving. Currently supported + // values: `ctr`, `cvr`. If not specified, we choose default based on + // engine type. Default depends on type of recommendation: + // `recommended-for-you` => `ctr` `others-you-may-like` => `ctr` + OptimizationObjective string `json:"optimizationObjective,omitempty"` + + // OptimizationObjectiveConfig: Name and value of the custom threshold + // for cvr optimization_objective. For target_field `watch-time`, + // target_field_value must be an integer value indicating the media + // progress time in seconds between (0, 86400] (excludes 0, includes + // 86400) (e.g., 90). For target_field `watch-percentage`, the + // target_field_value must be a valid float value between (0, 1.0] + // (excludes 0, includes 1.0) (e.g., 0.5). + OptimizationObjectiveConfig *GoogleCloudDiscoveryengineV1alphaEngineMediaRecommendationEngineConfigOptimizationObjectiveConfig `json:"optimizationObjectiveConfig,omitempty"` + + // TrainingState: The training state that the engine is in (e.g. + // `TRAINING` or `PAUSED`). Since part of the cost of running the + // service is frequency of training - this can be used to determine when + // to train engine in order to control cost. If not specified: the + // default value for `CreateEngine` method is `TRAINING`. The default + // value for `UpdateEngine` method is to keep the state the same as + // before. // // Possible values: - // "SITE_VERIFICATION_STATE_UNSPECIFIED" - Defaults to VERIFIED. - // "VERIFIED" - Site ownership verified. - // "UNVERIFIED" - Site ownership pending verification or verification - // failed. - // "EXEMPTED" - Site exempt from verification, e.g. a public website - // that opens to all. - SiteVerificationState string `json:"siteVerificationState,omitempty"` + // "TRAINING_STATE_UNSPECIFIED" - Unspecified training state. + // "PAUSED" - The engine training is paused. + // "TRAINING" - The engine is training. + TrainingState string `json:"trainingState,omitempty"` - // VerifyTime: Latest site verification time. - VerifyTime string `json:"verifyTime,omitempty"` + // Type: Required. The type of engine. e.g., `recommended-for-you`. This + // field together with optimization_objective describe engine metadata + // to use to control engine training and serving. Currently supported + // values: `recommended-for-you`, `others-you-may-like`, + // `more-like-this`, `most-popular-items`. + Type string `json:"type,omitempty"` // ForceSendFields is a list of field names (e.g. - // "SiteVerificationState") to unconditionally include in API requests. + // "OptimizationObjective") to unconditionally include in API requests. // By default, fields with empty or default values are omitted from API // requests. However, any non-pointer, non-interface field appearing in // ForceSendFields will be sent to the server regardless of whether the @@ -3531,7 +3340,7 @@ type GoogleCloudDiscoveryengineV1alphaSiteVerificationInfo struct { // Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "SiteVerificationState") to + // NullFields is a list of field names (e.g. "OptimizationObjective") to // include in API requests with the JSON null value. By default, fields // with empty values are omitted from API requests. However, any field // with an empty value appearing in NullFields will be sent to the @@ -3541,74 +3350,25 @@ type GoogleCloudDiscoveryengineV1alphaSiteVerificationInfo struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaSiteVerificationInfo) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSiteVerificationInfo +func (s *GoogleCloudDiscoveryengineV1alphaEngineMediaRecommendationEngineConfig) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaEngineMediaRecommendationEngineConfig raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaTargetSite: A target site for the -// SiteSearchEngine. -type GoogleCloudDiscoveryengineV1alphaTargetSite struct { - // ExactMatch: Input only. If set to false, a uri_pattern is generated - // to include all pages whose address contains the provided_uri_pattern. - // If set to true, an uri_pattern is generated to try to be an exact - // match of the provided_uri_pattern or just the specific page if the - // provided_uri_pattern is a specific one. provided_uri_pattern is - // always normalized to generate the URI pattern to be used by the - // search engine. - ExactMatch bool `json:"exactMatch,omitempty"` - - // FailureReason: Output only. Failure reason. - FailureReason *GoogleCloudDiscoveryengineV1alphaTargetSiteFailureReason `json:"failureReason,omitempty"` - - // GeneratedUriPattern: Output only. This is system-generated based on - // the provided_uri_pattern. - GeneratedUriPattern string `json:"generatedUriPattern,omitempty"` - - // IndexingStatus: Output only. Indexing status. - // - // Possible values: - // "INDEXING_STATUS_UNSPECIFIED" - Defaults to SUCCEEDED. - // "PENDING" - The target site is in the update queue and will be - // picked up by indexing pipeline. - // "FAILED" - The target site fails to be indexed. - // "SUCCEEDED" - The target site has been indexed. - // "DELETING" - The previously indexed target site has been marked to - // be deleted. This is a transitioning state which will resulted in - // either: 1. target site deleted if unindexing is successful; 2. state - // reverts to SUCCEEDED if the unindexing fails. - IndexingStatus string `json:"indexingStatus,omitempty"` - - // Name: Output only. The fully qualified resource name of the target - // site. - // `projects/{project}/locations/{location}/collections/{collection}/data - // Stores/{data_store}/siteSearchEngine/targetSites/{target_site}` The - // `target_site_id` is system-generated. - Name string `json:"name,omitempty"` - - // ProvidedUriPattern: Required. Input only. The user provided URI - // pattern from which the `generated_uri_pattern` is generated. - ProvidedUriPattern string `json:"providedUriPattern,omitempty"` - - // SiteVerificationInfo: Output only. Site ownership and validity - // verification status. - SiteVerificationInfo *GoogleCloudDiscoveryengineV1alphaSiteVerificationInfo `json:"siteVerificationInfo,omitempty"` - - // Type: The type of the target site, e.g. whether the site is to be - // included or excluded. - // - // Possible values: - // "TYPE_UNSPECIFIED" - This value is unused. In this case, server - // behavior defaults to Type.INCLUDE. - // "INCLUDE" - Include the target site. - // "EXCLUDE" - Exclude the target site. - Type string `json:"type,omitempty"` +// GoogleCloudDiscoveryengineV1alphaEngineMediaRecommendationEngineConfig +// OptimizationObjectiveConfig: Custom threshold for `cvr` +// optimization_objective. +type GoogleCloudDiscoveryengineV1alphaEngineMediaRecommendationEngineConfigOptimizationObjectiveConfig struct { + // TargetField: Required. The name of the field to target. Currently + // supported values: `watch-percentage`, `watch-time`. + TargetField string `json:"targetField,omitempty"` - // UpdateTime: Output only. The target site's last updated time. - UpdateTime string `json:"updateTime,omitempty"` + // TargetFieldValueFloat: Required. The threshold to be applied to the + // target (e.g., 0.5). + TargetFieldValueFloat float64 `json:"targetFieldValueFloat,omitempty"` - // ForceSendFields is a list of field names (e.g. "ExactMatch") to + // ForceSendFields is a list of field names (e.g. "TargetField") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -3616,65 +3376,78 @@ type GoogleCloudDiscoveryengineV1alphaTargetSite struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "ExactMatch") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as + // NullFields is a list of field names (e.g. "TargetField") to include + // in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. However, any field with + // an empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaTargetSite) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaTargetSite +func (s *GoogleCloudDiscoveryengineV1alphaEngineMediaRecommendationEngineConfigOptimizationObjectiveConfig) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaEngineMediaRecommendationEngineConfigOptimizationObjectiveConfig raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaTargetSiteFailureReason: Site search -// indexing failure reasons. -type GoogleCloudDiscoveryengineV1alphaTargetSiteFailureReason struct { - // QuotaFailure: Failed due to insufficient quota. - QuotaFailure *GoogleCloudDiscoveryengineV1alphaTargetSiteFailureReasonQuotaFailure `json:"quotaFailure,omitempty"` - - // ForceSendFields is a list of field names (e.g. "QuotaFailure") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. - ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "QuotaFailure") to include - // in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. However, any field with - // an empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. - NullFields []string `json:"-"` +func (s *GoogleCloudDiscoveryengineV1alphaEngineMediaRecommendationEngineConfigOptimizationObjectiveConfig) UnmarshalJSON(data []byte) error { + type NoMethod GoogleCloudDiscoveryengineV1alphaEngineMediaRecommendationEngineConfigOptimizationObjectiveConfig + var s1 struct { + TargetFieldValueFloat gensupport.JSONFloat64 `json:"targetFieldValueFloat"` + *NoMethod + } + s1.NoMethod = (*NoMethod)(s) + if err := json.Unmarshal(data, &s1); err != nil { + return err + } + s.TargetFieldValueFloat = float64(s1.TargetFieldValueFloat) + return nil } -func (s *GoogleCloudDiscoveryengineV1alphaTargetSiteFailureReason) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaTargetSiteFailureReason - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) -} +// GoogleCloudDiscoveryengineV1alphaEngineRecommendationMetadata: +// Additional information of a recommendation engine. +type GoogleCloudDiscoveryengineV1alphaEngineRecommendationMetadata struct { + // DataState: Output only. The state of data requirements for this + // engine: `DATA_OK` and `DATA_ERROR`. Engine cannot be trained if the + // data is in `DATA_ERROR` state. Engine can have `DATA_ERROR` state + // even if serving state is `ACTIVE`: engines were trained successfully + // before, but cannot be refreshed because the underlying engine no + // longer has sufficient data for training. + // + // Possible values: + // "DATA_STATE_UNSPECIFIED" - Unspecified default value, should never + // be explicitly set. + // "DATA_OK" - The engine has sufficient training data. + // "DATA_ERROR" - The engine does not have sufficient training data. + // Error messages can be queried via Stackdriver. + DataState string `json:"dataState,omitempty"` -type GoogleCloudDiscoveryengineV1alphaTargetSiteFailureReasonQuotaFailure struct { -} + // LastTuneTime: Output only. The timestamp when the latest successful + // tune finished. Only applicable on Media Recommendation engines. + LastTuneTime string `json:"lastTuneTime,omitempty"` -// GoogleCloudDiscoveryengineV1alphaTrainCustomModelMetadata: Metadata -// related to the progress of the TrainCustomModel operation. This is -// returned by the google.longrunning.Operation.metadata field. -type GoogleCloudDiscoveryengineV1alphaTrainCustomModelMetadata struct { - // CreateTime: Operation create time. - CreateTime string `json:"createTime,omitempty"` + // ServingState: Output only. The serving state of the engine: `ACTIVE`, + // `NOT_ACTIVE`. + // + // Possible values: + // "SERVING_STATE_UNSPECIFIED" - Unspecified serving state. + // "INACTIVE" - The engine is not serving. + // "ACTIVE" - The engine is serving and can be queried. + // "TUNED" - The engine is trained on tuned hyperparameters and can be + // queried. + ServingState string `json:"servingState,omitempty"` - // UpdateTime: Operation last update time. If the operation is done, - // this is also the finish time. - UpdateTime string `json:"updateTime,omitempty"` + // TuningOperation: Output only. The latest tune operation id associated + // with the engine. Only applicable on Media Recommendation engines. If + // present, this operation id can be used to determine if there is an + // ongoing tune for this engine. To check the operation status, send the + // GetOperation request with this operation id in the engine resource + // format. If no tuning has happened for this engine, the string is + // empty. + TuningOperation string `json:"tuningOperation,omitempty"` - // ForceSendFields is a list of field names (e.g. "CreateTime") to + // ForceSendFields is a list of field names (e.g. "DataState") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -3682,7 +3455,7 @@ type GoogleCloudDiscoveryengineV1alphaTrainCustomModelMetadata struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "CreateTime") to include in + // NullFields is a list of field names (e.g. "DataState") to include in // API requests with the JSON null value. By default, fields with empty // values are omitted from API requests. However, any field with an // empty value appearing in NullFields will be sent to the server as @@ -3691,32 +3464,36 @@ type GoogleCloudDiscoveryengineV1alphaTrainCustomModelMetadata struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaTrainCustomModelMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaTrainCustomModelMetadata +func (s *GoogleCloudDiscoveryengineV1alphaEngineRecommendationMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaEngineRecommendationMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaTrainCustomModelResponse: Response -// of the TrainCustomModelRequest. This message is returned by the -// google.longrunning.Operations.response field. -type GoogleCloudDiscoveryengineV1alphaTrainCustomModelResponse struct { - // ErrorConfig: Echoes the destination for the complete errors in the - // request if set. - ErrorConfig *GoogleCloudDiscoveryengineV1alphaImportErrorConfig `json:"errorConfig,omitempty"` - - // ErrorSamples: A sample of errors encountered while processing the - // data. - ErrorSamples []*GoogleRpcStatus `json:"errorSamples,omitempty"` +// GoogleCloudDiscoveryengineV1alphaEngineSearchEngineConfig: +// Configurations for a Search Engine. +type GoogleCloudDiscoveryengineV1alphaEngineSearchEngineConfig struct { + // SearchAddOns: The add-on that this search engine enables. + // + // Possible values: + // "SEARCH_ADD_ON_UNSPECIFIED" - Default value when the enum is + // unspecified. This is invalid to use. + // "SEARCH_ADD_ON_LLM" - Large language model add-on. + SearchAddOns []string `json:"searchAddOns,omitempty"` - // ModelStatus: The trained model status. Possible values are: * - // **bad-data**: The training data quality is bad. * **no-improvement**: - // Tuning didn't improve performance. Won't deploy. * **in-progress**: - // Model training is in progress. * **ready**: The model is ready for - // serving. - ModelStatus string `json:"modelStatus,omitempty"` + // SearchTier: The search feature tier of this engine. Different tiers + // might have different pricing. To learn more, please check the pricing + // documentation. Defaults to SearchTier.SEARCH_TIER_STANDARD if not + // specified. + // + // Possible values: + // "SEARCH_TIER_UNSPECIFIED" - Default value when the enum is + // unspecified. This is invalid to use. + // "SEARCH_TIER_STANDARD" - Standard tier. + // "SEARCH_TIER_ENTERPRISE" - Enterprise tier. + SearchTier string `json:"searchTier,omitempty"` - // ForceSendFields is a list of field names (e.g. "ErrorConfig") to + // ForceSendFields is a list of field names (e.g. "SearchAddOns") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -3724,7 +3501,7 @@ type GoogleCloudDiscoveryengineV1alphaTrainCustomModelResponse struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "ErrorConfig") to include + // NullFields is a list of field names (e.g. "SearchAddOns") to include // in API requests with the JSON null value. By default, fields with // empty values are omitted from API requests. However, any field with // an empty value appearing in NullFields will be sent to the server as @@ -3733,59 +3510,24 @@ type GoogleCloudDiscoveryengineV1alphaTrainCustomModelResponse struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaTrainCustomModelResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaTrainCustomModelResponse - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) -} - -// GoogleCloudDiscoveryengineV1alphaTuneEngineMetadata: Metadata -// associated with a tune operation. -type GoogleCloudDiscoveryengineV1alphaTuneEngineMetadata struct { - // Engine: Required. The resource name of the engine that this tune - // applies to. Format: - // `projects/{project_number}/locations/{location_id}/collections/{collec - // tion_id}/engines/{engine_id}` - Engine string `json:"engine,omitempty"` - - // ForceSendFields is a list of field names (e.g. "Engine") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. - ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Engine") to include in API - // requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. - NullFields []string `json:"-"` -} - -func (s *GoogleCloudDiscoveryengineV1alphaTuneEngineMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaTuneEngineMetadata +func (s *GoogleCloudDiscoveryengineV1alphaEngineSearchEngineConfig) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaEngineSearchEngineConfig raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaTuneEngineResponse: Response -// associated with a tune operation. -type GoogleCloudDiscoveryengineV1alphaTuneEngineResponse struct { +// GoogleCloudDiscoveryengineV1alphaEngineSimilarDocumentsEngineConfig: +// Additional config specs for a `similar-items` engine. +type GoogleCloudDiscoveryengineV1alphaEngineSimilarDocumentsEngineConfig struct { } -// GoogleCloudDiscoveryengineV1alphaUpdateSchemaMetadata: Metadata for -// UpdateSchema LRO. -type GoogleCloudDiscoveryengineV1alphaUpdateSchemaMetadata struct { +// GoogleCloudDiscoveryengineV1alphaEstimateDataSizeMetadata: Metadata +// related to the progress of the EstimateDataSize operation. This is +// returned by the google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1alphaEstimateDataSizeMetadata 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. However, any @@ -3803,25 +3545,25 @@ type GoogleCloudDiscoveryengineV1alphaUpdateSchemaMetadata struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaUpdateSchemaMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaUpdateSchemaMetadata +func (s *GoogleCloudDiscoveryengineV1alphaEstimateDataSizeMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaEstimateDataSizeMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaUpdateTargetSiteMetadata: Metadata -// related to the progress of the -// SiteSearchEngineService.UpdateTargetSite operation. This will be -// returned by the google.longrunning.Operation.metadata field. -type GoogleCloudDiscoveryengineV1alphaUpdateTargetSiteMetadata struct { - // CreateTime: Operation create time. - CreateTime string `json:"createTime,omitempty"` +// GoogleCloudDiscoveryengineV1alphaEstimateDataSizeResponse: Response +// of the EstimateDataSize request. If the long running operation was +// successful, then this message is returned by the +// google.longrunning.Operations.response field if the operation was +// successful. +type GoogleCloudDiscoveryengineV1alphaEstimateDataSizeResponse struct { + // DataSizeBytes: Data size in terms of bytes. + DataSizeBytes int64 `json:"dataSizeBytes,omitempty,string"` - // UpdateTime: Operation last update time. If the operation is done, - // this is also the finish time. - UpdateTime string `json:"updateTime,omitempty"` + // DocumentCount: Total number of documents. + DocumentCount int64 `json:"documentCount,omitempty,string"` - // ForceSendFields is a list of field names (e.g. "CreateTime") to + // ForceSendFields is a list of field names (e.g. "DataSizeBytes") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -3829,106 +3571,172 @@ type GoogleCloudDiscoveryengineV1alphaUpdateTargetSiteMetadata struct { // This may be used to include empty fields in Patch requests. 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. However, any field with an - // empty value appearing in NullFields will be sent to the server as + // NullFields is a list of field names (e.g. "DataSizeBytes") to include + // in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. However, any field with + // an empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1alphaUpdateTargetSiteMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaUpdateTargetSiteMetadata +func (s *GoogleCloudDiscoveryengineV1alphaEstimateDataSizeResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaEstimateDataSizeResponse raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaBigQuerySource: BigQuery source -// import data from. -type GoogleCloudDiscoveryengineV1betaBigQuerySource struct { - // DataSchema: The schema to use when parsing the data from the source. - // Supported values for user event imports: * `user_event` (default): - // One UserEvent per row. Supported values for document imports: * - // `document` (default): One Document format per row. Each document must - // have a valid Document.id and one of Document.json_data or - // Document.struct_data. * `custom`: One custom data per row in - // arbitrary format that conforms to the defined Schema of the data - // store. This can only be used by Gen App Builder. - DataSchema string `json:"dataSchema,omitempty"` - - // DatasetId: Required. The BigQuery data set to copy the data from with - // a length limit of 1,024 characters. - DatasetId string `json:"datasetId,omitempty"` - - // GcsStagingDir: Intermediate Cloud Storage directory used for the - // import with a length limit of 2,000 characters. Can be specified if - // one wants to have the BigQuery export to a specific Cloud Storage - // directory. - GcsStagingDir string `json:"gcsStagingDir,omitempty"` - - // PartitionDate: BigQuery time partitioned table's _PARTITIONDATE in - // YYYY-MM-DD format. - PartitionDate *GoogleTypeDate `json:"partitionDate,omitempty"` +// GoogleCloudDiscoveryengineV1alphaFieldConfig: Configurations for +// fields of a schema. For example, configuring a field is indexable, or +// searchable. +type GoogleCloudDiscoveryengineV1alphaFieldConfig struct { + // CompletableOption: If completable_option is COMPLETABLE_ENABLED, + // field values are directly used and returned as suggestions for + // Autocomplete in CompletionService.CompleteQuery. If + // completable_option is unset, the server behavior defaults to + // COMPLETABLE_DISABLED for fields that support setting completable + // options, which are just `string` fields. For those fields that do not + // support setting completable options, the server will skip completable + // option setting, and setting completable_option for those fields will + // throw `INVALID_ARGUMENT` error. + // + // Possible values: + // "COMPLETABLE_OPTION_UNSPECIFIED" - Value used when unset. + // "COMPLETABLE_ENABLED" - Completable option enabled for a schema + // field. + // "COMPLETABLE_DISABLED" - Completable option disabled for a schema + // field. + CompletableOption string `json:"completableOption,omitempty"` - // ProjectId: The project ID (can be project # or ID) that the BigQuery - // source is in with a length limit of 128 characters. If not specified, - // inherits the project ID from the parent request. - ProjectId string `json:"projectId,omitempty"` + // DynamicFacetableOption: If dynamic_facetable_option is + // DYNAMIC_FACETABLE_ENABLED, field values are available for dynamic + // facet. Could only be DYNAMIC_FACETABLE_DISABLED if + // FieldConfig.indexable_option is INDEXABLE_DISABLED. Otherwise, an + // `INVALID_ARGUMENT` error will be returned. If + // dynamic_facetable_option is unset, the server behavior defaults to + // DYNAMIC_FACETABLE_DISABLED for fields that support setting dynamic + // facetable options. For those fields that do not support setting + // dynamic facetable options, such as `object` and `boolean`, the server + // will skip dynamic facetable option setting, and setting + // dynamic_facetable_option for those fields will throw + // `INVALID_ARGUMENT` error. + // + // Possible values: + // "DYNAMIC_FACETABLE_OPTION_UNSPECIFIED" - Value used when unset. + // "DYNAMIC_FACETABLE_ENABLED" - Dynamic facetable option enabled for + // a schema field. + // "DYNAMIC_FACETABLE_DISABLED" - Dynamic facetable option disabled + // for a schema field. + DynamicFacetableOption string `json:"dynamicFacetableOption,omitempty"` - // TableId: Required. The BigQuery table to copy the data from with a - // length limit of 1,024 characters. - TableId string `json:"tableId,omitempty"` + // FieldPath: Required. Field path of the schema field. For example: + // `title`, `description`, `release_info.release_year`. + FieldPath string `json:"fieldPath,omitempty"` - // ForceSendFields is a list of field names (e.g. "DataSchema") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. - ForceSendFields []string `json:"-"` + // FieldType: Output only. Raw type of the field. + // + // Possible values: + // "FIELD_TYPE_UNSPECIFIED" - Field type is unspecified. + // "OBJECT" - Field value type is Object. + // "STRING" - Field value type is String. + // "NUMBER" - Field value type is Number. + // "INTEGER" - Field value type is Integer. + // "BOOLEAN" - Field value type is Boolean. + // "GEOLOCATION" - Field value type is Geolocation. + // "DATETIME" - Field value type is Datetime. + FieldType string `json:"fieldType,omitempty"` - // NullFields is a list of field names (e.g. "DataSchema") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. - NullFields []string `json:"-"` -} + // IndexableOption: If indexable_option is INDEXABLE_ENABLED, field + // values are indexed so that it can be filtered or faceted in + // SearchService.Search. If indexable_option is unset, the server + // behavior defaults to INDEXABLE_DISABLED for fields that support + // setting indexable options. For those fields that do not support + // setting indexable options, such as `object` and `boolean` and key + // properties, the server will skip indexable_option setting, and + // setting indexable_option for those fields will throw + // `INVALID_ARGUMENT` error. + // + // Possible values: + // "INDEXABLE_OPTION_UNSPECIFIED" - Value used when unset. + // "INDEXABLE_ENABLED" - Indexable option enabled for a schema field. + // "INDEXABLE_DISABLED" - Indexable option disabled for a schema + // field. + IndexableOption string `json:"indexableOption,omitempty"` -func (s *GoogleCloudDiscoveryengineV1betaBigQuerySource) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaBigQuerySource - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) -} + // KeyPropertyType: Output only. Type of the key property that this + // field is mapped to. Empty string if this is not annotated as mapped + // to a key property. Example types are `title`, `description`. Full + // list is defined by `keyPropertyMapping` in the schema field + // annotation. If the schema field has a `KeyPropertyMapping` + // annotation, `indexable_option` and `searchable_option` of this field + // cannot be modified. + KeyPropertyType string `json:"keyPropertyType,omitempty"` -// GoogleCloudDiscoveryengineV1betaCompleteQueryResponse: Response -// message for CompletionService.CompleteQuery method. -type GoogleCloudDiscoveryengineV1betaCompleteQueryResponse struct { - // QuerySuggestions: Results of the matched query suggestions. The - // result list is ordered and the first result is a top suggestion. - QuerySuggestions []*GoogleCloudDiscoveryengineV1betaCompleteQueryResponseQuerySuggestion `json:"querySuggestions,omitempty"` + // RecsFilterableOption: If recs_filterable_option is + // FILTERABLE_ENABLED, field values are filterable by filter expression + // in RecommendationService.Recommend. If FILTERABLE_ENABLED but the + // field type is numerical, field values are not filterable by text + // queries in RecommendationService.Recommend. Only textual fields are + // supported. If recs_filterable_option is unset, the default setting is + // FILTERABLE_DISABLED for fields that support setting filterable + // options. When a field set to [FILTERABLE_DISABLED] is filtered, a + // warning is generated and an empty result is returned. + // + // Possible values: + // "FILTERABLE_OPTION_UNSPECIFIED" - Value used when unset. + // "FILTERABLE_ENABLED" - Filterable option enabled for a schema + // field. + // "FILTERABLE_DISABLED" - Filterable option disabled for a schema + // field. + RecsFilterableOption string `json:"recsFilterableOption,omitempty"` - // TailMatchTriggered: True if the returned suggestions are all tail - // suggestions. For tail matching to be triggered, - // include_tail_suggestions in the request must be true and there must - // be no suggestions that match the full query. - TailMatchTriggered bool `json:"tailMatchTriggered,omitempty"` + // RetrievableOption: If retrievable_option is RETRIEVABLE_ENABLED, + // field values are included in the search results. If + // retrievable_option is unset, the server behavior defaults to + // RETRIEVABLE_DISABLED for fields that support setting retrievable + // options. For those fields that do not support setting retrievable + // options, such as `object` and `boolean`, the server will skip + // retrievable option setting, and setting retrievable_option for those + // fields will throw `INVALID_ARGUMENT` error. + // + // Possible values: + // "RETRIEVABLE_OPTION_UNSPECIFIED" - Value used when unset. + // "RETRIEVABLE_ENABLED" - Retrievable option enabled for a schema + // field. + // "RETRIEVABLE_DISABLED" - Retrievable option disabled for a schema + // field. + RetrievableOption string `json:"retrievableOption,omitempty"` - // ServerResponse contains the HTTP response code and headers from the - // server. - googleapi.ServerResponse `json:"-"` + // SearchableOption: If searchable_option is SEARCHABLE_ENABLED, field + // values are searchable by text queries in SearchService.Search. If + // SEARCHABLE_ENABLED but field type is numerical, field values will not + // be searchable by text queries in SearchService.Search, as there are + // no text values associated to numerical fields. If searchable_option + // is unset, the server behavior defaults to SEARCHABLE_DISABLED for + // fields that support setting searchable options. Only `string` fields + // that have no key property mapping support setting searchable_option. + // For those fields that do not support setting searchable options, the + // server will skip searchable option setting, and setting + // searchable_option for those fields will throw `INVALID_ARGUMENT` + // error. + // + // Possible values: + // "SEARCHABLE_OPTION_UNSPECIFIED" - Value used when unset. + // "SEARCHABLE_ENABLED" - Searchable option enabled for a schema + // field. + // "SEARCHABLE_DISABLED" - Searchable option disabled for a schema + // field. + SearchableOption string `json:"searchableOption,omitempty"` - // ForceSendFields is a list of field names (e.g. "QuerySuggestions") to - // unconditionally include in API requests. By default, fields with + // ForceSendFields is a list of field names (e.g. "CompletableOption") + // to unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be // sent to the server regardless of whether the field is empty or not. // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "QuerySuggestions") to + // NullFields is a list of field names (e.g. "CompletableOption") to // include in API requests with the JSON null value. By default, fields // with empty values are omitted from API requests. However, any field // with an empty value appearing in NullFields will be sent to the @@ -3938,63 +3746,31 @@ type GoogleCloudDiscoveryengineV1betaCompleteQueryResponse struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1betaCompleteQueryResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaCompleteQueryResponse +func (s *GoogleCloudDiscoveryengineV1alphaFieldConfig) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaFieldConfig raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaCompleteQueryResponseQuerySuggestion: -// Suggestions as search queries. -type GoogleCloudDiscoveryengineV1betaCompleteQueryResponseQuerySuggestion struct { - // CompletableFieldPaths: The unique document field paths that serve as - // the source of this suggestion if it was generated from completable - // fields. This field is only populated for the document-completable - // model. - CompletableFieldPaths []string `json:"completableFieldPaths,omitempty"` - - // Suggestion: The suggestion for the query. - Suggestion string `json:"suggestion,omitempty"` - - // ForceSendFields is a list of field names (e.g. - // "CompletableFieldPaths") to unconditionally include in API requests. - // By default, fields with empty or default values are omitted from API - // requests. However, any non-pointer, non-interface field appearing in - // ForceSendFields will be sent to the server regardless of whether the - // field is empty or not. This may be used to include empty fields in - // Patch requests. - ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "CompletableFieldPaths") to - // include in API requests with the JSON null value. By default, fields - // with empty values are omitted from API requests. However, any field - // with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. - NullFields []string `json:"-"` -} +// GoogleCloudDiscoveryengineV1alphaImportDocumentsMetadata: Metadata +// related to the progress of the ImportDocuments operation. This is +// returned by the google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1alphaImportDocumentsMetadata struct { + // CreateTime: Operation create time. + CreateTime string `json:"createTime,omitempty"` -func (s *GoogleCloudDiscoveryengineV1betaCompleteQueryResponseQuerySuggestion) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaCompleteQueryResponseQuerySuggestion - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) -} + // FailureCount: Count of entries that encountered errors while + // processing. + FailureCount int64 `json:"failureCount,omitempty,string"` -// GoogleCloudDiscoveryengineV1betaCompletionInfo: Detailed completion -// information including completion attribution token and clicked -// completion info. -type GoogleCloudDiscoveryengineV1betaCompletionInfo struct { - // SelectedPosition: End user selected - // CompleteQueryResponse.QuerySuggestion.suggestion position, starting - // from 0. - SelectedPosition int64 `json:"selectedPosition,omitempty"` + // SuccessCount: Count of entries that were processed successfully. + SuccessCount int64 `json:"successCount,omitempty,string"` - // SelectedSuggestion: End user selected - // CompleteQueryResponse.QuerySuggestion.suggestion. - SelectedSuggestion string `json:"selectedSuggestion,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. "SelectedPosition") to + // 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. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -4002,65 +3778,7 @@ type GoogleCloudDiscoveryengineV1betaCompletionInfo struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "SelectedPosition") to - // include in API requests with the JSON null value. By default, fields - // with empty values are omitted from API requests. However, any field - // with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. - NullFields []string `json:"-"` -} - -func (s *GoogleCloudDiscoveryengineV1betaCompletionInfo) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaCompletionInfo - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) -} - -// GoogleCloudDiscoveryengineV1betaConversation: External conversation -// proto definition. -type GoogleCloudDiscoveryengineV1betaConversation struct { - // EndTime: Output only. The time the conversation finished. - EndTime string `json:"endTime,omitempty"` - - // Messages: Conversation messages. - Messages []*GoogleCloudDiscoveryengineV1betaConversationMessage `json:"messages,omitempty"` - - // Name: Immutable. Fully qualified name - // `project/*/locations/global/collections/{collection}/dataStore/*/conve - // rsations/*` or - // `project/*/locations/global/collections/{collection}/engines/*/convers - // ations/*`. - Name string `json:"name,omitempty"` - - // StartTime: Output only. The time the conversation started. - StartTime string `json:"startTime,omitempty"` - - // State: The state of the Conversation. - // - // Possible values: - // "STATE_UNSPECIFIED" - Unknown. - // "IN_PROGRESS" - Conversation is currently open. - // "COMPLETED" - Conversation has been completed. - State string `json:"state,omitempty"` - - // UserPseudoId: A unique identifier for tracking users. - UserPseudoId string `json:"userPseudoId,omitempty"` - - // ServerResponse contains the HTTP response code and headers from the - // server. - googleapi.ServerResponse `json:"-"` - - // 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. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. - ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "EndTime") to include in + // 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. However, any field with an // empty value appearing in NullFields will be sent to the server as @@ -4069,24 +3787,27 @@ type GoogleCloudDiscoveryengineV1betaConversation struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1betaConversation) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaConversation +func (s *GoogleCloudDiscoveryengineV1alphaImportDocumentsMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaImportDocumentsMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaConversationContext: Defines context -// of the conversation -type GoogleCloudDiscoveryengineV1betaConversationContext struct { - // ActiveDocument: The current active document the user opened. It - // contains the document resource reference. - ActiveDocument string `json:"activeDocument,omitempty"` +// GoogleCloudDiscoveryengineV1alphaImportDocumentsResponse: Response of +// the ImportDocumentsRequest. If the long running operation is done, +// then this message is returned by the +// google.longrunning.Operations.response field if the operation was +// successful. +type GoogleCloudDiscoveryengineV1alphaImportDocumentsResponse struct { + // ErrorConfig: Echoes the destination for the complete errors in the + // request if set. + ErrorConfig *GoogleCloudDiscoveryengineV1alphaImportErrorConfig `json:"errorConfig,omitempty"` - // ContextDocuments: The current list of documents the user is seeing. - // It contains the document resource references. - ContextDocuments []string `json:"contextDocuments,omitempty"` + // ErrorSamples: A sample of errors encountered while processing the + // request. + ErrorSamples []*GoogleRpcStatus `json:"errorSamples,omitempty"` - // ForceSendFields is a list of field names (e.g. "ActiveDocument") to + // ForceSendFields is a list of field names (e.g. "ErrorConfig") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -4094,35 +3815,31 @@ type GoogleCloudDiscoveryengineV1betaConversationContext struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "ActiveDocument") to - // include in API requests with the JSON null value. By default, fields - // with empty values are omitted from API requests. However, any field - // with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. + // NullFields is a list of field names (e.g. "ErrorConfig") to include + // in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. However, any field with + // an empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1betaConversationContext) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaConversationContext +func (s *GoogleCloudDiscoveryengineV1alphaImportDocumentsResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaImportDocumentsResponse raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaConversationMessage: Defines a -// conversation message. -type GoogleCloudDiscoveryengineV1betaConversationMessage struct { - // CreateTime: Output only. Message creation timestamp. - CreateTime string `json:"createTime,omitempty"` - - // Reply: Search reply. - Reply *GoogleCloudDiscoveryengineV1betaReply `json:"reply,omitempty"` - - // UserInput: User text input. - UserInput *GoogleCloudDiscoveryengineV1betaTextInput `json:"userInput,omitempty"` +// GoogleCloudDiscoveryengineV1alphaImportErrorConfig: Configuration of +// destination for Import related errors. +type GoogleCloudDiscoveryengineV1alphaImportErrorConfig struct { + // GcsPrefix: Cloud Storage prefix for import errors. This must be an + // empty, existing Cloud Storage directory. Import errors are written to + // sharded files in this directory, one per line, as a JSON-encoded + // `google.rpc.Status` message. + GcsPrefix string `json:"gcsPrefix,omitempty"` - // ForceSendFields is a list of field names (e.g. "CreateTime") to + // ForceSendFields is a list of field names (e.g. "GcsPrefix") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -4130,7 +3847,7 @@ type GoogleCloudDiscoveryengineV1betaConversationMessage struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "CreateTime") to include in + // NullFields is a list of field names (e.g. "GcsPrefix") to include in // API requests with the JSON null value. By default, fields with empty // values are omitted from API requests. However, any field with an // empty value appearing in NullFields will be sent to the server as @@ -4139,69 +3856,25 @@ type GoogleCloudDiscoveryengineV1betaConversationMessage struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1betaConversationMessage) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaConversationMessage +func (s *GoogleCloudDiscoveryengineV1alphaImportErrorConfig) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaImportErrorConfig raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaConverseConversationRequest: Request -// message for ConversationalSearchService.ConverseConversation method. -type GoogleCloudDiscoveryengineV1betaConverseConversationRequest struct { - // Conversation: The conversation to be used by auto session only. The - // name field will be ignored as we automatically assign new name for - // the conversation in auto session. - Conversation *GoogleCloudDiscoveryengineV1betaConversation `json:"conversation,omitempty"` - - // Filter: 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. This will be - // used to filter search results which may affect the summary response. - // 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 --> 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) - Filter string `json:"filter,omitempty"` - - // Query: Required. Current user input. - Query *GoogleCloudDiscoveryengineV1betaTextInput `json:"query,omitempty"` - - // SafeSearch: Whether to turn on safe search. - SafeSearch bool `json:"safeSearch,omitempty"` - - // ServingConfig: The resource name of the Serving Config to use. - // Format: - // `projects/{project_number}/locations/{location_id}/collections/{collec - // tion}/dataStores/{data_store_id}/servingConfigs/{serving_config_id}` - // If this is not set, the default serving config will be used. - ServingConfig string `json:"servingConfig,omitempty"` - - // SummarySpec: A specification for configuring the summary returned in - // the response. - SummarySpec *GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecSummarySpec `json:"summarySpec,omitempty"` +// GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesMetada +// ta: Metadata related to the progress of the +// ImportSuggestionDenyListEntries operation. This is returned by the +// google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesMetadata struct { + // CreateTime: Operation create time. + CreateTime string `json:"createTime,omitempty"` - // UserLabels: The user labels applied to a resource must meet the - // following requirements: * Each resource can have multiple labels, up - // to a maximum of 64. * Each label must be a key-value pair. * Keys - // have a minimum length of 1 character and a maximum length of 63 - // characters and cannot be empty. Values can be empty and have a - // maximum length of 63 characters. * Keys and values can contain only - // lowercase letters, numeric characters, underscores, and dashes. All - // characters must use UTF-8 encoding, and international characters are - // allowed. * The key portion of a label must be unique. However, you - // can use the same key with multiple resources. * Keys must start with - // a lowercase letter or international character. See Google Cloud - // Document - // (https://cloud.google.com/resource-manager/docs/creating-managing-labels#requirements) - // for more details. - UserLabels map[string]string `json:"userLabels,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. "Conversation") to + // 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. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -4209,42 +3882,38 @@ type GoogleCloudDiscoveryengineV1betaConverseConversationRequest struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Conversation") to include - // in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. However, any field with - // an empty value appearing in NullFields will be sent to the server as + // 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. However, any field with an + // empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1betaConverseConversationRequest) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaConverseConversationRequest +func (s *GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaConverseConversationResponse: -// Response message for ConversationalSearchService.ConverseConversation -// method. -type GoogleCloudDiscoveryengineV1betaConverseConversationResponse struct { - // Conversation: Updated conversation including the answer. - Conversation *GoogleCloudDiscoveryengineV1betaConversation `json:"conversation,omitempty"` - - // RelatedQuestions: Suggested related questions. - RelatedQuestions []string `json:"relatedQuestions,omitempty"` - - // Reply: Answer to the current query. - Reply *GoogleCloudDiscoveryengineV1betaReply `json:"reply,omitempty"` +// GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesRespon +// se: Response message for +// CompletionService.ImportSuggestionDenyListEntries method. +type GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesResponse struct { + // ErrorSamples: A sample of errors encountered while processing the + // request. + ErrorSamples []*GoogleRpcStatus `json:"errorSamples,omitempty"` - // SearchResults: Search Results. - SearchResults []*GoogleCloudDiscoveryengineV1betaSearchResponseSearchResult `json:"searchResults,omitempty"` + // FailedEntriesCount: Count of deny list entries that failed to be + // imported. + FailedEntriesCount int64 `json:"failedEntriesCount,omitempty,string"` - // ServerResponse contains the HTTP response code and headers from the - // server. - googleapi.ServerResponse `json:"-"` + // ImportedEntriesCount: Count of deny list entries successfully + // imported. + ImportedEntriesCount int64 `json:"importedEntriesCount,omitempty,string"` - // ForceSendFields is a list of field names (e.g. "Conversation") to + // ForceSendFields is a list of field names (e.g. "ErrorSamples") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -4252,7 +3921,7 @@ type GoogleCloudDiscoveryengineV1betaConverseConversationResponse struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Conversation") to include + // NullFields is a list of field names (e.g. "ErrorSamples") to include // in API requests with the JSON null value. By default, fields with // empty values are omitted from API requests. However, any field with // an empty value appearing in NullFields will be sent to the server as @@ -4261,18 +3930,26 @@ type GoogleCloudDiscoveryengineV1betaConverseConversationResponse struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1betaConverseConversationResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaConverseConversationResponse +func (s *GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesResponse raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaCreateSchemaMetadata: Metadata for -// Create Schema LRO. -type GoogleCloudDiscoveryengineV1betaCreateSchemaMetadata struct { +// GoogleCloudDiscoveryengineV1alphaImportUserEventsMetadata: Metadata +// related to the progress of the Import operation. This is returned by +// the google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1alphaImportUserEventsMetadata struct { // CreateTime: Operation create time. CreateTime string `json:"createTime,omitempty"` + // FailureCount: Count of entries that encountered errors while + // processing. + FailureCount int64 `json:"failureCount,omitempty,string"` + + // SuccessCount: Count of entries that were processed successfully. + SuccessCount int64 `json:"successCount,omitempty,string"` + // UpdateTime: Operation last update time. If the operation is done, // this is also the finish time. UpdateTime string `json:"updateTime,omitempty"` @@ -4294,29 +3971,35 @@ type GoogleCloudDiscoveryengineV1betaCreateSchemaMetadata struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1betaCreateSchemaMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaCreateSchemaMetadata +func (s *GoogleCloudDiscoveryengineV1alphaImportUserEventsMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaImportUserEventsMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaCustomAttribute: A custom attribute -// that is not explicitly modeled in a resource, e.g. UserEvent. -type GoogleCloudDiscoveryengineV1betaCustomAttribute struct { - // Numbers: The numerical values of this custom attribute. For example, - // `[2.3, 15.4]` when the key is "lengths_cm". Exactly one of - // CustomAttribute.text or CustomAttribute.numbers should be set. - // Otherwise, an `INVALID_ARGUMENT` error is returned. - Numbers []float64 `json:"numbers,omitempty"` +// GoogleCloudDiscoveryengineV1alphaImportUserEventsResponse: Response +// of the ImportUserEventsRequest. If the long running operation was +// successful, then this message is returned by the +// google.longrunning.Operations.response field if the operation was +// successful. +type GoogleCloudDiscoveryengineV1alphaImportUserEventsResponse struct { + // ErrorConfig: Echoes the destination for the complete errors if this + // field was set in the request. + ErrorConfig *GoogleCloudDiscoveryengineV1alphaImportErrorConfig `json:"errorConfig,omitempty"` - // Text: The textual values of this custom attribute. For example, - // `["yellow", "green"]` when the key is "color". Empty string is not - // allowed. Otherwise, an `INVALID_ARGUMENT` error is returned. Exactly - // one of CustomAttribute.text or CustomAttribute.numbers should be set. - // Otherwise, an `INVALID_ARGUMENT` error is returned. - Text []string `json:"text,omitempty"` + // ErrorSamples: A sample of errors encountered while processing the + // request. + ErrorSamples []*GoogleRpcStatus `json:"errorSamples,omitempty"` - // ForceSendFields is a list of field names (e.g. "Numbers") to + // JoinedEventsCount: Count of user events imported with complete + // existing Documents. + JoinedEventsCount int64 `json:"joinedEventsCount,omitempty,string"` + + // UnjoinedEventsCount: Count of user events imported, but with Document + // information not found in the existing Branch. + UnjoinedEventsCount int64 `json:"unjoinedEventsCount,omitempty,string"` + + // ForceSendFields is a list of field names (e.g. "ErrorConfig") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -4324,49 +4007,39 @@ type GoogleCloudDiscoveryengineV1betaCustomAttribute struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Numbers") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as + // NullFields is a list of field names (e.g. "ErrorConfig") to include + // in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. However, any field with + // an empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1betaCustomAttribute) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaCustomAttribute +func (s *GoogleCloudDiscoveryengineV1alphaImportUserEventsResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaImportUserEventsResponse raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -func (s *GoogleCloudDiscoveryengineV1betaCustomAttribute) UnmarshalJSON(data []byte) error { - type NoMethod GoogleCloudDiscoveryengineV1betaCustomAttribute - var s1 struct { - Numbers []gensupport.JSONFloat64 `json:"numbers"` - *NoMethod - } - s1.NoMethod = (*NoMethod)(s) - if err := json.Unmarshal(data, &s1); err != nil { - return err - } - s.Numbers = make([]float64, len(s1.Numbers)) - for i := range s1.Numbers { - s.Numbers[i] = float64(s1.Numbers[i]) - } - return nil -} +// GoogleCloudDiscoveryengineV1alphaOcrConfig: The OCR options for +// parsing documents. +type GoogleCloudDiscoveryengineV1alphaOcrConfig struct { + // Enabled: Required. If OCR is enabled or not. OCR must be enabled for + // other OcrConfig options to apply. We will only perform OCR on the + // first 80 pages of the PDF files. + Enabled bool `json:"enabled,omitempty"` -// GoogleCloudDiscoveryengineV1betaDeleteSchemaMetadata: Metadata for -// DeleteSchema LRO. -type GoogleCloudDiscoveryengineV1betaDeleteSchemaMetadata struct { - // CreateTime: Operation create time. - CreateTime string `json:"createTime,omitempty"` + // EnhancedDocumentElements: Apply additional enhanced OCR processing to + // a list of document elements. Supported values: * `table`: advanced + // table parsing model. + EnhancedDocumentElements []string `json:"enhancedDocumentElements,omitempty"` - // UpdateTime: Operation last update time. If the operation is done, - // this is also the finish time. - UpdateTime string `json:"updateTime,omitempty"` + // UseNativeText: If true, will use native text instead of OCR text on + // pages containing native text. + UseNativeText bool `json:"useNativeText,omitempty"` - // ForceSendFields is a list of field names (e.g. "CreateTime") to + // 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. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -4374,7 +4047,7 @@ type GoogleCloudDiscoveryengineV1betaDeleteSchemaMetadata struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "CreateTime") to include in + // 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. However, any field with an // empty value appearing in NullFields will be sent to the server as @@ -4383,60 +4056,31 @@ type GoogleCloudDiscoveryengineV1betaDeleteSchemaMetadata struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1betaDeleteSchemaMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaDeleteSchemaMetadata +func (s *GoogleCloudDiscoveryengineV1alphaOcrConfig) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaOcrConfig raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaDocument: Document captures all raw -// metadata information of items to be recommended or searched. -type GoogleCloudDiscoveryengineV1betaDocument struct { - // Content: The unstructured data linked to this document. Content must - // be set if this document is under a `CONTENT_REQUIRED` data store. - Content *GoogleCloudDiscoveryengineV1betaDocumentContent `json:"content,omitempty"` - - // DerivedStructData: Output only. This field is OUTPUT_ONLY. It - // contains derived data that are not in the original input document. - DerivedStructData googleapi.RawMessage `json:"derivedStructData,omitempty"` - - // Id: Immutable. The identifier of the document. Id should conform to - // RFC-1034 (https://tools.ietf.org/html/rfc1034) standard with a length - // limit of 63 characters. - Id string `json:"id,omitempty"` - - // JsonData: The JSON string representation of the document. It should - // conform to the registered Schema or an `INVALID_ARGUMENT` error is - // thrown. - JsonData string `json:"jsonData,omitempty"` - - // Name: Immutable. The full resource name of the document. Format: - // `projects/{project}/locations/{location}/collections/{collection}/data - // Stores/{data_store}/branches/{branch}/documents/{document_id}`. This - // field must be a UTF-8 encoded string with a length limit of 1024 - // characters. - Name string `json:"name,omitempty"` - - // ParentDocumentId: The identifier of the parent document. Currently - // supports at most two level document hierarchy. Id should conform to - // RFC-1034 (https://tools.ietf.org/html/rfc1034) standard with a length - // limit of 63 characters. - ParentDocumentId string `json:"parentDocumentId,omitempty"` +// GoogleCloudDiscoveryengineV1alphaPurgeDocumentsMetadata: Metadata +// related to the progress of the PurgeDocuments operation. This will be +// returned by the google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1alphaPurgeDocumentsMetadata struct { + // CreateTime: Operation create time. + CreateTime string `json:"createTime,omitempty"` - // SchemaId: The identifier of the schema located in the same data - // store. - SchemaId string `json:"schemaId,omitempty"` + // FailureCount: Count of entries that encountered errors while + // processing. + FailureCount int64 `json:"failureCount,omitempty,string"` - // StructData: The structured JSON data for the document. It should - // conform to the registered Schema or an `INVALID_ARGUMENT` error is - // thrown. - StructData googleapi.RawMessage `json:"structData,omitempty"` + // SuccessCount: Count of entries that were deleted successfully. + SuccessCount int64 `json:"successCount,omitempty,string"` - // ServerResponse contains the HTTP response code and headers from the - // server. - googleapi.ServerResponse `json:"-"` + // 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. "Content") to + // 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. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -4444,7 +4088,7 @@ type GoogleCloudDiscoveryengineV1betaDocument struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Content") to include in + // 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. However, any field with an // empty value appearing in NullFields will be sent to the server as @@ -4453,40 +4097,27 @@ type GoogleCloudDiscoveryengineV1betaDocument struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1betaDocument) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaDocument +func (s *GoogleCloudDiscoveryengineV1alphaPurgeDocumentsMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaPurgeDocumentsMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaDocumentContent: Unstructured data -// linked to this document. -type GoogleCloudDiscoveryengineV1betaDocumentContent struct { - // MimeType: The MIME type of the content. Supported types: * - // `application/pdf` (PDF, only native PDFs are supported for now) * - // `text/html` (HTML) * - // `application/vnd.openxmlformats-officedocument.wordprocessingml.docume - // nt` (DOCX) * - // `application/vnd.openxmlformats-officedocument.presentationml.presenta - // tion` (PPTX) * `text/plain` (TXT) See - // https://www.iana.org/assignments/media-types/media-types.xhtml. - MimeType string `json:"mimeType,omitempty"` - - // RawBytes: The content represented as a stream of bytes. The maximum - // length is 1,000,000 bytes (1 MB / ~0.95 MiB). Note: As with all - // `bytes` fields, this field is represented as pure binary in Protocol - // Buffers and base64-encoded string in JSON. For example, - // `abc123!?$*&()'-=@~` should be represented as - // `YWJjMTIzIT8kKiYoKSctPUB+` in JSON. See - // https://developers.google.com/protocol-buffers/docs/proto3#json. - RawBytes string `json:"rawBytes,omitempty"` +// GoogleCloudDiscoveryengineV1alphaPurgeDocumentsResponse: Response +// message for DocumentService.PurgeDocuments method. If the long +// running operation is successfully done, then this message is returned +// by the google.longrunning.Operations.response field. +type GoogleCloudDiscoveryengineV1alphaPurgeDocumentsResponse struct { + // PurgeCount: The total count of documents purged as a result of the + // operation. + PurgeCount int64 `json:"purgeCount,omitempty,string"` - // Uri: The URI of the content. Only Cloud Storage URIs (e.g. - // `gs://bucket-name/path/to/file`) are supported. The maximum file size - // is 2.5 MB for text-based formats, 100 MB for other formats. - Uri string `json:"uri,omitempty"` + // PurgeSample: A sample of document names that will be deleted. Only + // populated if `force` is set to false. A max of 100 names will be + // returned and the names are chosen at random. + PurgeSample []string `json:"purgeSample,omitempty"` - // ForceSendFields is a list of field names (e.g. "MimeType") to + // ForceSendFields is a list of field names (e.g. "PurgeCount") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -4494,7 +4125,7 @@ type GoogleCloudDiscoveryengineV1betaDocumentContent struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "MimeType") to include in + // NullFields is a list of field names (e.g. "PurgeCount") to include in // API requests with the JSON null value. By default, fields with empty // values are omitted from API requests. However, any field with an // empty value appearing in NullFields will be sent to the server as @@ -4503,38 +4134,25 @@ type GoogleCloudDiscoveryengineV1betaDocumentContent struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1betaDocumentContent) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaDocumentContent +func (s *GoogleCloudDiscoveryengineV1alphaPurgeDocumentsResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaPurgeDocumentsResponse raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaDocumentInfo: Detailed document -// information associated with a user event. -type GoogleCloudDiscoveryengineV1betaDocumentInfo struct { - // Id: The Document resource ID. - Id string `json:"id,omitempty"` - - // Name: The Document resource full name, of the form: - // `projects/{project_id}/locations/{location}/collections/{collection_id - // }/dataStores/{data_store_id}/branches/{branch_id}/documents/{document_ - // id}` - Name string `json:"name,omitempty"` - - // PromotionIds: The promotion IDs associated with this Document. - // Currently, this field is restricted to at most one ID. - PromotionIds []string `json:"promotionIds,omitempty"` - - // Quantity: Quantity of the Document associated with the user event. - // Defaults to 1. For example, this field will be 2 if two quantities of - // the same Document are involved in a `add-to-cart` event. Required for - // events of the following event types: * `add-to-cart` * `purchase` - Quantity int64 `json:"quantity,omitempty"` +// GoogleCloudDiscoveryengineV1alphaPurgeSuggestionDenyListEntriesMetadat +// a: Metadata related to the progress of the +// PurgeSuggestionDenyListEntries operation. This is returned by the +// google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1alphaPurgeSuggestionDenyListEntriesMetadata struct { + // CreateTime: Operation create time. + CreateTime string `json:"createTime,omitempty"` - // Uri: The Document URI - only allowed for website data stores. - Uri string `json:"uri,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. "Id") to + // 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. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -4542,8 +4160,8 @@ type GoogleCloudDiscoveryengineV1betaDocumentInfo struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Id") to include in API - // requests with the JSON null value. By default, fields with empty + // 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. However, any field with an // empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. @@ -4551,84 +4169,24 @@ type GoogleCloudDiscoveryengineV1betaDocumentInfo struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1betaDocumentInfo) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaDocumentInfo +func (s *GoogleCloudDiscoveryengineV1alphaPurgeSuggestionDenyListEntriesMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaPurgeSuggestionDenyListEntriesMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaDoubleList: Double list. -type GoogleCloudDiscoveryengineV1betaDoubleList struct { - // Values: Double values. - Values []float64 `json:"values,omitempty"` - - // ForceSendFields is a list of field names (e.g. "Values") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. - ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "Values") to include in API - // requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. - NullFields []string `json:"-"` -} - -func (s *GoogleCloudDiscoveryengineV1betaDoubleList) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaDoubleList - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) -} - -func (s *GoogleCloudDiscoveryengineV1betaDoubleList) UnmarshalJSON(data []byte) error { - type NoMethod GoogleCloudDiscoveryengineV1betaDoubleList - var s1 struct { - Values []gensupport.JSONFloat64 `json:"values"` - *NoMethod - } - s1.NoMethod = (*NoMethod)(s) - if err := json.Unmarshal(data, &s1); err != nil { - return err - } - s.Values = make([]float64, len(s1.Values)) - for i := range s1.Values { - s.Values[i] = float64(s1.Values[i]) - } - return nil -} - -// GoogleCloudDiscoveryengineV1betaGcsSource: Cloud Storage location for -// input content. -type GoogleCloudDiscoveryengineV1betaGcsSource struct { - // DataSchema: The schema to use when parsing the data from the source. - // Supported values for document imports: * `document` (default): One - // JSON Document per line. Each document must have a valid Document.id. - // * `content`: Unstructured data (e.g. PDF, HTML). Each file matched by - // `input_uris` becomes a document, with the ID set to the first 128 - // bits of SHA256(URI) encoded as a hex string. * `custom`: One custom - // data JSON per row in arbitrary format that conforms to the defined - // Schema of the data store. This can only be used by Gen App Builder. * - // `csv`: A CSV file with header conforming to the defined Schema of the - // data store. Each entry after the header is imported as a Document. - // This can only be used by Gen App Builder. Supported values for user - // even imports: * `user_event` (default): One JSON UserEvent per line. - DataSchema string `json:"dataSchema,omitempty"` +// GoogleCloudDiscoveryengineV1alphaPurgeSuggestionDenyListEntriesRespons +// e: Response message for +// CompletionService.PurgeSuggestionDenyListEntries method. +type GoogleCloudDiscoveryengineV1alphaPurgeSuggestionDenyListEntriesResponse struct { + // ErrorSamples: A sample of errors encountered while processing the + // request. + ErrorSamples []*GoogleRpcStatus `json:"errorSamples,omitempty"` - // InputUris: Required. Cloud Storage URIs to input files. URI can be up - // to 2000 characters long. URIs can match the full object path (for - // example, `gs://bucket/directory/object.json`) or a pattern matching - // one or more files, such as `gs://bucket/directory/*.json`. A request - // can contain at most 100 files (or 100,000 files if `data_schema` is - // `content`). Each file can be up to 2 GB (or 100 MB if `data_schema` - // is `content`). - InputUris []string `json:"inputUris,omitempty"` + // PurgeCount: Number of suggestion deny list entries purged. + PurgeCount int64 `json:"purgeCount,omitempty,string"` - // ForceSendFields is a list of field names (e.g. "DataSchema") to + // ForceSendFields is a list of field names (e.g. "ErrorSamples") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -4636,25 +4194,25 @@ type GoogleCloudDiscoveryengineV1betaGcsSource struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "DataSchema") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as + // NullFields is a list of field names (e.g. "ErrorSamples") to include + // in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. However, any field with + // an empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1betaGcsSource) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaGcsSource +func (s *GoogleCloudDiscoveryengineV1alphaPurgeSuggestionDenyListEntriesResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaPurgeSuggestionDenyListEntriesResponse raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaImportDocumentsMetadata: Metadata -// related to the progress of the ImportDocuments operation. This is -// returned by the google.longrunning.Operation.metadata field. -type GoogleCloudDiscoveryengineV1betaImportDocumentsMetadata struct { +// GoogleCloudDiscoveryengineV1alphaPurgeUserEventsMetadata: Metadata +// related to the progress of the PurgeUserEvents operation. This will +// be returned by the google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1alphaPurgeUserEventsMetadata struct { // CreateTime: Operation create time. CreateTime string `json:"createTime,omitempty"` @@ -4662,7 +4220,7 @@ type GoogleCloudDiscoveryengineV1betaImportDocumentsMetadata struct { // processing. FailureCount int64 `json:"failureCount,omitempty,string"` - // SuccessCount: Count of entries that were processed successfully. + // SuccessCount: Count of entries that were deleted successfully. SuccessCount int64 `json:"successCount,omitempty,string"` // UpdateTime: Operation last update time. If the operation is done, @@ -4686,72 +4244,22 @@ type GoogleCloudDiscoveryengineV1betaImportDocumentsMetadata struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1betaImportDocumentsMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaImportDocumentsMetadata +func (s *GoogleCloudDiscoveryengineV1alphaPurgeUserEventsMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaPurgeUserEventsMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaImportDocumentsRequest: Request -// message for Import methods. -type GoogleCloudDiscoveryengineV1betaImportDocumentsRequest struct { - // AutoGenerateIds: Whether to automatically generate IDs for the - // documents if absent. If set to `true`, Document.ids are automatically - // generated based on the hash of the payload, where IDs may not be - // consistent during multiple imports. In which case - // ReconciliationMode.FULL is highly recommended to avoid duplicate - // contents. If unset or set to `false`, Document.ids have to be - // specified using id_field, otherwise, documents without IDs fail to be - // imported. Only set this field when using GcsSource or BigQuerySource, - // and when GcsSource.data_schema or BigQuerySource.data_schema is - // `custom` or `csv`. Otherwise, an INVALID_ARGUMENT error is thrown. - AutoGenerateIds bool `json:"autoGenerateIds,omitempty"` - - // BigquerySource: BigQuery input source. - BigquerySource *GoogleCloudDiscoveryengineV1betaBigQuerySource `json:"bigquerySource,omitempty"` - - // ErrorConfig: The desired location of errors incurred during the - // Import. - ErrorConfig *GoogleCloudDiscoveryengineV1betaImportErrorConfig `json:"errorConfig,omitempty"` - - // GcsSource: Cloud Storage location for the input content. - GcsSource *GoogleCloudDiscoveryengineV1betaGcsSource `json:"gcsSource,omitempty"` - - // IdField: The field in the Cloud Storage and BigQuery sources that - // indicates the unique IDs of the documents. For GcsSource it is the - // key of the JSON field. For instance, `my_id` for JSON `{"my_id": - // "some_uuid"}`. For BigQuerySource it is the column name of the - // BigQuery table where the unique ids are stored. The values of the - // JSON field or the BigQuery column are used as the Document.ids. The - // JSON field or the BigQuery column must be of string type, and the - // values must be set as valid strings conform to RFC-1034 - // (https://tools.ietf.org/html/rfc1034) with 1-63 characters. - // Otherwise, documents without valid IDs fail to be imported. Only set - // this field when using GcsSource or BigQuerySource, and when - // GcsSource.data_schema or BigQuerySource.data_schema is `custom`. And - // only set this field when auto_generate_ids is unset or set as - // `false`. Otherwise, an INVALID_ARGUMENT error is thrown. If it is - // unset, a default value `_id` is used when importing from the allowed - // data sources. - IdField string `json:"idField,omitempty"` - - // InlineSource: The Inline source for the input content for documents. - InlineSource *GoogleCloudDiscoveryengineV1betaImportDocumentsRequestInlineSource `json:"inlineSource,omitempty"` - - // ReconciliationMode: The mode of reconciliation between existing - // documents and the documents to be imported. Defaults to - // ReconciliationMode.INCREMENTAL. - // - // Possible values: - // "RECONCILIATION_MODE_UNSPECIFIED" - Defaults to `INCREMENTAL`. - // "INCREMENTAL" - Inserts new documents or updates existing - // documents. - // "FULL" - Calculates diff and replaces the entire document dataset. - // Existing documents may be deleted if they are not present in the - // source location. - ReconciliationMode string `json:"reconciliationMode,omitempty"` +// GoogleCloudDiscoveryengineV1alphaPurgeUserEventsResponse: Response of +// the PurgeUserEventsRequest. If the long running operation is +// successfully done, then this message is returned by the +// google.longrunning.Operations.response field. +type GoogleCloudDiscoveryengineV1alphaPurgeUserEventsResponse struct { + // PurgeCount: The total count of events purged as a result of the + // operation. + PurgeCount int64 `json:"purgeCount,omitempty,string"` - // ForceSendFields is a list of field names (e.g. "AutoGenerateIds") to + // ForceSendFields is a list of field names (e.g. "PurgeCount") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -4759,30 +4267,53 @@ type GoogleCloudDiscoveryengineV1betaImportDocumentsRequest struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "AutoGenerateIds") to - // include in API requests with the JSON null value. By default, fields - // with empty values are omitted from API requests. However, any field - // with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. + // NullFields is a list of field names (e.g. "PurgeCount") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1betaImportDocumentsRequest) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaImportDocumentsRequest +func (s *GoogleCloudDiscoveryengineV1alphaPurgeUserEventsResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaPurgeUserEventsResponse raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaImportDocumentsRequestInlineSource: -// The inline source for the input config for ImportDocuments method. -type GoogleCloudDiscoveryengineV1betaImportDocumentsRequestInlineSource struct { - // Documents: Required. A list of documents to update/create. Each - // document must have a valid Document.id. Recommended max of 100 items. - Documents []*GoogleCloudDiscoveryengineV1betaDocument `json:"documents,omitempty"` +// GoogleCloudDiscoveryengineV1alphaRecrawlUrisMetadata: Metadata +// related to the progress of the SiteSearchEngineService.RecrawlUris +// operation. This will be returned by the +// google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1alphaRecrawlUrisMetadata struct { + // CreateTime: Operation create time. + CreateTime string `json:"createTime,omitempty"` - // ForceSendFields is a list of field names (e.g. "Documents") to + // InvalidUris: Unique URIs in the request that don't match any + // TargetSite in the DataStore, only match TargetSites that haven't been + // fully indexed, or match a TargetSite with type EXCLUDE. + InvalidUris []string `json:"invalidUris,omitempty"` + + // PendingCount: Total number of URIs that have yet to be crawled. + PendingCount int64 `json:"pendingCount,omitempty"` + + // QuotaExceededCount: Total number of URIs that were rejected due to + // insufficient indexing resources. + QuotaExceededCount int64 `json:"quotaExceededCount,omitempty"` + + // SuccessCount: Total number of URIs that have been crawled so far. + SuccessCount int64 `json:"successCount,omitempty"` + + // UpdateTime: Operation last update time. If the operation is done, + // this is also the finish time. + UpdateTime string `json:"updateTime,omitempty"` + + // ValidUrisCount: Total number of unique URIs in the request that are + // not in invalid_uris. + ValidUrisCount int64 `json:"validUrisCount,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. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -4790,7 +4321,7 @@ type GoogleCloudDiscoveryengineV1betaImportDocumentsRequestInlineSource struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Documents") to include in + // 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. However, any field with an // empty value appearing in NullFields will be sent to the server as @@ -4799,27 +4330,22 @@ type GoogleCloudDiscoveryengineV1betaImportDocumentsRequestInlineSource struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1betaImportDocumentsRequestInlineSource) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaImportDocumentsRequestInlineSource +func (s *GoogleCloudDiscoveryengineV1alphaRecrawlUrisMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaRecrawlUrisMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaImportDocumentsResponse: Response of -// the ImportDocumentsRequest. If the long running operation is done, -// then this message is returned by the -// google.longrunning.Operations.response field if the operation was -// successful. -type GoogleCloudDiscoveryengineV1betaImportDocumentsResponse struct { - // ErrorConfig: Echoes the destination for the complete errors in the - // request if set. - ErrorConfig *GoogleCloudDiscoveryengineV1betaImportErrorConfig `json:"errorConfig,omitempty"` +// GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponse: Response +// message for SiteSearchEngineService.RecrawlUris method. +type GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponse struct { + // FailedUris: URIs that were not crawled before the LRO terminated. + FailedUris []string `json:"failedUris,omitempty"` - // ErrorSamples: A sample of errors encountered while processing the - // request. - ErrorSamples []*GoogleRpcStatus `json:"errorSamples,omitempty"` + // FailureSamples: Details for a sample of up to 10 `failed_uris`. + FailureSamples []*GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfo `json:"failureSamples,omitempty"` - // ForceSendFields is a list of field names (e.g. "ErrorConfig") to + // ForceSendFields is a list of field names (e.g. "FailedUris") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -4827,31 +4353,33 @@ type GoogleCloudDiscoveryengineV1betaImportDocumentsResponse struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "ErrorConfig") to include - // in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. However, any field with - // an empty value appearing in NullFields will be sent to the server as + // NullFields is a list of field names (e.g. "FailedUris") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1betaImportDocumentsResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaImportDocumentsResponse +func (s *GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponse raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaImportErrorConfig: Configuration of -// destination for Import related errors. -type GoogleCloudDiscoveryengineV1betaImportErrorConfig struct { - // GcsPrefix: Cloud Storage prefix for import errors. This must be an - // empty, existing Cloud Storage directory. Import errors are written to - // sharded files in this directory, one per line, as a JSON-encoded - // `google.rpc.Status` message. - GcsPrefix string `json:"gcsPrefix,omitempty"` +// GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfo: +// Details about why a particular URI failed to be crawled. Each +// FailureInfo contains one FailureReason per CorpusType. +type GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfo struct { + // FailureReasons: List of failure reasons by corpus type (e.g. desktop, + // mobile). + FailureReasons []*GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfoFailureReason `json:"failureReasons,omitempty"` - // ForceSendFields is a list of field names (e.g. "GcsPrefix") to + // Uri: URI that failed to be crawled. + Uri string `json:"uri,omitempty"` + + // ForceSendFields is a list of field names (e.g. "FailureReasons") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -4859,34 +4387,41 @@ type GoogleCloudDiscoveryengineV1betaImportErrorConfig struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "GcsPrefix") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "FailureReasons") to + // include in API requests with the JSON null value. By default, fields + // with empty values are omitted from API requests. However, any field + // with an empty value appearing in NullFields will be sent to the + // server as null. It is an error if a field in this list has a + // non-empty value. This may be used to include null fields in Patch + // requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1betaImportErrorConfig) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaImportErrorConfig +func (s *GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfo) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfo raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaImportSuggestionDenyListEntriesMetadat -// a: Metadata related to the progress of the -// ImportSuggestionDenyListEntries operation. This is returned by the -// google.longrunning.Operation.metadata field. -type GoogleCloudDiscoveryengineV1betaImportSuggestionDenyListEntriesMetadata struct { - // CreateTime: Operation create time. - CreateTime string `json:"createTime,omitempty"` +// GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfoFailure +// Reason: Details about why crawling failed for a particular +// CorpusType, e.g., DESKTOP and MOBILE crawling may fail for different +// reasons. +type GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfoFailureReason struct { + // CorpusType: DESKTOP, MOBILE, or CORPUS_TYPE_UNSPECIFIED. + // + // Possible values: + // "CORPUS_TYPE_UNSPECIFIED" - Default value. + // "DESKTOP" - Denotes a crawling attempt for the desktop version of a + // page. + // "MOBILE" - Denotes a crawling attempt for the mobile version of a + // page. + CorpusType string `json:"corpusType,omitempty"` - // UpdateTime: Operation last update time. If the operation is done, - // this is also the finish time. - UpdateTime string `json:"updateTime,omitempty"` + // ErrorMessage: Reason why the URI was not crawled. + ErrorMessage string `json:"errorMessage,omitempty"` - // ForceSendFields is a list of field names (e.g. "CreateTime") to + // ForceSendFields is a list of field names (e.g. "CorpusType") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -4894,7 +4429,7 @@ type GoogleCloudDiscoveryengineV1betaImportSuggestionDenyListEntriesMetadata str // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "CreateTime") to include in + // NullFields is a list of field names (e.g. "CorpusType") to include in // API requests with the JSON null value. By default, fields with empty // values are omitted from API requests. However, any field with an // empty value appearing in NullFields will be sent to the server as @@ -4903,28 +4438,32 @@ type GoogleCloudDiscoveryengineV1betaImportSuggestionDenyListEntriesMetadata str NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1betaImportSuggestionDenyListEntriesMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaImportSuggestionDenyListEntriesMetadata +func (s *GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfoFailureReason) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfoFailureReason raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaImportSuggestionDenyListEntriesRequest -// : Request message for -// CompletionService.ImportSuggestionDenyListEntries method. -type GoogleCloudDiscoveryengineV1betaImportSuggestionDenyListEntriesRequest struct { - // GcsSource: Cloud Storage location for the input content. Only 1 file - // can be specified that contains all entries to import. Supported - // values `gcs_source.schema` for autocomplete suggestion deny list - // entry imports: * `suggestion_deny_list` (default): One JSON - // [SuggestionDenyListEntry] per line. - GcsSource *GoogleCloudDiscoveryengineV1betaGcsSource `json:"gcsSource,omitempty"` +// GoogleCloudDiscoveryengineV1alphaSchema: Defines the structure and +// layout of a type of document data. +type GoogleCloudDiscoveryengineV1alphaSchema struct { + // FieldConfigs: Output only. Configurations for fields of the schema. + FieldConfigs []*GoogleCloudDiscoveryengineV1alphaFieldConfig `json:"fieldConfigs,omitempty"` - // InlineSource: The Inline source for the input content for suggestion - // deny list entries. - InlineSource *GoogleCloudDiscoveryengineV1betaImportSuggestionDenyListEntriesRequestInlineSource `json:"inlineSource,omitempty"` + // JsonSchema: The JSON representation of the schema. + JsonSchema string `json:"jsonSchema,omitempty"` - // ForceSendFields is a list of field names (e.g. "GcsSource") to + // Name: Immutable. The full resource name of the schema, in the format + // of + // `projects/{project}/locations/{location}/collections/{collection}/data + // Stores/{data_store}/schemas/{schema}`. This field must be a UTF-8 + // encoded string with a length limit of 1024 characters. + Name string `json:"name,omitempty"` + + // StructSchema: The structured representation of the schema. + StructSchema googleapi.RawMessage `json:"structSchema,omitempty"` + + // ForceSendFields is a list of field names (e.g. "FieldConfigs") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -4932,29 +4471,126 @@ type GoogleCloudDiscoveryengineV1betaImportSuggestionDenyListEntriesRequest stru // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "GcsSource") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as + // NullFields is a list of field names (e.g. "FieldConfigs") to include + // in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. However, any field with + // an empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1betaImportSuggestionDenyListEntriesRequest) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaImportSuggestionDenyListEntriesRequest +func (s *GoogleCloudDiscoveryengineV1alphaSchema) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSchema raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaImportSuggestionDenyListEntriesRequest -// InlineSource: The inline source for SuggestionDenyListEntry. -type GoogleCloudDiscoveryengineV1betaImportSuggestionDenyListEntriesRequestInlineSource struct { - // Entries: Required. A list of all denylist entries to import. Max of - // 1000 items. - Entries []*GoogleCloudDiscoveryengineV1betaSuggestionDenyListEntry `json:"entries,omitempty"` +// GoogleCloudDiscoveryengineV1alphaSiteVerificationInfo: Verification +// information for target sites in advanced site search. +type GoogleCloudDiscoveryengineV1alphaSiteVerificationInfo struct { + // SiteVerificationState: Site verification state indicating the + // ownership and validity. + // + // Possible values: + // "SITE_VERIFICATION_STATE_UNSPECIFIED" - Defaults to VERIFIED. + // "VERIFIED" - Site ownership verified. + // "UNVERIFIED" - Site ownership pending verification or verification + // failed. + // "EXEMPTED" - Site exempt from verification, e.g., a public website + // that opens to all. + SiteVerificationState string `json:"siteVerificationState,omitempty"` - // ForceSendFields is a list of field names (e.g. "Entries") to + // VerifyTime: Latest site verification time. + VerifyTime string `json:"verifyTime,omitempty"` + + // ForceSendFields is a list of field names (e.g. + // "SiteVerificationState") to unconditionally include in API requests. + // By default, fields with empty or default values are omitted from API + // requests. However, any non-pointer, non-interface field appearing in + // ForceSendFields will be sent to the server regardless of whether the + // field is empty or not. This may be used to include empty fields in + // Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "SiteVerificationState") to + // include in API requests with the JSON null value. By default, fields + // with empty values are omitted from API requests. However, any field + // with an empty value appearing in NullFields will be sent to the + // server as null. It is an error if a field in this list has a + // non-empty value. This may be used to include null fields in Patch + // requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1alphaSiteVerificationInfo) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSiteVerificationInfo + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaTargetSite: A target site for the +// SiteSearchEngine. +type GoogleCloudDiscoveryengineV1alphaTargetSite struct { + // ExactMatch: Input only. If set to false, a uri_pattern is generated + // to include all pages whose address contains the provided_uri_pattern. + // If set to true, an uri_pattern is generated to try to be an exact + // match of the provided_uri_pattern or just the specific page if the + // provided_uri_pattern is a specific one. provided_uri_pattern is + // always normalized to generate the URI pattern to be used by the + // search engine. + ExactMatch bool `json:"exactMatch,omitempty"` + + // FailureReason: Output only. Failure reason. + FailureReason *GoogleCloudDiscoveryengineV1alphaTargetSiteFailureReason `json:"failureReason,omitempty"` + + // GeneratedUriPattern: Output only. This is system-generated based on + // the provided_uri_pattern. + GeneratedUriPattern string `json:"generatedUriPattern,omitempty"` + + // IndexingStatus: Output only. Indexing status. + // + // Possible values: + // "INDEXING_STATUS_UNSPECIFIED" - Defaults to SUCCEEDED. + // "PENDING" - The target site is in the update queue and will be + // picked up by indexing pipeline. + // "FAILED" - The target site fails to be indexed. + // "SUCCEEDED" - The target site has been indexed. + // "DELETING" - The previously indexed target site has been marked to + // be deleted. This is a transitioning state which will resulted in + // either: 1. target site deleted if unindexing is successful; 2. state + // reverts to SUCCEEDED if the unindexing fails. + IndexingStatus string `json:"indexingStatus,omitempty"` + + // Name: Output only. The fully qualified resource name of the target + // site. + // `projects/{project}/locations/{location}/collections/{collection}/data + // Stores/{data_store}/siteSearchEngine/targetSites/{target_site}` The + // `target_site_id` is system-generated. + Name string `json:"name,omitempty"` + + // ProvidedUriPattern: Required. Input only. The user provided URI + // pattern from which the `generated_uri_pattern` is generated. + ProvidedUriPattern string `json:"providedUriPattern,omitempty"` + + // SiteVerificationInfo: Output only. Site ownership and validity + // verification status. + SiteVerificationInfo *GoogleCloudDiscoveryengineV1alphaSiteVerificationInfo `json:"siteVerificationInfo,omitempty"` + + // Type: The type of the target site, e.g., whether the site is to be + // included or excluded. + // + // Possible values: + // "TYPE_UNSPECIFIED" - This value is unused. In this case, server + // behavior defaults to Type.INCLUDE. + // "INCLUDE" - Include the target site. + // "EXCLUDE" - Exclude the target site. + Type string `json:"type,omitempty"` + + // UpdateTime: Output only. The target site's last updated time. + UpdateTime string `json:"updateTime,omitempty"` + + // ForceSendFields is a list of field names (e.g. "ExactMatch") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -4962,7 +4598,7 @@ type GoogleCloudDiscoveryengineV1betaImportSuggestionDenyListEntriesRequestInlin // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Entries") to include in + // NullFields is a list of field names (e.g. "ExactMatch") to include in // API requests with the JSON null value. By default, fields with empty // values are omitted from API requests. However, any field with an // empty value appearing in NullFields will be sent to the server as @@ -4971,29 +4607,19 @@ type GoogleCloudDiscoveryengineV1betaImportSuggestionDenyListEntriesRequestInlin NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1betaImportSuggestionDenyListEntriesRequestInlineSource) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaImportSuggestionDenyListEntriesRequestInlineSource +func (s *GoogleCloudDiscoveryengineV1alphaTargetSite) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaTargetSite raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaImportSuggestionDenyListEntriesRespons -// e: Response message for -// CompletionService.ImportSuggestionDenyListEntries method. -type GoogleCloudDiscoveryengineV1betaImportSuggestionDenyListEntriesResponse struct { - // ErrorSamples: A sample of errors encountered while processing the - // request. - ErrorSamples []*GoogleRpcStatus `json:"errorSamples,omitempty"` - - // FailedEntriesCount: Count of deny list entries that failed to be - // imported. - FailedEntriesCount int64 `json:"failedEntriesCount,omitempty,string"` - - // ImportedEntriesCount: Count of deny list entries successfully - // imported. - ImportedEntriesCount int64 `json:"importedEntriesCount,omitempty,string"` +// GoogleCloudDiscoveryengineV1alphaTargetSiteFailureReason: Site search +// indexing failure reasons. +type GoogleCloudDiscoveryengineV1alphaTargetSiteFailureReason struct { + // QuotaFailure: Failed due to insufficient quota. + QuotaFailure *GoogleCloudDiscoveryengineV1alphaTargetSiteFailureReasonQuotaFailure `json:"quotaFailure,omitempty"` - // ForceSendFields is a list of field names (e.g. "ErrorSamples") to + // ForceSendFields is a list of field names (e.g. "QuotaFailure") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -5001,7 +4627,7 @@ type GoogleCloudDiscoveryengineV1betaImportSuggestionDenyListEntriesResponse str // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "ErrorSamples") to include + // NullFields is a list of field names (e.g. "QuotaFailure") to include // in API requests with the JSON null value. By default, fields with // empty values are omitted from API requests. However, any field with // an empty value appearing in NullFields will be sent to the server as @@ -5010,78 +4636,26 @@ type GoogleCloudDiscoveryengineV1betaImportSuggestionDenyListEntriesResponse str NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1betaImportSuggestionDenyListEntriesResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaImportSuggestionDenyListEntriesResponse - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) -} - -// GoogleCloudDiscoveryengineV1betaImportUserEventsMetadata: Metadata -// related to the progress of the Import operation. This is returned by -// the google.longrunning.Operation.metadata field. -type GoogleCloudDiscoveryengineV1betaImportUserEventsMetadata struct { - // CreateTime: Operation create time. - CreateTime string `json:"createTime,omitempty"` - - // FailureCount: Count of entries that encountered errors while - // processing. - FailureCount int64 `json:"failureCount,omitempty,string"` - - // SuccessCount: Count of entries that were processed successfully. - SuccessCount int64 `json:"successCount,omitempty,string"` - - // 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. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. - 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. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. - NullFields []string `json:"-"` -} - -func (s *GoogleCloudDiscoveryengineV1betaImportUserEventsMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaImportUserEventsMetadata +func (s *GoogleCloudDiscoveryengineV1alphaTargetSiteFailureReason) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaTargetSiteFailureReason raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaImportUserEventsRequest: Request -// message for the ImportUserEvents request. -type GoogleCloudDiscoveryengineV1betaImportUserEventsRequest struct { - // BigquerySource: BigQuery input source. - BigquerySource *GoogleCloudDiscoveryengineV1betaBigQuerySource `json:"bigquerySource,omitempty"` - - // ErrorConfig: The desired location of errors incurred during the - // Import. Cannot be set for inline user event imports. - ErrorConfig *GoogleCloudDiscoveryengineV1betaImportErrorConfig `json:"errorConfig,omitempty"` - - // GcsSource: Cloud Storage location for the input content. - GcsSource *GoogleCloudDiscoveryengineV1betaGcsSource `json:"gcsSource,omitempty"` - - // InlineSource: The Inline source for the input content for UserEvents. - InlineSource *GoogleCloudDiscoveryengineV1betaImportUserEventsRequestInlineSource `json:"inlineSource,omitempty"` +type GoogleCloudDiscoveryengineV1alphaTargetSiteFailureReasonQuotaFailure struct { + // TotalRequiredQuota: This number is an estimation on how much total + // quota this project needs to successfully complete indexing. + TotalRequiredQuota int64 `json:"totalRequiredQuota,omitempty,string"` - // ForceSendFields is a list of field names (e.g. "BigquerySource") to - // unconditionally include in API requests. By default, fields with + // ForceSendFields is a list of field names (e.g. "TotalRequiredQuota") + // to unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be // sent to the server regardless of whether the field is empty or not. // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "BigquerySource") to + // NullFields is a list of field names (e.g. "TotalRequiredQuota") to // include in API requests with the JSON null value. By default, fields // with empty values are omitted from API requests. However, any field // with an empty value appearing in NullFields will be sent to the @@ -5091,20 +4665,24 @@ type GoogleCloudDiscoveryengineV1betaImportUserEventsRequest struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1betaImportUserEventsRequest) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaImportUserEventsRequest +func (s *GoogleCloudDiscoveryengineV1alphaTargetSiteFailureReasonQuotaFailure) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaTargetSiteFailureReasonQuotaFailure raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaImportUserEventsRequestInlineSource: -// The inline source for the input config for ImportUserEvents method. -type GoogleCloudDiscoveryengineV1betaImportUserEventsRequestInlineSource struct { - // UserEvents: Required. A list of user events to import. Recommended - // max of 10k items. - UserEvents []*GoogleCloudDiscoveryengineV1betaUserEvent `json:"userEvents,omitempty"` +// GoogleCloudDiscoveryengineV1alphaTrainCustomModelMetadata: Metadata +// related to the progress of the TrainCustomModel operation. This is +// returned by the google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1alphaTrainCustomModelMetadata struct { + // CreateTime: Operation create time. + CreateTime string `json:"createTime,omitempty"` - // ForceSendFields is a list of field names (e.g. "UserEvents") to + // 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. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -5112,7 +4690,7 @@ type GoogleCloudDiscoveryengineV1betaImportUserEventsRequestInlineSource struct // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "UserEvents") to include in + // 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. However, any field with an // empty value appearing in NullFields will be sent to the server as @@ -5121,33 +4699,30 @@ type GoogleCloudDiscoveryengineV1betaImportUserEventsRequestInlineSource struct NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1betaImportUserEventsRequestInlineSource) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaImportUserEventsRequestInlineSource +func (s *GoogleCloudDiscoveryengineV1alphaTrainCustomModelMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaTrainCustomModelMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaImportUserEventsResponse: Response of -// the ImportUserEventsRequest. If the long running operation was -// successful, then this message is returned by the -// google.longrunning.Operations.response field if the operation was -// successful. -type GoogleCloudDiscoveryengineV1betaImportUserEventsResponse struct { - // ErrorConfig: Echoes the destination for the complete errors if this - // field was set in the request. - ErrorConfig *GoogleCloudDiscoveryengineV1betaImportErrorConfig `json:"errorConfig,omitempty"` +// GoogleCloudDiscoveryengineV1alphaTrainCustomModelResponse: Response +// of the TrainCustomModelRequest. This message is returned by the +// google.longrunning.Operations.response field. +type GoogleCloudDiscoveryengineV1alphaTrainCustomModelResponse struct { + // ErrorConfig: Echoes the destination for the complete errors in the + // request if set. + ErrorConfig *GoogleCloudDiscoveryengineV1alphaImportErrorConfig `json:"errorConfig,omitempty"` // ErrorSamples: A sample of errors encountered while processing the - // request. + // data. ErrorSamples []*GoogleRpcStatus `json:"errorSamples,omitempty"` - // JoinedEventsCount: Count of user events imported with complete - // existing Documents. - JoinedEventsCount int64 `json:"joinedEventsCount,omitempty,string"` - - // UnjoinedEventsCount: Count of user events imported, but with Document - // information not found in the existing Branch. - UnjoinedEventsCount int64 `json:"unjoinedEventsCount,omitempty,string"` + // ModelStatus: The trained model status. Possible values are: * + // **bad-data**: The training data quality is bad. * **no-improvement**: + // Tuning didn't improve performance. Won't deploy. * **in-progress**: + // Model training is in progress. * **ready**: The model is ready for + // serving. + ModelStatus string `json:"modelStatus,omitempty"` // ForceSendFields is a list of field names (e.g. "ErrorConfig") to // unconditionally include in API requests. By default, fields with @@ -5166,27 +4741,22 @@ type GoogleCloudDiscoveryengineV1betaImportUserEventsResponse struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1betaImportUserEventsResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaImportUserEventsResponse +func (s *GoogleCloudDiscoveryengineV1alphaTrainCustomModelResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaTrainCustomModelResponse raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaInterval: A floating point interval. -type GoogleCloudDiscoveryengineV1betaInterval struct { - // ExclusiveMaximum: Exclusive upper bound. - ExclusiveMaximum float64 `json:"exclusiveMaximum,omitempty"` - - // ExclusiveMinimum: Exclusive lower bound. - ExclusiveMinimum float64 `json:"exclusiveMinimum,omitempty"` - - // Maximum: Inclusive upper bound. - Maximum float64 `json:"maximum,omitempty"` - - // Minimum: Inclusive lower bound. - Minimum float64 `json:"minimum,omitempty"` +// GoogleCloudDiscoveryengineV1alphaTuneEngineMetadata: Metadata +// associated with a tune operation. +type GoogleCloudDiscoveryengineV1alphaTuneEngineMetadata struct { + // Engine: Required. The resource name of the engine that this tune + // applies to. Format: + // `projects/{project_number}/locations/{location_id}/collections/{collec + // tion_id}/engines/{engine_id}` + Engine string `json:"engine,omitempty"` - // ForceSendFields is a list of field names (e.g. "ExclusiveMaximum") to + // ForceSendFields is a list of field names (e.g. "Engine") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -5194,57 +4764,37 @@ type GoogleCloudDiscoveryengineV1betaInterval struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "ExclusiveMaximum") to - // include in API requests with the JSON null value. By default, fields - // with empty values are omitted from API requests. However, any field - // with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. + // NullFields is a list of field names (e.g. "Engine") to include in API + // requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1betaInterval) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaInterval +func (s *GoogleCloudDiscoveryengineV1alphaTuneEngineMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaTuneEngineMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -func (s *GoogleCloudDiscoveryengineV1betaInterval) UnmarshalJSON(data []byte) error { - type NoMethod GoogleCloudDiscoveryengineV1betaInterval - var s1 struct { - ExclusiveMaximum gensupport.JSONFloat64 `json:"exclusiveMaximum"` - ExclusiveMinimum gensupport.JSONFloat64 `json:"exclusiveMinimum"` - Maximum gensupport.JSONFloat64 `json:"maximum"` - Minimum gensupport.JSONFloat64 `json:"minimum"` - *NoMethod - } - s1.NoMethod = (*NoMethod)(s) - if err := json.Unmarshal(data, &s1); err != nil { - return err - } - s.ExclusiveMaximum = float64(s1.ExclusiveMaximum) - s.ExclusiveMinimum = float64(s1.ExclusiveMinimum) - s.Maximum = float64(s1.Maximum) - s.Minimum = float64(s1.Minimum) - return nil +// GoogleCloudDiscoveryengineV1alphaTuneEngineResponse: Response +// associated with a tune operation. +type GoogleCloudDiscoveryengineV1alphaTuneEngineResponse struct { } -// GoogleCloudDiscoveryengineV1betaListConversationsResponse: Response -// for ListConversations method. -type GoogleCloudDiscoveryengineV1betaListConversationsResponse struct { - // Conversations: All the Conversations for a given data store. - Conversations []*GoogleCloudDiscoveryengineV1betaConversation `json:"conversations,omitempty"` - - // NextPageToken: Pagination token, if not returned indicates the last - // page. - NextPageToken string `json:"nextPageToken,omitempty"` +// GoogleCloudDiscoveryengineV1alphaUpdateSchemaMetadata: Metadata for +// UpdateSchema LRO. +type GoogleCloudDiscoveryengineV1alphaUpdateSchemaMetadata struct { + // CreateTime: Operation create time. + CreateTime string `json:"createTime,omitempty"` - // ServerResponse contains the HTTP response code and headers from the - // server. - googleapi.ServerResponse `json:"-"` + // 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. "Conversations") to + // 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. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -5252,37 +4802,34 @@ type GoogleCloudDiscoveryengineV1betaListConversationsResponse struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Conversations") to include - // in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. However, any field with - // an empty value appearing in NullFields will be sent to the server as + // 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. However, any field with an + // empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1betaListConversationsResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaListConversationsResponse +func (s *GoogleCloudDiscoveryengineV1alphaUpdateSchemaMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaUpdateSchemaMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaListDocumentsResponse: Response -// message for DocumentService.ListDocuments method. -type GoogleCloudDiscoveryengineV1betaListDocumentsResponse struct { - // Documents: The Documents. - Documents []*GoogleCloudDiscoveryengineV1betaDocument `json:"documents,omitempty"` - - // NextPageToken: A token that can be sent as - // ListDocumentsRequest.page_token to retrieve the next page. If this - // field is omitted, there are no subsequent pages. - NextPageToken string `json:"nextPageToken,omitempty"` +// GoogleCloudDiscoveryengineV1alphaUpdateTargetSiteMetadata: Metadata +// related to the progress of the +// SiteSearchEngineService.UpdateTargetSite operation. This will be +// returned by the google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1alphaUpdateTargetSiteMetadata struct { + // CreateTime: Operation create time. + CreateTime string `json:"createTime,omitempty"` - // ServerResponse contains the HTTP response code and headers from the - // server. - googleapi.ServerResponse `json:"-"` + // 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. "Documents") to + // 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. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -5290,7 +4837,7 @@ type GoogleCloudDiscoveryengineV1betaListDocumentsResponse struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Documents") to include in + // 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. However, any field with an // empty value appearing in NullFields will be sent to the server as @@ -5299,28 +4846,25 @@ type GoogleCloudDiscoveryengineV1betaListDocumentsResponse struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1betaListDocumentsResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaListDocumentsResponse +func (s *GoogleCloudDiscoveryengineV1alphaUpdateTargetSiteMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaUpdateTargetSiteMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaListSchemasResponse: Response message -// for SchemaService.ListSchemas method. -type GoogleCloudDiscoveryengineV1betaListSchemasResponse struct { - // NextPageToken: A token that can be sent as - // ListSchemasRequest.page_token to retrieve the next page. If this - // field is omitted, there are no subsequent pages. - NextPageToken string `json:"nextPageToken,omitempty"` - - // Schemas: The Schemas. - Schemas []*GoogleCloudDiscoveryengineV1betaSchema `json:"schemas,omitempty"` +// GoogleCloudDiscoveryengineV1betaBatchCreateTargetSiteMetadata: +// Metadata related to the progress of the +// SiteSearchEngineService.BatchCreateTargetSites operation. This will +// be returned by the google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1betaBatchCreateTargetSiteMetadata struct { + // CreateTime: Operation create time. + CreateTime string `json:"createTime,omitempty"` - // ServerResponse contains the HTTP response code and headers from the - // server. - googleapi.ServerResponse `json:"-"` + // 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. "NextPageToken") to + // 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. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -5328,112 +4872,30 @@ type GoogleCloudDiscoveryengineV1betaListSchemasResponse struct { // This may be used to include empty fields in Patch requests. 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. However, any field with - // an empty value appearing in NullFields will be sent to the server as + // 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. However, any field with an + // empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1betaListSchemasResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaListSchemasResponse - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) -} - -// GoogleCloudDiscoveryengineV1betaMediaInfo: Media-specific user event -// information. -type GoogleCloudDiscoveryengineV1betaMediaInfo struct { - // MediaProgressDuration: The media progress time in seconds, if - // applicable. For example, if the end user has finished 90 seconds of a - // playback video, then MediaInfo.media_progress_duration.seconds should - // be set to 90. - MediaProgressDuration string `json:"mediaProgressDuration,omitempty"` - - // MediaProgressPercentage: Media progress should be computed using only - // the media_progress_duration relative to the media total length. This - // value must be between `[0, 1.0]` inclusive. If this is not a playback - // or the progress cannot be computed (e.g. ongoing livestream), this - // field should be unset. - MediaProgressPercentage float64 `json:"mediaProgressPercentage,omitempty"` - - // ForceSendFields is a list of field names (e.g. - // "MediaProgressDuration") to unconditionally include in API requests. - // By default, fields with empty or default values are omitted from API - // requests. However, any non-pointer, non-interface field appearing in - // ForceSendFields will be sent to the server regardless of whether the - // field is empty or not. This may be used to include empty fields in - // Patch requests. - ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "MediaProgressDuration") to - // include in API requests with the JSON null value. By default, fields - // with empty values are omitted from API requests. However, any field - // with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. - NullFields []string `json:"-"` -} - -func (s *GoogleCloudDiscoveryengineV1betaMediaInfo) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaMediaInfo +func (s *GoogleCloudDiscoveryengineV1betaBatchCreateTargetSiteMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaBatchCreateTargetSiteMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -func (s *GoogleCloudDiscoveryengineV1betaMediaInfo) UnmarshalJSON(data []byte) error { - type NoMethod GoogleCloudDiscoveryengineV1betaMediaInfo - var s1 struct { - MediaProgressPercentage gensupport.JSONFloat64 `json:"mediaProgressPercentage"` - *NoMethod - } - s1.NoMethod = (*NoMethod)(s) - if err := json.Unmarshal(data, &s1); err != nil { - return err - } - s.MediaProgressPercentage = float64(s1.MediaProgressPercentage) - return nil -} - -// GoogleCloudDiscoveryengineV1betaPageInfo: Detailed page information. -type GoogleCloudDiscoveryengineV1betaPageInfo struct { - // PageCategory: The most specific category associated with a category - // page. To represent full path of category, use '>' sign to separate - // different hierarchies. If '>' is part of the category name, please - // replace it with other character(s). Category pages include special - // pages such as sales or promotions. For instance, a special sale page - // may have the category hierarchy: "pageCategory" : "Sales > 2017 - // Black Friday Deals". Required for `view-category-page` events. Other - // event types should not set this field. Otherwise, an - // `INVALID_ARGUMENT` error is returned. - PageCategory string `json:"pageCategory,omitempty"` - - // PageviewId: 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 `pageview_id` 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. - PageviewId string `json:"pageviewId,omitempty"` - - // ReferrerUri: The referrer URL of the current page. When using the - // client side event reporting with JavaScript pixel and Google Tag - // Manager, this value is filled in automatically. However, some browser - // privacy restrictions may cause this field to be empty. - ReferrerUri string `json:"referrerUri,omitempty"` - - // Uri: Complete URL (window.location.href) of the user's current page. - // When using the client side event reporting with JavaScript pixel and - // Google Tag Manager, this value is filled in automatically. Maximum - // length 5,000 characters. - Uri string `json:"uri,omitempty"` +// GoogleCloudDiscoveryengineV1betaBatchCreateTargetSitesRequest: +// Request message for SiteSearchEngineService.BatchCreateTargetSites +// method. +type GoogleCloudDiscoveryengineV1betaBatchCreateTargetSitesRequest struct { + // Requests: Required. The request message specifying the resources to + // create. A maximum of 20 TargetSites can be created in a batch. + Requests []*GoogleCloudDiscoveryengineV1betaCreateTargetSiteRequest `json:"requests,omitempty"` - // ForceSendFields is a list of field names (e.g. "PageCategory") to + // 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. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -5441,39 +4903,29 @@ type GoogleCloudDiscoveryengineV1betaPageInfo struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "PageCategory") to include - // in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. However, any field with - // an empty value appearing in NullFields will be sent to the server as + // 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. However, any field with an + // empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1betaPageInfo) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaPageInfo +func (s *GoogleCloudDiscoveryengineV1betaBatchCreateTargetSitesRequest) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaBatchCreateTargetSitesRequest raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaPanelInfo: Detailed panel information -// associated with a user event. -type GoogleCloudDiscoveryengineV1betaPanelInfo struct { - // DisplayName: The display name of the panel. - DisplayName string `json:"displayName,omitempty"` - - // PanelId: Required. The panel ID. - PanelId string `json:"panelId,omitempty"` - - // PanelPosition: 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"` - - // TotalPanels: 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"` +// GoogleCloudDiscoveryengineV1betaBatchCreateTargetSitesResponse: +// Response message for SiteSearchEngineService.BatchCreateTargetSites +// method. +type GoogleCloudDiscoveryengineV1betaBatchCreateTargetSitesResponse struct { + // TargetSites: TargetSites created. + TargetSites []*GoogleCloudDiscoveryengineV1betaTargetSite `json:"targetSites,omitempty"` - // ForceSendFields is a list of field names (e.g. "DisplayName") to + // ForceSendFields is a list of field names (e.g. "TargetSites") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -5481,7 +4933,7 @@ type GoogleCloudDiscoveryengineV1betaPanelInfo struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "DisplayName") to include + // NullFields is a list of field names (e.g. "TargetSites") to include // in API requests with the JSON null value. By default, fields with // empty values are omitted from API requests. However, any field with // an empty value appearing in NullFields will be sent to the server as @@ -5490,31 +4942,55 @@ type GoogleCloudDiscoveryengineV1betaPanelInfo struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1betaPanelInfo) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaPanelInfo +func (s *GoogleCloudDiscoveryengineV1betaBatchCreateTargetSitesResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaBatchCreateTargetSitesResponse raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaPurgeDocumentsMetadata: Metadata -// related to the progress of the PurgeDocuments operation. This will be -// returned by the google.longrunning.Operation.metadata field. -type GoogleCloudDiscoveryengineV1betaPurgeDocumentsMetadata struct { - // CreateTime: Operation create time. - CreateTime string `json:"createTime,omitempty"` +// GoogleCloudDiscoveryengineV1betaBatchVerifyTargetSitesRequest: +// Request message for SiteSearchEngineService.BatchVerifyTargetSites +// method. +type GoogleCloudDiscoveryengineV1betaBatchVerifyTargetSitesRequest struct { +} - // FailureCount: Count of entries that encountered errors while - // processing. - FailureCount int64 `json:"failureCount,omitempty,string"` +// GoogleCloudDiscoveryengineV1betaBigQuerySource: BigQuery source +// import data from. +type GoogleCloudDiscoveryengineV1betaBigQuerySource struct { + // DataSchema: The schema to use when parsing the data from the source. + // Supported values for user event imports: * `user_event` (default): + // One UserEvent per row. Supported values for document imports: * + // `document` (default): One Document format per row. Each document must + // have a valid Document.id and one of Document.json_data or + // Document.struct_data. * `custom`: One custom data per row in + // arbitrary format that conforms to the defined Schema of the data + // store. This can only be used by Gen App Builder. + DataSchema string `json:"dataSchema,omitempty"` - // SuccessCount: Count of entries that were deleted successfully. - SuccessCount int64 `json:"successCount,omitempty,string"` + // DatasetId: Required. The BigQuery data set to copy the data from with + // a length limit of 1,024 characters. + DatasetId string `json:"datasetId,omitempty"` - // UpdateTime: Operation last update time. If the operation is done, - // this is also the finish time. - UpdateTime string `json:"updateTime,omitempty"` + // GcsStagingDir: Intermediate Cloud Storage directory used for the + // import with a length limit of 2,000 characters. Can be specified if + // one wants to have the BigQuery export to a specific Cloud Storage + // directory. + GcsStagingDir string `json:"gcsStagingDir,omitempty"` - // ForceSendFields is a list of field names (e.g. "CreateTime") to + // PartitionDate: BigQuery time partitioned table's _PARTITIONDATE in + // YYYY-MM-DD format. + PartitionDate *GoogleTypeDate `json:"partitionDate,omitempty"` + + // ProjectId: The project ID (can be project # or ID) that the BigQuery + // source is in with a length limit of 128 characters. If not specified, + // inherits the project ID from the parent request. + ProjectId string `json:"projectId,omitempty"` + + // TableId: Required. The BigQuery table to copy the data from with a + // length limit of 1,024 characters. + TableId string `json:"tableId,omitempty"` + + // ForceSendFields is a list of field names (e.g. "DataSchema") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -5522,7 +4998,7 @@ type GoogleCloudDiscoveryengineV1betaPurgeDocumentsMetadata struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "CreateTime") to include in + // NullFields is a list of field names (e.g. "DataSchema") to include in // API requests with the JSON null value. By default, fields with empty // values are omitted from API requests. However, any field with an // empty value appearing in NullFields will be sent to the server as @@ -5531,24 +5007,30 @@ type GoogleCloudDiscoveryengineV1betaPurgeDocumentsMetadata struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1betaPurgeDocumentsMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaPurgeDocumentsMetadata +func (s *GoogleCloudDiscoveryengineV1betaBigQuerySource) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaBigQuerySource raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaPurgeDocumentsRequest: Request -// message for DocumentService.PurgeDocuments method. -type GoogleCloudDiscoveryengineV1betaPurgeDocumentsRequest struct { - // Filter: Required. Filter matching documents to purge. Only currently - // supported value is `*` (all items). - Filter string `json:"filter,omitempty"` +// GoogleCloudDiscoveryengineV1betaCompleteQueryResponse: Response +// message for CompletionService.CompleteQuery method. +type GoogleCloudDiscoveryengineV1betaCompleteQueryResponse struct { + // QuerySuggestions: Results of the matched query suggestions. The + // result list is ordered and the first result is a top suggestion. + QuerySuggestions []*GoogleCloudDiscoveryengineV1betaCompleteQueryResponseQuerySuggestion `json:"querySuggestions,omitempty"` - // Force: Actually performs the purge. If `force` is set to false, - // return the expected purge count without deleting any documents. - Force bool `json:"force,omitempty"` + // TailMatchTriggered: True if the returned suggestions are all tail + // suggestions. For tail matching to be triggered, + // include_tail_suggestions in the request must be true and there must + // be no suggestions that match the full query. + TailMatchTriggered bool `json:"tailMatchTriggered,omitempty"` - // ForceSendFields is a list of field names (e.g. "Filter") to + // ServerResponse contains the HTTP response code and headers from the + // server. + googleapi.ServerResponse `json:"-"` + + // ForceSendFields is a list of field names (e.g. "QuerySuggestions") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -5556,36 +5038,73 @@ type GoogleCloudDiscoveryengineV1betaPurgeDocumentsRequest struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Filter") to include in API - // requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "QuerySuggestions") to + // include in API requests with the JSON null value. By default, fields + // with empty values are omitted from API requests. However, any field + // with an empty value appearing in NullFields will be sent to the + // server as null. It is an error if a field in this list has a + // non-empty value. This may be used to include null fields in Patch + // requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1betaPurgeDocumentsRequest) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaPurgeDocumentsRequest +func (s *GoogleCloudDiscoveryengineV1betaCompleteQueryResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaCompleteQueryResponse raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaPurgeDocumentsResponse: Response -// message for DocumentService.PurgeDocuments method. If the long -// running operation is successfully done, then this message is returned -// by the google.longrunning.Operations.response field. -type GoogleCloudDiscoveryengineV1betaPurgeDocumentsResponse struct { - // PurgeCount: The total count of documents purged as a result of the - // operation. - PurgeCount int64 `json:"purgeCount,omitempty,string"` +// GoogleCloudDiscoveryengineV1betaCompleteQueryResponseQuerySuggestion: +// Suggestions as search queries. +type GoogleCloudDiscoveryengineV1betaCompleteQueryResponseQuerySuggestion struct { + // CompletableFieldPaths: The unique document field paths that serve as + // the source of this suggestion if it was generated from completable + // fields. This field is only populated for the document-completable + // model. + CompletableFieldPaths []string `json:"completableFieldPaths,omitempty"` - // PurgeSample: A sample of document names that will be deleted. Only - // populated if `force` is set to false. A max of 100 names will be - // returned and the names are chosen at random. - PurgeSample []string `json:"purgeSample,omitempty"` + // Suggestion: The suggestion for the query. + Suggestion string `json:"suggestion,omitempty"` - // ForceSendFields is a list of field names (e.g. "PurgeCount") to + // ForceSendFields is a list of field names (e.g. + // "CompletableFieldPaths") to unconditionally include in API requests. + // By default, fields with empty or default values are omitted from API + // requests. However, any non-pointer, non-interface field appearing in + // ForceSendFields will be sent to the server regardless of whether the + // field is empty or not. This may be used to include empty fields in + // Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "CompletableFieldPaths") to + // include in API requests with the JSON null value. By default, fields + // with empty values are omitted from API requests. However, any field + // with an empty value appearing in NullFields will be sent to the + // server as null. It is an error if a field in this list has a + // non-empty value. This may be used to include null fields in Patch + // requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1betaCompleteQueryResponseQuerySuggestion) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaCompleteQueryResponseQuerySuggestion + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1betaCompletionInfo: Detailed completion +// information including completion attribution token and clicked +// completion info. +type GoogleCloudDiscoveryengineV1betaCompletionInfo struct { + // SelectedPosition: End user selected + // CompleteQueryResponse.QuerySuggestion.suggestion position, starting + // from 0. + SelectedPosition int64 `json:"selectedPosition,omitempty"` + + // SelectedSuggestion: End user selected + // CompleteQueryResponse.QuerySuggestion.suggestion. + SelectedSuggestion string `json:"selectedSuggestion,omitempty"` + + // ForceSendFields is a list of field names (e.g. "SelectedPosition") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -5593,7 +5112,65 @@ type GoogleCloudDiscoveryengineV1betaPurgeDocumentsResponse struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "PurgeCount") to include in + // NullFields is a list of field names (e.g. "SelectedPosition") to + // include in API requests with the JSON null value. By default, fields + // with empty values are omitted from API requests. However, any field + // with an empty value appearing in NullFields will be sent to the + // server as null. It is an error if a field in this list has a + // non-empty value. This may be used to include null fields in Patch + // requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1betaCompletionInfo) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaCompletionInfo + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1betaConversation: External conversation +// proto definition. +type GoogleCloudDiscoveryengineV1betaConversation struct { + // EndTime: Output only. The time the conversation finished. + EndTime string `json:"endTime,omitempty"` + + // Messages: Conversation messages. + Messages []*GoogleCloudDiscoveryengineV1betaConversationMessage `json:"messages,omitempty"` + + // Name: Immutable. Fully qualified name + // `project/*/locations/global/collections/{collection}/dataStore/*/conve + // rsations/*` or + // `project/*/locations/global/collections/{collection}/engines/*/convers + // ations/*`. + Name string `json:"name,omitempty"` + + // StartTime: Output only. The time the conversation started. + StartTime string `json:"startTime,omitempty"` + + // State: The state of the Conversation. + // + // Possible values: + // "STATE_UNSPECIFIED" - Unknown. + // "IN_PROGRESS" - Conversation is currently open. + // "COMPLETED" - Conversation has been completed. + State string `json:"state,omitempty"` + + // UserPseudoId: A unique identifier for tracking users. + UserPseudoId string `json:"userPseudoId,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the + // server. + googleapi.ServerResponse `json:"-"` + + // 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. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // 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. However, any field with an // empty value appearing in NullFields will be sent to the server as @@ -5602,23 +5179,58 @@ type GoogleCloudDiscoveryengineV1betaPurgeDocumentsResponse struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1betaPurgeDocumentsResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaPurgeDocumentsResponse +func (s *GoogleCloudDiscoveryengineV1betaConversation) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaConversation raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaPurgeSuggestionDenyListEntriesMetadata -// : Metadata related to the progress of the -// PurgeSuggestionDenyListEntries operation. This is returned by the -// google.longrunning.Operation.metadata field. -type GoogleCloudDiscoveryengineV1betaPurgeSuggestionDenyListEntriesMetadata struct { - // CreateTime: Operation create time. +// GoogleCloudDiscoveryengineV1betaConversationContext: Defines context +// of the conversation +type GoogleCloudDiscoveryengineV1betaConversationContext struct { + // ActiveDocument: The current active document the user opened. It + // contains the document resource reference. + ActiveDocument string `json:"activeDocument,omitempty"` + + // ContextDocuments: The current list of documents the user is seeing. + // It contains the document resource references. + ContextDocuments []string `json:"contextDocuments,omitempty"` + + // ForceSendFields is a list of field names (e.g. "ActiveDocument") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "ActiveDocument") to + // include in API requests with the JSON null value. By default, fields + // with empty values are omitted from API requests. However, any field + // with an empty value appearing in NullFields will be sent to the + // server as null. It is an error if a field in this list has a + // non-empty value. This may be used to include null fields in Patch + // requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1betaConversationContext) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaConversationContext + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1betaConversationMessage: Defines a +// conversation message. +type GoogleCloudDiscoveryengineV1betaConversationMessage struct { + // CreateTime: Output only. Message creation timestamp. 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"` + // Reply: Search reply. + Reply *GoogleCloudDiscoveryengineV1betaReply `json:"reply,omitempty"` + + // UserInput: User text input. + UserInput *GoogleCloudDiscoveryengineV1betaTextInput `json:"userInput,omitempty"` // ForceSendFields is a list of field names (e.g. "CreateTime") to // unconditionally include in API requests. By default, fields with @@ -5637,32 +5249,69 @@ type GoogleCloudDiscoveryengineV1betaPurgeSuggestionDenyListEntriesMetadata stru NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1betaPurgeSuggestionDenyListEntriesMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaPurgeSuggestionDenyListEntriesMetadata +func (s *GoogleCloudDiscoveryengineV1betaConversationMessage) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaConversationMessage raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaPurgeSuggestionDenyListEntriesRequest: -// -// Request message for CompletionService.PurgeSuggestionDenyListEntries -// -// method. -type GoogleCloudDiscoveryengineV1betaPurgeSuggestionDenyListEntriesRequest struct { -} +// GoogleCloudDiscoveryengineV1betaConverseConversationRequest: Request +// message for ConversationalSearchService.ConverseConversation method. +type GoogleCloudDiscoveryengineV1betaConverseConversationRequest struct { + // Conversation: The conversation to be used by auto session only. The + // name field will be ignored as we automatically assign new name for + // the conversation in auto session. + Conversation *GoogleCloudDiscoveryengineV1betaConversation `json:"conversation,omitempty"` -// GoogleCloudDiscoveryengineV1betaPurgeSuggestionDenyListEntriesResponse -// : Response message for -// CompletionService.PurgeSuggestionDenyListEntries method. -type GoogleCloudDiscoveryengineV1betaPurgeSuggestionDenyListEntriesResponse struct { - // ErrorSamples: A sample of errors encountered while processing the - // request. - ErrorSamples []*GoogleRpcStatus `json:"errorSamples,omitempty"` + // Filter: 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. This will be + // used to filter search results which may affect the summary response. + // 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 --> 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) + Filter string `json:"filter,omitempty"` - // PurgeCount: Number of suggestion deny list entries purged. - PurgeCount int64 `json:"purgeCount,omitempty,string"` + // Query: Required. Current user input. + Query *GoogleCloudDiscoveryengineV1betaTextInput `json:"query,omitempty"` - // ForceSendFields is a list of field names (e.g. "ErrorSamples") to + // SafeSearch: Whether to turn on safe search. + SafeSearch bool `json:"safeSearch,omitempty"` + + // ServingConfig: The resource name of the Serving Config to use. + // Format: + // `projects/{project_number}/locations/{location_id}/collections/{collec + // tion}/dataStores/{data_store_id}/servingConfigs/{serving_config_id}` + // If this is not set, the default serving config will be used. + ServingConfig string `json:"servingConfig,omitempty"` + + // SummarySpec: A specification for configuring the summary returned in + // the response. + SummarySpec *GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecSummarySpec `json:"summarySpec,omitempty"` + + // UserLabels: The user labels applied to a resource must meet the + // following requirements: * Each resource can have multiple labels, up + // to a maximum of 64. * Each label must be a key-value pair. * Keys + // have a minimum length of 1 character and a maximum length of 63 + // characters and cannot be empty. Values can be empty and have a + // maximum length of 63 characters. * Keys and values can contain only + // lowercase letters, numeric characters, underscores, and dashes. All + // characters must use UTF-8 encoding, and international characters are + // allowed. * The key portion of a label must be unique. However, you + // can use the same key with multiple resources. * Keys must start with + // a lowercase letter or international character. See Google Cloud + // Document + // (https://cloud.google.com/resource-manager/docs/creating-managing-labels#requirements) + // for more details. + UserLabels map[string]string `json:"userLabels,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Conversation") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -5670,7 +5319,7 @@ type GoogleCloudDiscoveryengineV1betaPurgeSuggestionDenyListEntriesResponse stru // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "ErrorSamples") to include + // NullFields is a list of field names (e.g. "Conversation") to include // in API requests with the JSON null value. By default, fields with // empty values are omitted from API requests. However, any field with // an empty value appearing in NullFields will be sent to the server as @@ -5679,95 +5328,33 @@ type GoogleCloudDiscoveryengineV1betaPurgeSuggestionDenyListEntriesResponse stru NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1betaPurgeSuggestionDenyListEntriesResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaPurgeSuggestionDenyListEntriesResponse +func (s *GoogleCloudDiscoveryengineV1betaConverseConversationRequest) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaConverseConversationRequest raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaRecommendRequest: Request message for -// Recommend method. -type GoogleCloudDiscoveryengineV1betaRecommendRequest struct { - // Filter: Filter for restricting recommendation results with a length - // limit of 5,000 characters. Currently, only filter expressions on the - // `filter_tags` attribute is supported. Examples: * `(filter_tags: - // ANY("Red", "Blue") OR filter_tags: ANY("Hot", "Cold"))` * - // `(filter_tags: ANY("Red", "Blue")) AND NOT (filter_tags: - // ANY("Green"))` If `attributeFilteringSyntax` is set to true under the - // `params` field, then attribute-based expressions are expected instead - // of the above described tag-based syntax. Examples: * (launguage: - // ANY("en", "es")) AND NOT (categories: ANY("Movie")) * (available: - // true) AND (launguage: ANY("en", "es")) OR (categories: ANY("Movie")) - // If your filter blocks all results, the API will return generic - // (unfiltered) popular Documents. If you only want results strictly - // matching the filters, set `strictFiltering` to True in - // RecommendRequest.params to receive empty results instead. Note that - // the API will never return Documents with `storageStatus` of `EXPIRED` - // or `DELETED` regardless of filter choices. - Filter string `json:"filter,omitempty"` - - // PageSize: Maximum number of results to return. Set this property to - // the number of recommendation results needed. If zero, the service - // will choose a reasonable default. The maximum allowed value is 100. - // Values above 100 will be coerced to 100. - PageSize int64 `json:"pageSize,omitempty"` +// GoogleCloudDiscoveryengineV1betaConverseConversationResponse: +// Response message for ConversationalSearchService.ConverseConversation +// method. +type GoogleCloudDiscoveryengineV1betaConverseConversationResponse struct { + // Conversation: Updated conversation including the answer. + Conversation *GoogleCloudDiscoveryengineV1betaConversation `json:"conversation,omitempty"` - // Params: Additional domain specific parameters for the - // recommendations. Allowed values: * `returnDocument`: Boolean. If set - // to true, the associated Document object will be returned in - // RecommendResponse.RecommendationResult.document. * `returnScore`: - // Boolean. If set to true, the recommendation 'score' corresponding to - // each returned Document will be set in - // RecommendResponse.RecommendationResult.metadata. The given 'score' - // indicates the probability of a Document conversion given the user's - // context and history. * `strictFiltering`: Boolean. True by default. - // If set to false, the service will return generic (unfiltered) popular - // Documents instead of empty if your filter blocks all recommendation - // results. * `diversityLevel`: String. Default empty. If set to be - // non-empty, then it needs to be one of: * `no-diversity` * - // `low-diversity` * `medium-diversity` * `high-diversity` * - // `auto-diversity` This gives request-level control and adjusts - // recommendation results based on Document category. * - // `attributeFilteringSyntax`: Boolean. False by default. If set to - // true, the `filter` field is interpreted according to the new, - // attribute-based syntax. - Params googleapi.RawMessage `json:"params,omitempty"` + // RelatedQuestions: Suggested related questions. + RelatedQuestions []string `json:"relatedQuestions,omitempty"` - // UserEvent: Required. Context about the user, what they are looking at - // and what action they took to trigger the Recommend request. Note that - // this user event detail won't be ingested to userEvent logs. Thus, a - // separate userEvent write request is required for event logging. Don't - // set UserEvent.user_pseudo_id or UserEvent.user_info.user_id to the - // same fixed ID for different users. If you are trying to receive - // non-personalized recommendations (not recommended; this can - // negatively impact model performance), instead set - // UserEvent.user_pseudo_id to a random unique ID and leave - // UserEvent.user_info.user_id unset. - UserEvent *GoogleCloudDiscoveryengineV1betaUserEvent `json:"userEvent,omitempty"` + // Reply: Answer to the current query. + Reply *GoogleCloudDiscoveryengineV1betaReply `json:"reply,omitempty"` - // UserLabels: The user labels applied to a resource must meet the - // following requirements: * Each resource can have multiple labels, up - // to a maximum of 64. * Each label must be a key-value pair. * Keys - // have a minimum length of 1 character and a maximum length of 63 - // characters and cannot be empty. Values can be empty and have a - // maximum length of 63 characters. * Keys and values can contain only - // lowercase letters, numeric characters, underscores, and dashes. All - // characters must use UTF-8 encoding, and international characters are - // allowed. * The key portion of a label must be unique. However, you - // can use the same key with multiple resources. * Keys must start with - // a lowercase letter or international character. See Requirements for - // labels - // (https://cloud.google.com/resource-manager/docs/creating-managing-labels#requirements) - // for more details. - UserLabels map[string]string `json:"userLabels,omitempty"` + // SearchResults: Search Results. + SearchResults []*GoogleCloudDiscoveryengineV1betaSearchResponseSearchResult `json:"searchResults,omitempty"` - // ValidateOnly: Use validate only mode for this recommendation query. - // If set to true, a fake model will be used that returns arbitrary - // Document IDs. Note that the validate only mode should only be used - // for testing the API, or if the model is not ready. - ValidateOnly bool `json:"validateOnly,omitempty"` + // ServerResponse contains the HTTP response code and headers from the + // server. + googleapi.ServerResponse `json:"-"` - // ForceSendFields is a list of field names (e.g. "Filter") to + // ForceSendFields is a list of field names (e.g. "Conversation") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -5775,45 +5362,34 @@ type GoogleCloudDiscoveryengineV1betaRecommendRequest struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Filter") to include in API - // requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as + // NullFields is a list of field names (e.g. "Conversation") to include + // in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. However, any field with + // an empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1betaRecommendRequest) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaRecommendRequest +func (s *GoogleCloudDiscoveryengineV1betaConverseConversationResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaConverseConversationResponse raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaRecommendResponse: Response message -// for Recommend method. -type GoogleCloudDiscoveryengineV1betaRecommendResponse struct { - // AttributionToken: A unique attribution token. This should be included - // in the UserEvent logs resulting from this recommendation, which - // enables accurate attribution of recommendation model performance. - AttributionToken string `json:"attributionToken,omitempty"` - - // MissingIds: IDs of documents in the request that were missing from - // the default Branch associated with the requested ServingConfig. - MissingIds []string `json:"missingIds,omitempty"` - - // Results: A list of recommended Documents. The order represents the - // ranking (from the most relevant Document to the least). - Results []*GoogleCloudDiscoveryengineV1betaRecommendResponseRecommendationResult `json:"results,omitempty"` - - // ValidateOnly: True if RecommendRequest.validate_only was set. - ValidateOnly bool `json:"validateOnly,omitempty"` +// GoogleCloudDiscoveryengineV1betaCreateDataStoreMetadata: Metadata +// related to the progress of the DataStoreService.CreateDataStore +// operation. This will be returned by the +// google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1betaCreateDataStoreMetadata struct { + // CreateTime: Operation create time. + CreateTime string `json:"createTime,omitempty"` - // ServerResponse contains the HTTP response code and headers from the - // server. - googleapi.ServerResponse `json:"-"` + // 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. "AttributionToken") to + // 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. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -5821,41 +5397,34 @@ type GoogleCloudDiscoveryengineV1betaRecommendResponse struct { // This may be used to include empty fields in Patch requests. 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. However, any field - // with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. + // 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. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1betaRecommendResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaRecommendResponse +func (s *GoogleCloudDiscoveryengineV1betaCreateDataStoreMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaCreateDataStoreMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaRecommendResponseRecommendationResult: -// -// RecommendationResult represents a generic recommendation result with -// -// associated metadata. -type GoogleCloudDiscoveryengineV1betaRecommendResponseRecommendationResult struct { - // Document: Set if `returnDocument` is set to true in - // RecommendRequest.params. - Document *GoogleCloudDiscoveryengineV1betaDocument `json:"document,omitempty"` - - // Id: Resource ID of the recommended Document. - Id string `json:"id,omitempty"` +// GoogleCloudDiscoveryengineV1betaCreateEngineMetadata: Metadata +// related to the progress of the EngineService.CreateEngine operation. +// This will be returned by the google.longrunning.Operation.metadata +// field. +type GoogleCloudDiscoveryengineV1betaCreateEngineMetadata struct { + // CreateTime: Operation create time. + CreateTime string `json:"createTime,omitempty"` - // Metadata: Additional Document metadata / annotations. Possible - // values: * `score`: Recommendation score in double value. Is set if - // `returnScore` is set to true in RecommendRequest.params. - Metadata googleapi.RawMessage `json:"metadata,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. "Document") to + // 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. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -5863,7 +5432,7 @@ type GoogleCloudDiscoveryengineV1betaRecommendResponseRecommendationResult struc // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Document") to include in + // 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. However, any field with an // empty value appearing in NullFields will be sent to the server as @@ -5872,25 +5441,23 @@ type GoogleCloudDiscoveryengineV1betaRecommendResponseRecommendationResult struc NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1betaRecommendResponseRecommendationResult) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaRecommendResponseRecommendationResult +func (s *GoogleCloudDiscoveryengineV1betaCreateEngineMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaCreateEngineMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaReply: Defines a reply message to -// user. -type GoogleCloudDiscoveryengineV1betaReply struct { - // References: References in the reply. - References []*GoogleCloudDiscoveryengineV1betaReplyReference `json:"references,omitempty"` - - // Reply: DEPRECATED: use `summary` instead. Text reply. - Reply string `json:"reply,omitempty"` +// GoogleCloudDiscoveryengineV1betaCreateSchemaMetadata: Metadata for +// Create Schema LRO. +type GoogleCloudDiscoveryengineV1betaCreateSchemaMetadata struct { + // CreateTime: Operation create time. + CreateTime string `json:"createTime,omitempty"` - // Summary: Summary based on search results. - Summary *GoogleCloudDiscoveryengineV1betaSearchResponseSummary `json:"summary,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. "References") to + // 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. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -5898,7 +5465,7 @@ type GoogleCloudDiscoveryengineV1betaReply struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "References") to include in + // 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. However, any field with an // empty value appearing in NullFields will be sent to the server as @@ -5907,28 +5474,25 @@ type GoogleCloudDiscoveryengineV1betaReply struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1betaReply) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaReply +func (s *GoogleCloudDiscoveryengineV1betaCreateSchemaMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaCreateSchemaMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaReplyReference: Defines reference in -// reply. -type GoogleCloudDiscoveryengineV1betaReplyReference struct { - // AnchorText: Anchor text. - AnchorText string `json:"anchorText,omitempty"` - - // End: Anchor text end index. - End int64 `json:"end,omitempty"` - - // Start: Anchor text start index. - Start int64 `json:"start,omitempty"` +// GoogleCloudDiscoveryengineV1betaCreateTargetSiteMetadata: Metadata +// related to the progress of the +// SiteSearchEngineService.CreateTargetSite operation. This will be +// returned by the google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1betaCreateTargetSiteMetadata struct { + // CreateTime: Operation create time. + CreateTime string `json:"createTime,omitempty"` - // Uri: URI link reference. - Uri string `json:"uri,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. "AnchorText") to + // 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. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -5936,7 +5500,7 @@ type GoogleCloudDiscoveryengineV1betaReplyReference struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "AnchorText") to include in + // 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. However, any field with an // empty value appearing in NullFields will be sent to the server as @@ -5945,33 +5509,24 @@ type GoogleCloudDiscoveryengineV1betaReplyReference struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1betaReplyReference) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaReplyReference +func (s *GoogleCloudDiscoveryengineV1betaCreateTargetSiteMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaCreateTargetSiteMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaSchema: Defines the structure and -// layout of a type of document data. -type GoogleCloudDiscoveryengineV1betaSchema struct { - // JsonSchema: The JSON representation of the schema. - JsonSchema string `json:"jsonSchema,omitempty"` - - // Name: Immutable. The full resource name of the schema, in the format - // of +// GoogleCloudDiscoveryengineV1betaCreateTargetSiteRequest: Request +// message for SiteSearchEngineService.CreateTargetSite method. +type GoogleCloudDiscoveryengineV1betaCreateTargetSiteRequest struct { + // Parent: Required. Parent resource name of TargetSite, such as // `projects/{project}/locations/{location}/collections/{collection}/data - // Stores/{data_store}/schemas/{schema}`. This field must be a UTF-8 - // encoded string with a length limit of 1024 characters. - Name string `json:"name,omitempty"` + // Stores/{data_store}/siteSearchEngine`. + Parent string `json:"parent,omitempty"` - // StructSchema: The structured representation of the schema. - StructSchema googleapi.RawMessage `json:"structSchema,omitempty"` - - // ServerResponse contains the HTTP response code and headers from the - // server. - googleapi.ServerResponse `json:"-"` + // TargetSite: Required. The TargetSite to create. + TargetSite *GoogleCloudDiscoveryengineV1betaTargetSite `json:"targetSite,omitempty"` - // ForceSendFields is a list of field names (e.g. "JsonSchema") to + // ForceSendFields is a list of field names (e.g. "Parent") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -5979,8 +5534,8 @@ type GoogleCloudDiscoveryengineV1betaSchema struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "JsonSchema") to include in - // API requests with the JSON null value. By default, fields with empty + // NullFields is a list of field names (e.g. "Parent") to include in API + // requests with the JSON null value. By default, fields with empty // values are omitted from API requests. However, any field with an // empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. @@ -5988,40 +5543,29 @@ type GoogleCloudDiscoveryengineV1betaSchema struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1betaSchema) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaSchema +func (s *GoogleCloudDiscoveryengineV1betaCreateTargetSiteRequest) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaCreateTargetSiteRequest raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaSearchInfo: Detailed search -// information. -type GoogleCloudDiscoveryengineV1betaSearchInfo struct { - // Offset: An integer that specifies the current offset for pagination - // (the 0-indexed starting location, amongst the products deemed by the - // API as relevant). See SearchRequest.offset for definition. If this - // field is negative, an `INVALID_ARGUMENT` is returned. This can only - // be set for `search` events. Other event types should not set this - // field. Otherwise, an `INVALID_ARGUMENT` error is returned. - Offset int64 `json:"offset,omitempty"` - - // OrderBy: The order in which products are returned, if applicable. See - // SearchRequest.order_by for definition and syntax. The value must be a - // UTF-8 encoded string with a length limit of 1,000 characters. - // Otherwise, an `INVALID_ARGUMENT` error is returned. This can only be - // set for `search` events. Other event types should not set this field. +// GoogleCloudDiscoveryengineV1betaCustomAttribute: A custom attribute +// that is not explicitly modeled in a resource, e.g. UserEvent. +type GoogleCloudDiscoveryengineV1betaCustomAttribute struct { + // Numbers: The numerical values of this custom attribute. For example, + // `[2.3, 15.4]` when the key is "lengths_cm". Exactly one of + // CustomAttribute.text or CustomAttribute.numbers should be set. // Otherwise, an `INVALID_ARGUMENT` error is returned. - OrderBy string `json:"orderBy,omitempty"` + Numbers []float64 `json:"numbers,omitempty"` - // SearchQuery: The user's search query. See SearchRequest.query for - // definition. The value must be a UTF-8 encoded string with a length - // limit of 5,000 characters. Otherwise, an `INVALID_ARGUMENT` error is - // returned. At least one of search_query or PageInfo.page_category is - // required for `search` events. Other event types should not set this - // field. Otherwise, an `INVALID_ARGUMENT` error is returned. - SearchQuery string `json:"searchQuery,omitempty"` + // Text: The textual values of this custom attribute. For example, + // `["yellow", "green"]` when the key is "color". Empty string is not + // allowed. Otherwise, an `INVALID_ARGUMENT` error is returned. Exactly + // one of CustomAttribute.text or CustomAttribute.numbers should be set. + // Otherwise, an `INVALID_ARGUMENT` error is returned. + Text []string `json:"text,omitempty"` - // ForceSendFields is a list of field names (e.g. "Offset") to + // ForceSendFields is a list of field names (e.g. "Numbers") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -6029,8 +5573,8 @@ type GoogleCloudDiscoveryengineV1betaSearchInfo struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Offset") to include in API - // requests with the JSON null value. By default, fields with empty + // NullFields is a list of field names (e.g. "Numbers") to include in + // API requests with the JSON null value. By default, fields with empty // values are omitted from API requests. However, any field with an // empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. @@ -6038,176 +5582,162 @@ type GoogleCloudDiscoveryengineV1betaSearchInfo struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1betaSearchInfo) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaSearchInfo +func (s *GoogleCloudDiscoveryengineV1betaCustomAttribute) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaCustomAttribute raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaSearchRequest: Request message for -// SearchService.Search method. -type GoogleCloudDiscoveryengineV1betaSearchRequest struct { - // BoostSpec: Boost specification to boost certain documents. For more - // information on boosting, see Boosting - // (https://cloud.google.com/retail/docs/boosting#boost) - BoostSpec *GoogleCloudDiscoveryengineV1betaSearchRequestBoostSpec `json:"boostSpec,omitempty"` +func (s *GoogleCloudDiscoveryengineV1betaCustomAttribute) UnmarshalJSON(data []byte) error { + type NoMethod GoogleCloudDiscoveryengineV1betaCustomAttribute + var s1 struct { + Numbers []gensupport.JSONFloat64 `json:"numbers"` + *NoMethod + } + s1.NoMethod = (*NoMethod)(s) + if err := json.Unmarshal(data, &s1); err != nil { + return err + } + s.Numbers = make([]float64, len(s1.Numbers)) + for i := range s1.Numbers { + s.Numbers[i] = float64(s1.Numbers[i]) + } + return nil +} - // Branch: The branch resource name, such as - // `projects/*/locations/global/collections/default_collection/dataStores - // /default_data_store/branches/0`. Use `default_branch` as the branch - // ID or leave this field empty, to search documents under the default - // branch. - Branch string `json:"branch,omitempty"` +// GoogleCloudDiscoveryengineV1betaDataStore: DataStore captures global +// settings and configs at the DataStore level. +type GoogleCloudDiscoveryengineV1betaDataStore struct { + // ContentConfig: Immutable. The content config of the data store. If + // this field is unset, the server behavior defaults to + // ContentConfig.NO_CONTENT. + // + // Possible values: + // "CONTENT_CONFIG_UNSPECIFIED" - Default value. + // "NO_CONTENT" - Only contains documents without any + // Document.content. + // "CONTENT_REQUIRED" - Only contains documents with Document.content. + // "PUBLIC_WEBSITE" - The data store is used for public website + // search. + ContentConfig string `json:"contentConfig,omitempty"` - // CanonicalFilter: The default filter that is applied when a user - // performs a search without checking any filters on the search page. - // The filter applied to every search request when quality improvement - // such as query expansion is needed. In the case a query does not have - // a sufficient amount of results this filter will be used to determine - // whether or not to enable the query expansion flow. The original - // filter will still be used for the query expanded search. This field - // is strongly recommended to achieve high search quality. For more - // information about filter syntax, see SearchRequest.filter. - CanonicalFilter string `json:"canonicalFilter,omitempty"` + // CreateTime: Output only. Timestamp the DataStore was created at. + CreateTime string `json:"createTime,omitempty"` - // ContentSearchSpec: A specification for configuring the behavior of - // content search. - ContentSearchSpec *GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpec `json:"contentSearchSpec,omitempty"` + // DefaultSchemaId: Output only. The id of the default Schema + // asscociated to this data store. + DefaultSchemaId string `json:"defaultSchemaId,omitempty"` - // EmbeddingSpec: Uses the provided embedding to do additional semantic - // document retrieval. The retrieval is based on the dot product of - // SearchRequest.EmbeddingSpec.EmbeddingVector.vector and the document - // embedding that is provided in - // SearchRequest.EmbeddingSpec.EmbeddingVector.field_path. If - // SearchRequest.EmbeddingSpec.EmbeddingVector.field_path is not - // provided, it will use ServingConfig.EmbeddingConfig.field_paths. - EmbeddingSpec *GoogleCloudDiscoveryengineV1betaSearchRequestEmbeddingSpec `json:"embeddingSpec,omitempty"` + // DisplayName: Required. The data store display name. This field must + // be a UTF-8 encoded string with a length limit of 128 characters. + // Otherwise, an INVALID_ARGUMENT error is returned. + DisplayName string `json:"displayName,omitempty"` - // FacetSpecs: Facet specifications for faceted search. If empty, no - // facets are returned. A maximum of 100 values are allowed. Otherwise, - // an `INVALID_ARGUMENT` error is returned. - FacetSpecs []*GoogleCloudDiscoveryengineV1betaSearchRequestFacetSpec `json:"facetSpecs,omitempty"` + // IndustryVertical: Immutable. The industry vertical that the data + // store registers. + // + // Possible values: + // "INDUSTRY_VERTICAL_UNSPECIFIED" - Value used when unset. + // "GENERIC" - The generic vertical for documents that are not + // specific to any industry vertical. + // "MEDIA" - The media industry vertical. + IndustryVertical string `json:"industryVertical,omitempty"` - // Filter: 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 --> 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) - Filter string `json:"filter,omitempty"` + // Name: Immutable. The full resource name of the data store. Format: + // `projects/{project}/locations/{location}/collections/{collection_id}/d + // ataStores/{data_store_id}`. This field must be a UTF-8 encoded string + // with a length limit of 1024 characters. + Name string `json:"name,omitempty"` - // ImageQuery: Raw image query. - ImageQuery *GoogleCloudDiscoveryengineV1betaSearchRequestImageQuery `json:"imageQuery,omitempty"` + // SolutionTypes: The solutions that the data store enrolls. Available + // solutions for each industry_vertical: * `MEDIA`: + // `SOLUTION_TYPE_RECOMMENDATION` and `SOLUTION_TYPE_SEARCH`. * + // `SITE_SEARCH`: `SOLUTION_TYPE_SEARCH` is automatically enrolled. + // Other solutions cannot be enrolled. + // + // Possible values: + // "SOLUTION_TYPE_UNSPECIFIED" - Default value. + // "SOLUTION_TYPE_RECOMMENDATION" - Used for Recommendations AI. + // "SOLUTION_TYPE_SEARCH" - Used for Discovery Search. + // "SOLUTION_TYPE_CHAT" - Used for use cases related to the Generative + // AI agent. + SolutionTypes []string `json:"solutionTypes,omitempty"` - // Offset: 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. - Offset int64 `json:"offset,omitempty"` + // ServerResponse contains the HTTP response code and headers from the + // server. + googleapi.ServerResponse `json:"-"` - // OrderBy: The order in which documents are returned. Documents can be - // ordered by a field in an Document object. Leave it unset if ordered - // by relevance. `order_by` expression is case-sensitive. For more - // information on ordering, see Ordering - // (https://cloud.google.com/retail/docs/filter-and-order#order) If this - // field is unrecognizable, an `INVALID_ARGUMENT` is returned. - OrderBy string `json:"orderBy,omitempty"` + // ForceSendFields is a list of field names (e.g. "ContentConfig") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` - // PageSize: Maximum number of Documents to return. If unspecified, - // defaults to a reasonable value. The maximum allowed value is 100. - // Values above 100 are coerced to 100. If this field is negative, an - // `INVALID_ARGUMENT` is returned. - PageSize int64 `json:"pageSize,omitempty"` + // NullFields is a list of field names (e.g. "ContentConfig") to include + // in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. However, any field with + // an empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} - // PageToken: A page token received from a previous SearchService.Search - // call. Provide this to retrieve the subsequent page. When paginating, - // all other parameters provided to SearchService.Search must match the - // call that provided the page token. Otherwise, an `INVALID_ARGUMENT` - // error is returned. - PageToken string `json:"pageToken,omitempty"` +func (s *GoogleCloudDiscoveryengineV1betaDataStore) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaDataStore + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} - // Params: Additional search parameters. For public website search only, - // supported values are: * `user_country_code`: string. Default empty. - // If set to non-empty, results are restricted or boosted based on the - // location provided. Example: user_country_code: "au" For available - // codes see Country Codes - // (https://developers.google.com/custom-search/docs/json_api_reference#countryCodes) - // * `search_type`: double. Default empty. Enables non-webpage searching - // depending on the value. The only valid non-default value is 1, which - // enables image searching. Example: search_type: 1 - Params googleapi.RawMessage `json:"params,omitempty"` +// GoogleCloudDiscoveryengineV1betaDeleteDataStoreMetadata: Metadata +// related to the progress of the DataStoreService.DeleteDataStore +// operation. This will be returned by the +// google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1betaDeleteDataStoreMetadata struct { + // CreateTime: Operation create time. + CreateTime string `json:"createTime,omitempty"` - // Query: Raw search query. - Query string `json:"query,omitempty"` + // UpdateTime: Operation last update time. If the operation is done, + // this is also the finish time. + UpdateTime string `json:"updateTime,omitempty"` - // QueryExpansionSpec: The query expansion specification that specifies - // the conditions under which query expansion occurs. - QueryExpansionSpec *GoogleCloudDiscoveryengineV1betaSearchRequestQueryExpansionSpec `json:"queryExpansionSpec,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. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` - // RankingExpression: The ranking expression controls the customized - // ranking on retrieval documents. This overrides - // ServingConfig.ranking_expression. The ranking expression is a single - // function or multiple functions that are joint by "+". * - // ranking_expression = function, { " + ", function }; Supported - // functions: * double * relevance_score * double * - // dotProduct(embedding_field_path) Function variables: - // `relevance_score`: pre-defined keywords, used for measure relevance - // between query and document. `embedding_field_path`: the document - // embedding field used with query embedding vector. `dotProduct`: - // embedding function between embedding_field_path and query embedding - // vector. Example ranking expression: If document has an embedding - // field doc_embedding, the ranking expression could be `0.5 * - // relevance_score + 0.3 * dotProduct(doc_embedding)`. - RankingExpression string `json:"rankingExpression,omitempty"` - - // SafeSearch: Whether to turn on safe search. This is only supported - // for website search. - SafeSearch bool `json:"safeSearch,omitempty"` - - // SpellCorrectionSpec: The spell correction specification that - // specifies the mode under which spell correction takes effect. - SpellCorrectionSpec *GoogleCloudDiscoveryengineV1betaSearchRequestSpellCorrectionSpec `json:"spellCorrectionSpec,omitempty"` + // 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. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} - // UserInfo: Information about the end user. Highly recommended for - // analytics. UserInfo.user_agent is used to deduce `device_type` for - // analytics. - UserInfo *GoogleCloudDiscoveryengineV1betaUserInfo `json:"userInfo,omitempty"` +func (s *GoogleCloudDiscoveryengineV1betaDeleteDataStoreMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaDeleteDataStoreMetadata + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} - // UserLabels: The user labels applied to a resource must meet the - // following requirements: * Each resource can have multiple labels, up - // to a maximum of 64. * Each label must be a key-value pair. * Keys - // have a minimum length of 1 character and a maximum length of 63 - // characters and cannot be empty. Values can be empty and have a - // maximum length of 63 characters. * Keys and values can contain only - // lowercase letters, numeric characters, underscores, and dashes. All - // characters must use UTF-8 encoding, and international characters are - // allowed. * The key portion of a label must be unique. However, you - // can use the same key with multiple resources. * Keys must start with - // a lowercase letter or international character. See Google Cloud - // Document - // (https://cloud.google.com/resource-manager/docs/creating-managing-labels#requirements) - // for more details. - UserLabels map[string]string `json:"userLabels,omitempty"` +// GoogleCloudDiscoveryengineV1betaDeleteEngineMetadata: Metadata +// related to the progress of the EngineService.DeleteEngine operation. +// This will be returned by the google.longrunning.Operation.metadata +// field. +type GoogleCloudDiscoveryengineV1betaDeleteEngineMetadata struct { + // CreateTime: Operation create time. + CreateTime string `json:"createTime,omitempty"` - // UserPseudoId: A unique identifier for tracking visitors. For example, - // this could be implemented with an HTTP cookie, which should be able - // to uniquely identify a visitor on a single device. This unique - // identifier should not change if the visitor logs in or out of the - // website. This field should NOT have a fixed value such as - // `unknown_visitor`. This should be the same identifier as - // UserEvent.user_pseudo_id and CompleteQueryRequest.user_pseudo_id The - // field must be a UTF-8 encoded string with a length limit of 128 - // characters. Otherwise, an `INVALID_ARGUMENT` error is returned. - UserPseudoId string `json:"userPseudoId,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. "BoostSpec") to + // 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. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -6215,7 +5745,7 @@ type GoogleCloudDiscoveryengineV1betaSearchRequest struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "BoostSpec") to include in + // 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. However, any field with an // empty value appearing in NullFields will be sent to the server as @@ -6224,72 +5754,58 @@ type GoogleCloudDiscoveryengineV1betaSearchRequest struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1betaSearchRequest) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaSearchRequest +func (s *GoogleCloudDiscoveryengineV1betaDeleteEngineMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaDeleteEngineMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaSearchRequestBoostSpec: Boost -// specification to boost certain documents. -type GoogleCloudDiscoveryengineV1betaSearchRequestBoostSpec struct { - // ConditionBoostSpecs: Condition boost specifications. If a document - // matches multiple conditions in the specifictions, boost scores from - // these specifications are all applied and combined in a non-linear - // way. Maximum number of specifications is 20. - ConditionBoostSpecs []*GoogleCloudDiscoveryengineV1betaSearchRequestBoostSpecConditionBoostSpec `json:"conditionBoostSpecs,omitempty"` +// GoogleCloudDiscoveryengineV1betaDeleteSchemaMetadata: Metadata for +// DeleteSchema LRO. +type GoogleCloudDiscoveryengineV1betaDeleteSchemaMetadata struct { + // CreateTime: Operation create time. + CreateTime string `json:"createTime,omitempty"` - // ForceSendFields is a list of field names (e.g. "ConditionBoostSpecs") - // to unconditionally include in API requests. By default, fields with + // 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. However, any // non-pointer, non-interface field appearing in ForceSendFields will be // sent to the server regardless of whether the field is empty or not. // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "ConditionBoostSpecs") to - // include in API requests with the JSON null value. By default, fields - // with empty values are omitted from API requests. However, any field - // with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. + // 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. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1betaSearchRequestBoostSpec) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaSearchRequestBoostSpec +func (s *GoogleCloudDiscoveryengineV1betaDeleteSchemaMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaDeleteSchemaMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaSearchRequestBoostSpecConditionBoostSp -// ec: Boost applies to documents which match a condition. -type GoogleCloudDiscoveryengineV1betaSearchRequestBoostSpecConditionBoostSpec struct { - // Boost: Strength of the condition boost, which should be in [-1, 1]. - // Negative boost means demotion. Default is 0.0. Setting to 1.0 gives - // the document a big promotion. However, it does not necessarily mean - // that the boosted document will be the top result at all times, nor - // that other documents will be excluded. Results could still be shown - // even when none of them matches the condition. And results that are - // significantly more relevant to the search query can still trump your - // heavily favored but irrelevant documents. Setting to -1.0 gives the - // document a big demotion. However, results that are deeply relevant - // might still be shown. The document will have an upstream battle to - // get a fairly high ranking, but it is not blocked out completely. - // Setting to 0.0 means no boost applied. The boosting condition is - // ignored. - Boost float64 `json:"boost,omitempty"` +// GoogleCloudDiscoveryengineV1betaDeleteTargetSiteMetadata: Metadata +// related to the progress of the +// SiteSearchEngineService.DeleteTargetSite operation. This will be +// returned by the google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1betaDeleteTargetSiteMetadata struct { + // CreateTime: Operation create time. + CreateTime string `json:"createTime,omitempty"` - // Condition: An expression which specifies a boost condition. The - // syntax and supported fields are the same as a filter expression. See - // SearchRequest.filter for detail syntax and limitations. Examples: * - // To boost documents with document ID "doc_1" or "doc_2", and color - // "Red" or "Blue": * (id: ANY("doc_1", "doc_2")) AND (color: - // ANY("Red","Blue")) - Condition string `json:"condition,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. "Boost") to + // 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. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -6297,8 +5813,8 @@ type GoogleCloudDiscoveryengineV1betaSearchRequestBoostSpecConditionBoostSpec st // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Boost") to include in API - // requests with the JSON null value. By default, fields with empty + // 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. However, any field with an // empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. @@ -6306,145 +5822,107 @@ type GoogleCloudDiscoveryengineV1betaSearchRequestBoostSpecConditionBoostSpec st NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1betaSearchRequestBoostSpecConditionBoostSpec) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaSearchRequestBoostSpecConditionBoostSpec +func (s *GoogleCloudDiscoveryengineV1betaDeleteTargetSiteMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaDeleteTargetSiteMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -func (s *GoogleCloudDiscoveryengineV1betaSearchRequestBoostSpecConditionBoostSpec) UnmarshalJSON(data []byte) error { - type NoMethod GoogleCloudDiscoveryengineV1betaSearchRequestBoostSpecConditionBoostSpec - var s1 struct { - Boost gensupport.JSONFloat64 `json:"boost"` - *NoMethod - } - s1.NoMethod = (*NoMethod)(s) - if err := json.Unmarshal(data, &s1); err != nil { - return err - } - s.Boost = float64(s1.Boost) - return nil -} - -// GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpec: A -// specification for configuring the behavior of content search. -type GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpec struct { - // ExtractiveContentSpec: If there is no extractive_content_spec - // provided, there will be no extractive answer in the search response. - ExtractiveContentSpec *GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecExtractiveContentSpec `json:"extractiveContentSpec,omitempty"` - - // SnippetSpec: If `snippetSpec` is not specified, snippets are not - // included in the search response. - SnippetSpec *GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecSnippetSpec `json:"snippetSpec,omitempty"` +// GoogleCloudDiscoveryengineV1betaDisableAdvancedSiteSearchMetadata: +// Metadata related to the progress of the +// SiteSearchEngineService.DisableAdvancedSiteSearch operation. This +// will be returned by the google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1betaDisableAdvancedSiteSearchMetadata struct { + // CreateTime: Operation create time. + CreateTime string `json:"createTime,omitempty"` - // SummarySpec: If `summarySpec` is not specified, summaries are not - // included in the search response. - SummarySpec *GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecSummarySpec `json:"summarySpec,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. - // "ExtractiveContentSpec") to unconditionally include in API requests. - // By default, fields with empty or default values are omitted from API - // requests. However, any non-pointer, non-interface field appearing in - // ForceSendFields will be sent to the server regardless of whether the - // field is empty or not. This may be used to include empty fields in - // Patch requests. + // 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. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "ExtractiveContentSpec") to - // include in API requests with the JSON null value. By default, fields - // with empty values are omitted from API requests. However, any field - // with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. + // 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. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpec) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpec +func (s *GoogleCloudDiscoveryengineV1betaDisableAdvancedSiteSearchMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaDisableAdvancedSiteSearchMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecExtracti -// veContentSpec: A specification for configuring the extractive content -// in a search response. -type GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecExtractiveContentSpec struct { - // MaxExtractiveAnswerCount: The maximum number of extractive answers - // returned in each search result. An extractive answer is a verbatim - // answer extracted from the original document, which provides a precise - // and contextually relevant answer to the search query. If the number - // of matching answers is less than the `max_extractive_answer_count`, - // return all of the answers. Otherwise, return the - // `max_extractive_answer_count`. At most five answers are returned for - // each SearchResult. - MaxExtractiveAnswerCount int64 `json:"maxExtractiveAnswerCount,omitempty"` +// GoogleCloudDiscoveryengineV1betaDisableAdvancedSiteSearchRequest: +// Request message for SiteSearchEngineService.DisableAdvancedSiteSearch +// method. +type GoogleCloudDiscoveryengineV1betaDisableAdvancedSiteSearchRequest struct { +} - // MaxExtractiveSegmentCount: The max number of extractive segments - // returned in each search result. Only applied if the DataStore is set - // to DataStore.ContentConfig.CONTENT_REQUIRED or - // DataStore.solution_types is SOLUTION_TYPE_CHAT. An extractive segment - // is a text segment extracted from the original document that is - // relevant to the search query, and, in general, more verbose than an - // extractive answer. The segment could then be used as input for LLMs - // to generate summaries and answers. If the number of matching segments - // is less than `max_extractive_segment_count`, return all of the - // segments. Otherwise, return the `max_extractive_segment_count`. - MaxExtractiveSegmentCount int64 `json:"maxExtractiveSegmentCount,omitempty"` +// GoogleCloudDiscoveryengineV1betaDisableAdvancedSiteSearchResponse: +// Response message for +// SiteSearchEngineService.DisableAdvancedSiteSearch method. +type GoogleCloudDiscoveryengineV1betaDisableAdvancedSiteSearchResponse struct { +} - // NumNextSegments: Return at most `num_next_segments` segments after - // each selected segments. - NumNextSegments int64 `json:"numNextSegments,omitempty"` +// GoogleCloudDiscoveryengineV1betaDocument: Document captures all raw +// metadata information of items to be recommended or searched. +type GoogleCloudDiscoveryengineV1betaDocument struct { + // Content: The unstructured data linked to this document. Content must + // be set if this document is under a `CONTENT_REQUIRED` data store. + Content *GoogleCloudDiscoveryengineV1betaDocumentContent `json:"content,omitempty"` - // NumPreviousSegments: Specifies whether to also include the adjacent - // from each selected segments. Return at most `num_previous_segments` - // segments before each selected segments. - NumPreviousSegments int64 `json:"numPreviousSegments,omitempty"` + // DerivedStructData: Output only. This field is OUTPUT_ONLY. It + // contains derived data that are not in the original input document. + DerivedStructData googleapi.RawMessage `json:"derivedStructData,omitempty"` - // ForceSendFields is a list of field names (e.g. - // "MaxExtractiveAnswerCount") to unconditionally include in API - // requests. By default, fields with empty or default values are omitted - // from API requests. However, any non-pointer, non-interface field - // appearing in ForceSendFields will be sent to the server regardless of - // whether the field is empty or not. This may be used to include empty - // fields in Patch requests. - ForceSendFields []string `json:"-"` + // Id: Immutable. The identifier of the document. Id should conform to + // RFC-1034 (https://tools.ietf.org/html/rfc1034) standard with a length + // limit of 63 characters. + Id string `json:"id,omitempty"` - // NullFields is a list of field names (e.g. "MaxExtractiveAnswerCount") - // to include in API requests with the JSON null value. By default, - // fields with empty values are omitted from API requests. However, any - // field with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. - NullFields []string `json:"-"` -} + // JsonData: The JSON string representation of the document. It should + // conform to the registered Schema or an `INVALID_ARGUMENT` error is + // thrown. + JsonData string `json:"jsonData,omitempty"` -func (s *GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecExtractiveContentSpec) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecExtractiveContentSpec - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) -} + // Name: Immutable. The full resource name of the document. Format: + // `projects/{project}/locations/{location}/collections/{collection}/data + // Stores/{data_store}/branches/{branch}/documents/{document_id}`. This + // field must be a UTF-8 encoded string with a length limit of 1024 + // characters. + Name string `json:"name,omitempty"` -// GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecSnippetS -// pec: A specification for configuring snippets in a search response. -type GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecSnippetSpec struct { - // MaxSnippetCount: [DEPRECATED] This field is deprecated. To control - // snippet return, use `return_snippet` field. For backwards - // compatibility, we will return snippet if max_snippet_count > 0. - MaxSnippetCount int64 `json:"maxSnippetCount,omitempty"` + // ParentDocumentId: The identifier of the parent document. Currently + // supports at most two level document hierarchy. Id should conform to + // RFC-1034 (https://tools.ietf.org/html/rfc1034) standard with a length + // limit of 63 characters. + ParentDocumentId string `json:"parentDocumentId,omitempty"` - // ReferenceOnly: [DEPRECATED] This field is deprecated and will have no - // affect on the snippet. - ReferenceOnly bool `json:"referenceOnly,omitempty"` + // SchemaId: The identifier of the schema located in the same data + // store. + SchemaId string `json:"schemaId,omitempty"` - // ReturnSnippet: If `true`, then return snippet. If no snippet can be - // generated, we return "No snippet is available for this page." A - // `snippet_status` with `SUCCESS` or `NO_SNIPPET_AVAILABLE` will also - // be returned. - ReturnSnippet bool `json:"returnSnippet,omitempty"` + // StructData: The structured JSON data for the document. It should + // conform to the registered Schema or an `INVALID_ARGUMENT` error is + // thrown. + StructData googleapi.RawMessage `json:"structData,omitempty"` - // ForceSendFields is a list of field names (e.g. "MaxSnippetCount") to + // ServerResponse contains the HTTP response code and headers from the + // server. + googleapi.ServerResponse `json:"-"` + + // ForceSendFields is a list of field names (e.g. "Content") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -6452,115 +5930,97 @@ type GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecSnippetSpec s // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "MaxSnippetCount") to - // include in API requests with the JSON null value. By default, fields - // with empty values are omitted from API requests. However, any field - // with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. + // NullFields is a list of field names (e.g. "Content") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecSnippetSpec) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecSnippetSpec +func (s *GoogleCloudDiscoveryengineV1betaDocument) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaDocument raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecSummaryS -// pec: A specification for configuring a summary returned in a search -// response. -type GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecSummarySpec struct { - // IgnoreAdversarialQuery: Specifies whether to filter out adversarial - // queries. The default value is `false`. Google employs search-query - // classification to detect adversarial queries. No summary is returned - // if the search query is classified as an adversarial query. For - // example, a user might ask a question regarding negative comments - // about the company or submit a query designed to generate unsafe, - // policy-violating output. If this field is set to `true`, we skip - // generating summaries for adversarial queries and return fallback - // messages instead. - IgnoreAdversarialQuery bool `json:"ignoreAdversarialQuery,omitempty"` - - // IgnoreNonSummarySeekingQuery: Specifies whether to filter out queries - // that are not summary-seeking. The default value is `false`. Google - // employs search-query classification to detect summary-seeking - // queries. No summary is returned if the search query is classified as - // a non-summary seeking query. For example, `why is the sky blue` and - // `Who is the best soccer player in the world?` are summary-seeking - // queries, but `SFO airport` and `world cup 2026` are not. They are - // most likely navigational queries. If this field is set to `true`, we - // skip generating summaries for non-summary seeking queries and return - // fallback messages instead. - IgnoreNonSummarySeekingQuery bool `json:"ignoreNonSummarySeekingQuery,omitempty"` - - // IncludeCitations: Specifies whether to include citations in the - // summary. The default value is `false`. When this field is set to - // `true`, summaries include in-line citation numbers. Example summary - // including citations: BigQuery is Google Cloud's fully managed and - // completely serverless enterprise data warehouse [1]. BigQuery - // supports all data types, works across clouds, and has built-in - // machine learning and business intelligence, all within a unified - // platform [2, 3]. The citation numbers refer to the returned search - // results and are 1-indexed. For example, [1] means that the sentence - // is attributed to the first search result. [2, 3] means that the - // sentence is attributed to both the second and third search results. - IncludeCitations bool `json:"includeCitations,omitempty"` - - // LanguageCode: Language code for Summary. Use language tags defined by - // BCP47 (https://www.rfc-editor.org/rfc/bcp/bcp47.txt). Note: This is - // an experimental feature. - LanguageCode string `json:"languageCode,omitempty"` - - // ModelPromptSpec: If specified, the spec will be used to modify the - // prompt provided to the LLM. - ModelPromptSpec *GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecSummarySpecModelPromptSpec `json:"modelPromptSpec,omitempty"` +// GoogleCloudDiscoveryengineV1betaDocumentContent: Unstructured data +// linked to this document. +type GoogleCloudDiscoveryengineV1betaDocumentContent struct { + // MimeType: The MIME type of the content. Supported types: * + // `application/pdf` (PDF, only native PDFs are supported for now) * + // `text/html` (HTML) * + // `application/vnd.openxmlformats-officedocument.wordprocessingml.docume + // nt` (DOCX) * + // `application/vnd.openxmlformats-officedocument.presentationml.presenta + // tion` (PPTX) * `text/plain` (TXT) See + // https://www.iana.org/assignments/media-types/media-types.xhtml. + MimeType string `json:"mimeType,omitempty"` - // ModelSpec: If specified, the spec will be used to modify the model - // specification provided to the LLM. - ModelSpec *GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecSummarySpecModelSpec `json:"modelSpec,omitempty"` + // RawBytes: The content represented as a stream of bytes. The maximum + // length is 1,000,000 bytes (1 MB / ~0.95 MiB). Note: As with all + // `bytes` fields, this field is represented as pure binary in Protocol + // Buffers and base64-encoded string in JSON. For example, + // `abc123!?$*&()'-=@~` should be represented as + // `YWJjMTIzIT8kKiYoKSctPUB+` in JSON. See + // https://developers.google.com/protocol-buffers/docs/proto3#json. + RawBytes string `json:"rawBytes,omitempty"` - // SummaryResultCount: The number of top results to generate the summary - // from. If the number of results returned is less than - // `summaryResultCount`, the summary is generated from all of the - // results. At most five results can be used to generate a summary. - SummaryResultCount int64 `json:"summaryResultCount,omitempty"` + // Uri: The URI of the content. Only Cloud Storage URIs (e.g. + // `gs://bucket-name/path/to/file`) are supported. The maximum file size + // is 2.5 MB for text-based formats, 100 MB for other formats. + Uri string `json:"uri,omitempty"` - // ForceSendFields is a list of field names (e.g. - // "IgnoreAdversarialQuery") to unconditionally include in API requests. - // By default, fields with empty or default values are omitted from API - // requests. However, any non-pointer, non-interface field appearing in - // ForceSendFields will be sent to the server regardless of whether the - // field is empty or not. This may be used to include empty fields in - // Patch requests. + // ForceSendFields is a list of field names (e.g. "MimeType") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "IgnoreAdversarialQuery") - // to include in API requests with the JSON null value. By default, - // fields with empty values are omitted from API requests. However, any - // field with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. + // NullFields is a list of field names (e.g. "MimeType") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecSummarySpec) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecSummarySpec +func (s *GoogleCloudDiscoveryengineV1betaDocumentContent) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaDocumentContent raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecSummaryS -// pecModelPromptSpec: Specification of the prompt to use with the -// model. -type GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecSummarySpecModelPromptSpec struct { - // Preamble: Text at the beginning of the prompt that instructs the - // assistant. Examples are available in the user guide. - Preamble string `json:"preamble,omitempty"` +// GoogleCloudDiscoveryengineV1betaDocumentInfo: Detailed document +// information associated with a user event. +type GoogleCloudDiscoveryengineV1betaDocumentInfo struct { + // Id: The Document resource ID. + Id string `json:"id,omitempty"` - // ForceSendFields is a list of field names (e.g. "Preamble") to + // Name: The Document resource full name, of the form: + // `projects/{project_id}/locations/{location}/collections/{collection_id + // }/dataStores/{data_store_id}/branches/{branch_id}/documents/{document_ + // id}` + Name string `json:"name,omitempty"` + + // PromotionIds: The promotion IDs associated with this Document. + // Currently, this field is restricted to at most one ID. + PromotionIds []string `json:"promotionIds,omitempty"` + + // Quantity: Quantity of the Document associated with the user event. + // Defaults to 1. For example, this field will be 2 if two quantities of + // the same Document are involved in a `add-to-cart` event. Required for + // events of the following event types: * `add-to-cart` * `purchase` + Quantity int64 `json:"quantity,omitempty"` + + // Uri: The Document URI - only allowed for website data stores. + Uri string `json:"uri,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. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -6568,8 +6028,8 @@ type GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecSummarySpecMo // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Preamble") to include in - // API requests with the JSON null value. By default, fields with empty + // NullFields is a list of field names (e.g. "Id") to include in API + // requests with the JSON null value. By default, fields with empty // values are omitted from API requests. However, any field with an // empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. @@ -6577,24 +6037,18 @@ type GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecSummarySpecMo NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecSummarySpecModelPromptSpec) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecSummarySpecModelPromptSpec +func (s *GoogleCloudDiscoveryengineV1betaDocumentInfo) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaDocumentInfo raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecSummaryS -// pecModelSpec: Specification of the model. -type GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecSummarySpecModelSpec struct { - // Version: The model version used to generate the summary. Supported - // values are: * `stable`: string. Default value when no value is - // specified. Uses a generally available, fine-tuned version of the - // text-bison@001 model. * `preview`: string. (Public preview) Uses a - // fine-tuned version of the text-bison@002 model. This model works only - // for summaries in English. - Version string `json:"version,omitempty"` +// GoogleCloudDiscoveryengineV1betaDoubleList: Double list. +type GoogleCloudDiscoveryengineV1betaDoubleList struct { + // Values: Double values. + Values []float64 `json:"values,omitempty"` - // ForceSendFields is a list of field names (e.g. "Version") to + // ForceSendFields is a list of field names (e.g. "Values") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -6602,8 +6056,8 @@ type GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecSummarySpecMo // This may be used to include empty fields in Patch requests. 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 + // NullFields is a list of field names (e.g. "Values") to include in API + // requests with the JSON null value. By default, fields with empty // values are omitted from API requests. However, any field with an // empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. @@ -6611,21 +6065,42 @@ type GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecSummarySpecMo NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecSummarySpecModelSpec) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecSummarySpecModelSpec +func (s *GoogleCloudDiscoveryengineV1betaDoubleList) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaDoubleList raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaSearchRequestEmbeddingSpec: The -// specification that uses customized query embedding vector to do -// semantic document retrieval. -type GoogleCloudDiscoveryengineV1betaSearchRequestEmbeddingSpec struct { - // EmbeddingVectors: The embedding vector used for retrieval. Limit to - // 1. - EmbeddingVectors []*GoogleCloudDiscoveryengineV1betaSearchRequestEmbeddingSpecEmbeddingVector `json:"embeddingVectors,omitempty"` +func (s *GoogleCloudDiscoveryengineV1betaDoubleList) UnmarshalJSON(data []byte) error { + type NoMethod GoogleCloudDiscoveryengineV1betaDoubleList + var s1 struct { + Values []gensupport.JSONFloat64 `json:"values"` + *NoMethod + } + s1.NoMethod = (*NoMethod)(s) + if err := json.Unmarshal(data, &s1); err != nil { + return err + } + s.Values = make([]float64, len(s1.Values)) + for i := range s1.Values { + s.Values[i] = float64(s1.Values[i]) + } + return nil +} - // ForceSendFields is a list of field names (e.g. "EmbeddingVectors") to +// GoogleCloudDiscoveryengineV1betaEnableAdvancedSiteSearchMetadata: +// Metadata related to the progress of the +// SiteSearchEngineService.EnableAdvancedSiteSearch operation. This will +// be returned by the google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1betaEnableAdvancedSiteSearchMetadata 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. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -6633,32 +6108,109 @@ type GoogleCloudDiscoveryengineV1betaSearchRequestEmbeddingSpec struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "EmbeddingVectors") to - // include in API requests with the JSON null value. By default, fields - // with empty values are omitted from API requests. However, any field - // with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. + // 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. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1betaSearchRequestEmbeddingSpec) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaSearchRequestEmbeddingSpec +func (s *GoogleCloudDiscoveryengineV1betaEnableAdvancedSiteSearchMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaEnableAdvancedSiteSearchMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaSearchRequestEmbeddingSpecEmbeddingVec -// tor: Embedding vector. -type GoogleCloudDiscoveryengineV1betaSearchRequestEmbeddingSpecEmbeddingVector struct { - // FieldPath: Embedding field path in schema. - FieldPath string `json:"fieldPath,omitempty"` +// GoogleCloudDiscoveryengineV1betaEnableAdvancedSiteSearchRequest: +// Request message for SiteSearchEngineService.EnableAdvancedSiteSearch +// method. +type GoogleCloudDiscoveryengineV1betaEnableAdvancedSiteSearchRequest struct { +} - // Vector: Query embedding vector. - Vector []float64 `json:"vector,omitempty"` +// GoogleCloudDiscoveryengineV1betaEnableAdvancedSiteSearchResponse: +// Response message for SiteSearchEngineService.EnableAdvancedSiteSearch +// method. +type GoogleCloudDiscoveryengineV1betaEnableAdvancedSiteSearchResponse struct { +} - // ForceSendFields is a list of field names (e.g. "FieldPath") to +// GoogleCloudDiscoveryengineV1betaEngine: Metadata that describes the +// training and serving parameters of an Engine. +type GoogleCloudDiscoveryengineV1betaEngine struct { + // ChatEngineConfig: Configurations for the Chat Engine. Only applicable + // if solution_type is SOLUTION_TYPE_CHAT. + ChatEngineConfig *GoogleCloudDiscoveryengineV1betaEngineChatEngineConfig `json:"chatEngineConfig,omitempty"` + + // ChatEngineMetadata: Output only. Additional information of the Chat + // Engine. Only applicable if solution_type is SOLUTION_TYPE_CHAT. + ChatEngineMetadata *GoogleCloudDiscoveryengineV1betaEngineChatEngineMetadata `json:"chatEngineMetadata,omitempty"` + + // CommonConfig: Common config spec that specifies the metadata of the + // engine. + CommonConfig *GoogleCloudDiscoveryengineV1betaEngineCommonConfig `json:"commonConfig,omitempty"` + + // CreateTime: Output only. Timestamp the Recommendation Engine was + // created at. + CreateTime string `json:"createTime,omitempty"` + + // DataStoreIds: The data stores associated with this engine. For + // SOLUTION_TYPE_SEARCH and SOLUTION_TYPE_RECOMMENDATION type of + // engines, they can only associate with at most one data store. If + // solution_type is SOLUTION_TYPE_CHAT, multiple DataStores in the same + // Collection can be associated here. Note that when used in + // CreateEngineRequest, one DataStore id must be provided as the system + // will use it for necessary initializations. + DataStoreIds []string `json:"dataStoreIds,omitempty"` + + // DisplayName: Required. The display name of the engine. Should be + // human readable. UTF-8 encoded string with limit of 1024 characters. + DisplayName string `json:"displayName,omitempty"` + + // IndustryVertical: The industry vertical that the engine registers. + // The restriction of the Engine industry vertical is based on + // DataStore: If unspecified, default to `GENERIC`. Vertical on Engine + // has to match vertical of the DataStore liniked to the engine. + // + // Possible values: + // "INDUSTRY_VERTICAL_UNSPECIFIED" - Value used when unset. + // "GENERIC" - The generic vertical for documents that are not + // specific to any industry vertical. + // "MEDIA" - The media industry vertical. + IndustryVertical string `json:"industryVertical,omitempty"` + + // Name: Immutable. The fully qualified resource name of the engine. + // This field must be a UTF-8 encoded string with a length limit of 1024 + // characters. Format: + // `projects/{project_number}/locations/{location}/collections/{collectio + // n}/engines/{engine}` engine should be 1-63 characters, and valid + // characters are /a-z0-9*/. Otherwise, an INVALID_ARGUMENT error is + // returned. + Name string `json:"name,omitempty"` + + // SearchEngineConfig: Configurations for the Search Engine. Only + // applicable if solution_type is SOLUTION_TYPE_SEARCH. + SearchEngineConfig *GoogleCloudDiscoveryengineV1betaEngineSearchEngineConfig `json:"searchEngineConfig,omitempty"` + + // SolutionType: Required. The solutions of the engine. + // + // Possible values: + // "SOLUTION_TYPE_UNSPECIFIED" - Default value. + // "SOLUTION_TYPE_RECOMMENDATION" - Used for Recommendations AI. + // "SOLUTION_TYPE_SEARCH" - Used for Discovery Search. + // "SOLUTION_TYPE_CHAT" - Used for use cases related to the Generative + // AI agent. + SolutionType string `json:"solutionType,omitempty"` + + // UpdateTime: Output only. Timestamp the Recommendation Engine was last + // updated. + UpdateTime string `json:"updateTime,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the + // server. + googleapi.ServerResponse `json:"-"` + + // ForceSendFields is a list of field names (e.g. "ChatEngineConfig") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -6666,102 +6218,53 @@ type GoogleCloudDiscoveryengineV1betaSearchRequestEmbeddingSpecEmbeddingVector s // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "FieldPath") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "ChatEngineConfig") to + // include in API requests with the JSON null value. By default, fields + // with empty values are omitted from API requests. However, any field + // with an empty value appearing in NullFields will be sent to the + // server as null. It is an error if a field in this list has a + // non-empty value. This may be used to include null fields in Patch + // requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1betaSearchRequestEmbeddingSpecEmbeddingVector) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaSearchRequestEmbeddingSpecEmbeddingVector +func (s *GoogleCloudDiscoveryengineV1betaEngine) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaEngine raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -func (s *GoogleCloudDiscoveryengineV1betaSearchRequestEmbeddingSpecEmbeddingVector) UnmarshalJSON(data []byte) error { - type NoMethod GoogleCloudDiscoveryengineV1betaSearchRequestEmbeddingSpecEmbeddingVector - var s1 struct { - Vector []gensupport.JSONFloat64 `json:"vector"` - *NoMethod - } - s1.NoMethod = (*NoMethod)(s) - if err := json.Unmarshal(data, &s1); err != nil { - return err - } - s.Vector = make([]float64, len(s1.Vector)) - for i := range s1.Vector { - s.Vector[i] = float64(s1.Vector[i]) - } - return nil -} - -// GoogleCloudDiscoveryengineV1betaSearchRequestFacetSpec: A facet -// specification to perform faceted search. -type GoogleCloudDiscoveryengineV1betaSearchRequestFacetSpec struct { - // EnableDynamicPosition: Enables dynamic position for this facet. If - // set to true, the position of this facet among all facets in the - // response is determined automatically. If dynamic facets are enabled, - // it is ordered together. If set to false, the position of this facet - // in the response is the same as in the request, and it is ranked - // before the facets with dynamic position enable and all dynamic - // facets. For example, you may always want to have rating facet - // returned in the response, but it's not necessarily to always display - // the rating facet at the top. In that case, you can set - // enable_dynamic_position to true so that the position of rating facet - // in response is determined automatically. Another example, assuming - // you have the following facets in the request: * "rating", - // enable_dynamic_position = true * "price", enable_dynamic_position = - // false * "brands", enable_dynamic_position = false And also you have a - // dynamic facets enabled, which generates a facet `gender`. Then the - // final order of the facets in the response can be ("price", "brands", - // "rating", "gender") or ("price", "brands", "gender", "rating") - // depends on how API orders "gender" and "rating" facets. However, - // notice that "price" and "brands" are always ranked at first and - // second position because their enable_dynamic_position is false. - EnableDynamicPosition bool `json:"enableDynamicPosition,omitempty"` - - // ExcludedFilterKeys: List of keys to exclude when faceting. By - // default, FacetKey.key is not excluded from the filter unless it is - // listed in this field. Listing a facet key in this field allows its - // values to appear as facet results, even when they are filtered out of - // search results. Using this field does not affect what search results - // are returned. For example, suppose there are 100 documents with the - // color facet "Red" and 200 documents with the color facet "Blue". A - // query containing the filter "color:ANY("Red")" and having "color" as - // FacetKey.key would by default return only "Red" documents in the - // search results, and also return "Red" with count 100 as the only - // color facet. Although there are also blue documents available, "Blue" - // would not be shown as an available facet value. If "color" is listed - // in "excludedFilterKeys", then the query returns the facet values - // "Red" with count 100 and "Blue" with count 200, because the "color" - // key is now excluded from the filter. Because this field doesn't - // affect search results, the search results are still correctly - // filtered to return only "Red" documents. A maximum of 100 values are - // allowed. Otherwise, an `INVALID_ARGUMENT` error is returned. - ExcludedFilterKeys []string `json:"excludedFilterKeys,omitempty"` - - // FacetKey: Required. The facet key specification. - FacetKey *GoogleCloudDiscoveryengineV1betaSearchRequestFacetSpecFacetKey `json:"facetKey,omitempty"` +// GoogleCloudDiscoveryengineV1betaEngineChatEngineConfig: +// Configurations for a Chat Engine. +type GoogleCloudDiscoveryengineV1betaEngineChatEngineConfig struct { + // AgentCreationConfig: The configurationt generate the Dialogflow agent + // that is associated to this Engine. Note that these configurations are + // one-time consumed by and passed to Dialogflow service. It means they + // cannot be retrieved using EngineService.GetEngine or + // EngineService.ListEngines API after engine creation. + AgentCreationConfig *GoogleCloudDiscoveryengineV1betaEngineChatEngineConfigAgentCreationConfig `json:"agentCreationConfig,omitempty"` - // Limit: Maximum of facet values that should be returned for this - // facet. If unspecified, defaults to 20. The maximum allowed value is - // 300. Values above 300 are coerced to 300. If this field is negative, - // an `INVALID_ARGUMENT` is returned. - Limit int64 `json:"limit,omitempty"` + // DialogflowAgentToLink: The resource name of an exist Dialogflow agent + // to link to this Chat Engine. Customers can either provide + // `agent_creation_config` to create agent or provide an agent name that + // links the agent with the Chat engine. Format: + // `projects//locations//agents/`. Note that the + // `dialogflow_agent_to_link` are one-time consumed by and passed to + // Dialogflow service. It means they cannot be retrieved using + // EngineService.GetEngine or EngineService.ListEngines API after engine + // creation. Please use ChatEngineMetadata.dialogflow_agent for actual + // agent association after Engine is created. + DialogflowAgentToLink string `json:"dialogflowAgentToLink,omitempty"` - // ForceSendFields is a list of field names (e.g. - // "EnableDynamicPosition") to unconditionally include in API requests. - // By default, fields with empty or default values are omitted from API - // requests. However, any non-pointer, non-interface field appearing in - // ForceSendFields will be sent to the server regardless of whether the - // field is empty or not. This may be used to include empty fields in - // Patch requests. + // ForceSendFields is a list of field names (e.g. "AgentCreationConfig") + // to unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "EnableDynamicPosition") to + // NullFields is a list of field names (e.g. "AgentCreationConfig") to // include in API requests with the JSON null value. By default, fields // with empty values are omitted from API requests. However, any field // with an empty value appearing in NullFields will be sent to the @@ -6771,62 +6274,42 @@ type GoogleCloudDiscoveryengineV1betaSearchRequestFacetSpec struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1betaSearchRequestFacetSpec) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaSearchRequestFacetSpec +func (s *GoogleCloudDiscoveryengineV1betaEngineChatEngineConfig) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaEngineChatEngineConfig raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaSearchRequestFacetSpecFacetKey: -// Specifies how a facet is computed. -type GoogleCloudDiscoveryengineV1betaSearchRequestFacetSpecFacetKey struct { - // CaseInsensitive: True to make facet keys case insensitive when - // getting faceting values with prefixes or contains; false otherwise. - CaseInsensitive bool `json:"caseInsensitive,omitempty"` - - // Contains: Only get facet values that contains the given strings. For - // example, suppose "category" has three values "Action > 2022", "Action - // > 2021" and "Sci-Fi > 2022". If set "contains" to "2022", the - // "category" facet only contains "Action > 2022" and "Sci-Fi > 2022". - // Only supported on textual fields. Maximum is 10. - Contains []string `json:"contains,omitempty"` - - // Intervals: Set only if values should be bucketed into intervals. Must - // be set for facets with numerical values. Must not be set for facet - // with text values. Maximum number of intervals is 30. - Intervals []*GoogleCloudDiscoveryengineV1betaInterval `json:"intervals,omitempty"` - - // Key: Required. Supported textual and numerical facet keys in Document - // object, over which the facet values are computed. Facet key is - // case-sensitive. - Key string `json:"key,omitempty"` +// GoogleCloudDiscoveryengineV1betaEngineChatEngineConfigAgentCreationCon +// fig: Configurations for generating a Dialogflow agent. Note that +// these configurations are one-time consumed by and passed to +// Dialogflow service. It means they cannot be retrieved using +// EngineService.GetEngine or EngineService.ListEngines API after engine +// creation. +type GoogleCloudDiscoveryengineV1betaEngineChatEngineConfigAgentCreationConfig struct { + // Business: Name of the company, organization or other entity that the + // agent represents. Used for knowledge connector LLM prompt and for + // knowledge search. + Business string `json:"business,omitempty"` - // OrderBy: The order in which documents are returned. Allowed values - // are: * "count desc", which means order by - // SearchResponse.Facet.values.count descending. * "value desc", which - // means order by SearchResponse.Facet.values.value descending. Only - // applies to textual facets. If not set, textual values are sorted in - // natural order (https://en.wikipedia.org/wiki/Natural_sort_order); - // numerical intervals are sorted in the order given by - // FacetSpec.FacetKey.intervals. - OrderBy string `json:"orderBy,omitempty"` + // DefaultLanguageCode: Required. The default language of the agent as a + // language tag. See Language Support + // (https://cloud.google.com/dialogflow/docs/reference/language) for a + // list of the currently supported language codes. + DefaultLanguageCode string `json:"defaultLanguageCode,omitempty"` - // Prefixes: Only get facet values that start with the given string - // prefix. For example, suppose "category" has three values "Action > - // 2022", "Action > 2021" and "Sci-Fi > 2022". If set "prefixes" to - // "Action", the "category" facet only contains "Action > 2022" and - // "Action > 2021". Only supported on textual fields. Maximum is 10. - Prefixes []string `json:"prefixes,omitempty"` + // Location: Agent location for Agent creation, supported values: + // global/us/eu. If not provided, us Engine will create Agent using + // us-central-1 by default; eu Engine will create Agent using eu-west-1 + // by default. + Location string `json:"location,omitempty"` - // RestrictedValues: Only get facet for the given restricted values. - // Only supported on textual fields. For example, suppose "category" has - // three values "Action > 2022", "Action > 2021" and "Sci-Fi > 2022". If - // set "restricted_values" to "Action > 2022", the "category" facet only - // contains "Action > 2022". Only supported on textual fields. Maximum - // is 10. - RestrictedValues []string `json:"restrictedValues,omitempty"` + // TimeZone: Required. The time zone of the agent from the time zone + // database (https://www.iana.org/time-zones), e.g., America/New_York, + // Europe/Paris. + TimeZone string `json:"timeZone,omitempty"` - // ForceSendFields is a list of field names (e.g. "CaseInsensitive") to + // ForceSendFields is a list of field names (e.g. "Business") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -6834,30 +6317,29 @@ type GoogleCloudDiscoveryengineV1betaSearchRequestFacetSpecFacetKey struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "CaseInsensitive") to - // include in API requests with the JSON null value. By default, fields - // with empty values are omitted from API requests. However, any field - // with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. + // NullFields is a list of field names (e.g. "Business") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1betaSearchRequestFacetSpecFacetKey) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaSearchRequestFacetSpecFacetKey +func (s *GoogleCloudDiscoveryengineV1betaEngineChatEngineConfigAgentCreationConfig) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaEngineChatEngineConfigAgentCreationConfig raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaSearchRequestImageQuery: Specifies -// the image query input. -type GoogleCloudDiscoveryengineV1betaSearchRequestImageQuery struct { - // ImageBytes: Base64 encoded image bytes. Supported image formats: - // JPEG, PNG, and BMP. - ImageBytes string `json:"imageBytes,omitempty"` +// GoogleCloudDiscoveryengineV1betaEngineChatEngineMetadata: Additional +// information of a Chat Engine. Fields in this message are output only. +type GoogleCloudDiscoveryengineV1betaEngineChatEngineMetadata struct { + // DialogflowAgent: The resource name of a Dialogflow agent, that this + // Chat Engine refers to. Format: `projects//locations//agents/`. + DialogflowAgent string `json:"dialogflowAgent,omitempty"` - // ForceSendFields is a list of field names (e.g. "ImageBytes") to + // ForceSendFields is a list of field names (e.g. "DialogflowAgent") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -6865,42 +6347,31 @@ type GoogleCloudDiscoveryengineV1betaSearchRequestImageQuery struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "ImageBytes") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "DialogflowAgent") to + // include in API requests with the JSON null value. By default, fields + // with empty values are omitted from API requests. However, any field + // with an empty value appearing in NullFields will be sent to the + // server as null. It is an error if a field in this list has a + // non-empty value. This may be used to include null fields in Patch + // requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1betaSearchRequestImageQuery) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaSearchRequestImageQuery +func (s *GoogleCloudDiscoveryengineV1betaEngineChatEngineMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaEngineChatEngineMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaSearchRequestQueryExpansionSpec: -// Specification to determine under which conditions query expansion -// should occur. -type GoogleCloudDiscoveryengineV1betaSearchRequestQueryExpansionSpec struct { - // Condition: The condition under which query expansion should occur. - // Default to Condition.DISABLED. - // - // Possible values: - // "CONDITION_UNSPECIFIED" - Unspecified query expansion condition. In - // this case, server behavior defaults to Condition.DISABLED. - // "DISABLED" - Disabled query expansion. Only the exact search query - // is used, even if SearchResponse.total_size is zero. - // "AUTO" - Automatic query expansion built by the Search API. - Condition string `json:"condition,omitempty"` - - // PinUnexpandedResults: Whether to pin unexpanded results. If this - // field is set to true, unexpanded products are always at the top of - // the search results, followed by the expanded results. - PinUnexpandedResults bool `json:"pinUnexpandedResults,omitempty"` +// GoogleCloudDiscoveryengineV1betaEngineCommonConfig: Common +// configurations for an Engine. +type GoogleCloudDiscoveryengineV1betaEngineCommonConfig struct { + // CompanyName: Immutable. The name of the company, business or entity + // that is associated with the engine. Setting this may help improve LLM + // related features. + CompanyName string `json:"companyName,omitempty"` - // ForceSendFields is a list of field names (e.g. "Condition") to + // ForceSendFields is a list of field names (e.g. "CompanyName") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -6908,38 +6379,45 @@ type GoogleCloudDiscoveryengineV1betaSearchRequestQueryExpansionSpec struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Condition") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as + // NullFields is a list of field names (e.g. "CompanyName") to include + // in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. However, any field with + // an empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1betaSearchRequestQueryExpansionSpec) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaSearchRequestQueryExpansionSpec +func (s *GoogleCloudDiscoveryengineV1betaEngineCommonConfig) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaEngineCommonConfig raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaSearchRequestSpellCorrectionSpec: The -// specification for query spell correction. -type GoogleCloudDiscoveryengineV1betaSearchRequestSpellCorrectionSpec struct { - // Mode: The mode under which spell correction should take effect to - // replace the original search query. Default to Mode.AUTO. +// GoogleCloudDiscoveryengineV1betaEngineSearchEngineConfig: +// Configurations for a Search Engine. +type GoogleCloudDiscoveryengineV1betaEngineSearchEngineConfig struct { + // SearchAddOns: The add-on that this search engine enables. // // Possible values: - // "MODE_UNSPECIFIED" - Unspecified spell correction mode. In this - // case, server behavior defaults to Mode.AUTO. - // "SUGGESTION_ONLY" - Search API will try to find a spell suggestion - // if there is any and put in the SearchResponse.corrected_query. The - // spell suggestion will not be used as the search query. - // "AUTO" - Automatic spell correction built by the Search API. Search - // will be based on the corrected query if found. - Mode string `json:"mode,omitempty"` + // "SEARCH_ADD_ON_UNSPECIFIED" - Default value when the enum is + // unspecified. This is invalid to use. + // "SEARCH_ADD_ON_LLM" - Large language model add-on. + SearchAddOns []string `json:"searchAddOns,omitempty"` - // ForceSendFields is a list of field names (e.g. "Mode") to + // SearchTier: The search feature tier of this engine. Different tiers + // might have different pricing. To learn more, please check the pricing + // documentation. Defaults to SearchTier.SEARCH_TIER_STANDARD if not + // specified. + // + // Possible values: + // "SEARCH_TIER_UNSPECIFIED" - Default value when the enum is + // unspecified. This is invalid to use. + // "SEARCH_TIER_STANDARD" - Standard tier. + // "SEARCH_TIER_ENTERPRISE" - Enterprise tier. + SearchTier string `json:"searchTier,omitempty"` + + // ForceSendFields is a list of field names (e.g. "SearchAddOns") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -6947,77 +6425,45 @@ type GoogleCloudDiscoveryengineV1betaSearchRequestSpellCorrectionSpec struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Mode") to include in API - // requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as + // NullFields is a list of field names (e.g. "SearchAddOns") to include + // in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. However, any field with + // an empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1betaSearchRequestSpellCorrectionSpec) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaSearchRequestSpellCorrectionSpec +func (s *GoogleCloudDiscoveryengineV1betaEngineSearchEngineConfig) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaEngineSearchEngineConfig raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaSearchResponse: Response message for -// SearchService.Search method. -type GoogleCloudDiscoveryengineV1betaSearchResponse struct { - // AppliedControls: Controls applied as part of the Control service. - AppliedControls []string `json:"appliedControls,omitempty"` - - // AttributionToken: A unique search token. This should be included in - // the UserEvent logs resulting from this search, which enables accurate - // attribution of search model performance. - AttributionToken string `json:"attributionToken,omitempty"` - - // CorrectedQuery: Contains the spell corrected query, if found. If the - // spell correction type is AUTOMATIC, then the search results are based - // on corrected_query. Otherwise the original query is used for search. - CorrectedQuery string `json:"correctedQuery,omitempty"` - - // Facets: Results of facets requested by user. - Facets []*GoogleCloudDiscoveryengineV1betaSearchResponseFacet `json:"facets,omitempty"` - - GeoSearchDebugInfo []*GoogleCloudDiscoveryengineV1betaSearchResponseGeoSearchDebugInfo `json:"geoSearchDebugInfo,omitempty"` - - // GuidedSearchResult: Guided search result. - GuidedSearchResult *GoogleCloudDiscoveryengineV1betaSearchResponseGuidedSearchResult `json:"guidedSearchResult,omitempty"` - - // NextPageToken: A token that can be sent as SearchRequest.page_token - // to retrieve the next page. If this field is omitted, there are no - // subsequent pages. +// GoogleCloudDiscoveryengineV1betaFetchDomainVerificationStatusResponse: +// +// Response message for +// +// SiteSearchEngineService.FetchDomainVerificationStatus method. +type GoogleCloudDiscoveryengineV1betaFetchDomainVerificationStatusResponse struct { + // NextPageToken: A token that 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"` - // QueryExpansionInfo: Query expansion information for the returned - // results. - QueryExpansionInfo *GoogleCloudDiscoveryengineV1betaSearchResponseQueryExpansionInfo `json:"queryExpansionInfo,omitempty"` - - // RedirectUri: The URI of a customer-defined redirect page. If redirect - // action is triggered, no search is performed, and only redirect_uri - // and attribution_token are set in the response. - RedirectUri string `json:"redirectUri,omitempty"` - - // Results: A list of matched documents. The order represents the - // ranking. - Results []*GoogleCloudDiscoveryengineV1betaSearchResponseSearchResult `json:"results,omitempty"` - - // Summary: A summary as part of the search results. This field is only - // returned if SearchRequest.ContentSearchSpec.summary_spec is set. - Summary *GoogleCloudDiscoveryengineV1betaSearchResponseSummary `json:"summary,omitempty"` + // TargetSites: List of TargetSites containing the site verification + // status. + TargetSites []*GoogleCloudDiscoveryengineV1betaTargetSite `json:"targetSites,omitempty"` - // TotalSize: The estimated total count of matched items irrespective of - // pagination. The count of results returned by pagination may be less - // than the total_size that matches. + // TotalSize: The total number of items matching the request. This will + // always be populated in the response. TotalSize int64 `json:"totalSize,omitempty"` // ServerResponse contains the HTTP response code and headers from the // server. googleapi.ServerResponse `json:"-"` - // ForceSendFields is a list of field names (e.g. "AppliedControls") to + // 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. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -7025,35 +6471,48 @@ type GoogleCloudDiscoveryengineV1betaSearchResponse struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "AppliedControls") to - // include in API requests with the JSON null value. By default, fields - // with empty values are omitted from API requests. However, any field - // with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. + // 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. However, any field with + // an empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1betaSearchResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaSearchResponse +func (s *GoogleCloudDiscoveryengineV1betaFetchDomainVerificationStatusResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaFetchDomainVerificationStatusResponse raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaSearchResponseFacet: A facet result. -type GoogleCloudDiscoveryengineV1betaSearchResponseFacet struct { - // DynamicFacet: Whether the facet is dynamically generated. - DynamicFacet bool `json:"dynamicFacet,omitempty"` - - // Key: The key for this facet. E.g., "colors" or "price". It matches - // SearchRequest.FacetSpec.FacetKey.key. - Key string `json:"key,omitempty"` - - // Values: The facet values for this field. - Values []*GoogleCloudDiscoveryengineV1betaSearchResponseFacetFacetValue `json:"values,omitempty"` +// GoogleCloudDiscoveryengineV1betaGcsSource: Cloud Storage location for +// input content. +type GoogleCloudDiscoveryengineV1betaGcsSource struct { + // DataSchema: The schema to use when parsing the data from the source. + // Supported values for document imports: * `document` (default): One + // JSON Document per line. Each document must have a valid Document.id. + // * `content`: Unstructured data (e.g. PDF, HTML). Each file matched by + // `input_uris` becomes a document, with the ID set to the first 128 + // bits of SHA256(URI) encoded as a hex string. * `custom`: One custom + // data JSON per row in arbitrary format that conforms to the defined + // Schema of the data store. This can only be used by Gen App Builder. * + // `csv`: A CSV file with header conforming to the defined Schema of the + // data store. Each entry after the header is imported as a Document. + // This can only be used by Gen App Builder. Supported values for user + // even imports: * `user_event` (default): One JSON UserEvent per line. + DataSchema string `json:"dataSchema,omitempty"` - // ForceSendFields is a list of field names (e.g. "DynamicFacet") to + // InputUris: Required. Cloud Storage URIs to input files. URI can be up + // to 2000 characters long. URIs can match the full object path (for + // example, `gs://bucket/directory/object.json`) or a pattern matching + // one or more files, such as `gs://bucket/directory/*.json`. A request + // can contain at most 100 files (or 100,000 files if `data_schema` is + // `content`). Each file can be up to 2 GB (or 100 MB if `data_schema` + // is `content`). + InputUris []string `json:"inputUris,omitempty"` + + // ForceSendFields is a list of field names (e.g. "DataSchema") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -7061,35 +6520,40 @@ type GoogleCloudDiscoveryengineV1betaSearchResponseFacet struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "DynamicFacet") to include - // in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. However, any field with - // an empty value appearing in NullFields will be sent to the server as + // NullFields is a list of field names (e.g. "DataSchema") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1betaSearchResponseFacet) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaSearchResponseFacet +func (s *GoogleCloudDiscoveryengineV1betaGcsSource) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaGcsSource raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaSearchResponseFacetFacetValue: A -// facet value which contains value names and their count. -type GoogleCloudDiscoveryengineV1betaSearchResponseFacetFacetValue struct { - // Count: Number of items that have this facet value. - Count int64 `json:"count,omitempty,string"` +// GoogleCloudDiscoveryengineV1betaImportDocumentsMetadata: Metadata +// related to the progress of the ImportDocuments operation. This is +// returned by the google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1betaImportDocumentsMetadata struct { + // CreateTime: Operation create time. + CreateTime string `json:"createTime,omitempty"` - // Interval: Interval value for a facet, such as 10, 20) for facet - // "price". It matches [SearchRequest.FacetSpec.FacetKey.intervals. - Interval *GoogleCloudDiscoveryengineV1betaInterval `json:"interval,omitempty"` + // FailureCount: Count of entries that encountered errors while + // processing. + FailureCount int64 `json:"failureCount,omitempty,string"` - // Value: Text value of a facet, such as "Black" for facet "colors". - Value string `json:"value,omitempty"` + // SuccessCount: Count of entries that were processed successfully. + SuccessCount int64 `json:"successCount,omitempty,string"` - // ForceSendFields is a list of field names (e.g. "Count") to + // 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. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -7097,8 +6561,8 @@ type GoogleCloudDiscoveryengineV1betaSearchResponseFacetFacetValue struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Count") to include in API - // requests with the JSON null value. By default, fields with empty + // 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. However, any field with an // empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. @@ -7106,66 +6570,80 @@ type GoogleCloudDiscoveryengineV1betaSearchResponseFacetFacetValue struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1betaSearchResponseFacetFacetValue) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaSearchResponseFacetFacetValue +func (s *GoogleCloudDiscoveryengineV1betaImportDocumentsMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaImportDocumentsMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaSearchResponseGeoSearchDebugInfo: -// Debug information specifically related to forward geocoding issues -// arising from Geolocation Search. -type GoogleCloudDiscoveryengineV1betaSearchResponseGeoSearchDebugInfo struct { - // ErrorMessage: The error produced. - ErrorMessage string `json:"errorMessage,omitempty"` +// GoogleCloudDiscoveryengineV1betaImportDocumentsRequest: Request +// message for Import methods. +type GoogleCloudDiscoveryengineV1betaImportDocumentsRequest struct { + // AutoGenerateIds: Whether to automatically generate IDs for the + // documents if absent. If set to `true`, Document.ids are automatically + // generated based on the hash of the payload, where IDs may not be + // consistent during multiple imports. In which case + // ReconciliationMode.FULL is highly recommended to avoid duplicate + // contents. If unset or set to `false`, Document.ids have to be + // specified using id_field, otherwise, documents without IDs fail to be + // imported. Only set this field when using GcsSource or BigQuerySource, + // and when GcsSource.data_schema or BigQuerySource.data_schema is + // `custom` or `csv`. Otherwise, an INVALID_ARGUMENT error is thrown. + AutoGenerateIds bool `json:"autoGenerateIds,omitempty"` - // OriginalAddressQuery: The address from which forward geocoding - // ingestion produced issues. - OriginalAddressQuery string `json:"originalAddressQuery,omitempty"` + // BigquerySource: BigQuery input source. + BigquerySource *GoogleCloudDiscoveryengineV1betaBigQuerySource `json:"bigquerySource,omitempty"` - // ForceSendFields is a list of field names (e.g. "ErrorMessage") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. - ForceSendFields []string `json:"-"` + // ErrorConfig: The desired location of errors incurred during the + // Import. + ErrorConfig *GoogleCloudDiscoveryengineV1betaImportErrorConfig `json:"errorConfig,omitempty"` - // NullFields is a list of field names (e.g. "ErrorMessage") to include - // in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. However, any field with - // an empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. - NullFields []string `json:"-"` -} + // GcsSource: Cloud Storage location for the input content. + GcsSource *GoogleCloudDiscoveryengineV1betaGcsSource `json:"gcsSource,omitempty"` -func (s *GoogleCloudDiscoveryengineV1betaSearchResponseGeoSearchDebugInfo) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaSearchResponseGeoSearchDebugInfo - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) -} + // IdField: The field in the Cloud Storage and BigQuery sources that + // indicates the unique IDs of the documents. For GcsSource it is the + // key of the JSON field. For instance, `my_id` for JSON `{"my_id": + // "some_uuid"}`. For BigQuerySource it is the column name of the + // BigQuery table where the unique ids are stored. The values of the + // JSON field or the BigQuery column are used as the Document.ids. The + // JSON field or the BigQuery column must be of string type, and the + // values must be set as valid strings conform to RFC-1034 + // (https://tools.ietf.org/html/rfc1034) with 1-63 characters. + // Otherwise, documents without valid IDs fail to be imported. Only set + // this field when using GcsSource or BigQuerySource, and when + // GcsSource.data_schema or BigQuerySource.data_schema is `custom`. And + // only set this field when auto_generate_ids is unset or set as + // `false`. Otherwise, an INVALID_ARGUMENT error is thrown. If it is + // unset, a default value `_id` is used when importing from the allowed + // data sources. + IdField string `json:"idField,omitempty"` -// GoogleCloudDiscoveryengineV1betaSearchResponseGuidedSearchResult: -// Guided search result. The guided search helps user to refine the -// search results and narrow down to the real needs from a broaded -// search results. -type GoogleCloudDiscoveryengineV1betaSearchResponseGuidedSearchResult struct { - // FollowUpQuestions: Suggested follow-up questions. - FollowUpQuestions []string `json:"followUpQuestions,omitempty"` + // InlineSource: The Inline source for the input content for documents. + InlineSource *GoogleCloudDiscoveryengineV1betaImportDocumentsRequestInlineSource `json:"inlineSource,omitempty"` - // RefinementAttributes: A list of ranked refinement attributes. - RefinementAttributes []*GoogleCloudDiscoveryengineV1betaSearchResponseGuidedSearchResultRefinementAttribute `json:"refinementAttributes,omitempty"` + // ReconciliationMode: The mode of reconciliation between existing + // documents and the documents to be imported. Defaults to + // ReconciliationMode.INCREMENTAL. + // + // Possible values: + // "RECONCILIATION_MODE_UNSPECIFIED" - Defaults to `INCREMENTAL`. + // "INCREMENTAL" - Inserts new documents or updates existing + // documents. + // "FULL" - Calculates diff and replaces the entire document dataset. + // Existing documents may be deleted if they are not present in the + // source location. + ReconciliationMode string `json:"reconciliationMode,omitempty"` - // ForceSendFields is a list of field names (e.g. "FollowUpQuestions") - // to unconditionally include in API requests. By default, fields with + // ForceSendFields is a list of field names (e.g. "AutoGenerateIds") to + // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be // sent to the server regardless of whether the field is empty or not. // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "FollowUpQuestions") to + // NullFields is a list of field names (e.g. "AutoGenerateIds") to // include in API requests with the JSON null value. By default, fields // with empty values are omitted from API requests. However, any field // with an empty value appearing in NullFields will be sent to the @@ -7175,24 +6653,20 @@ type GoogleCloudDiscoveryengineV1betaSearchResponseGuidedSearchResult struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1betaSearchResponseGuidedSearchResult) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaSearchResponseGuidedSearchResult +func (s *GoogleCloudDiscoveryengineV1betaImportDocumentsRequest) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaImportDocumentsRequest raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaSearchResponseGuidedSearchResultRefine -// mentAttribute: Useful attribute for search result refinements. -type GoogleCloudDiscoveryengineV1betaSearchResponseGuidedSearchResultRefinementAttribute struct { - // AttributeKey: Attribute key used to refine the results e.g. - // 'movie_type'. - AttributeKey string `json:"attributeKey,omitempty"` - - // AttributeValue: Attribute value used to refine the results e.g. - // 'drama'. - AttributeValue string `json:"attributeValue,omitempty"` +// GoogleCloudDiscoveryengineV1betaImportDocumentsRequestInlineSource: +// The inline source for the input config for ImportDocuments method. +type GoogleCloudDiscoveryengineV1betaImportDocumentsRequestInlineSource struct { + // Documents: Required. A list of documents to update/create. Each + // document must have a valid Document.id. Recommended max of 100 items. + Documents []*GoogleCloudDiscoveryengineV1betaDocument `json:"documents,omitempty"` - // ForceSendFields is a list of field names (e.g. "AttributeKey") to + // ForceSendFields is a list of field names (e.g. "Documents") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -7200,35 +6674,36 @@ type GoogleCloudDiscoveryengineV1betaSearchResponseGuidedSearchResultRefinementA // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "AttributeKey") to include - // in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. However, any field with - // an empty value appearing in NullFields will be sent to the server as + // NullFields is a list of field names (e.g. "Documents") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1betaSearchResponseGuidedSearchResultRefinementAttribute) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaSearchResponseGuidedSearchResultRefinementAttribute +func (s *GoogleCloudDiscoveryengineV1betaImportDocumentsRequestInlineSource) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaImportDocumentsRequestInlineSource raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaSearchResponseQueryExpansionInfo: -// Information describing query expansion including whether expansion -// has occurred. -type GoogleCloudDiscoveryengineV1betaSearchResponseQueryExpansionInfo struct { - // ExpandedQuery: Bool describing whether query expansion has occurred. - ExpandedQuery bool `json:"expandedQuery,omitempty"` +// GoogleCloudDiscoveryengineV1betaImportDocumentsResponse: Response of +// the ImportDocumentsRequest. If the long running operation is done, +// then this message is returned by the +// google.longrunning.Operations.response field if the operation was +// successful. +type GoogleCloudDiscoveryengineV1betaImportDocumentsResponse struct { + // ErrorConfig: Echoes the destination for the complete errors in the + // request if set. + ErrorConfig *GoogleCloudDiscoveryengineV1betaImportErrorConfig `json:"errorConfig,omitempty"` - // PinnedResultCount: Number of pinned results. This field will only be - // set when expansion happens and - // SearchRequest.QueryExpansionSpec.pin_unexpanded_results is set to - // true. - PinnedResultCount int64 `json:"pinnedResultCount,omitempty,string"` + // ErrorSamples: A sample of errors encountered while processing the + // request. + ErrorSamples []*GoogleRpcStatus `json:"errorSamples,omitempty"` - // ForceSendFields is a list of field names (e.g. "ExpandedQuery") to + // ForceSendFields is a list of field names (e.g. "ErrorConfig") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -7236,7 +6711,7 @@ type GoogleCloudDiscoveryengineV1betaSearchResponseQueryExpansionInfo struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "ExpandedQuery") to include + // NullFields is a list of field names (e.g. "ErrorConfig") to include // in API requests with the JSON null value. By default, fields with // empty values are omitted from API requests. However, any field with // an empty value appearing in NullFields will be sent to the server as @@ -7245,26 +6720,22 @@ type GoogleCloudDiscoveryengineV1betaSearchResponseQueryExpansionInfo struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1betaSearchResponseQueryExpansionInfo) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaSearchResponseQueryExpansionInfo +func (s *GoogleCloudDiscoveryengineV1betaImportDocumentsResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaImportDocumentsResponse raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaSearchResponseSearchResult: -// Represents the search results. -type GoogleCloudDiscoveryengineV1betaSearchResponseSearchResult struct { - // Document: The document data snippet in the search response. Only - // fields that are marked as retrievable are populated. - Document *GoogleCloudDiscoveryengineV1betaDocument `json:"document,omitempty"` - - // Id: Document.id of the searched Document. - Id string `json:"id,omitempty"` - - // ModelScores: Google provided available scores. - ModelScores map[string]GoogleCloudDiscoveryengineV1betaDoubleList `json:"modelScores,omitempty"` +// GoogleCloudDiscoveryengineV1betaImportErrorConfig: Configuration of +// destination for Import related errors. +type GoogleCloudDiscoveryengineV1betaImportErrorConfig struct { + // GcsPrefix: Cloud Storage prefix for import errors. This must be an + // empty, existing Cloud Storage directory. Import errors are written to + // sharded files in this directory, one per line, as a JSON-encoded + // `google.rpc.Status` message. + GcsPrefix string `json:"gcsPrefix,omitempty"` - // ForceSendFields is a list of field names (e.g. "Document") to + // ForceSendFields is a list of field names (e.g. "GcsPrefix") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -7272,7 +6743,7 @@ type GoogleCloudDiscoveryengineV1betaSearchResponseSearchResult struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Document") to include in + // NullFields is a list of field names (e.g. "GcsPrefix") to include in // API requests with the JSON null value. By default, fields with empty // values are omitted from API requests. However, any field with an // empty value appearing in NullFields will be sent to the server as @@ -7281,49 +6752,25 @@ type GoogleCloudDiscoveryengineV1betaSearchResponseSearchResult struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1betaSearchResponseSearchResult) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaSearchResponseSearchResult +func (s *GoogleCloudDiscoveryengineV1betaImportErrorConfig) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaImportErrorConfig raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaSearchResponseSummary: Summary of the -// top N search result specified by the summary spec. -type GoogleCloudDiscoveryengineV1betaSearchResponseSummary struct { - // SafetyAttributes: A collection of Safety Attribute categories and - // their associated confidence scores. - SafetyAttributes *GoogleCloudDiscoveryengineV1betaSearchResponseSummarySafetyAttributes `json:"safetyAttributes,omitempty"` - - // SummarySkippedReasons: Additional summary-skipped reasons. This - // provides the reason for ignored cases. If nothing is skipped, this - // field is not set. - // - // Possible values: - // "SUMMARY_SKIPPED_REASON_UNSPECIFIED" - Default value. The summary - // skipped reason is not specified. - // "ADVERSARIAL_QUERY_IGNORED" - The adversarial query ignored case. - // Only populated when SummarySpec.ignore_adversarial_query is set to - // `true`. - // "NON_SUMMARY_SEEKING_QUERY_IGNORED" - The non-summary seeking query - // ignored case. Only populated when - // SummarySpec.ignore_non_summary_seeking_query is set to `true`. - // "OUT_OF_DOMAIN_QUERY_IGNORED" - The out-of-domain query ignored - // case. Google skips the summary if there are no high-relevance search - // results. For example, the data store contains facts about company A - // but the user query is asking questions about company B. - // "POTENTIAL_POLICY_VIOLATION" - The potential policy violation case. - // Google skips the summary if there is a potential policy violation - // detected. This includes content that may be violent or toxic. - // "LLM_ADDON_NOT_ENABLED" - The LLM addon not enabled case. Google - // skips the summary if the LLM addon is not enabled. - SummarySkippedReasons []string `json:"summarySkippedReasons,omitempty"` - - // SummaryText: The summary content. - SummaryText string `json:"summaryText,omitempty"` +// GoogleCloudDiscoveryengineV1betaImportSuggestionDenyListEntriesMetadat +// a: Metadata related to the progress of the +// ImportSuggestionDenyListEntries operation. This is returned by the +// google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1betaImportSuggestionDenyListEntriesMetadata struct { + // CreateTime: Operation create time. + CreateTime string `json:"createTime,omitempty"` - SummaryWithMetadata *GoogleCloudDiscoveryengineV1betaSearchResponseSummarySummaryWithMetadata `json:"summaryWithMetadata,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. "SafetyAttributes") to + // 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. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -7331,36 +6778,37 @@ type GoogleCloudDiscoveryengineV1betaSearchResponseSummary struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "SafetyAttributes") to - // include in API requests with the JSON null value. By default, fields - // with empty values are omitted from API requests. However, any field - // with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. + // 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. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1betaSearchResponseSummary) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaSearchResponseSummary +func (s *GoogleCloudDiscoveryengineV1betaImportSuggestionDenyListEntriesMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaImportSuggestionDenyListEntriesMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaSearchResponseSummaryCitation: -// Citation info for a segment. -type GoogleCloudDiscoveryengineV1betaSearchResponseSummaryCitation struct { - // EndIndex: End of the attributed segment, exclusive. - EndIndex int64 `json:"endIndex,omitempty,string"` - - // Sources: Citation sources for the attributed segment. - Sources []*GoogleCloudDiscoveryengineV1betaSearchResponseSummaryCitationSource `json:"sources,omitempty"` +// GoogleCloudDiscoveryengineV1betaImportSuggestionDenyListEntriesRequest +// : Request message for +// CompletionService.ImportSuggestionDenyListEntries method. +type GoogleCloudDiscoveryengineV1betaImportSuggestionDenyListEntriesRequest struct { + // GcsSource: Cloud Storage location for the input content. Only 1 file + // can be specified that contains all entries to import. Supported + // values `gcs_source.schema` for autocomplete suggestion deny list + // entry imports: * `suggestion_deny_list` (default): One JSON + // [SuggestionDenyListEntry] per line. + GcsSource *GoogleCloudDiscoveryengineV1betaGcsSource `json:"gcsSource,omitempty"` - // StartIndex: Index indicates the start of the segment, measured in - // bytes/unicode. - StartIndex int64 `json:"startIndex,omitempty,string"` + // InlineSource: The Inline source for the input content for suggestion + // deny list entries. + InlineSource *GoogleCloudDiscoveryengineV1betaImportSuggestionDenyListEntriesRequestInlineSource `json:"inlineSource,omitempty"` - // ForceSendFields is a list of field names (e.g. "EndIndex") to + // ForceSendFields is a list of field names (e.g. "GcsSource") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -7368,7 +6816,7 @@ type GoogleCloudDiscoveryengineV1betaSearchResponseSummaryCitation struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "EndIndex") to include in + // NullFields is a list of field names (e.g. "GcsSource") to include in // API requests with the JSON null value. By default, fields with empty // values are omitted from API requests. However, any field with an // empty value appearing in NullFields will be sent to the server as @@ -7377,20 +6825,20 @@ type GoogleCloudDiscoveryengineV1betaSearchResponseSummaryCitation struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1betaSearchResponseSummaryCitation) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaSearchResponseSummaryCitation +func (s *GoogleCloudDiscoveryengineV1betaImportSuggestionDenyListEntriesRequest) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaImportSuggestionDenyListEntriesRequest raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaSearchResponseSummaryCitationMetadata: -// -// Citation metadata. -type GoogleCloudDiscoveryengineV1betaSearchResponseSummaryCitationMetadata struct { - // Citations: Citations for segments. - Citations []*GoogleCloudDiscoveryengineV1betaSearchResponseSummaryCitation `json:"citations,omitempty"` +// GoogleCloudDiscoveryengineV1betaImportSuggestionDenyListEntriesRequest +// InlineSource: The inline source for SuggestionDenyListEntry. +type GoogleCloudDiscoveryengineV1betaImportSuggestionDenyListEntriesRequestInlineSource struct { + // Entries: Required. A list of all denylist entries to import. Max of + // 1000 items. + Entries []*GoogleCloudDiscoveryengineV1betaSuggestionDenyListEntry `json:"entries,omitempty"` - // ForceSendFields is a list of field names (e.g. "Citations") to + // ForceSendFields is a list of field names (e.g. "Entries") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -7398,7 +6846,7 @@ type GoogleCloudDiscoveryengineV1betaSearchResponseSummaryCitationMetadata struc // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Citations") to include in + // NullFields is a list of field names (e.g. "Entries") to include in // API requests with the JSON null value. By default, fields with empty // values are omitted from API requests. However, any field with an // empty value appearing in NullFields will be sent to the server as @@ -7407,21 +6855,29 @@ type GoogleCloudDiscoveryengineV1betaSearchResponseSummaryCitationMetadata struc NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1betaSearchResponseSummaryCitationMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaSearchResponseSummaryCitationMetadata +func (s *GoogleCloudDiscoveryengineV1betaImportSuggestionDenyListEntriesRequestInlineSource) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaImportSuggestionDenyListEntriesRequestInlineSource raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaSearchResponseSummaryCitationSource: -// Citation source. -type GoogleCloudDiscoveryengineV1betaSearchResponseSummaryCitationSource struct { - // ReferenceIndex: Document reference index from - // SummaryWithMetadata.references. It is 0-indexed and the value will be - // zero if the reference_index is not set explicitly. - ReferenceIndex int64 `json:"referenceIndex,omitempty,string"` +// GoogleCloudDiscoveryengineV1betaImportSuggestionDenyListEntriesRespons +// e: Response message for +// CompletionService.ImportSuggestionDenyListEntries method. +type GoogleCloudDiscoveryengineV1betaImportSuggestionDenyListEntriesResponse struct { + // ErrorSamples: A sample of errors encountered while processing the + // request. + ErrorSamples []*GoogleRpcStatus `json:"errorSamples,omitempty"` - // ForceSendFields is a list of field names (e.g. "ReferenceIndex") to + // FailedEntriesCount: Count of deny list entries that failed to be + // imported. + FailedEntriesCount int64 `json:"failedEntriesCount,omitempty,string"` + + // ImportedEntriesCount: Count of deny list entries successfully + // imported. + ImportedEntriesCount int64 `json:"importedEntriesCount,omitempty,string"` + + // ForceSendFields is a list of field names (e.g. "ErrorSamples") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -7429,38 +6885,40 @@ type GoogleCloudDiscoveryengineV1betaSearchResponseSummaryCitationSource struct // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "ReferenceIndex") to - // include in API requests with the JSON null value. By default, fields - // with empty values are omitted from API requests. However, any field - // with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. + // NullFields is a list of field names (e.g. "ErrorSamples") to include + // in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. However, any field with + // an empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1betaSearchResponseSummaryCitationSource) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaSearchResponseSummaryCitationSource +func (s *GoogleCloudDiscoveryengineV1betaImportSuggestionDenyListEntriesResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaImportSuggestionDenyListEntriesResponse raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaSearchResponseSummaryReference: -// Document reference. -type GoogleCloudDiscoveryengineV1betaSearchResponseSummaryReference struct { - // Document: Required. Document.name of the document. Full resource name - // of the referenced document, in the format - // `projects/*/locations/*/collections/*/dataStores/*/branches/*/document - // s/*`. - Document string `json:"document,omitempty"` +// GoogleCloudDiscoveryengineV1betaImportUserEventsMetadata: Metadata +// related to the progress of the Import operation. This is returned by +// the google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1betaImportUserEventsMetadata struct { + // CreateTime: Operation create time. + CreateTime string `json:"createTime,omitempty"` - // Title: Title of the document. - Title string `json:"title,omitempty"` + // FailureCount: Count of entries that encountered errors while + // processing. + FailureCount int64 `json:"failureCount,omitempty,string"` - // Uri: Cloud Storage or HTTP uri for the document. - Uri string `json:"uri,omitempty"` + // SuccessCount: Count of entries that were processed successfully. + SuccessCount int64 `json:"successCount,omitempty,string"` - // ForceSendFields is a list of field names (e.g. "Document") to + // 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. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -7468,7 +6926,7 @@ type GoogleCloudDiscoveryengineV1betaSearchResponseSummaryReference struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Document") to include in + // 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. However, any field with an // empty value appearing in NullFields will be sent to the server as @@ -7477,25 +6935,29 @@ type GoogleCloudDiscoveryengineV1betaSearchResponseSummaryReference struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1betaSearchResponseSummaryReference) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaSearchResponseSummaryReference +func (s *GoogleCloudDiscoveryengineV1betaImportUserEventsMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaImportUserEventsMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaSearchResponseSummarySafetyAttributes: -// -// Safety Attribute categories and their associated confidence scores. -type GoogleCloudDiscoveryengineV1betaSearchResponseSummarySafetyAttributes struct { - // Categories: The display names of Safety Attribute categories - // associated with the generated content. Order matches the Scores. - Categories []string `json:"categories,omitempty"` +// GoogleCloudDiscoveryengineV1betaImportUserEventsRequest: Request +// message for the ImportUserEvents request. +type GoogleCloudDiscoveryengineV1betaImportUserEventsRequest struct { + // BigquerySource: BigQuery input source. + BigquerySource *GoogleCloudDiscoveryengineV1betaBigQuerySource `json:"bigquerySource,omitempty"` - // Scores: The confidence scores of the each category, higher value - // means higher confidence. Order matches the Categories. - Scores []float64 `json:"scores,omitempty"` + // ErrorConfig: The desired location of errors incurred during the + // Import. Cannot be set for inline user event imports. + ErrorConfig *GoogleCloudDiscoveryengineV1betaImportErrorConfig `json:"errorConfig,omitempty"` - // ForceSendFields is a list of field names (e.g. "Categories") to + // GcsSource: Cloud Storage location for the input content. + GcsSource *GoogleCloudDiscoveryengineV1betaGcsSource `json:"gcsSource,omitempty"` + + // InlineSource: The Inline source for the input content for UserEvents. + InlineSource *GoogleCloudDiscoveryengineV1betaImportUserEventsRequestInlineSource `json:"inlineSource,omitempty"` + + // ForceSendFields is a list of field names (e.g. "BigquerySource") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -7503,51 +6965,30 @@ type GoogleCloudDiscoveryengineV1betaSearchResponseSummarySafetyAttributes struc // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Categories") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "BigquerySource") to + // include in API requests with the JSON null value. By default, fields + // with empty values are omitted from API requests. However, any field + // with an empty value appearing in NullFields will be sent to the + // server as null. It is an error if a field in this list has a + // non-empty value. This may be used to include null fields in Patch + // requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1betaSearchResponseSummarySafetyAttributes) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaSearchResponseSummarySafetyAttributes +func (s *GoogleCloudDiscoveryengineV1betaImportUserEventsRequest) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaImportUserEventsRequest raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -func (s *GoogleCloudDiscoveryengineV1betaSearchResponseSummarySafetyAttributes) UnmarshalJSON(data []byte) error { - type NoMethod GoogleCloudDiscoveryengineV1betaSearchResponseSummarySafetyAttributes - var s1 struct { - Scores []gensupport.JSONFloat64 `json:"scores"` - *NoMethod - } - s1.NoMethod = (*NoMethod)(s) - if err := json.Unmarshal(data, &s1); err != nil { - return err - } - s.Scores = make([]float64, len(s1.Scores)) - for i := range s1.Scores { - s.Scores[i] = float64(s1.Scores[i]) - } - return nil -} - -// GoogleCloudDiscoveryengineV1betaSearchResponseSummarySummaryWithMetada -// ta: Summary with metadata information. -type GoogleCloudDiscoveryengineV1betaSearchResponseSummarySummaryWithMetadata struct { - // CitationMetadata: Citation metadata for given summary. - CitationMetadata *GoogleCloudDiscoveryengineV1betaSearchResponseSummaryCitationMetadata `json:"citationMetadata,omitempty"` - - // References: Document References. - References []*GoogleCloudDiscoveryengineV1betaSearchResponseSummaryReference `json:"references,omitempty"` - - // Summary: Summary text with no citation information. - Summary string `json:"summary,omitempty"` +// GoogleCloudDiscoveryengineV1betaImportUserEventsRequestInlineSource: +// The inline source for the input config for ImportUserEvents method. +type GoogleCloudDiscoveryengineV1betaImportUserEventsRequestInlineSource struct { + // UserEvents: Required. A list of user events to import. Recommended + // max of 10k items. + UserEvents []*GoogleCloudDiscoveryengineV1betaUserEvent `json:"userEvents,omitempty"` - // ForceSendFields is a list of field names (e.g. "CitationMetadata") to + // ForceSendFields is a list of field names (e.g. "UserEvents") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -7555,43 +6996,44 @@ type GoogleCloudDiscoveryengineV1betaSearchResponseSummarySummaryWithMetadata st // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "CitationMetadata") to - // include in API requests with the JSON null value. By default, fields - // with empty values are omitted from API requests. However, any field - // with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. + // NullFields is a list of field names (e.g. "UserEvents") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1betaSearchResponseSummarySummaryWithMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaSearchResponseSummarySummaryWithMetadata +func (s *GoogleCloudDiscoveryengineV1betaImportUserEventsRequestInlineSource) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaImportUserEventsRequestInlineSource raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaSuggestionDenyListEntry: Suggestion -// deny list entry identifying the phrase to block from suggestions and -// the applied operation for the phrase. -type GoogleCloudDiscoveryengineV1betaSuggestionDenyListEntry struct { - // BlockPhrase: Required. Phrase to block from suggestions served. Can - // be maximum 125 characters. - BlockPhrase string `json:"blockPhrase,omitempty"` +// GoogleCloudDiscoveryengineV1betaImportUserEventsResponse: Response of +// the ImportUserEventsRequest. If the long running operation was +// successful, then this message is returned by the +// google.longrunning.Operations.response field if the operation was +// successful. +type GoogleCloudDiscoveryengineV1betaImportUserEventsResponse struct { + // ErrorConfig: Echoes the destination for the complete errors if this + // field was set in the request. + ErrorConfig *GoogleCloudDiscoveryengineV1betaImportErrorConfig `json:"errorConfig,omitempty"` - // MatchOperator: Required. The match operator to apply for this phrase. - // Whether to block the exact phrase, or block any suggestions - // containing this phrase. - // - // Possible values: - // "MATCH_OPERATOR_UNSPECIFIED" - Default value. Should not be used - // "EXACT_MATCH" - If the suggestion is an exact match to the - // block_phrase, then block it. - // "CONTAINS" - If the suggestion contains the block_phrase, then - // block it. - MatchOperator string `json:"matchOperator,omitempty"` + // ErrorSamples: A sample of errors encountered while processing the + // request. + ErrorSamples []*GoogleRpcStatus `json:"errorSamples,omitempty"` - // ForceSendFields is a list of field names (e.g. "BlockPhrase") to + // JoinedEventsCount: Count of user events imported with complete + // existing Documents. + JoinedEventsCount int64 `json:"joinedEventsCount,omitempty,string"` + + // UnjoinedEventsCount: Count of user events imported, but with Document + // information not found in the existing Branch. + UnjoinedEventsCount int64 `json:"unjoinedEventsCount,omitempty,string"` + + // ForceSendFields is a list of field names (e.g. "ErrorConfig") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -7599,7 +7041,7 @@ type GoogleCloudDiscoveryengineV1betaSuggestionDenyListEntry struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "BlockPhrase") to include + // NullFields is a list of field names (e.g. "ErrorConfig") to include // in API requests with the JSON null value. By default, fields with // empty values are omitted from API requests. However, any field with // an empty value appearing in NullFields will be sent to the server as @@ -7608,21 +7050,27 @@ type GoogleCloudDiscoveryengineV1betaSuggestionDenyListEntry struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1betaSuggestionDenyListEntry) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaSuggestionDenyListEntry +func (s *GoogleCloudDiscoveryengineV1betaImportUserEventsResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaImportUserEventsResponse raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaTextInput: Defines text input. -type GoogleCloudDiscoveryengineV1betaTextInput struct { - // Context: Conversation context of the input. - Context *GoogleCloudDiscoveryengineV1betaConversationContext `json:"context,omitempty"` +// GoogleCloudDiscoveryengineV1betaInterval: A floating point interval. +type GoogleCloudDiscoveryengineV1betaInterval struct { + // ExclusiveMaximum: Exclusive upper bound. + ExclusiveMaximum float64 `json:"exclusiveMaximum,omitempty"` - // Input: Text input. - Input string `json:"input,omitempty"` + // ExclusiveMinimum: Exclusive lower bound. + ExclusiveMinimum float64 `json:"exclusiveMinimum,omitempty"` - // ForceSendFields is a list of field names (e.g. "Context") to + // Maximum: Inclusive upper bound. + Maximum float64 `json:"maximum,omitempty"` + + // Minimum: Inclusive lower bound. + Minimum float64 `json:"minimum,omitempty"` + + // ForceSendFields is a list of field names (e.g. "ExclusiveMaximum") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -7630,56 +7078,57 @@ type GoogleCloudDiscoveryengineV1betaTextInput struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Context") to include in - // API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "ExclusiveMaximum") to + // include in API requests with the JSON null value. By default, fields + // with empty values are omitted from API requests. However, any field + // with an empty value appearing in NullFields will be sent to the + // server as null. It is an error if a field in this list has a + // non-empty value. This may be used to include null fields in Patch + // requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1betaTextInput) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaTextInput +func (s *GoogleCloudDiscoveryengineV1betaInterval) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaInterval raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaTransactionInfo: A transaction -// represents the entire purchase transaction. -type GoogleCloudDiscoveryengineV1betaTransactionInfo struct { - // Cost: All the costs associated with the products. These can be - // manufacturing costs, shipping expenses not borne by the end user, or - // any other costs, such that: * Profit = value - tax - cost - Cost float64 `json:"cost,omitempty"` - - // Currency: Required. Currency code. Use three-character ISO-4217 code. - Currency string `json:"currency,omitempty"` - - // DiscountValue: The total discount(s) value applied to this - // transaction. This figure should be excluded from - // TransactionInfo.value For example, if a user paid - // TransactionInfo.value amount, then nominal (pre-discount) value of - // the transaction is the sum of TransactionInfo.value and - // TransactionInfo.discount_value This means that profit is calculated - // the same way, regardless of the discount value, and that - // TransactionInfo.discount_value can be larger than - // TransactionInfo.value: * Profit = value - tax - cost - DiscountValue float64 `json:"discountValue,omitempty"` +func (s *GoogleCloudDiscoveryengineV1betaInterval) UnmarshalJSON(data []byte) error { + type NoMethod GoogleCloudDiscoveryengineV1betaInterval + var s1 struct { + ExclusiveMaximum gensupport.JSONFloat64 `json:"exclusiveMaximum"` + ExclusiveMinimum gensupport.JSONFloat64 `json:"exclusiveMinimum"` + Maximum gensupport.JSONFloat64 `json:"maximum"` + Minimum gensupport.JSONFloat64 `json:"minimum"` + *NoMethod + } + s1.NoMethod = (*NoMethod)(s) + if err := json.Unmarshal(data, &s1); err != nil { + return err + } + s.ExclusiveMaximum = float64(s1.ExclusiveMaximum) + s.ExclusiveMinimum = float64(s1.ExclusiveMinimum) + s.Maximum = float64(s1.Maximum) + s.Minimum = float64(s1.Minimum) + return nil +} - // Tax: All the taxes associated with the transaction. - Tax float64 `json:"tax,omitempty"` +// GoogleCloudDiscoveryengineV1betaListConversationsResponse: Response +// for ListConversations method. +type GoogleCloudDiscoveryengineV1betaListConversationsResponse struct { + // Conversations: All the Conversations for a given data store. + Conversations []*GoogleCloudDiscoveryengineV1betaConversation `json:"conversations,omitempty"` - // TransactionId: The transaction ID with a length limit of 128 - // characters. - TransactionId string `json:"transactionId,omitempty"` + // NextPageToken: Pagination token, if not returned indicates the last + // page. + NextPageToken string `json:"nextPageToken,omitempty"` - // Value: Required. Total non-zero value associated with the - // transaction. This value may include shipping, tax, or other - // adjustments to the total value that you want to include. - Value float64 `json:"value,omitempty"` + // ServerResponse contains the HTTP response code and headers from the + // server. + googleapi.ServerResponse `json:"-"` - // ForceSendFields is a list of field names (e.g. "Cost") to + // ForceSendFields is a list of field names (e.g. "Conversations") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -7687,52 +7136,37 @@ type GoogleCloudDiscoveryengineV1betaTransactionInfo struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Cost") to include in API - // requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as + // NullFields is a list of field names (e.g. "Conversations") to include + // in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. However, any field with + // an empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1betaTransactionInfo) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaTransactionInfo +func (s *GoogleCloudDiscoveryengineV1betaListConversationsResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaListConversationsResponse raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -func (s *GoogleCloudDiscoveryengineV1betaTransactionInfo) UnmarshalJSON(data []byte) error { - type NoMethod GoogleCloudDiscoveryengineV1betaTransactionInfo - var s1 struct { - Cost gensupport.JSONFloat64 `json:"cost"` - DiscountValue gensupport.JSONFloat64 `json:"discountValue"` - Tax gensupport.JSONFloat64 `json:"tax"` - Value gensupport.JSONFloat64 `json:"value"` - *NoMethod - } - s1.NoMethod = (*NoMethod)(s) - if err := json.Unmarshal(data, &s1); err != nil { - return err - } - s.Cost = float64(s1.Cost) - s.DiscountValue = float64(s1.DiscountValue) - s.Tax = float64(s1.Tax) - s.Value = float64(s1.Value) - return nil -} +// GoogleCloudDiscoveryengineV1betaListDataStoresResponse: Response +// message for DataStoreService.ListDataStores method. +type GoogleCloudDiscoveryengineV1betaListDataStoresResponse struct { + // DataStores: All the customer's DataStores. + DataStores []*GoogleCloudDiscoveryengineV1betaDataStore `json:"dataStores,omitempty"` -// GoogleCloudDiscoveryengineV1betaUpdateSchemaMetadata: Metadata for -// UpdateSchema LRO. -type GoogleCloudDiscoveryengineV1betaUpdateSchemaMetadata struct { - // CreateTime: Operation create time. - CreateTime string `json:"createTime,omitempty"` + // NextPageToken: A token that can be sent as + // ListDataStoresRequest.page_token to retrieve the next page. If this + // field is omitted, there are no subsequent pages. + NextPageToken string `json:"nextPageToken,omitempty"` - // UpdateTime: Operation last update time. If the operation is done, - // this is also the finish time. - UpdateTime string `json:"updateTime,omitempty"` + // ServerResponse contains the HTTP response code and headers from the + // server. + googleapi.ServerResponse `json:"-"` - // ForceSendFields is a list of field names (e.g. "CreateTime") to + // ForceSendFields is a list of field names (e.g. "DataStores") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -7740,7 +7174,7 @@ type GoogleCloudDiscoveryengineV1betaUpdateSchemaMetadata struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "CreateTime") to include in + // NullFields is a list of field names (e.g. "DataStores") to include in // API requests with the JSON null value. By default, fields with empty // values are omitted from API requests. However, any field with an // empty value appearing in NullFields will be sent to the server as @@ -7749,164 +7183,28 @@ type GoogleCloudDiscoveryengineV1betaUpdateSchemaMetadata struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1betaUpdateSchemaMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaUpdateSchemaMetadata +func (s *GoogleCloudDiscoveryengineV1betaListDataStoresResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaListDataStoresResponse raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaUserEvent: UserEvent captures all -// metadata information Discovery Engine API needs to know about how end -// users interact with customers' website. -type GoogleCloudDiscoveryengineV1betaUserEvent struct { - // Attributes: Extra user event features to include in the - // recommendation model. These attributes must NOT contain data that - // needs to be parsed or processed further, e.g. JSON or other - // encodings. If you provide custom attributes for ingested user events, - // also include them in the user events that you associate with - // prediction requests. Custom attribute formatting must be consistent - // between imported events and events provided with prediction requests. - // This lets the Discovery Engine API use those custom attributes when - // training models and serving predictions, which helps improve - // recommendation quality. This field needs to pass all below criteria, - // otherwise an `INVALID_ARGUMENT` error is returned: * The key must be - // a UTF-8 encoded string with a length limit of 5,000 characters. * For - // text attributes, at most 400 values are allowed. Empty values are not - // allowed. Each value must be a UTF-8 encoded string with a length - // limit of 256 characters. * For number attributes, at most 400 values - // are allowed. For product recommendations, an example of extra user - // information is `traffic_channel`, which is how a user arrives at the - // site. Users can arrive at the site by coming to the site directly, - // coming through Google search, or in other ways. - Attributes map[string]GoogleCloudDiscoveryengineV1betaCustomAttribute `json:"attributes,omitempty"` - - // AttributionToken: Token to attribute an API response to user - // action(s) to trigger the event. Highly recommended for user events - // that are the result of RecommendationService.Recommend. This field - // enables accurate attribution of recommendation model performance. The - // value must be one of: * RecommendResponse.attribution_token for - // events that are the result of RecommendationService.Recommend. * - // SearchResponse.attribution_token for events that are the result of - // SearchService.Search. This token enables us to accurately attribute - // page view or conversion completion back to the event and the - // particular predict response containing this clicked/purchased - // product. If user clicks on product K in the recommendation results, - // pass RecommendResponse.attribution_token as a URL parameter to - // product K's page. When recording events on product K's page, log the - // RecommendResponse.attribution_token to this field. - AttributionToken string `json:"attributionToken,omitempty"` - - // CompletionInfo: CompletionService.CompleteQuery details related to - // the event. This field should be set for `search` event when - // autocomplete function is enabled and the user clicks a suggestion for - // search. - CompletionInfo *GoogleCloudDiscoveryengineV1betaCompletionInfo `json:"completionInfo,omitempty"` - - // DirectUserRequest: Should set to true if the request is made directly - // from the end user, in which case the UserEvent.user_info.user_agent - // can be populated from the HTTP request. This flag should be set only - // if the API request is made directly from the end user such as a - // mobile app (and not if a gateway or a server is processing and - // pushing the user events). This should not be set when using the - // JavaScript tag in UserEventService.CollectUserEvent. - DirectUserRequest bool `json:"directUserRequest,omitempty"` - - // Documents: List of Documents associated with this user event. This - // field is optional except for the following event types: * `view-item` - // * `add-to-cart` * `purchase` * `media-play` * `media-complete` In a - // `search` event, this field represents the documents 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 UserEvent.documents is desired. - Documents []*GoogleCloudDiscoveryengineV1betaDocumentInfo `json:"documents,omitempty"` - - // EventTime: Only required for UserEventService.ImportUserEvents - // method. Timestamp of when the user event happened. - EventTime string `json:"eventTime,omitempty"` - - // EventType: Required. User event type. Allowed values are: Generic - // values: * `search`: Search for Documents. * `view-item`: Detailed - // page view of a Document. * `view-item-list`: View of a panel or - // ordered list of Documents. * `view-home-page`: View of the home page. - // * `view-category-page`: View of a category page, e.g. Home > Men > - // Jeans Retail-related values: * `add-to-cart`: Add an item(s) to cart, - // e.g. in Retail online shopping * `purchase`: Purchase an item(s) - // Media-related values: * `media-play`: Start/resume watching a video, - // playing a song, etc. * `media-complete`: Finished or stopped midway - // through a video, song, etc. - EventType string `json:"eventType,omitempty"` - - // Filter: The filter syntax consists of an expression language for - // constructing a predicate from one or more fields of the documents - // being filtered. One example is for `search` events, the associated - // SearchRequest may contain a filter expression in SearchRequest.filter - // conforming to https://google.aip.dev/160#filtering. Similarly, for - // `view-item-list` events that are generated from a RecommendRequest, - // this field may be populated directly from RecommendRequest.filter - // conforming to https://google.aip.dev/160#filtering. The value must be - // a UTF-8 encoded string with a length limit of 1,000 characters. - // Otherwise, an `INVALID_ARGUMENT` error is returned. - Filter string `json:"filter,omitempty"` - - // MediaInfo: Media-specific info. - MediaInfo *GoogleCloudDiscoveryengineV1betaMediaInfo `json:"mediaInfo,omitempty"` - - // PageInfo: Page metadata such as categories and other critical - // information for certain event types such as `view-category-page`. - PageInfo *GoogleCloudDiscoveryengineV1betaPageInfo `json:"pageInfo,omitempty"` - - // Panel: Panel metadata associated with this user event. - Panel *GoogleCloudDiscoveryengineV1betaPanelInfo `json:"panel,omitempty"` - - // PromotionIds: The promotion IDs if this is an event associated with - // promotions. Currently, this field is restricted to at most one ID. - PromotionIds []string `json:"promotionIds,omitempty"` - - // SearchInfo: SearchService.Search details related to the event. This - // field should be set for `search` event. - SearchInfo *GoogleCloudDiscoveryengineV1betaSearchInfo `json:"searchInfo,omitempty"` - - // SessionId: A unique identifier for tracking a visitor session with a - // length limit of 128 bytes. A session is an aggregation of an end user - // behavior in a time span. A general guideline to populate the - // session_id: 1. If user has no activity for 30 min, a new session_id - // should be assigned. 2. The session_id should be unique across users, - // suggest use uuid or add UserEvent.user_pseudo_id as prefix. - SessionId string `json:"sessionId,omitempty"` - - // TagIds: A list of identifiers for the independent experiment groups - // this user event belongs to. This is used to distinguish between user - // events associated with different experiment setups on the customer - // end. - TagIds []string `json:"tagIds,omitempty"` - - // TransactionInfo: The transaction metadata (if any) associated with - // this user event. - TransactionInfo *GoogleCloudDiscoveryengineV1betaTransactionInfo `json:"transactionInfo,omitempty"` - - // UserInfo: Information about the end user. - UserInfo *GoogleCloudDiscoveryengineV1betaUserInfo `json:"userInfo,omitempty"` +// GoogleCloudDiscoveryengineV1betaListDocumentsResponse: Response +// message for DocumentService.ListDocuments method. +type GoogleCloudDiscoveryengineV1betaListDocumentsResponse struct { + // Documents: The Documents. + Documents []*GoogleCloudDiscoveryengineV1betaDocument `json:"documents,omitempty"` - // UserPseudoId: Required. A unique identifier for tracking visitors. - // For example, this could be implemented with an HTTP cookie, which - // should be able to uniquely identify a visitor on a single device. - // This unique identifier should not change if the visitor log in/out of - // the website. Do not set the field to the same fixed ID for different - // users. This mixes the event history of those users together, which - // results in degraded model quality. The field must be a UTF-8 encoded - // string with a length limit of 128 characters. Otherwise, an - // `INVALID_ARGUMENT` error is returned. The field should not contain - // PII or user-data. We recommend to use Google Analytics Client ID - // (https://developers.google.com/analytics/devguides/collection/analyticsjs/field-reference#clientId) - // for this field. - UserPseudoId string `json:"userPseudoId,omitempty"` + // NextPageToken: A token that can be sent as + // ListDocumentsRequest.page_token to retrieve the next page. If this + // field is omitted, there are no subsequent pages. + 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. "Attributes") to + // ForceSendFields is a list of field names (e.g. "Documents") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -7914,7 +7212,7 @@ type GoogleCloudDiscoveryengineV1betaUserEvent struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Attributes") to include in + // NullFields is a list of field names (e.g. "Documents") to include in // API requests with the JSON null value. By default, fields with empty // values are omitted from API requests. However, any field with an // empty value appearing in NullFields will be sent to the server as @@ -7923,32 +7221,26 @@ type GoogleCloudDiscoveryengineV1betaUserEvent struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1betaUserEvent) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaUserEvent +func (s *GoogleCloudDiscoveryengineV1betaListDocumentsResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaListDocumentsResponse raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaUserInfo: Information of an end user. -type GoogleCloudDiscoveryengineV1betaUserInfo struct { - // UserAgent: User agent as included in the HTTP header. The field must - // be a UTF-8 encoded string with a length limit of 1,000 characters. - // Otherwise, an `INVALID_ARGUMENT` error is returned. This should not - // be set when using the client side event reporting with GTM or - // JavaScript tag in UserEventService.CollectUserEvent or if - // UserEvent.direct_user_request is set. - UserAgent string `json:"userAgent,omitempty"` +// GoogleCloudDiscoveryengineV1betaListEnginesResponse: Response message +// for EngineService.ListEngines method. +type GoogleCloudDiscoveryengineV1betaListEnginesResponse struct { + // Engines: All the customer's Engines. + Engines []*GoogleCloudDiscoveryengineV1betaEngine `json:"engines,omitempty"` - // UserId: Highly recommended for logged-in users. Unique identifier for - // logged-in user, such as a user name. Don't set for anonymous users. - // Always use a hashed value for this ID. Don't set the field to the - // same fixed ID for different users. This mixes the event history of - // those users together, which results in degraded model quality. The - // field must be a UTF-8 encoded string with a length limit of 128 - // characters. Otherwise, an `INVALID_ARGUMENT` error is returned. - UserId string `json:"userId,omitempty"` + // NextPageToken: Not supported. + NextPageToken string `json:"nextPageToken,omitempty"` - // ForceSendFields is a list of field names (e.g. "UserAgent") to + // ServerResponse contains the HTTP response code and headers from the + // server. + googleapi.ServerResponse `json:"-"` + + // ForceSendFields is a list of field names (e.g. "Engines") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -7956,7 +7248,7 @@ type GoogleCloudDiscoveryengineV1betaUserInfo struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "UserAgent") to include in + // NullFields is a list of field names (e.g. "Engines") to include in // API requests with the JSON null value. By default, fields with empty // values are omitted from API requests. However, any field with an // empty value appearing in NullFields will be sent to the server as @@ -7965,21 +7257,22 @@ type GoogleCloudDiscoveryengineV1betaUserInfo struct { NullFields []string `json:"-"` } -func (s *GoogleCloudDiscoveryengineV1betaUserInfo) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaUserInfo +func (s *GoogleCloudDiscoveryengineV1betaListEnginesResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaListEnginesResponse raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleLongrunningListOperationsResponse: The response message for -// Operations.ListOperations. -type GoogleLongrunningListOperationsResponse struct { - // NextPageToken: The standard List next-page token. +// GoogleCloudDiscoveryengineV1betaListSchemasResponse: Response message +// for SchemaService.ListSchemas method. +type GoogleCloudDiscoveryengineV1betaListSchemasResponse struct { + // NextPageToken: A token that can be sent as + // ListSchemasRequest.page_token to retrieve the next page. If this + // field is omitted, there are no subsequent pages. NextPageToken string `json:"nextPageToken,omitempty"` - // Operations: A list of operations that matches the specified filter in - // the request. - Operations []*GoogleLongrunningOperation `json:"operations,omitempty"` + // Schemas: The Schemas. + Schemas []*GoogleCloudDiscoveryengineV1betaSchema `json:"schemas,omitempty"` // ServerResponse contains the HTTP response code and headers from the // server. @@ -8002,52 +7295,32 @@ type GoogleLongrunningListOperationsResponse struct { NullFields []string `json:"-"` } -func (s *GoogleLongrunningListOperationsResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleLongrunningListOperationsResponse +func (s *GoogleCloudDiscoveryengineV1betaListSchemasResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaListSchemasResponse raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleLongrunningOperation: This resource represents a long-running -// operation that is the result of a network API call. -type GoogleLongrunningOperation struct { - // Done: If the value is `false`, it means the operation is still in - // progress. If `true`, the operation is completed, and either `error` - // or `response` is available. - Done bool `json:"done,omitempty"` - - // Error: The error result of the operation in case of failure or - // cancellation. - Error *GoogleRpcStatus `json:"error,omitempty"` - - // Metadata: Service-specific metadata associated with the operation. It - // typically contains progress information and common metadata such as - // create time. Some services might not provide such metadata. Any - // method that returns a long-running operation should document the - // metadata type, if any. - Metadata googleapi.RawMessage `json:"metadata,omitempty"` +// GoogleCloudDiscoveryengineV1betaListTargetSitesResponse: Response +// message for SiteSearchEngineService.ListTargetSites method. +type GoogleCloudDiscoveryengineV1betaListTargetSitesResponse struct { + // NextPageToken: A token that 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"` - // Name: The server-assigned name, which is only unique within the same - // service that originally returns it. If you use the default HTTP - // mapping, the `name` should be a resource name ending with - // `operations/{unique_id}`. - Name string `json:"name,omitempty"` + // TargetSites: List of TargetSites. + TargetSites []*GoogleCloudDiscoveryengineV1betaTargetSite `json:"targetSites,omitempty"` - // Response: The normal, successful response of the operation. If the - // original method returns no data on success, such as `Delete`, the - // response is `google.protobuf.Empty`. If the original method is - // standard `Get`/`Create`/`Update`, the response should be the - // resource. For other methods, the response should have the type - // `XxxResponse`, where `Xxx` is the original method name. For example, - // if the original method name is `TakeSnapshot()`, the inferred - // response type is `TakeSnapshotResponse`. - Response googleapi.RawMessage `json:"response,omitempty"` + // TotalSize: The total number of items matching the request. This will + // always be populated in the response. + TotalSize int64 `json:"totalSize,omitempty"` // ServerResponse contains the HTTP response code and headers from the // server. googleapi.ServerResponse `json:"-"` - // ForceSendFields is a list of field names (e.g. "Done") to + // 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. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -8055,54 +7328,112 @@ type GoogleLongrunningOperation struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Done") to include in API - // requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as + // 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. However, any field with + // an empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleLongrunningOperation) MarshalJSON() ([]byte, error) { - type NoMethod GoogleLongrunningOperation +func (s *GoogleCloudDiscoveryengineV1betaListTargetSitesResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaListTargetSitesResponse raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleProtobufEmpty: A generic empty message that you can re-use to -// avoid defining duplicated empty messages in your APIs. A typical -// example is to use it as the request or the response type of an API -// method. For instance: service Foo { rpc Bar(google.protobuf.Empty) -// returns (google.protobuf.Empty); } -type GoogleProtobufEmpty struct { - // ServerResponse contains the HTTP response code and headers from the - // server. - googleapi.ServerResponse `json:"-"` -} +// GoogleCloudDiscoveryengineV1betaMediaInfo: Media-specific user event +// information. +type GoogleCloudDiscoveryengineV1betaMediaInfo struct { + // MediaProgressDuration: The media progress time in seconds, if + // applicable. For example, if the end user has finished 90 seconds of a + // playback video, then MediaInfo.media_progress_duration.seconds should + // be set to 90. + MediaProgressDuration string `json:"mediaProgressDuration,omitempty"` -// GoogleRpcStatus: The `Status` type defines a logical error model that -// is suitable for different programming environments, including REST -// APIs and RPC APIs. It is used by gRPC (https://github.com/grpc). Each -// `Status` message contains three pieces of data: error code, error -// message, and error details. You can find out more about this error -// model and how to work with it in the API Design Guide -// (https://cloud.google.com/apis/design/errors). -type GoogleRpcStatus struct { - // Code: The status code, which should be an enum value of - // google.rpc.Code. - Code int64 `json:"code,omitempty"` + // MediaProgressPercentage: Media progress should be computed using only + // the media_progress_duration relative to the media total length. This + // value must be between `[0, 1.0]` inclusive. If this is not a playback + // or the progress cannot be computed (e.g. ongoing livestream), this + // field should be unset. + MediaProgressPercentage float64 `json:"mediaProgressPercentage,omitempty"` - // Details: A list of messages that carry the error details. There is a - // common set of message types for APIs to use. - Details []googleapi.RawMessage `json:"details,omitempty"` + // ForceSendFields is a list of field names (e.g. + // "MediaProgressDuration") to unconditionally include in API requests. + // By default, fields with empty or default values are omitted from API + // requests. However, any non-pointer, non-interface field appearing in + // ForceSendFields will be sent to the server regardless of whether the + // field is empty or not. This may be used to include empty fields in + // Patch requests. + ForceSendFields []string `json:"-"` - // Message: A developer-facing error message, which should be in - // English. Any user-facing error message should be localized and sent - // in the google.rpc.Status.details field, or localized by the client. - Message string `json:"message,omitempty"` + // NullFields is a list of field names (e.g. "MediaProgressDuration") to + // include in API requests with the JSON null value. By default, fields + // with empty values are omitted from API requests. However, any field + // with an empty value appearing in NullFields will be sent to the + // server as null. It is an error if a field in this list has a + // non-empty value. This may be used to include null fields in Patch + // requests. + NullFields []string `json:"-"` +} - // ForceSendFields is a list of field names (e.g. "Code") to +func (s *GoogleCloudDiscoveryengineV1betaMediaInfo) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaMediaInfo + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +func (s *GoogleCloudDiscoveryengineV1betaMediaInfo) UnmarshalJSON(data []byte) error { + type NoMethod GoogleCloudDiscoveryengineV1betaMediaInfo + var s1 struct { + MediaProgressPercentage gensupport.JSONFloat64 `json:"mediaProgressPercentage"` + *NoMethod + } + s1.NoMethod = (*NoMethod)(s) + if err := json.Unmarshal(data, &s1); err != nil { + return err + } + s.MediaProgressPercentage = float64(s1.MediaProgressPercentage) + return nil +} + +// GoogleCloudDiscoveryengineV1betaPageInfo: Detailed page information. +type GoogleCloudDiscoveryengineV1betaPageInfo struct { + // PageCategory: The most specific category associated with a category + // page. To represent full path of category, use '>' sign to separate + // different hierarchies. If '>' is part of the category name, please + // replace it with other character(s). Category pages include special + // pages such as sales or promotions. For instance, a special sale page + // may have the category hierarchy: "pageCategory" : "Sales > 2017 + // Black Friday Deals". Required for `view-category-page` events. Other + // event types should not set this field. Otherwise, an + // `INVALID_ARGUMENT` error is returned. + PageCategory string `json:"pageCategory,omitempty"` + + // PageviewId: 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 `pageview_id` 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. + PageviewId string `json:"pageviewId,omitempty"` + + // ReferrerUri: The referrer URL of the current page. When using the + // client side event reporting with JavaScript pixel and Google Tag + // Manager, this value is filled in automatically. However, some browser + // privacy restrictions may cause this field to be empty. + ReferrerUri string `json:"referrerUri,omitempty"` + + // Uri: Complete URL (window.location.href) of the user's current page. + // When using the client side event reporting with JavaScript pixel and + // Google Tag Manager, this value is filled in automatically. Maximum + // length 5,000 characters. + Uri string `json:"uri,omitempty"` + + // ForceSendFields is a list of field names (e.g. "PageCategory") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -8110,8 +7441,89 @@ type GoogleRpcStatus struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Code") to include in API - // requests with the JSON null value. By default, fields with empty + // NullFields is a list of field names (e.g. "PageCategory") to include + // in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. However, any field with + // an empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1betaPageInfo) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaPageInfo + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1betaPanelInfo: Detailed panel information +// associated with a user event. +type GoogleCloudDiscoveryengineV1betaPanelInfo struct { + // DisplayName: The display name of the panel. + DisplayName string `json:"displayName,omitempty"` + + // PanelId: Required. The panel ID. + PanelId string `json:"panelId,omitempty"` + + // PanelPosition: 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"` + + // TotalPanels: 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. "DisplayName") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + 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. However, any field with + // an empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1betaPanelInfo) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaPanelInfo + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1betaPurgeDocumentsMetadata: Metadata +// related to the progress of the PurgeDocuments operation. This will be +// returned by the google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1betaPurgeDocumentsMetadata struct { + // CreateTime: Operation create time. + CreateTime string `json:"createTime,omitempty"` + + // FailureCount: Count of entries that encountered errors while + // processing. + FailureCount int64 `json:"failureCount,omitempty,string"` + + // SuccessCount: Count of entries that were deleted successfully. + SuccessCount int64 `json:"successCount,omitempty,string"` + + // 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. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + 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. However, any field with an // empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. @@ -8119,37 +7531,24 @@ type GoogleRpcStatus struct { NullFields []string `json:"-"` } -func (s *GoogleRpcStatus) MarshalJSON() ([]byte, error) { - type NoMethod GoogleRpcStatus +func (s *GoogleCloudDiscoveryengineV1betaPurgeDocumentsMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaPurgeDocumentsMetadata raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleTypeDate: Represents a whole or partial calendar date, such as -// a birthday. The time of day and time zone are either specified -// elsewhere or are insignificant. The date is relative to the Gregorian -// Calendar. This can represent one of the following: * A full date, -// with non-zero year, month, and day values. * A month and day, with a -// zero year (for example, an anniversary). * A year on its own, with a -// zero month and a zero day. * A year and month, with a zero day (for -// example, a credit card expiration date). Related types: * -// google.type.TimeOfDay * google.type.DateTime * -// google.protobuf.Timestamp -type GoogleTypeDate struct { - // Day: Day of a month. Must be from 1 to 31 and valid for the year and - // month, or 0 to specify a year by itself or a year and month where the - // day isn't significant. - Day int64 `json:"day,omitempty"` - - // Month: Month of a year. Must be from 1 to 12, or 0 to specify a year - // without a month and day. - Month int64 `json:"month,omitempty"` +// GoogleCloudDiscoveryengineV1betaPurgeDocumentsRequest: Request +// message for DocumentService.PurgeDocuments method. +type GoogleCloudDiscoveryengineV1betaPurgeDocumentsRequest struct { + // Filter: Required. Filter matching documents to purge. Only currently + // supported value is `*` (all items). + Filter string `json:"filter,omitempty"` - // Year: Year of the date. Must be from 1 to 9999, or 0 to specify a - // date without a year. - Year int64 `json:"year,omitempty"` + // Force: Actually performs the purge. If `force` is set to false, + // return the expected purge count without deleting any documents. + Force bool `json:"force,omitempty"` - // ForceSendFields is a list of field names (e.g. "Day") to + // ForceSendFields is a list of field names (e.g. "Filter") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -8157,7 +7556,7 @@ type GoogleTypeDate struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Day") to include in API + // NullFields is a list of field names (e.g. "Filter") to include in API // requests with the JSON null value. By default, fields with empty // values are omitted from API requests. However, any field with an // empty value appearing in NullFields will be sent to the server as @@ -8166,103 +7565,9500 @@ type GoogleTypeDate struct { NullFields []string `json:"-"` } -func (s *GoogleTypeDate) MarshalJSON() ([]byte, error) { - type NoMethod GoogleTypeDate - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +func (s *GoogleCloudDiscoveryengineV1betaPurgeDocumentsRequest) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaPurgeDocumentsRequest + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1betaPurgeDocumentsResponse: Response +// message for DocumentService.PurgeDocuments method. If the long +// running operation is successfully done, then this message is returned +// by the google.longrunning.Operations.response field. +type GoogleCloudDiscoveryengineV1betaPurgeDocumentsResponse struct { + // PurgeCount: The total count of documents purged as a result of the + // operation. + PurgeCount int64 `json:"purgeCount,omitempty,string"` + + // PurgeSample: A sample of document names that will be deleted. Only + // populated if `force` is set to false. A max of 100 names will be + // returned and the names are chosen at random. + PurgeSample []string `json:"purgeSample,omitempty"` + + // ForceSendFields is a list of field names (e.g. "PurgeCount") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "PurgeCount") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1betaPurgeDocumentsResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaPurgeDocumentsResponse + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1betaPurgeSuggestionDenyListEntriesMetadata +// : Metadata related to the progress of the +// PurgeSuggestionDenyListEntries operation. This is returned by the +// google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1betaPurgeSuggestionDenyListEntriesMetadata 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. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + 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. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1betaPurgeSuggestionDenyListEntriesMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaPurgeSuggestionDenyListEntriesMetadata + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1betaPurgeSuggestionDenyListEntriesRequest: +// +// Request message for CompletionService.PurgeSuggestionDenyListEntries +// +// method. +type GoogleCloudDiscoveryengineV1betaPurgeSuggestionDenyListEntriesRequest struct { +} + +// GoogleCloudDiscoveryengineV1betaPurgeSuggestionDenyListEntriesResponse +// : Response message for +// CompletionService.PurgeSuggestionDenyListEntries method. +type GoogleCloudDiscoveryengineV1betaPurgeSuggestionDenyListEntriesResponse struct { + // ErrorSamples: A sample of errors encountered while processing the + // request. + ErrorSamples []*GoogleRpcStatus `json:"errorSamples,omitempty"` + + // PurgeCount: Number of suggestion deny list entries purged. + PurgeCount int64 `json:"purgeCount,omitempty,string"` + + // ForceSendFields is a list of field names (e.g. "ErrorSamples") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "ErrorSamples") to include + // in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. However, any field with + // an empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1betaPurgeSuggestionDenyListEntriesResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaPurgeSuggestionDenyListEntriesResponse + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1betaRecommendRequest: Request message for +// Recommend method. +type GoogleCloudDiscoveryengineV1betaRecommendRequest struct { + // Filter: Filter for restricting recommendation results with a length + // limit of 5,000 characters. Currently, only filter expressions on the + // `filter_tags` attribute is supported. Examples: * `(filter_tags: + // ANY("Red", "Blue") OR filter_tags: ANY("Hot", "Cold"))` * + // `(filter_tags: ANY("Red", "Blue")) AND NOT (filter_tags: + // ANY("Green"))` If `attributeFilteringSyntax` is set to true under the + // `params` field, then attribute-based expressions are expected instead + // of the above described tag-based syntax. Examples: * (launguage: + // ANY("en", "es")) AND NOT (categories: ANY("Movie")) * (available: + // true) AND (launguage: ANY("en", "es")) OR (categories: ANY("Movie")) + // If your filter blocks all results, the API will return generic + // (unfiltered) popular Documents. If you only want results strictly + // matching the filters, set `strictFiltering` to True in + // RecommendRequest.params to receive empty results instead. Note that + // the API will never return Documents with `storageStatus` of `EXPIRED` + // or `DELETED` regardless of filter choices. + Filter string `json:"filter,omitempty"` + + // PageSize: Maximum number of results to return. Set this property to + // the number of recommendation results needed. If zero, the service + // will choose a reasonable default. The maximum allowed value is 100. + // Values above 100 will be coerced to 100. + PageSize int64 `json:"pageSize,omitempty"` + + // Params: Additional domain specific parameters for the + // recommendations. Allowed values: * `returnDocument`: Boolean. If set + // to true, the associated Document object will be returned in + // RecommendResponse.RecommendationResult.document. * `returnScore`: + // Boolean. If set to true, the recommendation 'score' corresponding to + // each returned Document will be set in + // RecommendResponse.RecommendationResult.metadata. The given 'score' + // indicates the probability of a Document conversion given the user's + // context and history. * `strictFiltering`: Boolean. True by default. + // If set to false, the service will return generic (unfiltered) popular + // Documents instead of empty if your filter blocks all recommendation + // results. * `diversityLevel`: String. Default empty. If set to be + // non-empty, then it needs to be one of: * `no-diversity` * + // `low-diversity` * `medium-diversity` * `high-diversity` * + // `auto-diversity` This gives request-level control and adjusts + // recommendation results based on Document category. * + // `attributeFilteringSyntax`: Boolean. False by default. If set to + // true, the `filter` field is interpreted according to the new, + // attribute-based syntax. + Params googleapi.RawMessage `json:"params,omitempty"` + + // UserEvent: Required. Context about the user, what they are looking at + // and what action they took to trigger the Recommend request. Note that + // this user event detail won't be ingested to userEvent logs. Thus, a + // separate userEvent write request is required for event logging. Don't + // set UserEvent.user_pseudo_id or UserEvent.user_info.user_id to the + // same fixed ID for different users. If you are trying to receive + // non-personalized recommendations (not recommended; this can + // negatively impact model performance), instead set + // UserEvent.user_pseudo_id to a random unique ID and leave + // UserEvent.user_info.user_id unset. + UserEvent *GoogleCloudDiscoveryengineV1betaUserEvent `json:"userEvent,omitempty"` + + // UserLabels: The user labels applied to a resource must meet the + // following requirements: * Each resource can have multiple labels, up + // to a maximum of 64. * Each label must be a key-value pair. * Keys + // have a minimum length of 1 character and a maximum length of 63 + // characters and cannot be empty. Values can be empty and have a + // maximum length of 63 characters. * Keys and values can contain only + // lowercase letters, numeric characters, underscores, and dashes. All + // characters must use UTF-8 encoding, and international characters are + // allowed. * The key portion of a label must be unique. However, you + // can use the same key with multiple resources. * Keys must start with + // a lowercase letter or international character. See Requirements for + // labels + // (https://cloud.google.com/resource-manager/docs/creating-managing-labels#requirements) + // for more details. + UserLabels map[string]string `json:"userLabels,omitempty"` + + // ValidateOnly: Use validate only mode for this recommendation query. + // If set to true, a fake model will be used that returns arbitrary + // Document IDs. Note that the validate only mode should only be used + // for testing the API, or if the model is not ready. + ValidateOnly bool `json:"validateOnly,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Filter") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "Filter") to include in API + // requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1betaRecommendRequest) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaRecommendRequest + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1betaRecommendResponse: Response message +// for Recommend method. +type GoogleCloudDiscoveryengineV1betaRecommendResponse struct { + // AttributionToken: A unique attribution token. This should be included + // in the UserEvent logs resulting from this recommendation, which + // enables accurate attribution of recommendation model performance. + AttributionToken string `json:"attributionToken,omitempty"` + + // MissingIds: IDs of documents in the request that were missing from + // the default Branch associated with the requested ServingConfig. + MissingIds []string `json:"missingIds,omitempty"` + + // Results: A list of recommended Documents. The order represents the + // ranking (from the most relevant Document to the least). + Results []*GoogleCloudDiscoveryengineV1betaRecommendResponseRecommendationResult `json:"results,omitempty"` + + // ValidateOnly: True if RecommendRequest.validate_only was set. + ValidateOnly bool `json:"validateOnly,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the + // server. + googleapi.ServerResponse `json:"-"` + + // 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. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + 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. However, any field + // with an empty value appearing in NullFields will be sent to the + // server as null. It is an error if a field in this list has a + // non-empty value. This may be used to include null fields in Patch + // requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1betaRecommendResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaRecommendResponse + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1betaRecommendResponseRecommendationResult: +// +// RecommendationResult represents a generic recommendation result with +// +// associated metadata. +type GoogleCloudDiscoveryengineV1betaRecommendResponseRecommendationResult struct { + // Document: Set if `returnDocument` is set to true in + // RecommendRequest.params. + Document *GoogleCloudDiscoveryengineV1betaDocument `json:"document,omitempty"` + + // Id: Resource ID of the recommended Document. + Id string `json:"id,omitempty"` + + // Metadata: Additional Document metadata / annotations. Possible + // values: * `score`: Recommendation score in double value. Is set if + // `returnScore` is set to true in RecommendRequest.params. + Metadata googleapi.RawMessage `json:"metadata,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Document") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "Document") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1betaRecommendResponseRecommendationResult) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaRecommendResponseRecommendationResult + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1betaRecrawlUrisRequest: Request message +// for SiteSearchEngineService.RecrawlUris method. +type GoogleCloudDiscoveryengineV1betaRecrawlUrisRequest struct { + // Uris: Required. List of URIs to crawl. At most 10K URIs are + // supported, otherwise an INVALID_ARGUMENT error is thrown. Each URI + // should match at least one TargetSite in `site_search_engine`. + Uris []string `json:"uris,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Uris") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "Uris") to include in API + // requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1betaRecrawlUrisRequest) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaRecrawlUrisRequest + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1betaReply: Defines a reply message to +// user. +type GoogleCloudDiscoveryengineV1betaReply struct { + // References: References in the reply. + References []*GoogleCloudDiscoveryengineV1betaReplyReference `json:"references,omitempty"` + + // Reply: DEPRECATED: use `summary` instead. Text reply. + Reply string `json:"reply,omitempty"` + + // Summary: Summary based on search results. + Summary *GoogleCloudDiscoveryengineV1betaSearchResponseSummary `json:"summary,omitempty"` + + // ForceSendFields is a list of field names (e.g. "References") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "References") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1betaReply) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaReply + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1betaReplyReference: Defines reference in +// reply. +type GoogleCloudDiscoveryengineV1betaReplyReference struct { + // AnchorText: Anchor text. + AnchorText string `json:"anchorText,omitempty"` + + // End: Anchor text end index. + End int64 `json:"end,omitempty"` + + // Start: Anchor text start index. + Start int64 `json:"start,omitempty"` + + // Uri: URI link reference. + Uri string `json:"uri,omitempty"` + + // ForceSendFields is a list of field names (e.g. "AnchorText") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "AnchorText") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1betaReplyReference) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaReplyReference + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1betaSchema: Defines the structure and +// layout of a type of document data. +type GoogleCloudDiscoveryengineV1betaSchema struct { + // JsonSchema: The JSON representation of the schema. + JsonSchema string `json:"jsonSchema,omitempty"` + + // Name: Immutable. The full resource name of the schema, in the format + // of + // `projects/{project}/locations/{location}/collections/{collection}/data + // Stores/{data_store}/schemas/{schema}`. This field must be a UTF-8 + // encoded string with a length limit of 1024 characters. + Name string `json:"name,omitempty"` + + // StructSchema: The structured representation of the schema. + StructSchema googleapi.RawMessage `json:"structSchema,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the + // server. + googleapi.ServerResponse `json:"-"` + + // ForceSendFields is a list of field names (e.g. "JsonSchema") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "JsonSchema") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1betaSchema) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaSchema + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1betaSearchInfo: Detailed search +// information. +type GoogleCloudDiscoveryengineV1betaSearchInfo struct { + // Offset: An integer that specifies the current offset for pagination + // (the 0-indexed starting location, amongst the products deemed by the + // API as relevant). See SearchRequest.offset for definition. If this + // field is negative, an `INVALID_ARGUMENT` is returned. This can only + // be set for `search` events. Other event types should not set this + // field. Otherwise, an `INVALID_ARGUMENT` error is returned. + Offset int64 `json:"offset,omitempty"` + + // OrderBy: The order in which products are returned, if applicable. See + // SearchRequest.order_by for definition and syntax. The value must be a + // UTF-8 encoded string with a length limit of 1,000 characters. + // Otherwise, an `INVALID_ARGUMENT` error is returned. This can only be + // set for `search` events. Other event types should not set this field. + // Otherwise, an `INVALID_ARGUMENT` error is returned. + OrderBy string `json:"orderBy,omitempty"` + + // SearchQuery: The user's search query. See SearchRequest.query for + // definition. The value must be a UTF-8 encoded string with a length + // limit of 5,000 characters. Otherwise, an `INVALID_ARGUMENT` error is + // returned. At least one of search_query or PageInfo.page_category is + // required for `search` events. Other event types should not set this + // field. Otherwise, an `INVALID_ARGUMENT` error is returned. + SearchQuery string `json:"searchQuery,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Offset") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "Offset") to include in API + // requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1betaSearchInfo) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaSearchInfo + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1betaSearchRequest: Request message for +// SearchService.Search method. +type GoogleCloudDiscoveryengineV1betaSearchRequest struct { + // BoostSpec: Boost specification to boost certain documents. For more + // information on boosting, see Boosting + // (https://cloud.google.com/retail/docs/boosting#boost) + BoostSpec *GoogleCloudDiscoveryengineV1betaSearchRequestBoostSpec `json:"boostSpec,omitempty"` + + // Branch: The branch resource name, such as + // `projects/*/locations/global/collections/default_collection/dataStores + // /default_data_store/branches/0`. Use `default_branch` as the branch + // ID or leave this field empty, to search documents under the default + // branch. + Branch string `json:"branch,omitempty"` + + // CanonicalFilter: The default filter that is applied when a user + // performs a search without checking any filters on the search page. + // The filter applied to every search request when quality improvement + // such as query expansion is needed. In the case a query does not have + // a sufficient amount of results this filter will be used to determine + // whether or not to enable the query expansion flow. The original + // filter will still be used for the query expanded search. This field + // is strongly recommended to achieve high search quality. For more + // information about filter syntax, see SearchRequest.filter. + CanonicalFilter string `json:"canonicalFilter,omitempty"` + + // ContentSearchSpec: A specification for configuring the behavior of + // content search. + ContentSearchSpec *GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpec `json:"contentSearchSpec,omitempty"` + + // EmbeddingSpec: Uses the provided embedding to do additional semantic + // document retrieval. The retrieval is based on the dot product of + // SearchRequest.EmbeddingSpec.EmbeddingVector.vector and the document + // embedding that is provided in + // SearchRequest.EmbeddingSpec.EmbeddingVector.field_path. If + // SearchRequest.EmbeddingSpec.EmbeddingVector.field_path is not + // provided, it will use ServingConfig.EmbeddingConfig.field_paths. + EmbeddingSpec *GoogleCloudDiscoveryengineV1betaSearchRequestEmbeddingSpec `json:"embeddingSpec,omitempty"` + + // FacetSpecs: Facet specifications for faceted search. If empty, no + // facets are returned. A maximum of 100 values are allowed. Otherwise, + // an `INVALID_ARGUMENT` error is returned. + FacetSpecs []*GoogleCloudDiscoveryengineV1betaSearchRequestFacetSpec `json:"facetSpecs,omitempty"` + + // Filter: 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 --> 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) + Filter string `json:"filter,omitempty"` + + // ImageQuery: Raw image query. + ImageQuery *GoogleCloudDiscoveryengineV1betaSearchRequestImageQuery `json:"imageQuery,omitempty"` + + // Offset: 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. + Offset int64 `json:"offset,omitempty"` + + // OrderBy: The order in which documents are returned. Documents can be + // ordered by a field in an Document object. Leave it unset if ordered + // by relevance. `order_by` expression is case-sensitive. For more + // information on ordering, see Ordering + // (https://cloud.google.com/retail/docs/filter-and-order#order) If this + // field is unrecognizable, an `INVALID_ARGUMENT` is returned. + OrderBy string `json:"orderBy,omitempty"` + + // PageSize: Maximum number of Documents to return. If unspecified, + // defaults to a reasonable value. The maximum allowed value is 100. + // Values above 100 are coerced to 100. If this field is negative, an + // `INVALID_ARGUMENT` is returned. + PageSize int64 `json:"pageSize,omitempty"` + + // PageToken: A page token received from a previous SearchService.Search + // call. Provide this to retrieve the subsequent page. When paginating, + // all other parameters provided to SearchService.Search must match the + // call that provided the page token. Otherwise, an `INVALID_ARGUMENT` + // error is returned. + PageToken string `json:"pageToken,omitempty"` + + // Params: Additional search parameters. For public website search only, + // supported values are: * `user_country_code`: string. Default empty. + // If set to non-empty, results are restricted or boosted based on the + // location provided. Example: user_country_code: "au" For available + // codes see Country Codes + // (https://developers.google.com/custom-search/docs/json_api_reference#countryCodes) + // * `search_type`: double. Default empty. Enables non-webpage searching + // depending on the value. The only valid non-default value is 1, which + // enables image searching. Example: search_type: 1 + Params googleapi.RawMessage `json:"params,omitempty"` + + // Query: Raw search query. + Query string `json:"query,omitempty"` + + // QueryExpansionSpec: The query expansion specification that specifies + // the conditions under which query expansion occurs. + QueryExpansionSpec *GoogleCloudDiscoveryengineV1betaSearchRequestQueryExpansionSpec `json:"queryExpansionSpec,omitempty"` + + // RankingExpression: The ranking expression controls the customized + // ranking on retrieval documents. This overrides + // ServingConfig.ranking_expression. The ranking expression is a single + // function or multiple functions that are joint by "+". * + // ranking_expression = function, { " + ", function }; Supported + // functions: * double * relevance_score * double * + // dotProduct(embedding_field_path) Function variables: + // `relevance_score`: pre-defined keywords, used for measure relevance + // between query and document. `embedding_field_path`: the document + // embedding field used with query embedding vector. `dotProduct`: + // embedding function between embedding_field_path and query embedding + // vector. Example ranking expression: If document has an embedding + // field doc_embedding, the ranking expression could be `0.5 * + // relevance_score + 0.3 * dotProduct(doc_embedding)`. + RankingExpression string `json:"rankingExpression,omitempty"` + + // SafeSearch: Whether to turn on safe search. This is only supported + // for website search. + SafeSearch bool `json:"safeSearch,omitempty"` + + // SpellCorrectionSpec: The spell correction specification that + // specifies the mode under which spell correction takes effect. + SpellCorrectionSpec *GoogleCloudDiscoveryengineV1betaSearchRequestSpellCorrectionSpec `json:"spellCorrectionSpec,omitempty"` + + // UserInfo: Information about the end user. Highly recommended for + // analytics. UserInfo.user_agent is used to deduce `device_type` for + // analytics. + UserInfo *GoogleCloudDiscoveryengineV1betaUserInfo `json:"userInfo,omitempty"` + + // UserLabels: The user labels applied to a resource must meet the + // following requirements: * Each resource can have multiple labels, up + // to a maximum of 64. * Each label must be a key-value pair. * Keys + // have a minimum length of 1 character and a maximum length of 63 + // characters and cannot be empty. Values can be empty and have a + // maximum length of 63 characters. * Keys and values can contain only + // lowercase letters, numeric characters, underscores, and dashes. All + // characters must use UTF-8 encoding, and international characters are + // allowed. * The key portion of a label must be unique. However, you + // can use the same key with multiple resources. * Keys must start with + // a lowercase letter or international character. See Google Cloud + // Document + // (https://cloud.google.com/resource-manager/docs/creating-managing-labels#requirements) + // for more details. + UserLabels map[string]string `json:"userLabels,omitempty"` + + // UserPseudoId: A unique identifier for tracking visitors. For example, + // this could be implemented with an HTTP cookie, which should be able + // to uniquely identify a visitor on a single device. This unique + // identifier should not change if the visitor logs in or out of the + // website. This field should NOT have a fixed value such as + // `unknown_visitor`. This should be the same identifier as + // UserEvent.user_pseudo_id and CompleteQueryRequest.user_pseudo_id The + // field must be a UTF-8 encoded string with a length limit of 128 + // characters. Otherwise, an `INVALID_ARGUMENT` error is returned. + UserPseudoId string `json:"userPseudoId,omitempty"` + + // ForceSendFields is a list of field names (e.g. "BoostSpec") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "BoostSpec") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1betaSearchRequest) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaSearchRequest + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1betaSearchRequestBoostSpec: Boost +// specification to boost certain documents. +type GoogleCloudDiscoveryengineV1betaSearchRequestBoostSpec struct { + // ConditionBoostSpecs: Condition boost specifications. If a document + // matches multiple conditions in the specifictions, boost scores from + // these specifications are all applied and combined in a non-linear + // way. Maximum number of specifications is 20. + ConditionBoostSpecs []*GoogleCloudDiscoveryengineV1betaSearchRequestBoostSpecConditionBoostSpec `json:"conditionBoostSpecs,omitempty"` + + // ForceSendFields is a list of field names (e.g. "ConditionBoostSpecs") + // to unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "ConditionBoostSpecs") to + // include in API requests with the JSON null value. By default, fields + // with empty values are omitted from API requests. However, any field + // with an empty value appearing in NullFields will be sent to the + // server as null. It is an error if a field in this list has a + // non-empty value. This may be used to include null fields in Patch + // requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1betaSearchRequestBoostSpec) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaSearchRequestBoostSpec + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1betaSearchRequestBoostSpecConditionBoostSp +// ec: Boost applies to documents which match a condition. +type GoogleCloudDiscoveryengineV1betaSearchRequestBoostSpecConditionBoostSpec struct { + // Boost: Strength of the condition boost, which should be in [-1, 1]. + // Negative boost means demotion. Default is 0.0. Setting to 1.0 gives + // the document a big promotion. However, it does not necessarily mean + // that the boosted document will be the top result at all times, nor + // that other documents will be excluded. Results could still be shown + // even when none of them matches the condition. And results that are + // significantly more relevant to the search query can still trump your + // heavily favored but irrelevant documents. Setting to -1.0 gives the + // document a big demotion. However, results that are deeply relevant + // might still be shown. The document will have an upstream battle to + // get a fairly high ranking, but it is not blocked out completely. + // Setting to 0.0 means no boost applied. The boosting condition is + // ignored. + Boost float64 `json:"boost,omitempty"` + + // Condition: An expression which specifies a boost condition. The + // syntax and supported fields are the same as a filter expression. See + // SearchRequest.filter for detail syntax and limitations. Examples: * + // To boost documents with document ID "doc_1" or "doc_2", and color + // "Red" or "Blue": * (id: ANY("doc_1", "doc_2")) AND (color: + // ANY("Red","Blue")) + Condition string `json:"condition,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Boost") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "Boost") to include in API + // requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1betaSearchRequestBoostSpecConditionBoostSpec) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaSearchRequestBoostSpecConditionBoostSpec + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +func (s *GoogleCloudDiscoveryengineV1betaSearchRequestBoostSpecConditionBoostSpec) UnmarshalJSON(data []byte) error { + type NoMethod GoogleCloudDiscoveryengineV1betaSearchRequestBoostSpecConditionBoostSpec + var s1 struct { + Boost gensupport.JSONFloat64 `json:"boost"` + *NoMethod + } + s1.NoMethod = (*NoMethod)(s) + if err := json.Unmarshal(data, &s1); err != nil { + return err + } + s.Boost = float64(s1.Boost) + return nil +} + +// GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpec: A +// specification for configuring the behavior of content search. +type GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpec struct { + // ExtractiveContentSpec: If there is no extractive_content_spec + // provided, there will be no extractive answer in the search response. + ExtractiveContentSpec *GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecExtractiveContentSpec `json:"extractiveContentSpec,omitempty"` + + // SnippetSpec: If `snippetSpec` is not specified, snippets are not + // included in the search response. + SnippetSpec *GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecSnippetSpec `json:"snippetSpec,omitempty"` + + // SummarySpec: If `summarySpec` is not specified, summaries are not + // included in the search response. + SummarySpec *GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecSummarySpec `json:"summarySpec,omitempty"` + + // ForceSendFields is a list of field names (e.g. + // "ExtractiveContentSpec") to unconditionally include in API requests. + // By default, fields with empty or default values are omitted from API + // requests. However, any non-pointer, non-interface field appearing in + // ForceSendFields will be sent to the server regardless of whether the + // field is empty or not. This may be used to include empty fields in + // Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "ExtractiveContentSpec") to + // include in API requests with the JSON null value. By default, fields + // with empty values are omitted from API requests. However, any field + // with an empty value appearing in NullFields will be sent to the + // server as null. It is an error if a field in this list has a + // non-empty value. This may be used to include null fields in Patch + // requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpec) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpec + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecExtracti +// veContentSpec: A specification for configuring the extractive content +// in a search response. +type GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecExtractiveContentSpec struct { + // MaxExtractiveAnswerCount: The maximum number of extractive answers + // returned in each search result. An extractive answer is a verbatim + // answer extracted from the original document, which provides a precise + // and contextually relevant answer to the search query. If the number + // of matching answers is less than the `max_extractive_answer_count`, + // return all of the answers. Otherwise, return the + // `max_extractive_answer_count`. At most five answers are returned for + // each SearchResult. + MaxExtractiveAnswerCount int64 `json:"maxExtractiveAnswerCount,omitempty"` + + // MaxExtractiveSegmentCount: The max number of extractive segments + // returned in each search result. Only applied if the DataStore is set + // to DataStore.ContentConfig.CONTENT_REQUIRED or + // DataStore.solution_types is SOLUTION_TYPE_CHAT. An extractive segment + // is a text segment extracted from the original document that is + // relevant to the search query, and, in general, more verbose than an + // extractive answer. The segment could then be used as input for LLMs + // to generate summaries and answers. If the number of matching segments + // is less than `max_extractive_segment_count`, return all of the + // segments. Otherwise, return the `max_extractive_segment_count`. + MaxExtractiveSegmentCount int64 `json:"maxExtractiveSegmentCount,omitempty"` + + // NumNextSegments: Return at most `num_next_segments` segments after + // each selected segments. + NumNextSegments int64 `json:"numNextSegments,omitempty"` + + // NumPreviousSegments: Specifies whether to also include the adjacent + // from each selected segments. Return at most `num_previous_segments` + // segments before each selected segments. + NumPreviousSegments int64 `json:"numPreviousSegments,omitempty"` + + // ForceSendFields is a list of field names (e.g. + // "MaxExtractiveAnswerCount") to unconditionally include in API + // requests. By default, fields with empty or default values are omitted + // from API requests. However, any non-pointer, non-interface field + // appearing in ForceSendFields will be sent to the server regardless of + // whether the field is empty or not. This may be used to include empty + // fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "MaxExtractiveAnswerCount") + // to include in API requests with the JSON null value. By default, + // fields with empty values are omitted from API requests. However, any + // field with an empty value appearing in NullFields will be sent to the + // server as null. It is an error if a field in this list has a + // non-empty value. This may be used to include null fields in Patch + // requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecExtractiveContentSpec) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecExtractiveContentSpec + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecSnippetS +// pec: A specification for configuring snippets in a search response. +type GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecSnippetSpec struct { + // MaxSnippetCount: [DEPRECATED] This field is deprecated. To control + // snippet return, use `return_snippet` field. For backwards + // compatibility, we will return snippet if max_snippet_count > 0. + MaxSnippetCount int64 `json:"maxSnippetCount,omitempty"` + + // ReferenceOnly: [DEPRECATED] This field is deprecated and will have no + // affect on the snippet. + ReferenceOnly bool `json:"referenceOnly,omitempty"` + + // ReturnSnippet: If `true`, then return snippet. If no snippet can be + // generated, we return "No snippet is available for this page." A + // `snippet_status` with `SUCCESS` or `NO_SNIPPET_AVAILABLE` will also + // be returned. + ReturnSnippet bool `json:"returnSnippet,omitempty"` + + // ForceSendFields is a list of field names (e.g. "MaxSnippetCount") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "MaxSnippetCount") to + // include in API requests with the JSON null value. By default, fields + // with empty values are omitted from API requests. However, any field + // with an empty value appearing in NullFields will be sent to the + // server as null. It is an error if a field in this list has a + // non-empty value. This may be used to include null fields in Patch + // requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecSnippetSpec) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecSnippetSpec + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecSummaryS +// pec: A specification for configuring a summary returned in a search +// response. +type GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecSummarySpec struct { + // IgnoreAdversarialQuery: Specifies whether to filter out adversarial + // queries. The default value is `false`. Google employs search-query + // classification to detect adversarial queries. No summary is returned + // if the search query is classified as an adversarial query. For + // example, a user might ask a question regarding negative comments + // about the company or submit a query designed to generate unsafe, + // policy-violating output. If this field is set to `true`, we skip + // generating summaries for adversarial queries and return fallback + // messages instead. + IgnoreAdversarialQuery bool `json:"ignoreAdversarialQuery,omitempty"` + + // IgnoreNonSummarySeekingQuery: Specifies whether to filter out queries + // that are not summary-seeking. The default value is `false`. Google + // employs search-query classification to detect summary-seeking + // queries. No summary is returned if the search query is classified as + // a non-summary seeking query. For example, `why is the sky blue` and + // `Who is the best soccer player in the world?` are summary-seeking + // queries, but `SFO airport` and `world cup 2026` are not. They are + // most likely navigational queries. If this field is set to `true`, we + // skip generating summaries for non-summary seeking queries and return + // fallback messages instead. + IgnoreNonSummarySeekingQuery bool `json:"ignoreNonSummarySeekingQuery,omitempty"` + + // IncludeCitations: Specifies whether to include citations in the + // summary. The default value is `false`. When this field is set to + // `true`, summaries include in-line citation numbers. Example summary + // including citations: BigQuery is Google Cloud's fully managed and + // completely serverless enterprise data warehouse [1]. BigQuery + // supports all data types, works across clouds, and has built-in + // machine learning and business intelligence, all within a unified + // platform [2, 3]. The citation numbers refer to the returned search + // results and are 1-indexed. For example, [1] means that the sentence + // is attributed to the first search result. [2, 3] means that the + // sentence is attributed to both the second and third search results. + IncludeCitations bool `json:"includeCitations,omitempty"` + + // LanguageCode: Language code for Summary. Use language tags defined by + // BCP47 (https://www.rfc-editor.org/rfc/bcp/bcp47.txt). Note: This is + // an experimental feature. + LanguageCode string `json:"languageCode,omitempty"` + + // ModelPromptSpec: If specified, the spec will be used to modify the + // prompt provided to the LLM. + ModelPromptSpec *GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecSummarySpecModelPromptSpec `json:"modelPromptSpec,omitempty"` + + // ModelSpec: If specified, the spec will be used to modify the model + // specification provided to the LLM. + ModelSpec *GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecSummarySpecModelSpec `json:"modelSpec,omitempty"` + + // SummaryResultCount: The number of top results to generate the summary + // from. If the number of results returned is less than + // `summaryResultCount`, the summary is generated from all of the + // results. At most five results can be used to generate a summary. + SummaryResultCount int64 `json:"summaryResultCount,omitempty"` + + // ForceSendFields is a list of field names (e.g. + // "IgnoreAdversarialQuery") to unconditionally include in API requests. + // By default, fields with empty or default values are omitted from API + // requests. However, any non-pointer, non-interface field appearing in + // ForceSendFields will be sent to the server regardless of whether the + // field is empty or not. This may be used to include empty fields in + // Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "IgnoreAdversarialQuery") + // to include in API requests with the JSON null value. By default, + // fields with empty values are omitted from API requests. However, any + // field with an empty value appearing in NullFields will be sent to the + // server as null. It is an error if a field in this list has a + // non-empty value. This may be used to include null fields in Patch + // requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecSummarySpec) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecSummarySpec + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecSummaryS +// pecModelPromptSpec: Specification of the prompt to use with the +// model. +type GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecSummarySpecModelPromptSpec struct { + // Preamble: Text at the beginning of the prompt that instructs the + // assistant. Examples are available in the user guide. + Preamble string `json:"preamble,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Preamble") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "Preamble") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecSummarySpecModelPromptSpec) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecSummarySpecModelPromptSpec + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecSummaryS +// pecModelSpec: Specification of the model. +type GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecSummarySpecModelSpec struct { + // Version: The model version used to generate the summary. Supported + // values are: * `stable`: string. Default value when no value is + // specified. Uses a generally available, fine-tuned version of the + // text-bison@001 model. * `preview`: string. (Public preview) Uses a + // fine-tuned version of the text-bison@002 model. This model works only + // for summaries in English. + 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. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + 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. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecSummarySpecModelSpec) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecSummarySpecModelSpec + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1betaSearchRequestEmbeddingSpec: The +// specification that uses customized query embedding vector to do +// semantic document retrieval. +type GoogleCloudDiscoveryengineV1betaSearchRequestEmbeddingSpec struct { + // EmbeddingVectors: The embedding vector used for retrieval. Limit to + // 1. + EmbeddingVectors []*GoogleCloudDiscoveryengineV1betaSearchRequestEmbeddingSpecEmbeddingVector `json:"embeddingVectors,omitempty"` + + // ForceSendFields is a list of field names (e.g. "EmbeddingVectors") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "EmbeddingVectors") to + // include in API requests with the JSON null value. By default, fields + // with empty values are omitted from API requests. However, any field + // with an empty value appearing in NullFields will be sent to the + // server as null. It is an error if a field in this list has a + // non-empty value. This may be used to include null fields in Patch + // requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1betaSearchRequestEmbeddingSpec) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaSearchRequestEmbeddingSpec + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1betaSearchRequestEmbeddingSpecEmbeddingVec +// tor: Embedding vector. +type GoogleCloudDiscoveryengineV1betaSearchRequestEmbeddingSpecEmbeddingVector struct { + // FieldPath: Embedding field path in schema. + FieldPath string `json:"fieldPath,omitempty"` + + // Vector: Query embedding vector. + Vector []float64 `json:"vector,omitempty"` + + // ForceSendFields is a list of field names (e.g. "FieldPath") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "FieldPath") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1betaSearchRequestEmbeddingSpecEmbeddingVector) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaSearchRequestEmbeddingSpecEmbeddingVector + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +func (s *GoogleCloudDiscoveryengineV1betaSearchRequestEmbeddingSpecEmbeddingVector) UnmarshalJSON(data []byte) error { + type NoMethod GoogleCloudDiscoveryengineV1betaSearchRequestEmbeddingSpecEmbeddingVector + var s1 struct { + Vector []gensupport.JSONFloat64 `json:"vector"` + *NoMethod + } + s1.NoMethod = (*NoMethod)(s) + if err := json.Unmarshal(data, &s1); err != nil { + return err + } + s.Vector = make([]float64, len(s1.Vector)) + for i := range s1.Vector { + s.Vector[i] = float64(s1.Vector[i]) + } + return nil +} + +// GoogleCloudDiscoveryengineV1betaSearchRequestFacetSpec: A facet +// specification to perform faceted search. +type GoogleCloudDiscoveryengineV1betaSearchRequestFacetSpec struct { + // EnableDynamicPosition: Enables dynamic position for this facet. If + // set to true, the position of this facet among all facets in the + // response is determined automatically. If dynamic facets are enabled, + // it is ordered together. If set to false, the position of this facet + // in the response is the same as in the request, and it is ranked + // before the facets with dynamic position enable and all dynamic + // facets. For example, you may always want to have rating facet + // returned in the response, but it's not necessarily to always display + // the rating facet at the top. In that case, you can set + // enable_dynamic_position to true so that the position of rating facet + // in response is determined automatically. Another example, assuming + // you have the following facets in the request: * "rating", + // enable_dynamic_position = true * "price", enable_dynamic_position = + // false * "brands", enable_dynamic_position = false And also you have a + // dynamic facets enabled, which generates a facet `gender`. Then the + // final order of the facets in the response can be ("price", "brands", + // "rating", "gender") or ("price", "brands", "gender", "rating") + // depends on how API orders "gender" and "rating" facets. However, + // notice that "price" and "brands" are always ranked at first and + // second position because their enable_dynamic_position is false. + EnableDynamicPosition bool `json:"enableDynamicPosition,omitempty"` + + // ExcludedFilterKeys: List of keys to exclude when faceting. By + // default, FacetKey.key is not excluded from the filter unless it is + // listed in this field. Listing a facet key in this field allows its + // values to appear as facet results, even when they are filtered out of + // search results. Using this field does not affect what search results + // are returned. For example, suppose there are 100 documents with the + // color facet "Red" and 200 documents with the color facet "Blue". A + // query containing the filter "color:ANY("Red")" and having "color" as + // FacetKey.key would by default return only "Red" documents in the + // search results, and also return "Red" with count 100 as the only + // color facet. Although there are also blue documents available, "Blue" + // would not be shown as an available facet value. If "color" is listed + // in "excludedFilterKeys", then the query returns the facet values + // "Red" with count 100 and "Blue" with count 200, because the "color" + // key is now excluded from the filter. Because this field doesn't + // affect search results, the search results are still correctly + // filtered to return only "Red" documents. A maximum of 100 values are + // allowed. Otherwise, an `INVALID_ARGUMENT` error is returned. + ExcludedFilterKeys []string `json:"excludedFilterKeys,omitempty"` + + // FacetKey: Required. The facet key specification. + FacetKey *GoogleCloudDiscoveryengineV1betaSearchRequestFacetSpecFacetKey `json:"facetKey,omitempty"` + + // Limit: Maximum of facet values that should be returned for this + // facet. If unspecified, defaults to 20. The maximum allowed value is + // 300. Values above 300 are coerced to 300. If this field is negative, + // an `INVALID_ARGUMENT` is returned. + Limit int64 `json:"limit,omitempty"` + + // ForceSendFields is a list of field names (e.g. + // "EnableDynamicPosition") to unconditionally include in API requests. + // By default, fields with empty or default values are omitted from API + // requests. However, any non-pointer, non-interface field appearing in + // ForceSendFields will be sent to the server regardless of whether the + // field is empty or not. This may be used to include empty fields in + // Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "EnableDynamicPosition") to + // include in API requests with the JSON null value. By default, fields + // with empty values are omitted from API requests. However, any field + // with an empty value appearing in NullFields will be sent to the + // server as null. It is an error if a field in this list has a + // non-empty value. This may be used to include null fields in Patch + // requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1betaSearchRequestFacetSpec) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaSearchRequestFacetSpec + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1betaSearchRequestFacetSpecFacetKey: +// Specifies how a facet is computed. +type GoogleCloudDiscoveryengineV1betaSearchRequestFacetSpecFacetKey struct { + // CaseInsensitive: True to make facet keys case insensitive when + // getting faceting values with prefixes or contains; false otherwise. + CaseInsensitive bool `json:"caseInsensitive,omitempty"` + + // Contains: Only get facet values that contains the given strings. For + // example, suppose "category" has three values "Action > 2022", "Action + // > 2021" and "Sci-Fi > 2022". If set "contains" to "2022", the + // "category" facet only contains "Action > 2022" and "Sci-Fi > 2022". + // Only supported on textual fields. Maximum is 10. + Contains []string `json:"contains,omitempty"` + + // Intervals: Set only if values should be bucketed into intervals. Must + // be set for facets with numerical values. Must not be set for facet + // with text values. Maximum number of intervals is 30. + Intervals []*GoogleCloudDiscoveryengineV1betaInterval `json:"intervals,omitempty"` + + // Key: Required. Supported textual and numerical facet keys in Document + // object, over which the facet values are computed. Facet key is + // case-sensitive. + Key string `json:"key,omitempty"` + + // OrderBy: The order in which documents are returned. Allowed values + // are: * "count desc", which means order by + // SearchResponse.Facet.values.count descending. * "value desc", which + // means order by SearchResponse.Facet.values.value descending. Only + // applies to textual facets. If not set, textual values are sorted in + // natural order (https://en.wikipedia.org/wiki/Natural_sort_order); + // numerical intervals are sorted in the order given by + // FacetSpec.FacetKey.intervals. + OrderBy string `json:"orderBy,omitempty"` + + // Prefixes: Only get facet values that start with the given string + // prefix. For example, suppose "category" has three values "Action > + // 2022", "Action > 2021" and "Sci-Fi > 2022". If set "prefixes" to + // "Action", the "category" facet only contains "Action > 2022" and + // "Action > 2021". Only supported on textual fields. Maximum is 10. + Prefixes []string `json:"prefixes,omitempty"` + + // RestrictedValues: Only get facet for the given restricted values. + // Only supported on textual fields. For example, suppose "category" has + // three values "Action > 2022", "Action > 2021" and "Sci-Fi > 2022". If + // set "restricted_values" to "Action > 2022", the "category" facet only + // contains "Action > 2022". Only supported on textual fields. Maximum + // is 10. + RestrictedValues []string `json:"restrictedValues,omitempty"` + + // ForceSendFields is a list of field names (e.g. "CaseInsensitive") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "CaseInsensitive") to + // include in API requests with the JSON null value. By default, fields + // with empty values are omitted from API requests. However, any field + // with an empty value appearing in NullFields will be sent to the + // server as null. It is an error if a field in this list has a + // non-empty value. This may be used to include null fields in Patch + // requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1betaSearchRequestFacetSpecFacetKey) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaSearchRequestFacetSpecFacetKey + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1betaSearchRequestImageQuery: Specifies +// the image query input. +type GoogleCloudDiscoveryengineV1betaSearchRequestImageQuery struct { + // ImageBytes: Base64 encoded image bytes. Supported image formats: + // JPEG, PNG, and BMP. + ImageBytes string `json:"imageBytes,omitempty"` + + // ForceSendFields is a list of field names (e.g. "ImageBytes") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "ImageBytes") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1betaSearchRequestImageQuery) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaSearchRequestImageQuery + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1betaSearchRequestQueryExpansionSpec: +// Specification to determine under which conditions query expansion +// should occur. +type GoogleCloudDiscoveryengineV1betaSearchRequestQueryExpansionSpec struct { + // Condition: The condition under which query expansion should occur. + // Default to Condition.DISABLED. + // + // Possible values: + // "CONDITION_UNSPECIFIED" - Unspecified query expansion condition. In + // this case, server behavior defaults to Condition.DISABLED. + // "DISABLED" - Disabled query expansion. Only the exact search query + // is used, even if SearchResponse.total_size is zero. + // "AUTO" - Automatic query expansion built by the Search API. + Condition string `json:"condition,omitempty"` + + // PinUnexpandedResults: Whether to pin unexpanded results. If this + // field is set to true, unexpanded products are always at the top of + // the search results, followed by the expanded results. + PinUnexpandedResults bool `json:"pinUnexpandedResults,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Condition") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "Condition") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1betaSearchRequestQueryExpansionSpec) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaSearchRequestQueryExpansionSpec + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1betaSearchRequestSpellCorrectionSpec: The +// specification for query spell correction. +type GoogleCloudDiscoveryengineV1betaSearchRequestSpellCorrectionSpec struct { + // Mode: The mode under which spell correction should take effect to + // replace the original search query. Default to Mode.AUTO. + // + // Possible values: + // "MODE_UNSPECIFIED" - Unspecified spell correction mode. In this + // case, server behavior defaults to Mode.AUTO. + // "SUGGESTION_ONLY" - Search API will try to find a spell suggestion + // if there is any and put in the SearchResponse.corrected_query. The + // spell suggestion will not be used as the search query. + // "AUTO" - Automatic spell correction built by the Search API. Search + // will be based on the corrected query if found. + Mode string `json:"mode,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Mode") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "Mode") to include in API + // requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1betaSearchRequestSpellCorrectionSpec) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaSearchRequestSpellCorrectionSpec + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1betaSearchResponse: Response message for +// SearchService.Search method. +type GoogleCloudDiscoveryengineV1betaSearchResponse struct { + // AppliedControls: Controls applied as part of the Control service. + AppliedControls []string `json:"appliedControls,omitempty"` + + // AttributionToken: A unique search token. This should be included in + // the UserEvent logs resulting from this search, which enables accurate + // attribution of search model performance. + AttributionToken string `json:"attributionToken,omitempty"` + + // CorrectedQuery: Contains the spell corrected query, if found. If the + // spell correction type is AUTOMATIC, then the search results are based + // on corrected_query. Otherwise the original query is used for search. + CorrectedQuery string `json:"correctedQuery,omitempty"` + + // Facets: Results of facets requested by user. + Facets []*GoogleCloudDiscoveryengineV1betaSearchResponseFacet `json:"facets,omitempty"` + + GeoSearchDebugInfo []*GoogleCloudDiscoveryengineV1betaSearchResponseGeoSearchDebugInfo `json:"geoSearchDebugInfo,omitempty"` + + // GuidedSearchResult: Guided search result. + GuidedSearchResult *GoogleCloudDiscoveryengineV1betaSearchResponseGuidedSearchResult `json:"guidedSearchResult,omitempty"` + + // NextPageToken: A token that can be sent as SearchRequest.page_token + // to retrieve the next page. If this field is omitted, there are no + // subsequent pages. + NextPageToken string `json:"nextPageToken,omitempty"` + + // QueryExpansionInfo: Query expansion information for the returned + // results. + QueryExpansionInfo *GoogleCloudDiscoveryengineV1betaSearchResponseQueryExpansionInfo `json:"queryExpansionInfo,omitempty"` + + // RedirectUri: The URI of a customer-defined redirect page. If redirect + // action is triggered, no search is performed, and only redirect_uri + // and attribution_token are set in the response. + RedirectUri string `json:"redirectUri,omitempty"` + + // Results: A list of matched documents. The order represents the + // ranking. + Results []*GoogleCloudDiscoveryengineV1betaSearchResponseSearchResult `json:"results,omitempty"` + + // Summary: A summary as part of the search results. This field is only + // returned if SearchRequest.ContentSearchSpec.summary_spec is set. + Summary *GoogleCloudDiscoveryengineV1betaSearchResponseSummary `json:"summary,omitempty"` + + // TotalSize: The estimated total count of matched items irrespective of + // pagination. The count of results returned by pagination may be less + // than the total_size that matches. + TotalSize int64 `json:"totalSize,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the + // server. + googleapi.ServerResponse `json:"-"` + + // ForceSendFields is a list of field names (e.g. "AppliedControls") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "AppliedControls") to + // include in API requests with the JSON null value. By default, fields + // with empty values are omitted from API requests. However, any field + // with an empty value appearing in NullFields will be sent to the + // server as null. It is an error if a field in this list has a + // non-empty value. This may be used to include null fields in Patch + // requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1betaSearchResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaSearchResponse + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1betaSearchResponseFacet: A facet result. +type GoogleCloudDiscoveryengineV1betaSearchResponseFacet struct { + // DynamicFacet: Whether the facet is dynamically generated. + DynamicFacet bool `json:"dynamicFacet,omitempty"` + + // Key: The key for this facet. E.g., "colors" or "price". It matches + // SearchRequest.FacetSpec.FacetKey.key. + Key string `json:"key,omitempty"` + + // Values: The facet values for this field. + Values []*GoogleCloudDiscoveryengineV1betaSearchResponseFacetFacetValue `json:"values,omitempty"` + + // ForceSendFields is a list of field names (e.g. "DynamicFacet") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "DynamicFacet") to include + // in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. However, any field with + // an empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1betaSearchResponseFacet) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaSearchResponseFacet + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1betaSearchResponseFacetFacetValue: A +// facet value which contains value names and their count. +type GoogleCloudDiscoveryengineV1betaSearchResponseFacetFacetValue struct { + // Count: Number of items that have this facet value. + Count int64 `json:"count,omitempty,string"` + + // Interval: Interval value for a facet, such as 10, 20) for facet + // "price". It matches [SearchRequest.FacetSpec.FacetKey.intervals. + Interval *GoogleCloudDiscoveryengineV1betaInterval `json:"interval,omitempty"` + + // Value: Text value of a facet, such as "Black" for facet "colors". + Value string `json:"value,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Count") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "Count") to include in API + // requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1betaSearchResponseFacetFacetValue) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaSearchResponseFacetFacetValue + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1betaSearchResponseGeoSearchDebugInfo: +// Debug information specifically related to forward geocoding issues +// arising from Geolocation Search. +type GoogleCloudDiscoveryengineV1betaSearchResponseGeoSearchDebugInfo struct { + // ErrorMessage: The error produced. + ErrorMessage string `json:"errorMessage,omitempty"` + + // OriginalAddressQuery: The address from which forward geocoding + // ingestion produced issues. + OriginalAddressQuery string `json:"originalAddressQuery,omitempty"` + + // ForceSendFields is a list of field names (e.g. "ErrorMessage") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "ErrorMessage") to include + // in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. However, any field with + // an empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1betaSearchResponseGeoSearchDebugInfo) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaSearchResponseGeoSearchDebugInfo + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1betaSearchResponseGuidedSearchResult: +// Guided search result. The guided search helps user to refine the +// search results and narrow down to the real needs from a broaded +// search results. +type GoogleCloudDiscoveryengineV1betaSearchResponseGuidedSearchResult struct { + // FollowUpQuestions: Suggested follow-up questions. + FollowUpQuestions []string `json:"followUpQuestions,omitempty"` + + // RefinementAttributes: A list of ranked refinement attributes. + RefinementAttributes []*GoogleCloudDiscoveryengineV1betaSearchResponseGuidedSearchResultRefinementAttribute `json:"refinementAttributes,omitempty"` + + // ForceSendFields is a list of field names (e.g. "FollowUpQuestions") + // to unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "FollowUpQuestions") to + // include in API requests with the JSON null value. By default, fields + // with empty values are omitted from API requests. However, any field + // with an empty value appearing in NullFields will be sent to the + // server as null. It is an error if a field in this list has a + // non-empty value. This may be used to include null fields in Patch + // requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1betaSearchResponseGuidedSearchResult) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaSearchResponseGuidedSearchResult + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1betaSearchResponseGuidedSearchResultRefine +// mentAttribute: Useful attribute for search result refinements. +type GoogleCloudDiscoveryengineV1betaSearchResponseGuidedSearchResultRefinementAttribute struct { + // AttributeKey: Attribute key used to refine the results e.g. + // 'movie_type'. + AttributeKey string `json:"attributeKey,omitempty"` + + // AttributeValue: Attribute value used to refine the results e.g. + // 'drama'. + AttributeValue string `json:"attributeValue,omitempty"` + + // ForceSendFields is a list of field names (e.g. "AttributeKey") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "AttributeKey") to include + // in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. However, any field with + // an empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1betaSearchResponseGuidedSearchResultRefinementAttribute) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaSearchResponseGuidedSearchResultRefinementAttribute + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1betaSearchResponseQueryExpansionInfo: +// Information describing query expansion including whether expansion +// has occurred. +type GoogleCloudDiscoveryengineV1betaSearchResponseQueryExpansionInfo struct { + // ExpandedQuery: Bool describing whether query expansion has occurred. + ExpandedQuery bool `json:"expandedQuery,omitempty"` + + // PinnedResultCount: Number of pinned results. This field will only be + // set when expansion happens and + // SearchRequest.QueryExpansionSpec.pin_unexpanded_results is set to + // true. + PinnedResultCount int64 `json:"pinnedResultCount,omitempty,string"` + + // ForceSendFields is a list of field names (e.g. "ExpandedQuery") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "ExpandedQuery") to include + // in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. However, any field with + // an empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1betaSearchResponseQueryExpansionInfo) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaSearchResponseQueryExpansionInfo + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1betaSearchResponseSearchResult: +// Represents the search results. +type GoogleCloudDiscoveryengineV1betaSearchResponseSearchResult struct { + // Document: The document data snippet in the search response. Only + // fields that are marked as retrievable are populated. + Document *GoogleCloudDiscoveryengineV1betaDocument `json:"document,omitempty"` + + // Id: Document.id of the searched Document. + Id string `json:"id,omitempty"` + + // ModelScores: Google provided available scores. + ModelScores map[string]GoogleCloudDiscoveryengineV1betaDoubleList `json:"modelScores,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Document") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "Document") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1betaSearchResponseSearchResult) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaSearchResponseSearchResult + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1betaSearchResponseSummary: Summary of the +// top N search result specified by the summary spec. +type GoogleCloudDiscoveryengineV1betaSearchResponseSummary struct { + // SafetyAttributes: A collection of Safety Attribute categories and + // their associated confidence scores. + SafetyAttributes *GoogleCloudDiscoveryengineV1betaSearchResponseSummarySafetyAttributes `json:"safetyAttributes,omitempty"` + + // SummarySkippedReasons: Additional summary-skipped reasons. This + // provides the reason for ignored cases. If nothing is skipped, this + // field is not set. + // + // Possible values: + // "SUMMARY_SKIPPED_REASON_UNSPECIFIED" - Default value. The summary + // skipped reason is not specified. + // "ADVERSARIAL_QUERY_IGNORED" - The adversarial query ignored case. + // Only populated when SummarySpec.ignore_adversarial_query is set to + // `true`. + // "NON_SUMMARY_SEEKING_QUERY_IGNORED" - The non-summary seeking query + // ignored case. Only populated when + // SummarySpec.ignore_non_summary_seeking_query is set to `true`. + // "OUT_OF_DOMAIN_QUERY_IGNORED" - The out-of-domain query ignored + // case. Google skips the summary if there are no high-relevance search + // results. For example, the data store contains facts about company A + // but the user query is asking questions about company B. + // "POTENTIAL_POLICY_VIOLATION" - The potential policy violation case. + // Google skips the summary if there is a potential policy violation + // detected. This includes content that may be violent or toxic. + // "LLM_ADDON_NOT_ENABLED" - The LLM addon not enabled case. Google + // skips the summary if the LLM addon is not enabled. + SummarySkippedReasons []string `json:"summarySkippedReasons,omitempty"` + + // SummaryText: The summary content. + SummaryText string `json:"summaryText,omitempty"` + + SummaryWithMetadata *GoogleCloudDiscoveryengineV1betaSearchResponseSummarySummaryWithMetadata `json:"summaryWithMetadata,omitempty"` + + // ForceSendFields is a list of field names (e.g. "SafetyAttributes") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "SafetyAttributes") to + // include in API requests with the JSON null value. By default, fields + // with empty values are omitted from API requests. However, any field + // with an empty value appearing in NullFields will be sent to the + // server as null. It is an error if a field in this list has a + // non-empty value. This may be used to include null fields in Patch + // requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1betaSearchResponseSummary) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaSearchResponseSummary + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1betaSearchResponseSummaryCitation: +// Citation info for a segment. +type GoogleCloudDiscoveryengineV1betaSearchResponseSummaryCitation struct { + // EndIndex: End of the attributed segment, exclusive. + EndIndex int64 `json:"endIndex,omitempty,string"` + + // Sources: Citation sources for the attributed segment. + Sources []*GoogleCloudDiscoveryengineV1betaSearchResponseSummaryCitationSource `json:"sources,omitempty"` + + // StartIndex: Index indicates the start of the segment, measured in + // bytes/unicode. + StartIndex int64 `json:"startIndex,omitempty,string"` + + // ForceSendFields is a list of field names (e.g. "EndIndex") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "EndIndex") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1betaSearchResponseSummaryCitation) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaSearchResponseSummaryCitation + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1betaSearchResponseSummaryCitationMetadata: +// +// Citation metadata. +type GoogleCloudDiscoveryengineV1betaSearchResponseSummaryCitationMetadata struct { + // Citations: Citations for segments. + Citations []*GoogleCloudDiscoveryengineV1betaSearchResponseSummaryCitation `json:"citations,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Citations") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "Citations") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1betaSearchResponseSummaryCitationMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaSearchResponseSummaryCitationMetadata + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1betaSearchResponseSummaryCitationSource: +// Citation source. +type GoogleCloudDiscoveryengineV1betaSearchResponseSummaryCitationSource struct { + // ReferenceIndex: Document reference index from + // SummaryWithMetadata.references. It is 0-indexed and the value will be + // zero if the reference_index is not set explicitly. + ReferenceIndex int64 `json:"referenceIndex,omitempty,string"` + + // ForceSendFields is a list of field names (e.g. "ReferenceIndex") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "ReferenceIndex") to + // include in API requests with the JSON null value. By default, fields + // with empty values are omitted from API requests. However, any field + // with an empty value appearing in NullFields will be sent to the + // server as null. It is an error if a field in this list has a + // non-empty value. This may be used to include null fields in Patch + // requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1betaSearchResponseSummaryCitationSource) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaSearchResponseSummaryCitationSource + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1betaSearchResponseSummaryReference: +// Document reference. +type GoogleCloudDiscoveryengineV1betaSearchResponseSummaryReference struct { + // Document: Required. Document.name of the document. Full resource name + // of the referenced document, in the format + // `projects/*/locations/*/collections/*/dataStores/*/branches/*/document + // s/*`. + Document string `json:"document,omitempty"` + + // Title: Title of the document. + Title string `json:"title,omitempty"` + + // Uri: Cloud Storage or HTTP uri for the document. + Uri string `json:"uri,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Document") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "Document") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1betaSearchResponseSummaryReference) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaSearchResponseSummaryReference + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1betaSearchResponseSummarySafetyAttributes: +// +// Safety Attribute categories and their associated confidence scores. +type GoogleCloudDiscoveryengineV1betaSearchResponseSummarySafetyAttributes struct { + // Categories: The display names of Safety Attribute categories + // associated with the generated content. Order matches the Scores. + Categories []string `json:"categories,omitempty"` + + // Scores: The confidence scores of the each category, higher value + // means higher confidence. Order matches the Categories. + Scores []float64 `json:"scores,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Categories") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "Categories") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1betaSearchResponseSummarySafetyAttributes) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaSearchResponseSummarySafetyAttributes + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +func (s *GoogleCloudDiscoveryengineV1betaSearchResponseSummarySafetyAttributes) UnmarshalJSON(data []byte) error { + type NoMethod GoogleCloudDiscoveryengineV1betaSearchResponseSummarySafetyAttributes + var s1 struct { + Scores []gensupport.JSONFloat64 `json:"scores"` + *NoMethod + } + s1.NoMethod = (*NoMethod)(s) + if err := json.Unmarshal(data, &s1); err != nil { + return err + } + s.Scores = make([]float64, len(s1.Scores)) + for i := range s1.Scores { + s.Scores[i] = float64(s1.Scores[i]) + } + return nil +} + +// GoogleCloudDiscoveryengineV1betaSearchResponseSummarySummaryWithMetada +// ta: Summary with metadata information. +type GoogleCloudDiscoveryengineV1betaSearchResponseSummarySummaryWithMetadata struct { + // CitationMetadata: Citation metadata for given summary. + CitationMetadata *GoogleCloudDiscoveryengineV1betaSearchResponseSummaryCitationMetadata `json:"citationMetadata,omitempty"` + + // References: Document References. + References []*GoogleCloudDiscoveryengineV1betaSearchResponseSummaryReference `json:"references,omitempty"` + + // Summary: Summary text with no citation information. + Summary string `json:"summary,omitempty"` + + // ForceSendFields is a list of field names (e.g. "CitationMetadata") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "CitationMetadata") to + // include in API requests with the JSON null value. By default, fields + // with empty values are omitted from API requests. However, any field + // with an empty value appearing in NullFields will be sent to the + // server as null. It is an error if a field in this list has a + // non-empty value. This may be used to include null fields in Patch + // requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1betaSearchResponseSummarySummaryWithMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaSearchResponseSummarySummaryWithMetadata + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1betaSiteSearchEngine: SiteSearchEngine +// captures DataStore level site search persisting configurations. It is +// a singleton value per data store. +type GoogleCloudDiscoveryengineV1betaSiteSearchEngine struct { + // Name: The fully qualified resource name of the site search engine. + // Format: `projects/*/locations/*/dataStores/*/siteSearchEngine` + 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. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + 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. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1betaSiteSearchEngine) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaSiteSearchEngine + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1betaSiteVerificationInfo: Verification +// information for target sites in advanced site search. +type GoogleCloudDiscoveryengineV1betaSiteVerificationInfo struct { + // SiteVerificationState: Site verification state indicating the + // ownership and validity. + // + // Possible values: + // "SITE_VERIFICATION_STATE_UNSPECIFIED" - Defaults to VERIFIED. + // "VERIFIED" - Site ownership verified. + // "UNVERIFIED" - Site ownership pending verification or verification + // failed. + // "EXEMPTED" - Site exempt from verification, e.g., a public website + // that opens to all. + SiteVerificationState string `json:"siteVerificationState,omitempty"` + + // VerifyTime: Latest site verification time. + VerifyTime string `json:"verifyTime,omitempty"` + + // ForceSendFields is a list of field names (e.g. + // "SiteVerificationState") to unconditionally include in API requests. + // By default, fields with empty or default values are omitted from API + // requests. However, any non-pointer, non-interface field appearing in + // ForceSendFields will be sent to the server regardless of whether the + // field is empty or not. This may be used to include empty fields in + // Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "SiteVerificationState") to + // include in API requests with the JSON null value. By default, fields + // with empty values are omitted from API requests. However, any field + // with an empty value appearing in NullFields will be sent to the + // server as null. It is an error if a field in this list has a + // non-empty value. This may be used to include null fields in Patch + // requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1betaSiteVerificationInfo) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaSiteVerificationInfo + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1betaSuggestionDenyListEntry: Suggestion +// deny list entry identifying the phrase to block from suggestions and +// the applied operation for the phrase. +type GoogleCloudDiscoveryengineV1betaSuggestionDenyListEntry struct { + // BlockPhrase: Required. Phrase to block from suggestions served. Can + // be maximum 125 characters. + BlockPhrase string `json:"blockPhrase,omitempty"` + + // MatchOperator: Required. The match operator to apply for this phrase. + // Whether to block the exact phrase, or block any suggestions + // containing this phrase. + // + // Possible values: + // "MATCH_OPERATOR_UNSPECIFIED" - Default value. Should not be used + // "EXACT_MATCH" - If the suggestion is an exact match to the + // block_phrase, then block it. + // "CONTAINS" - If the suggestion contains the block_phrase, then + // block it. + MatchOperator string `json:"matchOperator,omitempty"` + + // ForceSendFields is a list of field names (e.g. "BlockPhrase") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "BlockPhrase") to include + // in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. However, any field with + // an empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1betaSuggestionDenyListEntry) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaSuggestionDenyListEntry + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1betaTargetSite: A target site for the +// SiteSearchEngine. +type GoogleCloudDiscoveryengineV1betaTargetSite struct { + // ExactMatch: Input only. If set to false, a uri_pattern is generated + // to include all pages whose address contains the provided_uri_pattern. + // If set to true, an uri_pattern is generated to try to be an exact + // match of the provided_uri_pattern or just the specific page if the + // provided_uri_pattern is a specific one. provided_uri_pattern is + // always normalized to generate the URI pattern to be used by the + // search engine. + ExactMatch bool `json:"exactMatch,omitempty"` + + // FailureReason: Output only. Failure reason. + FailureReason *GoogleCloudDiscoveryengineV1betaTargetSiteFailureReason `json:"failureReason,omitempty"` + + // GeneratedUriPattern: Output only. This is system-generated based on + // the provided_uri_pattern. + GeneratedUriPattern string `json:"generatedUriPattern,omitempty"` + + // IndexingStatus: Output only. Indexing status. + // + // Possible values: + // "INDEXING_STATUS_UNSPECIFIED" - Defaults to SUCCEEDED. + // "PENDING" - The target site is in the update queue and will be + // picked up by indexing pipeline. + // "FAILED" - The target site fails to be indexed. + // "SUCCEEDED" - The target site has been indexed. + // "DELETING" - The previously indexed target site has been marked to + // be deleted. This is a transitioning state which will resulted in + // either: 1. target site deleted if unindexing is successful; 2. state + // reverts to SUCCEEDED if the unindexing fails. + IndexingStatus string `json:"indexingStatus,omitempty"` + + // Name: Output only. The fully qualified resource name of the target + // site. + // `projects/{project}/locations/{location}/collections/{collection}/data + // Stores/{data_store}/siteSearchEngine/targetSites/{target_site}` The + // `target_site_id` is system-generated. + Name string `json:"name,omitempty"` + + // ProvidedUriPattern: Required. Input only. The user provided URI + // pattern from which the `generated_uri_pattern` is generated. + ProvidedUriPattern string `json:"providedUriPattern,omitempty"` + + // SiteVerificationInfo: Output only. Site ownership and validity + // verification status. + SiteVerificationInfo *GoogleCloudDiscoveryengineV1betaSiteVerificationInfo `json:"siteVerificationInfo,omitempty"` + + // Type: The type of the target site, e.g., whether the site is to be + // included or excluded. + // + // Possible values: + // "TYPE_UNSPECIFIED" - This value is unused. In this case, server + // behavior defaults to Type.INCLUDE. + // "INCLUDE" - Include the target site. + // "EXCLUDE" - Exclude the target site. + Type string `json:"type,omitempty"` + + // UpdateTime: Output only. The target site's last updated time. + 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. "ExactMatch") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "ExactMatch") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1betaTargetSite) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaTargetSite + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1betaTargetSiteFailureReason: Site search +// indexing failure reasons. +type GoogleCloudDiscoveryengineV1betaTargetSiteFailureReason struct { + // QuotaFailure: Failed due to insufficient quota. + QuotaFailure *GoogleCloudDiscoveryengineV1betaTargetSiteFailureReasonQuotaFailure `json:"quotaFailure,omitempty"` + + // ForceSendFields is a list of field names (e.g. "QuotaFailure") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "QuotaFailure") to include + // in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. However, any field with + // an empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1betaTargetSiteFailureReason) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaTargetSiteFailureReason + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +type GoogleCloudDiscoveryengineV1betaTargetSiteFailureReasonQuotaFailure struct { + // TotalRequiredQuota: This number is an estimation on how much total + // quota this project needs to successfully complete indexing. + TotalRequiredQuota int64 `json:"totalRequiredQuota,omitempty,string"` + + // ForceSendFields is a list of field names (e.g. "TotalRequiredQuota") + // to unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "TotalRequiredQuota") to + // include in API requests with the JSON null value. By default, fields + // with empty values are omitted from API requests. However, any field + // with an empty value appearing in NullFields will be sent to the + // server as null. It is an error if a field in this list has a + // non-empty value. This may be used to include null fields in Patch + // requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1betaTargetSiteFailureReasonQuotaFailure) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaTargetSiteFailureReasonQuotaFailure + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1betaTextInput: Defines text input. +type GoogleCloudDiscoveryengineV1betaTextInput struct { + // Context: Conversation context of the input. + Context *GoogleCloudDiscoveryengineV1betaConversationContext `json:"context,omitempty"` + + // Input: Text input. + Input string `json:"input,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Context") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "Context") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1betaTextInput) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaTextInput + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1betaTransactionInfo: A transaction +// represents the entire purchase transaction. +type GoogleCloudDiscoveryengineV1betaTransactionInfo struct { + // Cost: All the costs associated with the products. These can be + // manufacturing costs, shipping expenses not borne by the end user, or + // any other costs, such that: * Profit = value - tax - cost + Cost float64 `json:"cost,omitempty"` + + // Currency: Required. Currency code. Use three-character ISO-4217 code. + Currency string `json:"currency,omitempty"` + + // DiscountValue: The total discount(s) value applied to this + // transaction. This figure should be excluded from + // TransactionInfo.value For example, if a user paid + // TransactionInfo.value amount, then nominal (pre-discount) value of + // the transaction is the sum of TransactionInfo.value and + // TransactionInfo.discount_value This means that profit is calculated + // the same way, regardless of the discount value, and that + // TransactionInfo.discount_value can be larger than + // TransactionInfo.value: * Profit = value - tax - cost + DiscountValue float64 `json:"discountValue,omitempty"` + + // Tax: All the taxes associated with the transaction. + Tax float64 `json:"tax,omitempty"` + + // TransactionId: The transaction ID with a length limit of 128 + // characters. + TransactionId string `json:"transactionId,omitempty"` + + // Value: Required. Total non-zero value associated with the + // transaction. This value may include shipping, tax, or other + // adjustments to the total value that you want to include. + Value float64 `json:"value,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Cost") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "Cost") to include in API + // requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1betaTransactionInfo) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaTransactionInfo + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +func (s *GoogleCloudDiscoveryengineV1betaTransactionInfo) UnmarshalJSON(data []byte) error { + type NoMethod GoogleCloudDiscoveryengineV1betaTransactionInfo + var s1 struct { + Cost gensupport.JSONFloat64 `json:"cost"` + DiscountValue gensupport.JSONFloat64 `json:"discountValue"` + Tax gensupport.JSONFloat64 `json:"tax"` + Value gensupport.JSONFloat64 `json:"value"` + *NoMethod + } + s1.NoMethod = (*NoMethod)(s) + if err := json.Unmarshal(data, &s1); err != nil { + return err + } + s.Cost = float64(s1.Cost) + s.DiscountValue = float64(s1.DiscountValue) + s.Tax = float64(s1.Tax) + s.Value = float64(s1.Value) + return nil +} + +// GoogleCloudDiscoveryengineV1betaUpdateSchemaMetadata: Metadata for +// UpdateSchema LRO. +type GoogleCloudDiscoveryengineV1betaUpdateSchemaMetadata 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. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + 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. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1betaUpdateSchemaMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaUpdateSchemaMetadata + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1betaUpdateTargetSiteMetadata: Metadata +// related to the progress of the +// SiteSearchEngineService.UpdateTargetSite operation. This will be +// returned by the google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1betaUpdateTargetSiteMetadata 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. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + 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. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1betaUpdateTargetSiteMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaUpdateTargetSiteMetadata + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1betaUserEvent: UserEvent captures all +// metadata information Discovery Engine API needs to know about how end +// users interact with customers' website. +type GoogleCloudDiscoveryengineV1betaUserEvent struct { + // Attributes: Extra user event features to include in the + // recommendation model. These attributes must NOT contain data that + // needs to be parsed or processed further, e.g. JSON or other + // encodings. If you provide custom attributes for ingested user events, + // also include them in the user events that you associate with + // prediction requests. Custom attribute formatting must be consistent + // between imported events and events provided with prediction requests. + // This lets the Discovery Engine API use those custom attributes when + // training models and serving predictions, which helps improve + // recommendation quality. This field needs to pass all below criteria, + // otherwise an `INVALID_ARGUMENT` error is returned: * The key must be + // a UTF-8 encoded string with a length limit of 5,000 characters. * For + // text attributes, at most 400 values are allowed. Empty values are not + // allowed. Each value must be a UTF-8 encoded string with a length + // limit of 256 characters. * For number attributes, at most 400 values + // are allowed. For product recommendations, an example of extra user + // information is `traffic_channel`, which is how a user arrives at the + // site. Users can arrive at the site by coming to the site directly, + // coming through Google search, or in other ways. + Attributes map[string]GoogleCloudDiscoveryengineV1betaCustomAttribute `json:"attributes,omitempty"` + + // AttributionToken: Token to attribute an API response to user + // action(s) to trigger the event. Highly recommended for user events + // that are the result of RecommendationService.Recommend. This field + // enables accurate attribution of recommendation model performance. The + // value must be one of: * RecommendResponse.attribution_token for + // events that are the result of RecommendationService.Recommend. * + // SearchResponse.attribution_token for events that are the result of + // SearchService.Search. This token enables us to accurately attribute + // page view or conversion completion back to the event and the + // particular predict response containing this clicked/purchased + // product. If user clicks on product K in the recommendation results, + // pass RecommendResponse.attribution_token as a URL parameter to + // product K's page. When recording events on product K's page, log the + // RecommendResponse.attribution_token to this field. + AttributionToken string `json:"attributionToken,omitempty"` + + // CompletionInfo: CompletionService.CompleteQuery details related to + // the event. This field should be set for `search` event when + // autocomplete function is enabled and the user clicks a suggestion for + // search. + CompletionInfo *GoogleCloudDiscoveryengineV1betaCompletionInfo `json:"completionInfo,omitempty"` + + // DirectUserRequest: Should set to true if the request is made directly + // from the end user, in which case the UserEvent.user_info.user_agent + // can be populated from the HTTP request. This flag should be set only + // if the API request is made directly from the end user such as a + // mobile app (and not if a gateway or a server is processing and + // pushing the user events). This should not be set when using the + // JavaScript tag in UserEventService.CollectUserEvent. + DirectUserRequest bool `json:"directUserRequest,omitempty"` + + // Documents: List of Documents associated with this user event. This + // field is optional except for the following event types: * `view-item` + // * `add-to-cart` * `purchase` * `media-play` * `media-complete` In a + // `search` event, this field represents the documents 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 UserEvent.documents is desired. + Documents []*GoogleCloudDiscoveryengineV1betaDocumentInfo `json:"documents,omitempty"` + + // EventTime: Only required for UserEventService.ImportUserEvents + // method. Timestamp of when the user event happened. + EventTime string `json:"eventTime,omitempty"` + + // EventType: Required. User event type. Allowed values are: Generic + // values: * `search`: Search for Documents. * `view-item`: Detailed + // page view of a Document. * `view-item-list`: View of a panel or + // ordered list of Documents. * `view-home-page`: View of the home page. + // * `view-category-page`: View of a category page, e.g. Home > Men > + // Jeans Retail-related values: * `add-to-cart`: Add an item(s) to cart, + // e.g. in Retail online shopping * `purchase`: Purchase an item(s) + // Media-related values: * `media-play`: Start/resume watching a video, + // playing a song, etc. * `media-complete`: Finished or stopped midway + // through a video, song, etc. + EventType string `json:"eventType,omitempty"` + + // Filter: The filter syntax consists of an expression language for + // constructing a predicate from one or more fields of the documents + // being filtered. One example is for `search` events, the associated + // SearchRequest may contain a filter expression in SearchRequest.filter + // conforming to https://google.aip.dev/160#filtering. Similarly, for + // `view-item-list` events that are generated from a RecommendRequest, + // this field may be populated directly from RecommendRequest.filter + // conforming to https://google.aip.dev/160#filtering. The value must be + // a UTF-8 encoded string with a length limit of 1,000 characters. + // Otherwise, an `INVALID_ARGUMENT` error is returned. + Filter string `json:"filter,omitempty"` + + // MediaInfo: Media-specific info. + MediaInfo *GoogleCloudDiscoveryengineV1betaMediaInfo `json:"mediaInfo,omitempty"` + + // PageInfo: Page metadata such as categories and other critical + // information for certain event types such as `view-category-page`. + PageInfo *GoogleCloudDiscoveryengineV1betaPageInfo `json:"pageInfo,omitempty"` + + // Panel: Panel metadata associated with this user event. + Panel *GoogleCloudDiscoveryengineV1betaPanelInfo `json:"panel,omitempty"` + + // PromotionIds: The promotion IDs if this is an event associated with + // promotions. Currently, this field is restricted to at most one ID. + PromotionIds []string `json:"promotionIds,omitempty"` + + // SearchInfo: SearchService.Search details related to the event. This + // field should be set for `search` event. + SearchInfo *GoogleCloudDiscoveryengineV1betaSearchInfo `json:"searchInfo,omitempty"` + + // SessionId: A unique identifier for tracking a visitor session with a + // length limit of 128 bytes. A session is an aggregation of an end user + // behavior in a time span. A general guideline to populate the + // session_id: 1. If user has no activity for 30 min, a new session_id + // should be assigned. 2. The session_id should be unique across users, + // suggest use uuid or add UserEvent.user_pseudo_id as prefix. + SessionId string `json:"sessionId,omitempty"` + + // TagIds: A list of identifiers for the independent experiment groups + // this user event belongs to. This is used to distinguish between user + // events associated with different experiment setups on the customer + // end. + TagIds []string `json:"tagIds,omitempty"` + + // TransactionInfo: The transaction metadata (if any) associated with + // this user event. + TransactionInfo *GoogleCloudDiscoveryengineV1betaTransactionInfo `json:"transactionInfo,omitempty"` + + // UserInfo: Information about the end user. + UserInfo *GoogleCloudDiscoveryengineV1betaUserInfo `json:"userInfo,omitempty"` + + // UserPseudoId: Required. A unique identifier for tracking visitors. + // For example, this could be implemented with an HTTP cookie, which + // should be able to uniquely identify a visitor on a single device. + // This unique identifier should not change if the visitor log in/out of + // the website. Do not set the field to the same fixed ID for different + // users. This mixes the event history of those users together, which + // results in degraded model quality. The field must be a UTF-8 encoded + // string with a length limit of 128 characters. Otherwise, an + // `INVALID_ARGUMENT` error is returned. The field should not contain + // PII or user-data. We recommend to use Google Analytics Client ID + // (https://developers.google.com/analytics/devguides/collection/analyticsjs/field-reference#clientId) + // for this field. + UserPseudoId string `json:"userPseudoId,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the + // server. + googleapi.ServerResponse `json:"-"` + + // ForceSendFields is a list of field names (e.g. "Attributes") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "Attributes") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1betaUserEvent) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaUserEvent + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1betaUserInfo: Information of an end user. +type GoogleCloudDiscoveryengineV1betaUserInfo struct { + // UserAgent: User agent as included in the HTTP header. The field must + // be a UTF-8 encoded string with a length limit of 1,000 characters. + // Otherwise, an `INVALID_ARGUMENT` error is returned. This should not + // be set when using the client side event reporting with GTM or + // JavaScript tag in UserEventService.CollectUserEvent or if + // UserEvent.direct_user_request is set. + UserAgent string `json:"userAgent,omitempty"` + + // UserId: Highly recommended for logged-in users. Unique identifier for + // logged-in user, such as a user name. Don't set for anonymous users. + // Always use a hashed value for this ID. Don't set the field to the + // same fixed ID for different users. This mixes the event history of + // those users together, which results in degraded model quality. The + // field must be a UTF-8 encoded string with a length limit of 128 + // characters. Otherwise, an `INVALID_ARGUMENT` error is returned. + UserId string `json:"userId,omitempty"` + + // ForceSendFields is a list of field names (e.g. "UserAgent") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "UserAgent") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1betaUserInfo) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaUserInfo + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleLongrunningListOperationsResponse: The response message for +// Operations.ListOperations. +type GoogleLongrunningListOperationsResponse 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 []*GoogleLongrunningOperation `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. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + 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. However, any field with + // an empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleLongrunningListOperationsResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleLongrunningListOperationsResponse + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleLongrunningOperation: This resource represents a long-running +// operation that is the result of a network API call. +type GoogleLongrunningOperation struct { + // Done: If the value is `false`, it means the operation is still in + // progress. If `true`, the operation is completed, and either `error` + // or `response` is available. + Done bool `json:"done,omitempty"` + + // Error: The error result of the operation in case of failure or + // cancellation. + Error *GoogleRpcStatus `json:"error,omitempty"` + + // Metadata: Service-specific metadata associated with the operation. It + // typically contains progress information and common metadata such as + // create time. Some services might not provide such metadata. Any + // method that returns a long-running operation should document the + // metadata type, if any. + Metadata googleapi.RawMessage `json:"metadata,omitempty"` + + // Name: The server-assigned name, which is only unique within the same + // service that originally returns it. If you use the default HTTP + // mapping, the `name` should be a resource name ending with + // `operations/{unique_id}`. + Name string `json:"name,omitempty"` + + // Response: The normal, successful response of the operation. If the + // original method returns no data on success, such as `Delete`, the + // response is `google.protobuf.Empty`. If the original method is + // standard `Get`/`Create`/`Update`, the response should be the + // resource. For other methods, the response should have the type + // `XxxResponse`, where `Xxx` is the original method name. For example, + // if the original method name is `TakeSnapshot()`, the inferred + // response type is `TakeSnapshotResponse`. + Response googleapi.RawMessage `json:"response,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the + // server. + googleapi.ServerResponse `json:"-"` + + // ForceSendFields is a list of field names (e.g. "Done") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "Done") to include in API + // requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleLongrunningOperation) MarshalJSON() ([]byte, error) { + type NoMethod GoogleLongrunningOperation + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleProtobufEmpty: A generic empty message that you can re-use to +// avoid defining duplicated empty messages in your APIs. A typical +// example is to use it as the request or the response type of an API +// method. For instance: service Foo { rpc Bar(google.protobuf.Empty) +// returns (google.protobuf.Empty); } +type GoogleProtobufEmpty struct { + // ServerResponse contains the HTTP response code and headers from the + // server. + googleapi.ServerResponse `json:"-"` +} + +// GoogleRpcStatus: The `Status` type defines a logical error model that +// is suitable for different programming environments, including REST +// APIs and RPC APIs. It is used by gRPC (https://github.com/grpc). Each +// `Status` message contains three pieces of data: error code, error +// message, and error details. You can find out more about this error +// model and how to work with it in the API Design Guide +// (https://cloud.google.com/apis/design/errors). +type GoogleRpcStatus struct { + // Code: The status code, which should be an enum value of + // google.rpc.Code. + Code int64 `json:"code,omitempty"` + + // Details: A list of messages that carry the error details. There is a + // common set of message types for APIs to use. + Details []googleapi.RawMessage `json:"details,omitempty"` + + // Message: A developer-facing error message, which should be in + // English. Any user-facing error message should be localized and sent + // in the google.rpc.Status.details field, or localized by the client. + Message string `json:"message,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Code") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "Code") to include in API + // requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleRpcStatus) MarshalJSON() ([]byte, error) { + type NoMethod GoogleRpcStatus + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleTypeDate: Represents a whole or partial calendar date, such as +// a birthday. The time of day and time zone are either specified +// elsewhere or are insignificant. The date is relative to the Gregorian +// Calendar. This can represent one of the following: * A full date, +// with non-zero year, month, and day values. * A month and day, with a +// zero year (for example, an anniversary). * A year on its own, with a +// zero month and a zero day. * A year and month, with a zero day (for +// example, a credit card expiration date). Related types: * +// google.type.TimeOfDay * google.type.DateTime * +// google.protobuf.Timestamp +type GoogleTypeDate struct { + // Day: Day of a month. Must be from 1 to 31 and valid for the year and + // month, or 0 to specify a year by itself or a year and month where the + // day isn't significant. + Day int64 `json:"day,omitempty"` + + // Month: Month of a year. Must be from 1 to 12, or 0 to specify a year + // without a month and day. + Month int64 `json:"month,omitempty"` + + // Year: Year of the date. Must be from 1 to 9999, or 0 to specify a + // date without a year. + Year int64 `json:"year,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Day") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "Day") to include in API + // requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleTypeDate) MarshalJSON() ([]byte, error) { + type NoMethod GoogleTypeDate + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// method id "discoveryengine.projects.locations.collections.dataConnector.operations.get": + +type ProjectsLocationsCollectionsDataConnectorOperationsGetCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// Get: Gets the latest state of a long-running operation. Clients can +// use this method to poll the operation result at intervals as +// recommended by the API service. +// +// - name: The name of the operation resource. +func (r *ProjectsLocationsCollectionsDataConnectorOperationsService) Get(name string) *ProjectsLocationsCollectionsDataConnectorOperationsGetCall { + c := &ProjectsLocationsCollectionsDataConnectorOperationsGetCall{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 information. +func (c *ProjectsLocationsCollectionsDataConnectorOperationsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataConnectorOperationsGetCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// IfNoneMatch sets the 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. Use googleapi.IsNotModified to check whether the response +// error from Do is the result of In-None-Match. +func (c *ProjectsLocationsCollectionsDataConnectorOperationsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsCollectionsDataConnectorOperationsGetCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do method. Any +// pending HTTP request will be aborted if the provided context is +// canceled. +func (c *ProjectsLocationsCollectionsDataConnectorOperationsGetCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataConnectorOperationsGetCall { + c.ctx_ = ctx + return c +} + +// Header returns an http.Header that can be modified by the caller to +// add HTTP headers to the request. +func (c *ProjectsLocationsCollectionsDataConnectorOperationsGetCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsCollectionsDataConnectorOperationsGetCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := make(http.Header) + reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) + for k, v := range c.header_ { + reqHeaders[k] = v + } + reqHeaders.Set("User-Agent", c.s.userAgent()) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) + } + var body io.Reader = nil + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("GET", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "name": c.name, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "discoveryengine.projects.locations.collections.dataConnector.operations.get" call. +// Exactly one of *GoogleLongrunningOperation or error will be non-nil. +// 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 *ProjectsLocationsCollectionsDataConnectorOperationsGetCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &GoogleLongrunningOperation{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil + // { + // "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": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataConnector/operations/{operationsId}", + // "httpMethod": "GET", + // "id": "discoveryengine.projects.locations.collections.dataConnector.operations.get", + // "parameterOrder": [ + // "name" + // ], + // "parameters": { + // "name": { + // "description": "The name of the operation resource.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataConnector/operations/[^/]+$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1beta/{+name}", + // "response": { + // "$ref": "GoogleLongrunningOperation" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "discoveryengine.projects.locations.collections.dataConnector.operations.list": + +type ProjectsLocationsCollectionsDataConnectorOperationsListCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// List: Lists operations that match the specified filter in the +// request. If the server doesn't support this method, it returns +// `UNIMPLEMENTED`. +// +// - name: The name of the operation's parent resource. +func (r *ProjectsLocationsCollectionsDataConnectorOperationsService) List(name string) *ProjectsLocationsCollectionsDataConnectorOperationsListCall { + c := &ProjectsLocationsCollectionsDataConnectorOperationsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + return c +} + +// Filter sets the optional parameter "filter": The standard list +// filter. +func (c *ProjectsLocationsCollectionsDataConnectorOperationsListCall) Filter(filter string) *ProjectsLocationsCollectionsDataConnectorOperationsListCall { + c.urlParams_.Set("filter", filter) + return c +} + +// PageSize sets the optional parameter "pageSize": The standard list +// page size. +func (c *ProjectsLocationsCollectionsDataConnectorOperationsListCall) PageSize(pageSize int64) *ProjectsLocationsCollectionsDataConnectorOperationsListCall { + c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) + return c +} + +// PageToken sets the optional parameter "pageToken": The standard list +// page token. +func (c *ProjectsLocationsCollectionsDataConnectorOperationsListCall) PageToken(pageToken string) *ProjectsLocationsCollectionsDataConnectorOperationsListCall { + 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 information. +func (c *ProjectsLocationsCollectionsDataConnectorOperationsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataConnectorOperationsListCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// IfNoneMatch sets the 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. Use googleapi.IsNotModified to check whether the response +// error from Do is the result of In-None-Match. +func (c *ProjectsLocationsCollectionsDataConnectorOperationsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsCollectionsDataConnectorOperationsListCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do method. Any +// pending HTTP request will be aborted if the provided context is +// canceled. +func (c *ProjectsLocationsCollectionsDataConnectorOperationsListCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataConnectorOperationsListCall { + c.ctx_ = ctx + return c +} + +// Header returns an http.Header that can be modified by the caller to +// add HTTP headers to the request. +func (c *ProjectsLocationsCollectionsDataConnectorOperationsListCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsCollectionsDataConnectorOperationsListCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := make(http.Header) + reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) + for k, v := range c.header_ { + reqHeaders[k] = v + } + reqHeaders.Set("User-Agent", c.s.userAgent()) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) + } + var body io.Reader = nil + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}/operations") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("GET", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "name": c.name, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "discoveryengine.projects.locations.collections.dataConnector.operations.list" call. +// Exactly one of *GoogleLongrunningListOperationsResponse or error will +// be non-nil. Any non-2xx status code is an error. Response headers are +// in either +// *GoogleLongrunningListOperationsResponse.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 *ProjectsLocationsCollectionsDataConnectorOperationsListCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningListOperationsResponse, 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 := &GoogleLongrunningListOperationsResponse{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil + // { + // "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataConnector/operations", + // "httpMethod": "GET", + // "id": "discoveryengine.projects.locations.collections.dataConnector.operations.list", + // "parameterOrder": [ + // "name" + // ], + // "parameters": { + // "filter": { + // "description": "The standard list filter.", + // "location": "query", + // "type": "string" + // }, + // "name": { + // "description": "The name of the operation's parent resource.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataConnector$", + // "required": true, + // "type": "string" + // }, + // "pageSize": { + // "description": "The standard list page size.", + // "format": "int32", + // "location": "query", + // "type": "integer" + // }, + // "pageToken": { + // "description": "The standard list page token.", + // "location": "query", + // "type": "string" + // } + // }, + // "path": "v1beta/{+name}/operations", + // "response": { + // "$ref": "GoogleLongrunningListOperationsResponse" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// 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 *ProjectsLocationsCollectionsDataConnectorOperationsListCall) Pages(ctx context.Context, f func(*GoogleLongrunningListOperationsResponse) error) error { + c.ctx_ = ctx + defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point + 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) + } +} + +// method id "discoveryengine.projects.locations.collections.dataStores.completeQuery": + +type ProjectsLocationsCollectionsDataStoresCompleteQueryCall struct { + s *Service + dataStore string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// CompleteQuery: Completes the specified user input with keyword +// suggestions. +// +// - dataStore: The parent data store resource name for which the +// completion is performed, such as +// `projects/*/locations/global/collections/default_collection/dataStor +// es/default_data_store`. +func (r *ProjectsLocationsCollectionsDataStoresService) CompleteQuery(dataStore string) *ProjectsLocationsCollectionsDataStoresCompleteQueryCall { + c := &ProjectsLocationsCollectionsDataStoresCompleteQueryCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.dataStore = dataStore + return c +} + +// IncludeTailSuggestions sets the optional parameter +// "includeTailSuggestions": Indicates if tail suggestions should be +// returned if there are no suggestions that match the full query. Even +// if set to true, if there are suggestions that match the full query, +// those are returned and no tail suggestions are returned. +func (c *ProjectsLocationsCollectionsDataStoresCompleteQueryCall) IncludeTailSuggestions(includeTailSuggestions bool) *ProjectsLocationsCollectionsDataStoresCompleteQueryCall { + c.urlParams_.Set("includeTailSuggestions", fmt.Sprint(includeTailSuggestions)) + return c +} + +// Query sets the optional parameter "query": Required. The typeahead +// input used to fetch suggestions. Maximum length is 128 characters. +func (c *ProjectsLocationsCollectionsDataStoresCompleteQueryCall) Query(query string) *ProjectsLocationsCollectionsDataStoresCompleteQueryCall { + c.urlParams_.Set("query", query) + return c +} + +// QueryModel sets the optional parameter "queryModel": Specifies the +// autocomplete data model. This overrides any model specified in the +// Configuration > Autocomplete section of the Cloud console. Currently +// supported values: * `document` - Using suggestions generated from +// user-imported documents. * `search-history` - Using suggestions +// generated from the past history of SearchService.Search API calls. Do +// not use it when there is no traffic for Search API. * `user-event` - +// Using suggestions generated from user-imported search events. * +// `document-completable` - Using suggestions taken directly from +// user-imported document fields marked as completable. Default values: +// * `document` is the default model for regular dataStores. * +// `search-history` is the default model for site search dataStores. +func (c *ProjectsLocationsCollectionsDataStoresCompleteQueryCall) QueryModel(queryModel string) *ProjectsLocationsCollectionsDataStoresCompleteQueryCall { + c.urlParams_.Set("queryModel", queryModel) + return c +} + +// UserPseudoId sets the optional parameter "userPseudoId": A unique +// identifier for tracking visitors. For example, this could be +// implemented with an HTTP cookie, which should be able to uniquely +// identify a visitor on a single device. This unique identifier should +// not change if the visitor logs in or out of the website. This field +// should NOT have a fixed value such as `unknown_visitor`. This should +// be the same identifier as UserEvent.user_pseudo_id and +// SearchRequest.user_pseudo_id. The field must be a UTF-8 encoded +// string with a length limit of 128 characters. Otherwise, an +// `INVALID_ARGUMENT` error is returned. +func (c *ProjectsLocationsCollectionsDataStoresCompleteQueryCall) UserPseudoId(userPseudoId string) *ProjectsLocationsCollectionsDataStoresCompleteQueryCall { + c.urlParams_.Set("userPseudoId", userPseudoId) + return c +} + +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse +// for more information. +func (c *ProjectsLocationsCollectionsDataStoresCompleteQueryCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresCompleteQueryCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// IfNoneMatch sets the 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. Use googleapi.IsNotModified to check whether the response +// error from Do is the result of In-None-Match. +func (c *ProjectsLocationsCollectionsDataStoresCompleteQueryCall) IfNoneMatch(entityTag string) *ProjectsLocationsCollectionsDataStoresCompleteQueryCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do method. Any +// pending HTTP request will be aborted if the provided context is +// canceled. +func (c *ProjectsLocationsCollectionsDataStoresCompleteQueryCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresCompleteQueryCall { + c.ctx_ = ctx + return c +} + +// Header returns an http.Header that can be modified by the caller to +// add HTTP headers to the request. +func (c *ProjectsLocationsCollectionsDataStoresCompleteQueryCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsCollectionsDataStoresCompleteQueryCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := make(http.Header) + reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) + for k, v := range c.header_ { + reqHeaders[k] = v + } + reqHeaders.Set("User-Agent", c.s.userAgent()) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) + } + var body io.Reader = nil + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+dataStore}:completeQuery") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("GET", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "dataStore": c.dataStore, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "discoveryengine.projects.locations.collections.dataStores.completeQuery" call. +// Exactly one of *GoogleCloudDiscoveryengineV1betaCompleteQueryResponse +// or error will be non-nil. Any non-2xx status code is an error. +// Response headers are in either +// *GoogleCloudDiscoveryengineV1betaCompleteQueryResponse.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 *ProjectsLocationsCollectionsDataStoresCompleteQueryCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1betaCompleteQueryResponse, 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 := &GoogleCloudDiscoveryengineV1betaCompleteQueryResponse{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil + // { + // "description": "Completes the specified user input with keyword suggestions.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}:completeQuery", + // "httpMethod": "GET", + // "id": "discoveryengine.projects.locations.collections.dataStores.completeQuery", + // "parameterOrder": [ + // "dataStore" + // ], + // "parameters": { + // "dataStore": { + // "description": "Required. The parent data store resource name for which the completion is performed, such as `projects/*/locations/global/collections/default_collection/dataStores/default_data_store`.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+$", + // "required": true, + // "type": "string" + // }, + // "includeTailSuggestions": { + // "description": "Indicates if tail suggestions should be returned if there are no suggestions that match the full query. Even if set to true, if there are suggestions that match the full query, those are returned and no tail suggestions are returned.", + // "location": "query", + // "type": "boolean" + // }, + // "query": { + // "description": "Required. The typeahead input used to fetch suggestions. Maximum length is 128 characters.", + // "location": "query", + // "type": "string" + // }, + // "queryModel": { + // "description": "Specifies the autocomplete data model. This overrides any model specified in the Configuration \u003e Autocomplete section of the Cloud console. Currently supported values: * `document` - Using suggestions generated from user-imported documents. * `search-history` - Using suggestions generated from the past history of SearchService.Search API calls. Do not use it when there is no traffic for Search API. * `user-event` - Using suggestions generated from user-imported search events. * `document-completable` - Using suggestions taken directly from user-imported document fields marked as completable. Default values: * `document` is the default model for regular dataStores. * `search-history` is the default model for site search dataStores.", + // "location": "query", + // "type": "string" + // }, + // "userPseudoId": { + // "description": "A unique identifier for tracking visitors. For example, this could be implemented with an HTTP cookie, which should be able to uniquely identify a visitor on a single device. This unique identifier should not change if the visitor logs in or out of the website. This field should NOT have a fixed value such as `unknown_visitor`. This should be the same identifier as UserEvent.user_pseudo_id and SearchRequest.user_pseudo_id. The field must be a UTF-8 encoded string with a length limit of 128 characters. Otherwise, an `INVALID_ARGUMENT` error is returned.", + // "location": "query", + // "type": "string" + // } + // }, + // "path": "v1beta/{+dataStore}:completeQuery", + // "response": { + // "$ref": "GoogleCloudDiscoveryengineV1betaCompleteQueryResponse" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "discoveryengine.projects.locations.collections.dataStores.create": + +type ProjectsLocationsCollectionsDataStoresCreateCall struct { + s *Service + parent string + googleclouddiscoveryenginev1betadatastore *GoogleCloudDiscoveryengineV1betaDataStore + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Create: Creates a DataStore. DataStore is for storing Documents. To +// serve these documents for Search, or Recommendation use case, an +// Engine needs to be created separately. +// +// - parent: The parent resource name, such as +// `projects/{project}/locations/{location}/collections/{collection}`. +func (r *ProjectsLocationsCollectionsDataStoresService) Create(parent string, googleclouddiscoveryenginev1betadatastore *GoogleCloudDiscoveryengineV1betaDataStore) *ProjectsLocationsCollectionsDataStoresCreateCall { + c := &ProjectsLocationsCollectionsDataStoresCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + c.googleclouddiscoveryenginev1betadatastore = googleclouddiscoveryenginev1betadatastore + return c +} + +// CreateAdvancedSiteSearch sets the optional parameter +// "createAdvancedSiteSearch": A boolean flag indicating whether user +// want to directly create an advanced data store for site search. If +// the data store is not configured as site search (GENERIC vertical and +// PUBLIC_WEBSITE content_config), this flag will be ignored. +func (c *ProjectsLocationsCollectionsDataStoresCreateCall) CreateAdvancedSiteSearch(createAdvancedSiteSearch bool) *ProjectsLocationsCollectionsDataStoresCreateCall { + c.urlParams_.Set("createAdvancedSiteSearch", fmt.Sprint(createAdvancedSiteSearch)) + return c +} + +// DataStoreId sets the optional parameter "dataStoreId": Required. The +// ID to use for the DataStore, which will become the final component of +// the DataStore's resource name. This field must conform to RFC-1034 +// (https://tools.ietf.org/html/rfc1034) standard with a length limit of +// 63 characters. Otherwise, an INVALID_ARGUMENT error is returned. +func (c *ProjectsLocationsCollectionsDataStoresCreateCall) DataStoreId(dataStoreId string) *ProjectsLocationsCollectionsDataStoresCreateCall { + c.urlParams_.Set("dataStoreId", dataStoreId) + return c +} + +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse +// for more information. +func (c *ProjectsLocationsCollectionsDataStoresCreateCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresCreateCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. Any +// pending HTTP request will be aborted if the provided context is +// canceled. +func (c *ProjectsLocationsCollectionsDataStoresCreateCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresCreateCall { + c.ctx_ = ctx + return c +} + +// Header returns an http.Header that can be modified by the caller to +// add HTTP headers to the request. +func (c *ProjectsLocationsCollectionsDataStoresCreateCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsCollectionsDataStoresCreateCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := make(http.Header) + reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) + for k, v := range c.header_ { + reqHeaders[k] = v + } + reqHeaders.Set("User-Agent", c.s.userAgent()) + var body io.Reader = nil + body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddiscoveryenginev1betadatastore) + if err != nil { + return nil, err + } + reqHeaders.Set("Content-Type", "application/json") + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+parent}/dataStores") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("POST", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "parent": c.parent, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "discoveryengine.projects.locations.collections.dataStores.create" call. +// Exactly one of *GoogleLongrunningOperation or error will be non-nil. +// 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 *ProjectsLocationsCollectionsDataStoresCreateCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &GoogleLongrunningOperation{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil + // { + // "description": "Creates a DataStore. DataStore is for storing Documents. To serve these documents for Search, or Recommendation use case, an Engine needs to be created separately.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores", + // "httpMethod": "POST", + // "id": "discoveryengine.projects.locations.collections.dataStores.create", + // "parameterOrder": [ + // "parent" + // ], + // "parameters": { + // "createAdvancedSiteSearch": { + // "description": "A boolean flag indicating whether user want to directly create an advanced data store for site search. If the data store is not configured as site search (GENERIC vertical and PUBLIC_WEBSITE content_config), this flag will be ignored.", + // "location": "query", + // "type": "boolean" + // }, + // "dataStoreId": { + // "description": "Required. The ID to use for the DataStore, which will become the final component of the DataStore's resource name. This field must conform to [RFC-1034](https://tools.ietf.org/html/rfc1034) standard with a length limit of 63 characters. Otherwise, an INVALID_ARGUMENT error is returned.", + // "location": "query", + // "type": "string" + // }, + // "parent": { + // "description": "Required. The parent resource name, such as `projects/{project}/locations/{location}/collections/{collection}`.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1beta/{+parent}/dataStores", + // "request": { + // "$ref": "GoogleCloudDiscoveryengineV1betaDataStore" + // }, + // "response": { + // "$ref": "GoogleLongrunningOperation" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "discoveryengine.projects.locations.collections.dataStores.delete": + +type ProjectsLocationsCollectionsDataStoresDeleteCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Delete: Deletes a DataStore. +// +// - name: Full resource name of DataStore, such as +// `projects/{project}/locations/{location}/collections/{collection_id} +// /dataStores/{data_store_id}`. If the caller does not have +// permission to delete the DataStore, regardless of whether or not it +// exists, a PERMISSION_DENIED error is returned. If the DataStore to +// delete does not exist, a NOT_FOUND error is returned. +func (r *ProjectsLocationsCollectionsDataStoresService) Delete(name string) *ProjectsLocationsCollectionsDataStoresDeleteCall { + c := &ProjectsLocationsCollectionsDataStoresDeleteCall{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 information. +func (c *ProjectsLocationsCollectionsDataStoresDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresDeleteCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. Any +// pending HTTP request will be aborted if the provided context is +// canceled. +func (c *ProjectsLocationsCollectionsDataStoresDeleteCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresDeleteCall { + c.ctx_ = ctx + return c +} + +// Header returns an http.Header that can be modified by the caller to +// add HTTP headers to the request. +func (c *ProjectsLocationsCollectionsDataStoresDeleteCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsCollectionsDataStoresDeleteCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := make(http.Header) + reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) + for k, v := range c.header_ { + reqHeaders[k] = v + } + reqHeaders.Set("User-Agent", c.s.userAgent()) + var body io.Reader = nil + 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("DELETE", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "name": c.name, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "discoveryengine.projects.locations.collections.dataStores.delete" call. +// Exactly one of *GoogleLongrunningOperation or error will be non-nil. +// 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 *ProjectsLocationsCollectionsDataStoresDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &GoogleLongrunningOperation{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil + // { + // "description": "Deletes a DataStore.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}", + // "httpMethod": "DELETE", + // "id": "discoveryengine.projects.locations.collections.dataStores.delete", + // "parameterOrder": [ + // "name" + // ], + // "parameters": { + // "name": { + // "description": "Required. Full resource name of DataStore, such as `projects/{project}/locations/{location}/collections/{collection_id}/dataStores/{data_store_id}`. If the caller does not have permission to delete the DataStore, regardless of whether or not it exists, a PERMISSION_DENIED error is returned. If the DataStore to delete does not exist, a NOT_FOUND error is returned.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1beta/{+name}", + // "response": { + // "$ref": "GoogleLongrunningOperation" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "discoveryengine.projects.locations.collections.dataStores.get": + +type ProjectsLocationsCollectionsDataStoresGetCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// Get: Gets a DataStore. +// +// - name: Full resource name of DataStore, such as +// `projects/{project}/locations/{location}/collections/{collection_id} +// /dataStores/{data_store_id}`. If the caller does not have +// permission to access the DataStore, regardless of whether or not it +// exists, a PERMISSION_DENIED error is returned. If the requested +// DataStore does not exist, a NOT_FOUND error is returned. +func (r *ProjectsLocationsCollectionsDataStoresService) Get(name string) *ProjectsLocationsCollectionsDataStoresGetCall { + c := &ProjectsLocationsCollectionsDataStoresGetCall{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 information. +func (c *ProjectsLocationsCollectionsDataStoresGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresGetCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// IfNoneMatch sets the 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. Use googleapi.IsNotModified to check whether the response +// error from Do is the result of In-None-Match. +func (c *ProjectsLocationsCollectionsDataStoresGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsCollectionsDataStoresGetCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do method. Any +// pending HTTP request will be aborted if the provided context is +// canceled. +func (c *ProjectsLocationsCollectionsDataStoresGetCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresGetCall { + c.ctx_ = ctx + return c +} + +// Header returns an http.Header that can be modified by the caller to +// add HTTP headers to the request. +func (c *ProjectsLocationsCollectionsDataStoresGetCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsCollectionsDataStoresGetCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := make(http.Header) + reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) + for k, v := range c.header_ { + reqHeaders[k] = v + } + reqHeaders.Set("User-Agent", c.s.userAgent()) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) + } + var body io.Reader = nil + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("GET", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "name": c.name, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "discoveryengine.projects.locations.collections.dataStores.get" call. +// Exactly one of *GoogleCloudDiscoveryengineV1betaDataStore or error +// will be non-nil. Any non-2xx status code is an error. Response +// headers are in either +// *GoogleCloudDiscoveryengineV1betaDataStore.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 *ProjectsLocationsCollectionsDataStoresGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1betaDataStore, 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 := &GoogleCloudDiscoveryengineV1betaDataStore{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil + // { + // "description": "Gets a DataStore.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}", + // "httpMethod": "GET", + // "id": "discoveryengine.projects.locations.collections.dataStores.get", + // "parameterOrder": [ + // "name" + // ], + // "parameters": { + // "name": { + // "description": "Required. Full resource name of DataStore, such as `projects/{project}/locations/{location}/collections/{collection_id}/dataStores/{data_store_id}`. If the caller does not have permission to access the DataStore, regardless of whether or not it exists, a PERMISSION_DENIED error is returned. If the requested DataStore does not exist, a NOT_FOUND error is returned.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1beta/{+name}", + // "response": { + // "$ref": "GoogleCloudDiscoveryengineV1betaDataStore" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "discoveryengine.projects.locations.collections.dataStores.getSiteSearchEngine": + +type ProjectsLocationsCollectionsDataStoresGetSiteSearchEngineCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// GetSiteSearchEngine: Gets the SiteSearchEngine. +// +// - name: Resource name of SiteSearchEngine, such as +// `projects/{project}/locations/{location}/collections/{collection}/da +// taStores/{data_store}/siteSearchEngine`. If the caller does not +// have permission to access the [SiteSearchEngine], regardless of +// whether or not it exists, a PERMISSION_DENIED error is returned. +func (r *ProjectsLocationsCollectionsDataStoresService) GetSiteSearchEngine(name string) *ProjectsLocationsCollectionsDataStoresGetSiteSearchEngineCall { + c := &ProjectsLocationsCollectionsDataStoresGetSiteSearchEngineCall{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 information. +func (c *ProjectsLocationsCollectionsDataStoresGetSiteSearchEngineCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresGetSiteSearchEngineCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// IfNoneMatch sets the 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. Use googleapi.IsNotModified to check whether the response +// error from Do is the result of In-None-Match. +func (c *ProjectsLocationsCollectionsDataStoresGetSiteSearchEngineCall) IfNoneMatch(entityTag string) *ProjectsLocationsCollectionsDataStoresGetSiteSearchEngineCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do method. Any +// pending HTTP request will be aborted if the provided context is +// canceled. +func (c *ProjectsLocationsCollectionsDataStoresGetSiteSearchEngineCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresGetSiteSearchEngineCall { + c.ctx_ = ctx + return c +} + +// Header returns an http.Header that can be modified by the caller to +// add HTTP headers to the request. +func (c *ProjectsLocationsCollectionsDataStoresGetSiteSearchEngineCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsCollectionsDataStoresGetSiteSearchEngineCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := make(http.Header) + reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) + for k, v := range c.header_ { + reqHeaders[k] = v + } + reqHeaders.Set("User-Agent", c.s.userAgent()) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) + } + var body io.Reader = nil + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("GET", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "name": c.name, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "discoveryengine.projects.locations.collections.dataStores.getSiteSearchEngine" call. +// Exactly one of *GoogleCloudDiscoveryengineV1betaSiteSearchEngine or +// error will be non-nil. Any non-2xx status code is an error. Response +// headers are in either +// *GoogleCloudDiscoveryengineV1betaSiteSearchEngine.ServerResponse.Heade +// r 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 *ProjectsLocationsCollectionsDataStoresGetSiteSearchEngineCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1betaSiteSearchEngine, 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 := &GoogleCloudDiscoveryengineV1betaSiteSearchEngine{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil + // { + // "description": "Gets the SiteSearchEngine.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/siteSearchEngine", + // "httpMethod": "GET", + // "id": "discoveryengine.projects.locations.collections.dataStores.getSiteSearchEngine", + // "parameterOrder": [ + // "name" + // ], + // "parameters": { + // "name": { + // "description": "Required. Resource name of SiteSearchEngine, such as `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/siteSearchEngine`. If the caller does not have permission to access the [SiteSearchEngine], regardless of whether or not it exists, a PERMISSION_DENIED error is returned.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/siteSearchEngine$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1beta/{+name}", + // "response": { + // "$ref": "GoogleCloudDiscoveryengineV1betaSiteSearchEngine" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "discoveryengine.projects.locations.collections.dataStores.list": + +type ProjectsLocationsCollectionsDataStoresListCall struct { + s *Service + parent string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// List: Lists all the DataStores associated with the project. +// +// - parent: The parent branch resource name, such as +// `projects/{project}/locations/{location}/collections/{collection_id} +// `. If the caller does not have permission to list DataStores under +// this location, regardless of whether or not this data store exists, +// a PERMISSION_DENIED error is returned. +func (r *ProjectsLocationsCollectionsDataStoresService) List(parent string) *ProjectsLocationsCollectionsDataStoresListCall { + c := &ProjectsLocationsCollectionsDataStoresListCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + return c +} + +// Filter sets the optional parameter "filter": Filter by solution type. +// For example: filter = 'solution_type:SOLUTION_TYPE_SEARCH' +func (c *ProjectsLocationsCollectionsDataStoresListCall) Filter(filter string) *ProjectsLocationsCollectionsDataStoresListCall { + c.urlParams_.Set("filter", filter) + return c +} + +// PageSize sets the optional parameter "pageSize": Maximum number of +// DataStores to return. If unspecified, defaults to 10. The maximum +// allowed value is 50. Values above 50 will be coerced to 50. If this +// field is negative, an INVALID_ARGUMENT is returned. +func (c *ProjectsLocationsCollectionsDataStoresListCall) PageSize(pageSize int64) *ProjectsLocationsCollectionsDataStoresListCall { + c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) + return c +} + +// PageToken sets the optional parameter "pageToken": A page token +// ListDataStoresResponse.next_page_token, received from a previous +// DataStoreService.ListDataStores call. Provide this to retrieve the +// subsequent page. When paginating, all other parameters provided to +// DataStoreService.ListDataStores must match the call that provided the +// page token. Otherwise, an INVALID_ARGUMENT error is returned. +func (c *ProjectsLocationsCollectionsDataStoresListCall) PageToken(pageToken string) *ProjectsLocationsCollectionsDataStoresListCall { + 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 information. +func (c *ProjectsLocationsCollectionsDataStoresListCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresListCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// IfNoneMatch sets the 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. Use googleapi.IsNotModified to check whether the response +// error from Do is the result of In-None-Match. +func (c *ProjectsLocationsCollectionsDataStoresListCall) IfNoneMatch(entityTag string) *ProjectsLocationsCollectionsDataStoresListCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do method. Any +// pending HTTP request will be aborted if the provided context is +// canceled. +func (c *ProjectsLocationsCollectionsDataStoresListCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresListCall { + c.ctx_ = ctx + return c +} + +// Header returns an http.Header that can be modified by the caller to +// add HTTP headers to the request. +func (c *ProjectsLocationsCollectionsDataStoresListCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsCollectionsDataStoresListCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := make(http.Header) + reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) + for k, v := range c.header_ { + reqHeaders[k] = v + } + reqHeaders.Set("User-Agent", c.s.userAgent()) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) + } + var body io.Reader = nil + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+parent}/dataStores") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("GET", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "parent": c.parent, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "discoveryengine.projects.locations.collections.dataStores.list" call. +// Exactly one of +// *GoogleCloudDiscoveryengineV1betaListDataStoresResponse or error will +// be non-nil. Any non-2xx status code is an error. Response headers are +// in either +// *GoogleCloudDiscoveryengineV1betaListDataStoresResponse.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 *ProjectsLocationsCollectionsDataStoresListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1betaListDataStoresResponse, 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 := &GoogleCloudDiscoveryengineV1betaListDataStoresResponse{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil + // { + // "description": "Lists all the DataStores associated with the project.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores", + // "httpMethod": "GET", + // "id": "discoveryengine.projects.locations.collections.dataStores.list", + // "parameterOrder": [ + // "parent" + // ], + // "parameters": { + // "filter": { + // "description": "Filter by solution type. For example: filter = 'solution_type:SOLUTION_TYPE_SEARCH'", + // "location": "query", + // "type": "string" + // }, + // "pageSize": { + // "description": "Maximum number of DataStores to return. If unspecified, defaults to 10. The maximum allowed value is 50. Values above 50 will be coerced to 50. If this field is negative, an INVALID_ARGUMENT is returned.", + // "format": "int32", + // "location": "query", + // "type": "integer" + // }, + // "pageToken": { + // "description": "A page token ListDataStoresResponse.next_page_token, received from a previous DataStoreService.ListDataStores call. Provide this to retrieve the subsequent page. When paginating, all other parameters provided to DataStoreService.ListDataStores must match the call that provided the page token. Otherwise, an INVALID_ARGUMENT error is returned.", + // "location": "query", + // "type": "string" + // }, + // "parent": { + // "description": "Required. The parent branch resource name, such as `projects/{project}/locations/{location}/collections/{collection_id}`. If the caller does not have permission to list DataStores under this location, regardless of whether or not this data store exists, a PERMISSION_DENIED error is returned.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1beta/{+parent}/dataStores", + // "response": { + // "$ref": "GoogleCloudDiscoveryengineV1betaListDataStoresResponse" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// 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 *ProjectsLocationsCollectionsDataStoresListCall) Pages(ctx context.Context, f func(*GoogleCloudDiscoveryengineV1betaListDataStoresResponse) error) error { + c.ctx_ = ctx + defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point + 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) + } +} + +// method id "discoveryengine.projects.locations.collections.dataStores.patch": + +type ProjectsLocationsCollectionsDataStoresPatchCall struct { + s *Service + name string + googleclouddiscoveryenginev1betadatastore *GoogleCloudDiscoveryengineV1betaDataStore + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Patch: Updates a DataStore +// +// - name: Immutable. The full resource name of the data store. Format: +// `projects/{project}/locations/{location}/collections/{collection_id} +// /dataStores/{data_store_id}`. This field must be a UTF-8 encoded +// string with a length limit of 1024 characters. +func (r *ProjectsLocationsCollectionsDataStoresService) Patch(name string, googleclouddiscoveryenginev1betadatastore *GoogleCloudDiscoveryengineV1betaDataStore) *ProjectsLocationsCollectionsDataStoresPatchCall { + c := &ProjectsLocationsCollectionsDataStoresPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + c.googleclouddiscoveryenginev1betadatastore = googleclouddiscoveryenginev1betadatastore + return c +} + +// UpdateMask sets the optional parameter "updateMask": Indicates which +// fields in the provided DataStore to update. If an unsupported or +// unknown field is provided, an INVALID_ARGUMENT error is returned. +func (c *ProjectsLocationsCollectionsDataStoresPatchCall) UpdateMask(updateMask string) *ProjectsLocationsCollectionsDataStoresPatchCall { + 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 information. +func (c *ProjectsLocationsCollectionsDataStoresPatchCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresPatchCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. Any +// pending HTTP request will be aborted if the provided context is +// canceled. +func (c *ProjectsLocationsCollectionsDataStoresPatchCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresPatchCall { + c.ctx_ = ctx + return c +} + +// Header returns an http.Header that can be modified by the caller to +// add HTTP headers to the request. +func (c *ProjectsLocationsCollectionsDataStoresPatchCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsCollectionsDataStoresPatchCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := make(http.Header) + reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) + for k, v := range c.header_ { + reqHeaders[k] = v + } + reqHeaders.Set("User-Agent", c.s.userAgent()) + var body io.Reader = nil + body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddiscoveryenginev1betadatastore) + if err != nil { + return nil, err + } + reqHeaders.Set("Content-Type", "application/json") + 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, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "discoveryengine.projects.locations.collections.dataStores.patch" call. +// Exactly one of *GoogleCloudDiscoveryengineV1betaDataStore or error +// will be non-nil. Any non-2xx status code is an error. Response +// headers are in either +// *GoogleCloudDiscoveryengineV1betaDataStore.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 *ProjectsLocationsCollectionsDataStoresPatchCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1betaDataStore, 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 := &GoogleCloudDiscoveryengineV1betaDataStore{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil + // { + // "description": "Updates a DataStore", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}", + // "httpMethod": "PATCH", + // "id": "discoveryengine.projects.locations.collections.dataStores.patch", + // "parameterOrder": [ + // "name" + // ], + // "parameters": { + // "name": { + // "description": "Immutable. The full resource name of the data store. Format: `projects/{project}/locations/{location}/collections/{collection_id}/dataStores/{data_store_id}`. This field must be a UTF-8 encoded string with a length limit of 1024 characters.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+$", + // "required": true, + // "type": "string" + // }, + // "updateMask": { + // "description": "Indicates which fields in the provided DataStore to update. If an unsupported or unknown field is provided, an INVALID_ARGUMENT error is returned.", + // "format": "google-fieldmask", + // "location": "query", + // "type": "string" + // } + // }, + // "path": "v1beta/{+name}", + // "request": { + // "$ref": "GoogleCloudDiscoveryengineV1betaDataStore" + // }, + // "response": { + // "$ref": "GoogleCloudDiscoveryengineV1betaDataStore" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "discoveryengine.projects.locations.collections.dataStores.branches.documents.create": + +type ProjectsLocationsCollectionsDataStoresBranchesDocumentsCreateCall struct { + s *Service + parent string + googleclouddiscoveryenginev1betadocument *GoogleCloudDiscoveryengineV1betaDocument + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Create: Creates a Document. +// +// - parent: The parent resource name, such as +// `projects/{project}/locations/{location}/collections/{collection}/da +// taStores/{data_store}/branches/{branch}`. +func (r *ProjectsLocationsCollectionsDataStoresBranchesDocumentsService) Create(parent string, googleclouddiscoveryenginev1betadocument *GoogleCloudDiscoveryengineV1betaDocument) *ProjectsLocationsCollectionsDataStoresBranchesDocumentsCreateCall { + c := &ProjectsLocationsCollectionsDataStoresBranchesDocumentsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + c.googleclouddiscoveryenginev1betadocument = googleclouddiscoveryenginev1betadocument + return c +} + +// DocumentId sets the optional parameter "documentId": Required. The ID +// to use for the Document, which will become the final component of the +// Document.name. If the caller does not have permission to create the +// Document, regardless of whether or not it exists, a +// `PERMISSION_DENIED` error is returned. This field must be unique +// among all Documents with the same parent. Otherwise, an +// `ALREADY_EXISTS` error is returned. This field must conform to +// RFC-1034 (https://tools.ietf.org/html/rfc1034) standard with a length +// limit of 63 characters. Otherwise, an `INVALID_ARGUMENT` error is +// returned. +func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsCreateCall) DocumentId(documentId string) *ProjectsLocationsCollectionsDataStoresBranchesDocumentsCreateCall { + c.urlParams_.Set("documentId", documentId) + return c +} + +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse +// for more information. +func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsCreateCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresBranchesDocumentsCreateCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. Any +// pending HTTP request will be aborted if the provided context is +// canceled. +func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsCreateCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresBranchesDocumentsCreateCall { + c.ctx_ = ctx + return c +} + +// Header returns an http.Header that can be modified by the caller to +// add HTTP headers to the request. +func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsCreateCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsCreateCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := make(http.Header) + reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) + for k, v := range c.header_ { + reqHeaders[k] = v + } + reqHeaders.Set("User-Agent", c.s.userAgent()) + var body io.Reader = nil + body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddiscoveryenginev1betadocument) + if err != nil { + return nil, err + } + reqHeaders.Set("Content-Type", "application/json") + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+parent}/documents") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("POST", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "parent": c.parent, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "discoveryengine.projects.locations.collections.dataStores.branches.documents.create" call. +// Exactly one of *GoogleCloudDiscoveryengineV1betaDocument or error +// will be non-nil. Any non-2xx status code is an error. Response +// headers are in either +// *GoogleCloudDiscoveryengineV1betaDocument.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 *ProjectsLocationsCollectionsDataStoresBranchesDocumentsCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1betaDocument, 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 := &GoogleCloudDiscoveryengineV1betaDocument{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil + // { + // "description": "Creates a Document.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/branches/{branchesId}/documents", + // "httpMethod": "POST", + // "id": "discoveryengine.projects.locations.collections.dataStores.branches.documents.create", + // "parameterOrder": [ + // "parent" + // ], + // "parameters": { + // "documentId": { + // "description": "Required. The ID to use for the Document, which will become the final component of the Document.name. If the caller does not have permission to create the Document, regardless of whether or not it exists, a `PERMISSION_DENIED` error is returned. This field must be unique among all Documents with the same parent. Otherwise, an `ALREADY_EXISTS` error is returned. This field must conform to [RFC-1034](https://tools.ietf.org/html/rfc1034) standard with a length limit of 63 characters. Otherwise, an `INVALID_ARGUMENT` error is returned.", + // "location": "query", + // "type": "string" + // }, + // "parent": { + // "description": "Required. The parent resource name, such as `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/branches/{branch}`.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/branches/[^/]+$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1beta/{+parent}/documents", + // "request": { + // "$ref": "GoogleCloudDiscoveryengineV1betaDocument" + // }, + // "response": { + // "$ref": "GoogleCloudDiscoveryengineV1betaDocument" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "discoveryengine.projects.locations.collections.dataStores.branches.documents.delete": + +type ProjectsLocationsCollectionsDataStoresBranchesDocumentsDeleteCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Delete: Deletes a Document. +// +// - name: Full resource name of Document, such as +// `projects/{project}/locations/{location}/collections/{collection}/da +// taStores/{data_store}/branches/{branch}/documents/{document}`. If +// the caller does not have permission to delete the Document, +// regardless of whether or not it exists, a `PERMISSION_DENIED` error +// is returned. If the Document to delete does not exist, a +// `NOT_FOUND` error is returned. +func (r *ProjectsLocationsCollectionsDataStoresBranchesDocumentsService) Delete(name string) *ProjectsLocationsCollectionsDataStoresBranchesDocumentsDeleteCall { + c := &ProjectsLocationsCollectionsDataStoresBranchesDocumentsDeleteCall{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 information. +func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresBranchesDocumentsDeleteCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. Any +// pending HTTP request will be aborted if the provided context is +// canceled. +func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsDeleteCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresBranchesDocumentsDeleteCall { + c.ctx_ = ctx + return c +} + +// Header returns an http.Header that can be modified by the caller to +// add HTTP headers to the request. +func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsDeleteCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsDeleteCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := make(http.Header) + reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) + for k, v := range c.header_ { + reqHeaders[k] = v + } + reqHeaders.Set("User-Agent", c.s.userAgent()) + var body io.Reader = nil + 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("DELETE", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "name": c.name, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "discoveryengine.projects.locations.collections.dataStores.branches.documents.delete" call. +// Exactly one of *GoogleProtobufEmpty or error will be non-nil. Any +// non-2xx status code is an error. Response headers are in either +// *GoogleProtobufEmpty.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 *ProjectsLocationsCollectionsDataStoresBranchesDocumentsDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, 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 := &GoogleProtobufEmpty{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil + // { + // "description": "Deletes a Document.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/branches/{branchesId}/documents/{documentsId}", + // "httpMethod": "DELETE", + // "id": "discoveryengine.projects.locations.collections.dataStores.branches.documents.delete", + // "parameterOrder": [ + // "name" + // ], + // "parameters": { + // "name": { + // "description": "Required. Full resource name of Document, such as `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/branches/{branch}/documents/{document}`. If the caller does not have permission to delete the Document, regardless of whether or not it exists, a `PERMISSION_DENIED` error is returned. If the Document to delete does not exist, a `NOT_FOUND` error is returned.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/branches/[^/]+/documents/[^/]+$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1beta/{+name}", + // "response": { + // "$ref": "GoogleProtobufEmpty" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "discoveryengine.projects.locations.collections.dataStores.branches.documents.get": + +type ProjectsLocationsCollectionsDataStoresBranchesDocumentsGetCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// Get: Gets a Document. +// +// - name: Full resource name of Document, such as +// `projects/{project}/locations/{location}/collections/{collection}/da +// taStores/{data_store}/branches/{branch}/documents/{document}`. If +// the caller does not have permission to access the Document, +// regardless of whether or not it exists, a `PERMISSION_DENIED` error +// is returned. If the requested Document does not exist, a +// `NOT_FOUND` error is returned. +func (r *ProjectsLocationsCollectionsDataStoresBranchesDocumentsService) Get(name string) *ProjectsLocationsCollectionsDataStoresBranchesDocumentsGetCall { + c := &ProjectsLocationsCollectionsDataStoresBranchesDocumentsGetCall{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 information. +func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresBranchesDocumentsGetCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// IfNoneMatch sets the 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. Use googleapi.IsNotModified to check whether the response +// error from Do is the result of In-None-Match. +func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsCollectionsDataStoresBranchesDocumentsGetCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do method. Any +// pending HTTP request will be aborted if the provided context is +// canceled. +func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsGetCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresBranchesDocumentsGetCall { + c.ctx_ = ctx + return c +} + +// Header returns an http.Header that can be modified by the caller to +// add HTTP headers to the request. +func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsGetCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsGetCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := make(http.Header) + reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) + for k, v := range c.header_ { + reqHeaders[k] = v + } + reqHeaders.Set("User-Agent", c.s.userAgent()) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) + } + var body io.Reader = nil + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("GET", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "name": c.name, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "discoveryengine.projects.locations.collections.dataStores.branches.documents.get" call. +// Exactly one of *GoogleCloudDiscoveryengineV1betaDocument or error +// will be non-nil. Any non-2xx status code is an error. Response +// headers are in either +// *GoogleCloudDiscoveryengineV1betaDocument.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 *ProjectsLocationsCollectionsDataStoresBranchesDocumentsGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1betaDocument, 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 := &GoogleCloudDiscoveryengineV1betaDocument{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil + // { + // "description": "Gets a Document.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/branches/{branchesId}/documents/{documentsId}", + // "httpMethod": "GET", + // "id": "discoveryengine.projects.locations.collections.dataStores.branches.documents.get", + // "parameterOrder": [ + // "name" + // ], + // "parameters": { + // "name": { + // "description": "Required. Full resource name of Document, such as `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/branches/{branch}/documents/{document}`. If the caller does not have permission to access the Document, regardless of whether or not it exists, a `PERMISSION_DENIED` error is returned. If the requested Document does not exist, a `NOT_FOUND` error is returned.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/branches/[^/]+/documents/[^/]+$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1beta/{+name}", + // "response": { + // "$ref": "GoogleCloudDiscoveryengineV1betaDocument" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "discoveryengine.projects.locations.collections.dataStores.branches.documents.import": + +type ProjectsLocationsCollectionsDataStoresBranchesDocumentsImportCall struct { + s *Service + parent string + googleclouddiscoveryenginev1betaimportdocumentsrequest *GoogleCloudDiscoveryengineV1betaImportDocumentsRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Import: Bulk import of multiple Documents. Request processing may be +// synchronous. Non-existing items will be created. Note: It is possible +// for a subset of the Documents to be successfully updated. +// +// - parent: The parent branch resource name, such as +// `projects/{project}/locations/{location}/collections/{collection}/da +// taStores/{data_store}/branches/{branch}`. Requires create/update +// permission. +func (r *ProjectsLocationsCollectionsDataStoresBranchesDocumentsService) Import(parent string, googleclouddiscoveryenginev1betaimportdocumentsrequest *GoogleCloudDiscoveryengineV1betaImportDocumentsRequest) *ProjectsLocationsCollectionsDataStoresBranchesDocumentsImportCall { + c := &ProjectsLocationsCollectionsDataStoresBranchesDocumentsImportCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + c.googleclouddiscoveryenginev1betaimportdocumentsrequest = googleclouddiscoveryenginev1betaimportdocumentsrequest + return c +} + +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse +// for more information. +func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsImportCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresBranchesDocumentsImportCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. Any +// pending HTTP request will be aborted if the provided context is +// canceled. +func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsImportCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresBranchesDocumentsImportCall { + c.ctx_ = ctx + return c +} + +// Header returns an http.Header that can be modified by the caller to +// add HTTP headers to the request. +func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsImportCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsImportCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := make(http.Header) + reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) + for k, v := range c.header_ { + reqHeaders[k] = v + } + reqHeaders.Set("User-Agent", c.s.userAgent()) + var body io.Reader = nil + body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddiscoveryenginev1betaimportdocumentsrequest) + if err != nil { + return nil, err + } + reqHeaders.Set("Content-Type", "application/json") + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+parent}/documents:import") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("POST", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "parent": c.parent, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "discoveryengine.projects.locations.collections.dataStores.branches.documents.import" call. +// Exactly one of *GoogleLongrunningOperation or error will be non-nil. +// 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 *ProjectsLocationsCollectionsDataStoresBranchesDocumentsImportCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &GoogleLongrunningOperation{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil + // { + // "description": "Bulk import of multiple Documents. Request processing may be synchronous. Non-existing items will be created. Note: It is possible for a subset of the Documents to be successfully updated.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/branches/{branchesId}/documents:import", + // "httpMethod": "POST", + // "id": "discoveryengine.projects.locations.collections.dataStores.branches.documents.import", + // "parameterOrder": [ + // "parent" + // ], + // "parameters": { + // "parent": { + // "description": "Required. The parent branch resource name, such as `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/branches/{branch}`. Requires create/update permission.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/branches/[^/]+$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1beta/{+parent}/documents:import", + // "request": { + // "$ref": "GoogleCloudDiscoveryengineV1betaImportDocumentsRequest" + // }, + // "response": { + // "$ref": "GoogleLongrunningOperation" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "discoveryengine.projects.locations.collections.dataStores.branches.documents.list": + +type ProjectsLocationsCollectionsDataStoresBranchesDocumentsListCall struct { + s *Service + parent string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// List: Gets a list of Documents. +// +// - parent: The parent branch resource name, such as +// `projects/{project}/locations/{location}/collections/{collection}/da +// taStores/{data_store}/branches/{branch}`. Use `default_branch` as +// the branch ID, to list documents under the default branch. If the +// caller does not have permission to list Documents under this +// branch, regardless of whether or not this branch exists, a +// `PERMISSION_DENIED` error is returned. +func (r *ProjectsLocationsCollectionsDataStoresBranchesDocumentsService) List(parent string) *ProjectsLocationsCollectionsDataStoresBranchesDocumentsListCall { + c := &ProjectsLocationsCollectionsDataStoresBranchesDocumentsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + return c +} + +// PageSize sets the optional parameter "pageSize": Maximum number of +// Documents to return. If unspecified, defaults to 100. The maximum +// allowed value is 1000. Values above 1000 will be coerced to 1000. If +// this field is negative, an `INVALID_ARGUMENT` error is returned. +func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsListCall) PageSize(pageSize int64) *ProjectsLocationsCollectionsDataStoresBranchesDocumentsListCall { + c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) + return c +} + +// PageToken sets the optional parameter "pageToken": A page token +// ListDocumentsResponse.next_page_token, received from a previous +// DocumentService.ListDocuments call. Provide this to retrieve the +// subsequent page. When paginating, all other parameters provided to +// DocumentService.ListDocuments must match the call that provided the +// page token. Otherwise, an `INVALID_ARGUMENT` error is returned. +func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsListCall) PageToken(pageToken string) *ProjectsLocationsCollectionsDataStoresBranchesDocumentsListCall { + 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 information. +func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresBranchesDocumentsListCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// IfNoneMatch sets the 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. Use googleapi.IsNotModified to check whether the response +// error from Do is the result of In-None-Match. +func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsCollectionsDataStoresBranchesDocumentsListCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do method. Any +// pending HTTP request will be aborted if the provided context is +// canceled. +func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsListCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresBranchesDocumentsListCall { + c.ctx_ = ctx + return c +} + +// Header returns an http.Header that can be modified by the caller to +// add HTTP headers to the request. +func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsListCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsListCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := make(http.Header) + reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) + for k, v := range c.header_ { + reqHeaders[k] = v + } + reqHeaders.Set("User-Agent", c.s.userAgent()) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) + } + var body io.Reader = nil + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+parent}/documents") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("GET", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "parent": c.parent, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "discoveryengine.projects.locations.collections.dataStores.branches.documents.list" call. +// Exactly one of *GoogleCloudDiscoveryengineV1betaListDocumentsResponse +// or error will be non-nil. Any non-2xx status code is an error. +// Response headers are in either +// *GoogleCloudDiscoveryengineV1betaListDocumentsResponse.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 *ProjectsLocationsCollectionsDataStoresBranchesDocumentsListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1betaListDocumentsResponse, 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 := &GoogleCloudDiscoveryengineV1betaListDocumentsResponse{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil + // { + // "description": "Gets a list of Documents.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/branches/{branchesId}/documents", + // "httpMethod": "GET", + // "id": "discoveryengine.projects.locations.collections.dataStores.branches.documents.list", + // "parameterOrder": [ + // "parent" + // ], + // "parameters": { + // "pageSize": { + // "description": "Maximum number of Documents to return. If unspecified, defaults to 100. The maximum allowed value is 1000. Values above 1000 will be coerced to 1000. If this field is negative, an `INVALID_ARGUMENT` error is returned.", + // "format": "int32", + // "location": "query", + // "type": "integer" + // }, + // "pageToken": { + // "description": "A page token ListDocumentsResponse.next_page_token, received from a previous DocumentService.ListDocuments call. Provide this to retrieve the subsequent page. When paginating, all other parameters provided to DocumentService.ListDocuments must match the call that provided the page token. Otherwise, an `INVALID_ARGUMENT` error is returned.", + // "location": "query", + // "type": "string" + // }, + // "parent": { + // "description": "Required. The parent branch resource name, such as `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/branches/{branch}`. Use `default_branch` as the branch ID, to list documents under the default branch. If the caller does not have permission to list Documents under this branch, regardless of whether or not this branch exists, a `PERMISSION_DENIED` error is returned.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/branches/[^/]+$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1beta/{+parent}/documents", + // "response": { + // "$ref": "GoogleCloudDiscoveryengineV1betaListDocumentsResponse" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// 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 *ProjectsLocationsCollectionsDataStoresBranchesDocumentsListCall) Pages(ctx context.Context, f func(*GoogleCloudDiscoveryengineV1betaListDocumentsResponse) error) error { + c.ctx_ = ctx + defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point + 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) + } +} + +// method id "discoveryengine.projects.locations.collections.dataStores.branches.documents.patch": + +type ProjectsLocationsCollectionsDataStoresBranchesDocumentsPatchCall struct { + s *Service + name string + googleclouddiscoveryenginev1betadocument *GoogleCloudDiscoveryengineV1betaDocument + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Patch: Updates a Document. +// +// - name: Immutable. The full resource name of the document. Format: +// `projects/{project}/locations/{location}/collections/{collection}/da +// taStores/{data_store}/branches/{branch}/documents/{document_id}`. +// This field must be a UTF-8 encoded string with a length limit of +// 1024 characters. +func (r *ProjectsLocationsCollectionsDataStoresBranchesDocumentsService) Patch(name string, googleclouddiscoveryenginev1betadocument *GoogleCloudDiscoveryengineV1betaDocument) *ProjectsLocationsCollectionsDataStoresBranchesDocumentsPatchCall { + c := &ProjectsLocationsCollectionsDataStoresBranchesDocumentsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + c.googleclouddiscoveryenginev1betadocument = googleclouddiscoveryenginev1betadocument + return c +} + +// AllowMissing sets the optional parameter "allowMissing": If set to +// true, and the Document is not found, a new Document will be created. +func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsPatchCall) AllowMissing(allowMissing bool) *ProjectsLocationsCollectionsDataStoresBranchesDocumentsPatchCall { + c.urlParams_.Set("allowMissing", fmt.Sprint(allowMissing)) + return c +} + +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse +// for more information. +func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsPatchCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresBranchesDocumentsPatchCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. Any +// pending HTTP request will be aborted if the provided context is +// canceled. +func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsPatchCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresBranchesDocumentsPatchCall { + c.ctx_ = ctx + return c +} + +// Header returns an http.Header that can be modified by the caller to +// add HTTP headers to the request. +func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsPatchCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsPatchCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := make(http.Header) + reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) + for k, v := range c.header_ { + reqHeaders[k] = v + } + reqHeaders.Set("User-Agent", c.s.userAgent()) + var body io.Reader = nil + body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddiscoveryenginev1betadocument) + if err != nil { + return nil, err + } + reqHeaders.Set("Content-Type", "application/json") + 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, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "discoveryengine.projects.locations.collections.dataStores.branches.documents.patch" call. +// Exactly one of *GoogleCloudDiscoveryengineV1betaDocument or error +// will be non-nil. Any non-2xx status code is an error. Response +// headers are in either +// *GoogleCloudDiscoveryengineV1betaDocument.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 *ProjectsLocationsCollectionsDataStoresBranchesDocumentsPatchCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1betaDocument, 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 := &GoogleCloudDiscoveryengineV1betaDocument{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil + // { + // "description": "Updates a Document.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/branches/{branchesId}/documents/{documentsId}", + // "httpMethod": "PATCH", + // "id": "discoveryengine.projects.locations.collections.dataStores.branches.documents.patch", + // "parameterOrder": [ + // "name" + // ], + // "parameters": { + // "allowMissing": { + // "description": "If set to true, and the Document is not found, a new Document will be created.", + // "location": "query", + // "type": "boolean" + // }, + // "name": { + // "description": "Immutable. The full resource name of the document. Format: `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/branches/{branch}/documents/{document_id}`. This field must be a UTF-8 encoded string with a length limit of 1024 characters.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/branches/[^/]+/documents/[^/]+$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1beta/{+name}", + // "request": { + // "$ref": "GoogleCloudDiscoveryengineV1betaDocument" + // }, + // "response": { + // "$ref": "GoogleCloudDiscoveryengineV1betaDocument" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "discoveryengine.projects.locations.collections.dataStores.branches.documents.purge": + +type ProjectsLocationsCollectionsDataStoresBranchesDocumentsPurgeCall struct { + s *Service + parent string + googleclouddiscoveryenginev1betapurgedocumentsrequest *GoogleCloudDiscoveryengineV1betaPurgeDocumentsRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Purge: Permanently deletes all selected Documents in a branch. This +// process is asynchronous. Depending on the number of Documents to be +// deleted, this operation can take hours to complete. Before the delete +// operation completes, some Documents might still be returned by +// DocumentService.GetDocument or DocumentService.ListDocuments. To get +// a list of the Documents to be deleted, set +// PurgeDocumentsRequest.force to false. +// +// - parent: The parent resource name, such as +// `projects/{project}/locations/{location}/collections/{collection}/da +// taStores/{data_store}/branches/{branch}`. +func (r *ProjectsLocationsCollectionsDataStoresBranchesDocumentsService) Purge(parent string, googleclouddiscoveryenginev1betapurgedocumentsrequest *GoogleCloudDiscoveryengineV1betaPurgeDocumentsRequest) *ProjectsLocationsCollectionsDataStoresBranchesDocumentsPurgeCall { + c := &ProjectsLocationsCollectionsDataStoresBranchesDocumentsPurgeCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + c.googleclouddiscoveryenginev1betapurgedocumentsrequest = googleclouddiscoveryenginev1betapurgedocumentsrequest + return c +} + +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse +// for more information. +func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsPurgeCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresBranchesDocumentsPurgeCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. Any +// pending HTTP request will be aborted if the provided context is +// canceled. +func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsPurgeCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresBranchesDocumentsPurgeCall { + c.ctx_ = ctx + return c +} + +// Header returns an http.Header that can be modified by the caller to +// add HTTP headers to the request. +func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsPurgeCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsPurgeCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := make(http.Header) + reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) + for k, v := range c.header_ { + reqHeaders[k] = v + } + reqHeaders.Set("User-Agent", c.s.userAgent()) + var body io.Reader = nil + body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddiscoveryenginev1betapurgedocumentsrequest) + if err != nil { + return nil, err + } + reqHeaders.Set("Content-Type", "application/json") + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+parent}/documents:purge") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("POST", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "parent": c.parent, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "discoveryengine.projects.locations.collections.dataStores.branches.documents.purge" call. +// Exactly one of *GoogleLongrunningOperation or error will be non-nil. +// 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 *ProjectsLocationsCollectionsDataStoresBranchesDocumentsPurgeCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &GoogleLongrunningOperation{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil + // { + // "description": "Permanently deletes all selected Documents in a branch. This process is asynchronous. Depending on the number of Documents to be deleted, this operation can take hours to complete. Before the delete operation completes, some Documents might still be returned by DocumentService.GetDocument or DocumentService.ListDocuments. To get a list of the Documents to be deleted, set PurgeDocumentsRequest.force to false.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/branches/{branchesId}/documents:purge", + // "httpMethod": "POST", + // "id": "discoveryengine.projects.locations.collections.dataStores.branches.documents.purge", + // "parameterOrder": [ + // "parent" + // ], + // "parameters": { + // "parent": { + // "description": "Required. The parent resource name, such as `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/branches/{branch}`.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/branches/[^/]+$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1beta/{+parent}/documents:purge", + // "request": { + // "$ref": "GoogleCloudDiscoveryengineV1betaPurgeDocumentsRequest" + // }, + // "response": { + // "$ref": "GoogleLongrunningOperation" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "discoveryengine.projects.locations.collections.dataStores.branches.operations.get": + +type ProjectsLocationsCollectionsDataStoresBranchesOperationsGetCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// Get: Gets the latest state of a long-running operation. Clients can +// use this method to poll the operation result at intervals as +// recommended by the API service. +// +// - name: The name of the operation resource. +func (r *ProjectsLocationsCollectionsDataStoresBranchesOperationsService) Get(name string) *ProjectsLocationsCollectionsDataStoresBranchesOperationsGetCall { + c := &ProjectsLocationsCollectionsDataStoresBranchesOperationsGetCall{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 information. +func (c *ProjectsLocationsCollectionsDataStoresBranchesOperationsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresBranchesOperationsGetCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// IfNoneMatch sets the 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. Use googleapi.IsNotModified to check whether the response +// error from Do is the result of In-None-Match. +func (c *ProjectsLocationsCollectionsDataStoresBranchesOperationsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsCollectionsDataStoresBranchesOperationsGetCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do method. Any +// pending HTTP request will be aborted if the provided context is +// canceled. +func (c *ProjectsLocationsCollectionsDataStoresBranchesOperationsGetCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresBranchesOperationsGetCall { + c.ctx_ = ctx + return c +} + +// Header returns an http.Header that can be modified by the caller to +// add HTTP headers to the request. +func (c *ProjectsLocationsCollectionsDataStoresBranchesOperationsGetCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsCollectionsDataStoresBranchesOperationsGetCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := make(http.Header) + reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) + for k, v := range c.header_ { + reqHeaders[k] = v + } + reqHeaders.Set("User-Agent", c.s.userAgent()) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) + } + var body io.Reader = nil + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("GET", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "name": c.name, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "discoveryengine.projects.locations.collections.dataStores.branches.operations.get" call. +// Exactly one of *GoogleLongrunningOperation or error will be non-nil. +// 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 *ProjectsLocationsCollectionsDataStoresBranchesOperationsGetCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &GoogleLongrunningOperation{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil + // { + // "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": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/branches/{branchesId}/operations/{operationsId}", + // "httpMethod": "GET", + // "id": "discoveryengine.projects.locations.collections.dataStores.branches.operations.get", + // "parameterOrder": [ + // "name" + // ], + // "parameters": { + // "name": { + // "description": "The name of the operation resource.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/branches/[^/]+/operations/[^/]+$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1beta/{+name}", + // "response": { + // "$ref": "GoogleLongrunningOperation" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "discoveryengine.projects.locations.collections.dataStores.branches.operations.list": + +type ProjectsLocationsCollectionsDataStoresBranchesOperationsListCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// List: Lists operations that match the specified filter in the +// request. If the server doesn't support this method, it returns +// `UNIMPLEMENTED`. +// +// - name: The name of the operation's parent resource. +func (r *ProjectsLocationsCollectionsDataStoresBranchesOperationsService) List(name string) *ProjectsLocationsCollectionsDataStoresBranchesOperationsListCall { + c := &ProjectsLocationsCollectionsDataStoresBranchesOperationsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + return c +} + +// Filter sets the optional parameter "filter": The standard list +// filter. +func (c *ProjectsLocationsCollectionsDataStoresBranchesOperationsListCall) Filter(filter string) *ProjectsLocationsCollectionsDataStoresBranchesOperationsListCall { + c.urlParams_.Set("filter", filter) + return c +} + +// PageSize sets the optional parameter "pageSize": The standard list +// page size. +func (c *ProjectsLocationsCollectionsDataStoresBranchesOperationsListCall) PageSize(pageSize int64) *ProjectsLocationsCollectionsDataStoresBranchesOperationsListCall { + c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) + return c +} + +// PageToken sets the optional parameter "pageToken": The standard list +// page token. +func (c *ProjectsLocationsCollectionsDataStoresBranchesOperationsListCall) PageToken(pageToken string) *ProjectsLocationsCollectionsDataStoresBranchesOperationsListCall { + 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 information. +func (c *ProjectsLocationsCollectionsDataStoresBranchesOperationsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresBranchesOperationsListCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// IfNoneMatch sets the 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. Use googleapi.IsNotModified to check whether the response +// error from Do is the result of In-None-Match. +func (c *ProjectsLocationsCollectionsDataStoresBranchesOperationsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsCollectionsDataStoresBranchesOperationsListCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do method. Any +// pending HTTP request will be aborted if the provided context is +// canceled. +func (c *ProjectsLocationsCollectionsDataStoresBranchesOperationsListCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresBranchesOperationsListCall { + c.ctx_ = ctx + return c +} + +// Header returns an http.Header that can be modified by the caller to +// add HTTP headers to the request. +func (c *ProjectsLocationsCollectionsDataStoresBranchesOperationsListCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsCollectionsDataStoresBranchesOperationsListCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := make(http.Header) + reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) + for k, v := range c.header_ { + reqHeaders[k] = v + } + reqHeaders.Set("User-Agent", c.s.userAgent()) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) + } + var body io.Reader = nil + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}/operations") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("GET", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "name": c.name, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "discoveryengine.projects.locations.collections.dataStores.branches.operations.list" call. +// Exactly one of *GoogleLongrunningListOperationsResponse or error will +// be non-nil. Any non-2xx status code is an error. Response headers are +// in either +// *GoogleLongrunningListOperationsResponse.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 *ProjectsLocationsCollectionsDataStoresBranchesOperationsListCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningListOperationsResponse, 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 := &GoogleLongrunningListOperationsResponse{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil + // { + // "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/branches/{branchesId}/operations", + // "httpMethod": "GET", + // "id": "discoveryengine.projects.locations.collections.dataStores.branches.operations.list", + // "parameterOrder": [ + // "name" + // ], + // "parameters": { + // "filter": { + // "description": "The standard list filter.", + // "location": "query", + // "type": "string" + // }, + // "name": { + // "description": "The name of the operation's parent resource.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/branches/[^/]+$", + // "required": true, + // "type": "string" + // }, + // "pageSize": { + // "description": "The standard list page size.", + // "format": "int32", + // "location": "query", + // "type": "integer" + // }, + // "pageToken": { + // "description": "The standard list page token.", + // "location": "query", + // "type": "string" + // } + // }, + // "path": "v1beta/{+name}/operations", + // "response": { + // "$ref": "GoogleLongrunningListOperationsResponse" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// 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 *ProjectsLocationsCollectionsDataStoresBranchesOperationsListCall) Pages(ctx context.Context, f func(*GoogleLongrunningListOperationsResponse) error) error { + c.ctx_ = ctx + defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point + 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) + } +} + +// method id "discoveryengine.projects.locations.collections.dataStores.conversations.converse": + +type ProjectsLocationsCollectionsDataStoresConversationsConverseCall struct { + s *Service + name string + googleclouddiscoveryenginev1betaconverseconversationrequest *GoogleCloudDiscoveryengineV1betaConverseConversationRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Converse: Converses a conversation. +// +// - name: The resource name of the Conversation to get. Format: +// `projects/{project_number}/locations/{location_id}/collections/{coll +// ection}/dataStores/{data_store_id}/conversations/{conversation_id}`. +// Use +// `projects/{project_number}/locations/{location_id}/collections/{coll +// ection}/dataStores/{data_store_id}/conversations/-` to activate +// auto session mode, which automatically creates a new conversation +// inside a ConverseConversation session. +func (r *ProjectsLocationsCollectionsDataStoresConversationsService) Converse(name string, googleclouddiscoveryenginev1betaconverseconversationrequest *GoogleCloudDiscoveryengineV1betaConverseConversationRequest) *ProjectsLocationsCollectionsDataStoresConversationsConverseCall { + c := &ProjectsLocationsCollectionsDataStoresConversationsConverseCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + c.googleclouddiscoveryenginev1betaconverseconversationrequest = googleclouddiscoveryenginev1betaconverseconversationrequest + return c +} + +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse +// for more information. +func (c *ProjectsLocationsCollectionsDataStoresConversationsConverseCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresConversationsConverseCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. Any +// pending HTTP request will be aborted if the provided context is +// canceled. +func (c *ProjectsLocationsCollectionsDataStoresConversationsConverseCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresConversationsConverseCall { + c.ctx_ = ctx + return c +} + +// Header returns an http.Header that can be modified by the caller to +// add HTTP headers to the request. +func (c *ProjectsLocationsCollectionsDataStoresConversationsConverseCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsCollectionsDataStoresConversationsConverseCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := make(http.Header) + reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) + for k, v := range c.header_ { + reqHeaders[k] = v + } + reqHeaders.Set("User-Agent", c.s.userAgent()) + var body io.Reader = nil + body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddiscoveryenginev1betaconverseconversationrequest) + if err != nil { + return nil, err + } + reqHeaders.Set("Content-Type", "application/json") + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}:converse") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("POST", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "name": c.name, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "discoveryengine.projects.locations.collections.dataStores.conversations.converse" call. +// Exactly one of +// *GoogleCloudDiscoveryengineV1betaConverseConversationResponse or +// error will be non-nil. Any non-2xx status code is an error. Response +// headers are in either +// *GoogleCloudDiscoveryengineV1betaConverseConversationResponse.ServerRe +// sponse.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 *ProjectsLocationsCollectionsDataStoresConversationsConverseCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1betaConverseConversationResponse, 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 := &GoogleCloudDiscoveryengineV1betaConverseConversationResponse{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil + // { + // "description": "Converses a conversation.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/conversations/{conversationsId}:converse", + // "httpMethod": "POST", + // "id": "discoveryengine.projects.locations.collections.dataStores.conversations.converse", + // "parameterOrder": [ + // "name" + // ], + // "parameters": { + // "name": { + // "description": "Required. The resource name of the Conversation to get. Format: `projects/{project_number}/locations/{location_id}/collections/{collection}/dataStores/{data_store_id}/conversations/{conversation_id}`. Use `projects/{project_number}/locations/{location_id}/collections/{collection}/dataStores/{data_store_id}/conversations/-` to activate auto session mode, which automatically creates a new conversation inside a ConverseConversation session.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/conversations/[^/]+$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1beta/{+name}:converse", + // "request": { + // "$ref": "GoogleCloudDiscoveryengineV1betaConverseConversationRequest" + // }, + // "response": { + // "$ref": "GoogleCloudDiscoveryengineV1betaConverseConversationResponse" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "discoveryengine.projects.locations.collections.dataStores.conversations.create": + +type ProjectsLocationsCollectionsDataStoresConversationsCreateCall struct { + s *Service + parent string + googleclouddiscoveryenginev1betaconversation *GoogleCloudDiscoveryengineV1betaConversation + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Create: Creates a Conversation. If the Conversation to create already +// exists, an ALREADY_EXISTS error is returned. +// +// - parent: Full resource name of parent data store. Format: +// `projects/{project_number}/locations/{location_id}/collections/{coll +// ection}/dataStores/{data_store_id}`. +func (r *ProjectsLocationsCollectionsDataStoresConversationsService) Create(parent string, googleclouddiscoveryenginev1betaconversation *GoogleCloudDiscoveryengineV1betaConversation) *ProjectsLocationsCollectionsDataStoresConversationsCreateCall { + c := &ProjectsLocationsCollectionsDataStoresConversationsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + c.googleclouddiscoveryenginev1betaconversation = googleclouddiscoveryenginev1betaconversation + return c +} + +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse +// for more information. +func (c *ProjectsLocationsCollectionsDataStoresConversationsCreateCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresConversationsCreateCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. Any +// pending HTTP request will be aborted if the provided context is +// canceled. +func (c *ProjectsLocationsCollectionsDataStoresConversationsCreateCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresConversationsCreateCall { + c.ctx_ = ctx + return c +} + +// Header returns an http.Header that can be modified by the caller to +// add HTTP headers to the request. +func (c *ProjectsLocationsCollectionsDataStoresConversationsCreateCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsCollectionsDataStoresConversationsCreateCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := make(http.Header) + reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) + for k, v := range c.header_ { + reqHeaders[k] = v + } + reqHeaders.Set("User-Agent", c.s.userAgent()) + var body io.Reader = nil + body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddiscoveryenginev1betaconversation) + if err != nil { + return nil, err + } + reqHeaders.Set("Content-Type", "application/json") + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+parent}/conversations") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("POST", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "parent": c.parent, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "discoveryengine.projects.locations.collections.dataStores.conversations.create" call. +// Exactly one of *GoogleCloudDiscoveryengineV1betaConversation or error +// will be non-nil. Any non-2xx status code is an error. Response +// headers are in either +// *GoogleCloudDiscoveryengineV1betaConversation.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 *ProjectsLocationsCollectionsDataStoresConversationsCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1betaConversation, 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 := &GoogleCloudDiscoveryengineV1betaConversation{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil + // { + // "description": "Creates a Conversation. If the Conversation to create already exists, an ALREADY_EXISTS error is returned.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/conversations", + // "httpMethod": "POST", + // "id": "discoveryengine.projects.locations.collections.dataStores.conversations.create", + // "parameterOrder": [ + // "parent" + // ], + // "parameters": { + // "parent": { + // "description": "Required. Full resource name of parent data store. Format: `projects/{project_number}/locations/{location_id}/collections/{collection}/dataStores/{data_store_id}`", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1beta/{+parent}/conversations", + // "request": { + // "$ref": "GoogleCloudDiscoveryengineV1betaConversation" + // }, + // "response": { + // "$ref": "GoogleCloudDiscoveryengineV1betaConversation" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "discoveryengine.projects.locations.collections.dataStores.conversations.delete": + +type ProjectsLocationsCollectionsDataStoresConversationsDeleteCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Delete: Deletes a Conversation. If the Conversation to delete does +// not exist, a NOT_FOUND error is returned. +// +// - name: The resource name of the Conversation to delete. Format: +// `projects/{project_number}/locations/{location_id}/collections/{coll +// ection}/dataStores/{data_store_id}/conversations/{conversation_id}`. +func (r *ProjectsLocationsCollectionsDataStoresConversationsService) Delete(name string) *ProjectsLocationsCollectionsDataStoresConversationsDeleteCall { + c := &ProjectsLocationsCollectionsDataStoresConversationsDeleteCall{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 information. +func (c *ProjectsLocationsCollectionsDataStoresConversationsDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresConversationsDeleteCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. Any +// pending HTTP request will be aborted if the provided context is +// canceled. +func (c *ProjectsLocationsCollectionsDataStoresConversationsDeleteCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresConversationsDeleteCall { + c.ctx_ = ctx + return c +} + +// Header returns an http.Header that can be modified by the caller to +// add HTTP headers to the request. +func (c *ProjectsLocationsCollectionsDataStoresConversationsDeleteCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsCollectionsDataStoresConversationsDeleteCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := make(http.Header) + reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) + for k, v := range c.header_ { + reqHeaders[k] = v + } + reqHeaders.Set("User-Agent", c.s.userAgent()) + var body io.Reader = nil + 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("DELETE", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "name": c.name, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "discoveryengine.projects.locations.collections.dataStores.conversations.delete" call. +// Exactly one of *GoogleProtobufEmpty or error will be non-nil. Any +// non-2xx status code is an error. Response headers are in either +// *GoogleProtobufEmpty.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 *ProjectsLocationsCollectionsDataStoresConversationsDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, 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 := &GoogleProtobufEmpty{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil + // { + // "description": "Deletes a Conversation. If the Conversation to delete does not exist, a NOT_FOUND error is returned.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/conversations/{conversationsId}", + // "httpMethod": "DELETE", + // "id": "discoveryengine.projects.locations.collections.dataStores.conversations.delete", + // "parameterOrder": [ + // "name" + // ], + // "parameters": { + // "name": { + // "description": "Required. The resource name of the Conversation to delete. Format: `projects/{project_number}/locations/{location_id}/collections/{collection}/dataStores/{data_store_id}/conversations/{conversation_id}`", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/conversations/[^/]+$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1beta/{+name}", + // "response": { + // "$ref": "GoogleProtobufEmpty" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "discoveryengine.projects.locations.collections.dataStores.conversations.get": + +type ProjectsLocationsCollectionsDataStoresConversationsGetCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// Get: Gets a Conversation. +// +// - name: The resource name of the Conversation to get. Format: +// `projects/{project_number}/locations/{location_id}/collections/{coll +// ection}/dataStores/{data_store_id}/conversations/{conversation_id}`. +func (r *ProjectsLocationsCollectionsDataStoresConversationsService) Get(name string) *ProjectsLocationsCollectionsDataStoresConversationsGetCall { + c := &ProjectsLocationsCollectionsDataStoresConversationsGetCall{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 information. +func (c *ProjectsLocationsCollectionsDataStoresConversationsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresConversationsGetCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// IfNoneMatch sets the 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. Use googleapi.IsNotModified to check whether the response +// error from Do is the result of In-None-Match. +func (c *ProjectsLocationsCollectionsDataStoresConversationsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsCollectionsDataStoresConversationsGetCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do method. Any +// pending HTTP request will be aborted if the provided context is +// canceled. +func (c *ProjectsLocationsCollectionsDataStoresConversationsGetCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresConversationsGetCall { + c.ctx_ = ctx + return c +} + +// Header returns an http.Header that can be modified by the caller to +// add HTTP headers to the request. +func (c *ProjectsLocationsCollectionsDataStoresConversationsGetCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsCollectionsDataStoresConversationsGetCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := make(http.Header) + reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) + for k, v := range c.header_ { + reqHeaders[k] = v + } + reqHeaders.Set("User-Agent", c.s.userAgent()) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) + } + var body io.Reader = nil + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("GET", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "name": c.name, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "discoveryengine.projects.locations.collections.dataStores.conversations.get" call. +// Exactly one of *GoogleCloudDiscoveryengineV1betaConversation or error +// will be non-nil. Any non-2xx status code is an error. Response +// headers are in either +// *GoogleCloudDiscoveryengineV1betaConversation.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 *ProjectsLocationsCollectionsDataStoresConversationsGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1betaConversation, 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 := &GoogleCloudDiscoveryengineV1betaConversation{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil + // { + // "description": "Gets a Conversation.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/conversations/{conversationsId}", + // "httpMethod": "GET", + // "id": "discoveryengine.projects.locations.collections.dataStores.conversations.get", + // "parameterOrder": [ + // "name" + // ], + // "parameters": { + // "name": { + // "description": "Required. The resource name of the Conversation to get. Format: `projects/{project_number}/locations/{location_id}/collections/{collection}/dataStores/{data_store_id}/conversations/{conversation_id}`", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/conversations/[^/]+$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1beta/{+name}", + // "response": { + // "$ref": "GoogleCloudDiscoveryengineV1betaConversation" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "discoveryengine.projects.locations.collections.dataStores.conversations.list": + +type ProjectsLocationsCollectionsDataStoresConversationsListCall struct { + s *Service + parent string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// List: Lists all Conversations by their parent DataStore. +// +// - parent: The data store resource name. Format: +// `projects/{project_number}/locations/{location_id}/collections/{coll +// ection}/dataStores/{data_store_id}`. +func (r *ProjectsLocationsCollectionsDataStoresConversationsService) List(parent string) *ProjectsLocationsCollectionsDataStoresConversationsListCall { + c := &ProjectsLocationsCollectionsDataStoresConversationsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + return c +} + +// Filter sets the optional parameter "filter": A filter to apply on the +// list results. The supported features are: user_pseudo_id, state. +// Example: "user_pseudo_id = some_id" +func (c *ProjectsLocationsCollectionsDataStoresConversationsListCall) Filter(filter string) *ProjectsLocationsCollectionsDataStoresConversationsListCall { + c.urlParams_.Set("filter", filter) + 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: * `update_time` * +// `create_time` * `conversation_name` Example: "update_time desc" +// "create_time" +func (c *ProjectsLocationsCollectionsDataStoresConversationsListCall) OrderBy(orderBy string) *ProjectsLocationsCollectionsDataStoresConversationsListCall { + c.urlParams_.Set("orderBy", orderBy) + return c +} + +// PageSize sets the optional parameter "pageSize": Maximum number of +// results to return. If unspecified, defaults to 50. Max allowed value +// is 1000. +func (c *ProjectsLocationsCollectionsDataStoresConversationsListCall) PageSize(pageSize int64) *ProjectsLocationsCollectionsDataStoresConversationsListCall { + c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) + return c +} + +// PageToken sets the optional parameter "pageToken": A page token, +// received from a previous `ListConversations` call. Provide this to +// retrieve the subsequent page. +func (c *ProjectsLocationsCollectionsDataStoresConversationsListCall) PageToken(pageToken string) *ProjectsLocationsCollectionsDataStoresConversationsListCall { + 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 information. +func (c *ProjectsLocationsCollectionsDataStoresConversationsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresConversationsListCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// IfNoneMatch sets the 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. Use googleapi.IsNotModified to check whether the response +// error from Do is the result of In-None-Match. +func (c *ProjectsLocationsCollectionsDataStoresConversationsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsCollectionsDataStoresConversationsListCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do method. Any +// pending HTTP request will be aborted if the provided context is +// canceled. +func (c *ProjectsLocationsCollectionsDataStoresConversationsListCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresConversationsListCall { + c.ctx_ = ctx + return c +} + +// Header returns an http.Header that can be modified by the caller to +// add HTTP headers to the request. +func (c *ProjectsLocationsCollectionsDataStoresConversationsListCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsCollectionsDataStoresConversationsListCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := make(http.Header) + reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) + for k, v := range c.header_ { + reqHeaders[k] = v + } + reqHeaders.Set("User-Agent", c.s.userAgent()) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) + } + var body io.Reader = nil + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+parent}/conversations") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("GET", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "parent": c.parent, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "discoveryengine.projects.locations.collections.dataStores.conversations.list" call. +// Exactly one of +// *GoogleCloudDiscoveryengineV1betaListConversationsResponse or error +// will be non-nil. Any non-2xx status code is an error. Response +// headers are in either +// *GoogleCloudDiscoveryengineV1betaListConversationsResponse.ServerRespo +// nse.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 *ProjectsLocationsCollectionsDataStoresConversationsListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1betaListConversationsResponse, 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 := &GoogleCloudDiscoveryengineV1betaListConversationsResponse{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil + // { + // "description": "Lists all Conversations by their parent DataStore.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/conversations", + // "httpMethod": "GET", + // "id": "discoveryengine.projects.locations.collections.dataStores.conversations.list", + // "parameterOrder": [ + // "parent" + // ], + // "parameters": { + // "filter": { + // "description": "A filter to apply on the list results. The supported features are: user_pseudo_id, state. Example: \"user_pseudo_id = some_id\"", + // "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: * `update_time` * `create_time` * `conversation_name` Example: \"update_time desc\" \"create_time\"", + // "location": "query", + // "type": "string" + // }, + // "pageSize": { + // "description": "Maximum number of results to return. If unspecified, defaults to 50. Max allowed value is 1000.", + // "format": "int32", + // "location": "query", + // "type": "integer" + // }, + // "pageToken": { + // "description": "A page token, received from a previous `ListConversations` call. Provide this to retrieve the subsequent page.", + // "location": "query", + // "type": "string" + // }, + // "parent": { + // "description": "Required. The data store resource name. Format: `projects/{project_number}/locations/{location_id}/collections/{collection}/dataStores/{data_store_id}`", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1beta/{+parent}/conversations", + // "response": { + // "$ref": "GoogleCloudDiscoveryengineV1betaListConversationsResponse" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// 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 *ProjectsLocationsCollectionsDataStoresConversationsListCall) Pages(ctx context.Context, f func(*GoogleCloudDiscoveryengineV1betaListConversationsResponse) error) error { + c.ctx_ = ctx + defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point + 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) + } +} + +// method id "discoveryengine.projects.locations.collections.dataStores.conversations.patch": + +type ProjectsLocationsCollectionsDataStoresConversationsPatchCall struct { + s *Service + name string + googleclouddiscoveryenginev1betaconversation *GoogleCloudDiscoveryengineV1betaConversation + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Patch: Updates a Conversation. Conversation action type cannot be +// changed. If the Conversation to update does not exist, a NOT_FOUND +// error is returned. +// +// - name: Immutable. Fully qualified name +// `project/*/locations/global/collections/{collection}/dataStore/*/con +// versations/*` or +// `project/*/locations/global/collections/{collection}/engines/*/conve +// rsations/*`. +func (r *ProjectsLocationsCollectionsDataStoresConversationsService) Patch(name string, googleclouddiscoveryenginev1betaconversation *GoogleCloudDiscoveryengineV1betaConversation) *ProjectsLocationsCollectionsDataStoresConversationsPatchCall { + c := &ProjectsLocationsCollectionsDataStoresConversationsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + c.googleclouddiscoveryenginev1betaconversation = googleclouddiscoveryenginev1betaconversation + return c +} + +// UpdateMask sets the optional parameter "updateMask": Indicates which +// fields in the provided Conversation to update. The following are NOT +// supported: * Conversation.name If not set or empty, all supported +// fields are updated. +func (c *ProjectsLocationsCollectionsDataStoresConversationsPatchCall) UpdateMask(updateMask string) *ProjectsLocationsCollectionsDataStoresConversationsPatchCall { + 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 information. +func (c *ProjectsLocationsCollectionsDataStoresConversationsPatchCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresConversationsPatchCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. Any +// pending HTTP request will be aborted if the provided context is +// canceled. +func (c *ProjectsLocationsCollectionsDataStoresConversationsPatchCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresConversationsPatchCall { + c.ctx_ = ctx + return c +} + +// Header returns an http.Header that can be modified by the caller to +// add HTTP headers to the request. +func (c *ProjectsLocationsCollectionsDataStoresConversationsPatchCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsCollectionsDataStoresConversationsPatchCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := make(http.Header) + reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) + for k, v := range c.header_ { + reqHeaders[k] = v + } + reqHeaders.Set("User-Agent", c.s.userAgent()) + var body io.Reader = nil + body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddiscoveryenginev1betaconversation) + if err != nil { + return nil, err + } + reqHeaders.Set("Content-Type", "application/json") + 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, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "discoveryengine.projects.locations.collections.dataStores.conversations.patch" call. +// Exactly one of *GoogleCloudDiscoveryengineV1betaConversation or error +// will be non-nil. Any non-2xx status code is an error. Response +// headers are in either +// *GoogleCloudDiscoveryengineV1betaConversation.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 *ProjectsLocationsCollectionsDataStoresConversationsPatchCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1betaConversation, 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 := &GoogleCloudDiscoveryengineV1betaConversation{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil + // { + // "description": "Updates a Conversation. Conversation action type cannot be changed. If the Conversation to update does not exist, a NOT_FOUND error is returned.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/conversations/{conversationsId}", + // "httpMethod": "PATCH", + // "id": "discoveryengine.projects.locations.collections.dataStores.conversations.patch", + // "parameterOrder": [ + // "name" + // ], + // "parameters": { + // "name": { + // "description": "Immutable. Fully qualified name `project/*/locations/global/collections/{collection}/dataStore/*/conversations/*` or `project/*/locations/global/collections/{collection}/engines/*/conversations/*`.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/conversations/[^/]+$", + // "required": true, + // "type": "string" + // }, + // "updateMask": { + // "description": "Indicates which fields in the provided Conversation to update. The following are NOT supported: * Conversation.name If not set or empty, all supported fields are updated.", + // "format": "google-fieldmask", + // "location": "query", + // "type": "string" + // } + // }, + // "path": "v1beta/{+name}", + // "request": { + // "$ref": "GoogleCloudDiscoveryengineV1betaConversation" + // }, + // "response": { + // "$ref": "GoogleCloudDiscoveryengineV1betaConversation" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "discoveryengine.projects.locations.collections.dataStores.models.operations.get": + +type ProjectsLocationsCollectionsDataStoresModelsOperationsGetCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// Get: Gets the latest state of a long-running operation. Clients can +// use this method to poll the operation result at intervals as +// recommended by the API service. +// +// - name: The name of the operation resource. +func (r *ProjectsLocationsCollectionsDataStoresModelsOperationsService) Get(name string) *ProjectsLocationsCollectionsDataStoresModelsOperationsGetCall { + c := &ProjectsLocationsCollectionsDataStoresModelsOperationsGetCall{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 information. +func (c *ProjectsLocationsCollectionsDataStoresModelsOperationsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresModelsOperationsGetCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// IfNoneMatch sets the 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. Use googleapi.IsNotModified to check whether the response +// error from Do is the result of In-None-Match. +func (c *ProjectsLocationsCollectionsDataStoresModelsOperationsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsCollectionsDataStoresModelsOperationsGetCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do method. Any +// pending HTTP request will be aborted if the provided context is +// canceled. +func (c *ProjectsLocationsCollectionsDataStoresModelsOperationsGetCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresModelsOperationsGetCall { + c.ctx_ = ctx + return c +} + +// Header returns an http.Header that can be modified by the caller to +// add HTTP headers to the request. +func (c *ProjectsLocationsCollectionsDataStoresModelsOperationsGetCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsCollectionsDataStoresModelsOperationsGetCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := make(http.Header) + reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) + for k, v := range c.header_ { + reqHeaders[k] = v + } + reqHeaders.Set("User-Agent", c.s.userAgent()) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) + } + var body io.Reader = nil + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("GET", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "name": c.name, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "discoveryengine.projects.locations.collections.dataStores.models.operations.get" call. +// Exactly one of *GoogleLongrunningOperation or error will be non-nil. +// 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 *ProjectsLocationsCollectionsDataStoresModelsOperationsGetCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &GoogleLongrunningOperation{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil + // { + // "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": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/models/{modelsId}/operations/{operationsId}", + // "httpMethod": "GET", + // "id": "discoveryengine.projects.locations.collections.dataStores.models.operations.get", + // "parameterOrder": [ + // "name" + // ], + // "parameters": { + // "name": { + // "description": "The name of the operation resource.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/models/[^/]+/operations/[^/]+$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1beta/{+name}", + // "response": { + // "$ref": "GoogleLongrunningOperation" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "discoveryengine.projects.locations.collections.dataStores.models.operations.list": + +type ProjectsLocationsCollectionsDataStoresModelsOperationsListCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// List: Lists operations that match the specified filter in the +// request. If the server doesn't support this method, it returns +// `UNIMPLEMENTED`. +// +// - name: The name of the operation's parent resource. +func (r *ProjectsLocationsCollectionsDataStoresModelsOperationsService) List(name string) *ProjectsLocationsCollectionsDataStoresModelsOperationsListCall { + c := &ProjectsLocationsCollectionsDataStoresModelsOperationsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + return c +} + +// Filter sets the optional parameter "filter": The standard list +// filter. +func (c *ProjectsLocationsCollectionsDataStoresModelsOperationsListCall) Filter(filter string) *ProjectsLocationsCollectionsDataStoresModelsOperationsListCall { + c.urlParams_.Set("filter", filter) + return c +} + +// PageSize sets the optional parameter "pageSize": The standard list +// page size. +func (c *ProjectsLocationsCollectionsDataStoresModelsOperationsListCall) PageSize(pageSize int64) *ProjectsLocationsCollectionsDataStoresModelsOperationsListCall { + c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) + return c +} + +// PageToken sets the optional parameter "pageToken": The standard list +// page token. +func (c *ProjectsLocationsCollectionsDataStoresModelsOperationsListCall) PageToken(pageToken string) *ProjectsLocationsCollectionsDataStoresModelsOperationsListCall { + 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 information. +func (c *ProjectsLocationsCollectionsDataStoresModelsOperationsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresModelsOperationsListCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// IfNoneMatch sets the 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. Use googleapi.IsNotModified to check whether the response +// error from Do is the result of In-None-Match. +func (c *ProjectsLocationsCollectionsDataStoresModelsOperationsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsCollectionsDataStoresModelsOperationsListCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do method. Any +// pending HTTP request will be aborted if the provided context is +// canceled. +func (c *ProjectsLocationsCollectionsDataStoresModelsOperationsListCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresModelsOperationsListCall { + c.ctx_ = ctx + return c +} + +// Header returns an http.Header that can be modified by the caller to +// add HTTP headers to the request. +func (c *ProjectsLocationsCollectionsDataStoresModelsOperationsListCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsCollectionsDataStoresModelsOperationsListCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := make(http.Header) + reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) + for k, v := range c.header_ { + reqHeaders[k] = v + } + reqHeaders.Set("User-Agent", c.s.userAgent()) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) + } + var body io.Reader = nil + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}/operations") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("GET", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "name": c.name, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "discoveryengine.projects.locations.collections.dataStores.models.operations.list" call. +// Exactly one of *GoogleLongrunningListOperationsResponse or error will +// be non-nil. Any non-2xx status code is an error. Response headers are +// in either +// *GoogleLongrunningListOperationsResponse.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 *ProjectsLocationsCollectionsDataStoresModelsOperationsListCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningListOperationsResponse, 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 := &GoogleLongrunningListOperationsResponse{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil + // { + // "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/models/{modelsId}/operations", + // "httpMethod": "GET", + // "id": "discoveryengine.projects.locations.collections.dataStores.models.operations.list", + // "parameterOrder": [ + // "name" + // ], + // "parameters": { + // "filter": { + // "description": "The standard list filter.", + // "location": "query", + // "type": "string" + // }, + // "name": { + // "description": "The name of the operation's parent resource.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/models/[^/]+$", + // "required": true, + // "type": "string" + // }, + // "pageSize": { + // "description": "The standard list page size.", + // "format": "int32", + // "location": "query", + // "type": "integer" + // }, + // "pageToken": { + // "description": "The standard list page token.", + // "location": "query", + // "type": "string" + // } + // }, + // "path": "v1beta/{+name}/operations", + // "response": { + // "$ref": "GoogleLongrunningListOperationsResponse" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// 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 *ProjectsLocationsCollectionsDataStoresModelsOperationsListCall) Pages(ctx context.Context, f func(*GoogleLongrunningListOperationsResponse) error) error { + c.ctx_ = ctx + defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point + 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) + } +} + +// method id "discoveryengine.projects.locations.collections.dataStores.operations.get": + +type ProjectsLocationsCollectionsDataStoresOperationsGetCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// Get: Gets the latest state of a long-running operation. Clients can +// use this method to poll the operation result at intervals as +// recommended by the API service. +// +// - name: The name of the operation resource. +func (r *ProjectsLocationsCollectionsDataStoresOperationsService) Get(name string) *ProjectsLocationsCollectionsDataStoresOperationsGetCall { + c := &ProjectsLocationsCollectionsDataStoresOperationsGetCall{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 information. +func (c *ProjectsLocationsCollectionsDataStoresOperationsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresOperationsGetCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// IfNoneMatch sets the 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. Use googleapi.IsNotModified to check whether the response +// error from Do is the result of In-None-Match. +func (c *ProjectsLocationsCollectionsDataStoresOperationsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsCollectionsDataStoresOperationsGetCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do method. Any +// pending HTTP request will be aborted if the provided context is +// canceled. +func (c *ProjectsLocationsCollectionsDataStoresOperationsGetCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresOperationsGetCall { + c.ctx_ = ctx + return c +} + +// Header returns an http.Header that can be modified by the caller to +// add HTTP headers to the request. +func (c *ProjectsLocationsCollectionsDataStoresOperationsGetCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsCollectionsDataStoresOperationsGetCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := make(http.Header) + reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) + for k, v := range c.header_ { + reqHeaders[k] = v + } + reqHeaders.Set("User-Agent", c.s.userAgent()) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) + } + var body io.Reader = nil + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("GET", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "name": c.name, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "discoveryengine.projects.locations.collections.dataStores.operations.get" call. +// Exactly one of *GoogleLongrunningOperation or error will be non-nil. +// 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 *ProjectsLocationsCollectionsDataStoresOperationsGetCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &GoogleLongrunningOperation{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil + // { + // "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": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/operations/{operationsId}", + // "httpMethod": "GET", + // "id": "discoveryengine.projects.locations.collections.dataStores.operations.get", + // "parameterOrder": [ + // "name" + // ], + // "parameters": { + // "name": { + // "description": "The name of the operation resource.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/operations/[^/]+$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1beta/{+name}", + // "response": { + // "$ref": "GoogleLongrunningOperation" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "discoveryengine.projects.locations.collections.dataStores.operations.list": + +type ProjectsLocationsCollectionsDataStoresOperationsListCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// List: Lists operations that match the specified filter in the +// request. If the server doesn't support this method, it returns +// `UNIMPLEMENTED`. +// +// - name: The name of the operation's parent resource. +func (r *ProjectsLocationsCollectionsDataStoresOperationsService) List(name string) *ProjectsLocationsCollectionsDataStoresOperationsListCall { + c := &ProjectsLocationsCollectionsDataStoresOperationsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + return c +} + +// Filter sets the optional parameter "filter": The standard list +// filter. +func (c *ProjectsLocationsCollectionsDataStoresOperationsListCall) Filter(filter string) *ProjectsLocationsCollectionsDataStoresOperationsListCall { + c.urlParams_.Set("filter", filter) + return c +} + +// PageSize sets the optional parameter "pageSize": The standard list +// page size. +func (c *ProjectsLocationsCollectionsDataStoresOperationsListCall) PageSize(pageSize int64) *ProjectsLocationsCollectionsDataStoresOperationsListCall { + c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) + return c +} + +// PageToken sets the optional parameter "pageToken": The standard list +// page token. +func (c *ProjectsLocationsCollectionsDataStoresOperationsListCall) PageToken(pageToken string) *ProjectsLocationsCollectionsDataStoresOperationsListCall { + 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 information. +func (c *ProjectsLocationsCollectionsDataStoresOperationsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresOperationsListCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// IfNoneMatch sets the 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. Use googleapi.IsNotModified to check whether the response +// error from Do is the result of In-None-Match. +func (c *ProjectsLocationsCollectionsDataStoresOperationsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsCollectionsDataStoresOperationsListCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do method. Any +// pending HTTP request will be aborted if the provided context is +// canceled. +func (c *ProjectsLocationsCollectionsDataStoresOperationsListCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresOperationsListCall { + c.ctx_ = ctx + return c +} + +// Header returns an http.Header that can be modified by the caller to +// add HTTP headers to the request. +func (c *ProjectsLocationsCollectionsDataStoresOperationsListCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsCollectionsDataStoresOperationsListCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := make(http.Header) + reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) + for k, v := range c.header_ { + reqHeaders[k] = v + } + reqHeaders.Set("User-Agent", c.s.userAgent()) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) + } + var body io.Reader = nil + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}/operations") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("GET", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "name": c.name, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "discoveryengine.projects.locations.collections.dataStores.operations.list" call. +// Exactly one of *GoogleLongrunningListOperationsResponse or error will +// be non-nil. Any non-2xx status code is an error. Response headers are +// in either +// *GoogleLongrunningListOperationsResponse.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 *ProjectsLocationsCollectionsDataStoresOperationsListCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningListOperationsResponse, 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 := &GoogleLongrunningListOperationsResponse{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil + // { + // "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/operations", + // "httpMethod": "GET", + // "id": "discoveryengine.projects.locations.collections.dataStores.operations.list", + // "parameterOrder": [ + // "name" + // ], + // "parameters": { + // "filter": { + // "description": "The standard list filter.", + // "location": "query", + // "type": "string" + // }, + // "name": { + // "description": "The name of the operation's parent resource.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+$", + // "required": true, + // "type": "string" + // }, + // "pageSize": { + // "description": "The standard list page size.", + // "format": "int32", + // "location": "query", + // "type": "integer" + // }, + // "pageToken": { + // "description": "The standard list page token.", + // "location": "query", + // "type": "string" + // } + // }, + // "path": "v1beta/{+name}/operations", + // "response": { + // "$ref": "GoogleLongrunningListOperationsResponse" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// 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 *ProjectsLocationsCollectionsDataStoresOperationsListCall) Pages(ctx context.Context, f func(*GoogleLongrunningListOperationsResponse) error) error { + c.ctx_ = ctx + defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point + 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) + } +} + +// method id "discoveryengine.projects.locations.collections.dataStores.schemas.create": + +type ProjectsLocationsCollectionsDataStoresSchemasCreateCall struct { + s *Service + parent string + googleclouddiscoveryenginev1betaschema *GoogleCloudDiscoveryengineV1betaSchema + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Create: Creates a Schema. +// +// - parent: The parent data store resource name, in the format of +// `projects/{project}/locations/{location}/collections/{collection}/da +// taStores/{data_store}`. +func (r *ProjectsLocationsCollectionsDataStoresSchemasService) Create(parent string, googleclouddiscoveryenginev1betaschema *GoogleCloudDiscoveryengineV1betaSchema) *ProjectsLocationsCollectionsDataStoresSchemasCreateCall { + c := &ProjectsLocationsCollectionsDataStoresSchemasCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + c.googleclouddiscoveryenginev1betaschema = googleclouddiscoveryenginev1betaschema + return c +} + +// SchemaId sets the optional parameter "schemaId": Required. The ID to +// use for the Schema, which will become the final component of the +// Schema.name. This field should conform to RFC-1034 +// (https://tools.ietf.org/html/rfc1034) standard with a length limit of +// 63 characters. +func (c *ProjectsLocationsCollectionsDataStoresSchemasCreateCall) SchemaId(schemaId string) *ProjectsLocationsCollectionsDataStoresSchemasCreateCall { + c.urlParams_.Set("schemaId", schemaId) + return c +} + +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse +// for more information. +func (c *ProjectsLocationsCollectionsDataStoresSchemasCreateCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresSchemasCreateCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. Any +// pending HTTP request will be aborted if the provided context is +// canceled. +func (c *ProjectsLocationsCollectionsDataStoresSchemasCreateCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresSchemasCreateCall { + c.ctx_ = ctx + return c +} + +// Header returns an http.Header that can be modified by the caller to +// add HTTP headers to the request. +func (c *ProjectsLocationsCollectionsDataStoresSchemasCreateCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsCollectionsDataStoresSchemasCreateCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := make(http.Header) + reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) + for k, v := range c.header_ { + reqHeaders[k] = v + } + reqHeaders.Set("User-Agent", c.s.userAgent()) + var body io.Reader = nil + body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddiscoveryenginev1betaschema) + if err != nil { + return nil, err + } + reqHeaders.Set("Content-Type", "application/json") + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+parent}/schemas") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("POST", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "parent": c.parent, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "discoveryengine.projects.locations.collections.dataStores.schemas.create" call. +// Exactly one of *GoogleLongrunningOperation or error will be non-nil. +// 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 *ProjectsLocationsCollectionsDataStoresSchemasCreateCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &GoogleLongrunningOperation{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil + // { + // "description": "Creates a Schema.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/schemas", + // "httpMethod": "POST", + // "id": "discoveryengine.projects.locations.collections.dataStores.schemas.create", + // "parameterOrder": [ + // "parent" + // ], + // "parameters": { + // "parent": { + // "description": "Required. The parent data store resource name, in the format of `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}`.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+$", + // "required": true, + // "type": "string" + // }, + // "schemaId": { + // "description": "Required. The ID to use for the Schema, which will become the final component of the Schema.name. This field should conform to [RFC-1034](https://tools.ietf.org/html/rfc1034) standard with a length limit of 63 characters.", + // "location": "query", + // "type": "string" + // } + // }, + // "path": "v1beta/{+parent}/schemas", + // "request": { + // "$ref": "GoogleCloudDiscoveryengineV1betaSchema" + // }, + // "response": { + // "$ref": "GoogleLongrunningOperation" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "discoveryengine.projects.locations.collections.dataStores.schemas.delete": + +type ProjectsLocationsCollectionsDataStoresSchemasDeleteCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Delete: Deletes a Schema. +// +// - name: The full resource name of the schema, in the format of +// `projects/{project}/locations/{location}/collections/{collection}/da +// taStores/{data_store}/schemas/{schema}`. +func (r *ProjectsLocationsCollectionsDataStoresSchemasService) Delete(name string) *ProjectsLocationsCollectionsDataStoresSchemasDeleteCall { + c := &ProjectsLocationsCollectionsDataStoresSchemasDeleteCall{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 information. +func (c *ProjectsLocationsCollectionsDataStoresSchemasDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresSchemasDeleteCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. Any +// pending HTTP request will be aborted if the provided context is +// canceled. +func (c *ProjectsLocationsCollectionsDataStoresSchemasDeleteCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresSchemasDeleteCall { + c.ctx_ = ctx + return c +} + +// Header returns an http.Header that can be modified by the caller to +// add HTTP headers to the request. +func (c *ProjectsLocationsCollectionsDataStoresSchemasDeleteCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsCollectionsDataStoresSchemasDeleteCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := make(http.Header) + reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) + for k, v := range c.header_ { + reqHeaders[k] = v + } + reqHeaders.Set("User-Agent", c.s.userAgent()) + var body io.Reader = nil + 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("DELETE", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "name": c.name, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "discoveryengine.projects.locations.collections.dataStores.schemas.delete" call. +// Exactly one of *GoogleLongrunningOperation or error will be non-nil. +// 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 *ProjectsLocationsCollectionsDataStoresSchemasDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &GoogleLongrunningOperation{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil + // { + // "description": "Deletes a Schema.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/schemas/{schemasId}", + // "httpMethod": "DELETE", + // "id": "discoveryengine.projects.locations.collections.dataStores.schemas.delete", + // "parameterOrder": [ + // "name" + // ], + // "parameters": { + // "name": { + // "description": "Required. The full resource name of the schema, in the format of `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/schemas/{schema}`.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/schemas/[^/]+$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1beta/{+name}", + // "response": { + // "$ref": "GoogleLongrunningOperation" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "discoveryengine.projects.locations.collections.dataStores.schemas.get": + +type ProjectsLocationsCollectionsDataStoresSchemasGetCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// Get: Gets a Schema. +// +// - name: The full resource name of the schema, in the format of +// `projects/{project}/locations/{location}/collections/{collection}/da +// taStores/{data_store}/schemas/{schema}`. +func (r *ProjectsLocationsCollectionsDataStoresSchemasService) Get(name string) *ProjectsLocationsCollectionsDataStoresSchemasGetCall { + c := &ProjectsLocationsCollectionsDataStoresSchemasGetCall{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 information. +func (c *ProjectsLocationsCollectionsDataStoresSchemasGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresSchemasGetCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// IfNoneMatch sets the 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. Use googleapi.IsNotModified to check whether the response +// error from Do is the result of In-None-Match. +func (c *ProjectsLocationsCollectionsDataStoresSchemasGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsCollectionsDataStoresSchemasGetCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do method. Any +// pending HTTP request will be aborted if the provided context is +// canceled. +func (c *ProjectsLocationsCollectionsDataStoresSchemasGetCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresSchemasGetCall { + c.ctx_ = ctx + return c +} + +// Header returns an http.Header that can be modified by the caller to +// add HTTP headers to the request. +func (c *ProjectsLocationsCollectionsDataStoresSchemasGetCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsCollectionsDataStoresSchemasGetCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := make(http.Header) + reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) + for k, v := range c.header_ { + reqHeaders[k] = v + } + reqHeaders.Set("User-Agent", c.s.userAgent()) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) + } + var body io.Reader = nil + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("GET", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "name": c.name, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "discoveryengine.projects.locations.collections.dataStores.schemas.get" call. +// Exactly one of *GoogleCloudDiscoveryengineV1betaSchema or error will +// be non-nil. Any non-2xx status code is an error. Response headers are +// in either +// *GoogleCloudDiscoveryengineV1betaSchema.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 *ProjectsLocationsCollectionsDataStoresSchemasGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1betaSchema, 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 := &GoogleCloudDiscoveryengineV1betaSchema{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil + // { + // "description": "Gets a Schema.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/schemas/{schemasId}", + // "httpMethod": "GET", + // "id": "discoveryengine.projects.locations.collections.dataStores.schemas.get", + // "parameterOrder": [ + // "name" + // ], + // "parameters": { + // "name": { + // "description": "Required. The full resource name of the schema, in the format of `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/schemas/{schema}`.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/schemas/[^/]+$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1beta/{+name}", + // "response": { + // "$ref": "GoogleCloudDiscoveryengineV1betaSchema" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "discoveryengine.projects.locations.collections.dataStores.schemas.list": + +type ProjectsLocationsCollectionsDataStoresSchemasListCall struct { + s *Service + parent string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// List: Gets a list of Schemas. +// +// - parent: The parent data store resource name, in the format of +// `projects/{project}/locations/{location}/collections/{collection}/da +// taStores/{data_store}`. +func (r *ProjectsLocationsCollectionsDataStoresSchemasService) List(parent string) *ProjectsLocationsCollectionsDataStoresSchemasListCall { + c := &ProjectsLocationsCollectionsDataStoresSchemasListCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + return c +} + +// PageSize sets the optional parameter "pageSize": The maximum number +// of Schemas to return. The service may return fewer than this value. +// If unspecified, at most 100 Schemas will be returned. The maximum +// value is 1000; values above 1000 will be coerced to 1000. +func (c *ProjectsLocationsCollectionsDataStoresSchemasListCall) PageSize(pageSize int64) *ProjectsLocationsCollectionsDataStoresSchemasListCall { + c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) + return c +} + +// PageToken sets the optional parameter "pageToken": A page token, +// received from a previous SchemaService.ListSchemas call. Provide this +// to retrieve the subsequent page. When paginating, all other +// parameters provided to SchemaService.ListSchemas must match the call +// that provided the page token. +func (c *ProjectsLocationsCollectionsDataStoresSchemasListCall) PageToken(pageToken string) *ProjectsLocationsCollectionsDataStoresSchemasListCall { + 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 information. +func (c *ProjectsLocationsCollectionsDataStoresSchemasListCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresSchemasListCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// IfNoneMatch sets the 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. Use googleapi.IsNotModified to check whether the response +// error from Do is the result of In-None-Match. +func (c *ProjectsLocationsCollectionsDataStoresSchemasListCall) IfNoneMatch(entityTag string) *ProjectsLocationsCollectionsDataStoresSchemasListCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do method. Any +// pending HTTP request will be aborted if the provided context is +// canceled. +func (c *ProjectsLocationsCollectionsDataStoresSchemasListCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresSchemasListCall { + c.ctx_ = ctx + return c +} + +// Header returns an http.Header that can be modified by the caller to +// add HTTP headers to the request. +func (c *ProjectsLocationsCollectionsDataStoresSchemasListCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsCollectionsDataStoresSchemasListCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := make(http.Header) + reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) + for k, v := range c.header_ { + reqHeaders[k] = v + } + reqHeaders.Set("User-Agent", c.s.userAgent()) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) + } + var body io.Reader = nil + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+parent}/schemas") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("GET", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "parent": c.parent, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "discoveryengine.projects.locations.collections.dataStores.schemas.list" call. +// Exactly one of *GoogleCloudDiscoveryengineV1betaListSchemasResponse +// or error will be non-nil. Any non-2xx status code is an error. +// Response headers are in either +// *GoogleCloudDiscoveryengineV1betaListSchemasResponse.ServerResponse.He +// ader 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 *ProjectsLocationsCollectionsDataStoresSchemasListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1betaListSchemasResponse, 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 := &GoogleCloudDiscoveryengineV1betaListSchemasResponse{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil + // { + // "description": "Gets a list of Schemas.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/schemas", + // "httpMethod": "GET", + // "id": "discoveryengine.projects.locations.collections.dataStores.schemas.list", + // "parameterOrder": [ + // "parent" + // ], + // "parameters": { + // "pageSize": { + // "description": "The maximum number of Schemas to return. The service may return fewer than this value. If unspecified, at most 100 Schemas will be returned. The maximum value is 1000; values above 1000 will be coerced to 1000.", + // "format": "int32", + // "location": "query", + // "type": "integer" + // }, + // "pageToken": { + // "description": "A page token, received from a previous SchemaService.ListSchemas call. Provide this to retrieve the subsequent page. When paginating, all other parameters provided to SchemaService.ListSchemas must match the call that provided the page token.", + // "location": "query", + // "type": "string" + // }, + // "parent": { + // "description": "Required. The parent data store resource name, in the format of `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}`.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1beta/{+parent}/schemas", + // "response": { + // "$ref": "GoogleCloudDiscoveryengineV1betaListSchemasResponse" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// 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 *ProjectsLocationsCollectionsDataStoresSchemasListCall) Pages(ctx context.Context, f func(*GoogleCloudDiscoveryengineV1betaListSchemasResponse) error) error { + c.ctx_ = ctx + defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point + 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) + } +} + +// method id "discoveryengine.projects.locations.collections.dataStores.schemas.patch": + +type ProjectsLocationsCollectionsDataStoresSchemasPatchCall struct { + s *Service + name string + googleclouddiscoveryenginev1betaschema *GoogleCloudDiscoveryengineV1betaSchema + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Patch: Updates a Schema. +// +// - name: Immutable. The full resource name of the schema, in the +// format of +// `projects/{project}/locations/{location}/collections/{collection}/da +// taStores/{data_store}/schemas/{schema}`. This field must be a UTF-8 +// encoded string with a length limit of 1024 characters. +func (r *ProjectsLocationsCollectionsDataStoresSchemasService) Patch(name string, googleclouddiscoveryenginev1betaschema *GoogleCloudDiscoveryengineV1betaSchema) *ProjectsLocationsCollectionsDataStoresSchemasPatchCall { + c := &ProjectsLocationsCollectionsDataStoresSchemasPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + c.googleclouddiscoveryenginev1betaschema = googleclouddiscoveryenginev1betaschema + return c +} + +// AllowMissing sets the optional parameter "allowMissing": If set to +// true, and the Schema is not found, a new Schema will be created. In +// this situation, `update_mask` is ignored. +func (c *ProjectsLocationsCollectionsDataStoresSchemasPatchCall) AllowMissing(allowMissing bool) *ProjectsLocationsCollectionsDataStoresSchemasPatchCall { + c.urlParams_.Set("allowMissing", fmt.Sprint(allowMissing)) + return c +} + +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse +// for more information. +func (c *ProjectsLocationsCollectionsDataStoresSchemasPatchCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresSchemasPatchCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. Any +// pending HTTP request will be aborted if the provided context is +// canceled. +func (c *ProjectsLocationsCollectionsDataStoresSchemasPatchCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresSchemasPatchCall { + c.ctx_ = ctx + return c +} + +// Header returns an http.Header that can be modified by the caller to +// add HTTP headers to the request. +func (c *ProjectsLocationsCollectionsDataStoresSchemasPatchCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsCollectionsDataStoresSchemasPatchCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := make(http.Header) + reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) + for k, v := range c.header_ { + reqHeaders[k] = v + } + reqHeaders.Set("User-Agent", c.s.userAgent()) + var body io.Reader = nil + body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddiscoveryenginev1betaschema) + if err != nil { + return nil, err + } + reqHeaders.Set("Content-Type", "application/json") + 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, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "discoveryengine.projects.locations.collections.dataStores.schemas.patch" call. +// Exactly one of *GoogleLongrunningOperation or error will be non-nil. +// 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 *ProjectsLocationsCollectionsDataStoresSchemasPatchCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &GoogleLongrunningOperation{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil + // { + // "description": "Updates a Schema.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/schemas/{schemasId}", + // "httpMethod": "PATCH", + // "id": "discoveryengine.projects.locations.collections.dataStores.schemas.patch", + // "parameterOrder": [ + // "name" + // ], + // "parameters": { + // "allowMissing": { + // "description": "If set to true, and the Schema is not found, a new Schema will be created. In this situation, `update_mask` is ignored.", + // "location": "query", + // "type": "boolean" + // }, + // "name": { + // "description": "Immutable. The full resource name of the schema, in the format of `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/schemas/{schema}`. This field must be a UTF-8 encoded string with a length limit of 1024 characters.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/schemas/[^/]+$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1beta/{+name}", + // "request": { + // "$ref": "GoogleCloudDiscoveryengineV1betaSchema" + // }, + // "response": { + // "$ref": "GoogleLongrunningOperation" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "discoveryengine.projects.locations.collections.dataStores.schemas.operations.get": + +type ProjectsLocationsCollectionsDataStoresSchemasOperationsGetCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// Get: Gets the latest state of a long-running operation. Clients can +// use this method to poll the operation result at intervals as +// recommended by the API service. +// +// - name: The name of the operation resource. +func (r *ProjectsLocationsCollectionsDataStoresSchemasOperationsService) Get(name string) *ProjectsLocationsCollectionsDataStoresSchemasOperationsGetCall { + c := &ProjectsLocationsCollectionsDataStoresSchemasOperationsGetCall{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 information. +func (c *ProjectsLocationsCollectionsDataStoresSchemasOperationsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresSchemasOperationsGetCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// IfNoneMatch sets the 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. Use googleapi.IsNotModified to check whether the response +// error from Do is the result of In-None-Match. +func (c *ProjectsLocationsCollectionsDataStoresSchemasOperationsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsCollectionsDataStoresSchemasOperationsGetCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do method. Any +// pending HTTP request will be aborted if the provided context is +// canceled. +func (c *ProjectsLocationsCollectionsDataStoresSchemasOperationsGetCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresSchemasOperationsGetCall { + c.ctx_ = ctx + return c +} + +// Header returns an http.Header that can be modified by the caller to +// add HTTP headers to the request. +func (c *ProjectsLocationsCollectionsDataStoresSchemasOperationsGetCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsCollectionsDataStoresSchemasOperationsGetCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := make(http.Header) + reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) + for k, v := range c.header_ { + reqHeaders[k] = v + } + reqHeaders.Set("User-Agent", c.s.userAgent()) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) + } + var body io.Reader = nil + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("GET", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "name": c.name, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "discoveryengine.projects.locations.collections.dataStores.schemas.operations.get" call. +// Exactly one of *GoogleLongrunningOperation or error will be non-nil. +// 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 *ProjectsLocationsCollectionsDataStoresSchemasOperationsGetCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &GoogleLongrunningOperation{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil + // { + // "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": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/schemas/{schemasId}/operations/{operationsId}", + // "httpMethod": "GET", + // "id": "discoveryengine.projects.locations.collections.dataStores.schemas.operations.get", + // "parameterOrder": [ + // "name" + // ], + // "parameters": { + // "name": { + // "description": "The name of the operation resource.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/schemas/[^/]+/operations/[^/]+$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1beta/{+name}", + // "response": { + // "$ref": "GoogleLongrunningOperation" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "discoveryengine.projects.locations.collections.dataStores.schemas.operations.list": + +type ProjectsLocationsCollectionsDataStoresSchemasOperationsListCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// List: Lists operations that match the specified filter in the +// request. If the server doesn't support this method, it returns +// `UNIMPLEMENTED`. +// +// - name: The name of the operation's parent resource. +func (r *ProjectsLocationsCollectionsDataStoresSchemasOperationsService) List(name string) *ProjectsLocationsCollectionsDataStoresSchemasOperationsListCall { + c := &ProjectsLocationsCollectionsDataStoresSchemasOperationsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + return c +} + +// Filter sets the optional parameter "filter": The standard list +// filter. +func (c *ProjectsLocationsCollectionsDataStoresSchemasOperationsListCall) Filter(filter string) *ProjectsLocationsCollectionsDataStoresSchemasOperationsListCall { + c.urlParams_.Set("filter", filter) + return c +} + +// PageSize sets the optional parameter "pageSize": The standard list +// page size. +func (c *ProjectsLocationsCollectionsDataStoresSchemasOperationsListCall) PageSize(pageSize int64) *ProjectsLocationsCollectionsDataStoresSchemasOperationsListCall { + c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) + return c +} + +// PageToken sets the optional parameter "pageToken": The standard list +// page token. +func (c *ProjectsLocationsCollectionsDataStoresSchemasOperationsListCall) PageToken(pageToken string) *ProjectsLocationsCollectionsDataStoresSchemasOperationsListCall { + 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 information. +func (c *ProjectsLocationsCollectionsDataStoresSchemasOperationsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresSchemasOperationsListCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// IfNoneMatch sets the 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. Use googleapi.IsNotModified to check whether the response +// error from Do is the result of In-None-Match. +func (c *ProjectsLocationsCollectionsDataStoresSchemasOperationsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsCollectionsDataStoresSchemasOperationsListCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do method. Any +// pending HTTP request will be aborted if the provided context is +// canceled. +func (c *ProjectsLocationsCollectionsDataStoresSchemasOperationsListCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresSchemasOperationsListCall { + c.ctx_ = ctx + return c +} + +// Header returns an http.Header that can be modified by the caller to +// add HTTP headers to the request. +func (c *ProjectsLocationsCollectionsDataStoresSchemasOperationsListCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsCollectionsDataStoresSchemasOperationsListCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := make(http.Header) + reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) + for k, v := range c.header_ { + reqHeaders[k] = v + } + reqHeaders.Set("User-Agent", c.s.userAgent()) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) + } + var body io.Reader = nil + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}/operations") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("GET", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "name": c.name, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "discoveryengine.projects.locations.collections.dataStores.schemas.operations.list" call. +// Exactly one of *GoogleLongrunningListOperationsResponse or error will +// be non-nil. Any non-2xx status code is an error. Response headers are +// in either +// *GoogleLongrunningListOperationsResponse.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 *ProjectsLocationsCollectionsDataStoresSchemasOperationsListCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningListOperationsResponse, 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 := &GoogleLongrunningListOperationsResponse{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil + // { + // "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/schemas/{schemasId}/operations", + // "httpMethod": "GET", + // "id": "discoveryengine.projects.locations.collections.dataStores.schemas.operations.list", + // "parameterOrder": [ + // "name" + // ], + // "parameters": { + // "filter": { + // "description": "The standard list filter.", + // "location": "query", + // "type": "string" + // }, + // "name": { + // "description": "The name of the operation's parent resource.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/schemas/[^/]+$", + // "required": true, + // "type": "string" + // }, + // "pageSize": { + // "description": "The standard list page size.", + // "format": "int32", + // "location": "query", + // "type": "integer" + // }, + // "pageToken": { + // "description": "The standard list page token.", + // "location": "query", + // "type": "string" + // } + // }, + // "path": "v1beta/{+name}/operations", + // "response": { + // "$ref": "GoogleLongrunningListOperationsResponse" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// 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 *ProjectsLocationsCollectionsDataStoresSchemasOperationsListCall) Pages(ctx context.Context, f func(*GoogleLongrunningListOperationsResponse) error) error { + c.ctx_ = ctx + defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point + 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) + } +} + +// method id "discoveryengine.projects.locations.collections.dataStores.servingConfigs.recommend": + +type ProjectsLocationsCollectionsDataStoresServingConfigsRecommendCall struct { + s *Service + servingConfig string + googleclouddiscoveryenginev1betarecommendrequest *GoogleCloudDiscoveryengineV1betaRecommendRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Recommend: Makes a recommendation, which requires a contextual user +// event. +// +// - servingConfig: Full resource name of a ServingConfig: +// `projects/*/locations/global/collections/*/engines/*/servingConfigs/ +// *`, or +// `projects/*/locations/global/collections/*/dataStores/*/servingConfi +// gs/*` One default serving config is created along with your +// recommendation engine creation. The engine ID will be used as the +// ID of the default serving config. For example, for Engine +// `projects/*/locations/global/collections/*/engines/my-engine`, you +// can use +// `projects/*/locations/global/collections/*/engines/my-engine/serving +// Configs/my-engine` for your RecommendationService.Recommend +// requests. +func (r *ProjectsLocationsCollectionsDataStoresServingConfigsService) Recommend(servingConfig string, googleclouddiscoveryenginev1betarecommendrequest *GoogleCloudDiscoveryengineV1betaRecommendRequest) *ProjectsLocationsCollectionsDataStoresServingConfigsRecommendCall { + c := &ProjectsLocationsCollectionsDataStoresServingConfigsRecommendCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.servingConfig = servingConfig + c.googleclouddiscoveryenginev1betarecommendrequest = googleclouddiscoveryenginev1betarecommendrequest + return c +} + +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse +// for more information. +func (c *ProjectsLocationsCollectionsDataStoresServingConfigsRecommendCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresServingConfigsRecommendCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. Any +// pending HTTP request will be aborted if the provided context is +// canceled. +func (c *ProjectsLocationsCollectionsDataStoresServingConfigsRecommendCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresServingConfigsRecommendCall { + c.ctx_ = ctx + return c +} + +// Header returns an http.Header that can be modified by the caller to +// add HTTP headers to the request. +func (c *ProjectsLocationsCollectionsDataStoresServingConfigsRecommendCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsCollectionsDataStoresServingConfigsRecommendCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := make(http.Header) + reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) + for k, v := range c.header_ { + reqHeaders[k] = v + } + reqHeaders.Set("User-Agent", c.s.userAgent()) + var body io.Reader = nil + body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddiscoveryenginev1betarecommendrequest) + if err != nil { + return nil, err + } + reqHeaders.Set("Content-Type", "application/json") + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+servingConfig}:recommend") + 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{ + "servingConfig": c.servingConfig, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "discoveryengine.projects.locations.collections.dataStores.servingConfigs.recommend" call. +// Exactly one of *GoogleCloudDiscoveryengineV1betaRecommendResponse or +// error will be non-nil. Any non-2xx status code is an error. Response +// headers are in either +// *GoogleCloudDiscoveryengineV1betaRecommendResponse.ServerResponse.Head +// er 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 *ProjectsLocationsCollectionsDataStoresServingConfigsRecommendCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1betaRecommendResponse, 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 := &GoogleCloudDiscoveryengineV1betaRecommendResponse{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil + // { + // "description": "Makes a recommendation, which requires a contextual user event.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/servingConfigs/{servingConfigsId}:recommend", + // "httpMethod": "POST", + // "id": "discoveryengine.projects.locations.collections.dataStores.servingConfigs.recommend", + // "parameterOrder": [ + // "servingConfig" + // ], + // "parameters": { + // "servingConfig": { + // "description": "Required. Full resource name of a ServingConfig: `projects/*/locations/global/collections/*/engines/*/servingConfigs/*`, or `projects/*/locations/global/collections/*/dataStores/*/servingConfigs/*` One default serving config is created along with your recommendation engine creation. The engine ID will be used as the ID of the default serving config. For example, for Engine `projects/*/locations/global/collections/*/engines/my-engine`, you can use `projects/*/locations/global/collections/*/engines/my-engine/servingConfigs/my-engine` for your RecommendationService.Recommend requests.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/servingConfigs/[^/]+$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1beta/{+servingConfig}:recommend", + // "request": { + // "$ref": "GoogleCloudDiscoveryengineV1betaRecommendRequest" + // }, + // "response": { + // "$ref": "GoogleCloudDiscoveryengineV1betaRecommendResponse" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "discoveryengine.projects.locations.collections.dataStores.servingConfigs.search": + +type ProjectsLocationsCollectionsDataStoresServingConfigsSearchCall struct { + s *Service + servingConfig string + googleclouddiscoveryenginev1betasearchrequest *GoogleCloudDiscoveryengineV1betaSearchRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Search: Performs a search. +// +// - servingConfig: The resource name of the Search serving config, such +// as +// `projects/*/locations/global/collections/default_collection/engines/ +// */servingConfigs/default_serving_config`, or +// `projects/*/locations/global/collections/default_collection/dataStor +// es/default_data_store/servingConfigs/default_serving_config`. This +// field is used to identify the serving configuration name, set of +// models used to make the search. +func (r *ProjectsLocationsCollectionsDataStoresServingConfigsService) Search(servingConfig string, googleclouddiscoveryenginev1betasearchrequest *GoogleCloudDiscoveryengineV1betaSearchRequest) *ProjectsLocationsCollectionsDataStoresServingConfigsSearchCall { + c := &ProjectsLocationsCollectionsDataStoresServingConfigsSearchCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.servingConfig = servingConfig + c.googleclouddiscoveryenginev1betasearchrequest = googleclouddiscoveryenginev1betasearchrequest + return c +} + +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse +// for more information. +func (c *ProjectsLocationsCollectionsDataStoresServingConfigsSearchCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresServingConfigsSearchCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. Any +// pending HTTP request will be aborted if the provided context is +// canceled. +func (c *ProjectsLocationsCollectionsDataStoresServingConfigsSearchCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresServingConfigsSearchCall { + c.ctx_ = ctx + return c +} + +// Header returns an http.Header that can be modified by the caller to +// add HTTP headers to the request. +func (c *ProjectsLocationsCollectionsDataStoresServingConfigsSearchCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsCollectionsDataStoresServingConfigsSearchCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := make(http.Header) + reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) + for k, v := range c.header_ { + reqHeaders[k] = v + } + reqHeaders.Set("User-Agent", c.s.userAgent()) + var body io.Reader = nil + body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddiscoveryenginev1betasearchrequest) + if err != nil { + return nil, err + } + reqHeaders.Set("Content-Type", "application/json") + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+servingConfig}:search") + 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{ + "servingConfig": c.servingConfig, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "discoveryengine.projects.locations.collections.dataStores.servingConfigs.search" call. +// Exactly one of *GoogleCloudDiscoveryengineV1betaSearchResponse or +// error will be non-nil. Any non-2xx status code is an error. Response +// headers are in either +// *GoogleCloudDiscoveryengineV1betaSearchResponse.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 *ProjectsLocationsCollectionsDataStoresServingConfigsSearchCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1betaSearchResponse, 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 := &GoogleCloudDiscoveryengineV1betaSearchResponse{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil + // { + // "description": "Performs a search.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/servingConfigs/{servingConfigsId}:search", + // "httpMethod": "POST", + // "id": "discoveryengine.projects.locations.collections.dataStores.servingConfigs.search", + // "parameterOrder": [ + // "servingConfig" + // ], + // "parameters": { + // "servingConfig": { + // "description": "Required. The resource name of the Search serving config, such as `projects/*/locations/global/collections/default_collection/engines/*/servingConfigs/default_serving_config`, or `projects/*/locations/global/collections/default_collection/dataStores/default_data_store/servingConfigs/default_serving_config`. This field is used to identify the serving configuration name, set of models used to make the search.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/servingConfigs/[^/]+$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1beta/{+servingConfig}:search", + // "request": { + // "$ref": "GoogleCloudDiscoveryengineV1betaSearchRequest" + // }, + // "response": { + // "$ref": "GoogleCloudDiscoveryengineV1betaSearchResponse" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// 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 *ProjectsLocationsCollectionsDataStoresServingConfigsSearchCall) Pages(ctx context.Context, f func(*GoogleCloudDiscoveryengineV1betaSearchResponse) error) error { + c.ctx_ = ctx + defer func(pt string) { c.googleclouddiscoveryenginev1betasearchrequest.PageToken = pt }(c.googleclouddiscoveryenginev1betasearchrequest.PageToken) // reset paging to original point + for { + x, err := c.Do() + if err != nil { + return err + } + if err := f(x); err != nil { + return err + } + if x.NextPageToken == "" { + return nil + } + c.googleclouddiscoveryenginev1betasearchrequest.PageToken = x.NextPageToken + } +} + +// method id "discoveryengine.projects.locations.collections.dataStores.siteSearchEngine.batchVerifyTargetSites": + +type ProjectsLocationsCollectionsDataStoresSiteSearchEngineBatchVerifyTargetSitesCall struct { + s *Service + parent string + googleclouddiscoveryenginev1betabatchverifytargetsitesrequest *GoogleCloudDiscoveryengineV1betaBatchVerifyTargetSitesRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// BatchVerifyTargetSites: Verify target sites' ownership and validity. +// This API sends all the target sites under site search engine for +// verification. +// +// - parent: The parent resource shared by all TargetSites being +// verified. +// `projects/{project}/locations/{location}/collections/{collection}/da +// taStores/{data_store}/siteSearchEngine`. +func (r *ProjectsLocationsCollectionsDataStoresSiteSearchEngineService) BatchVerifyTargetSites(parent string, googleclouddiscoveryenginev1betabatchverifytargetsitesrequest *GoogleCloudDiscoveryengineV1betaBatchVerifyTargetSitesRequest) *ProjectsLocationsCollectionsDataStoresSiteSearchEngineBatchVerifyTargetSitesCall { + c := &ProjectsLocationsCollectionsDataStoresSiteSearchEngineBatchVerifyTargetSitesCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + c.googleclouddiscoveryenginev1betabatchverifytargetsitesrequest = googleclouddiscoveryenginev1betabatchverifytargetsitesrequest + return c +} + +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse +// for more information. +func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineBatchVerifyTargetSitesCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresSiteSearchEngineBatchVerifyTargetSitesCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. Any +// pending HTTP request will be aborted if the provided context is +// canceled. +func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineBatchVerifyTargetSitesCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresSiteSearchEngineBatchVerifyTargetSitesCall { + c.ctx_ = ctx + return c +} + +// Header returns an http.Header that can be modified by the caller to +// add HTTP headers to the request. +func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineBatchVerifyTargetSitesCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineBatchVerifyTargetSitesCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := make(http.Header) + reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) + for k, v := range c.header_ { + reqHeaders[k] = v + } + reqHeaders.Set("User-Agent", c.s.userAgent()) + var body io.Reader = nil + body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddiscoveryenginev1betabatchverifytargetsitesrequest) + if err != nil { + return nil, err + } + reqHeaders.Set("Content-Type", "application/json") + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+parent}:batchVerifyTargetSites") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("POST", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "parent": c.parent, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "discoveryengine.projects.locations.collections.dataStores.siteSearchEngine.batchVerifyTargetSites" call. +// Exactly one of *GoogleLongrunningOperation or error will be non-nil. +// 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 *ProjectsLocationsCollectionsDataStoresSiteSearchEngineBatchVerifyTargetSitesCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &GoogleLongrunningOperation{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil + // { + // "description": "Verify target sites' ownership and validity. This API sends all the target sites under site search engine for verification.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/siteSearchEngine:batchVerifyTargetSites", + // "httpMethod": "POST", + // "id": "discoveryengine.projects.locations.collections.dataStores.siteSearchEngine.batchVerifyTargetSites", + // "parameterOrder": [ + // "parent" + // ], + // "parameters": { + // "parent": { + // "description": "Required. The parent resource shared by all TargetSites being verified. `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/siteSearchEngine`.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/siteSearchEngine$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1beta/{+parent}:batchVerifyTargetSites", + // "request": { + // "$ref": "GoogleCloudDiscoveryengineV1betaBatchVerifyTargetSitesRequest" + // }, + // "response": { + // "$ref": "GoogleLongrunningOperation" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "discoveryengine.projects.locations.collections.dataStores.siteSearchEngine.disableAdvancedSiteSearch": + +type ProjectsLocationsCollectionsDataStoresSiteSearchEngineDisableAdvancedSiteSearchCall struct { + s *Service + siteSearchEngine string + googleclouddiscoveryenginev1betadisableadvancedsitesearchrequest *GoogleCloudDiscoveryengineV1betaDisableAdvancedSiteSearchRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// DisableAdvancedSiteSearch: Downgrade from advanced site search to +// basic site search. +// +// - siteSearchEngine: Full resource name of the SiteSearchEngine, such +// as +// `projects/{project}/locations/{location}/dataStores/{data_store_id}/ +// siteSearchEngine`. +func (r *ProjectsLocationsCollectionsDataStoresSiteSearchEngineService) DisableAdvancedSiteSearch(siteSearchEngine string, googleclouddiscoveryenginev1betadisableadvancedsitesearchrequest *GoogleCloudDiscoveryengineV1betaDisableAdvancedSiteSearchRequest) *ProjectsLocationsCollectionsDataStoresSiteSearchEngineDisableAdvancedSiteSearchCall { + c := &ProjectsLocationsCollectionsDataStoresSiteSearchEngineDisableAdvancedSiteSearchCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.siteSearchEngine = siteSearchEngine + c.googleclouddiscoveryenginev1betadisableadvancedsitesearchrequest = googleclouddiscoveryenginev1betadisableadvancedsitesearchrequest + return c +} + +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse +// for more information. +func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineDisableAdvancedSiteSearchCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresSiteSearchEngineDisableAdvancedSiteSearchCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. Any +// pending HTTP request will be aborted if the provided context is +// canceled. +func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineDisableAdvancedSiteSearchCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresSiteSearchEngineDisableAdvancedSiteSearchCall { + c.ctx_ = ctx + return c +} + +// Header returns an http.Header that can be modified by the caller to +// add HTTP headers to the request. +func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineDisableAdvancedSiteSearchCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineDisableAdvancedSiteSearchCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := make(http.Header) + reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) + for k, v := range c.header_ { + reqHeaders[k] = v + } + reqHeaders.Set("User-Agent", c.s.userAgent()) + var body io.Reader = nil + body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddiscoveryenginev1betadisableadvancedsitesearchrequest) + if err != nil { + return nil, err + } + reqHeaders.Set("Content-Type", "application/json") + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+siteSearchEngine}:disableAdvancedSiteSearch") + 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{ + "siteSearchEngine": c.siteSearchEngine, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "discoveryengine.projects.locations.collections.dataStores.siteSearchEngine.disableAdvancedSiteSearch" call. +// Exactly one of *GoogleLongrunningOperation or error will be non-nil. +// 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 *ProjectsLocationsCollectionsDataStoresSiteSearchEngineDisableAdvancedSiteSearchCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &GoogleLongrunningOperation{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil + // { + // "description": "Downgrade from advanced site search to basic site search.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/siteSearchEngine:disableAdvancedSiteSearch", + // "httpMethod": "POST", + // "id": "discoveryengine.projects.locations.collections.dataStores.siteSearchEngine.disableAdvancedSiteSearch", + // "parameterOrder": [ + // "siteSearchEngine" + // ], + // "parameters": { + // "siteSearchEngine": { + // "description": "Required. Full resource name of the SiteSearchEngine, such as `projects/{project}/locations/{location}/dataStores/{data_store_id}/siteSearchEngine`.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/siteSearchEngine$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1beta/{+siteSearchEngine}:disableAdvancedSiteSearch", + // "request": { + // "$ref": "GoogleCloudDiscoveryengineV1betaDisableAdvancedSiteSearchRequest" + // }, + // "response": { + // "$ref": "GoogleLongrunningOperation" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + } -// method id "discoveryengine.projects.locations.collections.dataConnector.operations.get": +// method id "discoveryengine.projects.locations.collections.dataStores.siteSearchEngine.enableAdvancedSiteSearch": -type ProjectsLocationsCollectionsDataConnectorOperationsGetCall struct { - s *Service - name string - urlParams_ gensupport.URLParams - ifNoneMatch_ string - ctx_ context.Context - header_ http.Header +type ProjectsLocationsCollectionsDataStoresSiteSearchEngineEnableAdvancedSiteSearchCall struct { + s *Service + siteSearchEngine string + googleclouddiscoveryenginev1betaenableadvancedsitesearchrequest *GoogleCloudDiscoveryengineV1betaEnableAdvancedSiteSearchRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// Get: Gets the latest state of a long-running operation. Clients can -// use this method to poll the operation result at intervals as -// recommended by the API service. +// EnableAdvancedSiteSearch: Upgrade from basic site search to advanced +// site search. // -// - name: The name of the operation resource. -func (r *ProjectsLocationsCollectionsDataConnectorOperationsService) Get(name string) *ProjectsLocationsCollectionsDataConnectorOperationsGetCall { - c := &ProjectsLocationsCollectionsDataConnectorOperationsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.name = name +// - siteSearchEngine: Full resource name of the SiteSearchEngine, such +// as +// `projects/{project}/locations/{location}/dataStores/{data_store_id}/ +// siteSearchEngine`. +func (r *ProjectsLocationsCollectionsDataStoresSiteSearchEngineService) EnableAdvancedSiteSearch(siteSearchEngine string, googleclouddiscoveryenginev1betaenableadvancedsitesearchrequest *GoogleCloudDiscoveryengineV1betaEnableAdvancedSiteSearchRequest) *ProjectsLocationsCollectionsDataStoresSiteSearchEngineEnableAdvancedSiteSearchCall { + c := &ProjectsLocationsCollectionsDataStoresSiteSearchEngineEnableAdvancedSiteSearchCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.siteSearchEngine = siteSearchEngine + c.googleclouddiscoveryenginev1betaenableadvancedsitesearchrequest = googleclouddiscoveryenginev1betaenableadvancedsitesearchrequest return c } // Fields allows partial responses to be retrieved. See // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse // for more information. -func (c *ProjectsLocationsCollectionsDataConnectorOperationsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataConnectorOperationsGetCall { +func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineEnableAdvancedSiteSearchCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresSiteSearchEngineEnableAdvancedSiteSearchCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// IfNoneMatch sets the 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. Use googleapi.IsNotModified to check whether the response -// error from Do is the result of In-None-Match. -func (c *ProjectsLocationsCollectionsDataConnectorOperationsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsCollectionsDataConnectorOperationsGetCall { - c.ifNoneMatch_ = entityTag - return c -} - // Context sets the context to be used in this call's Do method. Any // pending HTTP request will be aborted if the provided context is // canceled. -func (c *ProjectsLocationsCollectionsDataConnectorOperationsGetCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataConnectorOperationsGetCall { +func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineEnableAdvancedSiteSearchCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresSiteSearchEngineEnableAdvancedSiteSearchCall { c.ctx_ = ctx return c } // Header returns an http.Header that can be modified by the caller to // add HTTP headers to the request. -func (c *ProjectsLocationsCollectionsDataConnectorOperationsGetCall) Header() http.Header { +func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineEnableAdvancedSiteSearchCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsCollectionsDataConnectorOperationsGetCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineEnableAdvancedSiteSearchCall) doRequest(alt string) (*http.Response, error) { reqHeaders := make(http.Header) reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) for k, v := range c.header_ { reqHeaders[k] = v } reqHeaders.Set("User-Agent", c.s.userAgent()) - if c.ifNoneMatch_ != "" { - reqHeaders.Set("If-None-Match", c.ifNoneMatch_) - } var body io.Reader = nil + body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddiscoveryenginev1betaenableadvancedsitesearchrequest) + if err != nil { + return nil, err + } + reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+siteSearchEngine}:enableAdvancedSiteSearch") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("GET", urls, body) + req, err := http.NewRequest("POST", urls, body) if err != nil { return nil, err } req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ - "name": c.name, + "siteSearchEngine": c.siteSearchEngine, }) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "discoveryengine.projects.locations.collections.dataConnector.operations.get" call. +// Do executes the "discoveryengine.projects.locations.collections.dataStores.siteSearchEngine.enableAdvancedSiteSearch" call. // Exactly one of *GoogleLongrunningOperation or error will be non-nil. // 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 *ProjectsLocationsCollectionsDataConnectorOperationsGetCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { +func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineEnableAdvancedSiteSearchCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -8293,23 +17089,26 @@ func (c *ProjectsLocationsCollectionsDataConnectorOperationsGetCall) Do(opts ... } return ret, nil // { - // "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": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataConnector/operations/{operationsId}", - // "httpMethod": "GET", - // "id": "discoveryengine.projects.locations.collections.dataConnector.operations.get", + // "description": "Upgrade from basic site search to advanced site search.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/siteSearchEngine:enableAdvancedSiteSearch", + // "httpMethod": "POST", + // "id": "discoveryengine.projects.locations.collections.dataStores.siteSearchEngine.enableAdvancedSiteSearch", // "parameterOrder": [ - // "name" + // "siteSearchEngine" // ], // "parameters": { - // "name": { - // "description": "The name of the operation resource.", + // "siteSearchEngine": { + // "description": "Required. Full resource name of the SiteSearchEngine, such as `projects/{project}/locations/{location}/dataStores/{data_store_id}/siteSearchEngine`.", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataConnector/operations/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/siteSearchEngine$", // "required": true, // "type": "string" // } // }, - // "path": "v1beta/{+name}", + // "path": "v1beta/{+siteSearchEngine}:enableAdvancedSiteSearch", + // "request": { + // "$ref": "GoogleCloudDiscoveryengineV1betaEnableAdvancedSiteSearchRequest" + // }, // "response": { // "$ref": "GoogleLongrunningOperation" // }, @@ -8320,45 +17119,47 @@ func (c *ProjectsLocationsCollectionsDataConnectorOperationsGetCall) Do(opts ... } -// method id "discoveryengine.projects.locations.collections.dataConnector.operations.list": +// method id "discoveryengine.projects.locations.collections.dataStores.siteSearchEngine.fetchDomainVerificationStatus": -type ProjectsLocationsCollectionsDataConnectorOperationsListCall struct { - s *Service - name string - urlParams_ gensupport.URLParams - ifNoneMatch_ string - ctx_ context.Context - header_ http.Header +type ProjectsLocationsCollectionsDataStoresSiteSearchEngineFetchDomainVerificationStatusCall struct { + s *Service + siteSearchEngine string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header } -// List: Lists operations that match the specified filter in the -// request. If the server doesn't support this method, it returns -// `UNIMPLEMENTED`. +// FetchDomainVerificationStatus: Returns list of target sites with its +// domain verification status. This method can only be called under data +// store with BASIC_SITE_SEARCH state at the moment. // -// - name: The name of the operation's parent resource. -func (r *ProjectsLocationsCollectionsDataConnectorOperationsService) List(name string) *ProjectsLocationsCollectionsDataConnectorOperationsListCall { - c := &ProjectsLocationsCollectionsDataConnectorOperationsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.name = name - return c -} - -// Filter sets the optional parameter "filter": The standard list -// filter. -func (c *ProjectsLocationsCollectionsDataConnectorOperationsListCall) Filter(filter string) *ProjectsLocationsCollectionsDataConnectorOperationsListCall { - c.urlParams_.Set("filter", filter) +// - siteSearchEngine: The site search engine resource under which we +// fetch all the domain verification status. +// `projects/{project}/locations/{location}/collections/{collection}/da +// taStores/{data_store}/siteSearchEngine`. +func (r *ProjectsLocationsCollectionsDataStoresSiteSearchEngineService) FetchDomainVerificationStatus(siteSearchEngine string) *ProjectsLocationsCollectionsDataStoresSiteSearchEngineFetchDomainVerificationStatusCall { + c := &ProjectsLocationsCollectionsDataStoresSiteSearchEngineFetchDomainVerificationStatusCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.siteSearchEngine = siteSearchEngine return c } -// PageSize sets the optional parameter "pageSize": The standard list -// page size. -func (c *ProjectsLocationsCollectionsDataConnectorOperationsListCall) PageSize(pageSize int64) *ProjectsLocationsCollectionsDataConnectorOperationsListCall { +// PageSize sets the optional parameter "pageSize": Requested page size. +// Server may return fewer items than requested. If unspecified, server +// will pick an appropriate default. The maximum value is 1000; values +// above 1000 will be coerced to 1000. If this field is negative, an +// INVALID_ARGUMENT error is returned. +func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineFetchDomainVerificationStatusCall) PageSize(pageSize int64) *ProjectsLocationsCollectionsDataStoresSiteSearchEngineFetchDomainVerificationStatusCall { c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) return c } -// PageToken sets the optional parameter "pageToken": The standard list -// page token. -func (c *ProjectsLocationsCollectionsDataConnectorOperationsListCall) PageToken(pageToken string) *ProjectsLocationsCollectionsDataConnectorOperationsListCall { +// PageToken sets the optional parameter "pageToken": A page token, +// received from a previous `FetchDomainVerificationStatus` call. +// Provide this to retrieve the subsequent page. When paginating, all +// other parameters provided to `FetchDomainVerificationStatus` must +// match the call that provided the page token. +func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineFetchDomainVerificationStatusCall) PageToken(pageToken string) *ProjectsLocationsCollectionsDataStoresSiteSearchEngineFetchDomainVerificationStatusCall { c.urlParams_.Set("pageToken", pageToken) return c } @@ -8366,7 +17167,7 @@ func (c *ProjectsLocationsCollectionsDataConnectorOperationsListCall) PageToken( // Fields allows partial responses to be retrieved. See // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse // for more information. -func (c *ProjectsLocationsCollectionsDataConnectorOperationsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataConnectorOperationsListCall { +func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineFetchDomainVerificationStatusCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresSiteSearchEngineFetchDomainVerificationStatusCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } @@ -8376,7 +17177,7 @@ func (c *ProjectsLocationsCollectionsDataConnectorOperationsListCall) Fields(s . // getting updates only after the object has changed since the last // request. Use googleapi.IsNotModified to check whether the response // error from Do is the result of In-None-Match. -func (c *ProjectsLocationsCollectionsDataConnectorOperationsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsCollectionsDataConnectorOperationsListCall { +func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineFetchDomainVerificationStatusCall) IfNoneMatch(entityTag string) *ProjectsLocationsCollectionsDataStoresSiteSearchEngineFetchDomainVerificationStatusCall { c.ifNoneMatch_ = entityTag return c } @@ -8384,21 +17185,21 @@ func (c *ProjectsLocationsCollectionsDataConnectorOperationsListCall) IfNoneMatc // Context sets the context to be used in this call's Do method. Any // pending HTTP request will be aborted if the provided context is // canceled. -func (c *ProjectsLocationsCollectionsDataConnectorOperationsListCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataConnectorOperationsListCall { +func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineFetchDomainVerificationStatusCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresSiteSearchEngineFetchDomainVerificationStatusCall { c.ctx_ = ctx return c } // Header returns an http.Header that can be modified by the caller to // add HTTP headers to the request. -func (c *ProjectsLocationsCollectionsDataConnectorOperationsListCall) Header() http.Header { +func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineFetchDomainVerificationStatusCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsCollectionsDataConnectorOperationsListCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineFetchDomainVerificationStatusCall) doRequest(alt string) (*http.Response, error) { reqHeaders := make(http.Header) reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) for k, v := range c.header_ { @@ -8411,7 +17212,7 @@ func (c *ProjectsLocationsCollectionsDataConnectorOperationsListCall) doRequest( var body io.Reader = nil c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}/operations") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+siteSearchEngine}:fetchDomainVerificationStatus") urls += "?" + c.urlParams_.Encode() req, err := http.NewRequest("GET", urls, body) if err != nil { @@ -8419,20 +17220,24 @@ func (c *ProjectsLocationsCollectionsDataConnectorOperationsListCall) doRequest( } req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ - "name": c.name, + "siteSearchEngine": c.siteSearchEngine, }) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "discoveryengine.projects.locations.collections.dataConnector.operations.list" call. -// Exactly one of *GoogleLongrunningListOperationsResponse or error will -// be non-nil. Any non-2xx status code is an error. Response headers are -// in either -// *GoogleLongrunningListOperationsResponse.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 *ProjectsLocationsCollectionsDataConnectorOperationsListCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningListOperationsResponse, error) { +// Do executes the "discoveryengine.projects.locations.collections.dataStores.siteSearchEngine.fetchDomainVerificationStatus" call. +// Exactly one of +// *GoogleCloudDiscoveryengineV1betaFetchDomainVerificationStatusResponse +// +// or error will be non-nil. Any non-2xx status code is an error. +// +// Response headers are in either +// *GoogleCloudDiscoveryengineV1betaFetchDomainVerificationStatusResponse +// .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 *ProjectsLocationsCollectionsDataStoresSiteSearchEngineFetchDomainVerificationStatusCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1betaFetchDomainVerificationStatusResponse, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -8451,7 +17256,7 @@ func (c *ProjectsLocationsCollectionsDataConnectorOperationsListCall) Do(opts .. if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &GoogleLongrunningListOperationsResponse{ + ret := &GoogleCloudDiscoveryengineV1betaFetchDomainVerificationStatusResponse{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -8463,41 +17268,36 @@ func (c *ProjectsLocationsCollectionsDataConnectorOperationsListCall) Do(opts .. } return ret, nil // { - // "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`.", - // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataConnector/operations", + // "description": "Returns list of target sites with its domain verification status. This method can only be called under data store with BASIC_SITE_SEARCH state at the moment.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/siteSearchEngine:fetchDomainVerificationStatus", // "httpMethod": "GET", - // "id": "discoveryengine.projects.locations.collections.dataConnector.operations.list", + // "id": "discoveryengine.projects.locations.collections.dataStores.siteSearchEngine.fetchDomainVerificationStatus", // "parameterOrder": [ - // "name" + // "siteSearchEngine" // ], // "parameters": { - // "filter": { - // "description": "The standard list filter.", - // "location": "query", - // "type": "string" - // }, - // "name": { - // "description": "The name of the operation's parent resource.", - // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataConnector$", - // "required": true, - // "type": "string" - // }, // "pageSize": { - // "description": "The standard list page size.", + // "description": "Requested page size. Server may return fewer items than requested. If unspecified, server will pick an appropriate default. The maximum value is 1000; values above 1000 will be coerced to 1000. If this field is negative, an INVALID_ARGUMENT error is returned.", // "format": "int32", // "location": "query", // "type": "integer" // }, // "pageToken": { - // "description": "The standard list page token.", + // "description": "A page token, received from a previous `FetchDomainVerificationStatus` call. Provide this to retrieve the subsequent page. When paginating, all other parameters provided to `FetchDomainVerificationStatus` must match the call that provided the page token.", // "location": "query", // "type": "string" + // }, + // "siteSearchEngine": { + // "description": "Required. The site search engine resource under which we fetch all the domain verification status. `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/siteSearchEngine`.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/siteSearchEngine$", + // "required": true, + // "type": "string" // } // }, - // "path": "v1beta/{+name}/operations", + // "path": "v1beta/{+siteSearchEngine}:fetchDomainVerificationStatus", // "response": { - // "$ref": "GoogleLongrunningListOperationsResponse" + // "$ref": "GoogleCloudDiscoveryengineV1betaFetchDomainVerificationStatusResponse" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -8509,7 +17309,7 @@ func (c *ProjectsLocationsCollectionsDataConnectorOperationsListCall) Do(opts .. // 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 *ProjectsLocationsCollectionsDataConnectorOperationsListCall) Pages(ctx context.Context, f func(*GoogleLongrunningListOperationsResponse) error) error { +func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineFetchDomainVerificationStatusCall) Pages(ctx context.Context, f func(*GoogleCloudDiscoveryengineV1betaFetchDomainVerificationStatusResponse) error) error { c.ctx_ = ctx defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point for { @@ -8527,149 +17327,91 @@ func (c *ProjectsLocationsCollectionsDataConnectorOperationsListCall) Pages(ctx } } -// method id "discoveryengine.projects.locations.collections.dataStores.completeQuery": +// method id "discoveryengine.projects.locations.collections.dataStores.siteSearchEngine.recrawlUris": -type ProjectsLocationsCollectionsDataStoresCompleteQueryCall struct { - s *Service - dataStore string - urlParams_ gensupport.URLParams - ifNoneMatch_ string - ctx_ context.Context - header_ http.Header +type ProjectsLocationsCollectionsDataStoresSiteSearchEngineRecrawlUrisCall struct { + s *Service + siteSearchEngine string + googleclouddiscoveryenginev1betarecrawlurisrequest *GoogleCloudDiscoveryengineV1betaRecrawlUrisRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// CompleteQuery: Completes the specified user input with keyword -// suggestions. +// RecrawlUris: Request on-demand recrawl for a list of URIs. // -// - dataStore: The parent data store resource name for which the -// completion is performed, such as -// `projects/*/locations/global/collections/default_collection/dataStor -// es/default_data_store`. -func (r *ProjectsLocationsCollectionsDataStoresService) CompleteQuery(dataStore string) *ProjectsLocationsCollectionsDataStoresCompleteQueryCall { - c := &ProjectsLocationsCollectionsDataStoresCompleteQueryCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.dataStore = dataStore - return c -} - -// IncludeTailSuggestions sets the optional parameter -// "includeTailSuggestions": Indicates if tail suggestions should be -// returned if there are no suggestions that match the full query. Even -// if set to true, if there are suggestions that match the full query, -// those are returned and no tail suggestions are returned. -func (c *ProjectsLocationsCollectionsDataStoresCompleteQueryCall) IncludeTailSuggestions(includeTailSuggestions bool) *ProjectsLocationsCollectionsDataStoresCompleteQueryCall { - c.urlParams_.Set("includeTailSuggestions", fmt.Sprint(includeTailSuggestions)) - return c -} - -// Query sets the optional parameter "query": Required. The typeahead -// input used to fetch suggestions. Maximum length is 128 characters. -func (c *ProjectsLocationsCollectionsDataStoresCompleteQueryCall) Query(query string) *ProjectsLocationsCollectionsDataStoresCompleteQueryCall { - c.urlParams_.Set("query", query) - return c -} - -// QueryModel sets the optional parameter "queryModel": Selects data -// model of query suggestions for serving. Currently supported values: * -// `document` - Using suggestions generated from user-imported -// documents. * `search-history` - Using suggestions generated from the -// past history of SearchService.Search API calls. Do not use it when -// there is no traffic for Search API. * `user-event` - Using -// suggestions generated from user-imported search events. * -// `document-completable` - Using suggestions taken directly from -// user-imported document fields marked as completable. Default values: -// * `document` is the default model for regular dataStores. * -// `search-history` is the default model for site search dataStores. -func (c *ProjectsLocationsCollectionsDataStoresCompleteQueryCall) QueryModel(queryModel string) *ProjectsLocationsCollectionsDataStoresCompleteQueryCall { - c.urlParams_.Set("queryModel", queryModel) - return c -} - -// UserPseudoId sets the optional parameter "userPseudoId": A unique -// identifier for tracking visitors. For example, this could be -// implemented with an HTTP cookie, which should be able to uniquely -// identify a visitor on a single device. This unique identifier should -// not change if the visitor logs in or out of the website. This field -// should NOT have a fixed value such as `unknown_visitor`. This should -// be the same identifier as UserEvent.user_pseudo_id and -// SearchRequest.user_pseudo_id. The field must be a UTF-8 encoded -// string with a length limit of 128 characters. Otherwise, an -// `INVALID_ARGUMENT` error is returned. -func (c *ProjectsLocationsCollectionsDataStoresCompleteQueryCall) UserPseudoId(userPseudoId string) *ProjectsLocationsCollectionsDataStoresCompleteQueryCall { - c.urlParams_.Set("userPseudoId", userPseudoId) +// - siteSearchEngine: Full resource name of the SiteSearchEngine, such +// as +// `projects/*/locations/*/collections/*/dataStores/*/siteSearchEngine` +// . +func (r *ProjectsLocationsCollectionsDataStoresSiteSearchEngineService) RecrawlUris(siteSearchEngine string, googleclouddiscoveryenginev1betarecrawlurisrequest *GoogleCloudDiscoveryengineV1betaRecrawlUrisRequest) *ProjectsLocationsCollectionsDataStoresSiteSearchEngineRecrawlUrisCall { + c := &ProjectsLocationsCollectionsDataStoresSiteSearchEngineRecrawlUrisCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.siteSearchEngine = siteSearchEngine + c.googleclouddiscoveryenginev1betarecrawlurisrequest = googleclouddiscoveryenginev1betarecrawlurisrequest return c } // Fields allows partial responses to be retrieved. See // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse // for more information. -func (c *ProjectsLocationsCollectionsDataStoresCompleteQueryCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresCompleteQueryCall { +func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineRecrawlUrisCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresSiteSearchEngineRecrawlUrisCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// IfNoneMatch sets the 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. Use googleapi.IsNotModified to check whether the response -// error from Do is the result of In-None-Match. -func (c *ProjectsLocationsCollectionsDataStoresCompleteQueryCall) IfNoneMatch(entityTag string) *ProjectsLocationsCollectionsDataStoresCompleteQueryCall { - c.ifNoneMatch_ = entityTag - return c -} - // Context sets the context to be used in this call's Do method. Any // pending HTTP request will be aborted if the provided context is // canceled. -func (c *ProjectsLocationsCollectionsDataStoresCompleteQueryCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresCompleteQueryCall { +func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineRecrawlUrisCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresSiteSearchEngineRecrawlUrisCall { c.ctx_ = ctx return c } // Header returns an http.Header that can be modified by the caller to // add HTTP headers to the request. -func (c *ProjectsLocationsCollectionsDataStoresCompleteQueryCall) Header() http.Header { +func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineRecrawlUrisCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsCollectionsDataStoresCompleteQueryCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineRecrawlUrisCall) doRequest(alt string) (*http.Response, error) { reqHeaders := make(http.Header) reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) for k, v := range c.header_ { reqHeaders[k] = v } reqHeaders.Set("User-Agent", c.s.userAgent()) - if c.ifNoneMatch_ != "" { - reqHeaders.Set("If-None-Match", c.ifNoneMatch_) - } var body io.Reader = nil + body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddiscoveryenginev1betarecrawlurisrequest) + if err != nil { + return nil, err + } + reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+dataStore}:completeQuery") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+siteSearchEngine}:recrawlUris") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("GET", urls, body) + req, err := http.NewRequest("POST", urls, body) if err != nil { return nil, err } req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ - "dataStore": c.dataStore, - }) - return gensupport.SendRequest(c.ctx_, c.s.client, req) -} - -// Do executes the "discoveryengine.projects.locations.collections.dataStores.completeQuery" call. -// Exactly one of *GoogleCloudDiscoveryengineV1betaCompleteQueryResponse -// or error will be non-nil. Any non-2xx status code is an error. -// Response headers are in either -// *GoogleCloudDiscoveryengineV1betaCompleteQueryResponse.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 *ProjectsLocationsCollectionsDataStoresCompleteQueryCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1betaCompleteQueryResponse, error) { + "siteSearchEngine": c.siteSearchEngine, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "discoveryengine.projects.locations.collections.dataStores.siteSearchEngine.recrawlUris" call. +// Exactly one of *GoogleLongrunningOperation or error will be non-nil. +// 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 *ProjectsLocationsCollectionsDataStoresSiteSearchEngineRecrawlUrisCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -8688,7 +17430,7 @@ func (c *ProjectsLocationsCollectionsDataStoresCompleteQueryCall) Do(opts ...goo if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &GoogleCloudDiscoveryengineV1betaCompleteQueryResponse{ + ret := &GoogleLongrunningOperation{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -8700,45 +17442,28 @@ func (c *ProjectsLocationsCollectionsDataStoresCompleteQueryCall) Do(opts ...goo } return ret, nil // { - // "description": "Completes the specified user input with keyword suggestions.", - // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}:completeQuery", - // "httpMethod": "GET", - // "id": "discoveryengine.projects.locations.collections.dataStores.completeQuery", + // "description": "Request on-demand recrawl for a list of URIs.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/siteSearchEngine:recrawlUris", + // "httpMethod": "POST", + // "id": "discoveryengine.projects.locations.collections.dataStores.siteSearchEngine.recrawlUris", // "parameterOrder": [ - // "dataStore" + // "siteSearchEngine" // ], // "parameters": { - // "dataStore": { - // "description": "Required. The parent data store resource name for which the completion is performed, such as `projects/*/locations/global/collections/default_collection/dataStores/default_data_store`.", + // "siteSearchEngine": { + // "description": "Required. Full resource name of the SiteSearchEngine, such as `projects/*/locations/*/collections/*/dataStores/*/siteSearchEngine`.", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/siteSearchEngine$", // "required": true, // "type": "string" - // }, - // "includeTailSuggestions": { - // "description": "Indicates if tail suggestions should be returned if there are no suggestions that match the full query. Even if set to true, if there are suggestions that match the full query, those are returned and no tail suggestions are returned.", - // "location": "query", - // "type": "boolean" - // }, - // "query": { - // "description": "Required. The typeahead input used to fetch suggestions. Maximum length is 128 characters.", - // "location": "query", - // "type": "string" - // }, - // "queryModel": { - // "description": "Selects data model of query suggestions for serving. Currently supported values: * `document` - Using suggestions generated from user-imported documents. * `search-history` - Using suggestions generated from the past history of SearchService.Search API calls. Do not use it when there is no traffic for Search API. * `user-event` - Using suggestions generated from user-imported search events. * `document-completable` - Using suggestions taken directly from user-imported document fields marked as completable. Default values: * `document` is the default model for regular dataStores. * `search-history` is the default model for site search dataStores.", - // "location": "query", - // "type": "string" - // }, - // "userPseudoId": { - // "description": "A unique identifier for tracking visitors. For example, this could be implemented with an HTTP cookie, which should be able to uniquely identify a visitor on a single device. This unique identifier should not change if the visitor logs in or out of the website. This field should NOT have a fixed value such as `unknown_visitor`. This should be the same identifier as UserEvent.user_pseudo_id and SearchRequest.user_pseudo_id. The field must be a UTF-8 encoded string with a length limit of 128 characters. Otherwise, an `INVALID_ARGUMENT` error is returned.", - // "location": "query", - // "type": "string" // } // }, - // "path": "v1beta/{+dataStore}:completeQuery", + // "path": "v1beta/{+siteSearchEngine}:recrawlUris", + // "request": { + // "$ref": "GoogleCloudDiscoveryengineV1betaRecrawlUrisRequest" + // }, // "response": { - // "$ref": "GoogleCloudDiscoveryengineV1betaCompleteQueryResponse" + // "$ref": "GoogleLongrunningOperation" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -8747,107 +17472,97 @@ func (c *ProjectsLocationsCollectionsDataStoresCompleteQueryCall) Do(opts ...goo } -// method id "discoveryengine.projects.locations.collections.dataStores.branches.documents.create": +// method id "discoveryengine.projects.locations.collections.dataStores.siteSearchEngine.operations.get": -type ProjectsLocationsCollectionsDataStoresBranchesDocumentsCreateCall struct { - s *Service - parent string - googleclouddiscoveryenginev1betadocument *GoogleCloudDiscoveryengineV1betaDocument - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +type ProjectsLocationsCollectionsDataStoresSiteSearchEngineOperationsGetCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header } -// Create: Creates a Document. +// Get: Gets the latest state of a long-running operation. Clients can +// use this method to poll the operation result at intervals as +// recommended by the API service. // -// - parent: The parent resource name, such as -// `projects/{project}/locations/{location}/collections/{collection}/da -// taStores/{data_store}/branches/{branch}`. -func (r *ProjectsLocationsCollectionsDataStoresBranchesDocumentsService) Create(parent string, googleclouddiscoveryenginev1betadocument *GoogleCloudDiscoveryengineV1betaDocument) *ProjectsLocationsCollectionsDataStoresBranchesDocumentsCreateCall { - c := &ProjectsLocationsCollectionsDataStoresBranchesDocumentsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.parent = parent - c.googleclouddiscoveryenginev1betadocument = googleclouddiscoveryenginev1betadocument - return c -} - -// DocumentId sets the optional parameter "documentId": Required. The ID -// to use for the Document, which will become the final component of the -// Document.name. If the caller does not have permission to create the -// Document, regardless of whether or not it exists, a -// `PERMISSION_DENIED` error is returned. This field must be unique -// among all Documents with the same parent. Otherwise, an -// `ALREADY_EXISTS` error is returned. This field must conform to -// RFC-1034 (https://tools.ietf.org/html/rfc1034) standard with a length -// limit of 63 characters. Otherwise, an `INVALID_ARGUMENT` error is -// returned. -func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsCreateCall) DocumentId(documentId string) *ProjectsLocationsCollectionsDataStoresBranchesDocumentsCreateCall { - c.urlParams_.Set("documentId", documentId) +// - name: The name of the operation resource. +func (r *ProjectsLocationsCollectionsDataStoresSiteSearchEngineOperationsService) Get(name string) *ProjectsLocationsCollectionsDataStoresSiteSearchEngineOperationsGetCall { + c := &ProjectsLocationsCollectionsDataStoresSiteSearchEngineOperationsGetCall{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 information. -func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsCreateCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresBranchesDocumentsCreateCall { +func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineOperationsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresSiteSearchEngineOperationsGetCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } +// IfNoneMatch sets the 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. Use googleapi.IsNotModified to check whether the response +// error from Do is the result of In-None-Match. +func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineOperationsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsCollectionsDataStoresSiteSearchEngineOperationsGetCall { + c.ifNoneMatch_ = entityTag + return c +} + // Context sets the context to be used in this call's Do method. Any // pending HTTP request will be aborted if the provided context is // canceled. -func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsCreateCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresBranchesDocumentsCreateCall { +func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineOperationsGetCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresSiteSearchEngineOperationsGetCall { c.ctx_ = ctx return c } // Header returns an http.Header that can be modified by the caller to // add HTTP headers to the request. -func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsCreateCall) Header() http.Header { +func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineOperationsGetCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsCreateCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineOperationsGetCall) doRequest(alt string) (*http.Response, error) { reqHeaders := make(http.Header) reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) for k, v := range c.header_ { reqHeaders[k] = v } reqHeaders.Set("User-Agent", c.s.userAgent()) - var body io.Reader = nil - body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddiscoveryenginev1betadocument) - if err != nil { - return nil, err + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) } - reqHeaders.Set("Content-Type", "application/json") + var body io.Reader = nil c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+parent}/documents") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("POST", urls, body) + req, err := http.NewRequest("GET", urls, body) if err != nil { return nil, err } req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ - "parent": c.parent, + "name": c.name, }) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "discoveryengine.projects.locations.collections.dataStores.branches.documents.create" call. -// Exactly one of *GoogleCloudDiscoveryengineV1betaDocument or error -// will be non-nil. Any non-2xx status code is an error. Response -// headers are in either -// *GoogleCloudDiscoveryengineV1betaDocument.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 *ProjectsLocationsCollectionsDataStoresBranchesDocumentsCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1betaDocument, error) { +// Do executes the "discoveryengine.projects.locations.collections.dataStores.siteSearchEngine.operations.get" call. +// Exactly one of *GoogleLongrunningOperation or error will be non-nil. +// 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 *ProjectsLocationsCollectionsDataStoresSiteSearchEngineOperationsGetCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -8866,7 +17581,7 @@ func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsCreateCall) Do(o if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &GoogleCloudDiscoveryengineV1betaDocument{ + ret := &GoogleLongrunningOperation{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -8878,33 +17593,25 @@ func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsCreateCall) Do(o } return ret, nil // { - // "description": "Creates a Document.", - // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/branches/{branchesId}/documents", - // "httpMethod": "POST", - // "id": "discoveryengine.projects.locations.collections.dataStores.branches.documents.create", + // "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": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/siteSearchEngine/operations/{operationsId}", + // "httpMethod": "GET", + // "id": "discoveryengine.projects.locations.collections.dataStores.siteSearchEngine.operations.get", // "parameterOrder": [ - // "parent" + // "name" // ], // "parameters": { - // "documentId": { - // "description": "Required. The ID to use for the Document, which will become the final component of the Document.name. If the caller does not have permission to create the Document, regardless of whether or not it exists, a `PERMISSION_DENIED` error is returned. This field must be unique among all Documents with the same parent. Otherwise, an `ALREADY_EXISTS` error is returned. This field must conform to [RFC-1034](https://tools.ietf.org/html/rfc1034) standard with a length limit of 63 characters. Otherwise, an `INVALID_ARGUMENT` error is returned.", - // "location": "query", - // "type": "string" - // }, - // "parent": { - // "description": "Required. The parent resource name, such as `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/branches/{branch}`.", + // "name": { + // "description": "The name of the operation resource.", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/branches/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/siteSearchEngine/operations/[^/]+$", // "required": true, // "type": "string" // } // }, - // "path": "v1beta/{+parent}/documents", - // "request": { - // "$ref": "GoogleCloudDiscoveryengineV1betaDocument" - // }, + // "path": "v1beta/{+name}", // "response": { - // "$ref": "GoogleCloudDiscoveryengineV1betaDocument" + // "$ref": "GoogleLongrunningOperation" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -8913,69 +17620,100 @@ func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsCreateCall) Do(o } -// method id "discoveryengine.projects.locations.collections.dataStores.branches.documents.delete": +// method id "discoveryengine.projects.locations.collections.dataStores.siteSearchEngine.operations.list": -type ProjectsLocationsCollectionsDataStoresBranchesDocumentsDeleteCall struct { - s *Service - name string - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +type ProjectsLocationsCollectionsDataStoresSiteSearchEngineOperationsListCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header } -// Delete: Deletes a Document. +// List: Lists operations that match the specified filter in the +// request. If the server doesn't support this method, it returns +// `UNIMPLEMENTED`. // -// - name: Full resource name of Document, such as -// `projects/{project}/locations/{location}/collections/{collection}/da -// taStores/{data_store}/branches/{branch}/documents/{document}`. If -// the caller does not have permission to delete the Document, -// regardless of whether or not it exists, a `PERMISSION_DENIED` error -// is returned. If the Document to delete does not exist, a -// `NOT_FOUND` error is returned. -func (r *ProjectsLocationsCollectionsDataStoresBranchesDocumentsService) Delete(name string) *ProjectsLocationsCollectionsDataStoresBranchesDocumentsDeleteCall { - c := &ProjectsLocationsCollectionsDataStoresBranchesDocumentsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// - name: The name of the operation's parent resource. +func (r *ProjectsLocationsCollectionsDataStoresSiteSearchEngineOperationsService) List(name string) *ProjectsLocationsCollectionsDataStoresSiteSearchEngineOperationsListCall { + c := &ProjectsLocationsCollectionsDataStoresSiteSearchEngineOperationsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.name = name return c } +// Filter sets the optional parameter "filter": The standard list +// filter. +func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineOperationsListCall) Filter(filter string) *ProjectsLocationsCollectionsDataStoresSiteSearchEngineOperationsListCall { + c.urlParams_.Set("filter", filter) + return c +} + +// PageSize sets the optional parameter "pageSize": The standard list +// page size. +func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineOperationsListCall) PageSize(pageSize int64) *ProjectsLocationsCollectionsDataStoresSiteSearchEngineOperationsListCall { + c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) + return c +} + +// PageToken sets the optional parameter "pageToken": The standard list +// page token. +func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineOperationsListCall) PageToken(pageToken string) *ProjectsLocationsCollectionsDataStoresSiteSearchEngineOperationsListCall { + 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 information. -func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresBranchesDocumentsDeleteCall { +func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineOperationsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresSiteSearchEngineOperationsListCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } +// IfNoneMatch sets the 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. Use googleapi.IsNotModified to check whether the response +// error from Do is the result of In-None-Match. +func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineOperationsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsCollectionsDataStoresSiteSearchEngineOperationsListCall { + c.ifNoneMatch_ = entityTag + return c +} + // Context sets the context to be used in this call's Do method. Any // pending HTTP request will be aborted if the provided context is // canceled. -func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsDeleteCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresBranchesDocumentsDeleteCall { +func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineOperationsListCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresSiteSearchEngineOperationsListCall { c.ctx_ = ctx return c } // Header returns an http.Header that can be modified by the caller to // add HTTP headers to the request. -func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsDeleteCall) Header() http.Header { +func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineOperationsListCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsDeleteCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineOperationsListCall) doRequest(alt string) (*http.Response, error) { reqHeaders := make(http.Header) reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) for k, v := range c.header_ { reqHeaders[k] = v } reqHeaders.Set("User-Agent", c.s.userAgent()) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) + } var body io.Reader = nil c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}/operations") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("DELETE", urls, body) + req, err := http.NewRequest("GET", urls, body) if err != nil { return nil, err } @@ -8986,14 +17724,15 @@ func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsDeleteCall) doRe return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "discoveryengine.projects.locations.collections.dataStores.branches.documents.delete" call. -// Exactly one of *GoogleProtobufEmpty or error will be non-nil. Any -// non-2xx status code is an error. Response headers are in either -// *GoogleProtobufEmpty.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 +// Do executes the "discoveryengine.projects.locations.collections.dataStores.siteSearchEngine.operations.list" call. +// Exactly one of *GoogleLongrunningListOperationsResponse or error will +// be non-nil. Any non-2xx status code is an error. Response headers are +// in either +// *GoogleLongrunningListOperationsResponse.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 *ProjectsLocationsCollectionsDataStoresBranchesDocumentsDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, error) { +func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineOperationsListCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningListOperationsResponse, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -9012,7 +17751,7 @@ func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsDeleteCall) Do(o if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &GoogleProtobufEmpty{ + ret := &GoogleLongrunningListOperationsResponse{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -9024,25 +17763,41 @@ func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsDeleteCall) Do(o } return ret, nil // { - // "description": "Deletes a Document.", - // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/branches/{branchesId}/documents/{documentsId}", - // "httpMethod": "DELETE", - // "id": "discoveryengine.projects.locations.collections.dataStores.branches.documents.delete", + // "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/siteSearchEngine/operations", + // "httpMethod": "GET", + // "id": "discoveryengine.projects.locations.collections.dataStores.siteSearchEngine.operations.list", // "parameterOrder": [ // "name" // ], // "parameters": { + // "filter": { + // "description": "The standard list filter.", + // "location": "query", + // "type": "string" + // }, // "name": { - // "description": "Required. Full resource name of Document, such as `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/branches/{branch}/documents/{document}`. If the caller does not have permission to delete the Document, regardless of whether or not it exists, a `PERMISSION_DENIED` error is returned. If the Document to delete does not exist, a `NOT_FOUND` error is returned.", + // "description": "The name of the operation's parent resource.", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/branches/[^/]+/documents/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/siteSearchEngine$", // "required": true, // "type": "string" + // }, + // "pageSize": { + // "description": "The standard list page size.", + // "format": "int32", + // "location": "query", + // "type": "integer" + // }, + // "pageToken": { + // "description": "The standard list page token.", + // "location": "query", + // "type": "string" // } // }, - // "path": "v1beta/{+name}", + // "path": "v1beta/{+name}/operations", // "response": { - // "$ref": "GoogleProtobufEmpty" + // "$ref": "GoogleLongrunningListOperationsResponse" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -9051,103 +17806,114 @@ func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsDeleteCall) Do(o } -// method id "discoveryengine.projects.locations.collections.dataStores.branches.documents.get": +// 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 *ProjectsLocationsCollectionsDataStoresSiteSearchEngineOperationsListCall) Pages(ctx context.Context, f func(*GoogleLongrunningListOperationsResponse) error) error { + c.ctx_ = ctx + defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point + 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 ProjectsLocationsCollectionsDataStoresBranchesDocumentsGetCall struct { - s *Service - name string - urlParams_ gensupport.URLParams - ifNoneMatch_ string - ctx_ context.Context - header_ http.Header +// method id "discoveryengine.projects.locations.collections.dataStores.siteSearchEngine.targetSites.batchCreate": + +type ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesBatchCreateCall struct { + s *Service + parent string + googleclouddiscoveryenginev1betabatchcreatetargetsitesrequest *GoogleCloudDiscoveryengineV1betaBatchCreateTargetSitesRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// Get: Gets a Document. +// BatchCreate: Creates TargetSite in a batch. // -// - name: Full resource name of Document, such as +// - parent: The parent resource shared by all TargetSites being +// created. // `projects/{project}/locations/{location}/collections/{collection}/da -// taStores/{data_store}/branches/{branch}/documents/{document}`. If -// the caller does not have permission to access the Document, -// regardless of whether or not it exists, a `PERMISSION_DENIED` error -// is returned. If the requested Document does not exist, a -// `NOT_FOUND` error is returned. -func (r *ProjectsLocationsCollectionsDataStoresBranchesDocumentsService) Get(name string) *ProjectsLocationsCollectionsDataStoresBranchesDocumentsGetCall { - c := &ProjectsLocationsCollectionsDataStoresBranchesDocumentsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.name = name +// taStores/{data_store}/siteSearchEngine`. The parent field in the +// CreateBookRequest messages must either be empty or match this +// field. +func (r *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesService) BatchCreate(parent string, googleclouddiscoveryenginev1betabatchcreatetargetsitesrequest *GoogleCloudDiscoveryengineV1betaBatchCreateTargetSitesRequest) *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesBatchCreateCall { + c := &ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesBatchCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + c.googleclouddiscoveryenginev1betabatchcreatetargetsitesrequest = googleclouddiscoveryenginev1betabatchcreatetargetsitesrequest return c } // Fields allows partial responses to be retrieved. See // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse // for more information. -func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresBranchesDocumentsGetCall { +func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesBatchCreateCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesBatchCreateCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// IfNoneMatch sets the 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. Use googleapi.IsNotModified to check whether the response -// error from Do is the result of In-None-Match. -func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsCollectionsDataStoresBranchesDocumentsGetCall { - c.ifNoneMatch_ = entityTag - return c -} - // Context sets the context to be used in this call's Do method. Any // pending HTTP request will be aborted if the provided context is // canceled. -func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsGetCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresBranchesDocumentsGetCall { +func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesBatchCreateCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesBatchCreateCall { c.ctx_ = ctx return c } // Header returns an http.Header that can be modified by the caller to // add HTTP headers to the request. -func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsGetCall) Header() http.Header { +func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesBatchCreateCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsGetCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesBatchCreateCall) doRequest(alt string) (*http.Response, error) { reqHeaders := make(http.Header) reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) for k, v := range c.header_ { reqHeaders[k] = v } reqHeaders.Set("User-Agent", c.s.userAgent()) - if c.ifNoneMatch_ != "" { - reqHeaders.Set("If-None-Match", c.ifNoneMatch_) - } var body io.Reader = nil + body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddiscoveryenginev1betabatchcreatetargetsitesrequest) + if err != nil { + return nil, err + } + reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+parent}/targetSites:batchCreate") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("GET", urls, body) + req, err := http.NewRequest("POST", urls, body) if err != nil { return nil, err } req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ - "name": c.name, + "parent": c.parent, }) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "discoveryengine.projects.locations.collections.dataStores.branches.documents.get" call. -// Exactly one of *GoogleCloudDiscoveryengineV1betaDocument or error -// will be non-nil. Any non-2xx status code is an error. Response -// headers are in either -// *GoogleCloudDiscoveryengineV1betaDocument.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 *ProjectsLocationsCollectionsDataStoresBranchesDocumentsGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1betaDocument, error) { +// Do executes the "discoveryengine.projects.locations.collections.dataStores.siteSearchEngine.targetSites.batchCreate" call. +// Exactly one of *GoogleLongrunningOperation or error will be non-nil. +// 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 *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesBatchCreateCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -9166,7 +17932,7 @@ func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsGetCall) Do(opts if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &GoogleCloudDiscoveryengineV1betaDocument{ + ret := &GoogleLongrunningOperation{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -9178,25 +17944,28 @@ func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsGetCall) Do(opts } return ret, nil // { - // "description": "Gets a Document.", - // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/branches/{branchesId}/documents/{documentsId}", - // "httpMethod": "GET", - // "id": "discoveryengine.projects.locations.collections.dataStores.branches.documents.get", + // "description": "Creates TargetSite in a batch.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/siteSearchEngine/targetSites:batchCreate", + // "httpMethod": "POST", + // "id": "discoveryengine.projects.locations.collections.dataStores.siteSearchEngine.targetSites.batchCreate", // "parameterOrder": [ - // "name" + // "parent" // ], // "parameters": { - // "name": { - // "description": "Required. Full resource name of Document, such as `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/branches/{branch}/documents/{document}`. If the caller does not have permission to access the Document, regardless of whether or not it exists, a `PERMISSION_DENIED` error is returned. If the requested Document does not exist, a `NOT_FOUND` error is returned.", + // "parent": { + // "description": "Required. The parent resource shared by all TargetSites being created. `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/siteSearchEngine`. The parent field in the CreateBookRequest messages must either be empty or match this field.", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/branches/[^/]+/documents/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/siteSearchEngine$", // "required": true, // "type": "string" // } // }, - // "path": "v1beta/{+name}", + // "path": "v1beta/{+parent}/targetSites:batchCreate", + // "request": { + // "$ref": "GoogleCloudDiscoveryengineV1betaBatchCreateTargetSitesRequest" + // }, // "response": { - // "$ref": "GoogleCloudDiscoveryengineV1betaDocument" + // "$ref": "GoogleLongrunningOperation" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -9205,36 +17974,33 @@ func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsGetCall) Do(opts } -// method id "discoveryengine.projects.locations.collections.dataStores.branches.documents.import": +// method id "discoveryengine.projects.locations.collections.dataStores.siteSearchEngine.targetSites.create": -type ProjectsLocationsCollectionsDataStoresBranchesDocumentsImportCall struct { - s *Service - parent string - googleclouddiscoveryenginev1betaimportdocumentsrequest *GoogleCloudDiscoveryengineV1betaImportDocumentsRequest - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +type ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesCreateCall struct { + s *Service + parent string + googleclouddiscoveryenginev1betatargetsite *GoogleCloudDiscoveryengineV1betaTargetSite + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// Import: Bulk import of multiple Documents. Request processing may be -// synchronous. Non-existing items will be created. Note: It is possible -// for a subset of the Documents to be successfully updated. +// Create: Creates a TargetSite. // -// - parent: The parent branch resource name, such as +// - parent: Parent resource name of TargetSite, such as // `projects/{project}/locations/{location}/collections/{collection}/da -// taStores/{data_store}/branches/{branch}`. Requires create/update -// permission. -func (r *ProjectsLocationsCollectionsDataStoresBranchesDocumentsService) Import(parent string, googleclouddiscoveryenginev1betaimportdocumentsrequest *GoogleCloudDiscoveryengineV1betaImportDocumentsRequest) *ProjectsLocationsCollectionsDataStoresBranchesDocumentsImportCall { - c := &ProjectsLocationsCollectionsDataStoresBranchesDocumentsImportCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// taStores/{data_store}/siteSearchEngine`. +func (r *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesService) Create(parent string, googleclouddiscoveryenginev1betatargetsite *GoogleCloudDiscoveryengineV1betaTargetSite) *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesCreateCall { + c := &ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.parent = parent - c.googleclouddiscoveryenginev1betaimportdocumentsrequest = googleclouddiscoveryenginev1betaimportdocumentsrequest + c.googleclouddiscoveryenginev1betatargetsite = googleclouddiscoveryenginev1betatargetsite return c } // Fields allows partial responses to be retrieved. See // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse // for more information. -func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsImportCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresBranchesDocumentsImportCall { +func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesCreateCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesCreateCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } @@ -9242,21 +18008,21 @@ func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsImportCall) Fiel // Context sets the context to be used in this call's Do method. Any // pending HTTP request will be aborted if the provided context is // canceled. -func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsImportCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresBranchesDocumentsImportCall { +func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesCreateCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesCreateCall { c.ctx_ = ctx return c } // Header returns an http.Header that can be modified by the caller to // add HTTP headers to the request. -func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsImportCall) Header() http.Header { +func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesCreateCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsImportCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesCreateCall) doRequest(alt string) (*http.Response, error) { reqHeaders := make(http.Header) reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) for k, v := range c.header_ { @@ -9264,14 +18030,14 @@ func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsImportCall) doRe } reqHeaders.Set("User-Agent", c.s.userAgent()) var body io.Reader = nil - body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddiscoveryenginev1betaimportdocumentsrequest) + body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddiscoveryenginev1betatargetsite) if err != nil { return nil, err } reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+parent}/documents:import") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+parent}/targetSites") urls += "?" + c.urlParams_.Encode() req, err := http.NewRequest("POST", urls, body) if err != nil { @@ -9284,14 +18050,14 @@ func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsImportCall) doRe return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "discoveryengine.projects.locations.collections.dataStores.branches.documents.import" call. +// Do executes the "discoveryengine.projects.locations.collections.dataStores.siteSearchEngine.targetSites.create" call. // Exactly one of *GoogleLongrunningOperation or error will be non-nil. // 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 *ProjectsLocationsCollectionsDataStoresBranchesDocumentsImportCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { +func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesCreateCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -9322,25 +18088,25 @@ func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsImportCall) Do(o } return ret, nil // { - // "description": "Bulk import of multiple Documents. Request processing may be synchronous. Non-existing items will be created. Note: It is possible for a subset of the Documents to be successfully updated.", - // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/branches/{branchesId}/documents:import", + // "description": "Creates a TargetSite.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/siteSearchEngine/targetSites", // "httpMethod": "POST", - // "id": "discoveryengine.projects.locations.collections.dataStores.branches.documents.import", + // "id": "discoveryengine.projects.locations.collections.dataStores.siteSearchEngine.targetSites.create", // "parameterOrder": [ // "parent" // ], // "parameters": { // "parent": { - // "description": "Required. The parent branch resource name, such as `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/branches/{branch}`. Requires create/update permission.", + // "description": "Required. Parent resource name of TargetSite, such as `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/siteSearchEngine`.", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/branches/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/siteSearchEngine$", // "required": true, // "type": "string" // } // }, - // "path": "v1beta/{+parent}/documents:import", + // "path": "v1beta/{+parent}/targetSites", // "request": { - // "$ref": "GoogleCloudDiscoveryengineV1betaImportDocumentsRequest" + // "$ref": "GoogleCloudDiscoveryengineV1betaTargetSite" // }, // "response": { // "$ref": "GoogleLongrunningOperation" @@ -9352,123 +18118,87 @@ func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsImportCall) Do(o } -// method id "discoveryengine.projects.locations.collections.dataStores.branches.documents.list": +// method id "discoveryengine.projects.locations.collections.dataStores.siteSearchEngine.targetSites.delete": -type ProjectsLocationsCollectionsDataStoresBranchesDocumentsListCall struct { - s *Service - parent string - urlParams_ gensupport.URLParams - ifNoneMatch_ string - ctx_ context.Context - header_ http.Header +type ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesDeleteCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// List: Gets a list of Documents. +// Delete: Deletes a TargetSite. // -// - parent: The parent branch resource name, such as +// - name: Full resource name of TargetSite, such as // `projects/{project}/locations/{location}/collections/{collection}/da -// taStores/{data_store}/branches/{branch}`. Use `default_branch` as -// the branch ID, to list documents under the default branch. If the -// caller does not have permission to list Documents under this -// branch, regardless of whether or not this branch exists, a -// `PERMISSION_DENIED` error is returned. -func (r *ProjectsLocationsCollectionsDataStoresBranchesDocumentsService) List(parent string) *ProjectsLocationsCollectionsDataStoresBranchesDocumentsListCall { - c := &ProjectsLocationsCollectionsDataStoresBranchesDocumentsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.parent = parent - return c -} - -// PageSize sets the optional parameter "pageSize": Maximum number of -// Documents to return. If unspecified, defaults to 100. The maximum -// allowed value is 1000. Values above 1000 will be coerced to 1000. If -// this field is negative, an `INVALID_ARGUMENT` error is returned. -func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsListCall) PageSize(pageSize int64) *ProjectsLocationsCollectionsDataStoresBranchesDocumentsListCall { - c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) - return c -} - -// PageToken sets the optional parameter "pageToken": A page token -// ListDocumentsResponse.next_page_token, received from a previous -// DocumentService.ListDocuments call. Provide this to retrieve the -// subsequent page. When paginating, all other parameters provided to -// DocumentService.ListDocuments must match the call that provided the -// page token. Otherwise, an `INVALID_ARGUMENT` error is returned. -func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsListCall) PageToken(pageToken string) *ProjectsLocationsCollectionsDataStoresBranchesDocumentsListCall { - c.urlParams_.Set("pageToken", pageToken) +// taStores/{data_store}/siteSearchEngine/targetSites/{target_site}`. +// If the caller does not have permission to access the TargetSite, +// regardless of whether or not it exists, a PERMISSION_DENIED error +// is returned. If the requested TargetSite does not exist, a +// NOT_FOUND error is returned. +func (r *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesService) Delete(name string) *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesDeleteCall { + c := &ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesDeleteCall{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 information. -func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresBranchesDocumentsListCall { +func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesDeleteCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// IfNoneMatch sets the 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. Use googleapi.IsNotModified to check whether the response -// error from Do is the result of In-None-Match. -func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsCollectionsDataStoresBranchesDocumentsListCall { - c.ifNoneMatch_ = entityTag - return c -} - // Context sets the context to be used in this call's Do method. Any // pending HTTP request will be aborted if the provided context is // canceled. -func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsListCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresBranchesDocumentsListCall { +func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesDeleteCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesDeleteCall { c.ctx_ = ctx return c } // Header returns an http.Header that can be modified by the caller to // add HTTP headers to the request. -func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsListCall) Header() http.Header { +func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesDeleteCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsListCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesDeleteCall) doRequest(alt string) (*http.Response, error) { reqHeaders := make(http.Header) reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) for k, v := range c.header_ { reqHeaders[k] = v } reqHeaders.Set("User-Agent", c.s.userAgent()) - if c.ifNoneMatch_ != "" { - reqHeaders.Set("If-None-Match", c.ifNoneMatch_) - } var body io.Reader = nil c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+parent}/documents") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("GET", urls, body) + req, err := http.NewRequest("DELETE", urls, body) if err != nil { return nil, err } req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ - "parent": c.parent, + "name": c.name, }) - return gensupport.SendRequest(c.ctx_, c.s.client, req) -} - -// Do executes the "discoveryengine.projects.locations.collections.dataStores.branches.documents.list" call. -// Exactly one of *GoogleCloudDiscoveryengineV1betaListDocumentsResponse -// or error will be non-nil. Any non-2xx status code is an error. -// Response headers are in either -// *GoogleCloudDiscoveryengineV1betaListDocumentsResponse.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 *ProjectsLocationsCollectionsDataStoresBranchesDocumentsListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1betaListDocumentsResponse, error) { + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "discoveryengine.projects.locations.collections.dataStores.siteSearchEngine.targetSites.delete" call. +// Exactly one of *GoogleLongrunningOperation or error will be non-nil. +// 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 *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -9487,7 +18217,7 @@ func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsListCall) Do(opt if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &GoogleCloudDiscoveryengineV1betaListDocumentsResponse{ + ret := &GoogleLongrunningOperation{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -9499,36 +18229,25 @@ func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsListCall) Do(opt } return ret, nil // { - // "description": "Gets a list of Documents.", - // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/branches/{branchesId}/documents", - // "httpMethod": "GET", - // "id": "discoveryengine.projects.locations.collections.dataStores.branches.documents.list", + // "description": "Deletes a TargetSite.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/siteSearchEngine/targetSites/{targetSitesId}", + // "httpMethod": "DELETE", + // "id": "discoveryengine.projects.locations.collections.dataStores.siteSearchEngine.targetSites.delete", // "parameterOrder": [ - // "parent" + // "name" // ], // "parameters": { - // "pageSize": { - // "description": "Maximum number of Documents to return. If unspecified, defaults to 100. The maximum allowed value is 1000. Values above 1000 will be coerced to 1000. If this field is negative, an `INVALID_ARGUMENT` error is returned.", - // "format": "int32", - // "location": "query", - // "type": "integer" - // }, - // "pageToken": { - // "description": "A page token ListDocumentsResponse.next_page_token, received from a previous DocumentService.ListDocuments call. Provide this to retrieve the subsequent page. When paginating, all other parameters provided to DocumentService.ListDocuments must match the call that provided the page token. Otherwise, an `INVALID_ARGUMENT` error is returned.", - // "location": "query", - // "type": "string" - // }, - // "parent": { - // "description": "Required. The parent branch resource name, such as `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/branches/{branch}`. Use `default_branch` as the branch ID, to list documents under the default branch. If the caller does not have permission to list Documents under this branch, regardless of whether or not this branch exists, a `PERMISSION_DENIED` error is returned.", + // "name": { + // "description": "Required. Full resource name of TargetSite, such as `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/siteSearchEngine/targetSites/{target_site}`. If the caller does not have permission to access the TargetSite, regardless of whether or not it exists, a PERMISSION_DENIED error is returned. If the requested TargetSite does not exist, a NOT_FOUND error is returned.", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/branches/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/siteSearchEngine/targetSites/[^/]+$", // "required": true, // "type": "string" // } // }, - // "path": "v1beta/{+parent}/documents", + // "path": "v1beta/{+name}", // "response": { - // "$ref": "GoogleCloudDiscoveryengineV1betaListDocumentsResponse" + // "$ref": "GoogleLongrunningOperation" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -9537,102 +18256,83 @@ func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsListCall) Do(opt } -// 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 *ProjectsLocationsCollectionsDataStoresBranchesDocumentsListCall) Pages(ctx context.Context, f func(*GoogleCloudDiscoveryengineV1betaListDocumentsResponse) error) error { - c.ctx_ = ctx - defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point - 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) - } -} - -// method id "discoveryengine.projects.locations.collections.dataStores.branches.documents.patch": +// method id "discoveryengine.projects.locations.collections.dataStores.siteSearchEngine.targetSites.get": -type ProjectsLocationsCollectionsDataStoresBranchesDocumentsPatchCall struct { - s *Service - name string - googleclouddiscoveryenginev1betadocument *GoogleCloudDiscoveryengineV1betaDocument - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +type ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesGetCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header } -// Patch: Updates a Document. +// Get: Gets a TargetSite. // -// - name: Immutable. The full resource name of the document. Format: +// - name: Full resource name of TargetSite, such as // `projects/{project}/locations/{location}/collections/{collection}/da -// taStores/{data_store}/branches/{branch}/documents/{document_id}`. -// This field must be a UTF-8 encoded string with a length limit of -// 1024 characters. -func (r *ProjectsLocationsCollectionsDataStoresBranchesDocumentsService) Patch(name string, googleclouddiscoveryenginev1betadocument *GoogleCloudDiscoveryengineV1betaDocument) *ProjectsLocationsCollectionsDataStoresBranchesDocumentsPatchCall { - c := &ProjectsLocationsCollectionsDataStoresBranchesDocumentsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// taStores/{data_store}/siteSearchEngine/targetSites/{target_site}`. +// If the caller does not have permission to access the TargetSite, +// regardless of whether or not it exists, a PERMISSION_DENIED error +// is returned. If the requested TargetSite does not exist, a +// NOT_FOUND error is returned. +func (r *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesService) Get(name string) *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesGetCall { + c := &ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.name = name - c.googleclouddiscoveryenginev1betadocument = googleclouddiscoveryenginev1betadocument - return c -} - -// AllowMissing sets the optional parameter "allowMissing": If set to -// true, and the Document is not found, a new Document will be created. -func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsPatchCall) AllowMissing(allowMissing bool) *ProjectsLocationsCollectionsDataStoresBranchesDocumentsPatchCall { - c.urlParams_.Set("allowMissing", fmt.Sprint(allowMissing)) return c } // Fields allows partial responses to be retrieved. See // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse // for more information. -func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsPatchCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresBranchesDocumentsPatchCall { +func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesGetCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } +// IfNoneMatch sets the 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. Use googleapi.IsNotModified to check whether the response +// error from Do is the result of In-None-Match. +func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesGetCall { + c.ifNoneMatch_ = entityTag + return c +} + // Context sets the context to be used in this call's Do method. Any // pending HTTP request will be aborted if the provided context is // canceled. -func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsPatchCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresBranchesDocumentsPatchCall { +func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesGetCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesGetCall { c.ctx_ = ctx return c } // Header returns an http.Header that can be modified by the caller to // add HTTP headers to the request. -func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsPatchCall) Header() http.Header { +func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesGetCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsPatchCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesGetCall) doRequest(alt string) (*http.Response, error) { reqHeaders := make(http.Header) reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) for k, v := range c.header_ { reqHeaders[k] = v } reqHeaders.Set("User-Agent", c.s.userAgent()) - var body io.Reader = nil - body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddiscoveryenginev1betadocument) - if err != nil { - return nil, err + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) } - reqHeaders.Set("Content-Type", "application/json") + var body io.Reader = nil 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) + req, err := http.NewRequest("GET", urls, body) if err != nil { return nil, err } @@ -9643,16 +18343,16 @@ func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsPatchCall) doReq return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "discoveryengine.projects.locations.collections.dataStores.branches.documents.patch" call. -// Exactly one of *GoogleCloudDiscoveryengineV1betaDocument or error +// Do executes the "discoveryengine.projects.locations.collections.dataStores.siteSearchEngine.targetSites.get" call. +// Exactly one of *GoogleCloudDiscoveryengineV1betaTargetSite or error // will be non-nil. Any non-2xx status code is an error. Response // headers are in either -// *GoogleCloudDiscoveryengineV1betaDocument.ServerResponse.Header or +// *GoogleCloudDiscoveryengineV1betaTargetSite.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 *ProjectsLocationsCollectionsDataStoresBranchesDocumentsPatchCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1betaDocument, error) { +func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1betaTargetSite, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -9671,7 +18371,7 @@ func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsPatchCall) Do(op if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &GoogleCloudDiscoveryengineV1betaDocument{ + ret := &GoogleCloudDiscoveryengineV1betaTargetSite{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -9683,33 +18383,25 @@ func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsPatchCall) Do(op } return ret, nil // { - // "description": "Updates a Document.", - // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/branches/{branchesId}/documents/{documentsId}", - // "httpMethod": "PATCH", - // "id": "discoveryengine.projects.locations.collections.dataStores.branches.documents.patch", + // "description": "Gets a TargetSite.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/siteSearchEngine/targetSites/{targetSitesId}", + // "httpMethod": "GET", + // "id": "discoveryengine.projects.locations.collections.dataStores.siteSearchEngine.targetSites.get", // "parameterOrder": [ // "name" // ], // "parameters": { - // "allowMissing": { - // "description": "If set to true, and the Document is not found, a new Document will be created.", - // "location": "query", - // "type": "boolean" - // }, // "name": { - // "description": "Immutable. The full resource name of the document. Format: `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/branches/{branch}/documents/{document_id}`. This field must be a UTF-8 encoded string with a length limit of 1024 characters.", + // "description": "Required. Full resource name of TargetSite, such as `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/siteSearchEngine/targetSites/{target_site}`. If the caller does not have permission to access the TargetSite, regardless of whether or not it exists, a PERMISSION_DENIED error is returned. If the requested TargetSite does not exist, a NOT_FOUND error is returned.", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/branches/[^/]+/documents/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/siteSearchEngine/targetSites/[^/]+$", // "required": true, // "type": "string" // } // }, // "path": "v1beta/{+name}", - // "request": { - // "$ref": "GoogleCloudDiscoveryengineV1betaDocument" - // }, // "response": { - // "$ref": "GoogleCloudDiscoveryengineV1betaDocument" + // "$ref": "GoogleCloudDiscoveryengineV1betaTargetSite" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -9718,78 +18410,102 @@ func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsPatchCall) Do(op } -// method id "discoveryengine.projects.locations.collections.dataStores.branches.documents.purge": +// method id "discoveryengine.projects.locations.collections.dataStores.siteSearchEngine.targetSites.list": -type ProjectsLocationsCollectionsDataStoresBranchesDocumentsPurgeCall struct { - s *Service - parent string - googleclouddiscoveryenginev1betapurgedocumentsrequest *GoogleCloudDiscoveryengineV1betaPurgeDocumentsRequest - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +type ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesListCall struct { + s *Service + parent string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header } -// Purge: Permanently deletes all selected Documents in a branch. This -// process is asynchronous. Depending on the number of Documents to be -// deleted, this operation can take hours to complete. Before the delete -// operation completes, some Documents might still be returned by -// DocumentService.GetDocument or DocumentService.ListDocuments. To get -// a list of the Documents to be deleted, set -// PurgeDocumentsRequest.force to false. +// List: Gets a list of TargetSites. // -// - parent: The parent resource name, such as +// - parent: The parent site search engine resource name, such as // `projects/{project}/locations/{location}/collections/{collection}/da -// taStores/{data_store}/branches/{branch}`. -func (r *ProjectsLocationsCollectionsDataStoresBranchesDocumentsService) Purge(parent string, googleclouddiscoveryenginev1betapurgedocumentsrequest *GoogleCloudDiscoveryengineV1betaPurgeDocumentsRequest) *ProjectsLocationsCollectionsDataStoresBranchesDocumentsPurgeCall { - c := &ProjectsLocationsCollectionsDataStoresBranchesDocumentsPurgeCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// taStores/{data_store}/siteSearchEngine`. If the caller does not +// have permission to list TargetSites under this site search engine, +// regardless of whether or not this branch exists, a +// PERMISSION_DENIED error is returned. +func (r *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesService) List(parent string) *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesListCall { + c := &ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesListCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.parent = parent - c.googleclouddiscoveryenginev1betapurgedocumentsrequest = googleclouddiscoveryenginev1betapurgedocumentsrequest + 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. The maximum value is 1000; values +// above 1000 will be coerced to 1000. If this field is negative, an +// INVALID_ARGUMENT error is returned. +func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesListCall) PageSize(pageSize int64) *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesListCall { + c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) + return c +} + +// PageToken sets the optional parameter "pageToken": A page token, +// received from a previous `ListTargetSites` call. Provide this to +// retrieve the subsequent page. When paginating, all other parameters +// provided to `ListTargetSites` must match the call that provided the +// page token. +func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesListCall) PageToken(pageToken string) *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesListCall { + 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 information. -func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsPurgeCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresBranchesDocumentsPurgeCall { +func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesListCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesListCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } +// IfNoneMatch sets the 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. Use googleapi.IsNotModified to check whether the response +// error from Do is the result of In-None-Match. +func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesListCall) IfNoneMatch(entityTag string) *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesListCall { + c.ifNoneMatch_ = entityTag + return c +} + // Context sets the context to be used in this call's Do method. Any // pending HTTP request will be aborted if the provided context is // canceled. -func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsPurgeCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresBranchesDocumentsPurgeCall { +func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesListCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesListCall { c.ctx_ = ctx return c } // Header returns an http.Header that can be modified by the caller to // add HTTP headers to the request. -func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsPurgeCall) Header() http.Header { +func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesListCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsPurgeCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesListCall) doRequest(alt string) (*http.Response, error) { reqHeaders := make(http.Header) reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) for k, v := range c.header_ { reqHeaders[k] = v } reqHeaders.Set("User-Agent", c.s.userAgent()) - var body io.Reader = nil - body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddiscoveryenginev1betapurgedocumentsrequest) - if err != nil { - return nil, err + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) } - reqHeaders.Set("Content-Type", "application/json") + var body io.Reader = nil c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+parent}/documents:purge") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+parent}/targetSites") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("POST", urls, body) + req, err := http.NewRequest("GET", urls, body) if err != nil { return nil, err } @@ -9800,14 +18516,17 @@ func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsPurgeCall) doReq return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "discoveryengine.projects.locations.collections.dataStores.branches.documents.purge" call. -// Exactly one of *GoogleLongrunningOperation or error will be non-nil. -// 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 *ProjectsLocationsCollectionsDataStoresBranchesDocumentsPurgeCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { +// Do executes the "discoveryengine.projects.locations.collections.dataStores.siteSearchEngine.targetSites.list" call. +// Exactly one of +// *GoogleCloudDiscoveryengineV1betaListTargetSitesResponse or error +// will be non-nil. Any non-2xx status code is an error. Response +// headers are in either +// *GoogleCloudDiscoveryengineV1betaListTargetSitesResponse.ServerRespons +// e.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 *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1betaListTargetSitesResponse, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -9826,7 +18545,7 @@ func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsPurgeCall) Do(op if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &GoogleLongrunningOperation{ + ret := &GoogleCloudDiscoveryengineV1betaListTargetSitesResponse{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -9838,28 +18557,36 @@ func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsPurgeCall) Do(op } return ret, nil // { - // "description": "Permanently deletes all selected Documents in a branch. This process is asynchronous. Depending on the number of Documents to be deleted, this operation can take hours to complete. Before the delete operation completes, some Documents might still be returned by DocumentService.GetDocument or DocumentService.ListDocuments. To get a list of the Documents to be deleted, set PurgeDocumentsRequest.force to false.", - // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/branches/{branchesId}/documents:purge", - // "httpMethod": "POST", - // "id": "discoveryengine.projects.locations.collections.dataStores.branches.documents.purge", + // "description": "Gets a list of TargetSites.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/siteSearchEngine/targetSites", + // "httpMethod": "GET", + // "id": "discoveryengine.projects.locations.collections.dataStores.siteSearchEngine.targetSites.list", // "parameterOrder": [ // "parent" // ], // "parameters": { + // "pageSize": { + // "description": "Requested page size. Server may return fewer items than requested. If unspecified, server will pick an appropriate default. The maximum value is 1000; values above 1000 will be coerced to 1000. If this field is negative, an INVALID_ARGUMENT error is returned.", + // "format": "int32", + // "location": "query", + // "type": "integer" + // }, + // "pageToken": { + // "description": "A page token, received from a previous `ListTargetSites` call. Provide this to retrieve the subsequent page. When paginating, all other parameters provided to `ListTargetSites` must match the call that provided the page token.", + // "location": "query", + // "type": "string" + // }, // "parent": { - // "description": "Required. The parent resource name, such as `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/branches/{branch}`.", + // "description": "Required. The parent site search engine resource name, such as `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/siteSearchEngine`. If the caller does not have permission to list TargetSites under this site search engine, regardless of whether or not this branch exists, a PERMISSION_DENIED error is returned.", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/branches/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/siteSearchEngine$", // "required": true, // "type": "string" // } // }, - // "path": "v1beta/{+parent}/documents:purge", - // "request": { - // "$ref": "GoogleCloudDiscoveryengineV1betaPurgeDocumentsRequest" - // }, + // "path": "v1beta/{+parent}/targetSites", // "response": { - // "$ref": "GoogleLongrunningOperation" + // "$ref": "GoogleCloudDiscoveryengineV1betaListTargetSitesResponse" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -9868,79 +18595,95 @@ func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsPurgeCall) Do(op } -// method id "discoveryengine.projects.locations.collections.dataStores.branches.operations.get": +// 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 *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesListCall) Pages(ctx context.Context, f func(*GoogleCloudDiscoveryengineV1betaListTargetSitesResponse) error) error { + c.ctx_ = ctx + defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point + 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 ProjectsLocationsCollectionsDataStoresBranchesOperationsGetCall struct { - s *Service - name string - urlParams_ gensupport.URLParams - ifNoneMatch_ string - ctx_ context.Context - header_ http.Header +// method id "discoveryengine.projects.locations.collections.dataStores.siteSearchEngine.targetSites.patch": + +type ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesPatchCall struct { + s *Service + name string + googleclouddiscoveryenginev1betatargetsite *GoogleCloudDiscoveryengineV1betaTargetSite + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// Get: Gets the latest state of a long-running operation. Clients can -// use this method to poll the operation result at intervals as -// recommended by the API service. +// Patch: Updates a TargetSite. // -// - name: The name of the operation resource. -func (r *ProjectsLocationsCollectionsDataStoresBranchesOperationsService) Get(name string) *ProjectsLocationsCollectionsDataStoresBranchesOperationsGetCall { - c := &ProjectsLocationsCollectionsDataStoresBranchesOperationsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// - name: Output only. The fully qualified resource name of the target +// site. +// `projects/{project}/locations/{location}/collections/{collection}/da +// taStores/{data_store}/siteSearchEngine/targetSites/{target_site}` +// The `target_site_id` is system-generated. +func (r *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesService) Patch(name string, googleclouddiscoveryenginev1betatargetsite *GoogleCloudDiscoveryengineV1betaTargetSite) *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesPatchCall { + c := &ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.name = name + c.googleclouddiscoveryenginev1betatargetsite = googleclouddiscoveryenginev1betatargetsite return c } // Fields allows partial responses to be retrieved. See // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse // for more information. -func (c *ProjectsLocationsCollectionsDataStoresBranchesOperationsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresBranchesOperationsGetCall { +func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesPatchCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesPatchCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// IfNoneMatch sets the 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. Use googleapi.IsNotModified to check whether the response -// error from Do is the result of In-None-Match. -func (c *ProjectsLocationsCollectionsDataStoresBranchesOperationsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsCollectionsDataStoresBranchesOperationsGetCall { - c.ifNoneMatch_ = entityTag - return c -} - // Context sets the context to be used in this call's Do method. Any // pending HTTP request will be aborted if the provided context is // canceled. -func (c *ProjectsLocationsCollectionsDataStoresBranchesOperationsGetCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresBranchesOperationsGetCall { +func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesPatchCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesPatchCall { c.ctx_ = ctx return c } // Header returns an http.Header that can be modified by the caller to // add HTTP headers to the request. -func (c *ProjectsLocationsCollectionsDataStoresBranchesOperationsGetCall) Header() http.Header { +func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesPatchCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsCollectionsDataStoresBranchesOperationsGetCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesPatchCall) doRequest(alt string) (*http.Response, error) { reqHeaders := make(http.Header) reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) for k, v := range c.header_ { reqHeaders[k] = v } reqHeaders.Set("User-Agent", c.s.userAgent()) - if c.ifNoneMatch_ != "" { - reqHeaders.Set("If-None-Match", c.ifNoneMatch_) - } var body io.Reader = nil + body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddiscoveryenginev1betatargetsite) + if err != nil { + return nil, err + } + reqHeaders.Set("Content-Type", "application/json") 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, body) + req, err := http.NewRequest("PATCH", urls, body) if err != nil { return nil, err } @@ -9951,14 +18694,14 @@ func (c *ProjectsLocationsCollectionsDataStoresBranchesOperationsGetCall) doRequ return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "discoveryengine.projects.locations.collections.dataStores.branches.operations.get" call. +// Do executes the "discoveryengine.projects.locations.collections.dataStores.siteSearchEngine.targetSites.patch" call. // Exactly one of *GoogleLongrunningOperation or error will be non-nil. // 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 *ProjectsLocationsCollectionsDataStoresBranchesOperationsGetCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { +func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesPatchCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -9989,23 +18732,26 @@ func (c *ProjectsLocationsCollectionsDataStoresBranchesOperationsGetCall) Do(opt } return ret, nil // { - // "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": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/branches/{branchesId}/operations/{operationsId}", - // "httpMethod": "GET", - // "id": "discoveryengine.projects.locations.collections.dataStores.branches.operations.get", + // "description": "Updates a TargetSite.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/siteSearchEngine/targetSites/{targetSitesId}", + // "httpMethod": "PATCH", + // "id": "discoveryengine.projects.locations.collections.dataStores.siteSearchEngine.targetSites.patch", // "parameterOrder": [ // "name" // ], // "parameters": { // "name": { - // "description": "The name of the operation resource.", + // "description": "Output only. The fully qualified resource name of the target site. `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/siteSearchEngine/targetSites/{target_site}` The `target_site_id` is system-generated.", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/branches/[^/]+/operations/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/siteSearchEngine/targetSites/[^/]+$", // "required": true, // "type": "string" // } // }, // "path": "v1beta/{+name}", + // "request": { + // "$ref": "GoogleCloudDiscoveryengineV1betaTargetSite" + // }, // "response": { // "$ref": "GoogleLongrunningOperation" // }, @@ -10016,9 +18762,9 @@ func (c *ProjectsLocationsCollectionsDataStoresBranchesOperationsGetCall) Do(opt } -// method id "discoveryengine.projects.locations.collections.dataStores.branches.operations.list": +// method id "discoveryengine.projects.locations.collections.dataStores.siteSearchEngine.targetSites.operations.get": -type ProjectsLocationsCollectionsDataStoresBranchesOperationsListCall struct { +type ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesOperationsGetCall struct { s *Service name string urlParams_ gensupport.URLParams @@ -10027,42 +18773,21 @@ type ProjectsLocationsCollectionsDataStoresBranchesOperationsListCall struct { 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`. +// Get: Gets the latest state of a long-running operation. Clients can +// use this method to poll the operation result at intervals as +// recommended by the API service. // -// - name: The name of the operation's parent resource. -func (r *ProjectsLocationsCollectionsDataStoresBranchesOperationsService) List(name string) *ProjectsLocationsCollectionsDataStoresBranchesOperationsListCall { - c := &ProjectsLocationsCollectionsDataStoresBranchesOperationsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// - name: The name of the operation resource. +func (r *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesOperationsService) Get(name string) *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesOperationsGetCall { + c := &ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesOperationsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.name = name return c } -// Filter sets the optional parameter "filter": The standard list -// filter. -func (c *ProjectsLocationsCollectionsDataStoresBranchesOperationsListCall) Filter(filter string) *ProjectsLocationsCollectionsDataStoresBranchesOperationsListCall { - c.urlParams_.Set("filter", filter) - return c -} - -// PageSize sets the optional parameter "pageSize": The standard list -// page size. -func (c *ProjectsLocationsCollectionsDataStoresBranchesOperationsListCall) PageSize(pageSize int64) *ProjectsLocationsCollectionsDataStoresBranchesOperationsListCall { - c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) - return c -} - -// PageToken sets the optional parameter "pageToken": The standard list -// page token. -func (c *ProjectsLocationsCollectionsDataStoresBranchesOperationsListCall) PageToken(pageToken string) *ProjectsLocationsCollectionsDataStoresBranchesOperationsListCall { - 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 information. -func (c *ProjectsLocationsCollectionsDataStoresBranchesOperationsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresBranchesOperationsListCall { +func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesOperationsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesOperationsGetCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } @@ -10072,7 +18797,7 @@ func (c *ProjectsLocationsCollectionsDataStoresBranchesOperationsListCall) Field // getting updates only after the object has changed since the last // request. Use googleapi.IsNotModified to check whether the response // error from Do is the result of In-None-Match. -func (c *ProjectsLocationsCollectionsDataStoresBranchesOperationsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsCollectionsDataStoresBranchesOperationsListCall { +func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesOperationsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesOperationsGetCall { c.ifNoneMatch_ = entityTag return c } @@ -10080,21 +18805,21 @@ func (c *ProjectsLocationsCollectionsDataStoresBranchesOperationsListCall) IfNon // Context sets the context to be used in this call's Do method. Any // pending HTTP request will be aborted if the provided context is // canceled. -func (c *ProjectsLocationsCollectionsDataStoresBranchesOperationsListCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresBranchesOperationsListCall { +func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesOperationsGetCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesOperationsGetCall { c.ctx_ = ctx return c } // Header returns an http.Header that can be modified by the caller to // add HTTP headers to the request. -func (c *ProjectsLocationsCollectionsDataStoresBranchesOperationsListCall) Header() http.Header { +func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesOperationsGetCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsCollectionsDataStoresBranchesOperationsListCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesOperationsGetCall) doRequest(alt string) (*http.Response, error) { reqHeaders := make(http.Header) reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) for k, v := range c.header_ { @@ -10107,7 +18832,7 @@ func (c *ProjectsLocationsCollectionsDataStoresBranchesOperationsListCall) doReq var body io.Reader = nil c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}/operations") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}") urls += "?" + c.urlParams_.Encode() req, err := http.NewRequest("GET", urls, body) if err != nil { @@ -10120,15 +18845,14 @@ func (c *ProjectsLocationsCollectionsDataStoresBranchesOperationsListCall) doReq return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "discoveryengine.projects.locations.collections.dataStores.branches.operations.list" call. -// Exactly one of *GoogleLongrunningListOperationsResponse or error will -// be non-nil. Any non-2xx status code is an error. Response headers are -// in either -// *GoogleLongrunningListOperationsResponse.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 +// Do executes the "discoveryengine.projects.locations.collections.dataStores.siteSearchEngine.targetSites.operations.get" call. +// Exactly one of *GoogleLongrunningOperation or error will be non-nil. +// 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 *ProjectsLocationsCollectionsDataStoresBranchesOperationsListCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningListOperationsResponse, error) { +func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesOperationsGetCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -10147,7 +18871,7 @@ func (c *ProjectsLocationsCollectionsDataStoresBranchesOperationsListCall) Do(op if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &GoogleLongrunningListOperationsResponse{ + ret := &GoogleLongrunningOperation{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -10159,41 +18883,25 @@ func (c *ProjectsLocationsCollectionsDataStoresBranchesOperationsListCall) Do(op } return ret, nil // { - // "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`.", - // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/branches/{branchesId}/operations", + // "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": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/siteSearchEngine/targetSites/operations/{operationsId}", // "httpMethod": "GET", - // "id": "discoveryengine.projects.locations.collections.dataStores.branches.operations.list", + // "id": "discoveryengine.projects.locations.collections.dataStores.siteSearchEngine.targetSites.operations.get", // "parameterOrder": [ // "name" // ], // "parameters": { - // "filter": { - // "description": "The standard list filter.", - // "location": "query", - // "type": "string" - // }, // "name": { - // "description": "The name of the operation's parent resource.", + // "description": "The name of the operation resource.", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/branches/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/siteSearchEngine/targetSites/operations/[^/]+$", // "required": true, // "type": "string" - // }, - // "pageSize": { - // "description": "The standard list page size.", - // "format": "int32", - // "location": "query", - // "type": "integer" - // }, - // "pageToken": { - // "description": "The standard list page token.", - // "location": "query", - // "type": "string" // } // }, - // "path": "v1beta/{+name}/operations", + // "path": "v1beta/{+name}", // "response": { - // "$ref": "GoogleLongrunningListOperationsResponse" + // "$ref": "GoogleLongrunningOperation" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -10202,98 +18910,100 @@ func (c *ProjectsLocationsCollectionsDataStoresBranchesOperationsListCall) Do(op } -// 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 *ProjectsLocationsCollectionsDataStoresBranchesOperationsListCall) Pages(ctx context.Context, f func(*GoogleLongrunningListOperationsResponse) error) error { - c.ctx_ = ctx - defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point - 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) - } -} - -// method id "discoveryengine.projects.locations.collections.dataStores.conversations.converse": +// method id "discoveryengine.projects.locations.collections.dataStores.siteSearchEngine.targetSites.operations.list": -type ProjectsLocationsCollectionsDataStoresConversationsConverseCall struct { - s *Service - name string - googleclouddiscoveryenginev1betaconverseconversationrequest *GoogleCloudDiscoveryengineV1betaConverseConversationRequest - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +type ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesOperationsListCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header } -// Converse: Converses a conversation. +// List: Lists operations that match the specified filter in the +// request. If the server doesn't support this method, it returns +// `UNIMPLEMENTED`. // -// - name: The resource name of the Conversation to get. Format: -// `projects/{project_number}/locations/{location_id}/collections/{coll -// ection}/dataStores/{data_store_id}/conversations/{conversation_id}`. -// Use -// `projects/{project_number}/locations/{location_id}/collections/{coll -// ection}/dataStores/{data_store_id}/conversations/-` to activate -// auto session mode, which automatically creates a new conversation -// inside a ConverseConversation session. -func (r *ProjectsLocationsCollectionsDataStoresConversationsService) Converse(name string, googleclouddiscoveryenginev1betaconverseconversationrequest *GoogleCloudDiscoveryengineV1betaConverseConversationRequest) *ProjectsLocationsCollectionsDataStoresConversationsConverseCall { - c := &ProjectsLocationsCollectionsDataStoresConversationsConverseCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// - name: The name of the operation's parent resource. +func (r *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesOperationsService) List(name string) *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesOperationsListCall { + c := &ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesOperationsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.name = name - c.googleclouddiscoveryenginev1betaconverseconversationrequest = googleclouddiscoveryenginev1betaconverseconversationrequest + return c +} + +// Filter sets the optional parameter "filter": The standard list +// filter. +func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesOperationsListCall) Filter(filter string) *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesOperationsListCall { + c.urlParams_.Set("filter", filter) + return c +} + +// PageSize sets the optional parameter "pageSize": The standard list +// page size. +func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesOperationsListCall) PageSize(pageSize int64) *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesOperationsListCall { + c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) + return c +} + +// PageToken sets the optional parameter "pageToken": The standard list +// page token. +func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesOperationsListCall) PageToken(pageToken string) *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesOperationsListCall { + 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 information. -func (c *ProjectsLocationsCollectionsDataStoresConversationsConverseCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresConversationsConverseCall { +func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesOperationsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesOperationsListCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } +// IfNoneMatch sets the 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. Use googleapi.IsNotModified to check whether the response +// error from Do is the result of In-None-Match. +func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesOperationsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesOperationsListCall { + c.ifNoneMatch_ = entityTag + return c +} + // Context sets the context to be used in this call's Do method. Any // pending HTTP request will be aborted if the provided context is // canceled. -func (c *ProjectsLocationsCollectionsDataStoresConversationsConverseCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresConversationsConverseCall { +func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesOperationsListCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesOperationsListCall { c.ctx_ = ctx return c } // Header returns an http.Header that can be modified by the caller to // add HTTP headers to the request. -func (c *ProjectsLocationsCollectionsDataStoresConversationsConverseCall) Header() http.Header { +func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesOperationsListCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsCollectionsDataStoresConversationsConverseCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesOperationsListCall) doRequest(alt string) (*http.Response, error) { reqHeaders := make(http.Header) reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) for k, v := range c.header_ { reqHeaders[k] = v } reqHeaders.Set("User-Agent", c.s.userAgent()) - var body io.Reader = nil - body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddiscoveryenginev1betaconverseconversationrequest) - if err != nil { - return nil, err + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) } - reqHeaders.Set("Content-Type", "application/json") + var body io.Reader = nil c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}:converse") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}/operations") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("POST", urls, body) + req, err := http.NewRequest("GET", urls, body) if err != nil { return nil, err } @@ -10302,19 +19012,17 @@ func (c *ProjectsLocationsCollectionsDataStoresConversationsConverseCall) doRequ "name": c.name, }) return gensupport.SendRequest(c.ctx_, c.s.client, req) -} - -// Do executes the "discoveryengine.projects.locations.collections.dataStores.conversations.converse" call. -// Exactly one of -// *GoogleCloudDiscoveryengineV1betaConverseConversationResponse or -// error will be non-nil. Any non-2xx status code is an error. Response -// headers are in either -// *GoogleCloudDiscoveryengineV1betaConverseConversationResponse.ServerRe -// sponse.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 *ProjectsLocationsCollectionsDataStoresConversationsConverseCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1betaConverseConversationResponse, error) { +} + +// Do executes the "discoveryengine.projects.locations.collections.dataStores.siteSearchEngine.targetSites.operations.list" call. +// Exactly one of *GoogleLongrunningListOperationsResponse or error will +// be non-nil. Any non-2xx status code is an error. Response headers are +// in either +// *GoogleLongrunningListOperationsResponse.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 *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesOperationsListCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningListOperationsResponse, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -10333,7 +19041,7 @@ func (c *ProjectsLocationsCollectionsDataStoresConversationsConverseCall) Do(opt if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &GoogleCloudDiscoveryengineV1betaConverseConversationResponse{ + ret := &GoogleLongrunningListOperationsResponse{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -10345,28 +19053,41 @@ func (c *ProjectsLocationsCollectionsDataStoresConversationsConverseCall) Do(opt } return ret, nil // { - // "description": "Converses a conversation.", - // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/conversations/{conversationsId}:converse", - // "httpMethod": "POST", - // "id": "discoveryengine.projects.locations.collections.dataStores.conversations.converse", + // "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/siteSearchEngine/targetSites/operations", + // "httpMethod": "GET", + // "id": "discoveryengine.projects.locations.collections.dataStores.siteSearchEngine.targetSites.operations.list", // "parameterOrder": [ // "name" // ], // "parameters": { + // "filter": { + // "description": "The standard list filter.", + // "location": "query", + // "type": "string" + // }, // "name": { - // "description": "Required. The resource name of the Conversation to get. Format: `projects/{project_number}/locations/{location_id}/collections/{collection}/dataStores/{data_store_id}/conversations/{conversation_id}`. Use `projects/{project_number}/locations/{location_id}/collections/{collection}/dataStores/{data_store_id}/conversations/-` to activate auto session mode, which automatically creates a new conversation inside a ConverseConversation session.", + // "description": "The name of the operation's parent resource.", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/conversations/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/siteSearchEngine/targetSites$", // "required": true, // "type": "string" + // }, + // "pageSize": { + // "description": "The standard list page size.", + // "format": "int32", + // "location": "query", + // "type": "integer" + // }, + // "pageToken": { + // "description": "The standard list page token.", + // "location": "query", + // "type": "string" // } // }, - // "path": "v1beta/{+name}:converse", - // "request": { - // "$ref": "GoogleCloudDiscoveryengineV1betaConverseConversationRequest" - // }, + // "path": "v1beta/{+name}/operations", // "response": { - // "$ref": "GoogleCloudDiscoveryengineV1betaConverseConversationResponse" + // "$ref": "GoogleLongrunningListOperationsResponse" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -10375,34 +19096,54 @@ func (c *ProjectsLocationsCollectionsDataStoresConversationsConverseCall) Do(opt } -// method id "discoveryengine.projects.locations.collections.dataStores.conversations.create": +// 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 *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesOperationsListCall) Pages(ctx context.Context, f func(*GoogleLongrunningListOperationsResponse) error) error { + c.ctx_ = ctx + defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point + 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 ProjectsLocationsCollectionsDataStoresConversationsCreateCall struct { - s *Service - parent string - googleclouddiscoveryenginev1betaconversation *GoogleCloudDiscoveryengineV1betaConversation - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +// method id "discoveryengine.projects.locations.collections.dataStores.suggestionDenyListEntries.import": + +type ProjectsLocationsCollectionsDataStoresSuggestionDenyListEntriesImportCall struct { + s *Service + parent string + googleclouddiscoveryenginev1betaimportsuggestiondenylistentriesrequest *GoogleCloudDiscoveryengineV1betaImportSuggestionDenyListEntriesRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// Create: Creates a Conversation. If the Conversation to create already -// exists, an ALREADY_EXISTS error is returned. +// Import: Imports all SuggestionDenyListEntry for a DataStore. // -// - parent: Full resource name of parent data store. Format: -// `projects/{project_number}/locations/{location_id}/collections/{coll -// ection}/dataStores/{data_store_id}`. -func (r *ProjectsLocationsCollectionsDataStoresConversationsService) Create(parent string, googleclouddiscoveryenginev1betaconversation *GoogleCloudDiscoveryengineV1betaConversation) *ProjectsLocationsCollectionsDataStoresConversationsCreateCall { - c := &ProjectsLocationsCollectionsDataStoresConversationsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// - parent: The parent data store resource name for which to import +// denylist entries. Follows pattern +// projects/*/locations/*/collections/*/dataStores/*. +func (r *ProjectsLocationsCollectionsDataStoresSuggestionDenyListEntriesService) Import(parent string, googleclouddiscoveryenginev1betaimportsuggestiondenylistentriesrequest *GoogleCloudDiscoveryengineV1betaImportSuggestionDenyListEntriesRequest) *ProjectsLocationsCollectionsDataStoresSuggestionDenyListEntriesImportCall { + c := &ProjectsLocationsCollectionsDataStoresSuggestionDenyListEntriesImportCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.parent = parent - c.googleclouddiscoveryenginev1betaconversation = googleclouddiscoveryenginev1betaconversation + c.googleclouddiscoveryenginev1betaimportsuggestiondenylistentriesrequest = googleclouddiscoveryenginev1betaimportsuggestiondenylistentriesrequest return c } // Fields allows partial responses to be retrieved. See // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse // for more information. -func (c *ProjectsLocationsCollectionsDataStoresConversationsCreateCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresConversationsCreateCall { +func (c *ProjectsLocationsCollectionsDataStoresSuggestionDenyListEntriesImportCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresSuggestionDenyListEntriesImportCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } @@ -10410,21 +19151,21 @@ func (c *ProjectsLocationsCollectionsDataStoresConversationsCreateCall) Fields(s // Context sets the context to be used in this call's Do method. Any // pending HTTP request will be aborted if the provided context is // canceled. -func (c *ProjectsLocationsCollectionsDataStoresConversationsCreateCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresConversationsCreateCall { +func (c *ProjectsLocationsCollectionsDataStoresSuggestionDenyListEntriesImportCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresSuggestionDenyListEntriesImportCall { c.ctx_ = ctx return c } // Header returns an http.Header that can be modified by the caller to // add HTTP headers to the request. -func (c *ProjectsLocationsCollectionsDataStoresConversationsCreateCall) Header() http.Header { +func (c *ProjectsLocationsCollectionsDataStoresSuggestionDenyListEntriesImportCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsCollectionsDataStoresConversationsCreateCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsCollectionsDataStoresSuggestionDenyListEntriesImportCall) doRequest(alt string) (*http.Response, error) { reqHeaders := make(http.Header) reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) for k, v := range c.header_ { @@ -10432,14 +19173,14 @@ func (c *ProjectsLocationsCollectionsDataStoresConversationsCreateCall) doReques } reqHeaders.Set("User-Agent", c.s.userAgent()) var body io.Reader = nil - body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddiscoveryenginev1betaconversation) + body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddiscoveryenginev1betaimportsuggestiondenylistentriesrequest) if err != nil { return nil, err } reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+parent}/conversations") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+parent}/suggestionDenyListEntries:import") urls += "?" + c.urlParams_.Encode() req, err := http.NewRequest("POST", urls, body) if err != nil { @@ -10452,16 +19193,14 @@ func (c *ProjectsLocationsCollectionsDataStoresConversationsCreateCall) doReques return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "discoveryengine.projects.locations.collections.dataStores.conversations.create" call. -// Exactly one of *GoogleCloudDiscoveryengineV1betaConversation or error -// will be non-nil. Any non-2xx status code is an error. Response -// headers are in either -// *GoogleCloudDiscoveryengineV1betaConversation.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 *ProjectsLocationsCollectionsDataStoresConversationsCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1betaConversation, error) { +// Do executes the "discoveryengine.projects.locations.collections.dataStores.suggestionDenyListEntries.import" call. +// Exactly one of *GoogleLongrunningOperation or error will be non-nil. +// 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 *ProjectsLocationsCollectionsDataStoresSuggestionDenyListEntriesImportCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -10480,7 +19219,7 @@ func (c *ProjectsLocationsCollectionsDataStoresConversationsCreateCall) Do(opts if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &GoogleCloudDiscoveryengineV1betaConversation{ + ret := &GoogleLongrunningOperation{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -10492,28 +19231,28 @@ func (c *ProjectsLocationsCollectionsDataStoresConversationsCreateCall) Do(opts } return ret, nil // { - // "description": "Creates a Conversation. If the Conversation to create already exists, an ALREADY_EXISTS error is returned.", - // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/conversations", + // "description": "Imports all SuggestionDenyListEntry for a DataStore.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/suggestionDenyListEntries:import", // "httpMethod": "POST", - // "id": "discoveryengine.projects.locations.collections.dataStores.conversations.create", + // "id": "discoveryengine.projects.locations.collections.dataStores.suggestionDenyListEntries.import", // "parameterOrder": [ // "parent" // ], // "parameters": { // "parent": { - // "description": "Required. Full resource name of parent data store. Format: `projects/{project_number}/locations/{location_id}/collections/{collection}/dataStores/{data_store_id}`", + // "description": "Required. The parent data store resource name for which to import denylist entries. Follows pattern projects/*/locations/*/collections/*/dataStores/*.", // "location": "path", // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+$", // "required": true, // "type": "string" // } // }, - // "path": "v1beta/{+parent}/conversations", + // "path": "v1beta/{+parent}/suggestionDenyListEntries:import", // "request": { - // "$ref": "GoogleCloudDiscoveryengineV1betaConversation" + // "$ref": "GoogleCloudDiscoveryengineV1betaImportSuggestionDenyListEntriesRequest" // }, // "response": { - // "$ref": "GoogleCloudDiscoveryengineV1betaConversation" + // "$ref": "GoogleLongrunningOperation" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -10522,32 +19261,34 @@ func (c *ProjectsLocationsCollectionsDataStoresConversationsCreateCall) Do(opts } -// method id "discoveryengine.projects.locations.collections.dataStores.conversations.delete": +// method id "discoveryengine.projects.locations.collections.dataStores.suggestionDenyListEntries.purge": -type ProjectsLocationsCollectionsDataStoresConversationsDeleteCall struct { - s *Service - name string - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +type ProjectsLocationsCollectionsDataStoresSuggestionDenyListEntriesPurgeCall struct { + s *Service + parent string + googleclouddiscoveryenginev1betapurgesuggestiondenylistentriesrequest *GoogleCloudDiscoveryengineV1betaPurgeSuggestionDenyListEntriesRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// Delete: Deletes a Conversation. If the Conversation to delete does -// not exist, a NOT_FOUND error is returned. +// Purge: Permanently deletes all SuggestionDenyListEntry for a +// DataStore. // -// - name: The resource name of the Conversation to delete. Format: -// `projects/{project_number}/locations/{location_id}/collections/{coll -// ection}/dataStores/{data_store_id}/conversations/{conversation_id}`. -func (r *ProjectsLocationsCollectionsDataStoresConversationsService) Delete(name string) *ProjectsLocationsCollectionsDataStoresConversationsDeleteCall { - c := &ProjectsLocationsCollectionsDataStoresConversationsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.name = name +// - parent: The parent data store resource name for which to import +// denylist entries. Follows pattern +// projects/*/locations/*/collections/*/dataStores/*. +func (r *ProjectsLocationsCollectionsDataStoresSuggestionDenyListEntriesService) Purge(parent string, googleclouddiscoveryenginev1betapurgesuggestiondenylistentriesrequest *GoogleCloudDiscoveryengineV1betaPurgeSuggestionDenyListEntriesRequest) *ProjectsLocationsCollectionsDataStoresSuggestionDenyListEntriesPurgeCall { + c := &ProjectsLocationsCollectionsDataStoresSuggestionDenyListEntriesPurgeCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + c.googleclouddiscoveryenginev1betapurgesuggestiondenylistentriesrequest = googleclouddiscoveryenginev1betapurgesuggestiondenylistentriesrequest return c } // Fields allows partial responses to be retrieved. See // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse // for more information. -func (c *ProjectsLocationsCollectionsDataStoresConversationsDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresConversationsDeleteCall { +func (c *ProjectsLocationsCollectionsDataStoresSuggestionDenyListEntriesPurgeCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresSuggestionDenyListEntriesPurgeCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } @@ -10555,21 +19296,21 @@ func (c *ProjectsLocationsCollectionsDataStoresConversationsDeleteCall) Fields(s // Context sets the context to be used in this call's Do method. Any // pending HTTP request will be aborted if the provided context is // canceled. -func (c *ProjectsLocationsCollectionsDataStoresConversationsDeleteCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresConversationsDeleteCall { +func (c *ProjectsLocationsCollectionsDataStoresSuggestionDenyListEntriesPurgeCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresSuggestionDenyListEntriesPurgeCall { c.ctx_ = ctx return c } // Header returns an http.Header that can be modified by the caller to // add HTTP headers to the request. -func (c *ProjectsLocationsCollectionsDataStoresConversationsDeleteCall) Header() http.Header { +func (c *ProjectsLocationsCollectionsDataStoresSuggestionDenyListEntriesPurgeCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsCollectionsDataStoresConversationsDeleteCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsCollectionsDataStoresSuggestionDenyListEntriesPurgeCall) doRequest(alt string) (*http.Response, error) { reqHeaders := make(http.Header) reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) for k, v := range c.header_ { @@ -10577,29 +19318,34 @@ func (c *ProjectsLocationsCollectionsDataStoresConversationsDeleteCall) doReques } reqHeaders.Set("User-Agent", c.s.userAgent()) var body io.Reader = nil + body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddiscoveryenginev1betapurgesuggestiondenylistentriesrequest) + if err != nil { + return nil, err + } + reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+parent}/suggestionDenyListEntries:purge") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("DELETE", urls, body) + req, err := http.NewRequest("POST", urls, body) if err != nil { return nil, err } req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ - "name": c.name, + "parent": c.parent, }) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "discoveryengine.projects.locations.collections.dataStores.conversations.delete" call. -// Exactly one of *GoogleProtobufEmpty or error will be non-nil. Any -// non-2xx status code is an error. Response headers are in either -// *GoogleProtobufEmpty.ServerResponse.Header or (if a response was -// returned at all) in error.(*googleapi.Error).Header. Use +// Do executes the "discoveryengine.projects.locations.collections.dataStores.suggestionDenyListEntries.purge" call. +// Exactly one of *GoogleLongrunningOperation or error will be non-nil. +// 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 *ProjectsLocationsCollectionsDataStoresConversationsDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, error) { +func (c *ProjectsLocationsCollectionsDataStoresSuggestionDenyListEntriesPurgeCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -10618,7 +19364,7 @@ func (c *ProjectsLocationsCollectionsDataStoresConversationsDeleteCall) Do(opts if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &GoogleProtobufEmpty{ + ret := &GoogleLongrunningOperation{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -10630,25 +19376,28 @@ func (c *ProjectsLocationsCollectionsDataStoresConversationsDeleteCall) Do(opts } return ret, nil // { - // "description": "Deletes a Conversation. If the Conversation to delete does not exist, a NOT_FOUND error is returned.", - // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/conversations/{conversationsId}", - // "httpMethod": "DELETE", - // "id": "discoveryengine.projects.locations.collections.dataStores.conversations.delete", + // "description": "Permanently deletes all SuggestionDenyListEntry for a DataStore.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/suggestionDenyListEntries:purge", + // "httpMethod": "POST", + // "id": "discoveryengine.projects.locations.collections.dataStores.suggestionDenyListEntries.purge", // "parameterOrder": [ - // "name" + // "parent" // ], // "parameters": { - // "name": { - // "description": "Required. The resource name of the Conversation to delete. Format: `projects/{project_number}/locations/{location_id}/collections/{collection}/dataStores/{data_store_id}/conversations/{conversation_id}`", + // "parent": { + // "description": "Required. The parent data store resource name for which to import denylist entries. Follows pattern projects/*/locations/*/collections/*/dataStores/*.", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/conversations/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+$", // "required": true, // "type": "string" // } // }, - // "path": "v1beta/{+name}", + // "path": "v1beta/{+parent}/suggestionDenyListEntries:purge", + // "request": { + // "$ref": "GoogleCloudDiscoveryengineV1betaPurgeSuggestionDenyListEntriesRequest" + // }, // "response": { - // "$ref": "GoogleProtobufEmpty" + // "$ref": "GoogleLongrunningOperation" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -10657,32 +19406,60 @@ func (c *ProjectsLocationsCollectionsDataStoresConversationsDeleteCall) Do(opts } -// method id "discoveryengine.projects.locations.collections.dataStores.conversations.get": +// method id "discoveryengine.projects.locations.collections.dataStores.userEvents.collect": + +type ProjectsLocationsCollectionsDataStoresUserEventsCollectCall struct { + s *Service + parent string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// Collect: Writes a single user event from the browser. This uses a GET +// request to due to browser restriction of POST-ing to a third-party +// domain. This method is used only by the Discovery Engine API +// JavaScript pixel and Google Tag Manager. Users should not call this +// method directly. +// +// - parent: The parent DataStore resource name, such as +// `projects/{project}/locations/{location}/collections/{collection}/da +// taStores/{data_store}`. +func (r *ProjectsLocationsCollectionsDataStoresUserEventsService) Collect(parent string) *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall { + c := &ProjectsLocationsCollectionsDataStoresUserEventsCollectCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + return c +} + +// Ets sets the optional parameter "ets": The event timestamp in +// milliseconds. This prevents browser caching of otherwise identical +// get requests. The name is abbreviated to reduce the payload bytes. +func (c *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall) Ets(ets int64) *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall { + c.urlParams_.Set("ets", fmt.Sprint(ets)) + return c +} -type ProjectsLocationsCollectionsDataStoresConversationsGetCall struct { - s *Service - name string - urlParams_ gensupport.URLParams - ifNoneMatch_ string - ctx_ context.Context - header_ http.Header +// Uri sets the optional parameter "uri": The URL including +// cgi-parameters but excluding the hash fragment with a length limit of +// 5,000 characters. This is often more useful than the referer URL, +// because many browsers only send the domain for third-party requests. +func (c *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall) Uri(uri string) *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall { + c.urlParams_.Set("uri", uri) + return c } -// Get: Gets a Conversation. -// -// - name: The resource name of the Conversation to get. Format: -// `projects/{project_number}/locations/{location_id}/collections/{coll -// ection}/dataStores/{data_store_id}/conversations/{conversation_id}`. -func (r *ProjectsLocationsCollectionsDataStoresConversationsService) Get(name string) *ProjectsLocationsCollectionsDataStoresConversationsGetCall { - c := &ProjectsLocationsCollectionsDataStoresConversationsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.name = name +// UserEvent sets the optional parameter "userEvent": Required. URL +// encoded UserEvent proto with a length limit of 2,000,000 characters. +func (c *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall) UserEvent(userEvent string) *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall { + c.urlParams_.Set("userEvent", userEvent) return c } // Fields allows partial responses to be retrieved. See // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse // for more information. -func (c *ProjectsLocationsCollectionsDataStoresConversationsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresConversationsGetCall { +func (c *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } @@ -10692,7 +19469,7 @@ func (c *ProjectsLocationsCollectionsDataStoresConversationsGetCall) Fields(s .. // getting updates only after the object has changed since the last // request. Use googleapi.IsNotModified to check whether the response // error from Do is the result of In-None-Match. -func (c *ProjectsLocationsCollectionsDataStoresConversationsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsCollectionsDataStoresConversationsGetCall { +func (c *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall) IfNoneMatch(entityTag string) *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall { c.ifNoneMatch_ = entityTag return c } @@ -10700,21 +19477,21 @@ func (c *ProjectsLocationsCollectionsDataStoresConversationsGetCall) IfNoneMatch // Context sets the context to be used in this call's Do method. Any // pending HTTP request will be aborted if the provided context is // canceled. -func (c *ProjectsLocationsCollectionsDataStoresConversationsGetCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresConversationsGetCall { +func (c *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall { c.ctx_ = ctx return c } // Header returns an http.Header that can be modified by the caller to // add HTTP headers to the request. -func (c *ProjectsLocationsCollectionsDataStoresConversationsGetCall) Header() http.Header { +func (c *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsCollectionsDataStoresConversationsGetCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall) doRequest(alt string) (*http.Response, error) { reqHeaders := make(http.Header) reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) for k, v := range c.header_ { @@ -10727,7 +19504,7 @@ func (c *ProjectsLocationsCollectionsDataStoresConversationsGetCall) doRequest(a var body io.Reader = nil c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+parent}/userEvents:collect") urls += "?" + c.urlParams_.Encode() req, err := http.NewRequest("GET", urls, body) if err != nil { @@ -10735,21 +19512,19 @@ func (c *ProjectsLocationsCollectionsDataStoresConversationsGetCall) doRequest(a } req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ - "name": c.name, + "parent": c.parent, }) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "discoveryengine.projects.locations.collections.dataStores.conversations.get" call. -// Exactly one of *GoogleCloudDiscoveryengineV1betaConversation or error -// will be non-nil. Any non-2xx status code is an error. Response -// headers are in either -// *GoogleCloudDiscoveryengineV1betaConversation.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 *ProjectsLocationsCollectionsDataStoresConversationsGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1betaConversation, error) { +// Do executes the "discoveryengine.projects.locations.collections.dataStores.userEvents.collect" call. +// Exactly one of *GoogleApiHttpBody or error will be non-nil. Any +// non-2xx status code is an error. Response headers are in either +// *GoogleApiHttpBody.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 *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall) Do(opts ...googleapi.CallOption) (*GoogleApiHttpBody, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -10768,7 +19543,7 @@ func (c *ProjectsLocationsCollectionsDataStoresConversationsGetCall) Do(opts ... if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &GoogleCloudDiscoveryengineV1betaConversation{ + ret := &GoogleApiHttpBody{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -10780,25 +19555,41 @@ func (c *ProjectsLocationsCollectionsDataStoresConversationsGetCall) Do(opts ... } return ret, nil // { - // "description": "Gets a Conversation.", - // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/conversations/{conversationsId}", + // "description": "Writes a single user event from the browser. This uses a GET request to due to browser restriction of POST-ing to a third-party domain. This method is used only by the Discovery Engine API JavaScript pixel and Google Tag Manager. Users should not call this method directly.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/userEvents:collect", // "httpMethod": "GET", - // "id": "discoveryengine.projects.locations.collections.dataStores.conversations.get", + // "id": "discoveryengine.projects.locations.collections.dataStores.userEvents.collect", // "parameterOrder": [ - // "name" + // "parent" // ], // "parameters": { - // "name": { - // "description": "Required. The resource name of the Conversation to get. Format: `projects/{project_number}/locations/{location_id}/collections/{collection}/dataStores/{data_store_id}/conversations/{conversation_id}`", + // "ets": { + // "description": "The event timestamp in milliseconds. This prevents browser caching of otherwise identical get requests. The name is abbreviated to reduce the payload bytes.", + // "format": "int64", + // "location": "query", + // "type": "string" + // }, + // "parent": { + // "description": "Required. The parent DataStore resource name, such as `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}`.", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/conversations/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+$", // "required": true, // "type": "string" + // }, + // "uri": { + // "description": "The URL including cgi-parameters but excluding the hash fragment with a length limit of 5,000 characters. This is often more useful than the referer URL, because many browsers only send the domain for third-party requests.", + // "location": "query", + // "type": "string" + // }, + // "userEvent": { + // "description": "Required. URL encoded UserEvent proto with a length limit of 2,000,000 characters.", + // "location": "query", + // "type": "string" // } // }, - // "path": "v1beta/{+name}", + // "path": "v1beta/{+parent}/userEvents:collect", // "response": { - // "$ref": "GoogleCloudDiscoveryengineV1betaConversation" + // "$ref": "GoogleApiHttpBody" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -10807,113 +19598,77 @@ func (c *ProjectsLocationsCollectionsDataStoresConversationsGetCall) Do(opts ... } -// method id "discoveryengine.projects.locations.collections.dataStores.conversations.list": +// method id "discoveryengine.projects.locations.collections.dataStores.userEvents.import": -type ProjectsLocationsCollectionsDataStoresConversationsListCall struct { - s *Service - parent string - urlParams_ gensupport.URLParams - ifNoneMatch_ string - ctx_ context.Context - header_ http.Header +type ProjectsLocationsCollectionsDataStoresUserEventsImportCall struct { + s *Service + parent string + googleclouddiscoveryenginev1betaimportusereventsrequest *GoogleCloudDiscoveryengineV1betaImportUserEventsRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// List: Lists all Conversations by their parent DataStore. +// Import: Bulk import of User events. Request processing might be +// synchronous. Events that already exist are skipped. Use this method +// for backfilling historical user events. Operation.response is of type +// ImportResponse. Note that it is possible for a subset of the items to +// be successfully inserted. Operation.metadata is of type +// ImportMetadata. // -// - parent: The data store resource name. Format: -// `projects/{project_number}/locations/{location_id}/collections/{coll -// ection}/dataStores/{data_store_id}`. -func (r *ProjectsLocationsCollectionsDataStoresConversationsService) List(parent string) *ProjectsLocationsCollectionsDataStoresConversationsListCall { - c := &ProjectsLocationsCollectionsDataStoresConversationsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// - parent: Parent DataStore resource name, of the form +// `projects/{project}/locations/{location}/collections/{collection}/da +// taStores/{data_store}`. +func (r *ProjectsLocationsCollectionsDataStoresUserEventsService) Import(parent string, googleclouddiscoveryenginev1betaimportusereventsrequest *GoogleCloudDiscoveryengineV1betaImportUserEventsRequest) *ProjectsLocationsCollectionsDataStoresUserEventsImportCall { + c := &ProjectsLocationsCollectionsDataStoresUserEventsImportCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.parent = parent - return c -} - -// Filter sets the optional parameter "filter": A filter to apply on the -// list results. The supported features are: user_pseudo_id, state. -// Example: "user_pseudo_id = some_id" -func (c *ProjectsLocationsCollectionsDataStoresConversationsListCall) Filter(filter string) *ProjectsLocationsCollectionsDataStoresConversationsListCall { - c.urlParams_.Set("filter", filter) - 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: * `update_time` * -// `create_time` * `conversation_name` Example: "update_time desc" -// "create_time" -func (c *ProjectsLocationsCollectionsDataStoresConversationsListCall) OrderBy(orderBy string) *ProjectsLocationsCollectionsDataStoresConversationsListCall { - c.urlParams_.Set("orderBy", orderBy) - return c -} - -// PageSize sets the optional parameter "pageSize": Maximum number of -// results to return. If unspecified, defaults to 50. Max allowed value -// is 1000. -func (c *ProjectsLocationsCollectionsDataStoresConversationsListCall) PageSize(pageSize int64) *ProjectsLocationsCollectionsDataStoresConversationsListCall { - c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) - return c -} - -// PageToken sets the optional parameter "pageToken": A page token, -// received from a previous `ListConversations` call. Provide this to -// retrieve the subsequent page. -func (c *ProjectsLocationsCollectionsDataStoresConversationsListCall) PageToken(pageToken string) *ProjectsLocationsCollectionsDataStoresConversationsListCall { - c.urlParams_.Set("pageToken", pageToken) + c.googleclouddiscoveryenginev1betaimportusereventsrequest = googleclouddiscoveryenginev1betaimportusereventsrequest return c } // Fields allows partial responses to be retrieved. See // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse // for more information. -func (c *ProjectsLocationsCollectionsDataStoresConversationsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresConversationsListCall { +func (c *ProjectsLocationsCollectionsDataStoresUserEventsImportCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresUserEventsImportCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// IfNoneMatch sets the 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. Use googleapi.IsNotModified to check whether the response -// error from Do is the result of In-None-Match. -func (c *ProjectsLocationsCollectionsDataStoresConversationsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsCollectionsDataStoresConversationsListCall { - c.ifNoneMatch_ = entityTag - return c -} - // Context sets the context to be used in this call's Do method. Any // pending HTTP request will be aborted if the provided context is // canceled. -func (c *ProjectsLocationsCollectionsDataStoresConversationsListCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresConversationsListCall { +func (c *ProjectsLocationsCollectionsDataStoresUserEventsImportCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresUserEventsImportCall { c.ctx_ = ctx return c } // Header returns an http.Header that can be modified by the caller to // add HTTP headers to the request. -func (c *ProjectsLocationsCollectionsDataStoresConversationsListCall) Header() http.Header { +func (c *ProjectsLocationsCollectionsDataStoresUserEventsImportCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsCollectionsDataStoresConversationsListCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsCollectionsDataStoresUserEventsImportCall) doRequest(alt string) (*http.Response, error) { reqHeaders := make(http.Header) reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) for k, v := range c.header_ { reqHeaders[k] = v } reqHeaders.Set("User-Agent", c.s.userAgent()) - if c.ifNoneMatch_ != "" { - reqHeaders.Set("If-None-Match", c.ifNoneMatch_) - } var body io.Reader = nil + body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddiscoveryenginev1betaimportusereventsrequest) + if err != nil { + return nil, err + } + reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+parent}/conversations") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+parent}/userEvents:import") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("GET", urls, body) + req, err := http.NewRequest("POST", urls, body) if err != nil { return nil, err } @@ -10924,17 +19679,14 @@ func (c *ProjectsLocationsCollectionsDataStoresConversationsListCall) doRequest( return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "discoveryengine.projects.locations.collections.dataStores.conversations.list" call. -// Exactly one of -// *GoogleCloudDiscoveryengineV1betaListConversationsResponse or error -// will be non-nil. Any non-2xx status code is an error. Response -// headers are in either -// *GoogleCloudDiscoveryengineV1betaListConversationsResponse.ServerRespo -// nse.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 *ProjectsLocationsCollectionsDataStoresConversationsListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1betaListConversationsResponse, error) { +// Do executes the "discoveryengine.projects.locations.collections.dataStores.userEvents.import" call. +// Exactly one of *GoogleLongrunningOperation or error will be non-nil. +// 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 *ProjectsLocationsCollectionsDataStoresUserEventsImportCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -10953,7 +19705,7 @@ func (c *ProjectsLocationsCollectionsDataStoresConversationsListCall) Do(opts .. if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &GoogleCloudDiscoveryengineV1betaListConversationsResponse{ + ret := &GoogleLongrunningOperation{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -10965,46 +19717,28 @@ func (c *ProjectsLocationsCollectionsDataStoresConversationsListCall) Do(opts .. } return ret, nil // { - // "description": "Lists all Conversations by their parent DataStore.", - // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/conversations", - // "httpMethod": "GET", - // "id": "discoveryengine.projects.locations.collections.dataStores.conversations.list", + // "description": "Bulk import of User events. Request processing might be synchronous. Events that already exist are skipped. Use this method for backfilling historical user events. Operation.response is of type ImportResponse. Note that it is possible for a subset of the items to be successfully inserted. Operation.metadata is of type ImportMetadata.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/userEvents:import", + // "httpMethod": "POST", + // "id": "discoveryengine.projects.locations.collections.dataStores.userEvents.import", // "parameterOrder": [ // "parent" // ], // "parameters": { - // "filter": { - // "description": "A filter to apply on the list results. The supported features are: user_pseudo_id, state. Example: \"user_pseudo_id = some_id\"", - // "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: * `update_time` * `create_time` * `conversation_name` Example: \"update_time desc\" \"create_time\"", - // "location": "query", - // "type": "string" - // }, - // "pageSize": { - // "description": "Maximum number of results to return. If unspecified, defaults to 50. Max allowed value is 1000.", - // "format": "int32", - // "location": "query", - // "type": "integer" - // }, - // "pageToken": { - // "description": "A page token, received from a previous `ListConversations` call. Provide this to retrieve the subsequent page.", - // "location": "query", - // "type": "string" - // }, // "parent": { - // "description": "Required. The data store resource name. Format: `projects/{project_number}/locations/{location_id}/collections/{collection}/dataStores/{data_store_id}`", + // "description": "Required. Parent DataStore resource name, of the form `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}`", // "location": "path", // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+$", // "required": true, // "type": "string" // } // }, - // "path": "v1beta/{+parent}/conversations", + // "path": "v1beta/{+parent}/userEvents:import", + // "request": { + // "$ref": "GoogleCloudDiscoveryengineV1betaImportUserEventsRequest" + // }, // "response": { - // "$ref": "GoogleCloudDiscoveryengineV1betaListConversationsResponse" + // "$ref": "GoogleLongrunningOperation" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -11013,67 +19747,33 @@ func (c *ProjectsLocationsCollectionsDataStoresConversationsListCall) Do(opts .. } -// 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 *ProjectsLocationsCollectionsDataStoresConversationsListCall) Pages(ctx context.Context, f func(*GoogleCloudDiscoveryengineV1betaListConversationsResponse) error) error { - c.ctx_ = ctx - defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point - 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) - } -} - -// method id "discoveryengine.projects.locations.collections.dataStores.conversations.patch": +// method id "discoveryengine.projects.locations.collections.dataStores.userEvents.write": -type ProjectsLocationsCollectionsDataStoresConversationsPatchCall struct { - s *Service - name string - googleclouddiscoveryenginev1betaconversation *GoogleCloudDiscoveryengineV1betaConversation - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +type ProjectsLocationsCollectionsDataStoresUserEventsWriteCall struct { + s *Service + parent string + googleclouddiscoveryenginev1betauserevent *GoogleCloudDiscoveryengineV1betaUserEvent + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// Patch: Updates a Conversation. Conversation action type cannot be -// changed. If the Conversation to update does not exist, a NOT_FOUND -// error is returned. +// Write: Writes a single user event. // -// - name: Immutable. Fully qualified name -// `project/*/locations/global/collections/{collection}/dataStore/*/con -// versations/*` or -// `project/*/locations/global/collections/{collection}/engines/*/conve -// rsations/*`. -func (r *ProjectsLocationsCollectionsDataStoresConversationsService) Patch(name string, googleclouddiscoveryenginev1betaconversation *GoogleCloudDiscoveryengineV1betaConversation) *ProjectsLocationsCollectionsDataStoresConversationsPatchCall { - c := &ProjectsLocationsCollectionsDataStoresConversationsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.name = name - c.googleclouddiscoveryenginev1betaconversation = googleclouddiscoveryenginev1betaconversation - return c -} - -// UpdateMask sets the optional parameter "updateMask": Indicates which -// fields in the provided Conversation to update. The following are NOT -// supported: * Conversation.name If not set or empty, all supported -// fields are updated. -func (c *ProjectsLocationsCollectionsDataStoresConversationsPatchCall) UpdateMask(updateMask string) *ProjectsLocationsCollectionsDataStoresConversationsPatchCall { - c.urlParams_.Set("updateMask", updateMask) +// - parent: The parent DataStore resource name, such as +// `projects/{project}/locations/{location}/collections/{collection}/da +// taStores/{data_store}`. +func (r *ProjectsLocationsCollectionsDataStoresUserEventsService) Write(parent string, googleclouddiscoveryenginev1betauserevent *GoogleCloudDiscoveryengineV1betaUserEvent) *ProjectsLocationsCollectionsDataStoresUserEventsWriteCall { + c := &ProjectsLocationsCollectionsDataStoresUserEventsWriteCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + c.googleclouddiscoveryenginev1betauserevent = googleclouddiscoveryenginev1betauserevent return c } // Fields allows partial responses to be retrieved. See // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse // for more information. -func (c *ProjectsLocationsCollectionsDataStoresConversationsPatchCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresConversationsPatchCall { +func (c *ProjectsLocationsCollectionsDataStoresUserEventsWriteCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresUserEventsWriteCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } @@ -11081,21 +19781,21 @@ func (c *ProjectsLocationsCollectionsDataStoresConversationsPatchCall) Fields(s // Context sets the context to be used in this call's Do method. Any // pending HTTP request will be aborted if the provided context is // canceled. -func (c *ProjectsLocationsCollectionsDataStoresConversationsPatchCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresConversationsPatchCall { +func (c *ProjectsLocationsCollectionsDataStoresUserEventsWriteCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresUserEventsWriteCall { c.ctx_ = ctx return c } // Header returns an http.Header that can be modified by the caller to // add HTTP headers to the request. -func (c *ProjectsLocationsCollectionsDataStoresConversationsPatchCall) Header() http.Header { +func (c *ProjectsLocationsCollectionsDataStoresUserEventsWriteCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsCollectionsDataStoresConversationsPatchCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsCollectionsDataStoresUserEventsWriteCall) doRequest(alt string) (*http.Response, error) { reqHeaders := make(http.Header) reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) for k, v := range c.header_ { @@ -11103,36 +19803,36 @@ func (c *ProjectsLocationsCollectionsDataStoresConversationsPatchCall) doRequest } reqHeaders.Set("User-Agent", c.s.userAgent()) var body io.Reader = nil - body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddiscoveryenginev1betaconversation) + body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddiscoveryenginev1betauserevent) if err != nil { return nil, err } reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+parent}/userEvents:write") 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{ - "name": c.name, + "parent": c.parent, }) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "discoveryengine.projects.locations.collections.dataStores.conversations.patch" call. -// Exactly one of *GoogleCloudDiscoveryengineV1betaConversation or error +// Do executes the "discoveryengine.projects.locations.collections.dataStores.userEvents.write" call. +// Exactly one of *GoogleCloudDiscoveryengineV1betaUserEvent or error // will be non-nil. Any non-2xx status code is an error. Response // headers are in either -// *GoogleCloudDiscoveryengineV1betaConversation.ServerResponse.Header -// or (if a response was returned at all) in +// *GoogleCloudDiscoveryengineV1betaUserEvent.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 *ProjectsLocationsCollectionsDataStoresConversationsPatchCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1betaConversation, error) { +func (c *ProjectsLocationsCollectionsDataStoresUserEventsWriteCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1betaUserEvent, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -11151,7 +19851,7 @@ func (c *ProjectsLocationsCollectionsDataStoresConversationsPatchCall) Do(opts . if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &GoogleCloudDiscoveryengineV1betaConversation{ + ret := &GoogleCloudDiscoveryengineV1betaUserEvent{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -11163,34 +19863,28 @@ func (c *ProjectsLocationsCollectionsDataStoresConversationsPatchCall) Do(opts . } return ret, nil // { - // "description": "Updates a Conversation. Conversation action type cannot be changed. If the Conversation to update does not exist, a NOT_FOUND error is returned.", - // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/conversations/{conversationsId}", - // "httpMethod": "PATCH", - // "id": "discoveryengine.projects.locations.collections.dataStores.conversations.patch", + // "description": "Writes a single user event.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/userEvents:write", + // "httpMethod": "POST", + // "id": "discoveryengine.projects.locations.collections.dataStores.userEvents.write", // "parameterOrder": [ - // "name" + // "parent" // ], // "parameters": { - // "name": { - // "description": "Immutable. Fully qualified name `project/*/locations/global/collections/{collection}/dataStore/*/conversations/*` or `project/*/locations/global/collections/{collection}/engines/*/conversations/*`.", + // "parent": { + // "description": "Required. The parent DataStore resource name, such as `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}`.", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/conversations/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+$", // "required": true, // "type": "string" - // }, - // "updateMask": { - // "description": "Indicates which fields in the provided Conversation to update. The following are NOT supported: * Conversation.name If not set or empty, all supported fields are updated.", - // "format": "google-fieldmask", - // "location": "query", - // "type": "string" // } // }, - // "path": "v1beta/{+name}", + // "path": "v1beta/{+parent}/userEvents:write", // "request": { - // "$ref": "GoogleCloudDiscoveryengineV1betaConversation" + // "$ref": "GoogleCloudDiscoveryengineV1betaUserEvent" // }, // "response": { - // "$ref": "GoogleCloudDiscoveryengineV1betaConversation" + // "$ref": "GoogleCloudDiscoveryengineV1betaUserEvent" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -11199,97 +19893,99 @@ func (c *ProjectsLocationsCollectionsDataStoresConversationsPatchCall) Do(opts . } -// method id "discoveryengine.projects.locations.collections.dataStores.models.operations.get": +// method id "discoveryengine.projects.locations.collections.engines.create": -type ProjectsLocationsCollectionsDataStoresModelsOperationsGetCall struct { - s *Service - name string - urlParams_ gensupport.URLParams - ifNoneMatch_ string - ctx_ context.Context - header_ http.Header +type ProjectsLocationsCollectionsEnginesCreateCall struct { + s *Service + parent string + googleclouddiscoveryenginev1betaengine *GoogleCloudDiscoveryengineV1betaEngine + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// Get: Gets the latest state of a long-running operation. Clients can -// use this method to poll the operation result at intervals as -// recommended by the API service. +// Create: Creates a Engine. // -// - name: The name of the operation resource. -func (r *ProjectsLocationsCollectionsDataStoresModelsOperationsService) Get(name string) *ProjectsLocationsCollectionsDataStoresModelsOperationsGetCall { - c := &ProjectsLocationsCollectionsDataStoresModelsOperationsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.name = name +// - parent: The parent resource name, such as +// `projects/{project}/locations/{location}/collections/{collection}`. +func (r *ProjectsLocationsCollectionsEnginesService) Create(parent string, googleclouddiscoveryenginev1betaengine *GoogleCloudDiscoveryengineV1betaEngine) *ProjectsLocationsCollectionsEnginesCreateCall { + c := &ProjectsLocationsCollectionsEnginesCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + c.googleclouddiscoveryenginev1betaengine = googleclouddiscoveryenginev1betaengine + return c +} + +// EngineId sets the optional parameter "engineId": Required. The ID to +// use for the Engine, which will become the final component of the +// Engine's resource name. This field must conform to RFC-1034 +// (https://tools.ietf.org/html/rfc1034) standard with a length limit of +// 63 characters. Otherwise, an INVALID_ARGUMENT error is returned. +func (c *ProjectsLocationsCollectionsEnginesCreateCall) EngineId(engineId string) *ProjectsLocationsCollectionsEnginesCreateCall { + c.urlParams_.Set("engineId", engineId) return c } // Fields allows partial responses to be retrieved. See // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse // for more information. -func (c *ProjectsLocationsCollectionsDataStoresModelsOperationsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresModelsOperationsGetCall { +func (c *ProjectsLocationsCollectionsEnginesCreateCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsEnginesCreateCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// IfNoneMatch sets the 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. Use googleapi.IsNotModified to check whether the response -// error from Do is the result of In-None-Match. -func (c *ProjectsLocationsCollectionsDataStoresModelsOperationsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsCollectionsDataStoresModelsOperationsGetCall { - c.ifNoneMatch_ = entityTag - return c -} - // Context sets the context to be used in this call's Do method. Any // pending HTTP request will be aborted if the provided context is // canceled. -func (c *ProjectsLocationsCollectionsDataStoresModelsOperationsGetCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresModelsOperationsGetCall { +func (c *ProjectsLocationsCollectionsEnginesCreateCall) Context(ctx context.Context) *ProjectsLocationsCollectionsEnginesCreateCall { c.ctx_ = ctx return c } // Header returns an http.Header that can be modified by the caller to // add HTTP headers to the request. -func (c *ProjectsLocationsCollectionsDataStoresModelsOperationsGetCall) Header() http.Header { +func (c *ProjectsLocationsCollectionsEnginesCreateCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsCollectionsDataStoresModelsOperationsGetCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsCollectionsEnginesCreateCall) doRequest(alt string) (*http.Response, error) { reqHeaders := make(http.Header) reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) for k, v := range c.header_ { reqHeaders[k] = v } reqHeaders.Set("User-Agent", c.s.userAgent()) - if c.ifNoneMatch_ != "" { - reqHeaders.Set("If-None-Match", c.ifNoneMatch_) - } var body io.Reader = nil + body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddiscoveryenginev1betaengine) + if err != nil { + return nil, err + } + reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+parent}/engines") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("GET", urls, body) + req, err := http.NewRequest("POST", urls, body) if err != nil { return nil, err } req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ - "name": c.name, + "parent": c.parent, }) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "discoveryengine.projects.locations.collections.dataStores.models.operations.get" call. +// Do executes the "discoveryengine.projects.locations.collections.engines.create" call. // Exactly one of *GoogleLongrunningOperation or error will be non-nil. // 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 *ProjectsLocationsCollectionsDataStoresModelsOperationsGetCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { +func (c *ProjectsLocationsCollectionsEnginesCreateCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -11320,23 +20016,31 @@ func (c *ProjectsLocationsCollectionsDataStoresModelsOperationsGetCall) Do(opts } return ret, nil // { - // "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": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/models/{modelsId}/operations/{operationsId}", - // "httpMethod": "GET", - // "id": "discoveryengine.projects.locations.collections.dataStores.models.operations.get", + // "description": "Creates a Engine.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/engines", + // "httpMethod": "POST", + // "id": "discoveryengine.projects.locations.collections.engines.create", // "parameterOrder": [ - // "name" + // "parent" // ], // "parameters": { - // "name": { - // "description": "The name of the operation resource.", + // "engineId": { + // "description": "Required. The ID to use for the Engine, which will become the final component of the Engine's resource name. This field must conform to [RFC-1034](https://tools.ietf.org/html/rfc1034) standard with a length limit of 63 characters. Otherwise, an INVALID_ARGUMENT error is returned.", + // "location": "query", + // "type": "string" + // }, + // "parent": { + // "description": "Required. The parent resource name, such as `projects/{project}/locations/{location}/collections/{collection}`.", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/models/[^/]+/operations/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+$", // "required": true, // "type": "string" // } // }, - // "path": "v1beta/{+name}", + // "path": "v1beta/{+parent}/engines", + // "request": { + // "$ref": "GoogleCloudDiscoveryengineV1betaEngine" + // }, // "response": { // "$ref": "GoogleLongrunningOperation" // }, @@ -11347,100 +20051,68 @@ func (c *ProjectsLocationsCollectionsDataStoresModelsOperationsGetCall) Do(opts } -// method id "discoveryengine.projects.locations.collections.dataStores.models.operations.list": +// method id "discoveryengine.projects.locations.collections.engines.delete": -type ProjectsLocationsCollectionsDataStoresModelsOperationsListCall struct { - s *Service - name string - urlParams_ gensupport.URLParams - ifNoneMatch_ string - ctx_ context.Context - header_ http.Header +type ProjectsLocationsCollectionsEnginesDeleteCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + 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`. +// Delete: Deletes a Engine. // -// - name: The name of the operation's parent resource. -func (r *ProjectsLocationsCollectionsDataStoresModelsOperationsService) List(name string) *ProjectsLocationsCollectionsDataStoresModelsOperationsListCall { - c := &ProjectsLocationsCollectionsDataStoresModelsOperationsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// - name: Full resource name of Engine, such as +// `projects/{project}/locations/{location}/collections/{collection_id} +// /engines/{engine_id}`. If the caller does not have permission to +// delete the Engine, regardless of whether or not it exists, a +// PERMISSION_DENIED error is returned. If the Engine to delete does +// not exist, a NOT_FOUND error is returned. +func (r *ProjectsLocationsCollectionsEnginesService) Delete(name string) *ProjectsLocationsCollectionsEnginesDeleteCall { + c := &ProjectsLocationsCollectionsEnginesDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.name = name return c } -// Filter sets the optional parameter "filter": The standard list -// filter. -func (c *ProjectsLocationsCollectionsDataStoresModelsOperationsListCall) Filter(filter string) *ProjectsLocationsCollectionsDataStoresModelsOperationsListCall { - c.urlParams_.Set("filter", filter) - return c -} - -// PageSize sets the optional parameter "pageSize": The standard list -// page size. -func (c *ProjectsLocationsCollectionsDataStoresModelsOperationsListCall) PageSize(pageSize int64) *ProjectsLocationsCollectionsDataStoresModelsOperationsListCall { - c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) - return c -} - -// PageToken sets the optional parameter "pageToken": The standard list -// page token. -func (c *ProjectsLocationsCollectionsDataStoresModelsOperationsListCall) PageToken(pageToken string) *ProjectsLocationsCollectionsDataStoresModelsOperationsListCall { - 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 information. -func (c *ProjectsLocationsCollectionsDataStoresModelsOperationsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresModelsOperationsListCall { - c.urlParams_.Set("fields", googleapi.CombineFields(s)) - return c -} - -// IfNoneMatch sets the 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. Use googleapi.IsNotModified to check whether the response -// error from Do is the result of In-None-Match. -func (c *ProjectsLocationsCollectionsDataStoresModelsOperationsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsCollectionsDataStoresModelsOperationsListCall { - c.ifNoneMatch_ = entityTag +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse +// for more information. +func (c *ProjectsLocationsCollectionsEnginesDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsEnginesDeleteCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } // Context sets the context to be used in this call's Do method. Any // pending HTTP request will be aborted if the provided context is // canceled. -func (c *ProjectsLocationsCollectionsDataStoresModelsOperationsListCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresModelsOperationsListCall { +func (c *ProjectsLocationsCollectionsEnginesDeleteCall) Context(ctx context.Context) *ProjectsLocationsCollectionsEnginesDeleteCall { c.ctx_ = ctx return c } // Header returns an http.Header that can be modified by the caller to // add HTTP headers to the request. -func (c *ProjectsLocationsCollectionsDataStoresModelsOperationsListCall) Header() http.Header { +func (c *ProjectsLocationsCollectionsEnginesDeleteCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsCollectionsDataStoresModelsOperationsListCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsCollectionsEnginesDeleteCall) doRequest(alt string) (*http.Response, error) { reqHeaders := make(http.Header) reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) for k, v := range c.header_ { reqHeaders[k] = v } reqHeaders.Set("User-Agent", c.s.userAgent()) - if c.ifNoneMatch_ != "" { - reqHeaders.Set("If-None-Match", c.ifNoneMatch_) - } var body io.Reader = nil c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}/operations") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("GET", urls, body) + req, err := http.NewRequest("DELETE", urls, body) if err != nil { return nil, err } @@ -11451,15 +20123,14 @@ func (c *ProjectsLocationsCollectionsDataStoresModelsOperationsListCall) doReque return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "discoveryengine.projects.locations.collections.dataStores.models.operations.list" call. -// Exactly one of *GoogleLongrunningListOperationsResponse or error will -// be non-nil. Any non-2xx status code is an error. Response headers are -// in either -// *GoogleLongrunningListOperationsResponse.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 +// Do executes the "discoveryengine.projects.locations.collections.engines.delete" call. +// Exactly one of *GoogleLongrunningOperation or error will be non-nil. +// 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 *ProjectsLocationsCollectionsDataStoresModelsOperationsListCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningListOperationsResponse, error) { +func (c *ProjectsLocationsCollectionsEnginesDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -11478,7 +20149,7 @@ func (c *ProjectsLocationsCollectionsDataStoresModelsOperationsListCall) Do(opts if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &GoogleLongrunningListOperationsResponse{ + ret := &GoogleLongrunningOperation{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -11490,41 +20161,25 @@ func (c *ProjectsLocationsCollectionsDataStoresModelsOperationsListCall) Do(opts } return ret, nil // { - // "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`.", - // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/models/{modelsId}/operations", - // "httpMethod": "GET", - // "id": "discoveryengine.projects.locations.collections.dataStores.models.operations.list", + // "description": "Deletes a Engine.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/engines/{enginesId}", + // "httpMethod": "DELETE", + // "id": "discoveryengine.projects.locations.collections.engines.delete", // "parameterOrder": [ // "name" // ], // "parameters": { - // "filter": { - // "description": "The standard list filter.", - // "location": "query", - // "type": "string" - // }, // "name": { - // "description": "The name of the operation's parent resource.", + // "description": "Required. Full resource name of Engine, such as `projects/{project}/locations/{location}/collections/{collection_id}/engines/{engine_id}`. If the caller does not have permission to delete the Engine, regardless of whether or not it exists, a PERMISSION_DENIED error is returned. If the Engine to delete does not exist, a NOT_FOUND error is returned.", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/models/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/engines/[^/]+$", // "required": true, // "type": "string" - // }, - // "pageSize": { - // "description": "The standard list page size.", - // "format": "int32", - // "location": "query", - // "type": "integer" - // }, - // "pageToken": { - // "description": "The standard list page token.", - // "location": "query", - // "type": "string" // } // }, - // "path": "v1beta/{+name}/operations", + // "path": "v1beta/{+name}", // "response": { - // "$ref": "GoogleLongrunningListOperationsResponse" + // "$ref": "GoogleLongrunningOperation" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -11533,30 +20188,9 @@ func (c *ProjectsLocationsCollectionsDataStoresModelsOperationsListCall) Do(opts } -// 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 *ProjectsLocationsCollectionsDataStoresModelsOperationsListCall) Pages(ctx context.Context, f func(*GoogleLongrunningListOperationsResponse) error) error { - c.ctx_ = ctx - defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point - 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) - } -} - -// method id "discoveryengine.projects.locations.collections.dataStores.operations.get": +// method id "discoveryengine.projects.locations.collections.engines.get": -type ProjectsLocationsCollectionsDataStoresOperationsGetCall struct { +type ProjectsLocationsCollectionsEnginesGetCall struct { s *Service name string urlParams_ gensupport.URLParams @@ -11565,13 +20199,13 @@ type ProjectsLocationsCollectionsDataStoresOperationsGetCall struct { header_ http.Header } -// Get: Gets the latest state of a long-running operation. Clients can -// use this method to poll the operation result at intervals as -// recommended by the API service. +// Get: Gets a Engine. // -// - name: The name of the operation resource. -func (r *ProjectsLocationsCollectionsDataStoresOperationsService) Get(name string) *ProjectsLocationsCollectionsDataStoresOperationsGetCall { - c := &ProjectsLocationsCollectionsDataStoresOperationsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// - name: Full resource name of Engine, such as +// `projects/{project}/locations/{location}/collections/{collection_id} +// /engines/{engine_id}`. +func (r *ProjectsLocationsCollectionsEnginesService) Get(name string) *ProjectsLocationsCollectionsEnginesGetCall { + c := &ProjectsLocationsCollectionsEnginesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.name = name return c } @@ -11579,7 +20213,7 @@ func (r *ProjectsLocationsCollectionsDataStoresOperationsService) Get(name strin // Fields allows partial responses to be retrieved. See // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse // for more information. -func (c *ProjectsLocationsCollectionsDataStoresOperationsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresOperationsGetCall { +func (c *ProjectsLocationsCollectionsEnginesGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsEnginesGetCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } @@ -11589,7 +20223,7 @@ func (c *ProjectsLocationsCollectionsDataStoresOperationsGetCall) Fields(s ...go // getting updates only after the object has changed since the last // request. Use googleapi.IsNotModified to check whether the response // error from Do is the result of In-None-Match. -func (c *ProjectsLocationsCollectionsDataStoresOperationsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsCollectionsDataStoresOperationsGetCall { +func (c *ProjectsLocationsCollectionsEnginesGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsCollectionsEnginesGetCall { c.ifNoneMatch_ = entityTag return c } @@ -11597,21 +20231,21 @@ func (c *ProjectsLocationsCollectionsDataStoresOperationsGetCall) IfNoneMatch(en // Context sets the context to be used in this call's Do method. Any // pending HTTP request will be aborted if the provided context is // canceled. -func (c *ProjectsLocationsCollectionsDataStoresOperationsGetCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresOperationsGetCall { +func (c *ProjectsLocationsCollectionsEnginesGetCall) Context(ctx context.Context) *ProjectsLocationsCollectionsEnginesGetCall { c.ctx_ = ctx return c } // Header returns an http.Header that can be modified by the caller to // add HTTP headers to the request. -func (c *ProjectsLocationsCollectionsDataStoresOperationsGetCall) Header() http.Header { +func (c *ProjectsLocationsCollectionsEnginesGetCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsCollectionsDataStoresOperationsGetCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsCollectionsEnginesGetCall) doRequest(alt string) (*http.Response, error) { reqHeaders := make(http.Header) reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) for k, v := range c.header_ { @@ -11637,14 +20271,15 @@ func (c *ProjectsLocationsCollectionsDataStoresOperationsGetCall) doRequest(alt return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "discoveryengine.projects.locations.collections.dataStores.operations.get" call. -// Exactly one of *GoogleLongrunningOperation or error will be non-nil. -// 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 +// Do executes the "discoveryengine.projects.locations.collections.engines.get" call. +// Exactly one of *GoogleCloudDiscoveryengineV1betaEngine or error will +// be non-nil. Any non-2xx status code is an error. Response headers are +// in either +// *GoogleCloudDiscoveryengineV1betaEngine.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 *ProjectsLocationsCollectionsDataStoresOperationsGetCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { +func (c *ProjectsLocationsCollectionsEnginesGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1betaEngine, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -11663,7 +20298,7 @@ func (c *ProjectsLocationsCollectionsDataStoresOperationsGetCall) Do(opts ...goo if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &GoogleLongrunningOperation{ + ret := &GoogleCloudDiscoveryengineV1betaEngine{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -11675,25 +20310,25 @@ func (c *ProjectsLocationsCollectionsDataStoresOperationsGetCall) Do(opts ...goo } return ret, nil // { - // "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": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/operations/{operationsId}", + // "description": "Gets a Engine.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/engines/{enginesId}", // "httpMethod": "GET", - // "id": "discoveryengine.projects.locations.collections.dataStores.operations.get", + // "id": "discoveryengine.projects.locations.collections.engines.get", // "parameterOrder": [ // "name" // ], // "parameters": { // "name": { - // "description": "The name of the operation resource.", + // "description": "Required. Full resource name of Engine, such as `projects/{project}/locations/{location}/collections/{collection_id}/engines/{engine_id}`.", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/operations/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/engines/[^/]+$", // "required": true, // "type": "string" // } // }, // "path": "v1beta/{+name}", // "response": { - // "$ref": "GoogleLongrunningOperation" + // "$ref": "GoogleCloudDiscoveryengineV1betaEngine" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -11702,45 +20337,43 @@ func (c *ProjectsLocationsCollectionsDataStoresOperationsGetCall) Do(opts ...goo } -// method id "discoveryengine.projects.locations.collections.dataStores.operations.list": +// method id "discoveryengine.projects.locations.collections.engines.list": -type ProjectsLocationsCollectionsDataStoresOperationsListCall struct { +type ProjectsLocationsCollectionsEnginesListCall struct { s *Service - name string + parent string urlParams_ gensupport.URLParams ifNoneMatch_ string ctx_ context.Context header_ http.Header } -// List: Lists operations that match the specified filter in the -// request. If the server doesn't support this method, it returns -// `UNIMPLEMENTED`. +// List: Lists all the Engines associated with the project. // -// - name: The name of the operation's parent resource. -func (r *ProjectsLocationsCollectionsDataStoresOperationsService) List(name string) *ProjectsLocationsCollectionsDataStoresOperationsListCall { - c := &ProjectsLocationsCollectionsDataStoresOperationsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.name = name +// - parent: The parent resource name, such as +// `projects/{project}/locations/{location}/collections/{collection_id} +// `. +func (r *ProjectsLocationsCollectionsEnginesService) List(parent string) *ProjectsLocationsCollectionsEnginesListCall { + c := &ProjectsLocationsCollectionsEnginesListCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent return c } -// Filter sets the optional parameter "filter": The standard list -// filter. -func (c *ProjectsLocationsCollectionsDataStoresOperationsListCall) Filter(filter string) *ProjectsLocationsCollectionsDataStoresOperationsListCall { +// Filter sets the optional parameter "filter": Filter by solution type. +// For example: solution_type=SOLUTION_TYPE_SEARCH +func (c *ProjectsLocationsCollectionsEnginesListCall) Filter(filter string) *ProjectsLocationsCollectionsEnginesListCall { c.urlParams_.Set("filter", filter) return c } -// PageSize sets the optional parameter "pageSize": The standard list -// page size. -func (c *ProjectsLocationsCollectionsDataStoresOperationsListCall) PageSize(pageSize int64) *ProjectsLocationsCollectionsDataStoresOperationsListCall { +// PageSize sets the optional parameter "pageSize": Not supported. +func (c *ProjectsLocationsCollectionsEnginesListCall) PageSize(pageSize int64) *ProjectsLocationsCollectionsEnginesListCall { c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) return c } -// PageToken sets the optional parameter "pageToken": The standard list -// page token. -func (c *ProjectsLocationsCollectionsDataStoresOperationsListCall) PageToken(pageToken string) *ProjectsLocationsCollectionsDataStoresOperationsListCall { +// PageToken sets the optional parameter "pageToken": Not supported. +func (c *ProjectsLocationsCollectionsEnginesListCall) PageToken(pageToken string) *ProjectsLocationsCollectionsEnginesListCall { c.urlParams_.Set("pageToken", pageToken) return c } @@ -11748,7 +20381,7 @@ func (c *ProjectsLocationsCollectionsDataStoresOperationsListCall) PageToken(pag // Fields allows partial responses to be retrieved. See // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse // for more information. -func (c *ProjectsLocationsCollectionsDataStoresOperationsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresOperationsListCall { +func (c *ProjectsLocationsCollectionsEnginesListCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsEnginesListCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } @@ -11758,7 +20391,7 @@ func (c *ProjectsLocationsCollectionsDataStoresOperationsListCall) Fields(s ...g // getting updates only after the object has changed since the last // request. Use googleapi.IsNotModified to check whether the response // error from Do is the result of In-None-Match. -func (c *ProjectsLocationsCollectionsDataStoresOperationsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsCollectionsDataStoresOperationsListCall { +func (c *ProjectsLocationsCollectionsEnginesListCall) IfNoneMatch(entityTag string) *ProjectsLocationsCollectionsEnginesListCall { c.ifNoneMatch_ = entityTag return c } @@ -11766,21 +20399,21 @@ func (c *ProjectsLocationsCollectionsDataStoresOperationsListCall) IfNoneMatch(e // Context sets the context to be used in this call's Do method. Any // pending HTTP request will be aborted if the provided context is // canceled. -func (c *ProjectsLocationsCollectionsDataStoresOperationsListCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresOperationsListCall { +func (c *ProjectsLocationsCollectionsEnginesListCall) Context(ctx context.Context) *ProjectsLocationsCollectionsEnginesListCall { c.ctx_ = ctx return c } // Header returns an http.Header that can be modified by the caller to // add HTTP headers to the request. -func (c *ProjectsLocationsCollectionsDataStoresOperationsListCall) Header() http.Header { +func (c *ProjectsLocationsCollectionsEnginesListCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsCollectionsDataStoresOperationsListCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsCollectionsEnginesListCall) doRequest(alt string) (*http.Response, error) { reqHeaders := make(http.Header) reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) for k, v := range c.header_ { @@ -11793,7 +20426,7 @@ func (c *ProjectsLocationsCollectionsDataStoresOperationsListCall) doRequest(alt var body io.Reader = nil c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}/operations") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+parent}/engines") urls += "?" + c.urlParams_.Encode() req, err := http.NewRequest("GET", urls, body) if err != nil { @@ -11801,20 +20434,21 @@ func (c *ProjectsLocationsCollectionsDataStoresOperationsListCall) doRequest(alt } req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ - "name": c.name, + "parent": c.parent, }) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "discoveryengine.projects.locations.collections.dataStores.operations.list" call. -// Exactly one of *GoogleLongrunningListOperationsResponse or error will -// be non-nil. Any non-2xx status code is an error. Response headers are -// in either -// *GoogleLongrunningListOperationsResponse.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 *ProjectsLocationsCollectionsDataStoresOperationsListCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningListOperationsResponse, error) { +// Do executes the "discoveryengine.projects.locations.collections.engines.list" call. +// Exactly one of *GoogleCloudDiscoveryengineV1betaListEnginesResponse +// or error will be non-nil. Any non-2xx status code is an error. +// Response headers are in either +// *GoogleCloudDiscoveryengineV1betaListEnginesResponse.ServerResponse.He +// ader 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 *ProjectsLocationsCollectionsEnginesListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1betaListEnginesResponse, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -11833,7 +20467,7 @@ func (c *ProjectsLocationsCollectionsDataStoresOperationsListCall) Do(opts ...go if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &GoogleLongrunningListOperationsResponse{ + ret := &GoogleCloudDiscoveryengineV1betaListEnginesResponse{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -11845,41 +20479,41 @@ func (c *ProjectsLocationsCollectionsDataStoresOperationsListCall) Do(opts ...go } return ret, nil // { - // "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`.", - // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/operations", + // "description": "Lists all the Engines associated with the project.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/engines", // "httpMethod": "GET", - // "id": "discoveryengine.projects.locations.collections.dataStores.operations.list", + // "id": "discoveryengine.projects.locations.collections.engines.list", // "parameterOrder": [ - // "name" + // "parent" // ], // "parameters": { // "filter": { - // "description": "The standard list filter.", + // "description": "Optional. Filter by solution type. For example: solution_type=SOLUTION_TYPE_SEARCH", // "location": "query", // "type": "string" // }, - // "name": { - // "description": "The name of the operation's parent resource.", - // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+$", - // "required": true, - // "type": "string" - // }, // "pageSize": { - // "description": "The standard list page size.", + // "description": "Optional. Not supported.", // "format": "int32", // "location": "query", // "type": "integer" // }, // "pageToken": { - // "description": "The standard list page token.", + // "description": "Optional. Not supported.", // "location": "query", // "type": "string" + // }, + // "parent": { + // "description": "Required. The parent resource name, such as `projects/{project}/locations/{location}/collections/{collection_id}`.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+$", + // "required": true, + // "type": "string" // } // }, - // "path": "v1beta/{+name}/operations", + // "path": "v1beta/{+parent}/engines", // "response": { - // "$ref": "GoogleLongrunningListOperationsResponse" + // "$ref": "GoogleCloudDiscoveryengineV1betaListEnginesResponse" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -11891,7 +20525,7 @@ func (c *ProjectsLocationsCollectionsDataStoresOperationsListCall) Do(opts ...go // 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 *ProjectsLocationsCollectionsDataStoresOperationsListCall) Pages(ctx context.Context, f func(*GoogleLongrunningListOperationsResponse) error) error { +func (c *ProjectsLocationsCollectionsEnginesListCall) Pages(ctx context.Context, f func(*GoogleCloudDiscoveryengineV1betaListEnginesResponse) error) error { c.ctx_ = ctx defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point for { @@ -11909,43 +20543,45 @@ func (c *ProjectsLocationsCollectionsDataStoresOperationsListCall) Pages(ctx con } } -// method id "discoveryengine.projects.locations.collections.dataStores.schemas.create": +// method id "discoveryengine.projects.locations.collections.engines.patch": -type ProjectsLocationsCollectionsDataStoresSchemasCreateCall struct { +type ProjectsLocationsCollectionsEnginesPatchCall struct { s *Service - parent string - googleclouddiscoveryenginev1betaschema *GoogleCloudDiscoveryengineV1betaSchema + name string + googleclouddiscoveryenginev1betaengine *GoogleCloudDiscoveryengineV1betaEngine urlParams_ gensupport.URLParams ctx_ context.Context header_ http.Header } -// Create: Creates a Schema. +// Patch: Updates an Engine // -// - parent: The parent data store resource name, in the format of -// `projects/{project}/locations/{location}/collections/{collection}/da -// taStores/{data_store}`. -func (r *ProjectsLocationsCollectionsDataStoresSchemasService) Create(parent string, googleclouddiscoveryenginev1betaschema *GoogleCloudDiscoveryengineV1betaSchema) *ProjectsLocationsCollectionsDataStoresSchemasCreateCall { - c := &ProjectsLocationsCollectionsDataStoresSchemasCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.parent = parent - c.googleclouddiscoveryenginev1betaschema = googleclouddiscoveryenginev1betaschema +// - name: Immutable. The fully qualified resource name of the engine. +// This field must be a UTF-8 encoded string with a length limit of +// 1024 characters. Format: +// `projects/{project_number}/locations/{location}/collections/{collect +// ion}/engines/{engine}` engine should be 1-63 characters, and valid +// characters are /a-z0-9*/. Otherwise, an INVALID_ARGUMENT error is +// returned. +func (r *ProjectsLocationsCollectionsEnginesService) Patch(name string, googleclouddiscoveryenginev1betaengine *GoogleCloudDiscoveryengineV1betaEngine) *ProjectsLocationsCollectionsEnginesPatchCall { + c := &ProjectsLocationsCollectionsEnginesPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + c.googleclouddiscoveryenginev1betaengine = googleclouddiscoveryenginev1betaengine return c } -// SchemaId sets the optional parameter "schemaId": Required. The ID to -// use for the Schema, which will become the final component of the -// Schema.name. This field should conform to RFC-1034 -// (https://tools.ietf.org/html/rfc1034) standard with a length limit of -// 63 characters. -func (c *ProjectsLocationsCollectionsDataStoresSchemasCreateCall) SchemaId(schemaId string) *ProjectsLocationsCollectionsDataStoresSchemasCreateCall { - c.urlParams_.Set("schemaId", schemaId) +// UpdateMask sets the optional parameter "updateMask": Indicates which +// fields in the provided Engine to update. If an unsupported or unknown +// field is provided, an INVALID_ARGUMENT error is returned. +func (c *ProjectsLocationsCollectionsEnginesPatchCall) UpdateMask(updateMask string) *ProjectsLocationsCollectionsEnginesPatchCall { + 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 information. -func (c *ProjectsLocationsCollectionsDataStoresSchemasCreateCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresSchemasCreateCall { +func (c *ProjectsLocationsCollectionsEnginesPatchCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsEnginesPatchCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } @@ -11953,21 +20589,21 @@ func (c *ProjectsLocationsCollectionsDataStoresSchemasCreateCall) Fields(s ...go // Context sets the context to be used in this call's Do method. Any // pending HTTP request will be aborted if the provided context is // canceled. -func (c *ProjectsLocationsCollectionsDataStoresSchemasCreateCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresSchemasCreateCall { +func (c *ProjectsLocationsCollectionsEnginesPatchCall) Context(ctx context.Context) *ProjectsLocationsCollectionsEnginesPatchCall { c.ctx_ = ctx return c } // Header returns an http.Header that can be modified by the caller to // add HTTP headers to the request. -func (c *ProjectsLocationsCollectionsDataStoresSchemasCreateCall) Header() http.Header { +func (c *ProjectsLocationsCollectionsEnginesPatchCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsCollectionsDataStoresSchemasCreateCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsCollectionsEnginesPatchCall) doRequest(alt string) (*http.Response, error) { reqHeaders := make(http.Header) reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) for k, v := range c.header_ { @@ -11975,34 +20611,35 @@ func (c *ProjectsLocationsCollectionsDataStoresSchemasCreateCall) doRequest(alt } reqHeaders.Set("User-Agent", c.s.userAgent()) var body io.Reader = nil - body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddiscoveryenginev1betaschema) + body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddiscoveryenginev1betaengine) if err != nil { return nil, err } reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+parent}/schemas") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}") 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{ - "parent": c.parent, + "name": c.name, }) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "discoveryengine.projects.locations.collections.dataStores.schemas.create" call. -// Exactly one of *GoogleLongrunningOperation or error will be non-nil. -// 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 +// Do executes the "discoveryengine.projects.locations.collections.engines.patch" call. +// Exactly one of *GoogleCloudDiscoveryengineV1betaEngine or error will +// be non-nil. Any non-2xx status code is an error. Response headers are +// in either +// *GoogleCloudDiscoveryengineV1betaEngine.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 *ProjectsLocationsCollectionsDataStoresSchemasCreateCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { +func (c *ProjectsLocationsCollectionsEnginesPatchCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1betaEngine, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -12021,7 +20658,7 @@ func (c *ProjectsLocationsCollectionsDataStoresSchemasCreateCall) Do(opts ...goo if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &GoogleLongrunningOperation{ + ret := &GoogleCloudDiscoveryengineV1betaEngine{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -12033,33 +20670,34 @@ func (c *ProjectsLocationsCollectionsDataStoresSchemasCreateCall) Do(opts ...goo } return ret, nil // { - // "description": "Creates a Schema.", - // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/schemas", - // "httpMethod": "POST", - // "id": "discoveryengine.projects.locations.collections.dataStores.schemas.create", + // "description": "Updates an Engine", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/engines/{enginesId}", + // "httpMethod": "PATCH", + // "id": "discoveryengine.projects.locations.collections.engines.patch", // "parameterOrder": [ - // "parent" + // "name" // ], // "parameters": { - // "parent": { - // "description": "Required. The parent data store resource name, in the format of `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}`.", + // "name": { + // "description": "Immutable. The fully qualified resource name of the engine. This field must be a UTF-8 encoded string with a length limit of 1024 characters. Format: `projects/{project_number}/locations/{location}/collections/{collection}/engines/{engine}` engine should be 1-63 characters, and valid characters are /a-z0-9*/. Otherwise, an INVALID_ARGUMENT error is returned.", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/engines/[^/]+$", // "required": true, // "type": "string" // }, - // "schemaId": { - // "description": "Required. The ID to use for the Schema, which will become the final component of the Schema.name. This field should conform to [RFC-1034](https://tools.ietf.org/html/rfc1034) standard with a length limit of 63 characters.", + // "updateMask": { + // "description": "Indicates which fields in the provided Engine to update. If an unsupported or unknown field is provided, an INVALID_ARGUMENT error is returned.", + // "format": "google-fieldmask", // "location": "query", // "type": "string" // } // }, - // "path": "v1beta/{+parent}/schemas", + // "path": "v1beta/{+name}", // "request": { - // "$ref": "GoogleCloudDiscoveryengineV1betaSchema" + // "$ref": "GoogleCloudDiscoveryengineV1betaEngine" // }, // "response": { - // "$ref": "GoogleLongrunningOperation" + // "$ref": "GoogleCloudDiscoveryengineV1betaEngine" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -12067,32 +20705,39 @@ func (c *ProjectsLocationsCollectionsDataStoresSchemasCreateCall) Do(opts ...goo // } } - -// method id "discoveryengine.projects.locations.collections.dataStores.schemas.delete": - -type ProjectsLocationsCollectionsDataStoresSchemasDeleteCall struct { - s *Service - name string - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header + +// method id "discoveryengine.projects.locations.collections.engines.conversations.converse": + +type ProjectsLocationsCollectionsEnginesConversationsConverseCall struct { + s *Service + name string + googleclouddiscoveryenginev1betaconverseconversationrequest *GoogleCloudDiscoveryengineV1betaConverseConversationRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// Delete: Deletes a Schema. +// Converse: Converses a conversation. // -// - name: The full resource name of the schema, in the format of -// `projects/{project}/locations/{location}/collections/{collection}/da -// taStores/{data_store}/schemas/{schema}`. -func (r *ProjectsLocationsCollectionsDataStoresSchemasService) Delete(name string) *ProjectsLocationsCollectionsDataStoresSchemasDeleteCall { - c := &ProjectsLocationsCollectionsDataStoresSchemasDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// - name: The resource name of the Conversation to get. Format: +// `projects/{project_number}/locations/{location_id}/collections/{coll +// ection}/dataStores/{data_store_id}/conversations/{conversation_id}`. +// Use +// `projects/{project_number}/locations/{location_id}/collections/{coll +// ection}/dataStores/{data_store_id}/conversations/-` to activate +// auto session mode, which automatically creates a new conversation +// inside a ConverseConversation session. +func (r *ProjectsLocationsCollectionsEnginesConversationsService) Converse(name string, googleclouddiscoveryenginev1betaconverseconversationrequest *GoogleCloudDiscoveryengineV1betaConverseConversationRequest) *ProjectsLocationsCollectionsEnginesConversationsConverseCall { + c := &ProjectsLocationsCollectionsEnginesConversationsConverseCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.name = name + c.googleclouddiscoveryenginev1betaconverseconversationrequest = googleclouddiscoveryenginev1betaconverseconversationrequest return c } // Fields allows partial responses to be retrieved. See // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse // for more information. -func (c *ProjectsLocationsCollectionsDataStoresSchemasDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresSchemasDeleteCall { +func (c *ProjectsLocationsCollectionsEnginesConversationsConverseCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsEnginesConversationsConverseCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } @@ -12100,21 +20745,21 @@ func (c *ProjectsLocationsCollectionsDataStoresSchemasDeleteCall) Fields(s ...go // Context sets the context to be used in this call's Do method. Any // pending HTTP request will be aborted if the provided context is // canceled. -func (c *ProjectsLocationsCollectionsDataStoresSchemasDeleteCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresSchemasDeleteCall { +func (c *ProjectsLocationsCollectionsEnginesConversationsConverseCall) Context(ctx context.Context) *ProjectsLocationsCollectionsEnginesConversationsConverseCall { c.ctx_ = ctx return c } // Header returns an http.Header that can be modified by the caller to // add HTTP headers to the request. -func (c *ProjectsLocationsCollectionsDataStoresSchemasDeleteCall) Header() http.Header { +func (c *ProjectsLocationsCollectionsEnginesConversationsConverseCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsCollectionsDataStoresSchemasDeleteCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsCollectionsEnginesConversationsConverseCall) doRequest(alt string) (*http.Response, error) { reqHeaders := make(http.Header) reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) for k, v := range c.header_ { @@ -12122,11 +20767,16 @@ func (c *ProjectsLocationsCollectionsDataStoresSchemasDeleteCall) doRequest(alt } reqHeaders.Set("User-Agent", c.s.userAgent()) var body io.Reader = nil + body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddiscoveryenginev1betaconverseconversationrequest) + if err != nil { + return nil, err + } + reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}:converse") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("DELETE", urls, body) + req, err := http.NewRequest("POST", urls, body) if err != nil { return nil, err } @@ -12137,14 +20787,17 @@ func (c *ProjectsLocationsCollectionsDataStoresSchemasDeleteCall) doRequest(alt return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "discoveryengine.projects.locations.collections.dataStores.schemas.delete" call. -// Exactly one of *GoogleLongrunningOperation or error will be non-nil. -// 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 *ProjectsLocationsCollectionsDataStoresSchemasDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { +// Do executes the "discoveryengine.projects.locations.collections.engines.conversations.converse" call. +// Exactly one of +// *GoogleCloudDiscoveryengineV1betaConverseConversationResponse or +// error will be non-nil. Any non-2xx status code is an error. Response +// headers are in either +// *GoogleCloudDiscoveryengineV1betaConverseConversationResponse.ServerRe +// sponse.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 *ProjectsLocationsCollectionsEnginesConversationsConverseCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1betaConverseConversationResponse, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -12163,7 +20816,7 @@ func (c *ProjectsLocationsCollectionsDataStoresSchemasDeleteCall) Do(opts ...goo if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &GoogleLongrunningOperation{ + ret := &GoogleCloudDiscoveryengineV1betaConverseConversationResponse{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -12175,25 +20828,28 @@ func (c *ProjectsLocationsCollectionsDataStoresSchemasDeleteCall) Do(opts ...goo } return ret, nil // { - // "description": "Deletes a Schema.", - // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/schemas/{schemasId}", - // "httpMethod": "DELETE", - // "id": "discoveryengine.projects.locations.collections.dataStores.schemas.delete", + // "description": "Converses a conversation.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/engines/{enginesId}/conversations/{conversationsId}:converse", + // "httpMethod": "POST", + // "id": "discoveryengine.projects.locations.collections.engines.conversations.converse", // "parameterOrder": [ // "name" // ], // "parameters": { // "name": { - // "description": "Required. The full resource name of the schema, in the format of `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/schemas/{schema}`.", + // "description": "Required. The resource name of the Conversation to get. Format: `projects/{project_number}/locations/{location_id}/collections/{collection}/dataStores/{data_store_id}/conversations/{conversation_id}`. Use `projects/{project_number}/locations/{location_id}/collections/{collection}/dataStores/{data_store_id}/conversations/-` to activate auto session mode, which automatically creates a new conversation inside a ConverseConversation session.", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/schemas/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/engines/[^/]+/conversations/[^/]+$", // "required": true, // "type": "string" // } // }, - // "path": "v1beta/{+name}", + // "path": "v1beta/{+name}:converse", + // "request": { + // "$ref": "GoogleCloudDiscoveryengineV1betaConverseConversationRequest" + // }, // "response": { - // "$ref": "GoogleLongrunningOperation" + // "$ref": "GoogleCloudDiscoveryengineV1betaConverseConversationResponse" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -12202,98 +20858,93 @@ func (c *ProjectsLocationsCollectionsDataStoresSchemasDeleteCall) Do(opts ...goo } -// method id "discoveryengine.projects.locations.collections.dataStores.schemas.get": +// method id "discoveryengine.projects.locations.collections.engines.conversations.create": -type ProjectsLocationsCollectionsDataStoresSchemasGetCall struct { - s *Service - name string - urlParams_ gensupport.URLParams - ifNoneMatch_ string - ctx_ context.Context - header_ http.Header +type ProjectsLocationsCollectionsEnginesConversationsCreateCall struct { + s *Service + parent string + googleclouddiscoveryenginev1betaconversation *GoogleCloudDiscoveryengineV1betaConversation + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// Get: Gets a Schema. +// Create: Creates a Conversation. If the Conversation to create already +// exists, an ALREADY_EXISTS error is returned. // -// - name: The full resource name of the schema, in the format of -// `projects/{project}/locations/{location}/collections/{collection}/da -// taStores/{data_store}/schemas/{schema}`. -func (r *ProjectsLocationsCollectionsDataStoresSchemasService) Get(name string) *ProjectsLocationsCollectionsDataStoresSchemasGetCall { - c := &ProjectsLocationsCollectionsDataStoresSchemasGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.name = name +// - parent: Full resource name of parent data store. Format: +// `projects/{project_number}/locations/{location_id}/collections/{coll +// ection}/dataStores/{data_store_id}`. +func (r *ProjectsLocationsCollectionsEnginesConversationsService) Create(parent string, googleclouddiscoveryenginev1betaconversation *GoogleCloudDiscoveryengineV1betaConversation) *ProjectsLocationsCollectionsEnginesConversationsCreateCall { + c := &ProjectsLocationsCollectionsEnginesConversationsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + c.googleclouddiscoveryenginev1betaconversation = googleclouddiscoveryenginev1betaconversation return c } // Fields allows partial responses to be retrieved. See // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse // for more information. -func (c *ProjectsLocationsCollectionsDataStoresSchemasGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresSchemasGetCall { +func (c *ProjectsLocationsCollectionsEnginesConversationsCreateCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsEnginesConversationsCreateCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// IfNoneMatch sets the 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. Use googleapi.IsNotModified to check whether the response -// error from Do is the result of In-None-Match. -func (c *ProjectsLocationsCollectionsDataStoresSchemasGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsCollectionsDataStoresSchemasGetCall { - c.ifNoneMatch_ = entityTag - return c -} - // Context sets the context to be used in this call's Do method. Any // pending HTTP request will be aborted if the provided context is // canceled. -func (c *ProjectsLocationsCollectionsDataStoresSchemasGetCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresSchemasGetCall { +func (c *ProjectsLocationsCollectionsEnginesConversationsCreateCall) Context(ctx context.Context) *ProjectsLocationsCollectionsEnginesConversationsCreateCall { c.ctx_ = ctx return c } // Header returns an http.Header that can be modified by the caller to // add HTTP headers to the request. -func (c *ProjectsLocationsCollectionsDataStoresSchemasGetCall) Header() http.Header { +func (c *ProjectsLocationsCollectionsEnginesConversationsCreateCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsCollectionsDataStoresSchemasGetCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsCollectionsEnginesConversationsCreateCall) doRequest(alt string) (*http.Response, error) { reqHeaders := make(http.Header) reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) for k, v := range c.header_ { reqHeaders[k] = v } reqHeaders.Set("User-Agent", c.s.userAgent()) - if c.ifNoneMatch_ != "" { - reqHeaders.Set("If-None-Match", c.ifNoneMatch_) - } var body io.Reader = nil + body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddiscoveryenginev1betaconversation) + if err != nil { + return nil, err + } + reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+parent}/conversations") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("GET", urls, body) + req, err := http.NewRequest("POST", urls, body) if err != nil { return nil, err } req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ - "name": c.name, + "parent": c.parent, }) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "discoveryengine.projects.locations.collections.dataStores.schemas.get" call. -// Exactly one of *GoogleCloudDiscoveryengineV1betaSchema or error will -// be non-nil. Any non-2xx status code is an error. Response headers are -// in either -// *GoogleCloudDiscoveryengineV1betaSchema.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 *ProjectsLocationsCollectionsDataStoresSchemasGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1betaSchema, error) { +// Do executes the "discoveryengine.projects.locations.collections.engines.conversations.create" call. +// Exactly one of *GoogleCloudDiscoveryengineV1betaConversation or error +// will be non-nil. Any non-2xx status code is an error. Response +// headers are in either +// *GoogleCloudDiscoveryengineV1betaConversation.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 *ProjectsLocationsCollectionsEnginesConversationsCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1betaConversation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -12312,7 +20963,7 @@ func (c *ProjectsLocationsCollectionsDataStoresSchemasGetCall) Do(opts ...google if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &GoogleCloudDiscoveryengineV1betaSchema{ + ret := &GoogleCloudDiscoveryengineV1betaConversation{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -12324,25 +20975,28 @@ func (c *ProjectsLocationsCollectionsDataStoresSchemasGetCall) Do(opts ...google } return ret, nil // { - // "description": "Gets a Schema.", - // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/schemas/{schemasId}", - // "httpMethod": "GET", - // "id": "discoveryengine.projects.locations.collections.dataStores.schemas.get", + // "description": "Creates a Conversation. If the Conversation to create already exists, an ALREADY_EXISTS error is returned.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/engines/{enginesId}/conversations", + // "httpMethod": "POST", + // "id": "discoveryengine.projects.locations.collections.engines.conversations.create", // "parameterOrder": [ - // "name" + // "parent" // ], // "parameters": { - // "name": { - // "description": "Required. The full resource name of the schema, in the format of `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/schemas/{schema}`.", + // "parent": { + // "description": "Required. Full resource name of parent data store. Format: `projects/{project_number}/locations/{location_id}/collections/{collection}/dataStores/{data_store_id}`", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/schemas/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/engines/[^/]+$", // "required": true, // "type": "string" // } // }, - // "path": "v1beta/{+name}", + // "path": "v1beta/{+parent}/conversations", + // "request": { + // "$ref": "GoogleCloudDiscoveryengineV1betaConversation" + // }, // "response": { - // "$ref": "GoogleCloudDiscoveryengineV1betaSchema" + // "$ref": "GoogleCloudDiscoveryengineV1betaConversation" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -12351,118 +21005,84 @@ func (c *ProjectsLocationsCollectionsDataStoresSchemasGetCall) Do(opts ...google } -// method id "discoveryengine.projects.locations.collections.dataStores.schemas.list": +// method id "discoveryengine.projects.locations.collections.engines.conversations.delete": -type ProjectsLocationsCollectionsDataStoresSchemasListCall struct { - s *Service - parent string - urlParams_ gensupport.URLParams - ifNoneMatch_ string - ctx_ context.Context - header_ http.Header +type ProjectsLocationsCollectionsEnginesConversationsDeleteCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// List: Gets a list of Schemas. +// Delete: Deletes a Conversation. If the Conversation to delete does +// not exist, a NOT_FOUND error is returned. // -// - parent: The parent data store resource name, in the format of -// `projects/{project}/locations/{location}/collections/{collection}/da -// taStores/{data_store}`. -func (r *ProjectsLocationsCollectionsDataStoresSchemasService) List(parent string) *ProjectsLocationsCollectionsDataStoresSchemasListCall { - c := &ProjectsLocationsCollectionsDataStoresSchemasListCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.parent = parent - return c -} - -// PageSize sets the optional parameter "pageSize": The maximum number -// of Schemas to return. The service may return fewer than this value. -// If unspecified, at most 100 Schemas will be returned. The maximum -// value is 1000; values above 1000 will be coerced to 1000. -func (c *ProjectsLocationsCollectionsDataStoresSchemasListCall) PageSize(pageSize int64) *ProjectsLocationsCollectionsDataStoresSchemasListCall { - c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) - return c -} - -// PageToken sets the optional parameter "pageToken": A page token, -// received from a previous SchemaService.ListSchemas call. Provide this -// to retrieve the subsequent page. When paginating, all other -// parameters provided to SchemaService.ListSchemas must match the call -// that provided the page token. -func (c *ProjectsLocationsCollectionsDataStoresSchemasListCall) PageToken(pageToken string) *ProjectsLocationsCollectionsDataStoresSchemasListCall { - c.urlParams_.Set("pageToken", pageToken) +// - name: The resource name of the Conversation to delete. Format: +// `projects/{project_number}/locations/{location_id}/collections/{coll +// ection}/dataStores/{data_store_id}/conversations/{conversation_id}`. +func (r *ProjectsLocationsCollectionsEnginesConversationsService) Delete(name string) *ProjectsLocationsCollectionsEnginesConversationsDeleteCall { + c := &ProjectsLocationsCollectionsEnginesConversationsDeleteCall{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 information. -func (c *ProjectsLocationsCollectionsDataStoresSchemasListCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresSchemasListCall { +func (c *ProjectsLocationsCollectionsEnginesConversationsDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsEnginesConversationsDeleteCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// IfNoneMatch sets the 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. Use googleapi.IsNotModified to check whether the response -// error from Do is the result of In-None-Match. -func (c *ProjectsLocationsCollectionsDataStoresSchemasListCall) IfNoneMatch(entityTag string) *ProjectsLocationsCollectionsDataStoresSchemasListCall { - c.ifNoneMatch_ = entityTag - return c -} - // Context sets the context to be used in this call's Do method. Any // pending HTTP request will be aborted if the provided context is // canceled. -func (c *ProjectsLocationsCollectionsDataStoresSchemasListCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresSchemasListCall { +func (c *ProjectsLocationsCollectionsEnginesConversationsDeleteCall) Context(ctx context.Context) *ProjectsLocationsCollectionsEnginesConversationsDeleteCall { c.ctx_ = ctx return c } // Header returns an http.Header that can be modified by the caller to // add HTTP headers to the request. -func (c *ProjectsLocationsCollectionsDataStoresSchemasListCall) Header() http.Header { +func (c *ProjectsLocationsCollectionsEnginesConversationsDeleteCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsCollectionsDataStoresSchemasListCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsCollectionsEnginesConversationsDeleteCall) doRequest(alt string) (*http.Response, error) { reqHeaders := make(http.Header) reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) for k, v := range c.header_ { reqHeaders[k] = v } reqHeaders.Set("User-Agent", c.s.userAgent()) - if c.ifNoneMatch_ != "" { - reqHeaders.Set("If-None-Match", c.ifNoneMatch_) - } var body io.Reader = nil c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+parent}/schemas") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("GET", urls, body) + req, err := http.NewRequest("DELETE", urls, body) if err != nil { return nil, err } req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ - "parent": c.parent, + "name": c.name, }) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "discoveryengine.projects.locations.collections.dataStores.schemas.list" call. -// Exactly one of *GoogleCloudDiscoveryengineV1betaListSchemasResponse -// or error will be non-nil. Any non-2xx status code is an error. -// Response headers are in either -// *GoogleCloudDiscoveryengineV1betaListSchemasResponse.ServerResponse.He -// ader 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 *ProjectsLocationsCollectionsDataStoresSchemasListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1betaListSchemasResponse, error) { +// Do executes the "discoveryengine.projects.locations.collections.engines.conversations.delete" call. +// Exactly one of *GoogleProtobufEmpty or error will be non-nil. Any +// non-2xx status code is an error. Response headers are in either +// *GoogleProtobufEmpty.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 *ProjectsLocationsCollectionsEnginesConversationsDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -12481,7 +21101,7 @@ func (c *ProjectsLocationsCollectionsDataStoresSchemasListCall) Do(opts ...googl if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &GoogleCloudDiscoveryengineV1betaListSchemasResponse{ + ret := &GoogleProtobufEmpty{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -12493,36 +21113,25 @@ func (c *ProjectsLocationsCollectionsDataStoresSchemasListCall) Do(opts ...googl } return ret, nil // { - // "description": "Gets a list of Schemas.", - // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/schemas", - // "httpMethod": "GET", - // "id": "discoveryengine.projects.locations.collections.dataStores.schemas.list", + // "description": "Deletes a Conversation. If the Conversation to delete does not exist, a NOT_FOUND error is returned.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/engines/{enginesId}/conversations/{conversationsId}", + // "httpMethod": "DELETE", + // "id": "discoveryengine.projects.locations.collections.engines.conversations.delete", // "parameterOrder": [ - // "parent" + // "name" // ], // "parameters": { - // "pageSize": { - // "description": "The maximum number of Schemas to return. The service may return fewer than this value. If unspecified, at most 100 Schemas will be returned. The maximum value is 1000; values above 1000 will be coerced to 1000.", - // "format": "int32", - // "location": "query", - // "type": "integer" - // }, - // "pageToken": { - // "description": "A page token, received from a previous SchemaService.ListSchemas call. Provide this to retrieve the subsequent page. When paginating, all other parameters provided to SchemaService.ListSchemas must match the call that provided the page token.", - // "location": "query", - // "type": "string" - // }, - // "parent": { - // "description": "Required. The parent data store resource name, in the format of `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}`.", + // "name": { + // "description": "Required. The resource name of the Conversation to delete. Format: `projects/{project_number}/locations/{location_id}/collections/{collection}/dataStores/{data_store_id}/conversations/{conversation_id}`", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/engines/[^/]+/conversations/[^/]+$", // "required": true, // "type": "string" // } // }, - // "path": "v1beta/{+parent}/schemas", + // "path": "v1beta/{+name}", // "response": { - // "$ref": "GoogleCloudDiscoveryengineV1betaListSchemasResponse" + // "$ref": "GoogleProtobufEmpty" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -12531,103 +21140,79 @@ func (c *ProjectsLocationsCollectionsDataStoresSchemasListCall) Do(opts ...googl } -// 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 *ProjectsLocationsCollectionsDataStoresSchemasListCall) Pages(ctx context.Context, f func(*GoogleCloudDiscoveryengineV1betaListSchemasResponse) error) error { - c.ctx_ = ctx - defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point - 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) - } -} - -// method id "discoveryengine.projects.locations.collections.dataStores.schemas.patch": +// method id "discoveryengine.projects.locations.collections.engines.conversations.get": -type ProjectsLocationsCollectionsDataStoresSchemasPatchCall struct { - s *Service - name string - googleclouddiscoveryenginev1betaschema *GoogleCloudDiscoveryengineV1betaSchema - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +type ProjectsLocationsCollectionsEnginesConversationsGetCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header } -// Patch: Updates a Schema. +// Get: Gets a Conversation. // -// - name: Immutable. The full resource name of the schema, in the -// format of -// `projects/{project}/locations/{location}/collections/{collection}/da -// taStores/{data_store}/schemas/{schema}`. This field must be a UTF-8 -// encoded string with a length limit of 1024 characters. -func (r *ProjectsLocationsCollectionsDataStoresSchemasService) Patch(name string, googleclouddiscoveryenginev1betaschema *GoogleCloudDiscoveryengineV1betaSchema) *ProjectsLocationsCollectionsDataStoresSchemasPatchCall { - c := &ProjectsLocationsCollectionsDataStoresSchemasPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// - name: The resource name of the Conversation to get. Format: +// `projects/{project_number}/locations/{location_id}/collections/{coll +// ection}/dataStores/{data_store_id}/conversations/{conversation_id}`. +func (r *ProjectsLocationsCollectionsEnginesConversationsService) Get(name string) *ProjectsLocationsCollectionsEnginesConversationsGetCall { + c := &ProjectsLocationsCollectionsEnginesConversationsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.name = name - c.googleclouddiscoveryenginev1betaschema = googleclouddiscoveryenginev1betaschema - return c -} - -// AllowMissing sets the optional parameter "allowMissing": If set to -// true, and the Schema is not found, a new Schema will be created. In -// this situation, `update_mask` is ignored. -func (c *ProjectsLocationsCollectionsDataStoresSchemasPatchCall) AllowMissing(allowMissing bool) *ProjectsLocationsCollectionsDataStoresSchemasPatchCall { - c.urlParams_.Set("allowMissing", fmt.Sprint(allowMissing)) return c } // Fields allows partial responses to be retrieved. See // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse // for more information. -func (c *ProjectsLocationsCollectionsDataStoresSchemasPatchCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresSchemasPatchCall { +func (c *ProjectsLocationsCollectionsEnginesConversationsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsEnginesConversationsGetCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } +// IfNoneMatch sets the 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. Use googleapi.IsNotModified to check whether the response +// error from Do is the result of In-None-Match. +func (c *ProjectsLocationsCollectionsEnginesConversationsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsCollectionsEnginesConversationsGetCall { + c.ifNoneMatch_ = entityTag + return c +} + // Context sets the context to be used in this call's Do method. Any // pending HTTP request will be aborted if the provided context is // canceled. -func (c *ProjectsLocationsCollectionsDataStoresSchemasPatchCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresSchemasPatchCall { +func (c *ProjectsLocationsCollectionsEnginesConversationsGetCall) Context(ctx context.Context) *ProjectsLocationsCollectionsEnginesConversationsGetCall { c.ctx_ = ctx return c } // Header returns an http.Header that can be modified by the caller to // add HTTP headers to the request. -func (c *ProjectsLocationsCollectionsDataStoresSchemasPatchCall) Header() http.Header { +func (c *ProjectsLocationsCollectionsEnginesConversationsGetCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsCollectionsDataStoresSchemasPatchCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsCollectionsEnginesConversationsGetCall) doRequest(alt string) (*http.Response, error) { reqHeaders := make(http.Header) reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) for k, v := range c.header_ { reqHeaders[k] = v } reqHeaders.Set("User-Agent", c.s.userAgent()) - var body io.Reader = nil - body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddiscoveryenginev1betaschema) - if err != nil { - return nil, err + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) } - reqHeaders.Set("Content-Type", "application/json") + var body io.Reader = nil 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) + req, err := http.NewRequest("GET", urls, body) if err != nil { return nil, err } @@ -12638,14 +21223,16 @@ func (c *ProjectsLocationsCollectionsDataStoresSchemasPatchCall) doRequest(alt s return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "discoveryengine.projects.locations.collections.dataStores.schemas.patch" call. -// Exactly one of *GoogleLongrunningOperation or error will be non-nil. -// 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 *ProjectsLocationsCollectionsDataStoresSchemasPatchCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { +// Do executes the "discoveryengine.projects.locations.collections.engines.conversations.get" call. +// Exactly one of *GoogleCloudDiscoveryengineV1betaConversation or error +// will be non-nil. Any non-2xx status code is an error. Response +// headers are in either +// *GoogleCloudDiscoveryengineV1betaConversation.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 *ProjectsLocationsCollectionsEnginesConversationsGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1betaConversation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -12664,7 +21251,7 @@ func (c *ProjectsLocationsCollectionsDataStoresSchemasPatchCall) Do(opts ...goog if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &GoogleLongrunningOperation{ + ret := &GoogleCloudDiscoveryengineV1betaConversation{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -12676,33 +21263,25 @@ func (c *ProjectsLocationsCollectionsDataStoresSchemasPatchCall) Do(opts ...goog } return ret, nil // { - // "description": "Updates a Schema.", - // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/schemas/{schemasId}", - // "httpMethod": "PATCH", - // "id": "discoveryengine.projects.locations.collections.dataStores.schemas.patch", + // "description": "Gets a Conversation.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/engines/{enginesId}/conversations/{conversationsId}", + // "httpMethod": "GET", + // "id": "discoveryengine.projects.locations.collections.engines.conversations.get", // "parameterOrder": [ // "name" // ], // "parameters": { - // "allowMissing": { - // "description": "If set to true, and the Schema is not found, a new Schema will be created. In this situation, `update_mask` is ignored.", - // "location": "query", - // "type": "boolean" - // }, // "name": { - // "description": "Immutable. The full resource name of the schema, in the format of `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/schemas/{schema}`. This field must be a UTF-8 encoded string with a length limit of 1024 characters.", + // "description": "Required. The resource name of the Conversation to get. Format: `projects/{project_number}/locations/{location_id}/collections/{collection}/dataStores/{data_store_id}/conversations/{conversation_id}`", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/schemas/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/engines/[^/]+/conversations/[^/]+$", // "required": true, // "type": "string" // } // }, // "path": "v1beta/{+name}", - // "request": { - // "$ref": "GoogleCloudDiscoveryengineV1betaSchema" - // }, // "response": { - // "$ref": "GoogleLongrunningOperation" + // "$ref": "GoogleCloudDiscoveryengineV1betaConversation" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -12711,32 +21290,66 @@ func (c *ProjectsLocationsCollectionsDataStoresSchemasPatchCall) Do(opts ...goog } -// method id "discoveryengine.projects.locations.collections.dataStores.schemas.operations.get": +// method id "discoveryengine.projects.locations.collections.engines.conversations.list": -type ProjectsLocationsCollectionsDataStoresSchemasOperationsGetCall struct { +type ProjectsLocationsCollectionsEnginesConversationsListCall struct { s *Service - name string + parent string urlParams_ gensupport.URLParams ifNoneMatch_ string ctx_ context.Context header_ http.Header } -// Get: Gets the latest state of a long-running operation. Clients can -// use this method to poll the operation result at intervals as -// recommended by the API service. +// List: Lists all Conversations by their parent DataStore. // -// - name: The name of the operation resource. -func (r *ProjectsLocationsCollectionsDataStoresSchemasOperationsService) Get(name string) *ProjectsLocationsCollectionsDataStoresSchemasOperationsGetCall { - c := &ProjectsLocationsCollectionsDataStoresSchemasOperationsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.name = name +// - parent: The data store resource name. Format: +// `projects/{project_number}/locations/{location_id}/collections/{coll +// ection}/dataStores/{data_store_id}`. +func (r *ProjectsLocationsCollectionsEnginesConversationsService) List(parent string) *ProjectsLocationsCollectionsEnginesConversationsListCall { + c := &ProjectsLocationsCollectionsEnginesConversationsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + return c +} + +// Filter sets the optional parameter "filter": A filter to apply on the +// list results. The supported features are: user_pseudo_id, state. +// Example: "user_pseudo_id = some_id" +func (c *ProjectsLocationsCollectionsEnginesConversationsListCall) Filter(filter string) *ProjectsLocationsCollectionsEnginesConversationsListCall { + c.urlParams_.Set("filter", filter) + 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: * `update_time` * +// `create_time` * `conversation_name` Example: "update_time desc" +// "create_time" +func (c *ProjectsLocationsCollectionsEnginesConversationsListCall) OrderBy(orderBy string) *ProjectsLocationsCollectionsEnginesConversationsListCall { + c.urlParams_.Set("orderBy", orderBy) + return c +} + +// PageSize sets the optional parameter "pageSize": Maximum number of +// results to return. If unspecified, defaults to 50. Max allowed value +// is 1000. +func (c *ProjectsLocationsCollectionsEnginesConversationsListCall) PageSize(pageSize int64) *ProjectsLocationsCollectionsEnginesConversationsListCall { + c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) + return c +} + +// PageToken sets the optional parameter "pageToken": A page token, +// received from a previous `ListConversations` call. Provide this to +// retrieve the subsequent page. +func (c *ProjectsLocationsCollectionsEnginesConversationsListCall) PageToken(pageToken string) *ProjectsLocationsCollectionsEnginesConversationsListCall { + 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 information. -func (c *ProjectsLocationsCollectionsDataStoresSchemasOperationsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresSchemasOperationsGetCall { +func (c *ProjectsLocationsCollectionsEnginesConversationsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsEnginesConversationsListCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } @@ -12746,7 +21359,7 @@ func (c *ProjectsLocationsCollectionsDataStoresSchemasOperationsGetCall) Fields( // getting updates only after the object has changed since the last // request. Use googleapi.IsNotModified to check whether the response // error from Do is the result of In-None-Match. -func (c *ProjectsLocationsCollectionsDataStoresSchemasOperationsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsCollectionsDataStoresSchemasOperationsGetCall { +func (c *ProjectsLocationsCollectionsEnginesConversationsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsCollectionsEnginesConversationsListCall { c.ifNoneMatch_ = entityTag return c } @@ -12754,21 +21367,21 @@ func (c *ProjectsLocationsCollectionsDataStoresSchemasOperationsGetCall) IfNoneM // Context sets the context to be used in this call's Do method. Any // pending HTTP request will be aborted if the provided context is // canceled. -func (c *ProjectsLocationsCollectionsDataStoresSchemasOperationsGetCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresSchemasOperationsGetCall { +func (c *ProjectsLocationsCollectionsEnginesConversationsListCall) Context(ctx context.Context) *ProjectsLocationsCollectionsEnginesConversationsListCall { c.ctx_ = ctx return c } // Header returns an http.Header that can be modified by the caller to // add HTTP headers to the request. -func (c *ProjectsLocationsCollectionsDataStoresSchemasOperationsGetCall) Header() http.Header { +func (c *ProjectsLocationsCollectionsEnginesConversationsListCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsCollectionsDataStoresSchemasOperationsGetCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsCollectionsEnginesConversationsListCall) doRequest(alt string) (*http.Response, error) { reqHeaders := make(http.Header) reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) for k, v := range c.header_ { @@ -12781,7 +21394,7 @@ func (c *ProjectsLocationsCollectionsDataStoresSchemasOperationsGetCall) doReque var body io.Reader = nil c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+parent}/conversations") urls += "?" + c.urlParams_.Encode() req, err := http.NewRequest("GET", urls, body) if err != nil { @@ -12789,19 +21402,22 @@ func (c *ProjectsLocationsCollectionsDataStoresSchemasOperationsGetCall) doReque } req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ - "name": c.name, + "parent": c.parent, }) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "discoveryengine.projects.locations.collections.dataStores.schemas.operations.get" call. -// Exactly one of *GoogleLongrunningOperation or error will be non-nil. -// 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 *ProjectsLocationsCollectionsDataStoresSchemasOperationsGetCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { +// Do executes the "discoveryengine.projects.locations.collections.engines.conversations.list" call. +// Exactly one of +// *GoogleCloudDiscoveryengineV1betaListConversationsResponse or error +// will be non-nil. Any non-2xx status code is an error. Response +// headers are in either +// *GoogleCloudDiscoveryengineV1betaListConversationsResponse.ServerRespo +// nse.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 *ProjectsLocationsCollectionsEnginesConversationsListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1betaListConversationsResponse, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -12820,7 +21436,7 @@ func (c *ProjectsLocationsCollectionsDataStoresSchemasOperationsGetCall) Do(opts if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &GoogleLongrunningOperation{ + ret := &GoogleCloudDiscoveryengineV1betaListConversationsResponse{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -12832,25 +21448,46 @@ func (c *ProjectsLocationsCollectionsDataStoresSchemasOperationsGetCall) Do(opts } return ret, nil // { - // "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": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/schemas/{schemasId}/operations/{operationsId}", + // "description": "Lists all Conversations by their parent DataStore.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/engines/{enginesId}/conversations", // "httpMethod": "GET", - // "id": "discoveryengine.projects.locations.collections.dataStores.schemas.operations.get", + // "id": "discoveryengine.projects.locations.collections.engines.conversations.list", // "parameterOrder": [ - // "name" + // "parent" // ], // "parameters": { - // "name": { - // "description": "The name of the operation resource.", + // "filter": { + // "description": "A filter to apply on the list results. The supported features are: user_pseudo_id, state. Example: \"user_pseudo_id = some_id\"", + // "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: * `update_time` * `create_time` * `conversation_name` Example: \"update_time desc\" \"create_time\"", + // "location": "query", + // "type": "string" + // }, + // "pageSize": { + // "description": "Maximum number of results to return. If unspecified, defaults to 50. Max allowed value is 1000.", + // "format": "int32", + // "location": "query", + // "type": "integer" + // }, + // "pageToken": { + // "description": "A page token, received from a previous `ListConversations` call. Provide this to retrieve the subsequent page.", + // "location": "query", + // "type": "string" + // }, + // "parent": { + // "description": "Required. The data store resource name. Format: `projects/{project_number}/locations/{location_id}/collections/{collection}/dataStores/{data_store_id}`", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/schemas/[^/]+/operations/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/engines/[^/]+$", // "required": true, // "type": "string" // } // }, - // "path": "v1beta/{+name}", + // "path": "v1beta/{+parent}/conversations", // "response": { - // "$ref": "GoogleLongrunningOperation" + // "$ref": "GoogleCloudDiscoveryengineV1betaListConversationsResponse" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -12859,100 +21496,106 @@ func (c *ProjectsLocationsCollectionsDataStoresSchemasOperationsGetCall) Do(opts } -// method id "discoveryengine.projects.locations.collections.dataStores.schemas.operations.list": - -type ProjectsLocationsCollectionsDataStoresSchemasOperationsListCall struct { - s *Service - name string - urlParams_ gensupport.URLParams - ifNoneMatch_ string - 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 *ProjectsLocationsCollectionsEnginesConversationsListCall) Pages(ctx context.Context, f func(*GoogleCloudDiscoveryengineV1betaListConversationsResponse) error) error { + c.ctx_ = ctx + defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point + 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) + } } -// List: Lists operations that match the specified filter in the -// request. If the server doesn't support this method, it returns -// `UNIMPLEMENTED`. -// -// - name: The name of the operation's parent resource. -func (r *ProjectsLocationsCollectionsDataStoresSchemasOperationsService) List(name string) *ProjectsLocationsCollectionsDataStoresSchemasOperationsListCall { - c := &ProjectsLocationsCollectionsDataStoresSchemasOperationsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.name = name - return c -} +// method id "discoveryengine.projects.locations.collections.engines.conversations.patch": -// Filter sets the optional parameter "filter": The standard list -// filter. -func (c *ProjectsLocationsCollectionsDataStoresSchemasOperationsListCall) Filter(filter string) *ProjectsLocationsCollectionsDataStoresSchemasOperationsListCall { - c.urlParams_.Set("filter", filter) - return c +type ProjectsLocationsCollectionsEnginesConversationsPatchCall struct { + s *Service + name string + googleclouddiscoveryenginev1betaconversation *GoogleCloudDiscoveryengineV1betaConversation + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// PageSize sets the optional parameter "pageSize": The standard list -// page size. -func (c *ProjectsLocationsCollectionsDataStoresSchemasOperationsListCall) PageSize(pageSize int64) *ProjectsLocationsCollectionsDataStoresSchemasOperationsListCall { - c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) +// Patch: Updates a Conversation. Conversation action type cannot be +// changed. If the Conversation to update does not exist, a NOT_FOUND +// error is returned. +// +// - name: Immutable. Fully qualified name +// `project/*/locations/global/collections/{collection}/dataStore/*/con +// versations/*` or +// `project/*/locations/global/collections/{collection}/engines/*/conve +// rsations/*`. +func (r *ProjectsLocationsCollectionsEnginesConversationsService) Patch(name string, googleclouddiscoveryenginev1betaconversation *GoogleCloudDiscoveryengineV1betaConversation) *ProjectsLocationsCollectionsEnginesConversationsPatchCall { + c := &ProjectsLocationsCollectionsEnginesConversationsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + c.googleclouddiscoveryenginev1betaconversation = googleclouddiscoveryenginev1betaconversation return c } -// PageToken sets the optional parameter "pageToken": The standard list -// page token. -func (c *ProjectsLocationsCollectionsDataStoresSchemasOperationsListCall) PageToken(pageToken string) *ProjectsLocationsCollectionsDataStoresSchemasOperationsListCall { - c.urlParams_.Set("pageToken", pageToken) +// UpdateMask sets the optional parameter "updateMask": Indicates which +// fields in the provided Conversation to update. The following are NOT +// supported: * Conversation.name If not set or empty, all supported +// fields are updated. +func (c *ProjectsLocationsCollectionsEnginesConversationsPatchCall) UpdateMask(updateMask string) *ProjectsLocationsCollectionsEnginesConversationsPatchCall { + 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 information. -func (c *ProjectsLocationsCollectionsDataStoresSchemasOperationsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresSchemasOperationsListCall { +func (c *ProjectsLocationsCollectionsEnginesConversationsPatchCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsEnginesConversationsPatchCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// IfNoneMatch sets the 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. Use googleapi.IsNotModified to check whether the response -// error from Do is the result of In-None-Match. -func (c *ProjectsLocationsCollectionsDataStoresSchemasOperationsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsCollectionsDataStoresSchemasOperationsListCall { - c.ifNoneMatch_ = entityTag - return c -} - // Context sets the context to be used in this call's Do method. Any // pending HTTP request will be aborted if the provided context is // canceled. -func (c *ProjectsLocationsCollectionsDataStoresSchemasOperationsListCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresSchemasOperationsListCall { +func (c *ProjectsLocationsCollectionsEnginesConversationsPatchCall) Context(ctx context.Context) *ProjectsLocationsCollectionsEnginesConversationsPatchCall { c.ctx_ = ctx return c } // Header returns an http.Header that can be modified by the caller to // add HTTP headers to the request. -func (c *ProjectsLocationsCollectionsDataStoresSchemasOperationsListCall) Header() http.Header { +func (c *ProjectsLocationsCollectionsEnginesConversationsPatchCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsCollectionsDataStoresSchemasOperationsListCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsCollectionsEnginesConversationsPatchCall) doRequest(alt string) (*http.Response, error) { reqHeaders := make(http.Header) reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) for k, v := range c.header_ { reqHeaders[k] = v } reqHeaders.Set("User-Agent", c.s.userAgent()) - if c.ifNoneMatch_ != "" { - reqHeaders.Set("If-None-Match", c.ifNoneMatch_) - } var body io.Reader = nil + body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddiscoveryenginev1betaconversation) + if err != nil { + return nil, err + } + reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}/operations") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("GET", urls, body) + req, err := http.NewRequest("PATCH", urls, body) if err != nil { return nil, err } @@ -12963,15 +21606,16 @@ func (c *ProjectsLocationsCollectionsDataStoresSchemasOperationsListCall) doRequ return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "discoveryengine.projects.locations.collections.dataStores.schemas.operations.list" call. -// Exactly one of *GoogleLongrunningListOperationsResponse or error will -// be non-nil. Any non-2xx status code is an error. Response headers are -// in either -// *GoogleLongrunningListOperationsResponse.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 *ProjectsLocationsCollectionsDataStoresSchemasOperationsListCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningListOperationsResponse, error) { +// Do executes the "discoveryengine.projects.locations.collections.engines.conversations.patch" call. +// Exactly one of *GoogleCloudDiscoveryengineV1betaConversation or error +// will be non-nil. Any non-2xx status code is an error. Response +// headers are in either +// *GoogleCloudDiscoveryengineV1betaConversation.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 *ProjectsLocationsCollectionsEnginesConversationsPatchCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1betaConversation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -12990,7 +21634,7 @@ func (c *ProjectsLocationsCollectionsDataStoresSchemasOperationsListCall) Do(opt if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &GoogleLongrunningListOperationsResponse{ + ret := &GoogleCloudDiscoveryengineV1betaConversation{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -13002,166 +21646,133 @@ func (c *ProjectsLocationsCollectionsDataStoresSchemasOperationsListCall) Do(opt } return ret, nil // { - // "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`.", - // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/schemas/{schemasId}/operations", - // "httpMethod": "GET", - // "id": "discoveryengine.projects.locations.collections.dataStores.schemas.operations.list", + // "description": "Updates a Conversation. Conversation action type cannot be changed. If the Conversation to update does not exist, a NOT_FOUND error is returned.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/engines/{enginesId}/conversations/{conversationsId}", + // "httpMethod": "PATCH", + // "id": "discoveryengine.projects.locations.collections.engines.conversations.patch", // "parameterOrder": [ // "name" // ], // "parameters": { - // "filter": { - // "description": "The standard list filter.", - // "location": "query", - // "type": "string" - // }, // "name": { - // "description": "The name of the operation's parent resource.", + // "description": "Immutable. Fully qualified name `project/*/locations/global/collections/{collection}/dataStore/*/conversations/*` or `project/*/locations/global/collections/{collection}/engines/*/conversations/*`.", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/schemas/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/engines/[^/]+/conversations/[^/]+$", // "required": true, // "type": "string" // }, - // "pageSize": { - // "description": "The standard list page size.", - // "format": "int32", - // "location": "query", - // "type": "integer" - // }, - // "pageToken": { - // "description": "The standard list page token.", + // "updateMask": { + // "description": "Indicates which fields in the provided Conversation to update. The following are NOT supported: * Conversation.name If not set or empty, all supported fields are updated.", + // "format": "google-fieldmask", // "location": "query", - // "type": "string" - // } - // }, - // "path": "v1beta/{+name}/operations", - // "response": { - // "$ref": "GoogleLongrunningListOperationsResponse" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform" - // ] - // } - -} - -// 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 *ProjectsLocationsCollectionsDataStoresSchemasOperationsListCall) Pages(ctx context.Context, f func(*GoogleLongrunningListOperationsResponse) error) error { - c.ctx_ = ctx - defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point - 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": "string" + // } + // }, + // "path": "v1beta/{+name}", + // "request": { + // "$ref": "GoogleCloudDiscoveryengineV1betaConversation" + // }, + // "response": { + // "$ref": "GoogleCloudDiscoveryengineV1betaConversation" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + } -// method id "discoveryengine.projects.locations.collections.dataStores.servingConfigs.recommend": +// method id "discoveryengine.projects.locations.collections.engines.operations.get": -type ProjectsLocationsCollectionsDataStoresServingConfigsRecommendCall struct { - s *Service - servingConfig string - googleclouddiscoveryenginev1betarecommendrequest *GoogleCloudDiscoveryengineV1betaRecommendRequest - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +type ProjectsLocationsCollectionsEnginesOperationsGetCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header } -// Recommend: Makes a recommendation, which requires a contextual user -// event. +// Get: Gets the latest state of a long-running operation. Clients can +// use this method to poll the operation result at intervals as +// recommended by the API service. // -// - servingConfig: Full resource name of a ServingConfig: -// `projects/*/locations/global/collections/*/engines/*/servingConfigs/ -// *`, or -// `projects/*/locations/global/collections/*/dataStores/*/servingConfi -// gs/*` One default serving config is created along with your -// recommendation engine creation. The engine ID will be used as the -// ID of the default serving config. For example, for Engine -// `projects/*/locations/global/collections/*/engines/my-engine`, you -// can use -// `projects/*/locations/global/collections/*/engines/my-engine/serving -// Configs/my-engine` for your RecommendationService.Recommend -// requests. -func (r *ProjectsLocationsCollectionsDataStoresServingConfigsService) Recommend(servingConfig string, googleclouddiscoveryenginev1betarecommendrequest *GoogleCloudDiscoveryengineV1betaRecommendRequest) *ProjectsLocationsCollectionsDataStoresServingConfigsRecommendCall { - c := &ProjectsLocationsCollectionsDataStoresServingConfigsRecommendCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.servingConfig = servingConfig - c.googleclouddiscoveryenginev1betarecommendrequest = googleclouddiscoveryenginev1betarecommendrequest +// - name: The name of the operation resource. +func (r *ProjectsLocationsCollectionsEnginesOperationsService) Get(name string) *ProjectsLocationsCollectionsEnginesOperationsGetCall { + c := &ProjectsLocationsCollectionsEnginesOperationsGetCall{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 information. -func (c *ProjectsLocationsCollectionsDataStoresServingConfigsRecommendCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresServingConfigsRecommendCall { +func (c *ProjectsLocationsCollectionsEnginesOperationsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsEnginesOperationsGetCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } +// IfNoneMatch sets the 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. Use googleapi.IsNotModified to check whether the response +// error from Do is the result of In-None-Match. +func (c *ProjectsLocationsCollectionsEnginesOperationsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsCollectionsEnginesOperationsGetCall { + c.ifNoneMatch_ = entityTag + return c +} + // Context sets the context to be used in this call's Do method. Any // pending HTTP request will be aborted if the provided context is // canceled. -func (c *ProjectsLocationsCollectionsDataStoresServingConfigsRecommendCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresServingConfigsRecommendCall { +func (c *ProjectsLocationsCollectionsEnginesOperationsGetCall) Context(ctx context.Context) *ProjectsLocationsCollectionsEnginesOperationsGetCall { c.ctx_ = ctx return c } // Header returns an http.Header that can be modified by the caller to // add HTTP headers to the request. -func (c *ProjectsLocationsCollectionsDataStoresServingConfigsRecommendCall) Header() http.Header { +func (c *ProjectsLocationsCollectionsEnginesOperationsGetCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsCollectionsDataStoresServingConfigsRecommendCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsCollectionsEnginesOperationsGetCall) doRequest(alt string) (*http.Response, error) { reqHeaders := make(http.Header) reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) for k, v := range c.header_ { reqHeaders[k] = v } reqHeaders.Set("User-Agent", c.s.userAgent()) - var body io.Reader = nil - body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddiscoveryenginev1betarecommendrequest) - if err != nil { - return nil, err + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) } - reqHeaders.Set("Content-Type", "application/json") + var body io.Reader = nil c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+servingConfig}:recommend") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("POST", urls, body) + req, err := http.NewRequest("GET", urls, body) if err != nil { return nil, err } req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ - "servingConfig": c.servingConfig, + "name": c.name, }) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "discoveryengine.projects.locations.collections.dataStores.servingConfigs.recommend" call. -// Exactly one of *GoogleCloudDiscoveryengineV1betaRecommendResponse or -// error will be non-nil. Any non-2xx status code is an error. Response -// headers are in either -// *GoogleCloudDiscoveryengineV1betaRecommendResponse.ServerResponse.Head -// er 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 *ProjectsLocationsCollectionsDataStoresServingConfigsRecommendCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1betaRecommendResponse, error) { +// Do executes the "discoveryengine.projects.locations.collections.engines.operations.get" call. +// Exactly one of *GoogleLongrunningOperation or error will be non-nil. +// 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 *ProjectsLocationsCollectionsEnginesOperationsGetCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -13180,7 +21791,7 @@ func (c *ProjectsLocationsCollectionsDataStoresServingConfigsRecommendCall) Do(o if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &GoogleCloudDiscoveryengineV1betaRecommendResponse{ + ret := &GoogleLongrunningOperation{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -13192,28 +21803,25 @@ func (c *ProjectsLocationsCollectionsDataStoresServingConfigsRecommendCall) Do(o } return ret, nil // { - // "description": "Makes a recommendation, which requires a contextual user event.", - // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/servingConfigs/{servingConfigsId}:recommend", - // "httpMethod": "POST", - // "id": "discoveryengine.projects.locations.collections.dataStores.servingConfigs.recommend", + // "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": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/engines/{enginesId}/operations/{operationsId}", + // "httpMethod": "GET", + // "id": "discoveryengine.projects.locations.collections.engines.operations.get", // "parameterOrder": [ - // "servingConfig" + // "name" // ], // "parameters": { - // "servingConfig": { - // "description": "Required. Full resource name of a ServingConfig: `projects/*/locations/global/collections/*/engines/*/servingConfigs/*`, or `projects/*/locations/global/collections/*/dataStores/*/servingConfigs/*` One default serving config is created along with your recommendation engine creation. The engine ID will be used as the ID of the default serving config. For example, for Engine `projects/*/locations/global/collections/*/engines/my-engine`, you can use `projects/*/locations/global/collections/*/engines/my-engine/servingConfigs/my-engine` for your RecommendationService.Recommend requests.", + // "name": { + // "description": "The name of the operation resource.", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/servingConfigs/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/engines/[^/]+/operations/[^/]+$", // "required": true, // "type": "string" // } // }, - // "path": "v1beta/{+servingConfig}:recommend", - // "request": { - // "$ref": "GoogleCloudDiscoveryengineV1betaRecommendRequest" - // }, + // "path": "v1beta/{+name}", // "response": { - // "$ref": "GoogleCloudDiscoveryengineV1betaRecommendResponse" + // "$ref": "GoogleLongrunningOperation" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -13222,97 +21830,119 @@ func (c *ProjectsLocationsCollectionsDataStoresServingConfigsRecommendCall) Do(o } -// method id "discoveryengine.projects.locations.collections.dataStores.servingConfigs.search": +// method id "discoveryengine.projects.locations.collections.engines.operations.list": -type ProjectsLocationsCollectionsDataStoresServingConfigsSearchCall struct { - s *Service - servingConfig string - googleclouddiscoveryenginev1betasearchrequest *GoogleCloudDiscoveryengineV1betaSearchRequest - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +type ProjectsLocationsCollectionsEnginesOperationsListCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header } -// Search: Performs a search. +// List: Lists operations that match the specified filter in the +// request. If the server doesn't support this method, it returns +// `UNIMPLEMENTED`. // -// - servingConfig: The resource name of the Search serving config, such -// as -// `projects/*/locations/global/collections/default_collection/engines/ -// */servingConfigs/default_serving_config`, or -// `projects/*/locations/global/collections/default_collection/dataStor -// es/default_data_store/servingConfigs/default_serving_config`. This -// field is used to identify the serving configuration name, set of -// models used to make the search. -func (r *ProjectsLocationsCollectionsDataStoresServingConfigsService) Search(servingConfig string, googleclouddiscoveryenginev1betasearchrequest *GoogleCloudDiscoveryengineV1betaSearchRequest) *ProjectsLocationsCollectionsDataStoresServingConfigsSearchCall { - c := &ProjectsLocationsCollectionsDataStoresServingConfigsSearchCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.servingConfig = servingConfig - c.googleclouddiscoveryenginev1betasearchrequest = googleclouddiscoveryenginev1betasearchrequest +// - name: The name of the operation's parent resource. +func (r *ProjectsLocationsCollectionsEnginesOperationsService) List(name string) *ProjectsLocationsCollectionsEnginesOperationsListCall { + c := &ProjectsLocationsCollectionsEnginesOperationsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + return c +} + +// Filter sets the optional parameter "filter": The standard list +// filter. +func (c *ProjectsLocationsCollectionsEnginesOperationsListCall) Filter(filter string) *ProjectsLocationsCollectionsEnginesOperationsListCall { + c.urlParams_.Set("filter", filter) + return c +} + +// PageSize sets the optional parameter "pageSize": The standard list +// page size. +func (c *ProjectsLocationsCollectionsEnginesOperationsListCall) PageSize(pageSize int64) *ProjectsLocationsCollectionsEnginesOperationsListCall { + c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) + return c +} + +// PageToken sets the optional parameter "pageToken": The standard list +// page token. +func (c *ProjectsLocationsCollectionsEnginesOperationsListCall) PageToken(pageToken string) *ProjectsLocationsCollectionsEnginesOperationsListCall { + 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 information. -func (c *ProjectsLocationsCollectionsDataStoresServingConfigsSearchCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresServingConfigsSearchCall { +func (c *ProjectsLocationsCollectionsEnginesOperationsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsEnginesOperationsListCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } +// IfNoneMatch sets the 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. Use googleapi.IsNotModified to check whether the response +// error from Do is the result of In-None-Match. +func (c *ProjectsLocationsCollectionsEnginesOperationsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsCollectionsEnginesOperationsListCall { + c.ifNoneMatch_ = entityTag + return c +} + // Context sets the context to be used in this call's Do method. Any // pending HTTP request will be aborted if the provided context is // canceled. -func (c *ProjectsLocationsCollectionsDataStoresServingConfigsSearchCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresServingConfigsSearchCall { +func (c *ProjectsLocationsCollectionsEnginesOperationsListCall) Context(ctx context.Context) *ProjectsLocationsCollectionsEnginesOperationsListCall { c.ctx_ = ctx return c } // Header returns an http.Header that can be modified by the caller to // add HTTP headers to the request. -func (c *ProjectsLocationsCollectionsDataStoresServingConfigsSearchCall) Header() http.Header { +func (c *ProjectsLocationsCollectionsEnginesOperationsListCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsCollectionsDataStoresServingConfigsSearchCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsCollectionsEnginesOperationsListCall) doRequest(alt string) (*http.Response, error) { reqHeaders := make(http.Header) reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) for k, v := range c.header_ { reqHeaders[k] = v } reqHeaders.Set("User-Agent", c.s.userAgent()) - var body io.Reader = nil - body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddiscoveryenginev1betasearchrequest) - if err != nil { - return nil, err + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) } - reqHeaders.Set("Content-Type", "application/json") + var body io.Reader = nil c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+servingConfig}:search") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}/operations") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("POST", urls, body) + req, err := http.NewRequest("GET", urls, body) if err != nil { return nil, err } req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ - "servingConfig": c.servingConfig, + "name": c.name, }) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "discoveryengine.projects.locations.collections.dataStores.servingConfigs.search" call. -// Exactly one of *GoogleCloudDiscoveryengineV1betaSearchResponse or -// error will be non-nil. Any non-2xx status code is an error. Response -// headers are in either -// *GoogleCloudDiscoveryengineV1betaSearchResponse.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 *ProjectsLocationsCollectionsDataStoresServingConfigsSearchCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1betaSearchResponse, error) { +// Do executes the "discoveryengine.projects.locations.collections.engines.operations.list" call. +// Exactly one of *GoogleLongrunningListOperationsResponse or error will +// be non-nil. Any non-2xx status code is an error. Response headers are +// in either +// *GoogleLongrunningListOperationsResponse.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 *ProjectsLocationsCollectionsEnginesOperationsListCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningListOperationsResponse, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -13331,7 +21961,7 @@ func (c *ProjectsLocationsCollectionsDataStoresServingConfigsSearchCall) Do(opts if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &GoogleCloudDiscoveryengineV1betaSearchResponse{ + ret := &GoogleLongrunningListOperationsResponse{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -13343,28 +21973,41 @@ func (c *ProjectsLocationsCollectionsDataStoresServingConfigsSearchCall) Do(opts } return ret, nil // { - // "description": "Performs a search.", - // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/servingConfigs/{servingConfigsId}:search", - // "httpMethod": "POST", - // "id": "discoveryengine.projects.locations.collections.dataStores.servingConfigs.search", + // "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/engines/{enginesId}/operations", + // "httpMethod": "GET", + // "id": "discoveryengine.projects.locations.collections.engines.operations.list", // "parameterOrder": [ - // "servingConfig" + // "name" // ], // "parameters": { - // "servingConfig": { - // "description": "Required. The resource name of the Search serving config, such as `projects/*/locations/global/collections/default_collection/engines/*/servingConfigs/default_serving_config`, or `projects/*/locations/global/collections/default_collection/dataStores/default_data_store/servingConfigs/default_serving_config`. This field is used to identify the serving configuration name, set of models used to make the search.", + // "filter": { + // "description": "The standard list filter.", + // "location": "query", + // "type": "string" + // }, + // "name": { + // "description": "The name of the operation's parent resource.", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/servingConfigs/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/engines/[^/]+$", // "required": true, // "type": "string" + // }, + // "pageSize": { + // "description": "The standard list page size.", + // "format": "int32", + // "location": "query", + // "type": "integer" + // }, + // "pageToken": { + // "description": "The standard list page token.", + // "location": "query", + // "type": "string" // } // }, - // "path": "v1beta/{+servingConfig}:search", - // "request": { - // "$ref": "GoogleCloudDiscoveryengineV1betaSearchRequest" - // }, + // "path": "v1beta/{+name}/operations", // "response": { - // "$ref": "GoogleCloudDiscoveryengineV1betaSearchResponse" + // "$ref": "GoogleLongrunningListOperationsResponse" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -13376,9 +22019,9 @@ func (c *ProjectsLocationsCollectionsDataStoresServingConfigsSearchCall) Do(opts // 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 *ProjectsLocationsCollectionsDataStoresServingConfigsSearchCall) Pages(ctx context.Context, f func(*GoogleCloudDiscoveryengineV1betaSearchResponse) error) error { +func (c *ProjectsLocationsCollectionsEnginesOperationsListCall) Pages(ctx context.Context, f func(*GoogleLongrunningListOperationsResponse) error) error { c.ctx_ = ctx - defer func(pt string) { c.googleclouddiscoveryenginev1betasearchrequest.PageToken = pt }(c.googleclouddiscoveryenginev1betasearchrequest.PageToken) // reset paging to original point + defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point for { x, err := c.Do() if err != nil { @@ -13390,101 +22033,106 @@ func (c *ProjectsLocationsCollectionsDataStoresServingConfigsSearchCall) Pages(c if x.NextPageToken == "" { return nil } - c.googleclouddiscoveryenginev1betasearchrequest.PageToken = x.NextPageToken + c.PageToken(x.NextPageToken) } } -// method id "discoveryengine.projects.locations.collections.dataStores.siteSearchEngine.operations.get": +// method id "discoveryengine.projects.locations.collections.engines.servingConfigs.recommend": -type ProjectsLocationsCollectionsDataStoresSiteSearchEngineOperationsGetCall struct { - s *Service - name string - urlParams_ gensupport.URLParams - ifNoneMatch_ string - ctx_ context.Context - header_ http.Header +type ProjectsLocationsCollectionsEnginesServingConfigsRecommendCall struct { + s *Service + servingConfig string + googleclouddiscoveryenginev1betarecommendrequest *GoogleCloudDiscoveryengineV1betaRecommendRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// Get: Gets the latest state of a long-running operation. Clients can -// use this method to poll the operation result at intervals as -// recommended by the API service. +// Recommend: Makes a recommendation, which requires a contextual user +// event. // -// - name: The name of the operation resource. -func (r *ProjectsLocationsCollectionsDataStoresSiteSearchEngineOperationsService) Get(name string) *ProjectsLocationsCollectionsDataStoresSiteSearchEngineOperationsGetCall { - c := &ProjectsLocationsCollectionsDataStoresSiteSearchEngineOperationsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.name = name +// - servingConfig: Full resource name of a ServingConfig: +// `projects/*/locations/global/collections/*/engines/*/servingConfigs/ +// *`, or +// `projects/*/locations/global/collections/*/dataStores/*/servingConfi +// gs/*` One default serving config is created along with your +// recommendation engine creation. The engine ID will be used as the +// ID of the default serving config. For example, for Engine +// `projects/*/locations/global/collections/*/engines/my-engine`, you +// can use +// `projects/*/locations/global/collections/*/engines/my-engine/serving +// Configs/my-engine` for your RecommendationService.Recommend +// requests. +func (r *ProjectsLocationsCollectionsEnginesServingConfigsService) Recommend(servingConfig string, googleclouddiscoveryenginev1betarecommendrequest *GoogleCloudDiscoveryengineV1betaRecommendRequest) *ProjectsLocationsCollectionsEnginesServingConfigsRecommendCall { + c := &ProjectsLocationsCollectionsEnginesServingConfigsRecommendCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.servingConfig = servingConfig + c.googleclouddiscoveryenginev1betarecommendrequest = googleclouddiscoveryenginev1betarecommendrequest return c } // Fields allows partial responses to be retrieved. See // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse // for more information. -func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineOperationsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresSiteSearchEngineOperationsGetCall { +func (c *ProjectsLocationsCollectionsEnginesServingConfigsRecommendCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsEnginesServingConfigsRecommendCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// IfNoneMatch sets the 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. Use googleapi.IsNotModified to check whether the response -// error from Do is the result of In-None-Match. -func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineOperationsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsCollectionsDataStoresSiteSearchEngineOperationsGetCall { - c.ifNoneMatch_ = entityTag - return c -} - // Context sets the context to be used in this call's Do method. Any // pending HTTP request will be aborted if the provided context is // canceled. -func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineOperationsGetCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresSiteSearchEngineOperationsGetCall { +func (c *ProjectsLocationsCollectionsEnginesServingConfigsRecommendCall) Context(ctx context.Context) *ProjectsLocationsCollectionsEnginesServingConfigsRecommendCall { c.ctx_ = ctx return c } // Header returns an http.Header that can be modified by the caller to // add HTTP headers to the request. -func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineOperationsGetCall) Header() http.Header { +func (c *ProjectsLocationsCollectionsEnginesServingConfigsRecommendCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineOperationsGetCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsCollectionsEnginesServingConfigsRecommendCall) doRequest(alt string) (*http.Response, error) { reqHeaders := make(http.Header) reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) for k, v := range c.header_ { reqHeaders[k] = v } reqHeaders.Set("User-Agent", c.s.userAgent()) - if c.ifNoneMatch_ != "" { - reqHeaders.Set("If-None-Match", c.ifNoneMatch_) - } var body io.Reader = nil + body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddiscoveryenginev1betarecommendrequest) + if err != nil { + return nil, err + } + reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+servingConfig}:recommend") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("GET", urls, body) + req, err := http.NewRequest("POST", urls, body) if err != nil { return nil, err } req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ - "name": c.name, + "servingConfig": c.servingConfig, }) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "discoveryengine.projects.locations.collections.dataStores.siteSearchEngine.operations.get" call. -// Exactly one of *GoogleLongrunningOperation or error will be non-nil. -// 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 *ProjectsLocationsCollectionsDataStoresSiteSearchEngineOperationsGetCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { +// Do executes the "discoveryengine.projects.locations.collections.engines.servingConfigs.recommend" call. +// Exactly one of *GoogleCloudDiscoveryengineV1betaRecommendResponse or +// error will be non-nil. Any non-2xx status code is an error. Response +// headers are in either +// *GoogleCloudDiscoveryengineV1betaRecommendResponse.ServerResponse.Head +// er 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 *ProjectsLocationsCollectionsEnginesServingConfigsRecommendCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1betaRecommendResponse, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -13503,7 +22151,7 @@ func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineOperationsGetCall if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &GoogleLongrunningOperation{ + ret := &GoogleCloudDiscoveryengineV1betaRecommendResponse{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -13515,25 +22163,28 @@ func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineOperationsGetCall } return ret, nil // { - // "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": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/siteSearchEngine/operations/{operationsId}", - // "httpMethod": "GET", - // "id": "discoveryengine.projects.locations.collections.dataStores.siteSearchEngine.operations.get", + // "description": "Makes a recommendation, which requires a contextual user event.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/engines/{enginesId}/servingConfigs/{servingConfigsId}:recommend", + // "httpMethod": "POST", + // "id": "discoveryengine.projects.locations.collections.engines.servingConfigs.recommend", // "parameterOrder": [ - // "name" + // "servingConfig" // ], // "parameters": { - // "name": { - // "description": "The name of the operation resource.", + // "servingConfig": { + // "description": "Required. Full resource name of a ServingConfig: `projects/*/locations/global/collections/*/engines/*/servingConfigs/*`, or `projects/*/locations/global/collections/*/dataStores/*/servingConfigs/*` One default serving config is created along with your recommendation engine creation. The engine ID will be used as the ID of the default serving config. For example, for Engine `projects/*/locations/global/collections/*/engines/my-engine`, you can use `projects/*/locations/global/collections/*/engines/my-engine/servingConfigs/my-engine` for your RecommendationService.Recommend requests.", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/siteSearchEngine/operations/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/engines/[^/]+/servingConfigs/[^/]+$", // "required": true, // "type": "string" // } // }, - // "path": "v1beta/{+name}", + // "path": "v1beta/{+servingConfig}:recommend", + // "request": { + // "$ref": "GoogleCloudDiscoveryengineV1betaRecommendRequest" + // }, // "response": { - // "$ref": "GoogleLongrunningOperation" + // "$ref": "GoogleCloudDiscoveryengineV1betaRecommendResponse" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -13542,119 +22193,97 @@ func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineOperationsGetCall } -// method id "discoveryengine.projects.locations.collections.dataStores.siteSearchEngine.operations.list": +// method id "discoveryengine.projects.locations.collections.engines.servingConfigs.search": -type ProjectsLocationsCollectionsDataStoresSiteSearchEngineOperationsListCall struct { - s *Service - name string - urlParams_ gensupport.URLParams - ifNoneMatch_ string - ctx_ context.Context - header_ http.Header +type ProjectsLocationsCollectionsEnginesServingConfigsSearchCall struct { + s *Service + servingConfig string + googleclouddiscoveryenginev1betasearchrequest *GoogleCloudDiscoveryengineV1betaSearchRequest + urlParams_ gensupport.URLParams + 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`. +// Search: Performs a search. // -// - name: The name of the operation's parent resource. -func (r *ProjectsLocationsCollectionsDataStoresSiteSearchEngineOperationsService) List(name string) *ProjectsLocationsCollectionsDataStoresSiteSearchEngineOperationsListCall { - c := &ProjectsLocationsCollectionsDataStoresSiteSearchEngineOperationsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.name = name - return c -} - -// Filter sets the optional parameter "filter": The standard list -// filter. -func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineOperationsListCall) Filter(filter string) *ProjectsLocationsCollectionsDataStoresSiteSearchEngineOperationsListCall { - c.urlParams_.Set("filter", filter) - return c -} - -// PageSize sets the optional parameter "pageSize": The standard list -// page size. -func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineOperationsListCall) PageSize(pageSize int64) *ProjectsLocationsCollectionsDataStoresSiteSearchEngineOperationsListCall { - c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) - return c -} - -// PageToken sets the optional parameter "pageToken": The standard list -// page token. -func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineOperationsListCall) PageToken(pageToken string) *ProjectsLocationsCollectionsDataStoresSiteSearchEngineOperationsListCall { - c.urlParams_.Set("pageToken", pageToken) +// - servingConfig: The resource name of the Search serving config, such +// as +// `projects/*/locations/global/collections/default_collection/engines/ +// */servingConfigs/default_serving_config`, or +// `projects/*/locations/global/collections/default_collection/dataStor +// es/default_data_store/servingConfigs/default_serving_config`. This +// field is used to identify the serving configuration name, set of +// models used to make the search. +func (r *ProjectsLocationsCollectionsEnginesServingConfigsService) Search(servingConfig string, googleclouddiscoveryenginev1betasearchrequest *GoogleCloudDiscoveryengineV1betaSearchRequest) *ProjectsLocationsCollectionsEnginesServingConfigsSearchCall { + c := &ProjectsLocationsCollectionsEnginesServingConfigsSearchCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.servingConfig = servingConfig + c.googleclouddiscoveryenginev1betasearchrequest = googleclouddiscoveryenginev1betasearchrequest return c } // Fields allows partial responses to be retrieved. See // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse // for more information. -func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineOperationsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresSiteSearchEngineOperationsListCall { +func (c *ProjectsLocationsCollectionsEnginesServingConfigsSearchCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsEnginesServingConfigsSearchCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// IfNoneMatch sets the 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. Use googleapi.IsNotModified to check whether the response -// error from Do is the result of In-None-Match. -func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineOperationsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsCollectionsDataStoresSiteSearchEngineOperationsListCall { - c.ifNoneMatch_ = entityTag - return c -} - // Context sets the context to be used in this call's Do method. Any // pending HTTP request will be aborted if the provided context is // canceled. -func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineOperationsListCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresSiteSearchEngineOperationsListCall { +func (c *ProjectsLocationsCollectionsEnginesServingConfigsSearchCall) Context(ctx context.Context) *ProjectsLocationsCollectionsEnginesServingConfigsSearchCall { c.ctx_ = ctx return c } // Header returns an http.Header that can be modified by the caller to // add HTTP headers to the request. -func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineOperationsListCall) Header() http.Header { +func (c *ProjectsLocationsCollectionsEnginesServingConfigsSearchCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineOperationsListCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsCollectionsEnginesServingConfigsSearchCall) doRequest(alt string) (*http.Response, error) { reqHeaders := make(http.Header) reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) for k, v := range c.header_ { reqHeaders[k] = v } reqHeaders.Set("User-Agent", c.s.userAgent()) - if c.ifNoneMatch_ != "" { - reqHeaders.Set("If-None-Match", c.ifNoneMatch_) - } var body io.Reader = nil + body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddiscoveryenginev1betasearchrequest) + if err != nil { + return nil, err + } + reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}/operations") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+servingConfig}:search") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("GET", urls, body) + req, err := http.NewRequest("POST", urls, body) if err != nil { return nil, err } req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ - "name": c.name, + "servingConfig": c.servingConfig, }) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "discoveryengine.projects.locations.collections.dataStores.siteSearchEngine.operations.list" call. -// Exactly one of *GoogleLongrunningListOperationsResponse or error will -// be non-nil. Any non-2xx status code is an error. Response headers are -// in either -// *GoogleLongrunningListOperationsResponse.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 *ProjectsLocationsCollectionsDataStoresSiteSearchEngineOperationsListCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningListOperationsResponse, error) { +// Do executes the "discoveryengine.projects.locations.collections.engines.servingConfigs.search" call. +// Exactly one of *GoogleCloudDiscoveryengineV1betaSearchResponse or +// error will be non-nil. Any non-2xx status code is an error. Response +// headers are in either +// *GoogleCloudDiscoveryengineV1betaSearchResponse.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 *ProjectsLocationsCollectionsEnginesServingConfigsSearchCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1betaSearchResponse, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -13673,7 +22302,7 @@ func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineOperationsListCal if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &GoogleLongrunningListOperationsResponse{ + ret := &GoogleCloudDiscoveryengineV1betaSearchResponse{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -13685,41 +22314,28 @@ func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineOperationsListCal } return ret, nil // { - // "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`.", - // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/siteSearchEngine/operations", - // "httpMethod": "GET", - // "id": "discoveryengine.projects.locations.collections.dataStores.siteSearchEngine.operations.list", + // "description": "Performs a search.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/engines/{enginesId}/servingConfigs/{servingConfigsId}:search", + // "httpMethod": "POST", + // "id": "discoveryengine.projects.locations.collections.engines.servingConfigs.search", // "parameterOrder": [ - // "name" + // "servingConfig" // ], // "parameters": { - // "filter": { - // "description": "The standard list filter.", - // "location": "query", - // "type": "string" - // }, - // "name": { - // "description": "The name of the operation's parent resource.", + // "servingConfig": { + // "description": "Required. The resource name of the Search serving config, such as `projects/*/locations/global/collections/default_collection/engines/*/servingConfigs/default_serving_config`, or `projects/*/locations/global/collections/default_collection/dataStores/default_data_store/servingConfigs/default_serving_config`. This field is used to identify the serving configuration name, set of models used to make the search.", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/siteSearchEngine$", + // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/engines/[^/]+/servingConfigs/[^/]+$", // "required": true, // "type": "string" - // }, - // "pageSize": { - // "description": "The standard list page size.", - // "format": "int32", - // "location": "query", - // "type": "integer" - // }, - // "pageToken": { - // "description": "The standard list page token.", - // "location": "query", - // "type": "string" // } // }, - // "path": "v1beta/{+name}/operations", + // "path": "v1beta/{+servingConfig}:search", + // "request": { + // "$ref": "GoogleCloudDiscoveryengineV1betaSearchRequest" + // }, // "response": { - // "$ref": "GoogleLongrunningListOperationsResponse" + // "$ref": "GoogleCloudDiscoveryengineV1betaSearchResponse" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -13731,9 +22347,9 @@ func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineOperationsListCal // 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 *ProjectsLocationsCollectionsDataStoresSiteSearchEngineOperationsListCall) Pages(ctx context.Context, f func(*GoogleLongrunningListOperationsResponse) error) error { +func (c *ProjectsLocationsCollectionsEnginesServingConfigsSearchCall) Pages(ctx context.Context, f func(*GoogleCloudDiscoveryengineV1betaSearchResponse) error) error { c.ctx_ = ctx - defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point + defer func(pt string) { c.googleclouddiscoveryenginev1betasearchrequest.PageToken = pt }(c.googleclouddiscoveryenginev1betasearchrequest.PageToken) // reset paging to original point for { x, err := c.Do() if err != nil { @@ -13745,13 +22361,13 @@ func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineOperationsListCal if x.NextPageToken == "" { return nil } - c.PageToken(x.NextPageToken) + c.googleclouddiscoveryenginev1betasearchrequest.PageToken = x.NextPageToken } } -// method id "discoveryengine.projects.locations.collections.dataStores.siteSearchEngine.targetSites.operations.get": +// method id "discoveryengine.projects.locations.collections.operations.get": -type ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesOperationsGetCall struct { +type ProjectsLocationsCollectionsOperationsGetCall struct { s *Service name string urlParams_ gensupport.URLParams @@ -13765,8 +22381,8 @@ type ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesOperations // recommended by the API service. // // - name: The name of the operation resource. -func (r *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesOperationsService) Get(name string) *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesOperationsGetCall { - c := &ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesOperationsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} +func (r *ProjectsLocationsCollectionsOperationsService) Get(name string) *ProjectsLocationsCollectionsOperationsGetCall { + c := &ProjectsLocationsCollectionsOperationsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.name = name return c } @@ -13774,7 +22390,7 @@ func (r *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesOperat // Fields allows partial responses to be retrieved. See // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse // for more information. -func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesOperationsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesOperationsGetCall { +func (c *ProjectsLocationsCollectionsOperationsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsOperationsGetCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } @@ -13784,7 +22400,7 @@ func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesOperat // getting updates only after the object has changed since the last // request. Use googleapi.IsNotModified to check whether the response // error from Do is the result of In-None-Match. -func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesOperationsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesOperationsGetCall { +func (c *ProjectsLocationsCollectionsOperationsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsCollectionsOperationsGetCall { c.ifNoneMatch_ = entityTag return c } @@ -13792,21 +22408,21 @@ func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesOperat // Context sets the context to be used in this call's Do method. Any // pending HTTP request will be aborted if the provided context is // canceled. -func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesOperationsGetCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesOperationsGetCall { +func (c *ProjectsLocationsCollectionsOperationsGetCall) Context(ctx context.Context) *ProjectsLocationsCollectionsOperationsGetCall { c.ctx_ = ctx return c } // Header returns an http.Header that can be modified by the caller to // add HTTP headers to the request. -func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesOperationsGetCall) Header() http.Header { +func (c *ProjectsLocationsCollectionsOperationsGetCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesOperationsGetCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsCollectionsOperationsGetCall) doRequest(alt string) (*http.Response, error) { reqHeaders := make(http.Header) reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) for k, v := range c.header_ { @@ -13832,14 +22448,14 @@ func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesOperat return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "discoveryengine.projects.locations.collections.dataStores.siteSearchEngine.targetSites.operations.get" call. +// Do executes the "discoveryengine.projects.locations.collections.operations.get" call. // Exactly one of *GoogleLongrunningOperation or error will be non-nil. // 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 *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesOperationsGetCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { +func (c *ProjectsLocationsCollectionsOperationsGetCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -13871,9 +22487,9 @@ func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesOperat return ret, nil // { // "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": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/siteSearchEngine/targetSites/operations/{operationsId}", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/operations/{operationsId}", // "httpMethod": "GET", - // "id": "discoveryengine.projects.locations.collections.dataStores.siteSearchEngine.targetSites.operations.get", + // "id": "discoveryengine.projects.locations.collections.operations.get", // "parameterOrder": [ // "name" // ], @@ -13881,7 +22497,7 @@ func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesOperat // "name": { // "description": "The name of the operation resource.", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/siteSearchEngine/targetSites/operations/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/operations/[^/]+$", // "required": true, // "type": "string" // } @@ -13897,9 +22513,9 @@ func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesOperat } -// method id "discoveryengine.projects.locations.collections.dataStores.siteSearchEngine.targetSites.operations.list": +// method id "discoveryengine.projects.locations.collections.operations.list": -type ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesOperationsListCall struct { +type ProjectsLocationsCollectionsOperationsListCall struct { s *Service name string urlParams_ gensupport.URLParams @@ -13913,29 +22529,29 @@ type ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesOperations // `UNIMPLEMENTED`. // // - name: The name of the operation's parent resource. -func (r *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesOperationsService) List(name string) *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesOperationsListCall { - c := &ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesOperationsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} +func (r *ProjectsLocationsCollectionsOperationsService) List(name string) *ProjectsLocationsCollectionsOperationsListCall { + c := &ProjectsLocationsCollectionsOperationsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.name = name return c } // Filter sets the optional parameter "filter": The standard list // filter. -func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesOperationsListCall) Filter(filter string) *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesOperationsListCall { +func (c *ProjectsLocationsCollectionsOperationsListCall) Filter(filter string) *ProjectsLocationsCollectionsOperationsListCall { c.urlParams_.Set("filter", filter) return c } // PageSize sets the optional parameter "pageSize": The standard list // page size. -func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesOperationsListCall) PageSize(pageSize int64) *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesOperationsListCall { +func (c *ProjectsLocationsCollectionsOperationsListCall) PageSize(pageSize int64) *ProjectsLocationsCollectionsOperationsListCall { c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) return c } // PageToken sets the optional parameter "pageToken": The standard list // page token. -func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesOperationsListCall) PageToken(pageToken string) *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesOperationsListCall { +func (c *ProjectsLocationsCollectionsOperationsListCall) PageToken(pageToken string) *ProjectsLocationsCollectionsOperationsListCall { c.urlParams_.Set("pageToken", pageToken) return c } @@ -13943,7 +22559,7 @@ func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesOperat // Fields allows partial responses to be retrieved. See // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse // for more information. -func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesOperationsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesOperationsListCall { +func (c *ProjectsLocationsCollectionsOperationsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsOperationsListCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } @@ -13953,7 +22569,7 @@ func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesOperat // getting updates only after the object has changed since the last // request. Use googleapi.IsNotModified to check whether the response // error from Do is the result of In-None-Match. -func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesOperationsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesOperationsListCall { +func (c *ProjectsLocationsCollectionsOperationsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsCollectionsOperationsListCall { c.ifNoneMatch_ = entityTag return c } @@ -13961,21 +22577,21 @@ func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesOperat // Context sets the context to be used in this call's Do method. Any // pending HTTP request will be aborted if the provided context is // canceled. -func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesOperationsListCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesOperationsListCall { +func (c *ProjectsLocationsCollectionsOperationsListCall) Context(ctx context.Context) *ProjectsLocationsCollectionsOperationsListCall { c.ctx_ = ctx return c } // Header returns an http.Header that can be modified by the caller to // add HTTP headers to the request. -func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesOperationsListCall) Header() http.Header { +func (c *ProjectsLocationsCollectionsOperationsListCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesOperationsListCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsCollectionsOperationsListCall) doRequest(alt string) (*http.Response, error) { reqHeaders := make(http.Header) reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) for k, v := range c.header_ { @@ -14001,7 +22617,7 @@ func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesOperat return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "discoveryengine.projects.locations.collections.dataStores.siteSearchEngine.targetSites.operations.list" call. +// Do executes the "discoveryengine.projects.locations.collections.operations.list" call. // Exactly one of *GoogleLongrunningListOperationsResponse or error will // be non-nil. Any non-2xx status code is an error. Response headers are // in either @@ -14009,7 +22625,7 @@ func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesOperat // 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 *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesOperationsListCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningListOperationsResponse, error) { +func (c *ProjectsLocationsCollectionsOperationsListCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningListOperationsResponse, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -14041,9 +22657,9 @@ func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesOperat return ret, nil // { // "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`.", - // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/siteSearchEngine/targetSites/operations", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/operations", // "httpMethod": "GET", - // "id": "discoveryengine.projects.locations.collections.dataStores.siteSearchEngine.targetSites.operations.list", + // "id": "discoveryengine.projects.locations.collections.operations.list", // "parameterOrder": [ // "name" // ], @@ -14056,7 +22672,7 @@ func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesOperat // "name": { // "description": "The name of the operation's parent resource.", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/siteSearchEngine/targetSites$", + // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+$", // "required": true, // "type": "string" // }, @@ -14086,7 +22702,7 @@ func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesOperat // 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 *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesOperationsListCall) Pages(ctx context.Context, f func(*GoogleLongrunningListOperationsResponse) error) error { +func (c *ProjectsLocationsCollectionsOperationsListCall) Pages(ctx context.Context, f func(*GoogleLongrunningListOperationsResponse) error) error { c.ctx_ = ctx defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point for { @@ -14099,240 +22715,155 @@ func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineTargetSitesOperat } if x.NextPageToken == "" { return nil - } - c.PageToken(x.NextPageToken) - } -} - -// method id "discoveryengine.projects.locations.collections.dataStores.suggestionDenyListEntries.import": - -type ProjectsLocationsCollectionsDataStoresSuggestionDenyListEntriesImportCall struct { - s *Service - parent string - googleclouddiscoveryenginev1betaimportsuggestiondenylistentriesrequest *GoogleCloudDiscoveryengineV1betaImportSuggestionDenyListEntriesRequest - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header -} - -// Import: Imports all SuggestionDenyListEntry for a DataStore. -// -// - parent: The parent data store resource name for which to import -// denylist entries. Follows pattern -// projects/*/locations/*/collections/*/dataStores/*. -func (r *ProjectsLocationsCollectionsDataStoresSuggestionDenyListEntriesService) Import(parent string, googleclouddiscoveryenginev1betaimportsuggestiondenylistentriesrequest *GoogleCloudDiscoveryengineV1betaImportSuggestionDenyListEntriesRequest) *ProjectsLocationsCollectionsDataStoresSuggestionDenyListEntriesImportCall { - c := &ProjectsLocationsCollectionsDataStoresSuggestionDenyListEntriesImportCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.parent = parent - c.googleclouddiscoveryenginev1betaimportsuggestiondenylistentriesrequest = googleclouddiscoveryenginev1betaimportsuggestiondenylistentriesrequest - return c -} - -// Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. -func (c *ProjectsLocationsCollectionsDataStoresSuggestionDenyListEntriesImportCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresSuggestionDenyListEntriesImportCall { - c.urlParams_.Set("fields", googleapi.CombineFields(s)) - return c -} - -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. -func (c *ProjectsLocationsCollectionsDataStoresSuggestionDenyListEntriesImportCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresSuggestionDenyListEntriesImportCall { - c.ctx_ = ctx - return c -} - -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. -func (c *ProjectsLocationsCollectionsDataStoresSuggestionDenyListEntriesImportCall) Header() http.Header { - if c.header_ == nil { - c.header_ = make(http.Header) - } - return c.header_ -} - -func (c *ProjectsLocationsCollectionsDataStoresSuggestionDenyListEntriesImportCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) - var body io.Reader = nil - body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddiscoveryenginev1betaimportsuggestiondenylistentriesrequest) - if err != nil { - return nil, err - } - reqHeaders.Set("Content-Type", "application/json") - c.urlParams_.Set("alt", alt) - c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+parent}/suggestionDenyListEntries:import") - urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("POST", urls, body) - if err != nil { - return nil, err - } - req.Header = reqHeaders - googleapi.Expand(req.URL, map[string]string{ - "parent": c.parent, - }) - return gensupport.SendRequest(c.ctx_, c.s.client, req) -} - -// Do executes the "discoveryengine.projects.locations.collections.dataStores.suggestionDenyListEntries.import" call. -// Exactly one of *GoogleLongrunningOperation or error will be non-nil. -// 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 *ProjectsLocationsCollectionsDataStoresSuggestionDenyListEntriesImportCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { - gensupport.SetOptions(c.urlParams_, opts...) - res, err := c.doRequest("json") - if res != nil && res.StatusCode == http.StatusNotModified { - if res.Body != nil { - res.Body.Close() - } - return nil, gensupport.WrapError(&googleapi.Error{ - Code: res.StatusCode, - Header: res.Header, - }) - } - if err != nil { - return nil, err - } - defer googleapi.CloseBody(res) - if err := googleapi.CheckResponse(res); err != nil { - return nil, gensupport.WrapError(err) - } - ret := &GoogleLongrunningOperation{ - ServerResponse: googleapi.ServerResponse{ - Header: res.Header, - HTTPStatusCode: res.StatusCode, - }, - } - target := &ret - if err := gensupport.DecodeResponse(target, res); err != nil { - return nil, err - } - return ret, nil - // { - // "description": "Imports all SuggestionDenyListEntry for a DataStore.", - // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/suggestionDenyListEntries:import", - // "httpMethod": "POST", - // "id": "discoveryengine.projects.locations.collections.dataStores.suggestionDenyListEntries.import", - // "parameterOrder": [ - // "parent" - // ], - // "parameters": { - // "parent": { - // "description": "Required. The parent data store resource name for which to import denylist entries. Follows pattern projects/*/locations/*/collections/*/dataStores/*.", - // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+$", - // "required": true, - // "type": "string" - // } - // }, - // "path": "v1beta/{+parent}/suggestionDenyListEntries:import", - // "request": { - // "$ref": "GoogleCloudDiscoveryengineV1betaImportSuggestionDenyListEntriesRequest" - // }, - // "response": { - // "$ref": "GoogleLongrunningOperation" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform" - // ] - // } - + } + c.PageToken(x.NextPageToken) + } } -// method id "discoveryengine.projects.locations.collections.dataStores.suggestionDenyListEntries.purge": +// method id "discoveryengine.projects.locations.dataStores.completeQuery": -type ProjectsLocationsCollectionsDataStoresSuggestionDenyListEntriesPurgeCall struct { - s *Service - parent string - googleclouddiscoveryenginev1betapurgesuggestiondenylistentriesrequest *GoogleCloudDiscoveryengineV1betaPurgeSuggestionDenyListEntriesRequest - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +type ProjectsLocationsDataStoresCompleteQueryCall struct { + s *Service + dataStore string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header } -// Purge: Permanently deletes all SuggestionDenyListEntry for a -// DataStore. +// CompleteQuery: Completes the specified user input with keyword +// suggestions. // -// - parent: The parent data store resource name for which to import -// denylist entries. Follows pattern -// projects/*/locations/*/collections/*/dataStores/*. -func (r *ProjectsLocationsCollectionsDataStoresSuggestionDenyListEntriesService) Purge(parent string, googleclouddiscoveryenginev1betapurgesuggestiondenylistentriesrequest *GoogleCloudDiscoveryengineV1betaPurgeSuggestionDenyListEntriesRequest) *ProjectsLocationsCollectionsDataStoresSuggestionDenyListEntriesPurgeCall { - c := &ProjectsLocationsCollectionsDataStoresSuggestionDenyListEntriesPurgeCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.parent = parent - c.googleclouddiscoveryenginev1betapurgesuggestiondenylistentriesrequest = googleclouddiscoveryenginev1betapurgesuggestiondenylistentriesrequest +// - dataStore: The parent data store resource name for which the +// completion is performed, such as +// `projects/*/locations/global/collections/default_collection/dataStor +// es/default_data_store`. +func (r *ProjectsLocationsDataStoresService) CompleteQuery(dataStore string) *ProjectsLocationsDataStoresCompleteQueryCall { + c := &ProjectsLocationsDataStoresCompleteQueryCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.dataStore = dataStore + return c +} + +// IncludeTailSuggestions sets the optional parameter +// "includeTailSuggestions": Indicates if tail suggestions should be +// returned if there are no suggestions that match the full query. Even +// if set to true, if there are suggestions that match the full query, +// those are returned and no tail suggestions are returned. +func (c *ProjectsLocationsDataStoresCompleteQueryCall) IncludeTailSuggestions(includeTailSuggestions bool) *ProjectsLocationsDataStoresCompleteQueryCall { + c.urlParams_.Set("includeTailSuggestions", fmt.Sprint(includeTailSuggestions)) + return c +} + +// Query sets the optional parameter "query": Required. The typeahead +// input used to fetch suggestions. Maximum length is 128 characters. +func (c *ProjectsLocationsDataStoresCompleteQueryCall) Query(query string) *ProjectsLocationsDataStoresCompleteQueryCall { + c.urlParams_.Set("query", query) + return c +} + +// QueryModel sets the optional parameter "queryModel": Specifies the +// autocomplete data model. This overrides any model specified in the +// Configuration > Autocomplete section of the Cloud console. Currently +// supported values: * `document` - Using suggestions generated from +// user-imported documents. * `search-history` - Using suggestions +// generated from the past history of SearchService.Search API calls. Do +// not use it when there is no traffic for Search API. * `user-event` - +// Using suggestions generated from user-imported search events. * +// `document-completable` - Using suggestions taken directly from +// user-imported document fields marked as completable. Default values: +// * `document` is the default model for regular dataStores. * +// `search-history` is the default model for site search dataStores. +func (c *ProjectsLocationsDataStoresCompleteQueryCall) QueryModel(queryModel string) *ProjectsLocationsDataStoresCompleteQueryCall { + c.urlParams_.Set("queryModel", queryModel) + return c +} + +// UserPseudoId sets the optional parameter "userPseudoId": A unique +// identifier for tracking visitors. For example, this could be +// implemented with an HTTP cookie, which should be able to uniquely +// identify a visitor on a single device. This unique identifier should +// not change if the visitor logs in or out of the website. This field +// should NOT have a fixed value such as `unknown_visitor`. This should +// be the same identifier as UserEvent.user_pseudo_id and +// SearchRequest.user_pseudo_id. The field must be a UTF-8 encoded +// string with a length limit of 128 characters. Otherwise, an +// `INVALID_ARGUMENT` error is returned. +func (c *ProjectsLocationsDataStoresCompleteQueryCall) UserPseudoId(userPseudoId string) *ProjectsLocationsDataStoresCompleteQueryCall { + c.urlParams_.Set("userPseudoId", userPseudoId) return c } // Fields allows partial responses to be retrieved. See // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse // for more information. -func (c *ProjectsLocationsCollectionsDataStoresSuggestionDenyListEntriesPurgeCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresSuggestionDenyListEntriesPurgeCall { +func (c *ProjectsLocationsDataStoresCompleteQueryCall) Fields(s ...googleapi.Field) *ProjectsLocationsDataStoresCompleteQueryCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } +// IfNoneMatch sets the 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. Use googleapi.IsNotModified to check whether the response +// error from Do is the result of In-None-Match. +func (c *ProjectsLocationsDataStoresCompleteQueryCall) IfNoneMatch(entityTag string) *ProjectsLocationsDataStoresCompleteQueryCall { + c.ifNoneMatch_ = entityTag + return c +} + // Context sets the context to be used in this call's Do method. Any // pending HTTP request will be aborted if the provided context is // canceled. -func (c *ProjectsLocationsCollectionsDataStoresSuggestionDenyListEntriesPurgeCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresSuggestionDenyListEntriesPurgeCall { +func (c *ProjectsLocationsDataStoresCompleteQueryCall) Context(ctx context.Context) *ProjectsLocationsDataStoresCompleteQueryCall { c.ctx_ = ctx return c } // Header returns an http.Header that can be modified by the caller to // add HTTP headers to the request. -func (c *ProjectsLocationsCollectionsDataStoresSuggestionDenyListEntriesPurgeCall) Header() http.Header { +func (c *ProjectsLocationsDataStoresCompleteQueryCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsCollectionsDataStoresSuggestionDenyListEntriesPurgeCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsDataStoresCompleteQueryCall) doRequest(alt string) (*http.Response, error) { reqHeaders := make(http.Header) reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) for k, v := range c.header_ { reqHeaders[k] = v } reqHeaders.Set("User-Agent", c.s.userAgent()) - var body io.Reader = nil - body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddiscoveryenginev1betapurgesuggestiondenylistentriesrequest) - if err != nil { - return nil, err + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) } - reqHeaders.Set("Content-Type", "application/json") + var body io.Reader = nil c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+parent}/suggestionDenyListEntries:purge") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+dataStore}:completeQuery") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("POST", urls, body) + req, err := http.NewRequest("GET", urls, body) if err != nil { return nil, err } req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ - "parent": c.parent, + "dataStore": c.dataStore, }) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "discoveryengine.projects.locations.collections.dataStores.suggestionDenyListEntries.purge" call. -// Exactly one of *GoogleLongrunningOperation or error will be non-nil. -// 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 *ProjectsLocationsCollectionsDataStoresSuggestionDenyListEntriesPurgeCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { +// Do executes the "discoveryengine.projects.locations.dataStores.completeQuery" call. +// Exactly one of *GoogleCloudDiscoveryengineV1betaCompleteQueryResponse +// or error will be non-nil. Any non-2xx status code is an error. +// Response headers are in either +// *GoogleCloudDiscoveryengineV1betaCompleteQueryResponse.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 *ProjectsLocationsDataStoresCompleteQueryCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1betaCompleteQueryResponse, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -14351,7 +22882,7 @@ func (c *ProjectsLocationsCollectionsDataStoresSuggestionDenyListEntriesPurgeCal if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &GoogleLongrunningOperation{ + ret := &GoogleCloudDiscoveryengineV1betaCompleteQueryResponse{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -14363,28 +22894,45 @@ func (c *ProjectsLocationsCollectionsDataStoresSuggestionDenyListEntriesPurgeCal } return ret, nil // { - // "description": "Permanently deletes all SuggestionDenyListEntry for a DataStore.", - // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/suggestionDenyListEntries:purge", - // "httpMethod": "POST", - // "id": "discoveryengine.projects.locations.collections.dataStores.suggestionDenyListEntries.purge", + // "description": "Completes the specified user input with keyword suggestions.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}:completeQuery", + // "httpMethod": "GET", + // "id": "discoveryengine.projects.locations.dataStores.completeQuery", // "parameterOrder": [ - // "parent" + // "dataStore" // ], // "parameters": { - // "parent": { - // "description": "Required. The parent data store resource name for which to import denylist entries. Follows pattern projects/*/locations/*/collections/*/dataStores/*.", + // "dataStore": { + // "description": "Required. The parent data store resource name for which the completion is performed, such as `projects/*/locations/global/collections/default_collection/dataStores/default_data_store`.", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/dataStores/[^/]+$", // "required": true, // "type": "string" + // }, + // "includeTailSuggestions": { + // "description": "Indicates if tail suggestions should be returned if there are no suggestions that match the full query. Even if set to true, if there are suggestions that match the full query, those are returned and no tail suggestions are returned.", + // "location": "query", + // "type": "boolean" + // }, + // "query": { + // "description": "Required. The typeahead input used to fetch suggestions. Maximum length is 128 characters.", + // "location": "query", + // "type": "string" + // }, + // "queryModel": { + // "description": "Specifies the autocomplete data model. This overrides any model specified in the Configuration \u003e Autocomplete section of the Cloud console. Currently supported values: * `document` - Using suggestions generated from user-imported documents. * `search-history` - Using suggestions generated from the past history of SearchService.Search API calls. Do not use it when there is no traffic for Search API. * `user-event` - Using suggestions generated from user-imported search events. * `document-completable` - Using suggestions taken directly from user-imported document fields marked as completable. Default values: * `document` is the default model for regular dataStores. * `search-history` is the default model for site search dataStores.", + // "location": "query", + // "type": "string" + // }, + // "userPseudoId": { + // "description": "A unique identifier for tracking visitors. For example, this could be implemented with an HTTP cookie, which should be able to uniquely identify a visitor on a single device. This unique identifier should not change if the visitor logs in or out of the website. This field should NOT have a fixed value such as `unknown_visitor`. This should be the same identifier as UserEvent.user_pseudo_id and SearchRequest.user_pseudo_id. The field must be a UTF-8 encoded string with a length limit of 128 characters. Otherwise, an `INVALID_ARGUMENT` error is returned.", + // "location": "query", + // "type": "string" // } // }, - // "path": "v1beta/{+parent}/suggestionDenyListEntries:purge", - // "request": { - // "$ref": "GoogleCloudDiscoveryengineV1betaPurgeSuggestionDenyListEntriesRequest" - // }, + // "path": "v1beta/{+dataStore}:completeQuery", // "response": { - // "$ref": "GoogleLongrunningOperation" + // "$ref": "GoogleCloudDiscoveryengineV1betaCompleteQueryResponse" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -14393,107 +22941,93 @@ func (c *ProjectsLocationsCollectionsDataStoresSuggestionDenyListEntriesPurgeCal } -// method id "discoveryengine.projects.locations.collections.dataStores.userEvents.collect": +// method id "discoveryengine.projects.locations.dataStores.create": -type ProjectsLocationsCollectionsDataStoresUserEventsCollectCall struct { - s *Service - parent string - urlParams_ gensupport.URLParams - ifNoneMatch_ string - ctx_ context.Context - header_ http.Header +type ProjectsLocationsDataStoresCreateCall struct { + s *Service + parent string + googleclouddiscoveryenginev1betadatastore *GoogleCloudDiscoveryengineV1betaDataStore + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// Collect: Writes a single user event from the browser. This uses a GET -// request to due to browser restriction of POST-ing to a third-party -// domain. This method is used only by the Discovery Engine API -// JavaScript pixel and Google Tag Manager. Users should not call this -// method directly. +// Create: Creates a DataStore. DataStore is for storing Documents. To +// serve these documents for Search, or Recommendation use case, an +// Engine needs to be created separately. // -// - parent: The parent DataStore resource name, such as -// `projects/{project}/locations/{location}/collections/{collection}/da -// taStores/{data_store}`. -func (r *ProjectsLocationsCollectionsDataStoresUserEventsService) Collect(parent string) *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall { - c := &ProjectsLocationsCollectionsDataStoresUserEventsCollectCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// - parent: The parent resource name, such as +// `projects/{project}/locations/{location}/collections/{collection}`. +func (r *ProjectsLocationsDataStoresService) Create(parent string, googleclouddiscoveryenginev1betadatastore *GoogleCloudDiscoveryengineV1betaDataStore) *ProjectsLocationsDataStoresCreateCall { + c := &ProjectsLocationsDataStoresCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.parent = parent + c.googleclouddiscoveryenginev1betadatastore = googleclouddiscoveryenginev1betadatastore return c } -// Ets sets the optional parameter "ets": The event timestamp in -// milliseconds. This prevents browser caching of otherwise identical -// get requests. The name is abbreviated to reduce the payload bytes. -func (c *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall) Ets(ets int64) *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall { - c.urlParams_.Set("ets", fmt.Sprint(ets)) - return c -} - -// Uri sets the optional parameter "uri": The URL including -// cgi-parameters but excluding the hash fragment with a length limit of -// 5,000 characters. This is often more useful than the referer URL, -// because many browsers only send the domain for third-party requests. -func (c *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall) Uri(uri string) *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall { - c.urlParams_.Set("uri", uri) +// CreateAdvancedSiteSearch sets the optional parameter +// "createAdvancedSiteSearch": A boolean flag indicating whether user +// want to directly create an advanced data store for site search. If +// the data store is not configured as site search (GENERIC vertical and +// PUBLIC_WEBSITE content_config), this flag will be ignored. +func (c *ProjectsLocationsDataStoresCreateCall) CreateAdvancedSiteSearch(createAdvancedSiteSearch bool) *ProjectsLocationsDataStoresCreateCall { + c.urlParams_.Set("createAdvancedSiteSearch", fmt.Sprint(createAdvancedSiteSearch)) return c } -// UserEvent sets the optional parameter "userEvent": Required. URL -// encoded UserEvent proto with a length limit of 2,000,000 characters. -func (c *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall) UserEvent(userEvent string) *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall { - c.urlParams_.Set("userEvent", userEvent) +// DataStoreId sets the optional parameter "dataStoreId": Required. The +// ID to use for the DataStore, which will become the final component of +// the DataStore's resource name. This field must conform to RFC-1034 +// (https://tools.ietf.org/html/rfc1034) standard with a length limit of +// 63 characters. Otherwise, an INVALID_ARGUMENT error is returned. +func (c *ProjectsLocationsDataStoresCreateCall) DataStoreId(dataStoreId string) *ProjectsLocationsDataStoresCreateCall { + c.urlParams_.Set("dataStoreId", dataStoreId) return c } // Fields allows partial responses to be retrieved. See // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse // for more information. -func (c *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall { +func (c *ProjectsLocationsDataStoresCreateCall) Fields(s ...googleapi.Field) *ProjectsLocationsDataStoresCreateCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// IfNoneMatch sets the 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. Use googleapi.IsNotModified to check whether the response -// error from Do is the result of In-None-Match. -func (c *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall) IfNoneMatch(entityTag string) *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall { - c.ifNoneMatch_ = entityTag - return c -} - // Context sets the context to be used in this call's Do method. Any // pending HTTP request will be aborted if the provided context is // canceled. -func (c *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall { +func (c *ProjectsLocationsDataStoresCreateCall) Context(ctx context.Context) *ProjectsLocationsDataStoresCreateCall { c.ctx_ = ctx return c } // Header returns an http.Header that can be modified by the caller to // add HTTP headers to the request. -func (c *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall) Header() http.Header { +func (c *ProjectsLocationsDataStoresCreateCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsDataStoresCreateCall) doRequest(alt string) (*http.Response, error) { reqHeaders := make(http.Header) reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) for k, v := range c.header_ { reqHeaders[k] = v } reqHeaders.Set("User-Agent", c.s.userAgent()) - if c.ifNoneMatch_ != "" { - reqHeaders.Set("If-None-Match", c.ifNoneMatch_) - } var body io.Reader = nil + body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddiscoveryenginev1betadatastore) + if err != nil { + return nil, err + } + reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+parent}/userEvents:collect") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+parent}/dataStores") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("GET", urls, body) + req, err := http.NewRequest("POST", urls, body) if err != nil { return nil, err } @@ -14504,14 +23038,14 @@ func (c *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall) doRequest( return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "discoveryengine.projects.locations.collections.dataStores.userEvents.collect" call. -// Exactly one of *GoogleApiHttpBody or error will be non-nil. Any -// non-2xx status code is an error. Response headers are in either -// *GoogleApiHttpBody.ServerResponse.Header or (if a response was -// returned at all) in error.(*googleapi.Error).Header. Use +// Do executes the "discoveryengine.projects.locations.dataStores.create" call. +// Exactly one of *GoogleLongrunningOperation or error will be non-nil. +// 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 *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall) Do(opts ...googleapi.CallOption) (*GoogleApiHttpBody, error) { +func (c *ProjectsLocationsDataStoresCreateCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -14530,7 +23064,7 @@ func (c *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall) Do(opts .. if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &GoogleApiHttpBody{ + ret := &GoogleLongrunningOperation{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -14542,41 +23076,38 @@ func (c *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall) Do(opts .. } return ret, nil // { - // "description": "Writes a single user event from the browser. This uses a GET request to due to browser restriction of POST-ing to a third-party domain. This method is used only by the Discovery Engine API JavaScript pixel and Google Tag Manager. Users should not call this method directly.", - // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/userEvents:collect", - // "httpMethod": "GET", - // "id": "discoveryengine.projects.locations.collections.dataStores.userEvents.collect", + // "description": "Creates a DataStore. DataStore is for storing Documents. To serve these documents for Search, or Recommendation use case, an Engine needs to be created separately.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores", + // "httpMethod": "POST", + // "id": "discoveryengine.projects.locations.dataStores.create", // "parameterOrder": [ // "parent" // ], // "parameters": { - // "ets": { - // "description": "The event timestamp in milliseconds. This prevents browser caching of otherwise identical get requests. The name is abbreviated to reduce the payload bytes.", - // "format": "int64", + // "createAdvancedSiteSearch": { + // "description": "A boolean flag indicating whether user want to directly create an advanced data store for site search. If the data store is not configured as site search (GENERIC vertical and PUBLIC_WEBSITE content_config), this flag will be ignored.", + // "location": "query", + // "type": "boolean" + // }, + // "dataStoreId": { + // "description": "Required. The ID to use for the DataStore, which will become the final component of the DataStore's resource name. This field must conform to [RFC-1034](https://tools.ietf.org/html/rfc1034) standard with a length limit of 63 characters. Otherwise, an INVALID_ARGUMENT error is returned.", // "location": "query", // "type": "string" // }, // "parent": { - // "description": "Required. The parent DataStore resource name, such as `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}`.", + // "description": "Required. The parent resource name, such as `projects/{project}/locations/{location}/collections/{collection}`.", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+$", // "required": true, // "type": "string" - // }, - // "uri": { - // "description": "The URL including cgi-parameters but excluding the hash fragment with a length limit of 5,000 characters. This is often more useful than the referer URL, because many browsers only send the domain for third-party requests.", - // "location": "query", - // "type": "string" - // }, - // "userEvent": { - // "description": "Required. URL encoded UserEvent proto with a length limit of 2,000,000 characters.", - // "location": "query", - // "type": "string" // } // }, - // "path": "v1beta/{+parent}/userEvents:collect", + // "path": "v1beta/{+parent}/dataStores", + // "request": { + // "$ref": "GoogleCloudDiscoveryengineV1betaDataStore" + // }, // "response": { - // "$ref": "GoogleApiHttpBody" + // "$ref": "GoogleLongrunningOperation" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -14585,38 +23116,34 @@ func (c *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall) Do(opts .. } -// method id "discoveryengine.projects.locations.collections.dataStores.userEvents.import": +// method id "discoveryengine.projects.locations.dataStores.delete": -type ProjectsLocationsCollectionsDataStoresUserEventsImportCall struct { - s *Service - parent string - googleclouddiscoveryenginev1betaimportusereventsrequest *GoogleCloudDiscoveryengineV1betaImportUserEventsRequest - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +type ProjectsLocationsDataStoresDeleteCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// Import: Bulk import of User events. Request processing might be -// synchronous. Events that already exist are skipped. Use this method -// for backfilling historical user events. Operation.response is of type -// ImportResponse. Note that it is possible for a subset of the items to -// be successfully inserted. Operation.metadata is of type -// ImportMetadata. +// Delete: Deletes a DataStore. // -// - parent: Parent DataStore resource name, of the form -// `projects/{project}/locations/{location}/collections/{collection}/da -// taStores/{data_store}`. -func (r *ProjectsLocationsCollectionsDataStoresUserEventsService) Import(parent string, googleclouddiscoveryenginev1betaimportusereventsrequest *GoogleCloudDiscoveryengineV1betaImportUserEventsRequest) *ProjectsLocationsCollectionsDataStoresUserEventsImportCall { - c := &ProjectsLocationsCollectionsDataStoresUserEventsImportCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.parent = parent - c.googleclouddiscoveryenginev1betaimportusereventsrequest = googleclouddiscoveryenginev1betaimportusereventsrequest +// - name: Full resource name of DataStore, such as +// `projects/{project}/locations/{location}/collections/{collection_id} +// /dataStores/{data_store_id}`. If the caller does not have +// permission to delete the DataStore, regardless of whether or not it +// exists, a PERMISSION_DENIED error is returned. If the DataStore to +// delete does not exist, a NOT_FOUND error is returned. +func (r *ProjectsLocationsDataStoresService) Delete(name string) *ProjectsLocationsDataStoresDeleteCall { + c := &ProjectsLocationsDataStoresDeleteCall{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 information. -func (c *ProjectsLocationsCollectionsDataStoresUserEventsImportCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresUserEventsImportCall { +func (c *ProjectsLocationsDataStoresDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsDataStoresDeleteCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } @@ -14624,21 +23151,21 @@ func (c *ProjectsLocationsCollectionsDataStoresUserEventsImportCall) Fields(s .. // Context sets the context to be used in this call's Do method. Any // pending HTTP request will be aborted if the provided context is // canceled. -func (c *ProjectsLocationsCollectionsDataStoresUserEventsImportCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresUserEventsImportCall { +func (c *ProjectsLocationsDataStoresDeleteCall) Context(ctx context.Context) *ProjectsLocationsDataStoresDeleteCall { c.ctx_ = ctx return c } // Header returns an http.Header that can be modified by the caller to // add HTTP headers to the request. -func (c *ProjectsLocationsCollectionsDataStoresUserEventsImportCall) Header() http.Header { +func (c *ProjectsLocationsDataStoresDeleteCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsCollectionsDataStoresUserEventsImportCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsDataStoresDeleteCall) doRequest(alt string) (*http.Response, error) { reqHeaders := make(http.Header) reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) for k, v := range c.header_ { @@ -14646,34 +23173,29 @@ func (c *ProjectsLocationsCollectionsDataStoresUserEventsImportCall) doRequest(a } reqHeaders.Set("User-Agent", c.s.userAgent()) var body io.Reader = nil - body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddiscoveryenginev1betaimportusereventsrequest) - if err != nil { - return nil, err - } - reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+parent}/userEvents:import") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("POST", urls, body) + req, err := http.NewRequest("DELETE", urls, body) if err != nil { return nil, err } req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ - "parent": c.parent, + "name": c.name, }) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "discoveryengine.projects.locations.collections.dataStores.userEvents.import" call. +// Do executes the "discoveryengine.projects.locations.dataStores.delete" call. // Exactly one of *GoogleLongrunningOperation or error will be non-nil. // 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 *ProjectsLocationsCollectionsDataStoresUserEventsImportCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { +func (c *ProjectsLocationsDataStoresDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -14704,26 +23226,23 @@ func (c *ProjectsLocationsCollectionsDataStoresUserEventsImportCall) Do(opts ... } return ret, nil // { - // "description": "Bulk import of User events. Request processing might be synchronous. Events that already exist are skipped. Use this method for backfilling historical user events. Operation.response is of type ImportResponse. Note that it is possible for a subset of the items to be successfully inserted. Operation.metadata is of type ImportMetadata.", - // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/userEvents:import", - // "httpMethod": "POST", - // "id": "discoveryengine.projects.locations.collections.dataStores.userEvents.import", + // "description": "Deletes a DataStore.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}", + // "httpMethod": "DELETE", + // "id": "discoveryengine.projects.locations.dataStores.delete", // "parameterOrder": [ - // "parent" + // "name" // ], // "parameters": { - // "parent": { - // "description": "Required. Parent DataStore resource name, of the form `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}`", + // "name": { + // "description": "Required. Full resource name of DataStore, such as `projects/{project}/locations/{location}/collections/{collection_id}/dataStores/{data_store_id}`. If the caller does not have permission to delete the DataStore, regardless of whether or not it exists, a PERMISSION_DENIED error is returned. If the DataStore to delete does not exist, a NOT_FOUND error is returned.", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/dataStores/[^/]+$", // "required": true, // "type": "string" // } // }, - // "path": "v1beta/{+parent}/userEvents:import", - // "request": { - // "$ref": "GoogleCloudDiscoveryengineV1betaImportUserEventsRequest" - // }, + // "path": "v1beta/{+name}", // "response": { // "$ref": "GoogleLongrunningOperation" // }, @@ -14734,92 +23253,102 @@ func (c *ProjectsLocationsCollectionsDataStoresUserEventsImportCall) Do(opts ... } -// method id "discoveryengine.projects.locations.collections.dataStores.userEvents.write": +// method id "discoveryengine.projects.locations.dataStores.get": -type ProjectsLocationsCollectionsDataStoresUserEventsWriteCall struct { - s *Service - parent string - googleclouddiscoveryenginev1betauserevent *GoogleCloudDiscoveryengineV1betaUserEvent - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +type ProjectsLocationsDataStoresGetCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header } -// Write: Writes a single user event. +// Get: Gets a DataStore. // -// - parent: The parent DataStore resource name, such as -// `projects/{project}/locations/{location}/collections/{collection}/da -// taStores/{data_store}`. -func (r *ProjectsLocationsCollectionsDataStoresUserEventsService) Write(parent string, googleclouddiscoveryenginev1betauserevent *GoogleCloudDiscoveryengineV1betaUserEvent) *ProjectsLocationsCollectionsDataStoresUserEventsWriteCall { - c := &ProjectsLocationsCollectionsDataStoresUserEventsWriteCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.parent = parent - c.googleclouddiscoveryenginev1betauserevent = googleclouddiscoveryenginev1betauserevent +// - name: Full resource name of DataStore, such as +// `projects/{project}/locations/{location}/collections/{collection_id} +// /dataStores/{data_store_id}`. If the caller does not have +// permission to access the DataStore, regardless of whether or not it +// exists, a PERMISSION_DENIED error is returned. If the requested +// DataStore does not exist, a NOT_FOUND error is returned. +func (r *ProjectsLocationsDataStoresService) Get(name string) *ProjectsLocationsDataStoresGetCall { + c := &ProjectsLocationsDataStoresGetCall{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 information. -func (c *ProjectsLocationsCollectionsDataStoresUserEventsWriteCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresUserEventsWriteCall { +func (c *ProjectsLocationsDataStoresGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsDataStoresGetCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } +// IfNoneMatch sets the 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. Use googleapi.IsNotModified to check whether the response +// error from Do is the result of In-None-Match. +func (c *ProjectsLocationsDataStoresGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsDataStoresGetCall { + c.ifNoneMatch_ = entityTag + return c +} + // Context sets the context to be used in this call's Do method. Any // pending HTTP request will be aborted if the provided context is // canceled. -func (c *ProjectsLocationsCollectionsDataStoresUserEventsWriteCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresUserEventsWriteCall { +func (c *ProjectsLocationsDataStoresGetCall) Context(ctx context.Context) *ProjectsLocationsDataStoresGetCall { c.ctx_ = ctx return c } // Header returns an http.Header that can be modified by the caller to // add HTTP headers to the request. -func (c *ProjectsLocationsCollectionsDataStoresUserEventsWriteCall) Header() http.Header { +func (c *ProjectsLocationsDataStoresGetCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsCollectionsDataStoresUserEventsWriteCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsDataStoresGetCall) doRequest(alt string) (*http.Response, error) { reqHeaders := make(http.Header) reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) for k, v := range c.header_ { reqHeaders[k] = v } reqHeaders.Set("User-Agent", c.s.userAgent()) - var body io.Reader = nil - body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddiscoveryenginev1betauserevent) - if err != nil { - return nil, err + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) } - reqHeaders.Set("Content-Type", "application/json") + var body io.Reader = nil c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+parent}/userEvents:write") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("POST", urls, body) + req, err := http.NewRequest("GET", urls, body) if err != nil { return nil, err } req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ - "parent": c.parent, + "name": c.name, }) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "discoveryengine.projects.locations.collections.dataStores.userEvents.write" call. -// Exactly one of *GoogleCloudDiscoveryengineV1betaUserEvent or error +// Do executes the "discoveryengine.projects.locations.dataStores.get" call. +// Exactly one of *GoogleCloudDiscoveryengineV1betaDataStore or error // will be non-nil. Any non-2xx status code is an error. Response // headers are in either -// *GoogleCloudDiscoveryengineV1betaUserEvent.ServerResponse.Header or +// *GoogleCloudDiscoveryengineV1betaDataStore.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 *ProjectsLocationsCollectionsDataStoresUserEventsWriteCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1betaUserEvent, error) { +func (c *ProjectsLocationsDataStoresGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1betaDataStore, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -14838,7 +23367,7 @@ func (c *ProjectsLocationsCollectionsDataStoresUserEventsWriteCall) Do(opts ...g if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &GoogleCloudDiscoveryengineV1betaUserEvent{ + ret := &GoogleCloudDiscoveryengineV1betaDataStore{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -14850,28 +23379,25 @@ func (c *ProjectsLocationsCollectionsDataStoresUserEventsWriteCall) Do(opts ...g } return ret, nil // { - // "description": "Writes a single user event.", - // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/userEvents:write", - // "httpMethod": "POST", - // "id": "discoveryengine.projects.locations.collections.dataStores.userEvents.write", + // "description": "Gets a DataStore.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}", + // "httpMethod": "GET", + // "id": "discoveryengine.projects.locations.dataStores.get", // "parameterOrder": [ - // "parent" + // "name" // ], // "parameters": { - // "parent": { - // "description": "Required. The parent DataStore resource name, such as `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}`.", + // "name": { + // "description": "Required. Full resource name of DataStore, such as `projects/{project}/locations/{location}/collections/{collection_id}/dataStores/{data_store_id}`. If the caller does not have permission to access the DataStore, regardless of whether or not it exists, a PERMISSION_DENIED error is returned. If the requested DataStore does not exist, a NOT_FOUND error is returned.", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/dataStores/[^/]+$", // "required": true, // "type": "string" // } // }, - // "path": "v1beta/{+parent}/userEvents:write", - // "request": { - // "$ref": "GoogleCloudDiscoveryengineV1betaUserEvent" - // }, + // "path": "v1beta/{+name}", // "response": { - // "$ref": "GoogleCloudDiscoveryengineV1betaUserEvent" + // "$ref": "GoogleCloudDiscoveryengineV1betaDataStore" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -14880,77 +23406,81 @@ func (c *ProjectsLocationsCollectionsDataStoresUserEventsWriteCall) Do(opts ...g } -// method id "discoveryengine.projects.locations.collections.engines.conversations.converse": +// method id "discoveryengine.projects.locations.dataStores.getSiteSearchEngine": -type ProjectsLocationsCollectionsEnginesConversationsConverseCall struct { - s *Service - name string - googleclouddiscoveryenginev1betaconverseconversationrequest *GoogleCloudDiscoveryengineV1betaConverseConversationRequest - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +type ProjectsLocationsDataStoresGetSiteSearchEngineCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header } -// Converse: Converses a conversation. +// GetSiteSearchEngine: Gets the SiteSearchEngine. // -// - name: The resource name of the Conversation to get. Format: -// `projects/{project_number}/locations/{location_id}/collections/{coll -// ection}/dataStores/{data_store_id}/conversations/{conversation_id}`. -// Use -// `projects/{project_number}/locations/{location_id}/collections/{coll -// ection}/dataStores/{data_store_id}/conversations/-` to activate -// auto session mode, which automatically creates a new conversation -// inside a ConverseConversation session. -func (r *ProjectsLocationsCollectionsEnginesConversationsService) Converse(name string, googleclouddiscoveryenginev1betaconverseconversationrequest *GoogleCloudDiscoveryengineV1betaConverseConversationRequest) *ProjectsLocationsCollectionsEnginesConversationsConverseCall { - c := &ProjectsLocationsCollectionsEnginesConversationsConverseCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// - name: Resource name of SiteSearchEngine, such as +// `projects/{project}/locations/{location}/collections/{collection}/da +// taStores/{data_store}/siteSearchEngine`. If the caller does not +// have permission to access the [SiteSearchEngine], regardless of +// whether or not it exists, a PERMISSION_DENIED error is returned. +func (r *ProjectsLocationsDataStoresService) GetSiteSearchEngine(name string) *ProjectsLocationsDataStoresGetSiteSearchEngineCall { + c := &ProjectsLocationsDataStoresGetSiteSearchEngineCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.name = name - c.googleclouddiscoveryenginev1betaconverseconversationrequest = googleclouddiscoveryenginev1betaconverseconversationrequest return c } // Fields allows partial responses to be retrieved. See // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse // for more information. -func (c *ProjectsLocationsCollectionsEnginesConversationsConverseCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsEnginesConversationsConverseCall { +func (c *ProjectsLocationsDataStoresGetSiteSearchEngineCall) Fields(s ...googleapi.Field) *ProjectsLocationsDataStoresGetSiteSearchEngineCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } +// IfNoneMatch sets the 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. Use googleapi.IsNotModified to check whether the response +// error from Do is the result of In-None-Match. +func (c *ProjectsLocationsDataStoresGetSiteSearchEngineCall) IfNoneMatch(entityTag string) *ProjectsLocationsDataStoresGetSiteSearchEngineCall { + c.ifNoneMatch_ = entityTag + return c +} + // Context sets the context to be used in this call's Do method. Any // pending HTTP request will be aborted if the provided context is // canceled. -func (c *ProjectsLocationsCollectionsEnginesConversationsConverseCall) Context(ctx context.Context) *ProjectsLocationsCollectionsEnginesConversationsConverseCall { +func (c *ProjectsLocationsDataStoresGetSiteSearchEngineCall) Context(ctx context.Context) *ProjectsLocationsDataStoresGetSiteSearchEngineCall { c.ctx_ = ctx return c } // Header returns an http.Header that can be modified by the caller to // add HTTP headers to the request. -func (c *ProjectsLocationsCollectionsEnginesConversationsConverseCall) Header() http.Header { +func (c *ProjectsLocationsDataStoresGetSiteSearchEngineCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsCollectionsEnginesConversationsConverseCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsDataStoresGetSiteSearchEngineCall) doRequest(alt string) (*http.Response, error) { reqHeaders := make(http.Header) reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) for k, v := range c.header_ { reqHeaders[k] = v } reqHeaders.Set("User-Agent", c.s.userAgent()) - var body io.Reader = nil - body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddiscoveryenginev1betaconverseconversationrequest) - if err != nil { - return nil, err + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) } - reqHeaders.Set("Content-Type", "application/json") + var body io.Reader = nil c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}:converse") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("POST", urls, body) + req, err := http.NewRequest("GET", urls, body) if err != nil { return nil, err } @@ -14961,17 +23491,16 @@ func (c *ProjectsLocationsCollectionsEnginesConversationsConverseCall) doRequest return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "discoveryengine.projects.locations.collections.engines.conversations.converse" call. -// Exactly one of -// *GoogleCloudDiscoveryengineV1betaConverseConversationResponse or +// Do executes the "discoveryengine.projects.locations.dataStores.getSiteSearchEngine" call. +// Exactly one of *GoogleCloudDiscoveryengineV1betaSiteSearchEngine or // error will be non-nil. Any non-2xx status code is an error. Response // headers are in either -// *GoogleCloudDiscoveryengineV1betaConverseConversationResponse.ServerRe -// sponse.Header or (if a response was returned at all) in +// *GoogleCloudDiscoveryengineV1betaSiteSearchEngine.ServerResponse.Heade +// r 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 *ProjectsLocationsCollectionsEnginesConversationsConverseCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1betaConverseConversationResponse, error) { +func (c *ProjectsLocationsDataStoresGetSiteSearchEngineCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1betaSiteSearchEngine, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -14990,7 +23519,7 @@ func (c *ProjectsLocationsCollectionsEnginesConversationsConverseCall) Do(opts . if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &GoogleCloudDiscoveryengineV1betaConverseConversationResponse{ + ret := &GoogleCloudDiscoveryengineV1betaSiteSearchEngine{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -15002,28 +23531,25 @@ func (c *ProjectsLocationsCollectionsEnginesConversationsConverseCall) Do(opts . } return ret, nil // { - // "description": "Converses a conversation.", - // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/engines/{enginesId}/conversations/{conversationsId}:converse", - // "httpMethod": "POST", - // "id": "discoveryengine.projects.locations.collections.engines.conversations.converse", + // "description": "Gets the SiteSearchEngine.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/siteSearchEngine", + // "httpMethod": "GET", + // "id": "discoveryengine.projects.locations.dataStores.getSiteSearchEngine", // "parameterOrder": [ // "name" // ], // "parameters": { // "name": { - // "description": "Required. The resource name of the Conversation to get. Format: `projects/{project_number}/locations/{location_id}/collections/{collection}/dataStores/{data_store_id}/conversations/{conversation_id}`. Use `projects/{project_number}/locations/{location_id}/collections/{collection}/dataStores/{data_store_id}/conversations/-` to activate auto session mode, which automatically creates a new conversation inside a ConverseConversation session.", + // "description": "Required. Resource name of SiteSearchEngine, such as `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/siteSearchEngine`. If the caller does not have permission to access the [SiteSearchEngine], regardless of whether or not it exists, a PERMISSION_DENIED error is returned.", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/engines/[^/]+/conversations/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/dataStores/[^/]+/siteSearchEngine$", // "required": true, // "type": "string" // } // }, - // "path": "v1beta/{+name}:converse", - // "request": { - // "$ref": "GoogleCloudDiscoveryengineV1betaConverseConversationRequest" - // }, + // "path": "v1beta/{+name}", // "response": { - // "$ref": "GoogleCloudDiscoveryengineV1betaConverseConversationResponse" + // "$ref": "GoogleCloudDiscoveryengineV1betaSiteSearchEngine" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -15032,73 +23558,108 @@ func (c *ProjectsLocationsCollectionsEnginesConversationsConverseCall) Do(opts . } -// method id "discoveryengine.projects.locations.collections.engines.conversations.create": +// method id "discoveryengine.projects.locations.dataStores.list": -type ProjectsLocationsCollectionsEnginesConversationsCreateCall struct { - s *Service - parent string - googleclouddiscoveryenginev1betaconversation *GoogleCloudDiscoveryengineV1betaConversation - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +type ProjectsLocationsDataStoresListCall struct { + s *Service + parent string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// List: Lists all the DataStores associated with the project. +// +// - parent: The parent branch resource name, such as +// `projects/{project}/locations/{location}/collections/{collection_id} +// `. If the caller does not have permission to list DataStores under +// this location, regardless of whether or not this data store exists, +// a PERMISSION_DENIED error is returned. +func (r *ProjectsLocationsDataStoresService) List(parent string) *ProjectsLocationsDataStoresListCall { + c := &ProjectsLocationsDataStoresListCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + return c +} + +// Filter sets the optional parameter "filter": Filter by solution type. +// For example: filter = 'solution_type:SOLUTION_TYPE_SEARCH' +func (c *ProjectsLocationsDataStoresListCall) Filter(filter string) *ProjectsLocationsDataStoresListCall { + c.urlParams_.Set("filter", filter) + return c +} + +// PageSize sets the optional parameter "pageSize": Maximum number of +// DataStores to return. If unspecified, defaults to 10. The maximum +// allowed value is 50. Values above 50 will be coerced to 50. If this +// field is negative, an INVALID_ARGUMENT is returned. +func (c *ProjectsLocationsDataStoresListCall) PageSize(pageSize int64) *ProjectsLocationsDataStoresListCall { + c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) + return c } -// Create: Creates a Conversation. If the Conversation to create already -// exists, an ALREADY_EXISTS error is returned. -// -// - parent: Full resource name of parent data store. Format: -// `projects/{project_number}/locations/{location_id}/collections/{coll -// ection}/dataStores/{data_store_id}`. -func (r *ProjectsLocationsCollectionsEnginesConversationsService) Create(parent string, googleclouddiscoveryenginev1betaconversation *GoogleCloudDiscoveryengineV1betaConversation) *ProjectsLocationsCollectionsEnginesConversationsCreateCall { - c := &ProjectsLocationsCollectionsEnginesConversationsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.parent = parent - c.googleclouddiscoveryenginev1betaconversation = googleclouddiscoveryenginev1betaconversation +// PageToken sets the optional parameter "pageToken": A page token +// ListDataStoresResponse.next_page_token, received from a previous +// DataStoreService.ListDataStores call. Provide this to retrieve the +// subsequent page. When paginating, all other parameters provided to +// DataStoreService.ListDataStores must match the call that provided the +// page token. Otherwise, an INVALID_ARGUMENT error is returned. +func (c *ProjectsLocationsDataStoresListCall) PageToken(pageToken string) *ProjectsLocationsDataStoresListCall { + 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 information. -func (c *ProjectsLocationsCollectionsEnginesConversationsCreateCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsEnginesConversationsCreateCall { +func (c *ProjectsLocationsDataStoresListCall) Fields(s ...googleapi.Field) *ProjectsLocationsDataStoresListCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } +// IfNoneMatch sets the 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. Use googleapi.IsNotModified to check whether the response +// error from Do is the result of In-None-Match. +func (c *ProjectsLocationsDataStoresListCall) IfNoneMatch(entityTag string) *ProjectsLocationsDataStoresListCall { + c.ifNoneMatch_ = entityTag + return c +} + // Context sets the context to be used in this call's Do method. Any // pending HTTP request will be aborted if the provided context is // canceled. -func (c *ProjectsLocationsCollectionsEnginesConversationsCreateCall) Context(ctx context.Context) *ProjectsLocationsCollectionsEnginesConversationsCreateCall { +func (c *ProjectsLocationsDataStoresListCall) Context(ctx context.Context) *ProjectsLocationsDataStoresListCall { c.ctx_ = ctx return c } // Header returns an http.Header that can be modified by the caller to // add HTTP headers to the request. -func (c *ProjectsLocationsCollectionsEnginesConversationsCreateCall) Header() http.Header { +func (c *ProjectsLocationsDataStoresListCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsCollectionsEnginesConversationsCreateCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsDataStoresListCall) doRequest(alt string) (*http.Response, error) { reqHeaders := make(http.Header) reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) for k, v := range c.header_ { reqHeaders[k] = v } reqHeaders.Set("User-Agent", c.s.userAgent()) - var body io.Reader = nil - body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddiscoveryenginev1betaconversation) - if err != nil { - return nil, err + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) } - reqHeaders.Set("Content-Type", "application/json") + var body io.Reader = nil c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+parent}/conversations") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+parent}/dataStores") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("POST", urls, body) + req, err := http.NewRequest("GET", urls, body) if err != nil { return nil, err } @@ -15109,16 +23670,17 @@ func (c *ProjectsLocationsCollectionsEnginesConversationsCreateCall) doRequest(a return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "discoveryengine.projects.locations.collections.engines.conversations.create" call. -// Exactly one of *GoogleCloudDiscoveryengineV1betaConversation or error -// will be non-nil. Any non-2xx status code is an error. Response -// headers are in either -// *GoogleCloudDiscoveryengineV1betaConversation.ServerResponse.Header -// or (if a response was returned at all) in +// Do executes the "discoveryengine.projects.locations.dataStores.list" call. +// Exactly one of +// *GoogleCloudDiscoveryengineV1betaListDataStoresResponse or error will +// be non-nil. Any non-2xx status code is an error. Response headers are +// in either +// *GoogleCloudDiscoveryengineV1betaListDataStoresResponse.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 *ProjectsLocationsCollectionsEnginesConversationsCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1betaConversation, error) { +func (c *ProjectsLocationsDataStoresListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1betaListDataStoresResponse, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -15137,7 +23699,7 @@ func (c *ProjectsLocationsCollectionsEnginesConversationsCreateCall) Do(opts ... if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &GoogleCloudDiscoveryengineV1betaConversation{ + ret := &GoogleCloudDiscoveryengineV1betaListDataStoresResponse{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -15149,28 +23711,41 @@ func (c *ProjectsLocationsCollectionsEnginesConversationsCreateCall) Do(opts ... } return ret, nil // { - // "description": "Creates a Conversation. If the Conversation to create already exists, an ALREADY_EXISTS error is returned.", - // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/engines/{enginesId}/conversations", - // "httpMethod": "POST", - // "id": "discoveryengine.projects.locations.collections.engines.conversations.create", + // "description": "Lists all the DataStores associated with the project.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores", + // "httpMethod": "GET", + // "id": "discoveryengine.projects.locations.dataStores.list", // "parameterOrder": [ // "parent" // ], // "parameters": { + // "filter": { + // "description": "Filter by solution type. For example: filter = 'solution_type:SOLUTION_TYPE_SEARCH'", + // "location": "query", + // "type": "string" + // }, + // "pageSize": { + // "description": "Maximum number of DataStores to return. If unspecified, defaults to 10. The maximum allowed value is 50. Values above 50 will be coerced to 50. If this field is negative, an INVALID_ARGUMENT is returned.", + // "format": "int32", + // "location": "query", + // "type": "integer" + // }, + // "pageToken": { + // "description": "A page token ListDataStoresResponse.next_page_token, received from a previous DataStoreService.ListDataStores call. Provide this to retrieve the subsequent page. When paginating, all other parameters provided to DataStoreService.ListDataStores must match the call that provided the page token. Otherwise, an INVALID_ARGUMENT error is returned.", + // "location": "query", + // "type": "string" + // }, // "parent": { - // "description": "Required. Full resource name of parent data store. Format: `projects/{project_number}/locations/{location_id}/collections/{collection}/dataStores/{data_store_id}`", + // "description": "Required. The parent branch resource name, such as `projects/{project}/locations/{location}/collections/{collection_id}`. If the caller does not have permission to list DataStores under this location, regardless of whether or not this data store exists, a PERMISSION_DENIED error is returned.", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/engines/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+$", // "required": true, // "type": "string" // } // }, - // "path": "v1beta/{+parent}/conversations", - // "request": { - // "$ref": "GoogleCloudDiscoveryengineV1betaConversation" - // }, + // "path": "v1beta/{+parent}/dataStores", // "response": { - // "$ref": "GoogleCloudDiscoveryengineV1betaConversation" + // "$ref": "GoogleCloudDiscoveryengineV1betaListDataStoresResponse" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -15179,32 +23754,63 @@ func (c *ProjectsLocationsCollectionsEnginesConversationsCreateCall) Do(opts ... } -// method id "discoveryengine.projects.locations.collections.engines.conversations.delete": +// 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 *ProjectsLocationsDataStoresListCall) Pages(ctx context.Context, f func(*GoogleCloudDiscoveryengineV1betaListDataStoresResponse) error) error { + c.ctx_ = ctx + defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point + 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 ProjectsLocationsCollectionsEnginesConversationsDeleteCall struct { - s *Service - name string - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +// method id "discoveryengine.projects.locations.dataStores.patch": + +type ProjectsLocationsDataStoresPatchCall struct { + s *Service + name string + googleclouddiscoveryenginev1betadatastore *GoogleCloudDiscoveryengineV1betaDataStore + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// Delete: Deletes a Conversation. If the Conversation to delete does -// not exist, a NOT_FOUND error is returned. +// Patch: Updates a DataStore // -// - name: The resource name of the Conversation to delete. Format: -// `projects/{project_number}/locations/{location_id}/collections/{coll -// ection}/dataStores/{data_store_id}/conversations/{conversation_id}`. -func (r *ProjectsLocationsCollectionsEnginesConversationsService) Delete(name string) *ProjectsLocationsCollectionsEnginesConversationsDeleteCall { - c := &ProjectsLocationsCollectionsEnginesConversationsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// - name: Immutable. The full resource name of the data store. Format: +// `projects/{project}/locations/{location}/collections/{collection_id} +// /dataStores/{data_store_id}`. This field must be a UTF-8 encoded +// string with a length limit of 1024 characters. +func (r *ProjectsLocationsDataStoresService) Patch(name string, googleclouddiscoveryenginev1betadatastore *GoogleCloudDiscoveryengineV1betaDataStore) *ProjectsLocationsDataStoresPatchCall { + c := &ProjectsLocationsDataStoresPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.name = name + c.googleclouddiscoveryenginev1betadatastore = googleclouddiscoveryenginev1betadatastore + return c +} + +// UpdateMask sets the optional parameter "updateMask": Indicates which +// fields in the provided DataStore to update. If an unsupported or +// unknown field is provided, an INVALID_ARGUMENT error is returned. +func (c *ProjectsLocationsDataStoresPatchCall) UpdateMask(updateMask string) *ProjectsLocationsDataStoresPatchCall { + 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 information. -func (c *ProjectsLocationsCollectionsEnginesConversationsDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsEnginesConversationsDeleteCall { +func (c *ProjectsLocationsDataStoresPatchCall) Fields(s ...googleapi.Field) *ProjectsLocationsDataStoresPatchCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } @@ -15212,21 +23818,21 @@ func (c *ProjectsLocationsCollectionsEnginesConversationsDeleteCall) Fields(s .. // Context sets the context to be used in this call's Do method. Any // pending HTTP request will be aborted if the provided context is // canceled. -func (c *ProjectsLocationsCollectionsEnginesConversationsDeleteCall) Context(ctx context.Context) *ProjectsLocationsCollectionsEnginesConversationsDeleteCall { +func (c *ProjectsLocationsDataStoresPatchCall) Context(ctx context.Context) *ProjectsLocationsDataStoresPatchCall { c.ctx_ = ctx return c } // Header returns an http.Header that can be modified by the caller to // add HTTP headers to the request. -func (c *ProjectsLocationsCollectionsEnginesConversationsDeleteCall) Header() http.Header { +func (c *ProjectsLocationsDataStoresPatchCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsCollectionsEnginesConversationsDeleteCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsDataStoresPatchCall) doRequest(alt string) (*http.Response, error) { reqHeaders := make(http.Header) reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) for k, v := range c.header_ { @@ -15234,11 +23840,16 @@ func (c *ProjectsLocationsCollectionsEnginesConversationsDeleteCall) doRequest(a } reqHeaders.Set("User-Agent", c.s.userAgent()) var body io.Reader = nil + body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddiscoveryenginev1betadatastore) + if err != nil { + return nil, err + } + reqHeaders.Set("Content-Type", "application/json") 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("DELETE", urls, body) + req, err := http.NewRequest("PATCH", urls, body) if err != nil { return nil, err } @@ -15249,14 +23860,16 @@ func (c *ProjectsLocationsCollectionsEnginesConversationsDeleteCall) doRequest(a return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "discoveryengine.projects.locations.collections.engines.conversations.delete" call. -// Exactly one of *GoogleProtobufEmpty or error will be non-nil. Any -// non-2xx status code is an error. Response headers are in either -// *GoogleProtobufEmpty.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 *ProjectsLocationsCollectionsEnginesConversationsDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, error) { +// Do executes the "discoveryengine.projects.locations.dataStores.patch" call. +// Exactly one of *GoogleCloudDiscoveryengineV1betaDataStore or error +// will be non-nil. Any non-2xx status code is an error. Response +// headers are in either +// *GoogleCloudDiscoveryengineV1betaDataStore.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 *ProjectsLocationsDataStoresPatchCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1betaDataStore, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -15275,7 +23888,7 @@ func (c *ProjectsLocationsCollectionsEnginesConversationsDeleteCall) Do(opts ... if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &GoogleProtobufEmpty{ + ret := &GoogleCloudDiscoveryengineV1betaDataStore{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -15287,25 +23900,34 @@ func (c *ProjectsLocationsCollectionsEnginesConversationsDeleteCall) Do(opts ... } return ret, nil // { - // "description": "Deletes a Conversation. If the Conversation to delete does not exist, a NOT_FOUND error is returned.", - // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/engines/{enginesId}/conversations/{conversationsId}", - // "httpMethod": "DELETE", - // "id": "discoveryengine.projects.locations.collections.engines.conversations.delete", + // "description": "Updates a DataStore", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}", + // "httpMethod": "PATCH", + // "id": "discoveryengine.projects.locations.dataStores.patch", // "parameterOrder": [ // "name" // ], // "parameters": { // "name": { - // "description": "Required. The resource name of the Conversation to delete. Format: `projects/{project_number}/locations/{location_id}/collections/{collection}/dataStores/{data_store_id}/conversations/{conversation_id}`", + // "description": "Immutable. The full resource name of the data store. Format: `projects/{project}/locations/{location}/collections/{collection_id}/dataStores/{data_store_id}`. This field must be a UTF-8 encoded string with a length limit of 1024 characters.", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/engines/[^/]+/conversations/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/dataStores/[^/]+$", // "required": true, // "type": "string" + // }, + // "updateMask": { + // "description": "Indicates which fields in the provided DataStore to update. If an unsupported or unknown field is provided, an INVALID_ARGUMENT error is returned.", + // "format": "google-fieldmask", + // "location": "query", + // "type": "string" // } // }, // "path": "v1beta/{+name}", + // "request": { + // "$ref": "GoogleCloudDiscoveryengineV1betaDataStore" + // }, // "response": { - // "$ref": "GoogleProtobufEmpty" + // "$ref": "GoogleCloudDiscoveryengineV1betaDataStore" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -15314,99 +23936,107 @@ func (c *ProjectsLocationsCollectionsEnginesConversationsDeleteCall) Do(opts ... } -// method id "discoveryengine.projects.locations.collections.engines.conversations.get": +// method id "discoveryengine.projects.locations.dataStores.branches.documents.create": -type ProjectsLocationsCollectionsEnginesConversationsGetCall struct { - s *Service - name string - urlParams_ gensupport.URLParams - ifNoneMatch_ string - ctx_ context.Context - header_ http.Header +type ProjectsLocationsDataStoresBranchesDocumentsCreateCall struct { + s *Service + parent string + googleclouddiscoveryenginev1betadocument *GoogleCloudDiscoveryengineV1betaDocument + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// Get: Gets a Conversation. +// Create: Creates a Document. // -// - name: The resource name of the Conversation to get. Format: -// `projects/{project_number}/locations/{location_id}/collections/{coll -// ection}/dataStores/{data_store_id}/conversations/{conversation_id}`. -func (r *ProjectsLocationsCollectionsEnginesConversationsService) Get(name string) *ProjectsLocationsCollectionsEnginesConversationsGetCall { - c := &ProjectsLocationsCollectionsEnginesConversationsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.name = name +// - parent: The parent resource name, such as +// `projects/{project}/locations/{location}/collections/{collection}/da +// taStores/{data_store}/branches/{branch}`. +func (r *ProjectsLocationsDataStoresBranchesDocumentsService) Create(parent string, googleclouddiscoveryenginev1betadocument *GoogleCloudDiscoveryengineV1betaDocument) *ProjectsLocationsDataStoresBranchesDocumentsCreateCall { + c := &ProjectsLocationsDataStoresBranchesDocumentsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + c.googleclouddiscoveryenginev1betadocument = googleclouddiscoveryenginev1betadocument + return c +} + +// DocumentId sets the optional parameter "documentId": Required. The ID +// to use for the Document, which will become the final component of the +// Document.name. If the caller does not have permission to create the +// Document, regardless of whether or not it exists, a +// `PERMISSION_DENIED` error is returned. This field must be unique +// among all Documents with the same parent. Otherwise, an +// `ALREADY_EXISTS` error is returned. This field must conform to +// RFC-1034 (https://tools.ietf.org/html/rfc1034) standard with a length +// limit of 63 characters. Otherwise, an `INVALID_ARGUMENT` error is +// returned. +func (c *ProjectsLocationsDataStoresBranchesDocumentsCreateCall) DocumentId(documentId string) *ProjectsLocationsDataStoresBranchesDocumentsCreateCall { + c.urlParams_.Set("documentId", documentId) return c } // Fields allows partial responses to be retrieved. See // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse // for more information. -func (c *ProjectsLocationsCollectionsEnginesConversationsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsEnginesConversationsGetCall { +func (c *ProjectsLocationsDataStoresBranchesDocumentsCreateCall) Fields(s ...googleapi.Field) *ProjectsLocationsDataStoresBranchesDocumentsCreateCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// IfNoneMatch sets the 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. Use googleapi.IsNotModified to check whether the response -// error from Do is the result of In-None-Match. -func (c *ProjectsLocationsCollectionsEnginesConversationsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsCollectionsEnginesConversationsGetCall { - c.ifNoneMatch_ = entityTag - return c -} - // Context sets the context to be used in this call's Do method. Any // pending HTTP request will be aborted if the provided context is // canceled. -func (c *ProjectsLocationsCollectionsEnginesConversationsGetCall) Context(ctx context.Context) *ProjectsLocationsCollectionsEnginesConversationsGetCall { +func (c *ProjectsLocationsDataStoresBranchesDocumentsCreateCall) Context(ctx context.Context) *ProjectsLocationsDataStoresBranchesDocumentsCreateCall { c.ctx_ = ctx return c } // Header returns an http.Header that can be modified by the caller to // add HTTP headers to the request. -func (c *ProjectsLocationsCollectionsEnginesConversationsGetCall) Header() http.Header { +func (c *ProjectsLocationsDataStoresBranchesDocumentsCreateCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsCollectionsEnginesConversationsGetCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsDataStoresBranchesDocumentsCreateCall) doRequest(alt string) (*http.Response, error) { reqHeaders := make(http.Header) reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) for k, v := range c.header_ { reqHeaders[k] = v } reqHeaders.Set("User-Agent", c.s.userAgent()) - if c.ifNoneMatch_ != "" { - reqHeaders.Set("If-None-Match", c.ifNoneMatch_) - } var body io.Reader = nil + body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddiscoveryenginev1betadocument) + if err != nil { + return nil, err + } + reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+parent}/documents") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("GET", urls, body) + req, err := http.NewRequest("POST", urls, body) if err != nil { return nil, err } req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ - "name": c.name, + "parent": c.parent, }) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "discoveryengine.projects.locations.collections.engines.conversations.get" call. -// Exactly one of *GoogleCloudDiscoveryengineV1betaConversation or error +// Do executes the "discoveryengine.projects.locations.dataStores.branches.documents.create" call. +// Exactly one of *GoogleCloudDiscoveryengineV1betaDocument or error // will be non-nil. Any non-2xx status code is an error. Response // headers are in either -// *GoogleCloudDiscoveryengineV1betaConversation.ServerResponse.Header -// or (if a response was returned at all) in +// *GoogleCloudDiscoveryengineV1betaDocument.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 *ProjectsLocationsCollectionsEnginesConversationsGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1betaConversation, error) { +func (c *ProjectsLocationsDataStoresBranchesDocumentsCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1betaDocument, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -15425,7 +24055,7 @@ func (c *ProjectsLocationsCollectionsEnginesConversationsGetCall) Do(opts ...goo if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &GoogleCloudDiscoveryengineV1betaConversation{ + ret := &GoogleCloudDiscoveryengineV1betaDocument{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -15437,25 +24067,33 @@ func (c *ProjectsLocationsCollectionsEnginesConversationsGetCall) Do(opts ...goo } return ret, nil // { - // "description": "Gets a Conversation.", - // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/engines/{enginesId}/conversations/{conversationsId}", - // "httpMethod": "GET", - // "id": "discoveryengine.projects.locations.collections.engines.conversations.get", + // "description": "Creates a Document.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/branches/{branchesId}/documents", + // "httpMethod": "POST", + // "id": "discoveryengine.projects.locations.dataStores.branches.documents.create", // "parameterOrder": [ - // "name" + // "parent" // ], // "parameters": { - // "name": { - // "description": "Required. The resource name of the Conversation to get. Format: `projects/{project_number}/locations/{location_id}/collections/{collection}/dataStores/{data_store_id}/conversations/{conversation_id}`", + // "documentId": { + // "description": "Required. The ID to use for the Document, which will become the final component of the Document.name. If the caller does not have permission to create the Document, regardless of whether or not it exists, a `PERMISSION_DENIED` error is returned. This field must be unique among all Documents with the same parent. Otherwise, an `ALREADY_EXISTS` error is returned. This field must conform to [RFC-1034](https://tools.ietf.org/html/rfc1034) standard with a length limit of 63 characters. Otherwise, an `INVALID_ARGUMENT` error is returned.", + // "location": "query", + // "type": "string" + // }, + // "parent": { + // "description": "Required. The parent resource name, such as `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/branches/{branch}`.", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/engines/[^/]+/conversations/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/dataStores/[^/]+/branches/[^/]+$", // "required": true, // "type": "string" // } // }, - // "path": "v1beta/{+name}", + // "path": "v1beta/{+parent}/documents", + // "request": { + // "$ref": "GoogleCloudDiscoveryengineV1betaDocument" + // }, // "response": { - // "$ref": "GoogleCloudDiscoveryengineV1betaConversation" + // "$ref": "GoogleCloudDiscoveryengineV1betaDocument" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -15464,134 +24102,87 @@ func (c *ProjectsLocationsCollectionsEnginesConversationsGetCall) Do(opts ...goo } -// method id "discoveryengine.projects.locations.collections.engines.conversations.list": +// method id "discoveryengine.projects.locations.dataStores.branches.documents.delete": -type ProjectsLocationsCollectionsEnginesConversationsListCall struct { - s *Service - parent string - urlParams_ gensupport.URLParams - ifNoneMatch_ string - ctx_ context.Context - header_ http.Header +type ProjectsLocationsDataStoresBranchesDocumentsDeleteCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// List: Lists all Conversations by their parent DataStore. +// Delete: Deletes a Document. // -// - parent: The data store resource name. Format: -// `projects/{project_number}/locations/{location_id}/collections/{coll -// ection}/dataStores/{data_store_id}`. -func (r *ProjectsLocationsCollectionsEnginesConversationsService) List(parent string) *ProjectsLocationsCollectionsEnginesConversationsListCall { - c := &ProjectsLocationsCollectionsEnginesConversationsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.parent = parent - return c -} - -// Filter sets the optional parameter "filter": A filter to apply on the -// list results. The supported features are: user_pseudo_id, state. -// Example: "user_pseudo_id = some_id" -func (c *ProjectsLocationsCollectionsEnginesConversationsListCall) Filter(filter string) *ProjectsLocationsCollectionsEnginesConversationsListCall { - c.urlParams_.Set("filter", filter) - 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: * `update_time` * -// `create_time` * `conversation_name` Example: "update_time desc" -// "create_time" -func (c *ProjectsLocationsCollectionsEnginesConversationsListCall) OrderBy(orderBy string) *ProjectsLocationsCollectionsEnginesConversationsListCall { - c.urlParams_.Set("orderBy", orderBy) - return c -} - -// PageSize sets the optional parameter "pageSize": Maximum number of -// results to return. If unspecified, defaults to 50. Max allowed value -// is 1000. -func (c *ProjectsLocationsCollectionsEnginesConversationsListCall) PageSize(pageSize int64) *ProjectsLocationsCollectionsEnginesConversationsListCall { - c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) - return c -} - -// PageToken sets the optional parameter "pageToken": A page token, -// received from a previous `ListConversations` call. Provide this to -// retrieve the subsequent page. -func (c *ProjectsLocationsCollectionsEnginesConversationsListCall) PageToken(pageToken string) *ProjectsLocationsCollectionsEnginesConversationsListCall { - c.urlParams_.Set("pageToken", pageToken) +// - name: Full resource name of Document, such as +// `projects/{project}/locations/{location}/collections/{collection}/da +// taStores/{data_store}/branches/{branch}/documents/{document}`. If +// the caller does not have permission to delete the Document, +// regardless of whether or not it exists, a `PERMISSION_DENIED` error +// is returned. If the Document to delete does not exist, a +// `NOT_FOUND` error is returned. +func (r *ProjectsLocationsDataStoresBranchesDocumentsService) Delete(name string) *ProjectsLocationsDataStoresBranchesDocumentsDeleteCall { + c := &ProjectsLocationsDataStoresBranchesDocumentsDeleteCall{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 information. -func (c *ProjectsLocationsCollectionsEnginesConversationsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsEnginesConversationsListCall { +func (c *ProjectsLocationsDataStoresBranchesDocumentsDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsDataStoresBranchesDocumentsDeleteCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// IfNoneMatch sets the 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. Use googleapi.IsNotModified to check whether the response -// error from Do is the result of In-None-Match. -func (c *ProjectsLocationsCollectionsEnginesConversationsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsCollectionsEnginesConversationsListCall { - c.ifNoneMatch_ = entityTag - return c -} - // Context sets the context to be used in this call's Do method. Any // pending HTTP request will be aborted if the provided context is // canceled. -func (c *ProjectsLocationsCollectionsEnginesConversationsListCall) Context(ctx context.Context) *ProjectsLocationsCollectionsEnginesConversationsListCall { +func (c *ProjectsLocationsDataStoresBranchesDocumentsDeleteCall) Context(ctx context.Context) *ProjectsLocationsDataStoresBranchesDocumentsDeleteCall { c.ctx_ = ctx return c } // Header returns an http.Header that can be modified by the caller to // add HTTP headers to the request. -func (c *ProjectsLocationsCollectionsEnginesConversationsListCall) Header() http.Header { +func (c *ProjectsLocationsDataStoresBranchesDocumentsDeleteCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsCollectionsEnginesConversationsListCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsDataStoresBranchesDocumentsDeleteCall) doRequest(alt string) (*http.Response, error) { reqHeaders := make(http.Header) reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) for k, v := range c.header_ { reqHeaders[k] = v } reqHeaders.Set("User-Agent", c.s.userAgent()) - if c.ifNoneMatch_ != "" { - reqHeaders.Set("If-None-Match", c.ifNoneMatch_) - } var body io.Reader = nil c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+parent}/conversations") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("GET", urls, body) + req, err := http.NewRequest("DELETE", urls, body) if err != nil { return nil, err } req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ - "parent": c.parent, + "name": c.name, }) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "discoveryengine.projects.locations.collections.engines.conversations.list" call. -// Exactly one of -// *GoogleCloudDiscoveryengineV1betaListConversationsResponse or error -// will be non-nil. Any non-2xx status code is an error. Response -// headers are in either -// *GoogleCloudDiscoveryengineV1betaListConversationsResponse.ServerRespo -// nse.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 *ProjectsLocationsCollectionsEnginesConversationsListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1betaListConversationsResponse, error) { +// Do executes the "discoveryengine.projects.locations.dataStores.branches.documents.delete" call. +// Exactly one of *GoogleProtobufEmpty or error will be non-nil. Any +// non-2xx status code is an error. Response headers are in either +// *GoogleProtobufEmpty.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 *ProjectsLocationsDataStoresBranchesDocumentsDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -15610,7 +24201,7 @@ func (c *ProjectsLocationsCollectionsEnginesConversationsListCall) Do(opts ...go if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &GoogleCloudDiscoveryengineV1betaListConversationsResponse{ + ret := &GoogleProtobufEmpty{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -15622,46 +24213,25 @@ func (c *ProjectsLocationsCollectionsEnginesConversationsListCall) Do(opts ...go } return ret, nil // { - // "description": "Lists all Conversations by their parent DataStore.", - // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/engines/{enginesId}/conversations", - // "httpMethod": "GET", - // "id": "discoveryengine.projects.locations.collections.engines.conversations.list", + // "description": "Deletes a Document.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/branches/{branchesId}/documents/{documentsId}", + // "httpMethod": "DELETE", + // "id": "discoveryengine.projects.locations.dataStores.branches.documents.delete", // "parameterOrder": [ - // "parent" + // "name" // ], // "parameters": { - // "filter": { - // "description": "A filter to apply on the list results. The supported features are: user_pseudo_id, state. Example: \"user_pseudo_id = some_id\"", - // "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: * `update_time` * `create_time` * `conversation_name` Example: \"update_time desc\" \"create_time\"", - // "location": "query", - // "type": "string" - // }, - // "pageSize": { - // "description": "Maximum number of results to return. If unspecified, defaults to 50. Max allowed value is 1000.", - // "format": "int32", - // "location": "query", - // "type": "integer" - // }, - // "pageToken": { - // "description": "A page token, received from a previous `ListConversations` call. Provide this to retrieve the subsequent page.", - // "location": "query", - // "type": "string" - // }, - // "parent": { - // "description": "Required. The data store resource name. Format: `projects/{project_number}/locations/{location_id}/collections/{collection}/dataStores/{data_store_id}`", + // "name": { + // "description": "Required. Full resource name of Document, such as `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/branches/{branch}/documents/{document}`. If the caller does not have permission to delete the Document, regardless of whether or not it exists, a `PERMISSION_DENIED` error is returned. If the Document to delete does not exist, a `NOT_FOUND` error is returned.", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/engines/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/dataStores/[^/]+/branches/[^/]+/documents/[^/]+$", // "required": true, // "type": "string" // } // }, - // "path": "v1beta/{+parent}/conversations", + // "path": "v1beta/{+name}", // "response": { - // "$ref": "GoogleCloudDiscoveryengineV1betaListConversationsResponse" + // "$ref": "GoogleProtobufEmpty" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -15670,106 +24240,83 @@ func (c *ProjectsLocationsCollectionsEnginesConversationsListCall) Do(opts ...go } -// 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 *ProjectsLocationsCollectionsEnginesConversationsListCall) Pages(ctx context.Context, f func(*GoogleCloudDiscoveryengineV1betaListConversationsResponse) error) error { - c.ctx_ = ctx - defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point - 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) - } -} - -// method id "discoveryengine.projects.locations.collections.engines.conversations.patch": +// method id "discoveryengine.projects.locations.dataStores.branches.documents.get": -type ProjectsLocationsCollectionsEnginesConversationsPatchCall struct { - s *Service - name string - googleclouddiscoveryenginev1betaconversation *GoogleCloudDiscoveryengineV1betaConversation - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +type ProjectsLocationsDataStoresBranchesDocumentsGetCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header } -// Patch: Updates a Conversation. Conversation action type cannot be -// changed. If the Conversation to update does not exist, a NOT_FOUND -// error is returned. +// Get: Gets a Document. // -// - name: Immutable. Fully qualified name -// `project/*/locations/global/collections/{collection}/dataStore/*/con -// versations/*` or -// `project/*/locations/global/collections/{collection}/engines/*/conve -// rsations/*`. -func (r *ProjectsLocationsCollectionsEnginesConversationsService) Patch(name string, googleclouddiscoveryenginev1betaconversation *GoogleCloudDiscoveryengineV1betaConversation) *ProjectsLocationsCollectionsEnginesConversationsPatchCall { - c := &ProjectsLocationsCollectionsEnginesConversationsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// - name: Full resource name of Document, such as +// `projects/{project}/locations/{location}/collections/{collection}/da +// taStores/{data_store}/branches/{branch}/documents/{document}`. If +// the caller does not have permission to access the Document, +// regardless of whether or not it exists, a `PERMISSION_DENIED` error +// is returned. If the requested Document does not exist, a +// `NOT_FOUND` error is returned. +func (r *ProjectsLocationsDataStoresBranchesDocumentsService) Get(name string) *ProjectsLocationsDataStoresBranchesDocumentsGetCall { + c := &ProjectsLocationsDataStoresBranchesDocumentsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.name = name - c.googleclouddiscoveryenginev1betaconversation = googleclouddiscoveryenginev1betaconversation - return c -} - -// UpdateMask sets the optional parameter "updateMask": Indicates which -// fields in the provided Conversation to update. The following are NOT -// supported: * Conversation.name If not set or empty, all supported -// fields are updated. -func (c *ProjectsLocationsCollectionsEnginesConversationsPatchCall) UpdateMask(updateMask string) *ProjectsLocationsCollectionsEnginesConversationsPatchCall { - 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 information. -func (c *ProjectsLocationsCollectionsEnginesConversationsPatchCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsEnginesConversationsPatchCall { +func (c *ProjectsLocationsDataStoresBranchesDocumentsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsDataStoresBranchesDocumentsGetCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } +// IfNoneMatch sets the 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. Use googleapi.IsNotModified to check whether the response +// error from Do is the result of In-None-Match. +func (c *ProjectsLocationsDataStoresBranchesDocumentsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsDataStoresBranchesDocumentsGetCall { + c.ifNoneMatch_ = entityTag + return c +} + // Context sets the context to be used in this call's Do method. Any // pending HTTP request will be aborted if the provided context is // canceled. -func (c *ProjectsLocationsCollectionsEnginesConversationsPatchCall) Context(ctx context.Context) *ProjectsLocationsCollectionsEnginesConversationsPatchCall { +func (c *ProjectsLocationsDataStoresBranchesDocumentsGetCall) Context(ctx context.Context) *ProjectsLocationsDataStoresBranchesDocumentsGetCall { c.ctx_ = ctx return c } // Header returns an http.Header that can be modified by the caller to // add HTTP headers to the request. -func (c *ProjectsLocationsCollectionsEnginesConversationsPatchCall) Header() http.Header { +func (c *ProjectsLocationsDataStoresBranchesDocumentsGetCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsCollectionsEnginesConversationsPatchCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsDataStoresBranchesDocumentsGetCall) doRequest(alt string) (*http.Response, error) { reqHeaders := make(http.Header) reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) for k, v := range c.header_ { reqHeaders[k] = v } reqHeaders.Set("User-Agent", c.s.userAgent()) - var body io.Reader = nil - body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddiscoveryenginev1betaconversation) - if err != nil { - return nil, err + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) } - reqHeaders.Set("Content-Type", "application/json") + var body io.Reader = nil 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) + req, err := http.NewRequest("GET", urls, body) if err != nil { return nil, err } @@ -15780,16 +24327,16 @@ func (c *ProjectsLocationsCollectionsEnginesConversationsPatchCall) doRequest(al return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "discoveryengine.projects.locations.collections.engines.conversations.patch" call. -// Exactly one of *GoogleCloudDiscoveryengineV1betaConversation or error +// Do executes the "discoveryengine.projects.locations.dataStores.branches.documents.get" call. +// Exactly one of *GoogleCloudDiscoveryengineV1betaDocument or error // will be non-nil. Any non-2xx status code is an error. Response // headers are in either -// *GoogleCloudDiscoveryengineV1betaConversation.ServerResponse.Header -// or (if a response was returned at all) in +// *GoogleCloudDiscoveryengineV1betaDocument.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 *ProjectsLocationsCollectionsEnginesConversationsPatchCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1betaConversation, error) { +func (c *ProjectsLocationsDataStoresBranchesDocumentsGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1betaDocument, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -15808,7 +24355,7 @@ func (c *ProjectsLocationsCollectionsEnginesConversationsPatchCall) Do(opts ...g if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &GoogleCloudDiscoveryengineV1betaConversation{ + ret := &GoogleCloudDiscoveryengineV1betaDocument{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -15820,34 +24367,25 @@ func (c *ProjectsLocationsCollectionsEnginesConversationsPatchCall) Do(opts ...g } return ret, nil // { - // "description": "Updates a Conversation. Conversation action type cannot be changed. If the Conversation to update does not exist, a NOT_FOUND error is returned.", - // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/engines/{enginesId}/conversations/{conversationsId}", - // "httpMethod": "PATCH", - // "id": "discoveryengine.projects.locations.collections.engines.conversations.patch", + // "description": "Gets a Document.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/branches/{branchesId}/documents/{documentsId}", + // "httpMethod": "GET", + // "id": "discoveryengine.projects.locations.dataStores.branches.documents.get", // "parameterOrder": [ // "name" // ], // "parameters": { // "name": { - // "description": "Immutable. Fully qualified name `project/*/locations/global/collections/{collection}/dataStore/*/conversations/*` or `project/*/locations/global/collections/{collection}/engines/*/conversations/*`.", + // "description": "Required. Full resource name of Document, such as `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/branches/{branch}/documents/{document}`. If the caller does not have permission to access the Document, regardless of whether or not it exists, a `PERMISSION_DENIED` error is returned. If the requested Document does not exist, a `NOT_FOUND` error is returned.", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/engines/[^/]+/conversations/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/dataStores/[^/]+/branches/[^/]+/documents/[^/]+$", // "required": true, // "type": "string" - // }, - // "updateMask": { - // "description": "Indicates which fields in the provided Conversation to update. The following are NOT supported: * Conversation.name If not set or empty, all supported fields are updated.", - // "format": "google-fieldmask", - // "location": "query", - // "type": "string" // } // }, // "path": "v1beta/{+name}", - // "request": { - // "$ref": "GoogleCloudDiscoveryengineV1betaConversation" - // }, // "response": { - // "$ref": "GoogleCloudDiscoveryengineV1betaConversation" + // "$ref": "GoogleCloudDiscoveryengineV1betaDocument" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -15856,97 +24394,93 @@ func (c *ProjectsLocationsCollectionsEnginesConversationsPatchCall) Do(opts ...g } -// method id "discoveryengine.projects.locations.collections.engines.operations.get": +// method id "discoveryengine.projects.locations.dataStores.branches.documents.import": -type ProjectsLocationsCollectionsEnginesOperationsGetCall struct { - s *Service - name string - urlParams_ gensupport.URLParams - ifNoneMatch_ string - ctx_ context.Context - header_ http.Header +type ProjectsLocationsDataStoresBranchesDocumentsImportCall struct { + s *Service + parent string + googleclouddiscoveryenginev1betaimportdocumentsrequest *GoogleCloudDiscoveryengineV1betaImportDocumentsRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// Get: Gets the latest state of a long-running operation. Clients can -// use this method to poll the operation result at intervals as -// recommended by the API service. +// Import: Bulk import of multiple Documents. Request processing may be +// synchronous. Non-existing items will be created. Note: It is possible +// for a subset of the Documents to be successfully updated. // -// - name: The name of the operation resource. -func (r *ProjectsLocationsCollectionsEnginesOperationsService) Get(name string) *ProjectsLocationsCollectionsEnginesOperationsGetCall { - c := &ProjectsLocationsCollectionsEnginesOperationsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.name = name +// - parent: The parent branch resource name, such as +// `projects/{project}/locations/{location}/collections/{collection}/da +// taStores/{data_store}/branches/{branch}`. Requires create/update +// permission. +func (r *ProjectsLocationsDataStoresBranchesDocumentsService) Import(parent string, googleclouddiscoveryenginev1betaimportdocumentsrequest *GoogleCloudDiscoveryengineV1betaImportDocumentsRequest) *ProjectsLocationsDataStoresBranchesDocumentsImportCall { + c := &ProjectsLocationsDataStoresBranchesDocumentsImportCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + c.googleclouddiscoveryenginev1betaimportdocumentsrequest = googleclouddiscoveryenginev1betaimportdocumentsrequest return c } // Fields allows partial responses to be retrieved. See // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse // for more information. -func (c *ProjectsLocationsCollectionsEnginesOperationsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsEnginesOperationsGetCall { +func (c *ProjectsLocationsDataStoresBranchesDocumentsImportCall) Fields(s ...googleapi.Field) *ProjectsLocationsDataStoresBranchesDocumentsImportCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// IfNoneMatch sets the 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. Use googleapi.IsNotModified to check whether the response -// error from Do is the result of In-None-Match. -func (c *ProjectsLocationsCollectionsEnginesOperationsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsCollectionsEnginesOperationsGetCall { - c.ifNoneMatch_ = entityTag - return c -} - // Context sets the context to be used in this call's Do method. Any // pending HTTP request will be aborted if the provided context is // canceled. -func (c *ProjectsLocationsCollectionsEnginesOperationsGetCall) Context(ctx context.Context) *ProjectsLocationsCollectionsEnginesOperationsGetCall { +func (c *ProjectsLocationsDataStoresBranchesDocumentsImportCall) Context(ctx context.Context) *ProjectsLocationsDataStoresBranchesDocumentsImportCall { c.ctx_ = ctx return c } // Header returns an http.Header that can be modified by the caller to // add HTTP headers to the request. -func (c *ProjectsLocationsCollectionsEnginesOperationsGetCall) Header() http.Header { +func (c *ProjectsLocationsDataStoresBranchesDocumentsImportCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsCollectionsEnginesOperationsGetCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsDataStoresBranchesDocumentsImportCall) doRequest(alt string) (*http.Response, error) { reqHeaders := make(http.Header) reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) for k, v := range c.header_ { reqHeaders[k] = v } reqHeaders.Set("User-Agent", c.s.userAgent()) - if c.ifNoneMatch_ != "" { - reqHeaders.Set("If-None-Match", c.ifNoneMatch_) - } var body io.Reader = nil + body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddiscoveryenginev1betaimportdocumentsrequest) + if err != nil { + return nil, err + } + reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+parent}/documents:import") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("GET", urls, body) + req, err := http.NewRequest("POST", urls, body) if err != nil { return nil, err } req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ - "name": c.name, + "parent": c.parent, }) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "discoveryengine.projects.locations.collections.engines.operations.get" call. +// Do executes the "discoveryengine.projects.locations.dataStores.branches.documents.import" call. // Exactly one of *GoogleLongrunningOperation or error will be non-nil. // 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 *ProjectsLocationsCollectionsEnginesOperationsGetCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { +func (c *ProjectsLocationsDataStoresBranchesDocumentsImportCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -15977,23 +24511,26 @@ func (c *ProjectsLocationsCollectionsEnginesOperationsGetCall) Do(opts ...google } return ret, nil // { - // "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": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/engines/{enginesId}/operations/{operationsId}", - // "httpMethod": "GET", - // "id": "discoveryengine.projects.locations.collections.engines.operations.get", + // "description": "Bulk import of multiple Documents. Request processing may be synchronous. Non-existing items will be created. Note: It is possible for a subset of the Documents to be successfully updated.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/branches/{branchesId}/documents:import", + // "httpMethod": "POST", + // "id": "discoveryengine.projects.locations.dataStores.branches.documents.import", // "parameterOrder": [ - // "name" + // "parent" // ], // "parameters": { - // "name": { - // "description": "The name of the operation resource.", + // "parent": { + // "description": "Required. The parent branch resource name, such as `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/branches/{branch}`. Requires create/update permission.", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/engines/[^/]+/operations/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/dataStores/[^/]+/branches/[^/]+$", // "required": true, // "type": "string" // } // }, - // "path": "v1beta/{+name}", + // "path": "v1beta/{+parent}/documents:import", + // "request": { + // "$ref": "GoogleCloudDiscoveryengineV1betaImportDocumentsRequest" + // }, // "response": { // "$ref": "GoogleLongrunningOperation" // }, @@ -16004,45 +24541,48 @@ func (c *ProjectsLocationsCollectionsEnginesOperationsGetCall) Do(opts ...google } -// method id "discoveryengine.projects.locations.collections.engines.operations.list": +// method id "discoveryengine.projects.locations.dataStores.branches.documents.list": -type ProjectsLocationsCollectionsEnginesOperationsListCall struct { +type ProjectsLocationsDataStoresBranchesDocumentsListCall struct { s *Service - name string + parent string urlParams_ gensupport.URLParams ifNoneMatch_ string ctx_ context.Context header_ http.Header } -// List: Lists operations that match the specified filter in the -// request. If the server doesn't support this method, it returns -// `UNIMPLEMENTED`. +// List: Gets a list of Documents. // -// - name: The name of the operation's parent resource. -func (r *ProjectsLocationsCollectionsEnginesOperationsService) List(name string) *ProjectsLocationsCollectionsEnginesOperationsListCall { - c := &ProjectsLocationsCollectionsEnginesOperationsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.name = name - return c -} - -// Filter sets the optional parameter "filter": The standard list -// filter. -func (c *ProjectsLocationsCollectionsEnginesOperationsListCall) Filter(filter string) *ProjectsLocationsCollectionsEnginesOperationsListCall { - c.urlParams_.Set("filter", filter) +// - parent: The parent branch resource name, such as +// `projects/{project}/locations/{location}/collections/{collection}/da +// taStores/{data_store}/branches/{branch}`. Use `default_branch` as +// the branch ID, to list documents under the default branch. If the +// caller does not have permission to list Documents under this +// branch, regardless of whether or not this branch exists, a +// `PERMISSION_DENIED` error is returned. +func (r *ProjectsLocationsDataStoresBranchesDocumentsService) List(parent string) *ProjectsLocationsDataStoresBranchesDocumentsListCall { + c := &ProjectsLocationsDataStoresBranchesDocumentsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent return c } -// PageSize sets the optional parameter "pageSize": The standard list -// page size. -func (c *ProjectsLocationsCollectionsEnginesOperationsListCall) PageSize(pageSize int64) *ProjectsLocationsCollectionsEnginesOperationsListCall { +// PageSize sets the optional parameter "pageSize": Maximum number of +// Documents to return. If unspecified, defaults to 100. The maximum +// allowed value is 1000. Values above 1000 will be coerced to 1000. If +// this field is negative, an `INVALID_ARGUMENT` error is returned. +func (c *ProjectsLocationsDataStoresBranchesDocumentsListCall) PageSize(pageSize int64) *ProjectsLocationsDataStoresBranchesDocumentsListCall { c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) return c } -// PageToken sets the optional parameter "pageToken": The standard list -// page token. -func (c *ProjectsLocationsCollectionsEnginesOperationsListCall) PageToken(pageToken string) *ProjectsLocationsCollectionsEnginesOperationsListCall { +// PageToken sets the optional parameter "pageToken": A page token +// ListDocumentsResponse.next_page_token, received from a previous +// DocumentService.ListDocuments call. Provide this to retrieve the +// subsequent page. When paginating, all other parameters provided to +// DocumentService.ListDocuments must match the call that provided the +// page token. Otherwise, an `INVALID_ARGUMENT` error is returned. +func (c *ProjectsLocationsDataStoresBranchesDocumentsListCall) PageToken(pageToken string) *ProjectsLocationsDataStoresBranchesDocumentsListCall { c.urlParams_.Set("pageToken", pageToken) return c } @@ -16050,7 +24590,7 @@ func (c *ProjectsLocationsCollectionsEnginesOperationsListCall) PageToken(pageTo // Fields allows partial responses to be retrieved. See // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse // for more information. -func (c *ProjectsLocationsCollectionsEnginesOperationsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsEnginesOperationsListCall { +func (c *ProjectsLocationsDataStoresBranchesDocumentsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsDataStoresBranchesDocumentsListCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } @@ -16060,7 +24600,7 @@ func (c *ProjectsLocationsCollectionsEnginesOperationsListCall) Fields(s ...goog // getting updates only after the object has changed since the last // request. Use googleapi.IsNotModified to check whether the response // error from Do is the result of In-None-Match. -func (c *ProjectsLocationsCollectionsEnginesOperationsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsCollectionsEnginesOperationsListCall { +func (c *ProjectsLocationsDataStoresBranchesDocumentsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsDataStoresBranchesDocumentsListCall { c.ifNoneMatch_ = entityTag return c } @@ -16068,21 +24608,21 @@ func (c *ProjectsLocationsCollectionsEnginesOperationsListCall) IfNoneMatch(enti // Context sets the context to be used in this call's Do method. Any // pending HTTP request will be aborted if the provided context is // canceled. -func (c *ProjectsLocationsCollectionsEnginesOperationsListCall) Context(ctx context.Context) *ProjectsLocationsCollectionsEnginesOperationsListCall { +func (c *ProjectsLocationsDataStoresBranchesDocumentsListCall) Context(ctx context.Context) *ProjectsLocationsDataStoresBranchesDocumentsListCall { c.ctx_ = ctx return c } // Header returns an http.Header that can be modified by the caller to // add HTTP headers to the request. -func (c *ProjectsLocationsCollectionsEnginesOperationsListCall) Header() http.Header { +func (c *ProjectsLocationsDataStoresBranchesDocumentsListCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsCollectionsEnginesOperationsListCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsDataStoresBranchesDocumentsListCall) doRequest(alt string) (*http.Response, error) { reqHeaders := make(http.Header) reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) for k, v := range c.header_ { @@ -16095,7 +24635,7 @@ func (c *ProjectsLocationsCollectionsEnginesOperationsListCall) doRequest(alt st var body io.Reader = nil c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}/operations") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+parent}/documents") urls += "?" + c.urlParams_.Encode() req, err := http.NewRequest("GET", urls, body) if err != nil { @@ -16103,20 +24643,21 @@ func (c *ProjectsLocationsCollectionsEnginesOperationsListCall) doRequest(alt st } req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ - "name": c.name, + "parent": c.parent, }) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "discoveryengine.projects.locations.collections.engines.operations.list" call. -// Exactly one of *GoogleLongrunningListOperationsResponse or error will -// be non-nil. Any non-2xx status code is an error. Response headers are -// in either -// *GoogleLongrunningListOperationsResponse.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 *ProjectsLocationsCollectionsEnginesOperationsListCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningListOperationsResponse, error) { +// Do executes the "discoveryengine.projects.locations.dataStores.branches.documents.list" call. +// Exactly one of *GoogleCloudDiscoveryengineV1betaListDocumentsResponse +// or error will be non-nil. Any non-2xx status code is an error. +// Response headers are in either +// *GoogleCloudDiscoveryengineV1betaListDocumentsResponse.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 *ProjectsLocationsDataStoresBranchesDocumentsListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1betaListDocumentsResponse, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -16135,7 +24676,7 @@ func (c *ProjectsLocationsCollectionsEnginesOperationsListCall) Do(opts ...googl if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &GoogleLongrunningListOperationsResponse{ + ret := &GoogleCloudDiscoveryengineV1betaListDocumentsResponse{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -16147,41 +24688,36 @@ func (c *ProjectsLocationsCollectionsEnginesOperationsListCall) Do(opts ...googl } return ret, nil // { - // "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`.", - // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/engines/{enginesId}/operations", + // "description": "Gets a list of Documents.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/branches/{branchesId}/documents", // "httpMethod": "GET", - // "id": "discoveryengine.projects.locations.collections.engines.operations.list", + // "id": "discoveryengine.projects.locations.dataStores.branches.documents.list", // "parameterOrder": [ - // "name" + // "parent" // ], // "parameters": { - // "filter": { - // "description": "The standard list filter.", - // "location": "query", - // "type": "string" - // }, - // "name": { - // "description": "The name of the operation's parent resource.", - // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/engines/[^/]+$", - // "required": true, - // "type": "string" - // }, // "pageSize": { - // "description": "The standard list page size.", + // "description": "Maximum number of Documents to return. If unspecified, defaults to 100. The maximum allowed value is 1000. Values above 1000 will be coerced to 1000. If this field is negative, an `INVALID_ARGUMENT` error is returned.", // "format": "int32", // "location": "query", // "type": "integer" // }, // "pageToken": { - // "description": "The standard list page token.", + // "description": "A page token ListDocumentsResponse.next_page_token, received from a previous DocumentService.ListDocuments call. Provide this to retrieve the subsequent page. When paginating, all other parameters provided to DocumentService.ListDocuments must match the call that provided the page token. Otherwise, an `INVALID_ARGUMENT` error is returned.", // "location": "query", // "type": "string" + // }, + // "parent": { + // "description": "Required. The parent branch resource name, such as `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/branches/{branch}`. Use `default_branch` as the branch ID, to list documents under the default branch. If the caller does not have permission to list Documents under this branch, regardless of whether or not this branch exists, a `PERMISSION_DENIED` error is returned.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/dataStores/[^/]+/branches/[^/]+$", + // "required": true, + // "type": "string" // } // }, - // "path": "v1beta/{+name}/operations", + // "path": "v1beta/{+parent}/documents", // "response": { - // "$ref": "GoogleLongrunningListOperationsResponse" + // "$ref": "GoogleCloudDiscoveryengineV1betaListDocumentsResponse" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -16193,7 +24729,7 @@ func (c *ProjectsLocationsCollectionsEnginesOperationsListCall) Do(opts ...googl // 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 *ProjectsLocationsCollectionsEnginesOperationsListCall) Pages(ctx context.Context, f func(*GoogleLongrunningListOperationsResponse) error) error { +func (c *ProjectsLocationsDataStoresBranchesDocumentsListCall) Pages(ctx context.Context, f func(*GoogleCloudDiscoveryengineV1betaListDocumentsResponse) error) error { c.ctx_ = ctx defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point for { @@ -16211,43 +24747,42 @@ func (c *ProjectsLocationsCollectionsEnginesOperationsListCall) Pages(ctx contex } } -// method id "discoveryengine.projects.locations.collections.engines.servingConfigs.recommend": +// method id "discoveryengine.projects.locations.dataStores.branches.documents.patch": -type ProjectsLocationsCollectionsEnginesServingConfigsRecommendCall struct { - s *Service - servingConfig string - googleclouddiscoveryenginev1betarecommendrequest *GoogleCloudDiscoveryengineV1betaRecommendRequest - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +type ProjectsLocationsDataStoresBranchesDocumentsPatchCall struct { + s *Service + name string + googleclouddiscoveryenginev1betadocument *GoogleCloudDiscoveryengineV1betaDocument + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// Recommend: Makes a recommendation, which requires a contextual user -// event. +// Patch: Updates a Document. // -// - servingConfig: Full resource name of a ServingConfig: -// `projects/*/locations/global/collections/*/engines/*/servingConfigs/ -// *`, or -// `projects/*/locations/global/collections/*/dataStores/*/servingConfi -// gs/*` One default serving config is created along with your -// recommendation engine creation. The engine ID will be used as the -// ID of the default serving config. For example, for Engine -// `projects/*/locations/global/collections/*/engines/my-engine`, you -// can use -// `projects/*/locations/global/collections/*/engines/my-engine/serving -// Configs/my-engine` for your RecommendationService.Recommend -// requests. -func (r *ProjectsLocationsCollectionsEnginesServingConfigsService) Recommend(servingConfig string, googleclouddiscoveryenginev1betarecommendrequest *GoogleCloudDiscoveryengineV1betaRecommendRequest) *ProjectsLocationsCollectionsEnginesServingConfigsRecommendCall { - c := &ProjectsLocationsCollectionsEnginesServingConfigsRecommendCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.servingConfig = servingConfig - c.googleclouddiscoveryenginev1betarecommendrequest = googleclouddiscoveryenginev1betarecommendrequest +// - name: Immutable. The full resource name of the document. Format: +// `projects/{project}/locations/{location}/collections/{collection}/da +// taStores/{data_store}/branches/{branch}/documents/{document_id}`. +// This field must be a UTF-8 encoded string with a length limit of +// 1024 characters. +func (r *ProjectsLocationsDataStoresBranchesDocumentsService) Patch(name string, googleclouddiscoveryenginev1betadocument *GoogleCloudDiscoveryengineV1betaDocument) *ProjectsLocationsDataStoresBranchesDocumentsPatchCall { + c := &ProjectsLocationsDataStoresBranchesDocumentsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + c.googleclouddiscoveryenginev1betadocument = googleclouddiscoveryenginev1betadocument + return c +} + +// AllowMissing sets the optional parameter "allowMissing": If set to +// true, and the Document is not found, a new Document will be created. +func (c *ProjectsLocationsDataStoresBranchesDocumentsPatchCall) AllowMissing(allowMissing bool) *ProjectsLocationsDataStoresBranchesDocumentsPatchCall { + c.urlParams_.Set("allowMissing", fmt.Sprint(allowMissing)) return c } // Fields allows partial responses to be retrieved. See // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse // for more information. -func (c *ProjectsLocationsCollectionsEnginesServingConfigsRecommendCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsEnginesServingConfigsRecommendCall { +func (c *ProjectsLocationsDataStoresBranchesDocumentsPatchCall) Fields(s ...googleapi.Field) *ProjectsLocationsDataStoresBranchesDocumentsPatchCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } @@ -16255,21 +24790,21 @@ func (c *ProjectsLocationsCollectionsEnginesServingConfigsRecommendCall) Fields( // Context sets the context to be used in this call's Do method. Any // pending HTTP request will be aborted if the provided context is // canceled. -func (c *ProjectsLocationsCollectionsEnginesServingConfigsRecommendCall) Context(ctx context.Context) *ProjectsLocationsCollectionsEnginesServingConfigsRecommendCall { +func (c *ProjectsLocationsDataStoresBranchesDocumentsPatchCall) Context(ctx context.Context) *ProjectsLocationsDataStoresBranchesDocumentsPatchCall { c.ctx_ = ctx return c } // Header returns an http.Header that can be modified by the caller to // add HTTP headers to the request. -func (c *ProjectsLocationsCollectionsEnginesServingConfigsRecommendCall) Header() http.Header { +func (c *ProjectsLocationsDataStoresBranchesDocumentsPatchCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsCollectionsEnginesServingConfigsRecommendCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsDataStoresBranchesDocumentsPatchCall) doRequest(alt string) (*http.Response, error) { reqHeaders := make(http.Header) reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) for k, v := range c.header_ { @@ -16277,36 +24812,36 @@ func (c *ProjectsLocationsCollectionsEnginesServingConfigsRecommendCall) doReque } reqHeaders.Set("User-Agent", c.s.userAgent()) var body io.Reader = nil - body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddiscoveryenginev1betarecommendrequest) + body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddiscoveryenginev1betadocument) if err != nil { return nil, err } reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+servingConfig}:recommend") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}") 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{ - "servingConfig": c.servingConfig, + "name": c.name, }) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "discoveryengine.projects.locations.collections.engines.servingConfigs.recommend" call. -// Exactly one of *GoogleCloudDiscoveryengineV1betaRecommendResponse or -// error will be non-nil. Any non-2xx status code is an error. Response +// Do executes the "discoveryengine.projects.locations.dataStores.branches.documents.patch" call. +// Exactly one of *GoogleCloudDiscoveryengineV1betaDocument or error +// will be non-nil. Any non-2xx status code is an error. Response // headers are in either -// *GoogleCloudDiscoveryengineV1betaRecommendResponse.ServerResponse.Head -// er or (if a response was returned at all) in +// *GoogleCloudDiscoveryengineV1betaDocument.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 *ProjectsLocationsCollectionsEnginesServingConfigsRecommendCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1betaRecommendResponse, error) { +func (c *ProjectsLocationsDataStoresBranchesDocumentsPatchCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1betaDocument, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -16325,7 +24860,7 @@ func (c *ProjectsLocationsCollectionsEnginesServingConfigsRecommendCall) Do(opts if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &GoogleCloudDiscoveryengineV1betaRecommendResponse{ + ret := &GoogleCloudDiscoveryengineV1betaDocument{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -16337,28 +24872,33 @@ func (c *ProjectsLocationsCollectionsEnginesServingConfigsRecommendCall) Do(opts } return ret, nil // { - // "description": "Makes a recommendation, which requires a contextual user event.", - // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/engines/{enginesId}/servingConfigs/{servingConfigsId}:recommend", - // "httpMethod": "POST", - // "id": "discoveryengine.projects.locations.collections.engines.servingConfigs.recommend", + // "description": "Updates a Document.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/branches/{branchesId}/documents/{documentsId}", + // "httpMethod": "PATCH", + // "id": "discoveryengine.projects.locations.dataStores.branches.documents.patch", // "parameterOrder": [ - // "servingConfig" + // "name" // ], // "parameters": { - // "servingConfig": { - // "description": "Required. Full resource name of a ServingConfig: `projects/*/locations/global/collections/*/engines/*/servingConfigs/*`, or `projects/*/locations/global/collections/*/dataStores/*/servingConfigs/*` One default serving config is created along with your recommendation engine creation. The engine ID will be used as the ID of the default serving config. For example, for Engine `projects/*/locations/global/collections/*/engines/my-engine`, you can use `projects/*/locations/global/collections/*/engines/my-engine/servingConfigs/my-engine` for your RecommendationService.Recommend requests.", + // "allowMissing": { + // "description": "If set to true, and the Document is not found, a new Document will be created.", + // "location": "query", + // "type": "boolean" + // }, + // "name": { + // "description": "Immutable. The full resource name of the document. Format: `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/branches/{branch}/documents/{document_id}`. This field must be a UTF-8 encoded string with a length limit of 1024 characters.", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/engines/[^/]+/servingConfigs/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/dataStores/[^/]+/branches/[^/]+/documents/[^/]+$", // "required": true, // "type": "string" // } // }, - // "path": "v1beta/{+servingConfig}:recommend", + // "path": "v1beta/{+name}", // "request": { - // "$ref": "GoogleCloudDiscoveryengineV1betaRecommendRequest" + // "$ref": "GoogleCloudDiscoveryengineV1betaDocument" // }, // "response": { - // "$ref": "GoogleCloudDiscoveryengineV1betaRecommendResponse" + // "$ref": "GoogleCloudDiscoveryengineV1betaDocument" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -16367,38 +24907,39 @@ func (c *ProjectsLocationsCollectionsEnginesServingConfigsRecommendCall) Do(opts } -// method id "discoveryengine.projects.locations.collections.engines.servingConfigs.search": +// method id "discoveryengine.projects.locations.dataStores.branches.documents.purge": -type ProjectsLocationsCollectionsEnginesServingConfigsSearchCall struct { - s *Service - servingConfig string - googleclouddiscoveryenginev1betasearchrequest *GoogleCloudDiscoveryengineV1betaSearchRequest - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +type ProjectsLocationsDataStoresBranchesDocumentsPurgeCall struct { + s *Service + parent string + googleclouddiscoveryenginev1betapurgedocumentsrequest *GoogleCloudDiscoveryengineV1betaPurgeDocumentsRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// Search: Performs a search. +// Purge: Permanently deletes all selected Documents in a branch. This +// process is asynchronous. Depending on the number of Documents to be +// deleted, this operation can take hours to complete. Before the delete +// operation completes, some Documents might still be returned by +// DocumentService.GetDocument or DocumentService.ListDocuments. To get +// a list of the Documents to be deleted, set +// PurgeDocumentsRequest.force to false. // -// - servingConfig: The resource name of the Search serving config, such -// as -// `projects/*/locations/global/collections/default_collection/engines/ -// */servingConfigs/default_serving_config`, or -// `projects/*/locations/global/collections/default_collection/dataStor -// es/default_data_store/servingConfigs/default_serving_config`. This -// field is used to identify the serving configuration name, set of -// models used to make the search. -func (r *ProjectsLocationsCollectionsEnginesServingConfigsService) Search(servingConfig string, googleclouddiscoveryenginev1betasearchrequest *GoogleCloudDiscoveryengineV1betaSearchRequest) *ProjectsLocationsCollectionsEnginesServingConfigsSearchCall { - c := &ProjectsLocationsCollectionsEnginesServingConfigsSearchCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.servingConfig = servingConfig - c.googleclouddiscoveryenginev1betasearchrequest = googleclouddiscoveryenginev1betasearchrequest +// - parent: The parent resource name, such as +// `projects/{project}/locations/{location}/collections/{collection}/da +// taStores/{data_store}/branches/{branch}`. +func (r *ProjectsLocationsDataStoresBranchesDocumentsService) Purge(parent string, googleclouddiscoveryenginev1betapurgedocumentsrequest *GoogleCloudDiscoveryengineV1betaPurgeDocumentsRequest) *ProjectsLocationsDataStoresBranchesDocumentsPurgeCall { + c := &ProjectsLocationsDataStoresBranchesDocumentsPurgeCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + c.googleclouddiscoveryenginev1betapurgedocumentsrequest = googleclouddiscoveryenginev1betapurgedocumentsrequest return c } // Fields allows partial responses to be retrieved. See // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse // for more information. -func (c *ProjectsLocationsCollectionsEnginesServingConfigsSearchCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsEnginesServingConfigsSearchCall { +func (c *ProjectsLocationsDataStoresBranchesDocumentsPurgeCall) Fields(s ...googleapi.Field) *ProjectsLocationsDataStoresBranchesDocumentsPurgeCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } @@ -16406,21 +24947,21 @@ func (c *ProjectsLocationsCollectionsEnginesServingConfigsSearchCall) Fields(s . // Context sets the context to be used in this call's Do method. Any // pending HTTP request will be aborted if the provided context is // canceled. -func (c *ProjectsLocationsCollectionsEnginesServingConfigsSearchCall) Context(ctx context.Context) *ProjectsLocationsCollectionsEnginesServingConfigsSearchCall { +func (c *ProjectsLocationsDataStoresBranchesDocumentsPurgeCall) Context(ctx context.Context) *ProjectsLocationsDataStoresBranchesDocumentsPurgeCall { c.ctx_ = ctx return c } // Header returns an http.Header that can be modified by the caller to // add HTTP headers to the request. -func (c *ProjectsLocationsCollectionsEnginesServingConfigsSearchCall) Header() http.Header { +func (c *ProjectsLocationsDataStoresBranchesDocumentsPurgeCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsCollectionsEnginesServingConfigsSearchCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsDataStoresBranchesDocumentsPurgeCall) doRequest(alt string) (*http.Response, error) { reqHeaders := make(http.Header) reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) for k, v := range c.header_ { @@ -16428,14 +24969,14 @@ func (c *ProjectsLocationsCollectionsEnginesServingConfigsSearchCall) doRequest( } reqHeaders.Set("User-Agent", c.s.userAgent()) var body io.Reader = nil - body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddiscoveryenginev1betasearchrequest) + body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddiscoveryenginev1betapurgedocumentsrequest) if err != nil { return nil, err } reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+servingConfig}:search") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+parent}/documents:purge") urls += "?" + c.urlParams_.Encode() req, err := http.NewRequest("POST", urls, body) if err != nil { @@ -16443,21 +24984,19 @@ func (c *ProjectsLocationsCollectionsEnginesServingConfigsSearchCall) doRequest( } req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ - "servingConfig": c.servingConfig, + "parent": c.parent, }) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "discoveryengine.projects.locations.collections.engines.servingConfigs.search" call. -// Exactly one of *GoogleCloudDiscoveryengineV1betaSearchResponse or -// error will be non-nil. Any non-2xx status code is an error. Response -// headers are in either -// *GoogleCloudDiscoveryengineV1betaSearchResponse.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 *ProjectsLocationsCollectionsEnginesServingConfigsSearchCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1betaSearchResponse, error) { +// Do executes the "discoveryengine.projects.locations.dataStores.branches.documents.purge" call. +// Exactly one of *GoogleLongrunningOperation or error will be non-nil. +// 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 *ProjectsLocationsDataStoresBranchesDocumentsPurgeCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -16476,7 +25015,7 @@ func (c *ProjectsLocationsCollectionsEnginesServingConfigsSearchCall) Do(opts .. if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &GoogleCloudDiscoveryengineV1betaSearchResponse{ + ret := &GoogleLongrunningOperation{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -16488,28 +25027,28 @@ func (c *ProjectsLocationsCollectionsEnginesServingConfigsSearchCall) Do(opts .. } return ret, nil // { - // "description": "Performs a search.", - // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/engines/{enginesId}/servingConfigs/{servingConfigsId}:search", + // "description": "Permanently deletes all selected Documents in a branch. This process is asynchronous. Depending on the number of Documents to be deleted, this operation can take hours to complete. Before the delete operation completes, some Documents might still be returned by DocumentService.GetDocument or DocumentService.ListDocuments. To get a list of the Documents to be deleted, set PurgeDocumentsRequest.force to false.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/branches/{branchesId}/documents:purge", // "httpMethod": "POST", - // "id": "discoveryengine.projects.locations.collections.engines.servingConfigs.search", + // "id": "discoveryengine.projects.locations.dataStores.branches.documents.purge", // "parameterOrder": [ - // "servingConfig" + // "parent" // ], // "parameters": { - // "servingConfig": { - // "description": "Required. The resource name of the Search serving config, such as `projects/*/locations/global/collections/default_collection/engines/*/servingConfigs/default_serving_config`, or `projects/*/locations/global/collections/default_collection/dataStores/default_data_store/servingConfigs/default_serving_config`. This field is used to identify the serving configuration name, set of models used to make the search.", + // "parent": { + // "description": "Required. The parent resource name, such as `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/branches/{branch}`.", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/engines/[^/]+/servingConfigs/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/dataStores/[^/]+/branches/[^/]+$", // "required": true, // "type": "string" // } // }, - // "path": "v1beta/{+servingConfig}:search", + // "path": "v1beta/{+parent}/documents:purge", // "request": { - // "$ref": "GoogleCloudDiscoveryengineV1betaSearchRequest" + // "$ref": "GoogleCloudDiscoveryengineV1betaPurgeDocumentsRequest" // }, // "response": { - // "$ref": "GoogleCloudDiscoveryengineV1betaSearchResponse" + // "$ref": "GoogleLongrunningOperation" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -16518,30 +25057,9 @@ func (c *ProjectsLocationsCollectionsEnginesServingConfigsSearchCall) Do(opts .. } -// 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 *ProjectsLocationsCollectionsEnginesServingConfigsSearchCall) Pages(ctx context.Context, f func(*GoogleCloudDiscoveryengineV1betaSearchResponse) error) error { - c.ctx_ = ctx - defer func(pt string) { c.googleclouddiscoveryenginev1betasearchrequest.PageToken = pt }(c.googleclouddiscoveryenginev1betasearchrequest.PageToken) // reset paging to original point - for { - x, err := c.Do() - if err != nil { - return err - } - if err := f(x); err != nil { - return err - } - if x.NextPageToken == "" { - return nil - } - c.googleclouddiscoveryenginev1betasearchrequest.PageToken = x.NextPageToken - } -} - -// method id "discoveryengine.projects.locations.collections.operations.get": +// method id "discoveryengine.projects.locations.dataStores.branches.operations.get": -type ProjectsLocationsCollectionsOperationsGetCall struct { +type ProjectsLocationsDataStoresBranchesOperationsGetCall struct { s *Service name string urlParams_ gensupport.URLParams @@ -16555,8 +25073,8 @@ type ProjectsLocationsCollectionsOperationsGetCall struct { // recommended by the API service. // // - name: The name of the operation resource. -func (r *ProjectsLocationsCollectionsOperationsService) Get(name string) *ProjectsLocationsCollectionsOperationsGetCall { - c := &ProjectsLocationsCollectionsOperationsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} +func (r *ProjectsLocationsDataStoresBranchesOperationsService) Get(name string) *ProjectsLocationsDataStoresBranchesOperationsGetCall { + c := &ProjectsLocationsDataStoresBranchesOperationsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.name = name return c } @@ -16564,7 +25082,7 @@ func (r *ProjectsLocationsCollectionsOperationsService) Get(name string) *Projec // Fields allows partial responses to be retrieved. See // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse // for more information. -func (c *ProjectsLocationsCollectionsOperationsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsOperationsGetCall { +func (c *ProjectsLocationsDataStoresBranchesOperationsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsDataStoresBranchesOperationsGetCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } @@ -16574,7 +25092,7 @@ func (c *ProjectsLocationsCollectionsOperationsGetCall) Fields(s ...googleapi.Fi // getting updates only after the object has changed since the last // request. Use googleapi.IsNotModified to check whether the response // error from Do is the result of In-None-Match. -func (c *ProjectsLocationsCollectionsOperationsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsCollectionsOperationsGetCall { +func (c *ProjectsLocationsDataStoresBranchesOperationsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsDataStoresBranchesOperationsGetCall { c.ifNoneMatch_ = entityTag return c } @@ -16582,21 +25100,21 @@ func (c *ProjectsLocationsCollectionsOperationsGetCall) IfNoneMatch(entityTag st // Context sets the context to be used in this call's Do method. Any // pending HTTP request will be aborted if the provided context is // canceled. -func (c *ProjectsLocationsCollectionsOperationsGetCall) Context(ctx context.Context) *ProjectsLocationsCollectionsOperationsGetCall { +func (c *ProjectsLocationsDataStoresBranchesOperationsGetCall) Context(ctx context.Context) *ProjectsLocationsDataStoresBranchesOperationsGetCall { c.ctx_ = ctx return c } // Header returns an http.Header that can be modified by the caller to // add HTTP headers to the request. -func (c *ProjectsLocationsCollectionsOperationsGetCall) Header() http.Header { +func (c *ProjectsLocationsDataStoresBranchesOperationsGetCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsCollectionsOperationsGetCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsDataStoresBranchesOperationsGetCall) doRequest(alt string) (*http.Response, error) { reqHeaders := make(http.Header) reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) for k, v := range c.header_ { @@ -16622,14 +25140,14 @@ func (c *ProjectsLocationsCollectionsOperationsGetCall) doRequest(alt string) (* return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "discoveryengine.projects.locations.collections.operations.get" call. +// Do executes the "discoveryengine.projects.locations.dataStores.branches.operations.get" call. // Exactly one of *GoogleLongrunningOperation or error will be non-nil. // 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 *ProjectsLocationsCollectionsOperationsGetCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { +func (c *ProjectsLocationsDataStoresBranchesOperationsGetCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -16661,9 +25179,9 @@ func (c *ProjectsLocationsCollectionsOperationsGetCall) Do(opts ...googleapi.Cal return ret, nil // { // "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": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/operations/{operationsId}", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/branches/{branchesId}/operations/{operationsId}", // "httpMethod": "GET", - // "id": "discoveryengine.projects.locations.collections.operations.get", + // "id": "discoveryengine.projects.locations.dataStores.branches.operations.get", // "parameterOrder": [ // "name" // ], @@ -16671,7 +25189,7 @@ func (c *ProjectsLocationsCollectionsOperationsGetCall) Do(opts ...googleapi.Cal // "name": { // "description": "The name of the operation resource.", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/operations/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/dataStores/[^/]+/branches/[^/]+/operations/[^/]+$", // "required": true, // "type": "string" // } @@ -16687,9 +25205,9 @@ func (c *ProjectsLocationsCollectionsOperationsGetCall) Do(opts ...googleapi.Cal } -// method id "discoveryengine.projects.locations.collections.operations.list": +// method id "discoveryengine.projects.locations.dataStores.branches.operations.list": -type ProjectsLocationsCollectionsOperationsListCall struct { +type ProjectsLocationsDataStoresBranchesOperationsListCall struct { s *Service name string urlParams_ gensupport.URLParams @@ -16703,29 +25221,29 @@ type ProjectsLocationsCollectionsOperationsListCall struct { // `UNIMPLEMENTED`. // // - name: The name of the operation's parent resource. -func (r *ProjectsLocationsCollectionsOperationsService) List(name string) *ProjectsLocationsCollectionsOperationsListCall { - c := &ProjectsLocationsCollectionsOperationsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} +func (r *ProjectsLocationsDataStoresBranchesOperationsService) List(name string) *ProjectsLocationsDataStoresBranchesOperationsListCall { + c := &ProjectsLocationsDataStoresBranchesOperationsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.name = name return c } // Filter sets the optional parameter "filter": The standard list // filter. -func (c *ProjectsLocationsCollectionsOperationsListCall) Filter(filter string) *ProjectsLocationsCollectionsOperationsListCall { +func (c *ProjectsLocationsDataStoresBranchesOperationsListCall) Filter(filter string) *ProjectsLocationsDataStoresBranchesOperationsListCall { c.urlParams_.Set("filter", filter) return c } // PageSize sets the optional parameter "pageSize": The standard list // page size. -func (c *ProjectsLocationsCollectionsOperationsListCall) PageSize(pageSize int64) *ProjectsLocationsCollectionsOperationsListCall { +func (c *ProjectsLocationsDataStoresBranchesOperationsListCall) PageSize(pageSize int64) *ProjectsLocationsDataStoresBranchesOperationsListCall { c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) return c } // PageToken sets the optional parameter "pageToken": The standard list // page token. -func (c *ProjectsLocationsCollectionsOperationsListCall) PageToken(pageToken string) *ProjectsLocationsCollectionsOperationsListCall { +func (c *ProjectsLocationsDataStoresBranchesOperationsListCall) PageToken(pageToken string) *ProjectsLocationsDataStoresBranchesOperationsListCall { c.urlParams_.Set("pageToken", pageToken) return c } @@ -16733,7 +25251,7 @@ func (c *ProjectsLocationsCollectionsOperationsListCall) PageToken(pageToken str // Fields allows partial responses to be retrieved. See // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse // for more information. -func (c *ProjectsLocationsCollectionsOperationsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsOperationsListCall { +func (c *ProjectsLocationsDataStoresBranchesOperationsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsDataStoresBranchesOperationsListCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } @@ -16743,7 +25261,7 @@ func (c *ProjectsLocationsCollectionsOperationsListCall) Fields(s ...googleapi.F // getting updates only after the object has changed since the last // request. Use googleapi.IsNotModified to check whether the response // error from Do is the result of In-None-Match. -func (c *ProjectsLocationsCollectionsOperationsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsCollectionsOperationsListCall { +func (c *ProjectsLocationsDataStoresBranchesOperationsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsDataStoresBranchesOperationsListCall { c.ifNoneMatch_ = entityTag return c } @@ -16751,21 +25269,21 @@ func (c *ProjectsLocationsCollectionsOperationsListCall) IfNoneMatch(entityTag s // Context sets the context to be used in this call's Do method. Any // pending HTTP request will be aborted if the provided context is // canceled. -func (c *ProjectsLocationsCollectionsOperationsListCall) Context(ctx context.Context) *ProjectsLocationsCollectionsOperationsListCall { +func (c *ProjectsLocationsDataStoresBranchesOperationsListCall) Context(ctx context.Context) *ProjectsLocationsDataStoresBranchesOperationsListCall { c.ctx_ = ctx return c } // Header returns an http.Header that can be modified by the caller to // add HTTP headers to the request. -func (c *ProjectsLocationsCollectionsOperationsListCall) Header() http.Header { +func (c *ProjectsLocationsDataStoresBranchesOperationsListCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsCollectionsOperationsListCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsDataStoresBranchesOperationsListCall) doRequest(alt string) (*http.Response, error) { reqHeaders := make(http.Header) reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) for k, v := range c.header_ { @@ -16791,7 +25309,7 @@ func (c *ProjectsLocationsCollectionsOperationsListCall) doRequest(alt string) ( return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "discoveryengine.projects.locations.collections.operations.list" call. +// Do executes the "discoveryengine.projects.locations.dataStores.branches.operations.list" call. // Exactly one of *GoogleLongrunningListOperationsResponse or error will // be non-nil. Any non-2xx status code is an error. Response headers are // in either @@ -16799,7 +25317,7 @@ func (c *ProjectsLocationsCollectionsOperationsListCall) doRequest(alt string) ( // 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 *ProjectsLocationsCollectionsOperationsListCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningListOperationsResponse, error) { +func (c *ProjectsLocationsDataStoresBranchesOperationsListCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningListOperationsResponse, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -16831,9 +25349,9 @@ func (c *ProjectsLocationsCollectionsOperationsListCall) Do(opts ...googleapi.Ca return ret, nil // { // "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`.", - // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/operations", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/branches/{branchesId}/operations", // "httpMethod": "GET", - // "id": "discoveryengine.projects.locations.collections.operations.list", + // "id": "discoveryengine.projects.locations.dataStores.branches.operations.list", // "parameterOrder": [ // "name" // ], @@ -16846,7 +25364,7 @@ func (c *ProjectsLocationsCollectionsOperationsListCall) Do(opts ...googleapi.Ca // "name": { // "description": "The name of the operation's parent resource.", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/dataStores/[^/]+/branches/[^/]+$", // "required": true, // "type": "string" // }, @@ -16876,7 +25394,7 @@ func (c *ProjectsLocationsCollectionsOperationsListCall) Do(opts ...googleapi.Ca // 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 *ProjectsLocationsCollectionsOperationsListCall) Pages(ctx context.Context, f func(*GoogleLongrunningListOperationsResponse) error) error { +func (c *ProjectsLocationsDataStoresBranchesOperationsListCall) Pages(ctx context.Context, f func(*GoogleLongrunningListOperationsResponse) error) error { c.ctx_ = ctx defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point for { @@ -16894,149 +25412,98 @@ func (c *ProjectsLocationsCollectionsOperationsListCall) Pages(ctx context.Conte } } -// method id "discoveryengine.projects.locations.dataStores.completeQuery": +// method id "discoveryengine.projects.locations.dataStores.conversations.converse": -type ProjectsLocationsDataStoresCompleteQueryCall struct { - s *Service - dataStore string - urlParams_ gensupport.URLParams - ifNoneMatch_ string - ctx_ context.Context - header_ http.Header +type ProjectsLocationsDataStoresConversationsConverseCall struct { + s *Service + name string + googleclouddiscoveryenginev1betaconverseconversationrequest *GoogleCloudDiscoveryengineV1betaConverseConversationRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// CompleteQuery: Completes the specified user input with keyword -// suggestions. +// Converse: Converses a conversation. // -// - dataStore: The parent data store resource name for which the -// completion is performed, such as -// `projects/*/locations/global/collections/default_collection/dataStor -// es/default_data_store`. -func (r *ProjectsLocationsDataStoresService) CompleteQuery(dataStore string) *ProjectsLocationsDataStoresCompleteQueryCall { - c := &ProjectsLocationsDataStoresCompleteQueryCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.dataStore = dataStore - return c -} - -// IncludeTailSuggestions sets the optional parameter -// "includeTailSuggestions": Indicates if tail suggestions should be -// returned if there are no suggestions that match the full query. Even -// if set to true, if there are suggestions that match the full query, -// those are returned and no tail suggestions are returned. -func (c *ProjectsLocationsDataStoresCompleteQueryCall) IncludeTailSuggestions(includeTailSuggestions bool) *ProjectsLocationsDataStoresCompleteQueryCall { - c.urlParams_.Set("includeTailSuggestions", fmt.Sprint(includeTailSuggestions)) - return c -} - -// Query sets the optional parameter "query": Required. The typeahead -// input used to fetch suggestions. Maximum length is 128 characters. -func (c *ProjectsLocationsDataStoresCompleteQueryCall) Query(query string) *ProjectsLocationsDataStoresCompleteQueryCall { - c.urlParams_.Set("query", query) - return c -} - -// QueryModel sets the optional parameter "queryModel": Selects data -// model of query suggestions for serving. Currently supported values: * -// `document` - Using suggestions generated from user-imported -// documents. * `search-history` - Using suggestions generated from the -// past history of SearchService.Search API calls. Do not use it when -// there is no traffic for Search API. * `user-event` - Using -// suggestions generated from user-imported search events. * -// `document-completable` - Using suggestions taken directly from -// user-imported document fields marked as completable. Default values: -// * `document` is the default model for regular dataStores. * -// `search-history` is the default model for site search dataStores. -func (c *ProjectsLocationsDataStoresCompleteQueryCall) QueryModel(queryModel string) *ProjectsLocationsDataStoresCompleteQueryCall { - c.urlParams_.Set("queryModel", queryModel) - return c -} - -// UserPseudoId sets the optional parameter "userPseudoId": A unique -// identifier for tracking visitors. For example, this could be -// implemented with an HTTP cookie, which should be able to uniquely -// identify a visitor on a single device. This unique identifier should -// not change if the visitor logs in or out of the website. This field -// should NOT have a fixed value such as `unknown_visitor`. This should -// be the same identifier as UserEvent.user_pseudo_id and -// SearchRequest.user_pseudo_id. The field must be a UTF-8 encoded -// string with a length limit of 128 characters. Otherwise, an -// `INVALID_ARGUMENT` error is returned. -func (c *ProjectsLocationsDataStoresCompleteQueryCall) UserPseudoId(userPseudoId string) *ProjectsLocationsDataStoresCompleteQueryCall { - c.urlParams_.Set("userPseudoId", userPseudoId) +// - name: The resource name of the Conversation to get. Format: +// `projects/{project_number}/locations/{location_id}/collections/{coll +// ection}/dataStores/{data_store_id}/conversations/{conversation_id}`. +// Use +// `projects/{project_number}/locations/{location_id}/collections/{coll +// ection}/dataStores/{data_store_id}/conversations/-` to activate +// auto session mode, which automatically creates a new conversation +// inside a ConverseConversation session. +func (r *ProjectsLocationsDataStoresConversationsService) Converse(name string, googleclouddiscoveryenginev1betaconverseconversationrequest *GoogleCloudDiscoveryengineV1betaConverseConversationRequest) *ProjectsLocationsDataStoresConversationsConverseCall { + c := &ProjectsLocationsDataStoresConversationsConverseCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + c.googleclouddiscoveryenginev1betaconverseconversationrequest = googleclouddiscoveryenginev1betaconverseconversationrequest return c } // Fields allows partial responses to be retrieved. See // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse // for more information. -func (c *ProjectsLocationsDataStoresCompleteQueryCall) Fields(s ...googleapi.Field) *ProjectsLocationsDataStoresCompleteQueryCall { +func (c *ProjectsLocationsDataStoresConversationsConverseCall) Fields(s ...googleapi.Field) *ProjectsLocationsDataStoresConversationsConverseCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// IfNoneMatch sets the 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. Use googleapi.IsNotModified to check whether the response -// error from Do is the result of In-None-Match. -func (c *ProjectsLocationsDataStoresCompleteQueryCall) IfNoneMatch(entityTag string) *ProjectsLocationsDataStoresCompleteQueryCall { - c.ifNoneMatch_ = entityTag - return c -} - // Context sets the context to be used in this call's Do method. Any // pending HTTP request will be aborted if the provided context is // canceled. -func (c *ProjectsLocationsDataStoresCompleteQueryCall) Context(ctx context.Context) *ProjectsLocationsDataStoresCompleteQueryCall { +func (c *ProjectsLocationsDataStoresConversationsConverseCall) Context(ctx context.Context) *ProjectsLocationsDataStoresConversationsConverseCall { c.ctx_ = ctx return c } // Header returns an http.Header that can be modified by the caller to // add HTTP headers to the request. -func (c *ProjectsLocationsDataStoresCompleteQueryCall) Header() http.Header { +func (c *ProjectsLocationsDataStoresConversationsConverseCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsDataStoresCompleteQueryCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsDataStoresConversationsConverseCall) doRequest(alt string) (*http.Response, error) { reqHeaders := make(http.Header) reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) for k, v := range c.header_ { reqHeaders[k] = v } reqHeaders.Set("User-Agent", c.s.userAgent()) - if c.ifNoneMatch_ != "" { - reqHeaders.Set("If-None-Match", c.ifNoneMatch_) - } var body io.Reader = nil + body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddiscoveryenginev1betaconverseconversationrequest) + if err != nil { + return nil, err + } + reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+dataStore}:completeQuery") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}:converse") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("GET", urls, body) + req, err := http.NewRequest("POST", urls, body) if err != nil { return nil, err } req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ - "dataStore": c.dataStore, + "name": c.name, }) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "discoveryengine.projects.locations.dataStores.completeQuery" call. -// Exactly one of *GoogleCloudDiscoveryengineV1betaCompleteQueryResponse -// or error will be non-nil. Any non-2xx status code is an error. -// Response headers are in either -// *GoogleCloudDiscoveryengineV1betaCompleteQueryResponse.ServerResponse. -// Header or (if a response was returned at all) in +// Do executes the "discoveryengine.projects.locations.dataStores.conversations.converse" call. +// Exactly one of +// *GoogleCloudDiscoveryengineV1betaConverseConversationResponse or +// error will be non-nil. Any non-2xx status code is an error. Response +// headers are in either +// *GoogleCloudDiscoveryengineV1betaConverseConversationResponse.ServerRe +// sponse.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 *ProjectsLocationsDataStoresCompleteQueryCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1betaCompleteQueryResponse, error) { +func (c *ProjectsLocationsDataStoresConversationsConverseCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1betaConverseConversationResponse, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -17055,7 +25522,7 @@ func (c *ProjectsLocationsDataStoresCompleteQueryCall) Do(opts ...googleapi.Call if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &GoogleCloudDiscoveryengineV1betaCompleteQueryResponse{ + ret := &GoogleCloudDiscoveryengineV1betaConverseConversationResponse{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -17067,45 +25534,28 @@ func (c *ProjectsLocationsDataStoresCompleteQueryCall) Do(opts ...googleapi.Call } return ret, nil // { - // "description": "Completes the specified user input with keyword suggestions.", - // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}:completeQuery", - // "httpMethod": "GET", - // "id": "discoveryengine.projects.locations.dataStores.completeQuery", + // "description": "Converses a conversation.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/conversations/{conversationsId}:converse", + // "httpMethod": "POST", + // "id": "discoveryengine.projects.locations.dataStores.conversations.converse", // "parameterOrder": [ - // "dataStore" + // "name" // ], // "parameters": { - // "dataStore": { - // "description": "Required. The parent data store resource name for which the completion is performed, such as `projects/*/locations/global/collections/default_collection/dataStores/default_data_store`.", + // "name": { + // "description": "Required. The resource name of the Conversation to get. Format: `projects/{project_number}/locations/{location_id}/collections/{collection}/dataStores/{data_store_id}/conversations/{conversation_id}`. Use `projects/{project_number}/locations/{location_id}/collections/{collection}/dataStores/{data_store_id}/conversations/-` to activate auto session mode, which automatically creates a new conversation inside a ConverseConversation session.", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/dataStores/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/dataStores/[^/]+/conversations/[^/]+$", // "required": true, // "type": "string" - // }, - // "includeTailSuggestions": { - // "description": "Indicates if tail suggestions should be returned if there are no suggestions that match the full query. Even if set to true, if there are suggestions that match the full query, those are returned and no tail suggestions are returned.", - // "location": "query", - // "type": "boolean" - // }, - // "query": { - // "description": "Required. The typeahead input used to fetch suggestions. Maximum length is 128 characters.", - // "location": "query", - // "type": "string" - // }, - // "queryModel": { - // "description": "Selects data model of query suggestions for serving. Currently supported values: * `document` - Using suggestions generated from user-imported documents. * `search-history` - Using suggestions generated from the past history of SearchService.Search API calls. Do not use it when there is no traffic for Search API. * `user-event` - Using suggestions generated from user-imported search events. * `document-completable` - Using suggestions taken directly from user-imported document fields marked as completable. Default values: * `document` is the default model for regular dataStores. * `search-history` is the default model for site search dataStores.", - // "location": "query", - // "type": "string" - // }, - // "userPseudoId": { - // "description": "A unique identifier for tracking visitors. For example, this could be implemented with an HTTP cookie, which should be able to uniquely identify a visitor on a single device. This unique identifier should not change if the visitor logs in or out of the website. This field should NOT have a fixed value such as `unknown_visitor`. This should be the same identifier as UserEvent.user_pseudo_id and SearchRequest.user_pseudo_id. The field must be a UTF-8 encoded string with a length limit of 128 characters. Otherwise, an `INVALID_ARGUMENT` error is returned.", - // "location": "query", - // "type": "string" // } // }, - // "path": "v1beta/{+dataStore}:completeQuery", + // "path": "v1beta/{+name}:converse", + // "request": { + // "$ref": "GoogleCloudDiscoveryengineV1betaConverseConversationRequest" + // }, // "response": { - // "$ref": "GoogleCloudDiscoveryengineV1betaCompleteQueryResponse" + // "$ref": "GoogleCloudDiscoveryengineV1betaConverseConversationResponse" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -17114,48 +25564,34 @@ func (c *ProjectsLocationsDataStoresCompleteQueryCall) Do(opts ...googleapi.Call } -// method id "discoveryengine.projects.locations.dataStores.branches.documents.create": +// method id "discoveryengine.projects.locations.dataStores.conversations.create": -type ProjectsLocationsDataStoresBranchesDocumentsCreateCall struct { - s *Service - parent string - googleclouddiscoveryenginev1betadocument *GoogleCloudDiscoveryengineV1betaDocument - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +type ProjectsLocationsDataStoresConversationsCreateCall struct { + s *Service + parent string + googleclouddiscoveryenginev1betaconversation *GoogleCloudDiscoveryengineV1betaConversation + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// Create: Creates a Document. +// Create: Creates a Conversation. If the Conversation to create already +// exists, an ALREADY_EXISTS error is returned. // -// - parent: The parent resource name, such as -// `projects/{project}/locations/{location}/collections/{collection}/da -// taStores/{data_store}/branches/{branch}`. -func (r *ProjectsLocationsDataStoresBranchesDocumentsService) Create(parent string, googleclouddiscoveryenginev1betadocument *GoogleCloudDiscoveryengineV1betaDocument) *ProjectsLocationsDataStoresBranchesDocumentsCreateCall { - c := &ProjectsLocationsDataStoresBranchesDocumentsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.parent = parent - c.googleclouddiscoveryenginev1betadocument = googleclouddiscoveryenginev1betadocument - return c -} - -// DocumentId sets the optional parameter "documentId": Required. The ID -// to use for the Document, which will become the final component of the -// Document.name. If the caller does not have permission to create the -// Document, regardless of whether or not it exists, a -// `PERMISSION_DENIED` error is returned. This field must be unique -// among all Documents with the same parent. Otherwise, an -// `ALREADY_EXISTS` error is returned. This field must conform to -// RFC-1034 (https://tools.ietf.org/html/rfc1034) standard with a length -// limit of 63 characters. Otherwise, an `INVALID_ARGUMENT` error is -// returned. -func (c *ProjectsLocationsDataStoresBranchesDocumentsCreateCall) DocumentId(documentId string) *ProjectsLocationsDataStoresBranchesDocumentsCreateCall { - c.urlParams_.Set("documentId", documentId) +// - parent: Full resource name of parent data store. Format: +// `projects/{project_number}/locations/{location_id}/collections/{coll +// ection}/dataStores/{data_store_id}`. +func (r *ProjectsLocationsDataStoresConversationsService) Create(parent string, googleclouddiscoveryenginev1betaconversation *GoogleCloudDiscoveryengineV1betaConversation) *ProjectsLocationsDataStoresConversationsCreateCall { + c := &ProjectsLocationsDataStoresConversationsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + c.googleclouddiscoveryenginev1betaconversation = googleclouddiscoveryenginev1betaconversation return c } // Fields allows partial responses to be retrieved. See // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse // for more information. -func (c *ProjectsLocationsDataStoresBranchesDocumentsCreateCall) Fields(s ...googleapi.Field) *ProjectsLocationsDataStoresBranchesDocumentsCreateCall { +func (c *ProjectsLocationsDataStoresConversationsCreateCall) Fields(s ...googleapi.Field) *ProjectsLocationsDataStoresConversationsCreateCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } @@ -17163,21 +25599,21 @@ func (c *ProjectsLocationsDataStoresBranchesDocumentsCreateCall) Fields(s ...goo // Context sets the context to be used in this call's Do method. Any // pending HTTP request will be aborted if the provided context is // canceled. -func (c *ProjectsLocationsDataStoresBranchesDocumentsCreateCall) Context(ctx context.Context) *ProjectsLocationsDataStoresBranchesDocumentsCreateCall { +func (c *ProjectsLocationsDataStoresConversationsCreateCall) Context(ctx context.Context) *ProjectsLocationsDataStoresConversationsCreateCall { c.ctx_ = ctx return c } // Header returns an http.Header that can be modified by the caller to // add HTTP headers to the request. -func (c *ProjectsLocationsDataStoresBranchesDocumentsCreateCall) Header() http.Header { +func (c *ProjectsLocationsDataStoresConversationsCreateCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsDataStoresBranchesDocumentsCreateCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsDataStoresConversationsCreateCall) doRequest(alt string) (*http.Response, error) { reqHeaders := make(http.Header) reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) for k, v := range c.header_ { @@ -17185,14 +25621,14 @@ func (c *ProjectsLocationsDataStoresBranchesDocumentsCreateCall) doRequest(alt s } reqHeaders.Set("User-Agent", c.s.userAgent()) var body io.Reader = nil - body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddiscoveryenginev1betadocument) + body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddiscoveryenginev1betaconversation) if err != nil { return nil, err } reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+parent}/documents") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+parent}/conversations") urls += "?" + c.urlParams_.Encode() req, err := http.NewRequest("POST", urls, body) if err != nil { @@ -17205,16 +25641,16 @@ func (c *ProjectsLocationsDataStoresBranchesDocumentsCreateCall) doRequest(alt s return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "discoveryengine.projects.locations.dataStores.branches.documents.create" call. -// Exactly one of *GoogleCloudDiscoveryengineV1betaDocument or error +// Do executes the "discoveryengine.projects.locations.dataStores.conversations.create" call. +// Exactly one of *GoogleCloudDiscoveryengineV1betaConversation or error // will be non-nil. Any non-2xx status code is an error. Response // headers are in either -// *GoogleCloudDiscoveryengineV1betaDocument.ServerResponse.Header or -// (if a response was returned at all) in +// *GoogleCloudDiscoveryengineV1betaConversation.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 *ProjectsLocationsDataStoresBranchesDocumentsCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1betaDocument, error) { +func (c *ProjectsLocationsDataStoresConversationsCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1betaConversation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -17233,7 +25669,7 @@ func (c *ProjectsLocationsDataStoresBranchesDocumentsCreateCall) Do(opts ...goog if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &GoogleCloudDiscoveryengineV1betaDocument{ + ret := &GoogleCloudDiscoveryengineV1betaConversation{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -17245,33 +25681,28 @@ func (c *ProjectsLocationsDataStoresBranchesDocumentsCreateCall) Do(opts ...goog } return ret, nil // { - // "description": "Creates a Document.", - // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/branches/{branchesId}/documents", + // "description": "Creates a Conversation. If the Conversation to create already exists, an ALREADY_EXISTS error is returned.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/conversations", // "httpMethod": "POST", - // "id": "discoveryengine.projects.locations.dataStores.branches.documents.create", + // "id": "discoveryengine.projects.locations.dataStores.conversations.create", // "parameterOrder": [ // "parent" // ], // "parameters": { - // "documentId": { - // "description": "Required. The ID to use for the Document, which will become the final component of the Document.name. If the caller does not have permission to create the Document, regardless of whether or not it exists, a `PERMISSION_DENIED` error is returned. This field must be unique among all Documents with the same parent. Otherwise, an `ALREADY_EXISTS` error is returned. This field must conform to [RFC-1034](https://tools.ietf.org/html/rfc1034) standard with a length limit of 63 characters. Otherwise, an `INVALID_ARGUMENT` error is returned.", - // "location": "query", - // "type": "string" - // }, // "parent": { - // "description": "Required. The parent resource name, such as `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/branches/{branch}`.", + // "description": "Required. Full resource name of parent data store. Format: `projects/{project_number}/locations/{location_id}/collections/{collection}/dataStores/{data_store_id}`", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/dataStores/[^/]+/branches/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/dataStores/[^/]+$", // "required": true, // "type": "string" // } // }, - // "path": "v1beta/{+parent}/documents", + // "path": "v1beta/{+parent}/conversations", // "request": { - // "$ref": "GoogleCloudDiscoveryengineV1betaDocument" + // "$ref": "GoogleCloudDiscoveryengineV1betaConversation" // }, // "response": { - // "$ref": "GoogleCloudDiscoveryengineV1betaDocument" + // "$ref": "GoogleCloudDiscoveryengineV1betaConversation" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -17280,9 +25711,9 @@ func (c *ProjectsLocationsDataStoresBranchesDocumentsCreateCall) Do(opts ...goog } -// method id "discoveryengine.projects.locations.dataStores.branches.documents.delete": +// method id "discoveryengine.projects.locations.dataStores.conversations.delete": -type ProjectsLocationsDataStoresBranchesDocumentsDeleteCall struct { +type ProjectsLocationsDataStoresConversationsDeleteCall struct { s *Service name string urlParams_ gensupport.URLParams @@ -17290,17 +25721,14 @@ type ProjectsLocationsDataStoresBranchesDocumentsDeleteCall struct { header_ http.Header } -// Delete: Deletes a Document. +// Delete: Deletes a Conversation. If the Conversation to delete does +// not exist, a NOT_FOUND error is returned. // -// - name: Full resource name of Document, such as -// `projects/{project}/locations/{location}/collections/{collection}/da -// taStores/{data_store}/branches/{branch}/documents/{document}`. If -// the caller does not have permission to delete the Document, -// regardless of whether or not it exists, a `PERMISSION_DENIED` error -// is returned. If the Document to delete does not exist, a -// `NOT_FOUND` error is returned. -func (r *ProjectsLocationsDataStoresBranchesDocumentsService) Delete(name string) *ProjectsLocationsDataStoresBranchesDocumentsDeleteCall { - c := &ProjectsLocationsDataStoresBranchesDocumentsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// - name: The resource name of the Conversation to delete. Format: +// `projects/{project_number}/locations/{location_id}/collections/{coll +// ection}/dataStores/{data_store_id}/conversations/{conversation_id}`. +func (r *ProjectsLocationsDataStoresConversationsService) Delete(name string) *ProjectsLocationsDataStoresConversationsDeleteCall { + c := &ProjectsLocationsDataStoresConversationsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.name = name return c } @@ -17308,7 +25736,7 @@ func (r *ProjectsLocationsDataStoresBranchesDocumentsService) Delete(name string // Fields allows partial responses to be retrieved. See // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse // for more information. -func (c *ProjectsLocationsDataStoresBranchesDocumentsDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsDataStoresBranchesDocumentsDeleteCall { +func (c *ProjectsLocationsDataStoresConversationsDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsDataStoresConversationsDeleteCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } @@ -17316,21 +25744,21 @@ func (c *ProjectsLocationsDataStoresBranchesDocumentsDeleteCall) Fields(s ...goo // Context sets the context to be used in this call's Do method. Any // pending HTTP request will be aborted if the provided context is // canceled. -func (c *ProjectsLocationsDataStoresBranchesDocumentsDeleteCall) Context(ctx context.Context) *ProjectsLocationsDataStoresBranchesDocumentsDeleteCall { +func (c *ProjectsLocationsDataStoresConversationsDeleteCall) Context(ctx context.Context) *ProjectsLocationsDataStoresConversationsDeleteCall { c.ctx_ = ctx return c } // Header returns an http.Header that can be modified by the caller to // add HTTP headers to the request. -func (c *ProjectsLocationsDataStoresBranchesDocumentsDeleteCall) Header() http.Header { +func (c *ProjectsLocationsDataStoresConversationsDeleteCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsDataStoresBranchesDocumentsDeleteCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsDataStoresConversationsDeleteCall) doRequest(alt string) (*http.Response, error) { reqHeaders := make(http.Header) reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) for k, v := range c.header_ { @@ -17353,14 +25781,14 @@ func (c *ProjectsLocationsDataStoresBranchesDocumentsDeleteCall) doRequest(alt s return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "discoveryengine.projects.locations.dataStores.branches.documents.delete" call. +// Do executes the "discoveryengine.projects.locations.dataStores.conversations.delete" call. // Exactly one of *GoogleProtobufEmpty or error will be non-nil. Any // non-2xx status code is an error. Response headers are in either // *GoogleProtobufEmpty.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 *ProjectsLocationsDataStoresBranchesDocumentsDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, error) { +func (c *ProjectsLocationsDataStoresConversationsDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -17391,18 +25819,18 @@ func (c *ProjectsLocationsDataStoresBranchesDocumentsDeleteCall) Do(opts ...goog } return ret, nil // { - // "description": "Deletes a Document.", - // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/branches/{branchesId}/documents/{documentsId}", + // "description": "Deletes a Conversation. If the Conversation to delete does not exist, a NOT_FOUND error is returned.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/conversations/{conversationsId}", // "httpMethod": "DELETE", - // "id": "discoveryengine.projects.locations.dataStores.branches.documents.delete", + // "id": "discoveryengine.projects.locations.dataStores.conversations.delete", // "parameterOrder": [ // "name" // ], // "parameters": { // "name": { - // "description": "Required. Full resource name of Document, such as `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/branches/{branch}/documents/{document}`. If the caller does not have permission to delete the Document, regardless of whether or not it exists, a `PERMISSION_DENIED` error is returned. If the Document to delete does not exist, a `NOT_FOUND` error is returned.", + // "description": "Required. The resource name of the Conversation to delete. Format: `projects/{project_number}/locations/{location_id}/collections/{collection}/dataStores/{data_store_id}/conversations/{conversation_id}`", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/dataStores/[^/]+/branches/[^/]+/documents/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/dataStores/[^/]+/conversations/[^/]+$", // "required": true, // "type": "string" // } @@ -17418,9 +25846,9 @@ func (c *ProjectsLocationsDataStoresBranchesDocumentsDeleteCall) Do(opts ...goog } -// method id "discoveryengine.projects.locations.dataStores.branches.documents.get": +// method id "discoveryengine.projects.locations.dataStores.conversations.get": -type ProjectsLocationsDataStoresBranchesDocumentsGetCall struct { +type ProjectsLocationsDataStoresConversationsGetCall struct { s *Service name string urlParams_ gensupport.URLParams @@ -17429,17 +25857,13 @@ type ProjectsLocationsDataStoresBranchesDocumentsGetCall struct { header_ http.Header } -// Get: Gets a Document. +// Get: Gets a Conversation. // -// - name: Full resource name of Document, such as -// `projects/{project}/locations/{location}/collections/{collection}/da -// taStores/{data_store}/branches/{branch}/documents/{document}`. If -// the caller does not have permission to access the Document, -// regardless of whether or not it exists, a `PERMISSION_DENIED` error -// is returned. If the requested Document does not exist, a -// `NOT_FOUND` error is returned. -func (r *ProjectsLocationsDataStoresBranchesDocumentsService) Get(name string) *ProjectsLocationsDataStoresBranchesDocumentsGetCall { - c := &ProjectsLocationsDataStoresBranchesDocumentsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// - name: The resource name of the Conversation to get. Format: +// `projects/{project_number}/locations/{location_id}/collections/{coll +// ection}/dataStores/{data_store_id}/conversations/{conversation_id}`. +func (r *ProjectsLocationsDataStoresConversationsService) Get(name string) *ProjectsLocationsDataStoresConversationsGetCall { + c := &ProjectsLocationsDataStoresConversationsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.name = name return c } @@ -17447,7 +25871,7 @@ func (r *ProjectsLocationsDataStoresBranchesDocumentsService) Get(name string) * // Fields allows partial responses to be retrieved. See // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse // for more information. -func (c *ProjectsLocationsDataStoresBranchesDocumentsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsDataStoresBranchesDocumentsGetCall { +func (c *ProjectsLocationsDataStoresConversationsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsDataStoresConversationsGetCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } @@ -17457,7 +25881,7 @@ func (c *ProjectsLocationsDataStoresBranchesDocumentsGetCall) Fields(s ...google // getting updates only after the object has changed since the last // request. Use googleapi.IsNotModified to check whether the response // error from Do is the result of In-None-Match. -func (c *ProjectsLocationsDataStoresBranchesDocumentsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsDataStoresBranchesDocumentsGetCall { +func (c *ProjectsLocationsDataStoresConversationsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsDataStoresConversationsGetCall { c.ifNoneMatch_ = entityTag return c } @@ -17465,21 +25889,21 @@ func (c *ProjectsLocationsDataStoresBranchesDocumentsGetCall) IfNoneMatch(entity // Context sets the context to be used in this call's Do method. Any // pending HTTP request will be aborted if the provided context is // canceled. -func (c *ProjectsLocationsDataStoresBranchesDocumentsGetCall) Context(ctx context.Context) *ProjectsLocationsDataStoresBranchesDocumentsGetCall { +func (c *ProjectsLocationsDataStoresConversationsGetCall) Context(ctx context.Context) *ProjectsLocationsDataStoresConversationsGetCall { c.ctx_ = ctx return c } // Header returns an http.Header that can be modified by the caller to // add HTTP headers to the request. -func (c *ProjectsLocationsDataStoresBranchesDocumentsGetCall) Header() http.Header { +func (c *ProjectsLocationsDataStoresConversationsGetCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsDataStoresBranchesDocumentsGetCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsDataStoresConversationsGetCall) doRequest(alt string) (*http.Response, error) { reqHeaders := make(http.Header) reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) for k, v := range c.header_ { @@ -17505,16 +25929,16 @@ func (c *ProjectsLocationsDataStoresBranchesDocumentsGetCall) doRequest(alt stri return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "discoveryengine.projects.locations.dataStores.branches.documents.get" call. -// Exactly one of *GoogleCloudDiscoveryengineV1betaDocument or error +// Do executes the "discoveryengine.projects.locations.dataStores.conversations.get" call. +// Exactly one of *GoogleCloudDiscoveryengineV1betaConversation or error // will be non-nil. Any non-2xx status code is an error. Response // headers are in either -// *GoogleCloudDiscoveryengineV1betaDocument.ServerResponse.Header or -// (if a response was returned at all) in +// *GoogleCloudDiscoveryengineV1betaConversation.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 *ProjectsLocationsDataStoresBranchesDocumentsGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1betaDocument, error) { +func (c *ProjectsLocationsDataStoresConversationsGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1betaConversation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -17533,7 +25957,7 @@ func (c *ProjectsLocationsDataStoresBranchesDocumentsGetCall) Do(opts ...googlea if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &GoogleCloudDiscoveryengineV1betaDocument{ + ret := &GoogleCloudDiscoveryengineV1betaConversation{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -17545,25 +25969,25 @@ func (c *ProjectsLocationsDataStoresBranchesDocumentsGetCall) Do(opts ...googlea } return ret, nil // { - // "description": "Gets a Document.", - // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/branches/{branchesId}/documents/{documentsId}", + // "description": "Gets a Conversation.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/conversations/{conversationsId}", // "httpMethod": "GET", - // "id": "discoveryengine.projects.locations.dataStores.branches.documents.get", + // "id": "discoveryengine.projects.locations.dataStores.conversations.get", // "parameterOrder": [ // "name" // ], // "parameters": { // "name": { - // "description": "Required. Full resource name of Document, such as `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/branches/{branch}/documents/{document}`. If the caller does not have permission to access the Document, regardless of whether or not it exists, a `PERMISSION_DENIED` error is returned. If the requested Document does not exist, a `NOT_FOUND` error is returned.", + // "description": "Required. The resource name of the Conversation to get. Format: `projects/{project_number}/locations/{location_id}/collections/{collection}/dataStores/{data_store_id}/conversations/{conversation_id}`", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/dataStores/[^/]+/branches/[^/]+/documents/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/dataStores/[^/]+/conversations/[^/]+$", // "required": true, // "type": "string" // } // }, // "path": "v1beta/{+name}", // "response": { - // "$ref": "GoogleCloudDiscoveryengineV1betaDocument" + // "$ref": "GoogleCloudDiscoveryengineV1betaConversation" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -17572,75 +25996,113 @@ func (c *ProjectsLocationsDataStoresBranchesDocumentsGetCall) Do(opts ...googlea } -// method id "discoveryengine.projects.locations.dataStores.branches.documents.import": +// method id "discoveryengine.projects.locations.dataStores.conversations.list": -type ProjectsLocationsDataStoresBranchesDocumentsImportCall struct { - s *Service - parent string - googleclouddiscoveryenginev1betaimportdocumentsrequest *GoogleCloudDiscoveryengineV1betaImportDocumentsRequest - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +type ProjectsLocationsDataStoresConversationsListCall struct { + s *Service + parent string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header } -// Import: Bulk import of multiple Documents. Request processing may be -// synchronous. Non-existing items will be created. Note: It is possible -// for a subset of the Documents to be successfully updated. +// List: Lists all Conversations by their parent DataStore. // -// - parent: The parent branch resource name, such as -// `projects/{project}/locations/{location}/collections/{collection}/da -// taStores/{data_store}/branches/{branch}`. Requires create/update -// permission. -func (r *ProjectsLocationsDataStoresBranchesDocumentsService) Import(parent string, googleclouddiscoveryenginev1betaimportdocumentsrequest *GoogleCloudDiscoveryengineV1betaImportDocumentsRequest) *ProjectsLocationsDataStoresBranchesDocumentsImportCall { - c := &ProjectsLocationsDataStoresBranchesDocumentsImportCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// - parent: The data store resource name. Format: +// `projects/{project_number}/locations/{location_id}/collections/{coll +// ection}/dataStores/{data_store_id}`. +func (r *ProjectsLocationsDataStoresConversationsService) List(parent string) *ProjectsLocationsDataStoresConversationsListCall { + c := &ProjectsLocationsDataStoresConversationsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.parent = parent - c.googleclouddiscoveryenginev1betaimportdocumentsrequest = googleclouddiscoveryenginev1betaimportdocumentsrequest + return c +} + +// Filter sets the optional parameter "filter": A filter to apply on the +// list results. The supported features are: user_pseudo_id, state. +// Example: "user_pseudo_id = some_id" +func (c *ProjectsLocationsDataStoresConversationsListCall) Filter(filter string) *ProjectsLocationsDataStoresConversationsListCall { + c.urlParams_.Set("filter", filter) + 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: * `update_time` * +// `create_time` * `conversation_name` Example: "update_time desc" +// "create_time" +func (c *ProjectsLocationsDataStoresConversationsListCall) OrderBy(orderBy string) *ProjectsLocationsDataStoresConversationsListCall { + c.urlParams_.Set("orderBy", orderBy) + return c +} + +// PageSize sets the optional parameter "pageSize": Maximum number of +// results to return. If unspecified, defaults to 50. Max allowed value +// is 1000. +func (c *ProjectsLocationsDataStoresConversationsListCall) PageSize(pageSize int64) *ProjectsLocationsDataStoresConversationsListCall { + c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) + return c +} + +// PageToken sets the optional parameter "pageToken": A page token, +// received from a previous `ListConversations` call. Provide this to +// retrieve the subsequent page. +func (c *ProjectsLocationsDataStoresConversationsListCall) PageToken(pageToken string) *ProjectsLocationsDataStoresConversationsListCall { + 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 information. -func (c *ProjectsLocationsDataStoresBranchesDocumentsImportCall) Fields(s ...googleapi.Field) *ProjectsLocationsDataStoresBranchesDocumentsImportCall { +func (c *ProjectsLocationsDataStoresConversationsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsDataStoresConversationsListCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } +// IfNoneMatch sets the 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. Use googleapi.IsNotModified to check whether the response +// error from Do is the result of In-None-Match. +func (c *ProjectsLocationsDataStoresConversationsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsDataStoresConversationsListCall { + c.ifNoneMatch_ = entityTag + return c +} + // Context sets the context to be used in this call's Do method. Any // pending HTTP request will be aborted if the provided context is // canceled. -func (c *ProjectsLocationsDataStoresBranchesDocumentsImportCall) Context(ctx context.Context) *ProjectsLocationsDataStoresBranchesDocumentsImportCall { +func (c *ProjectsLocationsDataStoresConversationsListCall) Context(ctx context.Context) *ProjectsLocationsDataStoresConversationsListCall { c.ctx_ = ctx return c } // Header returns an http.Header that can be modified by the caller to // add HTTP headers to the request. -func (c *ProjectsLocationsDataStoresBranchesDocumentsImportCall) Header() http.Header { +func (c *ProjectsLocationsDataStoresConversationsListCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsDataStoresBranchesDocumentsImportCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsDataStoresConversationsListCall) doRequest(alt string) (*http.Response, error) { reqHeaders := make(http.Header) reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) for k, v := range c.header_ { reqHeaders[k] = v } reqHeaders.Set("User-Agent", c.s.userAgent()) - var body io.Reader = nil - body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddiscoveryenginev1betaimportdocumentsrequest) - if err != nil { - return nil, err + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) } - reqHeaders.Set("Content-Type", "application/json") + var body io.Reader = nil c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+parent}/documents:import") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+parent}/conversations") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("POST", urls, body) + req, err := http.NewRequest("GET", urls, body) if err != nil { return nil, err } @@ -17651,14 +26113,17 @@ func (c *ProjectsLocationsDataStoresBranchesDocumentsImportCall) doRequest(alt s return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "discoveryengine.projects.locations.dataStores.branches.documents.import" call. -// Exactly one of *GoogleLongrunningOperation or error will be non-nil. -// 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 *ProjectsLocationsDataStoresBranchesDocumentsImportCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { +// Do executes the "discoveryengine.projects.locations.dataStores.conversations.list" call. +// Exactly one of +// *GoogleCloudDiscoveryengineV1betaListConversationsResponse or error +// will be non-nil. Any non-2xx status code is an error. Response +// headers are in either +// *GoogleCloudDiscoveryengineV1betaListConversationsResponse.ServerRespo +// nse.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 *ProjectsLocationsDataStoresConversationsListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1betaListConversationsResponse, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -17677,7 +26142,7 @@ func (c *ProjectsLocationsDataStoresBranchesDocumentsImportCall) Do(opts ...goog if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &GoogleLongrunningOperation{ + ret := &GoogleCloudDiscoveryengineV1betaListConversationsResponse{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -17689,28 +26154,46 @@ func (c *ProjectsLocationsDataStoresBranchesDocumentsImportCall) Do(opts ...goog } return ret, nil // { - // "description": "Bulk import of multiple Documents. Request processing may be synchronous. Non-existing items will be created. Note: It is possible for a subset of the Documents to be successfully updated.", - // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/branches/{branchesId}/documents:import", - // "httpMethod": "POST", - // "id": "discoveryengine.projects.locations.dataStores.branches.documents.import", + // "description": "Lists all Conversations by their parent DataStore.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/conversations", + // "httpMethod": "GET", + // "id": "discoveryengine.projects.locations.dataStores.conversations.list", // "parameterOrder": [ // "parent" // ], // "parameters": { + // "filter": { + // "description": "A filter to apply on the list results. The supported features are: user_pseudo_id, state. Example: \"user_pseudo_id = some_id\"", + // "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: * `update_time` * `create_time` * `conversation_name` Example: \"update_time desc\" \"create_time\"", + // "location": "query", + // "type": "string" + // }, + // "pageSize": { + // "description": "Maximum number of results to return. If unspecified, defaults to 50. Max allowed value is 1000.", + // "format": "int32", + // "location": "query", + // "type": "integer" + // }, + // "pageToken": { + // "description": "A page token, received from a previous `ListConversations` call. 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}/collections/{collection}/dataStores/{data_store}/branches/{branch}`. Requires create/update permission.", + // "description": "Required. The data store resource name. Format: `projects/{project_number}/locations/{location_id}/collections/{collection}/dataStores/{data_store_id}`", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/dataStores/[^/]+/branches/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/dataStores/[^/]+$", // "required": true, // "type": "string" // } // }, - // "path": "v1beta/{+parent}/documents:import", - // "request": { - // "$ref": "GoogleCloudDiscoveryengineV1betaImportDocumentsRequest" - // }, + // "path": "v1beta/{+parent}/conversations", // "response": { - // "$ref": "GoogleLongrunningOperation" + // "$ref": "GoogleCloudDiscoveryengineV1betaListConversationsResponse" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -17719,123 +26202,126 @@ func (c *ProjectsLocationsDataStoresBranchesDocumentsImportCall) Do(opts ...goog } -// method id "discoveryengine.projects.locations.dataStores.branches.documents.list": - -type ProjectsLocationsDataStoresBranchesDocumentsListCall struct { - s *Service - parent string - urlParams_ gensupport.URLParams - ifNoneMatch_ string - 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 *ProjectsLocationsDataStoresConversationsListCall) Pages(ctx context.Context, f func(*GoogleCloudDiscoveryengineV1betaListConversationsResponse) error) error { + c.ctx_ = ctx + defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point + 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) + } } -// List: Gets a list of Documents. -// -// - parent: The parent branch resource name, such as -// `projects/{project}/locations/{location}/collections/{collection}/da -// taStores/{data_store}/branches/{branch}`. Use `default_branch` as -// the branch ID, to list documents under the default branch. If the -// caller does not have permission to list Documents under this -// branch, regardless of whether or not this branch exists, a -// `PERMISSION_DENIED` error is returned. -func (r *ProjectsLocationsDataStoresBranchesDocumentsService) List(parent string) *ProjectsLocationsDataStoresBranchesDocumentsListCall { - c := &ProjectsLocationsDataStoresBranchesDocumentsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.parent = parent - return c +// method id "discoveryengine.projects.locations.dataStores.conversations.patch": + +type ProjectsLocationsDataStoresConversationsPatchCall struct { + s *Service + name string + googleclouddiscoveryenginev1betaconversation *GoogleCloudDiscoveryengineV1betaConversation + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// PageSize sets the optional parameter "pageSize": Maximum number of -// Documents to return. If unspecified, defaults to 100. The maximum -// allowed value is 1000. Values above 1000 will be coerced to 1000. If -// this field is negative, an `INVALID_ARGUMENT` error is returned. -func (c *ProjectsLocationsDataStoresBranchesDocumentsListCall) PageSize(pageSize int64) *ProjectsLocationsDataStoresBranchesDocumentsListCall { - c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) +// Patch: Updates a Conversation. Conversation action type cannot be +// changed. If the Conversation to update does not exist, a NOT_FOUND +// error is returned. +// +// - name: Immutable. Fully qualified name +// `project/*/locations/global/collections/{collection}/dataStore/*/con +// versations/*` or +// `project/*/locations/global/collections/{collection}/engines/*/conve +// rsations/*`. +func (r *ProjectsLocationsDataStoresConversationsService) Patch(name string, googleclouddiscoveryenginev1betaconversation *GoogleCloudDiscoveryengineV1betaConversation) *ProjectsLocationsDataStoresConversationsPatchCall { + c := &ProjectsLocationsDataStoresConversationsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + c.googleclouddiscoveryenginev1betaconversation = googleclouddiscoveryenginev1betaconversation return c } -// PageToken sets the optional parameter "pageToken": A page token -// ListDocumentsResponse.next_page_token, received from a previous -// DocumentService.ListDocuments call. Provide this to retrieve the -// subsequent page. When paginating, all other parameters provided to -// DocumentService.ListDocuments must match the call that provided the -// page token. Otherwise, an `INVALID_ARGUMENT` error is returned. -func (c *ProjectsLocationsDataStoresBranchesDocumentsListCall) PageToken(pageToken string) *ProjectsLocationsDataStoresBranchesDocumentsListCall { - c.urlParams_.Set("pageToken", pageToken) +// UpdateMask sets the optional parameter "updateMask": Indicates which +// fields in the provided Conversation to update. The following are NOT +// supported: * Conversation.name If not set or empty, all supported +// fields are updated. +func (c *ProjectsLocationsDataStoresConversationsPatchCall) UpdateMask(updateMask string) *ProjectsLocationsDataStoresConversationsPatchCall { + 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 information. -func (c *ProjectsLocationsDataStoresBranchesDocumentsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsDataStoresBranchesDocumentsListCall { +func (c *ProjectsLocationsDataStoresConversationsPatchCall) Fields(s ...googleapi.Field) *ProjectsLocationsDataStoresConversationsPatchCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// IfNoneMatch sets the 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. Use googleapi.IsNotModified to check whether the response -// error from Do is the result of In-None-Match. -func (c *ProjectsLocationsDataStoresBranchesDocumentsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsDataStoresBranchesDocumentsListCall { - c.ifNoneMatch_ = entityTag - return c -} - // Context sets the context to be used in this call's Do method. Any // pending HTTP request will be aborted if the provided context is // canceled. -func (c *ProjectsLocationsDataStoresBranchesDocumentsListCall) Context(ctx context.Context) *ProjectsLocationsDataStoresBranchesDocumentsListCall { +func (c *ProjectsLocationsDataStoresConversationsPatchCall) Context(ctx context.Context) *ProjectsLocationsDataStoresConversationsPatchCall { c.ctx_ = ctx return c } // Header returns an http.Header that can be modified by the caller to // add HTTP headers to the request. -func (c *ProjectsLocationsDataStoresBranchesDocumentsListCall) Header() http.Header { +func (c *ProjectsLocationsDataStoresConversationsPatchCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsDataStoresBranchesDocumentsListCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsDataStoresConversationsPatchCall) doRequest(alt string) (*http.Response, error) { reqHeaders := make(http.Header) reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) for k, v := range c.header_ { reqHeaders[k] = v } reqHeaders.Set("User-Agent", c.s.userAgent()) - if c.ifNoneMatch_ != "" { - reqHeaders.Set("If-None-Match", c.ifNoneMatch_) - } var body io.Reader = nil + body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddiscoveryenginev1betaconversation) + if err != nil { + return nil, err + } + reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+parent}/documents") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("GET", 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{ - "parent": c.parent, + "name": c.name, }) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "discoveryengine.projects.locations.dataStores.branches.documents.list" call. -// Exactly one of *GoogleCloudDiscoveryengineV1betaListDocumentsResponse -// or error will be non-nil. Any non-2xx status code is an error. -// Response headers are in either -// *GoogleCloudDiscoveryengineV1betaListDocumentsResponse.ServerResponse. -// Header or (if a response was returned at all) in +// Do executes the "discoveryengine.projects.locations.dataStores.conversations.patch" call. +// Exactly one of *GoogleCloudDiscoveryengineV1betaConversation or error +// will be non-nil. Any non-2xx status code is an error. Response +// headers are in either +// *GoogleCloudDiscoveryengineV1betaConversation.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 *ProjectsLocationsDataStoresBranchesDocumentsListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1betaListDocumentsResponse, error) { +func (c *ProjectsLocationsDataStoresConversationsPatchCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1betaConversation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -17854,7 +26340,7 @@ func (c *ProjectsLocationsDataStoresBranchesDocumentsListCall) Do(opts ...google if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &GoogleCloudDiscoveryengineV1betaListDocumentsResponse{ + ret := &GoogleCloudDiscoveryengineV1betaConversation{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -17866,36 +26352,34 @@ func (c *ProjectsLocationsDataStoresBranchesDocumentsListCall) Do(opts ...google } return ret, nil // { - // "description": "Gets a list of Documents.", - // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/branches/{branchesId}/documents", - // "httpMethod": "GET", - // "id": "discoveryengine.projects.locations.dataStores.branches.documents.list", + // "description": "Updates a Conversation. Conversation action type cannot be changed. If the Conversation to update does not exist, a NOT_FOUND error is returned.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/conversations/{conversationsId}", + // "httpMethod": "PATCH", + // "id": "discoveryengine.projects.locations.dataStores.conversations.patch", // "parameterOrder": [ - // "parent" + // "name" // ], // "parameters": { - // "pageSize": { - // "description": "Maximum number of Documents to return. If unspecified, defaults to 100. The maximum allowed value is 1000. Values above 1000 will be coerced to 1000. If this field is negative, an `INVALID_ARGUMENT` error is returned.", - // "format": "int32", - // "location": "query", - // "type": "integer" - // }, - // "pageToken": { - // "description": "A page token ListDocumentsResponse.next_page_token, received from a previous DocumentService.ListDocuments call. Provide this to retrieve the subsequent page. When paginating, all other parameters provided to DocumentService.ListDocuments must match the call that provided the page token. Otherwise, an `INVALID_ARGUMENT` error is returned.", - // "location": "query", - // "type": "string" - // }, - // "parent": { - // "description": "Required. The parent branch resource name, such as `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/branches/{branch}`. Use `default_branch` as the branch ID, to list documents under the default branch. If the caller does not have permission to list Documents under this branch, regardless of whether or not this branch exists, a `PERMISSION_DENIED` error is returned.", + // "name": { + // "description": "Immutable. Fully qualified name `project/*/locations/global/collections/{collection}/dataStore/*/conversations/*` or `project/*/locations/global/collections/{collection}/engines/*/conversations/*`.", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/dataStores/[^/]+/branches/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/dataStores/[^/]+/conversations/[^/]+$", // "required": true, // "type": "string" + // }, + // "updateMask": { + // "description": "Indicates which fields in the provided Conversation to update. The following are NOT supported: * Conversation.name If not set or empty, all supported fields are updated.", + // "format": "google-fieldmask", + // "location": "query", + // "type": "string" // } // }, - // "path": "v1beta/{+parent}/documents", + // "path": "v1beta/{+name}", + // "request": { + // "$ref": "GoogleCloudDiscoveryengineV1betaConversation" + // }, // "response": { - // "$ref": "GoogleCloudDiscoveryengineV1betaListDocumentsResponse" + // "$ref": "GoogleCloudDiscoveryengineV1betaConversation" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -17904,102 +26388,79 @@ func (c *ProjectsLocationsDataStoresBranchesDocumentsListCall) Do(opts ...google } -// 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 *ProjectsLocationsDataStoresBranchesDocumentsListCall) Pages(ctx context.Context, f func(*GoogleCloudDiscoveryengineV1betaListDocumentsResponse) error) error { - c.ctx_ = ctx - defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point - 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) - } -} - -// method id "discoveryengine.projects.locations.dataStores.branches.documents.patch": +// method id "discoveryengine.projects.locations.dataStores.models.operations.get": -type ProjectsLocationsDataStoresBranchesDocumentsPatchCall struct { - s *Service - name string - googleclouddiscoveryenginev1betadocument *GoogleCloudDiscoveryengineV1betaDocument - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +type ProjectsLocationsDataStoresModelsOperationsGetCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header } -// Patch: Updates a Document. +// Get: Gets the latest state of a long-running operation. Clients can +// use this method to poll the operation result at intervals as +// recommended by the API service. // -// - name: Immutable. The full resource name of the document. Format: -// `projects/{project}/locations/{location}/collections/{collection}/da -// taStores/{data_store}/branches/{branch}/documents/{document_id}`. -// This field must be a UTF-8 encoded string with a length limit of -// 1024 characters. -func (r *ProjectsLocationsDataStoresBranchesDocumentsService) Patch(name string, googleclouddiscoveryenginev1betadocument *GoogleCloudDiscoveryengineV1betaDocument) *ProjectsLocationsDataStoresBranchesDocumentsPatchCall { - c := &ProjectsLocationsDataStoresBranchesDocumentsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// - name: The name of the operation resource. +func (r *ProjectsLocationsDataStoresModelsOperationsService) Get(name string) *ProjectsLocationsDataStoresModelsOperationsGetCall { + c := &ProjectsLocationsDataStoresModelsOperationsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.name = name - c.googleclouddiscoveryenginev1betadocument = googleclouddiscoveryenginev1betadocument - return c -} - -// AllowMissing sets the optional parameter "allowMissing": If set to -// true, and the Document is not found, a new Document will be created. -func (c *ProjectsLocationsDataStoresBranchesDocumentsPatchCall) AllowMissing(allowMissing bool) *ProjectsLocationsDataStoresBranchesDocumentsPatchCall { - c.urlParams_.Set("allowMissing", fmt.Sprint(allowMissing)) return c } // Fields allows partial responses to be retrieved. See // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse // for more information. -func (c *ProjectsLocationsDataStoresBranchesDocumentsPatchCall) Fields(s ...googleapi.Field) *ProjectsLocationsDataStoresBranchesDocumentsPatchCall { +func (c *ProjectsLocationsDataStoresModelsOperationsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsDataStoresModelsOperationsGetCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } +// IfNoneMatch sets the 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. Use googleapi.IsNotModified to check whether the response +// error from Do is the result of In-None-Match. +func (c *ProjectsLocationsDataStoresModelsOperationsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsDataStoresModelsOperationsGetCall { + c.ifNoneMatch_ = entityTag + return c +} + // Context sets the context to be used in this call's Do method. Any // pending HTTP request will be aborted if the provided context is // canceled. -func (c *ProjectsLocationsDataStoresBranchesDocumentsPatchCall) Context(ctx context.Context) *ProjectsLocationsDataStoresBranchesDocumentsPatchCall { +func (c *ProjectsLocationsDataStoresModelsOperationsGetCall) Context(ctx context.Context) *ProjectsLocationsDataStoresModelsOperationsGetCall { c.ctx_ = ctx return c } // Header returns an http.Header that can be modified by the caller to // add HTTP headers to the request. -func (c *ProjectsLocationsDataStoresBranchesDocumentsPatchCall) Header() http.Header { +func (c *ProjectsLocationsDataStoresModelsOperationsGetCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsDataStoresBranchesDocumentsPatchCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsDataStoresModelsOperationsGetCall) doRequest(alt string) (*http.Response, error) { reqHeaders := make(http.Header) reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) for k, v := range c.header_ { reqHeaders[k] = v } reqHeaders.Set("User-Agent", c.s.userAgent()) - var body io.Reader = nil - body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddiscoveryenginev1betadocument) - if err != nil { - return nil, err + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) } - reqHeaders.Set("Content-Type", "application/json") + var body io.Reader = nil 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) + req, err := http.NewRequest("GET", urls, body) if err != nil { return nil, err } @@ -18010,16 +26471,14 @@ func (c *ProjectsLocationsDataStoresBranchesDocumentsPatchCall) doRequest(alt st return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "discoveryengine.projects.locations.dataStores.branches.documents.patch" call. -// Exactly one of *GoogleCloudDiscoveryengineV1betaDocument or error -// will be non-nil. Any non-2xx status code is an error. Response -// headers are in either -// *GoogleCloudDiscoveryengineV1betaDocument.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 *ProjectsLocationsDataStoresBranchesDocumentsPatchCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1betaDocument, error) { +// Do executes the "discoveryengine.projects.locations.dataStores.models.operations.get" call. +// Exactly one of *GoogleLongrunningOperation or error will be non-nil. +// 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 *ProjectsLocationsDataStoresModelsOperationsGetCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -18038,7 +26497,7 @@ func (c *ProjectsLocationsDataStoresBranchesDocumentsPatchCall) Do(opts ...googl if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &GoogleCloudDiscoveryengineV1betaDocument{ + ret := &GoogleLongrunningOperation{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -18050,33 +26509,25 @@ func (c *ProjectsLocationsDataStoresBranchesDocumentsPatchCall) Do(opts ...googl } return ret, nil // { - // "description": "Updates a Document.", - // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/branches/{branchesId}/documents/{documentsId}", - // "httpMethod": "PATCH", - // "id": "discoveryengine.projects.locations.dataStores.branches.documents.patch", + // "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": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/models/{modelsId}/operations/{operationsId}", + // "httpMethod": "GET", + // "id": "discoveryengine.projects.locations.dataStores.models.operations.get", // "parameterOrder": [ // "name" // ], // "parameters": { - // "allowMissing": { - // "description": "If set to true, and the Document is not found, a new Document will be created.", - // "location": "query", - // "type": "boolean" - // }, // "name": { - // "description": "Immutable. The full resource name of the document. Format: `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/branches/{branch}/documents/{document_id}`. This field must be a UTF-8 encoded string with a length limit of 1024 characters.", + // "description": "The name of the operation resource.", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/dataStores/[^/]+/branches/[^/]+/documents/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/dataStores/[^/]+/models/[^/]+/operations/[^/]+$", // "required": true, // "type": "string" // } // }, // "path": "v1beta/{+name}", - // "request": { - // "$ref": "GoogleCloudDiscoveryengineV1betaDocument" - // }, // "response": { - // "$ref": "GoogleCloudDiscoveryengineV1betaDocument" + // "$ref": "GoogleLongrunningOperation" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -18085,96 +26536,119 @@ func (c *ProjectsLocationsDataStoresBranchesDocumentsPatchCall) Do(opts ...googl } -// method id "discoveryengine.projects.locations.dataStores.branches.documents.purge": +// method id "discoveryengine.projects.locations.dataStores.models.operations.list": -type ProjectsLocationsDataStoresBranchesDocumentsPurgeCall struct { - s *Service - parent string - googleclouddiscoveryenginev1betapurgedocumentsrequest *GoogleCloudDiscoveryengineV1betaPurgeDocumentsRequest - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +type ProjectsLocationsDataStoresModelsOperationsListCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header } -// Purge: Permanently deletes all selected Documents in a branch. This -// process is asynchronous. Depending on the number of Documents to be -// deleted, this operation can take hours to complete. Before the delete -// operation completes, some Documents might still be returned by -// DocumentService.GetDocument or DocumentService.ListDocuments. To get -// a list of the Documents to be deleted, set -// PurgeDocumentsRequest.force to false. +// List: Lists operations that match the specified filter in the +// request. If the server doesn't support this method, it returns +// `UNIMPLEMENTED`. // -// - parent: The parent resource name, such as -// `projects/{project}/locations/{location}/collections/{collection}/da -// taStores/{data_store}/branches/{branch}`. -func (r *ProjectsLocationsDataStoresBranchesDocumentsService) Purge(parent string, googleclouddiscoveryenginev1betapurgedocumentsrequest *GoogleCloudDiscoveryengineV1betaPurgeDocumentsRequest) *ProjectsLocationsDataStoresBranchesDocumentsPurgeCall { - c := &ProjectsLocationsDataStoresBranchesDocumentsPurgeCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.parent = parent - c.googleclouddiscoveryenginev1betapurgedocumentsrequest = googleclouddiscoveryenginev1betapurgedocumentsrequest +// - name: The name of the operation's parent resource. +func (r *ProjectsLocationsDataStoresModelsOperationsService) List(name string) *ProjectsLocationsDataStoresModelsOperationsListCall { + c := &ProjectsLocationsDataStoresModelsOperationsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + return c +} + +// Filter sets the optional parameter "filter": The standard list +// filter. +func (c *ProjectsLocationsDataStoresModelsOperationsListCall) Filter(filter string) *ProjectsLocationsDataStoresModelsOperationsListCall { + c.urlParams_.Set("filter", filter) + return c +} + +// PageSize sets the optional parameter "pageSize": The standard list +// page size. +func (c *ProjectsLocationsDataStoresModelsOperationsListCall) PageSize(pageSize int64) *ProjectsLocationsDataStoresModelsOperationsListCall { + c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) + return c +} + +// PageToken sets the optional parameter "pageToken": The standard list +// page token. +func (c *ProjectsLocationsDataStoresModelsOperationsListCall) PageToken(pageToken string) *ProjectsLocationsDataStoresModelsOperationsListCall { + 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 information. -func (c *ProjectsLocationsDataStoresBranchesDocumentsPurgeCall) Fields(s ...googleapi.Field) *ProjectsLocationsDataStoresBranchesDocumentsPurgeCall { +func (c *ProjectsLocationsDataStoresModelsOperationsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsDataStoresModelsOperationsListCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } +// IfNoneMatch sets the 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. Use googleapi.IsNotModified to check whether the response +// error from Do is the result of In-None-Match. +func (c *ProjectsLocationsDataStoresModelsOperationsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsDataStoresModelsOperationsListCall { + c.ifNoneMatch_ = entityTag + return c +} + // Context sets the context to be used in this call's Do method. Any // pending HTTP request will be aborted if the provided context is // canceled. -func (c *ProjectsLocationsDataStoresBranchesDocumentsPurgeCall) Context(ctx context.Context) *ProjectsLocationsDataStoresBranchesDocumentsPurgeCall { +func (c *ProjectsLocationsDataStoresModelsOperationsListCall) Context(ctx context.Context) *ProjectsLocationsDataStoresModelsOperationsListCall { c.ctx_ = ctx return c } // Header returns an http.Header that can be modified by the caller to // add HTTP headers to the request. -func (c *ProjectsLocationsDataStoresBranchesDocumentsPurgeCall) Header() http.Header { +func (c *ProjectsLocationsDataStoresModelsOperationsListCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsDataStoresBranchesDocumentsPurgeCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsDataStoresModelsOperationsListCall) doRequest(alt string) (*http.Response, error) { reqHeaders := make(http.Header) reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) for k, v := range c.header_ { reqHeaders[k] = v } reqHeaders.Set("User-Agent", c.s.userAgent()) - var body io.Reader = nil - body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddiscoveryenginev1betapurgedocumentsrequest) - if err != nil { - return nil, err + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) } - reqHeaders.Set("Content-Type", "application/json") + var body io.Reader = nil c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+parent}/documents:purge") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}/operations") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("POST", urls, body) + req, err := http.NewRequest("GET", urls, body) if err != nil { return nil, err } req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ - "parent": c.parent, + "name": c.name, }) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "discoveryengine.projects.locations.dataStores.branches.documents.purge" call. -// Exactly one of *GoogleLongrunningOperation or error will be non-nil. -// 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 +// Do executes the "discoveryengine.projects.locations.dataStores.models.operations.list" call. +// Exactly one of *GoogleLongrunningListOperationsResponse or error will +// be non-nil. Any non-2xx status code is an error. Response headers are +// in either +// *GoogleLongrunningListOperationsResponse.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 *ProjectsLocationsDataStoresBranchesDocumentsPurgeCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { +func (c *ProjectsLocationsDataStoresModelsOperationsListCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningListOperationsResponse, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -18193,7 +26667,7 @@ func (c *ProjectsLocationsDataStoresBranchesDocumentsPurgeCall) Do(opts ...googl if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &GoogleLongrunningOperation{ + ret := &GoogleLongrunningListOperationsResponse{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -18205,28 +26679,41 @@ func (c *ProjectsLocationsDataStoresBranchesDocumentsPurgeCall) Do(opts ...googl } return ret, nil // { - // "description": "Permanently deletes all selected Documents in a branch. This process is asynchronous. Depending on the number of Documents to be deleted, this operation can take hours to complete. Before the delete operation completes, some Documents might still be returned by DocumentService.GetDocument or DocumentService.ListDocuments. To get a list of the Documents to be deleted, set PurgeDocumentsRequest.force to false.", - // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/branches/{branchesId}/documents:purge", - // "httpMethod": "POST", - // "id": "discoveryengine.projects.locations.dataStores.branches.documents.purge", + // "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/models/{modelsId}/operations", + // "httpMethod": "GET", + // "id": "discoveryengine.projects.locations.dataStores.models.operations.list", // "parameterOrder": [ - // "parent" + // "name" // ], // "parameters": { - // "parent": { - // "description": "Required. The parent resource name, such as `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/branches/{branch}`.", + // "filter": { + // "description": "The standard list filter.", + // "location": "query", + // "type": "string" + // }, + // "name": { + // "description": "The name of the operation's parent resource.", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/dataStores/[^/]+/branches/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/dataStores/[^/]+/models/[^/]+$", // "required": true, // "type": "string" + // }, + // "pageSize": { + // "description": "The standard list page size.", + // "format": "int32", + // "location": "query", + // "type": "integer" + // }, + // "pageToken": { + // "description": "The standard list page token.", + // "location": "query", + // "type": "string" // } // }, - // "path": "v1beta/{+parent}/documents:purge", - // "request": { - // "$ref": "GoogleCloudDiscoveryengineV1betaPurgeDocumentsRequest" - // }, + // "path": "v1beta/{+name}/operations", // "response": { - // "$ref": "GoogleLongrunningOperation" + // "$ref": "GoogleLongrunningListOperationsResponse" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -18235,9 +26722,30 @@ func (c *ProjectsLocationsDataStoresBranchesDocumentsPurgeCall) Do(opts ...googl } -// method id "discoveryengine.projects.locations.dataStores.branches.operations.get": +// 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 *ProjectsLocationsDataStoresModelsOperationsListCall) Pages(ctx context.Context, f func(*GoogleLongrunningListOperationsResponse) error) error { + c.ctx_ = ctx + defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point + 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) + } +} + +// method id "discoveryengine.projects.locations.dataStores.operations.get": -type ProjectsLocationsDataStoresBranchesOperationsGetCall struct { +type ProjectsLocationsDataStoresOperationsGetCall struct { s *Service name string urlParams_ gensupport.URLParams @@ -18251,8 +26759,8 @@ type ProjectsLocationsDataStoresBranchesOperationsGetCall struct { // recommended by the API service. // // - name: The name of the operation resource. -func (r *ProjectsLocationsDataStoresBranchesOperationsService) Get(name string) *ProjectsLocationsDataStoresBranchesOperationsGetCall { - c := &ProjectsLocationsDataStoresBranchesOperationsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} +func (r *ProjectsLocationsDataStoresOperationsService) Get(name string) *ProjectsLocationsDataStoresOperationsGetCall { + c := &ProjectsLocationsDataStoresOperationsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.name = name return c } @@ -18260,7 +26768,7 @@ func (r *ProjectsLocationsDataStoresBranchesOperationsService) Get(name string) // Fields allows partial responses to be retrieved. See // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse // for more information. -func (c *ProjectsLocationsDataStoresBranchesOperationsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsDataStoresBranchesOperationsGetCall { +func (c *ProjectsLocationsDataStoresOperationsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsDataStoresOperationsGetCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } @@ -18270,7 +26778,7 @@ func (c *ProjectsLocationsDataStoresBranchesOperationsGetCall) Fields(s ...googl // getting updates only after the object has changed since the last // request. Use googleapi.IsNotModified to check whether the response // error from Do is the result of In-None-Match. -func (c *ProjectsLocationsDataStoresBranchesOperationsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsDataStoresBranchesOperationsGetCall { +func (c *ProjectsLocationsDataStoresOperationsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsDataStoresOperationsGetCall { c.ifNoneMatch_ = entityTag return c } @@ -18278,21 +26786,21 @@ func (c *ProjectsLocationsDataStoresBranchesOperationsGetCall) IfNoneMatch(entit // Context sets the context to be used in this call's Do method. Any // pending HTTP request will be aborted if the provided context is // canceled. -func (c *ProjectsLocationsDataStoresBranchesOperationsGetCall) Context(ctx context.Context) *ProjectsLocationsDataStoresBranchesOperationsGetCall { +func (c *ProjectsLocationsDataStoresOperationsGetCall) Context(ctx context.Context) *ProjectsLocationsDataStoresOperationsGetCall { c.ctx_ = ctx return c } // Header returns an http.Header that can be modified by the caller to // add HTTP headers to the request. -func (c *ProjectsLocationsDataStoresBranchesOperationsGetCall) Header() http.Header { +func (c *ProjectsLocationsDataStoresOperationsGetCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsDataStoresBranchesOperationsGetCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsDataStoresOperationsGetCall) doRequest(alt string) (*http.Response, error) { reqHeaders := make(http.Header) reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) for k, v := range c.header_ { @@ -18318,14 +26826,14 @@ func (c *ProjectsLocationsDataStoresBranchesOperationsGetCall) doRequest(alt str return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "discoveryengine.projects.locations.dataStores.branches.operations.get" call. +// Do executes the "discoveryengine.projects.locations.dataStores.operations.get" call. // Exactly one of *GoogleLongrunningOperation or error will be non-nil. // 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 *ProjectsLocationsDataStoresBranchesOperationsGetCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { +func (c *ProjectsLocationsDataStoresOperationsGetCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -18357,9 +26865,9 @@ func (c *ProjectsLocationsDataStoresBranchesOperationsGetCall) Do(opts ...google return ret, nil // { // "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": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/branches/{branchesId}/operations/{operationsId}", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/operations/{operationsId}", // "httpMethod": "GET", - // "id": "discoveryengine.projects.locations.dataStores.branches.operations.get", + // "id": "discoveryengine.projects.locations.dataStores.operations.get", // "parameterOrder": [ // "name" // ], @@ -18367,7 +26875,7 @@ func (c *ProjectsLocationsDataStoresBranchesOperationsGetCall) Do(opts ...google // "name": { // "description": "The name of the operation resource.", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/dataStores/[^/]+/branches/[^/]+/operations/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/dataStores/[^/]+/operations/[^/]+$", // "required": true, // "type": "string" // } @@ -18383,9 +26891,9 @@ func (c *ProjectsLocationsDataStoresBranchesOperationsGetCall) Do(opts ...google } -// method id "discoveryengine.projects.locations.dataStores.branches.operations.list": +// method id "discoveryengine.projects.locations.dataStores.operations.list": -type ProjectsLocationsDataStoresBranchesOperationsListCall struct { +type ProjectsLocationsDataStoresOperationsListCall struct { s *Service name string urlParams_ gensupport.URLParams @@ -18399,29 +26907,29 @@ type ProjectsLocationsDataStoresBranchesOperationsListCall struct { // `UNIMPLEMENTED`. // // - name: The name of the operation's parent resource. -func (r *ProjectsLocationsDataStoresBranchesOperationsService) List(name string) *ProjectsLocationsDataStoresBranchesOperationsListCall { - c := &ProjectsLocationsDataStoresBranchesOperationsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} +func (r *ProjectsLocationsDataStoresOperationsService) List(name string) *ProjectsLocationsDataStoresOperationsListCall { + c := &ProjectsLocationsDataStoresOperationsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.name = name return c } // Filter sets the optional parameter "filter": The standard list // filter. -func (c *ProjectsLocationsDataStoresBranchesOperationsListCall) Filter(filter string) *ProjectsLocationsDataStoresBranchesOperationsListCall { +func (c *ProjectsLocationsDataStoresOperationsListCall) Filter(filter string) *ProjectsLocationsDataStoresOperationsListCall { c.urlParams_.Set("filter", filter) return c } // PageSize sets the optional parameter "pageSize": The standard list // page size. -func (c *ProjectsLocationsDataStoresBranchesOperationsListCall) PageSize(pageSize int64) *ProjectsLocationsDataStoresBranchesOperationsListCall { +func (c *ProjectsLocationsDataStoresOperationsListCall) PageSize(pageSize int64) *ProjectsLocationsDataStoresOperationsListCall { c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) return c } // PageToken sets the optional parameter "pageToken": The standard list // page token. -func (c *ProjectsLocationsDataStoresBranchesOperationsListCall) PageToken(pageToken string) *ProjectsLocationsDataStoresBranchesOperationsListCall { +func (c *ProjectsLocationsDataStoresOperationsListCall) PageToken(pageToken string) *ProjectsLocationsDataStoresOperationsListCall { c.urlParams_.Set("pageToken", pageToken) return c } @@ -18429,7 +26937,7 @@ func (c *ProjectsLocationsDataStoresBranchesOperationsListCall) PageToken(pageTo // Fields allows partial responses to be retrieved. See // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse // for more information. -func (c *ProjectsLocationsDataStoresBranchesOperationsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsDataStoresBranchesOperationsListCall { +func (c *ProjectsLocationsDataStoresOperationsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsDataStoresOperationsListCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } @@ -18439,7 +26947,7 @@ func (c *ProjectsLocationsDataStoresBranchesOperationsListCall) Fields(s ...goog // getting updates only after the object has changed since the last // request. Use googleapi.IsNotModified to check whether the response // error from Do is the result of In-None-Match. -func (c *ProjectsLocationsDataStoresBranchesOperationsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsDataStoresBranchesOperationsListCall { +func (c *ProjectsLocationsDataStoresOperationsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsDataStoresOperationsListCall { c.ifNoneMatch_ = entityTag return c } @@ -18447,21 +26955,21 @@ func (c *ProjectsLocationsDataStoresBranchesOperationsListCall) IfNoneMatch(enti // Context sets the context to be used in this call's Do method. Any // pending HTTP request will be aborted if the provided context is // canceled. -func (c *ProjectsLocationsDataStoresBranchesOperationsListCall) Context(ctx context.Context) *ProjectsLocationsDataStoresBranchesOperationsListCall { +func (c *ProjectsLocationsDataStoresOperationsListCall) Context(ctx context.Context) *ProjectsLocationsDataStoresOperationsListCall { c.ctx_ = ctx return c } // Header returns an http.Header that can be modified by the caller to // add HTTP headers to the request. -func (c *ProjectsLocationsDataStoresBranchesOperationsListCall) Header() http.Header { +func (c *ProjectsLocationsDataStoresOperationsListCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsDataStoresBranchesOperationsListCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsDataStoresOperationsListCall) doRequest(alt string) (*http.Response, error) { reqHeaders := make(http.Header) reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) for k, v := range c.header_ { @@ -18481,207 +26989,21 @@ func (c *ProjectsLocationsDataStoresBranchesOperationsListCall) doRequest(alt st return nil, err } req.Header = reqHeaders - googleapi.Expand(req.URL, map[string]string{ - "name": c.name, - }) - return gensupport.SendRequest(c.ctx_, c.s.client, req) -} - -// Do executes the "discoveryengine.projects.locations.dataStores.branches.operations.list" call. -// Exactly one of *GoogleLongrunningListOperationsResponse or error will -// be non-nil. Any non-2xx status code is an error. Response headers are -// in either -// *GoogleLongrunningListOperationsResponse.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 *ProjectsLocationsDataStoresBranchesOperationsListCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningListOperationsResponse, 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 := &GoogleLongrunningListOperationsResponse{ - ServerResponse: googleapi.ServerResponse{ - Header: res.Header, - HTTPStatusCode: res.StatusCode, - }, - } - target := &ret - if err := gensupport.DecodeResponse(target, res); err != nil { - return nil, err - } - return ret, nil - // { - // "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`.", - // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/branches/{branchesId}/operations", - // "httpMethod": "GET", - // "id": "discoveryengine.projects.locations.dataStores.branches.operations.list", - // "parameterOrder": [ - // "name" - // ], - // "parameters": { - // "filter": { - // "description": "The standard list filter.", - // "location": "query", - // "type": "string" - // }, - // "name": { - // "description": "The name of the operation's parent resource.", - // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/dataStores/[^/]+/branches/[^/]+$", - // "required": true, - // "type": "string" - // }, - // "pageSize": { - // "description": "The standard list page size.", - // "format": "int32", - // "location": "query", - // "type": "integer" - // }, - // "pageToken": { - // "description": "The standard list page token.", - // "location": "query", - // "type": "string" - // } - // }, - // "path": "v1beta/{+name}/operations", - // "response": { - // "$ref": "GoogleLongrunningListOperationsResponse" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform" - // ] - // } - -} - -// 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 *ProjectsLocationsDataStoresBranchesOperationsListCall) Pages(ctx context.Context, f func(*GoogleLongrunningListOperationsResponse) error) error { - c.ctx_ = ctx - defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point - 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) - } -} - -// method id "discoveryengine.projects.locations.dataStores.conversations.converse": - -type ProjectsLocationsDataStoresConversationsConverseCall struct { - s *Service - name string - googleclouddiscoveryenginev1betaconverseconversationrequest *GoogleCloudDiscoveryengineV1betaConverseConversationRequest - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header -} - -// Converse: Converses a conversation. -// -// - name: The resource name of the Conversation to get. Format: -// `projects/{project_number}/locations/{location_id}/collections/{coll -// ection}/dataStores/{data_store_id}/conversations/{conversation_id}`. -// Use -// `projects/{project_number}/locations/{location_id}/collections/{coll -// ection}/dataStores/{data_store_id}/conversations/-` to activate -// auto session mode, which automatically creates a new conversation -// inside a ConverseConversation session. -func (r *ProjectsLocationsDataStoresConversationsService) Converse(name string, googleclouddiscoveryenginev1betaconverseconversationrequest *GoogleCloudDiscoveryengineV1betaConverseConversationRequest) *ProjectsLocationsDataStoresConversationsConverseCall { - c := &ProjectsLocationsDataStoresConversationsConverseCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.name = name - c.googleclouddiscoveryenginev1betaconverseconversationrequest = googleclouddiscoveryenginev1betaconverseconversationrequest - return c -} - -// Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. -func (c *ProjectsLocationsDataStoresConversationsConverseCall) Fields(s ...googleapi.Field) *ProjectsLocationsDataStoresConversationsConverseCall { - c.urlParams_.Set("fields", googleapi.CombineFields(s)) - return c -} - -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. -func (c *ProjectsLocationsDataStoresConversationsConverseCall) Context(ctx context.Context) *ProjectsLocationsDataStoresConversationsConverseCall { - c.ctx_ = ctx - return c -} - -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. -func (c *ProjectsLocationsDataStoresConversationsConverseCall) Header() http.Header { - if c.header_ == nil { - c.header_ = make(http.Header) - } - return c.header_ -} - -func (c *ProjectsLocationsDataStoresConversationsConverseCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) - var body io.Reader = nil - body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddiscoveryenginev1betaconverseconversationrequest) - if err != nil { - return nil, err - } - reqHeaders.Set("Content-Type", "application/json") - c.urlParams_.Set("alt", alt) - c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}:converse") - urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("POST", urls, body) - if err != nil { - return nil, err - } - req.Header = reqHeaders - googleapi.Expand(req.URL, map[string]string{ - "name": c.name, - }) - return gensupport.SendRequest(c.ctx_, c.s.client, req) -} - -// Do executes the "discoveryengine.projects.locations.dataStores.conversations.converse" call. -// Exactly one of -// *GoogleCloudDiscoveryengineV1betaConverseConversationResponse or -// error will be non-nil. Any non-2xx status code is an error. Response -// headers are in either -// *GoogleCloudDiscoveryengineV1betaConverseConversationResponse.ServerRe -// sponse.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 *ProjectsLocationsDataStoresConversationsConverseCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1betaConverseConversationResponse, error) { + googleapi.Expand(req.URL, map[string]string{ + "name": c.name, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "discoveryengine.projects.locations.dataStores.operations.list" call. +// Exactly one of *GoogleLongrunningListOperationsResponse or error will +// be non-nil. Any non-2xx status code is an error. Response headers are +// in either +// *GoogleLongrunningListOperationsResponse.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 *ProjectsLocationsDataStoresOperationsListCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningListOperationsResponse, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -18700,7 +27022,7 @@ func (c *ProjectsLocationsDataStoresConversationsConverseCall) Do(opts ...google if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &GoogleCloudDiscoveryengineV1betaConverseConversationResponse{ + ret := &GoogleLongrunningListOperationsResponse{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -18712,28 +27034,41 @@ func (c *ProjectsLocationsDataStoresConversationsConverseCall) Do(opts ...google } return ret, nil // { - // "description": "Converses a conversation.", - // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/conversations/{conversationsId}:converse", - // "httpMethod": "POST", - // "id": "discoveryengine.projects.locations.dataStores.conversations.converse", + // "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/operations", + // "httpMethod": "GET", + // "id": "discoveryengine.projects.locations.dataStores.operations.list", // "parameterOrder": [ // "name" // ], // "parameters": { + // "filter": { + // "description": "The standard list filter.", + // "location": "query", + // "type": "string" + // }, // "name": { - // "description": "Required. The resource name of the Conversation to get. Format: `projects/{project_number}/locations/{location_id}/collections/{collection}/dataStores/{data_store_id}/conversations/{conversation_id}`. Use `projects/{project_number}/locations/{location_id}/collections/{collection}/dataStores/{data_store_id}/conversations/-` to activate auto session mode, which automatically creates a new conversation inside a ConverseConversation session.", + // "description": "The name of the operation's parent resource.", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/dataStores/[^/]+/conversations/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/dataStores/[^/]+$", // "required": true, // "type": "string" + // }, + // "pageSize": { + // "description": "The standard list page size.", + // "format": "int32", + // "location": "query", + // "type": "integer" + // }, + // "pageToken": { + // "description": "The standard list page token.", + // "location": "query", + // "type": "string" // } // }, - // "path": "v1beta/{+name}:converse", - // "request": { - // "$ref": "GoogleCloudDiscoveryengineV1betaConverseConversationRequest" - // }, + // "path": "v1beta/{+name}/operations", // "response": { - // "$ref": "GoogleCloudDiscoveryengineV1betaConverseConversationResponse" + // "$ref": "GoogleLongrunningListOperationsResponse" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -18742,34 +27077,64 @@ func (c *ProjectsLocationsDataStoresConversationsConverseCall) Do(opts ...google } -// method id "discoveryengine.projects.locations.dataStores.conversations.create": +// 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 *ProjectsLocationsDataStoresOperationsListCall) Pages(ctx context.Context, f func(*GoogleLongrunningListOperationsResponse) error) error { + c.ctx_ = ctx + defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point + 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 ProjectsLocationsDataStoresConversationsCreateCall struct { - s *Service - parent string - googleclouddiscoveryenginev1betaconversation *GoogleCloudDiscoveryengineV1betaConversation - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +// method id "discoveryengine.projects.locations.dataStores.schemas.create": + +type ProjectsLocationsDataStoresSchemasCreateCall struct { + s *Service + parent string + googleclouddiscoveryenginev1betaschema *GoogleCloudDiscoveryengineV1betaSchema + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// Create: Creates a Conversation. If the Conversation to create already -// exists, an ALREADY_EXISTS error is returned. +// Create: Creates a Schema. // -// - parent: Full resource name of parent data store. Format: -// `projects/{project_number}/locations/{location_id}/collections/{coll -// ection}/dataStores/{data_store_id}`. -func (r *ProjectsLocationsDataStoresConversationsService) Create(parent string, googleclouddiscoveryenginev1betaconversation *GoogleCloudDiscoveryengineV1betaConversation) *ProjectsLocationsDataStoresConversationsCreateCall { - c := &ProjectsLocationsDataStoresConversationsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// - parent: The parent data store resource name, in the format of +// `projects/{project}/locations/{location}/collections/{collection}/da +// taStores/{data_store}`. +func (r *ProjectsLocationsDataStoresSchemasService) Create(parent string, googleclouddiscoveryenginev1betaschema *GoogleCloudDiscoveryengineV1betaSchema) *ProjectsLocationsDataStoresSchemasCreateCall { + c := &ProjectsLocationsDataStoresSchemasCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.parent = parent - c.googleclouddiscoveryenginev1betaconversation = googleclouddiscoveryenginev1betaconversation + c.googleclouddiscoveryenginev1betaschema = googleclouddiscoveryenginev1betaschema + return c +} + +// SchemaId sets the optional parameter "schemaId": Required. The ID to +// use for the Schema, which will become the final component of the +// Schema.name. This field should conform to RFC-1034 +// (https://tools.ietf.org/html/rfc1034) standard with a length limit of +// 63 characters. +func (c *ProjectsLocationsDataStoresSchemasCreateCall) SchemaId(schemaId string) *ProjectsLocationsDataStoresSchemasCreateCall { + c.urlParams_.Set("schemaId", schemaId) return c } // Fields allows partial responses to be retrieved. See // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse // for more information. -func (c *ProjectsLocationsDataStoresConversationsCreateCall) Fields(s ...googleapi.Field) *ProjectsLocationsDataStoresConversationsCreateCall { +func (c *ProjectsLocationsDataStoresSchemasCreateCall) Fields(s ...googleapi.Field) *ProjectsLocationsDataStoresSchemasCreateCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } @@ -18777,21 +27142,21 @@ func (c *ProjectsLocationsDataStoresConversationsCreateCall) Fields(s ...googlea // Context sets the context to be used in this call's Do method. Any // pending HTTP request will be aborted if the provided context is // canceled. -func (c *ProjectsLocationsDataStoresConversationsCreateCall) Context(ctx context.Context) *ProjectsLocationsDataStoresConversationsCreateCall { +func (c *ProjectsLocationsDataStoresSchemasCreateCall) Context(ctx context.Context) *ProjectsLocationsDataStoresSchemasCreateCall { c.ctx_ = ctx return c } // Header returns an http.Header that can be modified by the caller to // add HTTP headers to the request. -func (c *ProjectsLocationsDataStoresConversationsCreateCall) Header() http.Header { +func (c *ProjectsLocationsDataStoresSchemasCreateCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsDataStoresConversationsCreateCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsDataStoresSchemasCreateCall) doRequest(alt string) (*http.Response, error) { reqHeaders := make(http.Header) reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) for k, v := range c.header_ { @@ -18799,14 +27164,14 @@ func (c *ProjectsLocationsDataStoresConversationsCreateCall) doRequest(alt strin } reqHeaders.Set("User-Agent", c.s.userAgent()) var body io.Reader = nil - body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddiscoveryenginev1betaconversation) + body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddiscoveryenginev1betaschema) if err != nil { return nil, err } reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+parent}/conversations") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+parent}/schemas") urls += "?" + c.urlParams_.Encode() req, err := http.NewRequest("POST", urls, body) if err != nil { @@ -18819,16 +27184,14 @@ func (c *ProjectsLocationsDataStoresConversationsCreateCall) doRequest(alt strin return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "discoveryengine.projects.locations.dataStores.conversations.create" call. -// Exactly one of *GoogleCloudDiscoveryengineV1betaConversation or error -// will be non-nil. Any non-2xx status code is an error. Response -// headers are in either -// *GoogleCloudDiscoveryengineV1betaConversation.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 *ProjectsLocationsDataStoresConversationsCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1betaConversation, error) { +// Do executes the "discoveryengine.projects.locations.dataStores.schemas.create" call. +// Exactly one of *GoogleLongrunningOperation or error will be non-nil. +// 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 *ProjectsLocationsDataStoresSchemasCreateCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -18847,7 +27210,7 @@ func (c *ProjectsLocationsDataStoresConversationsCreateCall) Do(opts ...googleap if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &GoogleCloudDiscoveryengineV1betaConversation{ + ret := &GoogleLongrunningOperation{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -18859,28 +27222,33 @@ func (c *ProjectsLocationsDataStoresConversationsCreateCall) Do(opts ...googleap } return ret, nil // { - // "description": "Creates a Conversation. If the Conversation to create already exists, an ALREADY_EXISTS error is returned.", - // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/conversations", + // "description": "Creates a Schema.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/schemas", // "httpMethod": "POST", - // "id": "discoveryengine.projects.locations.dataStores.conversations.create", + // "id": "discoveryengine.projects.locations.dataStores.schemas.create", // "parameterOrder": [ // "parent" // ], // "parameters": { // "parent": { - // "description": "Required. Full resource name of parent data store. Format: `projects/{project_number}/locations/{location_id}/collections/{collection}/dataStores/{data_store_id}`", + // "description": "Required. The parent data store resource name, in the format of `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}`.", // "location": "path", // "pattern": "^projects/[^/]+/locations/[^/]+/dataStores/[^/]+$", // "required": true, // "type": "string" + // }, + // "schemaId": { + // "description": "Required. The ID to use for the Schema, which will become the final component of the Schema.name. This field should conform to [RFC-1034](https://tools.ietf.org/html/rfc1034) standard with a length limit of 63 characters.", + // "location": "query", + // "type": "string" // } // }, - // "path": "v1beta/{+parent}/conversations", + // "path": "v1beta/{+parent}/schemas", // "request": { - // "$ref": "GoogleCloudDiscoveryengineV1betaConversation" + // "$ref": "GoogleCloudDiscoveryengineV1betaSchema" // }, // "response": { - // "$ref": "GoogleCloudDiscoveryengineV1betaConversation" + // "$ref": "GoogleLongrunningOperation" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -18889,9 +27257,9 @@ func (c *ProjectsLocationsDataStoresConversationsCreateCall) Do(opts ...googleap } -// method id "discoveryengine.projects.locations.dataStores.conversations.delete": +// method id "discoveryengine.projects.locations.dataStores.schemas.delete": -type ProjectsLocationsDataStoresConversationsDeleteCall struct { +type ProjectsLocationsDataStoresSchemasDeleteCall struct { s *Service name string urlParams_ gensupport.URLParams @@ -18899,14 +27267,13 @@ type ProjectsLocationsDataStoresConversationsDeleteCall struct { header_ http.Header } -// Delete: Deletes a Conversation. If the Conversation to delete does -// not exist, a NOT_FOUND error is returned. +// Delete: Deletes a Schema. // -// - name: The resource name of the Conversation to delete. Format: -// `projects/{project_number}/locations/{location_id}/collections/{coll -// ection}/dataStores/{data_store_id}/conversations/{conversation_id}`. -func (r *ProjectsLocationsDataStoresConversationsService) Delete(name string) *ProjectsLocationsDataStoresConversationsDeleteCall { - c := &ProjectsLocationsDataStoresConversationsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// - name: The full resource name of the schema, in the format of +// `projects/{project}/locations/{location}/collections/{collection}/da +// taStores/{data_store}/schemas/{schema}`. +func (r *ProjectsLocationsDataStoresSchemasService) Delete(name string) *ProjectsLocationsDataStoresSchemasDeleteCall { + c := &ProjectsLocationsDataStoresSchemasDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.name = name return c } @@ -18914,7 +27281,7 @@ func (r *ProjectsLocationsDataStoresConversationsService) Delete(name string) *P // Fields allows partial responses to be retrieved. See // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse // for more information. -func (c *ProjectsLocationsDataStoresConversationsDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsDataStoresConversationsDeleteCall { +func (c *ProjectsLocationsDataStoresSchemasDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsDataStoresSchemasDeleteCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } @@ -18922,21 +27289,21 @@ func (c *ProjectsLocationsDataStoresConversationsDeleteCall) Fields(s ...googlea // Context sets the context to be used in this call's Do method. Any // pending HTTP request will be aborted if the provided context is // canceled. -func (c *ProjectsLocationsDataStoresConversationsDeleteCall) Context(ctx context.Context) *ProjectsLocationsDataStoresConversationsDeleteCall { +func (c *ProjectsLocationsDataStoresSchemasDeleteCall) Context(ctx context.Context) *ProjectsLocationsDataStoresSchemasDeleteCall { c.ctx_ = ctx return c } // Header returns an http.Header that can be modified by the caller to // add HTTP headers to the request. -func (c *ProjectsLocationsDataStoresConversationsDeleteCall) Header() http.Header { +func (c *ProjectsLocationsDataStoresSchemasDeleteCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsDataStoresConversationsDeleteCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsDataStoresSchemasDeleteCall) doRequest(alt string) (*http.Response, error) { reqHeaders := make(http.Header) reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) for k, v := range c.header_ { @@ -18959,14 +27326,14 @@ func (c *ProjectsLocationsDataStoresConversationsDeleteCall) doRequest(alt strin return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "discoveryengine.projects.locations.dataStores.conversations.delete" call. -// Exactly one of *GoogleProtobufEmpty or error will be non-nil. Any -// non-2xx status code is an error. Response headers are in either -// *GoogleProtobufEmpty.ServerResponse.Header or (if a response was -// returned at all) in error.(*googleapi.Error).Header. Use +// Do executes the "discoveryengine.projects.locations.dataStores.schemas.delete" call. +// Exactly one of *GoogleLongrunningOperation or error will be non-nil. +// 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 *ProjectsLocationsDataStoresConversationsDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, error) { +func (c *ProjectsLocationsDataStoresSchemasDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -18985,7 +27352,7 @@ func (c *ProjectsLocationsDataStoresConversationsDeleteCall) Do(opts ...googleap if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &GoogleProtobufEmpty{ + ret := &GoogleLongrunningOperation{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -18997,25 +27364,25 @@ func (c *ProjectsLocationsDataStoresConversationsDeleteCall) Do(opts ...googleap } return ret, nil // { - // "description": "Deletes a Conversation. If the Conversation to delete does not exist, a NOT_FOUND error is returned.", - // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/conversations/{conversationsId}", + // "description": "Deletes a Schema.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/schemas/{schemasId}", // "httpMethod": "DELETE", - // "id": "discoveryengine.projects.locations.dataStores.conversations.delete", + // "id": "discoveryengine.projects.locations.dataStores.schemas.delete", // "parameterOrder": [ // "name" // ], // "parameters": { // "name": { - // "description": "Required. The resource name of the Conversation to delete. Format: `projects/{project_number}/locations/{location_id}/collections/{collection}/dataStores/{data_store_id}/conversations/{conversation_id}`", + // "description": "Required. The full resource name of the schema, in the format of `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/schemas/{schema}`.", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/dataStores/[^/]+/conversations/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/dataStores/[^/]+/schemas/[^/]+$", // "required": true, // "type": "string" // } // }, // "path": "v1beta/{+name}", // "response": { - // "$ref": "GoogleProtobufEmpty" + // "$ref": "GoogleLongrunningOperation" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -19024,9 +27391,9 @@ func (c *ProjectsLocationsDataStoresConversationsDeleteCall) Do(opts ...googleap } -// method id "discoveryengine.projects.locations.dataStores.conversations.get": +// method id "discoveryengine.projects.locations.dataStores.schemas.get": -type ProjectsLocationsDataStoresConversationsGetCall struct { +type ProjectsLocationsDataStoresSchemasGetCall struct { s *Service name string urlParams_ gensupport.URLParams @@ -19035,13 +27402,13 @@ type ProjectsLocationsDataStoresConversationsGetCall struct { header_ http.Header } -// Get: Gets a Conversation. +// Get: Gets a Schema. // -// - name: The resource name of the Conversation to get. Format: -// `projects/{project_number}/locations/{location_id}/collections/{coll -// ection}/dataStores/{data_store_id}/conversations/{conversation_id}`. -func (r *ProjectsLocationsDataStoresConversationsService) Get(name string) *ProjectsLocationsDataStoresConversationsGetCall { - c := &ProjectsLocationsDataStoresConversationsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// - name: The full resource name of the schema, in the format of +// `projects/{project}/locations/{location}/collections/{collection}/da +// taStores/{data_store}/schemas/{schema}`. +func (r *ProjectsLocationsDataStoresSchemasService) Get(name string) *ProjectsLocationsDataStoresSchemasGetCall { + c := &ProjectsLocationsDataStoresSchemasGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.name = name return c } @@ -19049,7 +27416,7 @@ func (r *ProjectsLocationsDataStoresConversationsService) Get(name string) *Proj // Fields allows partial responses to be retrieved. See // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse // for more information. -func (c *ProjectsLocationsDataStoresConversationsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsDataStoresConversationsGetCall { +func (c *ProjectsLocationsDataStoresSchemasGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsDataStoresSchemasGetCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } @@ -19059,7 +27426,7 @@ func (c *ProjectsLocationsDataStoresConversationsGetCall) Fields(s ...googleapi. // getting updates only after the object has changed since the last // request. Use googleapi.IsNotModified to check whether the response // error from Do is the result of In-None-Match. -func (c *ProjectsLocationsDataStoresConversationsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsDataStoresConversationsGetCall { +func (c *ProjectsLocationsDataStoresSchemasGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsDataStoresSchemasGetCall { c.ifNoneMatch_ = entityTag return c } @@ -19067,21 +27434,21 @@ func (c *ProjectsLocationsDataStoresConversationsGetCall) IfNoneMatch(entityTag // Context sets the context to be used in this call's Do method. Any // pending HTTP request will be aborted if the provided context is // canceled. -func (c *ProjectsLocationsDataStoresConversationsGetCall) Context(ctx context.Context) *ProjectsLocationsDataStoresConversationsGetCall { +func (c *ProjectsLocationsDataStoresSchemasGetCall) Context(ctx context.Context) *ProjectsLocationsDataStoresSchemasGetCall { c.ctx_ = ctx return c } // Header returns an http.Header that can be modified by the caller to // add HTTP headers to the request. -func (c *ProjectsLocationsDataStoresConversationsGetCall) Header() http.Header { +func (c *ProjectsLocationsDataStoresSchemasGetCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsDataStoresConversationsGetCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsDataStoresSchemasGetCall) doRequest(alt string) (*http.Response, error) { reqHeaders := make(http.Header) reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) for k, v := range c.header_ { @@ -19107,16 +27474,15 @@ func (c *ProjectsLocationsDataStoresConversationsGetCall) doRequest(alt string) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "discoveryengine.projects.locations.dataStores.conversations.get" call. -// Exactly one of *GoogleCloudDiscoveryengineV1betaConversation or error -// will be non-nil. Any non-2xx status code is an error. Response -// headers are in either -// *GoogleCloudDiscoveryengineV1betaConversation.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 *ProjectsLocationsDataStoresConversationsGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1betaConversation, error) { +// Do executes the "discoveryengine.projects.locations.dataStores.schemas.get" call. +// Exactly one of *GoogleCloudDiscoveryengineV1betaSchema or error will +// be non-nil. Any non-2xx status code is an error. Response headers are +// in either +// *GoogleCloudDiscoveryengineV1betaSchema.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 *ProjectsLocationsDataStoresSchemasGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1betaSchema, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -19135,7 +27501,7 @@ func (c *ProjectsLocationsDataStoresConversationsGetCall) Do(opts ...googleapi.C if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &GoogleCloudDiscoveryengineV1betaConversation{ + ret := &GoogleCloudDiscoveryengineV1betaSchema{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -19147,25 +27513,25 @@ func (c *ProjectsLocationsDataStoresConversationsGetCall) Do(opts ...googleapi.C } return ret, nil // { - // "description": "Gets a Conversation.", - // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/conversations/{conversationsId}", + // "description": "Gets a Schema.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/schemas/{schemasId}", // "httpMethod": "GET", - // "id": "discoveryengine.projects.locations.dataStores.conversations.get", + // "id": "discoveryengine.projects.locations.dataStores.schemas.get", // "parameterOrder": [ // "name" // ], // "parameters": { // "name": { - // "description": "Required. The resource name of the Conversation to get. Format: `projects/{project_number}/locations/{location_id}/collections/{collection}/dataStores/{data_store_id}/conversations/{conversation_id}`", + // "description": "Required. The full resource name of the schema, in the format of `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/schemas/{schema}`.", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/dataStores/[^/]+/conversations/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/dataStores/[^/]+/schemas/[^/]+$", // "required": true, // "type": "string" // } // }, // "path": "v1beta/{+name}", // "response": { - // "$ref": "GoogleCloudDiscoveryengineV1betaConversation" + // "$ref": "GoogleCloudDiscoveryengineV1betaSchema" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -19174,9 +27540,9 @@ func (c *ProjectsLocationsDataStoresConversationsGetCall) Do(opts ...googleapi.C } -// method id "discoveryengine.projects.locations.dataStores.conversations.list": +// method id "discoveryengine.projects.locations.dataStores.schemas.list": -type ProjectsLocationsDataStoresConversationsListCall struct { +type ProjectsLocationsDataStoresSchemasListCall struct { s *Service parent string urlParams_ gensupport.URLParams @@ -19185,47 +27551,32 @@ type ProjectsLocationsDataStoresConversationsListCall struct { header_ http.Header } -// List: Lists all Conversations by their parent DataStore. +// List: Gets a list of Schemas. // -// - parent: The data store resource name. Format: -// `projects/{project_number}/locations/{location_id}/collections/{coll -// ection}/dataStores/{data_store_id}`. -func (r *ProjectsLocationsDataStoresConversationsService) List(parent string) *ProjectsLocationsDataStoresConversationsListCall { - c := &ProjectsLocationsDataStoresConversationsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// - parent: The parent data store resource name, in the format of +// `projects/{project}/locations/{location}/collections/{collection}/da +// taStores/{data_store}`. +func (r *ProjectsLocationsDataStoresSchemasService) List(parent string) *ProjectsLocationsDataStoresSchemasListCall { + c := &ProjectsLocationsDataStoresSchemasListCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.parent = parent return c } -// Filter sets the optional parameter "filter": A filter to apply on the -// list results. The supported features are: user_pseudo_id, state. -// Example: "user_pseudo_id = some_id" -func (c *ProjectsLocationsDataStoresConversationsListCall) Filter(filter string) *ProjectsLocationsDataStoresConversationsListCall { - c.urlParams_.Set("filter", filter) - 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: * `update_time` * -// `create_time` * `conversation_name` Example: "update_time desc" -// "create_time" -func (c *ProjectsLocationsDataStoresConversationsListCall) OrderBy(orderBy string) *ProjectsLocationsDataStoresConversationsListCall { - c.urlParams_.Set("orderBy", orderBy) - return c -} - -// PageSize sets the optional parameter "pageSize": Maximum number of -// results to return. If unspecified, defaults to 50. Max allowed value -// is 1000. -func (c *ProjectsLocationsDataStoresConversationsListCall) PageSize(pageSize int64) *ProjectsLocationsDataStoresConversationsListCall { +// PageSize sets the optional parameter "pageSize": The maximum number +// of Schemas to return. The service may return fewer than this value. +// If unspecified, at most 100 Schemas will be returned. The maximum +// value is 1000; values above 1000 will be coerced to 1000. +func (c *ProjectsLocationsDataStoresSchemasListCall) PageSize(pageSize int64) *ProjectsLocationsDataStoresSchemasListCall { c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) return c } // PageToken sets the optional parameter "pageToken": A page token, -// received from a previous `ListConversations` call. Provide this to -// retrieve the subsequent page. -func (c *ProjectsLocationsDataStoresConversationsListCall) PageToken(pageToken string) *ProjectsLocationsDataStoresConversationsListCall { +// received from a previous SchemaService.ListSchemas call. Provide this +// to retrieve the subsequent page. When paginating, all other +// parameters provided to SchemaService.ListSchemas must match the call +// that provided the page token. +func (c *ProjectsLocationsDataStoresSchemasListCall) PageToken(pageToken string) *ProjectsLocationsDataStoresSchemasListCall { c.urlParams_.Set("pageToken", pageToken) return c } @@ -19233,7 +27584,7 @@ func (c *ProjectsLocationsDataStoresConversationsListCall) PageToken(pageToken s // Fields allows partial responses to be retrieved. See // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse // for more information. -func (c *ProjectsLocationsDataStoresConversationsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsDataStoresConversationsListCall { +func (c *ProjectsLocationsDataStoresSchemasListCall) Fields(s ...googleapi.Field) *ProjectsLocationsDataStoresSchemasListCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } @@ -19243,7 +27594,7 @@ func (c *ProjectsLocationsDataStoresConversationsListCall) Fields(s ...googleapi // getting updates only after the object has changed since the last // request. Use googleapi.IsNotModified to check whether the response // error from Do is the result of In-None-Match. -func (c *ProjectsLocationsDataStoresConversationsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsDataStoresConversationsListCall { +func (c *ProjectsLocationsDataStoresSchemasListCall) IfNoneMatch(entityTag string) *ProjectsLocationsDataStoresSchemasListCall { c.ifNoneMatch_ = entityTag return c } @@ -19251,21 +27602,21 @@ func (c *ProjectsLocationsDataStoresConversationsListCall) IfNoneMatch(entityTag // Context sets the context to be used in this call's Do method. Any // pending HTTP request will be aborted if the provided context is // canceled. -func (c *ProjectsLocationsDataStoresConversationsListCall) Context(ctx context.Context) *ProjectsLocationsDataStoresConversationsListCall { +func (c *ProjectsLocationsDataStoresSchemasListCall) Context(ctx context.Context) *ProjectsLocationsDataStoresSchemasListCall { c.ctx_ = ctx return c } // Header returns an http.Header that can be modified by the caller to // add HTTP headers to the request. -func (c *ProjectsLocationsDataStoresConversationsListCall) Header() http.Header { +func (c *ProjectsLocationsDataStoresSchemasListCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsDataStoresConversationsListCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsDataStoresSchemasListCall) doRequest(alt string) (*http.Response, error) { reqHeaders := make(http.Header) reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) for k, v := range c.header_ { @@ -19278,7 +27629,7 @@ func (c *ProjectsLocationsDataStoresConversationsListCall) doRequest(alt string) var body io.Reader = nil c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+parent}/conversations") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+parent}/schemas") urls += "?" + c.urlParams_.Encode() req, err := http.NewRequest("GET", urls, body) if err != nil { @@ -19291,17 +27642,16 @@ func (c *ProjectsLocationsDataStoresConversationsListCall) doRequest(alt string) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "discoveryengine.projects.locations.dataStores.conversations.list" call. -// Exactly one of -// *GoogleCloudDiscoveryengineV1betaListConversationsResponse or error -// will be non-nil. Any non-2xx status code is an error. Response -// headers are in either -// *GoogleCloudDiscoveryengineV1betaListConversationsResponse.ServerRespo -// nse.Header or (if a response was returned at all) in +// Do executes the "discoveryengine.projects.locations.dataStores.schemas.list" call. +// Exactly one of *GoogleCloudDiscoveryengineV1betaListSchemasResponse +// or error will be non-nil. Any non-2xx status code is an error. +// Response headers are in either +// *GoogleCloudDiscoveryengineV1betaListSchemasResponse.ServerResponse.He +// ader 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 *ProjectsLocationsDataStoresConversationsListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1betaListConversationsResponse, error) { +func (c *ProjectsLocationsDataStoresSchemasListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1betaListSchemasResponse, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -19320,7 +27670,7 @@ func (c *ProjectsLocationsDataStoresConversationsListCall) Do(opts ...googleapi. if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &GoogleCloudDiscoveryengineV1betaListConversationsResponse{ + ret := &GoogleCloudDiscoveryengineV1betaListSchemasResponse{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -19332,46 +27682,36 @@ func (c *ProjectsLocationsDataStoresConversationsListCall) Do(opts ...googleapi. } return ret, nil // { - // "description": "Lists all Conversations by their parent DataStore.", - // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/conversations", + // "description": "Gets a list of Schemas.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/schemas", // "httpMethod": "GET", - // "id": "discoveryengine.projects.locations.dataStores.conversations.list", + // "id": "discoveryengine.projects.locations.dataStores.schemas.list", // "parameterOrder": [ // "parent" // ], // "parameters": { - // "filter": { - // "description": "A filter to apply on the list results. The supported features are: user_pseudo_id, state. Example: \"user_pseudo_id = some_id\"", - // "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: * `update_time` * `create_time` * `conversation_name` Example: \"update_time desc\" \"create_time\"", - // "location": "query", - // "type": "string" - // }, // "pageSize": { - // "description": "Maximum number of results to return. If unspecified, defaults to 50. Max allowed value is 1000.", + // "description": "The maximum number of Schemas to return. The service may return fewer than this value. If unspecified, at most 100 Schemas will be returned. The maximum value is 1000; values above 1000 will be coerced to 1000.", // "format": "int32", // "location": "query", // "type": "integer" // }, // "pageToken": { - // "description": "A page token, received from a previous `ListConversations` call. Provide this to retrieve the subsequent page.", + // "description": "A page token, received from a previous SchemaService.ListSchemas call. Provide this to retrieve the subsequent page. When paginating, all other parameters provided to SchemaService.ListSchemas must match the call that provided the page token.", // "location": "query", // "type": "string" // }, // "parent": { - // "description": "Required. The data store resource name. Format: `projects/{project_number}/locations/{location_id}/collections/{collection}/dataStores/{data_store_id}`", + // "description": "Required. The parent data store resource name, in the format of `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}`.", // "location": "path", // "pattern": "^projects/[^/]+/locations/[^/]+/dataStores/[^/]+$", // "required": true, // "type": "string" // } // }, - // "path": "v1beta/{+parent}/conversations", + // "path": "v1beta/{+parent}/schemas", // "response": { - // "$ref": "GoogleCloudDiscoveryengineV1betaListConversationsResponse" + // "$ref": "GoogleCloudDiscoveryengineV1betaListSchemasResponse" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -19383,7 +27723,7 @@ func (c *ProjectsLocationsDataStoresConversationsListCall) Do(opts ...googleapi. // 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 *ProjectsLocationsDataStoresConversationsListCall) Pages(ctx context.Context, f func(*GoogleCloudDiscoveryengineV1betaListConversationsResponse) error) error { +func (c *ProjectsLocationsDataStoresSchemasListCall) Pages(ctx context.Context, f func(*GoogleCloudDiscoveryengineV1betaListSchemasResponse) error) error { c.ctx_ = ctx defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point for { @@ -19401,46 +27741,43 @@ func (c *ProjectsLocationsDataStoresConversationsListCall) Pages(ctx context.Con } } -// method id "discoveryengine.projects.locations.dataStores.conversations.patch": +// method id "discoveryengine.projects.locations.dataStores.schemas.patch": -type ProjectsLocationsDataStoresConversationsPatchCall struct { - s *Service - name string - googleclouddiscoveryenginev1betaconversation *GoogleCloudDiscoveryengineV1betaConversation - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +type ProjectsLocationsDataStoresSchemasPatchCall struct { + s *Service + name string + googleclouddiscoveryenginev1betaschema *GoogleCloudDiscoveryengineV1betaSchema + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// Patch: Updates a Conversation. Conversation action type cannot be -// changed. If the Conversation to update does not exist, a NOT_FOUND -// error is returned. +// Patch: Updates a Schema. // -// - name: Immutable. Fully qualified name -// `project/*/locations/global/collections/{collection}/dataStore/*/con -// versations/*` or -// `project/*/locations/global/collections/{collection}/engines/*/conve -// rsations/*`. -func (r *ProjectsLocationsDataStoresConversationsService) Patch(name string, googleclouddiscoveryenginev1betaconversation *GoogleCloudDiscoveryengineV1betaConversation) *ProjectsLocationsDataStoresConversationsPatchCall { - c := &ProjectsLocationsDataStoresConversationsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// - name: Immutable. The full resource name of the schema, in the +// format of +// `projects/{project}/locations/{location}/collections/{collection}/da +// taStores/{data_store}/schemas/{schema}`. This field must be a UTF-8 +// encoded string with a length limit of 1024 characters. +func (r *ProjectsLocationsDataStoresSchemasService) Patch(name string, googleclouddiscoveryenginev1betaschema *GoogleCloudDiscoveryengineV1betaSchema) *ProjectsLocationsDataStoresSchemasPatchCall { + c := &ProjectsLocationsDataStoresSchemasPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.name = name - c.googleclouddiscoveryenginev1betaconversation = googleclouddiscoveryenginev1betaconversation + c.googleclouddiscoveryenginev1betaschema = googleclouddiscoveryenginev1betaschema return c } -// UpdateMask sets the optional parameter "updateMask": Indicates which -// fields in the provided Conversation to update. The following are NOT -// supported: * Conversation.name If not set or empty, all supported -// fields are updated. -func (c *ProjectsLocationsDataStoresConversationsPatchCall) UpdateMask(updateMask string) *ProjectsLocationsDataStoresConversationsPatchCall { - c.urlParams_.Set("updateMask", updateMask) +// AllowMissing sets the optional parameter "allowMissing": If set to +// true, and the Schema is not found, a new Schema will be created. In +// this situation, `update_mask` is ignored. +func (c *ProjectsLocationsDataStoresSchemasPatchCall) AllowMissing(allowMissing bool) *ProjectsLocationsDataStoresSchemasPatchCall { + c.urlParams_.Set("allowMissing", fmt.Sprint(allowMissing)) return c } // Fields allows partial responses to be retrieved. See // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse // for more information. -func (c *ProjectsLocationsDataStoresConversationsPatchCall) Fields(s ...googleapi.Field) *ProjectsLocationsDataStoresConversationsPatchCall { +func (c *ProjectsLocationsDataStoresSchemasPatchCall) Fields(s ...googleapi.Field) *ProjectsLocationsDataStoresSchemasPatchCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } @@ -19448,21 +27785,21 @@ func (c *ProjectsLocationsDataStoresConversationsPatchCall) Fields(s ...googleap // Context sets the context to be used in this call's Do method. Any // pending HTTP request will be aborted if the provided context is // canceled. -func (c *ProjectsLocationsDataStoresConversationsPatchCall) Context(ctx context.Context) *ProjectsLocationsDataStoresConversationsPatchCall { +func (c *ProjectsLocationsDataStoresSchemasPatchCall) Context(ctx context.Context) *ProjectsLocationsDataStoresSchemasPatchCall { c.ctx_ = ctx return c } // Header returns an http.Header that can be modified by the caller to // add HTTP headers to the request. -func (c *ProjectsLocationsDataStoresConversationsPatchCall) Header() http.Header { +func (c *ProjectsLocationsDataStoresSchemasPatchCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsDataStoresConversationsPatchCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsDataStoresSchemasPatchCall) doRequest(alt string) (*http.Response, error) { reqHeaders := make(http.Header) reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) for k, v := range c.header_ { @@ -19470,7 +27807,7 @@ func (c *ProjectsLocationsDataStoresConversationsPatchCall) doRequest(alt string } reqHeaders.Set("User-Agent", c.s.userAgent()) var body io.Reader = nil - body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddiscoveryenginev1betaconversation) + body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddiscoveryenginev1betaschema) if err != nil { return nil, err } @@ -19490,16 +27827,14 @@ func (c *ProjectsLocationsDataStoresConversationsPatchCall) doRequest(alt string return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "discoveryengine.projects.locations.dataStores.conversations.patch" call. -// Exactly one of *GoogleCloudDiscoveryengineV1betaConversation or error -// will be non-nil. Any non-2xx status code is an error. Response -// headers are in either -// *GoogleCloudDiscoveryengineV1betaConversation.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 *ProjectsLocationsDataStoresConversationsPatchCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1betaConversation, error) { +// Do executes the "discoveryengine.projects.locations.dataStores.schemas.patch" call. +// Exactly one of *GoogleLongrunningOperation or error will be non-nil. +// 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 *ProjectsLocationsDataStoresSchemasPatchCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -19518,7 +27853,7 @@ func (c *ProjectsLocationsDataStoresConversationsPatchCall) Do(opts ...googleapi if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &GoogleCloudDiscoveryengineV1betaConversation{ + ret := &GoogleLongrunningOperation{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -19530,34 +27865,33 @@ func (c *ProjectsLocationsDataStoresConversationsPatchCall) Do(opts ...googleapi } return ret, nil // { - // "description": "Updates a Conversation. Conversation action type cannot be changed. If the Conversation to update does not exist, a NOT_FOUND error is returned.", - // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/conversations/{conversationsId}", + // "description": "Updates a Schema.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/schemas/{schemasId}", // "httpMethod": "PATCH", - // "id": "discoveryengine.projects.locations.dataStores.conversations.patch", + // "id": "discoveryengine.projects.locations.dataStores.schemas.patch", // "parameterOrder": [ // "name" // ], // "parameters": { + // "allowMissing": { + // "description": "If set to true, and the Schema is not found, a new Schema will be created. In this situation, `update_mask` is ignored.", + // "location": "query", + // "type": "boolean" + // }, // "name": { - // "description": "Immutable. Fully qualified name `project/*/locations/global/collections/{collection}/dataStore/*/conversations/*` or `project/*/locations/global/collections/{collection}/engines/*/conversations/*`.", + // "description": "Immutable. The full resource name of the schema, in the format of `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/schemas/{schema}`. This field must be a UTF-8 encoded string with a length limit of 1024 characters.", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/dataStores/[^/]+/conversations/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/dataStores/[^/]+/schemas/[^/]+$", // "required": true, // "type": "string" - // }, - // "updateMask": { - // "description": "Indicates which fields in the provided Conversation to update. The following are NOT supported: * Conversation.name If not set or empty, all supported fields are updated.", - // "format": "google-fieldmask", - // "location": "query", - // "type": "string" // } // }, // "path": "v1beta/{+name}", // "request": { - // "$ref": "GoogleCloudDiscoveryengineV1betaConversation" + // "$ref": "GoogleCloudDiscoveryengineV1betaSchema" // }, // "response": { - // "$ref": "GoogleCloudDiscoveryengineV1betaConversation" + // "$ref": "GoogleLongrunningOperation" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -19566,97 +27900,102 @@ func (c *ProjectsLocationsDataStoresConversationsPatchCall) Do(opts ...googleapi } -// method id "discoveryengine.projects.locations.dataStores.models.operations.get": +// method id "discoveryengine.projects.locations.dataStores.servingConfigs.recommend": -type ProjectsLocationsDataStoresModelsOperationsGetCall struct { - s *Service - name string - urlParams_ gensupport.URLParams - ifNoneMatch_ string - ctx_ context.Context - header_ http.Header +type ProjectsLocationsDataStoresServingConfigsRecommendCall struct { + s *Service + servingConfig string + googleclouddiscoveryenginev1betarecommendrequest *GoogleCloudDiscoveryengineV1betaRecommendRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// Get: Gets the latest state of a long-running operation. Clients can -// use this method to poll the operation result at intervals as -// recommended by the API service. +// Recommend: Makes a recommendation, which requires a contextual user +// event. // -// - name: The name of the operation resource. -func (r *ProjectsLocationsDataStoresModelsOperationsService) Get(name string) *ProjectsLocationsDataStoresModelsOperationsGetCall { - c := &ProjectsLocationsDataStoresModelsOperationsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.name = name +// - servingConfig: Full resource name of a ServingConfig: +// `projects/*/locations/global/collections/*/engines/*/servingConfigs/ +// *`, or +// `projects/*/locations/global/collections/*/dataStores/*/servingConfi +// gs/*` One default serving config is created along with your +// recommendation engine creation. The engine ID will be used as the +// ID of the default serving config. For example, for Engine +// `projects/*/locations/global/collections/*/engines/my-engine`, you +// can use +// `projects/*/locations/global/collections/*/engines/my-engine/serving +// Configs/my-engine` for your RecommendationService.Recommend +// requests. +func (r *ProjectsLocationsDataStoresServingConfigsService) Recommend(servingConfig string, googleclouddiscoveryenginev1betarecommendrequest *GoogleCloudDiscoveryengineV1betaRecommendRequest) *ProjectsLocationsDataStoresServingConfigsRecommendCall { + c := &ProjectsLocationsDataStoresServingConfigsRecommendCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.servingConfig = servingConfig + c.googleclouddiscoveryenginev1betarecommendrequest = googleclouddiscoveryenginev1betarecommendrequest return c } // Fields allows partial responses to be retrieved. See // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse // for more information. -func (c *ProjectsLocationsDataStoresModelsOperationsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsDataStoresModelsOperationsGetCall { +func (c *ProjectsLocationsDataStoresServingConfigsRecommendCall) Fields(s ...googleapi.Field) *ProjectsLocationsDataStoresServingConfigsRecommendCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// IfNoneMatch sets the 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. Use googleapi.IsNotModified to check whether the response -// error from Do is the result of In-None-Match. -func (c *ProjectsLocationsDataStoresModelsOperationsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsDataStoresModelsOperationsGetCall { - c.ifNoneMatch_ = entityTag - return c -} - // Context sets the context to be used in this call's Do method. Any // pending HTTP request will be aborted if the provided context is // canceled. -func (c *ProjectsLocationsDataStoresModelsOperationsGetCall) Context(ctx context.Context) *ProjectsLocationsDataStoresModelsOperationsGetCall { +func (c *ProjectsLocationsDataStoresServingConfigsRecommendCall) Context(ctx context.Context) *ProjectsLocationsDataStoresServingConfigsRecommendCall { c.ctx_ = ctx return c } // Header returns an http.Header that can be modified by the caller to // add HTTP headers to the request. -func (c *ProjectsLocationsDataStoresModelsOperationsGetCall) Header() http.Header { +func (c *ProjectsLocationsDataStoresServingConfigsRecommendCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsDataStoresModelsOperationsGetCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsDataStoresServingConfigsRecommendCall) doRequest(alt string) (*http.Response, error) { reqHeaders := make(http.Header) reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) for k, v := range c.header_ { reqHeaders[k] = v } reqHeaders.Set("User-Agent", c.s.userAgent()) - if c.ifNoneMatch_ != "" { - reqHeaders.Set("If-None-Match", c.ifNoneMatch_) - } var body io.Reader = nil + body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddiscoveryenginev1betarecommendrequest) + if err != nil { + return nil, err + } + reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+servingConfig}:recommend") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("GET", urls, body) + req, err := http.NewRequest("POST", urls, body) if err != nil { return nil, err } req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ - "name": c.name, + "servingConfig": c.servingConfig, }) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "discoveryengine.projects.locations.dataStores.models.operations.get" call. -// Exactly one of *GoogleLongrunningOperation or error will be non-nil. -// 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 *ProjectsLocationsDataStoresModelsOperationsGetCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { +// Do executes the "discoveryengine.projects.locations.dataStores.servingConfigs.recommend" call. +// Exactly one of *GoogleCloudDiscoveryengineV1betaRecommendResponse or +// error will be non-nil. Any non-2xx status code is an error. Response +// headers are in either +// *GoogleCloudDiscoveryengineV1betaRecommendResponse.ServerResponse.Head +// er 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 *ProjectsLocationsDataStoresServingConfigsRecommendCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1betaRecommendResponse, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -19675,7 +28014,7 @@ func (c *ProjectsLocationsDataStoresModelsOperationsGetCall) Do(opts ...googleap if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &GoogleLongrunningOperation{ + ret := &GoogleCloudDiscoveryengineV1betaRecommendResponse{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -19687,25 +28026,28 @@ func (c *ProjectsLocationsDataStoresModelsOperationsGetCall) Do(opts ...googleap } return ret, nil // { - // "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": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/models/{modelsId}/operations/{operationsId}", - // "httpMethod": "GET", - // "id": "discoveryengine.projects.locations.dataStores.models.operations.get", + // "description": "Makes a recommendation, which requires a contextual user event.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/servingConfigs/{servingConfigsId}:recommend", + // "httpMethod": "POST", + // "id": "discoveryengine.projects.locations.dataStores.servingConfigs.recommend", // "parameterOrder": [ - // "name" + // "servingConfig" // ], // "parameters": { - // "name": { - // "description": "The name of the operation resource.", + // "servingConfig": { + // "description": "Required. Full resource name of a ServingConfig: `projects/*/locations/global/collections/*/engines/*/servingConfigs/*`, or `projects/*/locations/global/collections/*/dataStores/*/servingConfigs/*` One default serving config is created along with your recommendation engine creation. The engine ID will be used as the ID of the default serving config. For example, for Engine `projects/*/locations/global/collections/*/engines/my-engine`, you can use `projects/*/locations/global/collections/*/engines/my-engine/servingConfigs/my-engine` for your RecommendationService.Recommend requests.", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/dataStores/[^/]+/models/[^/]+/operations/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/dataStores/[^/]+/servingConfigs/[^/]+$", // "required": true, // "type": "string" // } // }, - // "path": "v1beta/{+name}", + // "path": "v1beta/{+servingConfig}:recommend", + // "request": { + // "$ref": "GoogleCloudDiscoveryengineV1betaRecommendRequest" + // }, // "response": { - // "$ref": "GoogleLongrunningOperation" + // "$ref": "GoogleCloudDiscoveryengineV1betaRecommendResponse" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -19714,119 +28056,97 @@ func (c *ProjectsLocationsDataStoresModelsOperationsGetCall) Do(opts ...googleap } -// method id "discoveryengine.projects.locations.dataStores.models.operations.list": +// method id "discoveryengine.projects.locations.dataStores.servingConfigs.search": -type ProjectsLocationsDataStoresModelsOperationsListCall struct { - s *Service - name string - urlParams_ gensupport.URLParams - ifNoneMatch_ string - ctx_ context.Context - header_ http.Header +type ProjectsLocationsDataStoresServingConfigsSearchCall struct { + s *Service + servingConfig string + googleclouddiscoveryenginev1betasearchrequest *GoogleCloudDiscoveryengineV1betaSearchRequest + urlParams_ gensupport.URLParams + 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`. +// Search: Performs a search. // -// - name: The name of the operation's parent resource. -func (r *ProjectsLocationsDataStoresModelsOperationsService) List(name string) *ProjectsLocationsDataStoresModelsOperationsListCall { - c := &ProjectsLocationsDataStoresModelsOperationsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.name = name - return c -} - -// Filter sets the optional parameter "filter": The standard list -// filter. -func (c *ProjectsLocationsDataStoresModelsOperationsListCall) Filter(filter string) *ProjectsLocationsDataStoresModelsOperationsListCall { - c.urlParams_.Set("filter", filter) - return c -} - -// PageSize sets the optional parameter "pageSize": The standard list -// page size. -func (c *ProjectsLocationsDataStoresModelsOperationsListCall) PageSize(pageSize int64) *ProjectsLocationsDataStoresModelsOperationsListCall { - c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) - return c -} - -// PageToken sets the optional parameter "pageToken": The standard list -// page token. -func (c *ProjectsLocationsDataStoresModelsOperationsListCall) PageToken(pageToken string) *ProjectsLocationsDataStoresModelsOperationsListCall { - c.urlParams_.Set("pageToken", pageToken) +// - servingConfig: The resource name of the Search serving config, such +// as +// `projects/*/locations/global/collections/default_collection/engines/ +// */servingConfigs/default_serving_config`, or +// `projects/*/locations/global/collections/default_collection/dataStor +// es/default_data_store/servingConfigs/default_serving_config`. This +// field is used to identify the serving configuration name, set of +// models used to make the search. +func (r *ProjectsLocationsDataStoresServingConfigsService) Search(servingConfig string, googleclouddiscoveryenginev1betasearchrequest *GoogleCloudDiscoveryengineV1betaSearchRequest) *ProjectsLocationsDataStoresServingConfigsSearchCall { + c := &ProjectsLocationsDataStoresServingConfigsSearchCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.servingConfig = servingConfig + c.googleclouddiscoveryenginev1betasearchrequest = googleclouddiscoveryenginev1betasearchrequest return c } // Fields allows partial responses to be retrieved. See // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse // for more information. -func (c *ProjectsLocationsDataStoresModelsOperationsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsDataStoresModelsOperationsListCall { +func (c *ProjectsLocationsDataStoresServingConfigsSearchCall) Fields(s ...googleapi.Field) *ProjectsLocationsDataStoresServingConfigsSearchCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// IfNoneMatch sets the 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. Use googleapi.IsNotModified to check whether the response -// error from Do is the result of In-None-Match. -func (c *ProjectsLocationsDataStoresModelsOperationsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsDataStoresModelsOperationsListCall { - c.ifNoneMatch_ = entityTag - return c -} - // Context sets the context to be used in this call's Do method. Any // pending HTTP request will be aborted if the provided context is // canceled. -func (c *ProjectsLocationsDataStoresModelsOperationsListCall) Context(ctx context.Context) *ProjectsLocationsDataStoresModelsOperationsListCall { +func (c *ProjectsLocationsDataStoresServingConfigsSearchCall) Context(ctx context.Context) *ProjectsLocationsDataStoresServingConfigsSearchCall { c.ctx_ = ctx return c } // Header returns an http.Header that can be modified by the caller to // add HTTP headers to the request. -func (c *ProjectsLocationsDataStoresModelsOperationsListCall) Header() http.Header { +func (c *ProjectsLocationsDataStoresServingConfigsSearchCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsDataStoresModelsOperationsListCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsDataStoresServingConfigsSearchCall) doRequest(alt string) (*http.Response, error) { reqHeaders := make(http.Header) reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) for k, v := range c.header_ { reqHeaders[k] = v } reqHeaders.Set("User-Agent", c.s.userAgent()) - if c.ifNoneMatch_ != "" { - reqHeaders.Set("If-None-Match", c.ifNoneMatch_) - } var body io.Reader = nil + body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddiscoveryenginev1betasearchrequest) + if err != nil { + return nil, err + } + reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}/operations") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+servingConfig}:search") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("GET", urls, body) + req, err := http.NewRequest("POST", urls, body) if err != nil { return nil, err } req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ - "name": c.name, + "servingConfig": c.servingConfig, }) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "discoveryengine.projects.locations.dataStores.models.operations.list" call. -// Exactly one of *GoogleLongrunningListOperationsResponse or error will -// be non-nil. Any non-2xx status code is an error. Response headers are -// in either -// *GoogleLongrunningListOperationsResponse.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 *ProjectsLocationsDataStoresModelsOperationsListCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningListOperationsResponse, error) { +// Do executes the "discoveryengine.projects.locations.dataStores.servingConfigs.search" call. +// Exactly one of *GoogleCloudDiscoveryengineV1betaSearchResponse or +// error will be non-nil. Any non-2xx status code is an error. Response +// headers are in either +// *GoogleCloudDiscoveryengineV1betaSearchResponse.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 *ProjectsLocationsDataStoresServingConfigsSearchCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1betaSearchResponse, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -19845,7 +28165,7 @@ func (c *ProjectsLocationsDataStoresModelsOperationsListCall) Do(opts ...googlea if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &GoogleLongrunningListOperationsResponse{ + ret := &GoogleCloudDiscoveryengineV1betaSearchResponse{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -19857,41 +28177,28 @@ func (c *ProjectsLocationsDataStoresModelsOperationsListCall) Do(opts ...googlea } return ret, nil // { - // "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`.", - // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/models/{modelsId}/operations", - // "httpMethod": "GET", - // "id": "discoveryengine.projects.locations.dataStores.models.operations.list", + // "description": "Performs a search.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/servingConfigs/{servingConfigsId}:search", + // "httpMethod": "POST", + // "id": "discoveryengine.projects.locations.dataStores.servingConfigs.search", // "parameterOrder": [ - // "name" + // "servingConfig" // ], // "parameters": { - // "filter": { - // "description": "The standard list filter.", - // "location": "query", - // "type": "string" - // }, - // "name": { - // "description": "The name of the operation's parent resource.", + // "servingConfig": { + // "description": "Required. The resource name of the Search serving config, such as `projects/*/locations/global/collections/default_collection/engines/*/servingConfigs/default_serving_config`, or `projects/*/locations/global/collections/default_collection/dataStores/default_data_store/servingConfigs/default_serving_config`. This field is used to identify the serving configuration name, set of models used to make the search.", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/dataStores/[^/]+/models/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/dataStores/[^/]+/servingConfigs/[^/]+$", // "required": true, // "type": "string" - // }, - // "pageSize": { - // "description": "The standard list page size.", - // "format": "int32", - // "location": "query", - // "type": "integer" - // }, - // "pageToken": { - // "description": "The standard list page token.", - // "location": "query", - // "type": "string" // } // }, - // "path": "v1beta/{+name}/operations", + // "path": "v1beta/{+servingConfig}:search", + // "request": { + // "$ref": "GoogleCloudDiscoveryengineV1betaSearchRequest" + // }, // "response": { - // "$ref": "GoogleLongrunningListOperationsResponse" + // "$ref": "GoogleCloudDiscoveryengineV1betaSearchResponse" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -19903,9 +28210,9 @@ func (c *ProjectsLocationsDataStoresModelsOperationsListCall) Do(opts ...googlea // 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 *ProjectsLocationsDataStoresModelsOperationsListCall) Pages(ctx context.Context, f func(*GoogleLongrunningListOperationsResponse) error) error { +func (c *ProjectsLocationsDataStoresServingConfigsSearchCall) Pages(ctx context.Context, f func(*GoogleCloudDiscoveryengineV1betaSearchResponse) error) error { c.ctx_ = ctx - defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point + defer func(pt string) { c.googleclouddiscoveryenginev1betasearchrequest.PageToken = pt }(c.googleclouddiscoveryenginev1betasearchrequest.PageToken) // reset paging to original point for { x, err := c.Do() if err != nil { @@ -19917,101 +28224,96 @@ func (c *ProjectsLocationsDataStoresModelsOperationsListCall) Pages(ctx context. if x.NextPageToken == "" { return nil } - c.PageToken(x.NextPageToken) - } -} - -// method id "discoveryengine.projects.locations.dataStores.operations.get": - -type ProjectsLocationsDataStoresOperationsGetCall struct { - s *Service - name string - urlParams_ gensupport.URLParams - ifNoneMatch_ string - ctx_ context.Context - header_ http.Header + c.googleclouddiscoveryenginev1betasearchrequest.PageToken = x.NextPageToken + } } -// Get: Gets the latest state of a long-running operation. Clients can -// use this method to poll the operation result at intervals as -// recommended by the API service. +// method id "discoveryengine.projects.locations.dataStores.siteSearchEngine.disableAdvancedSiteSearch": + +type ProjectsLocationsDataStoresSiteSearchEngineDisableAdvancedSiteSearchCall struct { + s *Service + siteSearchEngine string + googleclouddiscoveryenginev1betadisableadvancedsitesearchrequest *GoogleCloudDiscoveryengineV1betaDisableAdvancedSiteSearchRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// DisableAdvancedSiteSearch: Downgrade from advanced site search to +// basic site search. // -// - name: The name of the operation resource. -func (r *ProjectsLocationsDataStoresOperationsService) Get(name string) *ProjectsLocationsDataStoresOperationsGetCall { - c := &ProjectsLocationsDataStoresOperationsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.name = name +// - siteSearchEngine: Full resource name of the SiteSearchEngine, such +// as +// `projects/{project}/locations/{location}/dataStores/{data_store_id}/ +// siteSearchEngine`. +func (r *ProjectsLocationsDataStoresSiteSearchEngineService) DisableAdvancedSiteSearch(siteSearchEngine string, googleclouddiscoveryenginev1betadisableadvancedsitesearchrequest *GoogleCloudDiscoveryengineV1betaDisableAdvancedSiteSearchRequest) *ProjectsLocationsDataStoresSiteSearchEngineDisableAdvancedSiteSearchCall { + c := &ProjectsLocationsDataStoresSiteSearchEngineDisableAdvancedSiteSearchCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.siteSearchEngine = siteSearchEngine + c.googleclouddiscoveryenginev1betadisableadvancedsitesearchrequest = googleclouddiscoveryenginev1betadisableadvancedsitesearchrequest return c } // Fields allows partial responses to be retrieved. See // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse // for more information. -func (c *ProjectsLocationsDataStoresOperationsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsDataStoresOperationsGetCall { +func (c *ProjectsLocationsDataStoresSiteSearchEngineDisableAdvancedSiteSearchCall) Fields(s ...googleapi.Field) *ProjectsLocationsDataStoresSiteSearchEngineDisableAdvancedSiteSearchCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// IfNoneMatch sets the 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. Use googleapi.IsNotModified to check whether the response -// error from Do is the result of In-None-Match. -func (c *ProjectsLocationsDataStoresOperationsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsDataStoresOperationsGetCall { - c.ifNoneMatch_ = entityTag - return c -} - // Context sets the context to be used in this call's Do method. Any // pending HTTP request will be aborted if the provided context is // canceled. -func (c *ProjectsLocationsDataStoresOperationsGetCall) Context(ctx context.Context) *ProjectsLocationsDataStoresOperationsGetCall { +func (c *ProjectsLocationsDataStoresSiteSearchEngineDisableAdvancedSiteSearchCall) Context(ctx context.Context) *ProjectsLocationsDataStoresSiteSearchEngineDisableAdvancedSiteSearchCall { c.ctx_ = ctx return c } // Header returns an http.Header that can be modified by the caller to // add HTTP headers to the request. -func (c *ProjectsLocationsDataStoresOperationsGetCall) Header() http.Header { +func (c *ProjectsLocationsDataStoresSiteSearchEngineDisableAdvancedSiteSearchCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsDataStoresOperationsGetCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsDataStoresSiteSearchEngineDisableAdvancedSiteSearchCall) doRequest(alt string) (*http.Response, error) { reqHeaders := make(http.Header) reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) for k, v := range c.header_ { reqHeaders[k] = v } reqHeaders.Set("User-Agent", c.s.userAgent()) - if c.ifNoneMatch_ != "" { - reqHeaders.Set("If-None-Match", c.ifNoneMatch_) - } var body io.Reader = nil + body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddiscoveryenginev1betadisableadvancedsitesearchrequest) + if err != nil { + return nil, err + } + reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+siteSearchEngine}:disableAdvancedSiteSearch") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("GET", urls, body) + req, err := http.NewRequest("POST", urls, body) if err != nil { return nil, err } req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ - "name": c.name, + "siteSearchEngine": c.siteSearchEngine, }) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "discoveryengine.projects.locations.dataStores.operations.get" call. +// Do executes the "discoveryengine.projects.locations.dataStores.siteSearchEngine.disableAdvancedSiteSearch" call. // Exactly one of *GoogleLongrunningOperation or error will be non-nil. // 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 *ProjectsLocationsDataStoresOperationsGetCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { +func (c *ProjectsLocationsDataStoresSiteSearchEngineDisableAdvancedSiteSearchCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -20042,23 +28344,26 @@ func (c *ProjectsLocationsDataStoresOperationsGetCall) Do(opts ...googleapi.Call } return ret, nil // { - // "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": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/operations/{operationsId}", - // "httpMethod": "GET", - // "id": "discoveryengine.projects.locations.dataStores.operations.get", + // "description": "Downgrade from advanced site search to basic site search.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/siteSearchEngine:disableAdvancedSiteSearch", + // "httpMethod": "POST", + // "id": "discoveryengine.projects.locations.dataStores.siteSearchEngine.disableAdvancedSiteSearch", // "parameterOrder": [ - // "name" + // "siteSearchEngine" // ], // "parameters": { - // "name": { - // "description": "The name of the operation resource.", + // "siteSearchEngine": { + // "description": "Required. Full resource name of the SiteSearchEngine, such as `projects/{project}/locations/{location}/dataStores/{data_store_id}/siteSearchEngine`.", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/dataStores/[^/]+/operations/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/dataStores/[^/]+/siteSearchEngine$", // "required": true, // "type": "string" // } // }, - // "path": "v1beta/{+name}", + // "path": "v1beta/{+siteSearchEngine}:disableAdvancedSiteSearch", + // "request": { + // "$ref": "GoogleCloudDiscoveryengineV1betaDisableAdvancedSiteSearchRequest" + // }, // "response": { // "$ref": "GoogleLongrunningOperation" // }, @@ -20069,119 +28374,92 @@ func (c *ProjectsLocationsDataStoresOperationsGetCall) Do(opts ...googleapi.Call } -// method id "discoveryengine.projects.locations.dataStores.operations.list": +// method id "discoveryengine.projects.locations.dataStores.siteSearchEngine.enableAdvancedSiteSearch": -type ProjectsLocationsDataStoresOperationsListCall struct { - s *Service - name string - urlParams_ gensupport.URLParams - ifNoneMatch_ string - ctx_ context.Context - header_ http.Header +type ProjectsLocationsDataStoresSiteSearchEngineEnableAdvancedSiteSearchCall struct { + s *Service + siteSearchEngine string + googleclouddiscoveryenginev1betaenableadvancedsitesearchrequest *GoogleCloudDiscoveryengineV1betaEnableAdvancedSiteSearchRequest + urlParams_ gensupport.URLParams + 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`. +// EnableAdvancedSiteSearch: Upgrade from basic site search to advanced +// site search. // -// - name: The name of the operation's parent resource. -func (r *ProjectsLocationsDataStoresOperationsService) List(name string) *ProjectsLocationsDataStoresOperationsListCall { - c := &ProjectsLocationsDataStoresOperationsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.name = name - return c -} - -// Filter sets the optional parameter "filter": The standard list -// filter. -func (c *ProjectsLocationsDataStoresOperationsListCall) Filter(filter string) *ProjectsLocationsDataStoresOperationsListCall { - c.urlParams_.Set("filter", filter) - return c -} - -// PageSize sets the optional parameter "pageSize": The standard list -// page size. -func (c *ProjectsLocationsDataStoresOperationsListCall) PageSize(pageSize int64) *ProjectsLocationsDataStoresOperationsListCall { - c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) - return c -} - -// PageToken sets the optional parameter "pageToken": The standard list -// page token. -func (c *ProjectsLocationsDataStoresOperationsListCall) PageToken(pageToken string) *ProjectsLocationsDataStoresOperationsListCall { - c.urlParams_.Set("pageToken", pageToken) +// - siteSearchEngine: Full resource name of the SiteSearchEngine, such +// as +// `projects/{project}/locations/{location}/dataStores/{data_store_id}/ +// siteSearchEngine`. +func (r *ProjectsLocationsDataStoresSiteSearchEngineService) EnableAdvancedSiteSearch(siteSearchEngine string, googleclouddiscoveryenginev1betaenableadvancedsitesearchrequest *GoogleCloudDiscoveryengineV1betaEnableAdvancedSiteSearchRequest) *ProjectsLocationsDataStoresSiteSearchEngineEnableAdvancedSiteSearchCall { + c := &ProjectsLocationsDataStoresSiteSearchEngineEnableAdvancedSiteSearchCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.siteSearchEngine = siteSearchEngine + c.googleclouddiscoveryenginev1betaenableadvancedsitesearchrequest = googleclouddiscoveryenginev1betaenableadvancedsitesearchrequest return c } // Fields allows partial responses to be retrieved. See // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse // for more information. -func (c *ProjectsLocationsDataStoresOperationsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsDataStoresOperationsListCall { +func (c *ProjectsLocationsDataStoresSiteSearchEngineEnableAdvancedSiteSearchCall) Fields(s ...googleapi.Field) *ProjectsLocationsDataStoresSiteSearchEngineEnableAdvancedSiteSearchCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// IfNoneMatch sets the 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. Use googleapi.IsNotModified to check whether the response -// error from Do is the result of In-None-Match. -func (c *ProjectsLocationsDataStoresOperationsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsDataStoresOperationsListCall { - c.ifNoneMatch_ = entityTag - return c -} - // Context sets the context to be used in this call's Do method. Any // pending HTTP request will be aborted if the provided context is // canceled. -func (c *ProjectsLocationsDataStoresOperationsListCall) Context(ctx context.Context) *ProjectsLocationsDataStoresOperationsListCall { +func (c *ProjectsLocationsDataStoresSiteSearchEngineEnableAdvancedSiteSearchCall) Context(ctx context.Context) *ProjectsLocationsDataStoresSiteSearchEngineEnableAdvancedSiteSearchCall { c.ctx_ = ctx return c } // Header returns an http.Header that can be modified by the caller to // add HTTP headers to the request. -func (c *ProjectsLocationsDataStoresOperationsListCall) Header() http.Header { +func (c *ProjectsLocationsDataStoresSiteSearchEngineEnableAdvancedSiteSearchCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsDataStoresOperationsListCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsDataStoresSiteSearchEngineEnableAdvancedSiteSearchCall) doRequest(alt string) (*http.Response, error) { reqHeaders := make(http.Header) reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) for k, v := range c.header_ { reqHeaders[k] = v } reqHeaders.Set("User-Agent", c.s.userAgent()) - if c.ifNoneMatch_ != "" { - reqHeaders.Set("If-None-Match", c.ifNoneMatch_) - } var body io.Reader = nil + body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddiscoveryenginev1betaenableadvancedsitesearchrequest) + if err != nil { + return nil, err + } + reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}/operations") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+siteSearchEngine}:enableAdvancedSiteSearch") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("GET", urls, body) + req, err := http.NewRequest("POST", urls, body) if err != nil { return nil, err } req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ - "name": c.name, + "siteSearchEngine": c.siteSearchEngine, }) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "discoveryengine.projects.locations.dataStores.operations.list" call. -// Exactly one of *GoogleLongrunningListOperationsResponse or error will -// be non-nil. Any non-2xx status code is an error. Response headers are -// in either -// *GoogleLongrunningListOperationsResponse.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 +// Do executes the "discoveryengine.projects.locations.dataStores.siteSearchEngine.enableAdvancedSiteSearch" call. +// Exactly one of *GoogleLongrunningOperation or error will be non-nil. +// 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 *ProjectsLocationsDataStoresOperationsListCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningListOperationsResponse, error) { +func (c *ProjectsLocationsDataStoresSiteSearchEngineEnableAdvancedSiteSearchCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -20200,7 +28478,7 @@ func (c *ProjectsLocationsDataStoresOperationsListCall) Do(opts ...googleapi.Cal if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &GoogleLongrunningListOperationsResponse{ + ret := &GoogleLongrunningOperation{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -20212,41 +28490,28 @@ func (c *ProjectsLocationsDataStoresOperationsListCall) Do(opts ...googleapi.Cal } return ret, nil // { - // "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`.", - // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/operations", - // "httpMethod": "GET", - // "id": "discoveryengine.projects.locations.dataStores.operations.list", + // "description": "Upgrade from basic site search to advanced site search.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/siteSearchEngine:enableAdvancedSiteSearch", + // "httpMethod": "POST", + // "id": "discoveryengine.projects.locations.dataStores.siteSearchEngine.enableAdvancedSiteSearch", // "parameterOrder": [ - // "name" + // "siteSearchEngine" // ], // "parameters": { - // "filter": { - // "description": "The standard list filter.", - // "location": "query", - // "type": "string" - // }, - // "name": { - // "description": "The name of the operation's parent resource.", + // "siteSearchEngine": { + // "description": "Required. Full resource name of the SiteSearchEngine, such as `projects/{project}/locations/{location}/dataStores/{data_store_id}/siteSearchEngine`.", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/dataStores/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/dataStores/[^/]+/siteSearchEngine$", // "required": true, // "type": "string" - // }, - // "pageSize": { - // "description": "The standard list page size.", - // "format": "int32", - // "location": "query", - // "type": "integer" - // }, - // "pageToken": { - // "description": "The standard list page token.", - // "location": "query", - // "type": "string" // } // }, - // "path": "v1beta/{+name}/operations", + // "path": "v1beta/{+siteSearchEngine}:enableAdvancedSiteSearch", + // "request": { + // "$ref": "GoogleCloudDiscoveryengineV1betaEnableAdvancedSiteSearchRequest" + // }, // "response": { - // "$ref": "GoogleLongrunningListOperationsResponse" + // "$ref": "GoogleLongrunningOperation" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -20255,64 +28520,34 @@ func (c *ProjectsLocationsDataStoresOperationsListCall) Do(opts ...googleapi.Cal } -// 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 *ProjectsLocationsDataStoresOperationsListCall) Pages(ctx context.Context, f func(*GoogleLongrunningListOperationsResponse) error) error { - c.ctx_ = ctx - defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point - 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) - } -} - -// method id "discoveryengine.projects.locations.dataStores.schemas.create": +// method id "discoveryengine.projects.locations.dataStores.siteSearchEngine.recrawlUris": -type ProjectsLocationsDataStoresSchemasCreateCall struct { - s *Service - parent string - googleclouddiscoveryenginev1betaschema *GoogleCloudDiscoveryengineV1betaSchema - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +type ProjectsLocationsDataStoresSiteSearchEngineRecrawlUrisCall struct { + s *Service + siteSearchEngine string + googleclouddiscoveryenginev1betarecrawlurisrequest *GoogleCloudDiscoveryengineV1betaRecrawlUrisRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// Create: Creates a Schema. +// RecrawlUris: Request on-demand recrawl for a list of URIs. // -// - parent: The parent data store resource name, in the format of -// `projects/{project}/locations/{location}/collections/{collection}/da -// taStores/{data_store}`. -func (r *ProjectsLocationsDataStoresSchemasService) Create(parent string, googleclouddiscoveryenginev1betaschema *GoogleCloudDiscoveryengineV1betaSchema) *ProjectsLocationsDataStoresSchemasCreateCall { - c := &ProjectsLocationsDataStoresSchemasCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.parent = parent - c.googleclouddiscoveryenginev1betaschema = googleclouddiscoveryenginev1betaschema - return c -} - -// SchemaId sets the optional parameter "schemaId": Required. The ID to -// use for the Schema, which will become the final component of the -// Schema.name. This field should conform to RFC-1034 -// (https://tools.ietf.org/html/rfc1034) standard with a length limit of -// 63 characters. -func (c *ProjectsLocationsDataStoresSchemasCreateCall) SchemaId(schemaId string) *ProjectsLocationsDataStoresSchemasCreateCall { - c.urlParams_.Set("schemaId", schemaId) +// - siteSearchEngine: Full resource name of the SiteSearchEngine, such +// as +// `projects/*/locations/*/collections/*/dataStores/*/siteSearchEngine` +// . +func (r *ProjectsLocationsDataStoresSiteSearchEngineService) RecrawlUris(siteSearchEngine string, googleclouddiscoveryenginev1betarecrawlurisrequest *GoogleCloudDiscoveryengineV1betaRecrawlUrisRequest) *ProjectsLocationsDataStoresSiteSearchEngineRecrawlUrisCall { + c := &ProjectsLocationsDataStoresSiteSearchEngineRecrawlUrisCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.siteSearchEngine = siteSearchEngine + c.googleclouddiscoveryenginev1betarecrawlurisrequest = googleclouddiscoveryenginev1betarecrawlurisrequest return c } // Fields allows partial responses to be retrieved. See // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse // for more information. -func (c *ProjectsLocationsDataStoresSchemasCreateCall) Fields(s ...googleapi.Field) *ProjectsLocationsDataStoresSchemasCreateCall { +func (c *ProjectsLocationsDataStoresSiteSearchEngineRecrawlUrisCall) Fields(s ...googleapi.Field) *ProjectsLocationsDataStoresSiteSearchEngineRecrawlUrisCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } @@ -20320,21 +28555,21 @@ func (c *ProjectsLocationsDataStoresSchemasCreateCall) Fields(s ...googleapi.Fie // Context sets the context to be used in this call's Do method. Any // pending HTTP request will be aborted if the provided context is // canceled. -func (c *ProjectsLocationsDataStoresSchemasCreateCall) Context(ctx context.Context) *ProjectsLocationsDataStoresSchemasCreateCall { +func (c *ProjectsLocationsDataStoresSiteSearchEngineRecrawlUrisCall) Context(ctx context.Context) *ProjectsLocationsDataStoresSiteSearchEngineRecrawlUrisCall { c.ctx_ = ctx return c } // Header returns an http.Header that can be modified by the caller to // add HTTP headers to the request. -func (c *ProjectsLocationsDataStoresSchemasCreateCall) Header() http.Header { +func (c *ProjectsLocationsDataStoresSiteSearchEngineRecrawlUrisCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsDataStoresSchemasCreateCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsDataStoresSiteSearchEngineRecrawlUrisCall) doRequest(alt string) (*http.Response, error) { reqHeaders := make(http.Header) reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) for k, v := range c.header_ { @@ -20342,14 +28577,14 @@ func (c *ProjectsLocationsDataStoresSchemasCreateCall) doRequest(alt string) (*h } reqHeaders.Set("User-Agent", c.s.userAgent()) var body io.Reader = nil - body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddiscoveryenginev1betaschema) + body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddiscoveryenginev1betarecrawlurisrequest) if err != nil { return nil, err } reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+parent}/schemas") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+siteSearchEngine}:recrawlUris") urls += "?" + c.urlParams_.Encode() req, err := http.NewRequest("POST", urls, body) if err != nil { @@ -20357,19 +28592,19 @@ func (c *ProjectsLocationsDataStoresSchemasCreateCall) doRequest(alt string) (*h } req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ - "parent": c.parent, + "siteSearchEngine": c.siteSearchEngine, }) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "discoveryengine.projects.locations.dataStores.schemas.create" call. +// Do executes the "discoveryengine.projects.locations.dataStores.siteSearchEngine.recrawlUris" call. // Exactly one of *GoogleLongrunningOperation or error will be non-nil. // 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 *ProjectsLocationsDataStoresSchemasCreateCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { +func (c *ProjectsLocationsDataStoresSiteSearchEngineRecrawlUrisCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -20400,30 +28635,25 @@ func (c *ProjectsLocationsDataStoresSchemasCreateCall) Do(opts ...googleapi.Call } return ret, nil // { - // "description": "Creates a Schema.", - // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/schemas", + // "description": "Request on-demand recrawl for a list of URIs.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/siteSearchEngine:recrawlUris", // "httpMethod": "POST", - // "id": "discoveryengine.projects.locations.dataStores.schemas.create", + // "id": "discoveryengine.projects.locations.dataStores.siteSearchEngine.recrawlUris", // "parameterOrder": [ - // "parent" + // "siteSearchEngine" // ], // "parameters": { - // "parent": { - // "description": "Required. The parent data store resource name, in the format of `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}`.", + // "siteSearchEngine": { + // "description": "Required. Full resource name of the SiteSearchEngine, such as `projects/*/locations/*/collections/*/dataStores/*/siteSearchEngine`.", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/dataStores/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/dataStores/[^/]+/siteSearchEngine$", // "required": true, // "type": "string" - // }, - // "schemaId": { - // "description": "Required. The ID to use for the Schema, which will become the final component of the Schema.name. This field should conform to [RFC-1034](https://tools.ietf.org/html/rfc1034) standard with a length limit of 63 characters.", - // "location": "query", - // "type": "string" // } // }, - // "path": "v1beta/{+parent}/schemas", + // "path": "v1beta/{+siteSearchEngine}:recrawlUris", // "request": { - // "$ref": "GoogleCloudDiscoveryengineV1betaSchema" + // "$ref": "GoogleCloudDiscoveryengineV1betaRecrawlUrisRequest" // }, // "response": { // "$ref": "GoogleLongrunningOperation" @@ -20435,31 +28665,36 @@ func (c *ProjectsLocationsDataStoresSchemasCreateCall) Do(opts ...googleapi.Call } -// method id "discoveryengine.projects.locations.dataStores.schemas.delete": +// method id "discoveryengine.projects.locations.dataStores.siteSearchEngine.targetSites.batchCreate": -type ProjectsLocationsDataStoresSchemasDeleteCall struct { - s *Service - name string - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +type ProjectsLocationsDataStoresSiteSearchEngineTargetSitesBatchCreateCall struct { + s *Service + parent string + googleclouddiscoveryenginev1betabatchcreatetargetsitesrequest *GoogleCloudDiscoveryengineV1betaBatchCreateTargetSitesRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// Delete: Deletes a Schema. +// BatchCreate: Creates TargetSite in a batch. // -// - name: The full resource name of the schema, in the format of +// - parent: The parent resource shared by all TargetSites being +// created. // `projects/{project}/locations/{location}/collections/{collection}/da -// taStores/{data_store}/schemas/{schema}`. -func (r *ProjectsLocationsDataStoresSchemasService) Delete(name string) *ProjectsLocationsDataStoresSchemasDeleteCall { - c := &ProjectsLocationsDataStoresSchemasDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.name = name +// taStores/{data_store}/siteSearchEngine`. The parent field in the +// CreateBookRequest messages must either be empty or match this +// field. +func (r *ProjectsLocationsDataStoresSiteSearchEngineTargetSitesService) BatchCreate(parent string, googleclouddiscoveryenginev1betabatchcreatetargetsitesrequest *GoogleCloudDiscoveryengineV1betaBatchCreateTargetSitesRequest) *ProjectsLocationsDataStoresSiteSearchEngineTargetSitesBatchCreateCall { + c := &ProjectsLocationsDataStoresSiteSearchEngineTargetSitesBatchCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + c.googleclouddiscoveryenginev1betabatchcreatetargetsitesrequest = googleclouddiscoveryenginev1betabatchcreatetargetsitesrequest return c } // Fields allows partial responses to be retrieved. See // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse // for more information. -func (c *ProjectsLocationsDataStoresSchemasDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsDataStoresSchemasDeleteCall { +func (c *ProjectsLocationsDataStoresSiteSearchEngineTargetSitesBatchCreateCall) Fields(s ...googleapi.Field) *ProjectsLocationsDataStoresSiteSearchEngineTargetSitesBatchCreateCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } @@ -20467,21 +28702,21 @@ func (c *ProjectsLocationsDataStoresSchemasDeleteCall) Fields(s ...googleapi.Fie // Context sets the context to be used in this call's Do method. Any // pending HTTP request will be aborted if the provided context is // canceled. -func (c *ProjectsLocationsDataStoresSchemasDeleteCall) Context(ctx context.Context) *ProjectsLocationsDataStoresSchemasDeleteCall { +func (c *ProjectsLocationsDataStoresSiteSearchEngineTargetSitesBatchCreateCall) Context(ctx context.Context) *ProjectsLocationsDataStoresSiteSearchEngineTargetSitesBatchCreateCall { c.ctx_ = ctx return c } // Header returns an http.Header that can be modified by the caller to // add HTTP headers to the request. -func (c *ProjectsLocationsDataStoresSchemasDeleteCall) Header() http.Header { +func (c *ProjectsLocationsDataStoresSiteSearchEngineTargetSitesBatchCreateCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsDataStoresSchemasDeleteCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsDataStoresSiteSearchEngineTargetSitesBatchCreateCall) doRequest(alt string) (*http.Response, error) { reqHeaders := make(http.Header) reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) for k, v := range c.header_ { @@ -20489,29 +28724,34 @@ func (c *ProjectsLocationsDataStoresSchemasDeleteCall) doRequest(alt string) (*h } reqHeaders.Set("User-Agent", c.s.userAgent()) var body io.Reader = nil + body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddiscoveryenginev1betabatchcreatetargetsitesrequest) + if err != nil { + return nil, err + } + reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+parent}/targetSites:batchCreate") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("DELETE", urls, body) + req, err := http.NewRequest("POST", urls, body) if err != nil { return nil, err } req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ - "name": c.name, + "parent": c.parent, }) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "discoveryengine.projects.locations.dataStores.schemas.delete" call. +// Do executes the "discoveryengine.projects.locations.dataStores.siteSearchEngine.targetSites.batchCreate" call. // Exactly one of *GoogleLongrunningOperation or error will be non-nil. // 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 *ProjectsLocationsDataStoresSchemasDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { +func (c *ProjectsLocationsDataStoresSiteSearchEngineTargetSitesBatchCreateCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -20542,23 +28782,26 @@ func (c *ProjectsLocationsDataStoresSchemasDeleteCall) Do(opts ...googleapi.Call } return ret, nil // { - // "description": "Deletes a Schema.", - // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/schemas/{schemasId}", - // "httpMethod": "DELETE", - // "id": "discoveryengine.projects.locations.dataStores.schemas.delete", + // "description": "Creates TargetSite in a batch.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/siteSearchEngine/targetSites:batchCreate", + // "httpMethod": "POST", + // "id": "discoveryengine.projects.locations.dataStores.siteSearchEngine.targetSites.batchCreate", // "parameterOrder": [ - // "name" + // "parent" // ], // "parameters": { - // "name": { - // "description": "Required. The full resource name of the schema, in the format of `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/schemas/{schema}`.", + // "parent": { + // "description": "Required. The parent resource shared by all TargetSites being created. `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/siteSearchEngine`. The parent field in the CreateBookRequest messages must either be empty or match this field.", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/dataStores/[^/]+/schemas/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/dataStores/[^/]+/siteSearchEngine$", // "required": true, // "type": "string" // } // }, - // "path": "v1beta/{+name}", + // "path": "v1beta/{+parent}/targetSites:batchCreate", + // "request": { + // "$ref": "GoogleCloudDiscoveryengineV1betaBatchCreateTargetSitesRequest" + // }, // "response": { // "$ref": "GoogleLongrunningOperation" // }, @@ -20569,98 +28812,90 @@ func (c *ProjectsLocationsDataStoresSchemasDeleteCall) Do(opts ...googleapi.Call } -// method id "discoveryengine.projects.locations.dataStores.schemas.get": +// method id "discoveryengine.projects.locations.dataStores.siteSearchEngine.targetSites.create": -type ProjectsLocationsDataStoresSchemasGetCall struct { - s *Service - name string - urlParams_ gensupport.URLParams - ifNoneMatch_ string - ctx_ context.Context - header_ http.Header +type ProjectsLocationsDataStoresSiteSearchEngineTargetSitesCreateCall struct { + s *Service + parent string + googleclouddiscoveryenginev1betatargetsite *GoogleCloudDiscoveryengineV1betaTargetSite + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// Get: Gets a Schema. +// Create: Creates a TargetSite. // -// - name: The full resource name of the schema, in the format of +// - parent: Parent resource name of TargetSite, such as // `projects/{project}/locations/{location}/collections/{collection}/da -// taStores/{data_store}/schemas/{schema}`. -func (r *ProjectsLocationsDataStoresSchemasService) Get(name string) *ProjectsLocationsDataStoresSchemasGetCall { - c := &ProjectsLocationsDataStoresSchemasGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.name = name +// taStores/{data_store}/siteSearchEngine`. +func (r *ProjectsLocationsDataStoresSiteSearchEngineTargetSitesService) Create(parent string, googleclouddiscoveryenginev1betatargetsite *GoogleCloudDiscoveryengineV1betaTargetSite) *ProjectsLocationsDataStoresSiteSearchEngineTargetSitesCreateCall { + c := &ProjectsLocationsDataStoresSiteSearchEngineTargetSitesCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + c.googleclouddiscoveryenginev1betatargetsite = googleclouddiscoveryenginev1betatargetsite return c } // Fields allows partial responses to be retrieved. See // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse // for more information. -func (c *ProjectsLocationsDataStoresSchemasGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsDataStoresSchemasGetCall { +func (c *ProjectsLocationsDataStoresSiteSearchEngineTargetSitesCreateCall) Fields(s ...googleapi.Field) *ProjectsLocationsDataStoresSiteSearchEngineTargetSitesCreateCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// IfNoneMatch sets the 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. Use googleapi.IsNotModified to check whether the response -// error from Do is the result of In-None-Match. -func (c *ProjectsLocationsDataStoresSchemasGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsDataStoresSchemasGetCall { - c.ifNoneMatch_ = entityTag - return c -} - // Context sets the context to be used in this call's Do method. Any // pending HTTP request will be aborted if the provided context is // canceled. -func (c *ProjectsLocationsDataStoresSchemasGetCall) Context(ctx context.Context) *ProjectsLocationsDataStoresSchemasGetCall { +func (c *ProjectsLocationsDataStoresSiteSearchEngineTargetSitesCreateCall) Context(ctx context.Context) *ProjectsLocationsDataStoresSiteSearchEngineTargetSitesCreateCall { c.ctx_ = ctx return c } // Header returns an http.Header that can be modified by the caller to // add HTTP headers to the request. -func (c *ProjectsLocationsDataStoresSchemasGetCall) Header() http.Header { +func (c *ProjectsLocationsDataStoresSiteSearchEngineTargetSitesCreateCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsDataStoresSchemasGetCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsDataStoresSiteSearchEngineTargetSitesCreateCall) doRequest(alt string) (*http.Response, error) { reqHeaders := make(http.Header) reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) for k, v := range c.header_ { reqHeaders[k] = v } reqHeaders.Set("User-Agent", c.s.userAgent()) - if c.ifNoneMatch_ != "" { - reqHeaders.Set("If-None-Match", c.ifNoneMatch_) - } var body io.Reader = nil + body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddiscoveryenginev1betatargetsite) + if err != nil { + return nil, err + } + reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+parent}/targetSites") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("GET", urls, body) + req, err := http.NewRequest("POST", urls, body) if err != nil { return nil, err } req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ - "name": c.name, + "parent": c.parent, }) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "discoveryengine.projects.locations.dataStores.schemas.get" call. -// Exactly one of *GoogleCloudDiscoveryengineV1betaSchema or error will -// be non-nil. Any non-2xx status code is an error. Response headers are -// in either -// *GoogleCloudDiscoveryengineV1betaSchema.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 +// Do executes the "discoveryengine.projects.locations.dataStores.siteSearchEngine.targetSites.create" call. +// Exactly one of *GoogleLongrunningOperation or error will be non-nil. +// 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 *ProjectsLocationsDataStoresSchemasGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1betaSchema, error) { +func (c *ProjectsLocationsDataStoresSiteSearchEngineTargetSitesCreateCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -20679,7 +28914,7 @@ func (c *ProjectsLocationsDataStoresSchemasGetCall) Do(opts ...googleapi.CallOpt if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &GoogleCloudDiscoveryengineV1betaSchema{ + ret := &GoogleLongrunningOperation{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -20691,25 +28926,28 @@ func (c *ProjectsLocationsDataStoresSchemasGetCall) Do(opts ...googleapi.CallOpt } return ret, nil // { - // "description": "Gets a Schema.", - // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/schemas/{schemasId}", - // "httpMethod": "GET", - // "id": "discoveryengine.projects.locations.dataStores.schemas.get", + // "description": "Creates a TargetSite.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/siteSearchEngine/targetSites", + // "httpMethod": "POST", + // "id": "discoveryengine.projects.locations.dataStores.siteSearchEngine.targetSites.create", // "parameterOrder": [ - // "name" + // "parent" // ], // "parameters": { - // "name": { - // "description": "Required. The full resource name of the schema, in the format of `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/schemas/{schema}`.", + // "parent": { + // "description": "Required. Parent resource name of TargetSite, such as `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/siteSearchEngine`.", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/dataStores/[^/]+/schemas/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/dataStores/[^/]+/siteSearchEngine$", // "required": true, // "type": "string" // } // }, - // "path": "v1beta/{+name}", + // "path": "v1beta/{+parent}/targetSites", + // "request": { + // "$ref": "GoogleCloudDiscoveryengineV1betaTargetSite" + // }, // "response": { - // "$ref": "GoogleCloudDiscoveryengineV1betaSchema" + // "$ref": "GoogleLongrunningOperation" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -20718,118 +28956,87 @@ func (c *ProjectsLocationsDataStoresSchemasGetCall) Do(opts ...googleapi.CallOpt } -// method id "discoveryengine.projects.locations.dataStores.schemas.list": +// method id "discoveryengine.projects.locations.dataStores.siteSearchEngine.targetSites.delete": -type ProjectsLocationsDataStoresSchemasListCall struct { - s *Service - parent string - urlParams_ gensupport.URLParams - ifNoneMatch_ string - ctx_ context.Context - header_ http.Header +type ProjectsLocationsDataStoresSiteSearchEngineTargetSitesDeleteCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// List: Gets a list of Schemas. +// Delete: Deletes a TargetSite. // -// - parent: The parent data store resource name, in the format of +// - name: Full resource name of TargetSite, such as // `projects/{project}/locations/{location}/collections/{collection}/da -// taStores/{data_store}`. -func (r *ProjectsLocationsDataStoresSchemasService) List(parent string) *ProjectsLocationsDataStoresSchemasListCall { - c := &ProjectsLocationsDataStoresSchemasListCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.parent = parent - return c -} - -// PageSize sets the optional parameter "pageSize": The maximum number -// of Schemas to return. The service may return fewer than this value. -// If unspecified, at most 100 Schemas will be returned. The maximum -// value is 1000; values above 1000 will be coerced to 1000. -func (c *ProjectsLocationsDataStoresSchemasListCall) PageSize(pageSize int64) *ProjectsLocationsDataStoresSchemasListCall { - c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) - return c -} - -// PageToken sets the optional parameter "pageToken": A page token, -// received from a previous SchemaService.ListSchemas call. Provide this -// to retrieve the subsequent page. When paginating, all other -// parameters provided to SchemaService.ListSchemas must match the call -// that provided the page token. -func (c *ProjectsLocationsDataStoresSchemasListCall) PageToken(pageToken string) *ProjectsLocationsDataStoresSchemasListCall { - c.urlParams_.Set("pageToken", pageToken) +// taStores/{data_store}/siteSearchEngine/targetSites/{target_site}`. +// If the caller does not have permission to access the TargetSite, +// regardless of whether or not it exists, a PERMISSION_DENIED error +// is returned. If the requested TargetSite does not exist, a +// NOT_FOUND error is returned. +func (r *ProjectsLocationsDataStoresSiteSearchEngineTargetSitesService) Delete(name string) *ProjectsLocationsDataStoresSiteSearchEngineTargetSitesDeleteCall { + c := &ProjectsLocationsDataStoresSiteSearchEngineTargetSitesDeleteCall{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 information. -func (c *ProjectsLocationsDataStoresSchemasListCall) Fields(s ...googleapi.Field) *ProjectsLocationsDataStoresSchemasListCall { +func (c *ProjectsLocationsDataStoresSiteSearchEngineTargetSitesDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsDataStoresSiteSearchEngineTargetSitesDeleteCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// IfNoneMatch sets the 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. Use googleapi.IsNotModified to check whether the response -// error from Do is the result of In-None-Match. -func (c *ProjectsLocationsDataStoresSchemasListCall) IfNoneMatch(entityTag string) *ProjectsLocationsDataStoresSchemasListCall { - c.ifNoneMatch_ = entityTag - return c -} - // Context sets the context to be used in this call's Do method. Any // pending HTTP request will be aborted if the provided context is // canceled. -func (c *ProjectsLocationsDataStoresSchemasListCall) Context(ctx context.Context) *ProjectsLocationsDataStoresSchemasListCall { +func (c *ProjectsLocationsDataStoresSiteSearchEngineTargetSitesDeleteCall) Context(ctx context.Context) *ProjectsLocationsDataStoresSiteSearchEngineTargetSitesDeleteCall { c.ctx_ = ctx return c } // Header returns an http.Header that can be modified by the caller to // add HTTP headers to the request. -func (c *ProjectsLocationsDataStoresSchemasListCall) Header() http.Header { +func (c *ProjectsLocationsDataStoresSiteSearchEngineTargetSitesDeleteCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsDataStoresSchemasListCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsDataStoresSiteSearchEngineTargetSitesDeleteCall) doRequest(alt string) (*http.Response, error) { reqHeaders := make(http.Header) reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) for k, v := range c.header_ { reqHeaders[k] = v } reqHeaders.Set("User-Agent", c.s.userAgent()) - if c.ifNoneMatch_ != "" { - reqHeaders.Set("If-None-Match", c.ifNoneMatch_) - } var body io.Reader = nil c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+parent}/schemas") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("GET", urls, body) + req, err := http.NewRequest("DELETE", urls, body) if err != nil { return nil, err } req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ - "parent": c.parent, + "name": c.name, }) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "discoveryengine.projects.locations.dataStores.schemas.list" call. -// Exactly one of *GoogleCloudDiscoveryengineV1betaListSchemasResponse -// or error will be non-nil. Any non-2xx status code is an error. -// Response headers are in either -// *GoogleCloudDiscoveryengineV1betaListSchemasResponse.ServerResponse.He -// ader 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 *ProjectsLocationsDataStoresSchemasListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1betaListSchemasResponse, error) { +// Do executes the "discoveryengine.projects.locations.dataStores.siteSearchEngine.targetSites.delete" call. +// Exactly one of *GoogleLongrunningOperation or error will be non-nil. +// 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 *ProjectsLocationsDataStoresSiteSearchEngineTargetSitesDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -20848,7 +29055,7 @@ func (c *ProjectsLocationsDataStoresSchemasListCall) Do(opts ...googleapi.CallOp if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &GoogleCloudDiscoveryengineV1betaListSchemasResponse{ + ret := &GoogleLongrunningOperation{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -20860,36 +29067,25 @@ func (c *ProjectsLocationsDataStoresSchemasListCall) Do(opts ...googleapi.CallOp } return ret, nil // { - // "description": "Gets a list of Schemas.", - // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/schemas", - // "httpMethod": "GET", - // "id": "discoveryengine.projects.locations.dataStores.schemas.list", + // "description": "Deletes a TargetSite.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/siteSearchEngine/targetSites/{targetSitesId}", + // "httpMethod": "DELETE", + // "id": "discoveryengine.projects.locations.dataStores.siteSearchEngine.targetSites.delete", // "parameterOrder": [ - // "parent" + // "name" // ], // "parameters": { - // "pageSize": { - // "description": "The maximum number of Schemas to return. The service may return fewer than this value. If unspecified, at most 100 Schemas will be returned. The maximum value is 1000; values above 1000 will be coerced to 1000.", - // "format": "int32", - // "location": "query", - // "type": "integer" - // }, - // "pageToken": { - // "description": "A page token, received from a previous SchemaService.ListSchemas call. Provide this to retrieve the subsequent page. When paginating, all other parameters provided to SchemaService.ListSchemas must match the call that provided the page token.", - // "location": "query", - // "type": "string" - // }, - // "parent": { - // "description": "Required. The parent data store resource name, in the format of `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}`.", + // "name": { + // "description": "Required. Full resource name of TargetSite, such as `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/siteSearchEngine/targetSites/{target_site}`. If the caller does not have permission to access the TargetSite, regardless of whether or not it exists, a PERMISSION_DENIED error is returned. If the requested TargetSite does not exist, a NOT_FOUND error is returned.", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/dataStores/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/dataStores/[^/]+/siteSearchEngine/targetSites/[^/]+$", // "required": true, // "type": "string" // } // }, - // "path": "v1beta/{+parent}/schemas", + // "path": "v1beta/{+name}", // "response": { - // "$ref": "GoogleCloudDiscoveryengineV1betaListSchemasResponse" + // "$ref": "GoogleLongrunningOperation" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -20898,103 +29094,83 @@ func (c *ProjectsLocationsDataStoresSchemasListCall) Do(opts ...googleapi.CallOp } -// 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 *ProjectsLocationsDataStoresSchemasListCall) Pages(ctx context.Context, f func(*GoogleCloudDiscoveryengineV1betaListSchemasResponse) error) error { - c.ctx_ = ctx - defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point - 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) - } -} - -// method id "discoveryengine.projects.locations.dataStores.schemas.patch": +// method id "discoveryengine.projects.locations.dataStores.siteSearchEngine.targetSites.get": -type ProjectsLocationsDataStoresSchemasPatchCall struct { - s *Service - name string - googleclouddiscoveryenginev1betaschema *GoogleCloudDiscoveryengineV1betaSchema - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +type ProjectsLocationsDataStoresSiteSearchEngineTargetSitesGetCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header } -// Patch: Updates a Schema. +// Get: Gets a TargetSite. // -// - name: Immutable. The full resource name of the schema, in the -// format of +// - name: Full resource name of TargetSite, such as // `projects/{project}/locations/{location}/collections/{collection}/da -// taStores/{data_store}/schemas/{schema}`. This field must be a UTF-8 -// encoded string with a length limit of 1024 characters. -func (r *ProjectsLocationsDataStoresSchemasService) Patch(name string, googleclouddiscoveryenginev1betaschema *GoogleCloudDiscoveryengineV1betaSchema) *ProjectsLocationsDataStoresSchemasPatchCall { - c := &ProjectsLocationsDataStoresSchemasPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// taStores/{data_store}/siteSearchEngine/targetSites/{target_site}`. +// If the caller does not have permission to access the TargetSite, +// regardless of whether or not it exists, a PERMISSION_DENIED error +// is returned. If the requested TargetSite does not exist, a +// NOT_FOUND error is returned. +func (r *ProjectsLocationsDataStoresSiteSearchEngineTargetSitesService) Get(name string) *ProjectsLocationsDataStoresSiteSearchEngineTargetSitesGetCall { + c := &ProjectsLocationsDataStoresSiteSearchEngineTargetSitesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.name = name - c.googleclouddiscoveryenginev1betaschema = googleclouddiscoveryenginev1betaschema - return c -} - -// AllowMissing sets the optional parameter "allowMissing": If set to -// true, and the Schema is not found, a new Schema will be created. In -// this situation, `update_mask` is ignored. -func (c *ProjectsLocationsDataStoresSchemasPatchCall) AllowMissing(allowMissing bool) *ProjectsLocationsDataStoresSchemasPatchCall { - c.urlParams_.Set("allowMissing", fmt.Sprint(allowMissing)) return c } // Fields allows partial responses to be retrieved. See // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse // for more information. -func (c *ProjectsLocationsDataStoresSchemasPatchCall) Fields(s ...googleapi.Field) *ProjectsLocationsDataStoresSchemasPatchCall { +func (c *ProjectsLocationsDataStoresSiteSearchEngineTargetSitesGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsDataStoresSiteSearchEngineTargetSitesGetCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } +// IfNoneMatch sets the 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. Use googleapi.IsNotModified to check whether the response +// error from Do is the result of In-None-Match. +func (c *ProjectsLocationsDataStoresSiteSearchEngineTargetSitesGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsDataStoresSiteSearchEngineTargetSitesGetCall { + c.ifNoneMatch_ = entityTag + return c +} + // Context sets the context to be used in this call's Do method. Any // pending HTTP request will be aborted if the provided context is // canceled. -func (c *ProjectsLocationsDataStoresSchemasPatchCall) Context(ctx context.Context) *ProjectsLocationsDataStoresSchemasPatchCall { +func (c *ProjectsLocationsDataStoresSiteSearchEngineTargetSitesGetCall) Context(ctx context.Context) *ProjectsLocationsDataStoresSiteSearchEngineTargetSitesGetCall { c.ctx_ = ctx return c } // Header returns an http.Header that can be modified by the caller to // add HTTP headers to the request. -func (c *ProjectsLocationsDataStoresSchemasPatchCall) Header() http.Header { +func (c *ProjectsLocationsDataStoresSiteSearchEngineTargetSitesGetCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsDataStoresSchemasPatchCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsDataStoresSiteSearchEngineTargetSitesGetCall) doRequest(alt string) (*http.Response, error) { reqHeaders := make(http.Header) reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) for k, v := range c.header_ { reqHeaders[k] = v } reqHeaders.Set("User-Agent", c.s.userAgent()) - var body io.Reader = nil - body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddiscoveryenginev1betaschema) - if err != nil { - return nil, err + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) } - reqHeaders.Set("Content-Type", "application/json") + var body io.Reader = nil 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) + req, err := http.NewRequest("GET", urls, body) if err != nil { return nil, err } @@ -21005,14 +29181,16 @@ func (c *ProjectsLocationsDataStoresSchemasPatchCall) doRequest(alt string) (*ht return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "discoveryengine.projects.locations.dataStores.schemas.patch" call. -// Exactly one of *GoogleLongrunningOperation or error will be non-nil. -// 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 *ProjectsLocationsDataStoresSchemasPatchCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { +// Do executes the "discoveryengine.projects.locations.dataStores.siteSearchEngine.targetSites.get" call. +// Exactly one of *GoogleCloudDiscoveryengineV1betaTargetSite or error +// will be non-nil. Any non-2xx status code is an error. Response +// headers are in either +// *GoogleCloudDiscoveryengineV1betaTargetSite.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 *ProjectsLocationsDataStoresSiteSearchEngineTargetSitesGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1betaTargetSite, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -21031,7 +29209,7 @@ func (c *ProjectsLocationsDataStoresSchemasPatchCall) Do(opts ...googleapi.CallO if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &GoogleLongrunningOperation{ + ret := &GoogleCloudDiscoveryengineV1betaTargetSite{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -21043,33 +29221,25 @@ func (c *ProjectsLocationsDataStoresSchemasPatchCall) Do(opts ...googleapi.CallO } return ret, nil // { - // "description": "Updates a Schema.", - // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/schemas/{schemasId}", - // "httpMethod": "PATCH", - // "id": "discoveryengine.projects.locations.dataStores.schemas.patch", + // "description": "Gets a TargetSite.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/siteSearchEngine/targetSites/{targetSitesId}", + // "httpMethod": "GET", + // "id": "discoveryengine.projects.locations.dataStores.siteSearchEngine.targetSites.get", // "parameterOrder": [ // "name" // ], // "parameters": { - // "allowMissing": { - // "description": "If set to true, and the Schema is not found, a new Schema will be created. In this situation, `update_mask` is ignored.", - // "location": "query", - // "type": "boolean" - // }, // "name": { - // "description": "Immutable. The full resource name of the schema, in the format of `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/schemas/{schema}`. This field must be a UTF-8 encoded string with a length limit of 1024 characters.", + // "description": "Required. Full resource name of TargetSite, such as `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/siteSearchEngine/targetSites/{target_site}`. If the caller does not have permission to access the TargetSite, regardless of whether or not it exists, a PERMISSION_DENIED error is returned. If the requested TargetSite does not exist, a NOT_FOUND error is returned.", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/dataStores/[^/]+/schemas/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/dataStores/[^/]+/siteSearchEngine/targetSites/[^/]+$", // "required": true, // "type": "string" // } // }, // "path": "v1beta/{+name}", - // "request": { - // "$ref": "GoogleCloudDiscoveryengineV1betaSchema" - // }, // "response": { - // "$ref": "GoogleLongrunningOperation" + // "$ref": "GoogleCloudDiscoveryengineV1betaTargetSite" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -21078,102 +29248,123 @@ func (c *ProjectsLocationsDataStoresSchemasPatchCall) Do(opts ...googleapi.CallO } -// method id "discoveryengine.projects.locations.dataStores.servingConfigs.recommend": +// method id "discoveryengine.projects.locations.dataStores.siteSearchEngine.targetSites.list": -type ProjectsLocationsDataStoresServingConfigsRecommendCall struct { - s *Service - servingConfig string - googleclouddiscoveryenginev1betarecommendrequest *GoogleCloudDiscoveryengineV1betaRecommendRequest - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +type ProjectsLocationsDataStoresSiteSearchEngineTargetSitesListCall struct { + s *Service + parent string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header } -// Recommend: Makes a recommendation, which requires a contextual user -// event. +// List: Gets a list of TargetSites. // -// - servingConfig: Full resource name of a ServingConfig: -// `projects/*/locations/global/collections/*/engines/*/servingConfigs/ -// *`, or -// `projects/*/locations/global/collections/*/dataStores/*/servingConfi -// gs/*` One default serving config is created along with your -// recommendation engine creation. The engine ID will be used as the -// ID of the default serving config. For example, for Engine -// `projects/*/locations/global/collections/*/engines/my-engine`, you -// can use -// `projects/*/locations/global/collections/*/engines/my-engine/serving -// Configs/my-engine` for your RecommendationService.Recommend -// requests. -func (r *ProjectsLocationsDataStoresServingConfigsService) Recommend(servingConfig string, googleclouddiscoveryenginev1betarecommendrequest *GoogleCloudDiscoveryengineV1betaRecommendRequest) *ProjectsLocationsDataStoresServingConfigsRecommendCall { - c := &ProjectsLocationsDataStoresServingConfigsRecommendCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.servingConfig = servingConfig - c.googleclouddiscoveryenginev1betarecommendrequest = googleclouddiscoveryenginev1betarecommendrequest +// - parent: The parent site search engine resource name, such as +// `projects/{project}/locations/{location}/collections/{collection}/da +// taStores/{data_store}/siteSearchEngine`. If the caller does not +// have permission to list TargetSites under this site search engine, +// regardless of whether or not this branch exists, a +// PERMISSION_DENIED error is returned. +func (r *ProjectsLocationsDataStoresSiteSearchEngineTargetSitesService) List(parent string) *ProjectsLocationsDataStoresSiteSearchEngineTargetSitesListCall { + c := &ProjectsLocationsDataStoresSiteSearchEngineTargetSitesListCall{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. The maximum value is 1000; values +// above 1000 will be coerced to 1000. If this field is negative, an +// INVALID_ARGUMENT error is returned. +func (c *ProjectsLocationsDataStoresSiteSearchEngineTargetSitesListCall) PageSize(pageSize int64) *ProjectsLocationsDataStoresSiteSearchEngineTargetSitesListCall { + c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) + return c +} + +// PageToken sets the optional parameter "pageToken": A page token, +// received from a previous `ListTargetSites` call. Provide this to +// retrieve the subsequent page. When paginating, all other parameters +// provided to `ListTargetSites` must match the call that provided the +// page token. +func (c *ProjectsLocationsDataStoresSiteSearchEngineTargetSitesListCall) PageToken(pageToken string) *ProjectsLocationsDataStoresSiteSearchEngineTargetSitesListCall { + 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 information. -func (c *ProjectsLocationsDataStoresServingConfigsRecommendCall) Fields(s ...googleapi.Field) *ProjectsLocationsDataStoresServingConfigsRecommendCall { +func (c *ProjectsLocationsDataStoresSiteSearchEngineTargetSitesListCall) Fields(s ...googleapi.Field) *ProjectsLocationsDataStoresSiteSearchEngineTargetSitesListCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } +// IfNoneMatch sets the 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. Use googleapi.IsNotModified to check whether the response +// error from Do is the result of In-None-Match. +func (c *ProjectsLocationsDataStoresSiteSearchEngineTargetSitesListCall) IfNoneMatch(entityTag string) *ProjectsLocationsDataStoresSiteSearchEngineTargetSitesListCall { + c.ifNoneMatch_ = entityTag + return c +} + // Context sets the context to be used in this call's Do method. Any // pending HTTP request will be aborted if the provided context is // canceled. -func (c *ProjectsLocationsDataStoresServingConfigsRecommendCall) Context(ctx context.Context) *ProjectsLocationsDataStoresServingConfigsRecommendCall { +func (c *ProjectsLocationsDataStoresSiteSearchEngineTargetSitesListCall) Context(ctx context.Context) *ProjectsLocationsDataStoresSiteSearchEngineTargetSitesListCall { c.ctx_ = ctx return c } // Header returns an http.Header that can be modified by the caller to // add HTTP headers to the request. -func (c *ProjectsLocationsDataStoresServingConfigsRecommendCall) Header() http.Header { +func (c *ProjectsLocationsDataStoresSiteSearchEngineTargetSitesListCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsDataStoresServingConfigsRecommendCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsDataStoresSiteSearchEngineTargetSitesListCall) doRequest(alt string) (*http.Response, error) { reqHeaders := make(http.Header) reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) for k, v := range c.header_ { reqHeaders[k] = v } reqHeaders.Set("User-Agent", c.s.userAgent()) - var body io.Reader = nil - body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddiscoveryenginev1betarecommendrequest) - if err != nil { - return nil, err + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) } - reqHeaders.Set("Content-Type", "application/json") + var body io.Reader = nil c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+servingConfig}:recommend") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+parent}/targetSites") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("POST", urls, body) + req, err := http.NewRequest("GET", urls, body) if err != nil { return nil, err } req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ - "servingConfig": c.servingConfig, + "parent": c.parent, }) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "discoveryengine.projects.locations.dataStores.servingConfigs.recommend" call. -// Exactly one of *GoogleCloudDiscoveryengineV1betaRecommendResponse or -// error will be non-nil. Any non-2xx status code is an error. Response +// Do executes the "discoveryengine.projects.locations.dataStores.siteSearchEngine.targetSites.list" call. +// Exactly one of +// *GoogleCloudDiscoveryengineV1betaListTargetSitesResponse or error +// will be non-nil. Any non-2xx status code is an error. Response // headers are in either -// *GoogleCloudDiscoveryengineV1betaRecommendResponse.ServerResponse.Head -// er or (if a response was returned at all) in +// *GoogleCloudDiscoveryengineV1betaListTargetSitesResponse.ServerRespons +// e.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 *ProjectsLocationsDataStoresServingConfigsRecommendCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1betaRecommendResponse, error) { +func (c *ProjectsLocationsDataStoresSiteSearchEngineTargetSitesListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1betaListTargetSitesResponse, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -21192,7 +29383,7 @@ func (c *ProjectsLocationsDataStoresServingConfigsRecommendCall) Do(opts ...goog if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &GoogleCloudDiscoveryengineV1betaRecommendResponse{ + ret := &GoogleCloudDiscoveryengineV1betaListTargetSitesResponse{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -21204,28 +29395,36 @@ func (c *ProjectsLocationsDataStoresServingConfigsRecommendCall) Do(opts ...goog } return ret, nil // { - // "description": "Makes a recommendation, which requires a contextual user event.", - // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/servingConfigs/{servingConfigsId}:recommend", - // "httpMethod": "POST", - // "id": "discoveryengine.projects.locations.dataStores.servingConfigs.recommend", + // "description": "Gets a list of TargetSites.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/siteSearchEngine/targetSites", + // "httpMethod": "GET", + // "id": "discoveryengine.projects.locations.dataStores.siteSearchEngine.targetSites.list", // "parameterOrder": [ - // "servingConfig" + // "parent" // ], // "parameters": { - // "servingConfig": { - // "description": "Required. Full resource name of a ServingConfig: `projects/*/locations/global/collections/*/engines/*/servingConfigs/*`, or `projects/*/locations/global/collections/*/dataStores/*/servingConfigs/*` One default serving config is created along with your recommendation engine creation. The engine ID will be used as the ID of the default serving config. For example, for Engine `projects/*/locations/global/collections/*/engines/my-engine`, you can use `projects/*/locations/global/collections/*/engines/my-engine/servingConfigs/my-engine` for your RecommendationService.Recommend requests.", + // "pageSize": { + // "description": "Requested page size. Server may return fewer items than requested. If unspecified, server will pick an appropriate default. The maximum value is 1000; values above 1000 will be coerced to 1000. If this field is negative, an INVALID_ARGUMENT error is returned.", + // "format": "int32", + // "location": "query", + // "type": "integer" + // }, + // "pageToken": { + // "description": "A page token, received from a previous `ListTargetSites` call. Provide this to retrieve the subsequent page. When paginating, all other parameters provided to `ListTargetSites` must match the call that provided the page token.", + // "location": "query", + // "type": "string" + // }, + // "parent": { + // "description": "Required. The parent site search engine resource name, such as `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/siteSearchEngine`. If the caller does not have permission to list TargetSites under this site search engine, regardless of whether or not this branch exists, a PERMISSION_DENIED error is returned.", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/dataStores/[^/]+/servingConfigs/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/dataStores/[^/]+/siteSearchEngine$", // "required": true, // "type": "string" // } // }, - // "path": "v1beta/{+servingConfig}:recommend", - // "request": { - // "$ref": "GoogleCloudDiscoveryengineV1betaRecommendRequest" - // }, + // "path": "v1beta/{+parent}/targetSites", // "response": { - // "$ref": "GoogleCloudDiscoveryengineV1betaRecommendResponse" + // "$ref": "GoogleCloudDiscoveryengineV1betaListTargetSitesResponse" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -21234,38 +29433,56 @@ func (c *ProjectsLocationsDataStoresServingConfigsRecommendCall) Do(opts ...goog } -// method id "discoveryengine.projects.locations.dataStores.servingConfigs.search": +// 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 *ProjectsLocationsDataStoresSiteSearchEngineTargetSitesListCall) Pages(ctx context.Context, f func(*GoogleCloudDiscoveryengineV1betaListTargetSitesResponse) error) error { + c.ctx_ = ctx + defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point + 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 ProjectsLocationsDataStoresServingConfigsSearchCall struct { - s *Service - servingConfig string - googleclouddiscoveryenginev1betasearchrequest *GoogleCloudDiscoveryengineV1betaSearchRequest - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +// method id "discoveryengine.projects.locations.dataStores.siteSearchEngine.targetSites.patch": + +type ProjectsLocationsDataStoresSiteSearchEngineTargetSitesPatchCall struct { + s *Service + name string + googleclouddiscoveryenginev1betatargetsite *GoogleCloudDiscoveryengineV1betaTargetSite + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// Search: Performs a search. +// Patch: Updates a TargetSite. // -// - servingConfig: The resource name of the Search serving config, such -// as -// `projects/*/locations/global/collections/default_collection/engines/ -// */servingConfigs/default_serving_config`, or -// `projects/*/locations/global/collections/default_collection/dataStor -// es/default_data_store/servingConfigs/default_serving_config`. This -// field is used to identify the serving configuration name, set of -// models used to make the search. -func (r *ProjectsLocationsDataStoresServingConfigsService) Search(servingConfig string, googleclouddiscoveryenginev1betasearchrequest *GoogleCloudDiscoveryengineV1betaSearchRequest) *ProjectsLocationsDataStoresServingConfigsSearchCall { - c := &ProjectsLocationsDataStoresServingConfigsSearchCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.servingConfig = servingConfig - c.googleclouddiscoveryenginev1betasearchrequest = googleclouddiscoveryenginev1betasearchrequest +// - name: Output only. The fully qualified resource name of the target +// site. +// `projects/{project}/locations/{location}/collections/{collection}/da +// taStores/{data_store}/siteSearchEngine/targetSites/{target_site}` +// The `target_site_id` is system-generated. +func (r *ProjectsLocationsDataStoresSiteSearchEngineTargetSitesService) Patch(name string, googleclouddiscoveryenginev1betatargetsite *GoogleCloudDiscoveryengineV1betaTargetSite) *ProjectsLocationsDataStoresSiteSearchEngineTargetSitesPatchCall { + c := &ProjectsLocationsDataStoresSiteSearchEngineTargetSitesPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + c.googleclouddiscoveryenginev1betatargetsite = googleclouddiscoveryenginev1betatargetsite return c } // Fields allows partial responses to be retrieved. See // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse // for more information. -func (c *ProjectsLocationsDataStoresServingConfigsSearchCall) Fields(s ...googleapi.Field) *ProjectsLocationsDataStoresServingConfigsSearchCall { +func (c *ProjectsLocationsDataStoresSiteSearchEngineTargetSitesPatchCall) Fields(s ...googleapi.Field) *ProjectsLocationsDataStoresSiteSearchEngineTargetSitesPatchCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } @@ -21273,21 +29490,21 @@ func (c *ProjectsLocationsDataStoresServingConfigsSearchCall) Fields(s ...google // Context sets the context to be used in this call's Do method. Any // pending HTTP request will be aborted if the provided context is // canceled. -func (c *ProjectsLocationsDataStoresServingConfigsSearchCall) Context(ctx context.Context) *ProjectsLocationsDataStoresServingConfigsSearchCall { +func (c *ProjectsLocationsDataStoresSiteSearchEngineTargetSitesPatchCall) Context(ctx context.Context) *ProjectsLocationsDataStoresSiteSearchEngineTargetSitesPatchCall { c.ctx_ = ctx return c } // Header returns an http.Header that can be modified by the caller to // add HTTP headers to the request. -func (c *ProjectsLocationsDataStoresServingConfigsSearchCall) Header() http.Header { +func (c *ProjectsLocationsDataStoresSiteSearchEngineTargetSitesPatchCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsDataStoresServingConfigsSearchCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsDataStoresSiteSearchEngineTargetSitesPatchCall) doRequest(alt string) (*http.Response, error) { reqHeaders := make(http.Header) reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) for k, v := range c.header_ { @@ -21295,36 +29512,34 @@ func (c *ProjectsLocationsDataStoresServingConfigsSearchCall) doRequest(alt stri } reqHeaders.Set("User-Agent", c.s.userAgent()) var body io.Reader = nil - body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddiscoveryenginev1betasearchrequest) + body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddiscoveryenginev1betatargetsite) if err != nil { return nil, err } reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+servingConfig}:search") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}") 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{ - "servingConfig": c.servingConfig, + "name": c.name, }) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "discoveryengine.projects.locations.dataStores.servingConfigs.search" call. -// Exactly one of *GoogleCloudDiscoveryengineV1betaSearchResponse or -// error will be non-nil. Any non-2xx status code is an error. Response -// headers are in either -// *GoogleCloudDiscoveryengineV1betaSearchResponse.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 *ProjectsLocationsDataStoresServingConfigsSearchCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1betaSearchResponse, error) { +// Do executes the "discoveryengine.projects.locations.dataStores.siteSearchEngine.targetSites.patch" call. +// Exactly one of *GoogleLongrunningOperation or error will be non-nil. +// 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 *ProjectsLocationsDataStoresSiteSearchEngineTargetSitesPatchCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -21343,7 +29558,7 @@ func (c *ProjectsLocationsDataStoresServingConfigsSearchCall) Do(opts ...googlea if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &GoogleCloudDiscoveryengineV1betaSearchResponse{ + ret := &GoogleLongrunningOperation{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -21355,28 +29570,28 @@ func (c *ProjectsLocationsDataStoresServingConfigsSearchCall) Do(opts ...googlea } return ret, nil // { - // "description": "Performs a search.", - // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/servingConfigs/{servingConfigsId}:search", - // "httpMethod": "POST", - // "id": "discoveryengine.projects.locations.dataStores.servingConfigs.search", + // "description": "Updates a TargetSite.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/siteSearchEngine/targetSites/{targetSitesId}", + // "httpMethod": "PATCH", + // "id": "discoveryengine.projects.locations.dataStores.siteSearchEngine.targetSites.patch", // "parameterOrder": [ - // "servingConfig" + // "name" // ], // "parameters": { - // "servingConfig": { - // "description": "Required. The resource name of the Search serving config, such as `projects/*/locations/global/collections/default_collection/engines/*/servingConfigs/default_serving_config`, or `projects/*/locations/global/collections/default_collection/dataStores/default_data_store/servingConfigs/default_serving_config`. This field is used to identify the serving configuration name, set of models used to make the search.", + // "name": { + // "description": "Output only. The fully qualified resource name of the target site. `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/siteSearchEngine/targetSites/{target_site}` The `target_site_id` is system-generated.", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/dataStores/[^/]+/servingConfigs/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/dataStores/[^/]+/siteSearchEngine/targetSites/[^/]+$", // "required": true, // "type": "string" // } // }, - // "path": "v1beta/{+servingConfig}:search", + // "path": "v1beta/{+name}", // "request": { - // "$ref": "GoogleCloudDiscoveryengineV1betaSearchRequest" + // "$ref": "GoogleCloudDiscoveryengineV1betaTargetSite" // }, // "response": { - // "$ref": "GoogleCloudDiscoveryengineV1betaSearchResponse" + // "$ref": "GoogleLongrunningOperation" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -21385,27 +29600,6 @@ func (c *ProjectsLocationsDataStoresServingConfigsSearchCall) Do(opts ...googlea } -// 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 *ProjectsLocationsDataStoresServingConfigsSearchCall) Pages(ctx context.Context, f func(*GoogleCloudDiscoveryengineV1betaSearchResponse) error) error { - c.ctx_ = ctx - defer func(pt string) { c.googleclouddiscoveryenginev1betasearchrequest.PageToken = pt }(c.googleclouddiscoveryenginev1betasearchrequest.PageToken) // reset paging to original point - for { - x, err := c.Do() - if err != nil { - return err - } - if err := f(x); err != nil { - return err - } - if x.NextPageToken == "" { - return nil - } - c.googleclouddiscoveryenginev1betasearchrequest.PageToken = x.NextPageToken - } -} - // method id "discoveryengine.projects.locations.dataStores.suggestionDenyListEntries.import": type ProjectsLocationsDataStoresSuggestionDenyListEntriesImportCall struct { diff --git a/documentai/v1/documentai-api.json b/documentai/v1/documentai-api.json index 4fc039e616f..972a237c5c6 100644 --- a/documentai/v1/documentai-api.json +++ b/documentai/v1/documentai-api.json @@ -1042,7 +1042,7 @@ } } }, - "revision": "20240112", + "revision": "20240118", "rootUrl": "https://documentai.googleapis.com/", "schemas": { "GoogleCloudDocumentaiUiv1beta3AutoLabelDocumentsMetadata": { @@ -4370,6 +4370,21 @@ "$ref": "GoogleCloudDocumentaiV1EvaluationReference", "description": "The most recently invoked evaluation for the processor version." }, + "modelType": { + "description": "Output only. The model type of this processor version.", + "enum": [ + "MODEL_TYPE_UNSPECIFIED", + "MODEL_TYPE_GENERATIVE", + "MODEL_TYPE_CUSTOM" + ], + "enumDescriptions": [ + "The processor version has unspecified model type.", + "The processor version has generative model type.", + "The processor version has custom model type." + ], + "readOnly": true, + "type": "string" + }, "name": { "description": "The resource name of the processor version. Format: `projects/{project}/locations/{location}/processors/{processor}/processorVersions/{processor_version}`", "type": "string" diff --git a/documentai/v1/documentai-gen.go b/documentai/v1/documentai-gen.go index 4a7668d92ba..a0708940947 100644 --- a/documentai/v1/documentai-gen.go +++ b/documentai/v1/documentai-gen.go @@ -5915,6 +5915,16 @@ type GoogleCloudDocumentaiV1ProcessorVersion struct { // processor version. LatestEvaluation *GoogleCloudDocumentaiV1EvaluationReference `json:"latestEvaluation,omitempty"` + // ModelType: Output only. The model type of this processor version. + // + // Possible values: + // "MODEL_TYPE_UNSPECIFIED" - The processor version has unspecified + // model type. + // "MODEL_TYPE_GENERATIVE" - The processor version has generative + // model type. + // "MODEL_TYPE_CUSTOM" - The processor version has custom model type. + ModelType string `json:"modelType,omitempty"` + // Name: The resource name of the processor version. Format: // `projects/{project}/locations/{location}/processors/{processor}/proces // sorVersions/{processor_version}` diff --git a/documentai/v1beta3/documentai-api.json b/documentai/v1beta3/documentai-api.json index 5107e05d4cd..f44ed4eb220 100644 --- a/documentai/v1beta3/documentai-api.json +++ b/documentai/v1beta3/documentai-api.json @@ -1284,7 +1284,7 @@ } } }, - "revision": "20240112", + "revision": "20240118", "rootUrl": "https://documentai.googleapis.com/", "schemas": { "GoogleCloudDocumentaiUiv1beta3AutoLabelDocumentsMetadata": { @@ -8394,6 +8394,21 @@ "$ref": "GoogleCloudDocumentaiV1beta3EvaluationReference", "description": "The most recently invoked evaluation for the processor version." }, + "modelType": { + "description": "Output only. The model type of this processor version.", + "enum": [ + "MODEL_TYPE_UNSPECIFIED", + "MODEL_TYPE_GENERATIVE", + "MODEL_TYPE_CUSTOM" + ], + "enumDescriptions": [ + "The processor version has unspecified model type.", + "The processor version has generative model type.", + "The processor version has custom model type." + ], + "readOnly": true, + "type": "string" + }, "name": { "description": "The resource name of the processor version. Format: `projects/{project}/locations/{location}/processors/{processor}/processorVersions/{processor_version}`", "type": "string" diff --git a/documentai/v1beta3/documentai-gen.go b/documentai/v1beta3/documentai-gen.go index 0b96d884701..ce6f2bc8ff2 100644 --- a/documentai/v1beta3/documentai-gen.go +++ b/documentai/v1beta3/documentai-gen.go @@ -12278,6 +12278,16 @@ type GoogleCloudDocumentaiV1beta3ProcessorVersion struct { // processor version. LatestEvaluation *GoogleCloudDocumentaiV1beta3EvaluationReference `json:"latestEvaluation,omitempty"` + // ModelType: Output only. The model type of this processor version. + // + // Possible values: + // "MODEL_TYPE_UNSPECIFIED" - The processor version has unspecified + // model type. + // "MODEL_TYPE_GENERATIVE" - The processor version has generative + // model type. + // "MODEL_TYPE_CUSTOM" - The processor version has custom model type. + ModelType string `json:"modelType,omitempty"` + // Name: The resource name of the processor version. Format: // `projects/{project}/locations/{location}/processors/{processor}/proces // sorVersions/{processor_version}` diff --git a/metastore/v1beta/metastore-api.json b/metastore/v1beta/metastore-api.json index 49fa308168d..eb545bcffa3 100644 --- a/metastore/v1beta/metastore-api.json +++ b/metastore/v1beta/metastore-api.json @@ -1607,7 +1607,7 @@ } } }, - "revision": "20231214", + "revision": "20240111", "rootUrl": "https://metastore.googleapis.com/", "schemas": { "AlterMetadataResourceLocationRequest": { @@ -2833,7 +2833,7 @@ "id": "RestoreServiceRequest", "properties": { "backup": { - "description": "Required. The relative resource name of the metastore service backup to restore from, in the following form:projects/{project_id}/locations/{location_id}/services/{service_id}/backups/{backup_id}.", + "description": "Optional. The relative resource name of the metastore service backup to restore from, in the following form:projects/{project_id}/locations/{location_id}/services/{service_id}/backups/{backup_id}. Mutually exclusive with backup_location, and exactly one of the two must be set.", "type": "string" }, "requestId": { diff --git a/metastore/v1beta/metastore-gen.go b/metastore/v1beta/metastore-gen.go index f656a39bf0f..2856990673b 100644 --- a/metastore/v1beta/metastore-gen.go +++ b/metastore/v1beta/metastore-gen.go @@ -2369,10 +2369,11 @@ func (s *Restore) MarshalJSON() ([]byte, error) { // RestoreServiceRequest: Request message for DataprocMetastore.Restore. type RestoreServiceRequest struct { - // Backup: Required. The relative resource name of the metastore service + // Backup: Optional. The relative resource name of the metastore service // backup to restore from, in the following // form:projects/{project_id}/locations/{location_id}/services/{service_i - // d}/backups/{backup_id}. + // d}/backups/{backup_id}. Mutually exclusive with backup_location, and + // exactly one of the two must be set. Backup string `json:"backup,omitempty"` // RequestId: Optional. A request ID. Specify a unique request ID to diff --git a/policysimulator/v1/policysimulator-api.json b/policysimulator/v1/policysimulator-api.json index c3a67df8ff0..babf3ebccc0 100644 --- a/policysimulator/v1/policysimulator-api.json +++ b/policysimulator/v1/policysimulator-api.json @@ -707,7 +707,7 @@ } } }, - "revision": "20231217", + "revision": "20240121", "rootUrl": "https://policysimulator.googleapis.com/", "schemas": { "GoogleCloudOrgpolicyV2AlternatePolicySpec": { @@ -1402,14 +1402,14 @@ "id": "GoogleCloudPolicysimulatorV1alphaOrgPolicyOverlay", "properties": { "customConstraints": { - "description": "The OrgPolicy CustomConstraint changes to preview violations for. Any existing CustomConstraints with the same name will be overridden in the simulation. That is, violations will be determined as if all custom constraints in the overlay were instantiated. Only a single custom_constraint is supported in the overlay at a time. For evaluating multiple constraints, multiple `GenerateOrgPolicyViolationsPreview` requests are made, where each request evaluates a single constraint.", + "description": "Optional. The OrgPolicy CustomConstraint changes to preview violations for. Any existing CustomConstraints with the same name will be overridden in the simulation. That is, violations will be determined as if all custom constraints in the overlay were instantiated. Only a single custom_constraint is supported in the overlay at a time. For evaluating multiple constraints, multiple `GenerateOrgPolicyViolationsPreview` requests are made, where each request evaluates a single constraint.", "items": { "$ref": "GoogleCloudPolicysimulatorV1alphaOrgPolicyOverlayCustomConstraintOverlay" }, "type": "array" }, "policies": { - "description": "The OrgPolicy changes to preview violations for. Any existing OrgPolicies with the same name will be overridden in the simulation. That is, violations will be determined as if all policies in the overlay were created or updated.", + "description": "Optional. The OrgPolicy changes to preview violations for. Any existing OrgPolicies with the same name will be overridden in the simulation. That is, violations will be determined as if all policies in the overlay were created or updated.", "items": { "$ref": "GoogleCloudPolicysimulatorV1alphaOrgPolicyOverlayPolicyOverlay" }, @@ -1424,10 +1424,10 @@ "properties": { "customConstraint": { "$ref": "GoogleCloudOrgpolicyV2CustomConstraint", - "description": "The new or updated custom constraint." + "description": "Optional. The new or updated custom constraint." }, "customConstraintParent": { - "description": "Resource the constraint is attached to. Example: \"organization/987654\"", + "description": "Optional. Resource the constraint is attached to. Example: \"organization/987654\"", "type": "string" } }, @@ -1439,10 +1439,10 @@ "properties": { "policy": { "$ref": "GoogleCloudOrgpolicyV2Policy", - "description": "The new or updated OrgPolicy." + "description": "Optional. The new or updated OrgPolicy." }, "policyParent": { - "description": "The parent of the policy we are attaching to. Example: \"projects/123456\"", + "description": "Optional. The parent of the policy we are attaching to. Example: \"projects/123456\"", "type": "string" } }, @@ -1513,28 +1513,33 @@ "id": "GoogleCloudPolicysimulatorV1alphaOrgPolicyViolationsPreviewResourceCounts", "properties": { "compliant": { - "description": "Number of scanned resources with zero violations.", + "description": "Output only. Number of scanned resources with zero violations.", "format": "int32", + "readOnly": true, "type": "integer" }, "errors": { - "description": "Number of resources that returned an error when scanned.", + "description": "Output only. Number of resources that returned an error when scanned.", "format": "int32", + "readOnly": true, "type": "integer" }, "noncompliant": { - "description": "Number of scanned resources with at least one violation.", + "description": "Output only. Number of scanned resources with at least one violation.", "format": "int32", + "readOnly": true, "type": "integer" }, "scanned": { - "description": "Number of resources checked for compliance. Must equal: unenforced + noncompliant + compliant + error", + "description": "Output only. Number of resources checked for compliance. Must equal: unenforced + noncompliant + compliant + error", "format": "int32", + "readOnly": true, "type": "integer" }, "unenforced": { - "description": "Number of resources where the constraint was not enforced, i.e. the Policy set `enforced: false` for that resource.", + "description": "Output only. Number of resources where the constraint was not enforced, i.e. the Policy set `enforced: false` for that resource.", "format": "int32", + "readOnly": true, "type": "integer" } }, @@ -1595,14 +1600,14 @@ "id": "GoogleCloudPolicysimulatorV1betaOrgPolicyOverlay", "properties": { "customConstraints": { - "description": "The OrgPolicy CustomConstraint changes to preview violations for. Any existing CustomConstraints with the same name will be overridden in the simulation. That is, violations will be determined as if all custom constraints in the overlay were instantiated. Only a single custom_constraint is supported in the overlay at a time. For evaluating multiple constraints, multiple `GenerateOrgPolicyViolationsPreview` requests are made, where each request evaluates a single constraint.", + "description": "Optional. The OrgPolicy CustomConstraint changes to preview violations for. Any existing CustomConstraints with the same name will be overridden in the simulation. That is, violations will be determined as if all custom constraints in the overlay were instantiated. Only a single custom_constraint is supported in the overlay at a time. For evaluating multiple constraints, multiple `GenerateOrgPolicyViolationsPreview` requests are made, where each request evaluates a single constraint.", "items": { "$ref": "GoogleCloudPolicysimulatorV1betaOrgPolicyOverlayCustomConstraintOverlay" }, "type": "array" }, "policies": { - "description": "The OrgPolicy changes to preview violations for. Any existing OrgPolicies with the same name will be overridden in the simulation. That is, violations will be determined as if all policies in the overlay were created or updated.", + "description": "Optional. The OrgPolicy changes to preview violations for. Any existing OrgPolicies with the same name will be overridden in the simulation. That is, violations will be determined as if all policies in the overlay were created or updated.", "items": { "$ref": "GoogleCloudPolicysimulatorV1betaOrgPolicyOverlayPolicyOverlay" }, @@ -1617,10 +1622,10 @@ "properties": { "customConstraint": { "$ref": "GoogleCloudOrgpolicyV2CustomConstraint", - "description": "The new or updated custom constraint." + "description": "Optional. The new or updated custom constraint." }, "customConstraintParent": { - "description": "Resource the constraint is attached to. Example: \"organization/987654\"", + "description": "Optional. Resource the constraint is attached to. Example: \"organization/987654\"", "type": "string" } }, @@ -1632,10 +1637,10 @@ "properties": { "policy": { "$ref": "GoogleCloudOrgpolicyV2Policy", - "description": "The new or updated OrgPolicy." + "description": "Optional. The new or updated OrgPolicy." }, "policyParent": { - "description": "The parent of the policy we are attaching to. Example: \"projects/123456\"", + "description": "Optional. The parent of the policy we are attaching to. Example: \"projects/123456\"", "type": "string" } }, @@ -1706,28 +1711,33 @@ "id": "GoogleCloudPolicysimulatorV1betaOrgPolicyViolationsPreviewResourceCounts", "properties": { "compliant": { - "description": "Number of scanned resources with zero violations.", + "description": "Output only. Number of scanned resources with zero violations.", "format": "int32", + "readOnly": true, "type": "integer" }, "errors": { - "description": "Number of resources that returned an error when scanned.", + "description": "Output only. Number of resources that returned an error when scanned.", "format": "int32", + "readOnly": true, "type": "integer" }, "noncompliant": { - "description": "Number of scanned resources with at least one violation.", + "description": "Output only. Number of scanned resources with at least one violation.", "format": "int32", + "readOnly": true, "type": "integer" }, "scanned": { - "description": "Number of resources checked for compliance. Must equal: unenforced + noncompliant + compliant + error", + "description": "Output only. Number of resources checked for compliance. Must equal: unenforced + noncompliant + compliant + error", "format": "int32", + "readOnly": true, "type": "integer" }, "unenforced": { - "description": "Number of resources where the constraint was not enforced, i.e. the Policy set `enforced: false` for that resource.", + "description": "Output only. Number of resources where the constraint was not enforced, i.e. the Policy set `enforced: false` for that resource.", "format": "int32", + "readOnly": true, "type": "integer" } }, @@ -1797,7 +1807,7 @@ "type": "array" }, "role": { - "description": "Role that is assigned to the list of `members`, or principals. For example, `roles/viewer`, `roles/editor`, or `roles/owner`.", + "description": "Role that is assigned to the list of `members`, or principals. For example, `roles/viewer`, `roles/editor`, or `roles/owner`. For an overview of the IAM roles and permissions, see the [IAM documentation](https://cloud.google.com/iam/docs/roles-overview). For a list of the available pre-defined roles, see [here](https://cloud.google.com/iam/docs/understanding-roles).", "type": "string" } }, diff --git a/policysimulator/v1/policysimulator-gen.go b/policysimulator/v1/policysimulator-gen.go index ef68f86094e..5b86483b471 100644 --- a/policysimulator/v1/policysimulator-gen.go +++ b/policysimulator/v1/policysimulator-gen.go @@ -1478,18 +1478,18 @@ func (s *GoogleCloudPolicysimulatorV1alphaGenerateOrgPolicyViolationsPreviewOper // GoogleCloudPolicysimulatorV1alphaOrgPolicyOverlay: The proposed // changes to OrgPolicy. type GoogleCloudPolicysimulatorV1alphaOrgPolicyOverlay struct { - // CustomConstraints: The OrgPolicy CustomConstraint changes to preview - // violations for. Any existing CustomConstraints with the same name - // will be overridden in the simulation. That is, violations will be - // determined as if all custom constraints in the overlay were + // CustomConstraints: Optional. The OrgPolicy CustomConstraint changes + // to preview violations for. Any existing CustomConstraints with the + // same name will be overridden in the simulation. That is, violations + // will be determined as if all custom constraints in the overlay were // instantiated. Only a single custom_constraint is supported in the // overlay at a time. For evaluating multiple constraints, multiple // `GenerateOrgPolicyViolationsPreview` requests are made, where each // request evaluates a single constraint. CustomConstraints []*GoogleCloudPolicysimulatorV1alphaOrgPolicyOverlayCustomConstraintOverlay `json:"customConstraints,omitempty"` - // Policies: The OrgPolicy changes to preview violations for. Any - // existing OrgPolicies with the same name will be overridden in the + // Policies: Optional. The OrgPolicy changes to preview violations for. + // Any existing OrgPolicies with the same name will be overridden in the // simulation. That is, violations will be determined as if all policies // in the overlay were created or updated. Policies []*GoogleCloudPolicysimulatorV1alphaOrgPolicyOverlayPolicyOverlay `json:"policies,omitempty"` @@ -1521,11 +1521,11 @@ func (s *GoogleCloudPolicysimulatorV1alphaOrgPolicyOverlay) MarshalJSON() ([]byt // GoogleCloudPolicysimulatorV1alphaOrgPolicyOverlayCustomConstraintOverl // ay: A change to an OrgPolicy custom constraint. type GoogleCloudPolicysimulatorV1alphaOrgPolicyOverlayCustomConstraintOverlay struct { - // CustomConstraint: The new or updated custom constraint. + // CustomConstraint: Optional. The new or updated custom constraint. CustomConstraint *GoogleCloudOrgpolicyV2CustomConstraint `json:"customConstraint,omitempty"` - // CustomConstraintParent: Resource the constraint is attached to. - // Example: "organization/987654" + // CustomConstraintParent: Optional. Resource the constraint is attached + // to. Example: "organization/987654" CustomConstraintParent string `json:"customConstraintParent,omitempty"` // ForceSendFields is a list of field names (e.g. "CustomConstraint") to @@ -1555,11 +1555,11 @@ func (s *GoogleCloudPolicysimulatorV1alphaOrgPolicyOverlayCustomConstraintOverla // GoogleCloudPolicysimulatorV1alphaOrgPolicyOverlayPolicyOverlay: A // change to an OrgPolicy. type GoogleCloudPolicysimulatorV1alphaOrgPolicyOverlayPolicyOverlay struct { - // Policy: The new or updated OrgPolicy. + // Policy: Optional. The new or updated OrgPolicy. Policy *GoogleCloudOrgpolicyV2Policy `json:"policy,omitempty"` - // PolicyParent: The parent of the policy we are attaching to. Example: - // "projects/123456" + // PolicyParent: Optional. The parent of the policy we are attaching to. + // Example: "projects/123456" PolicyParent string `json:"policyParent,omitempty"` // ForceSendFields is a list of field names (e.g. "Policy") to @@ -1673,22 +1673,25 @@ func (s *GoogleCloudPolicysimulatorV1alphaOrgPolicyViolationsPreview) MarshalJSO // nts: A summary of the state of all resources scanned for compliance // with the changed OrgPolicy. type GoogleCloudPolicysimulatorV1alphaOrgPolicyViolationsPreviewResourceCounts struct { - // Compliant: Number of scanned resources with zero violations. + // Compliant: Output only. Number of scanned resources with zero + // violations. Compliant int64 `json:"compliant,omitempty"` - // Errors: Number of resources that returned an error when scanned. + // Errors: Output only. Number of resources that returned an error when + // scanned. Errors int64 `json:"errors,omitempty"` - // Noncompliant: Number of scanned resources with at least one - // violation. + // Noncompliant: Output only. Number of scanned resources with at least + // one violation. Noncompliant int64 `json:"noncompliant,omitempty"` - // Scanned: Number of resources checked for compliance. Must equal: - // unenforced + noncompliant + compliant + error + // Scanned: Output only. Number of resources checked for compliance. + // Must equal: unenforced + noncompliant + compliant + error Scanned int64 `json:"scanned,omitempty"` - // Unenforced: Number of resources where the constraint was not - // enforced, i.e. the Policy set `enforced: false` for that resource. + // Unenforced: Output only. Number of resources where the constraint was + // not enforced, i.e. the Policy set `enforced: false` for that + // resource. Unenforced int64 `json:"unenforced,omitempty"` // ForceSendFields is a list of field names (e.g. "Compliant") to @@ -1775,18 +1778,18 @@ func (s *GoogleCloudPolicysimulatorV1betaGenerateOrgPolicyViolationsPreviewOpera // GoogleCloudPolicysimulatorV1betaOrgPolicyOverlay: The proposed // changes to OrgPolicy. type GoogleCloudPolicysimulatorV1betaOrgPolicyOverlay struct { - // CustomConstraints: The OrgPolicy CustomConstraint changes to preview - // violations for. Any existing CustomConstraints with the same name - // will be overridden in the simulation. That is, violations will be - // determined as if all custom constraints in the overlay were + // CustomConstraints: Optional. The OrgPolicy CustomConstraint changes + // to preview violations for. Any existing CustomConstraints with the + // same name will be overridden in the simulation. That is, violations + // will be determined as if all custom constraints in the overlay were // instantiated. Only a single custom_constraint is supported in the // overlay at a time. For evaluating multiple constraints, multiple // `GenerateOrgPolicyViolationsPreview` requests are made, where each // request evaluates a single constraint. CustomConstraints []*GoogleCloudPolicysimulatorV1betaOrgPolicyOverlayCustomConstraintOverlay `json:"customConstraints,omitempty"` - // Policies: The OrgPolicy changes to preview violations for. Any - // existing OrgPolicies with the same name will be overridden in the + // Policies: Optional. The OrgPolicy changes to preview violations for. + // Any existing OrgPolicies with the same name will be overridden in the // simulation. That is, violations will be determined as if all policies // in the overlay were created or updated. Policies []*GoogleCloudPolicysimulatorV1betaOrgPolicyOverlayPolicyOverlay `json:"policies,omitempty"` @@ -1818,11 +1821,11 @@ func (s *GoogleCloudPolicysimulatorV1betaOrgPolicyOverlay) MarshalJSON() ([]byte // GoogleCloudPolicysimulatorV1betaOrgPolicyOverlayCustomConstraintOverla // y: A change to an OrgPolicy custom constraint. type GoogleCloudPolicysimulatorV1betaOrgPolicyOverlayCustomConstraintOverlay struct { - // CustomConstraint: The new or updated custom constraint. + // CustomConstraint: Optional. The new or updated custom constraint. CustomConstraint *GoogleCloudOrgpolicyV2CustomConstraint `json:"customConstraint,omitempty"` - // CustomConstraintParent: Resource the constraint is attached to. - // Example: "organization/987654" + // CustomConstraintParent: Optional. Resource the constraint is attached + // to. Example: "organization/987654" CustomConstraintParent string `json:"customConstraintParent,omitempty"` // ForceSendFields is a list of field names (e.g. "CustomConstraint") to @@ -1852,11 +1855,11 @@ func (s *GoogleCloudPolicysimulatorV1betaOrgPolicyOverlayCustomConstraintOverlay // GoogleCloudPolicysimulatorV1betaOrgPolicyOverlayPolicyOverlay: A // change to an OrgPolicy. type GoogleCloudPolicysimulatorV1betaOrgPolicyOverlayPolicyOverlay struct { - // Policy: The new or updated OrgPolicy. + // Policy: Optional. The new or updated OrgPolicy. Policy *GoogleCloudOrgpolicyV2Policy `json:"policy,omitempty"` - // PolicyParent: The parent of the policy we are attaching to. Example: - // "projects/123456" + // PolicyParent: Optional. The parent of the policy we are attaching to. + // Example: "projects/123456" PolicyParent string `json:"policyParent,omitempty"` // ForceSendFields is a list of field names (e.g. "Policy") to @@ -1970,22 +1973,25 @@ func (s *GoogleCloudPolicysimulatorV1betaOrgPolicyViolationsPreview) MarshalJSON // ts: A summary of the state of all resources scanned for compliance // with the changed OrgPolicy. type GoogleCloudPolicysimulatorV1betaOrgPolicyViolationsPreviewResourceCounts struct { - // Compliant: Number of scanned resources with zero violations. + // Compliant: Output only. Number of scanned resources with zero + // violations. Compliant int64 `json:"compliant,omitempty"` - // Errors: Number of resources that returned an error when scanned. + // Errors: Output only. Number of resources that returned an error when + // scanned. Errors int64 `json:"errors,omitempty"` - // Noncompliant: Number of scanned resources with at least one - // violation. + // Noncompliant: Output only. Number of scanned resources with at least + // one violation. Noncompliant int64 `json:"noncompliant,omitempty"` - // Scanned: Number of resources checked for compliance. Must equal: - // unenforced + noncompliant + compliant + error + // Scanned: Output only. Number of resources checked for compliance. + // Must equal: unenforced + noncompliant + compliant + error Scanned int64 `json:"scanned,omitempty"` - // Unenforced: Number of resources where the constraint was not - // enforced, i.e. the Policy set `enforced: false` for that resource. + // Unenforced: Output only. Number of resources where the constraint was + // not enforced, i.e. the Policy set `enforced: false` for that + // resource. Unenforced int64 `json:"unenforced,omitempty"` // ForceSendFields is a list of field names (e.g. "Compliant") to @@ -2189,7 +2195,11 @@ type GoogleIamV1Binding struct { Members []string `json:"members,omitempty"` // Role: Role that is assigned to the list of `members`, or principals. - // For example, `roles/viewer`, `roles/editor`, or `roles/owner`. + // For example, `roles/viewer`, `roles/editor`, or `roles/owner`. For an + // overview of the IAM roles and permissions, see the IAM documentation + // (https://cloud.google.com/iam/docs/roles-overview). For a list of the + // available pre-defined roles, see here + // (https://cloud.google.com/iam/docs/understanding-roles). Role string `json:"role,omitempty"` // ForceSendFields is a list of field names (e.g. "Condition") to diff --git a/policysimulator/v1alpha/policysimulator-api.json b/policysimulator/v1alpha/policysimulator-api.json index 04381d69725..d1031e463b5 100644 --- a/policysimulator/v1alpha/policysimulator-api.json +++ b/policysimulator/v1alpha/policysimulator-api.json @@ -457,6 +457,34 @@ "resources": { "orgPolicyViolationsPreviews": { "methods": { + "generate": { + "description": "GenerateOrgPolicyViolationsPreview generates an OrgPolicyViolationsPreview for the proposed changes in the provided OrgPolicyViolationsPreview.OrgPolicyOverlay. The changes to OrgPolicy are specified by this `OrgPolicyOverlay`. The resources to scan are inferred from these specified changes.", + "flatPath": "v1alpha/organizations/{organizationsId}/locations/{locationsId}/orgPolicyViolationsPreviews:generate", + "httpMethod": "POST", + "id": "policysimulator.organizations.locations.orgPolicyViolationsPreviews.generate", + "parameterOrder": [ + "parent" + ], + "parameters": { + "parent": { + "description": "Required. The organization under which this OrgPolicyViolationsPreview will be created. Example: `organizations/my-example-org/locations/global`", + "location": "path", + "pattern": "^organizations/[^/]+/locations/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1alpha/{+parent}/orgPolicyViolationsPreviews:generate", + "request": { + "$ref": "GoogleCloudPolicysimulatorV1alphaOrgPolicyViolationsPreview" + }, + "response": { + "$ref": "GoogleLongrunningOperation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, "get": { "description": "GetOrgPolicyViolationsPreview gets the specified OrgPolicyViolationsPreview. Each OrgPolicyViolationsPreview is available for at least 7 days.", "flatPath": "v1alpha/organizations/{organizationsId}/locations/{locationsId}/orgPolicyViolationsPreviews/{orgPolicyViolationsPreviewsId}", @@ -492,13 +520,13 @@ ], "parameters": { "pageSize": { - "description": "The maximum number of items to return. The service may return fewer than this value. If unspecified, at most 5 items will be returned. The maximum value is 10; values above 10 will be coerced to 10.", + "description": "Optional. The maximum number of items to return. The service may return fewer than this value. If unspecified, at most 5 items will be returned. The maximum value is 10; values above 10 will be coerced to 10.", "format": "int32", "location": "query", "type": "integer" }, "pageToken": { - "description": "A page token, received from a previous call. Provide this to retrieve the subsequent page. When paginating, all other parameters must match the call that provided the page token.", + "description": "Optional. A page token, received from a previous call. Provide this to retrieve the subsequent page. When paginating, all other parameters must match the call that provided the page token.", "location": "query", "type": "string" }, @@ -561,13 +589,13 @@ ], "parameters": { "pageSize": { - "description": "The maximum number of items to return. The service may return fewer than this value. If unspecified, at most 50 items will be returned. The maximum value is 1000; values above 1000 will be coerced to 1000.", + "description": "Optional. The maximum number of items to return. The service may return fewer than this value. If unspecified, at most 50 items will be returned. The maximum value is 1000; values above 1000 will be coerced to 1000.", "format": "int32", "location": "query", "type": "integer" }, "pageToken": { - "description": "A page token, received from a previous call. Provide this to retrieve the subsequent page. When paginating, all other parameters must match the call that provided the page token.", + "description": "Optional. A page token, received from a previous call. Provide this to retrieve the subsequent page. When paginating, all other parameters must match the call that provided the page token.", "location": "query", "type": "string" }, @@ -1047,7 +1075,7 @@ } } }, - "revision": "20231217", + "revision": "20240121", "rootUrl": "https://policysimulator.googleapis.com/", "schemas": { "GoogleCloudOrgpolicyV2AlternatePolicySpec": { @@ -1754,14 +1782,14 @@ "id": "GoogleCloudPolicysimulatorV1alphaOrgPolicyOverlay", "properties": { "customConstraints": { - "description": "The OrgPolicy CustomConstraint changes to preview violations for. Any existing CustomConstraints with the same name will be overridden in the simulation. That is, violations will be determined as if all custom constraints in the overlay were instantiated. Only a single custom_constraint is supported in the overlay at a time. For evaluating multiple constraints, multiple `GenerateOrgPolicyViolationsPreview` requests are made, where each request evaluates a single constraint.", + "description": "Optional. The OrgPolicy CustomConstraint changes to preview violations for. Any existing CustomConstraints with the same name will be overridden in the simulation. That is, violations will be determined as if all custom constraints in the overlay were instantiated. Only a single custom_constraint is supported in the overlay at a time. For evaluating multiple constraints, multiple `GenerateOrgPolicyViolationsPreview` requests are made, where each request evaluates a single constraint.", "items": { "$ref": "GoogleCloudPolicysimulatorV1alphaOrgPolicyOverlayCustomConstraintOverlay" }, "type": "array" }, "policies": { - "description": "The OrgPolicy changes to preview violations for. Any existing OrgPolicies with the same name will be overridden in the simulation. That is, violations will be determined as if all policies in the overlay were created or updated.", + "description": "Optional. The OrgPolicy changes to preview violations for. Any existing OrgPolicies with the same name will be overridden in the simulation. That is, violations will be determined as if all policies in the overlay were created or updated.", "items": { "$ref": "GoogleCloudPolicysimulatorV1alphaOrgPolicyOverlayPolicyOverlay" }, @@ -1776,10 +1804,10 @@ "properties": { "customConstraint": { "$ref": "GoogleCloudOrgpolicyV2CustomConstraint", - "description": "The new or updated custom constraint." + "description": "Optional. The new or updated custom constraint." }, "customConstraintParent": { - "description": "Resource the constraint is attached to. Example: \"organization/987654\"", + "description": "Optional. Resource the constraint is attached to. Example: \"organization/987654\"", "type": "string" } }, @@ -1791,10 +1819,10 @@ "properties": { "policy": { "$ref": "GoogleCloudOrgpolicyV2Policy", - "description": "The new or updated OrgPolicy." + "description": "Optional. The new or updated OrgPolicy." }, "policyParent": { - "description": "The parent of the policy we are attaching to. Example: \"projects/123456\"", + "description": "Optional. The parent of the policy we are attaching to. Example: \"projects/123456\"", "type": "string" } }, @@ -1888,28 +1916,33 @@ "id": "GoogleCloudPolicysimulatorV1alphaOrgPolicyViolationsPreviewResourceCounts", "properties": { "compliant": { - "description": "Number of scanned resources with zero violations.", + "description": "Output only. Number of scanned resources with zero violations.", "format": "int32", + "readOnly": true, "type": "integer" }, "errors": { - "description": "Number of resources that returned an error when scanned.", + "description": "Output only. Number of resources that returned an error when scanned.", "format": "int32", + "readOnly": true, "type": "integer" }, "noncompliant": { - "description": "Number of scanned resources with at least one violation.", + "description": "Output only. Number of scanned resources with at least one violation.", "format": "int32", + "readOnly": true, "type": "integer" }, "scanned": { - "description": "Number of resources checked for compliance. Must equal: unenforced + noncompliant + compliant + error", + "description": "Output only. Number of resources checked for compliance. Must equal: unenforced + noncompliant + compliant + error", "format": "int32", + "readOnly": true, "type": "integer" }, "unenforced": { - "description": "Number of resources where the constraint was not enforced, i.e. the Policy set `enforced: false` for that resource.", + "description": "Output only. Number of resources where the constraint was not enforced, i.e. the Policy set `enforced: false` for that resource.", "format": "int32", + "readOnly": true, "type": "integer" } }, @@ -2135,14 +2168,14 @@ "id": "GoogleCloudPolicysimulatorV1betaOrgPolicyOverlay", "properties": { "customConstraints": { - "description": "The OrgPolicy CustomConstraint changes to preview violations for. Any existing CustomConstraints with the same name will be overridden in the simulation. That is, violations will be determined as if all custom constraints in the overlay were instantiated. Only a single custom_constraint is supported in the overlay at a time. For evaluating multiple constraints, multiple `GenerateOrgPolicyViolationsPreview` requests are made, where each request evaluates a single constraint.", + "description": "Optional. The OrgPolicy CustomConstraint changes to preview violations for. Any existing CustomConstraints with the same name will be overridden in the simulation. That is, violations will be determined as if all custom constraints in the overlay were instantiated. Only a single custom_constraint is supported in the overlay at a time. For evaluating multiple constraints, multiple `GenerateOrgPolicyViolationsPreview` requests are made, where each request evaluates a single constraint.", "items": { "$ref": "GoogleCloudPolicysimulatorV1betaOrgPolicyOverlayCustomConstraintOverlay" }, "type": "array" }, "policies": { - "description": "The OrgPolicy changes to preview violations for. Any existing OrgPolicies with the same name will be overridden in the simulation. That is, violations will be determined as if all policies in the overlay were created or updated.", + "description": "Optional. The OrgPolicy changes to preview violations for. Any existing OrgPolicies with the same name will be overridden in the simulation. That is, violations will be determined as if all policies in the overlay were created or updated.", "items": { "$ref": "GoogleCloudPolicysimulatorV1betaOrgPolicyOverlayPolicyOverlay" }, @@ -2157,10 +2190,10 @@ "properties": { "customConstraint": { "$ref": "GoogleCloudOrgpolicyV2CustomConstraint", - "description": "The new or updated custom constraint." + "description": "Optional. The new or updated custom constraint." }, "customConstraintParent": { - "description": "Resource the constraint is attached to. Example: \"organization/987654\"", + "description": "Optional. Resource the constraint is attached to. Example: \"organization/987654\"", "type": "string" } }, @@ -2172,10 +2205,10 @@ "properties": { "policy": { "$ref": "GoogleCloudOrgpolicyV2Policy", - "description": "The new or updated OrgPolicy." + "description": "Optional. The new or updated OrgPolicy." }, "policyParent": { - "description": "The parent of the policy we are attaching to. Example: \"projects/123456\"", + "description": "Optional. The parent of the policy we are attaching to. Example: \"projects/123456\"", "type": "string" } }, @@ -2246,28 +2279,33 @@ "id": "GoogleCloudPolicysimulatorV1betaOrgPolicyViolationsPreviewResourceCounts", "properties": { "compliant": { - "description": "Number of scanned resources with zero violations.", + "description": "Output only. Number of scanned resources with zero violations.", "format": "int32", + "readOnly": true, "type": "integer" }, "errors": { - "description": "Number of resources that returned an error when scanned.", + "description": "Output only. Number of resources that returned an error when scanned.", "format": "int32", + "readOnly": true, "type": "integer" }, "noncompliant": { - "description": "Number of scanned resources with at least one violation.", + "description": "Output only. Number of scanned resources with at least one violation.", "format": "int32", + "readOnly": true, "type": "integer" }, "scanned": { - "description": "Number of resources checked for compliance. Must equal: unenforced + noncompliant + compliant + error", + "description": "Output only. Number of resources checked for compliance. Must equal: unenforced + noncompliant + compliant + error", "format": "int32", + "readOnly": true, "type": "integer" }, "unenforced": { - "description": "Number of resources where the constraint was not enforced, i.e. the Policy set `enforced: false` for that resource.", + "description": "Output only. Number of resources where the constraint was not enforced, i.e. the Policy set `enforced: false` for that resource.", "format": "int32", + "readOnly": true, "type": "integer" } }, @@ -2337,7 +2375,7 @@ "type": "array" }, "role": { - "description": "Role that is assigned to the list of `members`, or principals. For example, `roles/viewer`, `roles/editor`, or `roles/owner`.", + "description": "Role that is assigned to the list of `members`, or principals. For example, `roles/viewer`, `roles/editor`, or `roles/owner`. For an overview of the IAM roles and permissions, see the [IAM documentation](https://cloud.google.com/iam/docs/roles-overview). For a list of the available pre-defined roles, see [here](https://cloud.google.com/iam/docs/understanding-roles).", "type": "string" } }, diff --git a/policysimulator/v1alpha/policysimulator-gen.go b/policysimulator/v1alpha/policysimulator-gen.go index f8e28737136..aa0fdce51de 100644 --- a/policysimulator/v1alpha/policysimulator-gen.go +++ b/policysimulator/v1alpha/policysimulator-gen.go @@ -1579,18 +1579,18 @@ func (s *GoogleCloudPolicysimulatorV1alphaListReplaysResponse) MarshalJSON() ([] // GoogleCloudPolicysimulatorV1alphaOrgPolicyOverlay: The proposed // changes to OrgPolicy. type GoogleCloudPolicysimulatorV1alphaOrgPolicyOverlay struct { - // CustomConstraints: The OrgPolicy CustomConstraint changes to preview - // violations for. Any existing CustomConstraints with the same name - // will be overridden in the simulation. That is, violations will be - // determined as if all custom constraints in the overlay were + // CustomConstraints: Optional. The OrgPolicy CustomConstraint changes + // to preview violations for. Any existing CustomConstraints with the + // same name will be overridden in the simulation. That is, violations + // will be determined as if all custom constraints in the overlay were // instantiated. Only a single custom_constraint is supported in the // overlay at a time. For evaluating multiple constraints, multiple // `GenerateOrgPolicyViolationsPreview` requests are made, where each // request evaluates a single constraint. CustomConstraints []*GoogleCloudPolicysimulatorV1alphaOrgPolicyOverlayCustomConstraintOverlay `json:"customConstraints,omitempty"` - // Policies: The OrgPolicy changes to preview violations for. Any - // existing OrgPolicies with the same name will be overridden in the + // Policies: Optional. The OrgPolicy changes to preview violations for. + // Any existing OrgPolicies with the same name will be overridden in the // simulation. That is, violations will be determined as if all policies // in the overlay were created or updated. Policies []*GoogleCloudPolicysimulatorV1alphaOrgPolicyOverlayPolicyOverlay `json:"policies,omitempty"` @@ -1622,11 +1622,11 @@ func (s *GoogleCloudPolicysimulatorV1alphaOrgPolicyOverlay) MarshalJSON() ([]byt // GoogleCloudPolicysimulatorV1alphaOrgPolicyOverlayCustomConstraintOverl // ay: A change to an OrgPolicy custom constraint. type GoogleCloudPolicysimulatorV1alphaOrgPolicyOverlayCustomConstraintOverlay struct { - // CustomConstraint: The new or updated custom constraint. + // CustomConstraint: Optional. The new or updated custom constraint. CustomConstraint *GoogleCloudOrgpolicyV2CustomConstraint `json:"customConstraint,omitempty"` - // CustomConstraintParent: Resource the constraint is attached to. - // Example: "organization/987654" + // CustomConstraintParent: Optional. Resource the constraint is attached + // to. Example: "organization/987654" CustomConstraintParent string `json:"customConstraintParent,omitempty"` // ForceSendFields is a list of field names (e.g. "CustomConstraint") to @@ -1656,11 +1656,11 @@ func (s *GoogleCloudPolicysimulatorV1alphaOrgPolicyOverlayCustomConstraintOverla // GoogleCloudPolicysimulatorV1alphaOrgPolicyOverlayPolicyOverlay: A // change to an OrgPolicy. type GoogleCloudPolicysimulatorV1alphaOrgPolicyOverlayPolicyOverlay struct { - // Policy: The new or updated OrgPolicy. + // Policy: Optional. The new or updated OrgPolicy. Policy *GoogleCloudOrgpolicyV2Policy `json:"policy,omitempty"` - // PolicyParent: The parent of the policy we are attaching to. Example: - // "projects/123456" + // PolicyParent: Optional. The parent of the policy we are attaching to. + // Example: "projects/123456" PolicyParent string `json:"policyParent,omitempty"` // ForceSendFields is a list of field names (e.g. "Policy") to @@ -1820,22 +1820,25 @@ func (s *GoogleCloudPolicysimulatorV1alphaOrgPolicyViolationsPreview) MarshalJSO // nts: A summary of the state of all resources scanned for compliance // with the changed OrgPolicy. type GoogleCloudPolicysimulatorV1alphaOrgPolicyViolationsPreviewResourceCounts struct { - // Compliant: Number of scanned resources with zero violations. + // Compliant: Output only. Number of scanned resources with zero + // violations. Compliant int64 `json:"compliant,omitempty"` - // Errors: Number of resources that returned an error when scanned. + // Errors: Output only. Number of resources that returned an error when + // scanned. Errors int64 `json:"errors,omitempty"` - // Noncompliant: Number of scanned resources with at least one - // violation. + // Noncompliant: Output only. Number of scanned resources with at least + // one violation. Noncompliant int64 `json:"noncompliant,omitempty"` - // Scanned: Number of resources checked for compliance. Must equal: - // unenforced + noncompliant + compliant + error + // Scanned: Output only. Number of resources checked for compliance. + // Must equal: unenforced + noncompliant + compliant + error Scanned int64 `json:"scanned,omitempty"` - // Unenforced: Number of resources where the constraint was not - // enforced, i.e. the Policy set `enforced: false` for that resource. + // Unenforced: Output only. Number of resources where the constraint was + // not enforced, i.e. the Policy set `enforced: false` for that + // resource. Unenforced int64 `json:"unenforced,omitempty"` // ForceSendFields is a list of field names (e.g. "Compliant") to @@ -2219,18 +2222,18 @@ func (s *GoogleCloudPolicysimulatorV1betaGenerateOrgPolicyViolationsPreviewOpera // GoogleCloudPolicysimulatorV1betaOrgPolicyOverlay: The proposed // changes to OrgPolicy. type GoogleCloudPolicysimulatorV1betaOrgPolicyOverlay struct { - // CustomConstraints: The OrgPolicy CustomConstraint changes to preview - // violations for. Any existing CustomConstraints with the same name - // will be overridden in the simulation. That is, violations will be - // determined as if all custom constraints in the overlay were + // CustomConstraints: Optional. The OrgPolicy CustomConstraint changes + // to preview violations for. Any existing CustomConstraints with the + // same name will be overridden in the simulation. That is, violations + // will be determined as if all custom constraints in the overlay were // instantiated. Only a single custom_constraint is supported in the // overlay at a time. For evaluating multiple constraints, multiple // `GenerateOrgPolicyViolationsPreview` requests are made, where each // request evaluates a single constraint. CustomConstraints []*GoogleCloudPolicysimulatorV1betaOrgPolicyOverlayCustomConstraintOverlay `json:"customConstraints,omitempty"` - // Policies: The OrgPolicy changes to preview violations for. Any - // existing OrgPolicies with the same name will be overridden in the + // Policies: Optional. The OrgPolicy changes to preview violations for. + // Any existing OrgPolicies with the same name will be overridden in the // simulation. That is, violations will be determined as if all policies // in the overlay were created or updated. Policies []*GoogleCloudPolicysimulatorV1betaOrgPolicyOverlayPolicyOverlay `json:"policies,omitempty"` @@ -2262,11 +2265,11 @@ func (s *GoogleCloudPolicysimulatorV1betaOrgPolicyOverlay) MarshalJSON() ([]byte // GoogleCloudPolicysimulatorV1betaOrgPolicyOverlayCustomConstraintOverla // y: A change to an OrgPolicy custom constraint. type GoogleCloudPolicysimulatorV1betaOrgPolicyOverlayCustomConstraintOverlay struct { - // CustomConstraint: The new or updated custom constraint. + // CustomConstraint: Optional. The new or updated custom constraint. CustomConstraint *GoogleCloudOrgpolicyV2CustomConstraint `json:"customConstraint,omitempty"` - // CustomConstraintParent: Resource the constraint is attached to. - // Example: "organization/987654" + // CustomConstraintParent: Optional. Resource the constraint is attached + // to. Example: "organization/987654" CustomConstraintParent string `json:"customConstraintParent,omitempty"` // ForceSendFields is a list of field names (e.g. "CustomConstraint") to @@ -2296,11 +2299,11 @@ func (s *GoogleCloudPolicysimulatorV1betaOrgPolicyOverlayCustomConstraintOverlay // GoogleCloudPolicysimulatorV1betaOrgPolicyOverlayPolicyOverlay: A // change to an OrgPolicy. type GoogleCloudPolicysimulatorV1betaOrgPolicyOverlayPolicyOverlay struct { - // Policy: The new or updated OrgPolicy. + // Policy: Optional. The new or updated OrgPolicy. Policy *GoogleCloudOrgpolicyV2Policy `json:"policy,omitempty"` - // PolicyParent: The parent of the policy we are attaching to. Example: - // "projects/123456" + // PolicyParent: Optional. The parent of the policy we are attaching to. + // Example: "projects/123456" PolicyParent string `json:"policyParent,omitempty"` // ForceSendFields is a list of field names (e.g. "Policy") to @@ -2414,22 +2417,25 @@ func (s *GoogleCloudPolicysimulatorV1betaOrgPolicyViolationsPreview) MarshalJSON // ts: A summary of the state of all resources scanned for compliance // with the changed OrgPolicy. type GoogleCloudPolicysimulatorV1betaOrgPolicyViolationsPreviewResourceCounts struct { - // Compliant: Number of scanned resources with zero violations. + // Compliant: Output only. Number of scanned resources with zero + // violations. Compliant int64 `json:"compliant,omitempty"` - // Errors: Number of resources that returned an error when scanned. + // Errors: Output only. Number of resources that returned an error when + // scanned. Errors int64 `json:"errors,omitempty"` - // Noncompliant: Number of scanned resources with at least one - // violation. + // Noncompliant: Output only. Number of scanned resources with at least + // one violation. Noncompliant int64 `json:"noncompliant,omitempty"` - // Scanned: Number of resources checked for compliance. Must equal: - // unenforced + noncompliant + compliant + error + // Scanned: Output only. Number of resources checked for compliance. + // Must equal: unenforced + noncompliant + compliant + error Scanned int64 `json:"scanned,omitempty"` - // Unenforced: Number of resources where the constraint was not - // enforced, i.e. the Policy set `enforced: false` for that resource. + // Unenforced: Output only. Number of resources where the constraint was + // not enforced, i.e. the Policy set `enforced: false` for that + // resource. Unenforced int64 `json:"unenforced,omitempty"` // ForceSendFields is a list of field names (e.g. "Compliant") to @@ -2633,7 +2639,11 @@ type GoogleIamV1Binding struct { Members []string `json:"members,omitempty"` // Role: Role that is assigned to the list of `members`, or principals. - // For example, `roles/viewer`, `roles/editor`, or `roles/owner`. + // For example, `roles/viewer`, `roles/editor`, or `roles/owner`. For an + // overview of the IAM roles and permissions, see the IAM documentation + // (https://cloud.google.com/iam/docs/roles-overview). For a list of the + // available pre-defined roles, see here + // (https://cloud.google.com/iam/docs/understanding-roles). Role string `json:"role,omitempty"` // ForceSendFields is a list of field names (e.g. "Condition") to @@ -4728,6 +4738,154 @@ func (c *OrganizationsLocationsOrgPolicyViolationsPreviewsCall) Do(opts ...googl } +// method id "policysimulator.organizations.locations.orgPolicyViolationsPreviews.generate": + +type OrganizationsLocationsOrgPolicyViolationsPreviewsGenerateCall struct { + s *Service + parent string + googlecloudpolicysimulatorv1alphaorgpolicyviolationspreview *GoogleCloudPolicysimulatorV1alphaOrgPolicyViolationsPreview + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Generate: GenerateOrgPolicyViolationsPreview generates an +// OrgPolicyViolationsPreview for the proposed changes in the provided +// OrgPolicyViolationsPreview.OrgPolicyOverlay. The changes to OrgPolicy +// are specified by this `OrgPolicyOverlay`. The resources to scan are +// inferred from these specified changes. +// +// - parent: The organization under which this +// OrgPolicyViolationsPreview will be created. Example: +// `organizations/my-example-org/locations/global`. +func (r *OrganizationsLocationsOrgPolicyViolationsPreviewsService) Generate(parent string, googlecloudpolicysimulatorv1alphaorgpolicyviolationspreview *GoogleCloudPolicysimulatorV1alphaOrgPolicyViolationsPreview) *OrganizationsLocationsOrgPolicyViolationsPreviewsGenerateCall { + c := &OrganizationsLocationsOrgPolicyViolationsPreviewsGenerateCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + c.googlecloudpolicysimulatorv1alphaorgpolicyviolationspreview = googlecloudpolicysimulatorv1alphaorgpolicyviolationspreview + return c +} + +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse +// for more information. +func (c *OrganizationsLocationsOrgPolicyViolationsPreviewsGenerateCall) Fields(s ...googleapi.Field) *OrganizationsLocationsOrgPolicyViolationsPreviewsGenerateCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. Any +// pending HTTP request will be aborted if the provided context is +// canceled. +func (c *OrganizationsLocationsOrgPolicyViolationsPreviewsGenerateCall) Context(ctx context.Context) *OrganizationsLocationsOrgPolicyViolationsPreviewsGenerateCall { + c.ctx_ = ctx + return c +} + +// Header returns an http.Header that can be modified by the caller to +// add HTTP headers to the request. +func (c *OrganizationsLocationsOrgPolicyViolationsPreviewsGenerateCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *OrganizationsLocationsOrgPolicyViolationsPreviewsGenerateCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := make(http.Header) + reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) + for k, v := range c.header_ { + reqHeaders[k] = v + } + reqHeaders.Set("User-Agent", c.s.userAgent()) + var body io.Reader = nil + body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudpolicysimulatorv1alphaorgpolicyviolationspreview) + if err != nil { + return nil, err + } + reqHeaders.Set("Content-Type", "application/json") + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+parent}/orgPolicyViolationsPreviews:generate") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("POST", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "parent": c.parent, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "policysimulator.organizations.locations.orgPolicyViolationsPreviews.generate" call. +// Exactly one of *GoogleLongrunningOperation or error will be non-nil. +// 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 *OrganizationsLocationsOrgPolicyViolationsPreviewsGenerateCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &GoogleLongrunningOperation{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil + // { + // "description": "GenerateOrgPolicyViolationsPreview generates an OrgPolicyViolationsPreview for the proposed changes in the provided OrgPolicyViolationsPreview.OrgPolicyOverlay. The changes to OrgPolicy are specified by this `OrgPolicyOverlay`. The resources to scan are inferred from these specified changes.", + // "flatPath": "v1alpha/organizations/{organizationsId}/locations/{locationsId}/orgPolicyViolationsPreviews:generate", + // "httpMethod": "POST", + // "id": "policysimulator.organizations.locations.orgPolicyViolationsPreviews.generate", + // "parameterOrder": [ + // "parent" + // ], + // "parameters": { + // "parent": { + // "description": "Required. The organization under which this OrgPolicyViolationsPreview will be created. Example: `organizations/my-example-org/locations/global`", + // "location": "path", + // "pattern": "^organizations/[^/]+/locations/[^/]+$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1alpha/{+parent}/orgPolicyViolationsPreviews:generate", + // "request": { + // "$ref": "GoogleCloudPolicysimulatorV1alphaOrgPolicyViolationsPreview" + // }, + // "response": { + // "$ref": "GoogleLongrunningOperation" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + // method id "policysimulator.organizations.locations.orgPolicyViolationsPreviews.get": type OrganizationsLocationsOrgPolicyViolationsPreviewsGetCall struct { @@ -5032,13 +5190,13 @@ func (c *OrganizationsLocationsOrgPolicyViolationsPreviewsListCall) Do(opts ...g // ], // "parameters": { // "pageSize": { - // "description": "The maximum number of items to return. The service may return fewer than this value. If unspecified, at most 5 items will be returned. The maximum value is 10; values above 10 will be coerced to 10.", + // "description": "Optional. The maximum number of items to return. The service may return fewer than this value. If unspecified, at most 5 items will be returned. The maximum value is 10; values above 10 will be coerced to 10.", // "format": "int32", // "location": "query", // "type": "integer" // }, // "pageToken": { - // "description": "A page token, received from a previous call. Provide this to retrieve the subsequent page. When paginating, all other parameters must match the call that provided the page token.", + // "description": "Optional. A page token, received from a previous call. Provide this to retrieve the subsequent page. When paginating, all other parameters must match the call that provided the page token.", // "location": "query", // "type": "string" // }, @@ -5383,13 +5541,13 @@ func (c *OrganizationsLocationsOrgPolicyViolationsPreviewsOrgPolicyViolationsLis // ], // "parameters": { // "pageSize": { - // "description": "The maximum number of items to return. The service may return fewer than this value. If unspecified, at most 50 items will be returned. The maximum value is 1000; values above 1000 will be coerced to 1000.", + // "description": "Optional. The maximum number of items to return. The service may return fewer than this value. If unspecified, at most 50 items will be returned. The maximum value is 1000; values above 1000 will be coerced to 1000.", // "format": "int32", // "location": "query", // "type": "integer" // }, // "pageToken": { - // "description": "A page token, received from a previous call. Provide this to retrieve the subsequent page. When paginating, all other parameters must match the call that provided the page token.", + // "description": "Optional. A page token, received from a previous call. Provide this to retrieve the subsequent page. When paginating, all other parameters must match the call that provided the page token.", // "location": "query", // "type": "string" // }, diff --git a/policysimulator/v1beta/policysimulator-api.json b/policysimulator/v1beta/policysimulator-api.json index c7a632e2622..3ce5ffbaecb 100644 --- a/policysimulator/v1beta/policysimulator-api.json +++ b/policysimulator/v1beta/policysimulator-api.json @@ -457,6 +457,34 @@ "resources": { "orgPolicyViolationsPreviews": { "methods": { + "generate": { + "description": "GenerateOrgPolicyViolationsPreview generates an OrgPolicyViolationsPreview for the proposed changes in the provided OrgPolicyViolationsPreview.OrgPolicyOverlay. The changes to OrgPolicy are specified by this `OrgPolicyOverlay`. The resources to scan are inferred from these specified changes.", + "flatPath": "v1beta/organizations/{organizationsId}/locations/{locationsId}/orgPolicyViolationsPreviews:generate", + "httpMethod": "POST", + "id": "policysimulator.organizations.locations.orgPolicyViolationsPreviews.generate", + "parameterOrder": [ + "parent" + ], + "parameters": { + "parent": { + "description": "Required. The organization under which this OrgPolicyViolationsPreview will be created. Example: `organizations/my-example-org/locations/global`", + "location": "path", + "pattern": "^organizations/[^/]+/locations/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1beta/{+parent}/orgPolicyViolationsPreviews:generate", + "request": { + "$ref": "GoogleCloudPolicysimulatorV1betaOrgPolicyViolationsPreview" + }, + "response": { + "$ref": "GoogleLongrunningOperation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, "get": { "description": "GetOrgPolicyViolationsPreview gets the specified OrgPolicyViolationsPreview. Each OrgPolicyViolationsPreview is available for at least 7 days.", "flatPath": "v1beta/organizations/{organizationsId}/locations/{locationsId}/orgPolicyViolationsPreviews/{orgPolicyViolationsPreviewsId}", @@ -492,13 +520,13 @@ ], "parameters": { "pageSize": { - "description": "The maximum number of items to return. The service may return fewer than this value. If unspecified, at most 5 items will be returned. The maximum value is 10; values above 10 will be coerced to 10.", + "description": "Optional. The maximum number of items to return. The service may return fewer than this value. If unspecified, at most 5 items will be returned. The maximum value is 10; values above 10 will be coerced to 10.", "format": "int32", "location": "query", "type": "integer" }, "pageToken": { - "description": "A page token, received from a previous call. Provide this to retrieve the subsequent page. When paginating, all other parameters must match the call that provided the page token.", + "description": "Optional. A page token, received from a previous call. Provide this to retrieve the subsequent page. When paginating, all other parameters must match the call that provided the page token.", "location": "query", "type": "string" }, @@ -561,13 +589,13 @@ ], "parameters": { "pageSize": { - "description": "The maximum number of items to return. The service may return fewer than this value. If unspecified, at most 50 items will be returned. The maximum value is 1000; values above 1000 will be coerced to 1000.", + "description": "Optional. The maximum number of items to return. The service may return fewer than this value. If unspecified, at most 50 items will be returned. The maximum value is 1000; values above 1000 will be coerced to 1000.", "format": "int32", "location": "query", "type": "integer" }, "pageToken": { - "description": "A page token, received from a previous call. Provide this to retrieve the subsequent page. When paginating, all other parameters must match the call that provided the page token.", + "description": "Optional. A page token, received from a previous call. Provide this to retrieve the subsequent page. When paginating, all other parameters must match the call that provided the page token.", "location": "query", "type": "string" }, @@ -1047,7 +1075,7 @@ } } }, - "revision": "20231217", + "revision": "20240121", "rootUrl": "https://policysimulator.googleapis.com/", "schemas": { "GoogleCloudOrgpolicyV2AlternatePolicySpec": { @@ -1410,14 +1438,14 @@ "id": "GoogleCloudPolicysimulatorV1alphaOrgPolicyOverlay", "properties": { "customConstraints": { - "description": "The OrgPolicy CustomConstraint changes to preview violations for. Any existing CustomConstraints with the same name will be overridden in the simulation. That is, violations will be determined as if all custom constraints in the overlay were instantiated. Only a single custom_constraint is supported in the overlay at a time. For evaluating multiple constraints, multiple `GenerateOrgPolicyViolationsPreview` requests are made, where each request evaluates a single constraint.", + "description": "Optional. The OrgPolicy CustomConstraint changes to preview violations for. Any existing CustomConstraints with the same name will be overridden in the simulation. That is, violations will be determined as if all custom constraints in the overlay were instantiated. Only a single custom_constraint is supported in the overlay at a time. For evaluating multiple constraints, multiple `GenerateOrgPolicyViolationsPreview` requests are made, where each request evaluates a single constraint.", "items": { "$ref": "GoogleCloudPolicysimulatorV1alphaOrgPolicyOverlayCustomConstraintOverlay" }, "type": "array" }, "policies": { - "description": "The OrgPolicy changes to preview violations for. Any existing OrgPolicies with the same name will be overridden in the simulation. That is, violations will be determined as if all policies in the overlay were created or updated.", + "description": "Optional. The OrgPolicy changes to preview violations for. Any existing OrgPolicies with the same name will be overridden in the simulation. That is, violations will be determined as if all policies in the overlay were created or updated.", "items": { "$ref": "GoogleCloudPolicysimulatorV1alphaOrgPolicyOverlayPolicyOverlay" }, @@ -1432,10 +1460,10 @@ "properties": { "customConstraint": { "$ref": "GoogleCloudOrgpolicyV2CustomConstraint", - "description": "The new or updated custom constraint." + "description": "Optional. The new or updated custom constraint." }, "customConstraintParent": { - "description": "Resource the constraint is attached to. Example: \"organization/987654\"", + "description": "Optional. Resource the constraint is attached to. Example: \"organization/987654\"", "type": "string" } }, @@ -1447,10 +1475,10 @@ "properties": { "policy": { "$ref": "GoogleCloudOrgpolicyV2Policy", - "description": "The new or updated OrgPolicy." + "description": "Optional. The new or updated OrgPolicy." }, "policyParent": { - "description": "The parent of the policy we are attaching to. Example: \"projects/123456\"", + "description": "Optional. The parent of the policy we are attaching to. Example: \"projects/123456\"", "type": "string" } }, @@ -1521,28 +1549,33 @@ "id": "GoogleCloudPolicysimulatorV1alphaOrgPolicyViolationsPreviewResourceCounts", "properties": { "compliant": { - "description": "Number of scanned resources with zero violations.", + "description": "Output only. Number of scanned resources with zero violations.", "format": "int32", + "readOnly": true, "type": "integer" }, "errors": { - "description": "Number of resources that returned an error when scanned.", + "description": "Output only. Number of resources that returned an error when scanned.", "format": "int32", + "readOnly": true, "type": "integer" }, "noncompliant": { - "description": "Number of scanned resources with at least one violation.", + "description": "Output only. Number of scanned resources with at least one violation.", "format": "int32", + "readOnly": true, "type": "integer" }, "scanned": { - "description": "Number of resources checked for compliance. Must equal: unenforced + noncompliant + compliant + error", + "description": "Output only. Number of resources checked for compliance. Must equal: unenforced + noncompliant + compliant + error", "format": "int32", + "readOnly": true, "type": "integer" }, "unenforced": { - "description": "Number of resources where the constraint was not enforced, i.e. the Policy set `enforced: false` for that resource.", + "description": "Output only. Number of resources where the constraint was not enforced, i.e. the Policy set `enforced: false` for that resource.", "format": "int32", + "readOnly": true, "type": "integer" } }, @@ -1947,14 +1980,14 @@ "id": "GoogleCloudPolicysimulatorV1betaOrgPolicyOverlay", "properties": { "customConstraints": { - "description": "The OrgPolicy CustomConstraint changes to preview violations for. Any existing CustomConstraints with the same name will be overridden in the simulation. That is, violations will be determined as if all custom constraints in the overlay were instantiated. Only a single custom_constraint is supported in the overlay at a time. For evaluating multiple constraints, multiple `GenerateOrgPolicyViolationsPreview` requests are made, where each request evaluates a single constraint.", + "description": "Optional. The OrgPolicy CustomConstraint changes to preview violations for. Any existing CustomConstraints with the same name will be overridden in the simulation. That is, violations will be determined as if all custom constraints in the overlay were instantiated. Only a single custom_constraint is supported in the overlay at a time. For evaluating multiple constraints, multiple `GenerateOrgPolicyViolationsPreview` requests are made, where each request evaluates a single constraint.", "items": { "$ref": "GoogleCloudPolicysimulatorV1betaOrgPolicyOverlayCustomConstraintOverlay" }, "type": "array" }, "policies": { - "description": "The OrgPolicy changes to preview violations for. Any existing OrgPolicies with the same name will be overridden in the simulation. That is, violations will be determined as if all policies in the overlay were created or updated.", + "description": "Optional. The OrgPolicy changes to preview violations for. Any existing OrgPolicies with the same name will be overridden in the simulation. That is, violations will be determined as if all policies in the overlay were created or updated.", "items": { "$ref": "GoogleCloudPolicysimulatorV1betaOrgPolicyOverlayPolicyOverlay" }, @@ -1969,10 +2002,10 @@ "properties": { "customConstraint": { "$ref": "GoogleCloudOrgpolicyV2CustomConstraint", - "description": "The new or updated custom constraint." + "description": "Optional. The new or updated custom constraint." }, "customConstraintParent": { - "description": "Resource the constraint is attached to. Example: \"organization/987654\"", + "description": "Optional. Resource the constraint is attached to. Example: \"organization/987654\"", "type": "string" } }, @@ -1984,10 +2017,10 @@ "properties": { "policy": { "$ref": "GoogleCloudOrgpolicyV2Policy", - "description": "The new or updated OrgPolicy." + "description": "Optional. The new or updated OrgPolicy." }, "policyParent": { - "description": "The parent of the policy we are attaching to. Example: \"projects/123456\"", + "description": "Optional. The parent of the policy we are attaching to. Example: \"projects/123456\"", "type": "string" } }, @@ -2081,28 +2114,33 @@ "id": "GoogleCloudPolicysimulatorV1betaOrgPolicyViolationsPreviewResourceCounts", "properties": { "compliant": { - "description": "Number of scanned resources with zero violations.", + "description": "Output only. Number of scanned resources with zero violations.", "format": "int32", + "readOnly": true, "type": "integer" }, "errors": { - "description": "Number of resources that returned an error when scanned.", + "description": "Output only. Number of resources that returned an error when scanned.", "format": "int32", + "readOnly": true, "type": "integer" }, "noncompliant": { - "description": "Number of scanned resources with at least one violation.", + "description": "Output only. Number of scanned resources with at least one violation.", "format": "int32", + "readOnly": true, "type": "integer" }, "scanned": { - "description": "Number of resources checked for compliance. Must equal: unenforced + noncompliant + compliant + error", + "description": "Output only. Number of resources checked for compliance. Must equal: unenforced + noncompliant + compliant + error", "format": "int32", + "readOnly": true, "type": "integer" }, "unenforced": { - "description": "Number of resources where the constraint was not enforced, i.e. the Policy set `enforced: false` for that resource.", + "description": "Output only. Number of resources where the constraint was not enforced, i.e. the Policy set `enforced: false` for that resource.", "format": "int32", + "readOnly": true, "type": "integer" } }, @@ -2337,7 +2375,7 @@ "type": "array" }, "role": { - "description": "Role that is assigned to the list of `members`, or principals. For example, `roles/viewer`, `roles/editor`, or `roles/owner`.", + "description": "Role that is assigned to the list of `members`, or principals. For example, `roles/viewer`, `roles/editor`, or `roles/owner`. For an overview of the IAM roles and permissions, see the [IAM documentation](https://cloud.google.com/iam/docs/roles-overview). For a list of the available pre-defined roles, see [here](https://cloud.google.com/iam/docs/understanding-roles).", "type": "string" } }, diff --git a/policysimulator/v1beta/policysimulator-gen.go b/policysimulator/v1beta/policysimulator-gen.go index 467ea9d4f3e..f2dd878daee 100644 --- a/policysimulator/v1beta/policysimulator-gen.go +++ b/policysimulator/v1beta/policysimulator-gen.go @@ -1004,18 +1004,18 @@ func (s *GoogleCloudPolicysimulatorV1alphaGenerateOrgPolicyViolationsPreviewOper // GoogleCloudPolicysimulatorV1alphaOrgPolicyOverlay: The proposed // changes to OrgPolicy. type GoogleCloudPolicysimulatorV1alphaOrgPolicyOverlay struct { - // CustomConstraints: The OrgPolicy CustomConstraint changes to preview - // violations for. Any existing CustomConstraints with the same name - // will be overridden in the simulation. That is, violations will be - // determined as if all custom constraints in the overlay were + // CustomConstraints: Optional. The OrgPolicy CustomConstraint changes + // to preview violations for. Any existing CustomConstraints with the + // same name will be overridden in the simulation. That is, violations + // will be determined as if all custom constraints in the overlay were // instantiated. Only a single custom_constraint is supported in the // overlay at a time. For evaluating multiple constraints, multiple // `GenerateOrgPolicyViolationsPreview` requests are made, where each // request evaluates a single constraint. CustomConstraints []*GoogleCloudPolicysimulatorV1alphaOrgPolicyOverlayCustomConstraintOverlay `json:"customConstraints,omitempty"` - // Policies: The OrgPolicy changes to preview violations for. Any - // existing OrgPolicies with the same name will be overridden in the + // Policies: Optional. The OrgPolicy changes to preview violations for. + // Any existing OrgPolicies with the same name will be overridden in the // simulation. That is, violations will be determined as if all policies // in the overlay were created or updated. Policies []*GoogleCloudPolicysimulatorV1alphaOrgPolicyOverlayPolicyOverlay `json:"policies,omitempty"` @@ -1047,11 +1047,11 @@ func (s *GoogleCloudPolicysimulatorV1alphaOrgPolicyOverlay) MarshalJSON() ([]byt // GoogleCloudPolicysimulatorV1alphaOrgPolicyOverlayCustomConstraintOverl // ay: A change to an OrgPolicy custom constraint. type GoogleCloudPolicysimulatorV1alphaOrgPolicyOverlayCustomConstraintOverlay struct { - // CustomConstraint: The new or updated custom constraint. + // CustomConstraint: Optional. The new or updated custom constraint. CustomConstraint *GoogleCloudOrgpolicyV2CustomConstraint `json:"customConstraint,omitempty"` - // CustomConstraintParent: Resource the constraint is attached to. - // Example: "organization/987654" + // CustomConstraintParent: Optional. Resource the constraint is attached + // to. Example: "organization/987654" CustomConstraintParent string `json:"customConstraintParent,omitempty"` // ForceSendFields is a list of field names (e.g. "CustomConstraint") to @@ -1081,11 +1081,11 @@ func (s *GoogleCloudPolicysimulatorV1alphaOrgPolicyOverlayCustomConstraintOverla // GoogleCloudPolicysimulatorV1alphaOrgPolicyOverlayPolicyOverlay: A // change to an OrgPolicy. type GoogleCloudPolicysimulatorV1alphaOrgPolicyOverlayPolicyOverlay struct { - // Policy: The new or updated OrgPolicy. + // Policy: Optional. The new or updated OrgPolicy. Policy *GoogleCloudOrgpolicyV2Policy `json:"policy,omitempty"` - // PolicyParent: The parent of the policy we are attaching to. Example: - // "projects/123456" + // PolicyParent: Optional. The parent of the policy we are attaching to. + // Example: "projects/123456" PolicyParent string `json:"policyParent,omitempty"` // ForceSendFields is a list of field names (e.g. "Policy") to @@ -1199,22 +1199,25 @@ func (s *GoogleCloudPolicysimulatorV1alphaOrgPolicyViolationsPreview) MarshalJSO // nts: A summary of the state of all resources scanned for compliance // with the changed OrgPolicy. type GoogleCloudPolicysimulatorV1alphaOrgPolicyViolationsPreviewResourceCounts struct { - // Compliant: Number of scanned resources with zero violations. + // Compliant: Output only. Number of scanned resources with zero + // violations. Compliant int64 `json:"compliant,omitempty"` - // Errors: Number of resources that returned an error when scanned. + // Errors: Output only. Number of resources that returned an error when + // scanned. Errors int64 `json:"errors,omitempty"` - // Noncompliant: Number of scanned resources with at least one - // violation. + // Noncompliant: Output only. Number of scanned resources with at least + // one violation. Noncompliant int64 `json:"noncompliant,omitempty"` - // Scanned: Number of resources checked for compliance. Must equal: - // unenforced + noncompliant + compliant + error + // Scanned: Output only. Number of resources checked for compliance. + // Must equal: unenforced + noncompliant + compliant + error Scanned int64 `json:"scanned,omitempty"` - // Unenforced: Number of resources where the constraint was not - // enforced, i.e. the Policy set `enforced: false` for that resource. + // Unenforced: Output only. Number of resources where the constraint was + // not enforced, i.e. the Policy set `enforced: false` for that + // resource. Unenforced int64 `json:"unenforced,omitempty"` // ForceSendFields is a list of field names (e.g. "Compliant") to @@ -1877,18 +1880,18 @@ func (s *GoogleCloudPolicysimulatorV1betaListReplaysResponse) MarshalJSON() ([]b // GoogleCloudPolicysimulatorV1betaOrgPolicyOverlay: The proposed // changes to OrgPolicy. type GoogleCloudPolicysimulatorV1betaOrgPolicyOverlay struct { - // CustomConstraints: The OrgPolicy CustomConstraint changes to preview - // violations for. Any existing CustomConstraints with the same name - // will be overridden in the simulation. That is, violations will be - // determined as if all custom constraints in the overlay were + // CustomConstraints: Optional. The OrgPolicy CustomConstraint changes + // to preview violations for. Any existing CustomConstraints with the + // same name will be overridden in the simulation. That is, violations + // will be determined as if all custom constraints in the overlay were // instantiated. Only a single custom_constraint is supported in the // overlay at a time. For evaluating multiple constraints, multiple // `GenerateOrgPolicyViolationsPreview` requests are made, where each // request evaluates a single constraint. CustomConstraints []*GoogleCloudPolicysimulatorV1betaOrgPolicyOverlayCustomConstraintOverlay `json:"customConstraints,omitempty"` - // Policies: The OrgPolicy changes to preview violations for. Any - // existing OrgPolicies with the same name will be overridden in the + // Policies: Optional. The OrgPolicy changes to preview violations for. + // Any existing OrgPolicies with the same name will be overridden in the // simulation. That is, violations will be determined as if all policies // in the overlay were created or updated. Policies []*GoogleCloudPolicysimulatorV1betaOrgPolicyOverlayPolicyOverlay `json:"policies,omitempty"` @@ -1920,11 +1923,11 @@ func (s *GoogleCloudPolicysimulatorV1betaOrgPolicyOverlay) MarshalJSON() ([]byte // GoogleCloudPolicysimulatorV1betaOrgPolicyOverlayCustomConstraintOverla // y: A change to an OrgPolicy custom constraint. type GoogleCloudPolicysimulatorV1betaOrgPolicyOverlayCustomConstraintOverlay struct { - // CustomConstraint: The new or updated custom constraint. + // CustomConstraint: Optional. The new or updated custom constraint. CustomConstraint *GoogleCloudOrgpolicyV2CustomConstraint `json:"customConstraint,omitempty"` - // CustomConstraintParent: Resource the constraint is attached to. - // Example: "organization/987654" + // CustomConstraintParent: Optional. Resource the constraint is attached + // to. Example: "organization/987654" CustomConstraintParent string `json:"customConstraintParent,omitempty"` // ForceSendFields is a list of field names (e.g. "CustomConstraint") to @@ -1954,11 +1957,11 @@ func (s *GoogleCloudPolicysimulatorV1betaOrgPolicyOverlayCustomConstraintOverlay // GoogleCloudPolicysimulatorV1betaOrgPolicyOverlayPolicyOverlay: A // change to an OrgPolicy. type GoogleCloudPolicysimulatorV1betaOrgPolicyOverlayPolicyOverlay struct { - // Policy: The new or updated OrgPolicy. + // Policy: Optional. The new or updated OrgPolicy. Policy *GoogleCloudOrgpolicyV2Policy `json:"policy,omitempty"` - // PolicyParent: The parent of the policy we are attaching to. Example: - // "projects/123456" + // PolicyParent: Optional. The parent of the policy we are attaching to. + // Example: "projects/123456" PolicyParent string `json:"policyParent,omitempty"` // ForceSendFields is a list of field names (e.g. "Policy") to @@ -2118,22 +2121,25 @@ func (s *GoogleCloudPolicysimulatorV1betaOrgPolicyViolationsPreview) MarshalJSON // ts: A summary of the state of all resources scanned for compliance // with the changed OrgPolicy. type GoogleCloudPolicysimulatorV1betaOrgPolicyViolationsPreviewResourceCounts struct { - // Compliant: Number of scanned resources with zero violations. + // Compliant: Output only. Number of scanned resources with zero + // violations. Compliant int64 `json:"compliant,omitempty"` - // Errors: Number of resources that returned an error when scanned. + // Errors: Output only. Number of resources that returned an error when + // scanned. Errors int64 `json:"errors,omitempty"` - // Noncompliant: Number of scanned resources with at least one - // violation. + // Noncompliant: Output only. Number of scanned resources with at least + // one violation. Noncompliant int64 `json:"noncompliant,omitempty"` - // Scanned: Number of resources checked for compliance. Must equal: - // unenforced + noncompliant + compliant + error + // Scanned: Output only. Number of resources checked for compliance. + // Must equal: unenforced + noncompliant + compliant + error Scanned int64 `json:"scanned,omitempty"` - // Unenforced: Number of resources where the constraint was not - // enforced, i.e. the Policy set `enforced: false` for that resource. + // Unenforced: Output only. Number of resources where the constraint was + // not enforced, i.e. the Policy set `enforced: false` for that + // resource. Unenforced int64 `json:"unenforced,omitempty"` // ForceSendFields is a list of field names (e.g. "Compliant") to @@ -2634,7 +2640,11 @@ type GoogleIamV1Binding struct { Members []string `json:"members,omitempty"` // Role: Role that is assigned to the list of `members`, or principals. - // For example, `roles/viewer`, `roles/editor`, or `roles/owner`. + // For example, `roles/viewer`, `roles/editor`, or `roles/owner`. For an + // overview of the IAM roles and permissions, see the IAM documentation + // (https://cloud.google.com/iam/docs/roles-overview). For a list of the + // available pre-defined roles, see here + // (https://cloud.google.com/iam/docs/understanding-roles). Role string `json:"role,omitempty"` // ForceSendFields is a list of field names (e.g. "Condition") to @@ -4729,6 +4739,154 @@ func (c *OrganizationsLocationsOrgPolicyViolationsPreviewsCall) Do(opts ...googl } +// method id "policysimulator.organizations.locations.orgPolicyViolationsPreviews.generate": + +type OrganizationsLocationsOrgPolicyViolationsPreviewsGenerateCall struct { + s *Service + parent string + googlecloudpolicysimulatorv1betaorgpolicyviolationspreview *GoogleCloudPolicysimulatorV1betaOrgPolicyViolationsPreview + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Generate: GenerateOrgPolicyViolationsPreview generates an +// OrgPolicyViolationsPreview for the proposed changes in the provided +// OrgPolicyViolationsPreview.OrgPolicyOverlay. The changes to OrgPolicy +// are specified by this `OrgPolicyOverlay`. The resources to scan are +// inferred from these specified changes. +// +// - parent: The organization under which this +// OrgPolicyViolationsPreview will be created. Example: +// `organizations/my-example-org/locations/global`. +func (r *OrganizationsLocationsOrgPolicyViolationsPreviewsService) Generate(parent string, googlecloudpolicysimulatorv1betaorgpolicyviolationspreview *GoogleCloudPolicysimulatorV1betaOrgPolicyViolationsPreview) *OrganizationsLocationsOrgPolicyViolationsPreviewsGenerateCall { + c := &OrganizationsLocationsOrgPolicyViolationsPreviewsGenerateCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + c.googlecloudpolicysimulatorv1betaorgpolicyviolationspreview = googlecloudpolicysimulatorv1betaorgpolicyviolationspreview + return c +} + +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse +// for more information. +func (c *OrganizationsLocationsOrgPolicyViolationsPreviewsGenerateCall) Fields(s ...googleapi.Field) *OrganizationsLocationsOrgPolicyViolationsPreviewsGenerateCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. Any +// pending HTTP request will be aborted if the provided context is +// canceled. +func (c *OrganizationsLocationsOrgPolicyViolationsPreviewsGenerateCall) Context(ctx context.Context) *OrganizationsLocationsOrgPolicyViolationsPreviewsGenerateCall { + c.ctx_ = ctx + return c +} + +// Header returns an http.Header that can be modified by the caller to +// add HTTP headers to the request. +func (c *OrganizationsLocationsOrgPolicyViolationsPreviewsGenerateCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *OrganizationsLocationsOrgPolicyViolationsPreviewsGenerateCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := make(http.Header) + reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) + for k, v := range c.header_ { + reqHeaders[k] = v + } + reqHeaders.Set("User-Agent", c.s.userAgent()) + var body io.Reader = nil + body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudpolicysimulatorv1betaorgpolicyviolationspreview) + if err != nil { + return nil, err + } + reqHeaders.Set("Content-Type", "application/json") + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+parent}/orgPolicyViolationsPreviews:generate") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("POST", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "parent": c.parent, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "policysimulator.organizations.locations.orgPolicyViolationsPreviews.generate" call. +// Exactly one of *GoogleLongrunningOperation or error will be non-nil. +// 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 *OrganizationsLocationsOrgPolicyViolationsPreviewsGenerateCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &GoogleLongrunningOperation{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil + // { + // "description": "GenerateOrgPolicyViolationsPreview generates an OrgPolicyViolationsPreview for the proposed changes in the provided OrgPolicyViolationsPreview.OrgPolicyOverlay. The changes to OrgPolicy are specified by this `OrgPolicyOverlay`. The resources to scan are inferred from these specified changes.", + // "flatPath": "v1beta/organizations/{organizationsId}/locations/{locationsId}/orgPolicyViolationsPreviews:generate", + // "httpMethod": "POST", + // "id": "policysimulator.organizations.locations.orgPolicyViolationsPreviews.generate", + // "parameterOrder": [ + // "parent" + // ], + // "parameters": { + // "parent": { + // "description": "Required. The organization under which this OrgPolicyViolationsPreview will be created. Example: `organizations/my-example-org/locations/global`", + // "location": "path", + // "pattern": "^organizations/[^/]+/locations/[^/]+$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1beta/{+parent}/orgPolicyViolationsPreviews:generate", + // "request": { + // "$ref": "GoogleCloudPolicysimulatorV1betaOrgPolicyViolationsPreview" + // }, + // "response": { + // "$ref": "GoogleLongrunningOperation" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + // method id "policysimulator.organizations.locations.orgPolicyViolationsPreviews.get": type OrganizationsLocationsOrgPolicyViolationsPreviewsGetCall struct { @@ -5033,13 +5191,13 @@ func (c *OrganizationsLocationsOrgPolicyViolationsPreviewsListCall) Do(opts ...g // ], // "parameters": { // "pageSize": { - // "description": "The maximum number of items to return. The service may return fewer than this value. If unspecified, at most 5 items will be returned. The maximum value is 10; values above 10 will be coerced to 10.", + // "description": "Optional. The maximum number of items to return. The service may return fewer than this value. If unspecified, at most 5 items will be returned. The maximum value is 10; values above 10 will be coerced to 10.", // "format": "int32", // "location": "query", // "type": "integer" // }, // "pageToken": { - // "description": "A page token, received from a previous call. Provide this to retrieve the subsequent page. When paginating, all other parameters must match the call that provided the page token.", + // "description": "Optional. A page token, received from a previous call. Provide this to retrieve the subsequent page. When paginating, all other parameters must match the call that provided the page token.", // "location": "query", // "type": "string" // }, @@ -5384,13 +5542,13 @@ func (c *OrganizationsLocationsOrgPolicyViolationsPreviewsOrgPolicyViolationsLis // ], // "parameters": { // "pageSize": { - // "description": "The maximum number of items to return. The service may return fewer than this value. If unspecified, at most 50 items will be returned. The maximum value is 1000; values above 1000 will be coerced to 1000.", + // "description": "Optional. The maximum number of items to return. The service may return fewer than this value. If unspecified, at most 50 items will be returned. The maximum value is 1000; values above 1000 will be coerced to 1000.", // "format": "int32", // "location": "query", // "type": "integer" // }, // "pageToken": { - // "description": "A page token, received from a previous call. Provide this to retrieve the subsequent page. When paginating, all other parameters must match the call that provided the page token.", + // "description": "Optional. A page token, received from a previous call. Provide this to retrieve the subsequent page. When paginating, all other parameters must match the call that provided the page token.", // "location": "query", // "type": "string" // }, diff --git a/policytroubleshooter/v1/policytroubleshooter-api.json b/policytroubleshooter/v1/policytroubleshooter-api.json index 9f57f610c83..8d7a132c62d 100644 --- a/policytroubleshooter/v1/policytroubleshooter-api.json +++ b/policytroubleshooter/v1/policytroubleshooter-api.json @@ -128,7 +128,7 @@ } } }, - "revision": "20231217", + "revision": "20240121", "rootUrl": "https://policytroubleshooter.googleapis.com/", "schemas": { "GoogleCloudPolicytroubleshooterV1AccessTuple": { @@ -441,7 +441,7 @@ "type": "array" }, "role": { - "description": "Role that is assigned to the list of `members`, or principals. For example, `roles/viewer`, `roles/editor`, or `roles/owner`.", + "description": "Role that is assigned to the list of `members`, or principals. For example, `roles/viewer`, `roles/editor`, or `roles/owner`. For an overview of the IAM roles and permissions, see the [IAM documentation](https://cloud.google.com/iam/docs/roles-overview). For a list of the available pre-defined roles, see [here](https://cloud.google.com/iam/docs/understanding-roles).", "type": "string" } }, diff --git a/policytroubleshooter/v1/policytroubleshooter-gen.go b/policytroubleshooter/v1/policytroubleshooter-gen.go index 7307e7ca94b..7a5fbdd4204 100644 --- a/policytroubleshooter/v1/policytroubleshooter-gen.go +++ b/policytroubleshooter/v1/policytroubleshooter-gen.go @@ -730,7 +730,11 @@ type GoogleIamV1Binding struct { Members []string `json:"members,omitempty"` // Role: Role that is assigned to the list of `members`, or principals. - // For example, `roles/viewer`, `roles/editor`, or `roles/owner`. + // For example, `roles/viewer`, `roles/editor`, or `roles/owner`. For an + // overview of the IAM roles and permissions, see the IAM documentation + // (https://cloud.google.com/iam/docs/roles-overview). For a list of the + // available pre-defined roles, see here + // (https://cloud.google.com/iam/docs/understanding-roles). Role string `json:"role,omitempty"` // ForceSendFields is a list of field names (e.g. "Condition") to diff --git a/policytroubleshooter/v1beta/policytroubleshooter-api.json b/policytroubleshooter/v1beta/policytroubleshooter-api.json index b40c0901cbd..ad91b77e907 100644 --- a/policytroubleshooter/v1beta/policytroubleshooter-api.json +++ b/policytroubleshooter/v1beta/policytroubleshooter-api.json @@ -128,7 +128,7 @@ } } }, - "revision": "20231217", + "revision": "20240121", "rootUrl": "https://policytroubleshooter.googleapis.com/", "schemas": { "GoogleCloudPolicytroubleshooterV1betaAccessTuple": { @@ -434,7 +434,7 @@ "type": "array" }, "role": { - "description": "Role that is assigned to the list of `members`, or principals. For example, `roles/viewer`, `roles/editor`, or `roles/owner`.", + "description": "Role that is assigned to the list of `members`, or principals. For example, `roles/viewer`, `roles/editor`, or `roles/owner`. For an overview of the IAM roles and permissions, see the [IAM documentation](https://cloud.google.com/iam/docs/roles-overview). For a list of the available pre-defined roles, see [here](https://cloud.google.com/iam/docs/understanding-roles).", "type": "string" } }, diff --git a/policytroubleshooter/v1beta/policytroubleshooter-gen.go b/policytroubleshooter/v1beta/policytroubleshooter-gen.go index 8b2caa41898..ac9ee589bdc 100644 --- a/policytroubleshooter/v1beta/policytroubleshooter-gen.go +++ b/policytroubleshooter/v1beta/policytroubleshooter-gen.go @@ -719,7 +719,11 @@ type GoogleIamV1Binding struct { Members []string `json:"members,omitempty"` // Role: Role that is assigned to the list of `members`, or principals. - // For example, `roles/viewer`, `roles/editor`, or `roles/owner`. + // For example, `roles/viewer`, `roles/editor`, or `roles/owner`. For an + // overview of the IAM roles and permissions, see the IAM documentation + // (https://cloud.google.com/iam/docs/roles-overview). For a list of the + // available pre-defined roles, see here + // (https://cloud.google.com/iam/docs/understanding-roles). Role string `json:"role,omitempty"` // ForceSendFields is a list of field names (e.g. "Condition") to diff --git a/prod_tt_sasportal/v1alpha1/prod_tt_sasportal-api.json b/prod_tt_sasportal/v1alpha1/prod_tt_sasportal-api.json index 2c3493842b9..3976c6c8a52 100644 --- a/prod_tt_sasportal/v1alpha1/prod_tt_sasportal-api.json +++ b/prod_tt_sasportal/v1alpha1/prod_tt_sasportal-api.json @@ -110,22 +110,6 @@ "resources": { "customers": { "methods": { - "checkHasProvisionedDeployment": { - "description": "Checks whether a SAS deployment for the authentication context exists.", - "flatPath": "v1alpha1/customers:checkHasProvisionedDeployment", - "httpMethod": "GET", - "id": "prod_tt_sasportal.customers.checkHasProvisionedDeployment", - "parameterOrder": [], - "parameters": {}, - "path": "v1alpha1/customers:checkHasProvisionedDeployment", - "response": { - "$ref": "SasPortalCheckHasProvisionedDeploymentResponse" - }, - "scopes": [ - "https://www.googleapis.com/auth/cloud-platform", - "https://www.googleapis.com/auth/sasportal" - ] - }, "get": { "description": "Returns a requested customer.", "flatPath": "v1alpha1/customers/{customersId}", @@ -2669,7 +2653,7 @@ } } }, - "revision": "20240115", + "revision": "20240120", "rootUrl": "https://prod-tt-sasportal.googleapis.com/", "schemas": { "SasPortalAssignment": { @@ -2706,17 +2690,6 @@ }, "type": "object" }, - "SasPortalCheckHasProvisionedDeploymentResponse": { - "description": "Response for [CheckHasProvisionedDeployment]. [spectrum.sas.portal.v1alpha1.Provisioning.CheckHasProvisionedDeployment].", - "id": "SasPortalCheckHasProvisionedDeploymentResponse", - "properties": { - "hasProvisionedDeployment": { - "description": "Whether a SAS deployment for the authentication context exists.", - "type": "boolean" - } - }, - "type": "object" - }, "SasPortalCreateSignedDeviceRequest": { "description": "Request for CreateSignedDevice.", "id": "SasPortalCreateSignedDeviceRequest", diff --git a/prod_tt_sasportal/v1alpha1/prod_tt_sasportal-gen.go b/prod_tt_sasportal/v1alpha1/prod_tt_sasportal-gen.go index e35fa4e2f66..45ff0267275 100644 --- a/prod_tt_sasportal/v1alpha1/prod_tt_sasportal-gen.go +++ b/prod_tt_sasportal/v1alpha1/prod_tt_sasportal-gen.go @@ -482,44 +482,6 @@ func (s *SasPortalChannelWithScore) UnmarshalJSON(data []byte) error { return nil } -// SasPortalCheckHasProvisionedDeploymentResponse: Response for -// [CheckHasProvisionedDeployment]. -// [spectrum.sas.portal.v1alpha1.Provisioning.CheckHasProvisionedDeployme -// nt]. -type SasPortalCheckHasProvisionedDeploymentResponse struct { - // HasProvisionedDeployment: Whether a SAS deployment for the - // authentication context exists. - HasProvisionedDeployment bool `json:"hasProvisionedDeployment,omitempty"` - - // ServerResponse contains the HTTP response code and headers from the - // server. - googleapi.ServerResponse `json:"-"` - - // ForceSendFields is a list of field names (e.g. - // "HasProvisionedDeployment") to unconditionally include in API - // requests. By default, fields with empty or default values are omitted - // from API requests. However, any non-pointer, non-interface field - // appearing in ForceSendFields will be sent to the server regardless of - // whether the field is empty or not. This may be used to include empty - // fields in Patch requests. - ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "HasProvisionedDeployment") - // to include in API requests with the JSON null value. By default, - // fields with empty values are omitted from API requests. However, any - // field with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. - NullFields []string `json:"-"` -} - -func (s *SasPortalCheckHasProvisionedDeploymentResponse) MarshalJSON() ([]byte, error) { - type NoMethod SasPortalCheckHasProvisionedDeploymentResponse - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) -} - // SasPortalCreateSignedDeviceRequest: Request for CreateSignedDevice. type SasPortalCreateSignedDeviceRequest struct { // EncodedDevice: Required. JSON Web Token signed using a CPI private @@ -2381,139 +2343,6 @@ type SasPortalValidateInstallerResponse struct { googleapi.ServerResponse `json:"-"` } -// method id "prod_tt_sasportal.customers.checkHasProvisionedDeployment": - -type CustomersCheckHasProvisionedDeploymentCall struct { - s *Service - urlParams_ gensupport.URLParams - ifNoneMatch_ string - ctx_ context.Context - header_ http.Header -} - -// CheckHasProvisionedDeployment: Checks whether a SAS deployment for -// the authentication context exists. -func (r *CustomersService) CheckHasProvisionedDeployment() *CustomersCheckHasProvisionedDeploymentCall { - c := &CustomersCheckHasProvisionedDeploymentCall{s: r.s, urlParams_: make(gensupport.URLParams)} - return c -} - -// Fields allows partial responses to be retrieved. See -// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse -// for more information. -func (c *CustomersCheckHasProvisionedDeploymentCall) Fields(s ...googleapi.Field) *CustomersCheckHasProvisionedDeploymentCall { - c.urlParams_.Set("fields", googleapi.CombineFields(s)) - return c -} - -// IfNoneMatch sets the 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. Use googleapi.IsNotModified to check whether the response -// error from Do is the result of In-None-Match. -func (c *CustomersCheckHasProvisionedDeploymentCall) IfNoneMatch(entityTag string) *CustomersCheckHasProvisionedDeploymentCall { - c.ifNoneMatch_ = entityTag - return c -} - -// Context sets the context to be used in this call's Do method. Any -// pending HTTP request will be aborted if the provided context is -// canceled. -func (c *CustomersCheckHasProvisionedDeploymentCall) Context(ctx context.Context) *CustomersCheckHasProvisionedDeploymentCall { - c.ctx_ = ctx - return c -} - -// Header returns an http.Header that can be modified by the caller to -// add HTTP headers to the request. -func (c *CustomersCheckHasProvisionedDeploymentCall) Header() http.Header { - if c.header_ == nil { - c.header_ = make(http.Header) - } - return c.header_ -} - -func (c *CustomersCheckHasProvisionedDeploymentCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := make(http.Header) - reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) - for k, v := range c.header_ { - reqHeaders[k] = v - } - reqHeaders.Set("User-Agent", c.s.userAgent()) - if c.ifNoneMatch_ != "" { - reqHeaders.Set("If-None-Match", c.ifNoneMatch_) - } - var body io.Reader = nil - c.urlParams_.Set("alt", alt) - c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha1/customers:checkHasProvisionedDeployment") - urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("GET", urls, body) - if err != nil { - return nil, err - } - req.Header = reqHeaders - return gensupport.SendRequest(c.ctx_, c.s.client, req) -} - -// Do executes the "prod_tt_sasportal.customers.checkHasProvisionedDeployment" call. -// Exactly one of *SasPortalCheckHasProvisionedDeploymentResponse or -// error will be non-nil. Any non-2xx status code is an error. Response -// headers are in either -// *SasPortalCheckHasProvisionedDeploymentResponse.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 *CustomersCheckHasProvisionedDeploymentCall) Do(opts ...googleapi.CallOption) (*SasPortalCheckHasProvisionedDeploymentResponse, 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 := &SasPortalCheckHasProvisionedDeploymentResponse{ - ServerResponse: googleapi.ServerResponse{ - Header: res.Header, - HTTPStatusCode: res.StatusCode, - }, - } - target := &ret - if err := gensupport.DecodeResponse(target, res); err != nil { - return nil, err - } - return ret, nil - // { - // "description": "Checks whether a SAS deployment for the authentication context exists.", - // "flatPath": "v1alpha1/customers:checkHasProvisionedDeployment", - // "httpMethod": "GET", - // "id": "prod_tt_sasportal.customers.checkHasProvisionedDeployment", - // "parameterOrder": [], - // "parameters": {}, - // "path": "v1alpha1/customers:checkHasProvisionedDeployment", - // "response": { - // "$ref": "SasPortalCheckHasProvisionedDeploymentResponse" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform", - // "https://www.googleapis.com/auth/sasportal" - // ] - // } - -} - // method id "prod_tt_sasportal.customers.get": type CustomersGetCall struct { diff --git a/recommender/v1/recommender-api.json b/recommender/v1/recommender-api.json index ce7aa8297b6..6df1032dbad 100644 --- a/recommender/v1/recommender-api.json +++ b/recommender/v1/recommender-api.json @@ -1686,7 +1686,7 @@ } } }, - "revision": "20231203", + "revision": "20240121", "rootUrl": "https://recommender.googleapis.com/", "schemas": { "GoogleCloudRecommenderV1CostProjection": { @@ -2204,6 +2204,13 @@ "$ref": "GoogleCloudRecommenderV1RecommendationStateInfo", "description": "Information for state. Contains state and metadata." }, + "targetResources": { + "description": "Fully qualified resource names that this recommendation is targeting.", + "items": { + "type": "string" + }, + "type": "array" + }, "xorGroupId": { "description": "Corresponds to a mutually exclusive group ID within a recommender. A non-empty ID indicates that the recommendation belongs to a mutually exclusive group. This means that only one recommendation within the group is suggested to be applied.", "type": "string" diff --git a/recommender/v1/recommender-gen.go b/recommender/v1/recommender-gen.go index 2d5fa2e72ff..d23857e41d9 100644 --- a/recommender/v1/recommender-gen.go +++ b/recommender/v1/recommender-gen.go @@ -1233,6 +1233,10 @@ type GoogleCloudRecommenderV1Recommendation struct { // StateInfo: Information for state. Contains state and metadata. StateInfo *GoogleCloudRecommenderV1RecommendationStateInfo `json:"stateInfo,omitempty"` + // TargetResources: Fully qualified resource names that this + // recommendation is targeting. + TargetResources []string `json:"targetResources,omitempty"` + // XorGroupId: Corresponds to a mutually exclusive group ID within a // recommender. A non-empty ID indicates that the recommendation belongs // to a mutually exclusive group. This means that only one diff --git a/securitycenter/v1/securitycenter-api.json b/securitycenter/v1/securitycenter-api.json index 6568d1d01b2..75186448894 100644 --- a/securitycenter/v1/securitycenter-api.json +++ b/securitycenter/v1/securitycenter-api.json @@ -3483,6 +3483,11 @@ "location": "query", "type": "string" }, + "orderBy": { + "description": "Optional. The fields by which to order the valued resources response. Supported fields: * `exposed_score` * `resource_value` * `resource_type` * `resource` * `display_name` Values should be a comma separated list of fields. For example: `exposed_score,resource_value`. The default sorting order is descending. To specify ascending or descending order for a field, append a \" ASC\" or a \" DESC\" suffix, respectively; for example: `exposed_score DESC`.", + "location": "query", + "type": "string" + }, "pageSize": { "description": "The maximum number of results to return in a single response. Default is 10, minimum is 1, maximum is 1000.", "format": "int32", @@ -3600,6 +3605,11 @@ "location": "query", "type": "string" }, + "orderBy": { + "description": "Optional. The fields by which to order the valued resources response. Supported fields: * `exposed_score` * `resource_value` * `resource_type` * `resource` * `display_name` Values should be a comma separated list of fields. For example: `exposed_score,resource_value`. The default sorting order is descending. To specify ascending or descending order for a field, append a \" ASC\" or a \" DESC\" suffix, respectively; for example: `exposed_score DESC`.", + "location": "query", + "type": "string" + }, "pageSize": { "description": "The maximum number of results to return in a single response. Default is 10, minimum is 1, maximum is 1000.", "format": "int32", @@ -5810,7 +5820,7 @@ } } }, - "revision": "20240117", + "revision": "20240119", "rootUrl": "https://securitycenter.googleapis.com/", "schemas": { "Access": { @@ -6316,7 +6326,7 @@ "type": "array" }, "role": { - "description": "Role that is assigned to the list of `members`, or principals. For example, `roles/viewer`, `roles/editor`, or `roles/owner`.", + "description": "Role that is assigned to the list of `members`, or principals. For example, `roles/viewer`, `roles/editor`, or `roles/owner`. For an overview of the IAM roles and permissions, see the [IAM documentation](https://cloud.google.com/iam/docs/roles-overview). For a list of the available pre-defined roles, see [here](https://cloud.google.com/iam/docs/understanding-roles).", "type": "string" } }, diff --git a/securitycenter/v1/securitycenter-gen.go b/securitycenter/v1/securitycenter-gen.go index a6a9d94421a..378ce0ec6fd 100644 --- a/securitycenter/v1/securitycenter-gen.go +++ b/securitycenter/v1/securitycenter-gen.go @@ -1740,7 +1740,11 @@ type Binding struct { Members []string `json:"members,omitempty"` // Role: Role that is assigned to the list of `members`, or principals. - // For example, `roles/viewer`, `roles/editor`, or `roles/owner`. + // For example, `roles/viewer`, `roles/editor`, or `roles/owner`. For an + // overview of the IAM roles and permissions, see the IAM documentation + // (https://cloud.google.com/iam/docs/roles-overview). For a list of the + // available pre-defined roles, see here + // (https://cloud.google.com/iam/docs/understanding-roles). Role string `json:"role,omitempty"` // ForceSendFields is a list of field names (e.g. "Condition") to @@ -25379,6 +25383,19 @@ func (c *OrganizationsSimulationsAttackExposureResultsValuedResourcesListCall) F return c } +// OrderBy sets the optional parameter "orderBy": The fields by which to +// order the valued resources response. Supported fields: * +// `exposed_score` * `resource_value` * `resource_type` * `resource` * +// `display_name` Values should be a comma separated list of fields. For +// example: `exposed_score,resource_value`. The default sorting order is +// descending. To specify ascending or descending order for a field, +// append a " ASC" or a " DESC" suffix, respectively; for example: +// `exposed_score DESC`. +func (c *OrganizationsSimulationsAttackExposureResultsValuedResourcesListCall) OrderBy(orderBy string) *OrganizationsSimulationsAttackExposureResultsValuedResourcesListCall { + c.urlParams_.Set("orderBy", orderBy) + return c +} + // PageSize sets the optional parameter "pageSize": The maximum number // of results to return in a single response. Default is 10, minimum is // 1, maximum is 1000. @@ -25508,6 +25525,11 @@ func (c *OrganizationsSimulationsAttackExposureResultsValuedResourcesListCall) D // "location": "query", // "type": "string" // }, + // "orderBy": { + // "description": "Optional. The fields by which to order the valued resources response. Supported fields: * `exposed_score` * `resource_value` * `resource_type` * `resource` * `display_name` Values should be a comma separated list of fields. For example: `exposed_score,resource_value`. The default sorting order is descending. To specify ascending or descending order for a field, append a \" ASC\" or a \" DESC\" suffix, respectively; for example: `exposed_score DESC`.", + // "location": "query", + // "type": "string" + // }, // "pageSize": { // "description": "The maximum number of results to return in a single response. Default is 10, minimum is 1, maximum is 1000.", // "format": "int32", @@ -25955,6 +25977,19 @@ func (c *OrganizationsSimulationsValuedResourcesListCall) Filter(filter string) return c } +// OrderBy sets the optional parameter "orderBy": The fields by which to +// order the valued resources response. Supported fields: * +// `exposed_score` * `resource_value` * `resource_type` * `resource` * +// `display_name` Values should be a comma separated list of fields. For +// example: `exposed_score,resource_value`. The default sorting order is +// descending. To specify ascending or descending order for a field, +// append a " ASC" or a " DESC" suffix, respectively; for example: +// `exposed_score DESC`. +func (c *OrganizationsSimulationsValuedResourcesListCall) OrderBy(orderBy string) *OrganizationsSimulationsValuedResourcesListCall { + c.urlParams_.Set("orderBy", orderBy) + return c +} + // PageSize sets the optional parameter "pageSize": The maximum number // of results to return in a single response. Default is 10, minimum is // 1, maximum is 1000. @@ -26084,6 +26119,11 @@ func (c *OrganizationsSimulationsValuedResourcesListCall) Do(opts ...googleapi.C // "location": "query", // "type": "string" // }, + // "orderBy": { + // "description": "Optional. The fields by which to order the valued resources response. Supported fields: * `exposed_score` * `resource_value` * `resource_type` * `resource` * `display_name` Values should be a comma separated list of fields. For example: `exposed_score,resource_value`. The default sorting order is descending. To specify ascending or descending order for a field, append a \" ASC\" or a \" DESC\" suffix, respectively; for example: `exposed_score DESC`.", + // "location": "query", + // "type": "string" + // }, // "pageSize": { // "description": "The maximum number of results to return in a single response. Default is 10, minimum is 1, maximum is 1000.", // "format": "int32", diff --git a/securitycenter/v1beta1/securitycenter-api.json b/securitycenter/v1beta1/securitycenter-api.json index ebe5e65d036..0d9cd1860c1 100644 --- a/securitycenter/v1beta1/securitycenter-api.json +++ b/securitycenter/v1beta1/securitycenter-api.json @@ -896,7 +896,7 @@ } } }, - "revision": "20240117", + "revision": "20240119", "rootUrl": "https://securitycenter.googleapis.com/", "schemas": { "Access": { @@ -1238,7 +1238,7 @@ "type": "array" }, "role": { - "description": "Role that is assigned to the list of `members`, or principals. For example, `roles/viewer`, `roles/editor`, or `roles/owner`.", + "description": "Role that is assigned to the list of `members`, or principals. For example, `roles/viewer`, `roles/editor`, or `roles/owner`. For an overview of the IAM roles and permissions, see the [IAM documentation](https://cloud.google.com/iam/docs/roles-overview). For a list of the available pre-defined roles, see [here](https://cloud.google.com/iam/docs/understanding-roles).", "type": "string" } }, diff --git a/securitycenter/v1beta1/securitycenter-gen.go b/securitycenter/v1beta1/securitycenter-gen.go index 9771454b978..d348cfaa2de 100644 --- a/securitycenter/v1beta1/securitycenter-gen.go +++ b/securitycenter/v1beta1/securitycenter-gen.go @@ -832,7 +832,11 @@ type Binding struct { Members []string `json:"members,omitempty"` // Role: Role that is assigned to the list of `members`, or principals. - // For example, `roles/viewer`, `roles/editor`, or `roles/owner`. + // For example, `roles/viewer`, `roles/editor`, or `roles/owner`. For an + // overview of the IAM roles and permissions, see the IAM documentation + // (https://cloud.google.com/iam/docs/roles-overview). For a list of the + // available pre-defined roles, see here + // (https://cloud.google.com/iam/docs/understanding-roles). Role string `json:"role,omitempty"` // ForceSendFields is a list of field names (e.g. "Condition") to