Skip to content

Commit 9e8db12

Browse files
feat: Automated regeneration of DiscoveryEngine client (googleapis#12328)
Auto-created at 2024-10-15 13:16:04 +0000 using the toys pull request generator.
1 parent 7cb9c26 commit 9e8db12

27 files changed

+932
-226
lines changed

clients/discovery_engine/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ Install this package from [Hex](https://hex.pm) by adding
1111

1212
```elixir
1313
def deps do
14-
[{:google_api_discovery_engine, "~> 0.18"}]
14+
[{:google_api_discovery_engine, "~> 0.19"}]
1515
end
1616
```
1717

clients/discovery_engine/lib/google_api/discovery_engine/v1/api/projects.ex

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -344,8 +344,10 @@ defmodule GoogleApi.DiscoveryEngine.V1.Api.Projects do
344344
* `:quotaUser` (*type:* `String.t`) - 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.
345345
* `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart").
346346
* `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart").
347+
* `:cmekConfigName` (*type:* `String.t`) - Resource name of the CmekConfig to use for protecting this DataStore.
347348
* `:createAdvancedSiteSearch` (*type:* `boolean()`) - A boolean flag indicating whether user want to directly create an advanced data store for site search. If the data store is not configured as site search (GENERIC vertical and PUBLIC_WEBSITE content_config), this flag will be ignored.
348349
* `:dataStoreId` (*type:* `String.t`) - Required. The ID to use for the DataStore, which will become the final component of the DataStore's resource name. This field must conform to [RFC-1034](https://tools.ietf.org/html/rfc1034) standard with a length limit of 63 characters. Otherwise, an INVALID_ARGUMENT error is returned.
350+
* `:disableCmek` (*type:* `boolean()`) - DataStore without CMEK protections. If a default CmekConfig is set for the project, setting this field will override the default CmekConfig as well.
349351
* `:skipDefaultSchemaCreation` (*type:* `boolean()`) - A boolean flag indicating whether to skip the default schema creation for the data store. Only enable this flag if you are certain that the default schema is incompatible with your use case. If set to true, you must manually create a schema for the data store before any documents can be ingested. This flag cannot be specified if `data_store.starting_schema` is specified.
350352
* `:body` (*type:* `GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1DataStore.t`) -
351353
* `opts` (*type:* `keyword()`) - Call options
@@ -383,8 +385,10 @@ defmodule GoogleApi.DiscoveryEngine.V1.Api.Projects do
383385
:quotaUser => :query,
384386
:uploadType => :query,
385387
:upload_protocol => :query,
388+
:cmekConfigName => :query,
386389
:createAdvancedSiteSearch => :query,
387390
:dataStoreId => :query,
391+
:disableCmek => :query,
388392
:skipDefaultSchemaCreation => :query,
389393
:body => :body
390394
}
@@ -8158,8 +8162,10 @@ defmodule GoogleApi.DiscoveryEngine.V1.Api.Projects do
81588162
* `:quotaUser` (*type:* `String.t`) - 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.
81598163
* `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart").
81608164
* `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart").
8165+
* `:cmekConfigName` (*type:* `String.t`) - Resource name of the CmekConfig to use for protecting this DataStore.
81618166
* `:createAdvancedSiteSearch` (*type:* `boolean()`) - A boolean flag indicating whether user want to directly create an advanced data store for site search. If the data store is not configured as site search (GENERIC vertical and PUBLIC_WEBSITE content_config), this flag will be ignored.
81628167
* `:dataStoreId` (*type:* `String.t`) - Required. The ID to use for the DataStore, which will become the final component of the DataStore's resource name. This field must conform to [RFC-1034](https://tools.ietf.org/html/rfc1034) standard with a length limit of 63 characters. Otherwise, an INVALID_ARGUMENT error is returned.
8168+
* `:disableCmek` (*type:* `boolean()`) - DataStore without CMEK protections. If a default CmekConfig is set for the project, setting this field will override the default CmekConfig as well.
81638169
* `:skipDefaultSchemaCreation` (*type:* `boolean()`) - A boolean flag indicating whether to skip the default schema creation for the data store. Only enable this flag if you are certain that the default schema is incompatible with your use case. If set to true, you must manually create a schema for the data store before any documents can be ingested. This flag cannot be specified if `data_store.starting_schema` is specified.
81648170
* `:body` (*type:* `GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1DataStore.t`) -
81658171
* `opts` (*type:* `keyword()`) - Call options
@@ -8197,8 +8203,10 @@ defmodule GoogleApi.DiscoveryEngine.V1.Api.Projects do
81978203
:quotaUser => :query,
81988204
:uploadType => :query,
81998205
:upload_protocol => :query,
8206+
:cmekConfigName => :query,
82008207
:createAdvancedSiteSearch => :query,
82018208
:dataStoreId => :query,
8209+
:disableCmek => :query,
82028210
:skipDefaultSchemaCreation => :query,
82038211
:body => :body
82048212
}

