diff --git a/androidpublisher/v3/androidpublisher-api.json b/androidpublisher/v3/androidpublisher-api.json index 2c15c5ebbc..bcc8e3f8ad 100644 --- a/androidpublisher/v3/androidpublisher-api.json +++ b/androidpublisher/v3/androidpublisher-api.json @@ -4732,7 +4732,7 @@ } } }, - "revision": "20241216", + "revision": "20241217", "rootUrl": "https://androidpublisher.googleapis.com/", "schemas": { "Abi": { @@ -5249,7 +5249,7 @@ "id": "AutoRenewingBasePlanType", "properties": { "accountHoldDuration": { - "description": "Optional. Account hold period of the subscription, specified in ISO 8601 format. Acceptable values must be in DAYS and in the range P0D (zero days) to P30D (30 days). If not specified, the default value is P30D (30 days).", + "description": "Optional. Account hold period of the subscription, specified in ISO 8601 format. Acceptable values must be in days and between P0D and P60D. If not specified, the default value is P30D. The sum of gracePeriodDuration and accountHoldDuration must be between P30D and P60D days, inclusive.", "type": "string" }, "billingPeriodDuration": { @@ -5257,7 +5257,7 @@ "type": "string" }, "gracePeriodDuration": { - "description": "Grace period of the subscription, specified in ISO 8601 format. Acceptable values are P0D (zero days), P3D (3 days), P7D (7 days), P14D (14 days), and P30D (30 days). If not specified, a default value will be used based on the recurring period duration.", + "description": "Grace period of the subscription, specified in ISO 8601 format. Acceptable values must be in days and between P0D and the lesser of 30D and base plan billing period. If not specified, a default value will be used based on the billing period. The sum of gracePeriodDuration and accountHoldDuration must be between P30D and P60D days, inclusive.", "type": "string" }, "legacyCompatible": { @@ -7077,7 +7077,7 @@ "id": "InstallmentsBasePlanType", "properties": { "accountHoldDuration": { - "description": "Optional. Account hold period of the subscription, specified exclusively in days and in ISO 8601 format. Acceptable values are P0D (zero days) to P30D (30days). If not specified, the default value is P30D (30 days).", + "description": "Optional. Account hold period of the subscription, specified in ISO 8601 format. Acceptable values must be in days and between P0D and P60D. If not specified, the default value is P30D. The sum of gracePeriodDuration and accountHoldDuration must be between P30D and P60D days, inclusive.", "type": "string" }, "billingPeriodDuration": { @@ -7090,7 +7090,7 @@ "type": "integer" }, "gracePeriodDuration": { - "description": "Grace period of the subscription, specified in ISO 8601 format. Acceptable values are P0D (zero days), P3D (3 days), P7D (7 days), P14D (14 days), and P30D (30 days). If not specified, a default value will be used based on the recurring period duration.", + "description": "Grace period of the subscription, specified in ISO 8601 format. Acceptable values must be in days and between P0D and the lesser of 30D and base plan billing period. If not specified, a default value will be used based on the billing period. The sum of gracePeriodDuration and accountHoldDuration must be between P30D and P60D days, inclusive.", "type": "string" }, "prorationMode": { diff --git a/androidpublisher/v3/androidpublisher-gen.go b/androidpublisher/v3/androidpublisher-gen.go index 669e26f02f..d76c731afd 100644 --- a/androidpublisher/v3/androidpublisher-gen.go +++ b/androidpublisher/v3/androidpublisher-gen.go @@ -1244,18 +1244,20 @@ func (s AssetSliceSet) MarshalJSON() ([]byte, error) { // at the end of its subscription period. type AutoRenewingBasePlanType struct { // AccountHoldDuration: Optional. Account hold period of the subscription, - // specified in ISO 8601 format. Acceptable values must be in DAYS and in the - // range P0D (zero days) to P30D (30 days). If not specified, the default value - // is P30D (30 days). + // specified in ISO 8601 format. Acceptable values must be in days and between + // P0D and P60D. If not specified, the default value is P30D. The sum of + // gracePeriodDuration and accountHoldDuration must be between P30D and P60D + // days, inclusive. AccountHoldDuration string `json:"accountHoldDuration,omitempty"` // BillingPeriodDuration: Required. Immutable. Subscription period, specified // in ISO 8601 format. For a list of acceptable billing periods, refer to the // help center. The duration is immutable after the base plan is created. BillingPeriodDuration string `json:"billingPeriodDuration,omitempty"` // GracePeriodDuration: Grace period of the subscription, specified in ISO 8601 - // format. Acceptable values are P0D (zero days), P3D (3 days), P7D (7 days), - // P14D (14 days), and P30D (30 days). If not specified, a default value will - // be used based on the recurring period duration. + // format. Acceptable values must be in days and between P0D and the lesser of + // 30D and base plan billing period. If not specified, a default value will be + // used based on the billing period. The sum of gracePeriodDuration and + // accountHoldDuration must be between P30D and P60D days, inclusive. GracePeriodDuration string `json:"gracePeriodDuration,omitempty"` // LegacyCompatible: Whether the renewing base plan is backward compatible. The // backward compatible base plan is returned by the Google Play Billing Library @@ -3628,9 +3630,10 @@ func (s InstallmentPlan) MarshalJSON() ([]byte, error) { // commits to a specified number of payments. type InstallmentsBasePlanType struct { // AccountHoldDuration: Optional. Account hold period of the subscription, - // specified exclusively in days and in ISO 8601 format. Acceptable values are - // P0D (zero days) to P30D (30days). If not specified, the default value is - // P30D (30 days). + // specified in ISO 8601 format. Acceptable values must be in days and between + // P0D and P60D. If not specified, the default value is P30D. The sum of + // gracePeriodDuration and accountHoldDuration must be between P30D and P60D + // days, inclusive. AccountHoldDuration string `json:"accountHoldDuration,omitempty"` // BillingPeriodDuration: Required. Immutable. Subscription period, specified // in ISO 8601 format. For a list of acceptable billing periods, refer to the @@ -3640,9 +3643,10 @@ type InstallmentsBasePlanType struct { // is committed to. It is immutable after the base plan is created. CommittedPaymentsCount int64 `json:"committedPaymentsCount,omitempty"` // GracePeriodDuration: Grace period of the subscription, specified in ISO 8601 - // format. Acceptable values are P0D (zero days), P3D (3 days), P7D (7 days), - // P14D (14 days), and P30D (30 days). If not specified, a default value will - // be used based on the recurring period duration. + // format. Acceptable values must be in days and between P0D and the lesser of + // 30D and base plan billing period. If not specified, a default value will be + // used based on the billing period. The sum of gracePeriodDuration and + // accountHoldDuration must be between P30D and P60D days, inclusive. GracePeriodDuration string `json:"gracePeriodDuration,omitempty"` // ProrationMode: The proration mode for the base plan determines what happens // when a user switches to this plan from another base plan. If unspecified, diff --git a/areainsights/v1/areainsights-api.json b/areainsights/v1/areainsights-api.json new file mode 100644 index 0000000000..b59455ae10 --- /dev/null +++ b/areainsights/v1/areainsights-api.json @@ -0,0 +1,402 @@ +{ + "auth": { + "oauth2": { + "scopes": { + "https://www.googleapis.com/auth/cloud-platform": { + "description": "See, edit, configure, and delete your Google Cloud data and see the email address for your Google Account." + } + } + } + }, + "basePath": "", + "baseUrl": "https://areainsights.googleapis.com/", + "batchPath": "batch", + "canonicalName": "Area Insights", + "description": "Places Insights API.", + "discoveryVersion": "v1", + "documentationLink": "https://g3doc.corp.google.com/geo/platform/area_insights/README.md?cl=head", + "fullyEncodeReservedExpansion": true, + "icons": { + "x16": "http://www.google.com/images/icons/product/search-16.gif", + "x32": "http://www.google.com/images/icons/product/search-32.gif" + }, + "id": "areainsights:v1", + "kind": "discovery#restDescription", + "mtlsRootUrl": "https://areainsights.mtls.googleapis.com/", + "name": "areainsights", + "ownerDomain": "google.com", + "ownerName": "Google", + "parameters": { + "$.xgafv": { + "description": "V1 error format.", + "enum": [ + "1", + "2" + ], + "enumDescriptions": [ + "v1 error format", + "v2 error format" + ], + "location": "query", + "type": "string" + }, + "access_token": { + "description": "OAuth access token.", + "location": "query", + "type": "string" + }, + "alt": { + "default": "json", + "description": "Data format for response.", + "enum": [ + "json", + "media", + "proto" + ], + "enumDescriptions": [ + "Responses with Content-Type of application/json", + "Media download with context-dependent Content-Type", + "Responses with Content-Type of application/x-protobuf" + ], + "location": "query", + "type": "string" + }, + "callback": { + "description": "JSONP", + "location": "query", + "type": "string" + }, + "fields": { + "description": "Selector specifying which fields to include in a partial response.", + "location": "query", + "type": "string" + }, + "key": { + "description": "API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token.", + "location": "query", + "type": "string" + }, + "oauth_token": { + "description": "OAuth 2.0 token for the current user.", + "location": "query", + "type": "string" + }, + "prettyPrint": { + "default": "true", + "description": "Returns response with indentations and line breaks.", + "location": "query", + "type": "boolean" + }, + "quotaUser": { + "description": "Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.", + "location": "query", + "type": "string" + }, + "uploadType": { + "description": "Legacy upload protocol for media (e.g. \"media\", \"multipart\").", + "location": "query", + "type": "string" + }, + "upload_protocol": { + "description": "Upload protocol for media (e.g. \"raw\", \"multipart\").", + "location": "query", + "type": "string" + } + }, + "protocol": "rest", + "resources": { + "v1": { + "methods": { + "computeInsights": { + "description": "Compute Insights RPC This method lets you retrieve insights about areas using a variaty of filter such as: area, place type, operating status, price level and ratings. Currently \"count\" and \"places\" insights are supported. With \"count\" insights you can answer questions such as \"How many restaurant are located in California that are operational, are inexpensive and have an average rating of at least 4 stars\" (see `insight` enum for more details). With \"places\" insights, you can determine which places match the requested filter. Clients can then use those place resource names to fetch more details about each individual place using the Places API.", + "flatPath": "v1:computeInsights", + "httpMethod": "POST", + "id": "areainsights.computeInsights", + "parameterOrder": [], + "parameters": {}, + "path": "v1:computeInsights", + "request": { + "$ref": "ComputeInsightsRequest" + }, + "response": { + "$ref": "ComputeInsightsResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + } + } + } + }, + "revision": "20241211", + "rootUrl": "https://areainsights.googleapis.com/", + "schemas": { + "Circle": { + "description": "A circle is defined by a center point and radius in meters.", + "id": "Circle", + "properties": { + "latLng": { + "$ref": "LatLng", + "description": "The latitude and longitude of the center of the circle." + }, + "place": { + "description": "The Place resource name of the center of the circle. Only point places are supported.", + "type": "string" + }, + "radius": { + "description": "Optional. The radius of the circle in meters", + "format": "int32", + "type": "integer" + } + }, + "type": "object" + }, + "ComputeInsightsRequest": { + "description": "Request for the ComputeInsights RPC.", + "id": "ComputeInsightsRequest", + "properties": { + "filter": { + "$ref": "Filter", + "description": "Required. Insight filter." + }, + "insights": { + "description": "Required. Insights to compute. Currently only INSIGHT_COUNT and INSIGHT_PLACES are supported.", + "items": { + "enum": [ + "INSIGHT_UNSPECIFIED", + "INSIGHT_COUNT", + "INSIGHT_PLACES" + ], + "enumDescriptions": [ + "Not Specified.", + "Count insight. When this insight is specified ComputeInsights returns the number of places that match the specified filter criteria. ``` For example if the request is: ComputeInsightsRequest { insights: INSIGHT_COUNT filter { location_filter {region: } type_filter {included_types: \"restaurant\"} operating_status: OPERATING_STATUS_OPERATIONAL price_levels: PRICE_LEVEL_FREE price_levels: PRICE_LEVEL_INEXPENSIVE min_rating: 4.0 } } The method will return the count of restaurants in California that are operational, with price level free or inexpensive and have an average rating of at least 4 starts. Example response: ComputeInsightsResponse { count: } ```", + "Return Places When this insight is specified ComputeInsights returns Places that match the specified filter criteria. ``` For example if the request is: ComputeInsightsRequest { insights: INSIGHT_PLACES filter { location_filter {region: } type_filter {included_types: \"restaurant\"} operating_status: OPERATING_STATUS_OPERATIONAL price_levels: PRICE_LEVEL_FREE price_levels: PRICE_LEVEL_INEXPENSIVE min_rating: 4.0 } } The method will return list of places of restaurants in California that are operational, with price level free or inexpensive and have an average rating of at least 4 stars. Example response: ComputeInsightsResponse { place_insights { place: \"places/ABC\" } place_insights { place: \"places/PQR\" } place_insights { place: \"places/XYZ\" } } ```" + ], + "type": "string" + }, + "type": "array" + } + }, + "type": "object" + }, + "ComputeInsightsResponse": { + "description": "Response for the ComputeInsights RPC.", + "id": "ComputeInsightsResponse", + "properties": { + "count": { + "description": "Result for Insights.INSIGHT_COUNT.", + "format": "int64", + "type": "string" + }, + "placeInsights": { + "description": "Result for Insights.INSIGHT_PLACES.", + "items": { + "$ref": "PlaceInsight" + }, + "type": "array" + } + }, + "type": "object" + }, + "CustomArea": { + "description": "Custom Area.", + "id": "CustomArea", + "properties": { + "polygon": { + "$ref": "Polygon", + "description": "Required. The custom area represented as a polygon" + } + }, + "type": "object" + }, + "Filter": { + "description": "Filters for the ComputeInsights RPC.", + "id": "Filter", + "properties": { + "locationFilter": { + "$ref": "LocationFilter", + "description": "Required. Restricts results to places which are located in the area specified by location filters." + }, + "operatingStatus": { + "description": "Optional. Restricts results to places whose operating status is included on this list. If operating_status is not set, OPERATING_STATUS_OPERATIONAL is used as default.", + "items": { + "enum": [ + "OPERATING_STATUS_UNSPECIFIED", + "OPERATING_STATUS_OPERATIONAL", + "OPERATING_STATUS_PERMANENTLY_CLOSED", + "OPERATING_STATUS_TEMPORARILY_CLOSED" + ], + "enumDescriptions": [ + "Not Specified.", + "The place is operational and its open during its defined hours.", + "The Place is no longer in business.", + "The Place is temporarily closed and expected to reopen in the future." + ], + "type": "string" + }, + "type": "array" + }, + "priceLevels": { + "description": "Optional. Restricts results to places whose price level is included on this list. If price_level is not set, all price levels are included in the results.", + "items": { + "enum": [ + "PRICE_LEVEL_UNSPECIFIED", + "PRICE_LEVEL_FREE", + "PRICE_LEVEL_INEXPENSIVE", + "PRICE_LEVEL_MODERATE", + "PRICE_LEVEL_EXPENSIVE", + "PRICE_LEVEL_VERY_EXPENSIVE" + ], + "enumDescriptions": [ + "Place price level is unspecified or unknown.", + "Place provides free services.", + "Place provides inexpensive services.", + "Place provides moderately priced services.", + "Place provides expensive services.", + "Place provides very expensive services." + ], + "type": "string" + }, + "type": "array" + }, + "ratingFilter": { + "$ref": "RatingFilter", + "description": "Optional. Restricts results to places whose average user ratings are in the range specified by rating_filter. If rating_filter is not set, all ratings are included in the result." + }, + "typeFilter": { + "$ref": "TypeFilter", + "description": "Required. Place type filters." + } + }, + "type": "object" + }, + "LatLng": { + "description": "An object that represents a latitude/longitude pair. This is expressed as a pair of doubles to represent degrees latitude and degrees longitude. Unless specified otherwise, this object must conform to the WGS84 standard. Values must be within normalized ranges.", + "id": "LatLng", + "properties": { + "latitude": { + "description": "The latitude in degrees. It must be in the range [-90.0, +90.0].", + "format": "double", + "type": "number" + }, + "longitude": { + "description": "The longitude in degrees. It must be in the range [-180.0, +180.0].", + "format": "double", + "type": "number" + } + }, + "type": "object" + }, + "LocationFilter": { + "description": "Location filters. Specifies the area of interest for the insight.", + "id": "LocationFilter", + "properties": { + "circle": { + "$ref": "Circle", + "description": "Area as a circle." + }, + "customArea": { + "$ref": "CustomArea", + "description": "Custom area specified by a polygon." + }, + "region": { + "$ref": "Region", + "description": "Area as region." + } + }, + "type": "object" + }, + "PlaceInsight": { + "description": "Holds information about a place", + "id": "PlaceInsight", + "properties": { + "place": { + "description": "The unique identifier of the place. This resource name can be used to retrieve details about the place using the [Places API](https://developers.google.com/maps/documentation/places/web-service/reference/rest/v1/places/get).", + "type": "string" + } + }, + "type": "object" + }, + "Polygon": { + "description": "A polygon is represented by a series of connected coordinates in an counterclockwise ordered sequence. The coordinates form a closed loop and define a filled region. The first and last coordinates are equivalent, and they must contain identical values. The format is a simplified version of GeoJSON polygons (we only support one counterclockwise exterior ring).", + "id": "Polygon", + "properties": { + "coordinates": { + "description": "Optional. The coordinates that define the polygon.", + "items": { + "$ref": "LatLng" + }, + "type": "array" + } + }, + "type": "object" + }, + "RatingFilter": { + "description": "Average user rating filters.", + "id": "RatingFilter", + "properties": { + "maxRating": { + "description": "Optional. Restricts results to places whose average user rating is strictly less than or equal to max_rating. Values must be between 1.0 and 5.0.", + "format": "float", + "type": "number" + }, + "minRating": { + "description": "Optional. Restricts results to places whose average user rating is greater than or equal to min_rating. Values must be between 1.0 and 5.0.", + "format": "float", + "type": "number" + } + }, + "type": "object" + }, + "Region": { + "description": "A region is a geographic boundary such as: cities, postal codes, counties, states, etc.", + "id": "Region", + "properties": { + "place": { + "description": "The unique identifier of a specific geographic region.", + "type": "string" + } + }, + "type": "object" + }, + "TypeFilter": { + "description": "Place type filters. Only Place types from [Table a](https://developers.google.com/maps/documentation/places/web-service/place-types#table-a) are supported. A place can only have a single primary type associated with it. For example, the primary type might be \"mexican_restaurant\" or \"steak_house\". Use included_primary_types and excluded_primary_types to filter the results on a place's primary type. A place can also have multiple type values associated with it. For example a restaurant might have the following types: \"seafood_restaurant\", \"restaurant\", \"food\", \"point_of_interest\", \"establishment\". Use included_types and excluded_types to filter the results on the list of types associated with a place. If a search is specified with multiple type restrictions, only places that satisfy all of the restrictions are returned. For example, if you specify {\"included_types\": [\"restaurant\"], \"excluded_primary_types\": [\"steak_house\"]}, the returned places provide \"restaurant\" related services but do not operate primarily as a \"steak_house\". If there are any conflicting types, i.e. a type appears in both included_types and excluded_types types or included_primary_types and excluded_primary_types, an INVALID_ARGUMENT error is returned. One of included_types or included_primary_types must be set.", + "id": "TypeFilter", + "properties": { + "excludedPrimaryTypes": { + "description": "Optional. Excluded primary Place types.", + "items": { + "type": "string" + }, + "type": "array" + }, + "excludedTypes": { + "description": "Optional. Excluded Place types.", + "items": { + "type": "string" + }, + "type": "array" + }, + "includedPrimaryTypes": { + "description": "Optional. Included primary Place types.", + "items": { + "type": "string" + }, + "type": "array" + }, + "includedTypes": { + "description": "Optional. Included Place types.", + "items": { + "type": "string" + }, + "type": "array" + } + }, + "type": "object" + } + }, + "servicePath": "", + "title": "Places Insights API", + "version": "v1", + "version_module": true +} \ No newline at end of file diff --git a/areainsights/v1/areainsights-gen.go b/areainsights/v1/areainsights-gen.go new file mode 100644 index 0000000000..6c64dc9d94 --- /dev/null +++ b/areainsights/v1/areainsights-gen.go @@ -0,0 +1,685 @@ +// Copyright 2024 Google LLC. +// Use of this source code is governed by a BSD-style +// license that can be found in the LICENSE file. + +// Code generated file. DO NOT EDIT. + +// Package areainsights provides access to the Places Insights API. +// +// For product documentation, see: https://g3doc.corp.google.com/geo/platform/area_insights/README.md?cl=head +// +// # Library status +// +// These client libraries are officially supported by Google. However, this +// library is considered complete and is in maintenance mode. This means +// that we will address critical bugs and security issues but will not add +// any new features. +// +// When possible, we recommend using our newer +// [Cloud Client Libraries for Go](https://pkg.go.dev/cloud.google.com/go) +// that are still actively being worked and iterated on. +// +// # Creating a client +// +// Usage example: +// +// import "google.golang.org/api/areainsights/v1" +// ... +// ctx := context.Background() +// areainsightsService, err := areainsights.NewService(ctx) +// +// In this example, Google Application Default Credentials are used for +// authentication. For information on how to create and obtain Application +// Default Credentials, see https://developers.google.com/identity/protocols/application-default-credentials. +// +// # Other authentication options +// +// To use an API key for authentication (note: some APIs do not support API +// keys), use [google.golang.org/api/option.WithAPIKey]: +// +// areainsightsService, err := areainsights.NewService(ctx, option.WithAPIKey("AIza...")) +// +// To use an OAuth token (e.g., a user token obtained via a three-legged OAuth +// flow, use [google.golang.org/api/option.WithTokenSource]: +// +// config := &oauth2.Config{...} +// // ... +// token, err := config.Exchange(ctx, ...) +// areainsightsService, err := areainsights.NewService(ctx, option.WithTokenSource(config.TokenSource(ctx, token))) +// +// See [google.golang.org/api/option.ClientOption] for details on options. +package areainsights // import "google.golang.org/api/areainsights/v1" + +import ( + "bytes" + "context" + "encoding/json" + "errors" + "fmt" + "io" + "log/slog" + "net/http" + "net/url" + "strconv" + "strings" + + "github.com/googleapis/gax-go/v2/internallog" + googleapi "google.golang.org/api/googleapi" + internal "google.golang.org/api/internal" + gensupport "google.golang.org/api/internal/gensupport" + option "google.golang.org/api/option" + internaloption "google.golang.org/api/option/internaloption" + htransport "google.golang.org/api/transport/http" +) + +// Always reference these packages, just in case the auto-generated code +// below doesn't. +var _ = bytes.NewBuffer +var _ = strconv.Itoa +var _ = fmt.Sprintf +var _ = json.NewDecoder +var _ = io.Copy +var _ = url.Parse +var _ = gensupport.MarshalJSON +var _ = googleapi.Version +var _ = errors.New +var _ = strings.Replace +var _ = context.Canceled +var _ = internaloption.WithDefaultEndpoint +var _ = internal.Version +var _ = internallog.New + +const apiId = "areainsights:v1" +const apiName = "areainsights" +const apiVersion = "v1" +const basePath = "https://areainsights.googleapis.com/" +const basePathTemplate = "https://areainsights.UNIVERSE_DOMAIN/" +const mtlsBasePath = "https://areainsights.mtls.googleapis.com/" + +// OAuth2 scopes used by this API. +const ( + // See, edit, configure, and delete your Google Cloud data and see the email + // address for your Google Account. + CloudPlatformScope = "https://www.googleapis.com/auth/cloud-platform" +) + +// NewService creates a new Service. +func NewService(ctx context.Context, opts ...option.ClientOption) (*Service, error) { + scopesOption := internaloption.WithDefaultScopes( + "https://www.googleapis.com/auth/cloud-platform", + ) + // NOTE: prepend, so we don't override user-specified scopes. + opts = append([]option.ClientOption{scopesOption}, opts...) + opts = append(opts, internaloption.WithDefaultEndpoint(basePath)) + opts = append(opts, internaloption.WithDefaultEndpointTemplate(basePathTemplate)) + opts = append(opts, internaloption.WithDefaultMTLSEndpoint(mtlsBasePath)) + opts = append(opts, internaloption.EnableNewAuthLibrary()) + client, endpoint, err := htransport.NewClient(ctx, opts...) + if err != nil { + return nil, err + } + s := &Service{client: client, BasePath: basePath, logger: internaloption.GetLogger(opts)} + s.V1 = NewV1Service(s) + if err != nil { + return nil, err + } + if endpoint != "" { + s.BasePath = endpoint + } + return s, nil +} + +// New creates a new Service. It uses the provided http.Client for requests. +// +// Deprecated: please use NewService instead. +// To provide a custom HTTP client, use option.WithHTTPClient. +// If you are using google.golang.org/api/googleapis/transport.APIKey, use option.WithAPIKey with NewService instead. +func New(client *http.Client) (*Service, error) { + if client == nil { + return nil, errors.New("client is nil") + } + return NewService(context.Background(), option.WithHTTPClient(client)) +} + +type Service struct { + client *http.Client + logger *slog.Logger + BasePath string // API endpoint base URL + UserAgent string // optional additional User-Agent fragment + + V1 *V1Service +} + +func (s *Service) userAgent() string { + if s.UserAgent == "" { + return googleapi.UserAgent + } + return googleapi.UserAgent + " " + s.UserAgent +} + +func NewV1Service(s *Service) *V1Service { + rs := &V1Service{s: s} + return rs +} + +type V1Service struct { + s *Service +} + +// Circle: A circle is defined by a center point and radius in meters. +type Circle struct { + // LatLng: The latitude and longitude of the center of the circle. + LatLng *LatLng `json:"latLng,omitempty"` + // Place: The Place resource name of the center of the circle. Only point + // places are supported. + Place string `json:"place,omitempty"` + // Radius: Optional. The radius of the circle in meters + Radius int64 `json:"radius,omitempty"` + // ForceSendFields is a list of field names (e.g. "LatLng") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "LatLng") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s Circle) MarshalJSON() ([]byte, error) { + type NoMethod Circle + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// ComputeInsightsRequest: Request for the ComputeInsights RPC. +type ComputeInsightsRequest struct { + // Filter: Required. Insight filter. + Filter *Filter `json:"filter,omitempty"` + // Insights: Required. Insights to compute. Currently only INSIGHT_COUNT and + // INSIGHT_PLACES are supported. + // + // Possible values: + // "INSIGHT_UNSPECIFIED" - Not Specified. + // "INSIGHT_COUNT" - Count insight. When this insight is specified + // ComputeInsights returns the number of places that match the specified filter + // criteria. ``` For example if the request is: ComputeInsightsRequest { + // insights: INSIGHT_COUNT filter { location_filter {region: } type_filter + // {included_types: "restaurant"} operating_status: + // OPERATING_STATUS_OPERATIONAL price_levels: PRICE_LEVEL_FREE price_levels: + // PRICE_LEVEL_INEXPENSIVE min_rating: 4.0 } } The method will return the count + // of restaurants in California that are operational, with price level free or + // inexpensive and have an average rating of at least 4 starts. Example + // response: ComputeInsightsResponse { count: } ``` + // "INSIGHT_PLACES" - Return Places When this insight is specified + // ComputeInsights returns Places that match the specified filter criteria. ``` + // For example if the request is: ComputeInsightsRequest { insights: + // INSIGHT_PLACES filter { location_filter {region: } type_filter + // {included_types: "restaurant"} operating_status: + // OPERATING_STATUS_OPERATIONAL price_levels: PRICE_LEVEL_FREE price_levels: + // PRICE_LEVEL_INEXPENSIVE min_rating: 4.0 } } The method will return list of + // places of restaurants in California that are operational, with price level + // free or inexpensive and have an average rating of at least 4 stars. Example + // response: ComputeInsightsResponse { place_insights { place: "places/ABC" } + // place_insights { place: "places/PQR" } place_insights { place: "places/XYZ" + // } } ``` + Insights []string `json:"insights,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. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + 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. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s ComputeInsightsRequest) MarshalJSON() ([]byte, error) { + type NoMethod ComputeInsightsRequest + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// ComputeInsightsResponse: Response for the ComputeInsights RPC. +type ComputeInsightsResponse struct { + // Count: Result for Insights.INSIGHT_COUNT. + Count int64 `json:"count,omitempty,string"` + // PlaceInsights: Result for Insights.INSIGHT_PLACES. + PlaceInsights []*PlaceInsight `json:"placeInsights,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the server. + googleapi.ServerResponse `json:"-"` + // ForceSendFields is a list of field names (e.g. "Count") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "Count") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s ComputeInsightsResponse) MarshalJSON() ([]byte, error) { + type NoMethod ComputeInsightsResponse + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// CustomArea: Custom Area. +type CustomArea struct { + // Polygon: Required. The custom area represented as a polygon + Polygon *Polygon `json:"polygon,omitempty"` + // ForceSendFields is a list of field names (e.g. "Polygon") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "Polygon") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s CustomArea) MarshalJSON() ([]byte, error) { + type NoMethod CustomArea + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// Filter: Filters for the ComputeInsights RPC. +type Filter struct { + // LocationFilter: Required. Restricts results to places which are located in + // the area specified by location filters. + LocationFilter *LocationFilter `json:"locationFilter,omitempty"` + // OperatingStatus: Optional. Restricts results to places whose operating + // status is included on this list. If operating_status is not set, + // OPERATING_STATUS_OPERATIONAL is used as default. + // + // Possible values: + // "OPERATING_STATUS_UNSPECIFIED" - Not Specified. + // "OPERATING_STATUS_OPERATIONAL" - The place is operational and its open + // during its defined hours. + // "OPERATING_STATUS_PERMANENTLY_CLOSED" - The Place is no longer in + // business. + // "OPERATING_STATUS_TEMPORARILY_CLOSED" - The Place is temporarily closed + // and expected to reopen in the future. + OperatingStatus []string `json:"operatingStatus,omitempty"` + // PriceLevels: Optional. Restricts results to places whose price level is + // included on this list. If price_level is not set, all price levels are + // included in the results. + // + // Possible values: + // "PRICE_LEVEL_UNSPECIFIED" - Place price level is unspecified or unknown. + // "PRICE_LEVEL_FREE" - Place provides free services. + // "PRICE_LEVEL_INEXPENSIVE" - Place provides inexpensive services. + // "PRICE_LEVEL_MODERATE" - Place provides moderately priced services. + // "PRICE_LEVEL_EXPENSIVE" - Place provides expensive services. + // "PRICE_LEVEL_VERY_EXPENSIVE" - Place provides very expensive services. + PriceLevels []string `json:"priceLevels,omitempty"` + // RatingFilter: Optional. Restricts results to places whose average user + // ratings are in the range specified by rating_filter. If rating_filter is not + // set, all ratings are included in the result. + RatingFilter *RatingFilter `json:"ratingFilter,omitempty"` + // TypeFilter: Required. Place type filters. + TypeFilter *TypeFilter `json:"typeFilter,omitempty"` + // ForceSendFields is a list of field names (e.g. "LocationFilter") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "LocationFilter") to include in + // API requests with the JSON null value. By default, fields with empty values + // are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s Filter) MarshalJSON() ([]byte, error) { + type NoMethod Filter + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// LatLng: An object that represents a latitude/longitude pair. This is +// expressed as a pair of doubles to represent degrees latitude and degrees +// longitude. Unless specified otherwise, this object must conform to the WGS84 +// standard. Values must be within normalized ranges. +type LatLng struct { + // Latitude: The latitude in degrees. It must be in the range [-90.0, +90.0]. + Latitude float64 `json:"latitude,omitempty"` + // Longitude: The longitude in degrees. It must be in the range [-180.0, + // +180.0]. + Longitude float64 `json:"longitude,omitempty"` + // ForceSendFields is a list of field names (e.g. "Latitude") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "Latitude") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s LatLng) MarshalJSON() ([]byte, error) { + type NoMethod LatLng + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +func (s *LatLng) UnmarshalJSON(data []byte) error { + type NoMethod LatLng + var s1 struct { + Latitude gensupport.JSONFloat64 `json:"latitude"` + Longitude gensupport.JSONFloat64 `json:"longitude"` + *NoMethod + } + s1.NoMethod = (*NoMethod)(s) + if err := json.Unmarshal(data, &s1); err != nil { + return err + } + s.Latitude = float64(s1.Latitude) + s.Longitude = float64(s1.Longitude) + return nil +} + +// LocationFilter: Location filters. Specifies the area of interest for the +// insight. +type LocationFilter struct { + // Circle: Area as a circle. + Circle *Circle `json:"circle,omitempty"` + // CustomArea: Custom area specified by a polygon. + CustomArea *CustomArea `json:"customArea,omitempty"` + // Region: Area as region. + Region *Region `json:"region,omitempty"` + // ForceSendFields is a list of field names (e.g. "Circle") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "Circle") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s LocationFilter) MarshalJSON() ([]byte, error) { + type NoMethod LocationFilter + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// PlaceInsight: Holds information about a place +type PlaceInsight struct { + // Place: The unique identifier of the place. This resource name can be used to + // retrieve details about the place using the Places API + // (https://developers.google.com/maps/documentation/places/web-service/reference/rest/v1/places/get). + Place string `json:"place,omitempty"` + // ForceSendFields is a list of field names (e.g. "Place") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "Place") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s PlaceInsight) MarshalJSON() ([]byte, error) { + type NoMethod PlaceInsight + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// Polygon: A polygon is represented by a series of connected coordinates in an +// counterclockwise ordered sequence. The coordinates form a closed loop and +// define a filled region. The first and last coordinates are equivalent, and +// they must contain identical values. The format is a simplified version of +// GeoJSON polygons (we only support one counterclockwise exterior ring). +type Polygon struct { + // Coordinates: Optional. The coordinates that define the polygon. + Coordinates []*LatLng `json:"coordinates,omitempty"` + // ForceSendFields is a list of field names (e.g. "Coordinates") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "Coordinates") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s Polygon) MarshalJSON() ([]byte, error) { + type NoMethod Polygon + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// RatingFilter: Average user rating filters. +type RatingFilter struct { + // MaxRating: Optional. Restricts results to places whose average user rating + // is strictly less than or equal to max_rating. Values must be between 1.0 and + // 5.0. + MaxRating float64 `json:"maxRating,omitempty"` + // MinRating: Optional. Restricts results to places whose average user rating + // is greater than or equal to min_rating. Values must be between 1.0 and 5.0. + MinRating float64 `json:"minRating,omitempty"` + // ForceSendFields is a list of field names (e.g. "MaxRating") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "MaxRating") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s RatingFilter) MarshalJSON() ([]byte, error) { + type NoMethod RatingFilter + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +func (s *RatingFilter) UnmarshalJSON(data []byte) error { + type NoMethod RatingFilter + var s1 struct { + MaxRating gensupport.JSONFloat64 `json:"maxRating"` + MinRating gensupport.JSONFloat64 `json:"minRating"` + *NoMethod + } + s1.NoMethod = (*NoMethod)(s) + if err := json.Unmarshal(data, &s1); err != nil { + return err + } + s.MaxRating = float64(s1.MaxRating) + s.MinRating = float64(s1.MinRating) + return nil +} + +// Region: A region is a geographic boundary such as: cities, postal codes, +// counties, states, etc. +type Region struct { + // Place: The unique identifier of a specific geographic region. + Place string `json:"place,omitempty"` + // ForceSendFields is a list of field names (e.g. "Place") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "Place") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s Region) MarshalJSON() ([]byte, error) { + type NoMethod Region + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// TypeFilter: Place type filters. Only Place types from Table a +// (https://developers.google.com/maps/documentation/places/web-service/place-types#table-a) +// are supported. A place can only have a single primary type associated with +// it. For example, the primary type might be "mexican_restaurant" or +// "steak_house". Use included_primary_types and excluded_primary_types to +// filter the results on a place's primary type. A place can also have multiple +// type values associated with it. For example a restaurant might have the +// following types: "seafood_restaurant", "restaurant", "food", +// "point_of_interest", "establishment". Use included_types and excluded_types +// to filter the results on the list of types associated with a place. If a +// search is specified with multiple type restrictions, only places that +// satisfy all of the restrictions are returned. For example, if you specify +// {"included_types": ["restaurant"], "excluded_primary_types": +// ["steak_house"]}, the returned places provide "restaurant" related services +// but do not operate primarily as a "steak_house". If there are any +// conflicting types, i.e. a type appears in both included_types and +// excluded_types types or included_primary_types and excluded_primary_types, +// an INVALID_ARGUMENT error is returned. One of included_types or +// included_primary_types must be set. +type TypeFilter struct { + // ExcludedPrimaryTypes: Optional. Excluded primary Place types. + ExcludedPrimaryTypes []string `json:"excludedPrimaryTypes,omitempty"` + // ExcludedTypes: Optional. Excluded Place types. + ExcludedTypes []string `json:"excludedTypes,omitempty"` + // IncludedPrimaryTypes: Optional. Included primary Place types. + IncludedPrimaryTypes []string `json:"includedPrimaryTypes,omitempty"` + // IncludedTypes: Optional. Included Place types. + IncludedTypes []string `json:"includedTypes,omitempty"` + // ForceSendFields is a list of field names (e.g. "ExcludedPrimaryTypes") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "ExcludedPrimaryTypes") to include + // in API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s TypeFilter) MarshalJSON() ([]byte, error) { + type NoMethod TypeFilter + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +type V1ComputeInsightsCall struct { + s *Service + computeinsightsrequest *ComputeInsightsRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// ComputeInsights: Compute Insights RPC This method lets you retrieve insights +// about areas using a variaty of filter such as: area, place type, operating +// status, price level and ratings. Currently "count" and "places" insights are +// supported. With "count" insights you can answer questions such as "How many +// restaurant are located in California that are operational, are inexpensive +// and have an average rating of at least 4 stars" (see `insight` enum for more +// details). With "places" insights, you can determine which places match the +// requested filter. Clients can then use those place resource names to fetch +// more details about each individual place using the Places API. +func (r *V1Service) ComputeInsights(computeinsightsrequest *ComputeInsightsRequest) *V1ComputeInsightsCall { + c := &V1ComputeInsightsCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.computeinsightsrequest = computeinsightsrequest + return c +} + +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. +func (c *V1ComputeInsightsCall) Fields(s ...googleapi.Field) *V1ComputeInsightsCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *V1ComputeInsightsCall) Context(ctx context.Context) *V1ComputeInsightsCall { + c.ctx_ = ctx + return c +} + +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. +func (c *V1ComputeInsightsCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *V1ComputeInsightsCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) + body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.computeinsightsrequest) + if err != nil { + return nil, err + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1:computeInsights") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("POST", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "areainsights.computeInsights", "request", internallog.HTTPRequest(req, body.Bytes())) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "areainsights.computeInsights" call. +// Any non-2xx status code is an error. Response headers are in either +// *ComputeInsightsResponse.ServerResponse.Header or (if a response was +// returned at all) in error.(*googleapi.Error).Header. Use +// googleapi.IsNotModified to check whether the returned error was because +// http.StatusNotModified was returned. +func (c *V1ComputeInsightsCall) Do(opts ...googleapi.CallOption) (*ComputeInsightsResponse, 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 := &ComputeInsightsResponse{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + b, err := gensupport.DecodeResponseBytes(target, res) + if err != nil { + return nil, err + } + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "areainsights.computeInsights", "response", internallog.HTTPResponse(res, b)) + return ret, nil +} diff --git a/chromemanagement/v1/chromemanagement-api.json b/chromemanagement/v1/chromemanagement-api.json index b47b215e73..14d4edcccc 100644 --- a/chromemanagement/v1/chromemanagement-api.json +++ b/chromemanagement/v1/chromemanagement-api.json @@ -20,7 +20,7 @@ "canonicalName": "Chrome Management", "description": "The Chrome Management API is a suite of services that allows Chrome administrators to view, manage and gain insights on their Chrome OS and Chrome Browser devices.", "discoveryVersion": "v1", - "documentationLink": "http://developers.google.com/chrome/management/", + "documentationLink": "https://developers.google.com/chrome/management/", "fullyEncodeReservedExpansion": true, "icons": { "x16": "http://www.google.com/images/icons/product/search-16.gif", @@ -1263,7 +1263,7 @@ } } }, - "revision": "20241215", + "revision": "20241216", "rootUrl": "https://chromemanagement.googleapis.com/", "schemas": { "GoogleChromeManagementV1AndroidAppInfo": { diff --git a/chromemanagement/v1/chromemanagement-gen.go b/chromemanagement/v1/chromemanagement-gen.go index 671a7f3cfa..cb9213fbf6 100644 --- a/chromemanagement/v1/chromemanagement-gen.go +++ b/chromemanagement/v1/chromemanagement-gen.go @@ -6,7 +6,7 @@ // Package chromemanagement provides access to the Chrome Management API. // -// For product documentation, see: http://developers.google.com/chrome/management/ +// For product documentation, see: https://developers.google.com/chrome/management/ // // # Library status // diff --git a/content/v2.1/content-api.json b/content/v2.1/content-api.json index c3954086c6..53e45dc3fd 100644 --- a/content/v2.1/content-api.json +++ b/content/v2.1/content-api.json @@ -4570,7 +4570,7 @@ } } }, - "revision": "20241120", + "revision": "20241217", "rootUrl": "https://shoppingcontent.googleapis.com/", "schemas": { "Account": { @@ -10512,6 +10512,13 @@ "$ref": "ProductSubscriptionCost", "description": "Number of periods (months or years) and amount of payment per period for an item with an associated subscription contract." }, + "sustainabilityIncentives": { + "description": "Optional. The list of sustainability incentive programs.", + "items": { + "$ref": "ProductSustainabilityIncentive" + }, + "type": "array" + }, "targetCountry": { "description": "Required. The CLDR territory code for the item's country of sale.", "type": "string" @@ -11075,6 +11082,36 @@ }, "type": "object" }, + "ProductSustainabilityIncentive": { + "description": "Information regarding sustainability related incentive programs such as rebates or tax relief.", + "id": "ProductSustainabilityIncentive", + "properties": { + "amount": { + "$ref": "Price", + "description": "Optional. The fixed amount of the incentive." + }, + "percentage": { + "description": "Optional. The percentage of the sale price that the incentive is applied to.", + "format": "double", + "type": "number" + }, + "type": { + "description": "Required. Sustainability incentive program.", + "enum": [ + "TYPE_UNSPECIFIED", + "EV_TAX_CREDIT", + "EV_PRICE_DISCOUNT" + ], + "enumDescriptions": [ + "Unspecified or unknown sustainability incentive type.", + "Program offering tax liability reductions for electric vehicles and, in some countries, plug-in hybrids. These reductions can be based on a specific amount or a percentage of the sale price.", + "A subsidy program, often called an environmental bonus, provides a purchase grant for electric vehicles and, in some countries, plug-in hybrids. The grant amount may be a fixed sum or a percentage of the sale price." + ], + "type": "string" + } + }, + "type": "object" + }, "ProductTax": { "id": "ProductTax", "properties": { diff --git a/content/v2.1/content-gen.go b/content/v2.1/content-gen.go index 010a3cf803..e2602d197c 100644 --- a/content/v2.1/content-gen.go +++ b/content/v2.1/content-gen.go @@ -8176,6 +8176,9 @@ type Product struct { // SubscriptionCost: Number of periods (months or years) and amount of payment // per period for an item with an associated subscription contract. SubscriptionCost *ProductSubscriptionCost `json:"subscriptionCost,omitempty"` + // SustainabilityIncentives: Optional. The list of sustainability incentive + // programs. + SustainabilityIncentives []*ProductSustainabilityIncentive `json:"sustainabilityIncentives,omitempty"` // TargetCountry: Required. The CLDR territory code for the item's country of // sale. TargetCountry string `json:"targetCountry,omitempty"` @@ -8976,6 +8979,58 @@ func (s ProductSubscriptionCost) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// ProductSustainabilityIncentive: Information regarding sustainability related +// incentive programs such as rebates or tax relief. +type ProductSustainabilityIncentive struct { + // Amount: Optional. The fixed amount of the incentive. + Amount *Price `json:"amount,omitempty"` + // Percentage: Optional. The percentage of the sale price that the incentive is + // applied to. + Percentage float64 `json:"percentage,omitempty"` + // Type: Required. Sustainability incentive program. + // + // Possible values: + // "TYPE_UNSPECIFIED" - Unspecified or unknown sustainability incentive type. + // "EV_TAX_CREDIT" - Program offering tax liability reductions for electric + // vehicles and, in some countries, plug-in hybrids. These reductions can be + // based on a specific amount or a percentage of the sale price. + // "EV_PRICE_DISCOUNT" - A subsidy program, often called an environmental + // bonus, provides a purchase grant for electric vehicles and, in some + // countries, plug-in hybrids. The grant amount may be a fixed sum or a + // percentage of the sale price. + Type string `json:"type,omitempty"` + // ForceSendFields is a list of field names (e.g. "Amount") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "Amount") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s ProductSustainabilityIncentive) MarshalJSON() ([]byte, error) { + type NoMethod ProductSustainabilityIncentive + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +func (s *ProductSustainabilityIncentive) UnmarshalJSON(data []byte) error { + type NoMethod ProductSustainabilityIncentive + var s1 struct { + Percentage gensupport.JSONFloat64 `json:"percentage"` + *NoMethod + } + s1.NoMethod = (*NoMethod)(s) + if err := json.Unmarshal(data, &s1); err != nil { + return err + } + s.Percentage = float64(s1.Percentage) + return nil +} + type ProductTax struct { // Country: The country within which the item is taxed, specified as a CLDR // territory code. diff --git a/discoveryengine/v1/discoveryengine-api.json b/discoveryengine/v1/discoveryengine-api.json index 97ccc61de4..7a38e9f1ca 100644 --- a/discoveryengine/v1/discoveryengine-api.json +++ b/discoveryengine/v1/discoveryengine-api.json @@ -160,6 +160,36 @@ }, "resources": { "locations": { + "methods": { + "generateGroundedContent": { + "description": "Generates grounded content.", + "flatPath": "v1/projects/{projectsId}/locations/{locationsId}:generateGroundedContent", + "httpMethod": "POST", + "id": "discoveryengine.projects.locations.generateGroundedContent", + "parameterOrder": [ + "location" + ], + "parameters": { + "location": { + "description": "Required. Location resource. Format: `projects/{project}/locations/{location}`.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1/{+location}:generateGroundedContent", + "request": { + "$ref": "GoogleCloudDiscoveryengineV1GenerateGroundedContentRequest" + }, + "response": { + "$ref": "GoogleCloudDiscoveryengineV1GenerateGroundedContentResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + } + }, "resources": { "collections": { "resources": { @@ -6341,7 +6371,7 @@ } } }, - "revision": "20241210", + "revision": "20241216", "rootUrl": "https://discoveryengine.googleapis.com/", "schemas": { "GoogleApiDistribution": { @@ -8341,6 +8371,13 @@ "description": "Required. Name of the CmekConfig, of the form `projects/{project}/locations/{location}/cmekConfig` or `projects/{project}/locations/{location}/cmekConfigs/{cmekConfig}`.", "type": "string" }, + "singleRegionKeys": { + "description": "Optional. Single-regional CMEKs that are required for some VAIS features.", + "items": { + "$ref": "GoogleCloudDiscoveryengineV1SingleRegionKey" + }, + "type": "array" + }, "state": { "description": "Output only. State of the CmekConfig.", "enum": [ @@ -9071,6 +9108,10 @@ ], "type": "string" }, + "isInfobotFaqDataStore": { + "description": "Optional. If set, this DataStore is an Infobot FAQ DataStore.", + "type": "boolean" + }, "kmsKeyName": { "description": "Input only. The KMS key to be used to protect this DataStore at creation time. Must be set for requests that need to comply with CMEK Org Policy protections. If this field is set and processed successfully, the DataStore will be protected by the KMS key, as indicated in the cmek_config field.", "type": "string" @@ -9283,7 +9324,7 @@ }, "indexStatus": { "$ref": "GoogleCloudDiscoveryengineV1DocumentIndexStatus", - "description": "Output only. The index status of the document. * If document is indexed successfully, the index_time field is populated. * Otherwise, if document is not indexed due to errors, the error_samples field is populated. * Otherwise, index_status is unset.", + "description": "Output only. The index status of the document. * If document is indexed successfully, the index_time field is populated. * Otherwise, if document is not indexed due to errors, the error_samples field is populated. * Otherwise, if document's index is in progress, the pending_message field is populated.", "readOnly": true }, "indexTime": { @@ -9354,6 +9395,10 @@ "description": "The time when the document was indexed. If this field is populated, it means the document has been indexed.", "format": "google-datetime", "type": "string" + }, + "pendingMessage": { + "description": "Immutable. The message indicates the document index is in progress. If this field is populated, the document index is pending.", + "type": "string" } }, "type": "object" @@ -9833,236 +9878,654 @@ }, "type": "object" }, - "GoogleCloudDiscoveryengineV1GroundingFact": { - "description": "Grounding Fact.", - "id": "GoogleCloudDiscoveryengineV1GroundingFact", + "GoogleCloudDiscoveryengineV1GenerateGroundedContentRequest": { + "description": "Top-level message sent by the client for the `GenerateGroundedContent` method.", + "id": "GoogleCloudDiscoveryengineV1GenerateGroundedContentRequest", "properties": { - "attributes": { + "contents": { + "description": "Content of the current conversation with the model. For single-turn queries, this is a single instance. For multi-turn queries, this is a repeated field that contains conversation history + latest request.", + "items": { + "$ref": "GoogleCloudDiscoveryengineV1GroundedGenerationContent" + }, + "type": "array" + }, + "generationSpec": { + "$ref": "GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestGenerationSpec", + "description": "Content generation specification." + }, + "groundingSpec": { + "$ref": "GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestGroundingSpec", + "description": "Grounding specification." + }, + "systemInstruction": { + "$ref": "GoogleCloudDiscoveryengineV1GroundedGenerationContent", + "description": "Content of the system instruction for the current API. These instructions will take priority over any other prompt instructions if the selected model is supporting them." + }, + "userLabels": { "additionalProperties": { "type": "string" }, - "description": "Attributes associated with the fact. Common attributes include `source` (indicating where the fact was sourced from), `author` (indicating the author of the fact), and so on.", + "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" + }, + "GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestDynamicRetrievalConfiguration": { + "description": "Describes the options to customize dynamic retrieval.", + "id": "GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestDynamicRetrievalConfiguration", + "properties": { + "predictor": { + "$ref": "GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestDynamicRetrievalConfigurationDynamicRetrievalPredictor", + "description": "Specification for the predictor for dynamic retrieval." + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestDynamicRetrievalConfigurationDynamicRetrievalPredictor": { + "description": "Describes the predictor settings for dynamic retrieval.", + "id": "GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestDynamicRetrievalConfigurationDynamicRetrievalPredictor", + "properties": { + "threshold": { + "description": "The value of the threshold. If the predictor will predict a value smaller than this, it would suppress grounding in the source.", + "format": "float", + "type": "number" }, - "factText": { - "description": "Text content of the fact. Can be at most 10K characters long.", + "version": { + "description": "The version of the predictor to be used in dynamic retrieval.", + "enum": [ + "VERSION_UNSPECIFIED", + "V1_INDEPENDENT" + ], + "enumDescriptions": [ + "Automatically choose the best version of the retrieval predictor.", + "The V1 model which is evaluating each source independently." + ], "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1ImportCompletionSuggestionsMetadata": { - "description": "Metadata related to the progress of the ImportCompletionSuggestions operation. This will be returned by the google.longrunning.Operation.metadata field.", - "id": "GoogleCloudDiscoveryengineV1ImportCompletionSuggestionsMetadata", + "GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestGenerationSpec": { + "description": "Content generation specification.", + "id": "GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestGenerationSpec", "properties": { - "createTime": { - "description": "Operation create time.", - "format": "google-datetime", - "type": "string" + "frequencyPenalty": { + "description": "If specified, custom value for frequency penalty will be used.", + "format": "float", + "type": "number" }, - "failureCount": { - "description": "Count of CompletionSuggestions that failed to be imported.", - "format": "int64", + "languageCode": { + "description": "Language code for content. Use language tags defined by [BCP47](https://www.rfc-editor.org/rfc/bcp/bcp47.txt).", "type": "string" }, - "successCount": { - "description": "Count of CompletionSuggestions successfully imported.", - "format": "int64", - "type": "string" + "maxOutputTokens": { + "description": "If specified, custom value for max output tokens will be used.", + "format": "int32", + "type": "integer" }, - "updateTime": { - "description": "Operation last update time. If the operation is done, this is also the finish time.", - "format": "google-datetime", + "modelId": { + "description": "Specifies which Vertex model id to use for generation.", "type": "string" + }, + "presencePenalty": { + "description": "If specified, custom value for presence penalty will be used.", + "format": "float", + "type": "number" + }, + "seed": { + "description": "If specified, custom value for the seed will be used.", + "format": "int32", + "type": "integer" + }, + "temperature": { + "description": "If specified, custom value for the temperature will be used.", + "format": "float", + "type": "number" + }, + "topK": { + "description": "If specified, custom value for top-k sampling will be used.", + "format": "int32", + "type": "integer" + }, + "topP": { + "description": "If specified, custom value for nucleus sampling will be used.", + "format": "float", + "type": "number" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1ImportCompletionSuggestionsRequest": { - "description": "Request message for CompletionService.ImportCompletionSuggestions method.", - "id": "GoogleCloudDiscoveryengineV1ImportCompletionSuggestionsRequest", + "GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestGroundingSource": { + "description": "Grounding source.", + "id": "GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestGroundingSource", "properties": { - "bigquerySource": { - "$ref": "GoogleCloudDiscoveryengineV1BigQuerySource", - "description": "BigQuery input source." - }, - "errorConfig": { - "$ref": "GoogleCloudDiscoveryengineV1ImportErrorConfig", - "description": "The desired location of errors incurred during the Import." - }, - "gcsSource": { - "$ref": "GoogleCloudDiscoveryengineV1GcsSource", - "description": "Cloud Storage location for the input content." + "googleSearchSource": { + "$ref": "GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestGroundingSourceGoogleSearchSource", + "description": "If set, grounding is performed with Google Search." }, "inlineSource": { - "$ref": "GoogleCloudDiscoveryengineV1ImportCompletionSuggestionsRequestInlineSource", - "description": "The Inline source for suggestion entries." + "$ref": "GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestGroundingSourceInlineSource", + "description": "If set, grounding is performed with inline content." + }, + "searchSource": { + "$ref": "GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestGroundingSourceSearchSource", + "description": "If set, grounding is performed with Vertex AI Search." } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1ImportCompletionSuggestionsRequestInlineSource": { - "description": "The inline source for CompletionSuggestions.", - "id": "GoogleCloudDiscoveryengineV1ImportCompletionSuggestionsRequestInlineSource", + "GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestGroundingSourceGoogleSearchSource": { + "description": "Google Search config parameters.", + "id": "GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestGroundingSourceGoogleSearchSource", "properties": { - "suggestions": { - "description": "Required. A list of all denylist entries to import. Max of 1000 items.", - "items": { - "$ref": "GoogleCloudDiscoveryengineV1CompletionSuggestion" - }, - "type": "array" + "dynamicRetrievalConfig": { + "$ref": "GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestDynamicRetrievalConfiguration", + "description": "Optional. Specifies the dynamic retrieval configuration for the given source." } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1ImportCompletionSuggestionsResponse": { - "description": "Response of the CompletionService.ImportCompletionSuggestions method. If the long running operation is done, this message is returned by the google.longrunning.Operations.response field if the operation is successful.", - "id": "GoogleCloudDiscoveryengineV1ImportCompletionSuggestionsResponse", + "GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestGroundingSourceInlineSource": { + "description": "Message to be used for grounding based on inline content.", + "id": "GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestGroundingSourceInlineSource", "properties": { - "errorConfig": { - "$ref": "GoogleCloudDiscoveryengineV1ImportErrorConfig", - "description": "The desired location of errors incurred during the Import." + "attributes": { + "additionalProperties": { + "type": "string" + }, + "description": "Attributes associated with the content. Common attributes include `source` (indicating where the content was sourced from) and `author` (indicating the author of the content).", + "type": "object" }, - "errorSamples": { - "description": "A sample of errors encountered while processing the request.", + "groundingFacts": { + "description": "List of facts to be used for grounding.", "items": { - "$ref": "GoogleRpcStatus" + "$ref": "GoogleCloudDiscoveryengineV1GroundingFact" }, "type": "array" } }, "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", + "GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestGroundingSourceSearchSource": { + "description": "Message to be used for grounding with Vertex AI Search.", + "id": "GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestGroundingSourceSearchSource", "properties": { - "createTime": { - "description": "Operation create time.", - "format": "google-datetime", - "type": "string" - }, - "failureCount": { - "description": "Count of entries that encountered errors while processing.", - "format": "int64", + "filter": { + "description": "Filter expression to be applied to the search. The syntax is the same as SearchRequest.filter.", "type": "string" }, - "successCount": { - "description": "Count of entries that were processed successfully.", - "format": "int64", - "type": "string" + "maxResultCount": { + "description": "Number of search results to return. The default value is 10. The maximumm allowed value is 10.", + "format": "int32", + "type": "integer" }, - "totalCount": { - "description": "Total count of entries that were processed.", - "format": "int64", - "type": "string" + "safeSearch": { + "description": "If set, safe search is enabled in Vertex AI Search requests.", + "type": "boolean" }, - "updateTime": { - "description": "Operation last update time. If the operation is done, this is also the finish time.", - "format": "google-datetime", + "servingConfig": { + "description": "The resource name of the Engine to use. Format: `projects/{project}/locations/{location}/collections/{collection_id}/engines/{engine_id}/servingConfigs/{serving_config_id}`", "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1ImportDocumentsRequest": { - "description": "Request message for Import methods.", - "id": "GoogleCloudDiscoveryengineV1ImportDocumentsRequest", + "GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestGroundingSpec": { + "description": "Grounding specification.", + "id": "GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestGroundingSpec", "properties": { - "alloyDbSource": { - "$ref": "GoogleCloudDiscoveryengineV1AlloyDbSource", - "description": "AlloyDB input source." - }, - "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. Supported data sources: * GcsSource. GcsSource.data_schema must be `custom` or `csv`. Otherwise, an INVALID_ARGUMENT error is thrown. * BigQuerySource. BigQuerySource.data_schema must be `custom` or `csv`. Otherwise, an INVALID_ARGUMENT error is thrown. * SpannerSource. * CloudSqlSource. * FirestoreSource. * BigtableSource.", - "type": "boolean" - }, - "bigquerySource": { - "$ref": "GoogleCloudDiscoveryengineV1BigQuerySource", - "description": "BigQuery input source." - }, - "bigtableSource": { - "$ref": "GoogleCloudDiscoveryengineV1BigtableSource", - "description": "Cloud Bigtable input source." - }, - "cloudSqlSource": { - "$ref": "GoogleCloudDiscoveryengineV1CloudSqlSource", - "description": "Cloud SQL input source." - }, - "errorConfig": { - "$ref": "GoogleCloudDiscoveryengineV1ImportErrorConfig", - "description": "The desired location of errors incurred during the Import." - }, - "fhirStoreSource": { - "$ref": "GoogleCloudDiscoveryengineV1FhirStoreSource", - "description": "FhirStore input source." - }, - "firestoreSource": { - "$ref": "GoogleCloudDiscoveryengineV1FirestoreSource", - "description": "Firestore input source." - }, - "gcsSource": { - "$ref": "GoogleCloudDiscoveryengineV1GcsSource", - "description": "Cloud Storage location for the input content." - }, - "idField": { - "description": "The field indicates the ID field or column to be used as 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 others, it may be the column name of the table where the unique ids are stored. The values of the JSON field or the table column are used as the Document.ids. The JSON field or the table 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 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. Supported data sources: * GcsSource. GcsSource.data_schema must be `custom` or `csv`. Otherwise, an INVALID_ARGUMENT error is thrown. * BigQuerySource. BigQuerySource.data_schema must be `custom` or `csv`. Otherwise, an INVALID_ARGUMENT error is thrown. * SpannerSource. * CloudSqlSource. * FirestoreSource. * BigtableSource.", - "type": "string" - }, - "inlineSource": { - "$ref": "GoogleCloudDiscoveryengineV1ImportDocumentsRequestInlineSource", - "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" - }, - "spannerSource": { - "$ref": "GoogleCloudDiscoveryengineV1SpannerSource", - "description": "Spanner input source." - }, - "updateMask": { - "description": "Indicates which fields in the provided imported documents to update. If not set, the default is to update all fields.", - "format": "google-fieldmask", - "type": "string" + "groundingSources": { + "description": "Grounding sources.", + "items": { + "$ref": "GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestGroundingSource" + }, + "type": "array" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1ImportDocumentsRequestInlineSource": { - "description": "The inline source for the input config for ImportDocuments method.", - "id": "GoogleCloudDiscoveryengineV1ImportDocumentsRequestInlineSource", + "GoogleCloudDiscoveryengineV1GenerateGroundedContentResponse": { + "description": "Response for the `GenerateGroundedContent` method.", + "id": "GoogleCloudDiscoveryengineV1GenerateGroundedContentResponse", "properties": { - "documents": { - "description": "Required. A list of documents to update/create. Each document must have a valid Document.id. Recommended max of 100 items.", + "candidates": { + "description": "Generated candidates.", "items": { - "$ref": "GoogleCloudDiscoveryengineV1Document" + "$ref": "GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidate" }, "type": "array" } }, "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", + "GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidate": { + "description": "A response candidate generated from the model.", + "id": "GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidate", "properties": { - "errorConfig": { - "$ref": "GoogleCloudDiscoveryengineV1ImportErrorConfig", - "description": "Echoes the destination for the complete errors in the request if set." + "content": { + "$ref": "GoogleCloudDiscoveryengineV1GroundedGenerationContent", + "description": "Content of the candidate." }, - "errorSamples": { - "description": "A sample of errors encountered while processing the request.", + "groundingMetadata": { + "$ref": "GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidateGroundingMetadata", + "description": "Grounding metadata for the generated content." + }, + "groundingScore": { + "description": "The overall grounding score for the candidate, in the range of [0, 1].", + "format": "float", + "type": "number" + }, + "index": { + "description": "Index of the candidate.", + "format": "int32", + "type": "integer" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidateGroundingMetadata": { + "description": "Citation for the generated content.", + "id": "GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidateGroundingMetadata", + "properties": { + "groundingSupport": { + "description": "GroundingSupport across all claims in the answer candidate. An support to a fact indicates that the claim is supported by the fact.", + "items": { + "$ref": "GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidateGroundingMetadataGroundingSupport" + }, + "type": "array" + }, + "retrievalMetadata": { + "description": "Retrieval metadata to provide an understanding in the retrieval steps performed by the model. There can be multiple such messages which can correspond to different parts of the retrieval. This is a mechanism used to ensure transparency to our users.", + "items": { + "$ref": "GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidateGroundingMetadataRetrievalMetadata" + }, + "type": "array" + }, + "searchEntryPoint": { + "$ref": "GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidateGroundingMetadataSearchEntryPoint", + "description": "Google search entry for the following-up web searches." + }, + "supportChunks": { + "description": "List of chunks to be attributed across all claims in the candidate. These are derived from the grounding sources supplied in the request.", + "items": { + "$ref": "GoogleCloudDiscoveryengineV1FactChunk" + }, + "type": "array" + }, + "webSearchQueries": { + "description": "Web search queries for the following-up web search.", + "items": { + "type": "string" + }, + "type": "array" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidateGroundingMetadataDynamicRetrievalMetadata": { + "description": "Describes the metadata about dynamic retrieval.", + "id": "GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidateGroundingMetadataDynamicRetrievalMetadata", + "properties": { + "predictorMetadata": { + "$ref": "GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidateGroundingMetadataDynamicRetrievalPredictorMetadata", + "description": "Metadata for the dynamic retrieval predictor." + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidateGroundingMetadataDynamicRetrievalPredictorMetadata": { + "description": "Describes the metadata about the dynamic retrieval predictor.", + "id": "GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidateGroundingMetadataDynamicRetrievalPredictorMetadata", + "properties": { + "prediction": { + "description": "The value of the predictor. This should be between [0, 1] where a value of 0 means that the query would not benefit from grounding, while a value of 1.0 means that the query would benefit the most. In between values allow to differentiate between different usefulness scores for grounding.", + "format": "float", + "type": "number" + }, + "version": { + "description": "The version of the predictor which was used in dynamic retrieval.", + "enum": [ + "VERSION_UNSPECIFIED", + "V1_INDEPENDENT" + ], + "enumDescriptions": [ + "Unspecified version, should never be used.", + "The V1 model which is evaluating each source independently." + ], + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidateGroundingMetadataGroundingSupport": { + "description": "Grounding info for a claim in the candidate and its support.", + "id": "GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidateGroundingMetadataGroundingSupport", + "properties": { + "claimText": { + "description": "Text for the claim in the candidate. Always provided when a support is found.", + "type": "string" + }, + "supportChunkIndices": { + "description": "A list of indices (into 'support_chunks') specifying the citations associated with the claim. For instance [1,3,4] means that support_chunks[1], support_chunks[3], support_chunks[4] are the chunks attributed to the claim.", + "items": { + "format": "int32", + "type": "integer" + }, + "type": "array" + }, + "supportScore": { + "description": "A score in the range of [0, 1] describing how grounded is a specific claim in the support chunks indicated. Higher value means that the claim is better supported by the chunks.", + "format": "float", + "type": "number" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidateGroundingMetadataRetrievalMetadata": { + "description": "Describes the metadata associated with a retrieval step.", + "id": "GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidateGroundingMetadataRetrievalMetadata", + "properties": { + "dynamicRetrievalMetadata": { + "$ref": "GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidateGroundingMetadataDynamicRetrievalMetadata", + "description": "Metadata for dynamic retrieval." + }, + "source": { + "description": "Describes the source to which the metadata is referring to.", + "enum": [ + "SOURCE_UNSPECIFIED", + "VERTEX_AI_SEARCH", + "GOOGLE_SEARCH", + "INLINE_CONTENT", + "GOOGLE_MAPS" + ], + "enumDescriptions": [ + "Unspecified source.", + "Vertex AI search.", + "Google Search.", + "User inline provided content.", + "Google Maps." + ], + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidateGroundingMetadataSearchEntryPoint": { + "description": "Google search entry point.", + "id": "GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidateGroundingMetadataSearchEntryPoint", + "properties": { + "renderedContent": { + "description": "Web content snippet that can be embedded in a web page or an app webview.", + "type": "string" + }, + "sdkBlob": { + "description": "Base64 encoded JSON representing array of tuple.", + "format": "byte", + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1GroundedGenerationContent": { + "description": "Base structured datatype containing multi-part content of a message.", + "id": "GoogleCloudDiscoveryengineV1GroundedGenerationContent", + "properties": { + "parts": { + "description": "Ordered `Parts` that constitute a single message.", + "items": { + "$ref": "GoogleCloudDiscoveryengineV1GroundedGenerationContentPart" + }, + "type": "array" + }, + "role": { + "description": "Producer of the content. Must be either `user` or `model`. Intended to be used for multi-turn conversations. Otherwise, it can be left unset.", + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1GroundedGenerationContentPart": { + "description": "Single part of content.", + "id": "GoogleCloudDiscoveryengineV1GroundedGenerationContentPart", + "properties": { + "text": { + "description": "Inline text.", + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1GroundingFact": { + "description": "Grounding Fact.", + "id": "GoogleCloudDiscoveryengineV1GroundingFact", + "properties": { + "attributes": { + "additionalProperties": { + "type": "string" + }, + "description": "Attributes associated with the fact. Common attributes include `source` (indicating where the fact was sourced from), `author` (indicating the author of the fact), and so on.", + "type": "object" + }, + "factText": { + "description": "Text content of the fact. Can be at most 10K characters long.", + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1ImportCompletionSuggestionsMetadata": { + "description": "Metadata related to the progress of the ImportCompletionSuggestions operation. This will be returned by the google.longrunning.Operation.metadata field.", + "id": "GoogleCloudDiscoveryengineV1ImportCompletionSuggestionsMetadata", + "properties": { + "createTime": { + "description": "Operation create time.", + "format": "google-datetime", + "type": "string" + }, + "failureCount": { + "description": "Count of CompletionSuggestions that failed to be imported.", + "format": "int64", + "type": "string" + }, + "successCount": { + "description": "Count of CompletionSuggestions successfully imported.", + "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" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1ImportCompletionSuggestionsRequest": { + "description": "Request message for CompletionService.ImportCompletionSuggestions method.", + "id": "GoogleCloudDiscoveryengineV1ImportCompletionSuggestionsRequest", + "properties": { + "bigquerySource": { + "$ref": "GoogleCloudDiscoveryengineV1BigQuerySource", + "description": "BigQuery input source." + }, + "errorConfig": { + "$ref": "GoogleCloudDiscoveryengineV1ImportErrorConfig", + "description": "The desired location of errors incurred during the Import." + }, + "gcsSource": { + "$ref": "GoogleCloudDiscoveryengineV1GcsSource", + "description": "Cloud Storage location for the input content." + }, + "inlineSource": { + "$ref": "GoogleCloudDiscoveryengineV1ImportCompletionSuggestionsRequestInlineSource", + "description": "The Inline source for suggestion entries." + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1ImportCompletionSuggestionsRequestInlineSource": { + "description": "The inline source for CompletionSuggestions.", + "id": "GoogleCloudDiscoveryengineV1ImportCompletionSuggestionsRequestInlineSource", + "properties": { + "suggestions": { + "description": "Required. A list of all denylist entries to import. Max of 1000 items.", + "items": { + "$ref": "GoogleCloudDiscoveryengineV1CompletionSuggestion" + }, + "type": "array" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1ImportCompletionSuggestionsResponse": { + "description": "Response of the CompletionService.ImportCompletionSuggestions method. If the long running operation is done, this message is returned by the google.longrunning.Operations.response field if the operation is successful.", + "id": "GoogleCloudDiscoveryengineV1ImportCompletionSuggestionsResponse", + "properties": { + "errorConfig": { + "$ref": "GoogleCloudDiscoveryengineV1ImportErrorConfig", + "description": "The desired location of errors incurred during the Import." + }, + "errorSamples": { + "description": "A sample of errors encountered while processing the request.", + "items": { + "$ref": "GoogleRpcStatus" + }, + "type": "array" + } + }, + "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", + "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" + }, + "totalCount": { + "description": "Total count of entries that were processed.", + "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" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1ImportDocumentsRequest": { + "description": "Request message for Import methods.", + "id": "GoogleCloudDiscoveryengineV1ImportDocumentsRequest", + "properties": { + "alloyDbSource": { + "$ref": "GoogleCloudDiscoveryengineV1AlloyDbSource", + "description": "AlloyDB input source." + }, + "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. Supported data sources: * GcsSource. GcsSource.data_schema must be `custom` or `csv`. Otherwise, an INVALID_ARGUMENT error is thrown. * BigQuerySource. BigQuerySource.data_schema must be `custom` or `csv`. Otherwise, an INVALID_ARGUMENT error is thrown. * SpannerSource. * CloudSqlSource. * FirestoreSource. * BigtableSource.", + "type": "boolean" + }, + "bigquerySource": { + "$ref": "GoogleCloudDiscoveryengineV1BigQuerySource", + "description": "BigQuery input source." + }, + "bigtableSource": { + "$ref": "GoogleCloudDiscoveryengineV1BigtableSource", + "description": "Cloud Bigtable input source." + }, + "cloudSqlSource": { + "$ref": "GoogleCloudDiscoveryengineV1CloudSqlSource", + "description": "Cloud SQL input source." + }, + "errorConfig": { + "$ref": "GoogleCloudDiscoveryengineV1ImportErrorConfig", + "description": "The desired location of errors incurred during the Import." + }, + "fhirStoreSource": { + "$ref": "GoogleCloudDiscoveryengineV1FhirStoreSource", + "description": "FhirStore input source." + }, + "firestoreSource": { + "$ref": "GoogleCloudDiscoveryengineV1FirestoreSource", + "description": "Firestore input source." + }, + "gcsSource": { + "$ref": "GoogleCloudDiscoveryengineV1GcsSource", + "description": "Cloud Storage location for the input content." + }, + "idField": { + "description": "The field indicates the ID field or column to be used as 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 others, it may be the column name of the table where the unique ids are stored. The values of the JSON field or the table column are used as the Document.ids. The JSON field or the table 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 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. Supported data sources: * GcsSource. GcsSource.data_schema must be `custom` or `csv`. Otherwise, an INVALID_ARGUMENT error is thrown. * BigQuerySource. BigQuerySource.data_schema must be `custom` or `csv`. Otherwise, an INVALID_ARGUMENT error is thrown. * SpannerSource. * CloudSqlSource. * FirestoreSource. * BigtableSource.", + "type": "string" + }, + "inlineSource": { + "$ref": "GoogleCloudDiscoveryengineV1ImportDocumentsRequestInlineSource", + "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" + }, + "spannerSource": { + "$ref": "GoogleCloudDiscoveryengineV1SpannerSource", + "description": "Spanner input source." + }, + "updateMask": { + "description": "Indicates which fields in the provided imported documents to update. If not set, the default is to update all fields.", + "format": "google-fieldmask", + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1ImportDocumentsRequestInlineSource": { + "description": "The inline source for the input config for ImportDocuments method.", + "id": "GoogleCloudDiscoveryengineV1ImportDocumentsRequestInlineSource", + "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": "GoogleCloudDiscoveryengineV1Document" + }, + "type": "array" + } + }, + "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", + "properties": { + "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": "GoogleRpcStatus" }, @@ -12242,6 +12705,17 @@ }, "type": "object" }, + "GoogleCloudDiscoveryengineV1SingleRegionKey": { + "description": "Metadata for single-regional CMEKs.", + "id": "GoogleCloudDiscoveryengineV1SingleRegionKey", + "properties": { + "kmsKey": { + "description": "Required. Single-regional kms key resource name which will be used to encrypt resources `projects/{project}/locations/{location}/keyRings/{keyRing}/cryptoKeys/{keyId}`.", + "type": "string" + } + }, + "type": "object" + }, "GoogleCloudDiscoveryengineV1SiteSearchEngine": { "description": "SiteSearchEngine captures DataStore level site search persisting configurations. It is a singleton value per data store.", "id": "GoogleCloudDiscoveryengineV1SiteSearchEngine", @@ -12817,6 +13291,26 @@ }, "type": "object" }, + "GoogleCloudDiscoveryengineV1alphaActionConfig": { + "description": "Informations to support actions on the connector.", + "id": "GoogleCloudDiscoveryengineV1alphaActionConfig", + "properties": { + "actionParams": { + "additionalProperties": { + "description": "Properties of the object.", + "type": "any" + }, + "description": "Required. Params needed to support actions in the format of (Key, Value) pairs. Required parameters for sources that support OAUTH, i.e. `gmail`, `google_calendar`, `jira`, `workday`, `salesforce`, `confluence`: * Key: `client_id` * Value: type STRING. The client id for the service provider to identify your application. * Key: `client_secret` * Value:type STRING. The client secret generated by the application's authorization server.", + "type": "object" + }, + "isActionConfigured": { + "description": "Output only. The connector contains the necessary parameters and is configured to support actions.", + "readOnly": true, + "type": "boolean" + } + }, + "type": "object" + }, "GoogleCloudDiscoveryengineV1alphaAdvancedSiteSearchConfig": { "description": "Configuration data for advance site search.", "id": "GoogleCloudDiscoveryengineV1alphaAdvancedSiteSearchConfig", @@ -13421,6 +13915,13 @@ "description": "Required. Name of the CmekConfig, of the form `projects/{project}/locations/{location}/cmekConfig` or `projects/{project}/locations/{location}/cmekConfigs/{cmekConfig}`.", "type": "string" }, + "singleRegionKeys": { + "description": "Optional. Single-regional CMEKs that are required for some VAIS features.", + "items": { + "$ref": "GoogleCloudDiscoveryengineV1alphaSingleRegionKey" + }, + "type": "array" + }, "state": { "description": "Output only. State of the CmekConfig.", "enum": [ @@ -13447,6 +13948,32 @@ }, "type": "object" }, + "GoogleCloudDiscoveryengineV1alphaCollection": { + "description": "Collection is a container for configuring resources and access to a set of DataStores.", + "id": "GoogleCloudDiscoveryengineV1alphaCollection", + "properties": { + "createTime": { + "description": "Output only. Timestamp the Collection was created at.", + "format": "google-datetime", + "readOnly": true, + "type": "string" + }, + "dataConnector": { + "$ref": "GoogleCloudDiscoveryengineV1alphaDataConnector", + "description": "Output only. The data connector, if present, manages the connection for data stores in the Collection. To set up the connector, use DataConnectorService.SetUpDataConnector method, which creates a new Collection while setting up the DataConnector singleton resource. Setting up connector on an existing Collection is not supported. This output only field contains a subset of the DataConnector fields, including `name`, `data_source`, `entities.entity_name` and `entities.data_store`. To get more details about a data connector, use the DataConnector.GetDataConnector method.", + "readOnly": true + }, + "displayName": { + "description": "Required. The Collection 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" + }, + "name": { + "description": "Immutable. The full resource name of the Collection. Format: `projects/{project}/locations/{location}/collections/{collection_id}`. This field must be a UTF-8 encoded string with a length limit of 1024 characters.", + "type": "string" + } + }, + "type": "object" + }, "GoogleCloudDiscoveryengineV1alphaCondition": { "description": "Defines circumstances to be checked before allowing a behavior", "id": "GoogleCloudDiscoveryengineV1alphaCondition", @@ -13504,6 +14031,186 @@ }, "type": "object" }, + "GoogleCloudDiscoveryengineV1alphaConnectorRun": { + "description": "A data sync run of DataConnector. After DataConnector is successfully initialized, data syncs are scheduled at DataConnector.refresh_interval. A ConnectorRun represents a data sync either in the past or onging that the moment. //", + "id": "GoogleCloudDiscoveryengineV1alphaConnectorRun", + "properties": { + "endTime": { + "description": "Output only. The time when the connector run ended.", + "format": "google-datetime", + "readOnly": true, + "type": "string" + }, + "entityRuns": { + "description": "Output only. The details of the entities synced at the ConnectorRun. Each ConnectorRun consists of syncing one or more entities.", + "items": { + "$ref": "GoogleCloudDiscoveryengineV1alphaConnectorRunEntityRun" + }, + "readOnly": true, + "type": "array" + }, + "errors": { + "description": "Contains info about errors incurred during the sync. Only exist if running into an error state. Contains error code and error message. Use with the `state` field.", + "items": { + "$ref": "GoogleRpcStatus" + }, + "type": "array" + }, + "latestPauseTime": { + "description": "Output only. The time when the connector run was most recently paused.", + "format": "google-datetime", + "readOnly": true, + "type": "string" + }, + "name": { + "description": "Output only. The full resource name of the Connector Run. Format: `projects/*/locations/*/collections/*/dataConnector/connectorRuns/*`. The `connector_run_id` is system-generated.", + "readOnly": true, + "type": "string" + }, + "startTime": { + "description": "Output only. The time when the connector run started.", + "format": "google-datetime", + "readOnly": true, + "type": "string" + }, + "state": { + "description": "Output only. The state of the sync run.", + "enum": [ + "STATE_UNSPECIFIED", + "RUNNING", + "SUCCEEDED", + "FAILED", + "OVERRUN", + "CANCELLED", + "PENDING", + "WARNING" + ], + "enumDescriptions": [ + "Default value.", + "The data sync is ongoing.", + "The data sync is finished.", + "The data sync is failed.", + "Data sync has been running longer than expected and is still running at the time the next run is supposed to start.", + "Data sync was scheduled but has been cancelled.", + "Data sync is about to start.", + "The data sync completed with non-fatal errors." + ], + "readOnly": true, + "type": "string" + }, + "stateUpdateTime": { + "description": "Timestamp at which the connector run sync state was last updated.", + "format": "google-datetime", + "type": "string" + }, + "trigger": { + "description": "Output only. The trigger for this ConnectorRun.", + "enum": [ + "TRIGGER_UNSPECIFIED", + "SCHEDULER", + "INITIALIZATION", + "RESUME", + "MANUAL" + ], + "enumDescriptions": [ + "Default value.", + "ConnectorRun triggered by scheduler if connector has PERIODIC sync mode.", + "ConnectorRun auto triggered by connector initialization.", + "ConnectorRun auto triggered by resuming connector.", + "ConnectorRun triggered by user manually." + ], + "readOnly": true, + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaConnectorRunEntityRun": { + "description": "Represents an entity that was synced in this ConnectorRun.", + "id": "GoogleCloudDiscoveryengineV1alphaConnectorRunEntityRun", + "properties": { + "entityName": { + "description": "The name of the source entity.", + "type": "string" + }, + "errorRecordCount": { + "description": "The total number of documents failed at sync at any stage (extraction, indexing, etc).", + "format": "int64", + "type": "string" + }, + "errors": { + "description": "The errors from the entity's sync run. Only exist if running into an error state. Contains error code and error message.", + "items": { + "$ref": "GoogleRpcStatus" + }, + "type": "array" + }, + "extractedRecordCount": { + "description": "The number of documents extracted from connector source, ready to be ingested to UCS.", + "format": "int64", + "type": "string" + }, + "indexedRecordCount": { + "description": "The number of documents indexed.", + "format": "int64", + "type": "string" + }, + "sourceApiRequestCount": { + "description": "The number of requests sent to 3p API.", + "format": "int64", + "type": "string" + }, + "state": { + "description": "The state of the entity's sync run.", + "enum": [ + "STATE_UNSPECIFIED", + "RUNNING", + "SUCCEEDED", + "FAILED", + "OVERRUN", + "CANCELLED", + "PENDING", + "WARNING" + ], + "enumDescriptions": [ + "Default value.", + "The data sync is ongoing.", + "The data sync is finished.", + "The data sync is failed.", + "Data sync has been running longer than expected and is still running at the time the next run is supposed to start.", + "Data sync was scheduled but has been cancelled.", + "Data sync is about to start.", + "The data sync completed with non-fatal errors." + ], + "type": "string" + }, + "stateUpdateTime": { + "description": "Timestamp at which the entity sync state was last updated.", + "format": "google-datetime", + "type": "string" + }, + "statsUpdateTime": { + "description": "The timestamp for either extracted_documents_count, indexed_documents_count and error_documents_count was last updated.", + "format": "google-datetime", + "type": "string" + }, + "syncType": { + "description": "Sync type of this run.", + "enum": [ + "SYNC_TYPE_UNSPECIFIED", + "FULL", + "INCREMENTAL" + ], + "enumDescriptions": [ + "Sync type unspecified.", + "Sync triggers full sync of all documents.", + "Incremental sync of updated documents." + ], + "type": "string" + } + }, + "type": "object" + }, "GoogleCloudDiscoveryengineV1alphaControl": { "description": "Defines a conditioned behavior to employ during serving. Must be attached to a ServingConfig to be considered at serving time. Permitted actions dependent on `SolutionType`.", "id": "GoogleCloudDiscoveryengineV1alphaControl", @@ -13684,95 +14391,293 @@ "format": "google-datetime", "type": "string" }, - "updateTime": { - "description": "Operation last update time. If the operation is done, this is also the finish time.", + "updateTime": { + "description": "Operation last update time. If the operation is done, this is also the finish time.", + "format": "google-datetime", + "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", + "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" + }, + "GoogleCloudDiscoveryengineV1alphaCreateEvaluationMetadata": { + "description": "Metadata for EvaluationService.CreateEvaluation method.", + "id": "GoogleCloudDiscoveryengineV1alphaCreateEvaluationMetadata", + "properties": {}, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaCreateSchemaMetadata": { + "description": "Metadata for Create Schema LRO.", + "id": "GoogleCloudDiscoveryengineV1alphaCreateSchemaMetadata", + "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" + }, + "GoogleCloudDiscoveryengineV1alphaCreateSitemapMetadata": { + "description": "Metadata related to the progress of the SiteSearchEngineService.CreateSitemap operation. This will be returned by the google.longrunning.Operation.metadata field.", + "id": "GoogleCloudDiscoveryengineV1alphaCreateSitemapMetadata", + "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" + }, + "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" + }, + "updateTime": { + "description": "Operation last update time. If the operation is done, this is also the finish time.", + "format": "google-datetime", + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaCustomFineTuningSpec": { + "description": "Defines custom fine tuning spec.", + "id": "GoogleCloudDiscoveryengineV1alphaCustomFineTuningSpec", + "properties": { + "enableSearchAdaptor": { + "description": "Whether or not to enable and include custom fine tuned search adaptor model.", + "type": "boolean" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaDataConnector": { + "description": "Manages the connection to external data sources for all data stores grouped under a Collection. It's a singleton resource of Collection. The initialization is only supported through SetUpDataConnector method, which will create a new Collection and initialize its DataConnector. //", + "id": "GoogleCloudDiscoveryengineV1alphaDataConnector", + "properties": { + "actionConfig": { + "$ref": "GoogleCloudDiscoveryengineV1alphaActionConfig", + "description": "Optional. Action configurations to make the connector support actions." + }, + "autoRunDisabled": { + "description": "Indicates whether the connector is disabled for auto run. It can be used to pause periodical and real time sync.", + "type": "boolean" + }, + "blockingReasons": { + "description": "Output only. User actions that must be completed before the connector can start syncing data.", + "items": { + "enum": [ + "BLOCKING_REASON_UNSPECIFIED", + "ALLOWLIST_STATIC_IP", + "ALLOWLIST_IN_SERVICE_ATTACHMENT" + ], + "enumDescriptions": [ + "Default value.", + "Connector requires customer to allowlist static IPs.", + "Connector requires customer to allowlist our project in their service attachment." + ], + "type": "string" + }, + "readOnly": true, + "type": "array" + }, + "createTime": { + "description": "Output only. Timestamp the DataConnector was created at.", + "format": "google-datetime", + "readOnly": true, + "type": "string" + }, + "dataSource": { + "description": "Required. The name of the data source. Supported values: `salesforce`, `jira`, `confluence`, `bigquery`.", + "type": "string" + }, + "destinationConfigs": { + "description": "Optional. Any target destinations used to connect to third-party services.", + "items": { + "$ref": "GoogleCloudDiscoveryengineV1alphaDestinationConfig" + }, + "type": "array" + }, + "entities": { + "description": "List of entities from the connected data source to ingest.", + "items": { + "$ref": "GoogleCloudDiscoveryengineV1alphaDataConnectorSourceEntity" + }, + "type": "array" + }, + "errors": { + "description": "Output only. The errors from initialization or from the latest connector run.", + "items": { + "$ref": "GoogleRpcStatus" + }, + "readOnly": true, + "type": "array" + }, + "identityRefreshInterval": { + "deprecated": true, + "description": "The refresh interval to sync the Access Control List information for the documents ingested by this connector. If not set, the access control list will be refreshed at the default interval of 30 minutes. The identity refresh interval can be at least 30 minutes and at most 7 days.", + "format": "google-duration", + "type": "string" + }, + "identityScheduleConfig": { + "$ref": "GoogleCloudDiscoveryengineV1alphaIdentityScheduleConfig", + "description": "The configuration for the identity data synchronization runs. This contains the refresh interval to sync the Access Control List information for the documents ingested by this connector." + }, + "kmsKeyName": { + "description": "Input only. The KMS key to be used to protect the DataStores managed by this connector. Must be set for requests that need to comply with CMEK Org Policy protections. If this field is set and processed successfully, the DataStores created by this connector will be protected by the KMS key.", + "type": "string" + }, + "lastSyncTime": { + "description": "Output only. For periodic connectors only, the last time a data sync was completed.", "format": "google-datetime", + "readOnly": true, "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.", + }, + "latestPauseTime": { + "description": "Output only. The most recent timestamp when this DataConnector was paused, affecting all functionalities such as data synchronization. Pausing a connector has the following effects: - All functionalities, including data synchronization, are halted. - Any ongoing data synchronization job will be canceled. - No future data synchronization runs will be scheduled nor can be triggered.", "format": "google-datetime", + "readOnly": true, "type": "string" }, - "updateTime": { - "description": "Operation last update time. If the operation is done, this is also the finish time.", - "format": "google-datetime", + "name": { + "description": "Output only. The full resource name of the Data Connector. Format: `projects/*/locations/*/collections/*/dataConnector`.", + "readOnly": true, "type": "string" - } - }, - "type": "object" - }, - "GoogleCloudDiscoveryengineV1alphaCreateEvaluationMetadata": { - "description": "Metadata for EvaluationService.CreateEvaluation method.", - "id": "GoogleCloudDiscoveryengineV1alphaCreateEvaluationMetadata", - "properties": {}, - "type": "object" - }, - "GoogleCloudDiscoveryengineV1alphaCreateSchemaMetadata": { - "description": "Metadata for Create Schema LRO.", - "id": "GoogleCloudDiscoveryengineV1alphaCreateSchemaMetadata", - "properties": { - "createTime": { - "description": "Operation create time.", - "format": "google-datetime", + }, + "nextSyncTime": { + "$ref": "GoogleTypeDateTime", + "description": "The UTC time when the next data sync is expected to start for the Data Connector. Customers are only able to specify the hour and minute to schedule the data sync. This is utilized when the data connector has a refresh interval greater than 1 day." + }, + "params": { + "additionalProperties": { + "description": "Properties of the object.", + "type": "any" + }, + "description": "Required. Params needed to access the source in the format of (Key, Value) pairs. Required parameters for all data sources: * Key: `instance_uri` * Value: type STRING. The uri to access the data source. Required parameters for sources that support OAUTH, i.e. `salesforce`: * Key: `client_id` * Value: type STRING. The client id for the third party service provider to identify your application. * Key: `client_secret` * Value:type STRING. The client secret generated by the third party authorization server. * Key: `access_token` * Value: type STRING. OAuth token for UCS to access to the protected resource. * Key: `refresh_token` * Value: type STRING. OAuth refresh token for UCS to obtain a new access token without user interaction. Required parameters for sources that support basic API token auth, i.e. `jira`, `confluence`: * Key: `user_account` * Value: type STRING. The username or email with the source. * Key: `api_token` * Value: type STRING. The API token generated for the source account, that is used for authenticating anywhere where you would have used a password. Example: ```json { \"instance_uri\": \"https://xxx.atlassian.net\", \"user_account\": \"xxxx.xxx@xxx.com\", \"api_token\": \"test-token\" } ``` Optional parameter to specify the authorization type to use for multiple authorization types support: * Key: `auth_type` * Value: type STRING. The authorization type for the data source. Supported values: `BASIC_AUTH`, `OAUTH`, `OAUTH_ACCESS_TOKEN`, `OAUTH_TWO_LEGGED`, `OAUTH_JWT_BEARER`, `OAUTH_PASSWORD_GRANT`, `JWT`, `API_TOKEN`, `FEDERATED_CREDENTIAL`.", + "type": "object" + }, + "privateConnectivityProjectId": { + "description": "Output only. The tenant project ID associated with private connectivity connectors. This project must be allowlisted by in order for the connector to function.", + "readOnly": true, "type": "string" }, - "updateTime": { - "description": "Operation last update time. If the operation is done, this is also the finish time.", - "format": "google-datetime", + "refreshInterval": { + "description": "Required. The refresh interval for data sync. If duration is set to 0, the data will be synced in real time. The streaming feature is not supported yet. The minimum is 30 minutes and maximum is 7 days.", + "format": "google-duration", "type": "string" - } - }, - "type": "object" - }, - "GoogleCloudDiscoveryengineV1alphaCreateSitemapMetadata": { - "description": "Metadata related to the progress of the SiteSearchEngineService.CreateSitemap operation. This will be returned by the google.longrunning.Operation.metadata field.", - "id": "GoogleCloudDiscoveryengineV1alphaCreateSitemapMetadata", - "properties": { - "createTime": { - "description": "Operation create time.", - "format": "google-datetime", + }, + "state": { + "description": "Output only. State of the connector.", + "enum": [ + "STATE_UNSPECIFIED", + "CREATING", + "ACTIVE", + "FAILED", + "RUNNING", + "WARNING" + ], + "enumDescriptions": [ + "Default value.", + "The connector is being set up.", + "The connector is successfully set up and awaiting next sync run.", + "The connector is in error. The error details can be found in DataConnector.errors. If the error is unfixable, the DataConnector can be deleted by [CollectionService.DeleteCollection] API.", + "The connector is actively syncing records from the data source.", + "The connector has completed a sync run, but encountered non-fatal errors." + ], + "readOnly": true, + "type": "string" + }, + "staticIpAddresses": { + "description": "Output only. The static IP addresses used by this connector.", + "items": { + "type": "string" + }, + "readOnly": true, + "type": "array" + }, + "staticIpEnabled": { + "description": "Optional. Whether customer has enabled static IP addresses for this connector.", + "type": "boolean" + }, + "syncMode": { + "description": "The data synchronization mode supported by the data connector.", + "enum": [ + "PERIODIC" + ], + "enumDescriptions": [ + "The connector will sync data periodically based on the refresh_interval. Use it with auto_run_disabled to pause the periodic sync, or indicate a one-time sync." + ], "type": "string" }, "updateTime": { - "description": "Operation last update time. If the operation is done, this is also the finish time.", + "description": "Output only. Timestamp the DataConnector was last updated.", "format": "google-datetime", + "readOnly": true, "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", + "GoogleCloudDiscoveryengineV1alphaDataConnectorSourceEntity": { + "description": "Represents an entity in the data source. For example, the `Account` object in Salesforce.", + "id": "GoogleCloudDiscoveryengineV1alphaDataConnectorSourceEntity", "properties": { - "createTime": { - "description": "Operation create time.", - "format": "google-datetime", + "dataStore": { + "description": "Output only. The full resource name of the associated data store for the source entity. Format: `projects/*/locations/*/collections/*/dataStores/*`. When the connector is initialized by the DataConnectorService.SetUpDataConnector method, a DataStore is automatically created for each source entity.", + "readOnly": true, "type": "string" }, - "updateTime": { - "description": "Operation last update time. If the operation is done, this is also the finish time.", - "format": "google-datetime", + "entityName": { + "description": "The name of the entity. Supported values by data source: * Salesforce: `Lead`, `Opportunity`, `Contact`, `Account`, `Case`, `Contract`, `Campaign` * Jira: `Issue` * Confluence: `Content`, `Space`", "type": "string" - } - }, - "type": "object" - }, - "GoogleCloudDiscoveryengineV1alphaCustomFineTuningSpec": { - "description": "Defines custom fine tuning spec.", - "id": "GoogleCloudDiscoveryengineV1alphaCustomFineTuningSpec", - "properties": { - "enableSearchAdaptor": { - "description": "Whether or not to enable and include custom fine tuned search adaptor model.", - "type": "boolean" + }, + "keyPropertyMappings": { + "additionalProperties": { + "type": "string" + }, + "description": "Attributes for indexing. Key: Field name. Value: The key property to map a field to, such as `title`, and `description`. Supported key properties: * `title`: The title for data record. This would be displayed on search results. * `description`: The description for data record. This would be displayed on search results.", + "type": "object" + }, + "params": { + "additionalProperties": { + "description": "Properties of the object.", + "type": "any" + }, + "description": "The parameters for the entity to facilitate data ingestion. E.g. for BQ connectors: * Key: `document_id_column` * Value: type STRING. The value of the column id.", + "type": "object" } }, "type": "object" @@ -13857,6 +14762,10 @@ ], "type": "string" }, + "isInfobotFaqDataStore": { + "description": "Optional. If set, this DataStore is an Infobot FAQ DataStore.", + "type": "boolean" + }, "kmsKeyName": { "description": "Input only. The KMS key to be used to protect this DataStore at creation time. Must be set for requests that need to comply with CMEK Org Policy protections. If this field is set and processed successfully, the DataStore will be protected by the KMS key, as indicated in the cmek_config field.", "type": "string" @@ -13972,6 +14881,23 @@ }, "type": "object" }, + "GoogleCloudDiscoveryengineV1alphaDeleteCollectionMetadata": { + "description": "Metadata related to the progress of the CollectionService.UpdateCollection operation. This will be returned by the google.longrunning.Operation.metadata field.", + "id": "GoogleCloudDiscoveryengineV1alphaDeleteCollectionMetadata", + "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" + }, "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", @@ -14068,6 +14994,48 @@ }, "type": "object" }, + "GoogleCloudDiscoveryengineV1alphaDestinationConfig": { + "description": "Defines target endpoints used to connect to third-party sources.", + "id": "GoogleCloudDiscoveryengineV1alphaDestinationConfig", + "properties": { + "destinations": { + "description": "Optional. The destinations for the corresponding key.", + "items": { + "$ref": "GoogleCloudDiscoveryengineV1alphaDestinationConfigDestination" + }, + "type": "array" + }, + "key": { + "description": "Optional. Unique destination identifier that is supported by the connector.", + "type": "string" + }, + "params": { + "additionalProperties": { + "description": "Properties of the object.", + "type": "any" + }, + "description": "Optional. Additional parameters for this destination config.", + "type": "object" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaDestinationConfigDestination": { + "description": "Defines a target endpoint", + "id": "GoogleCloudDiscoveryengineV1alphaDestinationConfigDestination", + "properties": { + "host": { + "description": "Publicly routable host.", + "type": "string" + }, + "port": { + "description": "Optional. Target port number accepted by the destination.", + "format": "int32", + "type": "integer" + } + }, + "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", @@ -14854,6 +15822,18 @@ }, "type": "object" }, + "GoogleCloudDiscoveryengineV1alphaIdentityScheduleConfig": { + "description": "The configuration for the identity data synchronization runs.", + "id": "GoogleCloudDiscoveryengineV1alphaIdentityScheduleConfig", + "properties": { + "refreshInterval": { + "description": "Optional. The refresh interval to sync the Access Control List information for the documents ingested by this connector. If not set, the access control list will be refreshed at the default interval of 30 minutes. The identity refresh interval can be at least 30 minutes and at most 7 days.", + "format": "google-duration", + "type": "string" + } + }, + "type": "object" + }, "GoogleCloudDiscoveryengineV1alphaIdpConfig": { "description": "Identity Provider Config.", "id": "GoogleCloudDiscoveryengineV1alphaIdpConfig", @@ -16585,6 +17565,12 @@ }, "type": "object" }, + "GoogleCloudDiscoveryengineV1alphaSetUpDataConnectorMetadata": { + "description": "Metadata for DataConnectorService.SetUpDataConnector method.", + "id": "GoogleCloudDiscoveryengineV1alphaSetUpDataConnectorMetadata", + "properties": {}, + "type": "object" + }, "GoogleCloudDiscoveryengineV1alphaSetUriPatternDocumentDataMetadata": { "description": "Metadata related to the progress of the SiteSearchEngineService.SetUriPatternDocumentData operation. This will be returned by the google.longrunning.Operation.metadata field.", "id": "GoogleCloudDiscoveryengineV1alphaSetUriPatternDocumentDataMetadata", @@ -16608,6 +17594,17 @@ "properties": {}, "type": "object" }, + "GoogleCloudDiscoveryengineV1alphaSingleRegionKey": { + "description": "Metadata for single-regional CMEKs.", + "id": "GoogleCloudDiscoveryengineV1alphaSingleRegionKey", + "properties": { + "kmsKey": { + "description": "Required. Single-regional kms key resource name which will be used to encrypt resources `projects/{project}/locations/{location}/keyRings/{keyRing}/cryptoKeys/{keyId}`.", + "type": "string" + } + }, + "type": "object" + }, "GoogleCloudDiscoveryengineV1alphaSiteVerificationInfo": { "description": "Verification information for target sites in advanced site search.", "id": "GoogleCloudDiscoveryengineV1alphaSiteVerificationInfo", @@ -16845,6 +17842,23 @@ }, "type": "object" }, + "GoogleCloudDiscoveryengineV1alphaUpdateCollectionMetadata": { + "description": "Metadata related to the progress of the CollectionService.UpdateCollection operation. This will be returned by the google.longrunning.Operation.metadata field.", + "id": "GoogleCloudDiscoveryengineV1alphaUpdateCollectionMetadata", + "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" + }, "GoogleCloudDiscoveryengineV1alphaUpdateSchemaMetadata": { "description": "Metadata for UpdateSchema LRO.", "id": "GoogleCloudDiscoveryengineV1alphaUpdateSchemaMetadata", @@ -17017,6 +18031,13 @@ "description": "Required. Name of the CmekConfig, of the form `projects/{project}/locations/{location}/cmekConfig` or `projects/{project}/locations/{location}/cmekConfigs/{cmekConfig}`.", "type": "string" }, + "singleRegionKeys": { + "description": "Optional. Single-regional CMEKs that are required for some VAIS features.", + "items": { + "$ref": "GoogleCloudDiscoveryengineV1betaSingleRegionKey" + }, + "type": "array" + }, "state": { "description": "Output only. State of the CmekConfig.", "enum": [ @@ -17422,6 +18443,10 @@ ], "type": "string" }, + "isInfobotFaqDataStore": { + "description": "Optional. If set, this DataStore is an Infobot FAQ DataStore.", + "type": "boolean" + }, "kmsKeyName": { "description": "Input only. The KMS key to be used to protect this DataStore at creation time. Must be set for requests that need to comply with CMEK Org Policy protections. If this field is set and processed successfully, the DataStore will be protected by the KMS key, as indicated in the cmek_config field.", "type": "string" @@ -19356,6 +20381,17 @@ }, "type": "object" }, + "GoogleCloudDiscoveryengineV1betaSingleRegionKey": { + "description": "Metadata for single-regional CMEKs.", + "id": "GoogleCloudDiscoveryengineV1betaSingleRegionKey", + "properties": { + "kmsKey": { + "description": "Required. Single-regional kms key resource name which will be used to encrypt resources `projects/{project}/locations/{location}/keyRings/{keyRing}/cryptoKeys/{keyId}`.", + "type": "string" + } + }, + "type": "object" + }, "GoogleCloudDiscoveryengineV1betaSiteVerificationInfo": { "description": "Verification information for target sites in advanced site search.", "id": "GoogleCloudDiscoveryengineV1betaSiteVerificationInfo", @@ -19914,6 +20950,72 @@ } }, "type": "object" + }, + "GoogleTypeDateTime": { + "description": "Represents civil time (or occasionally physical time). This type can represent a civil time in one of a few possible ways: * When utc_offset is set and time_zone is unset: a civil time on a calendar day with a particular offset from UTC. * When time_zone is set and utc_offset is unset: a civil time on a calendar day in a particular time zone. * When neither time_zone nor utc_offset is set: a civil time on a calendar day in local time. The date is relative to the Proleptic Gregorian Calendar. If year, month, or day are 0, the DateTime is considered not to have a specific year, month, or day respectively. This type may also be used to represent a physical time if all the date and time fields are set and either case of the `time_offset` oneof is set. Consider using `Timestamp` message for physical time instead. If your use case also would like to store the user's timezone, that can be done in another field. This type is more flexible than some applications may want. Make sure to document and validate your application's limitations.", + "id": "GoogleTypeDateTime", + "properties": { + "day": { + "description": "Optional. Day of month. Must be from 1 to 31 and valid for the year and month, or 0 if specifying a datetime without a day.", + "format": "int32", + "type": "integer" + }, + "hours": { + "description": "Optional. Hours of day in 24 hour format. Should be from 0 to 23, defaults to 0 (midnight). An API may choose to allow the value \"24:00:00\" for scenarios like business closing time.", + "format": "int32", + "type": "integer" + }, + "minutes": { + "description": "Optional. Minutes of hour of day. Must be from 0 to 59, defaults to 0.", + "format": "int32", + "type": "integer" + }, + "month": { + "description": "Optional. Month of year. Must be from 1 to 12, or 0 if specifying a datetime without a month.", + "format": "int32", + "type": "integer" + }, + "nanos": { + "description": "Optional. Fractions of seconds in nanoseconds. Must be from 0 to 999,999,999, defaults to 0.", + "format": "int32", + "type": "integer" + }, + "seconds": { + "description": "Optional. Seconds of minutes of the time. Must normally be from 0 to 59, defaults to 0. An API may allow the value 60 if it allows leap-seconds.", + "format": "int32", + "type": "integer" + }, + "timeZone": { + "$ref": "GoogleTypeTimeZone", + "description": "Time zone." + }, + "utcOffset": { + "description": "UTC offset. Must be whole seconds, between -18 hours and +18 hours. For example, a UTC offset of -4:00 would be represented as { seconds: -14400 }.", + "format": "google-duration", + "type": "string" + }, + "year": { + "description": "Optional. Year of date. Must be from 1 to 9999, or 0 if specifying a datetime without a year.", + "format": "int32", + "type": "integer" + } + }, + "type": "object" + }, + "GoogleTypeTimeZone": { + "description": "Represents a time zone from the [IANA Time Zone Database](https://www.iana.org/time-zones).", + "id": "GoogleTypeTimeZone", + "properties": { + "id": { + "description": "IANA Time Zone Database time zone. For example \"America/New_York\".", + "type": "string" + }, + "version": { + "description": "Optional. IANA Time Zone Database version number. For example \"2019a\".", + "type": "string" + } + }, + "type": "object" } }, "servicePath": "", diff --git a/discoveryengine/v1/discoveryengine-gen.go b/discoveryengine/v1/discoveryengine-gen.go index 97afddfdc1..d270b68735 100644 --- a/discoveryengine/v1/discoveryengine-gen.go +++ b/discoveryengine/v1/discoveryengine-gen.go @@ -3775,6 +3775,9 @@ type GoogleCloudDiscoveryengineV1CmekConfig struct { // `projects/{project}/locations/{location}/cmekConfig` or // `projects/{project}/locations/{location}/cmekConfigs/{cmekConfig}`. Name string `json:"name,omitempty"` + // SingleRegionKeys: Optional. Single-regional CMEKs that are required for some + // VAIS features. + SingleRegionKeys []*GoogleCloudDiscoveryengineV1SingleRegionKey `json:"singleRegionKeys,omitempty"` // State: Output only. State of the CmekConfig. // // Possible values: @@ -4739,6 +4742,9 @@ type GoogleCloudDiscoveryengineV1DataStore struct { // "MEDIA" - The media industry vertical. // "HEALTHCARE_FHIR" - The healthcare FHIR vertical. IndustryVertical string `json:"industryVertical,omitempty"` + // IsInfobotFaqDataStore: Optional. If set, this DataStore is an Infobot FAQ + // DataStore. + IsInfobotFaqDataStore bool `json:"isInfobotFaqDataStore,omitempty"` // KmsKeyName: Input only. The KMS key to be used to protect this DataStore at // creation time. Must be set for requests that need to comply with CMEK Org // Policy protections. If this field is set and processed successfully, the @@ -5020,7 +5026,8 @@ type GoogleCloudDiscoveryengineV1Document struct { // IndexStatus: Output only. The index status of the document. * If document is // indexed successfully, the index_time field is populated. * Otherwise, if // document is not indexed due to errors, the error_samples field is populated. - // * Otherwise, index_status is unset. + // * Otherwise, if document's index is in progress, the pending_message field + // is populated. IndexStatus *GoogleCloudDiscoveryengineV1DocumentIndexStatus `json:"indexStatus,omitempty"` // IndexTime: Output only. The last time the document was indexed. If this // field is set, the document could be returned in search results. This field @@ -5115,6 +5122,9 @@ type GoogleCloudDiscoveryengineV1DocumentIndexStatus struct { // IndexTime: The time when the document was indexed. If this field is // populated, it means the document has been indexed. IndexTime string `json:"indexTime,omitempty"` + // PendingMessage: Immutable. The message indicates the document index is in + // progress. If this field is populated, the document index is pending. + PendingMessage string `json:"pendingMessage,omitempty"` // ForceSendFields is a list of field names (e.g. "ErrorSamples") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See @@ -5681,143 +5691,792 @@ type GoogleCloudDiscoveryengineV1FetchDomainVerificationStatusResponse struct { // 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 + // ServerResponse contains the HTTP response code and headers from the server. + googleapi.ServerResponse `json:"-"` + // ForceSendFields is a list of field names (e.g. "NextPageToken") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "NextPageToken") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1FetchDomainVerificationStatusResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1FetchDomainVerificationStatusResponse + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1FhirStoreSource: Cloud FhirStore source import +// data from. +type GoogleCloudDiscoveryengineV1FhirStoreSource struct { + // FhirStore: Required. The full resource name of the FHIR store to import data + // from, in the format of + // `projects/{project}/locations/{location}/datasets/{dataset}/fhirStores/{fhir_ + // store}`. + FhirStore string `json:"fhirStore,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 FhirStore export to a specific Cloud Storage directory. + GcsStagingDir string `json:"gcsStagingDir,omitempty"` + // ResourceTypes: The FHIR resource types to import. The resource types should + // be a subset of all supported FHIR resource types + // (https://cloud.google.com/generative-ai-app-builder/docs/fhir-schema-reference#resource-level-specification). + // Default to all supported FHIR resource types if empty. + ResourceTypes []string `json:"resourceTypes,omitempty"` + // UpdateFromLatestPredefinedSchema: Optional. Whether to update the DataStore + // schema to the latest predefined schema. If true, the DataStore schema will + // be updated to include any FHIR fields or resource types that have been added + // since the last import and corresponding FHIR resources will be imported from + // the FHIR store. Note this field cannot be used in conjunction with + // `resource_types`. It should be used after initial import. + UpdateFromLatestPredefinedSchema bool `json:"updateFromLatestPredefinedSchema,omitempty"` + // ForceSendFields is a list of field names (e.g. "FhirStore") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "FhirStore") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1FhirStoreSource) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1FhirStoreSource + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1FirestoreSource: Firestore source import data +// from. +type GoogleCloudDiscoveryengineV1FirestoreSource struct { + // CollectionId: Required. The Firestore collection (or entity) to copy the + // data from with a length limit of 1,500 characters. + CollectionId string `json:"collectionId,omitempty"` + // DatabaseId: Required. The Firestore database to copy the data from with a + // length limit of 256 characters. + DatabaseId string `json:"databaseId,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 Firestore export to a specific Cloud Storage directory. Ensure that the + // Firestore service account has the necessary Cloud Storage Admin permissions + // to access the specified Cloud Storage directory. + GcsStagingDir string `json:"gcsStagingDir,omitempty"` + // ProjectId: The project ID that the Cloud SQL 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"` + // ForceSendFields is a list of field names (e.g. "CollectionId") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "CollectionId") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1FirestoreSource) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1FirestoreSource + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1GcsSource: Cloud Storage location for input +// content. +type GoogleCloudDiscoveryengineV1GcsSource 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 the GENERIC Data Store vertical. * `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 the + // GENERIC Data Store vertical. Supported values for user event imports: * + // `user_event` (default): One JSON UserEvent per line. + DataSchema string `json:"dataSchema,omitempty"` + // InputUris: Required. Cloud Storage URIs to input files. Each 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. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + 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. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1GcsSource) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1GcsSource + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1GenerateGroundedContentRequest: Top-level +// message sent by the client for the `GenerateGroundedContent` method. +type GoogleCloudDiscoveryengineV1GenerateGroundedContentRequest struct { + // Contents: Content of the current conversation with the model. For + // single-turn queries, this is a single instance. For multi-turn queries, this + // is a repeated field that contains conversation history + latest request. + Contents []*GoogleCloudDiscoveryengineV1GroundedGenerationContent `json:"contents,omitempty"` + // GenerationSpec: Content generation specification. + GenerationSpec *GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestGenerationSpec `json:"generationSpec,omitempty"` + // GroundingSpec: Grounding specification. + GroundingSpec *GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestGroundingSpec `json:"groundingSpec,omitempty"` + // SystemInstruction: Content of the system instruction for the current API. + // These instructions will take priority over any other prompt instructions if + // the selected model is supporting them. + SystemInstruction *GoogleCloudDiscoveryengineV1GroundedGenerationContent `json:"systemInstruction,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. "Contents") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "Contents") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1GenerateGroundedContentRequest) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1GenerateGroundedContentRequest + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestDynamicRetrievalCon +// figuration: Describes the options to customize dynamic retrieval. +type GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestDynamicRetrievalConfiguration struct { + // Predictor: Specification for the predictor for dynamic retrieval. + Predictor *GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestDynamicRetrievalConfigurationDynamicRetrievalPredictor `json:"predictor,omitempty"` + // ForceSendFields is a list of field names (e.g. "Predictor") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "Predictor") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestDynamicRetrievalConfiguration) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestDynamicRetrievalConfiguration + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestDynamicRetrievalCon +// figurationDynamicRetrievalPredictor: Describes the predictor settings for +// dynamic retrieval. +type GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestDynamicRetrievalConfigurationDynamicRetrievalPredictor struct { + // Threshold: The value of the threshold. If the predictor will predict a value + // smaller than this, it would suppress grounding in the source. + Threshold float64 `json:"threshold,omitempty"` + // Version: The version of the predictor to be used in dynamic retrieval. + // + // Possible values: + // "VERSION_UNSPECIFIED" - Automatically choose the best version of the + // retrieval predictor. + // "V1_INDEPENDENT" - The V1 model which is evaluating each source + // independently. + Version string `json:"version,omitempty"` + // ForceSendFields is a list of field names (e.g. "Threshold") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "Threshold") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestDynamicRetrievalConfigurationDynamicRetrievalPredictor) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestDynamicRetrievalConfigurationDynamicRetrievalPredictor + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +func (s *GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestDynamicRetrievalConfigurationDynamicRetrievalPredictor) UnmarshalJSON(data []byte) error { + type NoMethod GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestDynamicRetrievalConfigurationDynamicRetrievalPredictor + var s1 struct { + Threshold gensupport.JSONFloat64 `json:"threshold"` + *NoMethod + } + s1.NoMethod = (*NoMethod)(s) + if err := json.Unmarshal(data, &s1); err != nil { + return err + } + s.Threshold = float64(s1.Threshold) + return nil +} + +// GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestGenerationSpec: +// Content generation specification. +type GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestGenerationSpec struct { + // FrequencyPenalty: If specified, custom value for frequency penalty will be + // used. + FrequencyPenalty float64 `json:"frequencyPenalty,omitempty"` + // LanguageCode: Language code for content. Use language tags defined by BCP47 + // (https://www.rfc-editor.org/rfc/bcp/bcp47.txt). + LanguageCode string `json:"languageCode,omitempty"` + // MaxOutputTokens: If specified, custom value for max output tokens will be + // used. + MaxOutputTokens int64 `json:"maxOutputTokens,omitempty"` + // ModelId: Specifies which Vertex model id to use for generation. + ModelId string `json:"modelId,omitempty"` + // PresencePenalty: If specified, custom value for presence penalty will be + // used. + PresencePenalty float64 `json:"presencePenalty,omitempty"` + // Seed: If specified, custom value for the seed will be used. + Seed int64 `json:"seed,omitempty"` + // Temperature: If specified, custom value for the temperature will be used. + Temperature float64 `json:"temperature,omitempty"` + // TopK: If specified, custom value for top-k sampling will be used. + TopK int64 `json:"topK,omitempty"` + // TopP: If specified, custom value for nucleus sampling will be used. + TopP float64 `json:"topP,omitempty"` + // ForceSendFields is a list of field names (e.g. "FrequencyPenalty") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "FrequencyPenalty") to include in + // API requests with the JSON null value. By default, fields with empty values + // are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestGenerationSpec) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestGenerationSpec + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +func (s *GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestGenerationSpec) UnmarshalJSON(data []byte) error { + type NoMethod GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestGenerationSpec + var s1 struct { + FrequencyPenalty gensupport.JSONFloat64 `json:"frequencyPenalty"` + PresencePenalty gensupport.JSONFloat64 `json:"presencePenalty"` + Temperature gensupport.JSONFloat64 `json:"temperature"` + TopP gensupport.JSONFloat64 `json:"topP"` + *NoMethod + } + s1.NoMethod = (*NoMethod)(s) + if err := json.Unmarshal(data, &s1); err != nil { + return err + } + s.FrequencyPenalty = float64(s1.FrequencyPenalty) + s.PresencePenalty = float64(s1.PresencePenalty) + s.Temperature = float64(s1.Temperature) + s.TopP = float64(s1.TopP) + return nil +} + +// GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestGroundingSource: +// Grounding source. +type GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestGroundingSource struct { + // GoogleSearchSource: If set, grounding is performed with Google Search. + GoogleSearchSource *GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestGroundingSourceGoogleSearchSource `json:"googleSearchSource,omitempty"` + // InlineSource: If set, grounding is performed with inline content. + InlineSource *GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestGroundingSourceInlineSource `json:"inlineSource,omitempty"` + // SearchSource: If set, grounding is performed with Vertex AI Search. + SearchSource *GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestGroundingSourceSearchSource `json:"searchSource,omitempty"` + // ForceSendFields is a list of field names (e.g. "GoogleSearchSource") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "GoogleSearchSource") to include + // in API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestGroundingSource) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestGroundingSource + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestGroundingSourceGoog +// leSearchSource: Google Search config parameters. +type GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestGroundingSourceGoogleSearchSource struct { + // DynamicRetrievalConfig: Optional. Specifies the dynamic retrieval + // configuration for the given source. + DynamicRetrievalConfig *GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestDynamicRetrievalConfiguration `json:"dynamicRetrievalConfig,omitempty"` + // ForceSendFields is a list of field names (e.g. "DynamicRetrievalConfig") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "DynamicRetrievalConfig") to + // include in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestGroundingSourceGoogleSearchSource) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestGroundingSourceGoogleSearchSource + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestGroundingSourceInli +// neSource: Message to be used for grounding based on inline content. +type GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestGroundingSourceInlineSource struct { + // Attributes: Attributes associated with the content. Common attributes + // include `source` (indicating where the content was sourced from) and + // `author` (indicating the author of the content). + Attributes map[string]string `json:"attributes,omitempty"` + // GroundingFacts: List of facts to be used for grounding. + GroundingFacts []*GoogleCloudDiscoveryengineV1GroundingFact `json:"groundingFacts,omitempty"` + // 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. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + 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. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestGroundingSourceInlineSource) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestGroundingSourceInlineSource + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestGroundingSourceSear +// chSource: Message to be used for grounding with Vertex AI Search. +type GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestGroundingSourceSearchSource struct { + // Filter: Filter expression to be applied to the search. The syntax is the + // same as SearchRequest.filter. + Filter string `json:"filter,omitempty"` + // MaxResultCount: Number of search results to return. The default value is 10. + // The maximumm allowed value is 10. + MaxResultCount int64 `json:"maxResultCount,omitempty"` + // SafeSearch: If set, safe search is enabled in Vertex AI Search requests. + SafeSearch bool `json:"safeSearch,omitempty"` + // ServingConfig: The resource name of the Engine to use. Format: + // `projects/{project}/locations/{location}/collections/{collection_id}/engines/ + // {engine_id}/servingConfigs/{serving_config_id}` + ServingConfig string `json:"servingConfig,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. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + 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. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestGroundingSourceSearchSource) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestGroundingSourceSearchSource + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestGroundingSpec: +// Grounding specification. +type GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestGroundingSpec struct { + // GroundingSources: Grounding sources. + GroundingSources []*GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestGroundingSource `json:"groundingSources,omitempty"` + // ForceSendFields is a list of field names (e.g. "GroundingSources") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "GroundingSources") to include in + // API requests with the JSON null value. By default, fields with empty values + // are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestGroundingSpec) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestGroundingSpec + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1GenerateGroundedContentResponse: Response for +// the `GenerateGroundedContent` method. +type GoogleCloudDiscoveryengineV1GenerateGroundedContentResponse struct { + // Candidates: Generated candidates. + Candidates []*GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidate `json:"candidates,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the server. + googleapi.ServerResponse `json:"-"` + // ForceSendFields is a list of field names (e.g. "Candidates") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "Candidates") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1GenerateGroundedContentResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1GenerateGroundedContentResponse + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidate: A +// response candidate generated from the model. +type GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidate struct { + // Content: Content of the candidate. + Content *GoogleCloudDiscoveryengineV1GroundedGenerationContent `json:"content,omitempty"` + // GroundingMetadata: Grounding metadata for the generated content. + GroundingMetadata *GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidateGroundingMetadata `json:"groundingMetadata,omitempty"` + // GroundingScore: The overall grounding score for the candidate, in the range + // of [0, 1]. + GroundingScore float64 `json:"groundingScore,omitempty"` + // Index: Index of the candidate. + Index int64 `json:"index,omitempty"` + // 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. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + 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. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidate) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidate + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +func (s *GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidate) UnmarshalJSON(data []byte) error { + type NoMethod GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidate + var s1 struct { + GroundingScore gensupport.JSONFloat64 `json:"groundingScore"` + *NoMethod + } + s1.NoMethod = (*NoMethod)(s) + if err := json.Unmarshal(data, &s1); err != nil { + return err + } + s.GroundingScore = float64(s1.GroundingScore) + return nil +} + +// GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidateGrounding +// Metadata: Citation for the generated content. +type GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidateGroundingMetadata struct { + // GroundingSupport: GroundingSupport across all claims in the answer + // candidate. An support to a fact indicates that the claim is supported by the + // fact. + GroundingSupport []*GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidateGroundingMetadataGroundingSupport `json:"groundingSupport,omitempty"` + // RetrievalMetadata: Retrieval metadata to provide an understanding in the + // retrieval steps performed by the model. There can be multiple such messages + // which can correspond to different parts of the retrieval. This is a + // mechanism used to ensure transparency to our users. + RetrievalMetadata []*GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidateGroundingMetadataRetrievalMetadata `json:"retrievalMetadata,omitempty"` + // SearchEntryPoint: Google search entry for the following-up web searches. + SearchEntryPoint *GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidateGroundingMetadataSearchEntryPoint `json:"searchEntryPoint,omitempty"` + // SupportChunks: List of chunks to be attributed across all claims in the + // candidate. These are derived from the grounding sources supplied in the + // request. + SupportChunks []*GoogleCloudDiscoveryengineV1FactChunk `json:"supportChunks,omitempty"` + // WebSearchQueries: Web search queries for the following-up web search. + WebSearchQueries []string `json:"webSearchQueries,omitempty"` + // ForceSendFields is a list of field names (e.g. "GroundingSupport") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "GroundingSupport") to include in + // API requests with the JSON null value. By default, fields with empty values + // are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidateGroundingMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidateGroundingMetadata + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidateGrounding +// MetadataDynamicRetrievalMetadata: Describes the metadata about dynamic +// retrieval. +type GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidateGroundingMetadataDynamicRetrievalMetadata struct { + // PredictorMetadata: Metadata for the dynamic retrieval predictor. + PredictorMetadata *GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidateGroundingMetadataDynamicRetrievalPredictorMetadata `json:"predictorMetadata,omitempty"` + // ForceSendFields is a list of field names (e.g. "PredictorMetadata") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "PredictorMetadata") to include in + // API requests with the JSON null value. By default, fields with empty values + // are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidateGroundingMetadataDynamicRetrievalMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidateGroundingMetadataDynamicRetrievalMetadata + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidateGrounding +// MetadataDynamicRetrievalPredictorMetadata: Describes the metadata about the +// dynamic retrieval predictor. +type GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidateGroundingMetadataDynamicRetrievalPredictorMetadata struct { + // Prediction: The value of the predictor. This should be between [0, 1] where + // a value of 0 means that the query would not benefit from grounding, while a + // value of 1.0 means that the query would benefit the most. In between values + // allow to differentiate between different usefulness scores for grounding. + Prediction float64 `json:"prediction,omitempty"` + // Version: The version of the predictor which was used in dynamic retrieval. + // + // Possible values: + // "VERSION_UNSPECIFIED" - Unspecified version, should never be used. + // "V1_INDEPENDENT" - The V1 model which is evaluating each source + // independently. + Version string `json:"version,omitempty"` + // ForceSendFields is a list of field names (e.g. "Prediction") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "Prediction") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidateGroundingMetadataDynamicRetrievalPredictorMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidateGroundingMetadataDynamicRetrievalPredictorMetadata + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +func (s *GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidateGroundingMetadataDynamicRetrievalPredictorMetadata) UnmarshalJSON(data []byte) error { + type NoMethod GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidateGroundingMetadataDynamicRetrievalPredictorMetadata + var s1 struct { + Prediction gensupport.JSONFloat64 `json:"prediction"` + *NoMethod + } + s1.NoMethod = (*NoMethod)(s) + if err := json.Unmarshal(data, &s1); err != nil { + return err + } + s.Prediction = float64(s1.Prediction) + return nil +} + +// GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidateGrounding +// MetadataGroundingSupport: Grounding info for a claim in the candidate and +// its support. +type GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidateGroundingMetadataGroundingSupport struct { + // ClaimText: Text for the claim in the candidate. Always provided when a + // support is found. + ClaimText string `json:"claimText,omitempty"` + // SupportChunkIndices: A list of indices (into 'support_chunks') specifying + // the citations associated with the claim. For instance [1,3,4] means that + // support_chunks[1], support_chunks[3], support_chunks[4] are the chunks + // attributed to the claim. + SupportChunkIndices []int64 `json:"supportChunkIndices,omitempty"` + // SupportScore: A score in the range of [0, 1] describing how grounded is a + // specific claim in the support chunks indicated. Higher value means that the + // claim is better supported by the chunks. + SupportScore float64 `json:"supportScore,omitempty"` + // ForceSendFields is a list of field names (e.g. "ClaimText") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "ClaimText") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidateGroundingMetadataGroundingSupport) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidateGroundingMetadataGroundingSupport + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +func (s *GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidateGroundingMetadataGroundingSupport) UnmarshalJSON(data []byte) error { + type NoMethod GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidateGroundingMetadataGroundingSupport + var s1 struct { + SupportScore gensupport.JSONFloat64 `json:"supportScore"` + *NoMethod + } + s1.NoMethod = (*NoMethod)(s) + if err := json.Unmarshal(data, &s1); err != nil { + return err + } + s.SupportScore = float64(s1.SupportScore) + return nil +} + +// GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidateGrounding +// MetadataRetrievalMetadata: Describes the metadata associated with a +// retrieval step. +type GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidateGroundingMetadataRetrievalMetadata struct { + // DynamicRetrievalMetadata: Metadata for dynamic retrieval. + DynamicRetrievalMetadata *GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidateGroundingMetadataDynamicRetrievalMetadata `json:"dynamicRetrievalMetadata,omitempty"` + // Source: Describes the source to which the metadata is referring to. + // + // Possible values: + // "SOURCE_UNSPECIFIED" - Unspecified source. + // "VERTEX_AI_SEARCH" - Vertex AI search. + // "GOOGLE_SEARCH" - Google Search. + // "INLINE_CONTENT" - User inline provided content. + // "GOOGLE_MAPS" - Google Maps. + Source string `json:"source,omitempty"` + // ForceSendFields is a list of field names (e.g. "DynamicRetrievalMetadata") + // to unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "NextPageToken") to include in API - // requests with the JSON null value. By default, fields with empty values are - // omitted from API requests. See + // NullFields is a list of field names (e.g. "DynamicRetrievalMetadata") to + // include in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1FetchDomainVerificationStatusResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1FetchDomainVerificationStatusResponse +func (s GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidateGroundingMetadataRetrievalMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidateGroundingMetadataRetrievalMetadata return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1FhirStoreSource: Cloud FhirStore source import -// data from. -type GoogleCloudDiscoveryengineV1FhirStoreSource struct { - // FhirStore: Required. The full resource name of the FHIR store to import data - // from, in the format of - // `projects/{project}/locations/{location}/datasets/{dataset}/fhirStores/{fhir_ - // store}`. - FhirStore string `json:"fhirStore,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 FhirStore export to a specific Cloud Storage directory. - GcsStagingDir string `json:"gcsStagingDir,omitempty"` - // ResourceTypes: The FHIR resource types to import. The resource types should - // be a subset of all supported FHIR resource types - // (https://cloud.google.com/generative-ai-app-builder/docs/fhir-schema-reference#resource-level-specification). - // Default to all supported FHIR resource types if empty. - ResourceTypes []string `json:"resourceTypes,omitempty"` - // UpdateFromLatestPredefinedSchema: Optional. Whether to update the DataStore - // schema to the latest predefined schema. If true, the DataStore schema will - // be updated to include any FHIR fields or resource types that have been added - // since the last import and corresponding FHIR resources will be imported from - // the FHIR store. Note this field cannot be used in conjunction with - // `resource_types`. It should be used after initial import. - UpdateFromLatestPredefinedSchema bool `json:"updateFromLatestPredefinedSchema,omitempty"` - // ForceSendFields is a list of field names (e.g. "FhirStore") to +// GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidateGrounding +// MetadataSearchEntryPoint: Google search entry point. +type GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidateGroundingMetadataSearchEntryPoint struct { + // RenderedContent: Web content snippet that can be embedded in a web page or + // an app webview. + RenderedContent string `json:"renderedContent,omitempty"` + // SdkBlob: Base64 encoded JSON representing array of tuple. + SdkBlob string `json:"sdkBlob,omitempty"` + // ForceSendFields is a list of field names (e.g. "RenderedContent") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "FhirStore") to include in API - // requests with the JSON null value. By default, fields with empty values are - // omitted from API requests. See + // NullFields is a list of field names (e.g. "RenderedContent") to include in + // API requests with the JSON null value. By default, fields with empty values + // are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1FhirStoreSource) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1FhirStoreSource +func (s GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidateGroundingMetadataSearchEntryPoint) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidateGroundingMetadataSearchEntryPoint return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1FirestoreSource: Firestore source import data -// from. -type GoogleCloudDiscoveryengineV1FirestoreSource struct { - // CollectionId: Required. The Firestore collection (or entity) to copy the - // data from with a length limit of 1,500 characters. - CollectionId string `json:"collectionId,omitempty"` - // DatabaseId: Required. The Firestore database to copy the data from with a - // length limit of 256 characters. - DatabaseId string `json:"databaseId,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 Firestore export to a specific Cloud Storage directory. Ensure that the - // Firestore service account has the necessary Cloud Storage Admin permissions - // to access the specified Cloud Storage directory. - GcsStagingDir string `json:"gcsStagingDir,omitempty"` - // ProjectId: The project ID that the Cloud SQL 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"` - // ForceSendFields is a list of field names (e.g. "CollectionId") to - // unconditionally include in API requests. By default, fields with empty or - // default values are omitted from API requests. See +// GoogleCloudDiscoveryengineV1GroundedGenerationContent: Base structured +// datatype containing multi-part content of a message. +type GoogleCloudDiscoveryengineV1GroundedGenerationContent struct { + // Parts: Ordered `Parts` that constitute a single message. + Parts []*GoogleCloudDiscoveryengineV1GroundedGenerationContentPart `json:"parts,omitempty"` + // Role: Producer of the content. Must be either `user` or `model`. Intended to + // be used for multi-turn conversations. Otherwise, it can be left unset. + Role string `json:"role,omitempty"` + // ForceSendFields is a list of field names (e.g. "Parts") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "CollectionId") to include in API + // NullFields is a list of field names (e.g. "Parts") to include in API // requests with the JSON null value. By default, fields with empty values are // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1FirestoreSource) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1FirestoreSource +func (s GoogleCloudDiscoveryengineV1GroundedGenerationContent) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1GroundedGenerationContent return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1GcsSource: Cloud Storage location for input +// GoogleCloudDiscoveryengineV1GroundedGenerationContentPart: Single part of // content. -type GoogleCloudDiscoveryengineV1GcsSource 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 the GENERIC Data Store vertical. * `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 the - // GENERIC Data Store vertical. Supported values for user event imports: * - // `user_event` (default): One JSON UserEvent per line. - DataSchema string `json:"dataSchema,omitempty"` - // InputUris: Required. Cloud Storage URIs to input files. Each 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. See +type GoogleCloudDiscoveryengineV1GroundedGenerationContentPart struct { + // Text: Inline text. + Text string `json:"text,omitempty"` + // ForceSendFields is a list of field names (e.g. "Text") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. 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. See + // NullFields is a list of field names (e.g. "Text") to include in API requests + // with the JSON null value. By default, fields with empty values are omitted + // from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1GcsSource) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1GcsSource +func (s GoogleCloudDiscoveryengineV1GroundedGenerationContentPart) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1GroundedGenerationContentPart return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } @@ -9438,6 +10097,32 @@ func (s GoogleCloudDiscoveryengineV1SessionTurn) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudDiscoveryengineV1SingleRegionKey: Metadata for single-regional +// CMEKs. +type GoogleCloudDiscoveryengineV1SingleRegionKey struct { + // KmsKey: Required. Single-regional kms key resource name which will be used + // to encrypt resources + // `projects/{project}/locations/{location}/keyRings/{keyRing}/cryptoKeys/{keyId + // }`. + KmsKey string `json:"kmsKey,omitempty"` + // ForceSendFields is a list of field names (e.g. "KmsKey") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "KmsKey") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1SingleRegionKey) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1SingleRegionKey + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudDiscoveryengineV1SiteSearchEngine: SiteSearchEngine captures // DataStore level site search persisting configurations. It is a singleton // value per data store. @@ -10270,6 +10955,38 @@ func (s GoogleCloudDiscoveryengineV1alphaAclConfig) MarshalJSON() ([]byte, error return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudDiscoveryengineV1alphaActionConfig: Informations to support +// actions on the connector. +type GoogleCloudDiscoveryengineV1alphaActionConfig struct { + // ActionParams: Required. Params needed to support actions in the format of + // (Key, Value) pairs. Required parameters for sources that support OAUTH, i.e. + // `gmail`, `google_calendar`, `jira`, `workday`, `salesforce`, `confluence`: * + // Key: `client_id` * Value: type STRING. The client id for the service + // provider to identify your application. * Key: `client_secret` * Value:type + // STRING. The client secret generated by the application's authorization + // server. + ActionParams googleapi.RawMessage `json:"actionParams,omitempty"` + // IsActionConfigured: Output only. The connector contains the necessary + // parameters and is configured to support actions. + IsActionConfigured bool `json:"isActionConfigured,omitempty"` + // ForceSendFields is a list of field names (e.g. "ActionParams") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "ActionParams") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1alphaActionConfig) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaActionConfig + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudDiscoveryengineV1alphaAdvancedSiteSearchConfig: Configuration // data for advance site search. type GoogleCloudDiscoveryengineV1alphaAdvancedSiteSearchConfig struct { @@ -11034,6 +11751,9 @@ type GoogleCloudDiscoveryengineV1alphaCmekConfig struct { // `projects/{project}/locations/{location}/cmekConfig` or // `projects/{project}/locations/{location}/cmekConfigs/{cmekConfig}`. Name string `json:"name,omitempty"` + // SingleRegionKeys: Optional. Single-regional CMEKs that are required for some + // VAIS features. + SingleRegionKeys []*GoogleCloudDiscoveryengineV1alphaSingleRegionKey `json:"singleRegionKeys,omitempty"` // State: Output only. State of the CmekConfig. // // Possible values: @@ -11065,6 +11785,47 @@ func (s GoogleCloudDiscoveryengineV1alphaCmekConfig) MarshalJSON() ([]byte, erro return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudDiscoveryengineV1alphaCollection: Collection is a container for +// configuring resources and access to a set of DataStores. +type GoogleCloudDiscoveryengineV1alphaCollection struct { + // CreateTime: Output only. Timestamp the Collection was created at. + CreateTime string `json:"createTime,omitempty"` + // DataConnector: Output only. The data connector, if present, manages the + // connection for data stores in the Collection. To set up the connector, use + // DataConnectorService.SetUpDataConnector method, which creates a new + // Collection while setting up the DataConnector singleton resource. Setting up + // connector on an existing Collection is not supported. This output only field + // contains a subset of the DataConnector fields, including `name`, + // `data_source`, `entities.entity_name` and `entities.data_store`. To get more + // details about a data connector, use the DataConnector.GetDataConnector + // method. + DataConnector *GoogleCloudDiscoveryengineV1alphaDataConnector `json:"dataConnector,omitempty"` + // DisplayName: Required. The Collection 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"` + // Name: Immutable. The full resource name of the Collection. Format: + // `projects/{project}/locations/{location}/collections/{collection_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. "CreateTime") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "CreateTime") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1alphaCollection) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaCollection + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudDiscoveryengineV1alphaCondition: Defines circumstances to be // checked before allowing a behavior type GoogleCloudDiscoveryengineV1alphaCondition struct { @@ -11148,6 +11909,135 @@ func (s GoogleCloudDiscoveryengineV1alphaConditionTimeRange) MarshalJSON() ([]by return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudDiscoveryengineV1alphaConnectorRun: A data sync run of +// DataConnector. After DataConnector is successfully initialized, data syncs +// are scheduled at DataConnector.refresh_interval. A ConnectorRun represents a +// data sync either in the past or onging that the moment. // +type GoogleCloudDiscoveryengineV1alphaConnectorRun struct { + // EndTime: Output only. The time when the connector run ended. + EndTime string `json:"endTime,omitempty"` + // EntityRuns: Output only. The details of the entities synced at the + // ConnectorRun. Each ConnectorRun consists of syncing one or more entities. + EntityRuns []*GoogleCloudDiscoveryengineV1alphaConnectorRunEntityRun `json:"entityRuns,omitempty"` + // Errors: Contains info about errors incurred during the sync. Only exist if + // running into an error state. Contains error code and error message. Use with + // the `state` field. + Errors []*GoogleRpcStatus `json:"errors,omitempty"` + // LatestPauseTime: Output only. The time when the connector run was most + // recently paused. + LatestPauseTime string `json:"latestPauseTime,omitempty"` + // Name: Output only. The full resource name of the Connector Run. Format: + // `projects/*/locations/*/collections/*/dataConnector/connectorRuns/*`. The + // `connector_run_id` is system-generated. + Name string `json:"name,omitempty"` + // StartTime: Output only. The time when the connector run started. + StartTime string `json:"startTime,omitempty"` + // State: Output only. The state of the sync run. + // + // Possible values: + // "STATE_UNSPECIFIED" - Default value. + // "RUNNING" - The data sync is ongoing. + // "SUCCEEDED" - The data sync is finished. + // "FAILED" - The data sync is failed. + // "OVERRUN" - Data sync has been running longer than expected and is still + // running at the time the next run is supposed to start. + // "CANCELLED" - Data sync was scheduled but has been cancelled. + // "PENDING" - Data sync is about to start. + // "WARNING" - The data sync completed with non-fatal errors. + State string `json:"state,omitempty"` + // StateUpdateTime: Timestamp at which the connector run sync state was last + // updated. + StateUpdateTime string `json:"stateUpdateTime,omitempty"` + // Trigger: Output only. The trigger for this ConnectorRun. + // + // Possible values: + // "TRIGGER_UNSPECIFIED" - Default value. + // "SCHEDULER" - ConnectorRun triggered by scheduler if connector has + // PERIODIC sync mode. + // "INITIALIZATION" - ConnectorRun auto triggered by connector + // initialization. + // "RESUME" - ConnectorRun auto triggered by resuming connector. + // "MANUAL" - ConnectorRun triggered by user manually. + Trigger string `json:"trigger,omitempty"` + // ForceSendFields is a list of field names (e.g. "EndTime") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "EndTime") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1alphaConnectorRun) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaConnectorRun + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaConnectorRunEntityRun: Represents an entity +// that was synced in this ConnectorRun. +type GoogleCloudDiscoveryengineV1alphaConnectorRunEntityRun struct { + // EntityName: The name of the source entity. + EntityName string `json:"entityName,omitempty"` + // ErrorRecordCount: The total number of documents failed at sync at any stage + // (extraction, indexing, etc). + ErrorRecordCount int64 `json:"errorRecordCount,omitempty,string"` + // Errors: The errors from the entity's sync run. Only exist if running into an + // error state. Contains error code and error message. + Errors []*GoogleRpcStatus `json:"errors,omitempty"` + // ExtractedRecordCount: The number of documents extracted from connector + // source, ready to be ingested to UCS. + ExtractedRecordCount int64 `json:"extractedRecordCount,omitempty,string"` + // IndexedRecordCount: The number of documents indexed. + IndexedRecordCount int64 `json:"indexedRecordCount,omitempty,string"` + // SourceApiRequestCount: The number of requests sent to 3p API. + SourceApiRequestCount int64 `json:"sourceApiRequestCount,omitempty,string"` + // State: The state of the entity's sync run. + // + // Possible values: + // "STATE_UNSPECIFIED" - Default value. + // "RUNNING" - The data sync is ongoing. + // "SUCCEEDED" - The data sync is finished. + // "FAILED" - The data sync is failed. + // "OVERRUN" - Data sync has been running longer than expected and is still + // running at the time the next run is supposed to start. + // "CANCELLED" - Data sync was scheduled but has been cancelled. + // "PENDING" - Data sync is about to start. + // "WARNING" - The data sync completed with non-fatal errors. + State string `json:"state,omitempty"` + // StateUpdateTime: Timestamp at which the entity sync state was last updated. + StateUpdateTime string `json:"stateUpdateTime,omitempty"` + // StatsUpdateTime: The timestamp for either extracted_documents_count, + // indexed_documents_count and error_documents_count was last updated. + StatsUpdateTime string `json:"statsUpdateTime,omitempty"` + // SyncType: Sync type of this run. + // + // Possible values: + // "SYNC_TYPE_UNSPECIFIED" - Sync type unspecified. + // "FULL" - Sync triggers full sync of all documents. + // "INCREMENTAL" - Incremental sync of updated documents. + SyncType string `json:"syncType,omitempty"` + // ForceSendFields is a list of field names (e.g. "EntityName") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "EntityName") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1alphaConnectorRunEntityRun) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaConnectorRunEntityRun + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudDiscoveryengineV1alphaControl: Defines a conditioned behavior to // employ during serving. Must be attached to a ServingConfig to be considered // at serving time. Permitted actions dependent on `SolutionType`. @@ -11541,27 +12431,216 @@ func (s GoogleCloudDiscoveryengineV1alphaCreateTargetSiteMetadata) MarshalJSON() return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaCustomFineTuningSpec: Defines custom fine -// tuning spec. -type GoogleCloudDiscoveryengineV1alphaCustomFineTuningSpec struct { - // EnableSearchAdaptor: Whether or not to enable and include custom fine tuned - // search adaptor model. - EnableSearchAdaptor bool `json:"enableSearchAdaptor,omitempty"` - // ForceSendFields is a list of field names (e.g. "EnableSearchAdaptor") to +// GoogleCloudDiscoveryengineV1alphaCustomFineTuningSpec: Defines custom fine +// tuning spec. +type GoogleCloudDiscoveryengineV1alphaCustomFineTuningSpec struct { + // EnableSearchAdaptor: Whether or not to enable and include custom fine tuned + // search adaptor model. + EnableSearchAdaptor bool `json:"enableSearchAdaptor,omitempty"` + // ForceSendFields is a list of field names (e.g. "EnableSearchAdaptor") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "EnableSearchAdaptor") to include + // in API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1alphaCustomFineTuningSpec) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaCustomFineTuningSpec + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaDataConnector: Manages the connection to +// external data sources for all data stores grouped under a Collection. It's a +// singleton resource of Collection. The initialization is only supported +// through SetUpDataConnector method, which will create a new Collection and +// initialize its DataConnector. // +type GoogleCloudDiscoveryengineV1alphaDataConnector struct { + // ActionConfig: Optional. Action configurations to make the connector support + // actions. + ActionConfig *GoogleCloudDiscoveryengineV1alphaActionConfig `json:"actionConfig,omitempty"` + // AutoRunDisabled: Indicates whether the connector is disabled for auto run. + // It can be used to pause periodical and real time sync. + AutoRunDisabled bool `json:"autoRunDisabled,omitempty"` + // BlockingReasons: Output only. User actions that must be completed before the + // connector can start syncing data. + // + // Possible values: + // "BLOCKING_REASON_UNSPECIFIED" - Default value. + // "ALLOWLIST_STATIC_IP" - Connector requires customer to allowlist static + // IPs. + // "ALLOWLIST_IN_SERVICE_ATTACHMENT" - Connector requires customer to + // allowlist our project in their service attachment. + BlockingReasons []string `json:"blockingReasons,omitempty"` + // CreateTime: Output only. Timestamp the DataConnector was created at. + CreateTime string `json:"createTime,omitempty"` + // DataSource: Required. The name of the data source. Supported values: + // `salesforce`, `jira`, `confluence`, `bigquery`. + DataSource string `json:"dataSource,omitempty"` + // DestinationConfigs: Optional. Any target destinations used to connect to + // third-party services. + DestinationConfigs []*GoogleCloudDiscoveryengineV1alphaDestinationConfig `json:"destinationConfigs,omitempty"` + // Entities: List of entities from the connected data source to ingest. + Entities []*GoogleCloudDiscoveryengineV1alphaDataConnectorSourceEntity `json:"entities,omitempty"` + // Errors: Output only. The errors from initialization or from the latest + // connector run. + Errors []*GoogleRpcStatus `json:"errors,omitempty"` + // IdentityRefreshInterval: The refresh interval to sync the Access Control + // List information for the documents ingested by this connector. If not set, + // the access control list will be refreshed at the default interval of 30 + // minutes. The identity refresh interval can be at least 30 minutes and at + // most 7 days. + IdentityRefreshInterval string `json:"identityRefreshInterval,omitempty"` + // IdentityScheduleConfig: The configuration for the identity data + // synchronization runs. This contains the refresh interval to sync the Access + // Control List information for the documents ingested by this connector. + IdentityScheduleConfig *GoogleCloudDiscoveryengineV1alphaIdentityScheduleConfig `json:"identityScheduleConfig,omitempty"` + // KmsKeyName: Input only. The KMS key to be used to protect the DataStores + // managed by this connector. Must be set for requests that need to comply with + // CMEK Org Policy protections. If this field is set and processed + // successfully, the DataStores created by this connector will be protected by + // the KMS key. + KmsKeyName string `json:"kmsKeyName,omitempty"` + // LastSyncTime: Output only. For periodic connectors only, the last time a + // data sync was completed. + LastSyncTime string `json:"lastSyncTime,omitempty"` + // LatestPauseTime: Output only. The most recent timestamp when this + // DataConnector was paused, affecting all functionalities such as data + // synchronization. Pausing a connector has the following effects: - All + // functionalities, including data synchronization, are halted. - Any ongoing + // data synchronization job will be canceled. - No future data synchronization + // runs will be scheduled nor can be triggered. + LatestPauseTime string `json:"latestPauseTime,omitempty"` + // Name: Output only. The full resource name of the Data Connector. Format: + // `projects/*/locations/*/collections/*/dataConnector`. + Name string `json:"name,omitempty"` + // NextSyncTime: The UTC time when the next data sync is expected to start for + // the Data Connector. Customers are only able to specify the hour and minute + // to schedule the data sync. This is utilized when the data connector has a + // refresh interval greater than 1 day. + NextSyncTime *GoogleTypeDateTime `json:"nextSyncTime,omitempty"` + // Params: Required. Params needed to access the source in the format of (Key, + // Value) pairs. Required parameters for all data sources: * Key: + // `instance_uri` * Value: type STRING. The uri to access the data source. + // Required parameters for sources that support OAUTH, i.e. `salesforce`: * + // Key: `client_id` * Value: type STRING. The client id for the third party + // service provider to identify your application. * Key: `client_secret` * + // Value:type STRING. The client secret generated by the third party + // authorization server. * Key: `access_token` * Value: type STRING. OAuth + // token for UCS to access to the protected resource. * Key: `refresh_token` * + // Value: type STRING. OAuth refresh token for UCS to obtain a new access token + // without user interaction. Required parameters for sources that support basic + // API token auth, i.e. `jira`, `confluence`: * Key: `user_account` * Value: + // type STRING. The username or email with the source. * Key: `api_token` * + // Value: type STRING. The API token generated for the source account, that is + // used for authenticating anywhere where you would have used a password. + // Example: ```json { "instance_uri": "https://xxx.atlassian.net", + // "user_account": "xxxx.xxx@xxx.com", "api_token": "test-token" } ``` Optional + // parameter to specify the authorization type to use for multiple + // authorization types support: * Key: `auth_type` * Value: type STRING. The + // authorization type for the data source. Supported values: `BASIC_AUTH`, + // `OAUTH`, `OAUTH_ACCESS_TOKEN`, `OAUTH_TWO_LEGGED`, `OAUTH_JWT_BEARER`, + // `OAUTH_PASSWORD_GRANT`, `JWT`, `API_TOKEN`, `FEDERATED_CREDENTIAL`. + Params googleapi.RawMessage `json:"params,omitempty"` + // PrivateConnectivityProjectId: Output only. The tenant project ID associated + // with private connectivity connectors. This project must be allowlisted by in + // order for the connector to function. + PrivateConnectivityProjectId string `json:"privateConnectivityProjectId,omitempty"` + // RefreshInterval: Required. The refresh interval for data sync. If duration + // is set to 0, the data will be synced in real time. The streaming feature is + // not supported yet. The minimum is 30 minutes and maximum is 7 days. + RefreshInterval string `json:"refreshInterval,omitempty"` + // State: Output only. State of the connector. + // + // Possible values: + // "STATE_UNSPECIFIED" - Default value. + // "CREATING" - The connector is being set up. + // "ACTIVE" - The connector is successfully set up and awaiting next sync + // run. + // "FAILED" - The connector is in error. The error details can be found in + // DataConnector.errors. If the error is unfixable, the DataConnector can be + // deleted by [CollectionService.DeleteCollection] API. + // "RUNNING" - The connector is actively syncing records from the data + // source. + // "WARNING" - The connector has completed a sync run, but encountered + // non-fatal errors. + State string `json:"state,omitempty"` + // StaticIpAddresses: Output only. The static IP addresses used by this + // connector. + StaticIpAddresses []string `json:"staticIpAddresses,omitempty"` + // StaticIpEnabled: Optional. Whether customer has enabled static IP addresses + // for this connector. + StaticIpEnabled bool `json:"staticIpEnabled,omitempty"` + // SyncMode: The data synchronization mode supported by the data connector. + // + // Possible values: + // "PERIODIC" - The connector will sync data periodically based on the + // refresh_interval. Use it with auto_run_disabled to pause the periodic sync, + // or indicate a one-time sync. + SyncMode string `json:"syncMode,omitempty"` + // UpdateTime: Output only. Timestamp the DataConnector was last updated. + UpdateTime string `json:"updateTime,omitempty"` + // ForceSendFields is a list of field names (e.g. "ActionConfig") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "ActionConfig") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1alphaDataConnector) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaDataConnector + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaDataConnectorSourceEntity: Represents an +// entity in the data source. For example, the `Account` object in Salesforce. +type GoogleCloudDiscoveryengineV1alphaDataConnectorSourceEntity struct { + // DataStore: Output only. The full resource name of the associated data store + // for the source entity. Format: + // `projects/*/locations/*/collections/*/dataStores/*`. When the connector is + // initialized by the DataConnectorService.SetUpDataConnector method, a + // DataStore is automatically created for each source entity. + DataStore string `json:"dataStore,omitempty"` + // EntityName: The name of the entity. Supported values by data source: * + // Salesforce: `Lead`, `Opportunity`, `Contact`, `Account`, `Case`, `Contract`, + // `Campaign` * Jira: `Issue` * Confluence: `Content`, `Space` + EntityName string `json:"entityName,omitempty"` + // KeyPropertyMappings: Attributes for indexing. Key: Field name. Value: The + // key property to map a field to, such as `title`, and `description`. + // Supported key properties: * `title`: The title for data record. This would + // be displayed on search results. * `description`: The description for data + // record. This would be displayed on search results. + KeyPropertyMappings map[string]string `json:"keyPropertyMappings,omitempty"` + // Params: The parameters for the entity to facilitate data ingestion. E.g. for + // BQ connectors: * Key: `document_id_column` * Value: type STRING. The value + // of the column id. + Params googleapi.RawMessage `json:"params,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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "EnableSearchAdaptor") to include - // in API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. See + // NullFields is a list of field names (e.g. "DataStore") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaCustomFineTuningSpec) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaCustomFineTuningSpec +func (s GoogleCloudDiscoveryengineV1alphaDataConnectorSourceEntity) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaDataConnectorSourceEntity return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } @@ -11617,6 +12696,9 @@ type GoogleCloudDiscoveryengineV1alphaDataStore struct { // "MEDIA" - The media industry vertical. // "HEALTHCARE_FHIR" - The healthcare FHIR vertical. IndustryVertical string `json:"industryVertical,omitempty"` + // IsInfobotFaqDataStore: Optional. If set, this DataStore is an Infobot FAQ + // DataStore. + IsInfobotFaqDataStore bool `json:"isInfobotFaqDataStore,omitempty"` // KmsKeyName: Input only. The KMS key to be used to protect this DataStore at // creation time. Must be set for requests that need to comply with CMEK Org // Policy protections. If this field is set and processed successfully, the @@ -11772,6 +12854,33 @@ func (s GoogleCloudDiscoveryengineV1alphaDedicatedCrawlRateTimeSeries) MarshalJS return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudDiscoveryengineV1alphaDeleteCollectionMetadata: Metadata related +// to the progress of the CollectionService.UpdateCollection operation. This +// will be returned by the google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1alphaDeleteCollectionMetadata struct { + // CreateTime: Operation create time. + CreateTime string `json:"createTime,omitempty"` + // UpdateTime: Operation last update time. If the operation is done, this is + // also the finish time. + UpdateTime string `json:"updateTime,omitempty"` + // ForceSendFields is a list of field names (e.g. "CreateTime") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "CreateTime") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1alphaDeleteCollectionMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaDeleteCollectionMetadata + return gensupport.MarshalJSON(NoMethod(s), 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. @@ -11931,6 +13040,59 @@ func (s GoogleCloudDiscoveryengineV1alphaDeleteTargetSiteMetadata) MarshalJSON() return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudDiscoveryengineV1alphaDestinationConfig: Defines target endpoints +// used to connect to third-party sources. +type GoogleCloudDiscoveryengineV1alphaDestinationConfig struct { + // Destinations: Optional. The destinations for the corresponding key. + Destinations []*GoogleCloudDiscoveryengineV1alphaDestinationConfigDestination `json:"destinations,omitempty"` + // Key: Optional. Unique destination identifier that is supported by the + // connector. + Key string `json:"key,omitempty"` + // Params: Optional. Additional parameters for this destination config. + Params googleapi.RawMessage `json:"params,omitempty"` + // ForceSendFields is a list of field names (e.g. "Destinations") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "Destinations") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1alphaDestinationConfig) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaDestinationConfig + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaDestinationConfigDestination: Defines a +// target endpoint +type GoogleCloudDiscoveryengineV1alphaDestinationConfigDestination struct { + // Host: Publicly routable host. + Host string `json:"host,omitempty"` + // Port: Optional. Target port number accepted by the destination. + Port int64 `json:"port,omitempty"` + // ForceSendFields is a list of field names (e.g. "Host") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "Host") to include in API requests + // with the JSON null value. By default, fields with empty values are omitted + // from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1alphaDestinationConfigDestination) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaDestinationConfigDestination + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudDiscoveryengineV1alphaDisableAdvancedSiteSearchMetadata: Metadata // related to the progress of the // SiteSearchEngineService.DisableAdvancedSiteSearch operation. This will be @@ -12997,6 +14159,33 @@ func (s GoogleCloudDiscoveryengineV1alphaGetUriPatternDocumentDataResponse) Mars return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudDiscoveryengineV1alphaIdentityScheduleConfig: The configuration +// for the identity data synchronization runs. +type GoogleCloudDiscoveryengineV1alphaIdentityScheduleConfig struct { + // RefreshInterval: Optional. The refresh interval to sync the Access Control + // List information for the documents ingested by this connector. If not set, + // the access control list will be refreshed at the default interval of 30 + // minutes. The identity refresh interval can be at least 30 minutes and at + // most 7 days. + RefreshInterval string `json:"refreshInterval,omitempty"` + // ForceSendFields is a list of field names (e.g. "RefreshInterval") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "RefreshInterval") to include in + // API requests with the JSON null value. By default, fields with empty values + // are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1alphaIdentityScheduleConfig) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaIdentityScheduleConfig + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudDiscoveryengineV1alphaIdpConfig: Identity Provider Config. type GoogleCloudDiscoveryengineV1alphaIdpConfig struct { // ExternalIdpConfig: External Identity provider config. @@ -15516,6 +16705,11 @@ func (s GoogleCloudDiscoveryengineV1alphaSessionTurn) MarshalJSON() ([]byte, err return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudDiscoveryengineV1alphaSetUpDataConnectorMetadata: Metadata for +// DataConnectorService.SetUpDataConnector method. +type GoogleCloudDiscoveryengineV1alphaSetUpDataConnectorMetadata struct { +} + // GoogleCloudDiscoveryengineV1alphaSetUriPatternDocumentDataMetadata: Metadata // related to the progress of the // SiteSearchEngineService.SetUriPatternDocumentData operation. This will be @@ -15549,6 +16743,32 @@ func (s GoogleCloudDiscoveryengineV1alphaSetUriPatternDocumentDataMetadata) Mars type GoogleCloudDiscoveryengineV1alphaSetUriPatternDocumentDataResponse struct { } +// GoogleCloudDiscoveryengineV1alphaSingleRegionKey: Metadata for +// single-regional CMEKs. +type GoogleCloudDiscoveryengineV1alphaSingleRegionKey struct { + // KmsKey: Required. Single-regional kms key resource name which will be used + // to encrypt resources + // `projects/{project}/locations/{location}/keyRings/{keyRing}/cryptoKeys/{keyId + // }`. + KmsKey string `json:"kmsKey,omitempty"` + // ForceSendFields is a list of field names (e.g. "KmsKey") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "KmsKey") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1alphaSingleRegionKey) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSingleRegionKey + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudDiscoveryengineV1alphaSiteVerificationInfo: Verification // information for target sites in advanced site search. type GoogleCloudDiscoveryengineV1alphaSiteVerificationInfo struct { @@ -15852,6 +17072,33 @@ func (s GoogleCloudDiscoveryengineV1alphaUpdateCmekConfigMetadata) MarshalJSON() return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudDiscoveryengineV1alphaUpdateCollectionMetadata: Metadata related +// to the progress of the CollectionService.UpdateCollection operation. This +// will be returned by the google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1alphaUpdateCollectionMetadata struct { + // CreateTime: Operation create time. + CreateTime string `json:"createTime,omitempty"` + // UpdateTime: Operation last update time. If the operation is done, this is + // also the finish time. + UpdateTime string `json:"updateTime,omitempty"` + // ForceSendFields is a list of field names (e.g. "CreateTime") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "CreateTime") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1alphaUpdateCollectionMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaUpdateCollectionMetadata + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudDiscoveryengineV1alphaUpdateSchemaMetadata: Metadata for // UpdateSchema LRO. type GoogleCloudDiscoveryengineV1alphaUpdateSchemaMetadata struct { @@ -16085,6 +17332,9 @@ type GoogleCloudDiscoveryengineV1betaCmekConfig struct { // `projects/{project}/locations/{location}/cmekConfig` or // `projects/{project}/locations/{location}/cmekConfigs/{cmekConfig}`. Name string `json:"name,omitempty"` + // SingleRegionKeys: Optional. Single-regional CMEKs that are required for some + // VAIS features. + SingleRegionKeys []*GoogleCloudDiscoveryengineV1betaSingleRegionKey `json:"singleRegionKeys,omitempty"` // State: Output only. State of the CmekConfig. // // Possible values: @@ -16611,6 +17861,9 @@ type GoogleCloudDiscoveryengineV1betaDataStore struct { // "MEDIA" - The media industry vertical. // "HEALTHCARE_FHIR" - The healthcare FHIR vertical. IndustryVertical string `json:"industryVertical,omitempty"` + // IsInfobotFaqDataStore: Optional. If set, this DataStore is an Infobot FAQ + // DataStore. + IsInfobotFaqDataStore bool `json:"isInfobotFaqDataStore,omitempty"` // KmsKeyName: Input only. The KMS key to be used to protect this DataStore at // creation time. Must be set for requests that need to comply with CMEK Org // Policy protections. If this field is set and processed successfully, the @@ -19471,6 +20724,32 @@ func (s GoogleCloudDiscoveryengineV1betaSearchRequestSpellCorrectionSpec) Marsha return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudDiscoveryengineV1betaSingleRegionKey: Metadata for +// single-regional CMEKs. +type GoogleCloudDiscoveryengineV1betaSingleRegionKey struct { + // KmsKey: Required. Single-regional kms key resource name which will be used + // to encrypt resources + // `projects/{project}/locations/{location}/keyRings/{keyRing}/cryptoKeys/{keyId + // }`. + KmsKey string `json:"kmsKey,omitempty"` + // ForceSendFields is a list of field names (e.g. "KmsKey") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "KmsKey") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1betaSingleRegionKey) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaSingleRegionKey + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudDiscoveryengineV1betaSiteVerificationInfo: Verification // information for target sites in advanced site search. type GoogleCloudDiscoveryengineV1betaSiteVerificationInfo struct { @@ -20232,6 +21511,95 @@ func (s GoogleTypeDate) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleTypeDateTime: Represents civil time (or occasionally physical time). +// This type can represent a civil time in one of a few possible ways: * When +// utc_offset is set and time_zone is unset: a civil time on a calendar day +// with a particular offset from UTC. * When time_zone is set and utc_offset is +// unset: a civil time on a calendar day in a particular time zone. * When +// neither time_zone nor utc_offset is set: a civil time on a calendar day in +// local time. The date is relative to the Proleptic Gregorian Calendar. If +// year, month, or day are 0, the DateTime is considered not to have a specific +// year, month, or day respectively. This type may also be used to represent a +// physical time if all the date and time fields are set and either case of the +// `time_offset` oneof is set. Consider using `Timestamp` message for physical +// time instead. If your use case also would like to store the user's timezone, +// that can be done in another field. This type is more flexible than some +// applications may want. Make sure to document and validate your application's +// limitations. +type GoogleTypeDateTime struct { + // Day: Optional. Day of month. Must be from 1 to 31 and valid for the year and + // month, or 0 if specifying a datetime without a day. + Day int64 `json:"day,omitempty"` + // Hours: Optional. Hours of day in 24 hour format. Should be from 0 to 23, + // defaults to 0 (midnight). An API may choose to allow the value "24:00:00" + // for scenarios like business closing time. + Hours int64 `json:"hours,omitempty"` + // Minutes: Optional. Minutes of hour of day. Must be from 0 to 59, defaults to + // 0. + Minutes int64 `json:"minutes,omitempty"` + // Month: Optional. Month of year. Must be from 1 to 12, or 0 if specifying a + // datetime without a month. + Month int64 `json:"month,omitempty"` + // Nanos: Optional. Fractions of seconds in nanoseconds. Must be from 0 to + // 999,999,999, defaults to 0. + Nanos int64 `json:"nanos,omitempty"` + // Seconds: Optional. Seconds of minutes of the time. Must normally be from 0 + // to 59, defaults to 0. An API may allow the value 60 if it allows + // leap-seconds. + Seconds int64 `json:"seconds,omitempty"` + // TimeZone: Time zone. + TimeZone *GoogleTypeTimeZone `json:"timeZone,omitempty"` + // UtcOffset: UTC offset. Must be whole seconds, between -18 hours and +18 + // hours. For example, a UTC offset of -4:00 would be represented as { seconds: + // -14400 }. + UtcOffset string `json:"utcOffset,omitempty"` + // Year: Optional. Year of date. Must be from 1 to 9999, or 0 if specifying a + // datetime 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. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + 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. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleTypeDateTime) MarshalJSON() ([]byte, error) { + type NoMethod GoogleTypeDateTime + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleTypeTimeZone: Represents a time zone from the IANA Time Zone Database +// (https://www.iana.org/time-zones). +type GoogleTypeTimeZone struct { + // Id: IANA Time Zone Database time zone. For example "America/New_York". + Id string `json:"id,omitempty"` + // Version: Optional. IANA Time Zone Database version number. For example + // "2019a". + Version string `json:"version,omitempty"` + // ForceSendFields is a list of field names (e.g. "Id") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "Id") to include in API requests + // with the JSON null value. By default, fields with empty values are omitted + // from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleTypeTimeZone) MarshalJSON() ([]byte, error) { + type NoMethod GoogleTypeTimeZone + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + type ProjectsProvisionCall struct { s *Service name string @@ -20340,6 +21708,111 @@ func (c *ProjectsProvisionCall) Do(opts ...googleapi.CallOption) (*GoogleLongrun return ret, nil } +type ProjectsLocationsGenerateGroundedContentCall struct { + s *Service + location string + googleclouddiscoveryenginev1generategroundedcontentrequest *GoogleCloudDiscoveryengineV1GenerateGroundedContentRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// GenerateGroundedContent: Generates grounded content. +// +// - location: Location resource. Format: +// `projects/{project}/locations/{location}`. +func (r *ProjectsLocationsService) GenerateGroundedContent(location string, googleclouddiscoveryenginev1generategroundedcontentrequest *GoogleCloudDiscoveryengineV1GenerateGroundedContentRequest) *ProjectsLocationsGenerateGroundedContentCall { + c := &ProjectsLocationsGenerateGroundedContentCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.location = location + c.googleclouddiscoveryenginev1generategroundedcontentrequest = googleclouddiscoveryenginev1generategroundedcontentrequest + return c +} + +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. +func (c *ProjectsLocationsGenerateGroundedContentCall) Fields(s ...googleapi.Field) *ProjectsLocationsGenerateGroundedContentCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsGenerateGroundedContentCall) Context(ctx context.Context) *ProjectsLocationsGenerateGroundedContentCall { + c.ctx_ = ctx + return c +} + +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. +func (c *ProjectsLocationsGenerateGroundedContentCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsGenerateGroundedContentCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) + body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.googleclouddiscoveryenginev1generategroundedcontentrequest) + if err != nil { + return nil, err + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+location}:generateGroundedContent") + 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{ + "location": c.location, + }) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "discoveryengine.projects.locations.generateGroundedContent", "request", internallog.HTTPRequest(req, body.Bytes())) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "discoveryengine.projects.locations.generateGroundedContent" call. +// Any non-2xx status code is an error. Response headers are in either +// *GoogleCloudDiscoveryengineV1GenerateGroundedContentResponse.ServerResponse.H +// eader or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. +func (c *ProjectsLocationsGenerateGroundedContentCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1GenerateGroundedContentResponse, 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 := &GoogleCloudDiscoveryengineV1GenerateGroundedContentResponse{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + b, err := gensupport.DecodeResponseBytes(target, res) + if err != nil { + return nil, err + } + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "discoveryengine.projects.locations.generateGroundedContent", "response", internallog.HTTPResponse(res, b)) + return ret, nil +} + type ProjectsLocationsCollectionsDataConnectorOperationsGetCall struct { s *Service name string diff --git a/discoveryengine/v1alpha/discoveryengine-api.json b/discoveryengine/v1alpha/discoveryengine-api.json index ed5b738067..3b24549bf8 100644 --- a/discoveryengine/v1alpha/discoveryengine-api.json +++ b/discoveryengine/v1alpha/discoveryengine-api.json @@ -242,6 +242,34 @@ "https://www.googleapis.com/auth/cloud-platform" ] }, + "generateGroundedContent": { + "description": "Generates grounded content.", + "flatPath": "v1alpha/projects/{projectsId}/locations/{locationsId}:generateGroundedContent", + "httpMethod": "POST", + "id": "discoveryengine.projects.locations.generateGroundedContent", + "parameterOrder": [ + "location" + ], + "parameters": { + "location": { + "description": "Required. Location resource. Format: `projects/{project}/locations/{location}`.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1alpha/{+location}:generateGroundedContent", + "request": { + "$ref": "GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentRequest" + }, + "response": { + "$ref": "GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, "getAclConfig": { "description": "Gets the AclConfig.", "flatPath": "v1alpha/projects/{projectsId}/locations/{locationsId}/aclConfig", @@ -292,6 +320,34 @@ "https://www.googleapis.com/auth/cloud-platform" ] }, + "setUpDataConnector": { + "description": "Creates a Collection and sets up the DataConnector for it. To stop a DataConnector after setup, use the CollectionService.DeleteCollection method.", + "flatPath": "v1alpha/projects/{projectsId}/locations/{locationsId}:setUpDataConnector", + "httpMethod": "POST", + "id": "discoveryengine.projects.locations.setUpDataConnector", + "parameterOrder": [ + "parent" + ], + "parameters": { + "parent": { + "description": "Required. The parent of Collection, in the format of `projects/{project}/locations/{location}`.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1alpha/{+parent}:setUpDataConnector", + "request": { + "$ref": "GoogleCloudDiscoveryengineV1alphaSetUpDataConnectorRequest" + }, + "response": { + "$ref": "GoogleLongrunningOperation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, "updateAclConfig": { "description": "Default ACL configuration for use in a location of a customer's project. Updates will only reflect to new data stores. Existing data stores will still use the old value.", "flatPath": "v1alpha/projects/{projectsId}/locations/{locationsId}/aclConfig", @@ -443,9 +499,265 @@ } }, "collections": { + "methods": { + "delete": { + "description": "Deletes a Collection.", + "flatPath": "v1alpha/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}", + "httpMethod": "DELETE", + "id": "discoveryengine.projects.locations.collections.delete", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Required. The full resource name of the Collection, in the format of `projects/{project}/locations/{location}/collections/{collection}`.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1alpha/{+name}", + "response": { + "$ref": "GoogleLongrunningOperation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "get": { + "description": "Gets a Collection.", + "flatPath": "v1alpha/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}", + "httpMethod": "GET", + "id": "discoveryengine.projects.locations.collections.get", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Required. The full resource name, in the format of `projects/{project}/locations/{location}/collections/{collection}`.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1alpha/{+name}", + "response": { + "$ref": "GoogleCloudDiscoveryengineV1alphaCollection" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "getDataConnector": { + "description": "Gets the DataConnector. DataConnector is a singleton resource for each Collection.", + "flatPath": "v1alpha/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataConnector", + "httpMethod": "GET", + "id": "discoveryengine.projects.locations.collections.getDataConnector", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Required. Full resource name of DataConnector, such as `projects/{project}/locations/{location}/collections/{collection_id}/dataConnector`. If the caller does not have permission to access the DataConnector, regardless of whether or not it exists, a PERMISSION_DENIED error is returned. If the requested DataConnector does not exist, a NOT_FOUND error is returned.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataConnector$", + "required": true, + "type": "string" + } + }, + "path": "v1alpha/{+name}", + "response": { + "$ref": "GoogleCloudDiscoveryengineV1alphaDataConnector" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "list": { + "description": "Gets a list of Collections.", + "flatPath": "v1alpha/projects/{projectsId}/locations/{locationsId}/collections", + "httpMethod": "GET", + "id": "discoveryengine.projects.locations.collections.list", + "parameterOrder": [ + "parent" + ], + "parameters": { + "filter": { + "description": "Filter returned collections by associated data connector data sources. For example: `filter = 'data_source:jira confluence'`. If the filter is empty, we return all collections under a project and location.", + "location": "query", + "type": "string" + }, + "pageSize": { + "description": "The maximum number of Collections to return. The service may return fewer than this value. If unspecified, at most 100 Collections 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 CollectionService.ListCollections call. Provide this to retrieve the subsequent page. When paginating, all other parameters provided to CollectionService.ListCollections 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}`.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1alpha/{+parent}/collections", + "response": { + "$ref": "GoogleCloudDiscoveryengineV1alphaListCollectionsResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "patch": { + "description": "Updates a Collection.", + "flatPath": "v1alpha/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}", + "httpMethod": "PATCH", + "id": "discoveryengine.projects.locations.collections.patch", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Immutable. The full resource name of the Collection. Format: `projects/{project}/locations/{location}/collections/{collection_id}`. This field must be a UTF-8 encoded string with a length limit of 1024 characters.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+$", + "required": true, + "type": "string" + }, + "updateMask": { + "description": "Optional. The list of fields to be updated.", + "format": "google-fieldmask", + "location": "query", + "type": "string" + } + }, + "path": "v1alpha/{+name}", + "request": { + "$ref": "GoogleCloudDiscoveryengineV1alphaCollection" + }, + "response": { + "$ref": "GoogleLongrunningOperation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "updateDataConnector": { + "description": "Updates a DataConnector.", + "flatPath": "v1alpha/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataConnector", + "httpMethod": "PATCH", + "id": "discoveryengine.projects.locations.collections.updateDataConnector", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Output only. The full resource name of the Data Connector. Format: `projects/*/locations/*/collections/*/dataConnector`.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataConnector$", + "required": true, + "type": "string" + }, + "updateMask": { + "description": "Indicates which fields in the provided DataConnector to update. Supported field paths include: - refresh_interval - params - auto_run_disabled - action_config - destination_configs - blocking_reasons Note: Support for these fields may vary depending on the connector type. For example, not all connectors support `destination_configs`. If an unsupported or unknown field path is provided, the request will return an INVALID_ARGUMENT error.", + "format": "google-fieldmask", + "location": "query", + "type": "string" + } + }, + "path": "v1alpha/{+name}", + "request": { + "$ref": "GoogleCloudDiscoveryengineV1alphaDataConnector" + }, + "response": { + "$ref": "GoogleCloudDiscoveryengineV1alphaDataConnector" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + } + }, "resources": { "dataConnector": { + "methods": { + "startConnectorRun": { + "description": "Starts an immediate synchronization process for a DataConnector. Third Party Connector Users must specify which entities should be synced. FHIR Connectors must provide a timestamp to indicate the point in time from which data should be synced.", + "flatPath": "v1alpha/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataConnector:startConnectorRun", + "httpMethod": "POST", + "id": "discoveryengine.projects.locations.collections.dataConnector.startConnectorRun", + "parameterOrder": [ + "parent" + ], + "parameters": { + "parent": { + "description": "Required. Connector name of the form projects/{project}/locations/{location}/collections/ {collection_id}/dataConnector", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataConnector$", + "required": true, + "type": "string" + } + }, + "path": "v1alpha/{+parent}:startConnectorRun", + "request": { + "$ref": "GoogleCloudDiscoveryengineV1alphaStartConnectorRunRequest" + }, + "response": { + "$ref": "GoogleCloudDiscoveryengineV1alphaConnectorRun" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + } + }, "resources": { + "connectorRuns": { + "methods": { + "list": { + "description": "Lists the ConnectorRuns of a DataConnector.", + "flatPath": "v1alpha/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataConnector/connectorRuns", + "httpMethod": "GET", + "id": "discoveryengine.projects.locations.collections.dataConnector.connectorRuns.list", + "parameterOrder": [ + "parent" + ], + "parameters": { + "pageSize": { + "description": "Requested page size. Server may return fewer items than requested. If unspecified, defaults to 10. The maximum value is 50; values above 50 will be coerced to 50. 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 `ListConnectorRuns` call. Provide this to retrieve the subsequent page. When paginating, all other parameters provided to `ListConnectorRuns` must match the call that provided the page token.", + "location": "query", + "type": "string" + }, + "parent": { + "description": "Required. The parent DataConnector resource name, such as `projects/{project}/locations/{location}/collections/{collection_id}/dataConnector`. If the caller does not have permission to list ConnectorRuns under this DataConnector, regardless of whether or not this DataConnector exists, a PERMISSION_DENIED error is returned.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataConnector$", + "required": true, + "type": "string" + } + }, + "path": "v1alpha/{+parent}/connectorRuns", + "response": { + "$ref": "GoogleCloudDiscoveryengineV1alphaListConnectorRunsResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + } + } + }, "operations": { "methods": { "get": { @@ -8156,7 +8468,7 @@ } } }, - "revision": "20241210", + "revision": "20241216", "rootUrl": "https://discoveryengine.googleapis.com/", "schemas": { "GoogleApiDistribution": { @@ -8595,6 +8907,13 @@ "description": "Required. Name of the CmekConfig, of the form `projects/{project}/locations/{location}/cmekConfig` or `projects/{project}/locations/{location}/cmekConfigs/{cmekConfig}`.", "type": "string" }, + "singleRegionKeys": { + "description": "Optional. Single-regional CMEKs that are required for some VAIS features.", + "items": { + "$ref": "GoogleCloudDiscoveryengineV1SingleRegionKey" + }, + "type": "array" + }, "state": { "description": "Output only. State of the CmekConfig.", "enum": [ @@ -8977,6 +9296,10 @@ ], "type": "string" }, + "isInfobotFaqDataStore": { + "description": "Optional. If set, this DataStore is an Infobot FAQ DataStore.", + "type": "boolean" + }, "kmsKeyName": { "description": "Input only. The KMS key to be used to protect this DataStore at creation time. Must be set for requests that need to comply with CMEK Org Policy protections. If this field is set and processed successfully, the DataStore will be protected by the KMS key, as indicated in the cmek_config field.", "type": "string" @@ -10271,6 +10594,17 @@ }, "type": "object" }, + "GoogleCloudDiscoveryengineV1SingleRegionKey": { + "description": "Metadata for single-regional CMEKs.", + "id": "GoogleCloudDiscoveryengineV1SingleRegionKey", + "properties": { + "kmsKey": { + "description": "Required. Single-regional kms key resource name which will be used to encrypt resources `projects/{project}/locations/{location}/keyRings/{keyRing}/cryptoKeys/{keyId}`.", + "type": "string" + } + }, + "type": "object" + }, "GoogleCloudDiscoveryengineV1SiteVerificationInfo": { "description": "Verification information for target sites in advanced site search.", "id": "GoogleCloudDiscoveryengineV1SiteVerificationInfo", @@ -10561,16 +10895,36 @@ }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaAdvancedCompleteQueryRequest": { - "description": "Request message for CompletionService.AdvancedCompleteQuery method. .", - "id": "GoogleCloudDiscoveryengineV1alphaAdvancedCompleteQueryRequest", + "GoogleCloudDiscoveryengineV1alphaActionConfig": { + "description": "Informations to support actions on the connector.", + "id": "GoogleCloudDiscoveryengineV1alphaActionConfig", "properties": { - "boostSpec": { - "$ref": "GoogleCloudDiscoveryengineV1alphaAdvancedCompleteQueryRequestBoostSpec", - "description": "Optional. Specification to boost suggestions matching the condition." - }, - "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.", + "actionParams": { + "additionalProperties": { + "description": "Properties of the object.", + "type": "any" + }, + "description": "Required. Params needed to support actions in the format of (Key, Value) pairs. Required parameters for sources that support OAUTH, i.e. `gmail`, `google_calendar`, `jira`, `workday`, `salesforce`, `confluence`: * Key: `client_id` * Value: type STRING. The client id for the service provider to identify your application. * Key: `client_secret` * Value:type STRING. The client secret generated by the application's authorization server.", + "type": "object" + }, + "isActionConfigured": { + "description": "Output only. The connector contains the necessary parameters and is configured to support actions.", + "readOnly": true, + "type": "boolean" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaAdvancedCompleteQueryRequest": { + "description": "Request message for CompletionService.AdvancedCompleteQuery method. .", + "id": "GoogleCloudDiscoveryengineV1alphaAdvancedCompleteQueryRequest", + "properties": { + "boostSpec": { + "$ref": "GoogleCloudDiscoveryengineV1alphaAdvancedCompleteQueryRequestBoostSpec", + "description": "Optional. Specification to boost suggestions matching the condition." + }, + "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": { @@ -12510,6 +12864,13 @@ "description": "Required. Name of the CmekConfig, of the form `projects/{project}/locations/{location}/cmekConfig` or `projects/{project}/locations/{location}/cmekConfigs/{cmekConfig}`.", "type": "string" }, + "singleRegionKeys": { + "description": "Optional. Single-regional CMEKs that are required for some VAIS features.", + "items": { + "$ref": "GoogleCloudDiscoveryengineV1alphaSingleRegionKey" + }, + "type": "array" + }, "state": { "description": "Output only. State of the CmekConfig.", "enum": [ @@ -12536,6 +12897,32 @@ }, "type": "object" }, + "GoogleCloudDiscoveryengineV1alphaCollection": { + "description": "Collection is a container for configuring resources and access to a set of DataStores.", + "id": "GoogleCloudDiscoveryengineV1alphaCollection", + "properties": { + "createTime": { + "description": "Output only. Timestamp the Collection was created at.", + "format": "google-datetime", + "readOnly": true, + "type": "string" + }, + "dataConnector": { + "$ref": "GoogleCloudDiscoveryengineV1alphaDataConnector", + "description": "Output only. The data connector, if present, manages the connection for data stores in the Collection. To set up the connector, use DataConnectorService.SetUpDataConnector method, which creates a new Collection while setting up the DataConnector singleton resource. Setting up connector on an existing Collection is not supported. This output only field contains a subset of the DataConnector fields, including `name`, `data_source`, `entities.entity_name` and `entities.data_store`. To get more details about a data connector, use the DataConnector.GetDataConnector method.", + "readOnly": true + }, + "displayName": { + "description": "Required. The Collection 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" + }, + "name": { + "description": "Immutable. The full resource name of the Collection. Format: `projects/{project}/locations/{location}/collections/{collection_id}`. This field must be a UTF-8 encoded string with a length limit of 1024 characters.", + "type": "string" + } + }, + "type": "object" + }, "GoogleCloudDiscoveryengineV1alphaCompleteQueryResponse": { "description": "Response message for CompletionService.CompleteQuery method.", "id": "GoogleCloudDiscoveryengineV1alphaCompleteQueryResponse", @@ -12686,6 +13073,186 @@ }, "type": "object" }, + "GoogleCloudDiscoveryengineV1alphaConnectorRun": { + "description": "A data sync run of DataConnector. After DataConnector is successfully initialized, data syncs are scheduled at DataConnector.refresh_interval. A ConnectorRun represents a data sync either in the past or onging that the moment. //", + "id": "GoogleCloudDiscoveryengineV1alphaConnectorRun", + "properties": { + "endTime": { + "description": "Output only. The time when the connector run ended.", + "format": "google-datetime", + "readOnly": true, + "type": "string" + }, + "entityRuns": { + "description": "Output only. The details of the entities synced at the ConnectorRun. Each ConnectorRun consists of syncing one or more entities.", + "items": { + "$ref": "GoogleCloudDiscoveryengineV1alphaConnectorRunEntityRun" + }, + "readOnly": true, + "type": "array" + }, + "errors": { + "description": "Contains info about errors incurred during the sync. Only exist if running into an error state. Contains error code and error message. Use with the `state` field.", + "items": { + "$ref": "GoogleRpcStatus" + }, + "type": "array" + }, + "latestPauseTime": { + "description": "Output only. The time when the connector run was most recently paused.", + "format": "google-datetime", + "readOnly": true, + "type": "string" + }, + "name": { + "description": "Output only. The full resource name of the Connector Run. Format: `projects/*/locations/*/collections/*/dataConnector/connectorRuns/*`. The `connector_run_id` is system-generated.", + "readOnly": true, + "type": "string" + }, + "startTime": { + "description": "Output only. The time when the connector run started.", + "format": "google-datetime", + "readOnly": true, + "type": "string" + }, + "state": { + "description": "Output only. The state of the sync run.", + "enum": [ + "STATE_UNSPECIFIED", + "RUNNING", + "SUCCEEDED", + "FAILED", + "OVERRUN", + "CANCELLED", + "PENDING", + "WARNING" + ], + "enumDescriptions": [ + "Default value.", + "The data sync is ongoing.", + "The data sync is finished.", + "The data sync is failed.", + "Data sync has been running longer than expected and is still running at the time the next run is supposed to start.", + "Data sync was scheduled but has been cancelled.", + "Data sync is about to start.", + "The data sync completed with non-fatal errors." + ], + "readOnly": true, + "type": "string" + }, + "stateUpdateTime": { + "description": "Timestamp at which the connector run sync state was last updated.", + "format": "google-datetime", + "type": "string" + }, + "trigger": { + "description": "Output only. The trigger for this ConnectorRun.", + "enum": [ + "TRIGGER_UNSPECIFIED", + "SCHEDULER", + "INITIALIZATION", + "RESUME", + "MANUAL" + ], + "enumDescriptions": [ + "Default value.", + "ConnectorRun triggered by scheduler if connector has PERIODIC sync mode.", + "ConnectorRun auto triggered by connector initialization.", + "ConnectorRun auto triggered by resuming connector.", + "ConnectorRun triggered by user manually." + ], + "readOnly": true, + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaConnectorRunEntityRun": { + "description": "Represents an entity that was synced in this ConnectorRun.", + "id": "GoogleCloudDiscoveryengineV1alphaConnectorRunEntityRun", + "properties": { + "entityName": { + "description": "The name of the source entity.", + "type": "string" + }, + "errorRecordCount": { + "description": "The total number of documents failed at sync at any stage (extraction, indexing, etc).", + "format": "int64", + "type": "string" + }, + "errors": { + "description": "The errors from the entity's sync run. Only exist if running into an error state. Contains error code and error message.", + "items": { + "$ref": "GoogleRpcStatus" + }, + "type": "array" + }, + "extractedRecordCount": { + "description": "The number of documents extracted from connector source, ready to be ingested to UCS.", + "format": "int64", + "type": "string" + }, + "indexedRecordCount": { + "description": "The number of documents indexed.", + "format": "int64", + "type": "string" + }, + "sourceApiRequestCount": { + "description": "The number of requests sent to 3p API.", + "format": "int64", + "type": "string" + }, + "state": { + "description": "The state of the entity's sync run.", + "enum": [ + "STATE_UNSPECIFIED", + "RUNNING", + "SUCCEEDED", + "FAILED", + "OVERRUN", + "CANCELLED", + "PENDING", + "WARNING" + ], + "enumDescriptions": [ + "Default value.", + "The data sync is ongoing.", + "The data sync is finished.", + "The data sync is failed.", + "Data sync has been running longer than expected and is still running at the time the next run is supposed to start.", + "Data sync was scheduled but has been cancelled.", + "Data sync is about to start.", + "The data sync completed with non-fatal errors." + ], + "type": "string" + }, + "stateUpdateTime": { + "description": "Timestamp at which the entity sync state was last updated.", + "format": "google-datetime", + "type": "string" + }, + "statsUpdateTime": { + "description": "The timestamp for either extracted_documents_count, indexed_documents_count and error_documents_count was last updated.", + "format": "google-datetime", + "type": "string" + }, + "syncType": { + "description": "Sync type of this run.", + "enum": [ + "SYNC_TYPE_UNSPECIFIED", + "FULL", + "INCREMENTAL" + ], + "enumDescriptions": [ + "Sync type unspecified.", + "Sync triggers full sync of all documents.", + "Incremental sync of updated documents." + ], + "type": "string" + } + }, + "type": "object" + }, "GoogleCloudDiscoveryengineV1alphaControl": { "description": "Defines a conditioned behavior to employ during serving. Must be attached to a ServingConfig to be considered at serving time. Permitted actions dependent on `SolutionType`.", "id": "GoogleCloudDiscoveryengineV1alphaControl", @@ -13221,105 +13788,307 @@ }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaDataStore": { - "description": "DataStore captures global settings and configs at the DataStore level.", - "id": "GoogleCloudDiscoveryengineV1alphaDataStore", + "GoogleCloudDiscoveryengineV1alphaDataConnector": { + "description": "Manages the connection to external data sources for all data stores grouped under a Collection. It's a singleton resource of Collection. The initialization is only supported through SetUpDataConnector method, which will create a new Collection and initialize its DataConnector. //", + "id": "GoogleCloudDiscoveryengineV1alphaDataConnector", "properties": { - "aclEnabled": { - "description": "Immutable. Whether data in the DataStore has ACL information. If set to `true`, the source data must have ACL. ACL will be ingested when data is ingested by DocumentService.ImportDocuments methods. When ACL is enabled for the DataStore, Document can't be accessed by calling DocumentService.GetDocument or DocumentService.ListDocuments. Currently ACL is only supported in `GENERIC` industry vertical with non-`PUBLIC_WEBSITE` content config.", - "type": "boolean" - }, - "advancedSiteSearchConfig": { - "$ref": "GoogleCloudDiscoveryengineV1alphaAdvancedSiteSearchConfig", - "description": "Optional. Configuration for advanced site search." - }, - "billingEstimation": { - "$ref": "GoogleCloudDiscoveryengineV1alphaDataStoreBillingEstimation", - "description": "Output only. Data size estimation for billing.", - "readOnly": true + "actionConfig": { + "$ref": "GoogleCloudDiscoveryengineV1alphaActionConfig", + "description": "Optional. Action configurations to make the connector support actions." }, - "cmekConfig": { - "$ref": "GoogleCloudDiscoveryengineV1alphaCmekConfig", - "description": "Output only. CMEK-related information for the DataStore.", - "readOnly": true + "autoRunDisabled": { + "description": "Indicates whether the connector is disabled for auto run. It can be used to pause periodical and real time sync.", + "type": "boolean" }, - "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", - "GOOGLE_WORKSPACE" - ], - "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.", - "The data store is used for workspace search. Details of workspace data store are specified in the WorkspaceConfig." - ], - "type": "string" + "blockingReasons": { + "description": "Output only. User actions that must be completed before the connector can start syncing data.", + "items": { + "enum": [ + "BLOCKING_REASON_UNSPECIFIED", + "ALLOWLIST_STATIC_IP", + "ALLOWLIST_IN_SERVICE_ATTACHMENT" + ], + "enumDescriptions": [ + "Default value.", + "Connector requires customer to allowlist static IPs.", + "Connector requires customer to allowlist our project in their service attachment." + ], + "type": "string" + }, + "readOnly": true, + "type": "array" }, "createTime": { - "description": "Output only. Timestamp the DataStore was created at.", + "description": "Output only. Timestamp the DataConnector 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, + "dataSource": { + "description": "Required. The name of the data source. Supported values: `salesforce`, `jira`, `confluence`, `bigquery`.", "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" + "destinationConfigs": { + "description": "Optional. Any target destinations used to connect to third-party services.", + "items": { + "$ref": "GoogleCloudDiscoveryengineV1alphaDestinationConfig" + }, + "type": "array" }, - "documentProcessingConfig": { - "$ref": "GoogleCloudDiscoveryengineV1alphaDocumentProcessingConfig", - "description": "Configuration for Document understanding and enrichment." + "entities": { + "description": "List of entities from the connected data source to ingest.", + "items": { + "$ref": "GoogleCloudDiscoveryengineV1alphaDataConnectorSourceEntity" + }, + "type": "array" }, - "idpConfig": { - "$ref": "GoogleCloudDiscoveryengineV1alphaIdpConfig", - "description": "Output only. Data store level identity provider config.", - "readOnly": true + "errors": { + "description": "Output only. The errors from initialization or from the latest connector run.", + "items": { + "$ref": "GoogleRpcStatus" + }, + "readOnly": true, + "type": "array" }, - "industryVertical": { - "description": "Immutable. The industry vertical that the data store registers.", - "enum": [ - "INDUSTRY_VERTICAL_UNSPECIFIED", - "GENERIC", - "MEDIA", - "HEALTHCARE_FHIR" - ], - "enumDescriptions": [ - "Value used when unset.", - "The generic vertical for documents that are not specific to any industry vertical.", - "The media industry vertical.", - "The healthcare FHIR vertical." - ], + "identityRefreshInterval": { + "deprecated": true, + "description": "The refresh interval to sync the Access Control List information for the documents ingested by this connector. If not set, the access control list will be refreshed at the default interval of 30 minutes. The identity refresh interval can be at least 30 minutes and at most 7 days.", + "format": "google-duration", "type": "string" }, + "identityScheduleConfig": { + "$ref": "GoogleCloudDiscoveryengineV1alphaIdentityScheduleConfig", + "description": "The configuration for the identity data synchronization runs. This contains the refresh interval to sync the Access Control List information for the documents ingested by this connector." + }, "kmsKeyName": { - "description": "Input only. The KMS key to be used to protect this DataStore at creation time. Must be set for requests that need to comply with CMEK Org Policy protections. If this field is set and processed successfully, the DataStore will be protected by the KMS key, as indicated in the cmek_config field.", + "description": "Input only. The KMS key to be used to protect the DataStores managed by this connector. Must be set for requests that need to comply with CMEK Org Policy protections. If this field is set and processed successfully, the DataStores created by this connector will be protected by the KMS key.", "type": "string" }, - "languageInfo": { - "$ref": "GoogleCloudDiscoveryengineV1alphaLanguageInfo", - "description": "Language info for DataStore." + "lastSyncTime": { + "description": "Output only. For periodic connectors only, the last time a data sync was completed.", + "format": "google-datetime", + "readOnly": true, + "type": "string" + }, + "latestPauseTime": { + "description": "Output only. The most recent timestamp when this DataConnector was paused, affecting all functionalities such as data synchronization. Pausing a connector has the following effects: - All functionalities, including data synchronization, are halted. - Any ongoing data synchronization job will be canceled. - No future data synchronization runs will be scheduled nor can be triggered.", + "format": "google-datetime", + "readOnly": true, + "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.", + "description": "Output only. The full resource name of the Data Connector. Format: `projects/*/locations/*/collections/*/dataConnector`.", + "readOnly": true, "type": "string" }, - "naturalLanguageQueryUnderstandingConfig": { - "$ref": "GoogleCloudDiscoveryengineV1alphaNaturalLanguageQueryUnderstandingConfig", - "description": "Optional. Configuration for Natural Language Query Understanding." + "nextSyncTime": { + "$ref": "GoogleTypeDateTime", + "description": "The UTC time when the next data sync is expected to start for the Data Connector. Customers are only able to specify the hour and minute to schedule the data sync. This is utilized when the data connector has a refresh interval greater than 1 day." }, - "servingConfigDataStore": { - "$ref": "GoogleCloudDiscoveryengineV1alphaDataStoreServingConfigDataStore", - "description": "Optional. Stores serving config at DataStore level." + "params": { + "additionalProperties": { + "description": "Properties of the object.", + "type": "any" + }, + "description": "Required. Params needed to access the source in the format of (Key, Value) pairs. Required parameters for all data sources: * Key: `instance_uri` * Value: type STRING. The uri to access the data source. Required parameters for sources that support OAUTH, i.e. `salesforce`: * Key: `client_id` * Value: type STRING. The client id for the third party service provider to identify your application. * Key: `client_secret` * Value:type STRING. The client secret generated by the third party authorization server. * Key: `access_token` * Value: type STRING. OAuth token for UCS to access to the protected resource. * Key: `refresh_token` * Value: type STRING. OAuth refresh token for UCS to obtain a new access token without user interaction. Required parameters for sources that support basic API token auth, i.e. `jira`, `confluence`: * Key: `user_account` * Value: type STRING. The username or email with the source. * Key: `api_token` * Value: type STRING. The API token generated for the source account, that is used for authenticating anywhere where you would have used a password. Example: ```json { \"instance_uri\": \"https://xxx.atlassian.net\", \"user_account\": \"xxxx.xxx@xxx.com\", \"api_token\": \"test-token\" } ``` Optional parameter to specify the authorization type to use for multiple authorization types support: * Key: `auth_type` * Value: type STRING. The authorization type for the data source. Supported values: `BASIC_AUTH`, `OAUTH`, `OAUTH_ACCESS_TOKEN`, `OAUTH_TWO_LEGGED`, `OAUTH_JWT_BEARER`, `OAUTH_PASSWORD_GRANT`, `JWT`, `API_TOKEN`, `FEDERATED_CREDENTIAL`.", + "type": "object" + }, + "privateConnectivityProjectId": { + "description": "Output only. The tenant project ID associated with private connectivity connectors. This project must be allowlisted by in order for the connector to function.", + "readOnly": true, + "type": "string" + }, + "refreshInterval": { + "description": "Required. The refresh interval for data sync. If duration is set to 0, the data will be synced in real time. The streaming feature is not supported yet. The minimum is 30 minutes and maximum is 7 days.", + "format": "google-duration", + "type": "string" + }, + "state": { + "description": "Output only. State of the connector.", + "enum": [ + "STATE_UNSPECIFIED", + "CREATING", + "ACTIVE", + "FAILED", + "RUNNING", + "WARNING" + ], + "enumDescriptions": [ + "Default value.", + "The connector is being set up.", + "The connector is successfully set up and awaiting next sync run.", + "The connector is in error. The error details can be found in DataConnector.errors. If the error is unfixable, the DataConnector can be deleted by [CollectionService.DeleteCollection] API.", + "The connector is actively syncing records from the data source.", + "The connector has completed a sync run, but encountered non-fatal errors." + ], + "readOnly": true, + "type": "string" + }, + "staticIpAddresses": { + "description": "Output only. The static IP addresses used by this connector.", + "items": { + "type": "string" + }, + "readOnly": true, + "type": "array" + }, + "staticIpEnabled": { + "description": "Optional. Whether customer has enabled static IP addresses for this connector.", + "type": "boolean" + }, + "syncMode": { + "description": "The data synchronization mode supported by the data connector.", + "enum": [ + "PERIODIC" + ], + "enumDescriptions": [ + "The connector will sync data periodically based on the refresh_interval. Use it with auto_run_disabled to pause the periodic sync, or indicate a one-time sync." + ], + "type": "string" + }, + "updateTime": { + "description": "Output only. Timestamp the DataConnector was last updated.", + "format": "google-datetime", + "readOnly": true, + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaDataConnectorSourceEntity": { + "description": "Represents an entity in the data source. For example, the `Account` object in Salesforce.", + "id": "GoogleCloudDiscoveryengineV1alphaDataConnectorSourceEntity", + "properties": { + "dataStore": { + "description": "Output only. The full resource name of the associated data store for the source entity. Format: `projects/*/locations/*/collections/*/dataStores/*`. When the connector is initialized by the DataConnectorService.SetUpDataConnector method, a DataStore is automatically created for each source entity.", + "readOnly": true, + "type": "string" + }, + "entityName": { + "description": "The name of the entity. Supported values by data source: * Salesforce: `Lead`, `Opportunity`, `Contact`, `Account`, `Case`, `Contract`, `Campaign` * Jira: `Issue` * Confluence: `Content`, `Space`", + "type": "string" + }, + "keyPropertyMappings": { + "additionalProperties": { + "type": "string" + }, + "description": "Attributes for indexing. Key: Field name. Value: The key property to map a field to, such as `title`, and `description`. Supported key properties: * `title`: The title for data record. This would be displayed on search results. * `description`: The description for data record. This would be displayed on search results.", + "type": "object" + }, + "params": { + "additionalProperties": { + "description": "Properties of the object.", + "type": "any" + }, + "description": "The parameters for the entity to facilitate data ingestion. E.g. for BQ connectors: * Key: `document_id_column` * Value: type STRING. The value of the column id.", + "type": "object" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaDataStore": { + "description": "DataStore captures global settings and configs at the DataStore level.", + "id": "GoogleCloudDiscoveryengineV1alphaDataStore", + "properties": { + "aclEnabled": { + "description": "Immutable. Whether data in the DataStore has ACL information. If set to `true`, the source data must have ACL. ACL will be ingested when data is ingested by DocumentService.ImportDocuments methods. When ACL is enabled for the DataStore, Document can't be accessed by calling DocumentService.GetDocument or DocumentService.ListDocuments. Currently ACL is only supported in `GENERIC` industry vertical with non-`PUBLIC_WEBSITE` content config.", + "type": "boolean" + }, + "advancedSiteSearchConfig": { + "$ref": "GoogleCloudDiscoveryengineV1alphaAdvancedSiteSearchConfig", + "description": "Optional. Configuration for advanced site search." + }, + "billingEstimation": { + "$ref": "GoogleCloudDiscoveryengineV1alphaDataStoreBillingEstimation", + "description": "Output only. Data size estimation for billing.", + "readOnly": true + }, + "cmekConfig": { + "$ref": "GoogleCloudDiscoveryengineV1alphaCmekConfig", + "description": "Output only. CMEK-related information for the DataStore.", + "readOnly": true + }, + "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", + "GOOGLE_WORKSPACE" + ], + "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.", + "The data store is used for workspace search. Details of workspace data store are specified in the WorkspaceConfig." + ], + "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" + }, + "documentProcessingConfig": { + "$ref": "GoogleCloudDiscoveryengineV1alphaDocumentProcessingConfig", + "description": "Configuration for Document understanding and enrichment." + }, + "idpConfig": { + "$ref": "GoogleCloudDiscoveryengineV1alphaIdpConfig", + "description": "Output only. Data store level identity provider config.", + "readOnly": true + }, + "industryVertical": { + "description": "Immutable. The industry vertical that the data store registers.", + "enum": [ + "INDUSTRY_VERTICAL_UNSPECIFIED", + "GENERIC", + "MEDIA", + "HEALTHCARE_FHIR" + ], + "enumDescriptions": [ + "Value used when unset.", + "The generic vertical for documents that are not specific to any industry vertical.", + "The media industry vertical.", + "The healthcare FHIR vertical." + ], + "type": "string" + }, + "isInfobotFaqDataStore": { + "description": "Optional. If set, this DataStore is an Infobot FAQ DataStore.", + "type": "boolean" + }, + "kmsKeyName": { + "description": "Input only. The KMS key to be used to protect this DataStore at creation time. Must be set for requests that need to comply with CMEK Org Policy protections. If this field is set and processed successfully, the DataStore will be protected by the KMS key, as indicated in the cmek_config field.", + "type": "string" + }, + "languageInfo": { + "$ref": "GoogleCloudDiscoveryengineV1alphaLanguageInfo", + "description": "Language info for DataStore." + }, + "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" + }, + "naturalLanguageQueryUnderstandingConfig": { + "$ref": "GoogleCloudDiscoveryengineV1alphaNaturalLanguageQueryUnderstandingConfig", + "description": "Optional. Configuration for Natural Language Query Understanding." + }, + "servingConfigDataStore": { + "$ref": "GoogleCloudDiscoveryengineV1alphaDataStoreServingConfigDataStore", + "description": "Optional. Stores serving config at DataStore level." }, "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.", @@ -13416,6 +14185,23 @@ }, "type": "object" }, + "GoogleCloudDiscoveryengineV1alphaDeleteCollectionMetadata": { + "description": "Metadata related to the progress of the CollectionService.UpdateCollection operation. This will be returned by the google.longrunning.Operation.metadata field.", + "id": "GoogleCloudDiscoveryengineV1alphaDeleteCollectionMetadata", + "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" + }, "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", @@ -13512,6 +14298,48 @@ }, "type": "object" }, + "GoogleCloudDiscoveryengineV1alphaDestinationConfig": { + "description": "Defines target endpoints used to connect to third-party sources.", + "id": "GoogleCloudDiscoveryengineV1alphaDestinationConfig", + "properties": { + "destinations": { + "description": "Optional. The destinations for the corresponding key.", + "items": { + "$ref": "GoogleCloudDiscoveryengineV1alphaDestinationConfigDestination" + }, + "type": "array" + }, + "key": { + "description": "Optional. Unique destination identifier that is supported by the connector.", + "type": "string" + }, + "params": { + "additionalProperties": { + "description": "Properties of the object.", + "type": "any" + }, + "description": "Optional. Additional parameters for this destination config.", + "type": "object" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaDestinationConfigDestination": { + "description": "Defines a target endpoint", + "id": "GoogleCloudDiscoveryengineV1alphaDestinationConfigDestination", + "properties": { + "host": { + "description": "Publicly routable host.", + "type": "string" + }, + "port": { + "description": "Optional. Target port number accepted by the destination.", + "format": "int32", + "type": "integer" + } + }, + "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", @@ -13568,7 +14396,7 @@ }, "indexStatus": { "$ref": "GoogleCloudDiscoveryengineV1alphaDocumentIndexStatus", - "description": "Output only. The index status of the document. * If document is indexed successfully, the index_time field is populated. * Otherwise, if document is not indexed due to errors, the error_samples field is populated. * Otherwise, index_status is unset.", + "description": "Output only. The index status of the document. * If document is indexed successfully, the index_time field is populated. * Otherwise, if document is not indexed due to errors, the error_samples field is populated. * Otherwise, if document's index is in progress, the pending_message field is populated.", "readOnly": true }, "indexTime": { @@ -13671,6 +14499,10 @@ "description": "The time when the document was indexed. If this field is populated, it means the document has been indexed.", "format": "google-datetime", "type": "string" + }, + "pendingMessage": { + "description": "Immutable. The message indicates the document index is in progress. If this field is populated, the document index is pending.", + "type": "string" } }, "type": "object" @@ -14565,95 +15397,484 @@ "description": "Optional. The metatag name found in the HTML page. If user defines this field, the value of this metatag name will be used to extract metatag. If the user does not define this field, the FieldConfig.field_path will be used to extract metatag.", "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" + "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" + }, + "schemaOrgPaths": { + "description": "Field paths for indexing custom attribute from schema.org data. More details of schema.org and its defined types can be found at [schema.org](https://schema.org). It is only used on advanced site search schema. Currently only support full path from root. The full path to a field is constructed by concatenating field names, starting from `_root`, with a period `.` as the delimiter. Examples: * Publish date of the root: _root.datePublished * Publish date of the reviews: _root.review.datePublished", + "items": { + "type": "string" + }, + "type": "array" + }, + "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" + }, + "GoogleCloudDiscoveryengineV1alphaFirestoreSource": { + "description": "Firestore source import data from.", + "id": "GoogleCloudDiscoveryengineV1alphaFirestoreSource", + "properties": { + "collectionId": { + "description": "Required. The Firestore collection (or entity) to copy the data from with a length limit of 1,500 characters.", + "type": "string" + }, + "databaseId": { + "description": "Required. The Firestore database to copy the data from with a length limit of 256 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 Firestore export to a specific Cloud Storage directory. Ensure that the Firestore service account has the necessary Cloud Storage Admin permissions to access the specified Cloud Storage directory.", + "type": "string" + }, + "projectId": { + "description": "The project ID that the Cloud SQL source is in with a length limit of 128 characters. If not specified, inherits the project ID from the parent request.", + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaGcsSource": { + "description": "Cloud Storage location for input content.", + "id": "GoogleCloudDiscoveryengineV1alphaGcsSource", + "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 the GENERIC Data Store vertical. * `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 the GENERIC Data Store vertical. Supported values for user event imports: * `user_event` (default): One JSON UserEvent per line.", + "type": "string" + }, + "inputUris": { + "description": "Required. Cloud Storage URIs to input files. Each 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" + }, + "GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentRequest": { + "description": "Top-level message sent by the client for the `GenerateGroundedContent` method.", + "id": "GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentRequest", + "properties": { + "contents": { + "description": "Content of the current conversation with the model. For single-turn queries, this is a single instance. For multi-turn queries, this is a repeated field that contains conversation history + latest request.", + "items": { + "$ref": "GoogleCloudDiscoveryengineV1alphaGroundedGenerationContent" + }, + "type": "array" + }, + "generationSpec": { + "$ref": "GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentRequestGenerationSpec", + "description": "Content generation specification." + }, + "groundingSpec": { + "$ref": "GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentRequestGroundingSpec", + "description": "Grounding specification." + }, + "systemInstruction": { + "$ref": "GoogleCloudDiscoveryengineV1alphaGroundedGenerationContent", + "description": "Content of the system instruction for the current API. These instructions will take priority over any other prompt instructions if the selected model is supporting them." + }, + "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" + }, + "GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentRequestDynamicRetrievalConfiguration": { + "description": "Describes the options to customize dynamic retrieval.", + "id": "GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentRequestDynamicRetrievalConfiguration", + "properties": { + "predictor": { + "$ref": "GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentRequestDynamicRetrievalConfigurationDynamicRetrievalPredictor", + "description": "Specification for the predictor for dynamic retrieval." + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentRequestDynamicRetrievalConfigurationDynamicRetrievalPredictor": { + "description": "Describes the predictor settings for dynamic retrieval.", + "id": "GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentRequestDynamicRetrievalConfigurationDynamicRetrievalPredictor", + "properties": { + "threshold": { + "description": "The value of the threshold. If the predictor will predict a value smaller than this, it would suppress grounding in the source.", + "format": "float", + "type": "number" + }, + "version": { + "description": "The version of the predictor to be used in dynamic retrieval.", + "enum": [ + "VERSION_UNSPECIFIED", + "V1_INDEPENDENT" + ], + "enumDescriptions": [ + "Automatically choose the best version of the retrieval predictor.", + "The V1 model which is evaluating each source independently." + ], + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentRequestGenerationSpec": { + "description": "Content generation specification.", + "id": "GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentRequestGenerationSpec", + "properties": { + "frequencyPenalty": { + "description": "If specified, custom value for frequency penalty will be used.", + "format": "float", + "type": "number" + }, + "languageCode": { + "description": "Language code for content. Use language tags defined by [BCP47](https://www.rfc-editor.org/rfc/bcp/bcp47.txt).", + "type": "string" + }, + "maxOutputTokens": { + "description": "If specified, custom value for max output tokens will be used.", + "format": "int32", + "type": "integer" + }, + "modelId": { + "description": "Specifies which Vertex model id to use for generation.", + "type": "string" + }, + "presencePenalty": { + "description": "If specified, custom value for presence penalty will be used.", + "format": "float", + "type": "number" + }, + "seed": { + "description": "If specified, custom value for the seed will be used.", + "format": "int32", + "type": "integer" + }, + "temperature": { + "description": "If specified, custom value for the temperature will be used.", + "format": "float", + "type": "number" + }, + "topK": { + "description": "If specified, custom value for top-k sampling will be used.", + "format": "int32", + "type": "integer" + }, + "topP": { + "description": "If specified, custom value for nucleus sampling will be used.", + "format": "float", + "type": "number" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentRequestGroundingSource": { + "description": "Grounding source.", + "id": "GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentRequestGroundingSource", + "properties": { + "googleSearchSource": { + "$ref": "GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentRequestGroundingSourceGoogleSearchSource", + "description": "If set, grounding is performed with Google Search." + }, + "inlineSource": { + "$ref": "GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentRequestGroundingSourceInlineSource", + "description": "If set, grounding is performed with inline content." + }, + "searchSource": { + "$ref": "GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentRequestGroundingSourceSearchSource", + "description": "If set, grounding is performed with Vertex AI Search." + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentRequestGroundingSourceGoogleSearchSource": { + "description": "Google Search config parameters.", + "id": "GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentRequestGroundingSourceGoogleSearchSource", + "properties": { + "dynamicRetrievalConfig": { + "$ref": "GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentRequestDynamicRetrievalConfiguration", + "description": "Optional. Specifies the dynamic retrieval configuration for the given source." + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentRequestGroundingSourceInlineSource": { + "description": "Message to be used for grounding based on inline content.", + "id": "GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentRequestGroundingSourceInlineSource", + "properties": { + "attributes": { + "additionalProperties": { + "type": "string" + }, + "description": "Attributes associated with the content. Common attributes include `source` (indicating where the content was sourced from) and `author` (indicating the author of the content).", + "type": "object" + }, + "groundingFacts": { + "description": "List of facts to be used for grounding.", + "items": { + "$ref": "GoogleCloudDiscoveryengineV1alphaGroundingFact" + }, + "type": "array" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentRequestGroundingSourceSearchSource": { + "description": "Message to be used for grounding with Vertex AI Search.", + "id": "GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentRequestGroundingSourceSearchSource", + "properties": { + "filter": { + "description": "Filter expression to be applied to the search. The syntax is the same as SearchRequest.filter.", + "type": "string" + }, + "maxResultCount": { + "description": "Number of search results to return. The default value is 10. The maximumm allowed value is 10.", + "format": "int32", + "type": "integer" + }, + "safeSearch": { + "description": "If set, safe search is enabled in Vertex AI Search requests.", + "type": "boolean" + }, + "servingConfig": { + "description": "The resource name of the Engine to use. Format: `projects/{project}/locations/{location}/collections/{collection_id}/engines/{engine_id}/servingConfigs/{serving_config_id}`", + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentRequestGroundingSpec": { + "description": "Grounding specification.", + "id": "GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentRequestGroundingSpec", + "properties": { + "groundingSources": { + "description": "Grounding sources.", + "items": { + "$ref": "GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentRequestGroundingSource" + }, + "type": "array" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentResponse": { + "description": "Response for the `GenerateGroundedContent` method.", + "id": "GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentResponse", + "properties": { + "candidates": { + "description": "Generated candidates.", + "items": { + "$ref": "GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentResponseCandidate" + }, + "type": "array" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentResponseCandidate": { + "description": "A response candidate generated from the model.", + "id": "GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentResponseCandidate", + "properties": { + "content": { + "$ref": "GoogleCloudDiscoveryengineV1alphaGroundedGenerationContent", + "description": "Content of the candidate." + }, + "groundingMetadata": { + "$ref": "GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentResponseCandidateGroundingMetadata", + "description": "Grounding metadata for the generated content." + }, + "groundingScore": { + "description": "The overall grounding score for the candidate, in the range of [0, 1].", + "format": "float", + "type": "number" + }, + "index": { + "description": "Index of the candidate.", + "format": "int32", + "type": "integer" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentResponseCandidateGroundingMetadata": { + "description": "Citation for the generated content.", + "id": "GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentResponseCandidateGroundingMetadata", + "properties": { + "groundingSupport": { + "description": "GroundingSupport across all claims in the answer candidate. An support to a fact indicates that the claim is supported by the fact.", + "items": { + "$ref": "GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentResponseCandidateGroundingMetadataGroundingSupport" + }, + "type": "array" + }, + "retrievalMetadata": { + "description": "Retrieval metadata to provide an understanding in the retrieval steps performed by the model. There can be multiple such messages which can correspond to different parts of the retrieval. This is a mechanism used to ensure transparency to our users.", + "items": { + "$ref": "GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentResponseCandidateGroundingMetadataRetrievalMetadata" + }, + "type": "array" + }, + "searchEntryPoint": { + "$ref": "GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentResponseCandidateGroundingMetadataSearchEntryPoint", + "description": "Google search entry for the following-up web searches." }, - "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" + "supportChunks": { + "description": "List of chunks to be attributed across all claims in the candidate. These are derived from the grounding sources supplied in the request.", + "items": { + "$ref": "GoogleCloudDiscoveryengineV1alphaFactChunk" + }, + "type": "array" }, - "schemaOrgPaths": { - "description": "Field paths for indexing custom attribute from schema.org data. More details of schema.org and its defined types can be found at [schema.org](https://schema.org). It is only used on advanced site search schema. Currently only support full path from root. The full path to a field is constructed by concatenating field names, starting from `_root`, with a period `.` as the delimiter. Examples: * Publish date of the root: _root.datePublished * Publish date of the reviews: _root.review.datePublished", + "webSearchQueries": { + "description": "Web search queries for the following-up web search.", "items": { "type": "string" }, "type": "array" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentResponseCandidateGroundingMetadataDynamicRetrievalMetadata": { + "description": "Describes the metadata about dynamic retrieval.", + "id": "GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentResponseCandidateGroundingMetadataDynamicRetrievalMetadata", + "properties": { + "predictorMetadata": { + "$ref": "GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentResponseCandidateGroundingMetadataDynamicRetrievalPredictorMetadata", + "description": "Metadata for the dynamic retrieval predictor." + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentResponseCandidateGroundingMetadataDynamicRetrievalPredictorMetadata": { + "description": "Describes the metadata about the dynamic retrieval predictor.", + "id": "GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentResponseCandidateGroundingMetadataDynamicRetrievalPredictorMetadata", + "properties": { + "prediction": { + "description": "The value of the predictor. This should be between [0, 1] where a value of 0 means that the query would not benefit from grounding, while a value of 1.0 means that the query would benefit the most. In between values allow to differentiate between different usefulness scores for grounding.", + "format": "float", + "type": "number" }, - "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.", + "version": { + "description": "The version of the predictor which was used in dynamic retrieval.", "enum": [ - "SEARCHABLE_OPTION_UNSPECIFIED", - "SEARCHABLE_ENABLED", - "SEARCHABLE_DISABLED" + "VERSION_UNSPECIFIED", + "V1_INDEPENDENT" ], "enumDescriptions": [ - "Value used when unset.", - "Searchable option enabled for a schema field.", - "Searchable option disabled for a schema field." + "Unspecified version, should never be used.", + "The V1 model which is evaluating each source independently." ], "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaFirestoreSource": { - "description": "Firestore source import data from.", - "id": "GoogleCloudDiscoveryengineV1alphaFirestoreSource", + "GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentResponseCandidateGroundingMetadataGroundingSupport": { + "description": "Grounding info for a claim in the candidate and its support.", + "id": "GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentResponseCandidateGroundingMetadataGroundingSupport", "properties": { - "collectionId": { - "description": "Required. The Firestore collection (or entity) to copy the data from with a length limit of 1,500 characters.", + "claimText": { + "description": "Text for the claim in the candidate. Always provided when a support is found.", "type": "string" }, - "databaseId": { - "description": "Required. The Firestore database to copy the data from with a length limit of 256 characters.", - "type": "string" + "supportChunkIndices": { + "description": "A list of indices (into 'support_chunks') specifying the citations associated with the claim. For instance [1,3,4] means that support_chunks[1], support_chunks[3], support_chunks[4] are the chunks attributed to the claim.", + "items": { + "format": "int32", + "type": "integer" + }, + "type": "array" }, - "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 Firestore export to a specific Cloud Storage directory. Ensure that the Firestore service account has the necessary Cloud Storage Admin permissions to access the specified Cloud Storage directory.", - "type": "string" + "supportScore": { + "description": "A score in the range of [0, 1] describing how grounded is a specific claim in the support chunks indicated. Higher value means that the claim is better supported by the chunks.", + "format": "float", + "type": "number" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentResponseCandidateGroundingMetadataRetrievalMetadata": { + "description": "Describes the metadata associated with a retrieval step.", + "id": "GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentResponseCandidateGroundingMetadataRetrievalMetadata", + "properties": { + "dynamicRetrievalMetadata": { + "$ref": "GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentResponseCandidateGroundingMetadataDynamicRetrievalMetadata", + "description": "Metadata for dynamic retrieval." }, - "projectId": { - "description": "The project ID that the Cloud SQL source is in with a length limit of 128 characters. If not specified, inherits the project ID from the parent request.", + "source": { + "description": "Describes the source to which the metadata is referring to.", + "enum": [ + "SOURCE_UNSPECIFIED", + "VERTEX_AI_SEARCH", + "GOOGLE_SEARCH", + "INLINE_CONTENT", + "GOOGLE_MAPS" + ], + "enumDescriptions": [ + "Unspecified source.", + "Vertex AI search.", + "Google Search.", + "User inline provided content.", + "Google Maps." + ], "type": "string" } }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaGcsSource": { - "description": "Cloud Storage location for input content.", - "id": "GoogleCloudDiscoveryengineV1alphaGcsSource", + "GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentResponseCandidateGroundingMetadataSearchEntryPoint": { + "description": "Google search entry point.", + "id": "GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentResponseCandidateGroundingMetadataSearchEntryPoint", "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 the GENERIC Data Store vertical. * `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 the GENERIC Data Store vertical. Supported values for user event imports: * `user_event` (default): One JSON UserEvent per line.", + "renderedContent": { + "description": "Web content snippet that can be embedded in a web page or an app webview.", "type": "string" }, - "inputUris": { - "description": "Required. Cloud Storage URIs to input files. Each 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" + "sdkBlob": { + "description": "Base64 encoded JSON representing array of tuple.", + "format": "byte", + "type": "string" } }, "type": "object" @@ -14691,6 +15912,35 @@ }, "type": "object" }, + "GoogleCloudDiscoveryengineV1alphaGroundedGenerationContent": { + "description": "Base structured datatype containing multi-part content of a message.", + "id": "GoogleCloudDiscoveryengineV1alphaGroundedGenerationContent", + "properties": { + "parts": { + "description": "Ordered `Parts` that constitute a single message.", + "items": { + "$ref": "GoogleCloudDiscoveryengineV1alphaGroundedGenerationContentPart" + }, + "type": "array" + }, + "role": { + "description": "Producer of the content. Must be either `user` or `model`. Intended to be used for multi-turn conversations. Otherwise, it can be left unset.", + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaGroundedGenerationContentPart": { + "description": "Single part of content.", + "id": "GoogleCloudDiscoveryengineV1alphaGroundedGenerationContentPart", + "properties": { + "text": { + "description": "Inline text.", + "type": "string" + } + }, + "type": "object" + }, "GoogleCloudDiscoveryengineV1alphaGroundingFact": { "description": "Grounding Fact.", "id": "GoogleCloudDiscoveryengineV1alphaGroundingFact", @@ -14729,6 +15979,18 @@ }, "type": "object" }, + "GoogleCloudDiscoveryengineV1alphaIdentityScheduleConfig": { + "description": "The configuration for the identity data synchronization runs.", + "id": "GoogleCloudDiscoveryengineV1alphaIdentityScheduleConfig", + "properties": { + "refreshInterval": { + "description": "Optional. The refresh interval to sync the Access Control List information for the documents ingested by this connector. If not set, the access control list will be refreshed at the default interval of 30 minutes. The identity refresh interval can be at least 30 minutes and at most 7 days.", + "format": "google-duration", + "type": "string" + } + }, + "type": "object" + }, "GoogleCloudDiscoveryengineV1alphaIdpConfig": { "description": "Identity Provider Config.", "id": "GoogleCloudDiscoveryengineV1alphaIdpConfig", @@ -15330,6 +16592,42 @@ }, "type": "object" }, + "GoogleCloudDiscoveryengineV1alphaListCollectionsResponse": { + "description": "Response message for CollectionService.ListCollections method.", + "id": "GoogleCloudDiscoveryengineV1alphaListCollectionsResponse", + "properties": { + "collections": { + "description": "The Collections.", + "items": { + "$ref": "GoogleCloudDiscoveryengineV1alphaCollection" + }, + "type": "array" + }, + "nextPageToken": { + "description": "A token that can be sent as ListCollectionsRequest.page_token to retrieve the next page. If this field is omitted, there are no subsequent pages.", + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaListConnectorRunsResponse": { + "description": "Response for DataConnectorService.ListConnectorRuns method.", + "id": "GoogleCloudDiscoveryengineV1alphaListConnectorRunsResponse", + "properties": { + "connectorRuns": { + "description": "List of ConnectorRuns.", + "items": { + "$ref": "GoogleCloudDiscoveryengineV1alphaConnectorRun" + }, + "type": "array" + }, + "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" + } + }, + "type": "object" + }, "GoogleCloudDiscoveryengineV1alphaListControlsResponse": { "description": "Response for ListControls method.", "id": "GoogleCloudDiscoveryengineV1alphaListControlsResponse", @@ -18502,6 +19800,31 @@ }, "type": "object" }, + "GoogleCloudDiscoveryengineV1alphaSetUpDataConnectorMetadata": { + "description": "Metadata for DataConnectorService.SetUpDataConnector method.", + "id": "GoogleCloudDiscoveryengineV1alphaSetUpDataConnectorMetadata", + "properties": {}, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaSetUpDataConnectorRequest": { + "description": "Request for DataConnectorService.SetUpDataConnector method.", + "id": "GoogleCloudDiscoveryengineV1alphaSetUpDataConnectorRequest", + "properties": { + "collectionDisplayName": { + "description": "Required. The display name of the Collection. Should be human readable, used to display collections in the Console Dashboard. UTF-8 encoded string with limit of 1024 characters.", + "type": "string" + }, + "collectionId": { + "description": "Required. The ID to use for the Collection, which will become the final component of the Collection's resource name. A new Collection is created as part of the DataConnector setup. DataConnector is a singleton resource under Collection, managing all DataStores of the Collection. 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.", + "type": "string" + }, + "dataConnector": { + "$ref": "GoogleCloudDiscoveryengineV1alphaDataConnector", + "description": "Required. The DataConnector to initialize in the newly created Collection." + } + }, + "type": "object" + }, "GoogleCloudDiscoveryengineV1alphaSetUriPatternDocumentDataMetadata": { "description": "Metadata related to the progress of the SiteSearchEngineService.SetUriPatternDocumentData operation. This will be returned by the google.longrunning.Operation.metadata field.", "id": "GoogleCloudDiscoveryengineV1alphaSetUriPatternDocumentDataMetadata", @@ -18555,6 +19878,17 @@ "properties": {}, "type": "object" }, + "GoogleCloudDiscoveryengineV1alphaSingleRegionKey": { + "description": "Metadata for single-regional CMEKs.", + "id": "GoogleCloudDiscoveryengineV1alphaSingleRegionKey", + "properties": { + "kmsKey": { + "description": "Required. Single-regional kms key resource name which will be used to encrypt resources `projects/{project}/locations/{location}/keyRings/{keyRing}/cryptoKeys/{keyId}`.", + "type": "string" + } + }, + "type": "object" + }, "GoogleCloudDiscoveryengineV1alphaSiteSearchEngine": { "description": "SiteSearchEngine captures DataStore level site search persisting configurations. It is a singleton value per data store.", "id": "GoogleCloudDiscoveryengineV1alphaSiteSearchEngine", @@ -18643,6 +19977,36 @@ }, "type": "object" }, + "GoogleCloudDiscoveryengineV1alphaStartConnectorRunRequest": { + "description": "Request message for DataConnectorService.StartConnectorRun method.", + "id": "GoogleCloudDiscoveryengineV1alphaStartConnectorRunRequest", + "properties": { + "entities": { + "description": "Specifies which Third Party Connector entities should be synced. If not specified, all entities will be synced.", + "items": { + "type": "string" + }, + "type": "array" + }, + "healthcareFhirResourceTypes": { + "description": "The FHIR resource types to import. The resource types should be a subset of all supported FHIR resource types http://shortn/_J8ymdyOokT. Default to all supported FHIR resource types if empty.", + "items": { + "type": "string" + }, + "type": "array" + }, + "syncIdentity": { + "description": "If true, trigger Identity sync.", + "type": "boolean" + }, + "syncSinceTimestamp": { + "description": "Timestamp to indicate the point in time from which data should be synced for Streaming/Batch Data Connectors. This field is only utilized for Healthcare Connectors.", + "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", @@ -18957,6 +20321,23 @@ }, "type": "object" }, + "GoogleCloudDiscoveryengineV1alphaUpdateCollectionMetadata": { + "description": "Metadata related to the progress of the CollectionService.UpdateCollection operation. This will be returned by the google.longrunning.Operation.metadata field.", + "id": "GoogleCloudDiscoveryengineV1alphaUpdateCollectionMetadata", + "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" + }, "GoogleCloudDiscoveryengineV1alphaUpdateSchemaMetadata": { "description": "Metadata for UpdateSchema LRO.", "id": "GoogleCloudDiscoveryengineV1alphaUpdateSchemaMetadata", @@ -19240,6 +20621,13 @@ "description": "Required. Name of the CmekConfig, of the form `projects/{project}/locations/{location}/cmekConfig` or `projects/{project}/locations/{location}/cmekConfigs/{cmekConfig}`.", "type": "string" }, + "singleRegionKeys": { + "description": "Optional. Single-regional CMEKs that are required for some VAIS features.", + "items": { + "$ref": "GoogleCloudDiscoveryengineV1betaSingleRegionKey" + }, + "type": "array" + }, "state": { "description": "Output only. State of the CmekConfig.", "enum": [ @@ -19645,6 +21033,10 @@ ], "type": "string" }, + "isInfobotFaqDataStore": { + "description": "Optional. If set, this DataStore is an Infobot FAQ DataStore.", + "type": "boolean" + }, "kmsKeyName": { "description": "Input only. The KMS key to be used to protect this DataStore at creation time. Must be set for requests that need to comply with CMEK Org Policy protections. If this field is set and processed successfully, the DataStore will be protected by the KMS key, as indicated in the cmek_config field.", "type": "string" @@ -21579,6 +22971,17 @@ }, "type": "object" }, + "GoogleCloudDiscoveryengineV1betaSingleRegionKey": { + "description": "Metadata for single-regional CMEKs.", + "id": "GoogleCloudDiscoveryengineV1betaSingleRegionKey", + "properties": { + "kmsKey": { + "description": "Required. Single-regional kms key resource name which will be used to encrypt resources `projects/{project}/locations/{location}/keyRings/{keyRing}/cryptoKeys/{keyId}`.", + "type": "string" + } + }, + "type": "object" + }, "GoogleCloudDiscoveryengineV1betaSiteVerificationInfo": { "description": "Verification information for target sites in advanced site search.", "id": "GoogleCloudDiscoveryengineV1betaSiteVerificationInfo", @@ -22138,6 +23541,57 @@ }, "type": "object" }, + "GoogleTypeDateTime": { + "description": "Represents civil time (or occasionally physical time). This type can represent a civil time in one of a few possible ways: * When utc_offset is set and time_zone is unset: a civil time on a calendar day with a particular offset from UTC. * When time_zone is set and utc_offset is unset: a civil time on a calendar day in a particular time zone. * When neither time_zone nor utc_offset is set: a civil time on a calendar day in local time. The date is relative to the Proleptic Gregorian Calendar. If year, month, or day are 0, the DateTime is considered not to have a specific year, month, or day respectively. This type may also be used to represent a physical time if all the date and time fields are set and either case of the `time_offset` oneof is set. Consider using `Timestamp` message for physical time instead. If your use case also would like to store the user's timezone, that can be done in another field. This type is more flexible than some applications may want. Make sure to document and validate your application's limitations.", + "id": "GoogleTypeDateTime", + "properties": { + "day": { + "description": "Optional. Day of month. Must be from 1 to 31 and valid for the year and month, or 0 if specifying a datetime without a day.", + "format": "int32", + "type": "integer" + }, + "hours": { + "description": "Optional. Hours of day in 24 hour format. Should be from 0 to 23, defaults to 0 (midnight). An API may choose to allow the value \"24:00:00\" for scenarios like business closing time.", + "format": "int32", + "type": "integer" + }, + "minutes": { + "description": "Optional. Minutes of hour of day. Must be from 0 to 59, defaults to 0.", + "format": "int32", + "type": "integer" + }, + "month": { + "description": "Optional. Month of year. Must be from 1 to 12, or 0 if specifying a datetime without a month.", + "format": "int32", + "type": "integer" + }, + "nanos": { + "description": "Optional. Fractions of seconds in nanoseconds. Must be from 0 to 999,999,999, defaults to 0.", + "format": "int32", + "type": "integer" + }, + "seconds": { + "description": "Optional. Seconds of minutes of the time. Must normally be from 0 to 59, defaults to 0. An API may allow the value 60 if it allows leap-seconds.", + "format": "int32", + "type": "integer" + }, + "timeZone": { + "$ref": "GoogleTypeTimeZone", + "description": "Time zone." + }, + "utcOffset": { + "description": "UTC offset. Must be whole seconds, between -18 hours and +18 hours. For example, a UTC offset of -4:00 would be represented as { seconds: -14400 }.", + "format": "google-duration", + "type": "string" + }, + "year": { + "description": "Optional. Year of date. Must be from 1 to 9999, or 0 if specifying a datetime without a year.", + "format": "int32", + "type": "integer" + } + }, + "type": "object" + }, "GoogleTypeExpr": { "description": "Represents a textual expression in the Common Expression Language (CEL) syntax. CEL is a C-like expression language. The syntax and semantics of CEL are documented at https://github.com/google/cel-spec. Example (Comparison): title: \"Summary size limit\" description: \"Determines if a summary is less than 100 chars\" expression: \"document.summary.size() \u003c 100\" Example (Equality): title: \"Requestor is owner\" description: \"Determines if requestor is the document owner\" expression: \"document.owner == request.auth.claims.email\" Example (Logic): title: \"Public documents\" description: \"Determine whether the document should be publicly visible\" expression: \"document.type != 'private' \u0026\u0026 document.type != 'internal'\" Example (Data Manipulation): title: \"Notification string\" description: \"Create a notification string with a timestamp.\" expression: \"'New message received at ' + string(document.create_time)\" The exact variables and functions that may be referenced within an expression are determined by the service that evaluates it. See the service documentation for additional information.", "id": "GoogleTypeExpr", @@ -22160,6 +23614,21 @@ } }, "type": "object" + }, + "GoogleTypeTimeZone": { + "description": "Represents a time zone from the [IANA Time Zone Database](https://www.iana.org/time-zones).", + "id": "GoogleTypeTimeZone", + "properties": { + "id": { + "description": "IANA Time Zone Database time zone. For example \"America/New_York\".", + "type": "string" + }, + "version": { + "description": "Optional. IANA Time Zone Database version number. For example \"2019a\".", + "type": "string" + } + }, + "type": "object" } }, "servicePath": "", diff --git a/discoveryengine/v1alpha/discoveryengine-gen.go b/discoveryengine/v1alpha/discoveryengine-gen.go index 3a680dfcfd..63ed974224 100644 --- a/discoveryengine/v1alpha/discoveryengine-gen.go +++ b/discoveryengine/v1alpha/discoveryengine-gen.go @@ -249,6 +249,7 @@ type ProjectsLocationsCollectionsService struct { func NewProjectsLocationsCollectionsDataConnectorService(s *Service) *ProjectsLocationsCollectionsDataConnectorService { rs := &ProjectsLocationsCollectionsDataConnectorService{s: s} + rs.ConnectorRuns = NewProjectsLocationsCollectionsDataConnectorConnectorRunsService(s) rs.Operations = NewProjectsLocationsCollectionsDataConnectorOperationsService(s) return rs } @@ -256,9 +257,20 @@ func NewProjectsLocationsCollectionsDataConnectorService(s *Service) *ProjectsLo type ProjectsLocationsCollectionsDataConnectorService struct { s *Service + ConnectorRuns *ProjectsLocationsCollectionsDataConnectorConnectorRunsService + Operations *ProjectsLocationsCollectionsDataConnectorOperationsService } +func NewProjectsLocationsCollectionsDataConnectorConnectorRunsService(s *Service) *ProjectsLocationsCollectionsDataConnectorConnectorRunsService { + rs := &ProjectsLocationsCollectionsDataConnectorConnectorRunsService{s: s} + return rs +} + +type ProjectsLocationsCollectionsDataConnectorConnectorRunsService struct { + s *Service +} + func NewProjectsLocationsCollectionsDataConnectorOperationsService(s *Service) *ProjectsLocationsCollectionsDataConnectorOperationsService { rs := &ProjectsLocationsCollectionsDataConnectorOperationsService{s: s} return rs @@ -1819,6 +1831,9 @@ type GoogleCloudDiscoveryengineV1CmekConfig struct { // `projects/{project}/locations/{location}/cmekConfig` or // `projects/{project}/locations/{location}/cmekConfigs/{cmekConfig}`. Name string `json:"name,omitempty"` + // SingleRegionKeys: Optional. Single-regional CMEKs that are required for some + // VAIS features. + SingleRegionKeys []*GoogleCloudDiscoveryengineV1SingleRegionKey `json:"singleRegionKeys,omitempty"` // State: Output only. State of the CmekConfig. // // Possible values: @@ -2313,6 +2328,9 @@ type GoogleCloudDiscoveryengineV1DataStore struct { // "MEDIA" - The media industry vertical. // "HEALTHCARE_FHIR" - The healthcare FHIR vertical. IndustryVertical string `json:"industryVertical,omitempty"` + // IsInfobotFaqDataStore: Optional. If set, this DataStore is an Infobot FAQ + // DataStore. + IsInfobotFaqDataStore bool `json:"isInfobotFaqDataStore,omitempty"` // KmsKeyName: Input only. The KMS key to be used to protect this DataStore at // creation time. Must be set for requests that need to comply with CMEK Org // Policy protections. If this field is set and processed successfully, the @@ -4107,6 +4125,32 @@ func (s *GoogleCloudDiscoveryengineV1ServingConfigMediaConfig) UnmarshalJSON(dat return nil } +// GoogleCloudDiscoveryengineV1SingleRegionKey: Metadata for single-regional +// CMEKs. +type GoogleCloudDiscoveryengineV1SingleRegionKey struct { + // KmsKey: Required. Single-regional kms key resource name which will be used + // to encrypt resources + // `projects/{project}/locations/{location}/keyRings/{keyRing}/cryptoKeys/{keyId + // }`. + KmsKey string `json:"kmsKey,omitempty"` + // ForceSendFields is a list of field names (e.g. "KmsKey") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "KmsKey") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1SingleRegionKey) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1SingleRegionKey + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudDiscoveryengineV1SiteVerificationInfo: Verification information // for target sites in advanced site search. type GoogleCloudDiscoveryengineV1SiteVerificationInfo struct { @@ -4475,6 +4519,38 @@ func (s GoogleCloudDiscoveryengineV1alphaAclConfig) MarshalJSON() ([]byte, error return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudDiscoveryengineV1alphaActionConfig: Informations to support +// actions on the connector. +type GoogleCloudDiscoveryengineV1alphaActionConfig struct { + // ActionParams: Required. Params needed to support actions in the format of + // (Key, Value) pairs. Required parameters for sources that support OAUTH, i.e. + // `gmail`, `google_calendar`, `jira`, `workday`, `salesforce`, `confluence`: * + // Key: `client_id` * Value: type STRING. The client id for the service + // provider to identify your application. * Key: `client_secret` * Value:type + // STRING. The client secret generated by the application's authorization + // server. + ActionParams googleapi.RawMessage `json:"actionParams,omitempty"` + // IsActionConfigured: Output only. The connector contains the necessary + // parameters and is configured to support actions. + IsActionConfigured bool `json:"isActionConfigured,omitempty"` + // ForceSendFields is a list of field names (e.g. "ActionParams") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "ActionParams") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1alphaActionConfig) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaActionConfig + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudDiscoveryengineV1alphaAdvancedCompleteQueryRequest: Request // message for CompletionService.AdvancedCompleteQuery method. . type GoogleCloudDiscoveryengineV1alphaAdvancedCompleteQueryRequest struct { @@ -7158,6 +7234,9 @@ type GoogleCloudDiscoveryengineV1alphaCmekConfig struct { // `projects/{project}/locations/{location}/cmekConfig` or // `projects/{project}/locations/{location}/cmekConfigs/{cmekConfig}`. Name string `json:"name,omitempty"` + // SingleRegionKeys: Optional. Single-regional CMEKs that are required for some + // VAIS features. + SingleRegionKeys []*GoogleCloudDiscoveryengineV1alphaSingleRegionKey `json:"singleRegionKeys,omitempty"` // State: Output only. State of the CmekConfig. // // Possible values: @@ -7192,6 +7271,50 @@ func (s GoogleCloudDiscoveryengineV1alphaCmekConfig) MarshalJSON() ([]byte, erro return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudDiscoveryengineV1alphaCollection: Collection is a container for +// configuring resources and access to a set of DataStores. +type GoogleCloudDiscoveryengineV1alphaCollection struct { + // CreateTime: Output only. Timestamp the Collection was created at. + CreateTime string `json:"createTime,omitempty"` + // DataConnector: Output only. The data connector, if present, manages the + // connection for data stores in the Collection. To set up the connector, use + // DataConnectorService.SetUpDataConnector method, which creates a new + // Collection while setting up the DataConnector singleton resource. Setting up + // connector on an existing Collection is not supported. This output only field + // contains a subset of the DataConnector fields, including `name`, + // `data_source`, `entities.entity_name` and `entities.data_store`. To get more + // details about a data connector, use the DataConnector.GetDataConnector + // method. + DataConnector *GoogleCloudDiscoveryengineV1alphaDataConnector `json:"dataConnector,omitempty"` + // DisplayName: Required. The Collection 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"` + // Name: Immutable. The full resource name of the Collection. Format: + // `projects/{project}/locations/{location}/collections/{collection_id}`. 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:"-"` + // ForceSendFields is a list of field names (e.g. "CreateTime") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "CreateTime") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1alphaCollection) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaCollection + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudDiscoveryengineV1alphaCompleteQueryResponse: Response message for // CompletionService.CompleteQuery method. type GoogleCloudDiscoveryengineV1alphaCompleteQueryResponse struct { @@ -7417,6 +7540,138 @@ func (s GoogleCloudDiscoveryengineV1alphaConditionTimeRange) MarshalJSON() ([]by return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudDiscoveryengineV1alphaConnectorRun: A data sync run of +// DataConnector. After DataConnector is successfully initialized, data syncs +// are scheduled at DataConnector.refresh_interval. A ConnectorRun represents a +// data sync either in the past or onging that the moment. // +type GoogleCloudDiscoveryengineV1alphaConnectorRun struct { + // EndTime: Output only. The time when the connector run ended. + EndTime string `json:"endTime,omitempty"` + // EntityRuns: Output only. The details of the entities synced at the + // ConnectorRun. Each ConnectorRun consists of syncing one or more entities. + EntityRuns []*GoogleCloudDiscoveryengineV1alphaConnectorRunEntityRun `json:"entityRuns,omitempty"` + // Errors: Contains info about errors incurred during the sync. Only exist if + // running into an error state. Contains error code and error message. Use with + // the `state` field. + Errors []*GoogleRpcStatus `json:"errors,omitempty"` + // LatestPauseTime: Output only. The time when the connector run was most + // recently paused. + LatestPauseTime string `json:"latestPauseTime,omitempty"` + // Name: Output only. The full resource name of the Connector Run. Format: + // `projects/*/locations/*/collections/*/dataConnector/connectorRuns/*`. The + // `connector_run_id` is system-generated. + Name string `json:"name,omitempty"` + // StartTime: Output only. The time when the connector run started. + StartTime string `json:"startTime,omitempty"` + // State: Output only. The state of the sync run. + // + // Possible values: + // "STATE_UNSPECIFIED" - Default value. + // "RUNNING" - The data sync is ongoing. + // "SUCCEEDED" - The data sync is finished. + // "FAILED" - The data sync is failed. + // "OVERRUN" - Data sync has been running longer than expected and is still + // running at the time the next run is supposed to start. + // "CANCELLED" - Data sync was scheduled but has been cancelled. + // "PENDING" - Data sync is about to start. + // "WARNING" - The data sync completed with non-fatal errors. + State string `json:"state,omitempty"` + // StateUpdateTime: Timestamp at which the connector run sync state was last + // updated. + StateUpdateTime string `json:"stateUpdateTime,omitempty"` + // Trigger: Output only. The trigger for this ConnectorRun. + // + // Possible values: + // "TRIGGER_UNSPECIFIED" - Default value. + // "SCHEDULER" - ConnectorRun triggered by scheduler if connector has + // PERIODIC sync mode. + // "INITIALIZATION" - ConnectorRun auto triggered by connector + // initialization. + // "RESUME" - ConnectorRun auto triggered by resuming connector. + // "MANUAL" - ConnectorRun triggered by user manually. + Trigger string `json:"trigger,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. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + 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. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1alphaConnectorRun) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaConnectorRun + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaConnectorRunEntityRun: Represents an entity +// that was synced in this ConnectorRun. +type GoogleCloudDiscoveryengineV1alphaConnectorRunEntityRun struct { + // EntityName: The name of the source entity. + EntityName string `json:"entityName,omitempty"` + // ErrorRecordCount: The total number of documents failed at sync at any stage + // (extraction, indexing, etc). + ErrorRecordCount int64 `json:"errorRecordCount,omitempty,string"` + // Errors: The errors from the entity's sync run. Only exist if running into an + // error state. Contains error code and error message. + Errors []*GoogleRpcStatus `json:"errors,omitempty"` + // ExtractedRecordCount: The number of documents extracted from connector + // source, ready to be ingested to UCS. + ExtractedRecordCount int64 `json:"extractedRecordCount,omitempty,string"` + // IndexedRecordCount: The number of documents indexed. + IndexedRecordCount int64 `json:"indexedRecordCount,omitempty,string"` + // SourceApiRequestCount: The number of requests sent to 3p API. + SourceApiRequestCount int64 `json:"sourceApiRequestCount,omitempty,string"` + // State: The state of the entity's sync run. + // + // Possible values: + // "STATE_UNSPECIFIED" - Default value. + // "RUNNING" - The data sync is ongoing. + // "SUCCEEDED" - The data sync is finished. + // "FAILED" - The data sync is failed. + // "OVERRUN" - Data sync has been running longer than expected and is still + // running at the time the next run is supposed to start. + // "CANCELLED" - Data sync was scheduled but has been cancelled. + // "PENDING" - Data sync is about to start. + // "WARNING" - The data sync completed with non-fatal errors. + State string `json:"state,omitempty"` + // StateUpdateTime: Timestamp at which the entity sync state was last updated. + StateUpdateTime string `json:"stateUpdateTime,omitempty"` + // StatsUpdateTime: The timestamp for either extracted_documents_count, + // indexed_documents_count and error_documents_count was last updated. + StatsUpdateTime string `json:"statsUpdateTime,omitempty"` + // SyncType: Sync type of this run. + // + // Possible values: + // "SYNC_TYPE_UNSPECIFIED" - Sync type unspecified. + // "FULL" - Sync triggers full sync of all documents. + // "INCREMENTAL" - Incremental sync of updated documents. + SyncType string `json:"syncType,omitempty"` + // ForceSendFields is a list of field names (e.g. "EntityName") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "EntityName") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1alphaConnectorRunEntityRun) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaConnectorRunEntityRun + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudDiscoveryengineV1alphaControl: Defines a conditioned behavior to // employ during serving. Must be attached to a ServingConfig to be considered // at serving time. Permitted actions dependent on `SolutionType`. @@ -8165,6 +8420,198 @@ func (s GoogleCloudDiscoveryengineV1alphaCustomTuningModel) MarshalJSON() ([]byt return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudDiscoveryengineV1alphaDataConnector: Manages the connection to +// external data sources for all data stores grouped under a Collection. It's a +// singleton resource of Collection. The initialization is only supported +// through SetUpDataConnector method, which will create a new Collection and +// initialize its DataConnector. // +type GoogleCloudDiscoveryengineV1alphaDataConnector struct { + // ActionConfig: Optional. Action configurations to make the connector support + // actions. + ActionConfig *GoogleCloudDiscoveryengineV1alphaActionConfig `json:"actionConfig,omitempty"` + // AutoRunDisabled: Indicates whether the connector is disabled for auto run. + // It can be used to pause periodical and real time sync. + AutoRunDisabled bool `json:"autoRunDisabled,omitempty"` + // BlockingReasons: Output only. User actions that must be completed before the + // connector can start syncing data. + // + // Possible values: + // "BLOCKING_REASON_UNSPECIFIED" - Default value. + // "ALLOWLIST_STATIC_IP" - Connector requires customer to allowlist static + // IPs. + // "ALLOWLIST_IN_SERVICE_ATTACHMENT" - Connector requires customer to + // allowlist our project in their service attachment. + BlockingReasons []string `json:"blockingReasons,omitempty"` + // CreateTime: Output only. Timestamp the DataConnector was created at. + CreateTime string `json:"createTime,omitempty"` + // DataSource: Required. The name of the data source. Supported values: + // `salesforce`, `jira`, `confluence`, `bigquery`. + DataSource string `json:"dataSource,omitempty"` + // DestinationConfigs: Optional. Any target destinations used to connect to + // third-party services. + DestinationConfigs []*GoogleCloudDiscoveryengineV1alphaDestinationConfig `json:"destinationConfigs,omitempty"` + // Entities: List of entities from the connected data source to ingest. + Entities []*GoogleCloudDiscoveryengineV1alphaDataConnectorSourceEntity `json:"entities,omitempty"` + // Errors: Output only. The errors from initialization or from the latest + // connector run. + Errors []*GoogleRpcStatus `json:"errors,omitempty"` + // IdentityRefreshInterval: The refresh interval to sync the Access Control + // List information for the documents ingested by this connector. If not set, + // the access control list will be refreshed at the default interval of 30 + // minutes. The identity refresh interval can be at least 30 minutes and at + // most 7 days. + IdentityRefreshInterval string `json:"identityRefreshInterval,omitempty"` + // IdentityScheduleConfig: The configuration for the identity data + // synchronization runs. This contains the refresh interval to sync the Access + // Control List information for the documents ingested by this connector. + IdentityScheduleConfig *GoogleCloudDiscoveryengineV1alphaIdentityScheduleConfig `json:"identityScheduleConfig,omitempty"` + // KmsKeyName: Input only. The KMS key to be used to protect the DataStores + // managed by this connector. Must be set for requests that need to comply with + // CMEK Org Policy protections. If this field is set and processed + // successfully, the DataStores created by this connector will be protected by + // the KMS key. + KmsKeyName string `json:"kmsKeyName,omitempty"` + // LastSyncTime: Output only. For periodic connectors only, the last time a + // data sync was completed. + LastSyncTime string `json:"lastSyncTime,omitempty"` + // LatestPauseTime: Output only. The most recent timestamp when this + // DataConnector was paused, affecting all functionalities such as data + // synchronization. Pausing a connector has the following effects: - All + // functionalities, including data synchronization, are halted. - Any ongoing + // data synchronization job will be canceled. - No future data synchronization + // runs will be scheduled nor can be triggered. + LatestPauseTime string `json:"latestPauseTime,omitempty"` + // Name: Output only. The full resource name of the Data Connector. Format: + // `projects/*/locations/*/collections/*/dataConnector`. + Name string `json:"name,omitempty"` + // NextSyncTime: The UTC time when the next data sync is expected to start for + // the Data Connector. Customers are only able to specify the hour and minute + // to schedule the data sync. This is utilized when the data connector has a + // refresh interval greater than 1 day. + NextSyncTime *GoogleTypeDateTime `json:"nextSyncTime,omitempty"` + // Params: Required. Params needed to access the source in the format of (Key, + // Value) pairs. Required parameters for all data sources: * Key: + // `instance_uri` * Value: type STRING. The uri to access the data source. + // Required parameters for sources that support OAUTH, i.e. `salesforce`: * + // Key: `client_id` * Value: type STRING. The client id for the third party + // service provider to identify your application. * Key: `client_secret` * + // Value:type STRING. The client secret generated by the third party + // authorization server. * Key: `access_token` * Value: type STRING. OAuth + // token for UCS to access to the protected resource. * Key: `refresh_token` * + // Value: type STRING. OAuth refresh token for UCS to obtain a new access token + // without user interaction. Required parameters for sources that support basic + // API token auth, i.e. `jira`, `confluence`: * Key: `user_account` * Value: + // type STRING. The username or email with the source. * Key: `api_token` * + // Value: type STRING. The API token generated for the source account, that is + // used for authenticating anywhere where you would have used a password. + // Example: ```json { "instance_uri": "https://xxx.atlassian.net", + // "user_account": "xxxx.xxx@xxx.com", "api_token": "test-token" } ``` Optional + // parameter to specify the authorization type to use for multiple + // authorization types support: * Key: `auth_type` * Value: type STRING. The + // authorization type for the data source. Supported values: `BASIC_AUTH`, + // `OAUTH`, `OAUTH_ACCESS_TOKEN`, `OAUTH_TWO_LEGGED`, `OAUTH_JWT_BEARER`, + // `OAUTH_PASSWORD_GRANT`, `JWT`, `API_TOKEN`, `FEDERATED_CREDENTIAL`. + Params googleapi.RawMessage `json:"params,omitempty"` + // PrivateConnectivityProjectId: Output only. The tenant project ID associated + // with private connectivity connectors. This project must be allowlisted by in + // order for the connector to function. + PrivateConnectivityProjectId string `json:"privateConnectivityProjectId,omitempty"` + // RefreshInterval: Required. The refresh interval for data sync. If duration + // is set to 0, the data will be synced in real time. The streaming feature is + // not supported yet. The minimum is 30 minutes and maximum is 7 days. + RefreshInterval string `json:"refreshInterval,omitempty"` + // State: Output only. State of the connector. + // + // Possible values: + // "STATE_UNSPECIFIED" - Default value. + // "CREATING" - The connector is being set up. + // "ACTIVE" - The connector is successfully set up and awaiting next sync + // run. + // "FAILED" - The connector is in error. The error details can be found in + // DataConnector.errors. If the error is unfixable, the DataConnector can be + // deleted by [CollectionService.DeleteCollection] API. + // "RUNNING" - The connector is actively syncing records from the data + // source. + // "WARNING" - The connector has completed a sync run, but encountered + // non-fatal errors. + State string `json:"state,omitempty"` + // StaticIpAddresses: Output only. The static IP addresses used by this + // connector. + StaticIpAddresses []string `json:"staticIpAddresses,omitempty"` + // StaticIpEnabled: Optional. Whether customer has enabled static IP addresses + // for this connector. + StaticIpEnabled bool `json:"staticIpEnabled,omitempty"` + // SyncMode: The data synchronization mode supported by the data connector. + // + // Possible values: + // "PERIODIC" - The connector will sync data periodically based on the + // refresh_interval. Use it with auto_run_disabled to pause the periodic sync, + // or indicate a one-time sync. + SyncMode string `json:"syncMode,omitempty"` + // UpdateTime: Output only. Timestamp the DataConnector 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. "ActionConfig") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "ActionConfig") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1alphaDataConnector) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaDataConnector + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaDataConnectorSourceEntity: Represents an +// entity in the data source. For example, the `Account` object in Salesforce. +type GoogleCloudDiscoveryengineV1alphaDataConnectorSourceEntity struct { + // DataStore: Output only. The full resource name of the associated data store + // for the source entity. Format: + // `projects/*/locations/*/collections/*/dataStores/*`. When the connector is + // initialized by the DataConnectorService.SetUpDataConnector method, a + // DataStore is automatically created for each source entity. + DataStore string `json:"dataStore,omitempty"` + // EntityName: The name of the entity. Supported values by data source: * + // Salesforce: `Lead`, `Opportunity`, `Contact`, `Account`, `Case`, `Contract`, + // `Campaign` * Jira: `Issue` * Confluence: `Content`, `Space` + EntityName string `json:"entityName,omitempty"` + // KeyPropertyMappings: Attributes for indexing. Key: Field name. Value: The + // key property to map a field to, such as `title`, and `description`. + // Supported key properties: * `title`: The title for data record. This would + // be displayed on search results. * `description`: The description for data + // record. This would be displayed on search results. + KeyPropertyMappings map[string]string `json:"keyPropertyMappings,omitempty"` + // Params: The parameters for the entity to facilitate data ingestion. E.g. for + // BQ connectors: * Key: `document_id_column` * Value: type STRING. The value + // of the column id. + Params googleapi.RawMessage `json:"params,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. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // 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. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1alphaDataConnectorSourceEntity) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaDataConnectorSourceEntity + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudDiscoveryengineV1alphaDataStore: DataStore captures global // settings and configs at the DataStore level. type GoogleCloudDiscoveryengineV1alphaDataStore struct { @@ -8217,6 +8664,9 @@ type GoogleCloudDiscoveryengineV1alphaDataStore struct { // "MEDIA" - The media industry vertical. // "HEALTHCARE_FHIR" - The healthcare FHIR vertical. IndustryVertical string `json:"industryVertical,omitempty"` + // IsInfobotFaqDataStore: Optional. If set, this DataStore is an Infobot FAQ + // DataStore. + IsInfobotFaqDataStore bool `json:"isInfobotFaqDataStore,omitempty"` // KmsKeyName: Input only. The KMS key to be used to protect this DataStore at // creation time. Must be set for requests that need to comply with CMEK Org // Policy protections. If this field is set and processed successfully, the @@ -8375,6 +8825,33 @@ func (s GoogleCloudDiscoveryengineV1alphaDedicatedCrawlRateTimeSeries) MarshalJS return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudDiscoveryengineV1alphaDeleteCollectionMetadata: Metadata related +// to the progress of the CollectionService.UpdateCollection operation. This +// will be returned by the google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1alphaDeleteCollectionMetadata struct { + // CreateTime: Operation create time. + CreateTime string `json:"createTime,omitempty"` + // UpdateTime: Operation last update time. If the operation is done, this is + // also the finish time. + UpdateTime string `json:"updateTime,omitempty"` + // ForceSendFields is a list of field names (e.g. "CreateTime") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "CreateTime") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1alphaDeleteCollectionMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaDeleteCollectionMetadata + return gensupport.MarshalJSON(NoMethod(s), 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. @@ -8534,6 +9011,59 @@ func (s GoogleCloudDiscoveryengineV1alphaDeleteTargetSiteMetadata) MarshalJSON() return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudDiscoveryengineV1alphaDestinationConfig: Defines target endpoints +// used to connect to third-party sources. +type GoogleCloudDiscoveryengineV1alphaDestinationConfig struct { + // Destinations: Optional. The destinations for the corresponding key. + Destinations []*GoogleCloudDiscoveryengineV1alphaDestinationConfigDestination `json:"destinations,omitempty"` + // Key: Optional. Unique destination identifier that is supported by the + // connector. + Key string `json:"key,omitempty"` + // Params: Optional. Additional parameters for this destination config. + Params googleapi.RawMessage `json:"params,omitempty"` + // ForceSendFields is a list of field names (e.g. "Destinations") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "Destinations") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1alphaDestinationConfig) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaDestinationConfig + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaDestinationConfigDestination: Defines a +// target endpoint +type GoogleCloudDiscoveryengineV1alphaDestinationConfigDestination struct { + // Host: Publicly routable host. + Host string `json:"host,omitempty"` + // Port: Optional. Target port number accepted by the destination. + Port int64 `json:"port,omitempty"` + // ForceSendFields is a list of field names (e.g. "Host") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "Host") to include in API requests + // with the JSON null value. By default, fields with empty values are omitted + // from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1alphaDestinationConfigDestination) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaDestinationConfigDestination + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudDiscoveryengineV1alphaDisableAdvancedSiteSearchMetadata: Metadata // related to the progress of the // SiteSearchEngineService.DisableAdvancedSiteSearch operation. This will be @@ -8590,7 +9120,8 @@ type GoogleCloudDiscoveryengineV1alphaDocument struct { // IndexStatus: Output only. The index status of the document. * If document is // indexed successfully, the index_time field is populated. * Otherwise, if // document is not indexed due to errors, the error_samples field is populated. - // * Otherwise, index_status is unset. + // * Otherwise, if document's index is in progress, the pending_message field + // is populated. IndexStatus *GoogleCloudDiscoveryengineV1alphaDocumentIndexStatus `json:"indexStatus,omitempty"` // IndexTime: Output only. The last time the document was indexed. If this // field is set, the document could be returned in search results. This field @@ -8742,6 +9273,9 @@ type GoogleCloudDiscoveryengineV1alphaDocumentIndexStatus struct { // IndexTime: The time when the document was indexed. If this field is // populated, it means the document has been indexed. IndexTime string `json:"indexTime,omitempty"` + // PendingMessage: Immutable. The message indicates the document index is in + // progress. If this field is populated, the document index is pending. + PendingMessage string `json:"pendingMessage,omitempty"` // ForceSendFields is a list of field names (e.g. "ErrorSamples") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See @@ -10168,712 +10702,859 @@ func (s GoogleCloudDiscoveryengineV1alphaGcsSource) MarshalJSON() ([]byte, error return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaGetSessionRequest: Request for GetSession -// method. -type GoogleCloudDiscoveryengineV1alphaGetSessionRequest struct { - // IncludeAnswerDetails: Optional. If set to true, the full session including - // all answer details will be returned. - IncludeAnswerDetails bool `json:"includeAnswerDetails,omitempty"` - // Name: Required. The resource name of the Session to get. Format: - // `projects/{project}/locations/{location}/collections/{collection}/dataStores/ - // {data_store_id}/sessions/{session_id}` - Name string `json:"name,omitempty"` - // ForceSendFields is a list of field names (e.g. "IncludeAnswerDetails") to +// GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentRequest: Top-level +// message sent by the client for the `GenerateGroundedContent` method. +type GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentRequest struct { + // Contents: Content of the current conversation with the model. For + // single-turn queries, this is a single instance. For multi-turn queries, this + // is a repeated field that contains conversation history + latest request. + Contents []*GoogleCloudDiscoveryengineV1alphaGroundedGenerationContent `json:"contents,omitempty"` + // GenerationSpec: Content generation specification. + GenerationSpec *GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentRequestGenerationSpec `json:"generationSpec,omitempty"` + // GroundingSpec: Grounding specification. + GroundingSpec *GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentRequestGroundingSpec `json:"groundingSpec,omitempty"` + // SystemInstruction: Content of the system instruction for the current API. + // These instructions will take priority over any other prompt instructions if + // the selected model is supporting them. + SystemInstruction *GoogleCloudDiscoveryengineV1alphaGroundedGenerationContent `json:"systemInstruction,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. "Contents") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "IncludeAnswerDetails") to include - // in API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. See + // NullFields is a list of field names (e.g. "Contents") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaGetSessionRequest) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaGetSessionRequest +func (s GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentRequest) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentRequest return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaGetUriPatternDocumentDataResponse: Response -// message for SiteSearchEngineService.GetUriPatternDocumentData method. -type GoogleCloudDiscoveryengineV1alphaGetUriPatternDocumentDataResponse struct { - // DocumentDataMap: Document data keyed by URI pattern. For example: - // document_data_map = { "www.url1.com/*": { "Categories": ["category1", - // "category2"] }, "www.url2.com/*": { "Categories": ["category3"] } } - DocumentDataMap map[string]googleapi.RawMessage `json:"documentDataMap,omitempty"` - - // ServerResponse contains the HTTP response code and headers from the server. - googleapi.ServerResponse `json:"-"` - // ForceSendFields is a list of field names (e.g. "DocumentDataMap") to +// GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentRequestDynamicRetriev +// alConfiguration: Describes the options to customize dynamic retrieval. +type GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentRequestDynamicRetrievalConfiguration struct { + // Predictor: Specification for the predictor for dynamic retrieval. + Predictor *GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentRequestDynamicRetrievalConfigurationDynamicRetrievalPredictor `json:"predictor,omitempty"` + // ForceSendFields is a list of field names (e.g. "Predictor") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "DocumentDataMap") to include in - // API requests with the JSON null value. By default, fields with empty values - // are omitted from API requests. See + // NullFields is a list of field names (e.g. "Predictor") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaGetUriPatternDocumentDataResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaGetUriPatternDocumentDataResponse +func (s GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentRequestDynamicRetrievalConfiguration) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentRequestDynamicRetrievalConfiguration return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaGroundingFact: Grounding Fact. -type GoogleCloudDiscoveryengineV1alphaGroundingFact struct { - // Attributes: Attributes associated with the fact. Common attributes include - // `source` (indicating where the fact was sourced from), `author` (indicating - // the author of the fact), and so on. - Attributes map[string]string `json:"attributes,omitempty"` - // FactText: Text content of the fact. Can be at most 10K characters long. - FactText string `json:"factText,omitempty"` - // ForceSendFields is a list of field names (e.g. "Attributes") to +// GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentRequestDynamicRetriev +// alConfigurationDynamicRetrievalPredictor: Describes the predictor settings +// for dynamic retrieval. +type GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentRequestDynamicRetrievalConfigurationDynamicRetrievalPredictor struct { + // Threshold: The value of the threshold. If the predictor will predict a value + // smaller than this, it would suppress grounding in the source. + Threshold float64 `json:"threshold,omitempty"` + // Version: The version of the predictor to be used in dynamic retrieval. + // + // Possible values: + // "VERSION_UNSPECIFIED" - Automatically choose the best version of the + // retrieval predictor. + // "V1_INDEPENDENT" - The V1 model which is evaluating each source + // independently. + Version string `json:"version,omitempty"` + // ForceSendFields is a list of field names (e.g. "Threshold") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Attributes") to include in API + // NullFields is a list of field names (e.g. "Threshold") to include in API // requests with the JSON null value. By default, fields with empty values are // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaGroundingFact) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaGroundingFact +func (s GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentRequestDynamicRetrievalConfigurationDynamicRetrievalPredictor) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentRequestDynamicRetrievalConfigurationDynamicRetrievalPredictor return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaGuidedSearchSpec: Defines guided search -// spec. -type GoogleCloudDiscoveryengineV1alphaGuidedSearchSpec struct { - // EnableRefinementAttributes: Whether or not to enable and include refinement - // attributes in gudied search result. - EnableRefinementAttributes bool `json:"enableRefinementAttributes,omitempty"` - // EnableRelatedQuestions: Whether or not to enable and include related - // questions in search response. - EnableRelatedQuestions bool `json:"enableRelatedQuestions,omitempty"` - // MaxRelatedQuestions: Max number of related questions to be returned. The - // valid range is [1, 5]. If enable_related_questions is true, the default - // value is 3. - MaxRelatedQuestions int64 `json:"maxRelatedQuestions,omitempty"` - // ForceSendFields is a list of field names (e.g. "EnableRefinementAttributes") - // to unconditionally include in API requests. By default, fields with empty or +func (s *GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentRequestDynamicRetrievalConfigurationDynamicRetrievalPredictor) UnmarshalJSON(data []byte) error { + type NoMethod GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentRequestDynamicRetrievalConfigurationDynamicRetrievalPredictor + var s1 struct { + Threshold gensupport.JSONFloat64 `json:"threshold"` + *NoMethod + } + s1.NoMethod = (*NoMethod)(s) + if err := json.Unmarshal(data, &s1); err != nil { + return err + } + s.Threshold = float64(s1.Threshold) + return nil +} + +// GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentRequestGenerationSpec +// : Content generation specification. +type GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentRequestGenerationSpec struct { + // FrequencyPenalty: If specified, custom value for frequency penalty will be + // used. + FrequencyPenalty float64 `json:"frequencyPenalty,omitempty"` + // LanguageCode: Language code for content. Use language tags defined by BCP47 + // (https://www.rfc-editor.org/rfc/bcp/bcp47.txt). + LanguageCode string `json:"languageCode,omitempty"` + // MaxOutputTokens: If specified, custom value for max output tokens will be + // used. + MaxOutputTokens int64 `json:"maxOutputTokens,omitempty"` + // ModelId: Specifies which Vertex model id to use for generation. + ModelId string `json:"modelId,omitempty"` + // PresencePenalty: If specified, custom value for presence penalty will be + // used. + PresencePenalty float64 `json:"presencePenalty,omitempty"` + // Seed: If specified, custom value for the seed will be used. + Seed int64 `json:"seed,omitempty"` + // Temperature: If specified, custom value for the temperature will be used. + Temperature float64 `json:"temperature,omitempty"` + // TopK: If specified, custom value for top-k sampling will be used. + TopK int64 `json:"topK,omitempty"` + // TopP: If specified, custom value for nucleus sampling will be used. + TopP float64 `json:"topP,omitempty"` + // ForceSendFields is a list of field names (e.g. "FrequencyPenalty") to + // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "EnableRefinementAttributes") to - // include in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. See + // NullFields is a list of field names (e.g. "FrequencyPenalty") to include in + // API requests with the JSON null value. By default, fields with empty values + // are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaGuidedSearchSpec) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaGuidedSearchSpec +func (s GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentRequestGenerationSpec) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentRequestGenerationSpec return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaIdpConfig: Identity Provider Config. -type GoogleCloudDiscoveryengineV1alphaIdpConfig struct { - // ExternalIdpConfig: External Identity provider config. - ExternalIdpConfig *GoogleCloudDiscoveryengineV1alphaIdpConfigExternalIdpConfig `json:"externalIdpConfig,omitempty"` - // IdpType: Identity provider type configured. - // - // Possible values: - // "IDP_TYPE_UNSPECIFIED" - Default value. ACL search not enabled. - // "GSUITE" - Google 1P provider. - // "THIRD_PARTY" - Third party provider. - IdpType string `json:"idpType,omitempty"` - // ForceSendFields is a list of field names (e.g. "ExternalIdpConfig") to +func (s *GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentRequestGenerationSpec) UnmarshalJSON(data []byte) error { + type NoMethod GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentRequestGenerationSpec + var s1 struct { + FrequencyPenalty gensupport.JSONFloat64 `json:"frequencyPenalty"` + PresencePenalty gensupport.JSONFloat64 `json:"presencePenalty"` + Temperature gensupport.JSONFloat64 `json:"temperature"` + TopP gensupport.JSONFloat64 `json:"topP"` + *NoMethod + } + s1.NoMethod = (*NoMethod)(s) + if err := json.Unmarshal(data, &s1); err != nil { + return err + } + s.FrequencyPenalty = float64(s1.FrequencyPenalty) + s.PresencePenalty = float64(s1.PresencePenalty) + s.Temperature = float64(s1.Temperature) + s.TopP = float64(s1.TopP) + return nil +} + +// GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentRequestGroundingSourc +// e: Grounding source. +type GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentRequestGroundingSource struct { + // GoogleSearchSource: If set, grounding is performed with Google Search. + GoogleSearchSource *GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentRequestGroundingSourceGoogleSearchSource `json:"googleSearchSource,omitempty"` + // InlineSource: If set, grounding is performed with inline content. + InlineSource *GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentRequestGroundingSourceInlineSource `json:"inlineSource,omitempty"` + // SearchSource: If set, grounding is performed with Vertex AI Search. + SearchSource *GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentRequestGroundingSourceSearchSource `json:"searchSource,omitempty"` + // ForceSendFields is a list of field names (e.g. "GoogleSearchSource") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "ExternalIdpConfig") to include in - // API requests with the JSON null value. By default, fields with empty values - // are omitted from API requests. See + // NullFields is a list of field names (e.g. "GoogleSearchSource") to include + // in API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaIdpConfig) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaIdpConfig +func (s GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentRequestGroundingSource) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentRequestGroundingSource return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaIdpConfigExternalIdpConfig: Third party IDP -// Config. -type GoogleCloudDiscoveryengineV1alphaIdpConfigExternalIdpConfig struct { - // WorkforcePoolName: Workforce pool name. Example: - // "locations/global/workforcePools/pool_id" - WorkforcePoolName string `json:"workforcePoolName,omitempty"` - // ForceSendFields is a list of field names (e.g. "WorkforcePoolName") to +// GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentRequestGroundingSourc +// eGoogleSearchSource: Google Search config parameters. +type GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentRequestGroundingSourceGoogleSearchSource struct { + // DynamicRetrievalConfig: Optional. Specifies the dynamic retrieval + // configuration for the given source. + DynamicRetrievalConfig *GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentRequestDynamicRetrievalConfiguration `json:"dynamicRetrievalConfig,omitempty"` + // ForceSendFields is a list of field names (e.g. "DynamicRetrievalConfig") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "WorkforcePoolName") to include in - // API requests with the JSON null value. By default, fields with empty values - // are omitted from API requests. See + // NullFields is a list of field names (e.g. "DynamicRetrievalConfig") to + // include in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaIdpConfigExternalIdpConfig) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaIdpConfigExternalIdpConfig +func (s GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentRequestGroundingSourceGoogleSearchSource) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentRequestGroundingSourceGoogleSearchSource return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaImportCompletionSuggestionsMetadata: -// Metadata related to the progress of the ImportCompletionSuggestions -// operation. This will be returned by the -// google.longrunning.Operation.metadata field. -type GoogleCloudDiscoveryengineV1alphaImportCompletionSuggestionsMetadata struct { - // CreateTime: Operation create time. - CreateTime string `json:"createTime,omitempty"` - // FailureCount: Count of CompletionSuggestions that failed to be imported. - FailureCount int64 `json:"failureCount,omitempty,string"` - // SuccessCount: Count of CompletionSuggestions successfully imported. - 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 +// GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentRequestGroundingSourc +// eInlineSource: Message to be used for grounding based on inline content. +type GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentRequestGroundingSourceInlineSource struct { + // Attributes: Attributes associated with the content. Common attributes + // include `source` (indicating where the content was sourced from) and + // `author` (indicating the author of the content). + Attributes map[string]string `json:"attributes,omitempty"` + // GroundingFacts: List of facts to be used for grounding. + GroundingFacts []*GoogleCloudDiscoveryengineV1alphaGroundingFact `json:"groundingFacts,omitempty"` + // 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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "CreateTime") to include in API + // NullFields is a list of field names (e.g. "Attributes") to include in API // requests with the JSON null value. By default, fields with empty values are // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaImportCompletionSuggestionsMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaImportCompletionSuggestionsMetadata +func (s GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentRequestGroundingSourceInlineSource) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentRequestGroundingSourceInlineSource return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaImportCompletionSuggestionsRequest: Request -// message for CompletionService.ImportCompletionSuggestions method. -type GoogleCloudDiscoveryengineV1alphaImportCompletionSuggestionsRequest struct { - // 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"` - // InlineSource: The Inline source for suggestion entries. - InlineSource *GoogleCloudDiscoveryengineV1alphaImportCompletionSuggestionsRequestInlineSource `json:"inlineSource,omitempty"` - // ForceSendFields is a list of field names (e.g. "BigquerySource") to +// GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentRequestGroundingSourc +// eSearchSource: Message to be used for grounding with Vertex AI Search. +type GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentRequestGroundingSourceSearchSource struct { + // Filter: Filter expression to be applied to the search. The syntax is the + // same as SearchRequest.filter. + Filter string `json:"filter,omitempty"` + // MaxResultCount: Number of search results to return. The default value is 10. + // The maximumm allowed value is 10. + MaxResultCount int64 `json:"maxResultCount,omitempty"` + // SafeSearch: If set, safe search is enabled in Vertex AI Search requests. + SafeSearch bool `json:"safeSearch,omitempty"` + // ServingConfig: The resource name of the Engine to use. Format: + // `projects/{project}/locations/{location}/collections/{collection_id}/engines/ + // {engine_id}/servingConfigs/{serving_config_id}` + ServingConfig string `json:"servingConfig,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. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + 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. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentRequestGroundingSourceSearchSource) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentRequestGroundingSourceSearchSource + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentRequestGroundingSpec: +// +// Grounding specification. +type GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentRequestGroundingSpec struct { + // GroundingSources: Grounding sources. + GroundingSources []*GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentRequestGroundingSource `json:"groundingSources,omitempty"` + // ForceSendFields is a list of field names (e.g. "GroundingSources") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "BigquerySource") to include in + // NullFields is a list of field names (e.g. "GroundingSources") to include in // API requests with the JSON null value. By default, fields with empty values // are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaImportCompletionSuggestionsRequest) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaImportCompletionSuggestionsRequest +func (s GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentRequestGroundingSpec) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentRequestGroundingSpec return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaImportCompletionSuggestionsRequestInlineSour -// ce: The inline source for CompletionSuggestions. -type GoogleCloudDiscoveryengineV1alphaImportCompletionSuggestionsRequestInlineSource struct { - // Suggestions: Required. A list of all denylist entries to import. Max of 1000 - // items. - Suggestions []*GoogleCloudDiscoveryengineV1alphaCompletionSuggestion `json:"suggestions,omitempty"` - // ForceSendFields is a list of field names (e.g. "Suggestions") to +// GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentResponse: Response +// for the `GenerateGroundedContent` method. +type GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentResponse struct { + // Candidates: Generated candidates. + Candidates []*GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentResponseCandidate `json:"candidates,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the server. + googleapi.ServerResponse `json:"-"` + // ForceSendFields is a list of field names (e.g. "Candidates") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Suggestions") to include in API + // NullFields is a list of field names (e.g. "Candidates") to include in API // requests with the JSON null value. By default, fields with empty values are // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaImportCompletionSuggestionsRequestInlineSource) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaImportCompletionSuggestionsRequestInlineSource +func (s GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentResponse return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaImportCompletionSuggestionsResponse: -// Response of the CompletionService.ImportCompletionSuggestions method. If the -// long running operation is done, this message is returned by the -// google.longrunning.Operations.response field if the operation is successful. -type GoogleCloudDiscoveryengineV1alphaImportCompletionSuggestionsResponse struct { - // ErrorConfig: The desired location of errors incurred during the Import. - 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. See +// GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentResponseCandidate: A +// response candidate generated from the model. +type GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentResponseCandidate struct { + // Content: Content of the candidate. + Content *GoogleCloudDiscoveryengineV1alphaGroundedGenerationContent `json:"content,omitempty"` + // GroundingMetadata: Grounding metadata for the generated content. + GroundingMetadata *GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentResponseCandidateGroundingMetadata `json:"groundingMetadata,omitempty"` + // GroundingScore: The overall grounding score for the candidate, in the range + // of [0, 1]. + GroundingScore float64 `json:"groundingScore,omitempty"` + // Index: Index of the candidate. + Index int64 `json:"index,omitempty"` + // 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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "ErrorConfig") to include in API + // 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. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaImportCompletionSuggestionsResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaImportCompletionSuggestionsResponse +func (s GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentResponseCandidate) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentResponseCandidate return gensupport.MarshalJSON(NoMethod(s), 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"` - // TotalCount: Total count of entries that were processed. - TotalCount int64 `json:"totalCount,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 +func (s *GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentResponseCandidate) UnmarshalJSON(data []byte) error { + type NoMethod GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentResponseCandidate + var s1 struct { + GroundingScore gensupport.JSONFloat64 `json:"groundingScore"` + *NoMethod + } + s1.NoMethod = (*NoMethod)(s) + if err := json.Unmarshal(data, &s1); err != nil { + return err + } + s.GroundingScore = float64(s1.GroundingScore) + return nil +} + +// GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentResponseCandidateGrou +// ndingMetadata: Citation for the generated content. +type GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentResponseCandidateGroundingMetadata struct { + // GroundingSupport: GroundingSupport across all claims in the answer + // candidate. An support to a fact indicates that the claim is supported by the + // fact. + GroundingSupport []*GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentResponseCandidateGroundingMetadataGroundingSupport `json:"groundingSupport,omitempty"` + // RetrievalMetadata: Retrieval metadata to provide an understanding in the + // retrieval steps performed by the model. There can be multiple such messages + // which can correspond to different parts of the retrieval. This is a + // mechanism used to ensure transparency to our users. + RetrievalMetadata []*GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentResponseCandidateGroundingMetadataRetrievalMetadata `json:"retrievalMetadata,omitempty"` + // SearchEntryPoint: Google search entry for the following-up web searches. + SearchEntryPoint *GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentResponseCandidateGroundingMetadataSearchEntryPoint `json:"searchEntryPoint,omitempty"` + // SupportChunks: List of chunks to be attributed across all claims in the + // candidate. These are derived from the grounding sources supplied in the + // request. + SupportChunks []*GoogleCloudDiscoveryengineV1alphaFactChunk `json:"supportChunks,omitempty"` + // WebSearchQueries: Web search queries for the following-up web search. + WebSearchQueries []string `json:"webSearchQueries,omitempty"` + // ForceSendFields is a list of field names (e.g. "GroundingSupport") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "CreateTime") to include in API + // NullFields is a list of field names (e.g. "GroundingSupport") to include in + // API requests with the JSON null value. By default, fields with empty values + // are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentResponseCandidateGroundingMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentResponseCandidateGroundingMetadata + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentResponseCandidateGrou +// ndingMetadataDynamicRetrievalMetadata: Describes the metadata about dynamic +// retrieval. +type GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentResponseCandidateGroundingMetadataDynamicRetrievalMetadata struct { + // PredictorMetadata: Metadata for the dynamic retrieval predictor. + PredictorMetadata *GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentResponseCandidateGroundingMetadataDynamicRetrievalPredictorMetadata `json:"predictorMetadata,omitempty"` + // ForceSendFields is a list of field names (e.g. "PredictorMetadata") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "PredictorMetadata") to include in + // API requests with the JSON null value. By default, fields with empty values + // are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentResponseCandidateGroundingMetadataDynamicRetrievalMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentResponseCandidateGroundingMetadataDynamicRetrievalMetadata + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentResponseCandidateGrou +// ndingMetadataDynamicRetrievalPredictorMetadata: Describes the metadata about +// the dynamic retrieval predictor. +type GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentResponseCandidateGroundingMetadataDynamicRetrievalPredictorMetadata struct { + // Prediction: The value of the predictor. This should be between [0, 1] where + // a value of 0 means that the query would not benefit from grounding, while a + // value of 1.0 means that the query would benefit the most. In between values + // allow to differentiate between different usefulness scores for grounding. + Prediction float64 `json:"prediction,omitempty"` + // Version: The version of the predictor which was used in dynamic retrieval. + // + // Possible values: + // "VERSION_UNSPECIFIED" - Unspecified version, should never be used. + // "V1_INDEPENDENT" - The V1 model which is evaluating each source + // independently. + Version string `json:"version,omitempty"` + // ForceSendFields is a list of field names (e.g. "Prediction") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "Prediction") to include in API // requests with the JSON null value. By default, fields with empty values are // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaImportDocumentsMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaImportDocumentsMetadata +func (s GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentResponseCandidateGroundingMetadataDynamicRetrievalPredictorMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentResponseCandidateGroundingMetadataDynamicRetrievalPredictorMetadata return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaImportDocumentsRequest: Request message for -// Import methods. -type GoogleCloudDiscoveryengineV1alphaImportDocumentsRequest struct { - // AlloyDbSource: AlloyDB input source. - AlloyDbSource *GoogleCloudDiscoveryengineV1alphaAlloyDbSource `json:"alloyDbSource,omitempty"` - // 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. Supported data sources: * GcsSource. GcsSource.data_schema must be - // `custom` or `csv`. Otherwise, an INVALID_ARGUMENT error is thrown. * - // BigQuerySource. BigQuerySource.data_schema must be `custom` or `csv`. - // Otherwise, an INVALID_ARGUMENT error is thrown. * SpannerSource. * - // CloudSqlSource. * FirestoreSource. * BigtableSource. - AutoGenerateIds bool `json:"autoGenerateIds,omitempty"` - // BigquerySource: BigQuery input source. - BigquerySource *GoogleCloudDiscoveryengineV1alphaBigQuerySource `json:"bigquerySource,omitempty"` - // BigtableSource: Cloud Bigtable input source. - BigtableSource *GoogleCloudDiscoveryengineV1alphaBigtableSource `json:"bigtableSource,omitempty"` - // CloudSqlSource: Cloud SQL input source. - CloudSqlSource *GoogleCloudDiscoveryengineV1alphaCloudSqlSource `json:"cloudSqlSource,omitempty"` - // ErrorConfig: The desired location of errors incurred during the Import. - ErrorConfig *GoogleCloudDiscoveryengineV1alphaImportErrorConfig `json:"errorConfig,omitempty"` - // FhirStoreSource: FhirStore input source. - FhirStoreSource *GoogleCloudDiscoveryengineV1alphaFhirStoreSource `json:"fhirStoreSource,omitempty"` - // FirestoreSource: Firestore input source. - FirestoreSource *GoogleCloudDiscoveryengineV1alphaFirestoreSource `json:"firestoreSource,omitempty"` - // GcsSource: Cloud Storage location for the input content. - GcsSource *GoogleCloudDiscoveryengineV1alphaGcsSource `json:"gcsSource,omitempty"` - // IdField: The field indicates the ID field or column to be used as 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 others, it may be - // the column name of the table where the unique ids are stored. The values of - // the JSON field or the table column are used as the Document.ids. The JSON - // field or the table 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 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. - // Supported data sources: * GcsSource. GcsSource.data_schema must be `custom` - // or `csv`. Otherwise, an INVALID_ARGUMENT error is thrown. * BigQuerySource. - // BigQuerySource.data_schema must be `custom` or `csv`. Otherwise, an - // INVALID_ARGUMENT error is thrown. * SpannerSource. * CloudSqlSource. * - // FirestoreSource. * BigtableSource. - 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"` - // SpannerSource: Spanner input source. - SpannerSource *GoogleCloudDiscoveryengineV1alphaSpannerSource `json:"spannerSource,omitempty"` - // UpdateMask: Indicates which fields in the provided imported documents to - // update. If not set, the default is to update all fields. - UpdateMask string `json:"updateMask,omitempty"` - // ForceSendFields is a list of field names (e.g. "AlloyDbSource") to - // unconditionally include in API requests. By default, fields with empty or - // default values are omitted from API requests. See - // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more - // details. - ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "AlloyDbSource") to include in API - // requests with the JSON null value. By default, fields with empty values are - // omitted from API requests. See - // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. - NullFields []string `json:"-"` -} - -func (s GoogleCloudDiscoveryengineV1alphaImportDocumentsRequest) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaImportDocumentsRequest - return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +func (s *GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentResponseCandidateGroundingMetadataDynamicRetrievalPredictorMetadata) UnmarshalJSON(data []byte) error { + type NoMethod GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentResponseCandidateGroundingMetadataDynamicRetrievalPredictorMetadata + var s1 struct { + Prediction gensupport.JSONFloat64 `json:"prediction"` + *NoMethod + } + s1.NoMethod = (*NoMethod)(s) + if err := json.Unmarshal(data, &s1); err != nil { + return err + } + s.Prediction = float64(s1.Prediction) + return nil } -// 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 +// GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentResponseCandidateGrou +// ndingMetadataGroundingSupport: Grounding info for a claim in the candidate +// and its support. +type GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentResponseCandidateGroundingMetadataGroundingSupport struct { + // ClaimText: Text for the claim in the candidate. Always provided when a + // support is found. + ClaimText string `json:"claimText,omitempty"` + // SupportChunkIndices: A list of indices (into 'support_chunks') specifying + // the citations associated with the claim. For instance [1,3,4] means that + // support_chunks[1], support_chunks[3], support_chunks[4] are the chunks + // attributed to the claim. + SupportChunkIndices []int64 `json:"supportChunkIndices,omitempty"` + // SupportScore: A score in the range of [0, 1] describing how grounded is a + // specific claim in the support chunks indicated. Higher value means that the + // claim is better supported by the chunks. + SupportScore float64 `json:"supportScore,omitempty"` + // ForceSendFields is a list of field names (e.g. "ClaimText") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Documents") to include in API + // NullFields is a list of field names (e.g. "ClaimText") to include in API // requests with the JSON null value. By default, fields with empty values are // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaImportDocumentsRequestInlineSource) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaImportDocumentsRequestInlineSource +func (s GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentResponseCandidateGroundingMetadataGroundingSupport) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentResponseCandidateGroundingMetadataGroundingSupport return gensupport.MarshalJSON(NoMethod(s), 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 +func (s *GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentResponseCandidateGroundingMetadataGroundingSupport) UnmarshalJSON(data []byte) error { + type NoMethod GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentResponseCandidateGroundingMetadataGroundingSupport + var s1 struct { + SupportScore gensupport.JSONFloat64 `json:"supportScore"` + *NoMethod + } + s1.NoMethod = (*NoMethod)(s) + if err := json.Unmarshal(data, &s1); err != nil { + return err + } + s.SupportScore = float64(s1.SupportScore) + return nil +} + +// GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentResponseCandidateGrou +// ndingMetadataRetrievalMetadata: Describes the metadata associated with a +// retrieval step. +type GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentResponseCandidateGroundingMetadataRetrievalMetadata struct { + // DynamicRetrievalMetadata: Metadata for dynamic retrieval. + DynamicRetrievalMetadata *GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentResponseCandidateGroundingMetadataDynamicRetrievalMetadata `json:"dynamicRetrievalMetadata,omitempty"` + // Source: Describes the source to which the metadata is referring to. + // + // Possible values: + // "SOURCE_UNSPECIFIED" - Unspecified source. + // "VERTEX_AI_SEARCH" - Vertex AI search. + // "GOOGLE_SEARCH" - Google Search. + // "INLINE_CONTENT" - User inline provided content. + // "GOOGLE_MAPS" - Google Maps. + Source string `json:"source,omitempty"` + // ForceSendFields is a list of field names (e.g. "DynamicRetrievalMetadata") + // to unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. 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. See + // NullFields is a list of field names (e.g. "DynamicRetrievalMetadata") to + // include in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaImportDocumentsResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaImportDocumentsResponse +func (s GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentResponseCandidateGroundingMetadataRetrievalMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentResponseCandidateGroundingMetadataRetrievalMetadata return gensupport.MarshalJSON(NoMethod(s), 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 +// GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentResponseCandidateGrou +// ndingMetadataSearchEntryPoint: Google search entry point. +type GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentResponseCandidateGroundingMetadataSearchEntryPoint struct { + // RenderedContent: Web content snippet that can be embedded in a web page or + // an app webview. + RenderedContent string `json:"renderedContent,omitempty"` + // SdkBlob: Base64 encoded JSON representing array of tuple. + SdkBlob string `json:"sdkBlob,omitempty"` + // ForceSendFields is a list of field names (e.g. "RenderedContent") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. 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. See + // NullFields is a list of field names (e.g. "RenderedContent") to include in + // API requests with the JSON null value. By default, fields with empty values + // are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaImportErrorConfig) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaImportErrorConfig +func (s GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentResponseCandidateGroundingMetadataSearchEntryPoint) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentResponseCandidateGroundingMetadataSearchEntryPoint return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaImportSampleQueriesMetadata: Metadata -// related to the progress of the ImportSampleQueries operation. This will be -// returned by the google.longrunning.Operation.metadata field. -type GoogleCloudDiscoveryengineV1alphaImportSampleQueriesMetadata struct { - // CreateTime: ImportSampleQueries operation create time. - CreateTime string `json:"createTime,omitempty"` - // FailureCount: Count of SampleQuerys that failed to be imported. - FailureCount int64 `json:"failureCount,omitempty,string"` - // SuccessCount: Count of SampleQuerys successfully imported. - SuccessCount int64 `json:"successCount,omitempty,string"` - // TotalCount: Total count of SampleQuerys that were processed. - TotalCount int64 `json:"totalCount,omitempty,string"` - // UpdateTime: ImportSampleQueries 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 +// GoogleCloudDiscoveryengineV1alphaGetSessionRequest: Request for GetSession +// method. +type GoogleCloudDiscoveryengineV1alphaGetSessionRequest struct { + // IncludeAnswerDetails: Optional. If set to true, the full session including + // all answer details will be returned. + IncludeAnswerDetails bool `json:"includeAnswerDetails,omitempty"` + // Name: Required. The resource name of the Session to get. Format: + // `projects/{project}/locations/{location}/collections/{collection}/dataStores/ + // {data_store_id}/sessions/{session_id}` + Name string `json:"name,omitempty"` + // ForceSendFields is a list of field names (e.g. "IncludeAnswerDetails") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "CreateTime") to include in API - // requests with the JSON null value. By default, fields with empty values are - // omitted from API requests. See + // NullFields is a list of field names (e.g. "IncludeAnswerDetails") to include + // in API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaImportSampleQueriesMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaImportSampleQueriesMetadata +func (s GoogleCloudDiscoveryengineV1alphaGetSessionRequest) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaGetSessionRequest return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaImportSampleQueriesRequest: Request message -// for SampleQueryService.ImportSampleQueries method. -type GoogleCloudDiscoveryengineV1alphaImportSampleQueriesRequest struct { - // 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"` - // InlineSource: The Inline source for sample query entries. - InlineSource *GoogleCloudDiscoveryengineV1alphaImportSampleQueriesRequestInlineSource `json:"inlineSource,omitempty"` - // ForceSendFields is a list of field names (e.g. "BigquerySource") to +// GoogleCloudDiscoveryengineV1alphaGetUriPatternDocumentDataResponse: Response +// message for SiteSearchEngineService.GetUriPatternDocumentData method. +type GoogleCloudDiscoveryengineV1alphaGetUriPatternDocumentDataResponse struct { + // DocumentDataMap: Document data keyed by URI pattern. For example: + // document_data_map = { "www.url1.com/*": { "Categories": ["category1", + // "category2"] }, "www.url2.com/*": { "Categories": ["category3"] } } + DocumentDataMap map[string]googleapi.RawMessage `json:"documentDataMap,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the server. + googleapi.ServerResponse `json:"-"` + // ForceSendFields is a list of field names (e.g. "DocumentDataMap") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "BigquerySource") to include in + // NullFields is a list of field names (e.g. "DocumentDataMap") to include in // API requests with the JSON null value. By default, fields with empty values // are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaImportSampleQueriesRequest) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaImportSampleQueriesRequest +func (s GoogleCloudDiscoveryengineV1alphaGetUriPatternDocumentDataResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaGetUriPatternDocumentDataResponse return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaImportSampleQueriesRequestInlineSource: The -// inline source for SampleQuerys. -type GoogleCloudDiscoveryengineV1alphaImportSampleQueriesRequestInlineSource struct { - // SampleQueries: Required. A list of SampleQuerys to import. Max of 1000 - // items. - SampleQueries []*GoogleCloudDiscoveryengineV1alphaSampleQuery `json:"sampleQueries,omitempty"` - // ForceSendFields is a list of field names (e.g. "SampleQueries") to - // unconditionally include in API requests. By default, fields with empty or - // default values are omitted from API requests. See +// GoogleCloudDiscoveryengineV1alphaGroundedGenerationContent: Base structured +// datatype containing multi-part content of a message. +type GoogleCloudDiscoveryengineV1alphaGroundedGenerationContent struct { + // Parts: Ordered `Parts` that constitute a single message. + Parts []*GoogleCloudDiscoveryengineV1alphaGroundedGenerationContentPart `json:"parts,omitempty"` + // Role: Producer of the content. Must be either `user` or `model`. Intended to + // be used for multi-turn conversations. Otherwise, it can be left unset. + Role string `json:"role,omitempty"` + // ForceSendFields is a list of field names (e.g. "Parts") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "SampleQueries") to include in API + // NullFields is a list of field names (e.g. "Parts") to include in API // requests with the JSON null value. By default, fields with empty values are // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaImportSampleQueriesRequestInlineSource) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaImportSampleQueriesRequestInlineSource +func (s GoogleCloudDiscoveryengineV1alphaGroundedGenerationContent) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaGroundedGenerationContent return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaImportSampleQueriesResponse: Response of -// the SampleQueryService.ImportSampleQueries method. If the long running -// operation is done, this message is returned by the -// google.longrunning.Operations.response field if the operation is successful. -type GoogleCloudDiscoveryengineV1alphaImportSampleQueriesResponse struct { - // ErrorConfig: The desired location of errors incurred during the Import. - 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. See +// GoogleCloudDiscoveryengineV1alphaGroundedGenerationContentPart: Single part +// of content. +type GoogleCloudDiscoveryengineV1alphaGroundedGenerationContentPart struct { + // Text: Inline text. + Text string `json:"text,omitempty"` + // ForceSendFields is a list of field names (e.g. "Text") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. 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. See + // NullFields is a list of field names (e.g. "Text") to include in API requests + // with the JSON null value. By default, fields with empty values are omitted + // from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaImportSampleQueriesResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaImportSampleQueriesResponse +func (s GoogleCloudDiscoveryengineV1alphaGroundedGenerationContentPart) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaGroundedGenerationContentPart return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesMetadata: -// 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 +// GoogleCloudDiscoveryengineV1alphaGroundingFact: Grounding Fact. +type GoogleCloudDiscoveryengineV1alphaGroundingFact struct { + // Attributes: Attributes associated with the fact. Common attributes include + // `source` (indicating where the fact was sourced from), `author` (indicating + // the author of the fact), and so on. + Attributes map[string]string `json:"attributes,omitempty"` + // FactText: Text content of the fact. Can be at most 10K characters long. + FactText string `json:"factText,omitempty"` + // 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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "CreateTime") to include in API + // NullFields is a list of field names (e.g. "Attributes") to include in API // requests with the JSON null value. By default, fields with empty values are // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesMetadata +func (s GoogleCloudDiscoveryengineV1alphaGroundingFact) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaGroundingFact return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesRequest: -// 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 +// GoogleCloudDiscoveryengineV1alphaGuidedSearchSpec: Defines guided search +// spec. +type GoogleCloudDiscoveryengineV1alphaGuidedSearchSpec struct { + // EnableRefinementAttributes: Whether or not to enable and include refinement + // attributes in gudied search result. + EnableRefinementAttributes bool `json:"enableRefinementAttributes,omitempty"` + // EnableRelatedQuestions: Whether or not to enable and include related + // questions in search response. + EnableRelatedQuestions bool `json:"enableRelatedQuestions,omitempty"` + // MaxRelatedQuestions: Max number of related questions to be returned. The + // valid range is [1, 5]. If enable_related_questions is true, the default + // value is 3. + MaxRelatedQuestions int64 `json:"maxRelatedQuestions,omitempty"` + // ForceSendFields is a list of field names (e.g. "EnableRefinementAttributes") + // to unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "EnableRefinementAttributes") to + // include in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1alphaGuidedSearchSpec) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaGuidedSearchSpec + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaIdentityScheduleConfig: The configuration +// for the identity data synchronization runs. +type GoogleCloudDiscoveryengineV1alphaIdentityScheduleConfig struct { + // RefreshInterval: Optional. The refresh interval to sync the Access Control + // List information for the documents ingested by this connector. If not set, + // the access control list will be refreshed at the default interval of 30 + // minutes. The identity refresh interval can be at least 30 minutes and at + // most 7 days. + RefreshInterval string `json:"refreshInterval,omitempty"` + // ForceSendFields is a list of field names (e.g. "RefreshInterval") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. 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. See + // NullFields is a list of field names (e.g. "RefreshInterval") to include in + // API requests with the JSON null value. By default, fields with empty values + // are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesRequest) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesRequest +func (s GoogleCloudDiscoveryengineV1alphaIdentityScheduleConfig) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaIdentityScheduleConfig return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesRequestInline -// Source: 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. See +// GoogleCloudDiscoveryengineV1alphaIdpConfig: Identity Provider Config. +type GoogleCloudDiscoveryengineV1alphaIdpConfig struct { + // ExternalIdpConfig: External Identity provider config. + ExternalIdpConfig *GoogleCloudDiscoveryengineV1alphaIdpConfigExternalIdpConfig `json:"externalIdpConfig,omitempty"` + // IdpType: Identity provider type configured. + // + // Possible values: + // "IDP_TYPE_UNSPECIFIED" - Default value. ACL search not enabled. + // "GSUITE" - Google 1P provider. + // "THIRD_PARTY" - Third party provider. + IdpType string `json:"idpType,omitempty"` + // ForceSendFields is a list of field names (e.g. "ExternalIdpConfig") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Entries") to include in API - // requests with the JSON null value. By default, fields with empty values are - // omitted from API requests. See + // NullFields is a list of field names (e.g. "ExternalIdpConfig") to include in + // API requests with the JSON null value. By default, fields with empty values + // are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesRequestInlineSource) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesRequestInlineSource +func (s GoogleCloudDiscoveryengineV1alphaIdpConfig) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaIdpConfig return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesResponse: -// 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 +// GoogleCloudDiscoveryengineV1alphaIdpConfigExternalIdpConfig: Third party IDP +// Config. +type GoogleCloudDiscoveryengineV1alphaIdpConfigExternalIdpConfig struct { + // WorkforcePoolName: Workforce pool name. Example: + // "locations/global/workforcePools/pool_id" + WorkforcePoolName string `json:"workforcePoolName,omitempty"` + // ForceSendFields is a list of field names (e.g. "WorkforcePoolName") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "ErrorSamples") to include in API - // requests with the JSON null value. By default, fields with empty values are - // omitted from API requests. See + // NullFields is a list of field names (e.g. "WorkforcePoolName") to include in + // API requests with the JSON null value. By default, fields with empty values + // are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesResponse +func (s GoogleCloudDiscoveryengineV1alphaIdpConfigExternalIdpConfig) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaIdpConfigExternalIdpConfig return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaImportUserEventsMetadata: Metadata related -// to the progress of the Import operation. This is returned by the +// GoogleCloudDiscoveryengineV1alphaImportCompletionSuggestionsMetadata: +// Metadata related to the progress of the ImportCompletionSuggestions +// operation. This will be returned by the // google.longrunning.Operation.metadata field. -type GoogleCloudDiscoveryengineV1alphaImportUserEventsMetadata struct { +type GoogleCloudDiscoveryengineV1alphaImportCompletionSuggestionsMetadata struct { // CreateTime: Operation create time. CreateTime string `json:"createTime,omitempty"` - // FailureCount: Count of entries that encountered errors while processing. + // FailureCount: Count of CompletionSuggestions that failed to be imported. FailureCount int64 `json:"failureCount,omitempty,string"` - // SuccessCount: Count of entries that were processed successfully. + // SuccessCount: Count of CompletionSuggestions successfully imported. SuccessCount int64 `json:"successCount,omitempty,string"` // UpdateTime: Operation last update time. If the operation is done, this is // also the finish time. @@ -10891,23 +11572,22 @@ type GoogleCloudDiscoveryengineV1alphaImportUserEventsMetadata struct { NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaImportUserEventsMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaImportUserEventsMetadata +func (s GoogleCloudDiscoveryengineV1alphaImportCompletionSuggestionsMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaImportCompletionSuggestionsMetadata return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaImportUserEventsRequest: Request message -// for the ImportUserEvents request. -type GoogleCloudDiscoveryengineV1alphaImportUserEventsRequest struct { +// GoogleCloudDiscoveryengineV1alphaImportCompletionSuggestionsRequest: Request +// message for CompletionService.ImportCompletionSuggestions method. +type GoogleCloudDiscoveryengineV1alphaImportCompletionSuggestionsRequest 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"` + // InlineSource: The Inline source for suggestion entries. + InlineSource *GoogleCloudDiscoveryengineV1alphaImportCompletionSuggestionsRequestInlineSource `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. See @@ -10921,51 +11601,44 @@ type GoogleCloudDiscoveryengineV1alphaImportUserEventsRequest struct { NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaImportUserEventsRequest) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaImportUserEventsRequest +func (s GoogleCloudDiscoveryengineV1alphaImportCompletionSuggestionsRequest) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaImportCompletionSuggestionsRequest return gensupport.MarshalJSON(NoMethod(s), 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 +// GoogleCloudDiscoveryengineV1alphaImportCompletionSuggestionsRequestInlineSour +// ce: The inline source for CompletionSuggestions. +type GoogleCloudDiscoveryengineV1alphaImportCompletionSuggestionsRequestInlineSource struct { + // Suggestions: Required. A list of all denylist entries to import. Max of 1000 + // items. + Suggestions []*GoogleCloudDiscoveryengineV1alphaCompletionSuggestion `json:"suggestions,omitempty"` + // ForceSendFields is a list of field names (e.g. "Suggestions") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "UserEvents") to include in API + // NullFields is a list of field names (e.g. "Suggestions") to include in API // requests with the JSON null value. By default, fields with empty values are // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaImportUserEventsRequestInlineSource) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaImportUserEventsRequestInlineSource +func (s GoogleCloudDiscoveryengineV1alphaImportCompletionSuggestionsRequestInlineSource) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaImportCompletionSuggestionsRequestInlineSource return gensupport.MarshalJSON(NoMethod(s), 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. +// GoogleCloudDiscoveryengineV1alphaImportCompletionSuggestionsResponse: +// Response of the CompletionService.ImportCompletionSuggestions method. If the +// long running operation is done, this message is returned by the +// google.longrunning.Operations.response field if the operation is successful. +type GoogleCloudDiscoveryengineV1alphaImportCompletionSuggestionsResponse struct { + // ErrorConfig: The desired location of errors incurred during the Import. 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. See @@ -10979,1834 +11652,1848 @@ type GoogleCloudDiscoveryengineV1alphaImportUserEventsResponse struct { NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaImportUserEventsResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaImportUserEventsResponse +func (s GoogleCloudDiscoveryengineV1alphaImportCompletionSuggestionsResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaImportCompletionSuggestionsResponse return gensupport.MarshalJSON(NoMethod(s), 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 +// 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"` + // TotalCount: Total count of entries that were processed. + TotalCount int64 `json:"totalCount,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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. 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. See + // NullFields is a list of field names (e.g. "CreateTime") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaInterval) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaInterval +func (s GoogleCloudDiscoveryengineV1alphaImportDocumentsMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaImportDocumentsMetadata return gensupport.MarshalJSON(NoMethod(s), 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 -} - -// GoogleCloudDiscoveryengineV1alphaLanguageInfo: Language info for DataStore. -type GoogleCloudDiscoveryengineV1alphaLanguageInfo struct { - // Language: Output only. Language part of normalized_language_code. E.g.: - // `en-US` -> `en`, `zh-Hans-HK` -> `zh`, `en` -> `en`. - Language string `json:"language,omitempty"` - // LanguageCode: The language code for the DataStore. - LanguageCode string `json:"languageCode,omitempty"` - // NormalizedLanguageCode: Output only. This is the normalized form of - // language_code. E.g.: language_code of `en-GB`, `en_GB`, `en-UK` or `en-gb` - // will have normalized_language_code of `en-GB`. - NormalizedLanguageCode string `json:"normalizedLanguageCode,omitempty"` - // Region: Output only. Region part of normalized_language_code, if present. - // E.g.: `en-US` -> `US`, `zh-Hans-HK` -> `HK`, `en` -> ``. - Region string `json:"region,omitempty"` - // ForceSendFields is a list of field names (e.g. "Language") to +// GoogleCloudDiscoveryengineV1alphaImportDocumentsRequest: Request message for +// Import methods. +type GoogleCloudDiscoveryengineV1alphaImportDocumentsRequest struct { + // AlloyDbSource: AlloyDB input source. + AlloyDbSource *GoogleCloudDiscoveryengineV1alphaAlloyDbSource `json:"alloyDbSource,omitempty"` + // 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. Supported data sources: * GcsSource. GcsSource.data_schema must be + // `custom` or `csv`. Otherwise, an INVALID_ARGUMENT error is thrown. * + // BigQuerySource. BigQuerySource.data_schema must be `custom` or `csv`. + // Otherwise, an INVALID_ARGUMENT error is thrown. * SpannerSource. * + // CloudSqlSource. * FirestoreSource. * BigtableSource. + AutoGenerateIds bool `json:"autoGenerateIds,omitempty"` + // BigquerySource: BigQuery input source. + BigquerySource *GoogleCloudDiscoveryengineV1alphaBigQuerySource `json:"bigquerySource,omitempty"` + // BigtableSource: Cloud Bigtable input source. + BigtableSource *GoogleCloudDiscoveryengineV1alphaBigtableSource `json:"bigtableSource,omitempty"` + // CloudSqlSource: Cloud SQL input source. + CloudSqlSource *GoogleCloudDiscoveryengineV1alphaCloudSqlSource `json:"cloudSqlSource,omitempty"` + // ErrorConfig: The desired location of errors incurred during the Import. + ErrorConfig *GoogleCloudDiscoveryengineV1alphaImportErrorConfig `json:"errorConfig,omitempty"` + // FhirStoreSource: FhirStore input source. + FhirStoreSource *GoogleCloudDiscoveryengineV1alphaFhirStoreSource `json:"fhirStoreSource,omitempty"` + // FirestoreSource: Firestore input source. + FirestoreSource *GoogleCloudDiscoveryengineV1alphaFirestoreSource `json:"firestoreSource,omitempty"` + // GcsSource: Cloud Storage location for the input content. + GcsSource *GoogleCloudDiscoveryengineV1alphaGcsSource `json:"gcsSource,omitempty"` + // IdField: The field indicates the ID field or column to be used as 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 others, it may be + // the column name of the table where the unique ids are stored. The values of + // the JSON field or the table column are used as the Document.ids. The JSON + // field or the table 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 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. + // Supported data sources: * GcsSource. GcsSource.data_schema must be `custom` + // or `csv`. Otherwise, an INVALID_ARGUMENT error is thrown. * BigQuerySource. + // BigQuerySource.data_schema must be `custom` or `csv`. Otherwise, an + // INVALID_ARGUMENT error is thrown. * SpannerSource. * CloudSqlSource. * + // FirestoreSource. * BigtableSource. + 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"` + // SpannerSource: Spanner input source. + SpannerSource *GoogleCloudDiscoveryengineV1alphaSpannerSource `json:"spannerSource,omitempty"` + // UpdateMask: Indicates which fields in the provided imported documents to + // update. If not set, the default is to update all fields. + UpdateMask string `json:"updateMask,omitempty"` + // ForceSendFields is a list of field names (e.g. "AlloyDbSource") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Language") to include in API + // NullFields is a list of field names (e.g. "AlloyDbSource") to include in API // requests with the JSON null value. By default, fields with empty values are // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaLanguageInfo) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaLanguageInfo +func (s GoogleCloudDiscoveryengineV1alphaImportDocumentsRequest) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaImportDocumentsRequest return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaListChunksResponse: Response message for -// ChunkService.ListChunks method. -type GoogleCloudDiscoveryengineV1alphaListChunksResponse struct { - // Chunks: The Chunks. - Chunks []*GoogleCloudDiscoveryengineV1alphaChunk `json:"chunks,omitempty"` - // NextPageToken: A token that can be sent as ListChunksRequest.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. "Chunks") to unconditionally - // include in API requests. By default, fields with empty or default values are - // omitted from API requests. See +// 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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Chunks") to include in API + // 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. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaListChunksResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaListChunksResponse +func (s GoogleCloudDiscoveryengineV1alphaImportDocumentsRequestInlineSource) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaImportDocumentsRequestInlineSource return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaListCmekConfigsResponse: Response message -// for CmekConfigService.ListCmekConfigs method. -type GoogleCloudDiscoveryengineV1alphaListCmekConfigsResponse struct { - // CmekConfigs: All the customer's CmekConfigs. - CmekConfigs []*GoogleCloudDiscoveryengineV1alphaCmekConfig `json:"cmekConfigs,omitempty"` - - // ServerResponse contains the HTTP response code and headers from the server. - googleapi.ServerResponse `json:"-"` - // ForceSendFields is a list of field names (e.g. "CmekConfigs") to +// 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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "CmekConfigs") to include in API + // 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. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaListCmekConfigsResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaListCmekConfigsResponse +func (s GoogleCloudDiscoveryengineV1alphaImportDocumentsResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaImportDocumentsResponse return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaListControlsResponse: Response for -// ListControls method. -type GoogleCloudDiscoveryengineV1alphaListControlsResponse struct { - // Controls: All the Controls for a given data store. - Controls []*GoogleCloudDiscoveryengineV1alphaControl `json:"controls,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. "Controls") to +// 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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Controls") to include in API + // 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. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaListControlsResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaListControlsResponse +func (s GoogleCloudDiscoveryengineV1alphaImportErrorConfig) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaImportErrorConfig return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// 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 +// GoogleCloudDiscoveryengineV1alphaImportSampleQueriesMetadata: Metadata +// related to the progress of the ImportSampleQueries operation. This will be +// returned by the google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1alphaImportSampleQueriesMetadata struct { + // CreateTime: ImportSampleQueries operation create time. + CreateTime string `json:"createTime,omitempty"` + // FailureCount: Count of SampleQuerys that failed to be imported. + FailureCount int64 `json:"failureCount,omitempty,string"` + // SuccessCount: Count of SampleQuerys successfully imported. + SuccessCount int64 `json:"successCount,omitempty,string"` + // TotalCount: Total count of SampleQuerys that were processed. + TotalCount int64 `json:"totalCount,omitempty,string"` + // UpdateTime: ImportSampleQueries operation last update time. If the operation + // is done, this is also the finish time. + UpdateTime string `json:"updateTime,omitempty"` + // ForceSendFields is a list of field names (e.g. "CreateTime") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Conversations") to include in API + // NullFields is a list of field names (e.g. "CreateTime") to include in API // requests with the JSON null value. By default, fields with empty values are // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaListConversationsResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaListConversationsResponse +func (s GoogleCloudDiscoveryengineV1alphaImportSampleQueriesMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaImportSampleQueriesMetadata return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaListCustomModelsResponse: Response message -// for SearchTuningService.ListCustomModels method. -type GoogleCloudDiscoveryengineV1alphaListCustomModelsResponse struct { - // Models: List of custom tuning models. - Models []*GoogleCloudDiscoveryengineV1alphaCustomTuningModel `json:"models,omitempty"` - - // ServerResponse contains the HTTP response code and headers from the server. - googleapi.ServerResponse `json:"-"` - // ForceSendFields is a list of field names (e.g. "Models") to unconditionally - // include in API requests. By default, fields with empty or default values are - // omitted from API requests. See +// GoogleCloudDiscoveryengineV1alphaImportSampleQueriesRequest: Request message +// for SampleQueryService.ImportSampleQueries method. +type GoogleCloudDiscoveryengineV1alphaImportSampleQueriesRequest struct { + // 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"` + // InlineSource: The Inline source for sample query entries. + InlineSource *GoogleCloudDiscoveryengineV1alphaImportSampleQueriesRequestInlineSource `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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Models") to include in API - // requests with the JSON null value. By default, fields with empty values are - // omitted from API requests. See + // NullFields is a list of field names (e.g. "BigquerySource") to include in + // API requests with the JSON null value. By default, fields with empty values + // are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaListCustomModelsResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaListCustomModelsResponse +func (s GoogleCloudDiscoveryengineV1alphaImportSampleQueriesRequest) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaImportSampleQueriesRequest return gensupport.MarshalJSON(NoMethod(s), 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 +// GoogleCloudDiscoveryengineV1alphaImportSampleQueriesRequestInlineSource: The +// inline source for SampleQuerys. +type GoogleCloudDiscoveryengineV1alphaImportSampleQueriesRequestInlineSource struct { + // SampleQueries: Required. A list of SampleQuerys to import. Max of 1000 + // items. + SampleQueries []*GoogleCloudDiscoveryengineV1alphaSampleQuery `json:"sampleQueries,omitempty"` + // ForceSendFields is a list of field names (e.g. "SampleQueries") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "DataStores") to include in API + // NullFields is a list of field names (e.g. "SampleQueries") to include in API // requests with the JSON null value. By default, fields with empty values are // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaListDataStoresResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaListDataStoresResponse +func (s GoogleCloudDiscoveryengineV1alphaImportSampleQueriesRequestInlineSource) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaImportSampleQueriesRequestInlineSource return gensupport.MarshalJSON(NoMethod(s), 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 +// GoogleCloudDiscoveryengineV1alphaImportSampleQueriesResponse: Response of +// the SampleQueryService.ImportSampleQueries method. If the long running +// operation is done, this message is returned by the +// google.longrunning.Operations.response field if the operation is successful. +type GoogleCloudDiscoveryengineV1alphaImportSampleQueriesResponse struct { + // ErrorConfig: The desired location of errors incurred during the Import. + 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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Documents") to include in API + // 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. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaListDocumentsResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaListDocumentsResponse +func (s GoogleCloudDiscoveryengineV1alphaImportSampleQueriesResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaImportSampleQueriesResponse return gensupport.MarshalJSON(NoMethod(s), 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. See +// GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesMetadata: +// 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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Engines") to include in API + // NullFields is a list of field names (e.g. "CreateTime") to include in API // requests with the JSON null value. By default, fields with empty values are // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaListEnginesResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaListEnginesResponse +func (s GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesMetadata return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaListEvaluationResultsResponse: Response -// message for EvaluationService.ListEvaluationResults method. -type GoogleCloudDiscoveryengineV1alphaListEvaluationResultsResponse struct { - // EvaluationResults: The EvaluationResults. - EvaluationResults []*GoogleCloudDiscoveryengineV1alphaListEvaluationResultsResponseEvaluationResult `json:"evaluationResults,omitempty"` - // NextPageToken: A token that can be sent as - // ListEvaluationResultsRequest.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. "EvaluationResults") to +// GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesRequest: +// 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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "EvaluationResults") to include in - // API requests with the JSON null value. By default, fields with empty values - // are omitted from API requests. See + // NullFields is a list of field names (e.g. "GcsSource") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaListEvaluationResultsResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaListEvaluationResultsResponse +func (s GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesRequest) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesRequest return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaListEvaluationResultsResponseEvaluationResul -// t: Represents the results of an evaluation for a single SampleQuery. -type GoogleCloudDiscoveryengineV1alphaListEvaluationResultsResponseEvaluationResult struct { - // QualityMetrics: Output only. The metrics produced by the evaluation, for a - // given SampleQuery. - QualityMetrics *GoogleCloudDiscoveryengineV1alphaQualityMetrics `json:"qualityMetrics,omitempty"` - // SampleQuery: Output only. The SampleQuery that was evaluated. - SampleQuery *GoogleCloudDiscoveryengineV1alphaSampleQuery `json:"sampleQuery,omitempty"` - // ForceSendFields is a list of field names (e.g. "QualityMetrics") to - // unconditionally include in API requests. By default, fields with empty or - // default values are omitted from API requests. See +// GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesRequestInline +// Source: 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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "QualityMetrics") to include in - // API requests with the JSON null value. By default, fields with empty values - // are omitted from API requests. See + // NullFields is a list of field names (e.g. "Entries") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaListEvaluationResultsResponseEvaluationResult) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaListEvaluationResultsResponseEvaluationResult +func (s GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesRequestInlineSource) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesRequestInlineSource return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaListEvaluationsResponse: Response message -// for EvaluationService.ListEvaluations method. -type GoogleCloudDiscoveryengineV1alphaListEvaluationsResponse struct { - // Evaluations: The Evaluations. - Evaluations []*GoogleCloudDiscoveryengineV1alphaEvaluation `json:"evaluations,omitempty"` - // NextPageToken: A token that can be sent as ListEvaluationsRequest.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. "Evaluations") to +// GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesResponse: +// 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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Evaluations") to include in API + // NullFields is a list of field names (e.g. "ErrorSamples") to include in API // requests with the JSON null value. By default, fields with empty values are // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaListEvaluationsResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaListEvaluationsResponse +func (s GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaImportSuggestionDenyListEntriesResponse return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaListSampleQueriesResponse: Response message -// for SampleQueryService.ListSampleQueries method. -type GoogleCloudDiscoveryengineV1alphaListSampleQueriesResponse struct { - // NextPageToken: A token that can be sent as - // ListSampleQueriesRequest.page_token to retrieve the next page. If this field - // is omitted, there are no subsequent pages. - NextPageToken string `json:"nextPageToken,omitempty"` - // SampleQueries: The SampleQuerys. - SampleQueries []*GoogleCloudDiscoveryengineV1alphaSampleQuery `json:"sampleQueries,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 +// 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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "NextPageToken") to include in API + // NullFields is a list of field names (e.g. "CreateTime") to include in API // requests with the JSON null value. By default, fields with empty values are // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaListSampleQueriesResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaListSampleQueriesResponse +func (s GoogleCloudDiscoveryengineV1alphaImportUserEventsMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaImportUserEventsMetadata return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaListSampleQuerySetsResponse: Response -// message for SampleQuerySetService.ListSampleQuerySets method. -type GoogleCloudDiscoveryengineV1alphaListSampleQuerySetsResponse struct { - // NextPageToken: A token that can be sent as - // ListSampleQuerySetsRequest.page_token to retrieve the next page. If this - // field is omitted, there are no subsequent pages. - NextPageToken string `json:"nextPageToken,omitempty"` - // SampleQuerySets: The SampleQuerySets. - SampleQuerySets []*GoogleCloudDiscoveryengineV1alphaSampleQuerySet `json:"sampleQuerySets,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 +// 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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "NextPageToken") to include in API - // requests with the JSON null value. By default, fields with empty values are - // omitted from API requests. See + // 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. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaListSampleQuerySetsResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaListSampleQuerySetsResponse +func (s GoogleCloudDiscoveryengineV1alphaImportUserEventsRequest) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaImportUserEventsRequest return gensupport.MarshalJSON(NoMethod(s), 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 +// 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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "NextPageToken") to include in API + // NullFields is a list of field names (e.g. "UserEvents") to include in API // requests with the JSON null value. By default, fields with empty values are // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaListSchemasResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaListSchemasResponse +func (s GoogleCloudDiscoveryengineV1alphaImportUserEventsRequestInlineSource) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaImportUserEventsRequestInlineSource return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaListServingConfigsResponse: Response for -// ListServingConfigs method. -type GoogleCloudDiscoveryengineV1alphaListServingConfigsResponse struct { - // NextPageToken: Pagination token, if not returned indicates the last page. - NextPageToken string `json:"nextPageToken,omitempty"` - // ServingConfigs: All the ServingConfigs for a given dataStore. - ServingConfigs []*GoogleCloudDiscoveryengineV1alphaServingConfig `json:"servingConfigs,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"` + // 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. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + 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. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} - // ServerResponse contains the HTTP response code and headers from the server. - googleapi.ServerResponse `json:"-"` - // ForceSendFields is a list of field names (e.g. "NextPageToken") to +func (s GoogleCloudDiscoveryengineV1alphaImportUserEventsResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaImportUserEventsResponse + return gensupport.MarshalJSON(NoMethod(s), 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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "NextPageToken") to include in API + // NullFields is a list of field names (e.g. "ExclusiveMaximum") to include in + // API requests with the JSON null value. By default, fields with empty values + // are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1alphaInterval) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaInterval + return gensupport.MarshalJSON(NoMethod(s), 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 +} + +// GoogleCloudDiscoveryengineV1alphaLanguageInfo: Language info for DataStore. +type GoogleCloudDiscoveryengineV1alphaLanguageInfo struct { + // Language: Output only. Language part of normalized_language_code. E.g.: + // `en-US` -> `en`, `zh-Hans-HK` -> `zh`, `en` -> `en`. + Language string `json:"language,omitempty"` + // LanguageCode: The language code for the DataStore. + LanguageCode string `json:"languageCode,omitempty"` + // NormalizedLanguageCode: Output only. This is the normalized form of + // language_code. E.g.: language_code of `en-GB`, `en_GB`, `en-UK` or `en-gb` + // will have normalized_language_code of `en-GB`. + NormalizedLanguageCode string `json:"normalizedLanguageCode,omitempty"` + // Region: Output only. Region part of normalized_language_code, if present. + // E.g.: `en-US` -> `US`, `zh-Hans-HK` -> `HK`, `en` -> ``. + Region string `json:"region,omitempty"` + // ForceSendFields is a list of field names (e.g. "Language") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "Language") to include in API // requests with the JSON null value. By default, fields with empty values are // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaListServingConfigsResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaListServingConfigsResponse +func (s GoogleCloudDiscoveryengineV1alphaLanguageInfo) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaLanguageInfo return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaListSessionsRequest: Request for -// ListSessions method. -type GoogleCloudDiscoveryengineV1alphaListSessionsRequest struct { - // Filter: A filter to apply on the list results. The supported features are: - // user_pseudo_id, state. Example: "user_pseudo_id = some_id" - Filter string `json:"filter,omitempty"` - // OrderBy: A comma-separated list of fields to order by, sorted in ascending - // order. Use "desc" after a field name for descending. Supported fields: * - // `update_time` * `create_time` * `session_name` * `is_pinned` Example: * - // "update_time desc" * "create_time" * "is_pinned desc,update_time desc": list - // sessions by is_pinned first, then by update_time. - OrderBy string `json:"orderBy,omitempty"` - // PageSize: Maximum number of results to return. If unspecified, defaults to - // 50. Max allowed value is 1000. - PageSize int64 `json:"pageSize,omitempty"` - // PageToken: A page token, received from a previous `ListSessions` call. - // Provide this to retrieve the subsequent page. - PageToken string `json:"pageToken,omitempty"` - // Parent: Required. The data store resource name. Format: - // `projects/{project}/locations/{location}/collections/{collection}/dataStores/ - // {data_store_id}` - Parent string `json:"parent,omitempty"` - // ForceSendFields is a list of field names (e.g. "Filter") to unconditionally +// GoogleCloudDiscoveryengineV1alphaListChunksResponse: Response message for +// ChunkService.ListChunks method. +type GoogleCloudDiscoveryengineV1alphaListChunksResponse struct { + // Chunks: The Chunks. + Chunks []*GoogleCloudDiscoveryengineV1alphaChunk `json:"chunks,omitempty"` + // NextPageToken: A token that can be sent as ListChunksRequest.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. "Chunks") to unconditionally // include in API requests. By default, fields with empty or default values are // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. 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. "Chunks") to include in API // requests with the JSON null value. By default, fields with empty values are // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaListSessionsRequest) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaListSessionsRequest +func (s GoogleCloudDiscoveryengineV1alphaListChunksResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaListChunksResponse return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaListSessionsResponse: Response for -// ListSessions method. -type GoogleCloudDiscoveryengineV1alphaListSessionsResponse struct { - // NextPageToken: Pagination token, if not returned indicates the last page. +// GoogleCloudDiscoveryengineV1alphaListCmekConfigsResponse: Response message +// for CmekConfigService.ListCmekConfigs method. +type GoogleCloudDiscoveryengineV1alphaListCmekConfigsResponse struct { + // CmekConfigs: All the customer's CmekConfigs. + CmekConfigs []*GoogleCloudDiscoveryengineV1alphaCmekConfig `json:"cmekConfigs,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the server. + googleapi.ServerResponse `json:"-"` + // ForceSendFields is a list of field names (e.g. "CmekConfigs") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "CmekConfigs") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1alphaListCmekConfigsResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaListCmekConfigsResponse + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaListCollectionsResponse: Response message +// for CollectionService.ListCollections method. +type GoogleCloudDiscoveryengineV1alphaListCollectionsResponse struct { + // Collections: The Collections. + Collections []*GoogleCloudDiscoveryengineV1alphaCollection `json:"collections,omitempty"` + // NextPageToken: A token that can be sent as ListCollectionsRequest.page_token + // to retrieve the next page. If this field is omitted, there are no subsequent + // pages. NextPageToken string `json:"nextPageToken,omitempty"` - // Sessions: All the Sessions for a given data store. - Sessions []*GoogleCloudDiscoveryengineV1alphaSession `json:"sessions,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 + // ForceSendFields is a list of field names (e.g. "Collections") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "NextPageToken") to include in API + // NullFields is a list of field names (e.g. "Collections") to include in API // requests with the JSON null value. By default, fields with empty values are // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaListSessionsResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaListSessionsResponse +func (s GoogleCloudDiscoveryengineV1alphaListCollectionsResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaListCollectionsResponse return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaListTargetSitesResponse: Response message -// for SiteSearchEngineService.ListTargetSites method. -type GoogleCloudDiscoveryengineV1alphaListTargetSitesResponse struct { +// GoogleCloudDiscoveryengineV1alphaListConnectorRunsResponse: Response for +// DataConnectorService.ListConnectorRuns method. +type GoogleCloudDiscoveryengineV1alphaListConnectorRunsResponse struct { + // ConnectorRuns: List of ConnectorRuns. + ConnectorRuns []*GoogleCloudDiscoveryengineV1alphaConnectorRun `json:"connectorRuns,omitempty"` // 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 + // ForceSendFields is a list of field names (e.g. "ConnectorRuns") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "NextPageToken") to include in API + // NullFields is a list of field names (e.g. "ConnectorRuns") to include in API // requests with the JSON null value. By default, fields with empty values are // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaListTargetSitesResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaListTargetSitesResponse +func (s GoogleCloudDiscoveryengineV1alphaListConnectorRunsResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaListConnectorRunsResponse return gensupport.MarshalJSON(NoMethod(s), 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 +// GoogleCloudDiscoveryengineV1alphaListControlsResponse: Response for +// ListControls method. +type GoogleCloudDiscoveryengineV1alphaListControlsResponse struct { + // Controls: All the Controls for a given data store. + Controls []*GoogleCloudDiscoveryengineV1alphaControl `json:"controls,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. "Controls") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. 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. See + // NullFields is a list of field names (e.g. "Controls") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaMediaInfo) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaMediaInfo +func (s GoogleCloudDiscoveryengineV1alphaListControlsResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaListControlsResponse return gensupport.MarshalJSON(NoMethod(s), 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 -} +// 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"` -// GoogleCloudDiscoveryengineV1alphaNaturalLanguageQueryUnderstandingConfig: -// Configuration for Natural Language Query Understanding. -type GoogleCloudDiscoveryengineV1alphaNaturalLanguageQueryUnderstandingConfig struct { - // Mode: Mode of Natural Language Query Understanding. If this field is unset, - // the behavior defaults to - // NaturalLanguageQueryUnderstandingConfig.Mode.DISABLED. - // - // Possible values: - // "MODE_UNSPECIFIED" - Default value. - // "DISABLED" - Natural Language Query Understanding is disabled. - // "ENABLED" - Natural Language Query Understanding is enabled. - 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. See + // 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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. 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. See + // 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. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaNaturalLanguageQueryUnderstandingConfig) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaNaturalLanguageQueryUnderstandingConfig +func (s GoogleCloudDiscoveryengineV1alphaListConversationsResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaListConversationsResponse return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaObtainCrawlRateResponse: Response message -// for CrawlRateManagementService.ObtainCrawlRate method. The response contains -// organcic or dedicated crawl rate time series data for monitoring, depending -// on whether dedicated crawl rate is set. -type GoogleCloudDiscoveryengineV1alphaObtainCrawlRateResponse struct { - // DedicatedCrawlRateTimeSeries: The historical dedicated crawl rate timeseries - // data, used for monitoring. - DedicatedCrawlRateTimeSeries *GoogleCloudDiscoveryengineV1alphaDedicatedCrawlRateTimeSeries `json:"dedicatedCrawlRateTimeSeries,omitempty"` - // Error: Errors from service when handling the request. - Error *GoogleRpcStatus `json:"error,omitempty"` - // OrganicCrawlRateTimeSeries: The historical organic crawl rate timeseries - // data, used for monitoring. - OrganicCrawlRateTimeSeries *GoogleCloudDiscoveryengineV1alphaOrganicCrawlRateTimeSeries `json:"organicCrawlRateTimeSeries,omitempty"` - // State: Output only. The state of the response. - // - // Possible values: - // "STATE_UNSPECIFIED" - The state is unspecified. - // "SUCCEEDED" - The state is successful. - // "FAILED" - The state is failed. - State string `json:"state,omitempty"` - // ForceSendFields is a list of field names (e.g. - // "DedicatedCrawlRateTimeSeries") to unconditionally include in API requests. - // By default, fields with empty or default values are omitted from API - // requests. See https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields - // for more details. - ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "DedicatedCrawlRateTimeSeries") to - // include in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. See - // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. - NullFields []string `json:"-"` -} - -func (s GoogleCloudDiscoveryengineV1alphaObtainCrawlRateResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaObtainCrawlRateResponse - return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) -} +// GoogleCloudDiscoveryengineV1alphaListCustomModelsResponse: Response message +// for SearchTuningService.ListCustomModels method. +type GoogleCloudDiscoveryengineV1alphaListCustomModelsResponse struct { + // Models: List of custom tuning models. + Models []*GoogleCloudDiscoveryengineV1alphaCustomTuningModel `json:"models,omitempty"` -// GoogleCloudDiscoveryengineV1alphaOrganicCrawlRateTimeSeries: The historical -// organic crawl rate timeseries data, used for monitoring. Organic crawl is -// auto-determined by Google to crawl the user's website when dedicate crawl is -// not set. Crawl rate is the QPS of crawl request Google sends to the user's -// website. -type GoogleCloudDiscoveryengineV1alphaOrganicCrawlRateTimeSeries struct { - // GoogleOrganicCrawlRate: Google's organic crawl rate time series, which is - // the sum of all googlebots' crawl rate. Please refer to - // https://developers.google.com/search/docs/crawling-indexing/overview-google-crawlers - // for more details about googlebots. - GoogleOrganicCrawlRate *GoogleCloudDiscoveryengineV1alphaCrawlRateTimeSeries `json:"googleOrganicCrawlRate,omitempty"` - // VertexAiOrganicCrawlRate: Vertex AI's organic crawl rate time series, which - // is the crawl rate of Google-CloudVertexBot when dedicate crawl is not set. - // Please refer to - // https://developers.google.com/search/docs/crawling-indexing/google-common-crawlers#google-cloudvertexbot - // for more details about Google-CloudVertexBot. - VertexAiOrganicCrawlRate *GoogleCloudDiscoveryengineV1alphaCrawlRateTimeSeries `json:"vertexAiOrganicCrawlRate,omitempty"` - // ForceSendFields is a list of field names (e.g. "GoogleOrganicCrawlRate") to - // unconditionally include in API requests. By default, fields with empty or - // default values are omitted from API requests. See + // ServerResponse contains the HTTP response code and headers from the server. + googleapi.ServerResponse `json:"-"` + // ForceSendFields is a list of field names (e.g. "Models") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "GoogleOrganicCrawlRate") to - // include in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. See + // NullFields is a list of field names (e.g. "Models") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaOrganicCrawlRateTimeSeries) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaOrganicCrawlRateTimeSeries +func (s GoogleCloudDiscoveryengineV1alphaListCustomModelsResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaListCustomModelsResponse return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaPageInfo: Detailed page information. -type GoogleCloudDiscoveryengineV1alphaPageInfo struct { - // PageCategory: The most specific category associated with a category page. To - // represent full path of category, use '>' sign to separate different - // hierarchies. If '>' is part of the category name, 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 +// 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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "PageCategory") to include in API + // 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. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaPageInfo) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaPageInfo +func (s GoogleCloudDiscoveryengineV1alphaListDataStoresResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaListDataStoresResponse return gensupport.MarshalJSON(NoMethod(s), 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"` - // Documents: Optional. The document IDs associated with this panel. - Documents []*GoogleCloudDiscoveryengineV1alphaDocumentInfo `json:"documents,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 +// 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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "DisplayName") to include in API + // 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. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaPanelInfo) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaPanelInfo +func (s GoogleCloudDiscoveryengineV1alphaListDocumentsResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaListDocumentsResponse return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaPauseEngineRequest: Request for pausing -// training of an engine. -type GoogleCloudDiscoveryengineV1alphaPauseEngineRequest struct { -} +// 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"` -// GoogleCloudDiscoveryengineV1alphaPrincipal: Principal identifier of a user -// or a group. -type GoogleCloudDiscoveryengineV1alphaPrincipal struct { - // GroupId: Group identifier. For Google Workspace user account, group_id - // should be the google workspace group email. For non-google identity provider - // user account, group_id is the mapped group identifier configured during the - // workforcepool config. - GroupId string `json:"groupId,omitempty"` - // UserId: User identifier. For Google Workspace user account, user_id should - // be the google workspace user email. For non-google identity provider user - // account, user_id is the mapped user identifier configured during the - // workforcepool config. - UserId string `json:"userId,omitempty"` - // ForceSendFields is a list of field names (e.g. "GroupId") to unconditionally + // 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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "GroupId") to include in API + // 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. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaPrincipal) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaPrincipal +func (s GoogleCloudDiscoveryengineV1alphaListEnginesResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaListEnginesResponse return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaProcessedDocument: Document captures all -// raw metadata information of items to be recommended or searched. -type GoogleCloudDiscoveryengineV1alphaProcessedDocument struct { - // Document: Required. Full resource name of the referenced document, in the - // format - // `projects/*/locations/*/collections/*/dataStores/*/branches/*/documents/*`. - Document string `json:"document,omitempty"` - // JsonData: The JSON string representation of the processed document. - JsonData string `json:"jsonData,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 - // unconditionally include in API requests. By default, fields with empty or - // default values are omitted from API requests. See +// GoogleCloudDiscoveryengineV1alphaListEvaluationResultsResponse: Response +// message for EvaluationService.ListEvaluationResults method. +type GoogleCloudDiscoveryengineV1alphaListEvaluationResultsResponse struct { + // EvaluationResults: The EvaluationResults. + EvaluationResults []*GoogleCloudDiscoveryengineV1alphaListEvaluationResultsResponseEvaluationResult `json:"evaluationResults,omitempty"` + // NextPageToken: A token that can be sent as + // ListEvaluationResultsRequest.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. "EvaluationResults") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. 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. See + // NullFields is a list of field names (e.g. "EvaluationResults") to include in + // API requests with the JSON null value. By default, fields with empty values + // are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaProcessedDocument) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaProcessedDocument +func (s GoogleCloudDiscoveryengineV1alphaListEvaluationResultsResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaListEvaluationResultsResponse return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaProject: Metadata and configurations for a -// Google Cloud project in the service. -type GoogleCloudDiscoveryengineV1alphaProject struct { - // CreateTime: Output only. The timestamp when this project is created. - CreateTime string `json:"createTime,omitempty"` - // Name: Output only. Full resource name of the project, for example - // `projects/{project}`. Note that when making requests, project number and - // project id are both acceptable, but the server will always respond in - // project number. - Name string `json:"name,omitempty"` - // ProvisionCompletionTime: Output only. The timestamp when this project is - // successfully provisioned. Empty value means this project is still - // provisioning and is not ready for use. - ProvisionCompletionTime string `json:"provisionCompletionTime,omitempty"` - // ServiceTermsMap: Output only. A map of terms of services. The key is the - // `id` of ServiceTerms. - ServiceTermsMap map[string]GoogleCloudDiscoveryengineV1alphaProjectServiceTerms `json:"serviceTermsMap,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 +// GoogleCloudDiscoveryengineV1alphaListEvaluationResultsResponseEvaluationResul +// t: Represents the results of an evaluation for a single SampleQuery. +type GoogleCloudDiscoveryengineV1alphaListEvaluationResultsResponseEvaluationResult struct { + // QualityMetrics: Output only. The metrics produced by the evaluation, for a + // given SampleQuery. + QualityMetrics *GoogleCloudDiscoveryengineV1alphaQualityMetrics `json:"qualityMetrics,omitempty"` + // SampleQuery: Output only. The SampleQuery that was evaluated. + SampleQuery *GoogleCloudDiscoveryengineV1alphaSampleQuery `json:"sampleQuery,omitempty"` + // ForceSendFields is a list of field names (e.g. "QualityMetrics") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "CreateTime") to include in API - // requests with the JSON null value. By default, fields with empty values are - // omitted from API requests. See + // NullFields is a list of field names (e.g. "QualityMetrics") to include in + // API requests with the JSON null value. By default, fields with empty values + // are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaProject) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaProject +func (s GoogleCloudDiscoveryengineV1alphaListEvaluationResultsResponseEvaluationResult) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaListEvaluationResultsResponseEvaluationResult return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaProjectServiceTerms: Metadata about the -// terms of service. -type GoogleCloudDiscoveryengineV1alphaProjectServiceTerms struct { - // AcceptTime: The last time when the project agreed to the terms of service. - AcceptTime string `json:"acceptTime,omitempty"` - // DeclineTime: The last time when the project declined or revoked the - // agreement to terms of service. - DeclineTime string `json:"declineTime,omitempty"` - // Id: The unique identifier of this terms of service. Available terms: * - // `GA_DATA_USE_TERMS`: Terms for data use - // (https://cloud.google.com/retail/data-use-terms). When using this as `id`, - // the acceptable version to provide is `2022-11-23`. - Id string `json:"id,omitempty"` - // State: Whether the project has accepted/rejected the service terms or it is - // still pending. - // - // Possible values: - // "STATE_UNSPECIFIED" - The default value of the enum. This value is not - // actually used. - // "TERMS_ACCEPTED" - The project has given consent to the terms of service. - // "TERMS_PENDING" - The project is pending to review and accept the terms of - // service. - // "TERMS_DECLINED" - The project has declined or revoked the agreement to - // terms of service. - State string `json:"state,omitempty"` - // Version: The version string of the terms of service. For acceptable values, - // see the comments for id above. - Version string `json:"version,omitempty"` - // ForceSendFields is a list of field names (e.g. "AcceptTime") to +// GoogleCloudDiscoveryengineV1alphaListEvaluationsResponse: Response message +// for EvaluationService.ListEvaluations method. +type GoogleCloudDiscoveryengineV1alphaListEvaluationsResponse struct { + // Evaluations: The Evaluations. + Evaluations []*GoogleCloudDiscoveryengineV1alphaEvaluation `json:"evaluations,omitempty"` + // NextPageToken: A token that can be sent as ListEvaluationsRequest.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. "Evaluations") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "AcceptTime") to include in API + // NullFields is a list of field names (e.g. "Evaluations") to include in API // requests with the JSON null value. By default, fields with empty values are // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaProjectServiceTerms) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaProjectServiceTerms +func (s GoogleCloudDiscoveryengineV1alphaListEvaluationsResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaListEvaluationsResponse return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaProvisionProjectMetadata: Metadata -// associated with a project provision operation. -type GoogleCloudDiscoveryengineV1alphaProvisionProjectMetadata struct { -} +// GoogleCloudDiscoveryengineV1alphaListSampleQueriesResponse: Response message +// for SampleQueryService.ListSampleQueries method. +type GoogleCloudDiscoveryengineV1alphaListSampleQueriesResponse struct { + // NextPageToken: A token that can be sent as + // ListSampleQueriesRequest.page_token to retrieve the next page. If this field + // is omitted, there are no subsequent pages. + NextPageToken string `json:"nextPageToken,omitempty"` + // SampleQueries: The SampleQuerys. + SampleQueries []*GoogleCloudDiscoveryengineV1alphaSampleQuery `json:"sampleQueries,omitempty"` -// GoogleCloudDiscoveryengineV1alphaProvisionProjectRequest: Request for -// ProjectService.ProvisionProject method. -type GoogleCloudDiscoveryengineV1alphaProvisionProjectRequest struct { - // AcceptDataUseTerms: Required. Set to `true` to specify that caller has read - // and would like to give consent to the Terms for data use - // (https://cloud.google.com/retail/data-use-terms). - AcceptDataUseTerms bool `json:"acceptDataUseTerms,omitempty"` - // DataUseTermsVersion: Required. The version of the Terms for data use - // (https://cloud.google.com/retail/data-use-terms) that caller has read and - // would like to give consent to. Acceptable version is `2022-11-23`, and this - // may change over time. - DataUseTermsVersion string `json:"dataUseTermsVersion,omitempty"` - // ForceSendFields is a list of field names (e.g. "AcceptDataUseTerms") to + // ServerResponse contains the HTTP response code and headers from the server. + googleapi.ServerResponse `json:"-"` + // ForceSendFields is a list of field names (e.g. "NextPageToken") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "AcceptDataUseTerms") to include - // in API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. See + // NullFields is a list of field names (e.g. "NextPageToken") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaProvisionProjectRequest) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaProvisionProjectRequest +func (s GoogleCloudDiscoveryengineV1alphaListSampleQueriesResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaListSampleQueriesResponse return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaPurgeCompletionSuggestionsMetadata: -// Metadata related to the progress of the PurgeCompletionSuggestions -// operation. This is returned by the google.longrunning.Operation.metadata -// field. -type GoogleCloudDiscoveryengineV1alphaPurgeCompletionSuggestionsMetadata 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 +// GoogleCloudDiscoveryengineV1alphaListSampleQuerySetsResponse: Response +// message for SampleQuerySetService.ListSampleQuerySets method. +type GoogleCloudDiscoveryengineV1alphaListSampleQuerySetsResponse struct { + // NextPageToken: A token that can be sent as + // ListSampleQuerySetsRequest.page_token to retrieve the next page. If this + // field is omitted, there are no subsequent pages. + NextPageToken string `json:"nextPageToken,omitempty"` + // SampleQuerySets: The SampleQuerySets. + SampleQuerySets []*GoogleCloudDiscoveryengineV1alphaSampleQuerySet `json:"sampleQuerySets,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the server. + googleapi.ServerResponse `json:"-"` + // ForceSendFields is a list of field names (e.g. "NextPageToken") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "CreateTime") to include in API + // NullFields is a list of field names (e.g. "NextPageToken") to include in API // requests with the JSON null value. By default, fields with empty values are // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaPurgeCompletionSuggestionsMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaPurgeCompletionSuggestionsMetadata +func (s GoogleCloudDiscoveryengineV1alphaListSampleQuerySetsResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaListSampleQuerySetsResponse return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaPurgeCompletionSuggestionsRequest: Request -// message for CompletionService.PurgeCompletionSuggestions method. -type GoogleCloudDiscoveryengineV1alphaPurgeCompletionSuggestionsRequest struct { -} +// 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"` -// GoogleCloudDiscoveryengineV1alphaPurgeCompletionSuggestionsResponse: -// Response message for CompletionService.PurgeCompletionSuggestions method. -type GoogleCloudDiscoveryengineV1alphaPurgeCompletionSuggestionsResponse struct { - // ErrorSamples: A sample of errors encountered while processing the request. - ErrorSamples []*GoogleRpcStatus `json:"errorSamples,omitempty"` - // PurgeSucceeded: Whether the completion suggestions were successfully purged. - PurgeSucceeded bool `json:"purgeSucceeded,omitempty"` - // ForceSendFields is a list of field names (e.g. "ErrorSamples") to + // ServerResponse contains the HTTP response code and headers from the server. + googleapi.ServerResponse `json:"-"` + // ForceSendFields is a list of field names (e.g. "NextPageToken") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "ErrorSamples") to include in API + // NullFields is a list of field names (e.g. "NextPageToken") to include in API // requests with the JSON null value. By default, fields with empty values are // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaPurgeCompletionSuggestionsResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaPurgeCompletionSuggestionsResponse +func (s GoogleCloudDiscoveryengineV1alphaListSchemasResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaListSchemasResponse return gensupport.MarshalJSON(NoMethod(s), 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 { - // CreateTime: Operation create time. - CreateTime string `json:"createTime,omitempty"` - // FailureCount: Count of entries that encountered errors while processing. - FailureCount int64 `json:"failureCount,omitempty,string"` - // IgnoredCount: Count of entries that were ignored as entries were not found. - IgnoredCount int64 `json:"ignoredCount,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 +// GoogleCloudDiscoveryengineV1alphaListServingConfigsResponse: Response for +// ListServingConfigs method. +type GoogleCloudDiscoveryengineV1alphaListServingConfigsResponse struct { + // NextPageToken: Pagination token, if not returned indicates the last page. + NextPageToken string `json:"nextPageToken,omitempty"` + // ServingConfigs: All the ServingConfigs for a given dataStore. + ServingConfigs []*GoogleCloudDiscoveryengineV1alphaServingConfig `json:"servingConfigs,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the server. + googleapi.ServerResponse `json:"-"` + // ForceSendFields is a list of field names (e.g. "NextPageToken") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "CreateTime") to include in API + // NullFields is a list of field names (e.g. "NextPageToken") to include in API // requests with the JSON null value. By default, fields with empty values are // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaPurgeDocumentsMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaPurgeDocumentsMetadata +func (s GoogleCloudDiscoveryengineV1alphaListServingConfigsResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaListServingConfigsResponse return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaPurgeDocumentsRequest: Request message for -// DocumentService.PurgeDocuments method. -type GoogleCloudDiscoveryengineV1alphaPurgeDocumentsRequest struct { - // ErrorConfig: The desired location of errors incurred during the purge. - ErrorConfig *GoogleCloudDiscoveryengineV1alphaPurgeErrorConfig `json:"errorConfig,omitempty"` - // 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"` - // GcsSource: Cloud Storage location for the input content. Supported - // `data_schema`: * `document_id`: One valid Document.id per line. - GcsSource *GoogleCloudDiscoveryengineV1alphaGcsSource `json:"gcsSource,omitempty"` - // InlineSource: Inline source for the input content for purge. - InlineSource *GoogleCloudDiscoveryengineV1alphaPurgeDocumentsRequestInlineSource `json:"inlineSource,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. See +// GoogleCloudDiscoveryengineV1alphaListSessionsRequest: Request for +// ListSessions method. +type GoogleCloudDiscoveryengineV1alphaListSessionsRequest struct { + // Filter: A filter to apply on the list results. The supported features are: + // user_pseudo_id, state. Example: "user_pseudo_id = some_id" + Filter string `json:"filter,omitempty"` + // OrderBy: A comma-separated list of fields to order by, sorted in ascending + // order. Use "desc" after a field name for descending. Supported fields: * + // `update_time` * `create_time` * `session_name` * `is_pinned` Example: * + // "update_time desc" * "create_time" * "is_pinned desc,update_time desc": list + // sessions by is_pinned first, then by update_time. + OrderBy string `json:"orderBy,omitempty"` + // PageSize: Maximum number of results to return. If unspecified, defaults to + // 50. Max allowed value is 1000. + PageSize int64 `json:"pageSize,omitempty"` + // PageToken: A page token, received from a previous `ListSessions` call. + // Provide this to retrieve the subsequent page. + PageToken string `json:"pageToken,omitempty"` + // Parent: Required. The data store resource name. Format: + // `projects/{project}/locations/{location}/collections/{collection}/dataStores/ + // {data_store_id}` + Parent string `json:"parent,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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "ErrorConfig") 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. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaPurgeDocumentsRequest) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaPurgeDocumentsRequest +func (s GoogleCloudDiscoveryengineV1alphaListSessionsRequest) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaListSessionsRequest return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaPurgeDocumentsRequestInlineSource: The -// inline source for the input config for DocumentService.PurgeDocuments -// method. -type GoogleCloudDiscoveryengineV1alphaPurgeDocumentsRequestInlineSource struct { - // Documents: Required. A list of full resource name of documents to purge. In - // the format - // `projects/*/locations/*/collections/*/dataStores/*/branches/*/documents/*`. - // Recommended max of 100 items. - Documents []string `json:"documents,omitempty"` - // ForceSendFields is a list of field names (e.g. "Documents") to +// GoogleCloudDiscoveryengineV1alphaListSessionsResponse: Response for +// ListSessions method. +type GoogleCloudDiscoveryengineV1alphaListSessionsResponse struct { + // NextPageToken: Pagination token, if not returned indicates the last page. + NextPageToken string `json:"nextPageToken,omitempty"` + // Sessions: All the Sessions for a given data store. + Sessions []*GoogleCloudDiscoveryengineV1alphaSession `json:"sessions,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the server. + googleapi.ServerResponse `json:"-"` + // ForceSendFields is a list of field names (e.g. "NextPageToken") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Documents") to include in API + // NullFields is a list of field names (e.g. "NextPageToken") to include in API // requests with the JSON null value. By default, fields with empty values are // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaPurgeDocumentsRequestInlineSource) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaPurgeDocumentsRequestInlineSource +func (s GoogleCloudDiscoveryengineV1alphaListSessionsResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaListSessionsResponse return gensupport.MarshalJSON(NoMethod(s), 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 +// 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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "PurgeCount") to include in API + // NullFields is a list of field names (e.g. "NextPageToken") to include in API // requests with the JSON null value. By default, fields with empty values are // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaPurgeDocumentsResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaPurgeDocumentsResponse +func (s GoogleCloudDiscoveryengineV1alphaListTargetSitesResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaListTargetSitesResponse return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaPurgeErrorConfig: Configuration of -// destination for Purge related errors. -type GoogleCloudDiscoveryengineV1alphaPurgeErrorConfig struct { - // GcsPrefix: Cloud Storage prefix for purge errors. This must be an empty, - // existing Cloud Storage directory. Purge 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 +// 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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. 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. See + // 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. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaPurgeErrorConfig) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaPurgeErrorConfig +func (s GoogleCloudDiscoveryengineV1alphaMediaInfo) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaMediaInfo return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaPurgeSuggestionDenyListEntriesMetadata: -// 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. See +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 +} + +// GoogleCloudDiscoveryengineV1alphaNaturalLanguageQueryUnderstandingConfig: +// Configuration for Natural Language Query Understanding. +type GoogleCloudDiscoveryengineV1alphaNaturalLanguageQueryUnderstandingConfig struct { + // Mode: Mode of Natural Language Query Understanding. If this field is unset, + // the behavior defaults to + // NaturalLanguageQueryUnderstandingConfig.Mode.DISABLED. + // + // Possible values: + // "MODE_UNSPECIFIED" - Default value. + // "DISABLED" - Natural Language Query Understanding is disabled. + // "ENABLED" - Natural Language Query Understanding is enabled. + 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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "CreateTime") to include in API - // requests with the JSON null value. By default, fields with empty values are - // omitted from API requests. See + // NullFields is a list of field names (e.g. "Mode") to include in API requests + // with the JSON null value. By default, fields with empty values are omitted + // from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaPurgeSuggestionDenyListEntriesMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaPurgeSuggestionDenyListEntriesMetadata +func (s GoogleCloudDiscoveryengineV1alphaNaturalLanguageQueryUnderstandingConfig) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaNaturalLanguageQueryUnderstandingConfig return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaPurgeSuggestionDenyListEntriesRequest: -// Request message for CompletionService.PurgeSuggestionDenyListEntries method. -type GoogleCloudDiscoveryengineV1alphaPurgeSuggestionDenyListEntriesRequest struct { +// GoogleCloudDiscoveryengineV1alphaObtainCrawlRateResponse: Response message +// for CrawlRateManagementService.ObtainCrawlRate method. The response contains +// organcic or dedicated crawl rate time series data for monitoring, depending +// on whether dedicated crawl rate is set. +type GoogleCloudDiscoveryengineV1alphaObtainCrawlRateResponse struct { + // DedicatedCrawlRateTimeSeries: The historical dedicated crawl rate timeseries + // data, used for monitoring. + DedicatedCrawlRateTimeSeries *GoogleCloudDiscoveryengineV1alphaDedicatedCrawlRateTimeSeries `json:"dedicatedCrawlRateTimeSeries,omitempty"` + // Error: Errors from service when handling the request. + Error *GoogleRpcStatus `json:"error,omitempty"` + // OrganicCrawlRateTimeSeries: The historical organic crawl rate timeseries + // data, used for monitoring. + OrganicCrawlRateTimeSeries *GoogleCloudDiscoveryengineV1alphaOrganicCrawlRateTimeSeries `json:"organicCrawlRateTimeSeries,omitempty"` + // State: Output only. The state of the response. + // + // Possible values: + // "STATE_UNSPECIFIED" - The state is unspecified. + // "SUCCEEDED" - The state is successful. + // "FAILED" - The state is failed. + State string `json:"state,omitempty"` + // ForceSendFields is a list of field names (e.g. + // "DedicatedCrawlRateTimeSeries") to unconditionally include in API requests. + // By default, fields with empty or default values are omitted from API + // requests. See https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields + // for more details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "DedicatedCrawlRateTimeSeries") to + // include in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` } -// GoogleCloudDiscoveryengineV1alphaPurgeSuggestionDenyListEntriesResponse: -// 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 +func (s GoogleCloudDiscoveryengineV1alphaObtainCrawlRateResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaObtainCrawlRateResponse + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaOrganicCrawlRateTimeSeries: The historical +// organic crawl rate timeseries data, used for monitoring. Organic crawl is +// auto-determined by Google to crawl the user's website when dedicate crawl is +// not set. Crawl rate is the QPS of crawl request Google sends to the user's +// website. +type GoogleCloudDiscoveryengineV1alphaOrganicCrawlRateTimeSeries struct { + // GoogleOrganicCrawlRate: Google's organic crawl rate time series, which is + // the sum of all googlebots' crawl rate. Please refer to + // https://developers.google.com/search/docs/crawling-indexing/overview-google-crawlers + // for more details about googlebots. + GoogleOrganicCrawlRate *GoogleCloudDiscoveryengineV1alphaCrawlRateTimeSeries `json:"googleOrganicCrawlRate,omitempty"` + // VertexAiOrganicCrawlRate: Vertex AI's organic crawl rate time series, which + // is the crawl rate of Google-CloudVertexBot when dedicate crawl is not set. + // Please refer to + // https://developers.google.com/search/docs/crawling-indexing/google-common-crawlers#google-cloudvertexbot + // for more details about Google-CloudVertexBot. + VertexAiOrganicCrawlRate *GoogleCloudDiscoveryengineV1alphaCrawlRateTimeSeries `json:"vertexAiOrganicCrawlRate,omitempty"` + // ForceSendFields is a list of field names (e.g. "GoogleOrganicCrawlRate") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "ErrorSamples") to include in API - // requests with the JSON null value. By default, fields with empty values are - // omitted from API requests. See + // NullFields is a list of field names (e.g. "GoogleOrganicCrawlRate") to + // include in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaPurgeSuggestionDenyListEntriesResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaPurgeSuggestionDenyListEntriesResponse +func (s GoogleCloudDiscoveryengineV1alphaOrganicCrawlRateTimeSeries) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaOrganicCrawlRateTimeSeries return gensupport.MarshalJSON(NoMethod(s), 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 +// 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, 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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "CreateTime") to include in API + // NullFields is a list of field names (e.g. "PageCategory") to include in API // requests with the JSON null value. By default, fields with empty values are // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaPurgeUserEventsMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaPurgeUserEventsMetadata +func (s GoogleCloudDiscoveryengineV1alphaPageInfo) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaPageInfo return gensupport.MarshalJSON(NoMethod(s), 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. Note: This API only supports purging a max range of 30 days. 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 in a time range: `eventTime > - // "2012-04-23T18:25:43.511Z" eventTime < "2012-04-23T18:30:43.511Z" eventType - // = "search" * Deleting all events for a specific visitor in a time range: - // `eventTime > "2012-04-23T18:25:43.511Z" eventTime < - // "2012-04-23T18:30:43.511Z" userPseudoId = "visitor1024" * Deleting the past - // 30 days of 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. See +// GoogleCloudDiscoveryengineV1alphaPanelInfo: Detailed panel information +// associated with a user event. +type GoogleCloudDiscoveryengineV1alphaPanelInfo struct { + // DisplayName: The display name of the panel. + DisplayName string `json:"displayName,omitempty"` + // Documents: Optional. The document IDs associated with this panel. + Documents []*GoogleCloudDiscoveryengineV1alphaDocumentInfo `json:"documents,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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. 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. "DisplayName") to include in API // requests with the JSON null value. By default, fields with empty values are // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaPurgeUserEventsRequest) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaPurgeUserEventsRequest +func (s GoogleCloudDiscoveryengineV1alphaPanelInfo) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaPanelInfo return gensupport.MarshalJSON(NoMethod(s), 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. See +// GoogleCloudDiscoveryengineV1alphaPauseEngineRequest: Request for pausing +// training of an engine. +type GoogleCloudDiscoveryengineV1alphaPauseEngineRequest struct { +} + +// GoogleCloudDiscoveryengineV1alphaPrincipal: Principal identifier of a user +// or a group. +type GoogleCloudDiscoveryengineV1alphaPrincipal struct { + // GroupId: Group identifier. For Google Workspace user account, group_id + // should be the google workspace group email. For non-google identity provider + // user account, group_id is the mapped group identifier configured during the + // workforcepool config. + GroupId string `json:"groupId,omitempty"` + // UserId: User identifier. For Google Workspace user account, user_id should + // be the google workspace user email. For non-google identity provider user + // account, user_id is the mapped user identifier configured during the + // workforcepool config. + UserId string `json:"userId,omitempty"` + // ForceSendFields is a list of field names (e.g. "GroupId") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "PurgeCount") to include in API + // NullFields is a list of field names (e.g. "GroupId") to include in API // requests with the JSON null value. By default, fields with empty values are // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaPurgeUserEventsResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaPurgeUserEventsResponse +func (s GoogleCloudDiscoveryengineV1alphaPrincipal) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaPrincipal return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaQualityMetrics: Describes the metrics -// produced by the evaluation. -type GoogleCloudDiscoveryengineV1alphaQualityMetrics struct { - // DocNdcg: Normalized discounted cumulative gain (NDCG) per document, at - // various top-k cutoff levels. NDCG measures the ranking quality, giving - // higher relevance to top results. Example (top-3): Suppose SampleQuery with - // three retrieved documents (D1, D2, D3) and binary relevance judgements (1 - // for relevant, 0 for not relevant): Retrieved: [D3 (0), D1 (1), D2 (1)] - // Ideal: [D1 (1), D2 (1), D3 (0)] Calculate NDCG@3 for each SampleQuery: * - // DCG@3: 0/log2(1+1) + 1/log2(2+1) + 1/log2(3+1) = 1.13 * Ideal DCG@3: - // 1/log2(1+1) + 1/log2(2+1) + 0/log2(3+1) = 1.63 * NDCG@3: 1.13/1.63 = 0.693 - DocNdcg *GoogleCloudDiscoveryengineV1alphaQualityMetricsTopkMetrics `json:"docNdcg,omitempty"` - // DocPrecision: Precision per document, at various top-k cutoff levels. - // Precision is the fraction of retrieved documents that are relevant. Example - // (top-5): * For a single SampleQuery, If 4 out of 5 retrieved documents in - // the top-5 are relevant, precision@5 = 4/5 = 0.8 - DocPrecision *GoogleCloudDiscoveryengineV1alphaQualityMetricsTopkMetrics `json:"docPrecision,omitempty"` - // DocRecall: Recall per document, at various top-k cutoff levels. Recall is - // the fraction of relevant documents retrieved out of all relevant documents. - // Example (top-5): * For a single SampleQuery, If 3 out of 5 relevant - // documents are retrieved in the top-5, recall@5 = 3/5 = 0.6 - DocRecall *GoogleCloudDiscoveryengineV1alphaQualityMetricsTopkMetrics `json:"docRecall,omitempty"` - // PageNdcg: Normalized discounted cumulative gain (NDCG) per page, at various - // top-k cutoff levels. NDCG measures the ranking quality, giving higher - // relevance to top results. Example (top-3): Suppose SampleQuery with three - // retrieved pages (P1, P2, P3) and binary relevance judgements (1 for - // relevant, 0 for not relevant): Retrieved: [P3 (0), P1 (1), P2 (1)] Ideal: - // [P1 (1), P2 (1), P3 (0)] Calculate NDCG@3 for SampleQuery: * DCG@3: - // 0/log2(1+1) + 1/log2(2+1) + 1/log2(3+1) = 1.13 * Ideal DCG@3: 1/log2(1+1) + - // 1/log2(2+1) + 0/log2(3+1) = 1.63 * NDCG@3: 1.13/1.63 = 0.693 - PageNdcg *GoogleCloudDiscoveryengineV1alphaQualityMetricsTopkMetrics `json:"pageNdcg,omitempty"` - // PageRecall: Recall per page, at various top-k cutoff levels. Recall is the - // fraction of relevant pages retrieved out of all relevant pages. Example - // (top-5): * For a single SampleQuery, if 3 out of 5 relevant pages are - // retrieved in the top-5, recall@5 = 3/5 = 0.6 - PageRecall *GoogleCloudDiscoveryengineV1alphaQualityMetricsTopkMetrics `json:"pageRecall,omitempty"` - // ForceSendFields is a list of field names (e.g. "DocNdcg") to unconditionally - // include in API requests. By default, fields with empty or default values are - // omitted from API requests. See +// GoogleCloudDiscoveryengineV1alphaProcessedDocument: Document captures all +// raw metadata information of items to be recommended or searched. +type GoogleCloudDiscoveryengineV1alphaProcessedDocument struct { + // Document: Required. Full resource name of the referenced document, in the + // format + // `projects/*/locations/*/collections/*/dataStores/*/branches/*/documents/*`. + Document string `json:"document,omitempty"` + // JsonData: The JSON string representation of the processed document. + JsonData string `json:"jsonData,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 + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "DocNdcg") to include in API + // 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. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaQualityMetrics) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaQualityMetrics +func (s GoogleCloudDiscoveryengineV1alphaProcessedDocument) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaProcessedDocument return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaQualityMetricsTopkMetrics: Stores the -// metric values at specific top-k levels. -type GoogleCloudDiscoveryengineV1alphaQualityMetricsTopkMetrics struct { - // Top1: The top-1 value. - Top1 float64 `json:"top1,omitempty"` - // Top10: The top-10 value. - Top10 float64 `json:"top10,omitempty"` - // Top3: The top-3 value. - Top3 float64 `json:"top3,omitempty"` - // Top5: The top-5 value. - Top5 float64 `json:"top5,omitempty"` - // ForceSendFields is a list of field names (e.g. "Top1") to unconditionally - // include in API requests. By default, fields with empty or default values are - // omitted from API requests. See +// GoogleCloudDiscoveryengineV1alphaProject: Metadata and configurations for a +// Google Cloud project in the service. +type GoogleCloudDiscoveryengineV1alphaProject struct { + // CreateTime: Output only. The timestamp when this project is created. + CreateTime string `json:"createTime,omitempty"` + // Name: Output only. Full resource name of the project, for example + // `projects/{project}`. Note that when making requests, project number and + // project id are both acceptable, but the server will always respond in + // project number. + Name string `json:"name,omitempty"` + // ProvisionCompletionTime: Output only. The timestamp when this project is + // successfully provisioned. Empty value means this project is still + // provisioning and is not ready for use. + ProvisionCompletionTime string `json:"provisionCompletionTime,omitempty"` + // ServiceTermsMap: Output only. A map of terms of services. The key is the + // `id` of ServiceTerms. + ServiceTermsMap map[string]GoogleCloudDiscoveryengineV1alphaProjectServiceTerms `json:"serviceTermsMap,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the server. + googleapi.ServerResponse `json:"-"` + // ForceSendFields is a list of field names (e.g. "CreateTime") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Top1") to include in API requests - // with the JSON null value. By default, fields with empty values are omitted - // from API requests. See + // NullFields is a list of field names (e.g. "CreateTime") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaQualityMetricsTopkMetrics) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaQualityMetricsTopkMetrics +func (s GoogleCloudDiscoveryengineV1alphaProject) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaProject return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -func (s *GoogleCloudDiscoveryengineV1alphaQualityMetricsTopkMetrics) UnmarshalJSON(data []byte) error { - type NoMethod GoogleCloudDiscoveryengineV1alphaQualityMetricsTopkMetrics - var s1 struct { - Top1 gensupport.JSONFloat64 `json:"top1"` - Top10 gensupport.JSONFloat64 `json:"top10"` - Top3 gensupport.JSONFloat64 `json:"top3"` - Top5 gensupport.JSONFloat64 `json:"top5"` - *NoMethod - } - s1.NoMethod = (*NoMethod)(s) - if err := json.Unmarshal(data, &s1); err != nil { - return err - } - s.Top1 = float64(s1.Top1) - s.Top10 = float64(s1.Top10) - s.Top3 = float64(s1.Top3) - s.Top5 = float64(s1.Top5) - return nil -} - -// GoogleCloudDiscoveryengineV1alphaQuery: Defines a user inputed query. -type GoogleCloudDiscoveryengineV1alphaQuery struct { - // QueryId: Unique Id for the query. - QueryId string `json:"queryId,omitempty"` - // Text: Plain text. - Text string `json:"text,omitempty"` - // ForceSendFields is a list of field names (e.g. "QueryId") to unconditionally - // include in API requests. By default, fields with empty or default values are - // omitted from API requests. See +// GoogleCloudDiscoveryengineV1alphaProjectServiceTerms: Metadata about the +// terms of service. +type GoogleCloudDiscoveryengineV1alphaProjectServiceTerms struct { + // AcceptTime: The last time when the project agreed to the terms of service. + AcceptTime string `json:"acceptTime,omitempty"` + // DeclineTime: The last time when the project declined or revoked the + // agreement to terms of service. + DeclineTime string `json:"declineTime,omitempty"` + // Id: The unique identifier of this terms of service. Available terms: * + // `GA_DATA_USE_TERMS`: Terms for data use + // (https://cloud.google.com/retail/data-use-terms). When using this as `id`, + // the acceptable version to provide is `2022-11-23`. + Id string `json:"id,omitempty"` + // State: Whether the project has accepted/rejected the service terms or it is + // still pending. + // + // Possible values: + // "STATE_UNSPECIFIED" - The default value of the enum. This value is not + // actually used. + // "TERMS_ACCEPTED" - The project has given consent to the terms of service. + // "TERMS_PENDING" - The project is pending to review and accept the terms of + // service. + // "TERMS_DECLINED" - The project has declined or revoked the agreement to + // terms of service. + State string `json:"state,omitempty"` + // Version: The version string of the terms of service. For acceptable values, + // see the comments for id above. + Version string `json:"version,omitempty"` + // ForceSendFields is a list of field names (e.g. "AcceptTime") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "QueryId") to include in API + // NullFields is a list of field names (e.g. "AcceptTime") to include in API // requests with the JSON null value. By default, fields with empty values are // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaQuery) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaQuery +func (s GoogleCloudDiscoveryengineV1alphaProjectServiceTerms) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaProjectServiceTerms return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaRankRequest: Request message for -// RankService.Rank method. -type GoogleCloudDiscoveryengineV1alphaRankRequest struct { - // IgnoreRecordDetailsInResponse: If true, the response will contain only - // record ID and score. By default, it is false, the response will contain - // record details. - IgnoreRecordDetailsInResponse bool `json:"ignoreRecordDetailsInResponse,omitempty"` - // Model: The identifier of the model to use. It is one of: * - // `semantic-ranker-512@latest`: Semantic ranking model with maxiumn input - // token size 512. It is set to `semantic-ranker-512@latest` by default if - // unspecified. - Model string `json:"model,omitempty"` - // Query: The query to use. - Query string `json:"query,omitempty"` - // Records: Required. A list of records to rank. At most 200 records to rank. - Records []*GoogleCloudDiscoveryengineV1alphaRankingRecord `json:"records,omitempty"` - // TopN: The number of results to return. If this is unset or no bigger than - // zero, returns all results. - TopN int64 `json:"topN,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. - // "IgnoreRecordDetailsInResponse") to unconditionally include in API requests. - // By default, fields with empty or default values are omitted from API - // requests. See https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields - // for more details. +// GoogleCloudDiscoveryengineV1alphaProvisionProjectMetadata: Metadata +// associated with a project provision operation. +type GoogleCloudDiscoveryengineV1alphaProvisionProjectMetadata struct { +} + +// GoogleCloudDiscoveryengineV1alphaProvisionProjectRequest: Request for +// ProjectService.ProvisionProject method. +type GoogleCloudDiscoveryengineV1alphaProvisionProjectRequest struct { + // AcceptDataUseTerms: Required. Set to `true` to specify that caller has read + // and would like to give consent to the Terms for data use + // (https://cloud.google.com/retail/data-use-terms). + AcceptDataUseTerms bool `json:"acceptDataUseTerms,omitempty"` + // DataUseTermsVersion: Required. The version of the Terms for data use + // (https://cloud.google.com/retail/data-use-terms) that caller has read and + // would like to give consent to. Acceptable version is `2022-11-23`, and this + // may change over time. + DataUseTermsVersion string `json:"dataUseTermsVersion,omitempty"` + // ForceSendFields is a list of field names (e.g. "AcceptDataUseTerms") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "IgnoreRecordDetailsInResponse") - // to include in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. See + // NullFields is a list of field names (e.g. "AcceptDataUseTerms") to include + // in API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaRankRequest) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaRankRequest +func (s GoogleCloudDiscoveryengineV1alphaProvisionProjectRequest) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaProvisionProjectRequest return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaRankResponse: Response message for -// RankService.Rank method. -type GoogleCloudDiscoveryengineV1alphaRankResponse struct { - // Records: A list of records sorted by descending score. - Records []*GoogleCloudDiscoveryengineV1alphaRankingRecord `json:"records,omitempty"` - - // ServerResponse contains the HTTP response code and headers from the server. - googleapi.ServerResponse `json:"-"` - // ForceSendFields is a list of field names (e.g. "Records") to unconditionally - // include in API requests. By default, fields with empty or default values are - // omitted from API requests. See +// GoogleCloudDiscoveryengineV1alphaPurgeCompletionSuggestionsMetadata: +// Metadata related to the progress of the PurgeCompletionSuggestions +// operation. This is returned by the google.longrunning.Operation.metadata +// field. +type GoogleCloudDiscoveryengineV1alphaPurgeCompletionSuggestionsMetadata struct { + // CreateTime: Operation create time. + CreateTime string `json:"createTime,omitempty"` + // UpdateTime: Operation last update time. If the operation is done, this is + // also the finish time. + UpdateTime string `json:"updateTime,omitempty"` + // ForceSendFields is a list of field names (e.g. "CreateTime") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Records") to include in API + // NullFields is a list of field names (e.g. "CreateTime") to include in API // requests with the JSON null value. By default, fields with empty values are // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaRankResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaRankResponse +func (s GoogleCloudDiscoveryengineV1alphaPurgeCompletionSuggestionsMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaPurgeCompletionSuggestionsMetadata return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaRankingRecord: Record message for -// RankService.Rank method. -type GoogleCloudDiscoveryengineV1alphaRankingRecord struct { - // Content: The content of the record. Empty by default. At least one of title - // or content should be set otherwise an INVALID_ARGUMENT error is thrown. - Content string `json:"content,omitempty"` - // Id: The unique ID to represent the record. - Id string `json:"id,omitempty"` - // Score: The score of this record based on the given query and selected model. - // The score will be rounded to 2 decimal places. If the score is close to 0, - // it will be rounded to 0.0001 to avoid returning unset. - Score float64 `json:"score,omitempty"` - // Title: The title of the record. Empty by default. At least one of title or - // content should be set otherwise an INVALID_ARGUMENT error is thrown. - Title string `json:"title,omitempty"` - // 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. See +// GoogleCloudDiscoveryengineV1alphaPurgeCompletionSuggestionsRequest: Request +// message for CompletionService.PurgeCompletionSuggestions method. +type GoogleCloudDiscoveryengineV1alphaPurgeCompletionSuggestionsRequest struct { +} + +// GoogleCloudDiscoveryengineV1alphaPurgeCompletionSuggestionsResponse: +// Response message for CompletionService.PurgeCompletionSuggestions method. +type GoogleCloudDiscoveryengineV1alphaPurgeCompletionSuggestionsResponse struct { + // ErrorSamples: A sample of errors encountered while processing the request. + ErrorSamples []*GoogleRpcStatus `json:"errorSamples,omitempty"` + // PurgeSucceeded: Whether the completion suggestions were successfully purged. + PurgeSucceeded bool `json:"purgeSucceeded,omitempty"` + // ForceSendFields is a list of field names (e.g. "ErrorSamples") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Content") to include in API + // NullFields is a list of field names (e.g. "ErrorSamples") to include in API // requests with the JSON null value. By default, fields with empty values are // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaRankingRecord) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaRankingRecord +func (s GoogleCloudDiscoveryengineV1alphaPurgeCompletionSuggestionsResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaPurgeCompletionSuggestionsResponse return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -func (s *GoogleCloudDiscoveryengineV1alphaRankingRecord) UnmarshalJSON(data []byte) error { - type NoMethod GoogleCloudDiscoveryengineV1alphaRankingRecord - 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 +// 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"` + // IgnoredCount: Count of entries that were ignored as entries were not found. + IgnoredCount int64 `json:"ignoredCount,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. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "CreateTime") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` } -// 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: * (language: - // ANY("en", "es")) AND NOT (categories: ANY("Movie")) * (available: true) AND - // (language: ANY("en", "es")) OR (categories: ANY("Movie")) If your filter - // blocks all results, the API returns 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 never returns Documents with - // `storageStatus` as `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 chooses a - // reasonable default. The maximum allowed value is 100. Values above 100 are - // set 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 is returned in - // RecommendResponse.RecommendationResult.document. * `returnScore`: Boolean. - // If set to true, the recommendation score corresponding to each returned - // Document is 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 returns 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 is 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. See +func (s GoogleCloudDiscoveryengineV1alphaPurgeDocumentsMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaPurgeDocumentsMetadata + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaPurgeDocumentsRequest: Request message for +// DocumentService.PurgeDocuments method. +type GoogleCloudDiscoveryengineV1alphaPurgeDocumentsRequest struct { + // ErrorConfig: The desired location of errors incurred during the purge. + ErrorConfig *GoogleCloudDiscoveryengineV1alphaPurgeErrorConfig `json:"errorConfig,omitempty"` + // 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"` + // GcsSource: Cloud Storage location for the input content. Supported + // `data_schema`: * `document_id`: One valid Document.id per line. + GcsSource *GoogleCloudDiscoveryengineV1alphaGcsSource `json:"gcsSource,omitempty"` + // InlineSource: Inline source for the input content for purge. + InlineSource *GoogleCloudDiscoveryengineV1alphaPurgeDocumentsRequestInlineSource `json:"inlineSource,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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. 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. "ErrorConfig") to include in API // requests with the JSON null value. By default, fields with empty values are // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaRecommendRequest) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaRecommendRequest +func (s GoogleCloudDiscoveryengineV1alphaPurgeDocumentsRequest) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaPurgeDocumentsRequest return gensupport.MarshalJSON(NoMethod(s), 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"` +// GoogleCloudDiscoveryengineV1alphaPurgeDocumentsRequestInlineSource: The +// inline source for the input config for DocumentService.PurgeDocuments +// method. +type GoogleCloudDiscoveryengineV1alphaPurgeDocumentsRequestInlineSource struct { + // Documents: Required. A list of full resource name of documents to purge. In + // the format + // `projects/*/locations/*/collections/*/dataStores/*/branches/*/documents/*`. + // Recommended max of 100 items. + Documents []string `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. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + 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. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} - // ServerResponse contains the HTTP response code and headers from the server. - googleapi.ServerResponse `json:"-"` - // ForceSendFields is a list of field names (e.g. "AttributionToken") to +func (s GoogleCloudDiscoveryengineV1alphaPurgeDocumentsRequestInlineSource) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaPurgeDocumentsRequestInlineSource + return gensupport.MarshalJSON(NoMethod(s), 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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "AttributionToken") to include in - // API requests with the JSON null value. By default, fields with empty values - // are omitted from API requests. See + // 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. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaRecommendResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaRecommendResponse +func (s GoogleCloudDiscoveryengineV1alphaPurgeDocumentsResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaPurgeDocumentsResponse return gensupport.MarshalJSON(NoMethod(s), 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 or 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 +// GoogleCloudDiscoveryengineV1alphaPurgeErrorConfig: Configuration of +// destination for Purge related errors. +type GoogleCloudDiscoveryengineV1alphaPurgeErrorConfig struct { + // GcsPrefix: Cloud Storage prefix for purge errors. This must be an empty, + // existing Cloud Storage directory. Purge 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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Document") to include in API + // 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. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaRecommendResponseRecommendationResult) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaRecommendResponseRecommendationResult +func (s GoogleCloudDiscoveryengineV1alphaPurgeErrorConfig) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaPurgeErrorConfig return gensupport.MarshalJSON(NoMethod(s), 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 { +// GoogleCloudDiscoveryengineV1alphaPurgeSuggestionDenyListEntriesMetadata: +// 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"` - // InvalidUris: Unique URIs in the request that have invalid format. Sample - // limited to 1000. - InvalidUris []string `json:"invalidUris,omitempty"` - // InvalidUrisCount: Total number of unique URIs in the request that have - // invalid format. - InvalidUrisCount int64 `json:"invalidUrisCount,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"` - // UrisNotMatchingTargetSites: 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. Sample limited to 1000. - UrisNotMatchingTargetSites []string `json:"urisNotMatchingTargetSites,omitempty"` - // UrisNotMatchingTargetSitesCount: Total number of URIs that don't match any - // TargetSites. - UrisNotMatchingTargetSitesCount int64 `json:"urisNotMatchingTargetSitesCount,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. See @@ -12820,3018 +13507,4701 @@ type GoogleCloudDiscoveryengineV1alphaRecrawlUrisMetadata struct { NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaRecrawlUrisMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaRecrawlUrisMetadata +func (s GoogleCloudDiscoveryengineV1alphaPurgeSuggestionDenyListEntriesMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaPurgeSuggestionDenyListEntriesMetadata return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaRecrawlUrisRequest: Request message for -// SiteSearchEngineService.RecrawlUris method. -type GoogleCloudDiscoveryengineV1alphaRecrawlUrisRequest struct { - // SiteCredential: Optional. Full resource name of the SiteCredential, such as - // `projects/*/locations/*/collections/*/dataStores/*/siteSearchEngine/siteCrede - // ntials/*`. Only set to crawl private URIs. - SiteCredential string `json:"siteCredential,omitempty"` - // 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. "SiteCredential") to +// GoogleCloudDiscoveryengineV1alphaPurgeSuggestionDenyListEntriesRequest: +// Request message for CompletionService.PurgeSuggestionDenyListEntries method. +type GoogleCloudDiscoveryengineV1alphaPurgeSuggestionDenyListEntriesRequest struct { +} + +// GoogleCloudDiscoveryengineV1alphaPurgeSuggestionDenyListEntriesResponse: +// 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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "SiteCredential") to include in - // API requests with the JSON null value. By default, fields with empty values - // are omitted from API requests. See + // NullFields is a list of field names (e.g. "ErrorSamples") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaRecrawlUrisRequest) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaRecrawlUrisRequest +func (s GoogleCloudDiscoveryengineV1alphaPurgeSuggestionDenyListEntriesResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaPurgeSuggestionDenyListEntriesResponse return gensupport.MarshalJSON(NoMethod(s), 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 +// 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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "FailedUris") to include in API + // NullFields is a list of field names (e.g. "CreateTime") to include in API // requests with the JSON null value. By default, fields with empty values are // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponse +func (s GoogleCloudDiscoveryengineV1alphaPurgeUserEventsMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaPurgeUserEventsMetadata return gensupport.MarshalJSON(NoMethod(s), 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"` - // 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. See +// 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. Note: This API only supports purging a max range of 30 days. 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 in a time range: `eventTime > + // "2012-04-23T18:25:43.511Z" eventTime < "2012-04-23T18:30:43.511Z" eventType + // = "search" * Deleting all events for a specific visitor in a time range: + // `eventTime > "2012-04-23T18:25:43.511Z" eventTime < + // "2012-04-23T18:30:43.511Z" userPseudoId = "visitor1024" * Deleting the past + // 30 days of 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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // 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. See + // 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. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfo) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfo +func (s GoogleCloudDiscoveryengineV1alphaPurgeUserEventsRequest) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaPurgeUserEventsRequest return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfoFailureReason: -// -// 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 +// 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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "CorpusType") to include in API + // 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. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfoFailureReason) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfoFailureReason +func (s GoogleCloudDiscoveryengineV1alphaPurgeUserEventsResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaPurgeUserEventsResponse return gensupport.MarshalJSON(NoMethod(s), 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"` - // Summary: Summary based on search results. - Summary *GoogleCloudDiscoveryengineV1alphaSearchResponseSummary `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. See +// GoogleCloudDiscoveryengineV1alphaQualityMetrics: Describes the metrics +// produced by the evaluation. +type GoogleCloudDiscoveryengineV1alphaQualityMetrics struct { + // DocNdcg: Normalized discounted cumulative gain (NDCG) per document, at + // various top-k cutoff levels. NDCG measures the ranking quality, giving + // higher relevance to top results. Example (top-3): Suppose SampleQuery with + // three retrieved documents (D1, D2, D3) and binary relevance judgements (1 + // for relevant, 0 for not relevant): Retrieved: [D3 (0), D1 (1), D2 (1)] + // Ideal: [D1 (1), D2 (1), D3 (0)] Calculate NDCG@3 for each SampleQuery: * + // DCG@3: 0/log2(1+1) + 1/log2(2+1) + 1/log2(3+1) = 1.13 * Ideal DCG@3: + // 1/log2(1+1) + 1/log2(2+1) + 0/log2(3+1) = 1.63 * NDCG@3: 1.13/1.63 = 0.693 + DocNdcg *GoogleCloudDiscoveryengineV1alphaQualityMetricsTopkMetrics `json:"docNdcg,omitempty"` + // DocPrecision: Precision per document, at various top-k cutoff levels. + // Precision is the fraction of retrieved documents that are relevant. Example + // (top-5): * For a single SampleQuery, If 4 out of 5 retrieved documents in + // the top-5 are relevant, precision@5 = 4/5 = 0.8 + DocPrecision *GoogleCloudDiscoveryengineV1alphaQualityMetricsTopkMetrics `json:"docPrecision,omitempty"` + // DocRecall: Recall per document, at various top-k cutoff levels. Recall is + // the fraction of relevant documents retrieved out of all relevant documents. + // Example (top-5): * For a single SampleQuery, If 3 out of 5 relevant + // documents are retrieved in the top-5, recall@5 = 3/5 = 0.6 + DocRecall *GoogleCloudDiscoveryengineV1alphaQualityMetricsTopkMetrics `json:"docRecall,omitempty"` + // PageNdcg: Normalized discounted cumulative gain (NDCG) per page, at various + // top-k cutoff levels. NDCG measures the ranking quality, giving higher + // relevance to top results. Example (top-3): Suppose SampleQuery with three + // retrieved pages (P1, P2, P3) and binary relevance judgements (1 for + // relevant, 0 for not relevant): Retrieved: [P3 (0), P1 (1), P2 (1)] Ideal: + // [P1 (1), P2 (1), P3 (0)] Calculate NDCG@3 for SampleQuery: * DCG@3: + // 0/log2(1+1) + 1/log2(2+1) + 1/log2(3+1) = 1.13 * Ideal DCG@3: 1/log2(1+1) + + // 1/log2(2+1) + 0/log2(3+1) = 1.63 * NDCG@3: 1.13/1.63 = 0.693 + PageNdcg *GoogleCloudDiscoveryengineV1alphaQualityMetricsTopkMetrics `json:"pageNdcg,omitempty"` + // PageRecall: Recall per page, at various top-k cutoff levels. Recall is the + // fraction of relevant pages retrieved out of all relevant pages. Example + // (top-5): * For a single SampleQuery, if 3 out of 5 relevant pages are + // retrieved in the top-5, recall@5 = 3/5 = 0.6 + PageRecall *GoogleCloudDiscoveryengineV1alphaQualityMetricsTopkMetrics `json:"pageRecall,omitempty"` + // ForceSendFields is a list of field names (e.g. "DocNdcg") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "References") to include in API + // NullFields is a list of field names (e.g. "DocNdcg") to include in API // requests with the JSON null value. By default, fields with empty values are // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaReply) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaReply +func (s GoogleCloudDiscoveryengineV1alphaQualityMetrics) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaQualityMetrics return gensupport.MarshalJSON(NoMethod(s), 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"` - // 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. See +// GoogleCloudDiscoveryengineV1alphaQualityMetricsTopkMetrics: Stores the +// metric values at specific top-k levels. +type GoogleCloudDiscoveryengineV1alphaQualityMetricsTopkMetrics struct { + // Top1: The top-1 value. + Top1 float64 `json:"top1,omitempty"` + // Top10: The top-10 value. + Top10 float64 `json:"top10,omitempty"` + // Top3: The top-3 value. + Top3 float64 `json:"top3,omitempty"` + // Top5: The top-5 value. + Top5 float64 `json:"top5,omitempty"` + // ForceSendFields is a list of field names (e.g. "Top1") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. 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. See + // NullFields is a list of field names (e.g. "Top1") to include in API requests + // with the JSON null value. By default, fields with empty values are omitted + // from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaReplyReference) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaReplyReference +func (s GoogleCloudDiscoveryengineV1alphaQualityMetricsTopkMetrics) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaQualityMetricsTopkMetrics return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaReportConsentChangeRequest: Request for -// ReportConsentChange method. -type GoogleCloudDiscoveryengineV1alphaReportConsentChangeRequest struct { - // ConsentChangeAction: Required. Whether customer decides to accept or decline - // service term. At this moment, only accept action is supported. - // - // Possible values: - // "CONSENT_CHANGE_ACTION_UNSPECIFIED" - Invalid action, user must specify - // accept/decline - // "ACCEPT" - User accepts service terms. - ConsentChangeAction string `json:"consentChangeAction,omitempty"` - // ServiceTermId: Required. The unique identifier of the terms of service to - // update. Available term ids: * `GA_DATA_USE_TERMS`: Terms for data use - // (https://cloud.google.com/retail/data-use-terms). When using this service - // term id, the acceptable service_term_version to provide is `2022-11-23`. - ServiceTermId string `json:"serviceTermId,omitempty"` - // ServiceTermVersion: Required. The version string of the terms of service to - // update. - ServiceTermVersion string `json:"serviceTermVersion,omitempty"` - // ForceSendFields is a list of field names (e.g. "ConsentChangeAction") to - // unconditionally include in API requests. By default, fields with empty or - // default values are omitted from API requests. See +func (s *GoogleCloudDiscoveryengineV1alphaQualityMetricsTopkMetrics) UnmarshalJSON(data []byte) error { + type NoMethod GoogleCloudDiscoveryengineV1alphaQualityMetricsTopkMetrics + var s1 struct { + Top1 gensupport.JSONFloat64 `json:"top1"` + Top10 gensupport.JSONFloat64 `json:"top10"` + Top3 gensupport.JSONFloat64 `json:"top3"` + Top5 gensupport.JSONFloat64 `json:"top5"` + *NoMethod + } + s1.NoMethod = (*NoMethod)(s) + if err := json.Unmarshal(data, &s1); err != nil { + return err + } + s.Top1 = float64(s1.Top1) + s.Top10 = float64(s1.Top10) + s.Top3 = float64(s1.Top3) + s.Top5 = float64(s1.Top5) + return nil +} + +// GoogleCloudDiscoveryengineV1alphaQuery: Defines a user inputed query. +type GoogleCloudDiscoveryengineV1alphaQuery struct { + // QueryId: Unique Id for the query. + QueryId string `json:"queryId,omitempty"` + // Text: Plain text. + Text string `json:"text,omitempty"` + // ForceSendFields is a list of field names (e.g. "QueryId") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "ConsentChangeAction") to include - // in API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. See + // NullFields is a list of field names (e.g. "QueryId") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaReportConsentChangeRequest) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaReportConsentChangeRequest +func (s GoogleCloudDiscoveryengineV1alphaQuery) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaQuery return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaRequirement: A data requirement. -type GoogleCloudDiscoveryengineV1alphaRequirement struct { - // Condition: The condition for evaluating the requirement result. Variables in - // the expression should be provided by `metrics_bindings` or - // `threshold_bindings`. Where `metrics_bindings` are used for computed metrics - // and `threshold_bindings` are used to define thresholds for corresponding - // `metric_bindings`. - Condition *GoogleTypeExpr `json:"condition,omitempty"` - // Description: The description of the requirement. - Description string `json:"description,omitempty"` - // DisplayName: The name of the requirement. - DisplayName string `json:"displayName,omitempty"` - // MetricBindings: A list of the metric bindings to be used in `condition`. - MetricBindings []*GoogleCloudDiscoveryengineV1alphaRequirementMetricBinding `json:"metricBindings,omitempty"` - // Severity: The severity of errors if the requirement is not met. It must be - // ordered from the most strict to the least strict. Examples: * `BLOCKING` * - // `CRITICAL` * `WARNING` All thresholds in the requirement must have all the - // severity here. - Severity []string `json:"severity,omitempty"` - // ThresholdBindings: A list of threshold bindings to be used in `condition`. - ThresholdBindings []*GoogleCloudDiscoveryengineV1alphaRequirementThresholdBinding `json:"thresholdBindings,omitempty"` - // Type: The requirement type, used as an identifier. Must be unique. The type - // should prefix with service name to avoid possible collision. It's encouraged - // to use natural hierarchical grouping for similar requirements. Examples: * - // `library.googleapis.com/books/min_available_books` * - // `discoveryengine.googleapis.com/media_rec/recommended_for_you/conversion_rate - // ` - Type string `json:"type,omitempty"` - // ViolationSamplesBindings: A list of the metric bindings to be used in - // `condition`. - ViolationSamplesBindings []*GoogleCloudDiscoveryengineV1alphaRequirementViolationSamplesBinding `json:"violationSamplesBindings,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. See - // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more - // details. +// GoogleCloudDiscoveryengineV1alphaRankRequest: Request message for +// RankService.Rank method. +type GoogleCloudDiscoveryengineV1alphaRankRequest struct { + // IgnoreRecordDetailsInResponse: If true, the response will contain only + // record ID and score. By default, it is false, the response will contain + // record details. + IgnoreRecordDetailsInResponse bool `json:"ignoreRecordDetailsInResponse,omitempty"` + // Model: The identifier of the model to use. It is one of: * + // `semantic-ranker-512@latest`: Semantic ranking model with maxiumn input + // token size 512. It is set to `semantic-ranker-512@latest` by default if + // unspecified. + Model string `json:"model,omitempty"` + // Query: The query to use. + Query string `json:"query,omitempty"` + // Records: Required. A list of records to rank. At most 200 records to rank. + Records []*GoogleCloudDiscoveryengineV1alphaRankingRecord `json:"records,omitempty"` + // TopN: The number of results to return. If this is unset or no bigger than + // zero, returns all results. + TopN int64 `json:"topN,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. + // "IgnoreRecordDetailsInResponse") to unconditionally include in API requests. + // By default, fields with empty or default values are omitted from API + // requests. See https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields + // for more details. 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. See + // NullFields is a list of field names (e.g. "IgnoreRecordDetailsInResponse") + // to include in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaRequirement) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaRequirement +func (s GoogleCloudDiscoveryengineV1alphaRankRequest) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaRankRequest return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaRequirementMetricBinding: Specifies a -// metrics query and bind its result to a variable which will be used in the -// `condition`. -type GoogleCloudDiscoveryengineV1alphaRequirementMetricBinding struct { - // Category: The category of the metric's target resource. Example: "Events" - Category string `json:"category,omitempty"` - // Description: Human readable description of the corresponding metric filter. - Description string `json:"description,omitempty"` - // MetricFilter: The filter string used for metrics query. Example: - // "metric.type = \"discoveryengine.googleapis.com/events/day_count\" AND " - // "metric.conditions.time_range = \"NINETY_DAYS\"" - MetricFilter string `json:"metricFilter,omitempty"` - // ResourceType: The resource being monitored for the metric. - ResourceType string `json:"resourceType,omitempty"` - // VariableId: The variable id to be referenced in `condition`. - VariableId string `json:"variableId,omitempty"` - // ForceSendFields is a list of field names (e.g. "Category") to - // unconditionally include in API requests. By default, fields with empty or - // default values are omitted from API requests. See - // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more - // details. - ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Category") to include in API - // requests with the JSON null value. By default, fields with empty values are - // omitted from API requests. See - // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. - NullFields []string `json:"-"` -} - -func (s GoogleCloudDiscoveryengineV1alphaRequirementMetricBinding) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaRequirementMetricBinding - return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) -} +// GoogleCloudDiscoveryengineV1alphaRankResponse: Response message for +// RankService.Rank method. +type GoogleCloudDiscoveryengineV1alphaRankResponse struct { + // Records: A list of records sorted by descending score. + Records []*GoogleCloudDiscoveryengineV1alphaRankingRecord `json:"records,omitempty"` -// GoogleCloudDiscoveryengineV1alphaRequirementThresholdBinding: Specifies a -// multi-level threshold to apply to apply to a `metric_bindings` in the -// `condition` CEL expression. -type GoogleCloudDiscoveryengineV1alphaRequirementThresholdBinding struct { - // Description: Human readable description of the corresponding threshold and - // sub-requirement. - Description string `json:"description,omitempty"` - // ThresholdValues: The values of the threshold. The values should be ordered - // from the most strict to the least strict. - ThresholdValues []*GoogleCloudDiscoveryengineV1alphaRequirementThresholdBindingThresholdValue `json:"thresholdValues,omitempty"` - // VariableId: The variable id to be referenced in `condition`. Must be unique - // across all `metric_bindings` and `threshold_bindings`. - VariableId string `json:"variableId,omitempty"` - // ForceSendFields is a list of field names (e.g. "Description") to - // unconditionally include in API requests. By default, fields with empty or - // default values are omitted from API requests. See + // ServerResponse contains the HTTP response code and headers from the server. + googleapi.ServerResponse `json:"-"` + // ForceSendFields is a list of field names (e.g. "Records") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Description") to include in API + // NullFields is a list of field names (e.g. "Records") to include in API // requests with the JSON null value. By default, fields with empty values are // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaRequirementThresholdBinding) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaRequirementThresholdBinding +func (s GoogleCloudDiscoveryengineV1alphaRankResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaRankResponse return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaRequirementThresholdBindingThresholdValue: -// Specifies a threshold value for a given severity. -type GoogleCloudDiscoveryengineV1alphaRequirementThresholdBindingThresholdValue struct { - // Severity: The severity of errors if the threshold is not met. It should be - // one of the `severity` fields in the requirement. - Severity string `json:"severity,omitempty"` - // Value: The value of the threshold. - Value float64 `json:"value,omitempty"` - // ForceSendFields is a list of field names (e.g. "Severity") to - // unconditionally include in API requests. By default, fields with empty or - // default values are omitted from API requests. See +// GoogleCloudDiscoveryengineV1alphaRankingRecord: Record message for +// RankService.Rank method. +type GoogleCloudDiscoveryengineV1alphaRankingRecord struct { + // Content: The content of the record. Empty by default. At least one of title + // or content should be set otherwise an INVALID_ARGUMENT error is thrown. + Content string `json:"content,omitempty"` + // Id: The unique ID to represent the record. + Id string `json:"id,omitempty"` + // Score: The score of this record based on the given query and selected model. + // The score will be rounded to 2 decimal places. If the score is close to 0, + // it will be rounded to 0.0001 to avoid returning unset. + Score float64 `json:"score,omitempty"` + // Title: The title of the record. Empty by default. At least one of title or + // content should be set otherwise an INVALID_ARGUMENT error is thrown. + Title string `json:"title,omitempty"` + // 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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Severity") to include in API + // 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. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaRequirementThresholdBindingThresholdValue) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaRequirementThresholdBindingThresholdValue +func (s GoogleCloudDiscoveryengineV1alphaRankingRecord) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaRankingRecord return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -func (s *GoogleCloudDiscoveryengineV1alphaRequirementThresholdBindingThresholdValue) UnmarshalJSON(data []byte) error { - type NoMethod GoogleCloudDiscoveryengineV1alphaRequirementThresholdBindingThresholdValue +func (s *GoogleCloudDiscoveryengineV1alphaRankingRecord) UnmarshalJSON(data []byte) error { + type NoMethod GoogleCloudDiscoveryengineV1alphaRankingRecord var s1 struct { - Value gensupport.JSONFloat64 `json:"value"` + Score gensupport.JSONFloat64 `json:"score"` *NoMethod } s1.NoMethod = (*NoMethod)(s) if err := json.Unmarshal(data, &s1); err != nil { return err } - s.Value = float64(s1.Value) + s.Score = float64(s1.Score) return nil } -// GoogleCloudDiscoveryengineV1alphaRequirementViolationSamplesBinding: -// Specifies a samples query and bind its result to a variable which will be -// used in the `condition`. -type GoogleCloudDiscoveryengineV1alphaRequirementViolationSamplesBinding struct { - // Description: Description of this sample binding. Used by the UI to render - // user friendly descriptions for each requirement condition. Should be less - // than 128 characters long. - Description string `json:"description,omitempty"` - // SampleFilter: The filter string used for samples query. Example: - // "sample.type = \"retail.googleapis.com/user_event\" AND " - // "sample.labels.event_type = \"PURCHASE\" " - SampleFilter string `json:"sampleFilter,omitempty"` - // VariableId: The variable id to be referenced in `condition`. - VariableId string `json:"variableId,omitempty"` - // ForceSendFields is a list of field names (e.g. "Description") to - // unconditionally include in API requests. By default, fields with empty or - // default values are omitted from API requests. See - // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more - // details. - ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Description") to include in API - // requests with the JSON null value. By default, fields with empty values are - // omitted from API requests. See - // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. - NullFields []string `json:"-"` -} - -func (s GoogleCloudDiscoveryengineV1alphaRequirementViolationSamplesBinding) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaRequirementViolationSamplesBinding - return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) -} - -// GoogleCloudDiscoveryengineV1alphaResumeEngineRequest: Request for resuming -// training of an engine. -type GoogleCloudDiscoveryengineV1alphaResumeEngineRequest struct { -} - -// GoogleCloudDiscoveryengineV1alphaSampleQuery: Sample Query captures metadata -// to be used for evaluation. -type GoogleCloudDiscoveryengineV1alphaSampleQuery struct { - // CreateTime: Output only. Timestamp the SampleQuery was created at. - CreateTime string `json:"createTime,omitempty"` - // Name: Identifier. The full resource name of the sample query, in the format - // of - // `projects/{project}/locations/{location}/sampleQuerySets/{sample_query_set}/s - // ampleQueries/{sample_query}`. This field must be a UTF-8 encoded string with - // a length limit of 1024 characters. - Name string `json:"name,omitempty"` - // QueryEntry: The query entry. - QueryEntry *GoogleCloudDiscoveryengineV1alphaSampleQueryQueryEntry `json:"queryEntry,omitempty"` - - // ServerResponse contains the HTTP response code and headers from the server. - googleapi.ServerResponse `json:"-"` - // ForceSendFields is a list of field names (e.g. "CreateTime") to - // unconditionally include in API requests. By default, fields with empty or - // default values are omitted from API requests. See - // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more - // details. - ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "CreateTime") to include in API - // requests with the JSON null value. By default, fields with empty values are - // omitted from API requests. See - // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. - NullFields []string `json:"-"` -} - -func (s GoogleCloudDiscoveryengineV1alphaSampleQuery) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSampleQuery - return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) -} - -// GoogleCloudDiscoveryengineV1alphaSampleQueryQueryEntry: Query Entry captures -// metadata to be used for search evaluation. -type GoogleCloudDiscoveryengineV1alphaSampleQueryQueryEntry struct { - // Query: Required. The query. - Query string `json:"query,omitempty"` - // Targets: List of targets for the query. - Targets []*GoogleCloudDiscoveryengineV1alphaSampleQueryQueryEntryTarget `json:"targets,omitempty"` - // ForceSendFields is a list of field names (e.g. "Query") to unconditionally +// 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: * (language: + // ANY("en", "es")) AND NOT (categories: ANY("Movie")) * (available: true) AND + // (language: ANY("en", "es")) OR (categories: ANY("Movie")) If your filter + // blocks all results, the API returns 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 never returns Documents with + // `storageStatus` as `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 chooses a + // reasonable default. The maximum allowed value is 100. Values above 100 are + // set 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 is returned in + // RecommendResponse.RecommendationResult.document. * `returnScore`: Boolean. + // If set to true, the recommendation score corresponding to each returned + // Document is 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 returns 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 is 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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Query") 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. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaSampleQueryQueryEntry) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSampleQueryQueryEntry +func (s GoogleCloudDiscoveryengineV1alphaRecommendRequest) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaRecommendRequest return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaSampleQueryQueryEntryTarget: Defines the -// parameters of the query's expected outcome. -type GoogleCloudDiscoveryengineV1alphaSampleQueryQueryEntryTarget struct { - // PageNumbers: Expected page numbers of the target. Each page number must be - // non negative. - PageNumbers []int64 `json:"pageNumbers,omitempty"` - // Score: Relevance score of the target. - Score float64 `json:"score,omitempty"` - // Uri: Expected uri of the target. This field must be a UTF-8 encoded string - // with a length limit of 2048 characters. Example of valid uris: - // `https://example.com/abc`, `gcs://example/example.pdf`. - Uri string `json:"uri,omitempty"` - // ForceSendFields is a list of field names (e.g. "PageNumbers") to +// 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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "PageNumbers") to include in API - // requests with the JSON null value. By default, fields with empty values are - // omitted from API requests. See + // NullFields is a list of field names (e.g. "AttributionToken") to include in + // API requests with the JSON null value. By default, fields with empty values + // are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaSampleQueryQueryEntryTarget) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSampleQueryQueryEntryTarget +func (s GoogleCloudDiscoveryengineV1alphaRecommendResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaRecommendResponse return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -func (s *GoogleCloudDiscoveryengineV1alphaSampleQueryQueryEntryTarget) UnmarshalJSON(data []byte) error { - type NoMethod GoogleCloudDiscoveryengineV1alphaSampleQueryQueryEntryTarget - 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 -} - -// GoogleCloudDiscoveryengineV1alphaSampleQuerySet: A SampleQuerySet is the -// parent resource of SampleQuery, and contains the configurations shared by -// all SampleQuery under it. -type GoogleCloudDiscoveryengineV1alphaSampleQuerySet struct { - // CreateTime: Output only. Timestamp the SampleQuerySet was created at. - CreateTime string `json:"createTime,omitempty"` - // Description: The description of the SampleQuerySet. - Description string `json:"description,omitempty"` - // DisplayName: Required. The sample query set display name. This field must be - // a UTF-8 encoded string with a length limit of 128 characters. - DisplayName string `json:"displayName,omitempty"` - // Name: Identifier. The full resource name of the SampleQuerySet, in the - // format of - // `projects/{project}/locations/{location}/sampleQuerySets/{sample_query_set}`. - // 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:"-"` - // ForceSendFields is a list of field names (e.g. "CreateTime") to +// 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 or 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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "CreateTime") to include in API + // NullFields is a list of field names (e.g. "Document") to include in API // requests with the JSON null value. By default, fields with empty values are // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaSampleQuerySet) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSampleQuerySet +func (s GoogleCloudDiscoveryengineV1alphaRecommendResponseRecommendationResult) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaRecommendResponseRecommendationResult return gensupport.MarshalJSON(NoMethod(s), 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}/dataStores/ - // {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. "FieldConfigs") to +// 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 have invalid format. Sample + // limited to 1000. + InvalidUris []string `json:"invalidUris,omitempty"` + // InvalidUrisCount: Total number of unique URIs in the request that have + // invalid format. + InvalidUrisCount int64 `json:"invalidUrisCount,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"` + // UrisNotMatchingTargetSites: 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. Sample limited to 1000. + UrisNotMatchingTargetSites []string `json:"urisNotMatchingTargetSites,omitempty"` + // UrisNotMatchingTargetSitesCount: Total number of URIs that don't match any + // TargetSites. + UrisNotMatchingTargetSitesCount int64 `json:"urisNotMatchingTargetSitesCount,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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "FieldConfigs") to include in API + // NullFields is a list of field names (e.g. "CreateTime") to include in API // requests with the JSON null value. By default, fields with empty values are // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaSchema) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSchema +func (s GoogleCloudDiscoveryengineV1alphaRecrawlUrisMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaRecrawlUrisMetadata return gensupport.MarshalJSON(NoMethod(s), 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"` - // 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 +// GoogleCloudDiscoveryengineV1alphaRecrawlUrisRequest: Request message for +// SiteSearchEngineService.RecrawlUris method. +type GoogleCloudDiscoveryengineV1alphaRecrawlUrisRequest struct { + // SiteCredential: Optional. Full resource name of the SiteCredential, such as + // `projects/*/locations/*/collections/*/dataStores/*/siteSearchEngine/siteCrede + // ntials/*`. Only set to crawl private URIs. + SiteCredential string `json:"siteCredential,omitempty"` + // 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. "SiteCredential") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "SiteCredential") to include in + // API requests with the JSON null value. By default, fields with empty values + // are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1alphaRecrawlUrisRequest) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaRecrawlUrisRequest + return gensupport.MarshalJSON(NoMethod(s), 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. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + 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. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponse + return gensupport.MarshalJSON(NoMethod(s), 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"` + // 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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. 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. "FailureReasons") to include in + // API requests with the JSON null value. By default, fields with empty values + // are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfo) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfo + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfoFailureReason: +// +// 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. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + 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. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaSearchInfo) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSearchInfo +func (s GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfoFailureReason) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfoFailureReason return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaSearchLinkPromotion: Promotion proto -// includes uri and other helping information to display the promotion. -type GoogleCloudDiscoveryengineV1alphaSearchLinkPromotion struct { - // Description: Optional. The Promotion description. Maximum length: 200 - // characters. - Description string `json:"description,omitempty"` - // Enabled: Optional. The enabled promotion will be returned for any serving - // configs associated with the parent of the control this promotion is attached - // to. This flag is used for basic site search only. - Enabled bool `json:"enabled,omitempty"` - // ImageUri: Optional. The promotion thumbnail image url. - ImageUri string `json:"imageUri,omitempty"` - // Title: Required. The title of the promotion. Maximum length: 160 characters. - Title string `json:"title,omitempty"` - // Uri: Required. The URL for the page the user wants to promote. +// 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"` + // Summary: Summary based on search results. + Summary *GoogleCloudDiscoveryengineV1alphaSearchResponseSummary `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. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + 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. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1alphaReply) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaReply + return gensupport.MarshalJSON(NoMethod(s), 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"` - // ForceSendFields is a list of field names (e.g. "Description") to + // 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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Description") to include in API + // 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. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaSearchLinkPromotion) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSearchLinkPromotion +func (s GoogleCloudDiscoveryengineV1alphaReplyReference) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaReplyReference return gensupport.MarshalJSON(NoMethod(s), 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/generative-ai-app-builder/docs/boost-search-results) - BoostSpec *GoogleCloudDiscoveryengineV1alphaSearchRequestBoostSpec `json:"boostSpec,omitempty"` - // Branch: The branch resource name, such as - // `projects/*/locations/global/collections/default_collection/dataStores/defaul - // t_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"` - // CustomFineTuningSpec: Custom fine tuning configs. If set, it has higher - // priority than the configs set in ServingConfig.custom_fine_tuning_spec. - CustomFineTuningSpec *GoogleCloudDiscoveryengineV1alphaCustomFineTuningSpec `json:"customFineTuningSpec,omitempty"` - // DataStoreSpecs: Specs defining DataStores to filter on in a search call and - // configurations for those data stores. This is only considered for Engines - // with multiple data stores. For engines with a single data store, the specs - // directly under SearchRequest should be used. - DataStoreSpecs []*GoogleCloudDiscoveryengineV1alphaSearchRequestDataStoreSpec `json:"dataStoreSpecs,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_path. - 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"` - // LanguageCode: The BCP-47 language code, such as "en-US" or "sr-Latn". For - // more information, see Standard fields - // (https://cloud.google.com/apis/design/standard_fields). This field helps to - // better interpret the query. If a value isn't specified, the query language - // code is automatically detected, which may not be accurate. - LanguageCode string `json:"languageCode,omitempty"` - // NaturalLanguageQueryUnderstandingSpec: If - // `naturalLanguageQueryUnderstandingSpec` is not specified, no additional - // natural language query understanding will be done. - NaturalLanguageQueryUnderstandingSpec *GoogleCloudDiscoveryengineV1alphaSearchRequestNaturalLanguageQueryUnderstandingSpec `json:"naturalLanguageQueryUnderstandingSpec,omitempty"` - // Offset: A 0-indexed integer that specifies the current offset (that is, - // starting result location, amongst the Documents deemed by the API as - // 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"` - // OneBoxPageSize: The maximum number of results to return for OneBox. This - // applies to each OneBox type individually. Default number is 10. - OneBoxPageSize int64 `json:"oneBoxPageSize,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 - // the website search results, see Order web search results - // (https://cloud.google.com/generative-ai-app-builder/docs/order-web-search-results). - // For more information on ordering the healthcare search results, see Order - // healthcare search results - // (https://cloud.google.com/generative-ai-app-builder/docs/order-hc-results). - // If this field is unrecognizable, an `INVALID_ARGUMENT` is returned. - OrderBy string `json:"orderBy,omitempty"` - // PageSize: Maximum number of Documents to return. The maximum allowed value - // depends on the data type. Values above the maximum value are coerced to the - // maximum value. * Websites with basic indexing: Default `10`, Maximum `25`. * - // Websites with advanced indexing: Default `25`, Maximum `50`. * Other: - // Default `50`, Maximum `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. For 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. For example, `search_type: 1` - Params googleapi.RawMessage `json:"params,omitempty"` - // PersonalizationSpec: The specification for personalization. Notice that if - // both ServingConfig.personalization_spec and - // SearchRequest.personalization_spec are set, - // SearchRequest.personalization_spec overrides - // ServingConfig.personalization_spec. - PersonalizationSpec *GoogleCloudDiscoveryengineV1alphaSearchRequestPersonalizationSpec `json:"personalizationSpec,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 - // joined 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"` - // RegionCode: The Unicode country/region code (CLDR) of a location, such as - // "US" and "419". For more information, see Standard fields - // (https://cloud.google.com/apis/design/standard_fields). If set, then results - // will be boosted based on the region_code provided. - RegionCode string `json:"regionCode,omitempty"` - // RelevanceThreshold: The relevance threshold of the search results. Default - // to Google defined threshold, leveraging a balance of precision and recall to - // deliver both highly accurate results and comprehensive coverage of relevant - // information. +// GoogleCloudDiscoveryengineV1alphaReportConsentChangeRequest: Request for +// ReportConsentChange method. +type GoogleCloudDiscoveryengineV1alphaReportConsentChangeRequest struct { + // ConsentChangeAction: Required. Whether customer decides to accept or decline + // service term. At this moment, only accept action is supported. // // Possible values: - // "RELEVANCE_THRESHOLD_UNSPECIFIED" - Default value. In this case, server - // behavior defaults to Google defined threshold. - // "LOWEST" - Lowest relevance threshold. - // "LOW" - Low relevance threshold. - // "MEDIUM" - Medium relevance threshold. - // "HIGH" - High relevance threshold. - RelevanceThreshold string `json:"relevanceThreshold,omitempty"` - // SafeSearch: Whether to turn on safe search. This is only supported for - // website search. - SafeSearch bool `json:"safeSearch,omitempty"` - // SearchAsYouTypeSpec: Search as you type configuration. Only supported for - // the IndustryVertical.MEDIA vertical. - SearchAsYouTypeSpec *GoogleCloudDiscoveryengineV1alphaSearchRequestSearchAsYouTypeSpec `json:"searchAsYouTypeSpec,omitempty"` - // ServingConfig: Required. The resource name of the Search serving config, - // such as - // `projects/*/locations/global/collections/default_collection/engines/*/serving - // Configs/default_serving_config`, or - // `projects/*/locations/global/collections/default_collection/dataStores/defaul - // t_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"` - // Session: The session resource name. Optional. Session allows users to do - // multi-turn /search API calls or coordination between /search API calls and - // /answer API calls. Example #1 (multi-turn /search API calls): 1. Call - // /search API with the auto-session mode (see below). 2. Call /search API with - // the session ID generated in the first call. Here, the previous search query - // gets considered in query standing. I.e., if the first query is "How did - // Alphabet do in 2022?" and the current query is "How about 2023?", the - // current query will be interpreted as "How did Alphabet do in 2023?". Example - // #2 (coordination between /search API calls and /answer API calls): 1. Call - // /search API with the auto-session mode (see below). 2. Call /answer API with - // the session ID generated in the first call. Here, the answer generation - // happens in the context of the search results from the first search call. - // Auto-session mode: when `projects/.../sessions/-` is used, a new session - // gets automatically created. Otherwise, users can use the create-session API - // to create a session manually. Multi-turn Search feature is currently at - // private GA stage. Please use v1alpha or v1beta version instead before we - // launch this feature to public GA. Or ask for allowlisting through Google - // Support team. - Session string `json:"session,omitempty"` - // SessionSpec: Session specification. Can be used only when `session` is set. - SessionSpec *GoogleCloudDiscoveryengineV1alphaSearchRequestSessionSpec `json:"sessionSpec,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"` - // 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. See - // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more - // details. - 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. See - // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. - NullFields []string `json:"-"` -} - -func (s GoogleCloudDiscoveryengineV1alphaSearchRequest) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSearchRequest - return gensupport.MarshalJSON(NoMethod(s), 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"` - // ForceSendFields is a list of field names (e.g. "ConditionBoostSpecs") to + // "CONSENT_CHANGE_ACTION_UNSPECIFIED" - Invalid action, user must specify + // accept/decline + // "ACCEPT" - User accepts service terms. + ConsentChangeAction string `json:"consentChangeAction,omitempty"` + // ServiceTermId: Required. The unique identifier of the terms of service to + // update. Available term ids: * `GA_DATA_USE_TERMS`: Terms for data use + // (https://cloud.google.com/retail/data-use-terms). When using this service + // term id, the acceptable service_term_version to provide is `2022-11-23`. + ServiceTermId string `json:"serviceTermId,omitempty"` + // ServiceTermVersion: Required. The version string of the terms of service to + // update. + ServiceTermVersion string `json:"serviceTermVersion,omitempty"` + // ForceSendFields is a list of field names (e.g. "ConsentChangeAction") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "ConditionBoostSpecs") to include + // NullFields is a list of field names (e.g. "ConsentChangeAction") to include // in API requests with the JSON null value. By default, fields with empty // values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaSearchRequestBoostSpec) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSearchRequestBoostSpec +func (s GoogleCloudDiscoveryengineV1alphaReportConsentChangeRequest) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaReportConsentChangeRequest return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaSearchRequestBoostSpecConditionBoostSpec: -// 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. Only one of - // the (condition, boost) combination or the boost_control_spec below are set. - // If both are set then the global boost is ignored and the more fine-grained - // boost_control_spec is applied. - Boost float64 `json:"boost,omitempty"` - // BoostControlSpec: Complex specification for custom ranking based on customer - // defined attribute value. - BoostControlSpec *GoogleCloudDiscoveryengineV1alphaSearchRequestBoostSpecConditionBoostSpecBoostControlSpec `json:"boostControlSpec,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": - // `(document_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. See +// GoogleCloudDiscoveryengineV1alphaRequirement: A data requirement. +type GoogleCloudDiscoveryengineV1alphaRequirement struct { + // Condition: The condition for evaluating the requirement result. Variables in + // the expression should be provided by `metrics_bindings` or + // `threshold_bindings`. Where `metrics_bindings` are used for computed metrics + // and `threshold_bindings` are used to define thresholds for corresponding + // `metric_bindings`. + Condition *GoogleTypeExpr `json:"condition,omitempty"` + // Description: The description of the requirement. + Description string `json:"description,omitempty"` + // DisplayName: The name of the requirement. + DisplayName string `json:"displayName,omitempty"` + // MetricBindings: A list of the metric bindings to be used in `condition`. + MetricBindings []*GoogleCloudDiscoveryengineV1alphaRequirementMetricBinding `json:"metricBindings,omitempty"` + // Severity: The severity of errors if the requirement is not met. It must be + // ordered from the most strict to the least strict. Examples: * `BLOCKING` * + // `CRITICAL` * `WARNING` All thresholds in the requirement must have all the + // severity here. + Severity []string `json:"severity,omitempty"` + // ThresholdBindings: A list of threshold bindings to be used in `condition`. + ThresholdBindings []*GoogleCloudDiscoveryengineV1alphaRequirementThresholdBinding `json:"thresholdBindings,omitempty"` + // Type: The requirement type, used as an identifier. Must be unique. The type + // should prefix with service name to avoid possible collision. It's encouraged + // to use natural hierarchical grouping for similar requirements. Examples: * + // `library.googleapis.com/books/min_available_books` * + // `discoveryengine.googleapis.com/media_rec/recommended_for_you/conversion_rate + // ` + Type string `json:"type,omitempty"` + // ViolationSamplesBindings: A list of the metric bindings to be used in + // `condition`. + ViolationSamplesBindings []*GoogleCloudDiscoveryengineV1alphaRequirementViolationSamplesBinding `json:"violationSamplesBindings,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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Boost") to include in API + // 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. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaSearchRequestBoostSpecConditionBoostSpec) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSearchRequestBoostSpecConditionBoostSpec +func (s GoogleCloudDiscoveryengineV1alphaRequirement) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaRequirement return gensupport.MarshalJSON(NoMethod(s), 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 +// GoogleCloudDiscoveryengineV1alphaRequirementMetricBinding: Specifies a +// metrics query and bind its result to a variable which will be used in the +// `condition`. +type GoogleCloudDiscoveryengineV1alphaRequirementMetricBinding struct { + // Category: The category of the metric's target resource. Example: "Events" + Category string `json:"category,omitempty"` + // Description: Human readable description of the corresponding metric filter. + Description string `json:"description,omitempty"` + // MetricFilter: The filter string used for metrics query. Example: + // "metric.type = \"discoveryengine.googleapis.com/events/day_count\" AND " + // "metric.conditions.time_range = \"NINETY_DAYS\"" + MetricFilter string `json:"metricFilter,omitempty"` + // ResourceType: The resource being monitored for the metric. + ResourceType string `json:"resourceType,omitempty"` + // VariableId: The variable id to be referenced in `condition`. + VariableId string `json:"variableId,omitempty"` + // ForceSendFields is a list of field names (e.g. "Category") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "Category") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` } -// GoogleCloudDiscoveryengineV1alphaSearchRequestBoostSpecConditionBoostSpecBoos -// tControlSpec: Specification for custom ranking based on customer specified -// attribute value. It provides more controls for customized ranking than the -// simple (condition, boost) combination above. -type GoogleCloudDiscoveryengineV1alphaSearchRequestBoostSpecConditionBoostSpecBoostControlSpec struct { - // AttributeType: The attribute type to be used to determine the boost amount. - // The attribute value can be derived from the field value of the specified - // field_name. In the case of numerical it is straightforward i.e. - // attribute_value = numerical_field_value. In the case of freshness however, - // attribute_value = (time.now() - datetime_field_value). - // - // Possible values: - // "ATTRIBUTE_TYPE_UNSPECIFIED" - Unspecified AttributeType. - // "NUMERICAL" - The value of the numerical field will be used to dynamically - // update the boost amount. In this case, the attribute_value (the x value) of - // the control point will be the actual value of the numerical field for which - // the boost_amount is specified. - // "FRESHNESS" - For the freshness use case the attribute value will be the - // duration between the current time and the date in the datetime field - // specified. The value must be formatted as an XSD `dayTimeDuration` value (a - // restricted subset of an ISO 8601 duration value). The pattern for this is: - // `nDnM]`. For example, `5D`, `3DT12H30M`, `T24H`. - AttributeType string `json:"attributeType,omitempty"` - // ControlPoints: The control points used to define the curve. The monotonic - // function (defined through the interpolation_type above) passes through the - // control points listed here. - ControlPoints []*GoogleCloudDiscoveryengineV1alphaSearchRequestBoostSpecConditionBoostSpecBoostControlSpecControlPoint `json:"controlPoints,omitempty"` - // FieldName: The name of the field whose value will be used to determine the - // boost amount. - FieldName string `json:"fieldName,omitempty"` - // InterpolationType: The interpolation type to be applied to connect the - // control points listed below. - // - // Possible values: - // "INTERPOLATION_TYPE_UNSPECIFIED" - Interpolation type is unspecified. In - // this case, it defaults to Linear. - // "LINEAR" - Piecewise linear interpolation will be applied. - InterpolationType string `json:"interpolationType,omitempty"` - // ForceSendFields is a list of field names (e.g. "AttributeType") to +func (s GoogleCloudDiscoveryengineV1alphaRequirementMetricBinding) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaRequirementMetricBinding + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaRequirementThresholdBinding: Specifies a +// multi-level threshold to apply to apply to a `metric_bindings` in the +// `condition` CEL expression. +type GoogleCloudDiscoveryengineV1alphaRequirementThresholdBinding struct { + // Description: Human readable description of the corresponding threshold and + // sub-requirement. + Description string `json:"description,omitempty"` + // ThresholdValues: The values of the threshold. The values should be ordered + // from the most strict to the least strict. + ThresholdValues []*GoogleCloudDiscoveryengineV1alphaRequirementThresholdBindingThresholdValue `json:"thresholdValues,omitempty"` + // VariableId: The variable id to be referenced in `condition`. Must be unique + // across all `metric_bindings` and `threshold_bindings`. + VariableId string `json:"variableId,omitempty"` + // ForceSendFields is a list of field names (e.g. "Description") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "AttributeType") to include in API + // NullFields is a list of field names (e.g. "Description") to include in API // requests with the JSON null value. By default, fields with empty values are // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaSearchRequestBoostSpecConditionBoostSpecBoostControlSpec) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSearchRequestBoostSpecConditionBoostSpecBoostControlSpec +func (s GoogleCloudDiscoveryengineV1alphaRequirementThresholdBinding) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaRequirementThresholdBinding return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaSearchRequestBoostSpecConditionBoostSpecBoos -// tControlSpecControlPoint: The control points used to define the curve. The -// curve defined through these control points can only be monotonically -// increasing or decreasing(constant values are acceptable). -type GoogleCloudDiscoveryengineV1alphaSearchRequestBoostSpecConditionBoostSpecBoostControlSpecControlPoint struct { - // AttributeValue: Can be one of: 1. The numerical field value. 2. The duration - // spec for freshness: The value must be formatted as an XSD `dayTimeDuration` - // value (a restricted subset of an ISO 8601 duration value). The pattern for - // this is: `nDnM]`. - AttributeValue string `json:"attributeValue,omitempty"` - // BoostAmount: The value between -1 to 1 by which to boost the score if the - // attribute_value evaluates to the value specified above. - BoostAmount float64 `json:"boostAmount,omitempty"` - // ForceSendFields is a list of field names (e.g. "AttributeValue") to +// GoogleCloudDiscoveryengineV1alphaRequirementThresholdBindingThresholdValue: +// Specifies a threshold value for a given severity. +type GoogleCloudDiscoveryengineV1alphaRequirementThresholdBindingThresholdValue struct { + // Severity: The severity of errors if the threshold is not met. It should be + // one of the `severity` fields in the requirement. + Severity string `json:"severity,omitempty"` + // Value: The value of the threshold. + Value float64 `json:"value,omitempty"` + // ForceSendFields is a list of field names (e.g. "Severity") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "AttributeValue") to include in - // API requests with the JSON null value. By default, fields with empty values - // are omitted from API requests. See + // NullFields is a list of field names (e.g. "Severity") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaSearchRequestBoostSpecConditionBoostSpecBoostControlSpecControlPoint) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSearchRequestBoostSpecConditionBoostSpecBoostControlSpecControlPoint +func (s GoogleCloudDiscoveryengineV1alphaRequirementThresholdBindingThresholdValue) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaRequirementThresholdBindingThresholdValue return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -func (s *GoogleCloudDiscoveryengineV1alphaSearchRequestBoostSpecConditionBoostSpecBoostControlSpecControlPoint) UnmarshalJSON(data []byte) error { - type NoMethod GoogleCloudDiscoveryengineV1alphaSearchRequestBoostSpecConditionBoostSpecBoostControlSpecControlPoint +func (s *GoogleCloudDiscoveryengineV1alphaRequirementThresholdBindingThresholdValue) UnmarshalJSON(data []byte) error { + type NoMethod GoogleCloudDiscoveryengineV1alphaRequirementThresholdBindingThresholdValue var s1 struct { - BoostAmount gensupport.JSONFloat64 `json:"boostAmount"` + Value gensupport.JSONFloat64 `json:"value"` *NoMethod } s1.NoMethod = (*NoMethod)(s) if err := json.Unmarshal(data, &s1); err != nil { return err } - s.BoostAmount = float64(s1.BoostAmount) + s.Value = float64(s1.Value) return nil } -// GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpec: A -// specification for configuring the behavior of content search. -type GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpec struct { - // ChunkSpec: Specifies the chunk spec to be returned from the search response. - // Only available if the SearchRequest.ContentSearchSpec.search_result_mode is - // set to CHUNKS - ChunkSpec *GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecChunkSpec `json:"chunkSpec,omitempty"` - // ExtractiveContentSpec: If there is no extractive_content_spec provided, - // there will be no extractive answer in the search response. - ExtractiveContentSpec *GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecExtractiveContentSpec `json:"extractiveContentSpec,omitempty"` - // SearchResultMode: Specifies the search result mode. If unspecified, the - // search result mode defaults to `DOCUMENTS`. - // - // Possible values: - // "SEARCH_RESULT_MODE_UNSPECIFIED" - Default value. - // "DOCUMENTS" - Returns documents in the search result. - // "CHUNKS" - Returns chunks in the search result. Only available if the - // DocumentProcessingConfig.chunking_config is specified. - SearchResultMode string `json:"searchResultMode,omitempty"` - // SnippetSpec: If `snippetSpec` is not specified, snippets are not included in - // the search response. - SnippetSpec *GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSnippetSpec `json:"snippetSpec,omitempty"` - // 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. "ChunkSpec") to +// GoogleCloudDiscoveryengineV1alphaRequirementViolationSamplesBinding: +// Specifies a samples query and bind its result to a variable which will be +// used in the `condition`. +type GoogleCloudDiscoveryengineV1alphaRequirementViolationSamplesBinding struct { + // Description: Description of this sample binding. Used by the UI to render + // user friendly descriptions for each requirement condition. Should be less + // than 128 characters long. + Description string `json:"description,omitempty"` + // SampleFilter: The filter string used for samples query. Example: + // "sample.type = \"retail.googleapis.com/user_event\" AND " + // "sample.labels.event_type = \"PURCHASE\" " + SampleFilter string `json:"sampleFilter,omitempty"` + // VariableId: The variable id to be referenced in `condition`. + VariableId string `json:"variableId,omitempty"` + // ForceSendFields is a list of field names (e.g. "Description") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "ChunkSpec") to include in API + // NullFields is a list of field names (e.g. "Description") to include in API // requests with the JSON null value. By default, fields with empty values are // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpec) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpec +func (s GoogleCloudDiscoveryengineV1alphaRequirementViolationSamplesBinding) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaRequirementViolationSamplesBinding return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecChunkSpec: -// Specifies the chunk spec to be returned from the search response. Only -// available if the SearchRequest.ContentSearchSpec.search_result_mode is set -// to CHUNKS -type GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecChunkSpec struct { - // NumNextChunks: The number of next chunks to be returned of the current - // chunk. The maximum allowed value is 3. If not specified, no next chunks will - // be returned. - NumNextChunks int64 `json:"numNextChunks,omitempty"` - // NumPreviousChunks: The number of previous chunks to be returned of the - // current chunk. The maximum allowed value is 3. If not specified, no previous - // chunks will be returned. - NumPreviousChunks int64 `json:"numPreviousChunks,omitempty"` - // ForceSendFields is a list of field names (e.g. "NumNextChunks") to +// GoogleCloudDiscoveryengineV1alphaResumeEngineRequest: Request for resuming +// training of an engine. +type GoogleCloudDiscoveryengineV1alphaResumeEngineRequest struct { +} + +// GoogleCloudDiscoveryengineV1alphaSampleQuery: Sample Query captures metadata +// to be used for evaluation. +type GoogleCloudDiscoveryengineV1alphaSampleQuery struct { + // CreateTime: Output only. Timestamp the SampleQuery was created at. + CreateTime string `json:"createTime,omitempty"` + // Name: Identifier. The full resource name of the sample query, in the format + // of + // `projects/{project}/locations/{location}/sampleQuerySets/{sample_query_set}/s + // ampleQueries/{sample_query}`. This field must be a UTF-8 encoded string with + // a length limit of 1024 characters. + Name string `json:"name,omitempty"` + // QueryEntry: The query entry. + QueryEntry *GoogleCloudDiscoveryengineV1alphaSampleQueryQueryEntry `json:"queryEntry,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the server. + googleapi.ServerResponse `json:"-"` + // ForceSendFields is a list of field names (e.g. "CreateTime") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "NumNextChunks") to include in API + // NullFields is a list of field names (e.g. "CreateTime") to include in API // requests with the JSON null value. By default, fields with empty values are // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecChunkSpec) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecChunkSpec +func (s GoogleCloudDiscoveryengineV1alphaSampleQuery) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSampleQuery return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecExtractiveCont -// entSpec: 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"` - // 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"` - // ReturnExtractiveSegmentScore: Specifies whether to return the confidence - // score from the extractive segments in each search result. This feature is - // available only for new or allowlisted data stores. To allowlist your data - // store, contact your Customer Engineer. The default value is `false`. - ReturnExtractiveSegmentScore bool `json:"returnExtractiveSegmentScore,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. See +// GoogleCloudDiscoveryengineV1alphaSampleQueryQueryEntry: Query Entry captures +// metadata to be used for search evaluation. +type GoogleCloudDiscoveryengineV1alphaSampleQueryQueryEntry struct { + // Query: Required. The query. + Query string `json:"query,omitempty"` + // Targets: List of targets for the query. + Targets []*GoogleCloudDiscoveryengineV1alphaSampleQueryQueryEntryTarget `json:"targets,omitempty"` + // ForceSendFields is a list of field names (e.g. "Query") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. 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. See + // NullFields is a list of field names (e.g. "Query") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecExtractiveContentSpec) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecExtractiveContentSpec +func (s GoogleCloudDiscoveryengineV1alphaSampleQueryQueryEntry) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSampleQueryQueryEntry return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSnippetSpec: -// 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"` - // 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 +// GoogleCloudDiscoveryengineV1alphaSampleQueryQueryEntryTarget: Defines the +// parameters of the query's expected outcome. +type GoogleCloudDiscoveryengineV1alphaSampleQueryQueryEntryTarget struct { + // PageNumbers: Expected page numbers of the target. Each page number must be + // non negative. + PageNumbers []int64 `json:"pageNumbers,omitempty"` + // Score: Relevance score of the target. + Score float64 `json:"score,omitempty"` + // Uri: Expected uri of the target. This field must be a UTF-8 encoded string + // with a length limit of 2048 characters. Example of valid uris: + // `https://example.com/abc`, `gcs://example/example.pdf`. + Uri string `json:"uri,omitempty"` + // ForceSendFields is a list of field names (e.g. "PageNumbers") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. 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. See + // NullFields is a list of field names (e.g. "PageNumbers") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSnippetSpec) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSnippetSpec +func (s GoogleCloudDiscoveryengineV1alphaSampleQueryQueryEntryTarget) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSampleQueryQueryEntryTarget return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSummarySpec: -// 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"` - // IgnoreJailBreakingQuery: Optional. Specifies whether to filter out - // jail-breaking queries. The default value is `false`. Google employs - // search-query classification to detect jail-breaking queries. No summary is - // returned if the search query is classified as a jail-breaking query. A user - // might add instructions to the query to change the tone, style, language, - // content of the answer, or ask the model to act as a different entity, e.g. - // "Reply in the tone of a competing company's CEO". If this field is set to - // `true`, we skip generating summaries for jail-breaking queries and return - // fallback messages instead. - IgnoreJailBreakingQuery bool `json:"ignoreJailBreakingQuery,omitempty"` - // IgnoreLowRelevantContent: Specifies whether to filter out queries that have - // low relevance. The default value is `false`. If this field is set to - // `false`, all search results are used regardless of relevance to generate - // answers. If set to `true`, only queries with high relevance search results - // will generate answers. - IgnoreLowRelevantContent bool `json:"ignoreLowRelevantContent,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 *GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSummarySpecModelPromptSpec `json:"modelPromptSpec,omitempty"` - // ModelSpec: If specified, the spec will be used to modify the model - // specification provided to the LLM. - ModelSpec *GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSummarySpecModelSpec `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 10 results for - // documents mode, or 50 for chunks mode, can be used to generate a summary. - // The chunks mode is used when - // SearchRequest.ContentSearchSpec.search_result_mode is set to CHUNKS. - SummaryResultCount int64 `json:"summaryResultCount,omitempty"` - // UseSemanticChunks: If true, answer will be generated from most relevant - // chunks from top search results. This feature will improve summary quality. - // Note that with this feature enabled, not all top search results will be - // referenced and included in the reference list, so the citation source index - // only points to the search results listed in the reference list. - UseSemanticChunks bool `json:"useSemanticChunks,omitempty"` - // ForceSendFields is a list of field names (e.g. "IgnoreAdversarialQuery") to +func (s *GoogleCloudDiscoveryengineV1alphaSampleQueryQueryEntryTarget) UnmarshalJSON(data []byte) error { + type NoMethod GoogleCloudDiscoveryengineV1alphaSampleQueryQueryEntryTarget + 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 +} + +// GoogleCloudDiscoveryengineV1alphaSampleQuerySet: A SampleQuerySet is the +// parent resource of SampleQuery, and contains the configurations shared by +// all SampleQuery under it. +type GoogleCloudDiscoveryengineV1alphaSampleQuerySet struct { + // CreateTime: Output only. Timestamp the SampleQuerySet was created at. + CreateTime string `json:"createTime,omitempty"` + // Description: The description of the SampleQuerySet. + Description string `json:"description,omitempty"` + // DisplayName: Required. The sample query set display name. This field must be + // a UTF-8 encoded string with a length limit of 128 characters. + DisplayName string `json:"displayName,omitempty"` + // Name: Identifier. The full resource name of the SampleQuerySet, in the + // format of + // `projects/{project}/locations/{location}/sampleQuerySets/{sample_query_set}`. + // 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:"-"` + // ForceSendFields is a list of field names (e.g. "CreateTime") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "IgnoreAdversarialQuery") to - // include in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. See + // NullFields is a list of field names (e.g. "CreateTime") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSummarySpec) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSummarySpec +func (s GoogleCloudDiscoveryengineV1alphaSampleQuerySet) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSampleQuerySet return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSummarySpecMod -// elPromptSpec: 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. "Preamble") to +// 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}/dataStores/ + // {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. "FieldConfigs") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Preamble") to include in API + // 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. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSummarySpecModelPromptSpec) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSummarySpecModelPromptSpec +func (s GoogleCloudDiscoveryengineV1alphaSchema) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSchema return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSummarySpecMod -// elSpec: 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 model. For more information, see Answer - // generation model versions and lifecycle - // (https://cloud.google.com/generative-ai-app-builder/docs/answer-generation-models). - // * `preview`: string. (Public preview) Uses a preview model. For more - // information, see Answer generation model versions and lifecycle - // (https://cloud.google.com/generative-ai-app-builder/docs/answer-generation-models). - Version string `json:"version,omitempty"` - // ForceSendFields is a list of field names (e.g. "Version") to unconditionally +// 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"` + // 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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Version") to include in API + // 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. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSummarySpecModelSpec) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSummarySpecModelSpec - return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) -} - -// GoogleCloudDiscoveryengineV1alphaSearchRequestDataStoreSpec: A struct to -// define data stores to filter on in a search call and configurations for -// those data stores. Otherwise, an `INVALID_ARGUMENT` error is returned. -type GoogleCloudDiscoveryengineV1alphaSearchRequestDataStoreSpec struct { - // BoostSpec: Optional. Boost specification to boost certain documents. For - // more information on boosting, see Boosting - // (https://cloud.google.com/generative-ai-app-builder/docs/boost-search-results) - BoostSpec *GoogleCloudDiscoveryengineV1alphaSearchRequestBoostSpec `json:"boostSpec,omitempty"` - // DataStore: Required. Full resource name of DataStore, such as - // `projects/{project}/locations/{location}/collections/{collection_id}/dataStor - // es/{data_store_id}`. - DataStore string `json:"dataStore,omitempty"` - // Filter: Optional. Filter specification to filter documents in the data store - // specified by data_store field. For more information on filtering, see - // Filtering - // (https://cloud.google.com/generative-ai-app-builder/docs/filter-search-metadata) - Filter string `json:"filter,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. See - // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more - // details. - 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. See - // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. - NullFields []string `json:"-"` -} - -func (s GoogleCloudDiscoveryengineV1alphaSearchRequestDataStoreSpec) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSearchRequestDataStoreSpec - return gensupport.MarshalJSON(NoMethod(s), 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"` - // 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. See - // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more - // details. - 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. See - // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. - NullFields []string `json:"-"` -} - -func (s GoogleCloudDiscoveryengineV1alphaSearchRequestEmbeddingSpec) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSearchRequestEmbeddingSpec +func (s GoogleCloudDiscoveryengineV1alphaSearchInfo) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSearchInfo return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaSearchRequestEmbeddingSpecEmbeddingVector: -// Embedding vector. -type GoogleCloudDiscoveryengineV1alphaSearchRequestEmbeddingSpecEmbeddingVector 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 +// GoogleCloudDiscoveryengineV1alphaSearchLinkPromotion: Promotion proto +// includes uri and other helping information to display the promotion. +type GoogleCloudDiscoveryengineV1alphaSearchLinkPromotion struct { + // Description: Optional. The Promotion description. Maximum length: 200 + // characters. + Description string `json:"description,omitempty"` + // Enabled: Optional. The enabled promotion will be returned for any serving + // configs associated with the parent of the control this promotion is attached + // to. This flag is used for basic site search only. + Enabled bool `json:"enabled,omitempty"` + // ImageUri: Optional. The promotion thumbnail image url. + ImageUri string `json:"imageUri,omitempty"` + // Title: Required. The title of the promotion. Maximum length: 160 characters. + Title string `json:"title,omitempty"` + // Uri: Required. The URL for the page the user wants to promote. + Uri string `json:"uri,omitempty"` + // ForceSendFields is a list of field names (e.g. "Description") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "FieldPath") to include in API + // NullFields is a list of field names (e.g. "Description") to include in API // requests with the JSON null value. By default, fields with empty values are // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaSearchRequestEmbeddingSpecEmbeddingVector) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSearchRequestEmbeddingSpecEmbeddingVector - return gensupport.MarshalJSON(NoMethod(s), 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 facet values that are returned for this facet. If - // unspecified, defaults to 20. The maximum allowed value is 300. Values above - // 300 are coerced to 300. For aggregation in healthcare search, when the - // [FacetKey.key] is "healthcare_aggregation_key", the limit will be overridden - // to 10,000 internally, regardless of the value set here. 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. See - // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more - // details. - 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. See - // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. - NullFields []string `json:"-"` -} - -func (s GoogleCloudDiscoveryengineV1alphaSearchRequestFacetSpec) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSearchRequestFacetSpec - return gensupport.MarshalJSON(NoMethod(s), 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 contain 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"` - // 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. See - // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more - // details. - 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. See - // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. - NullFields []string `json:"-"` -} - -func (s GoogleCloudDiscoveryengineV1alphaSearchRequestFacetSpecFacetKey) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSearchRequestFacetSpecFacetKey +func (s GoogleCloudDiscoveryengineV1alphaSearchLinkPromotion) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSearchLinkPromotion return gensupport.MarshalJSON(NoMethod(s), 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"` - // 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. See - // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more - // details. - 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. See - // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. - NullFields []string `json:"-"` -} - -func (s GoogleCloudDiscoveryengineV1alphaSearchRequestImageQuery) MarshalJSON() ([]byte, error) { +// 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/generative-ai-app-builder/docs/boost-search-results) + BoostSpec *GoogleCloudDiscoveryengineV1alphaSearchRequestBoostSpec `json:"boostSpec,omitempty"` + // Branch: The branch resource name, such as + // `projects/*/locations/global/collections/default_collection/dataStores/defaul + // t_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"` + // CustomFineTuningSpec: Custom fine tuning configs. If set, it has higher + // priority than the configs set in ServingConfig.custom_fine_tuning_spec. + CustomFineTuningSpec *GoogleCloudDiscoveryengineV1alphaCustomFineTuningSpec `json:"customFineTuningSpec,omitempty"` + // DataStoreSpecs: Specs defining DataStores to filter on in a search call and + // configurations for those data stores. This is only considered for Engines + // with multiple data stores. For engines with a single data store, the specs + // directly under SearchRequest should be used. + DataStoreSpecs []*GoogleCloudDiscoveryengineV1alphaSearchRequestDataStoreSpec `json:"dataStoreSpecs,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_path. + 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"` + // LanguageCode: The BCP-47 language code, such as "en-US" or "sr-Latn". For + // more information, see Standard fields + // (https://cloud.google.com/apis/design/standard_fields). This field helps to + // better interpret the query. If a value isn't specified, the query language + // code is automatically detected, which may not be accurate. + LanguageCode string `json:"languageCode,omitempty"` + // NaturalLanguageQueryUnderstandingSpec: If + // `naturalLanguageQueryUnderstandingSpec` is not specified, no additional + // natural language query understanding will be done. + NaturalLanguageQueryUnderstandingSpec *GoogleCloudDiscoveryengineV1alphaSearchRequestNaturalLanguageQueryUnderstandingSpec `json:"naturalLanguageQueryUnderstandingSpec,omitempty"` + // Offset: A 0-indexed integer that specifies the current offset (that is, + // starting result location, amongst the Documents deemed by the API as + // 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"` + // OneBoxPageSize: The maximum number of results to return for OneBox. This + // applies to each OneBox type individually. Default number is 10. + OneBoxPageSize int64 `json:"oneBoxPageSize,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 + // the website search results, see Order web search results + // (https://cloud.google.com/generative-ai-app-builder/docs/order-web-search-results). + // For more information on ordering the healthcare search results, see Order + // healthcare search results + // (https://cloud.google.com/generative-ai-app-builder/docs/order-hc-results). + // If this field is unrecognizable, an `INVALID_ARGUMENT` is returned. + OrderBy string `json:"orderBy,omitempty"` + // PageSize: Maximum number of Documents to return. The maximum allowed value + // depends on the data type. Values above the maximum value are coerced to the + // maximum value. * Websites with basic indexing: Default `10`, Maximum `25`. * + // Websites with advanced indexing: Default `25`, Maximum `50`. * Other: + // Default `50`, Maximum `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. For 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. For example, `search_type: 1` + Params googleapi.RawMessage `json:"params,omitempty"` + // PersonalizationSpec: The specification for personalization. Notice that if + // both ServingConfig.personalization_spec and + // SearchRequest.personalization_spec are set, + // SearchRequest.personalization_spec overrides + // ServingConfig.personalization_spec. + PersonalizationSpec *GoogleCloudDiscoveryengineV1alphaSearchRequestPersonalizationSpec `json:"personalizationSpec,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 + // joined 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"` + // RegionCode: The Unicode country/region code (CLDR) of a location, such as + // "US" and "419". For more information, see Standard fields + // (https://cloud.google.com/apis/design/standard_fields). If set, then results + // will be boosted based on the region_code provided. + RegionCode string `json:"regionCode,omitempty"` + // RelevanceThreshold: The relevance threshold of the search results. Default + // to Google defined threshold, leveraging a balance of precision and recall to + // deliver both highly accurate results and comprehensive coverage of relevant + // information. + // + // Possible values: + // "RELEVANCE_THRESHOLD_UNSPECIFIED" - Default value. In this case, server + // behavior defaults to Google defined threshold. + // "LOWEST" - Lowest relevance threshold. + // "LOW" - Low relevance threshold. + // "MEDIUM" - Medium relevance threshold. + // "HIGH" - High relevance threshold. + RelevanceThreshold string `json:"relevanceThreshold,omitempty"` + // SafeSearch: Whether to turn on safe search. This is only supported for + // website search. + SafeSearch bool `json:"safeSearch,omitempty"` + // SearchAsYouTypeSpec: Search as you type configuration. Only supported for + // the IndustryVertical.MEDIA vertical. + SearchAsYouTypeSpec *GoogleCloudDiscoveryengineV1alphaSearchRequestSearchAsYouTypeSpec `json:"searchAsYouTypeSpec,omitempty"` + // ServingConfig: Required. The resource name of the Search serving config, + // such as + // `projects/*/locations/global/collections/default_collection/engines/*/serving + // Configs/default_serving_config`, or + // `projects/*/locations/global/collections/default_collection/dataStores/defaul + // t_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"` + // Session: The session resource name. Optional. Session allows users to do + // multi-turn /search API calls or coordination between /search API calls and + // /answer API calls. Example #1 (multi-turn /search API calls): 1. Call + // /search API with the auto-session mode (see below). 2. Call /search API with + // the session ID generated in the first call. Here, the previous search query + // gets considered in query standing. I.e., if the first query is "How did + // Alphabet do in 2022?" and the current query is "How about 2023?", the + // current query will be interpreted as "How did Alphabet do in 2023?". Example + // #2 (coordination between /search API calls and /answer API calls): 1. Call + // /search API with the auto-session mode (see below). 2. Call /answer API with + // the session ID generated in the first call. Here, the answer generation + // happens in the context of the search results from the first search call. + // Auto-session mode: when `projects/.../sessions/-` is used, a new session + // gets automatically created. Otherwise, users can use the create-session API + // to create a session manually. Multi-turn Search feature is currently at + // private GA stage. Please use v1alpha or v1beta version instead before we + // launch this feature to public GA. Or ask for allowlisting through Google + // Support team. + Session string `json:"session,omitempty"` + // SessionSpec: Session specification. Can be used only when `session` is set. + SessionSpec *GoogleCloudDiscoveryengineV1alphaSearchRequestSessionSpec `json:"sessionSpec,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"` + // 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. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + 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. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1alphaSearchRequest) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSearchRequest + return gensupport.MarshalJSON(NoMethod(s), 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"` + // 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. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + 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. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1alphaSearchRequestBoostSpec) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSearchRequestBoostSpec + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaSearchRequestBoostSpecConditionBoostSpec: +// 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. Only one of + // the (condition, boost) combination or the boost_control_spec below are set. + // If both are set then the global boost is ignored and the more fine-grained + // boost_control_spec is applied. + Boost float64 `json:"boost,omitempty"` + // BoostControlSpec: Complex specification for custom ranking based on customer + // defined attribute value. + BoostControlSpec *GoogleCloudDiscoveryengineV1alphaSearchRequestBoostSpecConditionBoostSpecBoostControlSpec `json:"boostControlSpec,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": + // `(document_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. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + 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. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1alphaSearchRequestBoostSpecConditionBoostSpec) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSearchRequestBoostSpecConditionBoostSpec + return gensupport.MarshalJSON(NoMethod(s), 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 +} + +// GoogleCloudDiscoveryengineV1alphaSearchRequestBoostSpecConditionBoostSpecBoos +// tControlSpec: Specification for custom ranking based on customer specified +// attribute value. It provides more controls for customized ranking than the +// simple (condition, boost) combination above. +type GoogleCloudDiscoveryengineV1alphaSearchRequestBoostSpecConditionBoostSpecBoostControlSpec struct { + // AttributeType: The attribute type to be used to determine the boost amount. + // The attribute value can be derived from the field value of the specified + // field_name. In the case of numerical it is straightforward i.e. + // attribute_value = numerical_field_value. In the case of freshness however, + // attribute_value = (time.now() - datetime_field_value). + // + // Possible values: + // "ATTRIBUTE_TYPE_UNSPECIFIED" - Unspecified AttributeType. + // "NUMERICAL" - The value of the numerical field will be used to dynamically + // update the boost amount. In this case, the attribute_value (the x value) of + // the control point will be the actual value of the numerical field for which + // the boost_amount is specified. + // "FRESHNESS" - For the freshness use case the attribute value will be the + // duration between the current time and the date in the datetime field + // specified. The value must be formatted as an XSD `dayTimeDuration` value (a + // restricted subset of an ISO 8601 duration value). The pattern for this is: + // `nDnM]`. For example, `5D`, `3DT12H30M`, `T24H`. + AttributeType string `json:"attributeType,omitempty"` + // ControlPoints: The control points used to define the curve. The monotonic + // function (defined through the interpolation_type above) passes through the + // control points listed here. + ControlPoints []*GoogleCloudDiscoveryengineV1alphaSearchRequestBoostSpecConditionBoostSpecBoostControlSpecControlPoint `json:"controlPoints,omitempty"` + // FieldName: The name of the field whose value will be used to determine the + // boost amount. + FieldName string `json:"fieldName,omitempty"` + // InterpolationType: The interpolation type to be applied to connect the + // control points listed below. + // + // Possible values: + // "INTERPOLATION_TYPE_UNSPECIFIED" - Interpolation type is unspecified. In + // this case, it defaults to Linear. + // "LINEAR" - Piecewise linear interpolation will be applied. + InterpolationType string `json:"interpolationType,omitempty"` + // ForceSendFields is a list of field names (e.g. "AttributeType") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "AttributeType") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1alphaSearchRequestBoostSpecConditionBoostSpecBoostControlSpec) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSearchRequestBoostSpecConditionBoostSpecBoostControlSpec + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaSearchRequestBoostSpecConditionBoostSpecBoos +// tControlSpecControlPoint: The control points used to define the curve. The +// curve defined through these control points can only be monotonically +// increasing or decreasing(constant values are acceptable). +type GoogleCloudDiscoveryengineV1alphaSearchRequestBoostSpecConditionBoostSpecBoostControlSpecControlPoint struct { + // AttributeValue: Can be one of: 1. The numerical field value. 2. The duration + // spec for freshness: The value must be formatted as an XSD `dayTimeDuration` + // value (a restricted subset of an ISO 8601 duration value). The pattern for + // this is: `nDnM]`. + AttributeValue string `json:"attributeValue,omitempty"` + // BoostAmount: The value between -1 to 1 by which to boost the score if the + // attribute_value evaluates to the value specified above. + BoostAmount float64 `json:"boostAmount,omitempty"` + // ForceSendFields is a list of field names (e.g. "AttributeValue") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "AttributeValue") to include in + // API requests with the JSON null value. By default, fields with empty values + // are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1alphaSearchRequestBoostSpecConditionBoostSpecBoostControlSpecControlPoint) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSearchRequestBoostSpecConditionBoostSpecBoostControlSpecControlPoint + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +func (s *GoogleCloudDiscoveryengineV1alphaSearchRequestBoostSpecConditionBoostSpecBoostControlSpecControlPoint) UnmarshalJSON(data []byte) error { + type NoMethod GoogleCloudDiscoveryengineV1alphaSearchRequestBoostSpecConditionBoostSpecBoostControlSpecControlPoint + var s1 struct { + BoostAmount gensupport.JSONFloat64 `json:"boostAmount"` + *NoMethod + } + s1.NoMethod = (*NoMethod)(s) + if err := json.Unmarshal(data, &s1); err != nil { + return err + } + s.BoostAmount = float64(s1.BoostAmount) + return nil +} + +// GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpec: A +// specification for configuring the behavior of content search. +type GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpec struct { + // ChunkSpec: Specifies the chunk spec to be returned from the search response. + // Only available if the SearchRequest.ContentSearchSpec.search_result_mode is + // set to CHUNKS + ChunkSpec *GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecChunkSpec `json:"chunkSpec,omitempty"` + // ExtractiveContentSpec: If there is no extractive_content_spec provided, + // there will be no extractive answer in the search response. + ExtractiveContentSpec *GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecExtractiveContentSpec `json:"extractiveContentSpec,omitempty"` + // SearchResultMode: Specifies the search result mode. If unspecified, the + // search result mode defaults to `DOCUMENTS`. + // + // Possible values: + // "SEARCH_RESULT_MODE_UNSPECIFIED" - Default value. + // "DOCUMENTS" - Returns documents in the search result. + // "CHUNKS" - Returns chunks in the search result. Only available if the + // DocumentProcessingConfig.chunking_config is specified. + SearchResultMode string `json:"searchResultMode,omitempty"` + // SnippetSpec: If `snippetSpec` is not specified, snippets are not included in + // the search response. + SnippetSpec *GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSnippetSpec `json:"snippetSpec,omitempty"` + // 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. "ChunkSpec") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "ChunkSpec") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpec) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpec + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecChunkSpec: +// Specifies the chunk spec to be returned from the search response. Only +// available if the SearchRequest.ContentSearchSpec.search_result_mode is set +// to CHUNKS +type GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecChunkSpec struct { + // NumNextChunks: The number of next chunks to be returned of the current + // chunk. The maximum allowed value is 3. If not specified, no next chunks will + // be returned. + NumNextChunks int64 `json:"numNextChunks,omitempty"` + // NumPreviousChunks: The number of previous chunks to be returned of the + // current chunk. The maximum allowed value is 3. If not specified, no previous + // chunks will be returned. + NumPreviousChunks int64 `json:"numPreviousChunks,omitempty"` + // ForceSendFields is a list of field names (e.g. "NumNextChunks") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "NumNextChunks") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecChunkSpec) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecChunkSpec + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecExtractiveCont +// entSpec: 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"` + // 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"` + // ReturnExtractiveSegmentScore: Specifies whether to return the confidence + // score from the extractive segments in each search result. This feature is + // available only for new or allowlisted data stores. To allowlist your data + // store, contact your Customer Engineer. The default value is `false`. + ReturnExtractiveSegmentScore bool `json:"returnExtractiveSegmentScore,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. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + 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. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecExtractiveContentSpec) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecExtractiveContentSpec + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSnippetSpec: +// 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"` + // 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. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + 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. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSnippetSpec) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSnippetSpec + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSummarySpec: +// 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"` + // IgnoreJailBreakingQuery: Optional. Specifies whether to filter out + // jail-breaking queries. The default value is `false`. Google employs + // search-query classification to detect jail-breaking queries. No summary is + // returned if the search query is classified as a jail-breaking query. A user + // might add instructions to the query to change the tone, style, language, + // content of the answer, or ask the model to act as a different entity, e.g. + // "Reply in the tone of a competing company's CEO". If this field is set to + // `true`, we skip generating summaries for jail-breaking queries and return + // fallback messages instead. + IgnoreJailBreakingQuery bool `json:"ignoreJailBreakingQuery,omitempty"` + // IgnoreLowRelevantContent: Specifies whether to filter out queries that have + // low relevance. The default value is `false`. If this field is set to + // `false`, all search results are used regardless of relevance to generate + // answers. If set to `true`, only queries with high relevance search results + // will generate answers. + IgnoreLowRelevantContent bool `json:"ignoreLowRelevantContent,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 *GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSummarySpecModelPromptSpec `json:"modelPromptSpec,omitempty"` + // ModelSpec: If specified, the spec will be used to modify the model + // specification provided to the LLM. + ModelSpec *GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSummarySpecModelSpec `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 10 results for + // documents mode, or 50 for chunks mode, can be used to generate a summary. + // The chunks mode is used when + // SearchRequest.ContentSearchSpec.search_result_mode is set to CHUNKS. + SummaryResultCount int64 `json:"summaryResultCount,omitempty"` + // UseSemanticChunks: If true, answer will be generated from most relevant + // chunks from top search results. This feature will improve summary quality. + // Note that with this feature enabled, not all top search results will be + // referenced and included in the reference list, so the citation source index + // only points to the search results listed in the reference list. + UseSemanticChunks bool `json:"useSemanticChunks,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. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + 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. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSummarySpec) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSummarySpec + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSummarySpecMod +// elPromptSpec: 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. "Preamble") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + 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. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSummarySpecModelPromptSpec) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSummarySpecModelPromptSpec + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSummarySpecMod +// elSpec: 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 model. For more information, see Answer + // generation model versions and lifecycle + // (https://cloud.google.com/generative-ai-app-builder/docs/answer-generation-models). + // * `preview`: string. (Public preview) Uses a preview model. For more + // information, see Answer generation model versions and lifecycle + // (https://cloud.google.com/generative-ai-app-builder/docs/answer-generation-models). + Version string `json:"version,omitempty"` + // ForceSendFields is a list of field names (e.g. "Version") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "Version") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSummarySpecModelSpec) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSummarySpecModelSpec + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaSearchRequestDataStoreSpec: A struct to +// define data stores to filter on in a search call and configurations for +// those data stores. Otherwise, an `INVALID_ARGUMENT` error is returned. +type GoogleCloudDiscoveryengineV1alphaSearchRequestDataStoreSpec struct { + // BoostSpec: Optional. Boost specification to boost certain documents. For + // more information on boosting, see Boosting + // (https://cloud.google.com/generative-ai-app-builder/docs/boost-search-results) + BoostSpec *GoogleCloudDiscoveryengineV1alphaSearchRequestBoostSpec `json:"boostSpec,omitempty"` + // DataStore: Required. Full resource name of DataStore, such as + // `projects/{project}/locations/{location}/collections/{collection_id}/dataStor + // es/{data_store_id}`. + DataStore string `json:"dataStore,omitempty"` + // Filter: Optional. Filter specification to filter documents in the data store + // specified by data_store field. For more information on filtering, see + // Filtering + // (https://cloud.google.com/generative-ai-app-builder/docs/filter-search-metadata) + Filter string `json:"filter,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. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + 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. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1alphaSearchRequestDataStoreSpec) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSearchRequestDataStoreSpec + return gensupport.MarshalJSON(NoMethod(s), 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"` + // 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. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + 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. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1alphaSearchRequestEmbeddingSpec) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSearchRequestEmbeddingSpec + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaSearchRequestEmbeddingSpecEmbeddingVector: +// Embedding vector. +type GoogleCloudDiscoveryengineV1alphaSearchRequestEmbeddingSpecEmbeddingVector 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. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + 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. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1alphaSearchRequestEmbeddingSpecEmbeddingVector) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSearchRequestEmbeddingSpecEmbeddingVector + return gensupport.MarshalJSON(NoMethod(s), 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 facet values that are returned for this facet. If + // unspecified, defaults to 20. The maximum allowed value is 300. Values above + // 300 are coerced to 300. For aggregation in healthcare search, when the + // [FacetKey.key] is "healthcare_aggregation_key", the limit will be overridden + // to 10,000 internally, regardless of the value set here. 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. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + 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. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1alphaSearchRequestFacetSpec) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSearchRequestFacetSpec + return gensupport.MarshalJSON(NoMethod(s), 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 contain 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"` + // 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. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + 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. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1alphaSearchRequestFacetSpecFacetKey) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSearchRequestFacetSpecFacetKey + return gensupport.MarshalJSON(NoMethod(s), 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"` + // 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. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + 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. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1alphaSearchRequestImageQuery) MarshalJSON() ([]byte, error) { type NoMethod GoogleCloudDiscoveryengineV1alphaSearchRequestImageQuery return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaSearchRequestNaturalLanguageQueryUnderstandi -// ngSpec: Specification to enable natural language understanding capabilities -// for search requests. -type GoogleCloudDiscoveryengineV1alphaSearchRequestNaturalLanguageQueryUnderstandingSpec struct { - // FilterExtractionCondition: The condition under which filter extraction - // should occur. Default to Condition.DISABLED. - // - // Possible values: - // "CONDITION_UNSPECIFIED" - Server behavior defaults to Condition.DISABLED. - // "DISABLED" - Disables NL filter extraction. - // "ENABLED" - Enables NL filter extraction. - FilterExtractionCondition string `json:"filterExtractionCondition,omitempty"` - // GeoSearchQueryDetectionFieldNames: Field names used for location-based - // filtering, where geolocation filters are detected in natural language search - // queries. Only valid when the FilterExtractionCondition is set to `ENABLED`. - // If this field is set, it overrides the field names set in - // ServingConfig.geo_search_query_detection_field_names. - GeoSearchQueryDetectionFieldNames []string `json:"geoSearchQueryDetectionFieldNames,omitempty"` - // ForceSendFields is a list of field names (e.g. "FilterExtractionCondition") - // to unconditionally include in API requests. By default, fields with empty or +// GoogleCloudDiscoveryengineV1alphaSearchRequestNaturalLanguageQueryUnderstandi +// ngSpec: Specification to enable natural language understanding capabilities +// for search requests. +type GoogleCloudDiscoveryengineV1alphaSearchRequestNaturalLanguageQueryUnderstandingSpec struct { + // FilterExtractionCondition: The condition under which filter extraction + // should occur. Default to Condition.DISABLED. + // + // Possible values: + // "CONDITION_UNSPECIFIED" - Server behavior defaults to Condition.DISABLED. + // "DISABLED" - Disables NL filter extraction. + // "ENABLED" - Enables NL filter extraction. + FilterExtractionCondition string `json:"filterExtractionCondition,omitempty"` + // GeoSearchQueryDetectionFieldNames: Field names used for location-based + // filtering, where geolocation filters are detected in natural language search + // queries. Only valid when the FilterExtractionCondition is set to `ENABLED`. + // If this field is set, it overrides the field names set in + // ServingConfig.geo_search_query_detection_field_names. + GeoSearchQueryDetectionFieldNames []string `json:"geoSearchQueryDetectionFieldNames,omitempty"` + // ForceSendFields is a list of field names (e.g. "FilterExtractionCondition") + // to unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "FilterExtractionCondition") to + // include in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1alphaSearchRequestNaturalLanguageQueryUnderstandingSpec) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSearchRequestNaturalLanguageQueryUnderstandingSpec + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaSearchRequestPersonalizationSpec: The +// specification for personalization. +type GoogleCloudDiscoveryengineV1alphaSearchRequestPersonalizationSpec struct { + // Mode: The personalization mode of the search request. Defaults to Mode.AUTO. + // + // Possible values: + // "MODE_UNSPECIFIED" - Default value. In this case, server behavior defaults + // to Mode.AUTO. + // "AUTO" - Personalization is enabled if data quality requirements are met. + // "DISABLED" - Disable personalization. + 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. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + 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. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1alphaSearchRequestPersonalizationSpec) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSearchRequestPersonalizationSpec + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// 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"` + // 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. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + 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. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1alphaSearchRequestQueryExpansionSpec) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSearchRequestQueryExpansionSpec + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaSearchRequestSearchAsYouTypeSpec: +// Specification for search as you type in search requests. +type GoogleCloudDiscoveryengineV1alphaSearchRequestSearchAsYouTypeSpec struct { + // Condition: The condition under which search as you type should occur. + // Default to Condition.DISABLED. + // + // Possible values: + // "CONDITION_UNSPECIFIED" - Server behavior defaults to Condition.DISABLED. + // "DISABLED" - Disables Search As You Type. + // "ENABLED" - Enables Search As You Type. + Condition string `json:"condition,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. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + 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. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1alphaSearchRequestSearchAsYouTypeSpec) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSearchRequestSearchAsYouTypeSpec + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaSearchRequestSessionSpec: Session +// specification. Multi-turn Search feature is currently at private GA stage. +// Please use v1alpha or v1beta version instead before we launch this feature +// to public GA. Or ask for allowlisting through Google Support team. +type GoogleCloudDiscoveryengineV1alphaSearchRequestSessionSpec struct { + // QueryId: If set, the search result gets stored to the "turn" specified by + // this query ID. Example: Let's say the session looks like this: session { + // name: ".../sessions/xxx" turns { query { text: "What is foo?" query_id: + // ".../questions/yyy" } answer: "Foo is ..." } turns { query { text: "How + // about bar then?" query_id: ".../questions/zzz" } } } The user can call + // /search API with a request like this: session: ".../sessions/xxx" + // session_spec { query_id: ".../questions/zzz" } Then, the API stores the + // search result, associated with the last turn. The stored search result can + // be used by a subsequent /answer API call (with the session ID and the query + // ID specified). Also, it is possible to call /search and /answer in parallel + // with the same session ID & query ID. + QueryId string `json:"queryId,omitempty"` + // SearchResultPersistenceCount: The number of top search results to persist. + // The persisted search results can be used for the subsequent /answer api + // call. This field is simliar to the `summary_result_count` field in + // SearchRequest.ContentSearchSpec.SummarySpec.summary_result_count. At most 10 + // results for documents mode, or 50 for chunks mode. + SearchResultPersistenceCount int64 `json:"searchResultPersistenceCount,omitempty"` + // ForceSendFields is a list of field names (e.g. "QueryId") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "QueryId") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1alphaSearchRequestSessionSpec) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSearchRequestSessionSpec + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaSearchRequestSpellCorrectionSpec: The +// specification for query spell correction. +type GoogleCloudDiscoveryengineV1alphaSearchRequestSpellCorrectionSpec struct { + // Mode: The mode under which spell correction replaces the original search + // query. Defaults to Mode.AUTO. + // + // Possible values: + // "MODE_UNSPECIFIED" - Unspecified spell correction mode. In this case, + // server behavior defaults to Mode.AUTO. + // "SUGGESTION_ONLY" - Search API tries to find a spelling suggestion. If a + // suggestion is found, it is put in the SearchResponse.corrected_query. The + // spelling suggestion won't 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. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + 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. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1alphaSearchRequestSpellCorrectionSpec) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSearchRequestSpellCorrectionSpec + return gensupport.MarshalJSON(NoMethod(s), 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. This also helps to identify a + // request during the customer support scenarios. + 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"` + // NaturalLanguageQueryUnderstandingInfo: Natural language query understanding + // information for the returned results. + NaturalLanguageQueryUnderstandingInfo *GoogleCloudDiscoveryengineV1alphaSearchResponseNaturalLanguageQueryUnderstandingInfo `json:"naturalLanguageQueryUnderstandingInfo,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"` + // OneBoxResults: A list of One Box results. There can be multiple One Box + // results of different types. + OneBoxResults []*GoogleCloudDiscoveryengineV1alphaSearchResponseOneBoxResult `json:"oneBoxResults,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"` + // SearchLinkPromotions: Promotions for site search. + SearchLinkPromotions []*GoogleCloudDiscoveryengineV1alphaSearchLinkPromotion `json:"searchLinkPromotions,omitempty"` + // SessionInfo: Session information. Only set if SearchRequest.session is + // provided. See its description for more details. + SessionInfo *GoogleCloudDiscoveryengineV1alphaSearchResponseSessionInfo `json:"sessionInfo,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. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + 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. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1alphaSearchResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSearchResponse + return gensupport.MarshalJSON(NoMethod(s), 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. For example, "colors" or "price". It + // matches SearchRequest.FacetSpec.FacetKey.key. + Key string `json:"key,omitempty"` + // Values: The facet values for this field. + Values []*GoogleCloudDiscoveryengineV1alphaSearchResponseFacetFacetValue `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. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + 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. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1alphaSearchResponseFacet) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSearchResponseFacet + return gensupport.MarshalJSON(NoMethod(s), 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"` + // 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. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "Count") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1alphaSearchResponseFacetFacetValue) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSearchResponseFacetFacetValue + return gensupport.MarshalJSON(NoMethod(s), 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"` + // 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. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + 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. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1alphaSearchResponseGeoSearchDebugInfo) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSearchResponseGeoSearchDebugInfo + return gensupport.MarshalJSON(NoMethod(s), 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"` + // 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. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + 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. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1alphaSearchResponseGuidedSearchResult) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSearchResponseGuidedSearchResult + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaSearchResponseGuidedSearchResultRefinementAt +// tribute: Useful attribute for search result refinements. +type GoogleCloudDiscoveryengineV1alphaSearchResponseGuidedSearchResultRefinementAttribute struct { + // AttributeKey: Attribute key used to refine the results. For example, + // "movie_type". + AttributeKey string `json:"attributeKey,omitempty"` + // AttributeValue: Attribute value used to refine the results. For example, + // "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. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + 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. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1alphaSearchResponseGuidedSearchResultRefinementAttribute) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSearchResponseGuidedSearchResultRefinementAttribute + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaSearchResponseNaturalLanguageQueryUnderstand +// ingInfo: Information describing what natural language understanding was done +// on the input query. +type GoogleCloudDiscoveryengineV1alphaSearchResponseNaturalLanguageQueryUnderstandingInfo struct { + // ExtractedFilters: The filters that were extracted from the input query. + ExtractedFilters string `json:"extractedFilters,omitempty"` + // RewrittenQuery: Rewritten input query minus the extracted filters. + RewrittenQuery string `json:"rewrittenQuery,omitempty"` + // StructuredExtractedFilter: The filters that were extracted from the input + // query represented in a structured form. + StructuredExtractedFilter *GoogleCloudDiscoveryengineV1alphaSearchResponseNaturalLanguageQueryUnderstandingInfoStructuredExtractedFilter `json:"structuredExtractedFilter,omitempty"` + // ForceSendFields is a list of field names (e.g. "ExtractedFilters") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "ExtractedFilters") to include in + // API requests with the JSON null value. By default, fields with empty values + // are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1alphaSearchResponseNaturalLanguageQueryUnderstandingInfo) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSearchResponseNaturalLanguageQueryUnderstandingInfo + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaSearchResponseNaturalLanguageQueryUnderstand +// ingInfoStructuredExtractedFilter: The filters that were extracted from the +// input query represented in a structured form. +type GoogleCloudDiscoveryengineV1alphaSearchResponseNaturalLanguageQueryUnderstandingInfoStructuredExtractedFilter struct { + // Expression: The expression denoting the filter that was extracted from the + // input query in a structured form. It can be a simple expression denoting a + // single string, numerical or geolocation constraint or a compound expression + // which is a combination of multiple expressions connected using logical (OR + // and AND) operators. + Expression *GoogleCloudDiscoveryengineV1alphaSearchResponseNaturalLanguageQueryUnderstandingInfoStructuredExtractedFilterExpression `json:"expression,omitempty"` + // ForceSendFields is a list of field names (e.g. "Expression") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "Expression") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1alphaSearchResponseNaturalLanguageQueryUnderstandingInfoStructuredExtractedFilter) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSearchResponseNaturalLanguageQueryUnderstandingInfoStructuredExtractedFilter + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaSearchResponseNaturalLanguageQueryUnderstand +// ingInfoStructuredExtractedFilterAndExpression: Logical `And` operator. +type GoogleCloudDiscoveryengineV1alphaSearchResponseNaturalLanguageQueryUnderstandingInfoStructuredExtractedFilterAndExpression struct { + // Expressions: The expressions that were ANDed together. + Expressions []*GoogleCloudDiscoveryengineV1alphaSearchResponseNaturalLanguageQueryUnderstandingInfoStructuredExtractedFilterExpression `json:"expressions,omitempty"` + // ForceSendFields is a list of field names (e.g. "Expressions") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "Expressions") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1alphaSearchResponseNaturalLanguageQueryUnderstandingInfoStructuredExtractedFilterAndExpression) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSearchResponseNaturalLanguageQueryUnderstandingInfoStructuredExtractedFilterAndExpression + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaSearchResponseNaturalLanguageQueryUnderstand +// ingInfoStructuredExtractedFilterExpression: The expression denoting the +// filter that was extracted from the input query. +type GoogleCloudDiscoveryengineV1alphaSearchResponseNaturalLanguageQueryUnderstandingInfoStructuredExtractedFilterExpression struct { + // AndExpr: Logical "And" compound operator connecting multiple expressions. + AndExpr *GoogleCloudDiscoveryengineV1alphaSearchResponseNaturalLanguageQueryUnderstandingInfoStructuredExtractedFilterAndExpression `json:"andExpr,omitempty"` + // GeolocationConstraint: Geolocation constraint expression. + GeolocationConstraint *GoogleCloudDiscoveryengineV1alphaSearchResponseNaturalLanguageQueryUnderstandingInfoStructuredExtractedFilterGeolocationConstraint `json:"geolocationConstraint,omitempty"` + // NumberConstraint: Numerical constraint expression. + NumberConstraint *GoogleCloudDiscoveryengineV1alphaSearchResponseNaturalLanguageQueryUnderstandingInfoStructuredExtractedFilterNumberConstraint `json:"numberConstraint,omitempty"` + // OrExpr: Logical "Or" compound operator connecting multiple expressions. + OrExpr *GoogleCloudDiscoveryengineV1alphaSearchResponseNaturalLanguageQueryUnderstandingInfoStructuredExtractedFilterOrExpression `json:"orExpr,omitempty"` + // StringConstraint: String constraint expression. + StringConstraint *GoogleCloudDiscoveryengineV1alphaSearchResponseNaturalLanguageQueryUnderstandingInfoStructuredExtractedFilterStringConstraint `json:"stringConstraint,omitempty"` + // ForceSendFields is a list of field names (e.g. "AndExpr") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "AndExpr") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1alphaSearchResponseNaturalLanguageQueryUnderstandingInfoStructuredExtractedFilterExpression) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSearchResponseNaturalLanguageQueryUnderstandingInfoStructuredExtractedFilterExpression + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaSearchResponseNaturalLanguageQueryUnderstand +// ingInfoStructuredExtractedFilterGeolocationConstraint: Constraint of a +// geolocation field. Name of the geolocation field as defined in the schema. +type GoogleCloudDiscoveryengineV1alphaSearchResponseNaturalLanguageQueryUnderstandingInfoStructuredExtractedFilterGeolocationConstraint struct { + // Address: The reference address that was inferred from the input query. The + // proximity of the reference address to the geolocation field will be used to + // filter the results. + Address string `json:"address,omitempty"` + // FieldName: The name of the geolocation field as defined in the schema. + FieldName string `json:"fieldName,omitempty"` + // Latitude: The latitude of the geolocation inferred from the input query. + Latitude float64 `json:"latitude,omitempty"` + // Longitude: The longitude of the geolocation inferred from the input query. + Longitude float64 `json:"longitude,omitempty"` + // RadiusInMeters: The radius in meters around the address. The record is + // returned if the location of the geolocation field is within the radius. + RadiusInMeters float64 `json:"radiusInMeters,omitempty"` + // ForceSendFields is a list of field names (e.g. "Address") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "Address") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1alphaSearchResponseNaturalLanguageQueryUnderstandingInfoStructuredExtractedFilterGeolocationConstraint) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSearchResponseNaturalLanguageQueryUnderstandingInfoStructuredExtractedFilterGeolocationConstraint + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +func (s *GoogleCloudDiscoveryengineV1alphaSearchResponseNaturalLanguageQueryUnderstandingInfoStructuredExtractedFilterGeolocationConstraint) UnmarshalJSON(data []byte) error { + type NoMethod GoogleCloudDiscoveryengineV1alphaSearchResponseNaturalLanguageQueryUnderstandingInfoStructuredExtractedFilterGeolocationConstraint + var s1 struct { + Latitude gensupport.JSONFloat64 `json:"latitude"` + Longitude gensupport.JSONFloat64 `json:"longitude"` + RadiusInMeters gensupport.JSONFloat64 `json:"radiusInMeters"` + *NoMethod + } + s1.NoMethod = (*NoMethod)(s) + if err := json.Unmarshal(data, &s1); err != nil { + return err + } + s.Latitude = float64(s1.Latitude) + s.Longitude = float64(s1.Longitude) + s.RadiusInMeters = float64(s1.RadiusInMeters) + return nil +} + +// GoogleCloudDiscoveryengineV1alphaSearchResponseNaturalLanguageQueryUnderstand +// ingInfoStructuredExtractedFilterNumberConstraint: Constraint expression of a +// number field. Example: price < 100. +type GoogleCloudDiscoveryengineV1alphaSearchResponseNaturalLanguageQueryUnderstandingInfoStructuredExtractedFilterNumberConstraint struct { + // Comparison: The comparison operation performed between the field value and + // the value specified in the constraint. + // + // Possible values: + // "COMPARISON_UNSPECIFIED" - Undefined comparison operator. + // "EQUALS" - Denotes equality `=` operator. + // "LESS_THAN_EQUALS" - Denotes less than or equal to `<=` operator. + // "LESS_THAN" - Denotes less than `<` operator. + // "GREATER_THAN_EQUALS" - Denotes greater than or equal to `>=` operator. + // "GREATER_THAN" - Denotes greater than `>` operator. + Comparison string `json:"comparison,omitempty"` + // FieldName: Name of the numerical field as defined in the schema. + FieldName string `json:"fieldName,omitempty"` + // QuerySegment: Identifies the keywords within the search query that match a + // filter. + QuerySegment string `json:"querySegment,omitempty"` + // Value: The value specified in the numerical constraint. + Value float64 `json:"value,omitempty"` + // ForceSendFields is a list of field names (e.g. "Comparison") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "Comparison") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1alphaSearchResponseNaturalLanguageQueryUnderstandingInfoStructuredExtractedFilterNumberConstraint) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSearchResponseNaturalLanguageQueryUnderstandingInfoStructuredExtractedFilterNumberConstraint + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +func (s *GoogleCloudDiscoveryengineV1alphaSearchResponseNaturalLanguageQueryUnderstandingInfoStructuredExtractedFilterNumberConstraint) UnmarshalJSON(data []byte) error { + type NoMethod GoogleCloudDiscoveryengineV1alphaSearchResponseNaturalLanguageQueryUnderstandingInfoStructuredExtractedFilterNumberConstraint + var s1 struct { + Value gensupport.JSONFloat64 `json:"value"` + *NoMethod + } + s1.NoMethod = (*NoMethod)(s) + if err := json.Unmarshal(data, &s1); err != nil { + return err + } + s.Value = float64(s1.Value) + return nil +} + +// GoogleCloudDiscoveryengineV1alphaSearchResponseNaturalLanguageQueryUnderstand +// ingInfoStructuredExtractedFilterOrExpression: Logical `Or` operator. +type GoogleCloudDiscoveryengineV1alphaSearchResponseNaturalLanguageQueryUnderstandingInfoStructuredExtractedFilterOrExpression struct { + // Expressions: The expressions that were ORed together. + Expressions []*GoogleCloudDiscoveryengineV1alphaSearchResponseNaturalLanguageQueryUnderstandingInfoStructuredExtractedFilterExpression `json:"expressions,omitempty"` + // ForceSendFields is a list of field names (e.g. "Expressions") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "Expressions") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1alphaSearchResponseNaturalLanguageQueryUnderstandingInfoStructuredExtractedFilterOrExpression) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSearchResponseNaturalLanguageQueryUnderstandingInfoStructuredExtractedFilterOrExpression + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaSearchResponseNaturalLanguageQueryUnderstand +// ingInfoStructuredExtractedFilterStringConstraint: Constraint expression of a +// string field. +type GoogleCloudDiscoveryengineV1alphaSearchResponseNaturalLanguageQueryUnderstandingInfoStructuredExtractedFilterStringConstraint struct { + // FieldName: Name of the string field as defined in the schema. + FieldName string `json:"fieldName,omitempty"` + // QuerySegment: Identifies the keywords within the search query that match a + // filter. + QuerySegment string `json:"querySegment,omitempty"` + // Values: Values of the string field. The record will only be returned if the + // field value matches one of the values specified here. + Values []string `json:"values,omitempty"` + // ForceSendFields is a list of field names (e.g. "FieldName") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "FieldName") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1alphaSearchResponseNaturalLanguageQueryUnderstandingInfoStructuredExtractedFilterStringConstraint) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSearchResponseNaturalLanguageQueryUnderstandingInfoStructuredExtractedFilterStringConstraint + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaSearchResponseOneBoxResult: OneBoxResult is +// a holder for all results of specific type that we want to display in UI +// differently. +type GoogleCloudDiscoveryengineV1alphaSearchResponseOneBoxResult struct { + // OneBoxType: The type of One Box result. + // + // Possible values: + // "ONE_BOX_TYPE_UNSPECIFIED" - Default value. Should not be used. + // "PEOPLE" - One Box result contains people results. + // "ORGANIZATION" - One Box result contains organization results. + // "SLACK" - One Box result contains slack results. + // "KNOWLEDGE_GRAPH" - One Box result contains Knowledge Graph search + // responses. + OneBoxType string `json:"oneBoxType,omitempty"` + // SearchResults: The search results for this One Box. + SearchResults []*GoogleCloudDiscoveryengineV1alphaSearchResponseSearchResult `json:"searchResults,omitempty"` + // ForceSendFields is a list of field names (e.g. "OneBoxType") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "OneBoxType") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1alphaSearchResponseOneBoxResult) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSearchResponseOneBoxResult + return gensupport.MarshalJSON(NoMethod(s), 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"` + // 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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "FilterExtractionCondition") to - // include in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. See + // NullFields is a list of field names (e.g. "ExpandedQuery") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaSearchRequestNaturalLanguageQueryUnderstandingSpec) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSearchRequestNaturalLanguageQueryUnderstandingSpec +func (s GoogleCloudDiscoveryengineV1alphaSearchResponseQueryExpansionInfo) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSearchResponseQueryExpansionInfo return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaSearchRequestPersonalizationSpec: The -// specification for personalization. -type GoogleCloudDiscoveryengineV1alphaSearchRequestPersonalizationSpec struct { - // Mode: The personalization mode of the search request. Defaults to Mode.AUTO. +// GoogleCloudDiscoveryengineV1alphaSearchResponseSearchResult: Represents the +// search results. +type GoogleCloudDiscoveryengineV1alphaSearchResponseSearchResult struct { + // Chunk: The chunk data in the search response if the + // SearchRequest.ContentSearchSpec.search_result_mode is set to CHUNKS. + Chunk *GoogleCloudDiscoveryengineV1alphaChunk `json:"chunk,omitempty"` + // 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"` + // ModelScores: Google provided available scores. + ModelScores map[string]GoogleCloudDiscoveryengineV1alphaDoubleList `json:"modelScores,omitempty"` + // ForceSendFields is a list of field names (e.g. "Chunk") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "Chunk") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1alphaSearchResponseSearchResult) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSearchResponseSearchResult + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaSearchResponseSessionInfo: Information +// about the session. +type GoogleCloudDiscoveryengineV1alphaSearchResponseSessionInfo struct { + // Name: Name of the session. If the auto-session mode is used (when + // SearchRequest.session ends with "-"), this field holds the newly generated + // session name. + Name string `json:"name,omitempty"` + // QueryId: Query ID that corresponds to this search API call. One session can + // have multiple turns, each with a unique query ID. By specifying the session + // name and this query ID in the Answer API call, the answer generation happens + // in the context of the search results from this search call. + QueryId string `json:"queryId,omitempty"` + // ForceSendFields is a list of field names (e.g. "Name") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "Name") to include in API requests + // with the JSON null value. By default, fields with empty values are omitted + // from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1alphaSearchResponseSessionInfo) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSearchResponseSessionInfo + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaSearchResponseSummary: Summary of the top N +// search results 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"` + // SummarySkippedReasons: Additional summary-skipped reasons. This provides the + // reason for ignored cases. If nothing is skipped, this field is not set. // // Possible values: - // "MODE_UNSPECIFIED" - Default value. In this case, server behavior defaults - // to Mode.AUTO. - // "AUTO" - Personalization is enabled if data quality requirements are met. - // "DISABLED" - Disable personalization. - 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 + // "SUMMARY_SKIPPED_REASON_UNSPECIFIED" - Default value. The summary skipped + // reason is not specified. + // "ADVERSARIAL_QUERY_IGNORED" - The adversarial query ignored case. Only + // used when SummarySpec.ignore_adversarial_query is set to `true`. + // "NON_SUMMARY_SEEKING_QUERY_IGNORED" - The non-summary seeking query + // ignored case. Google skips the summary if the query is chit chat. Only used + // when SummarySpec.ignore_non_summary_seeking_query is set to `true`. + // "OUT_OF_DOMAIN_QUERY_IGNORED" - The out-of-domain query ignored case. + // Google skips the summary if there are no high-relevance search results. For + // example, the data store contains facts about company A but the user query is + // 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. + // "NO_RELEVANT_CONTENT" - The no relevant content case. Google skips the + // summary if there is no relevant content in the retrieved search results. + // "JAIL_BREAKING_QUERY_IGNORED" - The jail-breaking query ignored case. For + // example, "Reply in the tone of a competing company's CEO". Only used when + // [SearchRequest.ContentSearchSpec.SummarySpec.ignore_jail_breaking_query] is + // set to `true`. + // "CUSTOMER_POLICY_VIOLATION" - The customer policy violation case. Google + // skips the summary if there is a customer policy violation detected. The + // policy is defined by the customer. + // "NON_SUMMARY_SEEKING_QUERY_IGNORED_V2" - The non-answer seeking query + // ignored case. Google skips the summary if the query doesn't have clear + // intent. Only used when + // [SearchRequest.ContentSearchSpec.SummarySpec.ignore_non_answer_seeking_query] + // is set to `true`. + SummarySkippedReasons []string `json:"summarySkippedReasons,omitempty"` + // SummaryText: The summary content. + SummaryText string `json:"summaryText,omitempty"` + // SummaryWithMetadata: Summary with metadata information. + 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. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + 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. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1alphaSearchResponseSummary) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSearchResponseSummary + return gensupport.MarshalJSON(NoMethod(s), 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"` + // Sources: Citation sources for the attributed segment. + Sources []*GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryCitationSource `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. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + 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. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryCitation) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryCitation + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryCitationMetadata: +// Citation metadata. +type GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryCitationMetadata struct { + // Citations: Citations for segments. + Citations []*GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryCitation `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. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + 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. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryCitationMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryCitationMetadata + return gensupport.MarshalJSON(NoMethod(s), 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"` + // 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. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + 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. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryCitationSource) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryCitationSource + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryReference: Document +// reference. +type GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryReference struct { + // ChunkContents: List of cited chunk contents derived from document content. + ChunkContents []*GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryReferenceChunkContent `json:"chunkContents,omitempty"` + // Document: Required. Document.name of the document. Full resource name of the + // referenced document, in the format + // `projects/*/locations/*/collections/*/dataStores/*/branches/*/documents/*`. + 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. "ChunkContents") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. 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. See + // NullFields is a list of field names (e.g. "ChunkContents") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaSearchRequestPersonalizationSpec) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSearchRequestPersonalizationSpec +func (s GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryReference) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryReference return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// 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"` - // 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. See +// GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryReferenceChunkContent: +// Chunk content. +type GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryReferenceChunkContent struct { + // Content: Chunk textual content. + Content string `json:"content,omitempty"` + // PageIdentifier: Page identifier. + PageIdentifier string `json:"pageIdentifier,omitempty"` + // 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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Condition") to include in API + // 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. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaSearchRequestQueryExpansionSpec) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSearchRequestQueryExpansionSpec +func (s GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryReferenceChunkContent) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryReferenceChunkContent return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaSearchRequestSearchAsYouTypeSpec: -// Specification for search as you type in search requests. -type GoogleCloudDiscoveryengineV1alphaSearchRequestSearchAsYouTypeSpec struct { - // Condition: The condition under which search as you type should occur. - // Default to Condition.DISABLED. - // - // Possible values: - // "CONDITION_UNSPECIFIED" - Server behavior defaults to Condition.DISABLED. - // "DISABLED" - Disables Search As You Type. - // "ENABLED" - Enables Search As You Type. - Condition string `json:"condition,omitempty"` - // ForceSendFields is a list of field names (e.g. "Condition") to +// 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"` + // 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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Condition") to include in API + // 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. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaSearchRequestSearchAsYouTypeSpec) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSearchRequestSearchAsYouTypeSpec +func (s GoogleCloudDiscoveryengineV1alphaSearchResponseSummarySafetyAttributes) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSearchResponseSummarySafetyAttributes return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaSearchRequestSessionSpec: Session -// specification. Multi-turn Search feature is currently at private GA stage. -// Please use v1alpha or v1beta version instead before we launch this feature -// to public GA. Or ask for allowlisting through Google Support team. -type GoogleCloudDiscoveryengineV1alphaSearchRequestSessionSpec struct { - // QueryId: If set, the search result gets stored to the "turn" specified by - // this query ID. Example: Let's say the session looks like this: session { - // name: ".../sessions/xxx" turns { query { text: "What is foo?" query_id: - // ".../questions/yyy" } answer: "Foo is ..." } turns { query { text: "How - // about bar then?" query_id: ".../questions/zzz" } } } The user can call - // /search API with a request like this: session: ".../sessions/xxx" - // session_spec { query_id: ".../questions/zzz" } Then, the API stores the - // search result, associated with the last turn. The stored search result can - // be used by a subsequent /answer API call (with the session ID and the query - // ID specified). Also, it is possible to call /search and /answer in parallel - // with the same session ID & query ID. - QueryId string `json:"queryId,omitempty"` - // SearchResultPersistenceCount: The number of top search results to persist. - // The persisted search results can be used for the subsequent /answer api - // call. This field is simliar to the `summary_result_count` field in - // SearchRequest.ContentSearchSpec.SummarySpec.summary_result_count. At most 10 - // results for documents mode, or 50 for chunks mode. - SearchResultPersistenceCount int64 `json:"searchResultPersistenceCount,omitempty"` - // ForceSendFields is a list of field names (e.g. "QueryId") to unconditionally - // include in API requests. By default, fields with empty or default values are - // omitted from API requests. See +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 +} + +// GoogleCloudDiscoveryengineV1alphaSearchResponseSummarySummaryWithMetadata: +// Summary with metadata information. +type GoogleCloudDiscoveryengineV1alphaSearchResponseSummarySummaryWithMetadata struct { + // CitationMetadata: Citation metadata for given summary. + CitationMetadata *GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryCitationMetadata `json:"citationMetadata,omitempty"` + // 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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "QueryId") to include in API - // requests with the JSON null value. By default, fields with empty values are - // omitted from API requests. See + // NullFields is a list of field names (e.g. "CitationMetadata") to include in + // API requests with the JSON null value. By default, fields with empty values + // are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaSearchRequestSessionSpec) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSearchRequestSessionSpec +func (s GoogleCloudDiscoveryengineV1alphaSearchResponseSummarySummaryWithMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSearchResponseSummarySummaryWithMetadata return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaSearchRequestSpellCorrectionSpec: The -// specification for query spell correction. -type GoogleCloudDiscoveryengineV1alphaSearchRequestSpellCorrectionSpec struct { - // Mode: The mode under which spell correction replaces the original search - // query. Defaults to Mode.AUTO. +// GoogleCloudDiscoveryengineV1alphaServingConfig: Configures metadata that is +// used to generate serving time results (e.g. search results or recommendation +// predictions). The ServingConfig is passed in the search and predict request +// and generates results. +type GoogleCloudDiscoveryengineV1alphaServingConfig struct { + // BoostControlIds: Boost controls to use in serving path. All triggered boost + // controls will be applied. Boost controls must be in the same data store as + // the serving config. Maximum of 20 boost controls. + BoostControlIds []string `json:"boostControlIds,omitempty"` + // CreateTime: Output only. ServingConfig created timestamp. + CreateTime string `json:"createTime,omitempty"` + // CustomFineTuningSpec: Custom fine tuning configs. If + // SearchRequest.custom_fine_tuning_spec is set, it has higher priority than + // the configs set here. + CustomFineTuningSpec *GoogleCloudDiscoveryengineV1alphaCustomFineTuningSpec `json:"customFineTuningSpec,omitempty"` + // DisplayName: Required. The human readable serving 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"` + // DissociateControlIds: Condition do not associate specifications. If multiple + // do not associate conditions match, all matching do not associate controls in + // the list will execute. Order does not matter. Maximum number of + // specifications is 100. Can only be set if SolutionType is + // SOLUTION_TYPE_SEARCH. + DissociateControlIds []string `json:"dissociateControlIds,omitempty"` + // DiversityLevel: How much diversity to use in recommendation model results + // e.g. `medium-diversity` or `high-diversity`. Currently supported values: * + // `no-diversity` * `low-diversity` * `medium-diversity` * `high-diversity` * + // `auto-diversity` If not specified, we choose default based on recommendation + // model type. Default value: `no-diversity`. Can only be set if SolutionType + // is SOLUTION_TYPE_RECOMMENDATION. + DiversityLevel string `json:"diversityLevel,omitempty"` + // EmbeddingConfig: Bring your own embedding config. The config is used for + // search semantic retrieval. The retrieval is based on the dot product of + // SearchRequest.EmbeddingSpec.EmbeddingVector.vector and the document + // embeddings that are provided by this EmbeddingConfig. If + // SearchRequest.EmbeddingSpec.EmbeddingVector.vector is provided, it overrides + // this ServingConfig.embedding_config. + EmbeddingConfig *GoogleCloudDiscoveryengineV1alphaEmbeddingConfig `json:"embeddingConfig,omitempty"` + // FilterControlIds: Filter controls to use in serving path. All triggered + // filter controls will be applied. Filter controls must be in the same data + // store as the serving config. Maximum of 20 filter controls. + FilterControlIds []string `json:"filterControlIds,omitempty"` + // GenericConfig: The GenericConfig of the serving configuration. + GenericConfig *GoogleCloudDiscoveryengineV1alphaServingConfigGenericConfig `json:"genericConfig,omitempty"` + // GuidedSearchSpec: Guided search configs. + GuidedSearchSpec *GoogleCloudDiscoveryengineV1alphaGuidedSearchSpec `json:"guidedSearchSpec,omitempty"` + // IgnoreControlIds: Condition ignore specifications. If multiple ignore + // conditions match, all matching ignore controls in the list will execute. + // Order does not matter. Maximum number of specifications is 100. + IgnoreControlIds []string `json:"ignoreControlIds,omitempty"` + // MediaConfig: The MediaConfig of the serving configuration. + MediaConfig *GoogleCloudDiscoveryengineV1alphaServingConfigMediaConfig `json:"mediaConfig,omitempty"` + // ModelId: The id of the model to use at serving time. Currently only + // RecommendationModels are supported. Can be changed but only to a compatible + // model (e.g. others-you-may-like CTR to others-you-may-like CVR). Required + // when SolutionType is SOLUTION_TYPE_RECOMMENDATION. + ModelId string `json:"modelId,omitempty"` + // Name: Immutable. Fully qualified name + // `projects/{project}/locations/{location}/collections/{collection_id}/engines/ + // {engine_id}/servingConfigs/{serving_config_id}` + Name string `json:"name,omitempty"` + // OnewaySynonymsControlIds: Condition oneway synonyms specifications. If + // multiple oneway synonyms conditions match, all matching oneway synonyms + // controls in the list will execute. Maximum number of specifications is 100. + // Can only be set if SolutionType is SOLUTION_TYPE_SEARCH. + OnewaySynonymsControlIds []string `json:"onewaySynonymsControlIds,omitempty"` + // PersonalizationSpec: The specification for personalization spec. Notice that + // if both ServingConfig.personalization_spec and + // SearchRequest.personalization_spec are set, + // SearchRequest.personalization_spec overrides + // ServingConfig.personalization_spec. + PersonalizationSpec *GoogleCloudDiscoveryengineV1alphaSearchRequestPersonalizationSpec `json:"personalizationSpec,omitempty"` + // PromoteControlIds: Condition promote specifications. Maximum number of + // specifications is 100. + PromoteControlIds []string `json:"promoteControlIds,omitempty"` + // RankingExpression: The ranking expression controls the customized ranking on + // retrieval documents. To leverage this, document embedding is required. The + // ranking expression setting in ServingConfig applies to all search requests + // served by the serving config. However, if SearchRequest.ranking_expression + // is specified, it overrides the ServingConfig ranking expression. The ranking + // expression is a single function or multiple functions that are joined 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"` + // RedirectControlIds: IDs of the redirect controls. Only the first triggered + // redirect action is applied, even if multiple apply. Maximum number of + // specifications is 100. Can only be set if SolutionType is + // SOLUTION_TYPE_SEARCH. + RedirectControlIds []string `json:"redirectControlIds,omitempty"` + // ReplacementControlIds: Condition replacement specifications. Applied + // according to the order in the list. A previously replaced term can not be + // re-replaced. Maximum number of specifications is 100. Can only be set if + // SolutionType is SOLUTION_TYPE_SEARCH. + ReplacementControlIds []string `json:"replacementControlIds,omitempty"` + // SolutionType: Required. Immutable. Specifies the solution type that a + // serving config can be associated with. // // Possible values: - // "MODE_UNSPECIFIED" - Unspecified spell correction mode. In this case, - // server behavior defaults to Mode.AUTO. - // "SUGGESTION_ONLY" - Search API tries to find a spelling suggestion. If a - // suggestion is found, it is put in the SearchResponse.corrected_query. The - // spelling suggestion won't 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. See - // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more - // details. - 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. See - // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. - NullFields []string `json:"-"` -} - -func (s GoogleCloudDiscoveryengineV1alphaSearchRequestSpellCorrectionSpec) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSearchRequestSpellCorrectionSpec - return gensupport.MarshalJSON(NoMethod(s), 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. This also helps to identify a - // request during the customer support scenarios. - 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"` - // NaturalLanguageQueryUnderstandingInfo: Natural language query understanding - // information for the returned results. - NaturalLanguageQueryUnderstandingInfo *GoogleCloudDiscoveryengineV1alphaSearchResponseNaturalLanguageQueryUnderstandingInfo `json:"naturalLanguageQueryUnderstandingInfo,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"` - // OneBoxResults: A list of One Box results. There can be multiple One Box - // results of different types. - OneBoxResults []*GoogleCloudDiscoveryengineV1alphaSearchResponseOneBoxResult `json:"oneBoxResults,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"` - // SearchLinkPromotions: Promotions for site search. - SearchLinkPromotions []*GoogleCloudDiscoveryengineV1alphaSearchLinkPromotion `json:"searchLinkPromotions,omitempty"` - // SessionInfo: Session information. Only set if SearchRequest.session is - // provided. See its description for more details. - SessionInfo *GoogleCloudDiscoveryengineV1alphaSearchResponseSessionInfo `json:"sessionInfo,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"` + // "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. + // "SOLUTION_TYPE_GENERATIVE_CHAT" - Used for use cases related to the + // Generative Chat agent. It's used for Generative chat engine only, the + // associated data stores must enrolled with `SOLUTION_TYPE_CHAT` solution. + SolutionType string `json:"solutionType,omitempty"` + // SynonymsControlIds: Condition synonyms specifications. If multiple synonyms + // conditions match, all matching synonyms controls in the list will execute. + // Maximum number of specifications is 100. Can only be set if SolutionType is + // SOLUTION_TYPE_SEARCH. + SynonymsControlIds []string `json:"synonymsControlIds,omitempty"` + // UpdateTime: Output only. ServingConfig updated timestamp. + UpdateTime string `json:"updateTime,omitempty"` // ServerResponse contains the HTTP response code and headers from the server. googleapi.ServerResponse `json:"-"` - // ForceSendFields is a list of field names (e.g. "AppliedControls") to + // ForceSendFields is a list of field names (e.g. "BoostControlIds") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "AppliedControls") to include in + // NullFields is a list of field names (e.g. "BoostControlIds") to include in // API requests with the JSON null value. By default, fields with empty values // are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaSearchResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSearchResponse +func (s GoogleCloudDiscoveryengineV1alphaServingConfig) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaServingConfig return gensupport.MarshalJSON(NoMethod(s), 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. For example, "colors" or "price". It - // matches SearchRequest.FacetSpec.FacetKey.key. - Key string `json:"key,omitempty"` - // Values: The facet values for this field. - Values []*GoogleCloudDiscoveryengineV1alphaSearchResponseFacetFacetValue `json:"values,omitempty"` - // ForceSendFields is a list of field names (e.g. "DynamicFacet") to +// GoogleCloudDiscoveryengineV1alphaServingConfigGenericConfig: Specifies the +// configurations needed for Generic Discovery.Currently we support: * +// `content_search_spec`: configuration for generic content search. +type GoogleCloudDiscoveryengineV1alphaServingConfigGenericConfig struct { + // ContentSearchSpec: Specifies the expected behavior of content search. Only + // valid for content-search enabled data store. + ContentSearchSpec *GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpec `json:"contentSearchSpec,omitempty"` + // ForceSendFields is a list of field names (e.g. "ContentSearchSpec") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. 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. See + // NullFields is a list of field names (e.g. "ContentSearchSpec") to include in + // API requests with the JSON null value. By default, fields with empty values + // are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaSearchResponseFacet) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSearchResponseFacet +func (s GoogleCloudDiscoveryengineV1alphaServingConfigGenericConfig) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaServingConfigGenericConfig return gensupport.MarshalJSON(NoMethod(s), 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"` - // 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. See +// GoogleCloudDiscoveryengineV1alphaServingConfigMediaConfig: Specifies the +// configurations needed for Media Discovery. Currently we support: * +// `demote_content_watched`: Threshold for watched content demotion. Customers +// can specify if using watched content demotion or use viewed detail page. +// Using the content watched demotion, customers need to specify the watched +// minutes or percentage exceeds the threshold, the content will be demoted in +// the recommendation result. * `promote_fresh_content`: cutoff days for fresh +// content promotion. Customers can specify if using content freshness +// promotion. If the content was published within the cutoff days, the content +// will be promoted in the recommendation result. Can only be set if +// SolutionType is SOLUTION_TYPE_RECOMMENDATION. +type GoogleCloudDiscoveryengineV1alphaServingConfigMediaConfig struct { + // ContentFreshnessCutoffDays: Specifies the content freshness used for + // recommendation result. Contents will be demoted if contents were published + // for more than content freshness cutoff days. + ContentFreshnessCutoffDays int64 `json:"contentFreshnessCutoffDays,omitempty"` + // ContentWatchedPercentageThreshold: Specifies the content watched percentage + // threshold for demotion. Threshold value must be between [0, 1.0] inclusive. + ContentWatchedPercentageThreshold float64 `json:"contentWatchedPercentageThreshold,omitempty"` + // ContentWatchedSecondsThreshold: Specifies the content watched minutes + // threshold for demotion. + ContentWatchedSecondsThreshold float64 `json:"contentWatchedSecondsThreshold,omitempty"` + // DemoteContentWatchedPastDays: Optional. Specifies the number of days to look + // back for demoting watched content. If set to zero or unset, defaults to the + // maximum of 365 days. + DemoteContentWatchedPastDays int64 `json:"demoteContentWatchedPastDays,omitempty"` + // DemotionEventType: Specifies the event type used for demoting recommendation + // result. Currently supported values: * `view-item`: Item viewed. * + // `media-play`: Start/resume watching a video, playing a song, etc. * + // `media-complete`: Finished or stopped midway through a video, song, etc. If + // unset, watch history demotion will not be applied. Content freshness + // demotion will still be applied. + DemotionEventType string `json:"demotionEventType,omitempty"` + // ForceSendFields is a list of field names (e.g. "ContentFreshnessCutoffDays") + // to unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Count") to include in API - // requests with the JSON null value. By default, fields with empty values are - // omitted from API requests. See + // NullFields is a list of field names (e.g. "ContentFreshnessCutoffDays") to + // include in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaSearchResponseFacetFacetValue) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSearchResponseFacetFacetValue +func (s GoogleCloudDiscoveryengineV1alphaServingConfigMediaConfig) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaServingConfigMediaConfig return gensupport.MarshalJSON(NoMethod(s), 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"` - // 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. See - // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more - // details. - 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. See - // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. - NullFields []string `json:"-"` +func (s *GoogleCloudDiscoveryengineV1alphaServingConfigMediaConfig) UnmarshalJSON(data []byte) error { + type NoMethod GoogleCloudDiscoveryengineV1alphaServingConfigMediaConfig + var s1 struct { + ContentWatchedPercentageThreshold gensupport.JSONFloat64 `json:"contentWatchedPercentageThreshold"` + ContentWatchedSecondsThreshold gensupport.JSONFloat64 `json:"contentWatchedSecondsThreshold"` + *NoMethod + } + s1.NoMethod = (*NoMethod)(s) + if err := json.Unmarshal(data, &s1); err != nil { + return err + } + s.ContentWatchedPercentageThreshold = float64(s1.ContentWatchedPercentageThreshold) + s.ContentWatchedSecondsThreshold = float64(s1.ContentWatchedSecondsThreshold) + return nil } -func (s GoogleCloudDiscoveryengineV1alphaSearchResponseGeoSearchDebugInfo) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSearchResponseGeoSearchDebugInfo - return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) -} +// GoogleCloudDiscoveryengineV1alphaSession: External session proto definition. +type GoogleCloudDiscoveryengineV1alphaSession struct { + // DisplayName: Optional. The display name of the session. This field is used + // to identify the session in the UI. By default, the display name is the first + // turn query text in the session. + DisplayName string `json:"displayName,omitempty"` + // EndTime: Output only. The time the session finished. + EndTime string `json:"endTime,omitempty"` + // IsPinned: Optional. Whether the session is pinned, pinned session will be + // displayed on the top of the session list. + IsPinned bool `json:"isPinned,omitempty"` + // Name: Immutable. Fully qualified name + // `projects/{project}/locations/global/collections/{collection}/engines/{engine + // }/sessions/*` + Name string `json:"name,omitempty"` + // StartTime: Output only. The time the session started. + StartTime string `json:"startTime,omitempty"` + // State: The state of the session. + // + // Possible values: + // "STATE_UNSPECIFIED" - State is unspecified. + // "IN_PROGRESS" - The session is currently open. + State string `json:"state,omitempty"` + // Turns: Turns. + Turns []*GoogleCloudDiscoveryengineV1alphaSessionTurn `json:"turns,omitempty"` + // UserPseudoId: A unique identifier for tracking users. + UserPseudoId string `json:"userPseudoId,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"` - // RefinementAttributes: A list of ranked refinement attributes. - RefinementAttributes []*GoogleCloudDiscoveryengineV1alphaSearchResponseGuidedSearchResultRefinementAttribute `json:"refinementAttributes,omitempty"` - // ForceSendFields is a list of field names (e.g. "FollowUpQuestions") to + // ServerResponse contains the HTTP response code and headers from the server. + googleapi.ServerResponse `json:"-"` + // ForceSendFields is a list of field names (e.g. "DisplayName") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "FollowUpQuestions") to include in - // API requests with the JSON null value. By default, fields with empty values - // are omitted from API requests. See + // NullFields is a list of field names (e.g. "DisplayName") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaSearchResponseGuidedSearchResult) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSearchResponseGuidedSearchResult +func (s GoogleCloudDiscoveryengineV1alphaSession) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSession return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaSearchResponseGuidedSearchResultRefinementAt -// tribute: Useful attribute for search result refinements. -type GoogleCloudDiscoveryengineV1alphaSearchResponseGuidedSearchResultRefinementAttribute struct { - // AttributeKey: Attribute key used to refine the results. For example, - // "movie_type". - AttributeKey string `json:"attributeKey,omitempty"` - // AttributeValue: Attribute value used to refine the results. For example, - // "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. See +// GoogleCloudDiscoveryengineV1alphaSessionTurn: Represents a turn, including a +// query from the user and a answer from service. +type GoogleCloudDiscoveryengineV1alphaSessionTurn struct { + // Answer: The resource name of the answer to the user query. Only set if the + // answer generation (/answer API call) happened in this turn. + Answer string `json:"answer,omitempty"` + // DetailedAnswer: Output only. In ConversationalSearchService.GetSession API, + // if GetSessionRequest.include_answer_details is set to true, this field will + // be populated when getting answer query session. + DetailedAnswer *GoogleCloudDiscoveryengineV1alphaAnswer `json:"detailedAnswer,omitempty"` + // Query: The user query. + Query *GoogleCloudDiscoveryengineV1alphaQuery `json:"query,omitempty"` + // ForceSendFields is a list of field names (e.g. "Answer") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "AttributeKey") to include in API + // NullFields is a list of field names (e.g. "Answer") to include in API // requests with the JSON null value. By default, fields with empty values are // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaSearchResponseGuidedSearchResultRefinementAttribute) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSearchResponseGuidedSearchResultRefinementAttribute +func (s GoogleCloudDiscoveryengineV1alphaSessionTurn) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSessionTurn return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaSearchResponseNaturalLanguageQueryUnderstand -// ingInfo: Information describing what natural language understanding was done -// on the input query. -type GoogleCloudDiscoveryengineV1alphaSearchResponseNaturalLanguageQueryUnderstandingInfo struct { - // ExtractedFilters: The filters that were extracted from the input query. - ExtractedFilters string `json:"extractedFilters,omitempty"` - // RewrittenQuery: Rewritten input query minus the extracted filters. - RewrittenQuery string `json:"rewrittenQuery,omitempty"` - // StructuredExtractedFilter: The filters that were extracted from the input - // query represented in a structured form. - StructuredExtractedFilter *GoogleCloudDiscoveryengineV1alphaSearchResponseNaturalLanguageQueryUnderstandingInfoStructuredExtractedFilter `json:"structuredExtractedFilter,omitempty"` - // ForceSendFields is a list of field names (e.g. "ExtractedFilters") to +// GoogleCloudDiscoveryengineV1alphaSetUpDataConnectorMetadata: Metadata for +// DataConnectorService.SetUpDataConnector method. +type GoogleCloudDiscoveryengineV1alphaSetUpDataConnectorMetadata struct { +} + +// GoogleCloudDiscoveryengineV1alphaSetUpDataConnectorRequest: Request for +// DataConnectorService.SetUpDataConnector method. +type GoogleCloudDiscoveryengineV1alphaSetUpDataConnectorRequest struct { + // CollectionDisplayName: Required. The display name of the Collection. Should + // be human readable, used to display collections in the Console Dashboard. + // UTF-8 encoded string with limit of 1024 characters. + CollectionDisplayName string `json:"collectionDisplayName,omitempty"` + // CollectionId: Required. The ID to use for the Collection, which will become + // the final component of the Collection's resource name. A new Collection is + // created as part of the DataConnector setup. DataConnector is a singleton + // resource under Collection, managing all DataStores of the Collection. 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. + CollectionId string `json:"collectionId,omitempty"` + // DataConnector: Required. The DataConnector to initialize in the newly + // created Collection. + DataConnector *GoogleCloudDiscoveryengineV1alphaDataConnector `json:"dataConnector,omitempty"` + // ForceSendFields is a list of field names (e.g. "CollectionDisplayName") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "ExtractedFilters") to include in - // API requests with the JSON null value. By default, fields with empty values - // are omitted from API requests. See + // NullFields is a list of field names (e.g. "CollectionDisplayName") to + // include in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaSearchResponseNaturalLanguageQueryUnderstandingInfo) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSearchResponseNaturalLanguageQueryUnderstandingInfo +func (s GoogleCloudDiscoveryengineV1alphaSetUpDataConnectorRequest) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSetUpDataConnectorRequest return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaSearchResponseNaturalLanguageQueryUnderstand -// ingInfoStructuredExtractedFilter: The filters that were extracted from the -// input query represented in a structured form. -type GoogleCloudDiscoveryengineV1alphaSearchResponseNaturalLanguageQueryUnderstandingInfoStructuredExtractedFilter struct { - // Expression: The expression denoting the filter that was extracted from the - // input query in a structured form. It can be a simple expression denoting a - // single string, numerical or geolocation constraint or a compound expression - // which is a combination of multiple expressions connected using logical (OR - // and AND) operators. - Expression *GoogleCloudDiscoveryengineV1alphaSearchResponseNaturalLanguageQueryUnderstandingInfoStructuredExtractedFilterExpression `json:"expression,omitempty"` - // ForceSendFields is a list of field names (e.g. "Expression") to +// GoogleCloudDiscoveryengineV1alphaSetUriPatternDocumentDataMetadata: Metadata +// related to the progress of the +// SiteSearchEngineService.SetUriPatternDocumentData operation. This will be +// returned by the google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1alphaSetUriPatternDocumentDataMetadata struct { + // CreateTime: Operation create time. + CreateTime string `json:"createTime,omitempty"` + // UpdateTime: Operation last update time. If the operation is done, this is + // also the finish time. + UpdateTime string `json:"updateTime,omitempty"` + // ForceSendFields is a list of field names (e.g. "CreateTime") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Expression") to include in API + // NullFields is a list of field names (e.g. "CreateTime") to include in API // requests with the JSON null value. By default, fields with empty values are // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaSearchResponseNaturalLanguageQueryUnderstandingInfoStructuredExtractedFilter) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSearchResponseNaturalLanguageQueryUnderstandingInfoStructuredExtractedFilter +func (s GoogleCloudDiscoveryengineV1alphaSetUriPatternDocumentDataMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSetUriPatternDocumentDataMetadata return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaSearchResponseNaturalLanguageQueryUnderstand -// ingInfoStructuredExtractedFilterAndExpression: Logical `And` operator. -type GoogleCloudDiscoveryengineV1alphaSearchResponseNaturalLanguageQueryUnderstandingInfoStructuredExtractedFilterAndExpression struct { - // Expressions: The expressions that were ANDed together. - Expressions []*GoogleCloudDiscoveryengineV1alphaSearchResponseNaturalLanguageQueryUnderstandingInfoStructuredExtractedFilterExpression `json:"expressions,omitempty"` - // ForceSendFields is a list of field names (e.g. "Expressions") to +// GoogleCloudDiscoveryengineV1alphaSetUriPatternDocumentDataRequest: Request +// message for SiteSearchEngineService.SetUriPatternDocumentData method. +type GoogleCloudDiscoveryengineV1alphaSetUriPatternDocumentDataRequest struct { + // DocumentDataMap: Document data keyed by URI pattern. Each entry must be + // consistent with the Schema. For example: Schema = { "type": "object", + // "properties": { "Categories": { "type": "array", "items": { "retrievable": + // true, "type": "string" } } } document_data_map = { "www.url1.com/*": { + // "Categories": ["category1", "category2"] }, "www.url2.com/*": { + // "Categories": ["category3"] } } + DocumentDataMap map[string]googleapi.RawMessage `json:"documentDataMap,omitempty"` + // EmptyDocumentDataMap: If true, clears the document data map. If true, + // SetUriPatternDocumentDataRequest.document_data_map must be empty. + EmptyDocumentDataMap bool `json:"emptyDocumentDataMap,omitempty"` + // Schema: Optional. If not provided, the current Schema is used. If provided, + // validates and updates the Schema. If validation fails, an error is returned. + Schema googleapi.RawMessage `json:"schema,omitempty"` + // ForceSendFields is a list of field names (e.g. "DocumentDataMap") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Expressions") to include in API - // requests with the JSON null value. By default, fields with empty values are - // omitted from API requests. See + // NullFields is a list of field names (e.g. "DocumentDataMap") to include in + // API requests with the JSON null value. By default, fields with empty values + // are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaSearchResponseNaturalLanguageQueryUnderstandingInfoStructuredExtractedFilterAndExpression) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSearchResponseNaturalLanguageQueryUnderstandingInfoStructuredExtractedFilterAndExpression +func (s GoogleCloudDiscoveryengineV1alphaSetUriPatternDocumentDataRequest) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSetUriPatternDocumentDataRequest return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaSearchResponseNaturalLanguageQueryUnderstand -// ingInfoStructuredExtractedFilterExpression: The expression denoting the -// filter that was extracted from the input query. -type GoogleCloudDiscoveryengineV1alphaSearchResponseNaturalLanguageQueryUnderstandingInfoStructuredExtractedFilterExpression struct { - // AndExpr: Logical "And" compound operator connecting multiple expressions. - AndExpr *GoogleCloudDiscoveryengineV1alphaSearchResponseNaturalLanguageQueryUnderstandingInfoStructuredExtractedFilterAndExpression `json:"andExpr,omitempty"` - // GeolocationConstraint: Geolocation constraint expression. - GeolocationConstraint *GoogleCloudDiscoveryengineV1alphaSearchResponseNaturalLanguageQueryUnderstandingInfoStructuredExtractedFilterGeolocationConstraint `json:"geolocationConstraint,omitempty"` - // NumberConstraint: Numerical constraint expression. - NumberConstraint *GoogleCloudDiscoveryengineV1alphaSearchResponseNaturalLanguageQueryUnderstandingInfoStructuredExtractedFilterNumberConstraint `json:"numberConstraint,omitempty"` - // OrExpr: Logical "Or" compound operator connecting multiple expressions. - OrExpr *GoogleCloudDiscoveryengineV1alphaSearchResponseNaturalLanguageQueryUnderstandingInfoStructuredExtractedFilterOrExpression `json:"orExpr,omitempty"` - // StringConstraint: String constraint expression. - StringConstraint *GoogleCloudDiscoveryengineV1alphaSearchResponseNaturalLanguageQueryUnderstandingInfoStructuredExtractedFilterStringConstraint `json:"stringConstraint,omitempty"` - // ForceSendFields is a list of field names (e.g. "AndExpr") to unconditionally - // include in API requests. By default, fields with empty or default values are - // omitted from API requests. See - // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more - // details. - ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "AndExpr") to include in API - // requests with the JSON null value. By default, fields with empty values are - // omitted from API requests. See - // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. - NullFields []string `json:"-"` -} - -func (s GoogleCloudDiscoveryengineV1alphaSearchResponseNaturalLanguageQueryUnderstandingInfoStructuredExtractedFilterExpression) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSearchResponseNaturalLanguageQueryUnderstandingInfoStructuredExtractedFilterExpression - return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +// GoogleCloudDiscoveryengineV1alphaSetUriPatternDocumentDataResponse: Response +// message for SiteSearchEngineService.SetUriPatternDocumentData method. +type GoogleCloudDiscoveryengineV1alphaSetUriPatternDocumentDataResponse struct { } -// GoogleCloudDiscoveryengineV1alphaSearchResponseNaturalLanguageQueryUnderstand -// ingInfoStructuredExtractedFilterGeolocationConstraint: Constraint of a -// geolocation field. Name of the geolocation field as defined in the schema. -type GoogleCloudDiscoveryengineV1alphaSearchResponseNaturalLanguageQueryUnderstandingInfoStructuredExtractedFilterGeolocationConstraint struct { - // Address: The reference address that was inferred from the input query. The - // proximity of the reference address to the geolocation field will be used to - // filter the results. - Address string `json:"address,omitempty"` - // FieldName: The name of the geolocation field as defined in the schema. - FieldName string `json:"fieldName,omitempty"` - // Latitude: The latitude of the geolocation inferred from the input query. - Latitude float64 `json:"latitude,omitempty"` - // Longitude: The longitude of the geolocation inferred from the input query. - Longitude float64 `json:"longitude,omitempty"` - // RadiusInMeters: The radius in meters around the address. The record is - // returned if the location of the geolocation field is within the radius. - RadiusInMeters float64 `json:"radiusInMeters,omitempty"` - // ForceSendFields is a list of field names (e.g. "Address") to unconditionally +// GoogleCloudDiscoveryengineV1alphaSingleRegionKey: Metadata for +// single-regional CMEKs. +type GoogleCloudDiscoveryengineV1alphaSingleRegionKey struct { + // KmsKey: Required. Single-regional kms key resource name which will be used + // to encrypt resources + // `projects/{project}/locations/{location}/keyRings/{keyRing}/cryptoKeys/{keyId + // }`. + KmsKey string `json:"kmsKey,omitempty"` + // ForceSendFields is a list of field names (e.g. "KmsKey") to unconditionally // include in API requests. By default, fields with empty or default values are // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Address") to include in API + // NullFields is a list of field names (e.g. "KmsKey") to include in API // requests with the JSON null value. By default, fields with empty values are // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaSearchResponseNaturalLanguageQueryUnderstandingInfoStructuredExtractedFilterGeolocationConstraint) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSearchResponseNaturalLanguageQueryUnderstandingInfoStructuredExtractedFilterGeolocationConstraint +func (s GoogleCloudDiscoveryengineV1alphaSingleRegionKey) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSingleRegionKey return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -func (s *GoogleCloudDiscoveryengineV1alphaSearchResponseNaturalLanguageQueryUnderstandingInfoStructuredExtractedFilterGeolocationConstraint) UnmarshalJSON(data []byte) error { - type NoMethod GoogleCloudDiscoveryengineV1alphaSearchResponseNaturalLanguageQueryUnderstandingInfoStructuredExtractedFilterGeolocationConstraint - var s1 struct { - Latitude gensupport.JSONFloat64 `json:"latitude"` - Longitude gensupport.JSONFloat64 `json:"longitude"` - RadiusInMeters gensupport.JSONFloat64 `json:"radiusInMeters"` - *NoMethod - } - s1.NoMethod = (*NoMethod)(s) - if err := json.Unmarshal(data, &s1); err != nil { - return err - } - s.Latitude = float64(s1.Latitude) - s.Longitude = float64(s1.Longitude) - s.RadiusInMeters = float64(s1.RadiusInMeters) - return nil -} +// 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"` -// GoogleCloudDiscoveryengineV1alphaSearchResponseNaturalLanguageQueryUnderstand -// ingInfoStructuredExtractedFilterNumberConstraint: Constraint expression of a -// number field. Example: price < 100. -type GoogleCloudDiscoveryengineV1alphaSearchResponseNaturalLanguageQueryUnderstandingInfoStructuredExtractedFilterNumberConstraint struct { - // Comparison: The comparison operation performed between the field value and - // the value specified in the constraint. - // - // Possible values: - // "COMPARISON_UNSPECIFIED" - Undefined comparison operator. - // "EQUALS" - Denotes equality `=` operator. - // "LESS_THAN_EQUALS" - Denotes less than or equal to `<=` operator. - // "LESS_THAN" - Denotes less than `<` operator. - // "GREATER_THAN_EQUALS" - Denotes greater than or equal to `>=` operator. - // "GREATER_THAN" - Denotes greater than `>` operator. - Comparison string `json:"comparison,omitempty"` - // FieldName: Name of the numerical field as defined in the schema. - FieldName string `json:"fieldName,omitempty"` - // QuerySegment: Identifies the keywords within the search query that match a - // filter. - QuerySegment string `json:"querySegment,omitempty"` - // Value: The value specified in the numerical constraint. - Value float64 `json:"value,omitempty"` - // ForceSendFields is a list of field names (e.g. "Comparison") to - // unconditionally include in API requests. By default, fields with empty or - // default values are omitted from API requests. See + // ServerResponse contains the HTTP response code and headers from the server. + googleapi.ServerResponse `json:"-"` + // ForceSendFields is a list of field names (e.g. "Name") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Comparison") to include in API - // requests with the JSON null value. By default, fields with empty values are - // omitted from API requests. See + // NullFields is a list of field names (e.g. "Name") to include in API requests + // with the JSON null value. By default, fields with empty values are omitted + // from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaSearchResponseNaturalLanguageQueryUnderstandingInfoStructuredExtractedFilterNumberConstraint) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSearchResponseNaturalLanguageQueryUnderstandingInfoStructuredExtractedFilterNumberConstraint +func (s GoogleCloudDiscoveryengineV1alphaSiteSearchEngine) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSiteSearchEngine return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -func (s *GoogleCloudDiscoveryengineV1alphaSearchResponseNaturalLanguageQueryUnderstandingInfoStructuredExtractedFilterNumberConstraint) UnmarshalJSON(data []byte) error { - type NoMethod GoogleCloudDiscoveryengineV1alphaSearchResponseNaturalLanguageQueryUnderstandingInfoStructuredExtractedFilterNumberConstraint - var s1 struct { - Value gensupport.JSONFloat64 `json:"value"` - *NoMethod - } - s1.NoMethod = (*NoMethod)(s) - if err := json.Unmarshal(data, &s1); err != nil { - return err - } - s.Value = float64(s1.Value) - return nil -} - -// GoogleCloudDiscoveryengineV1alphaSearchResponseNaturalLanguageQueryUnderstand -// ingInfoStructuredExtractedFilterOrExpression: Logical `Or` operator. -type GoogleCloudDiscoveryengineV1alphaSearchResponseNaturalLanguageQueryUnderstandingInfoStructuredExtractedFilterOrExpression struct { - // Expressions: The expressions that were ORed together. - Expressions []*GoogleCloudDiscoveryengineV1alphaSearchResponseNaturalLanguageQueryUnderstandingInfoStructuredExtractedFilterExpression `json:"expressions,omitempty"` - // ForceSendFields is a list of field names (e.g. "Expressions") to +// 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"` + // 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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Expressions") to include in API - // requests with the JSON null value. By default, fields with empty values are - // omitted from API requests. See + // NullFields is a list of field names (e.g. "SiteVerificationState") to + // include in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaSearchResponseNaturalLanguageQueryUnderstandingInfoStructuredExtractedFilterOrExpression) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSearchResponseNaturalLanguageQueryUnderstandingInfoStructuredExtractedFilterOrExpression +func (s GoogleCloudDiscoveryengineV1alphaSiteVerificationInfo) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSiteVerificationInfo return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaSearchResponseNaturalLanguageQueryUnderstand -// ingInfoStructuredExtractedFilterStringConstraint: Constraint expression of a -// string field. -type GoogleCloudDiscoveryengineV1alphaSearchResponseNaturalLanguageQueryUnderstandingInfoStructuredExtractedFilterStringConstraint struct { - // FieldName: Name of the string field as defined in the schema. - FieldName string `json:"fieldName,omitempty"` - // QuerySegment: Identifies the keywords within the search query that match a - // filter. - QuerySegment string `json:"querySegment,omitempty"` - // Values: Values of the string field. The record will only be returned if the - // field value matches one of the values specified here. - Values []string `json:"values,omitempty"` - // ForceSendFields is a list of field names (e.g. "FieldName") to +// GoogleCloudDiscoveryengineV1alphaSitemap: A sitemap for the +// SiteSearchEngine. +type GoogleCloudDiscoveryengineV1alphaSitemap struct { + // CreateTime: Output only. The sitemap's creation time. + CreateTime string `json:"createTime,omitempty"` + // Name: Output only. The fully qualified resource name of the sitemap. + // `projects/*/locations/*/collections/*/dataStores/*/siteSearchEngine/sitemaps/ + // *` The `sitemap_id` suffix is system-generated. + Name string `json:"name,omitempty"` + // Uri: Public URI for the sitemap, e.g. `www.example.com/sitemap.xml`. + Uri string `json:"uri,omitempty"` + // ForceSendFields is a list of field names (e.g. "CreateTime") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "FieldName") to include in API + // NullFields is a list of field names (e.g. "CreateTime") to include in API // requests with the JSON null value. By default, fields with empty values are // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaSearchResponseNaturalLanguageQueryUnderstandingInfoStructuredExtractedFilterStringConstraint) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSearchResponseNaturalLanguageQueryUnderstandingInfoStructuredExtractedFilterStringConstraint +func (s GoogleCloudDiscoveryengineV1alphaSitemap) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSitemap return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaSearchResponseOneBoxResult: OneBoxResult is -// a holder for all results of specific type that we want to display in UI -// differently. -type GoogleCloudDiscoveryengineV1alphaSearchResponseOneBoxResult struct { - // OneBoxType: The type of One Box result. - // - // Possible values: - // "ONE_BOX_TYPE_UNSPECIFIED" - Default value. Should not be used. - // "PEOPLE" - One Box result contains people results. - // "ORGANIZATION" - One Box result contains organization results. - // "SLACK" - One Box result contains slack results. - // "KNOWLEDGE_GRAPH" - One Box result contains Knowledge Graph search - // responses. - OneBoxType string `json:"oneBoxType,omitempty"` - // SearchResults: The search results for this One Box. - SearchResults []*GoogleCloudDiscoveryengineV1alphaSearchResponseSearchResult `json:"searchResults,omitempty"` - // ForceSendFields is a list of field names (e.g. "OneBoxType") to +// GoogleCloudDiscoveryengineV1alphaSpannerSource: The Spanner source for +// importing data +type GoogleCloudDiscoveryengineV1alphaSpannerSource struct { + // DatabaseId: Required. The database ID of the source Spanner table. + DatabaseId string `json:"databaseId,omitempty"` + // EnableDataBoost: Whether to apply data boost on Spanner export. Enabling + // this option will incur additional cost. More info can be found here + // (https://cloud.google.com/spanner/docs/databoost/databoost-overview#billing_and_quotas). + EnableDataBoost bool `json:"enableDataBoost,omitempty"` + // InstanceId: Required. The instance ID of the source Spanner table. + InstanceId string `json:"instanceId,omitempty"` + // ProjectId: The project ID that contains the Spanner source. Has 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 table name of the Spanner database that needs to be + // imported. + TableId string `json:"tableId,omitempty"` + // ForceSendFields is a list of field names (e.g. "DatabaseId") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "OneBoxType") to include in API + // NullFields is a list of field names (e.g. "DatabaseId") to include in API // requests with the JSON null value. By default, fields with empty values are // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaSearchResponseOneBoxResult) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSearchResponseOneBoxResult +func (s GoogleCloudDiscoveryengineV1alphaSpannerSource) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSpannerSource return gensupport.MarshalJSON(NoMethod(s), 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"` - // 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 +// GoogleCloudDiscoveryengineV1alphaStartConnectorRunRequest: Request message +// for DataConnectorService.StartConnectorRun method. +type GoogleCloudDiscoveryengineV1alphaStartConnectorRunRequest struct { + // Entities: Specifies which Third Party Connector entities should be synced. + // If not specified, all entities will be synced. + Entities []string `json:"entities,omitempty"` + // HealthcareFhirResourceTypes: The FHIR resource types to import. The resource + // types should be a subset of all supported FHIR resource types + // http://shortn/_J8ymdyOokT. Default to all supported FHIR resource types if + // empty. + HealthcareFhirResourceTypes []string `json:"healthcareFhirResourceTypes,omitempty"` + // SyncIdentity: If true, trigger Identity sync. + SyncIdentity bool `json:"syncIdentity,omitempty"` + // SyncSinceTimestamp: Timestamp to indicate the point in time from which data + // should be synced for Streaming/Batch Data Connectors. This field is only + // utilized for Healthcare Connectors. + SyncSinceTimestamp string `json:"syncSinceTimestamp,omitempty"` + // ForceSendFields is a list of field names (e.g. "Entities") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "ExpandedQuery") to include in API + // NullFields is a list of field names (e.g. "Entities") to include in API // requests with the JSON null value. By default, fields with empty values are // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaSearchResponseQueryExpansionInfo) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSearchResponseQueryExpansionInfo +func (s GoogleCloudDiscoveryengineV1alphaStartConnectorRunRequest) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaStartConnectorRunRequest return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaSearchResponseSearchResult: Represents the -// search results. -type GoogleCloudDiscoveryengineV1alphaSearchResponseSearchResult struct { - // Chunk: The chunk data in the search response if the - // SearchRequest.ContentSearchSpec.search_result_mode is set to CHUNKS. - Chunk *GoogleCloudDiscoveryengineV1alphaChunk `json:"chunk,omitempty"` - // 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"` - // ModelScores: Google provided available scores. - ModelScores map[string]GoogleCloudDiscoveryengineV1alphaDoubleList `json:"modelScores,omitempty"` - // ForceSendFields is a list of field names (e.g. "Chunk") to unconditionally - // include in API requests. By default, fields with empty or default values are - // omitted from API requests. See +// 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"` + // 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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Chunk") to include in API + // 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. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaSearchResponseSearchResult) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSearchResponseSearchResult +func (s GoogleCloudDiscoveryengineV1alphaSuggestionDenyListEntry) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSuggestionDenyListEntry return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaSearchResponseSessionInfo: Information -// about the session. -type GoogleCloudDiscoveryengineV1alphaSearchResponseSessionInfo struct { - // Name: Name of the session. If the auto-session mode is used (when - // SearchRequest.session ends with "-"), this field holds the newly generated - // session name. +// 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}/dataStores/ + // {data_store}/siteSearchEngine/targetSites/{target_site}` The + // `target_site_id` is system-generated. Name string `json:"name,omitempty"` - // QueryId: Query ID that corresponds to this search API call. One session can - // have multiple turns, each with a unique query ID. By specifying the session - // name and this query ID in the Answer API call, the answer generation happens - // in the context of the search results from this search call. - QueryId string `json:"queryId,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 + // ProvidedUriPattern: Required. Input only. The user provided URI pattern from + // which the `generated_uri_pattern` is generated. + ProvidedUriPattern string `json:"providedUriPattern,omitempty"` + // RootDomainUri: Output only. Root domain of the provided_uri_pattern. + RootDomainUri string `json:"rootDomainUri,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"` + + // 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. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + 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. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1alphaTargetSite) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaTargetSite + return gensupport.MarshalJSON(NoMethod(s), 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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Name") to include in API requests - // with the JSON null value. By default, fields with empty values are omitted - // from API requests. See + // 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. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaSearchResponseSessionInfo) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSearchResponseSessionInfo +func (s GoogleCloudDiscoveryengineV1alphaTargetSiteFailureReason) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaTargetSiteFailureReason return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaSearchResponseSummary: Summary of the top N -// search results 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"` - // 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 - // used when SummarySpec.ignore_adversarial_query is set to `true`. - // "NON_SUMMARY_SEEKING_QUERY_IGNORED" - The non-summary seeking query - // ignored case. Google skips the summary if the query is chit chat. Only used - // when SummarySpec.ignore_non_summary_seeking_query is set to `true`. - // "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. - // "NO_RELEVANT_CONTENT" - The no relevant content case. Google skips the - // summary if there is no relevant content in the retrieved search results. - // "JAIL_BREAKING_QUERY_IGNORED" - The jail-breaking query ignored case. For - // example, "Reply in the tone of a competing company's CEO". Only used when - // [SearchRequest.ContentSearchSpec.SummarySpec.ignore_jail_breaking_query] is - // set to `true`. - // "CUSTOMER_POLICY_VIOLATION" - The customer policy violation case. Google - // skips the summary if there is a customer policy violation detected. The - // policy is defined by the customer. - // "NON_SUMMARY_SEEKING_QUERY_IGNORED_V2" - The non-answer seeking query - // ignored case. Google skips the summary if the query doesn't have clear - // intent. Only used when - // [SearchRequest.ContentSearchSpec.SummarySpec.ignore_non_answer_seeking_query] - // is set to `true`. - SummarySkippedReasons []string `json:"summarySkippedReasons,omitempty"` - // SummaryText: The summary content. - SummaryText string `json:"summaryText,omitempty"` - // SummaryWithMetadata: Summary with metadata information. - SummaryWithMetadata *GoogleCloudDiscoveryengineV1alphaSearchResponseSummarySummaryWithMetadata `json:"summaryWithMetadata,omitempty"` - // ForceSendFields is a list of field names (e.g. "SafetyAttributes") to +// GoogleCloudDiscoveryengineV1alphaTargetSiteFailureReasonQuotaFailure: Failed +// due to insufficient quota. +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. "TotalRequiredQuota") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. 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. See + // 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. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaSearchResponseSummary) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSearchResponseSummary +func (s GoogleCloudDiscoveryengineV1alphaTargetSiteFailureReasonQuotaFailure) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaTargetSiteFailureReasonQuotaFailure return gensupport.MarshalJSON(NoMethod(s), 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"` - // Sources: Citation sources for the attributed segment. - Sources []*GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryCitationSource `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. See +// GoogleCloudDiscoveryengineV1alphaTextInput: Defines text input. +type GoogleCloudDiscoveryengineV1alphaTextInput struct { + // Context: Conversation context of the input. + Context *GoogleCloudDiscoveryengineV1alphaConversationContext `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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "EndIndex") to include in API + // 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. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryCitation) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryCitation +func (s GoogleCloudDiscoveryengineV1alphaTextInput) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaTextInput return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryCitationMetadata: -// Citation metadata. -type GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryCitationMetadata struct { - // Citations: Citations for segments. - Citations []*GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryCitation `json:"citations,omitempty"` - // ForceSendFields is a list of field names (e.g. "Citations") to +// 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"` + // UpdateTime: Operation last update time. If the operation is done, this is + // also the finish time. + UpdateTime string `json:"updateTime,omitempty"` + // ForceSendFields is a list of field names (e.g. "CreateTime") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Citations") to include in API + // NullFields is a list of field names (e.g. "CreateTime") to include in API // requests with the JSON null value. By default, fields with empty values are // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryCitationMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryCitationMetadata +func (s GoogleCloudDiscoveryengineV1alphaTrainCustomModelMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaTrainCustomModelMetadata return gensupport.MarshalJSON(NoMethod(s), 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"` - // ForceSendFields is a list of field names (e.g. "ReferenceIndex") to +// 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"` + // GcsTrainingInput: Cloud Storage training input. + GcsTrainingInput *GoogleCloudDiscoveryengineV1alphaTrainCustomModelRequestGcsTrainingInput `json:"gcsTrainingInput,omitempty"` + // ModelId: If not provided, a UUID will be generated. + ModelId string `json:"modelId,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. "ErrorConfig") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. 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. See + // 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. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryCitationSource) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryCitationSource +func (s GoogleCloudDiscoveryengineV1alphaTrainCustomModelRequest) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaTrainCustomModelRequest return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryReference: Document -// reference. -type GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryReference struct { - // ChunkContents: List of cited chunk contents derived from document content. - ChunkContents []*GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryReferenceChunkContent `json:"chunkContents,omitempty"` - // Document: Required. Document.name of the document. Full resource name of the - // referenced document, in the format - // `projects/*/locations/*/collections/*/dataStores/*/branches/*/documents/*`. - 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. "ChunkContents") to +// GoogleCloudDiscoveryengineV1alphaTrainCustomModelRequestGcsTrainingInput: +// 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"` + // 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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "ChunkContents") to include in API - // requests with the JSON null value. By default, fields with empty values are - // omitted from API requests. See + // NullFields is a list of field names (e.g. "CorpusDataPath") to include in + // API requests with the JSON null value. By default, fields with empty values + // are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryReference) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryReference +func (s GoogleCloudDiscoveryengineV1alphaTrainCustomModelRequestGcsTrainingInput) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaTrainCustomModelRequestGcsTrainingInput return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryReferenceChunkContent: -// Chunk content. -type GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryReferenceChunkContent struct { - // Content: Chunk textual content. - Content string `json:"content,omitempty"` - // PageIdentifier: Page identifier. - PageIdentifier string `json:"pageIdentifier,omitempty"` - // 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. See +// 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"` + // Metrics: The metrics of the trained model. + Metrics map[string]float64 `json:"metrics,omitempty"` + // ModelName: Fully qualified name of the CustomTuningModel. + ModelName string `json:"modelName,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 job + // creation is in progress. * **training**: Model is actively training. * + // **evaluating**: The model is evaluating trained metrics. * **indexing**: The + // model trained metrics are indexing. * **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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Content") to include in API + // 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. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryReferenceChunkContent) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryReferenceChunkContent +func (s GoogleCloudDiscoveryengineV1alphaTrainCustomModelResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaTrainCustomModelResponse return gensupport.MarshalJSON(NoMethod(s), 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"` - // 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. See +// 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"` + // 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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. 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. See + // 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. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaSearchResponseSummarySafetyAttributes) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSearchResponseSummarySafetyAttributes +func (s GoogleCloudDiscoveryengineV1alphaTransactionInfo) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaTransactionInfo return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -func (s *GoogleCloudDiscoveryengineV1alphaSearchResponseSummarySafetyAttributes) UnmarshalJSON(data []byte) error { - type NoMethod GoogleCloudDiscoveryengineV1alphaSearchResponseSummarySafetyAttributes +func (s *GoogleCloudDiscoveryengineV1alphaTransactionInfo) UnmarshalJSON(data []byte) error { + type NoMethod GoogleCloudDiscoveryengineV1alphaTransactionInfo var s1 struct { - Scores []gensupport.JSONFloat64 `json:"scores"` + 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.Scores = make([]float64, len(s1.Scores)) - for i := range s1.Scores { - s.Scores[i] = float64(s1.Scores[i]) - } + s.Cost = float64(s1.Cost) + s.DiscountValue = float64(s1.DiscountValue) + s.Tax = float64(s1.Tax) + s.Value = float64(s1.Value) return nil } -// GoogleCloudDiscoveryengineV1alphaSearchResponseSummarySummaryWithMetadata: -// Summary with metadata information. -type GoogleCloudDiscoveryengineV1alphaSearchResponseSummarySummaryWithMetadata struct { - // CitationMetadata: Citation metadata for given summary. - CitationMetadata *GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryCitationMetadata `json:"citationMetadata,omitempty"` - // 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. See +// 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}/locations/{location}/collections/{collection_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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. 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. See + // 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. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaSearchResponseSummarySummaryWithMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSearchResponseSummarySummaryWithMetadata +func (s GoogleCloudDiscoveryengineV1alphaTuneEngineMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaTuneEngineMetadata return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaServingConfig: Configures metadata that is -// used to generate serving time results (e.g. search results or recommendation -// predictions). The ServingConfig is passed in the search and predict request -// and generates results. -type GoogleCloudDiscoveryengineV1alphaServingConfig struct { - // BoostControlIds: Boost controls to use in serving path. All triggered boost - // controls will be applied. Boost controls must be in the same data store as - // the serving config. Maximum of 20 boost controls. - BoostControlIds []string `json:"boostControlIds,omitempty"` - // CreateTime: Output only. ServingConfig created timestamp. +// 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 { +} + +// GoogleCloudDiscoveryengineV1alphaUpdateCmekConfigMetadata: Metadata related +// to the progress of the CmekConfigService.UpdateCmekConfig operation. This +// will be returned by the google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1alphaUpdateCmekConfigMetadata struct { + // CreateTime: Operation create time. CreateTime string `json:"createTime,omitempty"` - // CustomFineTuningSpec: Custom fine tuning configs. If - // SearchRequest.custom_fine_tuning_spec is set, it has higher priority than - // the configs set here. - CustomFineTuningSpec *GoogleCloudDiscoveryengineV1alphaCustomFineTuningSpec `json:"customFineTuningSpec,omitempty"` - // DisplayName: Required. The human readable serving 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"` - // DissociateControlIds: Condition do not associate specifications. If multiple - // do not associate conditions match, all matching do not associate controls in - // the list will execute. Order does not matter. Maximum number of - // specifications is 100. Can only be set if SolutionType is - // SOLUTION_TYPE_SEARCH. - DissociateControlIds []string `json:"dissociateControlIds,omitempty"` - // DiversityLevel: How much diversity to use in recommendation model results - // e.g. `medium-diversity` or `high-diversity`. Currently supported values: * - // `no-diversity` * `low-diversity` * `medium-diversity` * `high-diversity` * - // `auto-diversity` If not specified, we choose default based on recommendation - // model type. Default value: `no-diversity`. Can only be set if SolutionType - // is SOLUTION_TYPE_RECOMMENDATION. - DiversityLevel string `json:"diversityLevel,omitempty"` - // EmbeddingConfig: Bring your own embedding config. The config is used for - // search semantic retrieval. The retrieval is based on the dot product of - // SearchRequest.EmbeddingSpec.EmbeddingVector.vector and the document - // embeddings that are provided by this EmbeddingConfig. If - // SearchRequest.EmbeddingSpec.EmbeddingVector.vector is provided, it overrides - // this ServingConfig.embedding_config. - EmbeddingConfig *GoogleCloudDiscoveryengineV1alphaEmbeddingConfig `json:"embeddingConfig,omitempty"` - // FilterControlIds: Filter controls to use in serving path. All triggered - // filter controls will be applied. Filter controls must be in the same data - // store as the serving config. Maximum of 20 filter controls. - FilterControlIds []string `json:"filterControlIds,omitempty"` - // GenericConfig: The GenericConfig of the serving configuration. - GenericConfig *GoogleCloudDiscoveryengineV1alphaServingConfigGenericConfig `json:"genericConfig,omitempty"` - // GuidedSearchSpec: Guided search configs. - GuidedSearchSpec *GoogleCloudDiscoveryengineV1alphaGuidedSearchSpec `json:"guidedSearchSpec,omitempty"` - // IgnoreControlIds: Condition ignore specifications. If multiple ignore - // conditions match, all matching ignore controls in the list will execute. - // Order does not matter. Maximum number of specifications is 100. - IgnoreControlIds []string `json:"ignoreControlIds,omitempty"` - // MediaConfig: The MediaConfig of the serving configuration. - MediaConfig *GoogleCloudDiscoveryengineV1alphaServingConfigMediaConfig `json:"mediaConfig,omitempty"` - // ModelId: The id of the model to use at serving time. Currently only - // RecommendationModels are supported. Can be changed but only to a compatible - // model (e.g. others-you-may-like CTR to others-you-may-like CVR). Required - // when SolutionType is SOLUTION_TYPE_RECOMMENDATION. - ModelId string `json:"modelId,omitempty"` - // Name: Immutable. Fully qualified name - // `projects/{project}/locations/{location}/collections/{collection_id}/engines/ - // {engine_id}/servingConfigs/{serving_config_id}` - Name string `json:"name,omitempty"` - // OnewaySynonymsControlIds: Condition oneway synonyms specifications. If - // multiple oneway synonyms conditions match, all matching oneway synonyms - // controls in the list will execute. Maximum number of specifications is 100. - // Can only be set if SolutionType is SOLUTION_TYPE_SEARCH. - OnewaySynonymsControlIds []string `json:"onewaySynonymsControlIds,omitempty"` - // PersonalizationSpec: The specification for personalization spec. Notice that - // if both ServingConfig.personalization_spec and - // SearchRequest.personalization_spec are set, - // SearchRequest.personalization_spec overrides - // ServingConfig.personalization_spec. - PersonalizationSpec *GoogleCloudDiscoveryengineV1alphaSearchRequestPersonalizationSpec `json:"personalizationSpec,omitempty"` - // PromoteControlIds: Condition promote specifications. Maximum number of - // specifications is 100. - PromoteControlIds []string `json:"promoteControlIds,omitempty"` - // RankingExpression: The ranking expression controls the customized ranking on - // retrieval documents. To leverage this, document embedding is required. The - // ranking expression setting in ServingConfig applies to all search requests - // served by the serving config. However, if SearchRequest.ranking_expression - // is specified, it overrides the ServingConfig ranking expression. The ranking - // expression is a single function or multiple functions that are joined 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"` - // RedirectControlIds: IDs of the redirect controls. Only the first triggered - // redirect action is applied, even if multiple apply. Maximum number of - // specifications is 100. Can only be set if SolutionType is - // SOLUTION_TYPE_SEARCH. - RedirectControlIds []string `json:"redirectControlIds,omitempty"` - // ReplacementControlIds: Condition replacement specifications. Applied - // according to the order in the list. A previously replaced term can not be - // re-replaced. Maximum number of specifications is 100. Can only be set if - // SolutionType is SOLUTION_TYPE_SEARCH. - ReplacementControlIds []string `json:"replacementControlIds,omitempty"` - // SolutionType: Required. Immutable. Specifies the solution type that a - // serving config can be associated with. - // - // 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. - // "SOLUTION_TYPE_GENERATIVE_CHAT" - Used for use cases related to the - // Generative Chat agent. It's used for Generative chat engine only, the - // associated data stores must enrolled with `SOLUTION_TYPE_CHAT` solution. - SolutionType string `json:"solutionType,omitempty"` - // SynonymsControlIds: Condition synonyms specifications. If multiple synonyms - // conditions match, all matching synonyms controls in the list will execute. - // Maximum number of specifications is 100. Can only be set if SolutionType is - // SOLUTION_TYPE_SEARCH. - SynonymsControlIds []string `json:"synonymsControlIds,omitempty"` - // UpdateTime: Output only. ServingConfig updated timestamp. + // UpdateTime: Operation last update time. If the operation is done, this is + // also the finish time. + UpdateTime string `json:"updateTime,omitempty"` + // ForceSendFields is a list of field names (e.g. "CreateTime") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "CreateTime") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1alphaUpdateCmekConfigMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaUpdateCmekConfigMetadata + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaUpdateCollectionMetadata: Metadata related +// to the progress of the CollectionService.UpdateCollection operation. This +// will be returned by the google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1alphaUpdateCollectionMetadata struct { + // CreateTime: Operation create time. + CreateTime string `json:"createTime,omitempty"` + // UpdateTime: Operation last update time. If the operation is done, this is + // also the finish time. UpdateTime string `json:"updateTime,omitempty"` + // ForceSendFields is a list of field names (e.g. "CreateTime") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "CreateTime") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} - // ServerResponse contains the HTTP response code and headers from the server. - googleapi.ServerResponse `json:"-"` - // ForceSendFields is a list of field names (e.g. "BoostControlIds") to +func (s GoogleCloudDiscoveryengineV1alphaUpdateCollectionMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaUpdateCollectionMetadata + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// 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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "BoostControlIds") to include in - // API requests with the JSON null value. By default, fields with empty values - // are omitted from API requests. See + // NullFields is a list of field names (e.g. "CreateTime") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaServingConfig) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaServingConfig +func (s GoogleCloudDiscoveryengineV1alphaUpdateSchemaMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaUpdateSchemaMetadata return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaServingConfigGenericConfig: Specifies the -// configurations needed for Generic Discovery.Currently we support: * -// `content_search_spec`: configuration for generic content search. -type GoogleCloudDiscoveryengineV1alphaServingConfigGenericConfig struct { - // ContentSearchSpec: Specifies the expected behavior of content search. Only - // valid for content-search enabled data store. - ContentSearchSpec *GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpec `json:"contentSearchSpec,omitempty"` - // ForceSendFields is a list of field names (e.g. "ContentSearchSpec") to +// GoogleCloudDiscoveryengineV1alphaUpdateSessionRequest: Request for +// UpdateSession method. +type GoogleCloudDiscoveryengineV1alphaUpdateSessionRequest struct { + // Session: Required. The Session to update. + Session *GoogleCloudDiscoveryengineV1alphaSession `json:"session,omitempty"` + // UpdateMask: Indicates which fields in the provided Session to update. The + // following are NOT supported: * Session.name If not set or empty, all + // supported fields are updated. + UpdateMask string `json:"updateMask,omitempty"` + // ForceSendFields is a list of field names (e.g. "Session") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "Session") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1alphaUpdateSessionRequest) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaUpdateSessionRequest + return gensupport.MarshalJSON(NoMethod(s), 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"` + // UpdateTime: Operation last update time. If the operation is done, this is + // also the finish time. + UpdateTime string `json:"updateTime,omitempty"` + // ForceSendFields is a list of field names (e.g. "CreateTime") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "CreateTime") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1alphaUpdateTargetSiteMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaUpdateTargetSiteMetadata + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaUserEvent: UserEvent captures all metadata +// information Discovery Engine API needs to know about how end users interact +// with your website. +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"` + // ConversionType: Optional. Conversion type. Required if UserEvent.event_type + // is `conversion`. This is a customer-defined conversion name in lowercase + // letters or numbers separated by "-", such as "watch", "good-visit" etc. Do + // not set the field if UserEvent.event_type is not `conversion`. This mixes + // the custom conversion event with predefined events like `search`, + // `view-item` etc. + ConversionType string `json:"conversionType,omitempty"` + // DataStore: The DataStore resource full name, of the form + // `projects/{project}/locations/{location}/collections/{collection_id}/dataStor + // es/{data_store_id}`. Optional. Only required for user events whose data + // store can't by determined by UserEvent.engine or UserEvent.documents. If + // data store is set in the parent of write/import/collect user event requests, + // this field can be omitted. + DataStore string `json:"dataStore,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"` + // Engine: The Engine resource name, in the form of + // `projects/{project}/locations/{location}/collections/{collection_id}/engines/ + // {engine_id}`. Optional. Only required for Engine produced user events. For + // example, user events from blended search. + Engine string `json:"engine,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 * `add-feedback`: Add a user + // feedback. 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. Custom conversion value: * `conversion`: Customer defined + // conversion event. + 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"` + // Panels: Optional. List of panels associated with this event. Used for + // page-level impression data. + Panels []*GoogleCloudDiscoveryengineV1alphaPanelInfo `json:"panels,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. + 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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "ContentSearchSpec") to include in - // API requests with the JSON null value. By default, fields with empty values - // are omitted from API requests. See + // NullFields is a list of field names (e.g. "Attributes") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaServingConfigGenericConfig) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaServingConfigGenericConfig +func (s GoogleCloudDiscoveryengineV1alphaUserEvent) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaUserEvent return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaServingConfigMediaConfig: Specifies the -// configurations needed for Media Discovery. Currently we support: * -// `demote_content_watched`: Threshold for watched content demotion. Customers -// can specify if using watched content demotion or use viewed detail page. -// Using the content watched demotion, customers need to specify the watched -// minutes or percentage exceeds the threshold, the content will be demoted in -// the recommendation result. * `promote_fresh_content`: cutoff days for fresh -// content promotion. Customers can specify if using content freshness -// promotion. If the content was published within the cutoff days, the content -// will be promoted in the recommendation result. Can only be set if -// SolutionType is SOLUTION_TYPE_RECOMMENDATION. -type GoogleCloudDiscoveryengineV1alphaServingConfigMediaConfig struct { - // ContentFreshnessCutoffDays: Specifies the content freshness used for - // recommendation result. Contents will be demoted if contents were published - // for more than content freshness cutoff days. - ContentFreshnessCutoffDays int64 `json:"contentFreshnessCutoffDays,omitempty"` - // ContentWatchedPercentageThreshold: Specifies the content watched percentage - // threshold for demotion. Threshold value must be between [0, 1.0] inclusive. - ContentWatchedPercentageThreshold float64 `json:"contentWatchedPercentageThreshold,omitempty"` - // ContentWatchedSecondsThreshold: Specifies the content watched minutes - // threshold for demotion. - ContentWatchedSecondsThreshold float64 `json:"contentWatchedSecondsThreshold,omitempty"` - // DemoteContentWatchedPastDays: Optional. Specifies the number of days to look - // back for demoting watched content. If set to zero or unset, defaults to the - // maximum of 365 days. - DemoteContentWatchedPastDays int64 `json:"demoteContentWatchedPastDays,omitempty"` - // DemotionEventType: Specifies the event type used for demoting recommendation - // result. Currently supported values: * `view-item`: Item viewed. * - // `media-play`: Start/resume watching a video, playing a song, etc. * - // `media-complete`: Finished or stopped midway through a video, song, etc. If - // unset, watch history demotion will not be applied. Content freshness - // demotion will still be applied. - DemotionEventType string `json:"demotionEventType,omitempty"` - // ForceSendFields is a list of field names (e.g. "ContentFreshnessCutoffDays") - // to unconditionally include in API requests. By default, fields with empty or +// 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"` + // 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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "ContentFreshnessCutoffDays") to - // include in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. See + // NullFields is a list of field names (e.g. "UserAgent") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaServingConfigMediaConfig) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaServingConfigMediaConfig +func (s GoogleCloudDiscoveryengineV1alphaUserInfo) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaUserInfo return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -func (s *GoogleCloudDiscoveryengineV1alphaServingConfigMediaConfig) UnmarshalJSON(data []byte) error { - type NoMethod GoogleCloudDiscoveryengineV1alphaServingConfigMediaConfig - var s1 struct { - ContentWatchedPercentageThreshold gensupport.JSONFloat64 `json:"contentWatchedPercentageThreshold"` - ContentWatchedSecondsThreshold gensupport.JSONFloat64 `json:"contentWatchedSecondsThreshold"` - *NoMethod - } - s1.NoMethod = (*NoMethod)(s) - if err := json.Unmarshal(data, &s1); err != nil { - return err - } - s.ContentWatchedPercentageThreshold = float64(s1.ContentWatchedPercentageThreshold) - s.ContentWatchedSecondsThreshold = float64(s1.ContentWatchedSecondsThreshold) - return nil -} - -// GoogleCloudDiscoveryengineV1alphaSession: External session proto definition. -type GoogleCloudDiscoveryengineV1alphaSession struct { - // DisplayName: Optional. The display name of the session. This field is used - // to identify the session in the UI. By default, the display name is the first - // turn query text in the session. - DisplayName string `json:"displayName,omitempty"` - // EndTime: Output only. The time the session finished. - EndTime string `json:"endTime,omitempty"` - // IsPinned: Optional. Whether the session is pinned, pinned session will be - // displayed on the top of the session list. - IsPinned bool `json:"isPinned,omitempty"` - // Name: Immutable. Fully qualified name - // `projects/{project}/locations/global/collections/{collection}/engines/{engine - // }/sessions/*` - Name string `json:"name,omitempty"` - // StartTime: Output only. The time the session started. - StartTime string `json:"startTime,omitempty"` - // State: The state of the session. +// GoogleCloudDiscoveryengineV1alphaWorkspaceConfig: Config to store data store +// type configuration for workspace data +type GoogleCloudDiscoveryengineV1alphaWorkspaceConfig struct { + // DasherCustomerId: Obfuscated Dasher customer ID. + DasherCustomerId string `json:"dasherCustomerId,omitempty"` + // SuperAdminEmailAddress: Optional. The super admin email address for the + // workspace that will be used for access token generation. For now we only use + // it for Native Google Drive connector data ingestion. + SuperAdminEmailAddress string `json:"superAdminEmailAddress,omitempty"` + // SuperAdminServiceAccount: Optional. The super admin service account for the + // workspace that will be used for access token generation. For now we only use + // it for Native Google Drive connector data ingestion. + SuperAdminServiceAccount string `json:"superAdminServiceAccount,omitempty"` + // Type: The Google Workspace data source. // // Possible values: - // "STATE_UNSPECIFIED" - State is unspecified. - // "IN_PROGRESS" - The session is currently open. - State string `json:"state,omitempty"` - // Turns: Turns. - Turns []*GoogleCloudDiscoveryengineV1alphaSessionTurn `json:"turns,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. "DisplayName") to + // "TYPE_UNSPECIFIED" - Defaults to an unspecified Workspace type. + // "GOOGLE_DRIVE" - Workspace Data Store contains Drive data + // "GOOGLE_MAIL" - Workspace Data Store contains Mail data + // "GOOGLE_SITES" - Workspace Data Store contains Sites data + // "GOOGLE_CALENDAR" - Workspace Data Store contains Calendar data + // "GOOGLE_CHAT" - Workspace Data Store contains Chat data + // "GOOGLE_GROUPS" - Workspace Data Store contains Groups data + // "GOOGLE_KEEP" - Workspace Data Store contains Keep data + Type string `json:"type,omitempty"` + // ForceSendFields is a list of field names (e.g. "DasherCustomerId") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "DisplayName") to include in API - // requests with the JSON null value. By default, fields with empty values are - // omitted from API requests. See + // NullFields is a list of field names (e.g. "DasherCustomerId") to include in + // API requests with the JSON null value. By default, fields with empty values + // are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaSession) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSession +func (s GoogleCloudDiscoveryengineV1alphaWorkspaceConfig) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaWorkspaceConfig return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaSessionTurn: Represents a turn, including a -// query from the user and a answer from service. -type GoogleCloudDiscoveryengineV1alphaSessionTurn struct { - // Answer: The resource name of the answer to the user query. Only set if the - // answer generation (/answer API call) happened in this turn. - Answer string `json:"answer,omitempty"` - // DetailedAnswer: Output only. In ConversationalSearchService.GetSession API, - // if GetSessionRequest.include_answer_details is set to true, this field will - // be populated when getting answer query session. - DetailedAnswer *GoogleCloudDiscoveryengineV1alphaAnswer `json:"detailedAnswer,omitempty"` - // Query: The user query. - Query *GoogleCloudDiscoveryengineV1alphaQuery `json:"query,omitempty"` - // ForceSendFields is a list of field names (e.g. "Answer") to unconditionally - // include in API requests. By default, fields with empty or default values are - // omitted from API requests. See - // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more - // details. - ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Answer") to include in API - // requests with the JSON null value. By default, fields with empty values are - // omitted from API requests. See - // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. - NullFields []string `json:"-"` -} - -func (s GoogleCloudDiscoveryengineV1alphaSessionTurn) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSessionTurn - return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +// GoogleCloudDiscoveryengineV1betaAdvancedSiteSearchConfig: Configuration data +// for advance site search. +type GoogleCloudDiscoveryengineV1betaAdvancedSiteSearchConfig struct { } -// GoogleCloudDiscoveryengineV1alphaSetUriPatternDocumentDataMetadata: Metadata +// GoogleCloudDiscoveryengineV1betaBatchCreateTargetSiteMetadata: Metadata // related to the progress of the -// SiteSearchEngineService.SetUriPatternDocumentData operation. This will be +// SiteSearchEngineService.BatchCreateTargetSites operation. This will be // returned by the google.longrunning.Operation.metadata field. -type GoogleCloudDiscoveryengineV1alphaSetUriPatternDocumentDataMetadata struct { +type GoogleCloudDiscoveryengineV1betaBatchCreateTargetSiteMetadata struct { // CreateTime: Operation create time. CreateTime string `json:"createTime,omitempty"` // UpdateTime: Operation last update time. If the operation is done, this is @@ -15850,600 +18220,517 @@ type GoogleCloudDiscoveryengineV1alphaSetUriPatternDocumentDataMetadata struct { NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaSetUriPatternDocumentDataMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSetUriPatternDocumentDataMetadata +func (s GoogleCloudDiscoveryengineV1betaBatchCreateTargetSiteMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaBatchCreateTargetSiteMetadata return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaSetUriPatternDocumentDataRequest: Request -// message for SiteSearchEngineService.SetUriPatternDocumentData method. -type GoogleCloudDiscoveryengineV1alphaSetUriPatternDocumentDataRequest struct { - // DocumentDataMap: Document data keyed by URI pattern. Each entry must be - // consistent with the Schema. For example: Schema = { "type": "object", - // "properties": { "Categories": { "type": "array", "items": { "retrievable": - // true, "type": "string" } } } document_data_map = { "www.url1.com/*": { - // "Categories": ["category1", "category2"] }, "www.url2.com/*": { - // "Categories": ["category3"] } } - DocumentDataMap map[string]googleapi.RawMessage `json:"documentDataMap,omitempty"` - // EmptyDocumentDataMap: If true, clears the document data map. If true, - // SetUriPatternDocumentDataRequest.document_data_map must be empty. - EmptyDocumentDataMap bool `json:"emptyDocumentDataMap,omitempty"` - // Schema: Optional. If not provided, the current Schema is used. If provided, - // validates and updates the Schema. If validation fails, an error is returned. - Schema googleapi.RawMessage `json:"schema,omitempty"` - // ForceSendFields is a list of field names (e.g. "DocumentDataMap") to +// 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. "TargetSites") to // unconditionally include in API requests. By default, fields with empty or - // default values are omitted from API requests. See - // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more - // details. - ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "DocumentDataMap") to include in - // API requests with the JSON null value. By default, fields with empty values - // are omitted from API requests. See - // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. - NullFields []string `json:"-"` -} - -func (s GoogleCloudDiscoveryengineV1alphaSetUriPatternDocumentDataRequest) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSetUriPatternDocumentDataRequest - return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) -} - -// GoogleCloudDiscoveryengineV1alphaSetUriPatternDocumentDataResponse: Response -// message for SiteSearchEngineService.SetUriPatternDocumentData method. -type GoogleCloudDiscoveryengineV1alphaSetUriPatternDocumentDataResponse struct { -} - -// 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"` - - // ServerResponse contains the HTTP response code and headers from the server. - googleapi.ServerResponse `json:"-"` - // ForceSendFields is a list of field names (e.g. "Name") to unconditionally - // include in API requests. By default, fields with empty or default values are - // omitted from API requests. See + // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Name") to include in API requests - // with the JSON null value. By default, fields with empty values are omitted - // from API requests. See + // 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. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaSiteSearchEngine) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSiteSearchEngine +func (s GoogleCloudDiscoveryengineV1betaBatchCreateTargetSitesResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaBatchCreateTargetSitesResponse return gensupport.MarshalJSON(NoMethod(s), 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. +// GoogleCloudDiscoveryengineV1betaCmekConfig: Configurations used to enable +// CMEK data encryption with Cloud KMS keys. +type GoogleCloudDiscoveryengineV1betaCmekConfig struct { + // IsDefault: Output only. The default CmekConfig for the Customer. + IsDefault bool `json:"isDefault,omitempty"` + // KmsKey: Kms key resource name which will be used to encrypt resources + // `projects/{project}/locations/{location}/keyRings/{keyRing}/cryptoKeys/{keyId + // }`. + KmsKey string `json:"kmsKey,omitempty"` + // KmsKeyVersion: Kms key version resource name which will be used to encrypt + // resources `/cryptoKeyVersions/{keyVersion}`. + KmsKeyVersion string `json:"kmsKeyVersion,omitempty"` + // LastRotationTimestampMicros: Output only. The timestamp of the last key + // rotation. + LastRotationTimestampMicros int64 `json:"lastRotationTimestampMicros,omitempty,string"` + // Name: Required. Name of the CmekConfig, of the form + // `projects/{project}/locations/{location}/cmekConfig` or + // `projects/{project}/locations/{location}/cmekConfigs/{cmekConfig}`. + Name string `json:"name,omitempty"` + // SingleRegionKeys: Optional. Single-regional CMEKs that are required for some + // VAIS features. + SingleRegionKeys []*GoogleCloudDiscoveryengineV1betaSingleRegionKey `json:"singleRegionKeys,omitempty"` + // State: Output only. State of the CmekConfig. // // 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 + // "STATE_UNSPECIFIED" - The CmekConfig state is unknown. + // "CREATING" - The CmekConfig is creating. + // "ACTIVE" - The CmekConfig can be used with DataStores. + // "KEY_ISSUE" - The CmekConfig is unavailable, most likely due to the KMS + // Key being revoked. + // "DELETING" - The CmekConfig is deleting. + // "UNUSABLE" - The CmekConfig is not usable, most likely due to some + // internal issue. + // "ACTIVE_ROTATING" - The KMS key version is being rotated. + State string `json:"state,omitempty"` + // ForceSendFields is a list of field names (e.g. "IsDefault") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. 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. See + // NullFields is a list of field names (e.g. "IsDefault") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaSiteVerificationInfo) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSiteVerificationInfo +func (s GoogleCloudDiscoveryengineV1betaCmekConfig) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaCmekConfig return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaSitemap: A sitemap for the -// SiteSearchEngine. -type GoogleCloudDiscoveryengineV1alphaSitemap struct { - // CreateTime: Output only. The sitemap's creation time. - CreateTime string `json:"createTime,omitempty"` - // Name: Output only. The fully qualified resource name of the sitemap. - // `projects/*/locations/*/collections/*/dataStores/*/siteSearchEngine/sitemaps/ - // *` The `sitemap_id` suffix is system-generated. - Name string `json:"name,omitempty"` - // Uri: Public URI for the sitemap, e.g. `www.example.com/sitemap.xml`. - Uri string `json:"uri,omitempty"` - // ForceSendFields is a list of field names (e.g. "CreateTime") to +// GoogleCloudDiscoveryengineV1betaCondition: Defines circumstances to be +// checked before allowing a behavior +type GoogleCloudDiscoveryengineV1betaCondition struct { + // ActiveTimeRange: Range of time(s) specifying when condition is active. + // Maximum of 10 time ranges. + ActiveTimeRange []*GoogleCloudDiscoveryengineV1betaConditionTimeRange `json:"activeTimeRange,omitempty"` + // QueryRegex: Optional. Query regex to match the whole search query. Cannot be + // set when Condition.query_terms is set. This is currently supporting + // promotion use case. + QueryRegex string `json:"queryRegex,omitempty"` + // QueryTerms: Search only A list of terms to match the query on. Cannot be set + // when Condition.query_regex is set. Maximum of 10 query terms. + QueryTerms []*GoogleCloudDiscoveryengineV1betaConditionQueryTerm `json:"queryTerms,omitempty"` + // ForceSendFields is a list of field names (e.g. "ActiveTimeRange") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "CreateTime") to include in API - // requests with the JSON null value. By default, fields with empty values are - // omitted from API requests. See + // NullFields is a list of field names (e.g. "ActiveTimeRange") to include in + // API requests with the JSON null value. By default, fields with empty values + // are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaSitemap) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSitemap +func (s GoogleCloudDiscoveryengineV1betaCondition) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaCondition return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaSpannerSource: The Spanner source for -// importing data -type GoogleCloudDiscoveryengineV1alphaSpannerSource struct { - // DatabaseId: Required. The database ID of the source Spanner table. - DatabaseId string `json:"databaseId,omitempty"` - // EnableDataBoost: Whether to apply data boost on Spanner export. Enabling - // this option will incur additional cost. More info can be found here - // (https://cloud.google.com/spanner/docs/databoost/databoost-overview#billing_and_quotas). - EnableDataBoost bool `json:"enableDataBoost,omitempty"` - // InstanceId: Required. The instance ID of the source Spanner table. - InstanceId string `json:"instanceId,omitempty"` - // ProjectId: The project ID that contains the Spanner source. Has 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 table name of the Spanner database that needs to be - // imported. - TableId string `json:"tableId,omitempty"` - // ForceSendFields is a list of field names (e.g. "DatabaseId") to +// GoogleCloudDiscoveryengineV1betaConditionQueryTerm: Matcher for search +// request query +type GoogleCloudDiscoveryengineV1betaConditionQueryTerm struct { + // FullMatch: Whether the search query needs to exactly match the query term. + FullMatch bool `json:"fullMatch,omitempty"` + // Value: The specific query value to match against Must be lowercase, must be + // UTF-8. Can have at most 3 space separated terms if full_match is true. + // Cannot be an empty string. Maximum length of 5000 characters. + Value string `json:"value,omitempty"` + // ForceSendFields is a list of field names (e.g. "FullMatch") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "DatabaseId") to include in API + // NullFields is a list of field names (e.g. "FullMatch") to include in API // requests with the JSON null value. By default, fields with empty values are // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaSpannerSource) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSpannerSource +func (s GoogleCloudDiscoveryengineV1betaConditionQueryTerm) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaConditionQueryTerm return gensupport.MarshalJSON(NoMethod(s), 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"` - // 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. See +// GoogleCloudDiscoveryengineV1betaConditionTimeRange: Used for time-dependent +// conditions. +type GoogleCloudDiscoveryengineV1betaConditionTimeRange struct { + // EndTime: End of time range. Range is inclusive. Must be in the future. + EndTime string `json:"endTime,omitempty"` + // StartTime: Start of time range. Range is inclusive. + StartTime string `json:"startTime,omitempty"` + // ForceSendFields is a list of field names (e.g. "EndTime") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "BlockPhrase") to include in API + // NullFields is a list of field names (e.g. "EndTime") to include in API // requests with the JSON null value. By default, fields with empty values are // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaSuggestionDenyListEntry) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaSuggestionDenyListEntry +func (s GoogleCloudDiscoveryengineV1betaConditionTimeRange) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaConditionTimeRange return gensupport.MarshalJSON(NoMethod(s), 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. +// GoogleCloudDiscoveryengineV1betaControl: Defines a conditioned behavior to +// employ during serving. Must be attached to a ServingConfig to be considered +// at serving time. Permitted actions dependent on `SolutionType`. +type GoogleCloudDiscoveryengineV1betaControl struct { + // AssociatedServingConfigIds: Output only. List of all ServingConfig IDs this + // control is attached to. May take up to 10 minutes to update after changes. + AssociatedServingConfigIds []string `json:"associatedServingConfigIds,omitempty"` + // BoostAction: Defines a boost-type control + BoostAction *GoogleCloudDiscoveryengineV1betaControlBoostAction `json:"boostAction,omitempty"` + // Conditions: Determines when the associated action will trigger. Omit to + // always apply the action. Currently only a single condition may be specified. + // Otherwise an INVALID ARGUMENT error is thrown. + Conditions []*GoogleCloudDiscoveryengineV1betaCondition `json:"conditions,omitempty"` + // DisplayName: Required. Human readable name. The identifier used in UI views. + // Must be UTF-8 encoded string. Length limit is 128 characters. Otherwise an + // INVALID ARGUMENT error is thrown. + DisplayName string `json:"displayName,omitempty"` + // FilterAction: Defines a filter-type control Currently not supported by + // Recommendation + FilterAction *GoogleCloudDiscoveryengineV1betaControlFilterAction `json:"filterAction,omitempty"` + // Name: Immutable. Fully qualified name + // `projects/*/locations/global/dataStore/*/controls/*` + Name string `json:"name,omitempty"` + // PromoteAction: Promote certain links based on predefined trigger queries. + // This now only supports basic site search. + PromoteAction *GoogleCloudDiscoveryengineV1betaControlPromoteAction `json:"promoteAction,omitempty"` + // RedirectAction: Defines a redirect-type control. + RedirectAction *GoogleCloudDiscoveryengineV1betaControlRedirectAction `json:"redirectAction,omitempty"` + // SolutionType: Required. Immutable. What solution the control belongs to. + // Must be compatible with vertical of resource. Otherwise an INVALID ARGUMENT + // error is thrown. // // 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}/dataStores/ - // {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"` - // RootDomainUri: Output only. Root domain of the provided_uri_pattern. - RootDomainUri string `json:"rootDomainUri,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. + // "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. + // "SOLUTION_TYPE_GENERATIVE_CHAT" - Used for use cases related to the + // Generative Chat agent. It's used for Generative chat engine only, the + // associated data stores must enrolled with `SOLUTION_TYPE_CHAT` solution. + SolutionType string `json:"solutionType,omitempty"` + // SynonymsAction: Treats a group of terms as synonyms of one another. + SynonymsAction *GoogleCloudDiscoveryengineV1betaControlSynonymsAction `json:"synonymsAction,omitempty"` + // UseCases: Specifies the use case for the control. Affects what condition + // fields can be set. Only applies to SOLUTION_TYPE_SEARCH. Currently only + // allow one use case per control. Must be set when solution_type is + // SolutionType.SOLUTION_TYPE_SEARCH. // // 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 + // "SEARCH_USE_CASE_UNSPECIFIED" - Value used when unset. Will not occur in + // CSS. + // "SEARCH_USE_CASE_SEARCH" - Search use case. Expects the traffic has a + // non-empty query. + // "SEARCH_USE_CASE_BROWSE" - Browse use case. Expects the traffic has an + // empty query. + UseCases []string `json:"useCases,omitempty"` + // ForceSendFields is a list of field names (e.g. "AssociatedServingConfigIds") + // to unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. 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. See + // NullFields is a list of field names (e.g. "AssociatedServingConfigIds") to + // include in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaTargetSite) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaTargetSite +func (s GoogleCloudDiscoveryengineV1betaControl) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaControl return gensupport.MarshalJSON(NoMethod(s), 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. See +// GoogleCloudDiscoveryengineV1betaControlBoostAction: Adjusts order of +// products in returned list. +type GoogleCloudDiscoveryengineV1betaControlBoostAction struct { + // Boost: Required. Strength of the boost, which should be in [-1, 1]. Negative + // boost means demotion. Default is 0.0 (No-op). + Boost float64 `json:"boost,omitempty"` + // DataStore: Required. Specifies which data store's documents can be boosted + // by this control. Full data store name e.g. + // projects/123/locations/global/collections/default_collection/dataStores/defau + // lt_data_store + DataStore string `json:"dataStore,omitempty"` + // Filter: Required. Specifies which products to apply the boost to. If no + // filter is provided all products will be boosted (No-op). Syntax + // documentation: https://cloud.google.com/retail/docs/filter-and-order Maximum + // length is 5000 characters. Otherwise an INVALID ARGUMENT error is thrown. + Filter string `json:"filter,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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "QuotaFailure") to include in API + // 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. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaTargetSiteFailureReason) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaTargetSiteFailureReason +func (s GoogleCloudDiscoveryengineV1betaControlBoostAction) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaControlBoostAction return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaTargetSiteFailureReasonQuotaFailure: Failed -// due to insufficient quota. -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. "TotalRequiredQuota") to - // unconditionally include in API requests. By default, fields with empty or - // default values are omitted from API requests. See - // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more - // details. - 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. See - // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. - NullFields []string `json:"-"` -} - -func (s GoogleCloudDiscoveryengineV1alphaTargetSiteFailureReasonQuotaFailure) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaTargetSiteFailureReasonQuotaFailure - return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +func (s *GoogleCloudDiscoveryengineV1betaControlBoostAction) UnmarshalJSON(data []byte) error { + type NoMethod GoogleCloudDiscoveryengineV1betaControlBoostAction + 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 } -// GoogleCloudDiscoveryengineV1alphaTextInput: Defines text input. -type GoogleCloudDiscoveryengineV1alphaTextInput struct { - // Context: Conversation context of the input. - Context *GoogleCloudDiscoveryengineV1alphaConversationContext `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. See +// GoogleCloudDiscoveryengineV1betaControlFilterAction: Specified which +// products may be included in results. Uses same filter as boost. +type GoogleCloudDiscoveryengineV1betaControlFilterAction struct { + // DataStore: Required. Specifies which data store's documents can be filtered + // by this control. Full data store name e.g. + // projects/123/locations/global/collections/default_collection/dataStores/defau + // lt_data_store + DataStore string `json:"dataStore,omitempty"` + // Filter: Required. A filter to apply on the matching condition results. + // Required Syntax documentation: + // https://cloud.google.com/retail/docs/filter-and-order Maximum length is 5000 + // characters. Otherwise an INVALID ARGUMENT error is thrown. + Filter string `json:"filter,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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Context") to include in API + // 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. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaTextInput) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaTextInput +func (s GoogleCloudDiscoveryengineV1betaControlFilterAction) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaControlFilterAction return gensupport.MarshalJSON(NoMethod(s), 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"` - // 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 +// GoogleCloudDiscoveryengineV1betaControlPromoteAction: Promote certain links +// based on some trigger queries. Example: Promote shoe store link when +// searching for `shoe` keyword. The link can be outside of associated data +// store. +type GoogleCloudDiscoveryengineV1betaControlPromoteAction struct { + // DataStore: Required. Data store with which this promotion is attached to. + DataStore string `json:"dataStore,omitempty"` + // SearchLinkPromotion: Required. Promotion attached to this action. + SearchLinkPromotion *GoogleCloudDiscoveryengineV1betaSearchLinkPromotion `json:"searchLinkPromotion,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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "CreateTime") to include in API + // NullFields is a list of field names (e.g. "DataStore") to include in API // requests with the JSON null value. By default, fields with empty values are // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaTrainCustomModelMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaTrainCustomModelMetadata +func (s GoogleCloudDiscoveryengineV1betaControlPromoteAction) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaControlPromoteAction return gensupport.MarshalJSON(NoMethod(s), 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"` - // GcsTrainingInput: Cloud Storage training input. - GcsTrainingInput *GoogleCloudDiscoveryengineV1alphaTrainCustomModelRequestGcsTrainingInput `json:"gcsTrainingInput,omitempty"` - // ModelId: If not provided, a UUID will be generated. - ModelId string `json:"modelId,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. "ErrorConfig") to +// GoogleCloudDiscoveryengineV1betaControlRedirectAction: Redirects a shopper +// to the provided URI. +type GoogleCloudDiscoveryengineV1betaControlRedirectAction struct { + // RedirectUri: Required. The URI to which the shopper will be redirected. + // Required. URI must have length equal or less than 2000 characters. Otherwise + // an INVALID ARGUMENT error is thrown. + RedirectUri string `json:"redirectUri,omitempty"` + // ForceSendFields is a list of field names (e.g. "RedirectUri") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "ErrorConfig") to include in API + // NullFields is a list of field names (e.g. "RedirectUri") to include in API // requests with the JSON null value. By default, fields with empty values are // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaTrainCustomModelRequest) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaTrainCustomModelRequest +func (s GoogleCloudDiscoveryengineV1betaControlRedirectAction) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaControlRedirectAction return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaTrainCustomModelRequestGcsTrainingInput: -// 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"` - // 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 +// GoogleCloudDiscoveryengineV1betaControlSynonymsAction: Creates a set of +// terms that will act as synonyms of one another. Example: "happy" will also +// be considered as "glad", "glad" will also be considered as "happy". +type GoogleCloudDiscoveryengineV1betaControlSynonymsAction struct { + // Synonyms: Defines a set of synonyms. Can specify up to 100 synonyms. Must + // specify at least 2 synonyms. Otherwise an INVALID ARGUMENT error is thrown. + Synonyms []string `json:"synonyms,omitempty"` + // ForceSendFields is a list of field names (e.g. "Synonyms") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // 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. See + // NullFields is a list of field names (e.g. "Synonyms") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` -} - -func (s GoogleCloudDiscoveryengineV1alphaTrainCustomModelRequestGcsTrainingInput) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaTrainCustomModelRequestGcsTrainingInput - return gensupport.MarshalJSON(NoMethod(s), 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"` - // Metrics: The metrics of the trained model. - Metrics map[string]float64 `json:"metrics,omitempty"` - // ModelName: Fully qualified name of the CustomTuningModel. - ModelName string `json:"modelName,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 job - // creation is in progress. * **training**: Model is actively training. * - // **evaluating**: The model is evaluating trained metrics. * **indexing**: The - // model trained metrics are indexing. * **ready**: The model is ready for - // serving. - ModelStatus string `json:"modelStatus,omitempty"` - // ForceSendFields is a list of field names (e.g. "ErrorConfig") to +} + +func (s GoogleCloudDiscoveryengineV1betaControlSynonymsAction) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaControlSynonymsAction + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// 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"` + // UpdateTime: Operation last update time. If the operation is done, this is + // also the finish time. + UpdateTime string `json:"updateTime,omitempty"` + // ForceSendFields is a list of field names (e.g. "CreateTime") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "ErrorConfig") to include in API + // NullFields is a list of field names (e.g. "CreateTime") to include in API // requests with the JSON null value. By default, fields with empty values are // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaTrainCustomModelResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaTrainCustomModelResponse +func (s GoogleCloudDiscoveryengineV1betaCreateDataStoreMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaCreateDataStoreMetadata return gensupport.MarshalJSON(NoMethod(s), 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"` - // 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. See +// 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"` + // UpdateTime: Operation last update time. If the operation is done, this is + // also the finish time. + UpdateTime string `json:"updateTime,omitempty"` + // ForceSendFields is a list of field names (e.g. "CreateTime") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Cost") to include in API requests - // with the JSON null value. By default, fields with empty values are omitted - // from API requests. See + // NullFields is a list of field names (e.g. "CreateTime") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaTransactionInfo) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaTransactionInfo +func (s GoogleCloudDiscoveryengineV1betaCreateEngineMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaCreateEngineMetadata return gensupport.MarshalJSON(NoMethod(s), 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 +// GoogleCloudDiscoveryengineV1betaCreateEvaluationMetadata: Metadata for +// EvaluationService.CreateEvaluation method. +type GoogleCloudDiscoveryengineV1betaCreateEvaluationMetadata struct { } -// 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}/locations/{location}/collections/{collection_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. See +// 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"` + // ForceSendFields is a list of field names (e.g. "CreateTime") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Engine") to include in API + // NullFields is a list of field names (e.g. "CreateTime") to include in API // requests with the JSON null value. By default, fields with empty values are // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaTuneEngineMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaTuneEngineMetadata +func (s GoogleCloudDiscoveryengineV1betaCreateSchemaMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaCreateSchemaMetadata return gensupport.MarshalJSON(NoMethod(s), 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 { +// GoogleCloudDiscoveryengineV1betaCreateSitemapMetadata: Metadata related to +// the progress of the SiteSearchEngineService.CreateSitemap operation. This +// will be returned by the google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1betaCreateSitemapMetadata struct { + // CreateTime: Operation create time. + CreateTime string `json:"createTime,omitempty"` + // UpdateTime: Operation last update time. If the operation is done, this is + // also the finish time. + UpdateTime string `json:"updateTime,omitempty"` + // ForceSendFields is a list of field names (e.g. "CreateTime") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "CreateTime") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` } -// GoogleCloudDiscoveryengineV1alphaTuneEngineResponse: Response associated -// with a tune operation. -type GoogleCloudDiscoveryengineV1alphaTuneEngineResponse struct { +func (s GoogleCloudDiscoveryengineV1betaCreateSitemapMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaCreateSitemapMetadata + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaUpdateCmekConfigMetadata: Metadata related -// to the progress of the CmekConfigService.UpdateCmekConfig operation. This -// will be returned by the google.longrunning.Operation.metadata field. -type GoogleCloudDiscoveryengineV1alphaUpdateCmekConfigMetadata struct { +// 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"` // UpdateTime: Operation last update time. If the operation is done, this is @@ -16455,75 +18742,189 @@ type GoogleCloudDiscoveryengineV1alphaUpdateCmekConfigMetadata struct { // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "CreateTime") to include in API - // requests with the JSON null value. By default, fields with empty values are - // omitted from API requests. See + // NullFields is a list of field names (e.g. "CreateTime") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1betaCreateTargetSiteMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaCreateTargetSiteMetadata + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1betaDataStore: DataStore captures global +// settings and configs at the DataStore level. +type GoogleCloudDiscoveryengineV1betaDataStore struct { + // AdvancedSiteSearchConfig: Optional. Configuration for advanced site search. + AdvancedSiteSearchConfig *GoogleCloudDiscoveryengineV1betaAdvancedSiteSearchConfig `json:"advancedSiteSearchConfig,omitempty"` + // BillingEstimation: Output only. Data size estimation for billing. + BillingEstimation *GoogleCloudDiscoveryengineV1betaDataStoreBillingEstimation `json:"billingEstimation,omitempty"` + // CmekConfig: Output only. CMEK-related information for the DataStore. + CmekConfig *GoogleCloudDiscoveryengineV1betaCmekConfig `json:"cmekConfig,omitempty"` + // 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. + // "GOOGLE_WORKSPACE" - The data store is used for workspace search. Details + // of workspace data store are specified in the WorkspaceConfig. + 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"` + // DocumentProcessingConfig: Configuration for Document understanding and + // enrichment. + DocumentProcessingConfig *GoogleCloudDiscoveryengineV1betaDocumentProcessingConfig `json:"documentProcessingConfig,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. + // "HEALTHCARE_FHIR" - The healthcare FHIR vertical. + IndustryVertical string `json:"industryVertical,omitempty"` + // IsInfobotFaqDataStore: Optional. If set, this DataStore is an Infobot FAQ + // DataStore. + IsInfobotFaqDataStore bool `json:"isInfobotFaqDataStore,omitempty"` + // KmsKeyName: Input only. The KMS key to be used to protect this DataStore at + // creation time. Must be set for requests that need to comply with CMEK Org + // Policy protections. If this field is set and processed successfully, the + // DataStore will be protected by the KMS key, as indicated in the cmek_config + // field. + KmsKeyName string `json:"kmsKeyName,omitempty"` + // LanguageInfo: Language info for DataStore. + LanguageInfo *GoogleCloudDiscoveryengineV1betaLanguageInfo `json:"languageInfo,omitempty"` + // Name: Immutable. The full resource name of the data store. Format: + // `projects/{project}/locations/{location}/collections/{collection_id}/dataStor + // es/{data_store_id}`. This field must be a UTF-8 encoded string with a length + // limit of 1024 characters. + Name string `json:"name,omitempty"` + // NaturalLanguageQueryUnderstandingConfig: Optional. Configuration for Natural + // Language Query Understanding. + NaturalLanguageQueryUnderstandingConfig *GoogleCloudDiscoveryengineV1betaNaturalLanguageQueryUnderstandingConfig `json:"naturalLanguageQueryUnderstandingConfig,omitempty"` + // ServingConfigDataStore: Optional. Stores serving config at DataStore level. + ServingConfigDataStore *GoogleCloudDiscoveryengineV1betaDataStoreServingConfigDataStore `json:"servingConfigDataStore,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. + // "SOLUTION_TYPE_GENERATIVE_CHAT" - Used for use cases related to the + // Generative Chat agent. It's used for Generative chat engine only, the + // associated data stores must enrolled with `SOLUTION_TYPE_CHAT` solution. + SolutionTypes []string `json:"solutionTypes,omitempty"` + // StartingSchema: The start schema to use for this DataStore when provisioning + // it. If unset, a default vertical specialized schema will be used. This field + // is only used by CreateDataStore API, and will be ignored if used in other + // APIs. This field will be omitted from all API responses including + // CreateDataStore API. To retrieve a schema of a DataStore, use + // SchemaService.GetSchema API instead. The provided schema will be validated + // against certain rules on schema. Learn more from this doc + // (https://cloud.google.com/generative-ai-app-builder/docs/provide-schema). + StartingSchema *GoogleCloudDiscoveryengineV1betaSchema `json:"startingSchema,omitempty"` + // WorkspaceConfig: Config to store data store type configuration for workspace + // data. This must be set when DataStore.content_config is set as + // DataStore.ContentConfig.GOOGLE_WORKSPACE. + WorkspaceConfig *GoogleCloudDiscoveryengineV1betaWorkspaceConfig `json:"workspaceConfig,omitempty"` + // ForceSendFields is a list of field names (e.g. "AdvancedSiteSearchConfig") + // to unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "AdvancedSiteSearchConfig") to + // include in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaUpdateCmekConfigMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaUpdateCmekConfigMetadata +func (s GoogleCloudDiscoveryengineV1betaDataStore) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaDataStore return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// 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 +// GoogleCloudDiscoveryengineV1betaDataStoreBillingEstimation: Estimation of +// data size per data store. +type GoogleCloudDiscoveryengineV1betaDataStoreBillingEstimation struct { + // StructuredDataSize: Data size for structured data in terms of bytes. + StructuredDataSize int64 `json:"structuredDataSize,omitempty,string"` + // StructuredDataUpdateTime: Last updated timestamp for structured data. + StructuredDataUpdateTime string `json:"structuredDataUpdateTime,omitempty"` + // UnstructuredDataSize: Data size for unstructured data in terms of bytes. + UnstructuredDataSize int64 `json:"unstructuredDataSize,omitempty,string"` + // UnstructuredDataUpdateTime: Last updated timestamp for unstructured data. + UnstructuredDataUpdateTime string `json:"unstructuredDataUpdateTime,omitempty"` + // WebsiteDataSize: Data size for websites in terms of bytes. + WebsiteDataSize int64 `json:"websiteDataSize,omitempty,string"` + // WebsiteDataUpdateTime: Last updated timestamp for websites. + WebsiteDataUpdateTime string `json:"websiteDataUpdateTime,omitempty"` + // ForceSendFields is a list of field names (e.g. "StructuredDataSize") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "CreateTime") to include in API - // requests with the JSON null value. By default, fields with empty values are - // omitted from API requests. See + // NullFields is a list of field names (e.g. "StructuredDataSize") to include + // in API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaUpdateSchemaMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaUpdateSchemaMetadata +func (s GoogleCloudDiscoveryengineV1betaDataStoreBillingEstimation) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaDataStoreBillingEstimation return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaUpdateSessionRequest: Request for -// UpdateSession method. -type GoogleCloudDiscoveryengineV1alphaUpdateSessionRequest struct { - // Session: Required. The Session to update. - Session *GoogleCloudDiscoveryengineV1alphaSession `json:"session,omitempty"` - // UpdateMask: Indicates which fields in the provided Session to update. The - // following are NOT supported: * Session.name If not set or empty, all - // supported fields are updated. - UpdateMask string `json:"updateMask,omitempty"` - // ForceSendFields is a list of field names (e.g. "Session") to unconditionally - // include in API requests. By default, fields with empty or default values are - // omitted from API requests. See +// GoogleCloudDiscoveryengineV1betaDataStoreServingConfigDataStore: Stores +// information regarding the serving configurations at DataStore level. +type GoogleCloudDiscoveryengineV1betaDataStoreServingConfigDataStore struct { + // DisabledForServing: If set true, the DataStore will not be available for + // serving search requests. + DisabledForServing bool `json:"disabledForServing,omitempty"` + // ForceSendFields is a list of field names (e.g. "DisabledForServing") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Session") to include in API - // requests with the JSON null value. By default, fields with empty values are - // omitted from API requests. See + // NullFields is a list of field names (e.g. "DisabledForServing") to include + // in API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaUpdateSessionRequest) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaUpdateSessionRequest +func (s GoogleCloudDiscoveryengineV1betaDataStoreServingConfigDataStore) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaDataStoreServingConfigDataStore return gensupport.MarshalJSON(NoMethod(s), 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 { +// 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"` // UpdateTime: Operation last update time. If the operation is done, this is @@ -16535,274 +18936,130 @@ type GoogleCloudDiscoveryengineV1alphaUpdateTargetSiteMetadata struct { // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "CreateTime") to include in API - // requests with the JSON null value. By default, fields with empty values are - // omitted from API requests. See - // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. - NullFields []string `json:"-"` -} - -func (s GoogleCloudDiscoveryengineV1alphaUpdateTargetSiteMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaUpdateTargetSiteMetadata - return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) -} - -// GoogleCloudDiscoveryengineV1alphaUserEvent: UserEvent captures all metadata -// information Discovery Engine API needs to know about how end users interact -// with your website. -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"` - // ConversionType: Optional. Conversion type. Required if UserEvent.event_type - // is `conversion`. This is a customer-defined conversion name in lowercase - // letters or numbers separated by "-", such as "watch", "good-visit" etc. Do - // not set the field if UserEvent.event_type is not `conversion`. This mixes - // the custom conversion event with predefined events like `search`, - // `view-item` etc. - ConversionType string `json:"conversionType,omitempty"` - // DataStore: The DataStore resource full name, of the form - // `projects/{project}/locations/{location}/collections/{collection_id}/dataStor - // es/{data_store_id}`. Optional. Only required for user events whose data - // store can't by determined by UserEvent.engine or UserEvent.documents. If - // data store is set in the parent of write/import/collect user event requests, - // this field can be omitted. - DataStore string `json:"dataStore,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"` - // Engine: The Engine resource name, in the form of - // `projects/{project}/locations/{location}/collections/{collection_id}/engines/ - // {engine_id}`. Optional. Only required for Engine produced user events. For - // example, user events from blended search. - Engine string `json:"engine,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 * `add-feedback`: Add a user - // feedback. 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. Custom conversion value: * `conversion`: Customer defined - // conversion event. - 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"` - // Panels: Optional. List of panels associated with this event. Used for - // page-level impression data. - Panels []*GoogleCloudDiscoveryengineV1alphaPanelInfo `json:"panels,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. - 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"` + // NullFields is a list of field names (e.g. "CreateTime") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} - // 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 +func (s GoogleCloudDiscoveryengineV1betaDeleteDataStoreMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaDeleteDataStoreMetadata + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// 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"` + // UpdateTime: Operation last update time. If the operation is done, this is + // also the finish time. + UpdateTime string `json:"updateTime,omitempty"` + // ForceSendFields is a list of field names (e.g. "CreateTime") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Attributes") to include in API + // NullFields is a list of field names (e.g. "CreateTime") to include in API // requests with the JSON null value. By default, fields with empty values are // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaUserEvent) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaUserEvent +func (s GoogleCloudDiscoveryengineV1betaDeleteEngineMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaDeleteEngineMetadata return gensupport.MarshalJSON(NoMethod(s), 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"` - // 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 +// GoogleCloudDiscoveryengineV1betaDeleteSchemaMetadata: Metadata for +// DeleteSchema LRO. +type GoogleCloudDiscoveryengineV1betaDeleteSchemaMetadata struct { + // CreateTime: Operation create time. + CreateTime string `json:"createTime,omitempty"` + // UpdateTime: Operation last update time. If the operation is done, this is + // also the finish time. + UpdateTime string `json:"updateTime,omitempty"` + // ForceSendFields is a list of field names (e.g. "CreateTime") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "UserAgent") to include in API + // NullFields is a list of field names (e.g. "CreateTime") to include in API // requests with the JSON null value. By default, fields with empty values are // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaUserInfo) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaUserInfo +func (s GoogleCloudDiscoveryengineV1betaDeleteSchemaMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaDeleteSchemaMetadata return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1alphaWorkspaceConfig: Config to store data store -// type configuration for workspace data -type GoogleCloudDiscoveryengineV1alphaWorkspaceConfig struct { - // DasherCustomerId: Obfuscated Dasher customer ID. - DasherCustomerId string `json:"dasherCustomerId,omitempty"` - // SuperAdminEmailAddress: Optional. The super admin email address for the - // workspace that will be used for access token generation. For now we only use - // it for Native Google Drive connector data ingestion. - SuperAdminEmailAddress string `json:"superAdminEmailAddress,omitempty"` - // SuperAdminServiceAccount: Optional. The super admin service account for the - // workspace that will be used for access token generation. For now we only use - // it for Native Google Drive connector data ingestion. - SuperAdminServiceAccount string `json:"superAdminServiceAccount,omitempty"` - // Type: The Google Workspace data source. - // - // Possible values: - // "TYPE_UNSPECIFIED" - Defaults to an unspecified Workspace type. - // "GOOGLE_DRIVE" - Workspace Data Store contains Drive data - // "GOOGLE_MAIL" - Workspace Data Store contains Mail data - // "GOOGLE_SITES" - Workspace Data Store contains Sites data - // "GOOGLE_CALENDAR" - Workspace Data Store contains Calendar data - // "GOOGLE_CHAT" - Workspace Data Store contains Chat data - // "GOOGLE_GROUPS" - Workspace Data Store contains Groups data - // "GOOGLE_KEEP" - Workspace Data Store contains Keep data - Type string `json:"type,omitempty"` - // ForceSendFields is a list of field names (e.g. "DasherCustomerId") to +// GoogleCloudDiscoveryengineV1betaDeleteSitemapMetadata: Metadata related to +// the progress of the SiteSearchEngineService.DeleteSitemap operation. This +// will be returned by the google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1betaDeleteSitemapMetadata struct { + // CreateTime: Operation create time. + CreateTime string `json:"createTime,omitempty"` + // UpdateTime: Operation last update time. If the operation is done, this is + // also the finish time. + UpdateTime string `json:"updateTime,omitempty"` + // ForceSendFields is a list of field names (e.g. "CreateTime") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "DasherCustomerId") to include in - // API requests with the JSON null value. By default, fields with empty values - // are omitted from API requests. See + // NullFields is a list of field names (e.g. "CreateTime") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1alphaWorkspaceConfig) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1alphaWorkspaceConfig +func (s GoogleCloudDiscoveryengineV1betaDeleteSitemapMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaDeleteSitemapMetadata return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaAdvancedSiteSearchConfig: Configuration data -// for advance site search. -type GoogleCloudDiscoveryengineV1betaAdvancedSiteSearchConfig struct { +// 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"` + // UpdateTime: Operation last update time. If the operation is done, this is + // also the finish time. + UpdateTime string `json:"updateTime,omitempty"` + // ForceSendFields is a list of field names (e.g. "CreateTime") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "CreateTime") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` } -// GoogleCloudDiscoveryengineV1betaBatchCreateTargetSiteMetadata: Metadata +func (s GoogleCloudDiscoveryengineV1betaDeleteTargetSiteMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaDeleteTargetSiteMetadata + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1betaDisableAdvancedSiteSearchMetadata: Metadata // related to the progress of the -// SiteSearchEngineService.BatchCreateTargetSites operation. This will be +// SiteSearchEngineService.DisableAdvancedSiteSearch operation. This will be // returned by the google.longrunning.Operation.metadata field. -type GoogleCloudDiscoveryengineV1betaBatchCreateTargetSiteMetadata struct { +type GoogleCloudDiscoveryengineV1betaDisableAdvancedSiteSearchMetadata struct { // CreateTime: Operation create time. CreateTime string `json:"createTime,omitempty"` // UpdateTime: Operation last update time. If the operation is done, this is @@ -16821,198 +19078,259 @@ type GoogleCloudDiscoveryengineV1betaBatchCreateTargetSiteMetadata struct { NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1betaBatchCreateTargetSiteMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaBatchCreateTargetSiteMetadata +func (s GoogleCloudDiscoveryengineV1betaDisableAdvancedSiteSearchMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaDisableAdvancedSiteSearchMetadata return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// 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. "TargetSites") to +// GoogleCloudDiscoveryengineV1betaDisableAdvancedSiteSearchResponse: Response +// message for SiteSearchEngineService.DisableAdvancedSiteSearch method. +type GoogleCloudDiscoveryengineV1betaDisableAdvancedSiteSearchResponse struct { +} + +// GoogleCloudDiscoveryengineV1betaDocumentProcessingConfig: A singleton +// resource of DataStore. If it's empty when DataStore is created and DataStore +// is set to DataStore.ContentConfig.CONTENT_REQUIRED, the default parser will +// default to digital parser. +type GoogleCloudDiscoveryengineV1betaDocumentProcessingConfig struct { + // ChunkingConfig: Whether chunking mode is enabled. + ChunkingConfig *GoogleCloudDiscoveryengineV1betaDocumentProcessingConfigChunkingConfig `json:"chunkingConfig,omitempty"` + // DefaultParsingConfig: Configurations for default Document parser. If not + // specified, we will configure it as default DigitalParsingConfig, and the + // default parsing config will be applied to all file types for Document + // parsing. + DefaultParsingConfig *GoogleCloudDiscoveryengineV1betaDocumentProcessingConfigParsingConfig `json:"defaultParsingConfig,omitempty"` + // Name: The full resource name of the Document Processing Config. Format: + // `projects/*/locations/*/collections/*/dataStores/*/documentProcessingConfig`. + Name string `json:"name,omitempty"` + // ParsingConfigOverrides: Map from file type to override the default parsing + // configuration based on the file type. Supported keys: * `pdf`: Override + // parsing config for PDF files, either digital parsing, ocr parsing or layout + // parsing is supported. * `html`: Override parsing config for HTML files, only + // digital parsing and layout parsing are supported. * `docx`: Override parsing + // config for DOCX files, only digital parsing and layout parsing are + // supported. * `pptx`: Override parsing config for PPTX files, only digital + // parsing and layout parsing are supported. * `xlsm`: Override parsing config + // for XLSM files, only digital parsing and layout parsing are supported. * + // `xlsx`: Override parsing config for XLSX files, only digital parsing and + // layout parsing are supported. + ParsingConfigOverrides map[string]GoogleCloudDiscoveryengineV1betaDocumentProcessingConfigParsingConfig `json:"parsingConfigOverrides,omitempty"` + // ForceSendFields is a list of field names (e.g. "ChunkingConfig") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. 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. See + // NullFields is a list of field names (e.g. "ChunkingConfig") to include in + // API requests with the JSON null value. By default, fields with empty values + // are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1betaBatchCreateTargetSitesResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaBatchCreateTargetSitesResponse +func (s GoogleCloudDiscoveryengineV1betaDocumentProcessingConfig) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaDocumentProcessingConfig return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaCmekConfig: Configurations used to enable -// CMEK data encryption with Cloud KMS keys. -type GoogleCloudDiscoveryengineV1betaCmekConfig struct { - // IsDefault: Output only. The default CmekConfig for the Customer. - IsDefault bool `json:"isDefault,omitempty"` - // KmsKey: Kms key resource name which will be used to encrypt resources - // `projects/{project}/locations/{location}/keyRings/{keyRing}/cryptoKeys/{keyId - // }`. - KmsKey string `json:"kmsKey,omitempty"` - // KmsKeyVersion: Kms key version resource name which will be used to encrypt - // resources `/cryptoKeyVersions/{keyVersion}`. - KmsKeyVersion string `json:"kmsKeyVersion,omitempty"` - // LastRotationTimestampMicros: Output only. The timestamp of the last key - // rotation. - LastRotationTimestampMicros int64 `json:"lastRotationTimestampMicros,omitempty,string"` - // Name: Required. Name of the CmekConfig, of the form - // `projects/{project}/locations/{location}/cmekConfig` or - // `projects/{project}/locations/{location}/cmekConfigs/{cmekConfig}`. - Name string `json:"name,omitempty"` - // State: Output only. State of the CmekConfig. - // - // Possible values: - // "STATE_UNSPECIFIED" - The CmekConfig state is unknown. - // "CREATING" - The CmekConfig is creating. - // "ACTIVE" - The CmekConfig can be used with DataStores. - // "KEY_ISSUE" - The CmekConfig is unavailable, most likely due to the KMS - // Key being revoked. - // "DELETING" - The CmekConfig is deleting. - // "UNUSABLE" - The CmekConfig is not usable, most likely due to some - // internal issue. - // "ACTIVE_ROTATING" - The KMS key version is being rotated. - State string `json:"state,omitempty"` - // ForceSendFields is a list of field names (e.g. "IsDefault") to +// GoogleCloudDiscoveryengineV1betaDocumentProcessingConfigChunkingConfig: +// Configuration for chunking config. +type GoogleCloudDiscoveryengineV1betaDocumentProcessingConfigChunkingConfig struct { + // LayoutBasedChunkingConfig: Configuration for the layout based chunking. + LayoutBasedChunkingConfig *GoogleCloudDiscoveryengineV1betaDocumentProcessingConfigChunkingConfigLayoutBasedChunkingConfig `json:"layoutBasedChunkingConfig,omitempty"` + // ForceSendFields is a list of field names (e.g. "LayoutBasedChunkingConfig") + // to unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "LayoutBasedChunkingConfig") to + // include in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1betaDocumentProcessingConfigChunkingConfig) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaDocumentProcessingConfigChunkingConfig + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1betaDocumentProcessingConfigChunkingConfigLayoutB +// asedChunkingConfig: Configuration for the layout based chunking. +type GoogleCloudDiscoveryengineV1betaDocumentProcessingConfigChunkingConfigLayoutBasedChunkingConfig struct { + // ChunkSize: The token size limit for each chunk. Supported values: 100-500 + // (inclusive). Default value: 500. + ChunkSize int64 `json:"chunkSize,omitempty"` + // IncludeAncestorHeadings: Whether to include appending different levels of + // headings to chunks from the middle of the document to prevent context loss. + // Default value: False. + IncludeAncestorHeadings bool `json:"includeAncestorHeadings,omitempty"` + // ForceSendFields is a list of field names (e.g. "ChunkSize") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "IsDefault") to include in API + // NullFields is a list of field names (e.g. "ChunkSize") to include in API // requests with the JSON null value. By default, fields with empty values are // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1betaCmekConfig) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaCmekConfig +func (s GoogleCloudDiscoveryengineV1betaDocumentProcessingConfigChunkingConfigLayoutBasedChunkingConfig) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaDocumentProcessingConfigChunkingConfigLayoutBasedChunkingConfig return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaCondition: Defines circumstances to be -// checked before allowing a behavior -type GoogleCloudDiscoveryengineV1betaCondition struct { - // ActiveTimeRange: Range of time(s) specifying when condition is active. - // Maximum of 10 time ranges. - ActiveTimeRange []*GoogleCloudDiscoveryengineV1betaConditionTimeRange `json:"activeTimeRange,omitempty"` - // QueryRegex: Optional. Query regex to match the whole search query. Cannot be - // set when Condition.query_terms is set. This is currently supporting - // promotion use case. - QueryRegex string `json:"queryRegex,omitempty"` - // QueryTerms: Search only A list of terms to match the query on. Cannot be set - // when Condition.query_regex is set. Maximum of 10 query terms. - QueryTerms []*GoogleCloudDiscoveryengineV1betaConditionQueryTerm `json:"queryTerms,omitempty"` - // ForceSendFields is a list of field names (e.g. "ActiveTimeRange") to +// GoogleCloudDiscoveryengineV1betaDocumentProcessingConfigParsingConfig: +// Related configurations applied to a specific type of document parser. +type GoogleCloudDiscoveryengineV1betaDocumentProcessingConfigParsingConfig struct { + // DigitalParsingConfig: Configurations applied to digital parser. + DigitalParsingConfig *GoogleCloudDiscoveryengineV1betaDocumentProcessingConfigParsingConfigDigitalParsingConfig `json:"digitalParsingConfig,omitempty"` + // LayoutParsingConfig: Configurations applied to layout parser. + LayoutParsingConfig *GoogleCloudDiscoveryengineV1betaDocumentProcessingConfigParsingConfigLayoutParsingConfig `json:"layoutParsingConfig,omitempty"` + // OcrParsingConfig: Configurations applied to OCR parser. Currently it only + // applies to PDFs. + OcrParsingConfig *GoogleCloudDiscoveryengineV1betaDocumentProcessingConfigParsingConfigOcrParsingConfig `json:"ocrParsingConfig,omitempty"` + // ForceSendFields is a list of field names (e.g. "DigitalParsingConfig") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "ActiveTimeRange") to include in - // API requests with the JSON null value. By default, fields with empty values - // are omitted from API requests. See + // NullFields is a list of field names (e.g. "DigitalParsingConfig") to include + // in API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1betaCondition) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaCondition +func (s GoogleCloudDiscoveryengineV1betaDocumentProcessingConfigParsingConfig) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaDocumentProcessingConfigParsingConfig return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaConditionQueryTerm: Matcher for search -// request query -type GoogleCloudDiscoveryengineV1betaConditionQueryTerm struct { - // FullMatch: Whether the search query needs to exactly match the query term. - FullMatch bool `json:"fullMatch,omitempty"` - // Value: The specific query value to match against Must be lowercase, must be - // UTF-8. Can have at most 3 space separated terms if full_match is true. - // Cannot be an empty string. Maximum length of 5000 characters. - Value string `json:"value,omitempty"` - // ForceSendFields is a list of field names (e.g. "FullMatch") to - // unconditionally include in API requests. By default, fields with empty or +// GoogleCloudDiscoveryengineV1betaDocumentProcessingConfigParsingConfigDigitalP +// arsingConfig: The digital parsing configurations for documents. +type GoogleCloudDiscoveryengineV1betaDocumentProcessingConfigParsingConfigDigitalParsingConfig struct { +} + +// GoogleCloudDiscoveryengineV1betaDocumentProcessingConfigParsingConfigLayoutPa +// rsingConfig: The layout parsing configurations for documents. +type GoogleCloudDiscoveryengineV1betaDocumentProcessingConfigParsingConfigLayoutParsingConfig struct { +} + +// GoogleCloudDiscoveryengineV1betaDocumentProcessingConfigParsingConfigOcrParsi +// ngConfig: The OCR parsing configurations for documents. +type GoogleCloudDiscoveryengineV1betaDocumentProcessingConfigParsingConfigOcrParsingConfig struct { + // EnhancedDocumentElements: [DEPRECATED] This field is deprecated. To use the + // additional enhanced document elements processing, please switch to + // `layout_parsing_config`. + 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. "EnhancedDocumentElements") + // to unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "FullMatch") to include in API - // requests with the JSON null value. By default, fields with empty values are - // omitted from API requests. See + // NullFields is a list of field names (e.g. "EnhancedDocumentElements") to + // include in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1betaConditionQueryTerm) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaConditionQueryTerm +func (s GoogleCloudDiscoveryengineV1betaDocumentProcessingConfigParsingConfigOcrParsingConfig) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaDocumentProcessingConfigParsingConfigOcrParsingConfig return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaConditionTimeRange: Used for time-dependent -// conditions. -type GoogleCloudDiscoveryengineV1betaConditionTimeRange struct { - // EndTime: End of time range. Range is inclusive. Must be in the future. - EndTime string `json:"endTime,omitempty"` - // StartTime: Start of time range. Range is inclusive. - StartTime string `json:"startTime,omitempty"` - // ForceSendFields is a list of field names (e.g. "EndTime") to unconditionally - // include in API requests. By default, fields with empty or default values are - // omitted from API requests. See +// 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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "EndTime") to include in API + // NullFields is a list of field names (e.g. "CreateTime") to include in API // requests with the JSON null value. By default, fields with empty values are // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1betaConditionTimeRange) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaConditionTimeRange +func (s GoogleCloudDiscoveryengineV1betaEnableAdvancedSiteSearchMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaEnableAdvancedSiteSearchMetadata return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaControl: Defines a conditioned behavior to -// employ during serving. Must be attached to a ServingConfig to be considered -// at serving time. Permitted actions dependent on `SolutionType`. -type GoogleCloudDiscoveryengineV1betaControl struct { - // AssociatedServingConfigIds: Output only. List of all ServingConfig IDs this - // control is attached to. May take up to 10 minutes to update after changes. - AssociatedServingConfigIds []string `json:"associatedServingConfigIds,omitempty"` - // BoostAction: Defines a boost-type control - BoostAction *GoogleCloudDiscoveryengineV1betaControlBoostAction `json:"boostAction,omitempty"` - // Conditions: Determines when the associated action will trigger. Omit to - // always apply the action. Currently only a single condition may be specified. - // Otherwise an INVALID ARGUMENT error is thrown. - Conditions []*GoogleCloudDiscoveryengineV1betaCondition `json:"conditions,omitempty"` - // DisplayName: Required. Human readable name. The identifier used in UI views. - // Must be UTF-8 encoded string. Length limit is 128 characters. Otherwise an - // INVALID ARGUMENT error is thrown. +// GoogleCloudDiscoveryengineV1betaEnableAdvancedSiteSearchResponse: Response +// message for SiteSearchEngineService.EnableAdvancedSiteSearch method. +type GoogleCloudDiscoveryengineV1betaEnableAdvancedSiteSearchResponse struct { +} + +// 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"` + // DisableAnalytics: Optional. Whether to disable analytics for searches + // performed on this engine. + DisableAnalytics bool `json:"disableAnalytics,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"` - // FilterAction: Defines a filter-type control Currently not supported by - // Recommendation - FilterAction *GoogleCloudDiscoveryengineV1betaControlFilterAction `json:"filterAction,omitempty"` - // Name: Immutable. Fully qualified name - // `projects/*/locations/global/dataStore/*/controls/*` + // IndustryVertical: The industry vertical that the engine registers. The + // restriction of the Engine industry vertical is based on DataStore: Vertical + // on Engine has to match vertical of the DataStore linked 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. + // "HEALTHCARE_FHIR" - The healthcare FHIR 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}/locations/{location}/collections/{collection}/engines/{en + // gine}` 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"` - // PromoteAction: Promote certain links based on predefined trigger queries. - // This now only supports basic site search. - PromoteAction *GoogleCloudDiscoveryengineV1betaControlPromoteAction `json:"promoteAction,omitempty"` - // RedirectAction: Defines a redirect-type control. - RedirectAction *GoogleCloudDiscoveryengineV1betaControlRedirectAction `json:"redirectAction,omitempty"` - // SolutionType: Required. Immutable. What solution the control belongs to. - // Must be compatible with vertical of resource. Otherwise an INVALID ARGUMENT - // error is thrown. + // 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. @@ -17024,313 +19342,354 @@ type GoogleCloudDiscoveryengineV1betaControl struct { // Generative Chat agent. It's used for Generative chat engine only, the // associated data stores must enrolled with `SOLUTION_TYPE_CHAT` solution. SolutionType string `json:"solutionType,omitempty"` - // SynonymsAction: Treats a group of terms as synonyms of one another. - SynonymsAction *GoogleCloudDiscoveryengineV1betaControlSynonymsAction `json:"synonymsAction,omitempty"` - // UseCases: Specifies the use case for the control. Affects what condition - // fields can be set. Only applies to SOLUTION_TYPE_SEARCH. Currently only - // allow one use case per control. Must be set when solution_type is - // SolutionType.SOLUTION_TYPE_SEARCH. - // - // Possible values: - // "SEARCH_USE_CASE_UNSPECIFIED" - Value used when unset. Will not occur in - // CSS. - // "SEARCH_USE_CASE_SEARCH" - Search use case. Expects the traffic has a - // non-empty query. - // "SEARCH_USE_CASE_BROWSE" - Browse use case. Expects the traffic has an - // empty query. - UseCases []string `json:"useCases,omitempty"` - // ForceSendFields is a list of field names (e.g. "AssociatedServingConfigIds") - // to unconditionally include in API requests. By default, fields with empty or + // 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. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + 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. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1betaEngine) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaEngine + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// 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"` + // 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. 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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "AssociatedServingConfigIds") to - // include in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. See + // NullFields is a list of field names (e.g. "AgentCreationConfig") to include + // in API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1betaControl) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaControl +func (s GoogleCloudDiscoveryengineV1betaEngineChatEngineConfig) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaEngineChatEngineConfig return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaControlBoostAction: Adjusts order of -// products in returned list. -type GoogleCloudDiscoveryengineV1betaControlBoostAction struct { - // Boost: Required. Strength of the boost, which should be in [-1, 1]. Negative - // boost means demotion. Default is 0.0 (No-op). - Boost float64 `json:"boost,omitempty"` - // DataStore: Required. Specifies which data store's documents can be boosted - // by this control. Full data store name e.g. - // projects/123/locations/global/collections/default_collection/dataStores/defau - // lt_data_store - DataStore string `json:"dataStore,omitempty"` - // Filter: Required. Specifies which products to apply the boost to. If no - // filter is provided all products will be boosted (No-op). Syntax - // documentation: https://cloud.google.com/retail/docs/filter-and-order Maximum - // length is 5000 characters. Otherwise an INVALID ARGUMENT error is thrown. - Filter string `json:"filter,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. See +// GoogleCloudDiscoveryengineV1betaEngineChatEngineConfigAgentCreationConfig: +// 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"` + // 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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Boost") to include in API + // 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. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1betaControlBoostAction) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaControlBoostAction +func (s GoogleCloudDiscoveryengineV1betaEngineChatEngineConfigAgentCreationConfig) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaEngineChatEngineConfigAgentCreationConfig return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -func (s *GoogleCloudDiscoveryengineV1betaControlBoostAction) UnmarshalJSON(data []byte) error { - type NoMethod GoogleCloudDiscoveryengineV1betaControlBoostAction - 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 -} - -// GoogleCloudDiscoveryengineV1betaControlFilterAction: Specified which -// products may be included in results. Uses same filter as boost. -type GoogleCloudDiscoveryengineV1betaControlFilterAction struct { - // DataStore: Required. Specifies which data store's documents can be filtered - // by this control. Full data store name e.g. - // projects/123/locations/global/collections/default_collection/dataStores/defau - // lt_data_store - DataStore string `json:"dataStore,omitempty"` - // Filter: Required. A filter to apply on the matching condition results. - // Required Syntax documentation: - // https://cloud.google.com/retail/docs/filter-and-order Maximum length is 5000 - // characters. Otherwise an INVALID ARGUMENT error is thrown. - Filter string `json:"filter,omitempty"` - // ForceSendFields is a list of field names (e.g. "DataStore") to +// 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. "DialogflowAgent") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // 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. See + // 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. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1betaControlFilterAction) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaControlFilterAction +func (s GoogleCloudDiscoveryengineV1betaEngineChatEngineMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaEngineChatEngineMetadata return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaControlPromoteAction: Promote certain links -// based on some trigger queries. Example: Promote shoe store link when -// searching for `shoe` keyword. The link can be outside of associated data -// store. -type GoogleCloudDiscoveryengineV1betaControlPromoteAction struct { - // DataStore: Required. Data store with which this promotion is attached to. - DataStore string `json:"dataStore,omitempty"` - // SearchLinkPromotion: Required. Promotion attached to this action. - SearchLinkPromotion *GoogleCloudDiscoveryengineV1betaSearchLinkPromotion `json:"searchLinkPromotion,omitempty"` - // ForceSendFields is a list of field names (e.g. "DataStore") to +// GoogleCloudDiscoveryengineV1betaEngineCommonConfig: Common configurations +// for an Engine. +type GoogleCloudDiscoveryengineV1betaEngineCommonConfig 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"` + // 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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "DataStore") to include in API + // 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. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1betaControlPromoteAction) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaControlPromoteAction +func (s GoogleCloudDiscoveryengineV1betaEngineCommonConfig) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaEngineCommonConfig return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaControlRedirectAction: Redirects a shopper -// to the provided URI. -type GoogleCloudDiscoveryengineV1betaControlRedirectAction struct { - // RedirectUri: Required. The URI to which the shopper will be redirected. - // Required. URI must have length equal or less than 2000 characters. Otherwise - // an INVALID ARGUMENT error is thrown. - RedirectUri string `json:"redirectUri,omitempty"` - // ForceSendFields is a list of field names (e.g. "RedirectUri") to +// 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"` + // SearchTier: The search feature tier of this engine. Different tiers might + // have different pricing. To learn more, 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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "RedirectUri") to include in API + // 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. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1betaControlRedirectAction) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaControlRedirectAction +func (s GoogleCloudDiscoveryengineV1betaEngineSearchEngineConfig) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaEngineSearchEngineConfig return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaControlSynonymsAction: Creates a set of -// terms that will act as synonyms of one another. Example: "happy" will also -// be considered as "glad", "glad" will also be considered as "happy". -type GoogleCloudDiscoveryengineV1betaControlSynonymsAction struct { - // Synonyms: Defines a set of synonyms. Can specify up to 100 synonyms. Must - // specify at least 2 synonyms. Otherwise an INVALID ARGUMENT error is thrown. - Synonyms []string `json:"synonyms,omitempty"` - // ForceSendFields is a list of field names (e.g. "Synonyms") to +// GoogleCloudDiscoveryengineV1betaEvaluation: An evaluation is a single +// execution (or run) of an evaluation process. It encapsulates the state of +// the evaluation and the resulting data. +type GoogleCloudDiscoveryengineV1betaEvaluation struct { + // CreateTime: Output only. Timestamp the Evaluation was created at. + CreateTime string `json:"createTime,omitempty"` + // EndTime: Output only. Timestamp the Evaluation was completed at. + EndTime string `json:"endTime,omitempty"` + // Error: Output only. The error that occurred during evaluation. Only + // populated when the evaluation's state is FAILED. + Error *GoogleRpcStatus `json:"error,omitempty"` + // ErrorSamples: Output only. A sample of errors encountered while processing + // the request. + ErrorSamples []*GoogleRpcStatus `json:"errorSamples,omitempty"` + // EvaluationSpec: Required. The specification of the evaluation. + EvaluationSpec *GoogleCloudDiscoveryengineV1betaEvaluationEvaluationSpec `json:"evaluationSpec,omitempty"` + // Name: Identifier. The full resource name of the Evaluation, in the format of + // `projects/{project}/locations/{location}/evaluations/{evaluation}`. This + // field must be a UTF-8 encoded string with a length limit of 1024 characters. + Name string `json:"name,omitempty"` + // QualityMetrics: Output only. The metrics produced by the evaluation, + // averaged across all SampleQuerys in the SampleQuerySet. Only populated when + // the evaluation's state is SUCCEEDED. + QualityMetrics *GoogleCloudDiscoveryengineV1betaQualityMetrics `json:"qualityMetrics,omitempty"` + // State: Output only. The state of the evaluation. + // + // Possible values: + // "STATE_UNSPECIFIED" - The evaluation is unspecified. + // "PENDING" - The service is preparing to run the evaluation. + // "RUNNING" - The evaluation is in progress. + // "SUCCEEDED" - The evaluation completed successfully. + // "FAILED" - The evaluation failed. + State string `json:"state,omitempty"` + // ForceSendFields is a list of field names (e.g. "CreateTime") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Synonyms") to include in API + // NullFields is a list of field names (e.g. "CreateTime") to include in API // requests with the JSON null value. By default, fields with empty values are // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1betaControlSynonymsAction) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaControlSynonymsAction +func (s GoogleCloudDiscoveryengineV1betaEvaluation) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaEvaluation return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// 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"` - // 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 +// GoogleCloudDiscoveryengineV1betaEvaluationEvaluationSpec: Describes the +// specification of the evaluation. +type GoogleCloudDiscoveryengineV1betaEvaluationEvaluationSpec struct { + // QuerySetSpec: Required. The specification of the query set. + QuerySetSpec *GoogleCloudDiscoveryengineV1betaEvaluationEvaluationSpecQuerySetSpec `json:"querySetSpec,omitempty"` + // SearchRequest: Required. The search request that is used to perform the + // evaluation. Only the following fields within SearchRequest are supported; if + // any other fields are provided, an UNSUPPORTED error will be returned: * + // SearchRequest.serving_config * SearchRequest.branch * + // SearchRequest.canonical_filter * SearchRequest.query_expansion_spec * + // SearchRequest.spell_correction_spec * SearchRequest.content_search_spec * + // SearchRequest.user_pseudo_id + SearchRequest *GoogleCloudDiscoveryengineV1betaSearchRequest `json:"searchRequest,omitempty"` + // ForceSendFields is a list of field names (e.g. "QuerySetSpec") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "CreateTime") to include in API + // NullFields is a list of field names (e.g. "QuerySetSpec") to include in API // requests with the JSON null value. By default, fields with empty values are // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1betaCreateDataStoreMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaCreateDataStoreMetadata +func (s GoogleCloudDiscoveryengineV1betaEvaluationEvaluationSpec) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaEvaluationEvaluationSpec return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) -} - -// 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"` - // 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 +} + +// GoogleCloudDiscoveryengineV1betaEvaluationEvaluationSpecQuerySetSpec: +// Describes the specification of the query set. +type GoogleCloudDiscoveryengineV1betaEvaluationEvaluationSpecQuerySetSpec struct { + // SampleQuerySet: Required. The full resource name of the SampleQuerySet used + // for the evaluation, in the format of + // `projects/{project}/locations/{location}/sampleQuerySets/{sampleQuerySet}`. + SampleQuerySet string `json:"sampleQuerySet,omitempty"` + // ForceSendFields is a list of field names (e.g. "SampleQuerySet") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "CreateTime") to include in API - // requests with the JSON null value. By default, fields with empty values are - // omitted from API requests. See + // NullFields is a list of field names (e.g. "SampleQuerySet") to include in + // API requests with the JSON null value. By default, fields with empty values + // are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1betaCreateEngineMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaCreateEngineMetadata +func (s GoogleCloudDiscoveryengineV1betaEvaluationEvaluationSpecQuerySetSpec) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaEvaluationEvaluationSpecQuerySetSpec return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaCreateEvaluationMetadata: Metadata for -// EvaluationService.CreateEvaluation method. -type GoogleCloudDiscoveryengineV1betaCreateEvaluationMetadata struct { -} - -// 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"` - // ForceSendFields is a list of field names (e.g. "CreateTime") to +// GoogleCloudDiscoveryengineV1betaFetchSitemapsResponse: Response message for +// SiteSearchEngineService.FetchSitemaps method. +type GoogleCloudDiscoveryengineV1betaFetchSitemapsResponse struct { + // SitemapsMetadata: List of Sitemaps fetched. + SitemapsMetadata []*GoogleCloudDiscoveryengineV1betaFetchSitemapsResponseSitemapMetadata `json:"sitemapsMetadata,omitempty"` + // ForceSendFields is a list of field names (e.g. "SitemapsMetadata") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "CreateTime") to include in API - // requests with the JSON null value. By default, fields with empty values are - // omitted from API requests. See + // NullFields is a list of field names (e.g. "SitemapsMetadata") to include in + // API requests with the JSON null value. By default, fields with empty values + // are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1betaCreateSchemaMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaCreateSchemaMetadata +func (s GoogleCloudDiscoveryengineV1betaFetchSitemapsResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaFetchSitemapsResponse return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaCreateSitemapMetadata: Metadata related to -// the progress of the SiteSearchEngineService.CreateSitemap operation. This -// will be returned by the google.longrunning.Operation.metadata field. -type GoogleCloudDiscoveryengineV1betaCreateSitemapMetadata struct { - // CreateTime: Operation create time. - CreateTime string `json:"createTime,omitempty"` - // UpdateTime: Operation last update time. If the operation is done, this is - // also the finish time. - UpdateTime string `json:"updateTime,omitempty"` - // ForceSendFields is a list of field names (e.g. "CreateTime") to - // unconditionally include in API requests. By default, fields with empty or - // default values are omitted from API requests. See +// GoogleCloudDiscoveryengineV1betaFetchSitemapsResponseSitemapMetadata: +// Contains a Sitemap and its metadata. +type GoogleCloudDiscoveryengineV1betaFetchSitemapsResponseSitemapMetadata struct { + // Sitemap: The Sitemap. + Sitemap *GoogleCloudDiscoveryengineV1betaSitemap `json:"sitemap,omitempty"` + // ForceSendFields is a list of field names (e.g. "Sitemap") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "CreateTime") to include in API + // NullFields is a list of field names (e.g. "Sitemap") to include in API // requests with the JSON null value. By default, fields with empty values are // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1betaCreateSitemapMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaCreateSitemapMetadata +func (s GoogleCloudDiscoveryengineV1betaFetchSitemapsResponseSitemapMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaFetchSitemapsResponseSitemapMetadata return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// 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 { +// GoogleCloudDiscoveryengineV1betaImportCompletionSuggestionsMetadata: +// Metadata related to the progress of the ImportCompletionSuggestions +// operation. This will be returned by the +// google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1betaImportCompletionSuggestionsMetadata struct { // CreateTime: Operation create time. CreateTime string `json:"createTime,omitempty"` + // FailureCount: Count of CompletionSuggestions that failed to be imported. + FailureCount int64 `json:"failureCount,omitempty,string"` + // SuccessCount: Count of CompletionSuggestions successfully imported. + 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"` @@ -17347,210 +19706,139 @@ type GoogleCloudDiscoveryengineV1betaCreateTargetSiteMetadata struct { NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1betaCreateTargetSiteMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaCreateTargetSiteMetadata +func (s GoogleCloudDiscoveryengineV1betaImportCompletionSuggestionsMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaImportCompletionSuggestionsMetadata return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaDataStore: DataStore captures global -// settings and configs at the DataStore level. -type GoogleCloudDiscoveryengineV1betaDataStore struct { - // AdvancedSiteSearchConfig: Optional. Configuration for advanced site search. - AdvancedSiteSearchConfig *GoogleCloudDiscoveryengineV1betaAdvancedSiteSearchConfig `json:"advancedSiteSearchConfig,omitempty"` - // BillingEstimation: Output only. Data size estimation for billing. - BillingEstimation *GoogleCloudDiscoveryengineV1betaDataStoreBillingEstimation `json:"billingEstimation,omitempty"` - // CmekConfig: Output only. CMEK-related information for the DataStore. - CmekConfig *GoogleCloudDiscoveryengineV1betaCmekConfig `json:"cmekConfig,omitempty"` - // 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. - // "GOOGLE_WORKSPACE" - The data store is used for workspace search. Details - // of workspace data store are specified in the WorkspaceConfig. - 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"` - // DocumentProcessingConfig: Configuration for Document understanding and - // enrichment. - DocumentProcessingConfig *GoogleCloudDiscoveryengineV1betaDocumentProcessingConfig `json:"documentProcessingConfig,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. - // "HEALTHCARE_FHIR" - The healthcare FHIR vertical. - IndustryVertical string `json:"industryVertical,omitempty"` - // KmsKeyName: Input only. The KMS key to be used to protect this DataStore at - // creation time. Must be set for requests that need to comply with CMEK Org - // Policy protections. If this field is set and processed successfully, the - // DataStore will be protected by the KMS key, as indicated in the cmek_config - // field. - KmsKeyName string `json:"kmsKeyName,omitempty"` - // LanguageInfo: Language info for DataStore. - LanguageInfo *GoogleCloudDiscoveryengineV1betaLanguageInfo `json:"languageInfo,omitempty"` - // Name: Immutable. The full resource name of the data store. Format: - // `projects/{project}/locations/{location}/collections/{collection_id}/dataStor - // es/{data_store_id}`. This field must be a UTF-8 encoded string with a length - // limit of 1024 characters. - Name string `json:"name,omitempty"` - // NaturalLanguageQueryUnderstandingConfig: Optional. Configuration for Natural - // Language Query Understanding. - NaturalLanguageQueryUnderstandingConfig *GoogleCloudDiscoveryengineV1betaNaturalLanguageQueryUnderstandingConfig `json:"naturalLanguageQueryUnderstandingConfig,omitempty"` - // ServingConfigDataStore: Optional. Stores serving config at DataStore level. - ServingConfigDataStore *GoogleCloudDiscoveryengineV1betaDataStoreServingConfigDataStore `json:"servingConfigDataStore,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. - // "SOLUTION_TYPE_GENERATIVE_CHAT" - Used for use cases related to the - // Generative Chat agent. It's used for Generative chat engine only, the - // associated data stores must enrolled with `SOLUTION_TYPE_CHAT` solution. - SolutionTypes []string `json:"solutionTypes,omitempty"` - // StartingSchema: The start schema to use for this DataStore when provisioning - // it. If unset, a default vertical specialized schema will be used. This field - // is only used by CreateDataStore API, and will be ignored if used in other - // APIs. This field will be omitted from all API responses including - // CreateDataStore API. To retrieve a schema of a DataStore, use - // SchemaService.GetSchema API instead. The provided schema will be validated - // against certain rules on schema. Learn more from this doc - // (https://cloud.google.com/generative-ai-app-builder/docs/provide-schema). - StartingSchema *GoogleCloudDiscoveryengineV1betaSchema `json:"startingSchema,omitempty"` - // WorkspaceConfig: Config to store data store type configuration for workspace - // data. This must be set when DataStore.content_config is set as - // DataStore.ContentConfig.GOOGLE_WORKSPACE. - WorkspaceConfig *GoogleCloudDiscoveryengineV1betaWorkspaceConfig `json:"workspaceConfig,omitempty"` - // ForceSendFields is a list of field names (e.g. "AdvancedSiteSearchConfig") - // to unconditionally include in API requests. By default, fields with empty or +// GoogleCloudDiscoveryengineV1betaImportCompletionSuggestionsResponse: +// Response of the CompletionService.ImportCompletionSuggestions method. If the +// long running operation is done, this message is returned by the +// google.longrunning.Operations.response field if the operation is successful. +type GoogleCloudDiscoveryengineV1betaImportCompletionSuggestionsResponse struct { + // ErrorConfig: The desired location of errors incurred during the Import. + ErrorConfig *GoogleCloudDiscoveryengineV1betaImportErrorConfig `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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "AdvancedSiteSearchConfig") to - // include in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. See + // NullFields is a list of field names (e.g. "ErrorConfig") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1betaDataStore) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaDataStore +func (s GoogleCloudDiscoveryengineV1betaImportCompletionSuggestionsResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaImportCompletionSuggestionsResponse return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaDataStoreBillingEstimation: Estimation of -// data size per data store. -type GoogleCloudDiscoveryengineV1betaDataStoreBillingEstimation struct { - // StructuredDataSize: Data size for structured data in terms of bytes. - StructuredDataSize int64 `json:"structuredDataSize,omitempty,string"` - // StructuredDataUpdateTime: Last updated timestamp for structured data. - StructuredDataUpdateTime string `json:"structuredDataUpdateTime,omitempty"` - // UnstructuredDataSize: Data size for unstructured data in terms of bytes. - UnstructuredDataSize int64 `json:"unstructuredDataSize,omitempty,string"` - // UnstructuredDataUpdateTime: Last updated timestamp for unstructured data. - UnstructuredDataUpdateTime string `json:"unstructuredDataUpdateTime,omitempty"` - // WebsiteDataSize: Data size for websites in terms of bytes. - WebsiteDataSize int64 `json:"websiteDataSize,omitempty,string"` - // WebsiteDataUpdateTime: Last updated timestamp for websites. - WebsiteDataUpdateTime string `json:"websiteDataUpdateTime,omitempty"` - // ForceSendFields is a list of field names (e.g. "StructuredDataSize") to +// 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"` + // 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"` + // TotalCount: Total count of entries that were processed. + TotalCount int64 `json:"totalCount,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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "StructuredDataSize") to include - // in API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. See + // NullFields is a list of field names (e.g. "CreateTime") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1betaDataStoreBillingEstimation) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaDataStoreBillingEstimation - return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) -} - -// GoogleCloudDiscoveryengineV1betaDataStoreServingConfigDataStore: Stores -// information regarding the serving configurations at DataStore level. -type GoogleCloudDiscoveryengineV1betaDataStoreServingConfigDataStore struct { - // DisabledForServing: If set true, the DataStore will not be available for - // serving search requests. - DisabledForServing bool `json:"disabledForServing,omitempty"` - // ForceSendFields is a list of field names (e.g. "DisabledForServing") to +func (s GoogleCloudDiscoveryengineV1betaImportDocumentsMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaImportDocumentsMetadata + return gensupport.MarshalJSON(NoMethod(s), 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"` + // 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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "DisabledForServing") to include - // in API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. See + // NullFields is a list of field names (e.g. "ErrorConfig") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1betaDataStoreServingConfigDataStore) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaDataStoreServingConfigDataStore +func (s GoogleCloudDiscoveryengineV1betaImportDocumentsResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaImportDocumentsResponse return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// 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"` - // 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 +// 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. "GcsPrefix") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "CreateTime") to include in API + // NullFields is a list of field names (e.g. "GcsPrefix") to include in API // requests with the JSON null value. By default, fields with empty values are // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1betaDeleteDataStoreMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaDeleteDataStoreMetadata +func (s GoogleCloudDiscoveryengineV1betaImportErrorConfig) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaImportErrorConfig return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaDeleteEngineMetadata: Metadata related to -// the progress of the EngineService.DeleteEngine operation. This will be +// GoogleCloudDiscoveryengineV1betaImportSampleQueriesMetadata: Metadata +// related to the progress of the ImportSampleQueries operation. This will be // returned by the google.longrunning.Operation.metadata field. -type GoogleCloudDiscoveryengineV1betaDeleteEngineMetadata struct { - // CreateTime: Operation create time. +type GoogleCloudDiscoveryengineV1betaImportSampleQueriesMetadata struct { + // CreateTime: ImportSampleQueries operation create time. CreateTime string `json:"createTime,omitempty"` - // UpdateTime: Operation last update time. If the operation is done, this is - // also the finish time. + // FailureCount: Count of SampleQuerys that failed to be imported. + FailureCount int64 `json:"failureCount,omitempty,string"` + // SuccessCount: Count of SampleQuerys successfully imported. + SuccessCount int64 `json:"successCount,omitempty,string"` + // TotalCount: Total count of SampleQuerys that were processed. + TotalCount int64 `json:"totalCount,omitempty,string"` + // UpdateTime: ImportSampleQueries 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 @@ -17565,41 +19853,43 @@ type GoogleCloudDiscoveryengineV1betaDeleteEngineMetadata struct { NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1betaDeleteEngineMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaDeleteEngineMetadata +func (s GoogleCloudDiscoveryengineV1betaImportSampleQueriesMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaImportSampleQueriesMetadata return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaDeleteSchemaMetadata: Metadata for -// DeleteSchema LRO. -type GoogleCloudDiscoveryengineV1betaDeleteSchemaMetadata 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 +// GoogleCloudDiscoveryengineV1betaImportSampleQueriesResponse: Response of the +// SampleQueryService.ImportSampleQueries method. If the long running operation +// is done, this message is returned by the +// google.longrunning.Operations.response field if the operation is successful. +type GoogleCloudDiscoveryengineV1betaImportSampleQueriesResponse struct { + // ErrorConfig: The desired location of errors incurred during the Import. + ErrorConfig *GoogleCloudDiscoveryengineV1betaImportErrorConfig `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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "CreateTime") to include in API + // NullFields is a list of field names (e.g. "ErrorConfig") to include in API // requests with the JSON null value. By default, fields with empty values are // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1betaDeleteSchemaMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaDeleteSchemaMetadata +func (s GoogleCloudDiscoveryengineV1betaImportSampleQueriesResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaImportSampleQueriesResponse return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaDeleteSitemapMetadata: Metadata related to -// the progress of the SiteSearchEngineService.DeleteSitemap operation. This -// will be returned by the google.longrunning.Operation.metadata field. -type GoogleCloudDiscoveryengineV1betaDeleteSitemapMetadata struct { +// GoogleCloudDiscoveryengineV1betaImportSuggestionDenyListEntriesMetadata: +// 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"` // UpdateTime: Operation last update time. If the operation is done, this is @@ -17618,45 +19908,49 @@ type GoogleCloudDiscoveryengineV1betaDeleteSitemapMetadata struct { NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1betaDeleteSitemapMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaDeleteSitemapMetadata +func (s GoogleCloudDiscoveryengineV1betaImportSuggestionDenyListEntriesMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaImportSuggestionDenyListEntriesMetadata return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// 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"` - // 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 +// GoogleCloudDiscoveryengineV1betaImportSuggestionDenyListEntriesResponse: +// 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"` + // ForceSendFields is a list of field names (e.g. "ErrorSamples") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "CreateTime") to include in API + // NullFields is a list of field names (e.g. "ErrorSamples") to include in API // requests with the JSON null value. By default, fields with empty values are // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1betaDeleteTargetSiteMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaDeleteTargetSiteMetadata +func (s GoogleCloudDiscoveryengineV1betaImportSuggestionDenyListEntriesResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaImportSuggestionDenyListEntriesResponse return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// 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 { +// 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"` @@ -17673,3397 +19967,3719 @@ type GoogleCloudDiscoveryengineV1betaDisableAdvancedSiteSearchMetadata struct { NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1betaDisableAdvancedSiteSearchMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaDisableAdvancedSiteSearchMetadata +func (s GoogleCloudDiscoveryengineV1betaImportUserEventsMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaImportUserEventsMetadata return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaDisableAdvancedSiteSearchResponse: Response -// message for SiteSearchEngineService.DisableAdvancedSiteSearch method. -type GoogleCloudDiscoveryengineV1betaDisableAdvancedSiteSearchResponse struct { -} - -// GoogleCloudDiscoveryengineV1betaDocumentProcessingConfig: A singleton -// resource of DataStore. If it's empty when DataStore is created and DataStore -// is set to DataStore.ContentConfig.CONTENT_REQUIRED, the default parser will -// default to digital parser. -type GoogleCloudDiscoveryengineV1betaDocumentProcessingConfig struct { - // ChunkingConfig: Whether chunking mode is enabled. - ChunkingConfig *GoogleCloudDiscoveryengineV1betaDocumentProcessingConfigChunkingConfig `json:"chunkingConfig,omitempty"` - // DefaultParsingConfig: Configurations for default Document parser. If not - // specified, we will configure it as default DigitalParsingConfig, and the - // default parsing config will be applied to all file types for Document - // parsing. - DefaultParsingConfig *GoogleCloudDiscoveryengineV1betaDocumentProcessingConfigParsingConfig `json:"defaultParsingConfig,omitempty"` - // Name: The full resource name of the Document Processing Config. Format: - // `projects/*/locations/*/collections/*/dataStores/*/documentProcessingConfig`. - Name string `json:"name,omitempty"` - // ParsingConfigOverrides: Map from file type to override the default parsing - // configuration based on the file type. Supported keys: * `pdf`: Override - // parsing config for PDF files, either digital parsing, ocr parsing or layout - // parsing is supported. * `html`: Override parsing config for HTML files, only - // digital parsing and layout parsing are supported. * `docx`: Override parsing - // config for DOCX files, only digital parsing and layout parsing are - // supported. * `pptx`: Override parsing config for PPTX files, only digital - // parsing and layout parsing are supported. * `xlsm`: Override parsing config - // for XLSM files, only digital parsing and layout parsing are supported. * - // `xlsx`: Override parsing config for XLSX files, only digital parsing and - // layout parsing are supported. - ParsingConfigOverrides map[string]GoogleCloudDiscoveryengineV1betaDocumentProcessingConfigParsingConfig `json:"parsingConfigOverrides,omitempty"` - // ForceSendFields is a list of field names (e.g. "ChunkingConfig") to +// 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"` + // 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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "ChunkingConfig") to include in - // API requests with the JSON null value. By default, fields with empty values - // are omitted from API requests. See - // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. - NullFields []string `json:"-"` -} - -func (s GoogleCloudDiscoveryengineV1betaDocumentProcessingConfig) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaDocumentProcessingConfig - return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) -} - -// GoogleCloudDiscoveryengineV1betaDocumentProcessingConfigChunkingConfig: -// Configuration for chunking config. -type GoogleCloudDiscoveryengineV1betaDocumentProcessingConfigChunkingConfig struct { - // LayoutBasedChunkingConfig: Configuration for the layout based chunking. - LayoutBasedChunkingConfig *GoogleCloudDiscoveryengineV1betaDocumentProcessingConfigChunkingConfigLayoutBasedChunkingConfig `json:"layoutBasedChunkingConfig,omitempty"` - // ForceSendFields is a list of field names (e.g. "LayoutBasedChunkingConfig") - // to unconditionally include in API requests. By default, fields with empty or - // default values are omitted from API requests. See - // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more - // details. - ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "LayoutBasedChunkingConfig") to - // include in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. See + // NullFields is a list of field names (e.g. "ErrorConfig") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1betaDocumentProcessingConfigChunkingConfig) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaDocumentProcessingConfigChunkingConfig +func (s GoogleCloudDiscoveryengineV1betaImportUserEventsResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaImportUserEventsResponse return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaDocumentProcessingConfigChunkingConfigLayoutB -// asedChunkingConfig: Configuration for the layout based chunking. -type GoogleCloudDiscoveryengineV1betaDocumentProcessingConfigChunkingConfigLayoutBasedChunkingConfig struct { - // ChunkSize: The token size limit for each chunk. Supported values: 100-500 - // (inclusive). Default value: 500. - ChunkSize int64 `json:"chunkSize,omitempty"` - // IncludeAncestorHeadings: Whether to include appending different levels of - // headings to chunks from the middle of the document to prevent context loss. - // Default value: False. - IncludeAncestorHeadings bool `json:"includeAncestorHeadings,omitempty"` - // ForceSendFields is a list of field names (e.g. "ChunkSize") to +// 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"` + // 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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "ChunkSize") to include in API - // requests with the JSON null value. By default, fields with empty values are - // omitted from API requests. See + // NullFields is a list of field names (e.g. "ExclusiveMaximum") to include in + // API requests with the JSON null value. By default, fields with empty values + // are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1betaDocumentProcessingConfigChunkingConfigLayoutBasedChunkingConfig) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaDocumentProcessingConfigChunkingConfigLayoutBasedChunkingConfig +func (s GoogleCloudDiscoveryengineV1betaInterval) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaInterval return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaDocumentProcessingConfigParsingConfig: -// Related configurations applied to a specific type of document parser. -type GoogleCloudDiscoveryengineV1betaDocumentProcessingConfigParsingConfig struct { - // DigitalParsingConfig: Configurations applied to digital parser. - DigitalParsingConfig *GoogleCloudDiscoveryengineV1betaDocumentProcessingConfigParsingConfigDigitalParsingConfig `json:"digitalParsingConfig,omitempty"` - // LayoutParsingConfig: Configurations applied to layout parser. - LayoutParsingConfig *GoogleCloudDiscoveryengineV1betaDocumentProcessingConfigParsingConfigLayoutParsingConfig `json:"layoutParsingConfig,omitempty"` - // OcrParsingConfig: Configurations applied to OCR parser. Currently it only - // applies to PDFs. - OcrParsingConfig *GoogleCloudDiscoveryengineV1betaDocumentProcessingConfigParsingConfigOcrParsingConfig `json:"ocrParsingConfig,omitempty"` - // ForceSendFields is a list of field names (e.g. "DigitalParsingConfig") to +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 +} + +// GoogleCloudDiscoveryengineV1betaLanguageInfo: Language info for DataStore. +type GoogleCloudDiscoveryengineV1betaLanguageInfo struct { + // Language: Output only. Language part of normalized_language_code. E.g.: + // `en-US` -> `en`, `zh-Hans-HK` -> `zh`, `en` -> `en`. + Language string `json:"language,omitempty"` + // LanguageCode: The language code for the DataStore. + LanguageCode string `json:"languageCode,omitempty"` + // NormalizedLanguageCode: Output only. This is the normalized form of + // language_code. E.g.: language_code of `en-GB`, `en_GB`, `en-UK` or `en-gb` + // will have normalized_language_code of `en-GB`. + NormalizedLanguageCode string `json:"normalizedLanguageCode,omitempty"` + // Region: Output only. Region part of normalized_language_code, if present. + // E.g.: `en-US` -> `US`, `zh-Hans-HK` -> `HK`, `en` -> ``. + Region string `json:"region,omitempty"` + // ForceSendFields is a list of field names (e.g. "Language") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "DigitalParsingConfig") to include - // in API requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. See + // NullFields is a list of field names (e.g. "Language") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1betaDocumentProcessingConfigParsingConfig) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaDocumentProcessingConfigParsingConfig +func (s GoogleCloudDiscoveryengineV1betaLanguageInfo) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaLanguageInfo return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaDocumentProcessingConfigParsingConfigDigitalP -// arsingConfig: The digital parsing configurations for documents. -type GoogleCloudDiscoveryengineV1betaDocumentProcessingConfigParsingConfigDigitalParsingConfig struct { +// GoogleCloudDiscoveryengineV1betaNaturalLanguageQueryUnderstandingConfig: +// Configuration for Natural Language Query Understanding. +type GoogleCloudDiscoveryengineV1betaNaturalLanguageQueryUnderstandingConfig struct { + // Mode: Mode of Natural Language Query Understanding. If this field is unset, + // the behavior defaults to + // NaturalLanguageQueryUnderstandingConfig.Mode.DISABLED. + // + // Possible values: + // "MODE_UNSPECIFIED" - Default value. + // "DISABLED" - Natural Language Query Understanding is disabled. + // "ENABLED" - Natural Language Query Understanding is enabled. + 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. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + 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. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` } -// GoogleCloudDiscoveryengineV1betaDocumentProcessingConfigParsingConfigLayoutPa -// rsingConfig: The layout parsing configurations for documents. -type GoogleCloudDiscoveryengineV1betaDocumentProcessingConfigParsingConfigLayoutParsingConfig struct { +func (s GoogleCloudDiscoveryengineV1betaNaturalLanguageQueryUnderstandingConfig) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaNaturalLanguageQueryUnderstandingConfig + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaDocumentProcessingConfigParsingConfigOcrParsi -// ngConfig: The OCR parsing configurations for documents. -type GoogleCloudDiscoveryengineV1betaDocumentProcessingConfigParsingConfigOcrParsingConfig struct { - // EnhancedDocumentElements: [DEPRECATED] This field is deprecated. To use the - // additional enhanced document elements processing, please switch to - // `layout_parsing_config`. - 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. "EnhancedDocumentElements") - // to unconditionally include in API requests. By default, fields with empty or +// GoogleCloudDiscoveryengineV1betaProject: Metadata and configurations for a +// Google Cloud project in the service. +type GoogleCloudDiscoveryengineV1betaProject struct { + // CreateTime: Output only. The timestamp when this project is created. + CreateTime string `json:"createTime,omitempty"` + // Name: Output only. Full resource name of the project, for example + // `projects/{project}`. Note that when making requests, project number and + // project id are both acceptable, but the server will always respond in + // project number. + Name string `json:"name,omitempty"` + // ProvisionCompletionTime: Output only. The timestamp when this project is + // successfully provisioned. Empty value means this project is still + // provisioning and is not ready for use. + ProvisionCompletionTime string `json:"provisionCompletionTime,omitempty"` + // ServiceTermsMap: Output only. A map of terms of services. The key is the + // `id` of ServiceTerms. + ServiceTermsMap map[string]GoogleCloudDiscoveryengineV1betaProjectServiceTerms `json:"serviceTermsMap,omitempty"` + // ForceSendFields is a list of field names (e.g. "CreateTime") to + // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "EnhancedDocumentElements") to - // include in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. See + // NullFields is a list of field names (e.g. "CreateTime") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1betaDocumentProcessingConfigParsingConfigOcrParsingConfig) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaDocumentProcessingConfigParsingConfigOcrParsingConfig +func (s GoogleCloudDiscoveryengineV1betaProject) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaProject return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// 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 +// GoogleCloudDiscoveryengineV1betaProjectServiceTerms: Metadata about the +// terms of service. +type GoogleCloudDiscoveryengineV1betaProjectServiceTerms struct { + // AcceptTime: The last time when the project agreed to the terms of service. + AcceptTime string `json:"acceptTime,omitempty"` + // DeclineTime: The last time when the project declined or revoked the + // agreement to terms of service. + DeclineTime string `json:"declineTime,omitempty"` + // Id: The unique identifier of this terms of service. Available terms: * + // `GA_DATA_USE_TERMS`: Terms for data use + // (https://cloud.google.com/retail/data-use-terms). When using this as `id`, + // the acceptable version to provide is `2022-11-23`. + Id string `json:"id,omitempty"` + // State: Whether the project has accepted/rejected the service terms or it is + // still pending. + // + // Possible values: + // "STATE_UNSPECIFIED" - The default value of the enum. This value is not + // actually used. + // "TERMS_ACCEPTED" - The project has given consent to the terms of service. + // "TERMS_PENDING" - The project is pending to review and accept the terms of + // service. + // "TERMS_DECLINED" - The project has declined or revoked the agreement to + // terms of service. + State string `json:"state,omitempty"` + // Version: The version string of the terms of service. For acceptable values, + // see the comments for id above. + Version string `json:"version,omitempty"` + // ForceSendFields is a list of field names (e.g. "AcceptTime") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "CreateTime") to include in API + // NullFields is a list of field names (e.g. "AcceptTime") to include in API // requests with the JSON null value. By default, fields with empty values are // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1betaEnableAdvancedSiteSearchMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaEnableAdvancedSiteSearchMetadata +func (s GoogleCloudDiscoveryengineV1betaProjectServiceTerms) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaProjectServiceTerms return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaEnableAdvancedSiteSearchResponse: Response -// message for SiteSearchEngineService.EnableAdvancedSiteSearch method. -type GoogleCloudDiscoveryengineV1betaEnableAdvancedSiteSearchResponse struct { +// GoogleCloudDiscoveryengineV1betaProvisionProjectMetadata: Metadata +// associated with a project provision operation. +type GoogleCloudDiscoveryengineV1betaProvisionProjectMetadata struct { } - -// 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"` - // DisableAnalytics: Optional. Whether to disable analytics for searches - // performed on this engine. - DisableAnalytics bool `json:"disableAnalytics,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: Vertical - // on Engine has to match vertical of the DataStore linked 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. - // "HEALTHCARE_FHIR" - The healthcare FHIR 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}/locations/{location}/collections/{collection}/engines/{en - // gine}` 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. - // "SOLUTION_TYPE_GENERATIVE_CHAT" - Used for use cases related to the - // Generative Chat agent. It's used for Generative chat engine only, the - // associated data stores must enrolled with `SOLUTION_TYPE_CHAT` solution. - SolutionType string `json:"solutionType,omitempty"` - // UpdateTime: Output only. Timestamp the Recommendation Engine was last - // updated. + +// 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"` + // IgnoredCount: Count of entries that were ignored as entries were not found. + IgnoredCount int64 `json:"ignoredCount,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. "ChatEngineConfig") 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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. 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. See + // NullFields is a list of field names (e.g. "CreateTime") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1betaEngine) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaEngine +func (s GoogleCloudDiscoveryengineV1betaPurgeDocumentsMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaPurgeDocumentsMetadata return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// 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"` - // 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. 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 +// 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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. 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. See + // 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. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1betaEngineChatEngineConfig) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaEngineChatEngineConfig +func (s GoogleCloudDiscoveryengineV1betaPurgeDocumentsResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaPurgeDocumentsResponse return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaEngineChatEngineConfigAgentCreationConfig: -// 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"` - // 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 +// 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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Business") to include in API + // NullFields is a list of field names (e.g. "CreateTime") to include in API // requests with the JSON null value. By default, fields with empty values are // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1betaEngineChatEngineConfigAgentCreationConfig) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaEngineChatEngineConfigAgentCreationConfig +func (s GoogleCloudDiscoveryengineV1betaPurgeSuggestionDenyListEntriesMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaPurgeSuggestionDenyListEntriesMetadata return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// 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. "DialogflowAgent") to +// 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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. 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. See + // NullFields is a list of field names (e.g. "ErrorSamples") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1betaEngineChatEngineMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaEngineChatEngineMetadata +func (s GoogleCloudDiscoveryengineV1betaPurgeSuggestionDenyListEntriesResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaPurgeSuggestionDenyListEntriesResponse return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaEngineCommonConfig: Common configurations -// for an Engine. -type GoogleCloudDiscoveryengineV1betaEngineCommonConfig 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"` - // ForceSendFields is a list of field names (e.g. "CompanyName") to +// GoogleCloudDiscoveryengineV1betaQualityMetrics: Describes the metrics +// produced by the evaluation. +type GoogleCloudDiscoveryengineV1betaQualityMetrics struct { + // DocNdcg: Normalized discounted cumulative gain (NDCG) per document, at + // various top-k cutoff levels. NDCG measures the ranking quality, giving + // higher relevance to top results. Example (top-3): Suppose SampleQuery with + // three retrieved documents (D1, D2, D3) and binary relevance judgements (1 + // for relevant, 0 for not relevant): Retrieved: [D3 (0), D1 (1), D2 (1)] + // Ideal: [D1 (1), D2 (1), D3 (0)] Calculate NDCG@3 for each SampleQuery: * + // DCG@3: 0/log2(1+1) + 1/log2(2+1) + 1/log2(3+1) = 1.13 * Ideal DCG@3: + // 1/log2(1+1) + 1/log2(2+1) + 0/log2(3+1) = 1.63 * NDCG@3: 1.13/1.63 = 0.693 + DocNdcg *GoogleCloudDiscoveryengineV1betaQualityMetricsTopkMetrics `json:"docNdcg,omitempty"` + // DocPrecision: Precision per document, at various top-k cutoff levels. + // Precision is the fraction of retrieved documents that are relevant. Example + // (top-5): * For a single SampleQuery, If 4 out of 5 retrieved documents in + // the top-5 are relevant, precision@5 = 4/5 = 0.8 + DocPrecision *GoogleCloudDiscoveryengineV1betaQualityMetricsTopkMetrics `json:"docPrecision,omitempty"` + // DocRecall: Recall per document, at various top-k cutoff levels. Recall is + // the fraction of relevant documents retrieved out of all relevant documents. + // Example (top-5): * For a single SampleQuery, If 3 out of 5 relevant + // documents are retrieved in the top-5, recall@5 = 3/5 = 0.6 + DocRecall *GoogleCloudDiscoveryengineV1betaQualityMetricsTopkMetrics `json:"docRecall,omitempty"` + // PageNdcg: Normalized discounted cumulative gain (NDCG) per page, at various + // top-k cutoff levels. NDCG measures the ranking quality, giving higher + // relevance to top results. Example (top-3): Suppose SampleQuery with three + // retrieved pages (P1, P2, P3) and binary relevance judgements (1 for + // relevant, 0 for not relevant): Retrieved: [P3 (0), P1 (1), P2 (1)] Ideal: + // [P1 (1), P2 (1), P3 (0)] Calculate NDCG@3 for SampleQuery: * DCG@3: + // 0/log2(1+1) + 1/log2(2+1) + 1/log2(3+1) = 1.13 * Ideal DCG@3: 1/log2(1+1) + + // 1/log2(2+1) + 0/log2(3+1) = 1.63 * NDCG@3: 1.13/1.63 = 0.693 + PageNdcg *GoogleCloudDiscoveryengineV1betaQualityMetricsTopkMetrics `json:"pageNdcg,omitempty"` + // PageRecall: Recall per page, at various top-k cutoff levels. Recall is the + // fraction of relevant pages retrieved out of all relevant pages. Example + // (top-5): * For a single SampleQuery, if 3 out of 5 relevant pages are + // retrieved in the top-5, recall@5 = 3/5 = 0.6 + PageRecall *GoogleCloudDiscoveryengineV1betaQualityMetricsTopkMetrics `json:"pageRecall,omitempty"` + // ForceSendFields is a list of field names (e.g. "DocNdcg") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "DocNdcg") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1betaQualityMetrics) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaQualityMetrics + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1betaQualityMetricsTopkMetrics: Stores the metric +// values at specific top-k levels. +type GoogleCloudDiscoveryengineV1betaQualityMetricsTopkMetrics struct { + // Top1: The top-1 value. + Top1 float64 `json:"top1,omitempty"` + // Top10: The top-10 value. + Top10 float64 `json:"top10,omitempty"` + // Top3: The top-3 value. + Top3 float64 `json:"top3,omitempty"` + // Top5: The top-5 value. + Top5 float64 `json:"top5,omitempty"` + // ForceSendFields is a list of field names (e.g. "Top1") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "Top1") to include in API requests + // with the JSON null value. By default, fields with empty values are omitted + // from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1betaQualityMetricsTopkMetrics) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaQualityMetricsTopkMetrics + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +func (s *GoogleCloudDiscoveryengineV1betaQualityMetricsTopkMetrics) UnmarshalJSON(data []byte) error { + type NoMethod GoogleCloudDiscoveryengineV1betaQualityMetricsTopkMetrics + var s1 struct { + Top1 gensupport.JSONFloat64 `json:"top1"` + Top10 gensupport.JSONFloat64 `json:"top10"` + Top3 gensupport.JSONFloat64 `json:"top3"` + Top5 gensupport.JSONFloat64 `json:"top5"` + *NoMethod + } + s1.NoMethod = (*NoMethod)(s) + if err := json.Unmarshal(data, &s1); err != nil { + return err + } + s.Top1 = float64(s1.Top1) + s.Top10 = float64(s1.Top10) + s.Top3 = float64(s1.Top3) + s.Top5 = float64(s1.Top5) + return nil +} + +// 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}/dataStores/ + // {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. "JsonSchema") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "CompanyName") to include in API + // 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. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1betaEngineCommonConfig) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaEngineCommonConfig +func (s GoogleCloudDiscoveryengineV1betaSchema) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaSchema return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// 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"` - // SearchTier: The search feature tier of this engine. Different tiers might - // have different pricing. To learn more, 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 +// GoogleCloudDiscoveryengineV1betaSearchLinkPromotion: Promotion proto +// includes uri and other helping information to display the promotion. +type GoogleCloudDiscoveryengineV1betaSearchLinkPromotion struct { + // Description: Optional. The Promotion description. Maximum length: 200 + // characters. + Description string `json:"description,omitempty"` + // Enabled: Optional. The enabled promotion will be returned for any serving + // configs associated with the parent of the control this promotion is attached + // to. This flag is used for basic site search only. + Enabled bool `json:"enabled,omitempty"` + // ImageUri: Optional. The promotion thumbnail image url. + ImageUri string `json:"imageUri,omitempty"` + // Title: Required. The title of the promotion. Maximum length: 160 characters. + Title string `json:"title,omitempty"` + // Uri: Required. The URL for the page the user wants to promote. + Uri string `json:"uri,omitempty"` + // ForceSendFields is a list of field names (e.g. "Description") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "SearchAddOns") to include in API + // NullFields is a list of field names (e.g. "Description") to include in API // requests with the JSON null value. By default, fields with empty values are // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1betaEngineSearchEngineConfig) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaEngineSearchEngineConfig +func (s GoogleCloudDiscoveryengineV1betaSearchLinkPromotion) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaSearchLinkPromotion return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaEvaluation: An evaluation is a single -// execution (or run) of an evaluation process. It encapsulates the state of -// the evaluation and the resulting data. -type GoogleCloudDiscoveryengineV1betaEvaluation struct { - // CreateTime: Output only. Timestamp the Evaluation was created at. - CreateTime string `json:"createTime,omitempty"` - // EndTime: Output only. Timestamp the Evaluation was completed at. - EndTime string `json:"endTime,omitempty"` - // Error: Output only. The error that occurred during evaluation. Only - // populated when the evaluation's state is FAILED. - Error *GoogleRpcStatus `json:"error,omitempty"` - // ErrorSamples: Output only. A sample of errors encountered while processing - // the request. - ErrorSamples []*GoogleRpcStatus `json:"errorSamples,omitempty"` - // EvaluationSpec: Required. The specification of the evaluation. - EvaluationSpec *GoogleCloudDiscoveryengineV1betaEvaluationEvaluationSpec `json:"evaluationSpec,omitempty"` - // Name: Identifier. The full resource name of the Evaluation, in the format of - // `projects/{project}/locations/{location}/evaluations/{evaluation}`. This - // field must be a UTF-8 encoded string with a length limit of 1024 characters. - Name string `json:"name,omitempty"` - // QualityMetrics: Output only. The metrics produced by the evaluation, - // averaged across all SampleQuerys in the SampleQuerySet. Only populated when - // the evaluation's state is SUCCEEDED. - QualityMetrics *GoogleCloudDiscoveryengineV1betaQualityMetrics `json:"qualityMetrics,omitempty"` - // State: Output only. The state of the evaluation. +// 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/generative-ai-app-builder/docs/boost-search-results) + BoostSpec *GoogleCloudDiscoveryengineV1betaSearchRequestBoostSpec `json:"boostSpec,omitempty"` + // Branch: The branch resource name, such as + // `projects/*/locations/global/collections/default_collection/dataStores/defaul + // t_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"` + // DataStoreSpecs: Specs defining DataStores to filter on in a search call and + // configurations for those data stores. This is only considered for Engines + // with multiple data stores. For engines with a single data store, the specs + // directly under SearchRequest should be used. + DataStoreSpecs []*GoogleCloudDiscoveryengineV1betaSearchRequestDataStoreSpec `json:"dataStoreSpecs,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_path. + 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"` + // LanguageCode: The BCP-47 language code, such as "en-US" or "sr-Latn". For + // more information, see Standard fields + // (https://cloud.google.com/apis/design/standard_fields). This field helps to + // better interpret the query. If a value isn't specified, the query language + // code is automatically detected, which may not be accurate. + LanguageCode string `json:"languageCode,omitempty"` + // NaturalLanguageQueryUnderstandingSpec: If + // `naturalLanguageQueryUnderstandingSpec` is not specified, no additional + // natural language query understanding will be done. + NaturalLanguageQueryUnderstandingSpec *GoogleCloudDiscoveryengineV1betaSearchRequestNaturalLanguageQueryUnderstandingSpec `json:"naturalLanguageQueryUnderstandingSpec,omitempty"` + // Offset: A 0-indexed integer that specifies the current offset (that is, + // starting result location, amongst the Documents deemed by the API as + // 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"` + // OneBoxPageSize: The maximum number of results to return for OneBox. This + // applies to each OneBox type individually. Default number is 10. + OneBoxPageSize int64 `json:"oneBoxPageSize,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 + // the website search results, see Order web search results + // (https://cloud.google.com/generative-ai-app-builder/docs/order-web-search-results). + // For more information on ordering the healthcare search results, see Order + // healthcare search results + // (https://cloud.google.com/generative-ai-app-builder/docs/order-hc-results). + // If this field is unrecognizable, an `INVALID_ARGUMENT` is returned. + OrderBy string `json:"orderBy,omitempty"` + // PageSize: Maximum number of Documents to return. The maximum allowed value + // depends on the data type. Values above the maximum value are coerced to the + // maximum value. * Websites with basic indexing: Default `10`, Maximum `25`. * + // Websites with advanced indexing: Default `25`, Maximum `50`. * Other: + // Default `50`, Maximum `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. For 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. For example, `search_type: 1` + Params googleapi.RawMessage `json:"params,omitempty"` + // PersonalizationSpec: The specification for personalization. Notice that if + // both ServingConfig.personalization_spec and + // SearchRequest.personalization_spec are set, + // SearchRequest.personalization_spec overrides + // ServingConfig.personalization_spec. + PersonalizationSpec *GoogleCloudDiscoveryengineV1betaSearchRequestPersonalizationSpec `json:"personalizationSpec,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 + // joined 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"` + // RegionCode: The Unicode country/region code (CLDR) of a location, such as + // "US" and "419". For more information, see Standard fields + // (https://cloud.google.com/apis/design/standard_fields). If set, then results + // will be boosted based on the region_code provided. + RegionCode string `json:"regionCode,omitempty"` + // RelevanceThreshold: The relevance threshold of the search results. Default + // to Google defined threshold, leveraging a balance of precision and recall to + // deliver both highly accurate results and comprehensive coverage of relevant + // information. // // Possible values: - // "STATE_UNSPECIFIED" - The evaluation is unspecified. - // "PENDING" - The service is preparing to run the evaluation. - // "RUNNING" - The evaluation is in progress. - // "SUCCEEDED" - The evaluation completed successfully. - // "FAILED" - The evaluation failed. - State string `json:"state,omitempty"` - // ForceSendFields is a list of field names (e.g. "CreateTime") to + // "RELEVANCE_THRESHOLD_UNSPECIFIED" - Default value. In this case, server + // behavior defaults to Google defined threshold. + // "LOWEST" - Lowest relevance threshold. + // "LOW" - Low relevance threshold. + // "MEDIUM" - Medium relevance threshold. + // "HIGH" - High relevance threshold. + RelevanceThreshold string `json:"relevanceThreshold,omitempty"` + // SafeSearch: Whether to turn on safe search. This is only supported for + // website search. + SafeSearch bool `json:"safeSearch,omitempty"` + // SearchAsYouTypeSpec: Search as you type configuration. Only supported for + // the IndustryVertical.MEDIA vertical. + SearchAsYouTypeSpec *GoogleCloudDiscoveryengineV1betaSearchRequestSearchAsYouTypeSpec `json:"searchAsYouTypeSpec,omitempty"` + // ServingConfig: Required. The resource name of the Search serving config, + // such as + // `projects/*/locations/global/collections/default_collection/engines/*/serving + // Configs/default_serving_config`, or + // `projects/*/locations/global/collections/default_collection/dataStores/defaul + // t_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"` + // Session: The session resource name. Optional. Session allows users to do + // multi-turn /search API calls or coordination between /search API calls and + // /answer API calls. Example #1 (multi-turn /search API calls): 1. Call + // /search API with the auto-session mode (see below). 2. Call /search API with + // the session ID generated in the first call. Here, the previous search query + // gets considered in query standing. I.e., if the first query is "How did + // Alphabet do in 2022?" and the current query is "How about 2023?", the + // current query will be interpreted as "How did Alphabet do in 2023?". Example + // #2 (coordination between /search API calls and /answer API calls): 1. Call + // /search API with the auto-session mode (see below). 2. Call /answer API with + // the session ID generated in the first call. Here, the answer generation + // happens in the context of the search results from the first search call. + // Auto-session mode: when `projects/.../sessions/-` is used, a new session + // gets automatically created. Otherwise, users can use the create-session API + // to create a session manually. Multi-turn Search feature is currently at + // private GA stage. Please use v1alpha or v1beta version instead before we + // launch this feature to public GA. Or ask for allowlisting through Google + // Support team. + Session string `json:"session,omitempty"` + // SessionSpec: Session specification. Can be used only when `session` is set. + SessionSpec *GoogleCloudDiscoveryengineV1betaSearchRequestSessionSpec `json:"sessionSpec,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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "CreateTime") to include in API + // NullFields is a list of field names (e.g. "BoostSpec") to include in API // requests with the JSON null value. By default, fields with empty values are // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1betaEvaluation) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaEvaluation +func (s GoogleCloudDiscoveryengineV1betaSearchRequest) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaSearchRequest return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaEvaluationEvaluationSpec: Describes the -// specification of the evaluation. -type GoogleCloudDiscoveryengineV1betaEvaluationEvaluationSpec struct { - // QuerySetSpec: Required. The specification of the query set. - QuerySetSpec *GoogleCloudDiscoveryengineV1betaEvaluationEvaluationSpecQuerySetSpec `json:"querySetSpec,omitempty"` - // SearchRequest: Required. The search request that is used to perform the - // evaluation. Only the following fields within SearchRequest are supported; if - // any other fields are provided, an UNSUPPORTED error will be returned: * - // SearchRequest.serving_config * SearchRequest.branch * - // SearchRequest.canonical_filter * SearchRequest.query_expansion_spec * - // SearchRequest.spell_correction_spec * SearchRequest.content_search_spec * - // SearchRequest.user_pseudo_id - SearchRequest *GoogleCloudDiscoveryengineV1betaSearchRequest `json:"searchRequest,omitempty"` - // ForceSendFields is a list of field names (e.g. "QuerySetSpec") to +// 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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "QuerySetSpec") to include in API - // requests with the JSON null value. By default, fields with empty values are - // omitted from API requests. See + // NullFields is a list of field names (e.g. "ConditionBoostSpecs") to include + // in API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1betaEvaluationEvaluationSpec) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaEvaluationEvaluationSpec +func (s GoogleCloudDiscoveryengineV1betaSearchRequestBoostSpec) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaSearchRequestBoostSpec return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaEvaluationEvaluationSpecQuerySetSpec: -// Describes the specification of the query set. -type GoogleCloudDiscoveryengineV1betaEvaluationEvaluationSpecQuerySetSpec struct { - // SampleQuerySet: Required. The full resource name of the SampleQuerySet used - // for the evaluation, in the format of - // `projects/{project}/locations/{location}/sampleQuerySets/{sampleQuerySet}`. - SampleQuerySet string `json:"sampleQuerySet,omitempty"` - // ForceSendFields is a list of field names (e.g. "SampleQuerySet") to - // unconditionally include in API requests. By default, fields with empty or - // default values are omitted from API requests. See +// GoogleCloudDiscoveryengineV1betaSearchRequestBoostSpecConditionBoostSpec: +// 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. Only one of + // the (condition, boost) combination or the boost_control_spec below are set. + // If both are set then the global boost is ignored and the more fine-grained + // boost_control_spec is applied. + Boost float64 `json:"boost,omitempty"` + // BoostControlSpec: Complex specification for custom ranking based on customer + // defined attribute value. + BoostControlSpec *GoogleCloudDiscoveryengineV1betaSearchRequestBoostSpecConditionBoostSpecBoostControlSpec `json:"boostControlSpec,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": + // `(document_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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "SampleQuerySet") to include in - // API requests with the JSON null value. By default, fields with empty values - // are omitted from API requests. See + // NullFields is a list of field names (e.g. "Boost") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1betaEvaluationEvaluationSpecQuerySetSpec) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaEvaluationEvaluationSpecQuerySetSpec +func (s GoogleCloudDiscoveryengineV1betaSearchRequestBoostSpecConditionBoostSpec) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaSearchRequestBoostSpecConditionBoostSpec return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaFetchSitemapsResponse: Response message for -// SiteSearchEngineService.FetchSitemaps method. -type GoogleCloudDiscoveryengineV1betaFetchSitemapsResponse struct { - // SitemapsMetadata: List of Sitemaps fetched. - SitemapsMetadata []*GoogleCloudDiscoveryengineV1betaFetchSitemapsResponseSitemapMetadata `json:"sitemapsMetadata,omitempty"` - // ForceSendFields is a list of field names (e.g. "SitemapsMetadata") to - // unconditionally include in API requests. By default, fields with empty or - // default values are omitted from API requests. See - // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more - // details. - ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "SitemapsMetadata") to include in - // API requests with the JSON null value. By default, fields with empty values - // are omitted from API requests. See - // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. - NullFields []string `json:"-"` -} - -func (s GoogleCloudDiscoveryengineV1betaFetchSitemapsResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaFetchSitemapsResponse - return gensupport.MarshalJSON(NoMethod(s), 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 } -// GoogleCloudDiscoveryengineV1betaFetchSitemapsResponseSitemapMetadata: -// Contains a Sitemap and its metadata. -type GoogleCloudDiscoveryengineV1betaFetchSitemapsResponseSitemapMetadata struct { - // Sitemap: The Sitemap. - Sitemap *GoogleCloudDiscoveryengineV1betaSitemap `json:"sitemap,omitempty"` - // ForceSendFields is a list of field names (e.g. "Sitemap") to unconditionally - // include in API requests. By default, fields with empty or default values are - // omitted from API requests. See +// GoogleCloudDiscoveryengineV1betaSearchRequestBoostSpecConditionBoostSpecBoost +// ControlSpec: Specification for custom ranking based on customer specified +// attribute value. It provides more controls for customized ranking than the +// simple (condition, boost) combination above. +type GoogleCloudDiscoveryengineV1betaSearchRequestBoostSpecConditionBoostSpecBoostControlSpec struct { + // AttributeType: The attribute type to be used to determine the boost amount. + // The attribute value can be derived from the field value of the specified + // field_name. In the case of numerical it is straightforward i.e. + // attribute_value = numerical_field_value. In the case of freshness however, + // attribute_value = (time.now() - datetime_field_value). + // + // Possible values: + // "ATTRIBUTE_TYPE_UNSPECIFIED" - Unspecified AttributeType. + // "NUMERICAL" - The value of the numerical field will be used to dynamically + // update the boost amount. In this case, the attribute_value (the x value) of + // the control point will be the actual value of the numerical field for which + // the boost_amount is specified. + // "FRESHNESS" - For the freshness use case the attribute value will be the + // duration between the current time and the date in the datetime field + // specified. The value must be formatted as an XSD `dayTimeDuration` value (a + // restricted subset of an ISO 8601 duration value). The pattern for this is: + // `nDnM]`. For example, `5D`, `3DT12H30M`, `T24H`. + AttributeType string `json:"attributeType,omitempty"` + // ControlPoints: The control points used to define the curve. The monotonic + // function (defined through the interpolation_type above) passes through the + // control points listed here. + ControlPoints []*GoogleCloudDiscoveryengineV1betaSearchRequestBoostSpecConditionBoostSpecBoostControlSpecControlPoint `json:"controlPoints,omitempty"` + // FieldName: The name of the field whose value will be used to determine the + // boost amount. + FieldName string `json:"fieldName,omitempty"` + // InterpolationType: The interpolation type to be applied to connect the + // control points listed below. + // + // Possible values: + // "INTERPOLATION_TYPE_UNSPECIFIED" - Interpolation type is unspecified. In + // this case, it defaults to Linear. + // "LINEAR" - Piecewise linear interpolation will be applied. + InterpolationType string `json:"interpolationType,omitempty"` + // ForceSendFields is a list of field names (e.g. "AttributeType") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Sitemap") to include in API + // NullFields is a list of field names (e.g. "AttributeType") to include in API // requests with the JSON null value. By default, fields with empty values are // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1betaFetchSitemapsResponseSitemapMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaFetchSitemapsResponseSitemapMetadata +func (s GoogleCloudDiscoveryengineV1betaSearchRequestBoostSpecConditionBoostSpecBoostControlSpec) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaSearchRequestBoostSpecConditionBoostSpecBoostControlSpec return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaImportCompletionSuggestionsMetadata: -// Metadata related to the progress of the ImportCompletionSuggestions -// operation. This will be returned by the -// google.longrunning.Operation.metadata field. -type GoogleCloudDiscoveryengineV1betaImportCompletionSuggestionsMetadata struct { - // CreateTime: Operation create time. - CreateTime string `json:"createTime,omitempty"` - // FailureCount: Count of CompletionSuggestions that failed to be imported. - FailureCount int64 `json:"failureCount,omitempty,string"` - // SuccessCount: Count of CompletionSuggestions successfully imported. - 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 +// GoogleCloudDiscoveryengineV1betaSearchRequestBoostSpecConditionBoostSpecBoost +// ControlSpecControlPoint: The control points used to define the curve. The +// curve defined through these control points can only be monotonically +// increasing or decreasing(constant values are acceptable). +type GoogleCloudDiscoveryengineV1betaSearchRequestBoostSpecConditionBoostSpecBoostControlSpecControlPoint struct { + // AttributeValue: Can be one of: 1. The numerical field value. 2. The duration + // spec for freshness: The value must be formatted as an XSD `dayTimeDuration` + // value (a restricted subset of an ISO 8601 duration value). The pattern for + // this is: `nDnM]`. + AttributeValue string `json:"attributeValue,omitempty"` + // BoostAmount: The value between -1 to 1 by which to boost the score if the + // attribute_value evaluates to the value specified above. + BoostAmount float64 `json:"boostAmount,omitempty"` + // ForceSendFields is a list of field names (e.g. "AttributeValue") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "CreateTime") to include in API - // requests with the JSON null value. By default, fields with empty values are - // omitted from API requests. See + // NullFields is a list of field names (e.g. "AttributeValue") to include in + // API requests with the JSON null value. By default, fields with empty values + // are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1betaImportCompletionSuggestionsMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaImportCompletionSuggestionsMetadata +func (s GoogleCloudDiscoveryengineV1betaSearchRequestBoostSpecConditionBoostSpecBoostControlSpecControlPoint) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaSearchRequestBoostSpecConditionBoostSpecBoostControlSpecControlPoint return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaImportCompletionSuggestionsResponse: -// Response of the CompletionService.ImportCompletionSuggestions method. If the -// long running operation is done, this message is returned by the -// google.longrunning.Operations.response field if the operation is successful. -type GoogleCloudDiscoveryengineV1betaImportCompletionSuggestionsResponse struct { - // ErrorConfig: The desired location of errors incurred during the Import. - ErrorConfig *GoogleCloudDiscoveryengineV1betaImportErrorConfig `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 +func (s *GoogleCloudDiscoveryengineV1betaSearchRequestBoostSpecConditionBoostSpecBoostControlSpecControlPoint) UnmarshalJSON(data []byte) error { + type NoMethod GoogleCloudDiscoveryengineV1betaSearchRequestBoostSpecConditionBoostSpecBoostControlSpecControlPoint + var s1 struct { + BoostAmount gensupport.JSONFloat64 `json:"boostAmount"` + *NoMethod + } + s1.NoMethod = (*NoMethod)(s) + if err := json.Unmarshal(data, &s1); err != nil { + return err + } + s.BoostAmount = float64(s1.BoostAmount) + return nil +} + +// GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpec: A +// specification for configuring the behavior of content search. +type GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpec struct { + // ChunkSpec: Specifies the chunk spec to be returned from the search response. + // Only available if the SearchRequest.ContentSearchSpec.search_result_mode is + // set to CHUNKS + ChunkSpec *GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecChunkSpec `json:"chunkSpec,omitempty"` + // ExtractiveContentSpec: If there is no extractive_content_spec provided, + // there will be no extractive answer in the search response. + ExtractiveContentSpec *GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecExtractiveContentSpec `json:"extractiveContentSpec,omitempty"` + // SearchResultMode: Specifies the search result mode. If unspecified, the + // search result mode defaults to `DOCUMENTS`. + // + // Possible values: + // "SEARCH_RESULT_MODE_UNSPECIFIED" - Default value. + // "DOCUMENTS" - Returns documents in the search result. + // "CHUNKS" - Returns chunks in the search result. Only available if the + // DocumentProcessingConfig.chunking_config is specified. + SearchResultMode string `json:"searchResultMode,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. "ChunkSpec") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "ErrorConfig") to include in API + // NullFields is a list of field names (e.g. "ChunkSpec") to include in API // requests with the JSON null value. By default, fields with empty values are // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1betaImportCompletionSuggestionsResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaImportCompletionSuggestionsResponse +func (s GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpec) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpec return gensupport.MarshalJSON(NoMethod(s), 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 { - // 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"` - // TotalCount: Total count of entries that were processed. - TotalCount int64 `json:"totalCount,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 +// GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecChunkSpec: +// Specifies the chunk spec to be returned from the search response. Only +// available if the SearchRequest.ContentSearchSpec.search_result_mode is set +// to CHUNKS +type GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecChunkSpec struct { + // NumNextChunks: The number of next chunks to be returned of the current + // chunk. The maximum allowed value is 3. If not specified, no next chunks will + // be returned. + NumNextChunks int64 `json:"numNextChunks,omitempty"` + // NumPreviousChunks: The number of previous chunks to be returned of the + // current chunk. The maximum allowed value is 3. If not specified, no previous + // chunks will be returned. + NumPreviousChunks int64 `json:"numPreviousChunks,omitempty"` + // ForceSendFields is a list of field names (e.g. "NumNextChunks") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "CreateTime") to include in API + // NullFields is a list of field names (e.g. "NumNextChunks") to include in API // requests with the JSON null value. By default, fields with empty values are // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1betaImportDocumentsMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaImportDocumentsMetadata +func (s GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecChunkSpec) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecChunkSpec return gensupport.MarshalJSON(NoMethod(s), 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"` - // 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 +// GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecExtractiveConte +// ntSpec: 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"` + // ReturnExtractiveSegmentScore: Specifies whether to return the confidence + // score from the extractive segments in each search result. This feature is + // available only for new or allowlisted data stores. To allowlist your data + // store, contact your Customer Engineer. The default value is `false`. + ReturnExtractiveSegmentScore bool `json:"returnExtractiveSegmentScore,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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. 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. See + // 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. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1betaImportDocumentsResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaImportDocumentsResponse +func (s GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecExtractiveContentSpec) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecExtractiveContentSpec return gensupport.MarshalJSON(NoMethod(s), 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"` - // ForceSendFields is a list of field names (e.g. "GcsPrefix") to +// GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecSnippetSpec: 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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. 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. See + // 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. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1betaImportErrorConfig) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaImportErrorConfig +func (s GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecSnippetSpec) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecSnippetSpec return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaImportSampleQueriesMetadata: Metadata -// related to the progress of the ImportSampleQueries operation. This will be -// returned by the google.longrunning.Operation.metadata field. -type GoogleCloudDiscoveryengineV1betaImportSampleQueriesMetadata struct { - // CreateTime: ImportSampleQueries operation create time. - CreateTime string `json:"createTime,omitempty"` - // FailureCount: Count of SampleQuerys that failed to be imported. - FailureCount int64 `json:"failureCount,omitempty,string"` - // SuccessCount: Count of SampleQuerys successfully imported. - SuccessCount int64 `json:"successCount,omitempty,string"` - // TotalCount: Total count of SampleQuerys that were processed. - TotalCount int64 `json:"totalCount,omitempty,string"` - // UpdateTime: ImportSampleQueries 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 +// GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecSummarySpec: 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"` + // IgnoreJailBreakingQuery: Optional. Specifies whether to filter out + // jail-breaking queries. The default value is `false`. Google employs + // search-query classification to detect jail-breaking queries. No summary is + // returned if the search query is classified as a jail-breaking query. A user + // might add instructions to the query to change the tone, style, language, + // content of the answer, or ask the model to act as a different entity, e.g. + // "Reply in the tone of a competing company's CEO". If this field is set to + // `true`, we skip generating summaries for jail-breaking queries and return + // fallback messages instead. + IgnoreJailBreakingQuery bool `json:"ignoreJailBreakingQuery,omitempty"` + // IgnoreLowRelevantContent: Specifies whether to filter out queries that have + // low relevance. The default value is `false`. If this field is set to + // `false`, all search results are used regardless of relevance to generate + // answers. If set to `true`, only queries with high relevance search results + // will generate answers. + IgnoreLowRelevantContent bool `json:"ignoreLowRelevantContent,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 10 results for + // documents mode, or 50 for chunks mode, can be used to generate a summary. + // The chunks mode is used when + // SearchRequest.ContentSearchSpec.search_result_mode is set to CHUNKS. + SummaryResultCount int64 `json:"summaryResultCount,omitempty"` + // UseSemanticChunks: If true, answer will be generated from most relevant + // chunks from top search results. This feature will improve summary quality. + // Note that with this feature enabled, not all top search results will be + // referenced and included in the reference list, so the citation source index + // only points to the search results listed in the reference list. + UseSemanticChunks bool `json:"useSemanticChunks,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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "CreateTime") to include in API - // requests with the JSON null value. By default, fields with empty values are - // omitted from API requests. See + // NullFields is a list of field names (e.g. "IgnoreAdversarialQuery") to + // include in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1betaImportSampleQueriesMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaImportSampleQueriesMetadata +func (s GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecSummarySpec) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecSummarySpec return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaImportSampleQueriesResponse: Response of the -// SampleQueryService.ImportSampleQueries method. If the long running operation -// is done, this message is returned by the -// google.longrunning.Operations.response field if the operation is successful. -type GoogleCloudDiscoveryengineV1betaImportSampleQueriesResponse struct { - // ErrorConfig: The desired location of errors incurred during the Import. - ErrorConfig *GoogleCloudDiscoveryengineV1betaImportErrorConfig `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 +// GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecSummarySpecMode +// lPromptSpec: 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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "ErrorConfig") to include in API + // 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. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1betaImportSampleQueriesResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaImportSampleQueriesResponse +func (s GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecSummarySpecModelPromptSpec) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecSummarySpecModelPromptSpec return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaImportSuggestionDenyListEntriesMetadata: -// 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"` - // UpdateTime: Operation last update time. If the operation is done, this is - // also the finish time. - UpdateTime string `json:"updateTime,omitempty"` - // ForceSendFields is a list of field names (e.g. "CreateTime") to - // unconditionally include in API requests. By default, fields with empty or - // default values are omitted from API requests. See +// GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecSummarySpecMode +// lSpec: 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 model. For more information, see Answer + // generation model versions and lifecycle + // (https://cloud.google.com/generative-ai-app-builder/docs/answer-generation-models). + // * `preview`: string. (Public preview) Uses a preview model. For more + // information, see Answer generation model versions and lifecycle + // (https://cloud.google.com/generative-ai-app-builder/docs/answer-generation-models). + Version string `json:"version,omitempty"` + // ForceSendFields is a list of field names (e.g. "Version") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "CreateTime") to include in API + // NullFields is a list of field names (e.g. "Version") to include in API // requests with the JSON null value. By default, fields with empty values are // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1betaImportSuggestionDenyListEntriesMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaImportSuggestionDenyListEntriesMetadata +func (s GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecSummarySpecModelSpec) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecSummarySpecModelSpec return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaImportSuggestionDenyListEntriesResponse: -// 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"` - // ForceSendFields is a list of field names (e.g. "ErrorSamples") to +// GoogleCloudDiscoveryengineV1betaSearchRequestDataStoreSpec: A struct to +// define data stores to filter on in a search call and configurations for +// those data stores. Otherwise, an `INVALID_ARGUMENT` error is returned. +type GoogleCloudDiscoveryengineV1betaSearchRequestDataStoreSpec struct { + // BoostSpec: Optional. Boost specification to boost certain documents. For + // more information on boosting, see Boosting + // (https://cloud.google.com/generative-ai-app-builder/docs/boost-search-results) + BoostSpec *GoogleCloudDiscoveryengineV1betaSearchRequestBoostSpec `json:"boostSpec,omitempty"` + // DataStore: Required. Full resource name of DataStore, such as + // `projects/{project}/locations/{location}/collections/{collection_id}/dataStor + // es/{data_store_id}`. + DataStore string `json:"dataStore,omitempty"` + // Filter: Optional. Filter specification to filter documents in the data store + // specified by data_store field. For more information on filtering, see + // Filtering + // (https://cloud.google.com/generative-ai-app-builder/docs/filter-search-metadata) + Filter string `json:"filter,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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "ErrorSamples") to include in API + // 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. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1betaImportSuggestionDenyListEntriesResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaImportSuggestionDenyListEntriesResponse +func (s GoogleCloudDiscoveryengineV1betaSearchRequestDataStoreSpec) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaSearchRequestDataStoreSpec return gensupport.MarshalJSON(NoMethod(s), 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 +// 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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "CreateTime") to include in API - // requests with the JSON null value. By default, fields with empty values are - // omitted from API requests. See + // NullFields is a list of field names (e.g. "EmbeddingVectors") to include in + // API requests with the JSON null value. By default, fields with empty values + // are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1betaImportUserEventsMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaImportUserEventsMetadata +func (s GoogleCloudDiscoveryengineV1betaSearchRequestEmbeddingSpec) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaSearchRequestEmbeddingSpec return gensupport.MarshalJSON(NoMethod(s), 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"` - // 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 +// GoogleCloudDiscoveryengineV1betaSearchRequestEmbeddingSpecEmbeddingVector: +// 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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "ErrorConfig") to include in API + // 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. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1betaImportUserEventsResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaImportUserEventsResponse - return gensupport.MarshalJSON(NoMethod(s), 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"` - // 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. See - // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more - // details. - 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. See - // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. - NullFields []string `json:"-"` -} - -func (s GoogleCloudDiscoveryengineV1betaInterval) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaInterval +func (s GoogleCloudDiscoveryengineV1betaSearchRequestEmbeddingSpecEmbeddingVector) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaSearchRequestEmbeddingSpecEmbeddingVector return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -func (s *GoogleCloudDiscoveryengineV1betaInterval) UnmarshalJSON(data []byte) error { - type NoMethod GoogleCloudDiscoveryengineV1betaInterval +func (s *GoogleCloudDiscoveryengineV1betaSearchRequestEmbeddingSpecEmbeddingVector) UnmarshalJSON(data []byte) error { + type NoMethod GoogleCloudDiscoveryengineV1betaSearchRequestEmbeddingSpecEmbeddingVector var s1 struct { - ExclusiveMaximum gensupport.JSONFloat64 `json:"exclusiveMaximum"` - ExclusiveMinimum gensupport.JSONFloat64 `json:"exclusiveMinimum"` - Maximum gensupport.JSONFloat64 `json:"maximum"` - Minimum gensupport.JSONFloat64 `json:"minimum"` + Vector []gensupport.JSONFloat64 `json:"vector"` *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) + s.Vector = make([]float64, len(s1.Vector)) + for i := range s1.Vector { + s.Vector[i] = float64(s1.Vector[i]) + } return nil } -// GoogleCloudDiscoveryengineV1betaLanguageInfo: Language info for DataStore. -type GoogleCloudDiscoveryengineV1betaLanguageInfo struct { - // Language: Output only. Language part of normalized_language_code. E.g.: - // `en-US` -> `en`, `zh-Hans-HK` -> `zh`, `en` -> `en`. - Language string `json:"language,omitempty"` - // LanguageCode: The language code for the DataStore. - LanguageCode string `json:"languageCode,omitempty"` - // NormalizedLanguageCode: Output only. This is the normalized form of - // language_code. E.g.: language_code of `en-GB`, `en_GB`, `en-UK` or `en-gb` - // will have normalized_language_code of `en-GB`. - NormalizedLanguageCode string `json:"normalizedLanguageCode,omitempty"` - // Region: Output only. Region part of normalized_language_code, if present. - // E.g.: `en-US` -> `US`, `zh-Hans-HK` -> `HK`, `en` -> ``. - Region string `json:"region,omitempty"` - // ForceSendFields is a list of field names (e.g. "Language") to +// 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 facet values that are returned for this facet. If + // unspecified, defaults to 20. The maximum allowed value is 300. Values above + // 300 are coerced to 300. For aggregation in healthcare search, when the + // [FacetKey.key] is "healthcare_aggregation_key", the limit will be overridden + // to 10,000 internally, regardless of the value set here. 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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Language") to include in API - // requests with the JSON null value. By default, fields with empty values are - // omitted from API requests. See - // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. - NullFields []string `json:"-"` -} - -func (s GoogleCloudDiscoveryengineV1betaLanguageInfo) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaLanguageInfo - return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) -} - -// GoogleCloudDiscoveryengineV1betaNaturalLanguageQueryUnderstandingConfig: -// Configuration for Natural Language Query Understanding. -type GoogleCloudDiscoveryengineV1betaNaturalLanguageQueryUnderstandingConfig struct { - // Mode: Mode of Natural Language Query Understanding. If this field is unset, - // the behavior defaults to - // NaturalLanguageQueryUnderstandingConfig.Mode.DISABLED. - // - // Possible values: - // "MODE_UNSPECIFIED" - Default value. - // "DISABLED" - Natural Language Query Understanding is disabled. - // "ENABLED" - Natural Language Query Understanding is enabled. - 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. See - // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more - // details. - 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. See + // 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. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1betaNaturalLanguageQueryUnderstandingConfig) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaNaturalLanguageQueryUnderstandingConfig +func (s GoogleCloudDiscoveryengineV1betaSearchRequestFacetSpec) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaSearchRequestFacetSpec return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaProject: Metadata and configurations for a -// Google Cloud project in the service. -type GoogleCloudDiscoveryengineV1betaProject struct { - // CreateTime: Output only. The timestamp when this project is created. - CreateTime string `json:"createTime,omitempty"` - // Name: Output only. Full resource name of the project, for example - // `projects/{project}`. Note that when making requests, project number and - // project id are both acceptable, but the server will always respond in - // project number. - Name string `json:"name,omitempty"` - // ProvisionCompletionTime: Output only. The timestamp when this project is - // successfully provisioned. Empty value means this project is still - // provisioning and is not ready for use. - ProvisionCompletionTime string `json:"provisionCompletionTime,omitempty"` - // ServiceTermsMap: Output only. A map of terms of services. The key is the - // `id` of ServiceTerms. - ServiceTermsMap map[string]GoogleCloudDiscoveryengineV1betaProjectServiceTerms `json:"serviceTermsMap,omitempty"` - // ForceSendFields is a list of field names (e.g. "CreateTime") to +// 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 contain 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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "CreateTime") to include in API - // requests with the JSON null value. By default, fields with empty values are - // omitted from API requests. See + // NullFields is a list of field names (e.g. "CaseInsensitive") to include in + // API requests with the JSON null value. By default, fields with empty values + // are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1betaProject) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaProject +func (s GoogleCloudDiscoveryengineV1betaSearchRequestFacetSpecFacetKey) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaSearchRequestFacetSpecFacetKey return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaProjectServiceTerms: Metadata about the -// terms of service. -type GoogleCloudDiscoveryengineV1betaProjectServiceTerms struct { - // AcceptTime: The last time when the project agreed to the terms of service. - AcceptTime string `json:"acceptTime,omitempty"` - // DeclineTime: The last time when the project declined or revoked the - // agreement to terms of service. - DeclineTime string `json:"declineTime,omitempty"` - // Id: The unique identifier of this terms of service. Available terms: * - // `GA_DATA_USE_TERMS`: Terms for data use - // (https://cloud.google.com/retail/data-use-terms). When using this as `id`, - // the acceptable version to provide is `2022-11-23`. - Id string `json:"id,omitempty"` - // State: Whether the project has accepted/rejected the service terms or it is - // still pending. - // - // Possible values: - // "STATE_UNSPECIFIED" - The default value of the enum. This value is not - // actually used. - // "TERMS_ACCEPTED" - The project has given consent to the terms of service. - // "TERMS_PENDING" - The project is pending to review and accept the terms of - // service. - // "TERMS_DECLINED" - The project has declined or revoked the agreement to - // terms of service. - State string `json:"state,omitempty"` - // Version: The version string of the terms of service. For acceptable values, - // see the comments for id above. - Version string `json:"version,omitempty"` - // ForceSendFields is a list of field names (e.g. "AcceptTime") to +// 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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "AcceptTime") to include in API + // 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. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1betaProjectServiceTerms) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaProjectServiceTerms +func (s GoogleCloudDiscoveryengineV1betaSearchRequestImageQuery) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaSearchRequestImageQuery return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaProvisionProjectMetadata: Metadata -// associated with a project provision operation. -type GoogleCloudDiscoveryengineV1betaProvisionProjectMetadata struct { -} - -// 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"` - // IgnoredCount: Count of entries that were ignored as entries were not found. - IgnoredCount int64 `json:"ignoredCount,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 +// GoogleCloudDiscoveryengineV1betaSearchRequestNaturalLanguageQueryUnderstandin +// gSpec: Specification to enable natural language understanding capabilities +// for search requests. +type GoogleCloudDiscoveryengineV1betaSearchRequestNaturalLanguageQueryUnderstandingSpec struct { + // FilterExtractionCondition: The condition under which filter extraction + // should occur. Default to Condition.DISABLED. + // + // Possible values: + // "CONDITION_UNSPECIFIED" - Server behavior defaults to Condition.DISABLED. + // "DISABLED" - Disables NL filter extraction. + // "ENABLED" - Enables NL filter extraction. + FilterExtractionCondition string `json:"filterExtractionCondition,omitempty"` + // GeoSearchQueryDetectionFieldNames: Field names used for location-based + // filtering, where geolocation filters are detected in natural language search + // queries. Only valid when the FilterExtractionCondition is set to `ENABLED`. + // If this field is set, it overrides the field names set in + // ServingConfig.geo_search_query_detection_field_names. + GeoSearchQueryDetectionFieldNames []string `json:"geoSearchQueryDetectionFieldNames,omitempty"` + // ForceSendFields is a list of field names (e.g. "FilterExtractionCondition") + // to unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "CreateTime") to include in API - // requests with the JSON null value. By default, fields with empty values are - // omitted from API requests. See + // NullFields is a list of field names (e.g. "FilterExtractionCondition") to + // include in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1betaPurgeDocumentsMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaPurgeDocumentsMetadata +func (s GoogleCloudDiscoveryengineV1betaSearchRequestNaturalLanguageQueryUnderstandingSpec) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaSearchRequestNaturalLanguageQueryUnderstandingSpec return gensupport.MarshalJSON(NoMethod(s), 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. See +// GoogleCloudDiscoveryengineV1betaSearchRequestPersonalizationSpec: The +// specification for personalization. +type GoogleCloudDiscoveryengineV1betaSearchRequestPersonalizationSpec struct { + // Mode: The personalization mode of the search request. Defaults to Mode.AUTO. + // + // Possible values: + // "MODE_UNSPECIFIED" - Default value. In this case, server behavior defaults + // to Mode.AUTO. + // "AUTO" - Personalization is enabled if data quality requirements are met. + // "DISABLED" - Disable personalization. + 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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. 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. See + // 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. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1betaPurgeDocumentsResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaPurgeDocumentsResponse +func (s GoogleCloudDiscoveryengineV1betaSearchRequestPersonalizationSpec) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaSearchRequestPersonalizationSpec return gensupport.MarshalJSON(NoMethod(s), 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 +// 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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "CreateTime") to include in API + // NullFields is a list of field names (e.g. "Condition") to include in API // requests with the JSON null value. By default, fields with empty values are // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1betaPurgeSuggestionDenyListEntriesMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaPurgeSuggestionDenyListEntriesMetadata +func (s GoogleCloudDiscoveryengineV1betaSearchRequestQueryExpansionSpec) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaSearchRequestQueryExpansionSpec return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// 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 +// GoogleCloudDiscoveryengineV1betaSearchRequestSearchAsYouTypeSpec: +// Specification for search as you type in search requests. +type GoogleCloudDiscoveryengineV1betaSearchRequestSearchAsYouTypeSpec struct { + // Condition: The condition under which search as you type should occur. + // Default to Condition.DISABLED. + // + // Possible values: + // "CONDITION_UNSPECIFIED" - Server behavior defaults to Condition.DISABLED. + // "DISABLED" - Disables Search As You Type. + // "ENABLED" - Enables Search As You Type. + Condition string `json:"condition,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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "ErrorSamples") to include in API + // 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. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1betaPurgeSuggestionDenyListEntriesResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaPurgeSuggestionDenyListEntriesResponse +func (s GoogleCloudDiscoveryengineV1betaSearchRequestSearchAsYouTypeSpec) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaSearchRequestSearchAsYouTypeSpec return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaQualityMetrics: Describes the metrics -// produced by the evaluation. -type GoogleCloudDiscoveryengineV1betaQualityMetrics struct { - // DocNdcg: Normalized discounted cumulative gain (NDCG) per document, at - // various top-k cutoff levels. NDCG measures the ranking quality, giving - // higher relevance to top results. Example (top-3): Suppose SampleQuery with - // three retrieved documents (D1, D2, D3) and binary relevance judgements (1 - // for relevant, 0 for not relevant): Retrieved: [D3 (0), D1 (1), D2 (1)] - // Ideal: [D1 (1), D2 (1), D3 (0)] Calculate NDCG@3 for each SampleQuery: * - // DCG@3: 0/log2(1+1) + 1/log2(2+1) + 1/log2(3+1) = 1.13 * Ideal DCG@3: - // 1/log2(1+1) + 1/log2(2+1) + 0/log2(3+1) = 1.63 * NDCG@3: 1.13/1.63 = 0.693 - DocNdcg *GoogleCloudDiscoveryengineV1betaQualityMetricsTopkMetrics `json:"docNdcg,omitempty"` - // DocPrecision: Precision per document, at various top-k cutoff levels. - // Precision is the fraction of retrieved documents that are relevant. Example - // (top-5): * For a single SampleQuery, If 4 out of 5 retrieved documents in - // the top-5 are relevant, precision@5 = 4/5 = 0.8 - DocPrecision *GoogleCloudDiscoveryengineV1betaQualityMetricsTopkMetrics `json:"docPrecision,omitempty"` - // DocRecall: Recall per document, at various top-k cutoff levels. Recall is - // the fraction of relevant documents retrieved out of all relevant documents. - // Example (top-5): * For a single SampleQuery, If 3 out of 5 relevant - // documents are retrieved in the top-5, recall@5 = 3/5 = 0.6 - DocRecall *GoogleCloudDiscoveryengineV1betaQualityMetricsTopkMetrics `json:"docRecall,omitempty"` - // PageNdcg: Normalized discounted cumulative gain (NDCG) per page, at various - // top-k cutoff levels. NDCG measures the ranking quality, giving higher - // relevance to top results. Example (top-3): Suppose SampleQuery with three - // retrieved pages (P1, P2, P3) and binary relevance judgements (1 for - // relevant, 0 for not relevant): Retrieved: [P3 (0), P1 (1), P2 (1)] Ideal: - // [P1 (1), P2 (1), P3 (0)] Calculate NDCG@3 for SampleQuery: * DCG@3: - // 0/log2(1+1) + 1/log2(2+1) + 1/log2(3+1) = 1.13 * Ideal DCG@3: 1/log2(1+1) + - // 1/log2(2+1) + 0/log2(3+1) = 1.63 * NDCG@3: 1.13/1.63 = 0.693 - PageNdcg *GoogleCloudDiscoveryengineV1betaQualityMetricsTopkMetrics `json:"pageNdcg,omitempty"` - // PageRecall: Recall per page, at various top-k cutoff levels. Recall is the - // fraction of relevant pages retrieved out of all relevant pages. Example - // (top-5): * For a single SampleQuery, if 3 out of 5 relevant pages are - // retrieved in the top-5, recall@5 = 3/5 = 0.6 - PageRecall *GoogleCloudDiscoveryengineV1betaQualityMetricsTopkMetrics `json:"pageRecall,omitempty"` - // ForceSendFields is a list of field names (e.g. "DocNdcg") to unconditionally +// GoogleCloudDiscoveryengineV1betaSearchRequestSessionSpec: Session +// specification. Multi-turn Search feature is currently at private GA stage. +// Please use v1alpha or v1beta version instead before we launch this feature +// to public GA. Or ask for allowlisting through Google Support team. +type GoogleCloudDiscoveryengineV1betaSearchRequestSessionSpec struct { + // QueryId: If set, the search result gets stored to the "turn" specified by + // this query ID. Example: Let's say the session looks like this: session { + // name: ".../sessions/xxx" turns { query { text: "What is foo?" query_id: + // ".../questions/yyy" } answer: "Foo is ..." } turns { query { text: "How + // about bar then?" query_id: ".../questions/zzz" } } } The user can call + // /search API with a request like this: session: ".../sessions/xxx" + // session_spec { query_id: ".../questions/zzz" } Then, the API stores the + // search result, associated with the last turn. The stored search result can + // be used by a subsequent /answer API call (with the session ID and the query + // ID specified). Also, it is possible to call /search and /answer in parallel + // with the same session ID & query ID. + QueryId string `json:"queryId,omitempty"` + // SearchResultPersistenceCount: The number of top search results to persist. + // The persisted search results can be used for the subsequent /answer api + // call. This field is simliar to the `summary_result_count` field in + // SearchRequest.ContentSearchSpec.SummarySpec.summary_result_count. At most 10 + // results for documents mode, or 50 for chunks mode. + SearchResultPersistenceCount int64 `json:"searchResultPersistenceCount,omitempty"` + // ForceSendFields is a list of field names (e.g. "QueryId") to unconditionally // include in API requests. By default, fields with empty or default values are // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "DocNdcg") to include in API + // NullFields is a list of field names (e.g. "QueryId") to include in API // requests with the JSON null value. By default, fields with empty values are // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1betaQualityMetrics) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaQualityMetrics +func (s GoogleCloudDiscoveryengineV1betaSearchRequestSessionSpec) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaSearchRequestSessionSpec return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaQualityMetricsTopkMetrics: Stores the metric -// values at specific top-k levels. -type GoogleCloudDiscoveryengineV1betaQualityMetricsTopkMetrics struct { - // Top1: The top-1 value. - Top1 float64 `json:"top1,omitempty"` - // Top10: The top-10 value. - Top10 float64 `json:"top10,omitempty"` - // Top3: The top-3 value. - Top3 float64 `json:"top3,omitempty"` - // Top5: The top-5 value. - Top5 float64 `json:"top5,omitempty"` - // ForceSendFields is a list of field names (e.g. "Top1") to unconditionally +// GoogleCloudDiscoveryengineV1betaSearchRequestSpellCorrectionSpec: The +// specification for query spell correction. +type GoogleCloudDiscoveryengineV1betaSearchRequestSpellCorrectionSpec struct { + // Mode: The mode under which spell correction replaces the original search + // query. Defaults to Mode.AUTO. + // + // Possible values: + // "MODE_UNSPECIFIED" - Unspecified spell correction mode. In this case, + // server behavior defaults to Mode.AUTO. + // "SUGGESTION_ONLY" - Search API tries to find a spelling suggestion. If a + // suggestion is found, it is put in the SearchResponse.corrected_query. The + // spelling suggestion won't 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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Top1") to include in API requests + // 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. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1betaQualityMetricsTopkMetrics) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaQualityMetricsTopkMetrics - return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) -} - -func (s *GoogleCloudDiscoveryengineV1betaQualityMetricsTopkMetrics) UnmarshalJSON(data []byte) error { - type NoMethod GoogleCloudDiscoveryengineV1betaQualityMetricsTopkMetrics - var s1 struct { - Top1 gensupport.JSONFloat64 `json:"top1"` - Top10 gensupport.JSONFloat64 `json:"top10"` - Top3 gensupport.JSONFloat64 `json:"top3"` - Top5 gensupport.JSONFloat64 `json:"top5"` - *NoMethod - } - s1.NoMethod = (*NoMethod)(s) - if err := json.Unmarshal(data, &s1); err != nil { - return err - } - s.Top1 = float64(s1.Top1) - s.Top10 = float64(s1.Top10) - s.Top3 = float64(s1.Top3) - s.Top5 = float64(s1.Top5) - return nil -} - -// 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}/dataStores/ - // {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. "JsonSchema") to - // unconditionally include in API requests. By default, fields with empty or - // default values are omitted from API requests. See - // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more - // details. - 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. See - // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. - NullFields []string `json:"-"` -} - -func (s GoogleCloudDiscoveryengineV1betaSchema) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaSchema +func (s GoogleCloudDiscoveryengineV1betaSearchRequestSpellCorrectionSpec) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaSearchRequestSpellCorrectionSpec return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } - -// GoogleCloudDiscoveryengineV1betaSearchLinkPromotion: Promotion proto -// includes uri and other helping information to display the promotion. -type GoogleCloudDiscoveryengineV1betaSearchLinkPromotion struct { - // Description: Optional. The Promotion description. Maximum length: 200 - // characters. - Description string `json:"description,omitempty"` - // Enabled: Optional. The enabled promotion will be returned for any serving - // configs associated with the parent of the control this promotion is attached - // to. This flag is used for basic site search only. - Enabled bool `json:"enabled,omitempty"` - // ImageUri: Optional. The promotion thumbnail image url. - ImageUri string `json:"imageUri,omitempty"` - // Title: Required. The title of the promotion. Maximum length: 160 characters. - Title string `json:"title,omitempty"` - // Uri: Required. The URL for the page the user wants to promote. - Uri string `json:"uri,omitempty"` - // ForceSendFields is a list of field names (e.g. "Description") to - // unconditionally include in API requests. By default, fields with empty or - // default values are omitted from API requests. See + +// GoogleCloudDiscoveryengineV1betaSingleRegionKey: Metadata for +// single-regional CMEKs. +type GoogleCloudDiscoveryengineV1betaSingleRegionKey struct { + // KmsKey: Required. Single-regional kms key resource name which will be used + // to encrypt resources + // `projects/{project}/locations/{location}/keyRings/{keyRing}/cryptoKeys/{keyId + // }`. + KmsKey string `json:"kmsKey,omitempty"` + // ForceSendFields is a list of field names (e.g. "KmsKey") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Description") to include in API + // NullFields is a list of field names (e.g. "KmsKey") to include in API // requests with the JSON null value. By default, fields with empty values are // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1betaSearchLinkPromotion) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaSearchLinkPromotion +func (s GoogleCloudDiscoveryengineV1betaSingleRegionKey) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaSingleRegionKey return gensupport.MarshalJSON(NoMethod(s), 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/generative-ai-app-builder/docs/boost-search-results) - BoostSpec *GoogleCloudDiscoveryengineV1betaSearchRequestBoostSpec `json:"boostSpec,omitempty"` - // Branch: The branch resource name, such as - // `projects/*/locations/global/collections/default_collection/dataStores/defaul - // t_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"` - // DataStoreSpecs: Specs defining DataStores to filter on in a search call and - // configurations for those data stores. This is only considered for Engines - // with multiple data stores. For engines with a single data store, the specs - // directly under SearchRequest should be used. - DataStoreSpecs []*GoogleCloudDiscoveryengineV1betaSearchRequestDataStoreSpec `json:"dataStoreSpecs,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_path. - 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"` - // LanguageCode: The BCP-47 language code, such as "en-US" or "sr-Latn". For - // more information, see Standard fields - // (https://cloud.google.com/apis/design/standard_fields). This field helps to - // better interpret the query. If a value isn't specified, the query language - // code is automatically detected, which may not be accurate. - LanguageCode string `json:"languageCode,omitempty"` - // NaturalLanguageQueryUnderstandingSpec: If - // `naturalLanguageQueryUnderstandingSpec` is not specified, no additional - // natural language query understanding will be done. - NaturalLanguageQueryUnderstandingSpec *GoogleCloudDiscoveryengineV1betaSearchRequestNaturalLanguageQueryUnderstandingSpec `json:"naturalLanguageQueryUnderstandingSpec,omitempty"` - // Offset: A 0-indexed integer that specifies the current offset (that is, - // starting result location, amongst the Documents deemed by the API as - // 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"` - // OneBoxPageSize: The maximum number of results to return for OneBox. This - // applies to each OneBox type individually. Default number is 10. - OneBoxPageSize int64 `json:"oneBoxPageSize,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 - // the website search results, see Order web search results - // (https://cloud.google.com/generative-ai-app-builder/docs/order-web-search-results). - // For more information on ordering the healthcare search results, see Order - // healthcare search results - // (https://cloud.google.com/generative-ai-app-builder/docs/order-hc-results). - // If this field is unrecognizable, an `INVALID_ARGUMENT` is returned. - OrderBy string `json:"orderBy,omitempty"` - // PageSize: Maximum number of Documents to return. The maximum allowed value - // depends on the data type. Values above the maximum value are coerced to the - // maximum value. * Websites with basic indexing: Default `10`, Maximum `25`. * - // Websites with advanced indexing: Default `25`, Maximum `50`. * Other: - // Default `50`, Maximum `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. For 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. For example, `search_type: 1` - Params googleapi.RawMessage `json:"params,omitempty"` - // PersonalizationSpec: The specification for personalization. Notice that if - // both ServingConfig.personalization_spec and - // SearchRequest.personalization_spec are set, - // SearchRequest.personalization_spec overrides - // ServingConfig.personalization_spec. - PersonalizationSpec *GoogleCloudDiscoveryengineV1betaSearchRequestPersonalizationSpec `json:"personalizationSpec,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 - // joined 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"` - // RegionCode: The Unicode country/region code (CLDR) of a location, such as - // "US" and "419". For more information, see Standard fields - // (https://cloud.google.com/apis/design/standard_fields). If set, then results - // will be boosted based on the region_code provided. - RegionCode string `json:"regionCode,omitempty"` - // RelevanceThreshold: The relevance threshold of the search results. Default - // to Google defined threshold, leveraging a balance of precision and recall to - // deliver both highly accurate results and comprehensive coverage of relevant - // information. +// GoogleCloudDiscoveryengineV1betaSiteVerificationInfo: Verification +// information for target sites in advanced site search. +type GoogleCloudDiscoveryengineV1betaSiteVerificationInfo struct { + // SiteVerificationState: Site verification state indicating the ownership and + // validity. // // Possible values: - // "RELEVANCE_THRESHOLD_UNSPECIFIED" - Default value. In this case, server - // behavior defaults to Google defined threshold. - // "LOWEST" - Lowest relevance threshold. - // "LOW" - Low relevance threshold. - // "MEDIUM" - Medium relevance threshold. - // "HIGH" - High relevance threshold. - RelevanceThreshold string `json:"relevanceThreshold,omitempty"` - // SafeSearch: Whether to turn on safe search. This is only supported for - // website search. - SafeSearch bool `json:"safeSearch,omitempty"` - // SearchAsYouTypeSpec: Search as you type configuration. Only supported for - // the IndustryVertical.MEDIA vertical. - SearchAsYouTypeSpec *GoogleCloudDiscoveryengineV1betaSearchRequestSearchAsYouTypeSpec `json:"searchAsYouTypeSpec,omitempty"` - // ServingConfig: Required. The resource name of the Search serving config, - // such as - // `projects/*/locations/global/collections/default_collection/engines/*/serving - // Configs/default_serving_config`, or - // `projects/*/locations/global/collections/default_collection/dataStores/defaul - // t_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"` - // Session: The session resource name. Optional. Session allows users to do - // multi-turn /search API calls or coordination between /search API calls and - // /answer API calls. Example #1 (multi-turn /search API calls): 1. Call - // /search API with the auto-session mode (see below). 2. Call /search API with - // the session ID generated in the first call. Here, the previous search query - // gets considered in query standing. I.e., if the first query is "How did - // Alphabet do in 2022?" and the current query is "How about 2023?", the - // current query will be interpreted as "How did Alphabet do in 2023?". Example - // #2 (coordination between /search API calls and /answer API calls): 1. Call - // /search API with the auto-session mode (see below). 2. Call /answer API with - // the session ID generated in the first call. Here, the answer generation - // happens in the context of the search results from the first search call. - // Auto-session mode: when `projects/.../sessions/-` is used, a new session - // gets automatically created. Otherwise, users can use the create-session API - // to create a session manually. Multi-turn Search feature is currently at - // private GA stage. Please use v1alpha or v1beta version instead before we - // launch this feature to public GA. Or ask for allowlisting through Google - // Support team. - Session string `json:"session,omitempty"` - // SessionSpec: Session specification. Can be used only when `session` is set. - SessionSpec *GoogleCloudDiscoveryengineV1betaSearchRequestSessionSpec `json:"sessionSpec,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 + // "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. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + 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. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1betaSiteVerificationInfo) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaSiteVerificationInfo + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1betaSitemap: A sitemap for the SiteSearchEngine. +type GoogleCloudDiscoveryengineV1betaSitemap struct { + // CreateTime: Output only. The sitemap's creation time. + CreateTime string `json:"createTime,omitempty"` + // Name: Output only. The fully qualified resource name of the sitemap. + // `projects/*/locations/*/collections/*/dataStores/*/siteSearchEngine/sitemaps/ + // *` The `sitemap_id` suffix is system-generated. + Name string `json:"name,omitempty"` + // Uri: Public URI for the sitemap, e.g. `www.example.com/sitemap.xml`. + Uri string `json:"uri,omitempty"` + // ForceSendFields is a list of field names (e.g. "CreateTime") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "BoostSpec") to include in API + // NullFields is a list of field names (e.g. "CreateTime") to include in API // requests with the JSON null value. By default, fields with empty values are // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1betaSearchRequest) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaSearchRequest +func (s GoogleCloudDiscoveryengineV1betaSitemap) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaSitemap return gensupport.MarshalJSON(NoMethod(s), 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 +// 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}/dataStores/ + // {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"` + // RootDomainUri: Output only. Root domain of the provided_uri_pattern. + RootDomainUri string `json:"rootDomainUri,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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "ConditionBoostSpecs") to include + // 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. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1betaTargetSite) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaTargetSite + return gensupport.MarshalJSON(NoMethod(s), 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. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + 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. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1betaTargetSiteFailureReason) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaTargetSiteFailureReason + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1betaTargetSiteFailureReasonQuotaFailure: Failed +// due to insufficient quota. +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. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + 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. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1betaSearchRequestBoostSpec) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaSearchRequestBoostSpec +func (s GoogleCloudDiscoveryengineV1betaTargetSiteFailureReasonQuotaFailure) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaTargetSiteFailureReasonQuotaFailure return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaSearchRequestBoostSpecConditionBoostSpec: -// 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. Only one of - // the (condition, boost) combination or the boost_control_spec below are set. - // If both are set then the global boost is ignored and the more fine-grained - // boost_control_spec is applied. - Boost float64 `json:"boost,omitempty"` - // BoostControlSpec: Complex specification for custom ranking based on customer - // defined attribute value. - BoostControlSpec *GoogleCloudDiscoveryengineV1betaSearchRequestBoostSpecConditionBoostSpecBoostControlSpec `json:"boostControlSpec,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": - // `(document_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 +// GoogleCloudDiscoveryengineV1betaTrainCustomModelMetadata: Metadata related +// to the progress of the TrainCustomModel operation. This is returned by the +// google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1betaTrainCustomModelMetadata struct { + // CreateTime: Operation create time. + CreateTime string `json:"createTime,omitempty"` + // UpdateTime: Operation last update time. If the operation is done, this is + // also the finish time. + UpdateTime string `json:"updateTime,omitempty"` + // ForceSendFields is a list of field names (e.g. "CreateTime") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "CreateTime") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1betaTrainCustomModelMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaTrainCustomModelMetadata + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1betaTrainCustomModelResponse: Response of the +// TrainCustomModelRequest. This message is returned by the +// google.longrunning.Operations.response field. +type GoogleCloudDiscoveryengineV1betaTrainCustomModelResponse struct { + // ErrorConfig: Echoes the destination for the complete errors in the request + // if set. + ErrorConfig *GoogleCloudDiscoveryengineV1betaImportErrorConfig `json:"errorConfig,omitempty"` + // ErrorSamples: A sample of errors encountered while processing the data. + ErrorSamples []*GoogleRpcStatus `json:"errorSamples,omitempty"` + // Metrics: The metrics of the trained model. + Metrics map[string]float64 `json:"metrics,omitempty"` + // ModelName: Fully qualified name of the CustomTuningModel. + ModelName string `json:"modelName,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 job + // creation is in progress. * **training**: Model is actively training. * + // **evaluating**: The model is evaluating trained metrics. * **indexing**: The + // model trained metrics are indexing. * **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. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + 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. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1betaTrainCustomModelResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaTrainCustomModelResponse + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1betaTuneEngineMetadata: Metadata associated with +// a tune operation. +type GoogleCloudDiscoveryengineV1betaTuneEngineMetadata struct { + // Engine: Required. The resource name of the engine that this tune applies to. + // Format: + // `projects/{project}/locations/{location}/collections/{collection_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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Boost") to include in API + // 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. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1betaTuneEngineMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaTuneEngineMetadata + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1betaTuneEngineResponse: Response associated with +// a tune operation. +type GoogleCloudDiscoveryengineV1betaTuneEngineResponse struct { +} + +// 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. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "CreateTime") to include in API // requests with the JSON null value. By default, fields with empty values are // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1betaSearchRequestBoostSpecConditionBoostSpec) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaSearchRequestBoostSpecConditionBoostSpec +func (s GoogleCloudDiscoveryengineV1betaUpdateSchemaMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaUpdateSchemaMetadata return gensupport.MarshalJSON(NoMethod(s), 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 +// 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. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "CreateTime") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` } -// GoogleCloudDiscoveryengineV1betaSearchRequestBoostSpecConditionBoostSpecBoost -// ControlSpec: Specification for custom ranking based on customer specified -// attribute value. It provides more controls for customized ranking than the -// simple (condition, boost) combination above. -type GoogleCloudDiscoveryengineV1betaSearchRequestBoostSpecConditionBoostSpecBoostControlSpec struct { - // AttributeType: The attribute type to be used to determine the boost amount. - // The attribute value can be derived from the field value of the specified - // field_name. In the case of numerical it is straightforward i.e. - // attribute_value = numerical_field_value. In the case of freshness however, - // attribute_value = (time.now() - datetime_field_value). - // - // Possible values: - // "ATTRIBUTE_TYPE_UNSPECIFIED" - Unspecified AttributeType. - // "NUMERICAL" - The value of the numerical field will be used to dynamically - // update the boost amount. In this case, the attribute_value (the x value) of - // the control point will be the actual value of the numerical field for which - // the boost_amount is specified. - // "FRESHNESS" - For the freshness use case the attribute value will be the - // duration between the current time and the date in the datetime field - // specified. The value must be formatted as an XSD `dayTimeDuration` value (a - // restricted subset of an ISO 8601 duration value). The pattern for this is: - // `nDnM]`. For example, `5D`, `3DT12H30M`, `T24H`. - AttributeType string `json:"attributeType,omitempty"` - // ControlPoints: The control points used to define the curve. The monotonic - // function (defined through the interpolation_type above) passes through the - // control points listed here. - ControlPoints []*GoogleCloudDiscoveryengineV1betaSearchRequestBoostSpecConditionBoostSpecBoostControlSpecControlPoint `json:"controlPoints,omitempty"` - // FieldName: The name of the field whose value will be used to determine the - // boost amount. - FieldName string `json:"fieldName,omitempty"` - // InterpolationType: The interpolation type to be applied to connect the - // control points listed below. - // - // Possible values: - // "INTERPOLATION_TYPE_UNSPECIFIED" - Interpolation type is unspecified. In - // this case, it defaults to Linear. - // "LINEAR" - Piecewise linear interpolation will be applied. - InterpolationType string `json:"interpolationType,omitempty"` - // ForceSendFields is a list of field names (e.g. "AttributeType") to +func (s GoogleCloudDiscoveryengineV1betaUpdateTargetSiteMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaUpdateTargetSiteMetadata + return gensupport.MarshalJSON(NoMethod(s), 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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "AttributeType") to include in API + // 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. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1betaSearchRequestBoostSpecConditionBoostSpecBoostControlSpec) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaSearchRequestBoostSpecConditionBoostSpecBoostControlSpec +func (s GoogleCloudDiscoveryengineV1betaUserInfo) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaUserInfo return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaSearchRequestBoostSpecConditionBoostSpecBoost -// ControlSpecControlPoint: The control points used to define the curve. The -// curve defined through these control points can only be monotonically -// increasing or decreasing(constant values are acceptable). -type GoogleCloudDiscoveryengineV1betaSearchRequestBoostSpecConditionBoostSpecBoostControlSpecControlPoint struct { - // AttributeValue: Can be one of: 1. The numerical field value. 2. The duration - // spec for freshness: The value must be formatted as an XSD `dayTimeDuration` - // value (a restricted subset of an ISO 8601 duration value). The pattern for - // this is: `nDnM]`. - AttributeValue string `json:"attributeValue,omitempty"` - // BoostAmount: The value between -1 to 1 by which to boost the score if the - // attribute_value evaluates to the value specified above. - BoostAmount float64 `json:"boostAmount,omitempty"` - // ForceSendFields is a list of field names (e.g. "AttributeValue") to +// GoogleCloudDiscoveryengineV1betaWorkspaceConfig: Config to store data store +// type configuration for workspace data +type GoogleCloudDiscoveryengineV1betaWorkspaceConfig struct { + // DasherCustomerId: Obfuscated Dasher customer ID. + DasherCustomerId string `json:"dasherCustomerId,omitempty"` + // SuperAdminEmailAddress: Optional. The super admin email address for the + // workspace that will be used for access token generation. For now we only use + // it for Native Google Drive connector data ingestion. + SuperAdminEmailAddress string `json:"superAdminEmailAddress,omitempty"` + // SuperAdminServiceAccount: Optional. The super admin service account for the + // workspace that will be used for access token generation. For now we only use + // it for Native Google Drive connector data ingestion. + SuperAdminServiceAccount string `json:"superAdminServiceAccount,omitempty"` + // Type: The Google Workspace data source. + // + // Possible values: + // "TYPE_UNSPECIFIED" - Defaults to an unspecified Workspace type. + // "GOOGLE_DRIVE" - Workspace Data Store contains Drive data + // "GOOGLE_MAIL" - Workspace Data Store contains Mail data + // "GOOGLE_SITES" - Workspace Data Store contains Sites data + // "GOOGLE_CALENDAR" - Workspace Data Store contains Calendar data + // "GOOGLE_CHAT" - Workspace Data Store contains Chat data + // "GOOGLE_GROUPS" - Workspace Data Store contains Groups data + // "GOOGLE_KEEP" - Workspace Data Store contains Keep data + Type string `json:"type,omitempty"` + // ForceSendFields is a list of field names (e.g. "DasherCustomerId") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "AttributeValue") to include in + // NullFields is a list of field names (e.g. "DasherCustomerId") to include in // API requests with the JSON null value. By default, fields with empty values // are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1betaSearchRequestBoostSpecConditionBoostSpecBoostControlSpecControlPoint) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaSearchRequestBoostSpecConditionBoostSpecBoostControlSpecControlPoint +func (s GoogleCloudDiscoveryengineV1betaWorkspaceConfig) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaWorkspaceConfig return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -func (s *GoogleCloudDiscoveryengineV1betaSearchRequestBoostSpecConditionBoostSpecBoostControlSpecControlPoint) UnmarshalJSON(data []byte) error { - type NoMethod GoogleCloudDiscoveryengineV1betaSearchRequestBoostSpecConditionBoostSpecBoostControlSpecControlPoint - var s1 struct { - BoostAmount gensupport.JSONFloat64 `json:"boostAmount"` - *NoMethod - } - s1.NoMethod = (*NoMethod)(s) - if err := json.Unmarshal(data, &s1); err != nil { - return err - } - s.BoostAmount = float64(s1.BoostAmount) - return nil +// GoogleLongrunningCancelOperationRequest: The request message for +// Operations.CancelOperation. +type GoogleLongrunningCancelOperationRequest struct { } -// GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpec: A -// specification for configuring the behavior of content search. -type GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpec struct { - // ChunkSpec: Specifies the chunk spec to be returned from the search response. - // Only available if the SearchRequest.ContentSearchSpec.search_result_mode is - // set to CHUNKS - ChunkSpec *GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecChunkSpec `json:"chunkSpec,omitempty"` - // ExtractiveContentSpec: If there is no extractive_content_spec provided, - // there will be no extractive answer in the search response. - ExtractiveContentSpec *GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecExtractiveContentSpec `json:"extractiveContentSpec,omitempty"` - // SearchResultMode: Specifies the search result mode. If unspecified, the - // search result mode defaults to `DOCUMENTS`. - // - // Possible values: - // "SEARCH_RESULT_MODE_UNSPECIFIED" - Default value. - // "DOCUMENTS" - Returns documents in the search result. - // "CHUNKS" - Returns chunks in the search result. Only available if the - // DocumentProcessingConfig.chunking_config is specified. - SearchResultMode string `json:"searchResultMode,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. "ChunkSpec") to +// 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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "ChunkSpec") to include in API - // requests with the JSON null value. By default, fields with empty values are - // omitted from API requests. See + // NullFields is a list of field names (e.g. "NextPageToken") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleLongrunningListOperationsResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleLongrunningListOperationsResponse + return gensupport.MarshalJSON(NoMethod(s), 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. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "Done") to include in API requests + // with the JSON null value. By default, fields with empty values are omitted + // from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpec) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpec +func (s GoogleLongrunningOperation) MarshalJSON() ([]byte, error) { + type NoMethod GoogleLongrunningOperation return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecChunkSpec: -// Specifies the chunk spec to be returned from the search response. Only -// available if the SearchRequest.ContentSearchSpec.search_result_mode is set -// to CHUNKS -type GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecChunkSpec struct { - // NumNextChunks: The number of next chunks to be returned of the current - // chunk. The maximum allowed value is 3. If not specified, no next chunks will - // be returned. - NumNextChunks int64 `json:"numNextChunks,omitempty"` - // NumPreviousChunks: The number of previous chunks to be returned of the - // current chunk. The maximum allowed value is 3. If not specified, no previous - // chunks will be returned. - NumPreviousChunks int64 `json:"numPreviousChunks,omitempty"` - // ForceSendFields is a list of field names (e.g. "NumNextChunks") to +// GoogleMonitoringV3Point: A single data point in a time series. +type GoogleMonitoringV3Point struct { + // Interval: The time interval to which the data point applies. For `GAUGE` + // metrics, the start time is optional, but if it is supplied, it must equal + // the end time. For `DELTA` metrics, the start and end time should specify a + // non-zero interval, with subsequent points specifying contiguous and + // non-overlapping intervals. For `CUMULATIVE` metrics, the start and end time + // should specify a non-zero interval, with subsequent points specifying the + // same start time and increasing end times, until an event resets the + // cumulative value to zero and sets a new start time for the following points. + Interval *GoogleMonitoringV3TimeInterval `json:"interval,omitempty"` + // Value: The value of the data point. + Value *GoogleMonitoringV3TypedValue `json:"value,omitempty"` + // ForceSendFields is a list of field names (e.g. "Interval") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "NumNextChunks") to include in API + // NullFields is a list of field names (e.g. "Interval") to include in API // requests with the JSON null value. By default, fields with empty values are // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecChunkSpec) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecChunkSpec - return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) -} - -// GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecExtractiveConte -// ntSpec: 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"` - // ReturnExtractiveSegmentScore: Specifies whether to return the confidence - // score from the extractive segments in each search result. This feature is - // available only for new or allowlisted data stores. To allowlist your data - // store, contact your Customer Engineer. The default value is `false`. - ReturnExtractiveSegmentScore bool `json:"returnExtractiveSegmentScore,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. See - // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more - // details. - 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. See - // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. - NullFields []string `json:"-"` -} - -func (s GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecExtractiveContentSpec) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecExtractiveContentSpec +func (s GoogleMonitoringV3Point) MarshalJSON() ([]byte, error) { + type NoMethod GoogleMonitoringV3Point return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecSnippetSpec: 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. See +// GoogleMonitoringV3TimeInterval: A time interval extending just after a start +// time through an end time. If the start time is the same as the end time, +// then the interval represents a single point in time. +type GoogleMonitoringV3TimeInterval struct { + // EndTime: Required. The end of the time interval. + EndTime string `json:"endTime,omitempty"` + // StartTime: Optional. The beginning of the time interval. The default value + // for the start time is the end time. The start time must not be later than + // the end time. + StartTime string `json:"startTime,omitempty"` + // ForceSendFields is a list of field names (e.g. "EndTime") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "MaxSnippetCount") to include in - // API requests with the JSON null value. By default, fields with empty values - // are omitted from API requests. See + // NullFields is a list of field names (e.g. "EndTime") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecSnippetSpec) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecSnippetSpec +func (s GoogleMonitoringV3TimeInterval) MarshalJSON() ([]byte, error) { + type NoMethod GoogleMonitoringV3TimeInterval return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecSummarySpec: 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"` - // IgnoreJailBreakingQuery: Optional. Specifies whether to filter out - // jail-breaking queries. The default value is `false`. Google employs - // search-query classification to detect jail-breaking queries. No summary is - // returned if the search query is classified as a jail-breaking query. A user - // might add instructions to the query to change the tone, style, language, - // content of the answer, or ask the model to act as a different entity, e.g. - // "Reply in the tone of a competing company's CEO". If this field is set to - // `true`, we skip generating summaries for jail-breaking queries and return - // fallback messages instead. - IgnoreJailBreakingQuery bool `json:"ignoreJailBreakingQuery,omitempty"` - // IgnoreLowRelevantContent: Specifies whether to filter out queries that have - // low relevance. The default value is `false`. If this field is set to - // `false`, all search results are used regardless of relevance to generate - // answers. If set to `true`, only queries with high relevance search results - // will generate answers. - IgnoreLowRelevantContent bool `json:"ignoreLowRelevantContent,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 10 results for - // documents mode, or 50 for chunks mode, can be used to generate a summary. - // The chunks mode is used when - // SearchRequest.ContentSearchSpec.search_result_mode is set to CHUNKS. - SummaryResultCount int64 `json:"summaryResultCount,omitempty"` - // UseSemanticChunks: If true, answer will be generated from most relevant - // chunks from top search results. This feature will improve summary quality. - // Note that with this feature enabled, not all top search results will be - // referenced and included in the reference list, so the citation source index - // only points to the search results listed in the reference list. - UseSemanticChunks bool `json:"useSemanticChunks,omitempty"` - // ForceSendFields is a list of field names (e.g. "IgnoreAdversarialQuery") to +// GoogleMonitoringV3TimeSeries: A collection of data points that describes the +// time-varying values of a metric. A time series is identified by a +// combination of a fully-specified monitored resource and a fully-specified +// metric. This type is used for both listing and creating time series. +type GoogleMonitoringV3TimeSeries struct { + // Description: Input only. A detailed description of the time series that will + // be associated with the google.api.MetricDescriptor for the metric. Once set, + // this field cannot be changed through CreateTimeSeries. + Description string `json:"description,omitempty"` + // Metadata: Output only. The associated monitored resource metadata. When + // reading a time series, this field will include metadata labels that are + // explicitly named in the reduction. When creating a time series, this field + // is ignored. + Metadata *GoogleApiMonitoredResourceMetadata `json:"metadata,omitempty"` + // Metric: The associated metric. A fully-specified metric used to identify the + // time series. + Metric *GoogleApiMetric `json:"metric,omitempty"` + // MetricKind: The metric kind of the time series. When listing time series, + // this metric kind might be different from the metric kind of the associated + // metric if this time series is an alignment or reduction of other time + // series. When creating a time series, this field is optional. If present, it + // must be the same as the metric kind of the associated metric. If the + // associated metric's descriptor must be auto-created, then this field + // specifies the metric kind of the new descriptor and must be either `GAUGE` + // (the default) or `CUMULATIVE`. + // + // Possible values: + // "METRIC_KIND_UNSPECIFIED" - Do not use this default value. + // "GAUGE" - An instantaneous measurement of a value. + // "DELTA" - The change in a value during a time interval. + // "CUMULATIVE" - A value accumulated over a time interval. Cumulative + // measurements in a time series should have the same start time and increasing + // end times, until an event resets the cumulative value to zero and sets a new + // start time for the following points. + MetricKind string `json:"metricKind,omitempty"` + // Points: The data points of this time series. When listing time series, + // points are returned in reverse time order. When creating a time series, this + // field must contain exactly one point and the point's type must be the same + // as the value type of the associated metric. If the associated metric's + // descriptor must be auto-created, then the value type of the descriptor is + // determined by the point's type, which must be `BOOL`, `INT64`, `DOUBLE`, or + // `DISTRIBUTION`. + Points []*GoogleMonitoringV3Point `json:"points,omitempty"` + // Resource: The associated monitored resource. Custom metrics can use only + // certain monitored resource types in their time series data. For more + // information, see Monitored resources for custom metrics + // (https://cloud.google.com/monitoring/custom-metrics/creating-metrics#custom-metric-resources). + Resource *GoogleApiMonitoredResource `json:"resource,omitempty"` + // Unit: The units in which the metric value is reported. It is only applicable + // if the `value_type` is `INT64`, `DOUBLE`, or `DISTRIBUTION`. The `unit` + // defines the representation of the stored metric values. This field can only + // be changed through CreateTimeSeries when it is empty. + Unit string `json:"unit,omitempty"` + // ValueType: The value type of the time series. When listing time series, this + // value type might be different from the value type of the associated metric + // if this time series is an alignment or reduction of other time series. When + // creating a time series, this field is optional. If present, it must be the + // same as the type of the data in the `points` field. + // + // Possible values: + // "VALUE_TYPE_UNSPECIFIED" - Do not use this default value. + // "BOOL" - The value is a boolean. This value type can be used only if the + // metric kind is `GAUGE`. + // "INT64" - The value is a signed 64-bit integer. + // "DOUBLE" - The value is a double precision floating point number. + // "STRING" - The value is a text string. This value type can be used only if + // the metric kind is `GAUGE`. + // "DISTRIBUTION" - The value is a `Distribution`. + // "MONEY" - The value is money. + ValueType string `json:"valueType,omitempty"` + // ForceSendFields is a list of field names (e.g. "Description") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "IgnoreAdversarialQuery") to - // include in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. See + // NullFields is a list of field names (e.g. "Description") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecSummarySpec) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecSummarySpec +func (s GoogleMonitoringV3TimeSeries) MarshalJSON() ([]byte, error) { + type NoMethod GoogleMonitoringV3TimeSeries return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecSummarySpecMode -// lPromptSpec: 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 +// GoogleMonitoringV3TypedValue: A single strongly-typed value. +type GoogleMonitoringV3TypedValue struct { + // BoolValue: A Boolean value: `true` or `false`. + BoolValue bool `json:"boolValue,omitempty"` + // DistributionValue: A distribution value. + DistributionValue *GoogleApiDistribution `json:"distributionValue,omitempty"` + // DoubleValue: A 64-bit double-precision floating-point number. Its magnitude + // is approximately ±10±300 and it has 16 significant digits of precision. + DoubleValue float64 `json:"doubleValue,omitempty"` + // Int64Value: A 64-bit integer. Its range is approximately ±9.2x1018. + Int64Value int64 `json:"int64Value,omitempty,string"` + // StringValue: A variable-length string value. + StringValue string `json:"stringValue,omitempty"` + // ForceSendFields is a list of field names (e.g. "BoolValue") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Preamble") to include in API + // NullFields is a list of field names (e.g. "BoolValue") to include in API // requests with the JSON null value. By default, fields with empty values are // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecSummarySpecModelPromptSpec) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecSummarySpecModelPromptSpec +func (s GoogleMonitoringV3TypedValue) MarshalJSON() ([]byte, error) { + type NoMethod GoogleMonitoringV3TypedValue return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecSummarySpecMode -// lSpec: 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 model. For more information, see Answer - // generation model versions and lifecycle - // (https://cloud.google.com/generative-ai-app-builder/docs/answer-generation-models). - // * `preview`: string. (Public preview) Uses a preview model. For more - // information, see Answer generation model versions and lifecycle - // (https://cloud.google.com/generative-ai-app-builder/docs/answer-generation-models). - Version string `json:"version,omitempty"` - // ForceSendFields is a list of field names (e.g. "Version") to unconditionally +func (s *GoogleMonitoringV3TypedValue) UnmarshalJSON(data []byte) error { + type NoMethod GoogleMonitoringV3TypedValue + var s1 struct { + DoubleValue gensupport.JSONFloat64 `json:"doubleValue"` + *NoMethod + } + s1.NoMethod = (*NoMethod)(s) + if err := json.Unmarshal(data, &s1); err != nil { + return err + } + s.DoubleValue = float64(s1.DoubleValue) + return nil +} + +// 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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Version") to include in API - // requests with the JSON null value. By default, fields with empty values are - // omitted from API requests. See + // NullFields is a list of field names (e.g. "Code") to include in API requests + // with the JSON null value. By default, fields with empty values are omitted + // from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecSummarySpecModelSpec) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecSummarySpecModelSpec +func (s GoogleRpcStatus) MarshalJSON() ([]byte, error) { + type NoMethod GoogleRpcStatus return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaSearchRequestDataStoreSpec: A struct to -// define data stores to filter on in a search call and configurations for -// those data stores. Otherwise, an `INVALID_ARGUMENT` error is returned. -type GoogleCloudDiscoveryengineV1betaSearchRequestDataStoreSpec struct { - // BoostSpec: Optional. Boost specification to boost certain documents. For - // more information on boosting, see Boosting - // (https://cloud.google.com/generative-ai-app-builder/docs/boost-search-results) - BoostSpec *GoogleCloudDiscoveryengineV1betaSearchRequestBoostSpec `json:"boostSpec,omitempty"` - // DataStore: Required. Full resource name of DataStore, such as - // `projects/{project}/locations/{location}/collections/{collection_id}/dataStor - // es/{data_store_id}`. - DataStore string `json:"dataStore,omitempty"` - // Filter: Optional. Filter specification to filter documents in the data store - // specified by data_store field. For more information on filtering, see - // Filtering - // (https://cloud.google.com/generative-ai-app-builder/docs/filter-search-metadata) - Filter string `json:"filter,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. See +// 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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. 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. See + // 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. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1betaSearchRequestDataStoreSpec) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaSearchRequestDataStoreSpec +func (s GoogleTypeDate) MarshalJSON() ([]byte, error) { + type NoMethod GoogleTypeDate return gensupport.MarshalJSON(NoMethod(s), 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. See +// GoogleTypeDateTime: Represents civil time (or occasionally physical time). +// This type can represent a civil time in one of a few possible ways: * When +// utc_offset is set and time_zone is unset: a civil time on a calendar day +// with a particular offset from UTC. * When time_zone is set and utc_offset is +// unset: a civil time on a calendar day in a particular time zone. * When +// neither time_zone nor utc_offset is set: a civil time on a calendar day in +// local time. The date is relative to the Proleptic Gregorian Calendar. If +// year, month, or day are 0, the DateTime is considered not to have a specific +// year, month, or day respectively. This type may also be used to represent a +// physical time if all the date and time fields are set and either case of the +// `time_offset` oneof is set. Consider using `Timestamp` message for physical +// time instead. If your use case also would like to store the user's timezone, +// that can be done in another field. This type is more flexible than some +// applications may want. Make sure to document and validate your application's +// limitations. +type GoogleTypeDateTime struct { + // Day: Optional. Day of month. Must be from 1 to 31 and valid for the year and + // month, or 0 if specifying a datetime without a day. + Day int64 `json:"day,omitempty"` + // Hours: Optional. Hours of day in 24 hour format. Should be from 0 to 23, + // defaults to 0 (midnight). An API may choose to allow the value "24:00:00" + // for scenarios like business closing time. + Hours int64 `json:"hours,omitempty"` + // Minutes: Optional. Minutes of hour of day. Must be from 0 to 59, defaults to + // 0. + Minutes int64 `json:"minutes,omitempty"` + // Month: Optional. Month of year. Must be from 1 to 12, or 0 if specifying a + // datetime without a month. + Month int64 `json:"month,omitempty"` + // Nanos: Optional. Fractions of seconds in nanoseconds. Must be from 0 to + // 999,999,999, defaults to 0. + Nanos int64 `json:"nanos,omitempty"` + // Seconds: Optional. Seconds of minutes of the time. Must normally be from 0 + // to 59, defaults to 0. An API may allow the value 60 if it allows + // leap-seconds. + Seconds int64 `json:"seconds,omitempty"` + // TimeZone: Time zone. + TimeZone *GoogleTypeTimeZone `json:"timeZone,omitempty"` + // UtcOffset: UTC offset. Must be whole seconds, between -18 hours and +18 + // hours. For example, a UTC offset of -4:00 would be represented as { seconds: + // -14400 }. + UtcOffset string `json:"utcOffset,omitempty"` + // Year: Optional. Year of date. Must be from 1 to 9999, or 0 if specifying a + // datetime 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. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. 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. See + // 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. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1betaSearchRequestEmbeddingSpec) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaSearchRequestEmbeddingSpec +func (s GoogleTypeDateTime) MarshalJSON() ([]byte, error) { + type NoMethod GoogleTypeDateTime return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaSearchRequestEmbeddingSpecEmbeddingVector: -// 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 +// GoogleTypeExpr: Represents a textual expression in the Common Expression +// Language (CEL) syntax. CEL is a C-like expression language. The syntax and +// semantics of CEL are documented at https://github.com/google/cel-spec. +// Example (Comparison): title: "Summary size limit" description: "Determines +// if a summary is less than 100 chars" expression: "document.summary.size() < +// 100" Example (Equality): title: "Requestor is owner" description: +// "Determines if requestor is the document owner" expression: "document.owner +// == request.auth.claims.email" Example (Logic): title: "Public documents" +// description: "Determine whether the document should be publicly visible" +// expression: "document.type != 'private' && document.type != 'internal'" +// Example (Data Manipulation): title: "Notification string" description: +// "Create a notification string with a timestamp." expression: "'New message +// received at ' + string(document.create_time)" The exact variables and +// functions that may be referenced within an expression are determined by the +// service that evaluates it. See the service documentation for additional +// information. +type GoogleTypeExpr struct { + // Description: Optional. Description of the expression. This is a longer text + // which describes the expression, e.g. when hovered over it in a UI. + Description string `json:"description,omitempty"` + // Expression: Textual representation of an expression in Common Expression + // Language syntax. + Expression string `json:"expression,omitempty"` + // Location: Optional. String indicating the location of the expression for + // error reporting, e.g. a file name and a position in the file. + Location string `json:"location,omitempty"` + // Title: Optional. Title for the expression, i.e. a short string describing + // its purpose. This can be used e.g. in UIs which allow to enter the + // expression. + Title string `json:"title,omitempty"` + // ForceSendFields is a list of field names (e.g. "Description") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "FieldPath") to include in API - // requests with the JSON null value. By default, fields with empty values are - // omitted from API requests. See + // NullFields is a list of field names (e.g. "Description") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleTypeExpr) MarshalJSON() ([]byte, error) { + type NoMethod GoogleTypeExpr + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleTypeTimeZone: Represents a time zone from the IANA Time Zone Database +// (https://www.iana.org/time-zones). +type GoogleTypeTimeZone struct { + // Id: IANA Time Zone Database time zone. For example "America/New_York". + Id string `json:"id,omitempty"` + // Version: Optional. IANA Time Zone Database version number. For example + // "2019a". + Version string `json:"version,omitempty"` + // ForceSendFields is a list of field names (e.g. "Id") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "Id") to include in API requests + // with the JSON null value. By default, fields with empty values are omitted + // from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } -func (s GoogleCloudDiscoveryengineV1betaSearchRequestEmbeddingSpecEmbeddingVector) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaSearchRequestEmbeddingSpecEmbeddingVector +func (s GoogleTypeTimeZone) MarshalJSON() ([]byte, error) { + type NoMethod GoogleTypeTimeZone return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -func (s *GoogleCloudDiscoveryengineV1betaSearchRequestEmbeddingSpecEmbeddingVector) UnmarshalJSON(data []byte) error { - type NoMethod GoogleCloudDiscoveryengineV1betaSearchRequestEmbeddingSpecEmbeddingVector - var s1 struct { - Vector []gensupport.JSONFloat64 `json:"vector"` - *NoMethod +type ProjectsGetCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// Get: Gets a Project. Returns NOT_FOUND when the project is not yet created. +// +// - name: Full resource name of a Project, such as +// `projects/{project_id_or_number}`. +func (r *ProjectsService) Get(name string) *ProjectsGetCall { + c := &ProjectsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + return c +} + +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. +func (c *ProjectsGetCall) Fields(s ...googleapi.Field) *ProjectsGetCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// IfNoneMatch sets an optional parameter which makes the operation fail if the +// object's ETag matches the given value. This is useful for getting updates +// only after the object has changed since the last request. +func (c *ProjectsGetCall) IfNoneMatch(entityTag string) *ProjectsGetCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsGetCall) Context(ctx context.Context) *ProjectsGetCall { + c.ctx_ = ctx + return c +} + +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. +func (c *ProjectsGetCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) } - s1.NoMethod = (*NoMethod)(s) - if err := json.Unmarshal(data, &s1); err != nil { - return err + return c.header_ +} + +func (c *ProjectsGetCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) } - s.Vector = make([]float64, len(s1.Vector)) - for i := range s1.Vector { - s.Vector[i] = float64(s1.Vector[i]) + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+name}") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("GET", urls, nil) + if err != nil { + return nil, err } - return nil + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "name": c.name, + }) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "discoveryengine.projects.get", "request", internallog.HTTPRequest(req, nil)) + return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// 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 facet values that are returned for this facet. If - // unspecified, defaults to 20. The maximum allowed value is 300. Values above - // 300 are coerced to 300. For aggregation in healthcare search, when the - // [FacetKey.key] is "healthcare_aggregation_key", the limit will be overridden - // to 10,000 internally, regardless of the value set here. 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. See - // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more - // details. - 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. See - // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. - NullFields []string `json:"-"` +// Do executes the "discoveryengine.projects.get" call. +// Any non-2xx status code is an error. Response headers are in either +// *GoogleCloudDiscoveryengineV1alphaProject.ServerResponse.Header or (if a +// response was returned at all) in error.(*googleapi.Error).Header. Use +// googleapi.IsNotModified to check whether the returned error was because +// http.StatusNotModified was returned. +func (c *ProjectsGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1alphaProject, 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 := &GoogleCloudDiscoveryengineV1alphaProject{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + b, err := gensupport.DecodeResponseBytes(target, res) + if err != nil { + return nil, err + } + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "discoveryengine.projects.get", "response", internallog.HTTPResponse(res, b)) + return ret, nil } -func (s GoogleCloudDiscoveryengineV1betaSearchRequestFacetSpec) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaSearchRequestFacetSpec - return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +type ProjectsProvisionCall struct { + s *Service + name string + googleclouddiscoveryenginev1alphaprovisionprojectrequest *GoogleCloudDiscoveryengineV1alphaProvisionProjectRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// 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 contain 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. See - // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more - // details. - 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. See - // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. - NullFields []string `json:"-"` +// Provision: Provisions the project resource. During the process, related +// systems will get prepared and initialized. Caller must read the Terms for +// data use (https://cloud.google.com/retail/data-use-terms), and optionally +// specify in request to provide consent to that service terms. +// +// - name: Full resource name of a Project, such as +// `projects/{project_id_or_number}`. +func (r *ProjectsService) Provision(name string, googleclouddiscoveryenginev1alphaprovisionprojectrequest *GoogleCloudDiscoveryengineV1alphaProvisionProjectRequest) *ProjectsProvisionCall { + c := &ProjectsProvisionCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + c.googleclouddiscoveryenginev1alphaprovisionprojectrequest = googleclouddiscoveryenginev1alphaprovisionprojectrequest + return c } -func (s GoogleCloudDiscoveryengineV1betaSearchRequestFacetSpecFacetKey) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaSearchRequestFacetSpecFacetKey - return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. +func (c *ProjectsProvisionCall) Fields(s ...googleapi.Field) *ProjectsProvisionCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c } -// 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. See - // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more - // details. - 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. See - // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. - NullFields []string `json:"-"` +// Context sets the context to be used in this call's Do method. +func (c *ProjectsProvisionCall) Context(ctx context.Context) *ProjectsProvisionCall { + c.ctx_ = ctx + return c } -func (s GoogleCloudDiscoveryengineV1betaSearchRequestImageQuery) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaSearchRequestImageQuery - return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. +func (c *ProjectsProvisionCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ } -// GoogleCloudDiscoveryengineV1betaSearchRequestNaturalLanguageQueryUnderstandin -// gSpec: Specification to enable natural language understanding capabilities -// for search requests. -type GoogleCloudDiscoveryengineV1betaSearchRequestNaturalLanguageQueryUnderstandingSpec struct { - // FilterExtractionCondition: The condition under which filter extraction - // should occur. Default to Condition.DISABLED. - // - // Possible values: - // "CONDITION_UNSPECIFIED" - Server behavior defaults to Condition.DISABLED. - // "DISABLED" - Disables NL filter extraction. - // "ENABLED" - Enables NL filter extraction. - FilterExtractionCondition string `json:"filterExtractionCondition,omitempty"` - // GeoSearchQueryDetectionFieldNames: Field names used for location-based - // filtering, where geolocation filters are detected in natural language search - // queries. Only valid when the FilterExtractionCondition is set to `ENABLED`. - // If this field is set, it overrides the field names set in - // ServingConfig.geo_search_query_detection_field_names. - GeoSearchQueryDetectionFieldNames []string `json:"geoSearchQueryDetectionFieldNames,omitempty"` - // ForceSendFields is a list of field names (e.g. "FilterExtractionCondition") - // to unconditionally include in API requests. By default, fields with empty or - // default values are omitted from API requests. See - // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more - // details. - ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "FilterExtractionCondition") to - // include in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. See - // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. - NullFields []string `json:"-"` +func (c *ProjectsProvisionCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) + body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.googleclouddiscoveryenginev1alphaprovisionprojectrequest) + if err != nil { + return nil, err + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+name}:provision") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("POST", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "name": c.name, + }) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "discoveryengine.projects.provision", "request", internallog.HTTPRequest(req, body.Bytes())) + return gensupport.SendRequest(c.ctx_, c.s.client, req) } -func (s GoogleCloudDiscoveryengineV1betaSearchRequestNaturalLanguageQueryUnderstandingSpec) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaSearchRequestNaturalLanguageQueryUnderstandingSpec - return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +// Do executes the "discoveryengine.projects.provision" call. +// Any non-2xx status code is an error. Response headers are in either +// *GoogleLongrunningOperation.ServerResponse.Header or (if a response was +// returned at all) in error.(*googleapi.Error).Header. Use +// googleapi.IsNotModified to check whether the returned error was because +// http.StatusNotModified was returned. +func (c *ProjectsProvisionCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &GoogleLongrunningOperation{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + b, err := gensupport.DecodeResponseBytes(target, res) + if err != nil { + return nil, err + } + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "discoveryengine.projects.provision", "response", internallog.HTTPResponse(res, b)) + return ret, nil } -// GoogleCloudDiscoveryengineV1betaSearchRequestPersonalizationSpec: The -// specification for personalization. -type GoogleCloudDiscoveryengineV1betaSearchRequestPersonalizationSpec struct { - // Mode: The personalization mode of the search request. Defaults to Mode.AUTO. - // - // Possible values: - // "MODE_UNSPECIFIED" - Default value. In this case, server behavior defaults - // to Mode.AUTO. - // "AUTO" - Personalization is enabled if data quality requirements are met. - // "DISABLED" - Disable personalization. - 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. See - // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more - // details. - 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. See - // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. - NullFields []string `json:"-"` +type ProjectsReportConsentChangeCall struct { + s *Service + project string + googleclouddiscoveryenginev1alphareportconsentchangerequest *GoogleCloudDiscoveryengineV1alphaReportConsentChangeRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -func (s GoogleCloudDiscoveryengineV1betaSearchRequestPersonalizationSpec) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaSearchRequestPersonalizationSpec - return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +// ReportConsentChange: Updates service terms for this project. This method can +// be used to retroactively accept the latest terms. Terms available for +// update: * Terms for data use +// (https://cloud.google.com/retail/data-use-terms) +// +// - project: Full resource name of a Project, such as +// `projects/{project_id_or_number}`. +func (r *ProjectsService) ReportConsentChange(project string, googleclouddiscoveryenginev1alphareportconsentchangerequest *GoogleCloudDiscoveryengineV1alphaReportConsentChangeRequest) *ProjectsReportConsentChangeCall { + c := &ProjectsReportConsentChangeCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.project = project + c.googleclouddiscoveryenginev1alphareportconsentchangerequest = googleclouddiscoveryenginev1alphareportconsentchangerequest + return c } -// 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. See - // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more - // details. - 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. See - // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. - NullFields []string `json:"-"` +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. +func (c *ProjectsReportConsentChangeCall) Fields(s ...googleapi.Field) *ProjectsReportConsentChangeCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c } -func (s GoogleCloudDiscoveryengineV1betaSearchRequestQueryExpansionSpec) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaSearchRequestQueryExpansionSpec - return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +// Context sets the context to be used in this call's Do method. +func (c *ProjectsReportConsentChangeCall) Context(ctx context.Context) *ProjectsReportConsentChangeCall { + c.ctx_ = ctx + return c } -// GoogleCloudDiscoveryengineV1betaSearchRequestSearchAsYouTypeSpec: -// Specification for search as you type in search requests. -type GoogleCloudDiscoveryengineV1betaSearchRequestSearchAsYouTypeSpec struct { - // Condition: The condition under which search as you type should occur. - // Default to Condition.DISABLED. - // - // Possible values: - // "CONDITION_UNSPECIFIED" - Server behavior defaults to Condition.DISABLED. - // "DISABLED" - Disables Search As You Type. - // "ENABLED" - Enables Search As You Type. - Condition string `json:"condition,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. See - // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more - // details. - 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. See - // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. - NullFields []string `json:"-"` +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. +func (c *ProjectsReportConsentChangeCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsReportConsentChangeCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) + body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.googleclouddiscoveryenginev1alphareportconsentchangerequest) + if err != nil { + return nil, err + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+project}:reportConsentChange") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("POST", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "project": c.project, + }) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "discoveryengine.projects.reportConsentChange", "request", internallog.HTTPRequest(req, body.Bytes())) + return gensupport.SendRequest(c.ctx_, c.s.client, req) } -func (s GoogleCloudDiscoveryengineV1betaSearchRequestSearchAsYouTypeSpec) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaSearchRequestSearchAsYouTypeSpec - return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +// Do executes the "discoveryengine.projects.reportConsentChange" call. +// Any non-2xx status code is an error. Response headers are in either +// *GoogleCloudDiscoveryengineV1alphaProject.ServerResponse.Header or (if a +// response was returned at all) in error.(*googleapi.Error).Header. Use +// googleapi.IsNotModified to check whether the returned error was because +// http.StatusNotModified was returned. +func (c *ProjectsReportConsentChangeCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1alphaProject, 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 := &GoogleCloudDiscoveryengineV1alphaProject{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + b, err := gensupport.DecodeResponseBytes(target, res) + if err != nil { + return nil, err + } + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "discoveryengine.projects.reportConsentChange", "response", internallog.HTTPResponse(res, b)) + return ret, nil } -// GoogleCloudDiscoveryengineV1betaSearchRequestSessionSpec: Session -// specification. Multi-turn Search feature is currently at private GA stage. -// Please use v1alpha or v1beta version instead before we launch this feature -// to public GA. Or ask for allowlisting through Google Support team. -type GoogleCloudDiscoveryengineV1betaSearchRequestSessionSpec struct { - // QueryId: If set, the search result gets stored to the "turn" specified by - // this query ID. Example: Let's say the session looks like this: session { - // name: ".../sessions/xxx" turns { query { text: "What is foo?" query_id: - // ".../questions/yyy" } answer: "Foo is ..." } turns { query { text: "How - // about bar then?" query_id: ".../questions/zzz" } } } The user can call - // /search API with a request like this: session: ".../sessions/xxx" - // session_spec { query_id: ".../questions/zzz" } Then, the API stores the - // search result, associated with the last turn. The stored search result can - // be used by a subsequent /answer API call (with the session ID and the query - // ID specified). Also, it is possible to call /search and /answer in parallel - // with the same session ID & query ID. - QueryId string `json:"queryId,omitempty"` - // SearchResultPersistenceCount: The number of top search results to persist. - // The persisted search results can be used for the subsequent /answer api - // call. This field is simliar to the `summary_result_count` field in - // SearchRequest.ContentSearchSpec.SummarySpec.summary_result_count. At most 10 - // results for documents mode, or 50 for chunks mode. - SearchResultPersistenceCount int64 `json:"searchResultPersistenceCount,omitempty"` - // ForceSendFields is a list of field names (e.g. "QueryId") to unconditionally - // include in API requests. By default, fields with empty or default values are - // omitted from API requests. See - // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more - // details. - ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "QueryId") to include in API - // requests with the JSON null value. By default, fields with empty values are - // omitted from API requests. See - // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. - NullFields []string `json:"-"` +type ProjectsLocationsEstimateDataSizeCall struct { + s *Service + location string + googleclouddiscoveryenginev1alphaestimatedatasizerequest *GoogleCloudDiscoveryengineV1alphaEstimateDataSizeRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -func (s GoogleCloudDiscoveryengineV1betaSearchRequestSessionSpec) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaSearchRequestSessionSpec - return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +// EstimateDataSize: Estimates the data size to be used by a customer. +// +// - location: Full resource name of the location, such as +// `projects/{project}/locations/{location}`. +func (r *ProjectsLocationsService) EstimateDataSize(location string, googleclouddiscoveryenginev1alphaestimatedatasizerequest *GoogleCloudDiscoveryengineV1alphaEstimateDataSizeRequest) *ProjectsLocationsEstimateDataSizeCall { + c := &ProjectsLocationsEstimateDataSizeCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.location = location + c.googleclouddiscoveryenginev1alphaestimatedatasizerequest = googleclouddiscoveryenginev1alphaestimatedatasizerequest + return c } -// GoogleCloudDiscoveryengineV1betaSearchRequestSpellCorrectionSpec: The -// specification for query spell correction. -type GoogleCloudDiscoveryengineV1betaSearchRequestSpellCorrectionSpec struct { - // Mode: The mode under which spell correction replaces the original search - // query. Defaults to Mode.AUTO. - // - // Possible values: - // "MODE_UNSPECIFIED" - Unspecified spell correction mode. In this case, - // server behavior defaults to Mode.AUTO. - // "SUGGESTION_ONLY" - Search API tries to find a spelling suggestion. If a - // suggestion is found, it is put in the SearchResponse.corrected_query. The - // spelling suggestion won't 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. See - // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more - // details. - 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. See - // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. - NullFields []string `json:"-"` +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. +func (c *ProjectsLocationsEstimateDataSizeCall) Fields(s ...googleapi.Field) *ProjectsLocationsEstimateDataSizeCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c } -func (s GoogleCloudDiscoveryengineV1betaSearchRequestSpellCorrectionSpec) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaSearchRequestSpellCorrectionSpec - return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsEstimateDataSizeCall) Context(ctx context.Context) *ProjectsLocationsEstimateDataSizeCall { + c.ctx_ = ctx + return c } -// 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. See - // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more - // details. - 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. See - // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. - NullFields []string `json:"-"` +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. +func (c *ProjectsLocationsEstimateDataSizeCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ } -func (s GoogleCloudDiscoveryengineV1betaSiteVerificationInfo) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaSiteVerificationInfo - return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +func (c *ProjectsLocationsEstimateDataSizeCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) + body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.googleclouddiscoveryenginev1alphaestimatedatasizerequest) + if err != nil { + return nil, err + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+location}:estimateDataSize") + 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{ + "location": c.location, + }) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "discoveryengine.projects.locations.estimateDataSize", "request", internallog.HTTPRequest(req, body.Bytes())) + return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// GoogleCloudDiscoveryengineV1betaSitemap: A sitemap for the SiteSearchEngine. -type GoogleCloudDiscoveryengineV1betaSitemap struct { - // CreateTime: Output only. The sitemap's creation time. - CreateTime string `json:"createTime,omitempty"` - // Name: Output only. The fully qualified resource name of the sitemap. - // `projects/*/locations/*/collections/*/dataStores/*/siteSearchEngine/sitemaps/ - // *` The `sitemap_id` suffix is system-generated. - Name string `json:"name,omitempty"` - // Uri: Public URI for the sitemap, e.g. `www.example.com/sitemap.xml`. - Uri string `json:"uri,omitempty"` - // ForceSendFields is a list of field names (e.g. "CreateTime") to - // unconditionally include in API requests. By default, fields with empty or - // default values are omitted from API requests. See - // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more - // details. - ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "CreateTime") to include in API - // requests with the JSON null value. By default, fields with empty values are - // omitted from API requests. See - // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. - NullFields []string `json:"-"` +// Do executes the "discoveryengine.projects.locations.estimateDataSize" call. +// Any non-2xx status code is an error. Response headers are in either +// *GoogleLongrunningOperation.ServerResponse.Header or (if a response was +// returned at all) in error.(*googleapi.Error).Header. Use +// googleapi.IsNotModified to check whether the returned error was because +// http.StatusNotModified was returned. +func (c *ProjectsLocationsEstimateDataSizeCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &GoogleLongrunningOperation{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + b, err := gensupport.DecodeResponseBytes(target, res) + if err != nil { + return nil, err + } + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "discoveryengine.projects.locations.estimateDataSize", "response", internallog.HTTPResponse(res, b)) + return ret, nil } -func (s GoogleCloudDiscoveryengineV1betaSitemap) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaSitemap - return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +type ProjectsLocationsGenerateGroundedContentCall struct { + s *Service + location string + googleclouddiscoveryenginev1alphagenerategroundedcontentrequest *GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// 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}/dataStores/ - // {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"` - // RootDomainUri: Output only. Root domain of the provided_uri_pattern. - RootDomainUri string `json:"rootDomainUri,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. See - // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more - // details. - 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. See - // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. - NullFields []string `json:"-"` +// GenerateGroundedContent: Generates grounded content. +// +// - location: Location resource. Format: +// `projects/{project}/locations/{location}`. +func (r *ProjectsLocationsService) GenerateGroundedContent(location string, googleclouddiscoveryenginev1alphagenerategroundedcontentrequest *GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentRequest) *ProjectsLocationsGenerateGroundedContentCall { + c := &ProjectsLocationsGenerateGroundedContentCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.location = location + c.googleclouddiscoveryenginev1alphagenerategroundedcontentrequest = googleclouddiscoveryenginev1alphagenerategroundedcontentrequest + return c } -func (s GoogleCloudDiscoveryengineV1betaTargetSite) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaTargetSite - return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. +func (c *ProjectsLocationsGenerateGroundedContentCall) Fields(s ...googleapi.Field) *ProjectsLocationsGenerateGroundedContentCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c } -// 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. See - // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more - // details. - 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. See - // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. - NullFields []string `json:"-"` +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsGenerateGroundedContentCall) Context(ctx context.Context) *ProjectsLocationsGenerateGroundedContentCall { + c.ctx_ = ctx + return c } -func (s GoogleCloudDiscoveryengineV1betaTargetSiteFailureReason) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaTargetSiteFailureReason - return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. +func (c *ProjectsLocationsGenerateGroundedContentCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ } -// GoogleCloudDiscoveryengineV1betaTargetSiteFailureReasonQuotaFailure: Failed -// due to insufficient quota. -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. See - // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more - // details. - 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. See - // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. - NullFields []string `json:"-"` +func (c *ProjectsLocationsGenerateGroundedContentCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) + body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.googleclouddiscoveryenginev1alphagenerategroundedcontentrequest) + if err != nil { + return nil, err + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+location}:generateGroundedContent") + 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{ + "location": c.location, + }) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "discoveryengine.projects.locations.generateGroundedContent", "request", internallog.HTTPRequest(req, body.Bytes())) + return gensupport.SendRequest(c.ctx_, c.s.client, req) } -func (s GoogleCloudDiscoveryengineV1betaTargetSiteFailureReasonQuotaFailure) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaTargetSiteFailureReasonQuotaFailure - return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +// Do executes the "discoveryengine.projects.locations.generateGroundedContent" call. +// Any non-2xx status code is an error. Response headers are in either +// *GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentResponse.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 *ProjectsLocationsGenerateGroundedContentCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentResponse, 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 := &GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentResponse{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + b, err := gensupport.DecodeResponseBytes(target, res) + if err != nil { + return nil, err + } + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "discoveryengine.projects.locations.generateGroundedContent", "response", internallog.HTTPResponse(res, b)) + return ret, nil } -// GoogleCloudDiscoveryengineV1betaTrainCustomModelMetadata: Metadata related -// to the progress of the TrainCustomModel operation. This is returned by the -// google.longrunning.Operation.metadata field. -type GoogleCloudDiscoveryengineV1betaTrainCustomModelMetadata struct { - // CreateTime: Operation create time. - CreateTime string `json:"createTime,omitempty"` - // UpdateTime: Operation last update time. If the operation is done, this is - // also the finish time. - UpdateTime string `json:"updateTime,omitempty"` - // ForceSendFields is a list of field names (e.g. "CreateTime") to - // unconditionally include in API requests. By default, fields with empty or - // default values are omitted from API requests. See - // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more - // details. - ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "CreateTime") to include in API - // requests with the JSON null value. By default, fields with empty values are - // omitted from API requests. See - // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. - NullFields []string `json:"-"` +type ProjectsLocationsGetAclConfigCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header } -func (s GoogleCloudDiscoveryengineV1betaTrainCustomModelMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaTrainCustomModelMetadata - return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +// GetAclConfig: Gets the AclConfig. +// +// - name: Resource name of AclConfig, such as +// `projects/*/locations/*/aclConfig`. If the caller does not have permission +// to access the AclConfig, regardless of whether or not it exists, a +// PERMISSION_DENIED error is returned. +func (r *ProjectsLocationsService) GetAclConfig(name string) *ProjectsLocationsGetAclConfigCall { + c := &ProjectsLocationsGetAclConfigCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + return c } -// GoogleCloudDiscoveryengineV1betaTrainCustomModelResponse: Response of the -// TrainCustomModelRequest. This message is returned by the -// google.longrunning.Operations.response field. -type GoogleCloudDiscoveryengineV1betaTrainCustomModelResponse struct { - // ErrorConfig: Echoes the destination for the complete errors in the request - // if set. - ErrorConfig *GoogleCloudDiscoveryengineV1betaImportErrorConfig `json:"errorConfig,omitempty"` - // ErrorSamples: A sample of errors encountered while processing the data. - ErrorSamples []*GoogleRpcStatus `json:"errorSamples,omitempty"` - // Metrics: The metrics of the trained model. - Metrics map[string]float64 `json:"metrics,omitempty"` - // ModelName: Fully qualified name of the CustomTuningModel. - ModelName string `json:"modelName,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 job - // creation is in progress. * **training**: Model is actively training. * - // **evaluating**: The model is evaluating trained metrics. * **indexing**: The - // model trained metrics are indexing. * **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. See - // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more - // details. - 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. See - // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. - NullFields []string `json:"-"` +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. +func (c *ProjectsLocationsGetAclConfigCall) Fields(s ...googleapi.Field) *ProjectsLocationsGetAclConfigCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c } -func (s GoogleCloudDiscoveryengineV1betaTrainCustomModelResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaTrainCustomModelResponse - return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +// IfNoneMatch sets an optional parameter which makes the operation fail if the +// object's ETag matches the given value. This is useful for getting updates +// only after the object has changed since the last request. +func (c *ProjectsLocationsGetAclConfigCall) IfNoneMatch(entityTag string) *ProjectsLocationsGetAclConfigCall { + c.ifNoneMatch_ = entityTag + return c } -// GoogleCloudDiscoveryengineV1betaTuneEngineMetadata: Metadata associated with -// a tune operation. -type GoogleCloudDiscoveryengineV1betaTuneEngineMetadata struct { - // Engine: Required. The resource name of the engine that this tune applies to. - // Format: - // `projects/{project}/locations/{location}/collections/{collection_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. See - // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more - // details. - 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. See - // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. - NullFields []string `json:"-"` +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsGetAclConfigCall) Context(ctx context.Context) *ProjectsLocationsGetAclConfigCall { + c.ctx_ = ctx + return c } -func (s GoogleCloudDiscoveryengineV1betaTuneEngineMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaTuneEngineMetadata - return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. +func (c *ProjectsLocationsGetAclConfigCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ } -// GoogleCloudDiscoveryengineV1betaTuneEngineResponse: Response associated with -// a tune operation. -type GoogleCloudDiscoveryengineV1betaTuneEngineResponse struct { +func (c *ProjectsLocationsGetAclConfigCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+name}") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("GET", urls, nil) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "name": c.name, + }) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "discoveryengine.projects.locations.getAclConfig", "request", internallog.HTTPRequest(req, nil)) + return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// 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. See - // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more - // details. - ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "CreateTime") to include in API - // requests with the JSON null value. By default, fields with empty values are - // omitted from API requests. See - // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. - NullFields []string `json:"-"` +// Do executes the "discoveryengine.projects.locations.getAclConfig" call. +// Any non-2xx status code is an error. Response headers are in either +// *GoogleCloudDiscoveryengineV1alphaAclConfig.ServerResponse.Header or (if a +// response was returned at all) in error.(*googleapi.Error).Header. Use +// googleapi.IsNotModified to check whether the returned error was because +// http.StatusNotModified was returned. +func (c *ProjectsLocationsGetAclConfigCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1alphaAclConfig, 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 := &GoogleCloudDiscoveryengineV1alphaAclConfig{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + b, err := gensupport.DecodeResponseBytes(target, res) + if err != nil { + return nil, err + } + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "discoveryengine.projects.locations.getAclConfig", "response", internallog.HTTPResponse(res, b)) + return ret, nil } -func (s GoogleCloudDiscoveryengineV1betaUpdateSchemaMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaUpdateSchemaMetadata - return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +type ProjectsLocationsGetCmekConfigCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header } -// 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. See - // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more - // details. - ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "CreateTime") to include in API - // requests with the JSON null value. By default, fields with empty values are - // omitted from API requests. See - // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. - NullFields []string `json:"-"` +// GetCmekConfig: Gets the CmekConfig. +// +// - name: Resource name of CmekConfig, such as +// `projects/*/locations/*/cmekConfig` or +// `projects/*/locations/*/cmekConfigs/*`. If the caller does not have +// permission to access the CmekConfig, regardless of whether or not it +// exists, a PERMISSION_DENIED error is returned. +func (r *ProjectsLocationsService) GetCmekConfig(name string) *ProjectsLocationsGetCmekConfigCall { + c := &ProjectsLocationsGetCmekConfigCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + return c } -func (s GoogleCloudDiscoveryengineV1betaUpdateTargetSiteMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaUpdateTargetSiteMetadata - return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. +func (c *ProjectsLocationsGetCmekConfigCall) Fields(s ...googleapi.Field) *ProjectsLocationsGetCmekConfigCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c } -// 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. See - // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more - // details. - 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. See - // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. - NullFields []string `json:"-"` +// IfNoneMatch sets an optional parameter which makes the operation fail if the +// object's ETag matches the given value. This is useful for getting updates +// only after the object has changed since the last request. +func (c *ProjectsLocationsGetCmekConfigCall) IfNoneMatch(entityTag string) *ProjectsLocationsGetCmekConfigCall { + c.ifNoneMatch_ = entityTag + return c } -func (s GoogleCloudDiscoveryengineV1betaUserInfo) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaUserInfo - return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsGetCmekConfigCall) Context(ctx context.Context) *ProjectsLocationsGetCmekConfigCall { + c.ctx_ = ctx + return c } -// GoogleCloudDiscoveryengineV1betaWorkspaceConfig: Config to store data store -// type configuration for workspace data -type GoogleCloudDiscoveryengineV1betaWorkspaceConfig struct { - // DasherCustomerId: Obfuscated Dasher customer ID. - DasherCustomerId string `json:"dasherCustomerId,omitempty"` - // SuperAdminEmailAddress: Optional. The super admin email address for the - // workspace that will be used for access token generation. For now we only use - // it for Native Google Drive connector data ingestion. - SuperAdminEmailAddress string `json:"superAdminEmailAddress,omitempty"` - // SuperAdminServiceAccount: Optional. The super admin service account for the - // workspace that will be used for access token generation. For now we only use - // it for Native Google Drive connector data ingestion. - SuperAdminServiceAccount string `json:"superAdminServiceAccount,omitempty"` - // Type: The Google Workspace data source. - // - // Possible values: - // "TYPE_UNSPECIFIED" - Defaults to an unspecified Workspace type. - // "GOOGLE_DRIVE" - Workspace Data Store contains Drive data - // "GOOGLE_MAIL" - Workspace Data Store contains Mail data - // "GOOGLE_SITES" - Workspace Data Store contains Sites data - // "GOOGLE_CALENDAR" - Workspace Data Store contains Calendar data - // "GOOGLE_CHAT" - Workspace Data Store contains Chat data - // "GOOGLE_GROUPS" - Workspace Data Store contains Groups data - // "GOOGLE_KEEP" - Workspace Data Store contains Keep data - Type string `json:"type,omitempty"` - // ForceSendFields is a list of field names (e.g. "DasherCustomerId") to - // unconditionally include in API requests. By default, fields with empty or - // default values are omitted from API requests. See - // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more - // details. - ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "DasherCustomerId") to include in - // API requests with the JSON null value. By default, fields with empty values - // are omitted from API requests. See - // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. - NullFields []string `json:"-"` +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. +func (c *ProjectsLocationsGetCmekConfigCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ } -func (s GoogleCloudDiscoveryengineV1betaWorkspaceConfig) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudDiscoveryengineV1betaWorkspaceConfig - return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +func (c *ProjectsLocationsGetCmekConfigCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+name}") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("GET", urls, nil) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "name": c.name, + }) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "discoveryengine.projects.locations.getCmekConfig", "request", internallog.HTTPRequest(req, nil)) + return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// GoogleLongrunningCancelOperationRequest: The request message for -// Operations.CancelOperation. -type GoogleLongrunningCancelOperationRequest struct { +// Do executes the "discoveryengine.projects.locations.getCmekConfig" call. +// Any non-2xx status code is an error. Response headers are in either +// *GoogleCloudDiscoveryengineV1alphaCmekConfig.ServerResponse.Header or (if a +// response was returned at all) in error.(*googleapi.Error).Header. Use +// googleapi.IsNotModified to check whether the returned error was because +// http.StatusNotModified was returned. +func (c *ProjectsLocationsGetCmekConfigCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1alphaCmekConfig, 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 := &GoogleCloudDiscoveryengineV1alphaCmekConfig{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + b, err := gensupport.DecodeResponseBytes(target, res) + if err != nil { + return nil, err + } + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "discoveryengine.projects.locations.getCmekConfig", "response", internallog.HTTPResponse(res, b)) + return ret, nil } -// 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. See - // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more - // details. - ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "NextPageToken") to include in API - // requests with the JSON null value. By default, fields with empty values are - // omitted from API requests. See - // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. - NullFields []string `json:"-"` +type ProjectsLocationsSetUpDataConnectorCall struct { + s *Service + parent string + googleclouddiscoveryenginev1alphasetupdataconnectorrequest *GoogleCloudDiscoveryengineV1alphaSetUpDataConnectorRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -func (s GoogleLongrunningListOperationsResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleLongrunningListOperationsResponse - return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +// SetUpDataConnector: Creates a Collection and sets up the DataConnector for +// it. To stop a DataConnector after setup, use the +// CollectionService.DeleteCollection method. +// +// - parent: The parent of Collection, in the format of +// `projects/{project}/locations/{location}`. +func (r *ProjectsLocationsService) SetUpDataConnector(parent string, googleclouddiscoveryenginev1alphasetupdataconnectorrequest *GoogleCloudDiscoveryengineV1alphaSetUpDataConnectorRequest) *ProjectsLocationsSetUpDataConnectorCall { + c := &ProjectsLocationsSetUpDataConnectorCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + c.googleclouddiscoveryenginev1alphasetupdataconnectorrequest = googleclouddiscoveryenginev1alphasetupdataconnectorrequest + return c } -// 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"` +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. +func (c *ProjectsLocationsSetUpDataConnectorCall) Fields(s ...googleapi.Field) *ProjectsLocationsSetUpDataConnectorCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} - // ServerResponse contains the HTTP response code and headers from the server. - googleapi.ServerResponse `json:"-"` - // ForceSendFields is a list of field names (e.g. "Done") to unconditionally - // include in API requests. By default, fields with empty or default values are - // omitted from API requests. See - // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more - // details. - ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Done") to include in API requests - // with the JSON null value. By default, fields with empty values are omitted - // from API requests. See - // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. - NullFields []string `json:"-"` +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsSetUpDataConnectorCall) Context(ctx context.Context) *ProjectsLocationsSetUpDataConnectorCall { + c.ctx_ = ctx + return c } -func (s GoogleLongrunningOperation) MarshalJSON() ([]byte, error) { - type NoMethod GoogleLongrunningOperation - return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. +func (c *ProjectsLocationsSetUpDataConnectorCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ } -// GoogleMonitoringV3Point: A single data point in a time series. -type GoogleMonitoringV3Point struct { - // Interval: The time interval to which the data point applies. For `GAUGE` - // metrics, the start time is optional, but if it is supplied, it must equal - // the end time. For `DELTA` metrics, the start and end time should specify a - // non-zero interval, with subsequent points specifying contiguous and - // non-overlapping intervals. For `CUMULATIVE` metrics, the start and end time - // should specify a non-zero interval, with subsequent points specifying the - // same start time and increasing end times, until an event resets the - // cumulative value to zero and sets a new start time for the following points. - Interval *GoogleMonitoringV3TimeInterval `json:"interval,omitempty"` - // Value: The value of the data point. - Value *GoogleMonitoringV3TypedValue `json:"value,omitempty"` - // ForceSendFields is a list of field names (e.g. "Interval") to - // unconditionally include in API requests. By default, fields with empty or - // default values are omitted from API requests. See - // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more - // details. - ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Interval") to include in API - // requests with the JSON null value. By default, fields with empty values are - // omitted from API requests. See - // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. - NullFields []string `json:"-"` +func (c *ProjectsLocationsSetUpDataConnectorCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) + body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.googleclouddiscoveryenginev1alphasetupdataconnectorrequest) + if err != nil { + return nil, err + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+parent}:setUpDataConnector") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("POST", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "parent": c.parent, + }) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "discoveryengine.projects.locations.setUpDataConnector", "request", internallog.HTTPRequest(req, body.Bytes())) + return gensupport.SendRequest(c.ctx_, c.s.client, req) } -func (s GoogleMonitoringV3Point) MarshalJSON() ([]byte, error) { - type NoMethod GoogleMonitoringV3Point - return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +// Do executes the "discoveryengine.projects.locations.setUpDataConnector" call. +// Any non-2xx status code is an error. Response headers are in either +// *GoogleLongrunningOperation.ServerResponse.Header or (if a response was +// returned at all) in error.(*googleapi.Error).Header. Use +// googleapi.IsNotModified to check whether the returned error was because +// http.StatusNotModified was returned. +func (c *ProjectsLocationsSetUpDataConnectorCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &GoogleLongrunningOperation{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + b, err := gensupport.DecodeResponseBytes(target, res) + if err != nil { + return nil, err + } + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "discoveryengine.projects.locations.setUpDataConnector", "response", internallog.HTTPResponse(res, b)) + return ret, nil } -// GoogleMonitoringV3TimeInterval: A time interval extending just after a start -// time through an end time. If the start time is the same as the end time, -// then the interval represents a single point in time. -type GoogleMonitoringV3TimeInterval struct { - // EndTime: Required. The end of the time interval. - EndTime string `json:"endTime,omitempty"` - // StartTime: Optional. The beginning of the time interval. The default value - // for the start time is the end time. The start time must not be later than - // the end time. - StartTime string `json:"startTime,omitempty"` - // ForceSendFields is a list of field names (e.g. "EndTime") to unconditionally - // include in API requests. By default, fields with empty or default values are - // omitted from API requests. See - // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more - // details. - ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "EndTime") to include in API - // requests with the JSON null value. By default, fields with empty values are - // omitted from API requests. See - // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. - NullFields []string `json:"-"` +type ProjectsLocationsUpdateAclConfigCall struct { + s *Service + name string + googleclouddiscoveryenginev1alphaaclconfig *GoogleCloudDiscoveryengineV1alphaAclConfig + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -func (s GoogleMonitoringV3TimeInterval) MarshalJSON() ([]byte, error) { - type NoMethod GoogleMonitoringV3TimeInterval - return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +// UpdateAclConfig: Default ACL configuration for use in a location of a +// customer's project. Updates will only reflect to new data stores. Existing +// data stores will still use the old value. +// +// - name: Immutable. The full resource name of the acl configuration. Format: +// `projects/{project}/locations/{location}/aclConfig`. This field must be a +// UTF-8 encoded string with a length limit of 1024 characters. +func (r *ProjectsLocationsService) UpdateAclConfig(name string, googleclouddiscoveryenginev1alphaaclconfig *GoogleCloudDiscoveryengineV1alphaAclConfig) *ProjectsLocationsUpdateAclConfigCall { + c := &ProjectsLocationsUpdateAclConfigCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + c.googleclouddiscoveryenginev1alphaaclconfig = googleclouddiscoveryenginev1alphaaclconfig + return c } -// GoogleMonitoringV3TimeSeries: A collection of data points that describes the -// time-varying values of a metric. A time series is identified by a -// combination of a fully-specified monitored resource and a fully-specified -// metric. This type is used for both listing and creating time series. -type GoogleMonitoringV3TimeSeries struct { - // Description: Input only. A detailed description of the time series that will - // be associated with the google.api.MetricDescriptor for the metric. Once set, - // this field cannot be changed through CreateTimeSeries. - Description string `json:"description,omitempty"` - // Metadata: Output only. The associated monitored resource metadata. When - // reading a time series, this field will include metadata labels that are - // explicitly named in the reduction. When creating a time series, this field - // is ignored. - Metadata *GoogleApiMonitoredResourceMetadata `json:"metadata,omitempty"` - // Metric: The associated metric. A fully-specified metric used to identify the - // time series. - Metric *GoogleApiMetric `json:"metric,omitempty"` - // MetricKind: The metric kind of the time series. When listing time series, - // this metric kind might be different from the metric kind of the associated - // metric if this time series is an alignment or reduction of other time - // series. When creating a time series, this field is optional. If present, it - // must be the same as the metric kind of the associated metric. If the - // associated metric's descriptor must be auto-created, then this field - // specifies the metric kind of the new descriptor and must be either `GAUGE` - // (the default) or `CUMULATIVE`. - // - // Possible values: - // "METRIC_KIND_UNSPECIFIED" - Do not use this default value. - // "GAUGE" - An instantaneous measurement of a value. - // "DELTA" - The change in a value during a time interval. - // "CUMULATIVE" - A value accumulated over a time interval. Cumulative - // measurements in a time series should have the same start time and increasing - // end times, until an event resets the cumulative value to zero and sets a new - // start time for the following points. - MetricKind string `json:"metricKind,omitempty"` - // Points: The data points of this time series. When listing time series, - // points are returned in reverse time order. When creating a time series, this - // field must contain exactly one point and the point's type must be the same - // as the value type of the associated metric. If the associated metric's - // descriptor must be auto-created, then the value type of the descriptor is - // determined by the point's type, which must be `BOOL`, `INT64`, `DOUBLE`, or - // `DISTRIBUTION`. - Points []*GoogleMonitoringV3Point `json:"points,omitempty"` - // Resource: The associated monitored resource. Custom metrics can use only - // certain monitored resource types in their time series data. For more - // information, see Monitored resources for custom metrics - // (https://cloud.google.com/monitoring/custom-metrics/creating-metrics#custom-metric-resources). - Resource *GoogleApiMonitoredResource `json:"resource,omitempty"` - // Unit: The units in which the metric value is reported. It is only applicable - // if the `value_type` is `INT64`, `DOUBLE`, or `DISTRIBUTION`. The `unit` - // defines the representation of the stored metric values. This field can only - // be changed through CreateTimeSeries when it is empty. - Unit string `json:"unit,omitempty"` - // ValueType: The value type of the time series. When listing time series, this - // value type might be different from the value type of the associated metric - // if this time series is an alignment or reduction of other time series. When - // creating a time series, this field is optional. If present, it must be the - // same as the type of the data in the `points` field. - // - // Possible values: - // "VALUE_TYPE_UNSPECIFIED" - Do not use this default value. - // "BOOL" - The value is a boolean. This value type can be used only if the - // metric kind is `GAUGE`. - // "INT64" - The value is a signed 64-bit integer. - // "DOUBLE" - The value is a double precision floating point number. - // "STRING" - The value is a text string. This value type can be used only if - // the metric kind is `GAUGE`. - // "DISTRIBUTION" - The value is a `Distribution`. - // "MONEY" - The value is money. - ValueType string `json:"valueType,omitempty"` - // ForceSendFields is a list of field names (e.g. "Description") to - // unconditionally include in API requests. By default, fields with empty or - // default values are omitted from API requests. See - // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more - // details. - ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Description") to include in API - // requests with the JSON null value. By default, fields with empty values are - // omitted from API requests. See - // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. - NullFields []string `json:"-"` +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. +func (c *ProjectsLocationsUpdateAclConfigCall) Fields(s ...googleapi.Field) *ProjectsLocationsUpdateAclConfigCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c } -func (s GoogleMonitoringV3TimeSeries) MarshalJSON() ([]byte, error) { - type NoMethod GoogleMonitoringV3TimeSeries - return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsUpdateAclConfigCall) Context(ctx context.Context) *ProjectsLocationsUpdateAclConfigCall { + c.ctx_ = ctx + return c } -// GoogleMonitoringV3TypedValue: A single strongly-typed value. -type GoogleMonitoringV3TypedValue struct { - // BoolValue: A Boolean value: `true` or `false`. - BoolValue bool `json:"boolValue,omitempty"` - // DistributionValue: A distribution value. - DistributionValue *GoogleApiDistribution `json:"distributionValue,omitempty"` - // DoubleValue: A 64-bit double-precision floating-point number. Its magnitude - // is approximately ±10±300 and it has 16 significant digits of precision. - DoubleValue float64 `json:"doubleValue,omitempty"` - // Int64Value: A 64-bit integer. Its range is approximately ±9.2x1018. - Int64Value int64 `json:"int64Value,omitempty,string"` - // StringValue: A variable-length string value. - StringValue string `json:"stringValue,omitempty"` - // ForceSendFields is a list of field names (e.g. "BoolValue") to - // unconditionally include in API requests. By default, fields with empty or - // default values are omitted from API requests. See - // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more - // details. - ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "BoolValue") to include in API - // requests with the JSON null value. By default, fields with empty values are - // omitted from API requests. See - // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. - NullFields []string `json:"-"` +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. +func (c *ProjectsLocationsUpdateAclConfigCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ } -func (s GoogleMonitoringV3TypedValue) MarshalJSON() ([]byte, error) { - type NoMethod GoogleMonitoringV3TypedValue - return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +func (c *ProjectsLocationsUpdateAclConfigCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) + body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.googleclouddiscoveryenginev1alphaaclconfig) + if err != nil { + return nil, err + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+name}") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("PATCH", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "name": c.name, + }) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "discoveryengine.projects.locations.updateAclConfig", "request", internallog.HTTPRequest(req, body.Bytes())) + return gensupport.SendRequest(c.ctx_, c.s.client, req) } -func (s *GoogleMonitoringV3TypedValue) UnmarshalJSON(data []byte) error { - type NoMethod GoogleMonitoringV3TypedValue - var s1 struct { - DoubleValue gensupport.JSONFloat64 `json:"doubleValue"` - *NoMethod +// Do executes the "discoveryengine.projects.locations.updateAclConfig" call. +// Any non-2xx status code is an error. Response headers are in either +// *GoogleCloudDiscoveryengineV1alphaAclConfig.ServerResponse.Header or (if a +// response was returned at all) in error.(*googleapi.Error).Header. Use +// googleapi.IsNotModified to check whether the returned error was because +// http.StatusNotModified was returned. +func (c *ProjectsLocationsUpdateAclConfigCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1alphaAclConfig, 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, + }) } - s1.NoMethod = (*NoMethod)(s) - if err := json.Unmarshal(data, &s1); err != nil { - return err + if err != nil { + return nil, err } - s.DoubleValue = float64(s1.DoubleValue) - return nil + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &GoogleCloudDiscoveryengineV1alphaAclConfig{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + b, err := gensupport.DecodeResponseBytes(target, res) + if err != nil { + return nil, err + } + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "discoveryengine.projects.locations.updateAclConfig", "response", internallog.HTTPResponse(res, b)) + return ret, nil } -// 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:"-"` +type ProjectsLocationsUpdateCmekConfigCall struct { + s *Service + name string + googleclouddiscoveryenginev1alphacmekconfig *GoogleCloudDiscoveryengineV1alphaCmekConfig + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// 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. See - // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more - // details. - ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Code") to include in API requests - // with the JSON null value. By default, fields with empty values are omitted - // from API requests. See - // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. - NullFields []string `json:"-"` +// UpdateCmekConfig: Provisions a CMEK key for use in a location of a +// customer's project. This method will also conduct location validation on the +// provided cmekConfig to make sure the key is valid and can be used in the +// selected location. +// +// - name: Name of the CmekConfig, of the form +// `projects/{project}/locations/{location}/cmekConfig` or +// `projects/{project}/locations/{location}/cmekConfigs/{cmekConfig}`. +func (r *ProjectsLocationsService) UpdateCmekConfig(name string, googleclouddiscoveryenginev1alphacmekconfig *GoogleCloudDiscoveryengineV1alphaCmekConfig) *ProjectsLocationsUpdateCmekConfigCall { + c := &ProjectsLocationsUpdateCmekConfigCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + c.googleclouddiscoveryenginev1alphacmekconfig = googleclouddiscoveryenginev1alphacmekconfig + return c } -func (s GoogleRpcStatus) MarshalJSON() ([]byte, error) { - type NoMethod GoogleRpcStatus - return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +// SetDefault sets the optional parameter "setDefault": Set the following +// CmekConfig as the default to be used for child resources if one is not +// specified. +func (c *ProjectsLocationsUpdateCmekConfigCall) SetDefault(setDefault bool) *ProjectsLocationsUpdateCmekConfigCall { + c.urlParams_.Set("setDefault", fmt.Sprint(setDefault)) + return c } -// 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. See - // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more - // details. - 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. See - // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. - NullFields []string `json:"-"` +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. +func (c *ProjectsLocationsUpdateCmekConfigCall) Fields(s ...googleapi.Field) *ProjectsLocationsUpdateCmekConfigCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c } -func (s GoogleTypeDate) MarshalJSON() ([]byte, error) { - type NoMethod GoogleTypeDate - return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsUpdateCmekConfigCall) Context(ctx context.Context) *ProjectsLocationsUpdateCmekConfigCall { + c.ctx_ = ctx + return c } -// GoogleTypeExpr: Represents a textual expression in the Common Expression -// Language (CEL) syntax. CEL is a C-like expression language. The syntax and -// semantics of CEL are documented at https://github.com/google/cel-spec. -// Example (Comparison): title: "Summary size limit" description: "Determines -// if a summary is less than 100 chars" expression: "document.summary.size() < -// 100" Example (Equality): title: "Requestor is owner" description: -// "Determines if requestor is the document owner" expression: "document.owner -// == request.auth.claims.email" Example (Logic): title: "Public documents" -// description: "Determine whether the document should be publicly visible" -// expression: "document.type != 'private' && document.type != 'internal'" -// Example (Data Manipulation): title: "Notification string" description: -// "Create a notification string with a timestamp." expression: "'New message -// received at ' + string(document.create_time)" The exact variables and -// functions that may be referenced within an expression are determined by the -// service that evaluates it. See the service documentation for additional -// information. -type GoogleTypeExpr struct { - // Description: Optional. Description of the expression. This is a longer text - // which describes the expression, e.g. when hovered over it in a UI. - Description string `json:"description,omitempty"` - // Expression: Textual representation of an expression in Common Expression - // Language syntax. - Expression string `json:"expression,omitempty"` - // Location: Optional. String indicating the location of the expression for - // error reporting, e.g. a file name and a position in the file. - Location string `json:"location,omitempty"` - // Title: Optional. Title for the expression, i.e. a short string describing - // its purpose. This can be used e.g. in UIs which allow to enter the - // expression. - Title string `json:"title,omitempty"` - // ForceSendFields is a list of field names (e.g. "Description") to - // unconditionally include in API requests. By default, fields with empty or - // default values are omitted from API requests. See - // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more - // details. - ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Description") to include in API - // requests with the JSON null value. By default, fields with empty values are - // omitted from API requests. See - // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. - NullFields []string `json:"-"` +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. +func (c *ProjectsLocationsUpdateCmekConfigCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ } -func (s GoogleTypeExpr) MarshalJSON() ([]byte, error) { - type NoMethod GoogleTypeExpr - return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +func (c *ProjectsLocationsUpdateCmekConfigCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) + body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.googleclouddiscoveryenginev1alphacmekconfig) + if err != nil { + return nil, err + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+name}") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("PATCH", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "name": c.name, + }) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "discoveryengine.projects.locations.updateCmekConfig", "request", internallog.HTTPRequest(req, body.Bytes())) + return gensupport.SendRequest(c.ctx_, c.s.client, req) } -type ProjectsGetCall struct { +// Do executes the "discoveryengine.projects.locations.updateCmekConfig" call. +// Any non-2xx status code is an error. Response headers are in either +// *GoogleLongrunningOperation.ServerResponse.Header or (if a response was +// returned at all) in error.(*googleapi.Error).Header. Use +// googleapi.IsNotModified to check whether the returned error was because +// http.StatusNotModified was returned. +func (c *ProjectsLocationsUpdateCmekConfigCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &GoogleLongrunningOperation{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + b, err := gensupport.DecodeResponseBytes(target, res) + if err != nil { + return nil, err + } + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "discoveryengine.projects.locations.updateCmekConfig", "response", internallog.HTTPResponse(res, b)) + return ret, nil +} + +type ProjectsLocationsCmekConfigsGetCall struct { s *Service name string urlParams_ gensupport.URLParams @@ -21072,12 +23688,15 @@ type ProjectsGetCall struct { header_ http.Header } -// Get: Gets a Project. Returns NOT_FOUND when the project is not yet created. +// Get: Gets the CmekConfig. // -// - name: Full resource name of a Project, such as -// `projects/{project_id_or_number}`. -func (r *ProjectsService) Get(name string) *ProjectsGetCall { - c := &ProjectsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// - name: Resource name of CmekConfig, such as +// `projects/*/locations/*/cmekConfig` or +// `projects/*/locations/*/cmekConfigs/*`. If the caller does not have +// permission to access the CmekConfig, regardless of whether or not it +// exists, a PERMISSION_DENIED error is returned. +func (r *ProjectsLocationsCmekConfigsService) Get(name string) *ProjectsLocationsCmekConfigsGetCall { + c := &ProjectsLocationsCmekConfigsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.name = name return c } @@ -21085,7 +23704,7 @@ func (r *ProjectsService) Get(name string) *ProjectsGetCall { // Fields allows partial responses to be retrieved. See // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more // details. -func (c *ProjectsGetCall) Fields(s ...googleapi.Field) *ProjectsGetCall { +func (c *ProjectsLocationsCmekConfigsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsCmekConfigsGetCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } @@ -21093,27 +23712,27 @@ func (c *ProjectsGetCall) Fields(s ...googleapi.Field) *ProjectsGetCall { // IfNoneMatch sets an optional parameter which makes the operation fail if the // object's ETag matches the given value. This is useful for getting updates // only after the object has changed since the last request. -func (c *ProjectsGetCall) IfNoneMatch(entityTag string) *ProjectsGetCall { +func (c *ProjectsLocationsCmekConfigsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsCmekConfigsGetCall { c.ifNoneMatch_ = entityTag return c } // Context sets the context to be used in this call's Do method. -func (c *ProjectsGetCall) Context(ctx context.Context) *ProjectsGetCall { +func (c *ProjectsLocationsCmekConfigsGetCall) Context(ctx context.Context) *ProjectsLocationsCmekConfigsGetCall { c.ctx_ = ctx return c } // Header returns a http.Header that can be modified by the caller to add // headers to the request. -func (c *ProjectsGetCall) Header() http.Header { +func (c *ProjectsLocationsCmekConfigsGetCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsGetCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsCmekConfigsGetCall) doRequest(alt string) (*http.Response, error) { reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) if c.ifNoneMatch_ != "" { reqHeaders.Set("If-None-Match", c.ifNoneMatch_) @@ -21130,17 +23749,17 @@ func (c *ProjectsGetCall) doRequest(alt string) (*http.Response, error) { googleapi.Expand(req.URL, map[string]string{ "name": c.name, }) - c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "discoveryengine.projects.get", "request", internallog.HTTPRequest(req, nil)) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "discoveryengine.projects.locations.cmekConfigs.get", "request", internallog.HTTPRequest(req, nil)) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "discoveryengine.projects.get" call. +// Do executes the "discoveryengine.projects.locations.cmekConfigs.get" call. // Any non-2xx status code is an error. Response headers are in either -// *GoogleCloudDiscoveryengineV1alphaProject.ServerResponse.Header or (if a +// *GoogleCloudDiscoveryengineV1alphaCmekConfig.ServerResponse.Header or (if a // response was returned at all) in error.(*googleapi.Error).Header. Use // googleapi.IsNotModified to check whether the returned error was because // http.StatusNotModified was returned. -func (c *ProjectsGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1alphaProject, error) { +func (c *ProjectsLocationsCmekConfigsGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1alphaCmekConfig, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -21159,7 +23778,7 @@ func (c *ProjectsGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscover if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &GoogleCloudDiscoveryengineV1alphaProject{ + ret := &GoogleCloudDiscoveryengineV1alphaCmekConfig{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -21170,85 +23789,90 @@ func (c *ProjectsGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscover if err != nil { return nil, err } - c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "discoveryengine.projects.get", "response", internallog.HTTPResponse(res, b)) + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "discoveryengine.projects.locations.cmekConfigs.get", "response", internallog.HTTPResponse(res, b)) return ret, nil } -type ProjectsProvisionCall struct { - s *Service - name string - googleclouddiscoveryenginev1alphaprovisionprojectrequest *GoogleCloudDiscoveryengineV1alphaProvisionProjectRequest - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +type ProjectsLocationsCmekConfigsListCall struct { + s *Service + parent string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header } -// Provision: Provisions the project resource. During the process, related -// systems will get prepared and initialized. Caller must read the Terms for -// data use (https://cloud.google.com/retail/data-use-terms), and optionally -// specify in request to provide consent to that service terms. +// List: Lists all the CmekConfigs with the project. // -// - name: Full resource name of a Project, such as -// `projects/{project_id_or_number}`. -func (r *ProjectsService) Provision(name string, googleclouddiscoveryenginev1alphaprovisionprojectrequest *GoogleCloudDiscoveryengineV1alphaProvisionProjectRequest) *ProjectsProvisionCall { - c := &ProjectsProvisionCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.name = name - c.googleclouddiscoveryenginev1alphaprovisionprojectrequest = googleclouddiscoveryenginev1alphaprovisionprojectrequest +// - parent: The parent location resource name, such as +// `projects/{project}/locations/{location}`. If the caller does not have +// permission to list CmekConfigs under this location, regardless of whether +// or not a CmekConfig exists, a PERMISSION_DENIED error is returned. +func (r *ProjectsLocationsCmekConfigsService) List(parent string) *ProjectsLocationsCmekConfigsListCall { + c := &ProjectsLocationsCmekConfigsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent return c } // Fields allows partial responses to be retrieved. See // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more // details. -func (c *ProjectsProvisionCall) Fields(s ...googleapi.Field) *ProjectsProvisionCall { +func (c *ProjectsLocationsCmekConfigsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsCmekConfigsListCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } +// IfNoneMatch sets an optional parameter which makes the operation fail if the +// object's ETag matches the given value. This is useful for getting updates +// only after the object has changed since the last request. +func (c *ProjectsLocationsCmekConfigsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsCmekConfigsListCall { + c.ifNoneMatch_ = entityTag + return c +} + // Context sets the context to be used in this call's Do method. -func (c *ProjectsProvisionCall) Context(ctx context.Context) *ProjectsProvisionCall { +func (c *ProjectsLocationsCmekConfigsListCall) Context(ctx context.Context) *ProjectsLocationsCmekConfigsListCall { c.ctx_ = ctx return c } // Header returns a http.Header that can be modified by the caller to add // headers to the request. -func (c *ProjectsProvisionCall) Header() http.Header { +func (c *ProjectsLocationsCmekConfigsListCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsProvisionCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) - body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.googleclouddiscoveryenginev1alphaprovisionprojectrequest) - if err != nil { - return nil, err +func (c *ProjectsLocationsCmekConfigsListCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) } c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+name}:provision") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+parent}/cmekConfigs") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("POST", urls, body) + req, err := http.NewRequest("GET", urls, nil) if err != nil { return nil, err } req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ - "name": c.name, + "parent": c.parent, }) - c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "discoveryengine.projects.provision", "request", internallog.HTTPRequest(req, body.Bytes())) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "discoveryengine.projects.locations.cmekConfigs.list", "request", internallog.HTTPRequest(req, nil)) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "discoveryengine.projects.provision" call. +// Do executes the "discoveryengine.projects.locations.cmekConfigs.list" call. // Any non-2xx status code is an error. Response headers are in either -// *GoogleLongrunningOperation.ServerResponse.Header or (if a response was -// returned at all) in error.(*googleapi.Error).Header. Use -// googleapi.IsNotModified to check whether the returned error was because -// http.StatusNotModified was returned. -func (c *ProjectsProvisionCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { +// *GoogleCloudDiscoveryengineV1alphaListCmekConfigsResponse.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 *ProjectsLocationsCmekConfigsListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1alphaListCmekConfigsResponse, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -21267,7 +23891,7 @@ func (c *ProjectsProvisionCall) Do(opts ...googleapi.CallOption) (*GoogleLongrun if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &GoogleLongrunningOperation{ + ret := &GoogleCloudDiscoveryengineV1alphaListCmekConfigsResponse{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -21278,85 +23902,93 @@ func (c *ProjectsProvisionCall) Do(opts ...googleapi.CallOption) (*GoogleLongrun if err != nil { return nil, err } - c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "discoveryengine.projects.provision", "response", internallog.HTTPResponse(res, b)) + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "discoveryengine.projects.locations.cmekConfigs.list", "response", internallog.HTTPResponse(res, b)) return ret, nil } -type ProjectsReportConsentChangeCall struct { - s *Service - project string - googleclouddiscoveryenginev1alphareportconsentchangerequest *GoogleCloudDiscoveryengineV1alphaReportConsentChangeRequest - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +type ProjectsLocationsCmekConfigsPatchCall struct { + s *Service + name string + googleclouddiscoveryenginev1alphacmekconfig *GoogleCloudDiscoveryengineV1alphaCmekConfig + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// ReportConsentChange: Updates service terms for this project. This method can -// be used to retroactively accept the latest terms. Terms available for -// update: * Terms for data use -// (https://cloud.google.com/retail/data-use-terms) +// Patch: Provisions a CMEK key for use in a location of a customer's project. +// This method will also conduct location validation on the provided cmekConfig +// to make sure the key is valid and can be used in the selected location. // -// - project: Full resource name of a Project, such as -// `projects/{project_id_or_number}`. -func (r *ProjectsService) ReportConsentChange(project string, googleclouddiscoveryenginev1alphareportconsentchangerequest *GoogleCloudDiscoveryengineV1alphaReportConsentChangeRequest) *ProjectsReportConsentChangeCall { - c := &ProjectsReportConsentChangeCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.project = project - c.googleclouddiscoveryenginev1alphareportconsentchangerequest = googleclouddiscoveryenginev1alphareportconsentchangerequest +// - name: Name of the CmekConfig, of the form +// `projects/{project}/locations/{location}/cmekConfig` or +// `projects/{project}/locations/{location}/cmekConfigs/{cmekConfig}`. +func (r *ProjectsLocationsCmekConfigsService) Patch(name string, googleclouddiscoveryenginev1alphacmekconfig *GoogleCloudDiscoveryengineV1alphaCmekConfig) *ProjectsLocationsCmekConfigsPatchCall { + c := &ProjectsLocationsCmekConfigsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + c.googleclouddiscoveryenginev1alphacmekconfig = googleclouddiscoveryenginev1alphacmekconfig + return c +} + +// SetDefault sets the optional parameter "setDefault": Set the following +// CmekConfig as the default to be used for child resources if one is not +// specified. +func (c *ProjectsLocationsCmekConfigsPatchCall) SetDefault(setDefault bool) *ProjectsLocationsCmekConfigsPatchCall { + c.urlParams_.Set("setDefault", fmt.Sprint(setDefault)) return c } // Fields allows partial responses to be retrieved. See // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more // details. -func (c *ProjectsReportConsentChangeCall) Fields(s ...googleapi.Field) *ProjectsReportConsentChangeCall { +func (c *ProjectsLocationsCmekConfigsPatchCall) Fields(s ...googleapi.Field) *ProjectsLocationsCmekConfigsPatchCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } // Context sets the context to be used in this call's Do method. -func (c *ProjectsReportConsentChangeCall) Context(ctx context.Context) *ProjectsReportConsentChangeCall { +func (c *ProjectsLocationsCmekConfigsPatchCall) Context(ctx context.Context) *ProjectsLocationsCmekConfigsPatchCall { c.ctx_ = ctx return c } // Header returns a http.Header that can be modified by the caller to add // headers to the request. -func (c *ProjectsReportConsentChangeCall) Header() http.Header { +func (c *ProjectsLocationsCmekConfigsPatchCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsReportConsentChangeCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsCmekConfigsPatchCall) doRequest(alt string) (*http.Response, error) { reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) - body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.googleclouddiscoveryenginev1alphareportconsentchangerequest) + body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.googleclouddiscoveryenginev1alphacmekconfig) if err != nil { return nil, err } c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+project}:reportConsentChange") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+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{ - "project": c.project, + "name": c.name, }) - c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "discoveryengine.projects.reportConsentChange", "request", internallog.HTTPRequest(req, body.Bytes())) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "discoveryengine.projects.locations.cmekConfigs.patch", "request", internallog.HTTPRequest(req, body.Bytes())) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "discoveryengine.projects.reportConsentChange" call. +// Do executes the "discoveryengine.projects.locations.cmekConfigs.patch" call. // Any non-2xx status code is an error. Response headers are in either -// *GoogleCloudDiscoveryengineV1alphaProject.ServerResponse.Header or (if a -// response was returned at all) in error.(*googleapi.Error).Header. Use +// *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 *ProjectsReportConsentChangeCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1alphaProject, error) { +func (c *ProjectsLocationsCmekConfigsPatchCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -21375,7 +24007,7 @@ func (c *ProjectsReportConsentChangeCall) Do(opts ...googleapi.CallOption) (*Goo if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &GoogleCloudDiscoveryengineV1alphaProject{ + ret := &GoogleLongrunningOperation{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -21386,82 +24018,76 @@ func (c *ProjectsReportConsentChangeCall) Do(opts ...googleapi.CallOption) (*Goo if err != nil { return nil, err } - c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "discoveryengine.projects.reportConsentChange", "response", internallog.HTTPResponse(res, b)) + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "discoveryengine.projects.locations.cmekConfigs.patch", "response", internallog.HTTPResponse(res, b)) return ret, nil } -type ProjectsLocationsEstimateDataSizeCall struct { - s *Service - location string - googleclouddiscoveryenginev1alphaestimatedatasizerequest *GoogleCloudDiscoveryengineV1alphaEstimateDataSizeRequest - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +type ProjectsLocationsCollectionsDeleteCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// EstimateDataSize: Estimates the data size to be used by a customer. +// Delete: Deletes a Collection. // -// - location: Full resource name of the location, such as -// `projects/{project}/locations/{location}`. -func (r *ProjectsLocationsService) EstimateDataSize(location string, googleclouddiscoveryenginev1alphaestimatedatasizerequest *GoogleCloudDiscoveryengineV1alphaEstimateDataSizeRequest) *ProjectsLocationsEstimateDataSizeCall { - c := &ProjectsLocationsEstimateDataSizeCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.location = location - c.googleclouddiscoveryenginev1alphaestimatedatasizerequest = googleclouddiscoveryenginev1alphaestimatedatasizerequest +// - name: The full resource name of the Collection, in the format of +// `projects/{project}/locations/{location}/collections/{collection}`. +func (r *ProjectsLocationsCollectionsService) Delete(name string) *ProjectsLocationsCollectionsDeleteCall { + c := &ProjectsLocationsCollectionsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name return c } // Fields allows partial responses to be retrieved. See // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more // details. -func (c *ProjectsLocationsEstimateDataSizeCall) Fields(s ...googleapi.Field) *ProjectsLocationsEstimateDataSizeCall { +func (c *ProjectsLocationsCollectionsDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDeleteCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } // Context sets the context to be used in this call's Do method. -func (c *ProjectsLocationsEstimateDataSizeCall) Context(ctx context.Context) *ProjectsLocationsEstimateDataSizeCall { +func (c *ProjectsLocationsCollectionsDeleteCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDeleteCall { c.ctx_ = ctx return c } // Header returns a http.Header that can be modified by the caller to add // headers to the request. -func (c *ProjectsLocationsEstimateDataSizeCall) Header() http.Header { +func (c *ProjectsLocationsCollectionsDeleteCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsEstimateDataSizeCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) - body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.googleclouddiscoveryenginev1alphaestimatedatasizerequest) - if err != nil { - return nil, err - } +func (c *ProjectsLocationsCollectionsDeleteCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+location}:estimateDataSize") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+name}") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("POST", urls, body) + req, err := http.NewRequest("DELETE", urls, nil) if err != nil { return nil, err } req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ - "location": c.location, + "name": c.name, }) - c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "discoveryengine.projects.locations.estimateDataSize", "request", internallog.HTTPRequest(req, body.Bytes())) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "discoveryengine.projects.locations.collections.delete", "request", internallog.HTTPRequest(req, nil)) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "discoveryengine.projects.locations.estimateDataSize" call. +// Do executes the "discoveryengine.projects.locations.collections.delete" call. // Any non-2xx status code is an error. Response headers are in either // *GoogleLongrunningOperation.ServerResponse.Header or (if a response was // returned at all) in error.(*googleapi.Error).Header. Use // googleapi.IsNotModified to check whether the returned error was because // http.StatusNotModified was returned. -func (c *ProjectsLocationsEstimateDataSizeCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { +func (c *ProjectsLocationsCollectionsDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -21491,11 +24117,11 @@ func (c *ProjectsLocationsEstimateDataSizeCall) Do(opts ...googleapi.CallOption) if err != nil { return nil, err } - c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "discoveryengine.projects.locations.estimateDataSize", "response", internallog.HTTPResponse(res, b)) + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "discoveryengine.projects.locations.collections.delete", "response", internallog.HTTPResponse(res, b)) return ret, nil } -type ProjectsLocationsGetAclConfigCall struct { +type ProjectsLocationsCollectionsGetCall struct { s *Service name string urlParams_ gensupport.URLParams @@ -21504,14 +24130,12 @@ type ProjectsLocationsGetAclConfigCall struct { header_ http.Header } -// GetAclConfig: Gets the AclConfig. +// Get: Gets a Collection. // -// - name: Resource name of AclConfig, such as -// `projects/*/locations/*/aclConfig`. If the caller does not have permission -// to access the AclConfig, regardless of whether or not it exists, a -// PERMISSION_DENIED error is returned. -func (r *ProjectsLocationsService) GetAclConfig(name string) *ProjectsLocationsGetAclConfigCall { - c := &ProjectsLocationsGetAclConfigCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// - name: The full resource name, in the format of +// `projects/{project}/locations/{location}/collections/{collection}`. +func (r *ProjectsLocationsCollectionsService) Get(name string) *ProjectsLocationsCollectionsGetCall { + c := &ProjectsLocationsCollectionsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.name = name return c } @@ -21519,7 +24143,7 @@ func (r *ProjectsLocationsService) GetAclConfig(name string) *ProjectsLocationsG // Fields allows partial responses to be retrieved. See // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more // details. -func (c *ProjectsLocationsGetAclConfigCall) Fields(s ...googleapi.Field) *ProjectsLocationsGetAclConfigCall { +func (c *ProjectsLocationsCollectionsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsGetCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } @@ -21527,27 +24151,27 @@ func (c *ProjectsLocationsGetAclConfigCall) Fields(s ...googleapi.Field) *Projec // IfNoneMatch sets an optional parameter which makes the operation fail if the // object's ETag matches the given value. This is useful for getting updates // only after the object has changed since the last request. -func (c *ProjectsLocationsGetAclConfigCall) IfNoneMatch(entityTag string) *ProjectsLocationsGetAclConfigCall { +func (c *ProjectsLocationsCollectionsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsCollectionsGetCall { c.ifNoneMatch_ = entityTag return c } // Context sets the context to be used in this call's Do method. -func (c *ProjectsLocationsGetAclConfigCall) Context(ctx context.Context) *ProjectsLocationsGetAclConfigCall { +func (c *ProjectsLocationsCollectionsGetCall) Context(ctx context.Context) *ProjectsLocationsCollectionsGetCall { c.ctx_ = ctx return c } // Header returns a http.Header that can be modified by the caller to add // headers to the request. -func (c *ProjectsLocationsGetAclConfigCall) Header() http.Header { +func (c *ProjectsLocationsCollectionsGetCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsGetAclConfigCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsCollectionsGetCall) doRequest(alt string) (*http.Response, error) { reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) if c.ifNoneMatch_ != "" { reqHeaders.Set("If-None-Match", c.ifNoneMatch_) @@ -21564,17 +24188,17 @@ func (c *ProjectsLocationsGetAclConfigCall) doRequest(alt string) (*http.Respons googleapi.Expand(req.URL, map[string]string{ "name": c.name, }) - c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "discoveryengine.projects.locations.getAclConfig", "request", internallog.HTTPRequest(req, nil)) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "discoveryengine.projects.locations.collections.get", "request", internallog.HTTPRequest(req, nil)) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "discoveryengine.projects.locations.getAclConfig" call. +// Do executes the "discoveryengine.projects.locations.collections.get" call. // Any non-2xx status code is an error. Response headers are in either -// *GoogleCloudDiscoveryengineV1alphaAclConfig.ServerResponse.Header or (if a +// *GoogleCloudDiscoveryengineV1alphaCollection.ServerResponse.Header or (if a // response was returned at all) in error.(*googleapi.Error).Header. Use // googleapi.IsNotModified to check whether the returned error was because // http.StatusNotModified was returned. -func (c *ProjectsLocationsGetAclConfigCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1alphaAclConfig, error) { +func (c *ProjectsLocationsCollectionsGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1alphaCollection, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -21593,7 +24217,7 @@ func (c *ProjectsLocationsGetAclConfigCall) Do(opts ...googleapi.CallOption) (*G if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &GoogleCloudDiscoveryengineV1alphaAclConfig{ + ret := &GoogleCloudDiscoveryengineV1alphaCollection{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -21604,11 +24228,11 @@ func (c *ProjectsLocationsGetAclConfigCall) Do(opts ...googleapi.CallOption) (*G if err != nil { return nil, err } - c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "discoveryengine.projects.locations.getAclConfig", "response", internallog.HTTPResponse(res, b)) + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "discoveryengine.projects.locations.collections.get", "response", internallog.HTTPResponse(res, b)) return ret, nil } -type ProjectsLocationsGetCmekConfigCall struct { +type ProjectsLocationsCollectionsGetDataConnectorCall struct { s *Service name string urlParams_ gensupport.URLParams @@ -21617,15 +24241,17 @@ type ProjectsLocationsGetCmekConfigCall struct { header_ http.Header } -// GetCmekConfig: Gets the CmekConfig. +// GetDataConnector: Gets the DataConnector. DataConnector is a singleton +// resource for each Collection. // -// - name: Resource name of CmekConfig, such as -// `projects/*/locations/*/cmekConfig` or -// `projects/*/locations/*/cmekConfigs/*`. If the caller does not have -// permission to access the CmekConfig, regardless of whether or not it -// exists, a PERMISSION_DENIED error is returned. -func (r *ProjectsLocationsService) GetCmekConfig(name string) *ProjectsLocationsGetCmekConfigCall { - c := &ProjectsLocationsGetCmekConfigCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// - name: Full resource name of DataConnector, such as +// `projects/{project}/locations/{location}/collections/{collection_id}/dataCo +// nnector`. If the caller does not have permission to access the +// DataConnector, regardless of whether or not it exists, a PERMISSION_DENIED +// error is returned. If the requested DataConnector does not exist, a +// NOT_FOUND error is returned. +func (r *ProjectsLocationsCollectionsService) GetDataConnector(name string) *ProjectsLocationsCollectionsGetDataConnectorCall { + c := &ProjectsLocationsCollectionsGetDataConnectorCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.name = name return c } @@ -21633,7 +24259,7 @@ func (r *ProjectsLocationsService) GetCmekConfig(name string) *ProjectsLocations // Fields allows partial responses to be retrieved. See // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more // details. -func (c *ProjectsLocationsGetCmekConfigCall) Fields(s ...googleapi.Field) *ProjectsLocationsGetCmekConfigCall { +func (c *ProjectsLocationsCollectionsGetDataConnectorCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsGetDataConnectorCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } @@ -21641,27 +24267,27 @@ func (c *ProjectsLocationsGetCmekConfigCall) Fields(s ...googleapi.Field) *Proje // IfNoneMatch sets an optional parameter which makes the operation fail if the // object's ETag matches the given value. This is useful for getting updates // only after the object has changed since the last request. -func (c *ProjectsLocationsGetCmekConfigCall) IfNoneMatch(entityTag string) *ProjectsLocationsGetCmekConfigCall { +func (c *ProjectsLocationsCollectionsGetDataConnectorCall) IfNoneMatch(entityTag string) *ProjectsLocationsCollectionsGetDataConnectorCall { c.ifNoneMatch_ = entityTag return c } // Context sets the context to be used in this call's Do method. -func (c *ProjectsLocationsGetCmekConfigCall) Context(ctx context.Context) *ProjectsLocationsGetCmekConfigCall { +func (c *ProjectsLocationsCollectionsGetDataConnectorCall) Context(ctx context.Context) *ProjectsLocationsCollectionsGetDataConnectorCall { c.ctx_ = ctx return c } // Header returns a http.Header that can be modified by the caller to add // headers to the request. -func (c *ProjectsLocationsGetCmekConfigCall) Header() http.Header { +func (c *ProjectsLocationsCollectionsGetDataConnectorCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsGetCmekConfigCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsCollectionsGetDataConnectorCall) doRequest(alt string) (*http.Response, error) { reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) if c.ifNoneMatch_ != "" { reqHeaders.Set("If-None-Match", c.ifNoneMatch_) @@ -21678,17 +24304,17 @@ func (c *ProjectsLocationsGetCmekConfigCall) doRequest(alt string) (*http.Respon googleapi.Expand(req.URL, map[string]string{ "name": c.name, }) - c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "discoveryengine.projects.locations.getCmekConfig", "request", internallog.HTTPRequest(req, nil)) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "discoveryengine.projects.locations.collections.getDataConnector", "request", internallog.HTTPRequest(req, nil)) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "discoveryengine.projects.locations.getCmekConfig" call. +// Do executes the "discoveryengine.projects.locations.collections.getDataConnector" call. // Any non-2xx status code is an error. Response headers are in either -// *GoogleCloudDiscoveryengineV1alphaCmekConfig.ServerResponse.Header or (if a -// response was returned at all) in error.(*googleapi.Error).Header. Use +// *GoogleCloudDiscoveryengineV1alphaDataConnector.ServerResponse.Header or (if +// a response was returned at all) in error.(*googleapi.Error).Header. Use // googleapi.IsNotModified to check whether the returned error was because // http.StatusNotModified was returned. -func (c *ProjectsLocationsGetCmekConfigCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1alphaCmekConfig, error) { +func (c *ProjectsLocationsCollectionsGetDataConnectorCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1alphaDataConnector, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -21707,7 +24333,7 @@ func (c *ProjectsLocationsGetCmekConfigCall) Do(opts ...googleapi.CallOption) (* if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &GoogleCloudDiscoveryengineV1alphaCmekConfig{ + ret := &GoogleCloudDiscoveryengineV1alphaDataConnector{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -21718,85 +24344,116 @@ func (c *ProjectsLocationsGetCmekConfigCall) Do(opts ...googleapi.CallOption) (* if err != nil { return nil, err } - c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "discoveryengine.projects.locations.getCmekConfig", "response", internallog.HTTPResponse(res, b)) + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "discoveryengine.projects.locations.collections.getDataConnector", "response", internallog.HTTPResponse(res, b)) return ret, nil } -type ProjectsLocationsUpdateAclConfigCall struct { - s *Service - name string - googleclouddiscoveryenginev1alphaaclconfig *GoogleCloudDiscoveryengineV1alphaAclConfig - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +type ProjectsLocationsCollectionsListCall struct { + s *Service + parent string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header } -// UpdateAclConfig: Default ACL configuration for use in a location of a -// customer's project. Updates will only reflect to new data stores. Existing -// data stores will still use the old value. +// List: Gets a list of Collections. // -// - name: Immutable. The full resource name of the acl configuration. Format: -// `projects/{project}/locations/{location}/aclConfig`. This field must be a -// UTF-8 encoded string with a length limit of 1024 characters. -func (r *ProjectsLocationsService) UpdateAclConfig(name string, googleclouddiscoveryenginev1alphaaclconfig *GoogleCloudDiscoveryengineV1alphaAclConfig) *ProjectsLocationsUpdateAclConfigCall { - c := &ProjectsLocationsUpdateAclConfigCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.name = name - c.googleclouddiscoveryenginev1alphaaclconfig = googleclouddiscoveryenginev1alphaaclconfig +// - parent: The parent data store resource name, in the format of +// `projects/{project}/locations/{location}`. +func (r *ProjectsLocationsCollectionsService) List(parent string) *ProjectsLocationsCollectionsListCall { + c := &ProjectsLocationsCollectionsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + return c +} + +// Filter sets the optional parameter "filter": Filter returned collections by +// associated data connector data sources. For example: `filter = +// 'data_source:jira confluence'`. If the filter is empty, we return all +// collections under a project and location. +func (c *ProjectsLocationsCollectionsListCall) Filter(filter string) *ProjectsLocationsCollectionsListCall { + c.urlParams_.Set("filter", filter) + return c +} + +// PageSize sets the optional parameter "pageSize": The maximum number of +// Collections to return. The service may return fewer than this value. If +// unspecified, at most 100 Collections will be returned. The maximum value is +// 1000; values above 1000 will be coerced to 1000. +func (c *ProjectsLocationsCollectionsListCall) PageSize(pageSize int64) *ProjectsLocationsCollectionsListCall { + c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) + return c +} + +// PageToken sets the optional parameter "pageToken": A page token, received +// from a previous CollectionService.ListCollections call. Provide this to +// retrieve the subsequent page. When paginating, all other parameters provided +// to CollectionService.ListCollections must match the call that provided the +// page token. +func (c *ProjectsLocationsCollectionsListCall) PageToken(pageToken string) *ProjectsLocationsCollectionsListCall { + c.urlParams_.Set("pageToken", pageToken) return c } // Fields allows partial responses to be retrieved. See // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more // details. -func (c *ProjectsLocationsUpdateAclConfigCall) Fields(s ...googleapi.Field) *ProjectsLocationsUpdateAclConfigCall { +func (c *ProjectsLocationsCollectionsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsListCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } +// IfNoneMatch sets an optional parameter which makes the operation fail if the +// object's ETag matches the given value. This is useful for getting updates +// only after the object has changed since the last request. +func (c *ProjectsLocationsCollectionsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsCollectionsListCall { + c.ifNoneMatch_ = entityTag + return c +} + // Context sets the context to be used in this call's Do method. -func (c *ProjectsLocationsUpdateAclConfigCall) Context(ctx context.Context) *ProjectsLocationsUpdateAclConfigCall { +func (c *ProjectsLocationsCollectionsListCall) Context(ctx context.Context) *ProjectsLocationsCollectionsListCall { c.ctx_ = ctx return c } // Header returns a http.Header that can be modified by the caller to add // headers to the request. -func (c *ProjectsLocationsUpdateAclConfigCall) Header() http.Header { +func (c *ProjectsLocationsCollectionsListCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsUpdateAclConfigCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) - body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.googleclouddiscoveryenginev1alphaaclconfig) - if err != nil { - return nil, err +func (c *ProjectsLocationsCollectionsListCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) } c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+name}") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+parent}/collections") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("PATCH", urls, body) + req, err := http.NewRequest("GET", urls, nil) if err != nil { return nil, err } req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ - "name": c.name, + "parent": c.parent, }) - c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "discoveryengine.projects.locations.updateAclConfig", "request", internallog.HTTPRequest(req, body.Bytes())) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "discoveryengine.projects.locations.collections.list", "request", internallog.HTTPRequest(req, nil)) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "discoveryengine.projects.locations.updateAclConfig" call. +// Do executes the "discoveryengine.projects.locations.collections.list" call. // Any non-2xx status code is an error. Response headers are in either -// *GoogleCloudDiscoveryengineV1alphaAclConfig.ServerResponse.Header or (if a -// response was returned at all) in error.(*googleapi.Error).Header. Use -// googleapi.IsNotModified to check whether the returned error was because -// http.StatusNotModified was returned. -func (c *ProjectsLocationsUpdateAclConfigCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1alphaAclConfig, error) { +// *GoogleCloudDiscoveryengineV1alphaListCollectionsResponse.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 *ProjectsLocationsCollectionsListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1alphaListCollectionsResponse, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -21815,7 +24472,7 @@ func (c *ProjectsLocationsUpdateAclConfigCall) Do(opts ...googleapi.CallOption) if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &GoogleCloudDiscoveryengineV1alphaAclConfig{ + ret := &GoogleCloudDiscoveryengineV1alphaListCollectionsResponse{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -21826,68 +24483,86 @@ func (c *ProjectsLocationsUpdateAclConfigCall) Do(opts ...googleapi.CallOption) if err != nil { return nil, err } - c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "discoveryengine.projects.locations.updateAclConfig", "response", internallog.HTTPResponse(res, b)) + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "discoveryengine.projects.locations.collections.list", "response", internallog.HTTPResponse(res, b)) return ret, nil } -type ProjectsLocationsUpdateCmekConfigCall struct { +// 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 *ProjectsLocationsCollectionsListCall) Pages(ctx context.Context, f func(*GoogleCloudDiscoveryengineV1alphaListCollectionsResponse) error) error { + c.ctx_ = ctx + defer c.PageToken(c.urlParams_.Get("pageToken")) + for { + x, err := c.Do() + if err != nil { + return err + } + if err := f(x); err != nil { + return err + } + if x.NextPageToken == "" { + return nil + } + c.PageToken(x.NextPageToken) + } +} + +type ProjectsLocationsCollectionsPatchCall struct { s *Service name string - googleclouddiscoveryenginev1alphacmekconfig *GoogleCloudDiscoveryengineV1alphaCmekConfig + googleclouddiscoveryenginev1alphacollection *GoogleCloudDiscoveryengineV1alphaCollection urlParams_ gensupport.URLParams ctx_ context.Context header_ http.Header } -// UpdateCmekConfig: Provisions a CMEK key for use in a location of a -// customer's project. This method will also conduct location validation on the -// provided cmekConfig to make sure the key is valid and can be used in the -// selected location. +// Patch: Updates a Collection. // -// - name: Name of the CmekConfig, of the form -// `projects/{project}/locations/{location}/cmekConfig` or -// `projects/{project}/locations/{location}/cmekConfigs/{cmekConfig}`. -func (r *ProjectsLocationsService) UpdateCmekConfig(name string, googleclouddiscoveryenginev1alphacmekconfig *GoogleCloudDiscoveryengineV1alphaCmekConfig) *ProjectsLocationsUpdateCmekConfigCall { - c := &ProjectsLocationsUpdateCmekConfigCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// - name: Immutable. The full resource name of the Collection. Format: +// `projects/{project}/locations/{location}/collections/{collection_id}`. +// This field must be a UTF-8 encoded string with a length limit of 1024 +// characters. +func (r *ProjectsLocationsCollectionsService) Patch(name string, googleclouddiscoveryenginev1alphacollection *GoogleCloudDiscoveryengineV1alphaCollection) *ProjectsLocationsCollectionsPatchCall { + c := &ProjectsLocationsCollectionsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.name = name - c.googleclouddiscoveryenginev1alphacmekconfig = googleclouddiscoveryenginev1alphacmekconfig + c.googleclouddiscoveryenginev1alphacollection = googleclouddiscoveryenginev1alphacollection return c } -// SetDefault sets the optional parameter "setDefault": Set the following -// CmekConfig as the default to be used for child resources if one is not -// specified. -func (c *ProjectsLocationsUpdateCmekConfigCall) SetDefault(setDefault bool) *ProjectsLocationsUpdateCmekConfigCall { - c.urlParams_.Set("setDefault", fmt.Sprint(setDefault)) +// UpdateMask sets the optional parameter "updateMask": The list of fields to +// be updated. +func (c *ProjectsLocationsCollectionsPatchCall) UpdateMask(updateMask string) *ProjectsLocationsCollectionsPatchCall { + c.urlParams_.Set("updateMask", updateMask) return c } // Fields allows partial responses to be retrieved. See // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more // details. -func (c *ProjectsLocationsUpdateCmekConfigCall) Fields(s ...googleapi.Field) *ProjectsLocationsUpdateCmekConfigCall { +func (c *ProjectsLocationsCollectionsPatchCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsPatchCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } // Context sets the context to be used in this call's Do method. -func (c *ProjectsLocationsUpdateCmekConfigCall) Context(ctx context.Context) *ProjectsLocationsUpdateCmekConfigCall { +func (c *ProjectsLocationsCollectionsPatchCall) Context(ctx context.Context) *ProjectsLocationsCollectionsPatchCall { c.ctx_ = ctx return c } // Header returns a http.Header that can be modified by the caller to add // headers to the request. -func (c *ProjectsLocationsUpdateCmekConfigCall) Header() http.Header { +func (c *ProjectsLocationsCollectionsPatchCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsUpdateCmekConfigCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsCollectionsPatchCall) doRequest(alt string) (*http.Response, error) { reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) - body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.googleclouddiscoveryenginev1alphacmekconfig) + body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.googleclouddiscoveryenginev1alphacollection) if err != nil { return nil, err } @@ -21903,17 +24578,17 @@ func (c *ProjectsLocationsUpdateCmekConfigCall) doRequest(alt string) (*http.Res googleapi.Expand(req.URL, map[string]string{ "name": c.name, }) - c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "discoveryengine.projects.locations.updateCmekConfig", "request", internallog.HTTPRequest(req, body.Bytes())) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "discoveryengine.projects.locations.collections.patch", "request", internallog.HTTPRequest(req, body.Bytes())) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "discoveryengine.projects.locations.updateCmekConfig" call. +// Do executes the "discoveryengine.projects.locations.collections.patch" call. // Any non-2xx status code is an error. Response headers are in either // *GoogleLongrunningOperation.ServerResponse.Header or (if a response was // returned at all) in error.(*googleapi.Error).Header. Use // googleapi.IsNotModified to check whether the returned error was because // http.StatusNotModified was returned. -func (c *ProjectsLocationsUpdateCmekConfigCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { +func (c *ProjectsLocationsCollectionsPatchCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -21943,73 +24618,76 @@ func (c *ProjectsLocationsUpdateCmekConfigCall) Do(opts ...googleapi.CallOption) if err != nil { return nil, err } - c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "discoveryengine.projects.locations.updateCmekConfig", "response", internallog.HTTPResponse(res, b)) + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "discoveryengine.projects.locations.collections.patch", "response", internallog.HTTPResponse(res, b)) return ret, nil } -type ProjectsLocationsCmekConfigsGetCall struct { - s *Service - name string - urlParams_ gensupport.URLParams - ifNoneMatch_ string - ctx_ context.Context - header_ http.Header +type ProjectsLocationsCollectionsUpdateDataConnectorCall struct { + s *Service + name string + googleclouddiscoveryenginev1alphadataconnector *GoogleCloudDiscoveryengineV1alphaDataConnector + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// Get: Gets the CmekConfig. +// UpdateDataConnector: Updates a DataConnector. // -// - name: Resource name of CmekConfig, such as -// `projects/*/locations/*/cmekConfig` or -// `projects/*/locations/*/cmekConfigs/*`. If the caller does not have -// permission to access the CmekConfig, regardless of whether or not it -// exists, a PERMISSION_DENIED error is returned. -func (r *ProjectsLocationsCmekConfigsService) Get(name string) *ProjectsLocationsCmekConfigsGetCall { - c := &ProjectsLocationsCmekConfigsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// - name: Output only. The full resource name of the Data Connector. Format: +// `projects/*/locations/*/collections/*/dataConnector`. +func (r *ProjectsLocationsCollectionsService) UpdateDataConnector(name string, googleclouddiscoveryenginev1alphadataconnector *GoogleCloudDiscoveryengineV1alphaDataConnector) *ProjectsLocationsCollectionsUpdateDataConnectorCall { + c := &ProjectsLocationsCollectionsUpdateDataConnectorCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.name = name + c.googleclouddiscoveryenginev1alphadataconnector = googleclouddiscoveryenginev1alphadataconnector + return c +} + +// UpdateMask sets the optional parameter "updateMask": Indicates which fields +// in the provided DataConnector to update. Supported field paths include: - +// refresh_interval - params - auto_run_disabled - action_config - +// destination_configs - blocking_reasons Note: Support for these fields may +// vary depending on the connector type. For example, not all connectors +// support `destination_configs`. If an unsupported or unknown field path is +// provided, the request will return an INVALID_ARGUMENT error. +func (c *ProjectsLocationsCollectionsUpdateDataConnectorCall) UpdateMask(updateMask string) *ProjectsLocationsCollectionsUpdateDataConnectorCall { + c.urlParams_.Set("updateMask", updateMask) return c } // Fields allows partial responses to be retrieved. See // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more // details. -func (c *ProjectsLocationsCmekConfigsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsCmekConfigsGetCall { +func (c *ProjectsLocationsCollectionsUpdateDataConnectorCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsUpdateDataConnectorCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// IfNoneMatch sets an optional parameter which makes the operation fail if the -// object's ETag matches the given value. This is useful for getting updates -// only after the object has changed since the last request. -func (c *ProjectsLocationsCmekConfigsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsCmekConfigsGetCall { - c.ifNoneMatch_ = entityTag - return c -} - // Context sets the context to be used in this call's Do method. -func (c *ProjectsLocationsCmekConfigsGetCall) Context(ctx context.Context) *ProjectsLocationsCmekConfigsGetCall { +func (c *ProjectsLocationsCollectionsUpdateDataConnectorCall) Context(ctx context.Context) *ProjectsLocationsCollectionsUpdateDataConnectorCall { c.ctx_ = ctx return c } // Header returns a http.Header that can be modified by the caller to add // headers to the request. -func (c *ProjectsLocationsCmekConfigsGetCall) Header() http.Header { +func (c *ProjectsLocationsCollectionsUpdateDataConnectorCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsCmekConfigsGetCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) - if c.ifNoneMatch_ != "" { - reqHeaders.Set("If-None-Match", c.ifNoneMatch_) +func (c *ProjectsLocationsCollectionsUpdateDataConnectorCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) + body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.googleclouddiscoveryenginev1alphadataconnector) + if err != nil { + return nil, err } c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+name}") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("GET", urls, nil) + req, err := http.NewRequest("PATCH", urls, body) if err != nil { return nil, err } @@ -22017,17 +24695,17 @@ func (c *ProjectsLocationsCmekConfigsGetCall) doRequest(alt string) (*http.Respo googleapi.Expand(req.URL, map[string]string{ "name": c.name, }) - c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "discoveryengine.projects.locations.cmekConfigs.get", "request", internallog.HTTPRequest(req, nil)) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "discoveryengine.projects.locations.collections.updateDataConnector", "request", internallog.HTTPRequest(req, body.Bytes())) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "discoveryengine.projects.locations.cmekConfigs.get" call. +// Do executes the "discoveryengine.projects.locations.collections.updateDataConnector" call. // Any non-2xx status code is an error. Response headers are in either -// *GoogleCloudDiscoveryengineV1alphaCmekConfig.ServerResponse.Header or (if a -// response was returned at all) in error.(*googleapi.Error).Header. Use +// *GoogleCloudDiscoveryengineV1alphaDataConnector.ServerResponse.Header or (if +// a response was returned at all) in error.(*googleapi.Error).Header. Use // googleapi.IsNotModified to check whether the returned error was because // http.StatusNotModified was returned. -func (c *ProjectsLocationsCmekConfigsGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1alphaCmekConfig, error) { +func (c *ProjectsLocationsCollectionsUpdateDataConnectorCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1alphaDataConnector, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -22046,7 +24724,7 @@ func (c *ProjectsLocationsCmekConfigsGetCall) Do(opts ...googleapi.CallOption) ( if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &GoogleCloudDiscoveryengineV1alphaCmekConfig{ + ret := &GoogleCloudDiscoveryengineV1alphaDataConnector{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -22057,72 +24735,68 @@ func (c *ProjectsLocationsCmekConfigsGetCall) Do(opts ...googleapi.CallOption) ( if err != nil { return nil, err } - c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "discoveryengine.projects.locations.cmekConfigs.get", "response", internallog.HTTPResponse(res, b)) + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "discoveryengine.projects.locations.collections.updateDataConnector", "response", internallog.HTTPResponse(res, b)) return ret, nil } -type ProjectsLocationsCmekConfigsListCall struct { - s *Service - parent string - urlParams_ gensupport.URLParams - ifNoneMatch_ string - ctx_ context.Context - header_ http.Header +type ProjectsLocationsCollectionsDataConnectorStartConnectorRunCall struct { + s *Service + parent string + googleclouddiscoveryenginev1alphastartconnectorrunrequest *GoogleCloudDiscoveryengineV1alphaStartConnectorRunRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// List: Lists all the CmekConfigs with the project. +// StartConnectorRun: Starts an immediate synchronization process for a +// DataConnector. Third Party Connector Users must specify which entities +// should be synced. FHIR Connectors must provide a timestamp to indicate the +// point in time from which data should be synced. // -// - parent: The parent location resource name, such as -// `projects/{project}/locations/{location}`. If the caller does not have -// permission to list CmekConfigs under this location, regardless of whether -// or not a CmekConfig exists, a PERMISSION_DENIED error is returned. -func (r *ProjectsLocationsCmekConfigsService) List(parent string) *ProjectsLocationsCmekConfigsListCall { - c := &ProjectsLocationsCmekConfigsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// - parent: Connector name of the form +// projects/{project}/locations/{location}/collections/ +// {collection_id}/dataConnector. +func (r *ProjectsLocationsCollectionsDataConnectorService) StartConnectorRun(parent string, googleclouddiscoveryenginev1alphastartconnectorrunrequest *GoogleCloudDiscoveryengineV1alphaStartConnectorRunRequest) *ProjectsLocationsCollectionsDataConnectorStartConnectorRunCall { + c := &ProjectsLocationsCollectionsDataConnectorStartConnectorRunCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.parent = parent + c.googleclouddiscoveryenginev1alphastartconnectorrunrequest = googleclouddiscoveryenginev1alphastartconnectorrunrequest return c } // Fields allows partial responses to be retrieved. See // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more // details. -func (c *ProjectsLocationsCmekConfigsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsCmekConfigsListCall { +func (c *ProjectsLocationsCollectionsDataConnectorStartConnectorRunCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataConnectorStartConnectorRunCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// IfNoneMatch sets an optional parameter which makes the operation fail if the -// object's ETag matches the given value. This is useful for getting updates -// only after the object has changed since the last request. -func (c *ProjectsLocationsCmekConfigsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsCmekConfigsListCall { - c.ifNoneMatch_ = entityTag - return c -} - // Context sets the context to be used in this call's Do method. -func (c *ProjectsLocationsCmekConfigsListCall) Context(ctx context.Context) *ProjectsLocationsCmekConfigsListCall { +func (c *ProjectsLocationsCollectionsDataConnectorStartConnectorRunCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataConnectorStartConnectorRunCall { c.ctx_ = ctx return c } // Header returns a http.Header that can be modified by the caller to add // headers to the request. -func (c *ProjectsLocationsCmekConfigsListCall) Header() http.Header { +func (c *ProjectsLocationsCollectionsDataConnectorStartConnectorRunCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsCmekConfigsListCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) - if c.ifNoneMatch_ != "" { - reqHeaders.Set("If-None-Match", c.ifNoneMatch_) +func (c *ProjectsLocationsCollectionsDataConnectorStartConnectorRunCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) + body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.googleclouddiscoveryenginev1alphastartconnectorrunrequest) + if err != nil { + return nil, err } c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+parent}/cmekConfigs") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+parent}:startConnectorRun") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("GET", urls, nil) + req, err := http.NewRequest("POST", urls, body) if err != nil { return nil, err } @@ -22130,17 +24804,17 @@ func (c *ProjectsLocationsCmekConfigsListCall) doRequest(alt string) (*http.Resp googleapi.Expand(req.URL, map[string]string{ "parent": c.parent, }) - c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "discoveryengine.projects.locations.cmekConfigs.list", "request", internallog.HTTPRequest(req, nil)) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "discoveryengine.projects.locations.collections.dataConnector.startConnectorRun", "request", internallog.HTTPRequest(req, body.Bytes())) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "discoveryengine.projects.locations.cmekConfigs.list" call. +// Do executes the "discoveryengine.projects.locations.collections.dataConnector.startConnectorRun" call. // Any non-2xx status code is an error. Response headers are in either -// *GoogleCloudDiscoveryengineV1alphaListCmekConfigsResponse.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 *ProjectsLocationsCmekConfigsListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1alphaListCmekConfigsResponse, error) { +// *GoogleCloudDiscoveryengineV1alphaConnectorRun.ServerResponse.Header or (if +// a response was returned at all) in error.(*googleapi.Error).Header. Use +// googleapi.IsNotModified to check whether the returned error was because +// http.StatusNotModified was returned. +func (c *ProjectsLocationsCollectionsDataConnectorStartConnectorRunCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1alphaConnectorRun, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -22159,7 +24833,7 @@ func (c *ProjectsLocationsCmekConfigsListCall) Do(opts ...googleapi.CallOption) if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &GoogleCloudDiscoveryengineV1alphaListCmekConfigsResponse{ + ret := &GoogleCloudDiscoveryengineV1alphaConnectorRun{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -22170,93 +24844,109 @@ func (c *ProjectsLocationsCmekConfigsListCall) Do(opts ...googleapi.CallOption) if err != nil { return nil, err } - c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "discoveryengine.projects.locations.cmekConfigs.list", "response", internallog.HTTPResponse(res, b)) + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "discoveryengine.projects.locations.collections.dataConnector.startConnectorRun", "response", internallog.HTTPResponse(res, b)) return ret, nil } -type ProjectsLocationsCmekConfigsPatchCall struct { - s *Service - name string - googleclouddiscoveryenginev1alphacmekconfig *GoogleCloudDiscoveryengineV1alphaCmekConfig - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +type ProjectsLocationsCollectionsDataConnectorConnectorRunsListCall struct { + s *Service + parent string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header } -// Patch: Provisions a CMEK key for use in a location of a customer's project. -// This method will also conduct location validation on the provided cmekConfig -// to make sure the key is valid and can be used in the selected location. +// List: Lists the ConnectorRuns of a DataConnector. // -// - name: Name of the CmekConfig, of the form -// `projects/{project}/locations/{location}/cmekConfig` or -// `projects/{project}/locations/{location}/cmekConfigs/{cmekConfig}`. -func (r *ProjectsLocationsCmekConfigsService) Patch(name string, googleclouddiscoveryenginev1alphacmekconfig *GoogleCloudDiscoveryengineV1alphaCmekConfig) *ProjectsLocationsCmekConfigsPatchCall { - c := &ProjectsLocationsCmekConfigsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.name = name - c.googleclouddiscoveryenginev1alphacmekconfig = googleclouddiscoveryenginev1alphacmekconfig +// - parent: The parent DataConnector resource name, such as +// `projects/{project}/locations/{location}/collections/{collection_id}/dataCo +// nnector`. If the caller does not have permission to list ConnectorRuns +// under this DataConnector, regardless of whether or not this DataConnector +// exists, a PERMISSION_DENIED error is returned. +func (r *ProjectsLocationsCollectionsDataConnectorConnectorRunsService) List(parent string) *ProjectsLocationsCollectionsDataConnectorConnectorRunsListCall { + c := &ProjectsLocationsCollectionsDataConnectorConnectorRunsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent return c } -// SetDefault sets the optional parameter "setDefault": Set the following -// CmekConfig as the default to be used for child resources if one is not -// specified. -func (c *ProjectsLocationsCmekConfigsPatchCall) SetDefault(setDefault bool) *ProjectsLocationsCmekConfigsPatchCall { - c.urlParams_.Set("setDefault", fmt.Sprint(setDefault)) +// PageSize sets the optional parameter "pageSize": Requested page size. Server +// may return fewer items than requested. If unspecified, defaults to 10. The +// maximum value is 50; values above 50 will be coerced to 50. If this field is +// negative, an INVALID_ARGUMENT error is returned. +func (c *ProjectsLocationsCollectionsDataConnectorConnectorRunsListCall) PageSize(pageSize int64) *ProjectsLocationsCollectionsDataConnectorConnectorRunsListCall { + c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) + return c +} + +// PageToken sets the optional parameter "pageToken": A page token, received +// from a previous `ListConnectorRuns` call. Provide this to retrieve the +// subsequent page. When paginating, all other parameters provided to +// `ListConnectorRuns` must match the call that provided the page token. +func (c *ProjectsLocationsCollectionsDataConnectorConnectorRunsListCall) PageToken(pageToken string) *ProjectsLocationsCollectionsDataConnectorConnectorRunsListCall { + c.urlParams_.Set("pageToken", pageToken) return c } // Fields allows partial responses to be retrieved. See // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more // details. -func (c *ProjectsLocationsCmekConfigsPatchCall) Fields(s ...googleapi.Field) *ProjectsLocationsCmekConfigsPatchCall { +func (c *ProjectsLocationsCollectionsDataConnectorConnectorRunsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataConnectorConnectorRunsListCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } +// IfNoneMatch sets an optional parameter which makes the operation fail if the +// object's ETag matches the given value. This is useful for getting updates +// only after the object has changed since the last request. +func (c *ProjectsLocationsCollectionsDataConnectorConnectorRunsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsCollectionsDataConnectorConnectorRunsListCall { + c.ifNoneMatch_ = entityTag + return c +} + // Context sets the context to be used in this call's Do method. -func (c *ProjectsLocationsCmekConfigsPatchCall) Context(ctx context.Context) *ProjectsLocationsCmekConfigsPatchCall { +func (c *ProjectsLocationsCollectionsDataConnectorConnectorRunsListCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataConnectorConnectorRunsListCall { c.ctx_ = ctx return c } // Header returns a http.Header that can be modified by the caller to add // headers to the request. -func (c *ProjectsLocationsCmekConfigsPatchCall) Header() http.Header { +func (c *ProjectsLocationsCollectionsDataConnectorConnectorRunsListCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsCmekConfigsPatchCall) doRequest(alt string) (*http.Response, error) { - reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) - body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.googleclouddiscoveryenginev1alphacmekconfig) - if err != nil { - return nil, err +func (c *ProjectsLocationsCollectionsDataConnectorConnectorRunsListCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) } c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+name}") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+parent}/connectorRuns") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("PATCH", urls, body) + req, err := http.NewRequest("GET", urls, nil) if err != nil { return nil, err } req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ - "name": c.name, + "parent": c.parent, }) - c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "discoveryengine.projects.locations.cmekConfigs.patch", "request", internallog.HTTPRequest(req, body.Bytes())) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "discoveryengine.projects.locations.collections.dataConnector.connectorRuns.list", "request", internallog.HTTPRequest(req, nil)) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "discoveryengine.projects.locations.cmekConfigs.patch" call. +// Do executes the "discoveryengine.projects.locations.collections.dataConnector.connectorRuns.list" call. // Any non-2xx status code is an error. Response headers are in either -// *GoogleLongrunningOperation.ServerResponse.Header or (if a response was -// returned at all) in error.(*googleapi.Error).Header. Use -// googleapi.IsNotModified to check whether the returned error was because -// http.StatusNotModified was returned. -func (c *ProjectsLocationsCmekConfigsPatchCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { +// *GoogleCloudDiscoveryengineV1alphaListConnectorRunsResponse.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 *ProjectsLocationsCollectionsDataConnectorConnectorRunsListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1alphaListConnectorRunsResponse, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -22275,7 +24965,7 @@ func (c *ProjectsLocationsCmekConfigsPatchCall) Do(opts ...googleapi.CallOption) if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &GoogleLongrunningOperation{ + ret := &GoogleCloudDiscoveryengineV1alphaListConnectorRunsResponse{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -22286,10 +24976,31 @@ func (c *ProjectsLocationsCmekConfigsPatchCall) Do(opts ...googleapi.CallOption) if err != nil { return nil, err } - c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "discoveryengine.projects.locations.cmekConfigs.patch", "response", internallog.HTTPResponse(res, b)) + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "discoveryengine.projects.locations.collections.dataConnector.connectorRuns.list", "response", internallog.HTTPResponse(res, b)) return ret, nil } +// Pages invokes f for each page of results. +// A non-nil error returned from f will halt the iteration. +// The provided context supersedes any context provided to the Context method. +func (c *ProjectsLocationsCollectionsDataConnectorConnectorRunsListCall) Pages(ctx context.Context, f func(*GoogleCloudDiscoveryengineV1alphaListConnectorRunsResponse) error) error { + c.ctx_ = ctx + defer c.PageToken(c.urlParams_.Get("pageToken")) + for { + x, err := c.Do() + if err != nil { + return err + } + if err := f(x); err != nil { + return err + } + if x.NextPageToken == "" { + return nil + } + c.PageToken(x.NextPageToken) + } +} + type ProjectsLocationsCollectionsDataConnectorOperationsGetCall struct { s *Service name string diff --git a/discoveryengine/v1beta/discoveryengine-api.json b/discoveryengine/v1beta/discoveryengine-api.json index d66a16f6ce..c6545fdd4f 100644 --- a/discoveryengine/v1beta/discoveryengine-api.json +++ b/discoveryengine/v1beta/discoveryengine-api.json @@ -160,6 +160,36 @@ }, "resources": { "locations": { + "methods": { + "generateGroundedContent": { + "description": "Generates grounded content.", + "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}:generateGroundedContent", + "httpMethod": "POST", + "id": "discoveryengine.projects.locations.generateGroundedContent", + "parameterOrder": [ + "location" + ], + "parameters": { + "location": { + "description": "Required. Location resource. Format: `projects/{project}/locations/{location}`.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1beta/{+location}:generateGroundedContent", + "request": { + "$ref": "GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequest" + }, + "response": { + "$ref": "GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + } + }, "resources": { "collections": { "resources": { @@ -7354,7 +7384,7 @@ } } }, - "revision": "20241210", + "revision": "20241216", "rootUrl": "https://discoveryengine.googleapis.com/", "schemas": { "GoogleApiDistribution": { @@ -7793,6 +7823,13 @@ "description": "Required. Name of the CmekConfig, of the form `projects/{project}/locations/{location}/cmekConfig` or `projects/{project}/locations/{location}/cmekConfigs/{cmekConfig}`.", "type": "string" }, + "singleRegionKeys": { + "description": "Optional. Single-regional CMEKs that are required for some VAIS features.", + "items": { + "$ref": "GoogleCloudDiscoveryengineV1SingleRegionKey" + }, + "type": "array" + }, "state": { "description": "Output only. State of the CmekConfig.", "enum": [ @@ -8175,6 +8212,10 @@ ], "type": "string" }, + "isInfobotFaqDataStore": { + "description": "Optional. If set, this DataStore is an Infobot FAQ DataStore.", + "type": "boolean" + }, "kmsKeyName": { "description": "Input only. The KMS key to be used to protect this DataStore at creation time. Must be set for requests that need to comply with CMEK Org Policy protections. If this field is set and processed successfully, the DataStore will be protected by the KMS key, as indicated in the cmek_config field.", "type": "string" @@ -9469,6 +9510,17 @@ }, "type": "object" }, + "GoogleCloudDiscoveryengineV1SingleRegionKey": { + "description": "Metadata for single-regional CMEKs.", + "id": "GoogleCloudDiscoveryengineV1SingleRegionKey", + "properties": { + "kmsKey": { + "description": "Required. Single-regional kms key resource name which will be used to encrypt resources `projects/{project}/locations/{location}/keyRings/{keyRing}/cryptoKeys/{keyId}`.", + "type": "string" + } + }, + "type": "object" + }, "GoogleCloudDiscoveryengineV1SiteVerificationInfo": { "description": "Verification information for target sites in advanced site search.", "id": "GoogleCloudDiscoveryengineV1SiteVerificationInfo", @@ -9759,6 +9811,26 @@ }, "type": "object" }, + "GoogleCloudDiscoveryengineV1alphaActionConfig": { + "description": "Informations to support actions on the connector.", + "id": "GoogleCloudDiscoveryengineV1alphaActionConfig", + "properties": { + "actionParams": { + "additionalProperties": { + "description": "Properties of the object.", + "type": "any" + }, + "description": "Required. Params needed to support actions in the format of (Key, Value) pairs. Required parameters for sources that support OAUTH, i.e. `gmail`, `google_calendar`, `jira`, `workday`, `salesforce`, `confluence`: * Key: `client_id` * Value: type STRING. The client id for the service provider to identify your application. * Key: `client_secret` * Value:type STRING. The client secret generated by the application's authorization server.", + "type": "object" + }, + "isActionConfigured": { + "description": "Output only. The connector contains the necessary parameters and is configured to support actions.", + "readOnly": true, + "type": "boolean" + } + }, + "type": "object" + }, "GoogleCloudDiscoveryengineV1alphaAdvancedSiteSearchConfig": { "description": "Configuration data for advance site search.", "id": "GoogleCloudDiscoveryengineV1alphaAdvancedSiteSearchConfig", @@ -10363,6 +10435,13 @@ "description": "Required. Name of the CmekConfig, of the form `projects/{project}/locations/{location}/cmekConfig` or `projects/{project}/locations/{location}/cmekConfigs/{cmekConfig}`.", "type": "string" }, + "singleRegionKeys": { + "description": "Optional. Single-regional CMEKs that are required for some VAIS features.", + "items": { + "$ref": "GoogleCloudDiscoveryengineV1alphaSingleRegionKey" + }, + "type": "array" + }, "state": { "description": "Output only. State of the CmekConfig.", "enum": [ @@ -10389,6 +10468,32 @@ }, "type": "object" }, + "GoogleCloudDiscoveryengineV1alphaCollection": { + "description": "Collection is a container for configuring resources and access to a set of DataStores.", + "id": "GoogleCloudDiscoveryengineV1alphaCollection", + "properties": { + "createTime": { + "description": "Output only. Timestamp the Collection was created at.", + "format": "google-datetime", + "readOnly": true, + "type": "string" + }, + "dataConnector": { + "$ref": "GoogleCloudDiscoveryengineV1alphaDataConnector", + "description": "Output only. The data connector, if present, manages the connection for data stores in the Collection. To set up the connector, use DataConnectorService.SetUpDataConnector method, which creates a new Collection while setting up the DataConnector singleton resource. Setting up connector on an existing Collection is not supported. This output only field contains a subset of the DataConnector fields, including `name`, `data_source`, `entities.entity_name` and `entities.data_store`. To get more details about a data connector, use the DataConnector.GetDataConnector method.", + "readOnly": true + }, + "displayName": { + "description": "Required. The Collection 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" + }, + "name": { + "description": "Immutable. The full resource name of the Collection. Format: `projects/{project}/locations/{location}/collections/{collection_id}`. This field must be a UTF-8 encoded string with a length limit of 1024 characters.", + "type": "string" + } + }, + "type": "object" + }, "GoogleCloudDiscoveryengineV1alphaCondition": { "description": "Defines circumstances to be checked before allowing a behavior", "id": "GoogleCloudDiscoveryengineV1alphaCondition", @@ -10446,6 +10551,186 @@ }, "type": "object" }, + "GoogleCloudDiscoveryengineV1alphaConnectorRun": { + "description": "A data sync run of DataConnector. After DataConnector is successfully initialized, data syncs are scheduled at DataConnector.refresh_interval. A ConnectorRun represents a data sync either in the past or onging that the moment. //", + "id": "GoogleCloudDiscoveryengineV1alphaConnectorRun", + "properties": { + "endTime": { + "description": "Output only. The time when the connector run ended.", + "format": "google-datetime", + "readOnly": true, + "type": "string" + }, + "entityRuns": { + "description": "Output only. The details of the entities synced at the ConnectorRun. Each ConnectorRun consists of syncing one or more entities.", + "items": { + "$ref": "GoogleCloudDiscoveryengineV1alphaConnectorRunEntityRun" + }, + "readOnly": true, + "type": "array" + }, + "errors": { + "description": "Contains info about errors incurred during the sync. Only exist if running into an error state. Contains error code and error message. Use with the `state` field.", + "items": { + "$ref": "GoogleRpcStatus" + }, + "type": "array" + }, + "latestPauseTime": { + "description": "Output only. The time when the connector run was most recently paused.", + "format": "google-datetime", + "readOnly": true, + "type": "string" + }, + "name": { + "description": "Output only. The full resource name of the Connector Run. Format: `projects/*/locations/*/collections/*/dataConnector/connectorRuns/*`. The `connector_run_id` is system-generated.", + "readOnly": true, + "type": "string" + }, + "startTime": { + "description": "Output only. The time when the connector run started.", + "format": "google-datetime", + "readOnly": true, + "type": "string" + }, + "state": { + "description": "Output only. The state of the sync run.", + "enum": [ + "STATE_UNSPECIFIED", + "RUNNING", + "SUCCEEDED", + "FAILED", + "OVERRUN", + "CANCELLED", + "PENDING", + "WARNING" + ], + "enumDescriptions": [ + "Default value.", + "The data sync is ongoing.", + "The data sync is finished.", + "The data sync is failed.", + "Data sync has been running longer than expected and is still running at the time the next run is supposed to start.", + "Data sync was scheduled but has been cancelled.", + "Data sync is about to start.", + "The data sync completed with non-fatal errors." + ], + "readOnly": true, + "type": "string" + }, + "stateUpdateTime": { + "description": "Timestamp at which the connector run sync state was last updated.", + "format": "google-datetime", + "type": "string" + }, + "trigger": { + "description": "Output only. The trigger for this ConnectorRun.", + "enum": [ + "TRIGGER_UNSPECIFIED", + "SCHEDULER", + "INITIALIZATION", + "RESUME", + "MANUAL" + ], + "enumDescriptions": [ + "Default value.", + "ConnectorRun triggered by scheduler if connector has PERIODIC sync mode.", + "ConnectorRun auto triggered by connector initialization.", + "ConnectorRun auto triggered by resuming connector.", + "ConnectorRun triggered by user manually." + ], + "readOnly": true, + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaConnectorRunEntityRun": { + "description": "Represents an entity that was synced in this ConnectorRun.", + "id": "GoogleCloudDiscoveryengineV1alphaConnectorRunEntityRun", + "properties": { + "entityName": { + "description": "The name of the source entity.", + "type": "string" + }, + "errorRecordCount": { + "description": "The total number of documents failed at sync at any stage (extraction, indexing, etc).", + "format": "int64", + "type": "string" + }, + "errors": { + "description": "The errors from the entity's sync run. Only exist if running into an error state. Contains error code and error message.", + "items": { + "$ref": "GoogleRpcStatus" + }, + "type": "array" + }, + "extractedRecordCount": { + "description": "The number of documents extracted from connector source, ready to be ingested to UCS.", + "format": "int64", + "type": "string" + }, + "indexedRecordCount": { + "description": "The number of documents indexed.", + "format": "int64", + "type": "string" + }, + "sourceApiRequestCount": { + "description": "The number of requests sent to 3p API.", + "format": "int64", + "type": "string" + }, + "state": { + "description": "The state of the entity's sync run.", + "enum": [ + "STATE_UNSPECIFIED", + "RUNNING", + "SUCCEEDED", + "FAILED", + "OVERRUN", + "CANCELLED", + "PENDING", + "WARNING" + ], + "enumDescriptions": [ + "Default value.", + "The data sync is ongoing.", + "The data sync is finished.", + "The data sync is failed.", + "Data sync has been running longer than expected and is still running at the time the next run is supposed to start.", + "Data sync was scheduled but has been cancelled.", + "Data sync is about to start.", + "The data sync completed with non-fatal errors." + ], + "type": "string" + }, + "stateUpdateTime": { + "description": "Timestamp at which the entity sync state was last updated.", + "format": "google-datetime", + "type": "string" + }, + "statsUpdateTime": { + "description": "The timestamp for either extracted_documents_count, indexed_documents_count and error_documents_count was last updated.", + "format": "google-datetime", + "type": "string" + }, + "syncType": { + "description": "Sync type of this run.", + "enum": [ + "SYNC_TYPE_UNSPECIFIED", + "FULL", + "INCREMENTAL" + ], + "enumDescriptions": [ + "Sync type unspecified.", + "Sync triggers full sync of all documents.", + "Incremental sync of updated documents." + ], + "type": "string" + } + }, + "type": "object" + }, "GoogleCloudDiscoveryengineV1alphaControl": { "description": "Defines a conditioned behavior to employ during serving. Must be attached to a ServingConfig to be considered at serving time. Permitted actions dependent on `SolutionType`.", "id": "GoogleCloudDiscoveryengineV1alphaControl", @@ -10719,72 +11004,270 @@ }, "type": "object" }, - "GoogleCloudDiscoveryengineV1alphaDataStore": { - "description": "DataStore captures global settings and configs at the DataStore level.", - "id": "GoogleCloudDiscoveryengineV1alphaDataStore", + "GoogleCloudDiscoveryengineV1alphaDataConnector": { + "description": "Manages the connection to external data sources for all data stores grouped under a Collection. It's a singleton resource of Collection. The initialization is only supported through SetUpDataConnector method, which will create a new Collection and initialize its DataConnector. //", + "id": "GoogleCloudDiscoveryengineV1alphaDataConnector", "properties": { - "aclEnabled": { - "description": "Immutable. Whether data in the DataStore has ACL information. If set to `true`, the source data must have ACL. ACL will be ingested when data is ingested by DocumentService.ImportDocuments methods. When ACL is enabled for the DataStore, Document can't be accessed by calling DocumentService.GetDocument or DocumentService.ListDocuments. Currently ACL is only supported in `GENERIC` industry vertical with non-`PUBLIC_WEBSITE` content config.", + "actionConfig": { + "$ref": "GoogleCloudDiscoveryengineV1alphaActionConfig", + "description": "Optional. Action configurations to make the connector support actions." + }, + "autoRunDisabled": { + "description": "Indicates whether the connector is disabled for auto run. It can be used to pause periodical and real time sync.", "type": "boolean" }, - "advancedSiteSearchConfig": { - "$ref": "GoogleCloudDiscoveryengineV1alphaAdvancedSiteSearchConfig", - "description": "Optional. Configuration for advanced site search." + "blockingReasons": { + "description": "Output only. User actions that must be completed before the connector can start syncing data.", + "items": { + "enum": [ + "BLOCKING_REASON_UNSPECIFIED", + "ALLOWLIST_STATIC_IP", + "ALLOWLIST_IN_SERVICE_ATTACHMENT" + ], + "enumDescriptions": [ + "Default value.", + "Connector requires customer to allowlist static IPs.", + "Connector requires customer to allowlist our project in their service attachment." + ], + "type": "string" + }, + "readOnly": true, + "type": "array" }, - "billingEstimation": { - "$ref": "GoogleCloudDiscoveryengineV1alphaDataStoreBillingEstimation", - "description": "Output only. Data size estimation for billing.", - "readOnly": true + "createTime": { + "description": "Output only. Timestamp the DataConnector was created at.", + "format": "google-datetime", + "readOnly": true, + "type": "string" }, - "cmekConfig": { - "$ref": "GoogleCloudDiscoveryengineV1alphaCmekConfig", - "description": "Output only. CMEK-related information for the DataStore.", - "readOnly": true + "dataSource": { + "description": "Required. The name of the data source. Supported values: `salesforce`, `jira`, `confluence`, `bigquery`.", + "type": "string" }, - "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", - "GOOGLE_WORKSPACE" - ], - "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.", - "The data store is used for workspace search. Details of workspace data store are specified in the WorkspaceConfig." - ], + "destinationConfigs": { + "description": "Optional. Any target destinations used to connect to third-party services.", + "items": { + "$ref": "GoogleCloudDiscoveryengineV1alphaDestinationConfig" + }, + "type": "array" + }, + "entities": { + "description": "List of entities from the connected data source to ingest.", + "items": { + "$ref": "GoogleCloudDiscoveryengineV1alphaDataConnectorSourceEntity" + }, + "type": "array" + }, + "errors": { + "description": "Output only. The errors from initialization or from the latest connector run.", + "items": { + "$ref": "GoogleRpcStatus" + }, + "readOnly": true, + "type": "array" + }, + "identityRefreshInterval": { + "deprecated": true, + "description": "The refresh interval to sync the Access Control List information for the documents ingested by this connector. If not set, the access control list will be refreshed at the default interval of 30 minutes. The identity refresh interval can be at least 30 minutes and at most 7 days.", + "format": "google-duration", "type": "string" }, - "createTime": { - "description": "Output only. Timestamp the DataStore was created at.", + "identityScheduleConfig": { + "$ref": "GoogleCloudDiscoveryengineV1alphaIdentityScheduleConfig", + "description": "The configuration for the identity data synchronization runs. This contains the refresh interval to sync the Access Control List information for the documents ingested by this connector." + }, + "kmsKeyName": { + "description": "Input only. The KMS key to be used to protect the DataStores managed by this connector. Must be set for requests that need to comply with CMEK Org Policy protections. If this field is set and processed successfully, the DataStores created by this connector will be protected by the KMS key.", + "type": "string" + }, + "lastSyncTime": { + "description": "Output only. For periodic connectors only, the last time a data sync was completed.", "format": "google-datetime", "readOnly": true, "type": "string" }, - "defaultSchemaId": { - "description": "Output only. The id of the default Schema asscociated to this data store.", + "latestPauseTime": { + "description": "Output only. The most recent timestamp when this DataConnector was paused, affecting all functionalities such as data synchronization. Pausing a connector has the following effects: - All functionalities, including data synchronization, are halted. - Any ongoing data synchronization job will be canceled. - No future data synchronization runs will be scheduled nor can be triggered.", + "format": "google-datetime", "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 full resource name of the Data Connector. Format: `projects/*/locations/*/collections/*/dataConnector`.", + "readOnly": true, "type": "string" }, - "documentProcessingConfig": { - "$ref": "GoogleCloudDiscoveryengineV1alphaDocumentProcessingConfig", - "description": "Configuration for Document understanding and enrichment." - }, - "idpConfig": { - "$ref": "GoogleCloudDiscoveryengineV1alphaIdpConfig", - "description": "Output only. Data store level identity provider config.", - "readOnly": true + "nextSyncTime": { + "$ref": "GoogleTypeDateTime", + "description": "The UTC time when the next data sync is expected to start for the Data Connector. Customers are only able to specify the hour and minute to schedule the data sync. This is utilized when the data connector has a refresh interval greater than 1 day." }, - "industryVertical": { - "description": "Immutable. The industry vertical that the data store registers.", + "params": { + "additionalProperties": { + "description": "Properties of the object.", + "type": "any" + }, + "description": "Required. Params needed to access the source in the format of (Key, Value) pairs. Required parameters for all data sources: * Key: `instance_uri` * Value: type STRING. The uri to access the data source. Required parameters for sources that support OAUTH, i.e. `salesforce`: * Key: `client_id` * Value: type STRING. The client id for the third party service provider to identify your application. * Key: `client_secret` * Value:type STRING. The client secret generated by the third party authorization server. * Key: `access_token` * Value: type STRING. OAuth token for UCS to access to the protected resource. * Key: `refresh_token` * Value: type STRING. OAuth refresh token for UCS to obtain a new access token without user interaction. Required parameters for sources that support basic API token auth, i.e. `jira`, `confluence`: * Key: `user_account` * Value: type STRING. The username or email with the source. * Key: `api_token` * Value: type STRING. The API token generated for the source account, that is used for authenticating anywhere where you would have used a password. Example: ```json { \"instance_uri\": \"https://xxx.atlassian.net\", \"user_account\": \"xxxx.xxx@xxx.com\", \"api_token\": \"test-token\" } ``` Optional parameter to specify the authorization type to use for multiple authorization types support: * Key: `auth_type` * Value: type STRING. The authorization type for the data source. Supported values: `BASIC_AUTH`, `OAUTH`, `OAUTH_ACCESS_TOKEN`, `OAUTH_TWO_LEGGED`, `OAUTH_JWT_BEARER`, `OAUTH_PASSWORD_GRANT`, `JWT`, `API_TOKEN`, `FEDERATED_CREDENTIAL`.", + "type": "object" + }, + "privateConnectivityProjectId": { + "description": "Output only. The tenant project ID associated with private connectivity connectors. This project must be allowlisted by in order for the connector to function.", + "readOnly": true, + "type": "string" + }, + "refreshInterval": { + "description": "Required. The refresh interval for data sync. If duration is set to 0, the data will be synced in real time. The streaming feature is not supported yet. The minimum is 30 minutes and maximum is 7 days.", + "format": "google-duration", + "type": "string" + }, + "state": { + "description": "Output only. State of the connector.", + "enum": [ + "STATE_UNSPECIFIED", + "CREATING", + "ACTIVE", + "FAILED", + "RUNNING", + "WARNING" + ], + "enumDescriptions": [ + "Default value.", + "The connector is being set up.", + "The connector is successfully set up and awaiting next sync run.", + "The connector is in error. The error details can be found in DataConnector.errors. If the error is unfixable, the DataConnector can be deleted by [CollectionService.DeleteCollection] API.", + "The connector is actively syncing records from the data source.", + "The connector has completed a sync run, but encountered non-fatal errors." + ], + "readOnly": true, + "type": "string" + }, + "staticIpAddresses": { + "description": "Output only. The static IP addresses used by this connector.", + "items": { + "type": "string" + }, + "readOnly": true, + "type": "array" + }, + "staticIpEnabled": { + "description": "Optional. Whether customer has enabled static IP addresses for this connector.", + "type": "boolean" + }, + "syncMode": { + "description": "The data synchronization mode supported by the data connector.", + "enum": [ + "PERIODIC" + ], + "enumDescriptions": [ + "The connector will sync data periodically based on the refresh_interval. Use it with auto_run_disabled to pause the periodic sync, or indicate a one-time sync." + ], + "type": "string" + }, + "updateTime": { + "description": "Output only. Timestamp the DataConnector was last updated.", + "format": "google-datetime", + "readOnly": true, + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaDataConnectorSourceEntity": { + "description": "Represents an entity in the data source. For example, the `Account` object in Salesforce.", + "id": "GoogleCloudDiscoveryengineV1alphaDataConnectorSourceEntity", + "properties": { + "dataStore": { + "description": "Output only. The full resource name of the associated data store for the source entity. Format: `projects/*/locations/*/collections/*/dataStores/*`. When the connector is initialized by the DataConnectorService.SetUpDataConnector method, a DataStore is automatically created for each source entity.", + "readOnly": true, + "type": "string" + }, + "entityName": { + "description": "The name of the entity. Supported values by data source: * Salesforce: `Lead`, `Opportunity`, `Contact`, `Account`, `Case`, `Contract`, `Campaign` * Jira: `Issue` * Confluence: `Content`, `Space`", + "type": "string" + }, + "keyPropertyMappings": { + "additionalProperties": { + "type": "string" + }, + "description": "Attributes for indexing. Key: Field name. Value: The key property to map a field to, such as `title`, and `description`. Supported key properties: * `title`: The title for data record. This would be displayed on search results. * `description`: The description for data record. This would be displayed on search results.", + "type": "object" + }, + "params": { + "additionalProperties": { + "description": "Properties of the object.", + "type": "any" + }, + "description": "The parameters for the entity to facilitate data ingestion. E.g. for BQ connectors: * Key: `document_id_column` * Value: type STRING. The value of the column id.", + "type": "object" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaDataStore": { + "description": "DataStore captures global settings and configs at the DataStore level.", + "id": "GoogleCloudDiscoveryengineV1alphaDataStore", + "properties": { + "aclEnabled": { + "description": "Immutable. Whether data in the DataStore has ACL information. If set to `true`, the source data must have ACL. ACL will be ingested when data is ingested by DocumentService.ImportDocuments methods. When ACL is enabled for the DataStore, Document can't be accessed by calling DocumentService.GetDocument or DocumentService.ListDocuments. Currently ACL is only supported in `GENERIC` industry vertical with non-`PUBLIC_WEBSITE` content config.", + "type": "boolean" + }, + "advancedSiteSearchConfig": { + "$ref": "GoogleCloudDiscoveryengineV1alphaAdvancedSiteSearchConfig", + "description": "Optional. Configuration for advanced site search." + }, + "billingEstimation": { + "$ref": "GoogleCloudDiscoveryengineV1alphaDataStoreBillingEstimation", + "description": "Output only. Data size estimation for billing.", + "readOnly": true + }, + "cmekConfig": { + "$ref": "GoogleCloudDiscoveryengineV1alphaCmekConfig", + "description": "Output only. CMEK-related information for the DataStore.", + "readOnly": true + }, + "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", + "GOOGLE_WORKSPACE" + ], + "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.", + "The data store is used for workspace search. Details of workspace data store are specified in the WorkspaceConfig." + ], + "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" + }, + "documentProcessingConfig": { + "$ref": "GoogleCloudDiscoveryengineV1alphaDocumentProcessingConfig", + "description": "Configuration for Document understanding and enrichment." + }, + "idpConfig": { + "$ref": "GoogleCloudDiscoveryengineV1alphaIdpConfig", + "description": "Output only. Data store level identity provider config.", + "readOnly": true + }, + "industryVertical": { + "description": "Immutable. The industry vertical that the data store registers.", "enum": [ "INDUSTRY_VERTICAL_UNSPECIFIED", "GENERIC", @@ -10799,6 +11282,10 @@ ], "type": "string" }, + "isInfobotFaqDataStore": { + "description": "Optional. If set, this DataStore is an Infobot FAQ DataStore.", + "type": "boolean" + }, "kmsKeyName": { "description": "Input only. The KMS key to be used to protect this DataStore at creation time. Must be set for requests that need to comply with CMEK Org Policy protections. If this field is set and processed successfully, the DataStore will be protected by the KMS key, as indicated in the cmek_config field.", "type": "string" @@ -10914,6 +11401,23 @@ }, "type": "object" }, + "GoogleCloudDiscoveryengineV1alphaDeleteCollectionMetadata": { + "description": "Metadata related to the progress of the CollectionService.UpdateCollection operation. This will be returned by the google.longrunning.Operation.metadata field.", + "id": "GoogleCloudDiscoveryengineV1alphaDeleteCollectionMetadata", + "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" + }, "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", @@ -11010,6 +11514,48 @@ }, "type": "object" }, + "GoogleCloudDiscoveryengineV1alphaDestinationConfig": { + "description": "Defines target endpoints used to connect to third-party sources.", + "id": "GoogleCloudDiscoveryengineV1alphaDestinationConfig", + "properties": { + "destinations": { + "description": "Optional. The destinations for the corresponding key.", + "items": { + "$ref": "GoogleCloudDiscoveryengineV1alphaDestinationConfigDestination" + }, + "type": "array" + }, + "key": { + "description": "Optional. Unique destination identifier that is supported by the connector.", + "type": "string" + }, + "params": { + "additionalProperties": { + "description": "Properties of the object.", + "type": "any" + }, + "description": "Optional. Additional parameters for this destination config.", + "type": "object" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaDestinationConfigDestination": { + "description": "Defines a target endpoint", + "id": "GoogleCloudDiscoveryengineV1alphaDestinationConfigDestination", + "properties": { + "host": { + "description": "Publicly routable host.", + "type": "string" + }, + "port": { + "description": "Optional. Target port number accepted by the destination.", + "format": "int32", + "type": "integer" + } + }, + "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", @@ -11796,6 +12342,18 @@ }, "type": "object" }, + "GoogleCloudDiscoveryengineV1alphaIdentityScheduleConfig": { + "description": "The configuration for the identity data synchronization runs.", + "id": "GoogleCloudDiscoveryengineV1alphaIdentityScheduleConfig", + "properties": { + "refreshInterval": { + "description": "Optional. The refresh interval to sync the Access Control List information for the documents ingested by this connector. If not set, the access control list will be refreshed at the default interval of 30 minutes. The identity refresh interval can be at least 30 minutes and at most 7 days.", + "format": "google-duration", + "type": "string" + } + }, + "type": "object" + }, "GoogleCloudDiscoveryengineV1alphaIdpConfig": { "description": "Identity Provider Config.", "id": "GoogleCloudDiscoveryengineV1alphaIdpConfig", @@ -13527,6 +14085,12 @@ }, "type": "object" }, + "GoogleCloudDiscoveryengineV1alphaSetUpDataConnectorMetadata": { + "description": "Metadata for DataConnectorService.SetUpDataConnector method.", + "id": "GoogleCloudDiscoveryengineV1alphaSetUpDataConnectorMetadata", + "properties": {}, + "type": "object" + }, "GoogleCloudDiscoveryengineV1alphaSetUriPatternDocumentDataMetadata": { "description": "Metadata related to the progress of the SiteSearchEngineService.SetUriPatternDocumentData operation. This will be returned by the google.longrunning.Operation.metadata field.", "id": "GoogleCloudDiscoveryengineV1alphaSetUriPatternDocumentDataMetadata", @@ -13550,6 +14114,17 @@ "properties": {}, "type": "object" }, + "GoogleCloudDiscoveryengineV1alphaSingleRegionKey": { + "description": "Metadata for single-regional CMEKs.", + "id": "GoogleCloudDiscoveryengineV1alphaSingleRegionKey", + "properties": { + "kmsKey": { + "description": "Required. Single-regional kms key resource name which will be used to encrypt resources `projects/{project}/locations/{location}/keyRings/{keyRing}/cryptoKeys/{keyId}`.", + "type": "string" + } + }, + "type": "object" + }, "GoogleCloudDiscoveryengineV1alphaSiteVerificationInfo": { "description": "Verification information for target sites in advanced site search.", "id": "GoogleCloudDiscoveryengineV1alphaSiteVerificationInfo", @@ -13787,6 +14362,23 @@ }, "type": "object" }, + "GoogleCloudDiscoveryengineV1alphaUpdateCollectionMetadata": { + "description": "Metadata related to the progress of the CollectionService.UpdateCollection operation. This will be returned by the google.longrunning.Operation.metadata field.", + "id": "GoogleCloudDiscoveryengineV1alphaUpdateCollectionMetadata", + "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" + }, "GoogleCloudDiscoveryengineV1alphaUpdateSchemaMetadata": { "description": "Metadata for UpdateSchema LRO.", "id": "GoogleCloudDiscoveryengineV1alphaUpdateSchemaMetadata", @@ -15754,6 +16346,13 @@ "description": "Required. Name of the CmekConfig, of the form `projects/{project}/locations/{location}/cmekConfig` or `projects/{project}/locations/{location}/cmekConfigs/{cmekConfig}`.", "type": "string" }, + "singleRegionKeys": { + "description": "Optional. Single-regional CMEKs that are required for some VAIS features.", + "items": { + "$ref": "GoogleCloudDiscoveryengineV1betaSingleRegionKey" + }, + "type": "array" + }, "state": { "description": "Output only. State of the CmekConfig.", "enum": [ @@ -16514,6 +17113,10 @@ ], "type": "string" }, + "isInfobotFaqDataStore": { + "description": "Optional. If set, this DataStore is an Infobot FAQ DataStore.", + "type": "boolean" + }, "kmsKeyName": { "description": "Input only. The KMS key to be used to protect this DataStore at creation time. Must be set for requests that need to comply with CMEK Org Policy protections. If this field is set and processed successfully, the DataStore will be protected by the KMS key, as indicated in the cmek_config field.", "type": "string" @@ -16751,7 +17354,7 @@ }, "indexStatus": { "$ref": "GoogleCloudDiscoveryengineV1betaDocumentIndexStatus", - "description": "Output only. The index status of the document. * If document is indexed successfully, the index_time field is populated. * Otherwise, if document is not indexed due to errors, the error_samples field is populated. * Otherwise, index_status is unset.", + "description": "Output only. The index status of the document. * If document is indexed successfully, the index_time field is populated. * Otherwise, if document is not indexed due to errors, the error_samples field is populated. * Otherwise, if document's index is in progress, the pending_message field is populated.", "readOnly": true }, "indexTime": { @@ -16822,6 +17425,10 @@ "description": "The time when the document was indexed. If this field is populated, it means the document has been indexed.", "format": "google-datetime", "type": "string" + }, + "pendingMessage": { + "description": "Immutable. The message indicates the document index is in progress. If this field is populated, the document index is pending.", + "type": "string" } }, "type": "object" @@ -17442,6 +18049,424 @@ }, "type": "object" }, + "GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequest": { + "description": "Top-level message sent by the client for the `GenerateGroundedContent` method.", + "id": "GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequest", + "properties": { + "contents": { + "description": "Content of the current conversation with the model. For single-turn queries, this is a single instance. For multi-turn queries, this is a repeated field that contains conversation history + latest request.", + "items": { + "$ref": "GoogleCloudDiscoveryengineV1betaGroundedGenerationContent" + }, + "type": "array" + }, + "generationSpec": { + "$ref": "GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestGenerationSpec", + "description": "Content generation specification." + }, + "groundingSpec": { + "$ref": "GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestGroundingSpec", + "description": "Grounding specification." + }, + "systemInstruction": { + "$ref": "GoogleCloudDiscoveryengineV1betaGroundedGenerationContent", + "description": "Content of the system instruction for the current API. These instructions will take priority over any other prompt instructions if the selected model is supporting them." + }, + "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" + }, + "GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestDynamicRetrievalConfiguration": { + "description": "Describes the options to customize dynamic retrieval.", + "id": "GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestDynamicRetrievalConfiguration", + "properties": { + "predictor": { + "$ref": "GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestDynamicRetrievalConfigurationDynamicRetrievalPredictor", + "description": "Specification for the predictor for dynamic retrieval." + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestDynamicRetrievalConfigurationDynamicRetrievalPredictor": { + "description": "Describes the predictor settings for dynamic retrieval.", + "id": "GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestDynamicRetrievalConfigurationDynamicRetrievalPredictor", + "properties": { + "threshold": { + "description": "The value of the threshold. If the predictor will predict a value smaller than this, it would suppress grounding in the source.", + "format": "float", + "type": "number" + }, + "version": { + "description": "The version of the predictor to be used in dynamic retrieval.", + "enum": [ + "VERSION_UNSPECIFIED", + "V1_INDEPENDENT" + ], + "enumDescriptions": [ + "Automatically choose the best version of the retrieval predictor.", + "The V1 model which is evaluating each source independently." + ], + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestGenerationSpec": { + "description": "Content generation specification.", + "id": "GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestGenerationSpec", + "properties": { + "frequencyPenalty": { + "description": "If specified, custom value for frequency penalty will be used.", + "format": "float", + "type": "number" + }, + "languageCode": { + "description": "Language code for content. Use language tags defined by [BCP47](https://www.rfc-editor.org/rfc/bcp/bcp47.txt).", + "type": "string" + }, + "maxOutputTokens": { + "description": "If specified, custom value for max output tokens will be used.", + "format": "int32", + "type": "integer" + }, + "modelId": { + "description": "Specifies which Vertex model id to use for generation.", + "type": "string" + }, + "presencePenalty": { + "description": "If specified, custom value for presence penalty will be used.", + "format": "float", + "type": "number" + }, + "seed": { + "description": "If specified, custom value for the seed will be used.", + "format": "int32", + "type": "integer" + }, + "temperature": { + "description": "If specified, custom value for the temperature will be used.", + "format": "float", + "type": "number" + }, + "topK": { + "description": "If specified, custom value for top-k sampling will be used.", + "format": "int32", + "type": "integer" + }, + "topP": { + "description": "If specified, custom value for nucleus sampling will be used.", + "format": "float", + "type": "number" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestGroundingSource": { + "description": "Grounding source.", + "id": "GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestGroundingSource", + "properties": { + "googleSearchSource": { + "$ref": "GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestGroundingSourceGoogleSearchSource", + "description": "If set, grounding is performed with Google Search." + }, + "inlineSource": { + "$ref": "GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestGroundingSourceInlineSource", + "description": "If set, grounding is performed with inline content." + }, + "searchSource": { + "$ref": "GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestGroundingSourceSearchSource", + "description": "If set, grounding is performed with Vertex AI Search." + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestGroundingSourceGoogleSearchSource": { + "description": "Google Search config parameters.", + "id": "GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestGroundingSourceGoogleSearchSource", + "properties": { + "dynamicRetrievalConfig": { + "$ref": "GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestDynamicRetrievalConfiguration", + "description": "Optional. Specifies the dynamic retrieval configuration for the given source." + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestGroundingSourceInlineSource": { + "description": "Message to be used for grounding based on inline content.", + "id": "GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestGroundingSourceInlineSource", + "properties": { + "attributes": { + "additionalProperties": { + "type": "string" + }, + "description": "Attributes associated with the content. Common attributes include `source` (indicating where the content was sourced from) and `author` (indicating the author of the content).", + "type": "object" + }, + "groundingFacts": { + "description": "List of facts to be used for grounding.", + "items": { + "$ref": "GoogleCloudDiscoveryengineV1betaGroundingFact" + }, + "type": "array" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestGroundingSourceSearchSource": { + "description": "Message to be used for grounding with Vertex AI Search.", + "id": "GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestGroundingSourceSearchSource", + "properties": { + "filter": { + "description": "Filter expression to be applied to the search. The syntax is the same as SearchRequest.filter.", + "type": "string" + }, + "maxResultCount": { + "description": "Number of search results to return. The default value is 10. The maximumm allowed value is 10.", + "format": "int32", + "type": "integer" + }, + "safeSearch": { + "description": "If set, safe search is enabled in Vertex AI Search requests.", + "type": "boolean" + }, + "servingConfig": { + "description": "The resource name of the Engine to use. Format: `projects/{project}/locations/{location}/collections/{collection_id}/engines/{engine_id}/servingConfigs/{serving_config_id}`", + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestGroundingSpec": { + "description": "Grounding specification.", + "id": "GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestGroundingSpec", + "properties": { + "groundingSources": { + "description": "Grounding sources.", + "items": { + "$ref": "GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestGroundingSource" + }, + "type": "array" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponse": { + "description": "Response for the `GenerateGroundedContent` method.", + "id": "GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponse", + "properties": { + "candidates": { + "description": "Generated candidates.", + "items": { + "$ref": "GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidate" + }, + "type": "array" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidate": { + "description": "A response candidate generated from the model.", + "id": "GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidate", + "properties": { + "content": { + "$ref": "GoogleCloudDiscoveryengineV1betaGroundedGenerationContent", + "description": "Content of the candidate." + }, + "groundingMetadata": { + "$ref": "GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidateGroundingMetadata", + "description": "Grounding metadata for the generated content." + }, + "groundingScore": { + "description": "The overall grounding score for the candidate, in the range of [0, 1].", + "format": "float", + "type": "number" + }, + "index": { + "description": "Index of the candidate.", + "format": "int32", + "type": "integer" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidateGroundingMetadata": { + "description": "Citation for the generated content.", + "id": "GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidateGroundingMetadata", + "properties": { + "groundingSupport": { + "description": "GroundingSupport across all claims in the answer candidate. An support to a fact indicates that the claim is supported by the fact.", + "items": { + "$ref": "GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidateGroundingMetadataGroundingSupport" + }, + "type": "array" + }, + "retrievalMetadata": { + "description": "Retrieval metadata to provide an understanding in the retrieval steps performed by the model. There can be multiple such messages which can correspond to different parts of the retrieval. This is a mechanism used to ensure transparency to our users.", + "items": { + "$ref": "GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidateGroundingMetadataRetrievalMetadata" + }, + "type": "array" + }, + "searchEntryPoint": { + "$ref": "GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidateGroundingMetadataSearchEntryPoint", + "description": "Google search entry for the following-up web searches." + }, + "supportChunks": { + "description": "List of chunks to be attributed across all claims in the candidate. These are derived from the grounding sources supplied in the request.", + "items": { + "$ref": "GoogleCloudDiscoveryengineV1betaFactChunk" + }, + "type": "array" + }, + "webSearchQueries": { + "description": "Web search queries for the following-up web search.", + "items": { + "type": "string" + }, + "type": "array" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidateGroundingMetadataDynamicRetrievalMetadata": { + "description": "Describes the metadata about dynamic retrieval.", + "id": "GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidateGroundingMetadataDynamicRetrievalMetadata", + "properties": { + "predictorMetadata": { + "$ref": "GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidateGroundingMetadataDynamicRetrievalPredictorMetadata", + "description": "Metadata for the dynamic retrieval predictor." + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidateGroundingMetadataDynamicRetrievalPredictorMetadata": { + "description": "Describes the metadata about the dynamic retrieval predictor.", + "id": "GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidateGroundingMetadataDynamicRetrievalPredictorMetadata", + "properties": { + "prediction": { + "description": "The value of the predictor. This should be between [0, 1] where a value of 0 means that the query would not benefit from grounding, while a value of 1.0 means that the query would benefit the most. In between values allow to differentiate between different usefulness scores for grounding.", + "format": "float", + "type": "number" + }, + "version": { + "description": "The version of the predictor which was used in dynamic retrieval.", + "enum": [ + "VERSION_UNSPECIFIED", + "V1_INDEPENDENT" + ], + "enumDescriptions": [ + "Unspecified version, should never be used.", + "The V1 model which is evaluating each source independently." + ], + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidateGroundingMetadataGroundingSupport": { + "description": "Grounding info for a claim in the candidate and its support.", + "id": "GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidateGroundingMetadataGroundingSupport", + "properties": { + "claimText": { + "description": "Text for the claim in the candidate. Always provided when a support is found.", + "type": "string" + }, + "supportChunkIndices": { + "description": "A list of indices (into 'support_chunks') specifying the citations associated with the claim. For instance [1,3,4] means that support_chunks[1], support_chunks[3], support_chunks[4] are the chunks attributed to the claim.", + "items": { + "format": "int32", + "type": "integer" + }, + "type": "array" + }, + "supportScore": { + "description": "A score in the range of [0, 1] describing how grounded is a specific claim in the support chunks indicated. Higher value means that the claim is better supported by the chunks.", + "format": "float", + "type": "number" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidateGroundingMetadataRetrievalMetadata": { + "description": "Describes the metadata associated with a retrieval step.", + "id": "GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidateGroundingMetadataRetrievalMetadata", + "properties": { + "dynamicRetrievalMetadata": { + "$ref": "GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidateGroundingMetadataDynamicRetrievalMetadata", + "description": "Metadata for dynamic retrieval." + }, + "source": { + "description": "Describes the source to which the metadata is referring to.", + "enum": [ + "SOURCE_UNSPECIFIED", + "VERTEX_AI_SEARCH", + "GOOGLE_SEARCH", + "INLINE_CONTENT", + "GOOGLE_MAPS" + ], + "enumDescriptions": [ + "Unspecified source.", + "Vertex AI search.", + "Google Search.", + "User inline provided content.", + "Google Maps." + ], + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidateGroundingMetadataSearchEntryPoint": { + "description": "Google search entry point.", + "id": "GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidateGroundingMetadataSearchEntryPoint", + "properties": { + "renderedContent": { + "description": "Web content snippet that can be embedded in a web page or an app webview.", + "type": "string" + }, + "sdkBlob": { + "description": "Base64 encoded JSON representing array of tuple.", + "format": "byte", + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1betaGroundedGenerationContent": { + "description": "Base structured datatype containing multi-part content of a message.", + "id": "GoogleCloudDiscoveryengineV1betaGroundedGenerationContent", + "properties": { + "parts": { + "description": "Ordered `Parts` that constitute a single message.", + "items": { + "$ref": "GoogleCloudDiscoveryengineV1betaGroundedGenerationContentPart" + }, + "type": "array" + }, + "role": { + "description": "Producer of the content. Must be either `user` or `model`. Intended to be used for multi-turn conversations. Otherwise, it can be left unset.", + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1betaGroundedGenerationContentPart": { + "description": "Single part of content.", + "id": "GoogleCloudDiscoveryengineV1betaGroundedGenerationContentPart", + "properties": { + "text": { + "description": "Inline text.", + "type": "string" + } + }, + "type": "object" + }, "GoogleCloudDiscoveryengineV1betaGroundingFact": { "description": "Grounding Fact.", "id": "GoogleCloudDiscoveryengineV1betaGroundingFact", @@ -20677,6 +21702,17 @@ }, "type": "object" }, + "GoogleCloudDiscoveryengineV1betaSingleRegionKey": { + "description": "Metadata for single-regional CMEKs.", + "id": "GoogleCloudDiscoveryengineV1betaSingleRegionKey", + "properties": { + "kmsKey": { + "description": "Required. Single-regional kms key resource name which will be used to encrypt resources `projects/{project}/locations/{location}/keyRings/{keyRing}/cryptoKeys/{keyId}`.", + "type": "string" + } + }, + "type": "object" + }, "GoogleCloudDiscoveryengineV1betaSiteSearchEngine": { "description": "SiteSearchEngine captures DataStore level site search persisting configurations. It is a singleton value per data store.", "id": "GoogleCloudDiscoveryengineV1betaSiteSearchEngine", @@ -21511,6 +22547,72 @@ } }, "type": "object" + }, + "GoogleTypeDateTime": { + "description": "Represents civil time (or occasionally physical time). This type can represent a civil time in one of a few possible ways: * When utc_offset is set and time_zone is unset: a civil time on a calendar day with a particular offset from UTC. * When time_zone is set and utc_offset is unset: a civil time on a calendar day in a particular time zone. * When neither time_zone nor utc_offset is set: a civil time on a calendar day in local time. The date is relative to the Proleptic Gregorian Calendar. If year, month, or day are 0, the DateTime is considered not to have a specific year, month, or day respectively. This type may also be used to represent a physical time if all the date and time fields are set and either case of the `time_offset` oneof is set. Consider using `Timestamp` message for physical time instead. If your use case also would like to store the user's timezone, that can be done in another field. This type is more flexible than some applications may want. Make sure to document and validate your application's limitations.", + "id": "GoogleTypeDateTime", + "properties": { + "day": { + "description": "Optional. Day of month. Must be from 1 to 31 and valid for the year and month, or 0 if specifying a datetime without a day.", + "format": "int32", + "type": "integer" + }, + "hours": { + "description": "Optional. Hours of day in 24 hour format. Should be from 0 to 23, defaults to 0 (midnight). An API may choose to allow the value \"24:00:00\" for scenarios like business closing time.", + "format": "int32", + "type": "integer" + }, + "minutes": { + "description": "Optional. Minutes of hour of day. Must be from 0 to 59, defaults to 0.", + "format": "int32", + "type": "integer" + }, + "month": { + "description": "Optional. Month of year. Must be from 1 to 12, or 0 if specifying a datetime without a month.", + "format": "int32", + "type": "integer" + }, + "nanos": { + "description": "Optional. Fractions of seconds in nanoseconds. Must be from 0 to 999,999,999, defaults to 0.", + "format": "int32", + "type": "integer" + }, + "seconds": { + "description": "Optional. Seconds of minutes of the time. Must normally be from 0 to 59, defaults to 0. An API may allow the value 60 if it allows leap-seconds.", + "format": "int32", + "type": "integer" + }, + "timeZone": { + "$ref": "GoogleTypeTimeZone", + "description": "Time zone." + }, + "utcOffset": { + "description": "UTC offset. Must be whole seconds, between -18 hours and +18 hours. For example, a UTC offset of -4:00 would be represented as { seconds: -14400 }.", + "format": "google-duration", + "type": "string" + }, + "year": { + "description": "Optional. Year of date. Must be from 1 to 9999, or 0 if specifying a datetime without a year.", + "format": "int32", + "type": "integer" + } + }, + "type": "object" + }, + "GoogleTypeTimeZone": { + "description": "Represents a time zone from the [IANA Time Zone Database](https://www.iana.org/time-zones).", + "id": "GoogleTypeTimeZone", + "properties": { + "id": { + "description": "IANA Time Zone Database time zone. For example \"America/New_York\".", + "type": "string" + }, + "version": { + "description": "Optional. IANA Time Zone Database version number. For example \"2019a\".", + "type": "string" + } + }, + "type": "object" } }, "servicePath": "", diff --git a/discoveryengine/v1beta/discoveryengine-gen.go b/discoveryengine/v1beta/discoveryengine-gen.go index 8de3537cfd..0f9745d769 100644 --- a/discoveryengine/v1beta/discoveryengine-gen.go +++ b/discoveryengine/v1beta/discoveryengine-gen.go @@ -1747,6 +1747,9 @@ type GoogleCloudDiscoveryengineV1CmekConfig struct { // `projects/{project}/locations/{location}/cmekConfig` or // `projects/{project}/locations/{location}/cmekConfigs/{cmekConfig}`. Name string `json:"name,omitempty"` + // SingleRegionKeys: Optional. Single-regional CMEKs that are required for some + // VAIS features. + SingleRegionKeys []*GoogleCloudDiscoveryengineV1SingleRegionKey `json:"singleRegionKeys,omitempty"` // State: Output only. State of the CmekConfig. // // Possible values: @@ -2241,6 +2244,9 @@ type GoogleCloudDiscoveryengineV1DataStore struct { // "MEDIA" - The media industry vertical. // "HEALTHCARE_FHIR" - The healthcare FHIR vertical. IndustryVertical string `json:"industryVertical,omitempty"` + // IsInfobotFaqDataStore: Optional. If set, this DataStore is an Infobot FAQ + // DataStore. + IsInfobotFaqDataStore bool `json:"isInfobotFaqDataStore,omitempty"` // KmsKeyName: Input only. The KMS key to be used to protect this DataStore at // creation time. Must be set for requests that need to comply with CMEK Org // Policy protections. If this field is set and processed successfully, the @@ -4035,6 +4041,32 @@ func (s *GoogleCloudDiscoveryengineV1ServingConfigMediaConfig) UnmarshalJSON(dat return nil } +// GoogleCloudDiscoveryengineV1SingleRegionKey: Metadata for single-regional +// CMEKs. +type GoogleCloudDiscoveryengineV1SingleRegionKey struct { + // KmsKey: Required. Single-regional kms key resource name which will be used + // to encrypt resources + // `projects/{project}/locations/{location}/keyRings/{keyRing}/cryptoKeys/{keyId + // }`. + KmsKey string `json:"kmsKey,omitempty"` + // ForceSendFields is a list of field names (e.g. "KmsKey") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "KmsKey") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1SingleRegionKey) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1SingleRegionKey + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudDiscoveryengineV1SiteVerificationInfo: Verification information // for target sites in advanced site search. type GoogleCloudDiscoveryengineV1SiteVerificationInfo struct { @@ -4400,6 +4432,38 @@ func (s GoogleCloudDiscoveryengineV1alphaAclConfig) MarshalJSON() ([]byte, error return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudDiscoveryengineV1alphaActionConfig: Informations to support +// actions on the connector. +type GoogleCloudDiscoveryengineV1alphaActionConfig struct { + // ActionParams: Required. Params needed to support actions in the format of + // (Key, Value) pairs. Required parameters for sources that support OAUTH, i.e. + // `gmail`, `google_calendar`, `jira`, `workday`, `salesforce`, `confluence`: * + // Key: `client_id` * Value: type STRING. The client id for the service + // provider to identify your application. * Key: `client_secret` * Value:type + // STRING. The client secret generated by the application's authorization + // server. + ActionParams googleapi.RawMessage `json:"actionParams,omitempty"` + // IsActionConfigured: Output only. The connector contains the necessary + // parameters and is configured to support actions. + IsActionConfigured bool `json:"isActionConfigured,omitempty"` + // ForceSendFields is a list of field names (e.g. "ActionParams") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "ActionParams") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1alphaActionConfig) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaActionConfig + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudDiscoveryengineV1alphaAdvancedSiteSearchConfig: Configuration // data for advance site search. type GoogleCloudDiscoveryengineV1alphaAdvancedSiteSearchConfig struct { @@ -5164,6 +5228,9 @@ type GoogleCloudDiscoveryengineV1alphaCmekConfig struct { // `projects/{project}/locations/{location}/cmekConfig` or // `projects/{project}/locations/{location}/cmekConfigs/{cmekConfig}`. Name string `json:"name,omitempty"` + // SingleRegionKeys: Optional. Single-regional CMEKs that are required for some + // VAIS features. + SingleRegionKeys []*GoogleCloudDiscoveryengineV1alphaSingleRegionKey `json:"singleRegionKeys,omitempty"` // State: Output only. State of the CmekConfig. // // Possible values: @@ -5195,6 +5262,47 @@ func (s GoogleCloudDiscoveryengineV1alphaCmekConfig) MarshalJSON() ([]byte, erro return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudDiscoveryengineV1alphaCollection: Collection is a container for +// configuring resources and access to a set of DataStores. +type GoogleCloudDiscoveryengineV1alphaCollection struct { + // CreateTime: Output only. Timestamp the Collection was created at. + CreateTime string `json:"createTime,omitempty"` + // DataConnector: Output only. The data connector, if present, manages the + // connection for data stores in the Collection. To set up the connector, use + // DataConnectorService.SetUpDataConnector method, which creates a new + // Collection while setting up the DataConnector singleton resource. Setting up + // connector on an existing Collection is not supported. This output only field + // contains a subset of the DataConnector fields, including `name`, + // `data_source`, `entities.entity_name` and `entities.data_store`. To get more + // details about a data connector, use the DataConnector.GetDataConnector + // method. + DataConnector *GoogleCloudDiscoveryengineV1alphaDataConnector `json:"dataConnector,omitempty"` + // DisplayName: Required. The Collection 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"` + // Name: Immutable. The full resource name of the Collection. Format: + // `projects/{project}/locations/{location}/collections/{collection_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. "CreateTime") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "CreateTime") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1alphaCollection) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaCollection + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudDiscoveryengineV1alphaCondition: Defines circumstances to be // checked before allowing a behavior type GoogleCloudDiscoveryengineV1alphaCondition struct { @@ -5278,6 +5386,135 @@ func (s GoogleCloudDiscoveryengineV1alphaConditionTimeRange) MarshalJSON() ([]by return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudDiscoveryengineV1alphaConnectorRun: A data sync run of +// DataConnector. After DataConnector is successfully initialized, data syncs +// are scheduled at DataConnector.refresh_interval. A ConnectorRun represents a +// data sync either in the past or onging that the moment. // +type GoogleCloudDiscoveryengineV1alphaConnectorRun struct { + // EndTime: Output only. The time when the connector run ended. + EndTime string `json:"endTime,omitempty"` + // EntityRuns: Output only. The details of the entities synced at the + // ConnectorRun. Each ConnectorRun consists of syncing one or more entities. + EntityRuns []*GoogleCloudDiscoveryengineV1alphaConnectorRunEntityRun `json:"entityRuns,omitempty"` + // Errors: Contains info about errors incurred during the sync. Only exist if + // running into an error state. Contains error code and error message. Use with + // the `state` field. + Errors []*GoogleRpcStatus `json:"errors,omitempty"` + // LatestPauseTime: Output only. The time when the connector run was most + // recently paused. + LatestPauseTime string `json:"latestPauseTime,omitempty"` + // Name: Output only. The full resource name of the Connector Run. Format: + // `projects/*/locations/*/collections/*/dataConnector/connectorRuns/*`. The + // `connector_run_id` is system-generated. + Name string `json:"name,omitempty"` + // StartTime: Output only. The time when the connector run started. + StartTime string `json:"startTime,omitempty"` + // State: Output only. The state of the sync run. + // + // Possible values: + // "STATE_UNSPECIFIED" - Default value. + // "RUNNING" - The data sync is ongoing. + // "SUCCEEDED" - The data sync is finished. + // "FAILED" - The data sync is failed. + // "OVERRUN" - Data sync has been running longer than expected and is still + // running at the time the next run is supposed to start. + // "CANCELLED" - Data sync was scheduled but has been cancelled. + // "PENDING" - Data sync is about to start. + // "WARNING" - The data sync completed with non-fatal errors. + State string `json:"state,omitempty"` + // StateUpdateTime: Timestamp at which the connector run sync state was last + // updated. + StateUpdateTime string `json:"stateUpdateTime,omitempty"` + // Trigger: Output only. The trigger for this ConnectorRun. + // + // Possible values: + // "TRIGGER_UNSPECIFIED" - Default value. + // "SCHEDULER" - ConnectorRun triggered by scheduler if connector has + // PERIODIC sync mode. + // "INITIALIZATION" - ConnectorRun auto triggered by connector + // initialization. + // "RESUME" - ConnectorRun auto triggered by resuming connector. + // "MANUAL" - ConnectorRun triggered by user manually. + Trigger string `json:"trigger,omitempty"` + // ForceSendFields is a list of field names (e.g. "EndTime") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "EndTime") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1alphaConnectorRun) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaConnectorRun + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaConnectorRunEntityRun: Represents an entity +// that was synced in this ConnectorRun. +type GoogleCloudDiscoveryengineV1alphaConnectorRunEntityRun struct { + // EntityName: The name of the source entity. + EntityName string `json:"entityName,omitempty"` + // ErrorRecordCount: The total number of documents failed at sync at any stage + // (extraction, indexing, etc). + ErrorRecordCount int64 `json:"errorRecordCount,omitempty,string"` + // Errors: The errors from the entity's sync run. Only exist if running into an + // error state. Contains error code and error message. + Errors []*GoogleRpcStatus `json:"errors,omitempty"` + // ExtractedRecordCount: The number of documents extracted from connector + // source, ready to be ingested to UCS. + ExtractedRecordCount int64 `json:"extractedRecordCount,omitempty,string"` + // IndexedRecordCount: The number of documents indexed. + IndexedRecordCount int64 `json:"indexedRecordCount,omitempty,string"` + // SourceApiRequestCount: The number of requests sent to 3p API. + SourceApiRequestCount int64 `json:"sourceApiRequestCount,omitempty,string"` + // State: The state of the entity's sync run. + // + // Possible values: + // "STATE_UNSPECIFIED" - Default value. + // "RUNNING" - The data sync is ongoing. + // "SUCCEEDED" - The data sync is finished. + // "FAILED" - The data sync is failed. + // "OVERRUN" - Data sync has been running longer than expected and is still + // running at the time the next run is supposed to start. + // "CANCELLED" - Data sync was scheduled but has been cancelled. + // "PENDING" - Data sync is about to start. + // "WARNING" - The data sync completed with non-fatal errors. + State string `json:"state,omitempty"` + // StateUpdateTime: Timestamp at which the entity sync state was last updated. + StateUpdateTime string `json:"stateUpdateTime,omitempty"` + // StatsUpdateTime: The timestamp for either extracted_documents_count, + // indexed_documents_count and error_documents_count was last updated. + StatsUpdateTime string `json:"statsUpdateTime,omitempty"` + // SyncType: Sync type of this run. + // + // Possible values: + // "SYNC_TYPE_UNSPECIFIED" - Sync type unspecified. + // "FULL" - Sync triggers full sync of all documents. + // "INCREMENTAL" - Incremental sync of updated documents. + SyncType string `json:"syncType,omitempty"` + // ForceSendFields is a list of field names (e.g. "EntityName") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "EntityName") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1alphaConnectorRunEntityRun) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaConnectorRunEntityRun + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudDiscoveryengineV1alphaControl: Defines a conditioned behavior to // employ during serving. Must be attached to a ServingConfig to be considered // at serving time. Permitted actions dependent on `SolutionType`. @@ -5695,6 +5932,195 @@ func (s GoogleCloudDiscoveryengineV1alphaCustomFineTuningSpec) MarshalJSON() ([] return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudDiscoveryengineV1alphaDataConnector: Manages the connection to +// external data sources for all data stores grouped under a Collection. It's a +// singleton resource of Collection. The initialization is only supported +// through SetUpDataConnector method, which will create a new Collection and +// initialize its DataConnector. // +type GoogleCloudDiscoveryengineV1alphaDataConnector struct { + // ActionConfig: Optional. Action configurations to make the connector support + // actions. + ActionConfig *GoogleCloudDiscoveryengineV1alphaActionConfig `json:"actionConfig,omitempty"` + // AutoRunDisabled: Indicates whether the connector is disabled for auto run. + // It can be used to pause periodical and real time sync. + AutoRunDisabled bool `json:"autoRunDisabled,omitempty"` + // BlockingReasons: Output only. User actions that must be completed before the + // connector can start syncing data. + // + // Possible values: + // "BLOCKING_REASON_UNSPECIFIED" - Default value. + // "ALLOWLIST_STATIC_IP" - Connector requires customer to allowlist static + // IPs. + // "ALLOWLIST_IN_SERVICE_ATTACHMENT" - Connector requires customer to + // allowlist our project in their service attachment. + BlockingReasons []string `json:"blockingReasons,omitempty"` + // CreateTime: Output only. Timestamp the DataConnector was created at. + CreateTime string `json:"createTime,omitempty"` + // DataSource: Required. The name of the data source. Supported values: + // `salesforce`, `jira`, `confluence`, `bigquery`. + DataSource string `json:"dataSource,omitempty"` + // DestinationConfigs: Optional. Any target destinations used to connect to + // third-party services. + DestinationConfigs []*GoogleCloudDiscoveryengineV1alphaDestinationConfig `json:"destinationConfigs,omitempty"` + // Entities: List of entities from the connected data source to ingest. + Entities []*GoogleCloudDiscoveryengineV1alphaDataConnectorSourceEntity `json:"entities,omitempty"` + // Errors: Output only. The errors from initialization or from the latest + // connector run. + Errors []*GoogleRpcStatus `json:"errors,omitempty"` + // IdentityRefreshInterval: The refresh interval to sync the Access Control + // List information for the documents ingested by this connector. If not set, + // the access control list will be refreshed at the default interval of 30 + // minutes. The identity refresh interval can be at least 30 minutes and at + // most 7 days. + IdentityRefreshInterval string `json:"identityRefreshInterval,omitempty"` + // IdentityScheduleConfig: The configuration for the identity data + // synchronization runs. This contains the refresh interval to sync the Access + // Control List information for the documents ingested by this connector. + IdentityScheduleConfig *GoogleCloudDiscoveryengineV1alphaIdentityScheduleConfig `json:"identityScheduleConfig,omitempty"` + // KmsKeyName: Input only. The KMS key to be used to protect the DataStores + // managed by this connector. Must be set for requests that need to comply with + // CMEK Org Policy protections. If this field is set and processed + // successfully, the DataStores created by this connector will be protected by + // the KMS key. + KmsKeyName string `json:"kmsKeyName,omitempty"` + // LastSyncTime: Output only. For periodic connectors only, the last time a + // data sync was completed. + LastSyncTime string `json:"lastSyncTime,omitempty"` + // LatestPauseTime: Output only. The most recent timestamp when this + // DataConnector was paused, affecting all functionalities such as data + // synchronization. Pausing a connector has the following effects: - All + // functionalities, including data synchronization, are halted. - Any ongoing + // data synchronization job will be canceled. - No future data synchronization + // runs will be scheduled nor can be triggered. + LatestPauseTime string `json:"latestPauseTime,omitempty"` + // Name: Output only. The full resource name of the Data Connector. Format: + // `projects/*/locations/*/collections/*/dataConnector`. + Name string `json:"name,omitempty"` + // NextSyncTime: The UTC time when the next data sync is expected to start for + // the Data Connector. Customers are only able to specify the hour and minute + // to schedule the data sync. This is utilized when the data connector has a + // refresh interval greater than 1 day. + NextSyncTime *GoogleTypeDateTime `json:"nextSyncTime,omitempty"` + // Params: Required. Params needed to access the source in the format of (Key, + // Value) pairs. Required parameters for all data sources: * Key: + // `instance_uri` * Value: type STRING. The uri to access the data source. + // Required parameters for sources that support OAUTH, i.e. `salesforce`: * + // Key: `client_id` * Value: type STRING. The client id for the third party + // service provider to identify your application. * Key: `client_secret` * + // Value:type STRING. The client secret generated by the third party + // authorization server. * Key: `access_token` * Value: type STRING. OAuth + // token for UCS to access to the protected resource. * Key: `refresh_token` * + // Value: type STRING. OAuth refresh token for UCS to obtain a new access token + // without user interaction. Required parameters for sources that support basic + // API token auth, i.e. `jira`, `confluence`: * Key: `user_account` * Value: + // type STRING. The username or email with the source. * Key: `api_token` * + // Value: type STRING. The API token generated for the source account, that is + // used for authenticating anywhere where you would have used a password. + // Example: ```json { "instance_uri": "https://xxx.atlassian.net", + // "user_account": "xxxx.xxx@xxx.com", "api_token": "test-token" } ``` Optional + // parameter to specify the authorization type to use for multiple + // authorization types support: * Key: `auth_type` * Value: type STRING. The + // authorization type for the data source. Supported values: `BASIC_AUTH`, + // `OAUTH`, `OAUTH_ACCESS_TOKEN`, `OAUTH_TWO_LEGGED`, `OAUTH_JWT_BEARER`, + // `OAUTH_PASSWORD_GRANT`, `JWT`, `API_TOKEN`, `FEDERATED_CREDENTIAL`. + Params googleapi.RawMessage `json:"params,omitempty"` + // PrivateConnectivityProjectId: Output only. The tenant project ID associated + // with private connectivity connectors. This project must be allowlisted by in + // order for the connector to function. + PrivateConnectivityProjectId string `json:"privateConnectivityProjectId,omitempty"` + // RefreshInterval: Required. The refresh interval for data sync. If duration + // is set to 0, the data will be synced in real time. The streaming feature is + // not supported yet. The minimum is 30 minutes and maximum is 7 days. + RefreshInterval string `json:"refreshInterval,omitempty"` + // State: Output only. State of the connector. + // + // Possible values: + // "STATE_UNSPECIFIED" - Default value. + // "CREATING" - The connector is being set up. + // "ACTIVE" - The connector is successfully set up and awaiting next sync + // run. + // "FAILED" - The connector is in error. The error details can be found in + // DataConnector.errors. If the error is unfixable, the DataConnector can be + // deleted by [CollectionService.DeleteCollection] API. + // "RUNNING" - The connector is actively syncing records from the data + // source. + // "WARNING" - The connector has completed a sync run, but encountered + // non-fatal errors. + State string `json:"state,omitempty"` + // StaticIpAddresses: Output only. The static IP addresses used by this + // connector. + StaticIpAddresses []string `json:"staticIpAddresses,omitempty"` + // StaticIpEnabled: Optional. Whether customer has enabled static IP addresses + // for this connector. + StaticIpEnabled bool `json:"staticIpEnabled,omitempty"` + // SyncMode: The data synchronization mode supported by the data connector. + // + // Possible values: + // "PERIODIC" - The connector will sync data periodically based on the + // refresh_interval. Use it with auto_run_disabled to pause the periodic sync, + // or indicate a one-time sync. + SyncMode string `json:"syncMode,omitempty"` + // UpdateTime: Output only. Timestamp the DataConnector was last updated. + UpdateTime string `json:"updateTime,omitempty"` + // ForceSendFields is a list of field names (e.g. "ActionConfig") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "ActionConfig") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1alphaDataConnector) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaDataConnector + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaDataConnectorSourceEntity: Represents an +// entity in the data source. For example, the `Account` object in Salesforce. +type GoogleCloudDiscoveryengineV1alphaDataConnectorSourceEntity struct { + // DataStore: Output only. The full resource name of the associated data store + // for the source entity. Format: + // `projects/*/locations/*/collections/*/dataStores/*`. When the connector is + // initialized by the DataConnectorService.SetUpDataConnector method, a + // DataStore is automatically created for each source entity. + DataStore string `json:"dataStore,omitempty"` + // EntityName: The name of the entity. Supported values by data source: * + // Salesforce: `Lead`, `Opportunity`, `Contact`, `Account`, `Case`, `Contract`, + // `Campaign` * Jira: `Issue` * Confluence: `Content`, `Space` + EntityName string `json:"entityName,omitempty"` + // KeyPropertyMappings: Attributes for indexing. Key: Field name. Value: The + // key property to map a field to, such as `title`, and `description`. + // Supported key properties: * `title`: The title for data record. This would + // be displayed on search results. * `description`: The description for data + // record. This would be displayed on search results. + KeyPropertyMappings map[string]string `json:"keyPropertyMappings,omitempty"` + // Params: The parameters for the entity to facilitate data ingestion. E.g. for + // BQ connectors: * Key: `document_id_column` * Value: type STRING. The value + // of the column id. + Params googleapi.RawMessage `json:"params,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. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // 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. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1alphaDataConnectorSourceEntity) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaDataConnectorSourceEntity + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudDiscoveryengineV1alphaDataStore: DataStore captures global // settings and configs at the DataStore level. type GoogleCloudDiscoveryengineV1alphaDataStore struct { @@ -5747,6 +6173,9 @@ type GoogleCloudDiscoveryengineV1alphaDataStore struct { // "MEDIA" - The media industry vertical. // "HEALTHCARE_FHIR" - The healthcare FHIR vertical. IndustryVertical string `json:"industryVertical,omitempty"` + // IsInfobotFaqDataStore: Optional. If set, this DataStore is an Infobot FAQ + // DataStore. + IsInfobotFaqDataStore bool `json:"isInfobotFaqDataStore,omitempty"` // KmsKeyName: Input only. The KMS key to be used to protect this DataStore at // creation time. Must be set for requests that need to comply with CMEK Org // Policy protections. If this field is set and processed successfully, the @@ -5902,6 +6331,33 @@ func (s GoogleCloudDiscoveryengineV1alphaDedicatedCrawlRateTimeSeries) MarshalJS return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudDiscoveryengineV1alphaDeleteCollectionMetadata: Metadata related +// to the progress of the CollectionService.UpdateCollection operation. This +// will be returned by the google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1alphaDeleteCollectionMetadata struct { + // CreateTime: Operation create time. + CreateTime string `json:"createTime,omitempty"` + // UpdateTime: Operation last update time. If the operation is done, this is + // also the finish time. + UpdateTime string `json:"updateTime,omitempty"` + // ForceSendFields is a list of field names (e.g. "CreateTime") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "CreateTime") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1alphaDeleteCollectionMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaDeleteCollectionMetadata + return gensupport.MarshalJSON(NoMethod(s), 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. @@ -6061,6 +6517,59 @@ func (s GoogleCloudDiscoveryengineV1alphaDeleteTargetSiteMetadata) MarshalJSON() return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudDiscoveryengineV1alphaDestinationConfig: Defines target endpoints +// used to connect to third-party sources. +type GoogleCloudDiscoveryengineV1alphaDestinationConfig struct { + // Destinations: Optional. The destinations for the corresponding key. + Destinations []*GoogleCloudDiscoveryengineV1alphaDestinationConfigDestination `json:"destinations,omitempty"` + // Key: Optional. Unique destination identifier that is supported by the + // connector. + Key string `json:"key,omitempty"` + // Params: Optional. Additional parameters for this destination config. + Params googleapi.RawMessage `json:"params,omitempty"` + // ForceSendFields is a list of field names (e.g. "Destinations") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "Destinations") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1alphaDestinationConfig) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaDestinationConfig + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaDestinationConfigDestination: Defines a +// target endpoint +type GoogleCloudDiscoveryengineV1alphaDestinationConfigDestination struct { + // Host: Publicly routable host. + Host string `json:"host,omitempty"` + // Port: Optional. Target port number accepted by the destination. + Port int64 `json:"port,omitempty"` + // ForceSendFields is a list of field names (e.g. "Host") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "Host") to include in API requests + // with the JSON null value. By default, fields with empty values are omitted + // from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1alphaDestinationConfigDestination) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaDestinationConfigDestination + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudDiscoveryengineV1alphaDisableAdvancedSiteSearchMetadata: Metadata // related to the progress of the // SiteSearchEngineService.DisableAdvancedSiteSearch operation. This will be @@ -7127,6 +7636,33 @@ func (s GoogleCloudDiscoveryengineV1alphaGetUriPatternDocumentDataResponse) Mars return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudDiscoveryengineV1alphaIdentityScheduleConfig: The configuration +// for the identity data synchronization runs. +type GoogleCloudDiscoveryengineV1alphaIdentityScheduleConfig struct { + // RefreshInterval: Optional. The refresh interval to sync the Access Control + // List information for the documents ingested by this connector. If not set, + // the access control list will be refreshed at the default interval of 30 + // minutes. The identity refresh interval can be at least 30 minutes and at + // most 7 days. + RefreshInterval string `json:"refreshInterval,omitempty"` + // ForceSendFields is a list of field names (e.g. "RefreshInterval") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "RefreshInterval") to include in + // API requests with the JSON null value. By default, fields with empty values + // are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1alphaIdentityScheduleConfig) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaIdentityScheduleConfig + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudDiscoveryengineV1alphaIdpConfig: Identity Provider Config. type GoogleCloudDiscoveryengineV1alphaIdpConfig struct { // ExternalIdpConfig: External Identity provider config. @@ -9646,6 +10182,11 @@ func (s GoogleCloudDiscoveryengineV1alphaSessionTurn) MarshalJSON() ([]byte, err return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudDiscoveryengineV1alphaSetUpDataConnectorMetadata: Metadata for +// DataConnectorService.SetUpDataConnector method. +type GoogleCloudDiscoveryengineV1alphaSetUpDataConnectorMetadata struct { +} + // GoogleCloudDiscoveryengineV1alphaSetUriPatternDocumentDataMetadata: Metadata // related to the progress of the // SiteSearchEngineService.SetUriPatternDocumentData operation. This will be @@ -9679,6 +10220,32 @@ func (s GoogleCloudDiscoveryengineV1alphaSetUriPatternDocumentDataMetadata) Mars type GoogleCloudDiscoveryengineV1alphaSetUriPatternDocumentDataResponse struct { } +// GoogleCloudDiscoveryengineV1alphaSingleRegionKey: Metadata for +// single-regional CMEKs. +type GoogleCloudDiscoveryengineV1alphaSingleRegionKey struct { + // KmsKey: Required. Single-regional kms key resource name which will be used + // to encrypt resources + // `projects/{project}/locations/{location}/keyRings/{keyRing}/cryptoKeys/{keyId + // }`. + KmsKey string `json:"kmsKey,omitempty"` + // ForceSendFields is a list of field names (e.g. "KmsKey") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "KmsKey") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1alphaSingleRegionKey) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaSingleRegionKey + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudDiscoveryengineV1alphaSiteVerificationInfo: Verification // information for target sites in advanced site search. type GoogleCloudDiscoveryengineV1alphaSiteVerificationInfo struct { @@ -9982,6 +10549,33 @@ func (s GoogleCloudDiscoveryengineV1alphaUpdateCmekConfigMetadata) MarshalJSON() return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudDiscoveryengineV1alphaUpdateCollectionMetadata: Metadata related +// to the progress of the CollectionService.UpdateCollection operation. This +// will be returned by the google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1alphaUpdateCollectionMetadata struct { + // CreateTime: Operation create time. + CreateTime string `json:"createTime,omitempty"` + // UpdateTime: Operation last update time. If the operation is done, this is + // also the finish time. + UpdateTime string `json:"updateTime,omitempty"` + // ForceSendFields is a list of field names (e.g. "CreateTime") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "CreateTime") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1alphaUpdateCollectionMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaUpdateCollectionMetadata + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudDiscoveryengineV1alphaUpdateSchemaMetadata: Metadata for // UpdateSchema LRO. type GoogleCloudDiscoveryengineV1alphaUpdateSchemaMetadata struct { @@ -12684,6 +13278,9 @@ type GoogleCloudDiscoveryengineV1betaCmekConfig struct { // `projects/{project}/locations/{location}/cmekConfig` or // `projects/{project}/locations/{location}/cmekConfigs/{cmekConfig}`. Name string `json:"name,omitempty"` + // SingleRegionKeys: Optional. Single-regional CMEKs that are required for some + // VAIS features. + SingleRegionKeys []*GoogleCloudDiscoveryengineV1betaSingleRegionKey `json:"singleRegionKeys,omitempty"` // State: Output only. State of the CmekConfig. // // Possible values: @@ -13683,6 +14280,9 @@ type GoogleCloudDiscoveryengineV1betaDataStore struct { // "MEDIA" - The media industry vertical. // "HEALTHCARE_FHIR" - The healthcare FHIR vertical. IndustryVertical string `json:"industryVertical,omitempty"` + // IsInfobotFaqDataStore: Optional. If set, this DataStore is an Infobot FAQ + // DataStore. + IsInfobotFaqDataStore bool `json:"isInfobotFaqDataStore,omitempty"` // KmsKeyName: Input only. The KMS key to be used to protect this DataStore at // creation time. Must be set for requests that need to comply with CMEK Org // Policy protections. If this field is set and processed successfully, the @@ -13996,7 +14596,8 @@ type GoogleCloudDiscoveryengineV1betaDocument struct { // IndexStatus: Output only. The index status of the document. * If document is // indexed successfully, the index_time field is populated. * Otherwise, if // document is not indexed due to errors, the error_samples field is populated. - // * Otherwise, index_status is unset. + // * Otherwise, if document's index is in progress, the pending_message field + // is populated. IndexStatus *GoogleCloudDiscoveryengineV1betaDocumentIndexStatus `json:"indexStatus,omitempty"` // IndexTime: Output only. The last time the document was indexed. If this // field is set, the document could be returned in search results. This field @@ -14091,6 +14692,9 @@ type GoogleCloudDiscoveryengineV1betaDocumentIndexStatus struct { // IndexTime: The time when the document was indexed. If this field is // populated, it means the document has been indexed. IndexTime string `json:"indexTime,omitempty"` + // PendingMessage: Immutable. The message indicates the document index is in + // progress. If this field is populated, the document index is pending. + PendingMessage string `json:"pendingMessage,omitempty"` // ForceSendFields is a list of field names (e.g. "ErrorSamples") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See @@ -15019,10 +15623,660 @@ func (s GoogleCloudDiscoveryengineV1betaGcsSource) MarshalJSON() ([]byte, error) return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } -// GoogleCloudDiscoveryengineV1betaGroundingFact: Grounding Fact. -type GoogleCloudDiscoveryengineV1betaGroundingFact struct { - // Attributes: Attributes associated with the fact. Common attributes include - // `source` (indicating where the fact was sourced from), `author` (indicating +// GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequest: Top-level +// message sent by the client for the `GenerateGroundedContent` method. +type GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequest struct { + // Contents: Content of the current conversation with the model. For + // single-turn queries, this is a single instance. For multi-turn queries, this + // is a repeated field that contains conversation history + latest request. + Contents []*GoogleCloudDiscoveryengineV1betaGroundedGenerationContent `json:"contents,omitempty"` + // GenerationSpec: Content generation specification. + GenerationSpec *GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestGenerationSpec `json:"generationSpec,omitempty"` + // GroundingSpec: Grounding specification. + GroundingSpec *GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestGroundingSpec `json:"groundingSpec,omitempty"` + // SystemInstruction: Content of the system instruction for the current API. + // These instructions will take priority over any other prompt instructions if + // the selected model is supporting them. + SystemInstruction *GoogleCloudDiscoveryengineV1betaGroundedGenerationContent `json:"systemInstruction,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. "Contents") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "Contents") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequest) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequest + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestDynamicRetrieva +// lConfiguration: Describes the options to customize dynamic retrieval. +type GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestDynamicRetrievalConfiguration struct { + // Predictor: Specification for the predictor for dynamic retrieval. + Predictor *GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestDynamicRetrievalConfigurationDynamicRetrievalPredictor `json:"predictor,omitempty"` + // ForceSendFields is a list of field names (e.g. "Predictor") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "Predictor") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestDynamicRetrievalConfiguration) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestDynamicRetrievalConfiguration + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestDynamicRetrieva +// lConfigurationDynamicRetrievalPredictor: Describes the predictor settings +// for dynamic retrieval. +type GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestDynamicRetrievalConfigurationDynamicRetrievalPredictor struct { + // Threshold: The value of the threshold. If the predictor will predict a value + // smaller than this, it would suppress grounding in the source. + Threshold float64 `json:"threshold,omitempty"` + // Version: The version of the predictor to be used in dynamic retrieval. + // + // Possible values: + // "VERSION_UNSPECIFIED" - Automatically choose the best version of the + // retrieval predictor. + // "V1_INDEPENDENT" - The V1 model which is evaluating each source + // independently. + Version string `json:"version,omitempty"` + // ForceSendFields is a list of field names (e.g. "Threshold") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "Threshold") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestDynamicRetrievalConfigurationDynamicRetrievalPredictor) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestDynamicRetrievalConfigurationDynamicRetrievalPredictor + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +func (s *GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestDynamicRetrievalConfigurationDynamicRetrievalPredictor) UnmarshalJSON(data []byte) error { + type NoMethod GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestDynamicRetrievalConfigurationDynamicRetrievalPredictor + var s1 struct { + Threshold gensupport.JSONFloat64 `json:"threshold"` + *NoMethod + } + s1.NoMethod = (*NoMethod)(s) + if err := json.Unmarshal(data, &s1); err != nil { + return err + } + s.Threshold = float64(s1.Threshold) + return nil +} + +// GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestGenerationSpec: +// +// Content generation specification. +type GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestGenerationSpec struct { + // FrequencyPenalty: If specified, custom value for frequency penalty will be + // used. + FrequencyPenalty float64 `json:"frequencyPenalty,omitempty"` + // LanguageCode: Language code for content. Use language tags defined by BCP47 + // (https://www.rfc-editor.org/rfc/bcp/bcp47.txt). + LanguageCode string `json:"languageCode,omitempty"` + // MaxOutputTokens: If specified, custom value for max output tokens will be + // used. + MaxOutputTokens int64 `json:"maxOutputTokens,omitempty"` + // ModelId: Specifies which Vertex model id to use for generation. + ModelId string `json:"modelId,omitempty"` + // PresencePenalty: If specified, custom value for presence penalty will be + // used. + PresencePenalty float64 `json:"presencePenalty,omitempty"` + // Seed: If specified, custom value for the seed will be used. + Seed int64 `json:"seed,omitempty"` + // Temperature: If specified, custom value for the temperature will be used. + Temperature float64 `json:"temperature,omitempty"` + // TopK: If specified, custom value for top-k sampling will be used. + TopK int64 `json:"topK,omitempty"` + // TopP: If specified, custom value for nucleus sampling will be used. + TopP float64 `json:"topP,omitempty"` + // ForceSendFields is a list of field names (e.g. "FrequencyPenalty") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "FrequencyPenalty") to include in + // API requests with the JSON null value. By default, fields with empty values + // are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestGenerationSpec) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestGenerationSpec + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +func (s *GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestGenerationSpec) UnmarshalJSON(data []byte) error { + type NoMethod GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestGenerationSpec + var s1 struct { + FrequencyPenalty gensupport.JSONFloat64 `json:"frequencyPenalty"` + PresencePenalty gensupport.JSONFloat64 `json:"presencePenalty"` + Temperature gensupport.JSONFloat64 `json:"temperature"` + TopP gensupport.JSONFloat64 `json:"topP"` + *NoMethod + } + s1.NoMethod = (*NoMethod)(s) + if err := json.Unmarshal(data, &s1); err != nil { + return err + } + s.FrequencyPenalty = float64(s1.FrequencyPenalty) + s.PresencePenalty = float64(s1.PresencePenalty) + s.Temperature = float64(s1.Temperature) + s.TopP = float64(s1.TopP) + return nil +} + +// GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestGroundingSource +// : Grounding source. +type GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestGroundingSource struct { + // GoogleSearchSource: If set, grounding is performed with Google Search. + GoogleSearchSource *GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestGroundingSourceGoogleSearchSource `json:"googleSearchSource,omitempty"` + // InlineSource: If set, grounding is performed with inline content. + InlineSource *GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestGroundingSourceInlineSource `json:"inlineSource,omitempty"` + // SearchSource: If set, grounding is performed with Vertex AI Search. + SearchSource *GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestGroundingSourceSearchSource `json:"searchSource,omitempty"` + // ForceSendFields is a list of field names (e.g. "GoogleSearchSource") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "GoogleSearchSource") to include + // in API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestGroundingSource) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestGroundingSource + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestGroundingSource +// GoogleSearchSource: Google Search config parameters. +type GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestGroundingSourceGoogleSearchSource struct { + // DynamicRetrievalConfig: Optional. Specifies the dynamic retrieval + // configuration for the given source. + DynamicRetrievalConfig *GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestDynamicRetrievalConfiguration `json:"dynamicRetrievalConfig,omitempty"` + // ForceSendFields is a list of field names (e.g. "DynamicRetrievalConfig") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "DynamicRetrievalConfig") to + // include in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestGroundingSourceGoogleSearchSource) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestGroundingSourceGoogleSearchSource + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestGroundingSource +// InlineSource: Message to be used for grounding based on inline content. +type GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestGroundingSourceInlineSource struct { + // Attributes: Attributes associated with the content. Common attributes + // include `source` (indicating where the content was sourced from) and + // `author` (indicating the author of the content). + Attributes map[string]string `json:"attributes,omitempty"` + // GroundingFacts: List of facts to be used for grounding. + GroundingFacts []*GoogleCloudDiscoveryengineV1betaGroundingFact `json:"groundingFacts,omitempty"` + // 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. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + 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. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestGroundingSourceInlineSource) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestGroundingSourceInlineSource + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestGroundingSource +// SearchSource: Message to be used for grounding with Vertex AI Search. +type GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestGroundingSourceSearchSource struct { + // Filter: Filter expression to be applied to the search. The syntax is the + // same as SearchRequest.filter. + Filter string `json:"filter,omitempty"` + // MaxResultCount: Number of search results to return. The default value is 10. + // The maximumm allowed value is 10. + MaxResultCount int64 `json:"maxResultCount,omitempty"` + // SafeSearch: If set, safe search is enabled in Vertex AI Search requests. + SafeSearch bool `json:"safeSearch,omitempty"` + // ServingConfig: The resource name of the Engine to use. Format: + // `projects/{project}/locations/{location}/collections/{collection_id}/engines/ + // {engine_id}/servingConfigs/{serving_config_id}` + ServingConfig string `json:"servingConfig,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. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + 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. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestGroundingSourceSearchSource) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestGroundingSourceSearchSource + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestGroundingSpec: +// Grounding specification. +type GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestGroundingSpec struct { + // GroundingSources: Grounding sources. + GroundingSources []*GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestGroundingSource `json:"groundingSources,omitempty"` + // ForceSendFields is a list of field names (e.g. "GroundingSources") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "GroundingSources") to include in + // API requests with the JSON null value. By default, fields with empty values + // are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestGroundingSpec) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestGroundingSpec + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponse: Response +// for the `GenerateGroundedContent` method. +type GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponse struct { + // Candidates: Generated candidates. + Candidates []*GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidate `json:"candidates,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the server. + googleapi.ServerResponse `json:"-"` + // ForceSendFields is a list of field names (e.g. "Candidates") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "Candidates") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponse + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidate: A +// response candidate generated from the model. +type GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidate struct { + // Content: Content of the candidate. + Content *GoogleCloudDiscoveryengineV1betaGroundedGenerationContent `json:"content,omitempty"` + // GroundingMetadata: Grounding metadata for the generated content. + GroundingMetadata *GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidateGroundingMetadata `json:"groundingMetadata,omitempty"` + // GroundingScore: The overall grounding score for the candidate, in the range + // of [0, 1]. + GroundingScore float64 `json:"groundingScore,omitempty"` + // Index: Index of the candidate. + Index int64 `json:"index,omitempty"` + // 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. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + 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. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidate) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidate + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +func (s *GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidate) UnmarshalJSON(data []byte) error { + type NoMethod GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidate + var s1 struct { + GroundingScore gensupport.JSONFloat64 `json:"groundingScore"` + *NoMethod + } + s1.NoMethod = (*NoMethod)(s) + if err := json.Unmarshal(data, &s1); err != nil { + return err + } + s.GroundingScore = float64(s1.GroundingScore) + return nil +} + +// GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidateGroun +// dingMetadata: Citation for the generated content. +type GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidateGroundingMetadata struct { + // GroundingSupport: GroundingSupport across all claims in the answer + // candidate. An support to a fact indicates that the claim is supported by the + // fact. + GroundingSupport []*GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidateGroundingMetadataGroundingSupport `json:"groundingSupport,omitempty"` + // RetrievalMetadata: Retrieval metadata to provide an understanding in the + // retrieval steps performed by the model. There can be multiple such messages + // which can correspond to different parts of the retrieval. This is a + // mechanism used to ensure transparency to our users. + RetrievalMetadata []*GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidateGroundingMetadataRetrievalMetadata `json:"retrievalMetadata,omitempty"` + // SearchEntryPoint: Google search entry for the following-up web searches. + SearchEntryPoint *GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidateGroundingMetadataSearchEntryPoint `json:"searchEntryPoint,omitempty"` + // SupportChunks: List of chunks to be attributed across all claims in the + // candidate. These are derived from the grounding sources supplied in the + // request. + SupportChunks []*GoogleCloudDiscoveryengineV1betaFactChunk `json:"supportChunks,omitempty"` + // WebSearchQueries: Web search queries for the following-up web search. + WebSearchQueries []string `json:"webSearchQueries,omitempty"` + // ForceSendFields is a list of field names (e.g. "GroundingSupport") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "GroundingSupport") to include in + // API requests with the JSON null value. By default, fields with empty values + // are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidateGroundingMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidateGroundingMetadata + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidateGroun +// dingMetadataDynamicRetrievalMetadata: Describes the metadata about dynamic +// retrieval. +type GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidateGroundingMetadataDynamicRetrievalMetadata struct { + // PredictorMetadata: Metadata for the dynamic retrieval predictor. + PredictorMetadata *GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidateGroundingMetadataDynamicRetrievalPredictorMetadata `json:"predictorMetadata,omitempty"` + // ForceSendFields is a list of field names (e.g. "PredictorMetadata") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "PredictorMetadata") to include in + // API requests with the JSON null value. By default, fields with empty values + // are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidateGroundingMetadataDynamicRetrievalMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidateGroundingMetadataDynamicRetrievalMetadata + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidateGroun +// dingMetadataDynamicRetrievalPredictorMetadata: Describes the metadata about +// the dynamic retrieval predictor. +type GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidateGroundingMetadataDynamicRetrievalPredictorMetadata struct { + // Prediction: The value of the predictor. This should be between [0, 1] where + // a value of 0 means that the query would not benefit from grounding, while a + // value of 1.0 means that the query would benefit the most. In between values + // allow to differentiate between different usefulness scores for grounding. + Prediction float64 `json:"prediction,omitempty"` + // Version: The version of the predictor which was used in dynamic retrieval. + // + // Possible values: + // "VERSION_UNSPECIFIED" - Unspecified version, should never be used. + // "V1_INDEPENDENT" - The V1 model which is evaluating each source + // independently. + Version string `json:"version,omitempty"` + // ForceSendFields is a list of field names (e.g. "Prediction") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "Prediction") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidateGroundingMetadataDynamicRetrievalPredictorMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidateGroundingMetadataDynamicRetrievalPredictorMetadata + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +func (s *GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidateGroundingMetadataDynamicRetrievalPredictorMetadata) UnmarshalJSON(data []byte) error { + type NoMethod GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidateGroundingMetadataDynamicRetrievalPredictorMetadata + var s1 struct { + Prediction gensupport.JSONFloat64 `json:"prediction"` + *NoMethod + } + s1.NoMethod = (*NoMethod)(s) + if err := json.Unmarshal(data, &s1); err != nil { + return err + } + s.Prediction = float64(s1.Prediction) + return nil +} + +// GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidateGroun +// dingMetadataGroundingSupport: Grounding info for a claim in the candidate +// and its support. +type GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidateGroundingMetadataGroundingSupport struct { + // ClaimText: Text for the claim in the candidate. Always provided when a + // support is found. + ClaimText string `json:"claimText,omitempty"` + // SupportChunkIndices: A list of indices (into 'support_chunks') specifying + // the citations associated with the claim. For instance [1,3,4] means that + // support_chunks[1], support_chunks[3], support_chunks[4] are the chunks + // attributed to the claim. + SupportChunkIndices []int64 `json:"supportChunkIndices,omitempty"` + // SupportScore: A score in the range of [0, 1] describing how grounded is a + // specific claim in the support chunks indicated. Higher value means that the + // claim is better supported by the chunks. + SupportScore float64 `json:"supportScore,omitempty"` + // ForceSendFields is a list of field names (e.g. "ClaimText") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "ClaimText") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidateGroundingMetadataGroundingSupport) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidateGroundingMetadataGroundingSupport + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +func (s *GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidateGroundingMetadataGroundingSupport) UnmarshalJSON(data []byte) error { + type NoMethod GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidateGroundingMetadataGroundingSupport + var s1 struct { + SupportScore gensupport.JSONFloat64 `json:"supportScore"` + *NoMethod + } + s1.NoMethod = (*NoMethod)(s) + if err := json.Unmarshal(data, &s1); err != nil { + return err + } + s.SupportScore = float64(s1.SupportScore) + return nil +} + +// GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidateGroun +// dingMetadataRetrievalMetadata: Describes the metadata associated with a +// retrieval step. +type GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidateGroundingMetadataRetrievalMetadata struct { + // DynamicRetrievalMetadata: Metadata for dynamic retrieval. + DynamicRetrievalMetadata *GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidateGroundingMetadataDynamicRetrievalMetadata `json:"dynamicRetrievalMetadata,omitempty"` + // Source: Describes the source to which the metadata is referring to. + // + // Possible values: + // "SOURCE_UNSPECIFIED" - Unspecified source. + // "VERTEX_AI_SEARCH" - Vertex AI search. + // "GOOGLE_SEARCH" - Google Search. + // "INLINE_CONTENT" - User inline provided content. + // "GOOGLE_MAPS" - Google Maps. + Source string `json:"source,omitempty"` + // ForceSendFields is a list of field names (e.g. "DynamicRetrievalMetadata") + // to unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "DynamicRetrievalMetadata") to + // include in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidateGroundingMetadataRetrievalMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidateGroundingMetadataRetrievalMetadata + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidateGroun +// dingMetadataSearchEntryPoint: Google search entry point. +type GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidateGroundingMetadataSearchEntryPoint struct { + // RenderedContent: Web content snippet that can be embedded in a web page or + // an app webview. + RenderedContent string `json:"renderedContent,omitempty"` + // SdkBlob: Base64 encoded JSON representing array of tuple. + SdkBlob string `json:"sdkBlob,omitempty"` + // ForceSendFields is a list of field names (e.g. "RenderedContent") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "RenderedContent") to include in + // API requests with the JSON null value. By default, fields with empty values + // are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidateGroundingMetadataSearchEntryPoint) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidateGroundingMetadataSearchEntryPoint + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1betaGroundedGenerationContent: Base structured +// datatype containing multi-part content of a message. +type GoogleCloudDiscoveryengineV1betaGroundedGenerationContent struct { + // Parts: Ordered `Parts` that constitute a single message. + Parts []*GoogleCloudDiscoveryengineV1betaGroundedGenerationContentPart `json:"parts,omitempty"` + // Role: Producer of the content. Must be either `user` or `model`. Intended to + // be used for multi-turn conversations. Otherwise, it can be left unset. + Role string `json:"role,omitempty"` + // ForceSendFields is a list of field names (e.g. "Parts") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "Parts") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1betaGroundedGenerationContent) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaGroundedGenerationContent + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1betaGroundedGenerationContentPart: Single part +// of content. +type GoogleCloudDiscoveryengineV1betaGroundedGenerationContentPart struct { + // Text: Inline text. + Text string `json:"text,omitempty"` + // ForceSendFields is a list of field names (e.g. "Text") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "Text") to include in API requests + // with the JSON null value. By default, fields with empty values are omitted + // from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1betaGroundedGenerationContentPart) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaGroundedGenerationContentPart + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1betaGroundingFact: Grounding Fact. +type GoogleCloudDiscoveryengineV1betaGroundingFact struct { + // Attributes: Attributes associated with the fact. Common attributes include + // `source` (indicating where the fact was sourced from), `author` (indicating // the author of the fact), and so on. Attributes map[string]string `json:"attributes,omitempty"` // FactText: Text content of the fact. Can be at most 10K characters long. @@ -19827,6 +21081,32 @@ func (s GoogleCloudDiscoveryengineV1betaSessionTurn) MarshalJSON() ([]byte, erro return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleCloudDiscoveryengineV1betaSingleRegionKey: Metadata for +// single-regional CMEKs. +type GoogleCloudDiscoveryengineV1betaSingleRegionKey struct { + // KmsKey: Required. Single-regional kms key resource name which will be used + // to encrypt resources + // `projects/{project}/locations/{location}/keyRings/{keyRing}/cryptoKeys/{keyId + // }`. + KmsKey string `json:"kmsKey,omitempty"` + // ForceSendFields is a list of field names (e.g. "KmsKey") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "KmsKey") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleCloudDiscoveryengineV1betaSingleRegionKey) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1betaSingleRegionKey + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudDiscoveryengineV1betaSiteSearchEngine: SiteSearchEngine captures // DataStore level site search persisting configurations. It is a singleton // value per data store. @@ -21026,6 +22306,95 @@ func (s GoogleTypeDate) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) } +// GoogleTypeDateTime: Represents civil time (or occasionally physical time). +// This type can represent a civil time in one of a few possible ways: * When +// utc_offset is set and time_zone is unset: a civil time on a calendar day +// with a particular offset from UTC. * When time_zone is set and utc_offset is +// unset: a civil time on a calendar day in a particular time zone. * When +// neither time_zone nor utc_offset is set: a civil time on a calendar day in +// local time. The date is relative to the Proleptic Gregorian Calendar. If +// year, month, or day are 0, the DateTime is considered not to have a specific +// year, month, or day respectively. This type may also be used to represent a +// physical time if all the date and time fields are set and either case of the +// `time_offset` oneof is set. Consider using `Timestamp` message for physical +// time instead. If your use case also would like to store the user's timezone, +// that can be done in another field. This type is more flexible than some +// applications may want. Make sure to document and validate your application's +// limitations. +type GoogleTypeDateTime struct { + // Day: Optional. Day of month. Must be from 1 to 31 and valid for the year and + // month, or 0 if specifying a datetime without a day. + Day int64 `json:"day,omitempty"` + // Hours: Optional. Hours of day in 24 hour format. Should be from 0 to 23, + // defaults to 0 (midnight). An API may choose to allow the value "24:00:00" + // for scenarios like business closing time. + Hours int64 `json:"hours,omitempty"` + // Minutes: Optional. Minutes of hour of day. Must be from 0 to 59, defaults to + // 0. + Minutes int64 `json:"minutes,omitempty"` + // Month: Optional. Month of year. Must be from 1 to 12, or 0 if specifying a + // datetime without a month. + Month int64 `json:"month,omitempty"` + // Nanos: Optional. Fractions of seconds in nanoseconds. Must be from 0 to + // 999,999,999, defaults to 0. + Nanos int64 `json:"nanos,omitempty"` + // Seconds: Optional. Seconds of minutes of the time. Must normally be from 0 + // to 59, defaults to 0. An API may allow the value 60 if it allows + // leap-seconds. + Seconds int64 `json:"seconds,omitempty"` + // TimeZone: Time zone. + TimeZone *GoogleTypeTimeZone `json:"timeZone,omitempty"` + // UtcOffset: UTC offset. Must be whole seconds, between -18 hours and +18 + // hours. For example, a UTC offset of -4:00 would be represented as { seconds: + // -14400 }. + UtcOffset string `json:"utcOffset,omitempty"` + // Year: Optional. Year of date. Must be from 1 to 9999, or 0 if specifying a + // datetime 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. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + 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. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleTypeDateTime) MarshalJSON() ([]byte, error) { + type NoMethod GoogleTypeDateTime + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + +// GoogleTypeTimeZone: Represents a time zone from the IANA Time Zone Database +// (https://www.iana.org/time-zones). +type GoogleTypeTimeZone struct { + // Id: IANA Time Zone Database time zone. For example "America/New_York". + Id string `json:"id,omitempty"` + // Version: Optional. IANA Time Zone Database version number. For example + // "2019a". + Version string `json:"version,omitempty"` + // ForceSendFields is a list of field names (e.g. "Id") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "Id") to include in API requests + // with the JSON null value. By default, fields with empty values are omitted + // from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s GoogleTypeTimeZone) MarshalJSON() ([]byte, error) { + type NoMethod GoogleTypeTimeZone + return gensupport.MarshalJSON(NoMethod(s), s.ForceSendFields, s.NullFields) +} + type ProjectsProvisionCall struct { s *Service name string @@ -21134,6 +22503,111 @@ func (c *ProjectsProvisionCall) Do(opts ...googleapi.CallOption) (*GoogleLongrun return ret, nil } +type ProjectsLocationsGenerateGroundedContentCall struct { + s *Service + location string + googleclouddiscoveryenginev1betagenerategroundedcontentrequest *GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// GenerateGroundedContent: Generates grounded content. +// +// - location: Location resource. Format: +// `projects/{project}/locations/{location}`. +func (r *ProjectsLocationsService) GenerateGroundedContent(location string, googleclouddiscoveryenginev1betagenerategroundedcontentrequest *GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequest) *ProjectsLocationsGenerateGroundedContentCall { + c := &ProjectsLocationsGenerateGroundedContentCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.location = location + c.googleclouddiscoveryenginev1betagenerategroundedcontentrequest = googleclouddiscoveryenginev1betagenerategroundedcontentrequest + return c +} + +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. +func (c *ProjectsLocationsGenerateGroundedContentCall) Fields(s ...googleapi.Field) *ProjectsLocationsGenerateGroundedContentCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsGenerateGroundedContentCall) Context(ctx context.Context) *ProjectsLocationsGenerateGroundedContentCall { + c.ctx_ = ctx + return c +} + +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. +func (c *ProjectsLocationsGenerateGroundedContentCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsGenerateGroundedContentCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) + body, err := googleapi.WithoutDataWrapper.JSONBuffer(c.googleclouddiscoveryenginev1betagenerategroundedcontentrequest) + if err != nil { + return nil, err + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+location}:generateGroundedContent") + 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{ + "location": c.location, + }) + c.s.logger.DebugContext(c.ctx_, "api request", "serviceName", apiName, "rpcName", "discoveryengine.projects.locations.generateGroundedContent", "request", internallog.HTTPRequest(req, body.Bytes())) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "discoveryengine.projects.locations.generateGroundedContent" call. +// Any non-2xx status code is an error. Response headers are in either +// *GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponse.ServerRespon +// se.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. +func (c *ProjectsLocationsGenerateGroundedContentCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponse, 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 := &GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponse{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + b, err := gensupport.DecodeResponseBytes(target, res) + if err != nil { + return nil, err + } + c.s.logger.DebugContext(c.ctx_, "api response", "serviceName", apiName, "rpcName", "discoveryengine.projects.locations.generateGroundedContent", "response", internallog.HTTPResponse(res, b)) + return ret, nil +} + type ProjectsLocationsCollectionsDataConnectorOperationsGetCall struct { s *Service name string diff --git a/jobs/v3/jobs-api.json b/jobs/v3/jobs-api.json index c265740e82..54f625ceaa 100644 --- a/jobs/v3/jobs-api.json +++ b/jobs/v3/jobs-api.json @@ -652,7 +652,7 @@ } } }, - "revision": "20240614", + "revision": "20241217", "rootUrl": "https://jobs.googleapis.com/", "schemas": { "ApplicationInfo": { @@ -2313,18 +2313,18 @@ "type": "object" }, "PostalAddress": { - "description": "Represents a postal address, e.g. for postal delivery or payments addresses. Given a postal address, a postal service can deliver items to a premise, P.O. Box or similar. It is not intended to model geographical locations (roads, towns, mountains). In typical usage an address would be created via user input or from importing existing data, depending on the type of process. Advice on address input / editing: - Use an internationalization-ready address widget such as https://github.com/google/libaddressinput) - Users should not be presented with UI elements for input or editing of fields outside countries where that field is used. For more guidance on how to use this schema, please see: https://support.google.com/business/answer/6397478", + "description": "Represents a postal address. For example for postal delivery or payments addresses. Given a postal address, a postal service can deliver items to a premise, P.O. Box or similar. It is not intended to model geographical locations (roads, towns, mountains). In typical usage an address would be created by user input or from importing existing data, depending on the type of process. Advice on address input / editing: - Use an internationalization-ready address widget such as https://github.com/google/libaddressinput) - Users should not be presented with UI elements for input or editing of fields outside countries where that field is used. For more guidance on how to use this schema, see: https://support.google.com/business/answer/6397478", "id": "PostalAddress", "properties": { "addressLines": { - "description": "Unstructured address lines describing the lower levels of an address. Because values in address_lines do not have type information and may sometimes contain multiple values in a single field (e.g. \"Austin, TX\"), it is important that the line order is clear. The order of address lines should be \"envelope order\" for the country/region of the address. In places where this can vary (e.g. Japan), address_language is used to make it explicit (e.g. \"ja\" for large-to-small ordering and \"ja-Latn\" or \"en\" for small-to-large). This way, the most specific line of an address can be selected based on the language. The minimum permitted structural representation of an address consists of a region_code with all remaining information placed in the address_lines. It would be possible to format such an address very approximately without geocoding, but no semantic reasoning could be made about any of the address components until it was at least partially resolved. Creating an address only containing a region_code and address_lines, and then geocoding is the recommended way to handle completely unstructured addresses (as opposed to guessing which parts of the address should be localities or administrative areas).", + "description": "Unstructured address lines describing the lower levels of an address. Because values in address_lines do not have type information and may sometimes contain multiple values in a single field (For example \"Austin, TX\"), it is important that the line order is clear. The order of address lines should be \"envelope order\" for the country/region of the address. In places where this can vary (For example Japan), address_language is used to make it explicit (For example \"ja\" for large-to-small ordering and \"ja-Latn\" or \"en\" for small-to-large). This way, the most specific line of an address can be selected based on the language. The minimum permitted structural representation of an address consists of a region_code with all remaining information placed in the address_lines. It would be possible to format such an address very approximately without geocoding, but no semantic reasoning could be made about any of the address components until it was at least partially resolved. Creating an address only containing a region_code and address_lines, and then geocoding is the recommended way to handle completely unstructured addresses (as opposed to guessing which parts of the address should be localities or administrative areas).", "items": { "type": "string" }, "type": "array" }, "administrativeArea": { - "description": "Optional. Highest administrative subdivision which is used for postal addresses of a country or region. For example, this can be a state, a province, an oblast, or a prefecture. Specifically, for Spain this is the province and not the autonomous community (e.g. \"Barcelona\" and not \"Catalonia\"). Many countries don't use an administrative area in postal addresses. E.g. in Switzerland this should be left unpopulated.", + "description": "Optional. Highest administrative subdivision which is used for postal addresses of a country or region. For example, this can be a state, a province, an oblast, or a prefecture. Specifically, for Spain this is the province and not the autonomous community (For example \"Barcelona\" and not \"Catalonia\"). Many countries don't use an administrative area in postal addresses. For example in Switzerland this should be left unpopulated.", "type": "string" }, "languageCode": { @@ -2340,7 +2340,7 @@ "type": "string" }, "postalCode": { - "description": "Optional. Postal code of the address. Not all countries use or require postal codes to be present, but where they are used, they may trigger additional validation with other parts of the address (e.g. state/zip validation in the U.S.A.).", + "description": "Optional. Postal code of the address. Not all countries use or require postal codes to be present, but where they are used, they may trigger additional validation with other parts of the address (For example state/zip validation in the U.S.A.).", "type": "string" }, "recipients": { @@ -2360,7 +2360,7 @@ "type": "integer" }, "sortingCode": { - "description": "Optional. Additional, country-specific, sorting code. This is not used in most regions. Where it is used, the value is either a string like \"CEDEX\", optionally followed by a number (e.g. \"CEDEX 7\"), or just a number alone, representing the \"sector code\" (Jamaica), \"delivery area indicator\" (Malawi) or \"post office indicator\" (e.g. Côte d'Ivoire).", + "description": "Optional. Additional, country-specific, sorting code. This is not used in most regions. Where it is used, the value is either a string like \"CEDEX\", optionally followed by a number (For example \"CEDEX 7\"), or just a number alone, representing the \"sector code\" (Jamaica), \"delivery area indicator\" (Malawi) or \"post office indicator\" (For example Côte d'Ivoire).", "type": "string" }, "sublocality": { @@ -2597,22 +2597,22 @@ "id": "TimeOfDay", "properties": { "hours": { - "description": "Hours of day in 24 hour format. Should be from 0 to 23. An API may choose to allow the value \"24:00:00\" for scenarios like business closing time.", + "description": "Hours of a day in 24 hour format. Must be greater than or equal to 0 and typically must be less than or equal to 23. An API may choose to allow the value \"24:00:00\" for scenarios like business closing time.", "format": "int32", "type": "integer" }, "minutes": { - "description": "Minutes of hour of day. Must be from 0 to 59.", + "description": "Minutes of an hour. Must be greater than or equal to 0 and less than or equal to 59.", "format": "int32", "type": "integer" }, "nanos": { - "description": "Fractions of seconds in nanoseconds. Must be from 0 to 999,999,999.", + "description": "Fractions of seconds, in nanoseconds. Must be greater than or equal to 0 and less than or equal to 999,999,999.", "format": "int32", "type": "integer" }, "seconds": { - "description": "Seconds of minutes of the time. Must normally be from 0 to 59. An API may allow the value 60 if it allows leap-seconds.", + "description": "Seconds of a minute. Must be greater than or equal to 0 and typically must be less than or equal to 59. An API may allow the value 60 if it allows leap-seconds.", "format": "int32", "type": "integer" } diff --git a/jobs/v3/jobs-gen.go b/jobs/v3/jobs-gen.go index a9cae2b8af..a074368e35 100644 --- a/jobs/v3/jobs-gen.go +++ b/jobs/v3/jobs-gen.go @@ -2401,42 +2401,43 @@ func (s *NumericBucketingResult) UnmarshalJSON(data []byte) error { return nil } -// PostalAddress: Represents a postal address, e.g. for postal delivery or -// payments addresses. Given a postal address, a postal service can deliver +// PostalAddress: Represents a postal address. For example for postal delivery +// or payments addresses. Given a postal address, a postal service can deliver // items to a premise, P.O. Box or similar. It is not intended to model // geographical locations (roads, towns, mountains). In typical usage an -// address would be created via user input or from importing existing data, +// address would be created by user input or from importing existing data, // depending on the type of process. Advice on address input / editing: - Use // an internationalization-ready address widget such as // https://github.com/google/libaddressinput) - Users should not be presented // with UI elements for input or editing of fields outside countries where that -// field is used. For more guidance on how to use this schema, please see: +// field is used. For more guidance on how to use this schema, see: // https://support.google.com/business/answer/6397478 type PostalAddress struct { // AddressLines: Unstructured address lines describing the lower levels of an // address. Because values in address_lines do not have type information and - // may sometimes contain multiple values in a single field (e.g. "Austin, TX"), - // it is important that the line order is clear. The order of address lines - // should be "envelope order" for the country/region of the address. In places - // where this can vary (e.g. Japan), address_language is used to make it - // explicit (e.g. "ja" for large-to-small ordering and "ja-Latn" or "en" for - // small-to-large). This way, the most specific line of an address can be - // selected based on the language. The minimum permitted structural - // representation of an address consists of a region_code with all remaining - // information placed in the address_lines. It would be possible to format such - // an address very approximately without geocoding, but no semantic reasoning - // could be made about any of the address components until it was at least - // partially resolved. Creating an address only containing a region_code and - // address_lines, and then geocoding is the recommended way to handle + // may sometimes contain multiple values in a single field (For example + // "Austin, TX"), it is important that the line order is clear. The order of + // address lines should be "envelope order" for the country/region of the + // address. In places where this can vary (For example Japan), address_language + // is used to make it explicit (For example "ja" for large-to-small ordering + // and "ja-Latn" or "en" for small-to-large). This way, the most specific line + // of an address can be selected based on the language. The minimum permitted + // structural representation of an address consists of a region_code with all + // remaining information placed in the address_lines. It would be possible to + // format such an address very approximately without geocoding, but no semantic + // reasoning could be made about any of the address components until it was at + // least partially resolved. Creating an address only containing a region_code + // and address_lines, and then geocoding is the recommended way to handle // completely unstructured addresses (as opposed to guessing which parts of the // address should be localities or administrative areas). AddressLines []string `json:"addressLines,omitempty"` // AdministrativeArea: Optional. Highest administrative subdivision which is // used for postal addresses of a country or region. For example, this can be a // state, a province, an oblast, or a prefecture. Specifically, for Spain this - // is the province and not the autonomous community (e.g. "Barcelona" and not - // "Catalonia"). Many countries don't use an administrative area in postal - // addresses. E.g. in Switzerland this should be left unpopulated. + // is the province and not the autonomous community (For example "Barcelona" + // and not "Catalonia"). Many countries don't use an administrative area in + // postal addresses. For example in Switzerland this should be left + // unpopulated. AdministrativeArea string `json:"administrativeArea,omitempty"` // LanguageCode: Optional. BCP-47 language code of the contents of this address // (if known). This is often the UI language of the input form or is expected @@ -2456,7 +2457,7 @@ type PostalAddress struct { Organization string `json:"organization,omitempty"` // PostalCode: Optional. Postal code of the address. Not all countries use or // require postal codes to be present, but where they are used, they may - // trigger additional validation with other parts of the address (e.g. + // trigger additional validation with other parts of the address (For example // state/zip validation in the U.S.A.). PostalCode string `json:"postalCode,omitempty"` // Recipients: Optional. The recipient at the address. This field may, under @@ -2475,9 +2476,10 @@ type PostalAddress struct { Revision int64 `json:"revision,omitempty"` // SortingCode: Optional. Additional, country-specific, sorting code. This is // not used in most regions. Where it is used, the value is either a string - // like "CEDEX", optionally followed by a number (e.g. "CEDEX 7"), or just a - // number alone, representing the "sector code" (Jamaica), "delivery area - // indicator" (Malawi) or "post office indicator" (e.g. Côte d'Ivoire). + // like "CEDEX", optionally followed by a number (For example "CEDEX 7"), or + // just a number alone, representing the "sector code" (Jamaica), "delivery + // area indicator" (Malawi) or "post office indicator" (For example Côte + // d'Ivoire). SortingCode string `json:"sortingCode,omitempty"` // Sublocality: Optional. Sublocality of the address. For example, this can be // neighborhoods, boroughs, districts. @@ -2832,16 +2834,19 @@ func (s SpellingCorrection) MarshalJSON() ([]byte, error) { // significant or are specified elsewhere. An API may choose to allow leap // seconds. Related types are google.type.Date and `google.protobuf.Timestamp`. type TimeOfDay struct { - // Hours: Hours of day in 24 hour format. Should be from 0 to 23. An API may - // choose to allow the value "24:00:00" for scenarios like business closing - // time. + // Hours: Hours of a day in 24 hour format. Must be greater than or equal to 0 + // and typically must be less than or equal to 23. An API may choose to allow + // the value "24:00:00" for scenarios like business closing time. Hours int64 `json:"hours,omitempty"` - // Minutes: Minutes of hour of day. Must be from 0 to 59. + // Minutes: Minutes of an hour. Must be greater than or equal to 0 and less + // than or equal to 59. Minutes int64 `json:"minutes,omitempty"` - // Nanos: Fractions of seconds in nanoseconds. Must be from 0 to 999,999,999. + // Nanos: Fractions of seconds, in nanoseconds. Must be greater than or equal + // to 0 and less than or equal to 999,999,999. Nanos int64 `json:"nanos,omitempty"` - // Seconds: Seconds of minutes of the time. Must normally be from 0 to 59. An - // API may allow the value 60 if it allows leap-seconds. + // Seconds: Seconds of a minute. Must be greater than or equal to 0 and + // typically must be less than or equal to 59. An API may allow the value 60 if + // it allows leap-seconds. Seconds int64 `json:"seconds,omitempty"` // ForceSendFields is a list of field names (e.g. "Hours") to unconditionally // include in API requests. By default, fields with empty or default values are diff --git a/pubsub/v1/pubsub-api.json b/pubsub/v1/pubsub-api.json index b638bd10d6..b66e635054 100644 --- a/pubsub/v1/pubsub-api.json +++ b/pubsub/v1/pubsub-api.json @@ -1638,7 +1638,7 @@ } } }, - "revision": "20240918", + "revision": "20241212", "rootUrl": "https://pubsub.googleapis.com/", "schemas": { "AcknowledgeRequest": { @@ -1656,7 +1656,7 @@ "type": "object" }, "AnalyticsHubSubscriptionInfo": { - "description": "Information about an associated Analytics Hub subscription (https://cloud.google.com/bigquery/docs/analytics-hub-manage-subscriptions).", + "description": "Information about an associated [Analytics Hub subscription](https://cloud.google.com/bigquery/docs/analytics-hub-manage-subscriptions).", "id": "AnalyticsHubSubscriptionInfo", "properties": { "listing": { diff --git a/run/v2/run-api.json b/run/v2/run-api.json index 57d8b2e074..e9df108419 100644 --- a/run/v2/run-api.json +++ b/run/v2/run-api.json @@ -1526,7 +1526,7 @@ } } }, - "revision": "20241206", + "revision": "20241213", "rootUrl": "https://run.googleapis.com/", "schemas": { "GoogleCloudRunV2BinaryAuthorization": { @@ -3433,6 +3433,11 @@ "format": "int32", "type": "integer" }, + "maxInstanceCount": { + "description": "Optional. total max instances for the service. This number of instances is divided among all revisions with specified traffic based on the percent of traffic they are receiving.", + "format": "int32", + "type": "integer" + }, "minInstanceCount": { "description": "Optional. total min instances for the service. This number of instances is divided among all revisions with specified traffic based on the percent of traffic they are receiving.", "format": "int32", diff --git a/run/v2/run-gen.go b/run/v2/run-gen.go index 535ae6599b..51102dbef4 100644 --- a/run/v2/run-gen.go +++ b/run/v2/run-gen.go @@ -2422,6 +2422,10 @@ type GoogleCloudRunV2ServiceScaling struct { // manual scaling mode. This number of instances is divided among all revisions // with specified traffic based on the percent of traffic they are receiving. ManualInstanceCount int64 `json:"manualInstanceCount,omitempty"` + // MaxInstanceCount: Optional. total max instances for the service. This number + // of instances is divided among all revisions with specified traffic based on + // the percent of traffic they are receiving. + MaxInstanceCount int64 `json:"maxInstanceCount,omitempty"` // MinInstanceCount: Optional. total min instances for the service. This number // of instances is divided among all revisions with specified traffic based on // the percent of traffic they are receiving.