clients/discovery_engine/lib/google_api/discovery_engine/v1/metadata.ex

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ defmodule GoogleApi.DiscoveryEngine.V1 do
2020
API client metadata for GoogleApi.DiscoveryEngine.V1.
2121
"""
2222

23-
@discovery_revision "20241004"
23+
@discovery_revision "20241010"
2424

2525
def discovery_revision(), do: @discovery_revision
2626
end
Lines changed: 66 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,66 @@
1+
# Copyright 2019 Google LLC
2+
#
3+
# Licensed under the Apache License, Version 2.0 (the "License");
4+
# you may not use this file except in compliance with the License.
5+
# You may obtain a copy of the License at
6+
#
7+
# http://www.apache.org/licenses/LICENSE-2.0
8+
#
9+
# Unless required by applicable law or agreed to in writing, software
10+
# distributed under the License is distributed on an "AS IS" BASIS,
11+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12+
# See the License for the specific language governing permissions and
13+
# limitations under the License.
14+
15+
# NOTE: This file is auto generated by the elixir code generator program.
16+
# Do not edit this file manually.
17+
18+
defmodule GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1CmekConfig do
19+
@moduledoc """
20+
Configurations used to enable CMEK data encryption with Cloud KMS keys.
21+
22+
## Attributes
23+
24+
* `isDefault` (*type:* `boolean()`, *default:* `nil`) - Output only. The default CmekConfig for the Customer.
25+
* `kmsKey` (*type:* `String.t`, *default:* `nil`) - Kms key resource name which will be used to encrypt resources `projects/{project}/locations/{location}/keyRings/{keyRing}/cryptoKeys/{keyId}`.
26+
* `kmsKeyVersion` (*type:* `String.t`, *default:* `nil`) - Kms key version resource name which will be used to encrypt resources `/cryptoKeyVersions/{keyVersion}`.
27+
* `lastRotationTimestampMicros` (*type:* `String.t`, *default:* `nil`) - Output only. The timestamp of the last key rotation.
28+
* `name` (*type:* `String.t`, *default:* `nil`) - Required. Name of the CmekConfig, of the form `projects/{project}/locations/{location}/cmekConfig` or `projects/{project}/locations/{location}/cmekConfigs/{cmekConfig}`.
29+
* `state` (*type:* `String.t`, *default:* `nil`) - Output only. State of the CmekConfig.
30+
"""
31+
32+
use GoogleApi.Gax.ModelBase
33+
34+
@type t :: %__MODULE__{
35+
:isDefault => boolean() | nil,
36+
:kmsKey => String.t() | nil,
37+
:kmsKeyVersion => String.t() | nil,
38+
:lastRotationTimestampMicros => String.t() | nil,
39+
:name => String.t() | nil,
40+
:state => String.t() | nil
41+
}
42+
43+
field(:isDefault)
44+
field(:kmsKey)
45+
field(:kmsKeyVersion)
46+
field(:lastRotationTimestampMicros)
47+
field(:name)
48+
field(:state)
49+
end
50+
51+
defimpl Poison.Decoder,
52+
for: GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1CmekConfig do
53+
def decode(value, options) do
54+
GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1CmekConfig.decode(
55+
value,
56+
options
57+
)
58+
end
59+
end
60+
61+
defimpl Poison.Encoder,
62+
for: GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1CmekConfig do
63+
def encode(value, options) do
64+
GoogleApi.Gax.ModelBase.encode(value, options)
65+
end
66+
end

clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_data_store.ex

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,12 +22,14 @@ defmodule GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1DataSto
2222
## Attributes
2323
2424
* `billingEstimation` (*type:* `GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1DataStoreBillingEstimation.t`, *default:* `nil`) - Output only. Data size estimation for billing.
25+
* `cmekConfig` (*type:* `GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1CmekConfig.t`, *default:* `nil`) - Output only. CMEK-related information for the DataStore.
2526
* `contentConfig` (*type:* `String.t`, *default:* `nil`) - Immutable. The content config of the data store. If this field is unset, the server behavior defaults to ContentConfig.NO_CONTENT.
2627
* `createTime` (*type:* `DateTime.t`, *default:* `nil`) - Output only. Timestamp the DataStore was created at.
2728
* `defaultSchemaId` (*type:* `String.t`, *default:* `nil`) - Output only. The id of the default Schema asscociated to this data store.
2829
* `displayName` (*type:* `String.t`, *default:* `nil`) - 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.
2930
* `documentProcessingConfig` (*type:* `GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1DocumentProcessingConfig.t`, *default:* `nil`) - Configuration for Document understanding and enrichment.
3031
* `industryVertical` (*type:* `String.t`, *default:* `nil`) - Immutable. The industry vertical that the data store registers.
32+
* `kmsKeyName` (*type:* `String.t`, *default:* `nil`) - 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.
3133
* `name` (*type:* `String.t`, *default:* `nil`) - 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.
3234
* `servingConfigDataStore` (*type:* `GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1ServingConfigDataStore.t`, *default:* `nil`) - Optional. Stores serving config at DataStore level.
3335
* `solutionTypes` (*type:* `list(String.t)`, *default:* `nil`) - 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.
@@ -41,6 +43,8 @@ defmodule GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1DataSto
4143
:billingEstimation =>
4244
GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1DataStoreBillingEstimation.t()
4345
| nil,
46+
:cmekConfig =>
47+
GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1CmekConfig.t() | nil,
4448
:contentConfig => String.t() | nil,
4549
:createTime => DateTime.t() | nil,
4650
:defaultSchemaId => String.t() | nil,
@@ -49,6 +53,7 @@ defmodule GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1DataSto
4953
GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1DocumentProcessingConfig.t()
5054
| nil,
5155
:industryVertical => String.t() | nil,
56+
:kmsKeyName => String.t() | nil,
5257
:name => String.t() | nil,
5358
:servingConfigDataStore =>
5459
GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1ServingConfigDataStore.t()
@@ -65,6 +70,8 @@ defmodule GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1DataSto
6570
as: GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1DataStoreBillingEstimation
6671
)
6772

73+
field(:cmekConfig, as: GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1CmekConfig)
74+
6875
field(:contentConfig)
6976
field(:createTime, as: DateTime)
7077
field(:defaultSchemaId)
@@ -75,6 +82,7 @@ defmodule GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1DataSto
7582
)
7683

7784
field(:industryVertical)
85+
field(:kmsKeyName)
7886
field(:name)
7987

8088
field(:servingConfigDataStore,

clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_search_request.ex

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,7 @@ defmodule GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1SearchR
3131
* `imageQuery` (*type:* `GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1SearchRequestImageQuery.t`, *default:* `nil`) - Raw image query.
3232
* `languageCode` (*type:* `String.t`, *default:* `nil`) - 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.
3333
* `offset` (*type:* `integer()`, *default:* `nil`) - 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.
34+
* `oneBoxPageSize` (*type:* `integer()`, *default:* `nil`) - The maximum number of results to return for OneBox. This applies to each OneBox type individually. Default number is 10.
3435
* `orderBy` (*type:* `String.t`, *default:* `nil`) - 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.
3536
* `pageSize` (*type:* `integer()`, *default:* `nil`) - 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.
3637
* `pageToken` (*type:* `String.t`, *default:* `nil`) - 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.
@@ -74,6 +75,7 @@ defmodule GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1SearchR
7475
| nil,
7576
:languageCode => String.t() | nil,
7677
:offset => integer() | nil,
78+
:oneBoxPageSize => integer() | nil,
7779
:orderBy => String.t() | nil,
7880
:pageSize => integer() | nil,
7981
:pageToken => String.t() | nil,
@@ -129,6 +131,7 @@ defmodule GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1SearchR
129131

130132
field(:languageCode)
131133
field(:offset)
134+
field(:oneBoxPageSize)
132135
field(:orderBy)
133136
field(:pageSize)
134137
field(:pageToken)
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,54 @@
1+
# Copyright 2019 Google LLC
2+
#
3+
# Licensed under the Apache License, Version 2.0 (the "License");
4+
# you may not use this file except in compliance with the License.
5+
# You may obtain a copy of the License at
6+
#
7+
# http://www.apache.org/licenses/LICENSE-2.0
8+
#
9+
# Unless required by applicable law or agreed to in writing, software
10+
# distributed under the License is distributed on an "AS IS" BASIS,
11+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12+
# See the License for the specific language governing permissions and
13+
# limitations under the License.
14+
15+
# NOTE: This file is auto generated by the elixir code generator program.
16+
# Do not edit this file manually.
17+
18+
defmodule GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1UpdateCmekConfigMetadata do
19+
@moduledoc """
20+
Metadata related to the progress of the CmekConfigService.UpdateCmekConfig operation. This will be returned by the google.longrunning.Operation.metadata field.
21+
22+
## Attributes
23+
24+
* `createTime` (*type:* `DateTime.t`, *default:* `nil`) - Operation create time.
25+
* `updateTime` (*type:* `DateTime.t`, *default:* `nil`) - Operation last update time. If the operation is done, this is also the finish time.
26+
"""
27+
28+
use GoogleApi.Gax.ModelBase
29+
30+
@type t :: %__MODULE__{
31+
:createTime => DateTime.t() | nil,
32+
:updateTime => DateTime.t() | nil
33+
}
34+
35+
field(:createTime, as: DateTime)
36+
field(:updateTime, as: DateTime)
37+
end
38+
39+
defimpl Poison.Decoder,
40+
for: GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1UpdateCmekConfigMetadata do
41+
def decode(value, options) do
42+
GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1UpdateCmekConfigMetadata.decode(
43+
value,
44+
options
45+
)
46+
end
47+
end
48+
49+
defimpl Poison.Encoder,
50+
for: GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1UpdateCmekConfigMetadata do
51+
def encode(value, options) do
52+
GoogleApi.Gax.ModelBase.encode(value, options)
53+
end
54+
end

0 commit comments

Comments
 (0)