From 179ea314053bef7582f4be3d72922c13eed0ccd8 Mon Sep 17 00:00:00 2001 From: yoshi-code-bot <70984784+yoshi-code-bot@users.noreply.github.com> Date: Wed, 18 Dec 2024 05:24:22 -0800 Subject: [PATCH] feat: Automated regeneration of DiscoveryEngine client (#12739) Auto-created at 2024-12-18 13:17:34 +0000 using the toys pull request generator. --- clients/discovery_engine/README.md | 2 +- .../discovery_engine/v1/api/projects.ex | 79 ++++++++++ .../discovery_engine/v1/metadata.ex | 2 +- ...le_cloud_discoveryengine_v1_cmek_config.ex | 12 ++ ...gle_cloud_discoveryengine_v1_data_store.ex | 3 + ...oogle_cloud_discoveryengine_v1_document.ex | 2 +- ...iscoveryengine_v1_document_index_status.ex | 5 +- ...ne_v1_generate_grounded_content_request.ex | 90 +++++++++++ ...request_dynamic_retrieval_configuration.ex | 58 +++++++ ...nfiguration_dynamic_retrieval_predictor.ex | 56 +++++++ ...rounded_content_request_generation_spec.ex | 77 +++++++++ ...ounded_content_request_grounding_source.ex | 76 +++++++++ ...t_grounding_source_google_search_source.ex | 58 +++++++ ..._request_grounding_source_inline_source.ex | 62 ++++++++ ..._request_grounding_source_search_source.ex | 62 ++++++++ ...grounded_content_request_grounding_spec.ex | 61 ++++++++ ...e_v1_generate_grounded_content_response.ex | 61 ++++++++ ...ate_grounded_content_response_candidate.ex | 73 +++++++++ ...t_response_candidate_grounding_metadata.ex | 95 +++++++++++ ...ing_metadata_dynamic_retrieval_metadata.ex | 58 +++++++ ...ta_dynamic_retrieval_predictor_metadata.ex | 56 +++++++ ...te_grounding_metadata_grounding_support.ex | 59 +++++++ ...e_grounding_metadata_retrieval_metadata.ex | 62 ++++++++ ...e_grounding_metadata_search_entry_point.ex | 56 +++++++ ...ryengine_v1_grounded_generation_content.ex | 63 ++++++++ ...ine_v1_grounded_generation_content_part.ex | 53 +++++++ ...ud_discoveryengine_v1_single_region_key.ex | 51 ++++++ ...d_discoveryengine_v1alpha_action_config.ex | 54 +++++++ ...oud_discoveryengine_v1alpha_cmek_config.ex | 12 ++ ...loud_discoveryengine_v1alpha_collection.ex | 66 ++++++++ ...d_discoveryengine_v1alpha_connector_run.ex | 84 ++++++++++ ...engine_v1alpha_connector_run_entity_run.ex | 78 ++++++++++ ..._discoveryengine_v1alpha_data_connector.ex | 146 +++++++++++++++++ ...ne_v1alpha_data_connector_source_entity.ex | 62 ++++++++ ...loud_discoveryengine_v1alpha_data_store.ex | 3 + ...gine_v1alpha_delete_collection_metadata.ex | 56 +++++++ ...coveryengine_v1alpha_destination_config.ex | 66 ++++++++ ..._v1alpha_destination_config_destination.ex | 56 +++++++ ...engine_v1alpha_identity_schedule_config.ex | 51 ++++++ ..._v1alpha_set_up_data_connector_metadata.ex | 48 ++++++ ...scoveryengine_v1alpha_single_region_key.ex | 51 ++++++ ...gine_v1alpha_update_collection_metadata.ex | 56 +++++++ ...loud_discoveryengine_v1beta_cmek_config.ex | 12 ++ ...cloud_discoveryengine_v1beta_data_store.ex | 3 + ...iscoveryengine_v1beta_single_region_key.ex | 51 ++++++ .../v1/model/google_type_date_time.ex | 70 +++++++++ .../v1/model/google_type_time_zone.ex | 49 ++++++ .../discovery_engine/v1beta/api/projects.ex | 79 ++++++++++ .../discovery_engine/v1beta/metadata.ex | 2 +- ...le_cloud_discoveryengine_v1_cmek_config.ex | 12 ++ ...gle_cloud_discoveryengine_v1_data_store.ex | 3 + ...ud_discoveryengine_v1_single_region_key.ex | 51 ++++++ ...d_discoveryengine_v1alpha_action_config.ex | 54 +++++++ ...oud_discoveryengine_v1alpha_cmek_config.ex | 12 ++ ...loud_discoveryengine_v1alpha_collection.ex | 66 ++++++++ ...d_discoveryengine_v1alpha_connector_run.ex | 85 ++++++++++ ...engine_v1alpha_connector_run_entity_run.ex | 80 ++++++++++ ..._discoveryengine_v1alpha_data_connector.ex | 147 ++++++++++++++++++ ...ne_v1alpha_data_connector_source_entity.ex | 62 ++++++++ ...loud_discoveryengine_v1alpha_data_store.ex | 3 + ...gine_v1alpha_delete_collection_metadata.ex | 56 +++++++ ...coveryengine_v1alpha_destination_config.ex | 66 ++++++++ ..._v1alpha_destination_config_destination.ex | 56 +++++++ ...engine_v1alpha_identity_schedule_config.ex | 53 +++++++ ..._v1alpha_set_up_data_connector_metadata.ex | 48 ++++++ ...scoveryengine_v1alpha_single_region_key.ex | 51 ++++++ ...gine_v1alpha_update_collection_metadata.ex | 56 +++++++ ...loud_discoveryengine_v1beta_cmek_config.ex | 12 ++ ...cloud_discoveryengine_v1beta_data_store.ex | 3 + ...e_cloud_discoveryengine_v1beta_document.ex | 2 +- ...veryengine_v1beta_document_index_status.ex | 5 +- ...1beta_generate_grounded_content_request.ex | 92 +++++++++++ ...request_dynamic_retrieval_configuration.ex | 58 +++++++ ...nfiguration_dynamic_retrieval_predictor.ex | 56 +++++++ ...rounded_content_request_generation_spec.ex | 77 +++++++++ ...ounded_content_request_grounding_source.ex | 76 +++++++++ ...t_grounding_source_google_search_source.ex | 58 +++++++ ..._request_grounding_source_inline_source.ex | 64 ++++++++ ..._request_grounding_source_search_source.ex | 62 ++++++++ ...grounded_content_request_grounding_spec.ex | 61 ++++++++ ...beta_generate_grounded_content_response.ex | 61 ++++++++ ...ate_grounded_content_response_candidate.ex | 74 +++++++++ ...t_response_candidate_grounding_metadata.ex | 97 ++++++++++++ ...ing_metadata_dynamic_retrieval_metadata.ex | 58 +++++++ ...ta_dynamic_retrieval_predictor_metadata.ex | 56 +++++++ ...te_grounding_metadata_grounding_support.ex | 59 +++++++ ...e_grounding_metadata_retrieval_metadata.ex | 62 ++++++++ ...e_grounding_metadata_search_entry_point.ex | 56 +++++++ ...gine_v1beta_grounded_generation_content.ex | 65 ++++++++ ...v1beta_grounded_generation_content_part.ex | 53 +++++++ ...iscoveryengine_v1beta_single_region_key.ex | 51 ++++++ .../v1beta/model/google_type_date_time.ex | 70 +++++++++ .../v1beta/model/google_type_time_zone.ex | 49 ++++++ clients/discovery_engine/mix.exs | 2 +- 94 files changed, 4939 insertions(+), 8 deletions(-) create mode 100644 clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_generate_grounded_content_request.ex create mode 100644 clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_generate_grounded_content_request_dynamic_retrieval_configuration.ex create mode 100644 clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_generate_grounded_content_request_dynamic_retrieval_configuration_dynamic_retrieval_predictor.ex create mode 100644 clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_generate_grounded_content_request_generation_spec.ex create mode 100644 clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_generate_grounded_content_request_grounding_source.ex create mode 100644 clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_generate_grounded_content_request_grounding_source_google_search_source.ex create mode 100644 clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_generate_grounded_content_request_grounding_source_inline_source.ex create mode 100644 clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_generate_grounded_content_request_grounding_source_search_source.ex create mode 100644 clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_generate_grounded_content_request_grounding_spec.ex create mode 100644 clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_generate_grounded_content_response.ex create mode 100644 clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_generate_grounded_content_response_candidate.ex create mode 100644 clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_generate_grounded_content_response_candidate_grounding_metadata.ex create mode 100644 clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_generate_grounded_content_response_candidate_grounding_metadata_dynamic_retrieval_metadata.ex create mode 100644 clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_generate_grounded_content_response_candidate_grounding_metadata_dynamic_retrieval_predictor_metadata.ex create mode 100644 clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_generate_grounded_content_response_candidate_grounding_metadata_grounding_support.ex create mode 100644 clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_generate_grounded_content_response_candidate_grounding_metadata_retrieval_metadata.ex create mode 100644 clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_generate_grounded_content_response_candidate_grounding_metadata_search_entry_point.ex create mode 100644 clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_grounded_generation_content.ex create mode 100644 clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_grounded_generation_content_part.ex create mode 100644 clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_single_region_key.ex create mode 100644 clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1alpha_action_config.ex create mode 100644 clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1alpha_collection.ex create mode 100644 clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1alpha_connector_run.ex create mode 100644 clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1alpha_connector_run_entity_run.ex create mode 100644 clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1alpha_data_connector.ex create mode 100644 clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1alpha_data_connector_source_entity.ex create mode 100644 clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1alpha_delete_collection_metadata.ex create mode 100644 clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1alpha_destination_config.ex create mode 100644 clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1alpha_destination_config_destination.ex create mode 100644 clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1alpha_identity_schedule_config.ex create mode 100644 clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1alpha_set_up_data_connector_metadata.ex create mode 100644 clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1alpha_single_region_key.ex create mode 100644 clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1alpha_update_collection_metadata.ex create mode 100644 clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1beta_single_region_key.ex create mode 100644 clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_type_date_time.ex create mode 100644 clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_type_time_zone.ex create mode 100644 clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1_single_region_key.ex create mode 100644 clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1alpha_action_config.ex create mode 100644 clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1alpha_collection.ex create mode 100644 clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1alpha_connector_run.ex create mode 100644 clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1alpha_connector_run_entity_run.ex create mode 100644 clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1alpha_data_connector.ex create mode 100644 clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1alpha_data_connector_source_entity.ex create mode 100644 clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1alpha_delete_collection_metadata.ex create mode 100644 clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1alpha_destination_config.ex create mode 100644 clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1alpha_destination_config_destination.ex create mode 100644 clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1alpha_identity_schedule_config.ex create mode 100644 clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1alpha_set_up_data_connector_metadata.ex create mode 100644 clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1alpha_single_region_key.ex create mode 100644 clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1alpha_update_collection_metadata.ex create mode 100644 clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_generate_grounded_content_request.ex create mode 100644 clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_generate_grounded_content_request_dynamic_retrieval_configuration.ex create mode 100644 clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_generate_grounded_content_request_dynamic_retrieval_configuration_dynamic_retrieval_predictor.ex create mode 100644 clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_generate_grounded_content_request_generation_spec.ex create mode 100644 clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_generate_grounded_content_request_grounding_source.ex create mode 100644 clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_generate_grounded_content_request_grounding_source_google_search_source.ex create mode 100644 clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_generate_grounded_content_request_grounding_source_inline_source.ex create mode 100644 clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_generate_grounded_content_request_grounding_source_search_source.ex create mode 100644 clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_generate_grounded_content_request_grounding_spec.ex create mode 100644 clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_generate_grounded_content_response.ex create mode 100644 clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_generate_grounded_content_response_candidate.ex create mode 100644 clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_generate_grounded_content_response_candidate_grounding_metadata.ex create mode 100644 clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_generate_grounded_content_response_candidate_grounding_metadata_dynamic_retrieval_metadata.ex create mode 100644 clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_generate_grounded_content_response_candidate_grounding_metadata_dynamic_retrieval_predictor_metadata.ex create mode 100644 clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_generate_grounded_content_response_candidate_grounding_metadata_grounding_support.ex create mode 100644 clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_generate_grounded_content_response_candidate_grounding_metadata_retrieval_metadata.ex create mode 100644 clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_generate_grounded_content_response_candidate_grounding_metadata_search_entry_point.ex create mode 100644 clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_grounded_generation_content.ex create mode 100644 clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_grounded_generation_content_part.ex create mode 100644 clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_single_region_key.ex create mode 100644 clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_type_date_time.ex create mode 100644 clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_type_time_zone.ex diff --git a/clients/discovery_engine/README.md b/clients/discovery_engine/README.md index a0c9007b6b..a84914a392 100644 --- a/clients/discovery_engine/README.md +++ b/clients/discovery_engine/README.md @@ -11,7 +11,7 @@ Install this package from [Hex](https://hex.pm) by adding ```elixir def deps do - [{:google_api_discovery_engine, "~> 0.27"}] + [{:google_api_discovery_engine, "~> 0.28"}] end ``` diff --git a/clients/discovery_engine/lib/google_api/discovery_engine/v1/api/projects.ex b/clients/discovery_engine/lib/google_api/discovery_engine/v1/api/projects.ex index 0e67abd80c..8b6c7623a0 100644 --- a/clients/discovery_engine/lib/google_api/discovery_engine/v1/api/projects.ex +++ b/clients/discovery_engine/lib/google_api/discovery_engine/v1/api/projects.ex @@ -89,6 +89,85 @@ defmodule GoogleApi.DiscoveryEngine.V1.Api.Projects do ) end + @doc """ + Generates grounded content. + + ## Parameters + + * `connection` (*type:* `GoogleApi.DiscoveryEngine.V1.Connection.t`) - Connection to server + * `location` (*type:* `String.t`) - Required. Location resource. Format: `projects/{project}/locations/{location}`. + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - 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. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `: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. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:body` (*type:* `GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentRequest.t`) - + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentResponse{}}` on success + * `{:error, info}` on failure + """ + @spec discoveryengine_projects_locations_generate_grounded_content( + Tesla.Env.client(), + String.t(), + keyword(), + keyword() + ) :: + {:ok, + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentResponse.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def discoveryengine_projects_locations_generate_grounded_content( + connection, + location, + optional_params \\ [], + opts \\ [] + ) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :body => :body + } + + request = + Request.new() + |> Request.method(:post) + |> Request.url("/v1/{+location}:generateGroundedContent", %{ + "location" => URI.encode(location, &URI.char_unreserved?/1) + }) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode( + opts ++ + [ + struct: + %GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentResponse{} + ] + ) + end + @doc """ Gets the latest state of a long-running operation. Clients can use this method to poll the operation result at intervals as recommended by the API service. diff --git a/clients/discovery_engine/lib/google_api/discovery_engine/v1/metadata.ex b/clients/discovery_engine/lib/google_api/discovery_engine/v1/metadata.ex index 2fffe8b34e..fe22657ac5 100644 --- a/clients/discovery_engine/lib/google_api/discovery_engine/v1/metadata.ex +++ b/clients/discovery_engine/lib/google_api/discovery_engine/v1/metadata.ex @@ -20,7 +20,7 @@ defmodule GoogleApi.DiscoveryEngine.V1 do API client metadata for GoogleApi.DiscoveryEngine.V1. """ - @discovery_revision "20241210" + @discovery_revision "20241216" def discovery_revision(), do: @discovery_revision end diff --git a/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_cmek_config.ex b/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_cmek_config.ex index c6e1c50678..2782336bd3 100644 --- a/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_cmek_config.ex +++ b/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_cmek_config.ex @@ -26,6 +26,7 @@ defmodule GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1CmekCon * `kmsKeyVersion` (*type:* `String.t`, *default:* `nil`) - Kms key version resource name which will be used to encrypt resources `/cryptoKeyVersions/{keyVersion}`. * `lastRotationTimestampMicros` (*type:* `String.t`, *default:* `nil`) - Output only. The timestamp of the last key rotation. * `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}`. + * `singleRegionKeys` (*type:* `list(GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1SingleRegionKey.t)`, *default:* `nil`) - Optional. Single-regional CMEKs that are required for some VAIS features. * `state` (*type:* `String.t`, *default:* `nil`) - Output only. State of the CmekConfig. """ @@ -37,6 +38,11 @@ defmodule GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1CmekCon :kmsKeyVersion => String.t() | nil, :lastRotationTimestampMicros => String.t() | nil, :name => String.t() | nil, + :singleRegionKeys => + list( + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1SingleRegionKey.t() + ) + | nil, :state => String.t() | nil } @@ -45,6 +51,12 @@ defmodule GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1CmekCon field(:kmsKeyVersion) field(:lastRotationTimestampMicros) field(:name) + + field(:singleRegionKeys, + as: GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1SingleRegionKey, + type: :list + ) + field(:state) end diff --git a/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_data_store.ex b/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_data_store.ex index 3ae955b1b7..ce61124876 100644 --- a/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_data_store.ex +++ b/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_data_store.ex @@ -30,6 +30,7 @@ defmodule GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1DataSto * `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. * `documentProcessingConfig` (*type:* `GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1DocumentProcessingConfig.t`, *default:* `nil`) - Configuration for Document understanding and enrichment. * `industryVertical` (*type:* `String.t`, *default:* `nil`) - Immutable. The industry vertical that the data store registers. + * `isInfobotFaqDataStore` (*type:* `boolean()`, *default:* `nil`) - Optional. If set, this DataStore is an Infobot FAQ DataStore. * `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. * `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. * `servingConfigDataStore` (*type:* `GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1DataStoreServingConfigDataStore.t`, *default:* `nil`) - Optional. Stores serving config at DataStore level. @@ -57,6 +58,7 @@ defmodule GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1DataSto GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1DocumentProcessingConfig.t() | nil, :industryVertical => String.t() | nil, + :isInfobotFaqDataStore => boolean() | nil, :kmsKeyName => String.t() | nil, :name => String.t() | nil, :servingConfigDataStore => @@ -90,6 +92,7 @@ defmodule GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1DataSto ) field(:industryVertical) + field(:isInfobotFaqDataStore) field(:kmsKeyName) field(:name) diff --git a/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_document.ex b/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_document.ex index 92b7b5dba3..121163d1a1 100644 --- a/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_document.ex +++ b/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_document.ex @@ -24,7 +24,7 @@ defmodule GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1Documen * `content` (*type:* `GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1DocumentContent.t`, *default:* `nil`) - The unstructured data linked to this document. Content must be set if this document is under a `CONTENT_REQUIRED` data store. * `derivedStructData` (*type:* `map()`, *default:* `nil`) - Output only. This field is OUTPUT_ONLY. It contains derived data that are not in the original input document. * `id` (*type:* `String.t`, *default:* `nil`) - Immutable. The identifier of the document. Id should conform to [RFC-1034](https://tools.ietf.org/html/rfc1034) standard with a length limit of 63 characters. - * `indexStatus` (*type:* `GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1DocumentIndexStatus.t`, *default:* `nil`) - Output only. The index status of the document. * If document is indexed successfully, the index_time field is populated. * Otherwise, if document is not indexed due to errors, the error_samples field is populated. * Otherwise, index_status is unset. + * `indexStatus` (*type:* `GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1DocumentIndexStatus.t`, *default:* `nil`) - 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. * `indexTime` (*type:* `DateTime.t`, *default:* `nil`) - Output only. The last time the document was indexed. If this field is set, the document could be returned in search results. This field is OUTPUT_ONLY. If this field is not populated, it means the document has never been indexed. * `jsonData` (*type:* `String.t`, *default:* `nil`) - The JSON string representation of the document. It should conform to the registered Schema or an `INVALID_ARGUMENT` error is thrown. * `name` (*type:* `String.t`, *default:* `nil`) - Immutable. The full resource name of the document. Format: `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/branches/{branch}/documents/{document_id}`. This field must be a UTF-8 encoded string with a length limit of 1024 characters. diff --git a/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_document_index_status.ex b/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_document_index_status.ex index a52cb10080..b7a90f1090 100644 --- a/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_document_index_status.ex +++ b/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_document_index_status.ex @@ -23,17 +23,20 @@ defmodule GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1Documen * `errorSamples` (*type:* `list(GoogleApi.DiscoveryEngine.V1.Model.GoogleRpcStatus.t)`, *default:* `nil`) - A sample of errors encountered while indexing the document. If this field is populated, the document is not indexed due to errors. * `indexTime` (*type:* `DateTime.t`, *default:* `nil`) - The time when the document was indexed. If this field is populated, it means the document has been indexed. + * `pendingMessage` (*type:* `String.t`, *default:* `nil`) - Immutable. The message indicates the document index is in progress. If this field is populated, the document index is pending. """ use GoogleApi.Gax.ModelBase @type t :: %__MODULE__{ :errorSamples => list(GoogleApi.DiscoveryEngine.V1.Model.GoogleRpcStatus.t()) | nil, - :indexTime => DateTime.t() | nil + :indexTime => DateTime.t() | nil, + :pendingMessage => String.t() | nil } field(:errorSamples, as: GoogleApi.DiscoveryEngine.V1.Model.GoogleRpcStatus, type: :list) field(:indexTime, as: DateTime) + field(:pendingMessage) end defimpl Poison.Decoder, diff --git a/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_generate_grounded_content_request.ex b/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_generate_grounded_content_request.ex new file mode 100644 index 0000000000..6b1f3bb9a9 --- /dev/null +++ b/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_generate_grounded_content_request.ex @@ -0,0 +1,90 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentRequest do + @moduledoc """ + Top-level message sent by the client for the `GenerateGroundedContent` method. + + ## Attributes + + * `contents` (*type:* `list(GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GroundedGenerationContent.t)`, *default:* `nil`) - 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. + * `generationSpec` (*type:* `GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestGenerationSpec.t`, *default:* `nil`) - Content generation specification. + * `groundingSpec` (*type:* `GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestGroundingSpec.t`, *default:* `nil`) - Grounding specification. + * `systemInstruction` (*type:* `GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GroundedGenerationContent.t`, *default:* `nil`) - 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` (*type:* `map()`, *default:* `nil`) - 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. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :contents => + list( + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GroundedGenerationContent.t() + ) + | nil, + :generationSpec => + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestGenerationSpec.t() + | nil, + :groundingSpec => + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestGroundingSpec.t() + | nil, + :systemInstruction => + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GroundedGenerationContent.t() + | nil, + :userLabels => map() | nil + } + + field(:contents, + as: GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GroundedGenerationContent, + type: :list + ) + + field(:generationSpec, + as: + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestGenerationSpec + ) + + field(:groundingSpec, + as: + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestGroundingSpec + ) + + field(:systemInstruction, + as: GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GroundedGenerationContent + ) + + field(:userLabels, type: :map) +end + +defimpl Poison.Decoder, + for: + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentRequest do + def decode(value, options) do + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentRequest.decode( + value, + options + ) + end +end + +defimpl Poison.Encoder, + for: + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentRequest do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_generate_grounded_content_request_dynamic_retrieval_configuration.ex b/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_generate_grounded_content_request_dynamic_retrieval_configuration.ex new file mode 100644 index 0000000000..17df81bb4d --- /dev/null +++ b/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_generate_grounded_content_request_dynamic_retrieval_configuration.ex @@ -0,0 +1,58 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestDynamicRetrievalConfiguration do + @moduledoc """ + Describes the options to customize dynamic retrieval. + + ## Attributes + + * `predictor` (*type:* `GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestDynamicRetrievalConfigurationDynamicRetrievalPredictor.t`, *default:* `nil`) - Specification for the predictor for dynamic retrieval. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :predictor => + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestDynamicRetrievalConfigurationDynamicRetrievalPredictor.t() + | nil + } + + field(:predictor, + as: + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestDynamicRetrievalConfigurationDynamicRetrievalPredictor + ) +end + +defimpl Poison.Decoder, + for: + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestDynamicRetrievalConfiguration do + def decode(value, options) do + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestDynamicRetrievalConfiguration.decode( + value, + options + ) + end +end + +defimpl Poison.Encoder, + for: + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestDynamicRetrievalConfiguration do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_generate_grounded_content_request_dynamic_retrieval_configuration_dynamic_retrieval_predictor.ex b/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_generate_grounded_content_request_dynamic_retrieval_configuration_dynamic_retrieval_predictor.ex new file mode 100644 index 0000000000..48abbc5fd6 --- /dev/null +++ b/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_generate_grounded_content_request_dynamic_retrieval_configuration_dynamic_retrieval_predictor.ex @@ -0,0 +1,56 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestDynamicRetrievalConfigurationDynamicRetrievalPredictor do + @moduledoc """ + Describes the predictor settings for dynamic retrieval. + + ## Attributes + + * `threshold` (*type:* `number()`, *default:* `nil`) - The value of the threshold. If the predictor will predict a value smaller than this, it would suppress grounding in the source. + * `version` (*type:* `String.t`, *default:* `nil`) - The version of the predictor to be used in dynamic retrieval. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :threshold => number() | nil, + :version => String.t() | nil + } + + field(:threshold) + field(:version) +end + +defimpl Poison.Decoder, + for: + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestDynamicRetrievalConfigurationDynamicRetrievalPredictor do + def decode(value, options) do + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestDynamicRetrievalConfigurationDynamicRetrievalPredictor.decode( + value, + options + ) + end +end + +defimpl Poison.Encoder, + for: + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestDynamicRetrievalConfigurationDynamicRetrievalPredictor do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_generate_grounded_content_request_generation_spec.ex b/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_generate_grounded_content_request_generation_spec.ex new file mode 100644 index 0000000000..80e8202182 --- /dev/null +++ b/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_generate_grounded_content_request_generation_spec.ex @@ -0,0 +1,77 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestGenerationSpec do + @moduledoc """ + Content generation specification. + + ## Attributes + + * `frequencyPenalty` (*type:* `number()`, *default:* `nil`) - If specified, custom value for frequency penalty will be used. + * `languageCode` (*type:* `String.t`, *default:* `nil`) - Language code for content. Use language tags defined by [BCP47](https://www.rfc-editor.org/rfc/bcp/bcp47.txt). + * `maxOutputTokens` (*type:* `integer()`, *default:* `nil`) - If specified, custom value for max output tokens will be used. + * `modelId` (*type:* `String.t`, *default:* `nil`) - Specifies which Vertex model id to use for generation. + * `presencePenalty` (*type:* `number()`, *default:* `nil`) - If specified, custom value for presence penalty will be used. + * `seed` (*type:* `integer()`, *default:* `nil`) - If specified, custom value for the seed will be used. + * `temperature` (*type:* `number()`, *default:* `nil`) - If specified, custom value for the temperature will be used. + * `topK` (*type:* `integer()`, *default:* `nil`) - If specified, custom value for top-k sampling will be used. + * `topP` (*type:* `number()`, *default:* `nil`) - If specified, custom value for nucleus sampling will be used. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :frequencyPenalty => number() | nil, + :languageCode => String.t() | nil, + :maxOutputTokens => integer() | nil, + :modelId => String.t() | nil, + :presencePenalty => number() | nil, + :seed => integer() | nil, + :temperature => number() | nil, + :topK => integer() | nil, + :topP => number() | nil + } + + field(:frequencyPenalty) + field(:languageCode) + field(:maxOutputTokens) + field(:modelId) + field(:presencePenalty) + field(:seed) + field(:temperature) + field(:topK) + field(:topP) +end + +defimpl Poison.Decoder, + for: + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestGenerationSpec do + def decode(value, options) do + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestGenerationSpec.decode( + value, + options + ) + end +end + +defimpl Poison.Encoder, + for: + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestGenerationSpec do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_generate_grounded_content_request_grounding_source.ex b/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_generate_grounded_content_request_grounding_source.ex new file mode 100644 index 0000000000..dc44a26439 --- /dev/null +++ b/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_generate_grounded_content_request_grounding_source.ex @@ -0,0 +1,76 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestGroundingSource do + @moduledoc """ + Grounding source. + + ## Attributes + + * `googleSearchSource` (*type:* `GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestGroundingSourceGoogleSearchSource.t`, *default:* `nil`) - If set, grounding is performed with Google Search. + * `inlineSource` (*type:* `GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestGroundingSourceInlineSource.t`, *default:* `nil`) - If set, grounding is performed with inline content. + * `searchSource` (*type:* `GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestGroundingSourceSearchSource.t`, *default:* `nil`) - If set, grounding is performed with Vertex AI Search. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :googleSearchSource => + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestGroundingSourceGoogleSearchSource.t() + | nil, + :inlineSource => + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestGroundingSourceInlineSource.t() + | nil, + :searchSource => + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestGroundingSourceSearchSource.t() + | nil + } + + field(:googleSearchSource, + as: + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestGroundingSourceGoogleSearchSource + ) + + field(:inlineSource, + as: + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestGroundingSourceInlineSource + ) + + field(:searchSource, + as: + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestGroundingSourceSearchSource + ) +end + +defimpl Poison.Decoder, + for: + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestGroundingSource do + def decode(value, options) do + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestGroundingSource.decode( + value, + options + ) + end +end + +defimpl Poison.Encoder, + for: + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestGroundingSource do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_generate_grounded_content_request_grounding_source_google_search_source.ex b/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_generate_grounded_content_request_grounding_source_google_search_source.ex new file mode 100644 index 0000000000..ccd128710c --- /dev/null +++ b/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_generate_grounded_content_request_grounding_source_google_search_source.ex @@ -0,0 +1,58 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestGroundingSourceGoogleSearchSource do + @moduledoc """ + Google Search config parameters. + + ## Attributes + + * `dynamicRetrievalConfig` (*type:* `GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestDynamicRetrievalConfiguration.t`, *default:* `nil`) - Optional. Specifies the dynamic retrieval configuration for the given source. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :dynamicRetrievalConfig => + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestDynamicRetrievalConfiguration.t() + | nil + } + + field(:dynamicRetrievalConfig, + as: + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestDynamicRetrievalConfiguration + ) +end + +defimpl Poison.Decoder, + for: + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestGroundingSourceGoogleSearchSource do + def decode(value, options) do + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestGroundingSourceGoogleSearchSource.decode( + value, + options + ) + end +end + +defimpl Poison.Encoder, + for: + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestGroundingSourceGoogleSearchSource do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_generate_grounded_content_request_grounding_source_inline_source.ex b/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_generate_grounded_content_request_grounding_source_inline_source.ex new file mode 100644 index 0000000000..e6299e6aeb --- /dev/null +++ b/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_generate_grounded_content_request_grounding_source_inline_source.ex @@ -0,0 +1,62 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestGroundingSourceInlineSource do + @moduledoc """ + Message to be used for grounding based on inline content. + + ## Attributes + + * `attributes` (*type:* `map()`, *default:* `nil`) - Attributes associated with the content. Common attributes include `source` (indicating where the content was sourced from) and `author` (indicating the author of the content). + * `groundingFacts` (*type:* `list(GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GroundingFact.t)`, *default:* `nil`) - List of facts to be used for grounding. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :attributes => map() | nil, + :groundingFacts => + list(GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GroundingFact.t()) + | nil + } + + field(:attributes, type: :map) + + field(:groundingFacts, + as: GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GroundingFact, + type: :list + ) +end + +defimpl Poison.Decoder, + for: + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestGroundingSourceInlineSource do + def decode(value, options) do + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestGroundingSourceInlineSource.decode( + value, + options + ) + end +end + +defimpl Poison.Encoder, + for: + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestGroundingSourceInlineSource do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_generate_grounded_content_request_grounding_source_search_source.ex b/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_generate_grounded_content_request_grounding_source_search_source.ex new file mode 100644 index 0000000000..1eb3171314 --- /dev/null +++ b/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_generate_grounded_content_request_grounding_source_search_source.ex @@ -0,0 +1,62 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestGroundingSourceSearchSource do + @moduledoc """ + Message to be used for grounding with Vertex AI Search. + + ## Attributes + + * `filter` (*type:* `String.t`, *default:* `nil`) - Filter expression to be applied to the search. The syntax is the same as SearchRequest.filter. + * `maxResultCount` (*type:* `integer()`, *default:* `nil`) - Number of search results to return. The default value is 10. The maximumm allowed value is 10. + * `safeSearch` (*type:* `boolean()`, *default:* `nil`) - If set, safe search is enabled in Vertex AI Search requests. + * `servingConfig` (*type:* `String.t`, *default:* `nil`) - The resource name of the Engine to use. Format: `projects/{project}/locations/{location}/collections/{collection_id}/engines/{engine_id}/servingConfigs/{serving_config_id}` + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :filter => String.t() | nil, + :maxResultCount => integer() | nil, + :safeSearch => boolean() | nil, + :servingConfig => String.t() | nil + } + + field(:filter) + field(:maxResultCount) + field(:safeSearch) + field(:servingConfig) +end + +defimpl Poison.Decoder, + for: + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestGroundingSourceSearchSource do + def decode(value, options) do + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestGroundingSourceSearchSource.decode( + value, + options + ) + end +end + +defimpl Poison.Encoder, + for: + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestGroundingSourceSearchSource do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_generate_grounded_content_request_grounding_spec.ex b/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_generate_grounded_content_request_grounding_spec.ex new file mode 100644 index 0000000000..5e2e3ed30d --- /dev/null +++ b/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_generate_grounded_content_request_grounding_spec.ex @@ -0,0 +1,61 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestGroundingSpec do + @moduledoc """ + Grounding specification. + + ## Attributes + + * `groundingSources` (*type:* `list(GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestGroundingSource.t)`, *default:* `nil`) - Grounding sources. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :groundingSources => + list( + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestGroundingSource.t() + ) + | nil + } + + field(:groundingSources, + as: + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestGroundingSource, + type: :list + ) +end + +defimpl Poison.Decoder, + for: + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestGroundingSpec do + def decode(value, options) do + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestGroundingSpec.decode( + value, + options + ) + end +end + +defimpl Poison.Encoder, + for: + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentRequestGroundingSpec do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_generate_grounded_content_response.ex b/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_generate_grounded_content_response.ex new file mode 100644 index 0000000000..71ad03cca3 --- /dev/null +++ b/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_generate_grounded_content_response.ex @@ -0,0 +1,61 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentResponse do + @moduledoc """ + Response for the `GenerateGroundedContent` method. + + ## Attributes + + * `candidates` (*type:* `list(GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidate.t)`, *default:* `nil`) - Generated candidates. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :candidates => + list( + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidate.t() + ) + | nil + } + + field(:candidates, + as: + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidate, + type: :list + ) +end + +defimpl Poison.Decoder, + for: + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentResponse do + def decode(value, options) do + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentResponse.decode( + value, + options + ) + end +end + +defimpl Poison.Encoder, + for: + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentResponse do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_generate_grounded_content_response_candidate.ex b/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_generate_grounded_content_response_candidate.ex new file mode 100644 index 0000000000..d7da0a4d89 --- /dev/null +++ b/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_generate_grounded_content_response_candidate.ex @@ -0,0 +1,73 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidate do + @moduledoc """ + A response candidate generated from the model. + + ## Attributes + + * `content` (*type:* `GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GroundedGenerationContent.t`, *default:* `nil`) - Content of the candidate. + * `groundingMetadata` (*type:* `GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidateGroundingMetadata.t`, *default:* `nil`) - Grounding metadata for the generated content. + * `groundingScore` (*type:* `number()`, *default:* `nil`) - The overall grounding score for the candidate, in the range of [0, 1]. + * `index` (*type:* `integer()`, *default:* `nil`) - Index of the candidate. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :content => + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GroundedGenerationContent.t() + | nil, + :groundingMetadata => + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidateGroundingMetadata.t() + | nil, + :groundingScore => number() | nil, + :index => integer() | nil + } + + field(:content, + as: GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GroundedGenerationContent + ) + + field(:groundingMetadata, + as: + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidateGroundingMetadata + ) + + field(:groundingScore) + field(:index) +end + +defimpl Poison.Decoder, + for: + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidate do + def decode(value, options) do + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidate.decode( + value, + options + ) + end +end + +defimpl Poison.Encoder, + for: + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidate do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_generate_grounded_content_response_candidate_grounding_metadata.ex b/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_generate_grounded_content_response_candidate_grounding_metadata.ex new file mode 100644 index 0000000000..7823c7b6ed --- /dev/null +++ b/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_generate_grounded_content_response_candidate_grounding_metadata.ex @@ -0,0 +1,95 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidateGroundingMetadata do + @moduledoc """ + Citation for the generated content. + + ## Attributes + + * `groundingSupport` (*type:* `list(GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidateGroundingMetadataGroundingSupport.t)`, *default:* `nil`) - GroundingSupport across all claims in the answer candidate. An support to a fact indicates that the claim is supported by the fact. + * `retrievalMetadata` (*type:* `list(GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidateGroundingMetadataRetrievalMetadata.t)`, *default:* `nil`) - 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. + * `searchEntryPoint` (*type:* `GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidateGroundingMetadataSearchEntryPoint.t`, *default:* `nil`) - Google search entry for the following-up web searches. + * `supportChunks` (*type:* `list(GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1FactChunk.t)`, *default:* `nil`) - List of chunks to be attributed across all claims in the candidate. These are derived from the grounding sources supplied in the request. + * `webSearchQueries` (*type:* `list(String.t)`, *default:* `nil`) - Web search queries for the following-up web search. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :groundingSupport => + list( + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidateGroundingMetadataGroundingSupport.t() + ) + | nil, + :retrievalMetadata => + list( + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidateGroundingMetadataRetrievalMetadata.t() + ) + | nil, + :searchEntryPoint => + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidateGroundingMetadataSearchEntryPoint.t() + | nil, + :supportChunks => + list(GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1FactChunk.t()) + | nil, + :webSearchQueries => list(String.t()) | nil + } + + field(:groundingSupport, + as: + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidateGroundingMetadataGroundingSupport, + type: :list + ) + + field(:retrievalMetadata, + as: + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidateGroundingMetadataRetrievalMetadata, + type: :list + ) + + field(:searchEntryPoint, + as: + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidateGroundingMetadataSearchEntryPoint + ) + + field(:supportChunks, + as: GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1FactChunk, + type: :list + ) + + field(:webSearchQueries, type: :list) +end + +defimpl Poison.Decoder, + for: + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidateGroundingMetadata do + def decode(value, options) do + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidateGroundingMetadata.decode( + value, + options + ) + end +end + +defimpl Poison.Encoder, + for: + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidateGroundingMetadata do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_generate_grounded_content_response_candidate_grounding_metadata_dynamic_retrieval_metadata.ex b/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_generate_grounded_content_response_candidate_grounding_metadata_dynamic_retrieval_metadata.ex new file mode 100644 index 0000000000..00ed853702 --- /dev/null +++ b/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_generate_grounded_content_response_candidate_grounding_metadata_dynamic_retrieval_metadata.ex @@ -0,0 +1,58 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidateGroundingMetadataDynamicRetrievalMetadata do + @moduledoc """ + Describes the metadata about dynamic retrieval. + + ## Attributes + + * `predictorMetadata` (*type:* `GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidateGroundingMetadataDynamicRetrievalPredictorMetadata.t`, *default:* `nil`) - Metadata for the dynamic retrieval predictor. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :predictorMetadata => + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidateGroundingMetadataDynamicRetrievalPredictorMetadata.t() + | nil + } + + field(:predictorMetadata, + as: + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidateGroundingMetadataDynamicRetrievalPredictorMetadata + ) +end + +defimpl Poison.Decoder, + for: + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidateGroundingMetadataDynamicRetrievalMetadata do + def decode(value, options) do + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidateGroundingMetadataDynamicRetrievalMetadata.decode( + value, + options + ) + end +end + +defimpl Poison.Encoder, + for: + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidateGroundingMetadataDynamicRetrievalMetadata do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_generate_grounded_content_response_candidate_grounding_metadata_dynamic_retrieval_predictor_metadata.ex b/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_generate_grounded_content_response_candidate_grounding_metadata_dynamic_retrieval_predictor_metadata.ex new file mode 100644 index 0000000000..e4e072783f --- /dev/null +++ b/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_generate_grounded_content_response_candidate_grounding_metadata_dynamic_retrieval_predictor_metadata.ex @@ -0,0 +1,56 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidateGroundingMetadataDynamicRetrievalPredictorMetadata do + @moduledoc """ + Describes the metadata about the dynamic retrieval predictor. + + ## Attributes + + * `prediction` (*type:* `number()`, *default:* `nil`) - 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. + * `version` (*type:* `String.t`, *default:* `nil`) - The version of the predictor which was used in dynamic retrieval. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :prediction => number() | nil, + :version => String.t() | nil + } + + field(:prediction) + field(:version) +end + +defimpl Poison.Decoder, + for: + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidateGroundingMetadataDynamicRetrievalPredictorMetadata do + def decode(value, options) do + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidateGroundingMetadataDynamicRetrievalPredictorMetadata.decode( + value, + options + ) + end +end + +defimpl Poison.Encoder, + for: + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidateGroundingMetadataDynamicRetrievalPredictorMetadata do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_generate_grounded_content_response_candidate_grounding_metadata_grounding_support.ex b/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_generate_grounded_content_response_candidate_grounding_metadata_grounding_support.ex new file mode 100644 index 0000000000..7a1e208186 --- /dev/null +++ b/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_generate_grounded_content_response_candidate_grounding_metadata_grounding_support.ex @@ -0,0 +1,59 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidateGroundingMetadataGroundingSupport do + @moduledoc """ + Grounding info for a claim in the candidate and its support. + + ## Attributes + + * `claimText` (*type:* `String.t`, *default:* `nil`) - Text for the claim in the candidate. Always provided when a support is found. + * `supportChunkIndices` (*type:* `list(integer())`, *default:* `nil`) - 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. + * `supportScore` (*type:* `number()`, *default:* `nil`) - 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. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :claimText => String.t() | nil, + :supportChunkIndices => list(integer()) | nil, + :supportScore => number() | nil + } + + field(:claimText) + field(:supportChunkIndices, type: :list) + field(:supportScore) +end + +defimpl Poison.Decoder, + for: + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidateGroundingMetadataGroundingSupport do + def decode(value, options) do + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidateGroundingMetadataGroundingSupport.decode( + value, + options + ) + end +end + +defimpl Poison.Encoder, + for: + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidateGroundingMetadataGroundingSupport do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_generate_grounded_content_response_candidate_grounding_metadata_retrieval_metadata.ex b/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_generate_grounded_content_response_candidate_grounding_metadata_retrieval_metadata.ex new file mode 100644 index 0000000000..d9e9d3e46a --- /dev/null +++ b/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_generate_grounded_content_response_candidate_grounding_metadata_retrieval_metadata.ex @@ -0,0 +1,62 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidateGroundingMetadataRetrievalMetadata do + @moduledoc """ + Describes the metadata associated with a retrieval step. + + ## Attributes + + * `dynamicRetrievalMetadata` (*type:* `GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidateGroundingMetadataDynamicRetrievalMetadata.t`, *default:* `nil`) - Metadata for dynamic retrieval. + * `source` (*type:* `String.t`, *default:* `nil`) - Describes the source to which the metadata is referring to. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :dynamicRetrievalMetadata => + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidateGroundingMetadataDynamicRetrievalMetadata.t() + | nil, + :source => String.t() | nil + } + + field(:dynamicRetrievalMetadata, + as: + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidateGroundingMetadataDynamicRetrievalMetadata + ) + + field(:source) +end + +defimpl Poison.Decoder, + for: + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidateGroundingMetadataRetrievalMetadata do + def decode(value, options) do + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidateGroundingMetadataRetrievalMetadata.decode( + value, + options + ) + end +end + +defimpl Poison.Encoder, + for: + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidateGroundingMetadataRetrievalMetadata do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_generate_grounded_content_response_candidate_grounding_metadata_search_entry_point.ex b/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_generate_grounded_content_response_candidate_grounding_metadata_search_entry_point.ex new file mode 100644 index 0000000000..44f6830cd9 --- /dev/null +++ b/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_generate_grounded_content_response_candidate_grounding_metadata_search_entry_point.ex @@ -0,0 +1,56 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidateGroundingMetadataSearchEntryPoint do + @moduledoc """ + Google search entry point. + + ## Attributes + + * `renderedContent` (*type:* `String.t`, *default:* `nil`) - Web content snippet that can be embedded in a web page or an app webview. + * `sdkBlob` (*type:* `String.t`, *default:* `nil`) - Base64 encoded JSON representing array of tuple. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :renderedContent => String.t() | nil, + :sdkBlob => String.t() | nil + } + + field(:renderedContent) + field(:sdkBlob) +end + +defimpl Poison.Decoder, + for: + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidateGroundingMetadataSearchEntryPoint do + def decode(value, options) do + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidateGroundingMetadataSearchEntryPoint.decode( + value, + options + ) + end +end + +defimpl Poison.Encoder, + for: + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidateGroundingMetadataSearchEntryPoint do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_grounded_generation_content.ex b/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_grounded_generation_content.ex new file mode 100644 index 0000000000..3d46bb795c --- /dev/null +++ b/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_grounded_generation_content.ex @@ -0,0 +1,63 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GroundedGenerationContent do + @moduledoc """ + Base structured datatype containing multi-part content of a message. + + ## Attributes + + * `parts` (*type:* `list(GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GroundedGenerationContentPart.t)`, *default:* `nil`) - Ordered `Parts` that constitute a single message. + * `role` (*type:* `String.t`, *default:* `nil`) - Producer of the content. Must be either `user` or `model`. Intended to be used for multi-turn conversations. Otherwise, it can be left unset. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :parts => + list( + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GroundedGenerationContentPart.t() + ) + | nil, + :role => String.t() | nil + } + + field(:parts, + as: + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GroundedGenerationContentPart, + type: :list + ) + + field(:role) +end + +defimpl Poison.Decoder, + for: GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GroundedGenerationContent do + def decode(value, options) do + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GroundedGenerationContent.decode( + value, + options + ) + end +end + +defimpl Poison.Encoder, + for: GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GroundedGenerationContent do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_grounded_generation_content_part.ex b/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_grounded_generation_content_part.ex new file mode 100644 index 0000000000..23e12cb0ae --- /dev/null +++ b/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_grounded_generation_content_part.ex @@ -0,0 +1,53 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GroundedGenerationContentPart do + @moduledoc """ + Single part of content. + + ## Attributes + + * `text` (*type:* `String.t`, *default:* `nil`) - Inline text. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :text => String.t() | nil + } + + field(:text) +end + +defimpl Poison.Decoder, + for: + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GroundedGenerationContentPart do + def decode(value, options) do + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GroundedGenerationContentPart.decode( + value, + options + ) + end +end + +defimpl Poison.Encoder, + for: + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1GroundedGenerationContentPart do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_single_region_key.ex b/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_single_region_key.ex new file mode 100644 index 0000000000..04a95b0285 --- /dev/null +++ b/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1_single_region_key.ex @@ -0,0 +1,51 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1SingleRegionKey do + @moduledoc """ + Metadata for single-regional CMEKs. + + ## Attributes + + * `kmsKey` (*type:* `String.t`, *default:* `nil`) - Required. Single-regional kms key resource name which will be used to encrypt resources `projects/{project}/locations/{location}/keyRings/{keyRing}/cryptoKeys/{keyId}`. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :kmsKey => String.t() | nil + } + + field(:kmsKey) +end + +defimpl Poison.Decoder, + for: GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1SingleRegionKey do + def decode(value, options) do + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1SingleRegionKey.decode( + value, + options + ) + end +end + +defimpl Poison.Encoder, + for: GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1SingleRegionKey do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1alpha_action_config.ex b/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1alpha_action_config.ex new file mode 100644 index 0000000000..73a635f30d --- /dev/null +++ b/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1alpha_action_config.ex @@ -0,0 +1,54 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1alphaActionConfig do + @moduledoc """ + Informations to support actions on the connector. + + ## Attributes + + * `actionParams` (*type:* `map()`, *default:* `nil`) - 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. + * `isActionConfigured` (*type:* `boolean()`, *default:* `nil`) - Output only. The connector contains the necessary parameters and is configured to support actions. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :actionParams => map() | nil, + :isActionConfigured => boolean() | nil + } + + field(:actionParams, type: :map) + field(:isActionConfigured) +end + +defimpl Poison.Decoder, + for: GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1alphaActionConfig do + def decode(value, options) do + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1alphaActionConfig.decode( + value, + options + ) + end +end + +defimpl Poison.Encoder, + for: GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1alphaActionConfig do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1alpha_cmek_config.ex b/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1alpha_cmek_config.ex index df80e17a09..678a40c923 100644 --- a/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1alpha_cmek_config.ex +++ b/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1alpha_cmek_config.ex @@ -26,6 +26,7 @@ defmodule GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1alphaCm * `kmsKeyVersion` (*type:* `String.t`, *default:* `nil`) - Kms key version resource name which will be used to encrypt resources `/cryptoKeyVersions/{keyVersion}`. * `lastRotationTimestampMicros` (*type:* `String.t`, *default:* `nil`) - Output only. The timestamp of the last key rotation. * `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}`. + * `singleRegionKeys` (*type:* `list(GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1alphaSingleRegionKey.t)`, *default:* `nil`) - Optional. Single-regional CMEKs that are required for some VAIS features. * `state` (*type:* `String.t`, *default:* `nil`) - Output only. State of the CmekConfig. """ @@ -37,6 +38,11 @@ defmodule GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1alphaCm :kmsKeyVersion => String.t() | nil, :lastRotationTimestampMicros => String.t() | nil, :name => String.t() | nil, + :singleRegionKeys => + list( + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1alphaSingleRegionKey.t() + ) + | nil, :state => String.t() | nil } @@ -45,6 +51,12 @@ defmodule GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1alphaCm field(:kmsKeyVersion) field(:lastRotationTimestampMicros) field(:name) + + field(:singleRegionKeys, + as: GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1alphaSingleRegionKey, + type: :list + ) + field(:state) end diff --git a/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1alpha_collection.ex b/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1alpha_collection.ex new file mode 100644 index 0000000000..642ae58a0b --- /dev/null +++ b/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1alpha_collection.ex @@ -0,0 +1,66 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1alphaCollection do + @moduledoc """ + Collection is a container for configuring resources and access to a set of DataStores. + + ## Attributes + + * `createTime` (*type:* `DateTime.t`, *default:* `nil`) - Output only. Timestamp the Collection was created at. + * `dataConnector` (*type:* `GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1alphaDataConnector.t`, *default:* `nil`) - 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. + * `displayName` (*type:* `String.t`, *default:* `nil`) - 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. + * `name` (*type:* `String.t`, *default:* `nil`) - 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. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :createTime => DateTime.t() | nil, + :dataConnector => + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1alphaDataConnector.t() + | nil, + :displayName => String.t() | nil, + :name => String.t() | nil + } + + field(:createTime, as: DateTime) + + field(:dataConnector, + as: GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1alphaDataConnector + ) + + field(:displayName) + field(:name) +end + +defimpl Poison.Decoder, + for: GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1alphaCollection do + def decode(value, options) do + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1alphaCollection.decode( + value, + options + ) + end +end + +defimpl Poison.Encoder, + for: GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1alphaCollection do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1alpha_connector_run.ex b/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1alpha_connector_run.ex new file mode 100644 index 0000000000..f8744e1bb1 --- /dev/null +++ b/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1alpha_connector_run.ex @@ -0,0 +1,84 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1alphaConnectorRun do + @moduledoc """ + 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. // + + ## Attributes + + * `endTime` (*type:* `DateTime.t`, *default:* `nil`) - Output only. The time when the connector run ended. + * `entityRuns` (*type:* `list(GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1alphaConnectorRunEntityRun.t)`, *default:* `nil`) - Output only. The details of the entities synced at the ConnectorRun. Each ConnectorRun consists of syncing one or more entities. + * `errors` (*type:* `list(GoogleApi.DiscoveryEngine.V1.Model.GoogleRpcStatus.t)`, *default:* `nil`) - 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. + * `latestPauseTime` (*type:* `DateTime.t`, *default:* `nil`) - Output only. The time when the connector run was most recently paused. + * `name` (*type:* `String.t`, *default:* `nil`) - Output only. The full resource name of the Connector Run. Format: `projects/*/locations/*/collections/*/dataConnector/connectorRuns/*`. The `connector_run_id` is system-generated. + * `startTime` (*type:* `DateTime.t`, *default:* `nil`) - Output only. The time when the connector run started. + * `state` (*type:* `String.t`, *default:* `nil`) - Output only. The state of the sync run. + * `stateUpdateTime` (*type:* `DateTime.t`, *default:* `nil`) - Timestamp at which the connector run sync state was last updated. + * `trigger` (*type:* `String.t`, *default:* `nil`) - Output only. The trigger for this ConnectorRun. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :endTime => DateTime.t() | nil, + :entityRuns => + list( + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1alphaConnectorRunEntityRun.t() + ) + | nil, + :errors => list(GoogleApi.DiscoveryEngine.V1.Model.GoogleRpcStatus.t()) | nil, + :latestPauseTime => DateTime.t() | nil, + :name => String.t() | nil, + :startTime => DateTime.t() | nil, + :state => String.t() | nil, + :stateUpdateTime => DateTime.t() | nil, + :trigger => String.t() | nil + } + + field(:endTime, as: DateTime) + + field(:entityRuns, + as: GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1alphaConnectorRunEntityRun, + type: :list + ) + + field(:errors, as: GoogleApi.DiscoveryEngine.V1.Model.GoogleRpcStatus, type: :list) + field(:latestPauseTime, as: DateTime) + field(:name) + field(:startTime, as: DateTime) + field(:state) + field(:stateUpdateTime, as: DateTime) + field(:trigger) +end + +defimpl Poison.Decoder, + for: GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1alphaConnectorRun do + def decode(value, options) do + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1alphaConnectorRun.decode( + value, + options + ) + end +end + +defimpl Poison.Encoder, + for: GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1alphaConnectorRun do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1alpha_connector_run_entity_run.ex b/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1alpha_connector_run_entity_run.ex new file mode 100644 index 0000000000..b31e1795f8 --- /dev/null +++ b/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1alpha_connector_run_entity_run.ex @@ -0,0 +1,78 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1alphaConnectorRunEntityRun do + @moduledoc """ + Represents an entity that was synced in this ConnectorRun. + + ## Attributes + + * `entityName` (*type:* `String.t`, *default:* `nil`) - The name of the source entity. + * `errorRecordCount` (*type:* `String.t`, *default:* `nil`) - The total number of documents failed at sync at any stage (extraction, indexing, etc). + * `errors` (*type:* `list(GoogleApi.DiscoveryEngine.V1.Model.GoogleRpcStatus.t)`, *default:* `nil`) - The errors from the entity's sync run. Only exist if running into an error state. Contains error code and error message. + * `extractedRecordCount` (*type:* `String.t`, *default:* `nil`) - The number of documents extracted from connector source, ready to be ingested to UCS. + * `indexedRecordCount` (*type:* `String.t`, *default:* `nil`) - The number of documents indexed. + * `sourceApiRequestCount` (*type:* `String.t`, *default:* `nil`) - The number of requests sent to 3p API. + * `state` (*type:* `String.t`, *default:* `nil`) - The state of the entity's sync run. + * `stateUpdateTime` (*type:* `DateTime.t`, *default:* `nil`) - Timestamp at which the entity sync state was last updated. + * `statsUpdateTime` (*type:* `DateTime.t`, *default:* `nil`) - The timestamp for either extracted_documents_count, indexed_documents_count and error_documents_count was last updated. + * `syncType` (*type:* `String.t`, *default:* `nil`) - Sync type of this run. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :entityName => String.t() | nil, + :errorRecordCount => String.t() | nil, + :errors => list(GoogleApi.DiscoveryEngine.V1.Model.GoogleRpcStatus.t()) | nil, + :extractedRecordCount => String.t() | nil, + :indexedRecordCount => String.t() | nil, + :sourceApiRequestCount => String.t() | nil, + :state => String.t() | nil, + :stateUpdateTime => DateTime.t() | nil, + :statsUpdateTime => DateTime.t() | nil, + :syncType => String.t() | nil + } + + field(:entityName) + field(:errorRecordCount) + field(:errors, as: GoogleApi.DiscoveryEngine.V1.Model.GoogleRpcStatus, type: :list) + field(:extractedRecordCount) + field(:indexedRecordCount) + field(:sourceApiRequestCount) + field(:state) + field(:stateUpdateTime, as: DateTime) + field(:statsUpdateTime, as: DateTime) + field(:syncType) +end + +defimpl Poison.Decoder, + for: GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1alphaConnectorRunEntityRun do + def decode(value, options) do + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1alphaConnectorRunEntityRun.decode( + value, + options + ) + end +end + +defimpl Poison.Encoder, + for: GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1alphaConnectorRunEntityRun do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1alpha_data_connector.ex b/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1alpha_data_connector.ex new file mode 100644 index 0000000000..f69f831c30 --- /dev/null +++ b/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1alpha_data_connector.ex @@ -0,0 +1,146 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1alphaDataConnector do + @moduledoc """ + 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. // + + ## Attributes + + * `actionConfig` (*type:* `GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1alphaActionConfig.t`, *default:* `nil`) - Optional. Action configurations to make the connector support actions. + * `autoRunDisabled` (*type:* `boolean()`, *default:* `nil`) - Indicates whether the connector is disabled for auto run. It can be used to pause periodical and real time sync. + * `blockingReasons` (*type:* `list(String.t)`, *default:* `nil`) - Output only. User actions that must be completed before the connector can start syncing data. + * `createTime` (*type:* `DateTime.t`, *default:* `nil`) - Output only. Timestamp the DataConnector was created at. + * `dataSource` (*type:* `String.t`, *default:* `nil`) - Required. The name of the data source. Supported values: `salesforce`, `jira`, `confluence`, `bigquery`. + * `destinationConfigs` (*type:* `list(GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1alphaDestinationConfig.t)`, *default:* `nil`) - Optional. Any target destinations used to connect to third-party services. + * `entities` (*type:* `list(GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1alphaDataConnectorSourceEntity.t)`, *default:* `nil`) - List of entities from the connected data source to ingest. + * `errors` (*type:* `list(GoogleApi.DiscoveryEngine.V1.Model.GoogleRpcStatus.t)`, *default:* `nil`) - Output only. The errors from initialization or from the latest connector run. + * `identityRefreshInterval` (*type:* `String.t`, *default:* `nil`) - 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. + * `identityScheduleConfig` (*type:* `GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1alphaIdentityScheduleConfig.t`, *default:* `nil`) - 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` (*type:* `String.t`, *default:* `nil`) - 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. + * `lastSyncTime` (*type:* `DateTime.t`, *default:* `nil`) - Output only. For periodic connectors only, the last time a data sync was completed. + * `latestPauseTime` (*type:* `DateTime.t`, *default:* `nil`) - 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. + * `name` (*type:* `String.t`, *default:* `nil`) - Output only. The full resource name of the Data Connector. Format: `projects/*/locations/*/collections/*/dataConnector`. + * `nextSyncTime` (*type:* `GoogleApi.DiscoveryEngine.V1.Model.GoogleTypeDateTime.t`, *default:* `nil`) - 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` (*type:* `map()`, *default:* `nil`) - 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`. + * `privateConnectivityProjectId` (*type:* `String.t`, *default:* `nil`) - Output only. The tenant project ID associated with private connectivity connectors. This project must be allowlisted by in order for the connector to function. + * `refreshInterval` (*type:* `String.t`, *default:* `nil`) - 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. + * `state` (*type:* `String.t`, *default:* `nil`) - Output only. State of the connector. + * `staticIpAddresses` (*type:* `list(String.t)`, *default:* `nil`) - Output only. The static IP addresses used by this connector. + * `staticIpEnabled` (*type:* `boolean()`, *default:* `nil`) - Optional. Whether customer has enabled static IP addresses for this connector. + * `syncMode` (*type:* `String.t`, *default:* `nil`) - The data synchronization mode supported by the data connector. + * `updateTime` (*type:* `DateTime.t`, *default:* `nil`) - Output only. Timestamp the DataConnector was last updated. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :actionConfig => + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1alphaActionConfig.t() + | nil, + :autoRunDisabled => boolean() | nil, + :blockingReasons => list(String.t()) | nil, + :createTime => DateTime.t() | nil, + :dataSource => String.t() | nil, + :destinationConfigs => + list( + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1alphaDestinationConfig.t() + ) + | nil, + :entities => + list( + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1alphaDataConnectorSourceEntity.t() + ) + | nil, + :errors => list(GoogleApi.DiscoveryEngine.V1.Model.GoogleRpcStatus.t()) | nil, + :identityRefreshInterval => String.t() | nil, + :identityScheduleConfig => + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1alphaIdentityScheduleConfig.t() + | nil, + :kmsKeyName => String.t() | nil, + :lastSyncTime => DateTime.t() | nil, + :latestPauseTime => DateTime.t() | nil, + :name => String.t() | nil, + :nextSyncTime => GoogleApi.DiscoveryEngine.V1.Model.GoogleTypeDateTime.t() | nil, + :params => map() | nil, + :privateConnectivityProjectId => String.t() | nil, + :refreshInterval => String.t() | nil, + :state => String.t() | nil, + :staticIpAddresses => list(String.t()) | nil, + :staticIpEnabled => boolean() | nil, + :syncMode => String.t() | nil, + :updateTime => DateTime.t() | nil + } + + field(:actionConfig, + as: GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1alphaActionConfig + ) + + field(:autoRunDisabled) + field(:blockingReasons, type: :list) + field(:createTime, as: DateTime) + field(:dataSource) + + field(:destinationConfigs, + as: GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1alphaDestinationConfig, + type: :list + ) + + field(:entities, + as: + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1alphaDataConnectorSourceEntity, + type: :list + ) + + field(:errors, as: GoogleApi.DiscoveryEngine.V1.Model.GoogleRpcStatus, type: :list) + field(:identityRefreshInterval) + + field(:identityScheduleConfig, + as: GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1alphaIdentityScheduleConfig + ) + + field(:kmsKeyName) + field(:lastSyncTime, as: DateTime) + field(:latestPauseTime, as: DateTime) + field(:name) + field(:nextSyncTime, as: GoogleApi.DiscoveryEngine.V1.Model.GoogleTypeDateTime) + field(:params, type: :map) + field(:privateConnectivityProjectId) + field(:refreshInterval) + field(:state) + field(:staticIpAddresses, type: :list) + field(:staticIpEnabled) + field(:syncMode) + field(:updateTime, as: DateTime) +end + +defimpl Poison.Decoder, + for: GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1alphaDataConnector do + def decode(value, options) do + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1alphaDataConnector.decode( + value, + options + ) + end +end + +defimpl Poison.Encoder, + for: GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1alphaDataConnector do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1alpha_data_connector_source_entity.ex b/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1alpha_data_connector_source_entity.ex new file mode 100644 index 0000000000..78b1022ba7 --- /dev/null +++ b/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1alpha_data_connector_source_entity.ex @@ -0,0 +1,62 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1alphaDataConnectorSourceEntity do + @moduledoc """ + Represents an entity in the data source. For example, the `Account` object in Salesforce. + + ## Attributes + + * `dataStore` (*type:* `String.t`, *default:* `nil`) - 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. + * `entityName` (*type:* `String.t`, *default:* `nil`) - The name of the entity. Supported values by data source: * Salesforce: `Lead`, `Opportunity`, `Contact`, `Account`, `Case`, `Contract`, `Campaign` * Jira: `Issue` * Confluence: `Content`, `Space` + * `keyPropertyMappings` (*type:* `map()`, *default:* `nil`) - 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. + * `params` (*type:* `map()`, *default:* `nil`) - 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. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :dataStore => String.t() | nil, + :entityName => String.t() | nil, + :keyPropertyMappings => map() | nil, + :params => map() | nil + } + + field(:dataStore) + field(:entityName) + field(:keyPropertyMappings, type: :map) + field(:params, type: :map) +end + +defimpl Poison.Decoder, + for: + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1alphaDataConnectorSourceEntity do + def decode(value, options) do + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1alphaDataConnectorSourceEntity.decode( + value, + options + ) + end +end + +defimpl Poison.Encoder, + for: + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1alphaDataConnectorSourceEntity do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1alpha_data_store.ex b/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1alpha_data_store.ex index 03699c1b77..fc6728465b 100644 --- a/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1alpha_data_store.ex +++ b/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1alpha_data_store.ex @@ -32,6 +32,7 @@ defmodule GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1alphaDa * `documentProcessingConfig` (*type:* `GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1alphaDocumentProcessingConfig.t`, *default:* `nil`) - Configuration for Document understanding and enrichment. * `idpConfig` (*type:* `GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1alphaIdpConfig.t`, *default:* `nil`) - Output only. Data store level identity provider config. * `industryVertical` (*type:* `String.t`, *default:* `nil`) - Immutable. The industry vertical that the data store registers. + * `isInfobotFaqDataStore` (*type:* `boolean()`, *default:* `nil`) - Optional. If set, this DataStore is an Infobot FAQ DataStore. * `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. * `languageInfo` (*type:* `GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1alphaLanguageInfo.t`, *default:* `nil`) - Language info for DataStore. * `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. @@ -66,6 +67,7 @@ defmodule GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1alphaDa GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1alphaIdpConfig.t() | nil, :industryVertical => String.t() | nil, + :isInfobotFaqDataStore => boolean() | nil, :kmsKeyName => String.t() | nil, :languageInfo => GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1alphaLanguageInfo.t() @@ -116,6 +118,7 @@ defmodule GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1alphaDa ) field(:industryVertical) + field(:isInfobotFaqDataStore) field(:kmsKeyName) field(:languageInfo, diff --git a/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1alpha_delete_collection_metadata.ex b/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1alpha_delete_collection_metadata.ex new file mode 100644 index 0000000000..57aaf2759e --- /dev/null +++ b/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1alpha_delete_collection_metadata.ex @@ -0,0 +1,56 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1alphaDeleteCollectionMetadata do + @moduledoc """ + Metadata related to the progress of the CollectionService.UpdateCollection operation. This will be returned by the google.longrunning.Operation.metadata field. + + ## Attributes + + * `createTime` (*type:* `DateTime.t`, *default:* `nil`) - Operation create time. + * `updateTime` (*type:* `DateTime.t`, *default:* `nil`) - Operation last update time. If the operation is done, this is also the finish time. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :createTime => DateTime.t() | nil, + :updateTime => DateTime.t() | nil + } + + field(:createTime, as: DateTime) + field(:updateTime, as: DateTime) +end + +defimpl Poison.Decoder, + for: + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1alphaDeleteCollectionMetadata do + def decode(value, options) do + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1alphaDeleteCollectionMetadata.decode( + value, + options + ) + end +end + +defimpl Poison.Encoder, + for: + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1alphaDeleteCollectionMetadata do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1alpha_destination_config.ex b/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1alpha_destination_config.ex new file mode 100644 index 0000000000..35c467cecb --- /dev/null +++ b/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1alpha_destination_config.ex @@ -0,0 +1,66 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1alphaDestinationConfig do + @moduledoc """ + Defines target endpoints used to connect to third-party sources. + + ## Attributes + + * `destinations` (*type:* `list(GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1alphaDestinationConfigDestination.t)`, *default:* `nil`) - Optional. The destinations for the corresponding key. + * `key` (*type:* `String.t`, *default:* `nil`) - Optional. Unique destination identifier that is supported by the connector. + * `params` (*type:* `map()`, *default:* `nil`) - Optional. Additional parameters for this destination config. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :destinations => + list( + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1alphaDestinationConfigDestination.t() + ) + | nil, + :key => String.t() | nil, + :params => map() | nil + } + + field(:destinations, + as: + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1alphaDestinationConfigDestination, + type: :list + ) + + field(:key) + field(:params, type: :map) +end + +defimpl Poison.Decoder, + for: GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1alphaDestinationConfig do + def decode(value, options) do + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1alphaDestinationConfig.decode( + value, + options + ) + end +end + +defimpl Poison.Encoder, + for: GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1alphaDestinationConfig do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1alpha_destination_config_destination.ex b/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1alpha_destination_config_destination.ex new file mode 100644 index 0000000000..cafbeb3a92 --- /dev/null +++ b/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1alpha_destination_config_destination.ex @@ -0,0 +1,56 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1alphaDestinationConfigDestination do + @moduledoc """ + Defines a target endpoint + + ## Attributes + + * `host` (*type:* `String.t`, *default:* `nil`) - Publicly routable host. + * `port` (*type:* `integer()`, *default:* `nil`) - Optional. Target port number accepted by the destination. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :host => String.t() | nil, + :port => integer() | nil + } + + field(:host) + field(:port) +end + +defimpl Poison.Decoder, + for: + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1alphaDestinationConfigDestination do + def decode(value, options) do + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1alphaDestinationConfigDestination.decode( + value, + options + ) + end +end + +defimpl Poison.Encoder, + for: + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1alphaDestinationConfigDestination do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1alpha_identity_schedule_config.ex b/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1alpha_identity_schedule_config.ex new file mode 100644 index 0000000000..4771144193 --- /dev/null +++ b/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1alpha_identity_schedule_config.ex @@ -0,0 +1,51 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1alphaIdentityScheduleConfig do + @moduledoc """ + The configuration for the identity data synchronization runs. + + ## Attributes + + * `refreshInterval` (*type:* `String.t`, *default:* `nil`) - 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. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :refreshInterval => String.t() | nil + } + + field(:refreshInterval) +end + +defimpl Poison.Decoder, + for: GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1alphaIdentityScheduleConfig do + def decode(value, options) do + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1alphaIdentityScheduleConfig.decode( + value, + options + ) + end +end + +defimpl Poison.Encoder, + for: GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1alphaIdentityScheduleConfig do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1alpha_set_up_data_connector_metadata.ex b/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1alpha_set_up_data_connector_metadata.ex new file mode 100644 index 0000000000..d751e07f93 --- /dev/null +++ b/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1alpha_set_up_data_connector_metadata.ex @@ -0,0 +1,48 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1alphaSetUpDataConnectorMetadata do + @moduledoc """ + Metadata for DataConnectorService.SetUpDataConnector method. + + ## Attributes + + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{} +end + +defimpl Poison.Decoder, + for: + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1alphaSetUpDataConnectorMetadata do + def decode(value, options) do + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1alphaSetUpDataConnectorMetadata.decode( + value, + options + ) + end +end + +defimpl Poison.Encoder, + for: + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1alphaSetUpDataConnectorMetadata do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1alpha_single_region_key.ex b/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1alpha_single_region_key.ex new file mode 100644 index 0000000000..108e2f4d1e --- /dev/null +++ b/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1alpha_single_region_key.ex @@ -0,0 +1,51 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1alphaSingleRegionKey do + @moduledoc """ + Metadata for single-regional CMEKs. + + ## Attributes + + * `kmsKey` (*type:* `String.t`, *default:* `nil`) - Required. Single-regional kms key resource name which will be used to encrypt resources `projects/{project}/locations/{location}/keyRings/{keyRing}/cryptoKeys/{keyId}`. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :kmsKey => String.t() | nil + } + + field(:kmsKey) +end + +defimpl Poison.Decoder, + for: GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1alphaSingleRegionKey do + def decode(value, options) do + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1alphaSingleRegionKey.decode( + value, + options + ) + end +end + +defimpl Poison.Encoder, + for: GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1alphaSingleRegionKey do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1alpha_update_collection_metadata.ex b/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1alpha_update_collection_metadata.ex new file mode 100644 index 0000000000..5a8ecdcf51 --- /dev/null +++ b/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1alpha_update_collection_metadata.ex @@ -0,0 +1,56 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1alphaUpdateCollectionMetadata do + @moduledoc """ + Metadata related to the progress of the CollectionService.UpdateCollection operation. This will be returned by the google.longrunning.Operation.metadata field. + + ## Attributes + + * `createTime` (*type:* `DateTime.t`, *default:* `nil`) - Operation create time. + * `updateTime` (*type:* `DateTime.t`, *default:* `nil`) - Operation last update time. If the operation is done, this is also the finish time. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :createTime => DateTime.t() | nil, + :updateTime => DateTime.t() | nil + } + + field(:createTime, as: DateTime) + field(:updateTime, as: DateTime) +end + +defimpl Poison.Decoder, + for: + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1alphaUpdateCollectionMetadata do + def decode(value, options) do + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1alphaUpdateCollectionMetadata.decode( + value, + options + ) + end +end + +defimpl Poison.Encoder, + for: + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1alphaUpdateCollectionMetadata do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1beta_cmek_config.ex b/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1beta_cmek_config.ex index 6f25f362c3..3140901770 100644 --- a/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1beta_cmek_config.ex +++ b/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1beta_cmek_config.ex @@ -26,6 +26,7 @@ defmodule GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1betaCme * `kmsKeyVersion` (*type:* `String.t`, *default:* `nil`) - Kms key version resource name which will be used to encrypt resources `/cryptoKeyVersions/{keyVersion}`. * `lastRotationTimestampMicros` (*type:* `String.t`, *default:* `nil`) - Output only. The timestamp of the last key rotation. * `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}`. + * `singleRegionKeys` (*type:* `list(GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1betaSingleRegionKey.t)`, *default:* `nil`) - Optional. Single-regional CMEKs that are required for some VAIS features. * `state` (*type:* `String.t`, *default:* `nil`) - Output only. State of the CmekConfig. """ @@ -37,6 +38,11 @@ defmodule GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1betaCme :kmsKeyVersion => String.t() | nil, :lastRotationTimestampMicros => String.t() | nil, :name => String.t() | nil, + :singleRegionKeys => + list( + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1betaSingleRegionKey.t() + ) + | nil, :state => String.t() | nil } @@ -45,6 +51,12 @@ defmodule GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1betaCme field(:kmsKeyVersion) field(:lastRotationTimestampMicros) field(:name) + + field(:singleRegionKeys, + as: GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1betaSingleRegionKey, + type: :list + ) + field(:state) end diff --git a/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1beta_data_store.ex b/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1beta_data_store.ex index 16ef66186a..155a209e3d 100644 --- a/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1beta_data_store.ex +++ b/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1beta_data_store.ex @@ -30,6 +30,7 @@ defmodule GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1betaDat * `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. * `documentProcessingConfig` (*type:* `GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1betaDocumentProcessingConfig.t`, *default:* `nil`) - Configuration for Document understanding and enrichment. * `industryVertical` (*type:* `String.t`, *default:* `nil`) - Immutable. The industry vertical that the data store registers. + * `isInfobotFaqDataStore` (*type:* `boolean()`, *default:* `nil`) - Optional. If set, this DataStore is an Infobot FAQ DataStore. * `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. * `languageInfo` (*type:* `GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1betaLanguageInfo.t`, *default:* `nil`) - Language info for DataStore. * `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. @@ -60,6 +61,7 @@ defmodule GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1betaDat GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1betaDocumentProcessingConfig.t() | nil, :industryVertical => String.t() | nil, + :isInfobotFaqDataStore => boolean() | nil, :kmsKeyName => String.t() | nil, :languageInfo => GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1betaLanguageInfo.t() @@ -104,6 +106,7 @@ defmodule GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1betaDat ) field(:industryVertical) + field(:isInfobotFaqDataStore) field(:kmsKeyName) field(:languageInfo, diff --git a/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1beta_single_region_key.ex b/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1beta_single_region_key.ex new file mode 100644 index 0000000000..314ba4d101 --- /dev/null +++ b/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_cloud_discoveryengine_v1beta_single_region_key.ex @@ -0,0 +1,51 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1betaSingleRegionKey do + @moduledoc """ + Metadata for single-regional CMEKs. + + ## Attributes + + * `kmsKey` (*type:* `String.t`, *default:* `nil`) - Required. Single-regional kms key resource name which will be used to encrypt resources `projects/{project}/locations/{location}/keyRings/{keyRing}/cryptoKeys/{keyId}`. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :kmsKey => String.t() | nil + } + + field(:kmsKey) +end + +defimpl Poison.Decoder, + for: GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1betaSingleRegionKey do + def decode(value, options) do + GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1betaSingleRegionKey.decode( + value, + options + ) + end +end + +defimpl Poison.Encoder, + for: GoogleApi.DiscoveryEngine.V1.Model.GoogleCloudDiscoveryengineV1betaSingleRegionKey do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_type_date_time.ex b/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_type_date_time.ex new file mode 100644 index 0000000000..b14825c108 --- /dev/null +++ b/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_type_date_time.ex @@ -0,0 +1,70 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DiscoveryEngine.V1.Model.GoogleTypeDateTime do + @moduledoc """ + 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. + + ## Attributes + + * `day` (*type:* `integer()`, *default:* `nil`) - 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. + * `hours` (*type:* `integer()`, *default:* `nil`) - 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. + * `minutes` (*type:* `integer()`, *default:* `nil`) - Optional. Minutes of hour of day. Must be from 0 to 59, defaults to 0. + * `month` (*type:* `integer()`, *default:* `nil`) - Optional. Month of year. Must be from 1 to 12, or 0 if specifying a datetime without a month. + * `nanos` (*type:* `integer()`, *default:* `nil`) - Optional. Fractions of seconds in nanoseconds. Must be from 0 to 999,999,999, defaults to 0. + * `seconds` (*type:* `integer()`, *default:* `nil`) - 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. + * `timeZone` (*type:* `GoogleApi.DiscoveryEngine.V1.Model.GoogleTypeTimeZone.t`, *default:* `nil`) - Time zone. + * `utcOffset` (*type:* `String.t`, *default:* `nil`) - 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 }. + * `year` (*type:* `integer()`, *default:* `nil`) - Optional. Year of date. Must be from 1 to 9999, or 0 if specifying a datetime without a year. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :day => integer() | nil, + :hours => integer() | nil, + :minutes => integer() | nil, + :month => integer() | nil, + :nanos => integer() | nil, + :seconds => integer() | nil, + :timeZone => GoogleApi.DiscoveryEngine.V1.Model.GoogleTypeTimeZone.t() | nil, + :utcOffset => String.t() | nil, + :year => integer() | nil + } + + field(:day) + field(:hours) + field(:minutes) + field(:month) + field(:nanos) + field(:seconds) + field(:timeZone, as: GoogleApi.DiscoveryEngine.V1.Model.GoogleTypeTimeZone) + field(:utcOffset) + field(:year) +end + +defimpl Poison.Decoder, for: GoogleApi.DiscoveryEngine.V1.Model.GoogleTypeDateTime do + def decode(value, options) do + GoogleApi.DiscoveryEngine.V1.Model.GoogleTypeDateTime.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.DiscoveryEngine.V1.Model.GoogleTypeDateTime do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_type_time_zone.ex b/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_type_time_zone.ex new file mode 100644 index 0000000000..eb9777604e --- /dev/null +++ b/clients/discovery_engine/lib/google_api/discovery_engine/v1/model/google_type_time_zone.ex @@ -0,0 +1,49 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DiscoveryEngine.V1.Model.GoogleTypeTimeZone do + @moduledoc """ + Represents a time zone from the [IANA Time Zone Database](https://www.iana.org/time-zones). + + ## Attributes + + * `id` (*type:* `String.t`, *default:* `nil`) - IANA Time Zone Database time zone. For example "America/New_York". + * `version` (*type:* `String.t`, *default:* `nil`) - Optional. IANA Time Zone Database version number. For example "2019a". + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :id => String.t() | nil, + :version => String.t() | nil + } + + field(:id) + field(:version) +end + +defimpl Poison.Decoder, for: GoogleApi.DiscoveryEngine.V1.Model.GoogleTypeTimeZone do + def decode(value, options) do + GoogleApi.DiscoveryEngine.V1.Model.GoogleTypeTimeZone.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.DiscoveryEngine.V1.Model.GoogleTypeTimeZone do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/api/projects.ex b/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/api/projects.ex index 96d9724263..2e850e48ae 100644 --- a/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/api/projects.ex +++ b/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/api/projects.ex @@ -89,6 +89,85 @@ defmodule GoogleApi.DiscoveryEngine.V1beta.Api.Projects do ) end + @doc """ + Generates grounded content. + + ## Parameters + + * `connection` (*type:* `GoogleApi.DiscoveryEngine.V1beta.Connection.t`) - Connection to server + * `location` (*type:* `String.t`) - Required. Location resource. Format: `projects/{project}/locations/{location}`. + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - 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. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `: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. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:body` (*type:* `GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequest.t`) - + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponse{}}` on success + * `{:error, info}` on failure + """ + @spec discoveryengine_projects_locations_generate_grounded_content( + Tesla.Env.client(), + String.t(), + keyword(), + keyword() + ) :: + {:ok, + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponse.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def discoveryengine_projects_locations_generate_grounded_content( + connection, + location, + optional_params \\ [], + opts \\ [] + ) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :body => :body + } + + request = + Request.new() + |> Request.method(:post) + |> Request.url("/v1beta/{+location}:generateGroundedContent", %{ + "location" => URI.encode(location, &URI.char_unreserved?/1) + }) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode( + opts ++ + [ + struct: + %GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponse{} + ] + ) + end + @doc """ Gets the latest state of a long-running operation. Clients can use this method to poll the operation result at intervals as recommended by the API service. diff --git a/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/metadata.ex b/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/metadata.ex index 9a1ca6eb89..fc087da3e9 100644 --- a/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/metadata.ex +++ b/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/metadata.ex @@ -20,7 +20,7 @@ defmodule GoogleApi.DiscoveryEngine.V1beta do API client metadata for GoogleApi.DiscoveryEngine.V1beta. """ - @discovery_revision "20241210" + @discovery_revision "20241216" def discovery_revision(), do: @discovery_revision end diff --git a/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1_cmek_config.ex b/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1_cmek_config.ex index 7984375645..76aac50070 100644 --- a/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1_cmek_config.ex +++ b/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1_cmek_config.ex @@ -26,6 +26,7 @@ defmodule GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1Cme * `kmsKeyVersion` (*type:* `String.t`, *default:* `nil`) - Kms key version resource name which will be used to encrypt resources `/cryptoKeyVersions/{keyVersion}`. * `lastRotationTimestampMicros` (*type:* `String.t`, *default:* `nil`) - Output only. The timestamp of the last key rotation. * `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}`. + * `singleRegionKeys` (*type:* `list(GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1SingleRegionKey.t)`, *default:* `nil`) - Optional. Single-regional CMEKs that are required for some VAIS features. * `state` (*type:* `String.t`, *default:* `nil`) - Output only. State of the CmekConfig. """ @@ -37,6 +38,11 @@ defmodule GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1Cme :kmsKeyVersion => String.t() | nil, :lastRotationTimestampMicros => String.t() | nil, :name => String.t() | nil, + :singleRegionKeys => + list( + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1SingleRegionKey.t() + ) + | nil, :state => String.t() | nil } @@ -45,6 +51,12 @@ defmodule GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1Cme field(:kmsKeyVersion) field(:lastRotationTimestampMicros) field(:name) + + field(:singleRegionKeys, + as: GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1SingleRegionKey, + type: :list + ) + field(:state) end diff --git a/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1_data_store.ex b/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1_data_store.ex index 12de4af5e0..e1c2402555 100644 --- a/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1_data_store.ex +++ b/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1_data_store.ex @@ -30,6 +30,7 @@ defmodule GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1Dat * `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. * `documentProcessingConfig` (*type:* `GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1DocumentProcessingConfig.t`, *default:* `nil`) - Configuration for Document understanding and enrichment. * `industryVertical` (*type:* `String.t`, *default:* `nil`) - Immutable. The industry vertical that the data store registers. + * `isInfobotFaqDataStore` (*type:* `boolean()`, *default:* `nil`) - Optional. If set, this DataStore is an Infobot FAQ DataStore. * `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. * `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. * `servingConfigDataStore` (*type:* `GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1DataStoreServingConfigDataStore.t`, *default:* `nil`) - Optional. Stores serving config at DataStore level. @@ -58,6 +59,7 @@ defmodule GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1Dat GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1DocumentProcessingConfig.t() | nil, :industryVertical => String.t() | nil, + :isInfobotFaqDataStore => boolean() | nil, :kmsKeyName => String.t() | nil, :name => String.t() | nil, :servingConfigDataStore => @@ -96,6 +98,7 @@ defmodule GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1Dat ) field(:industryVertical) + field(:isInfobotFaqDataStore) field(:kmsKeyName) field(:name) diff --git a/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1_single_region_key.ex b/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1_single_region_key.ex new file mode 100644 index 0000000000..db283ea31a --- /dev/null +++ b/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1_single_region_key.ex @@ -0,0 +1,51 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1SingleRegionKey do + @moduledoc """ + Metadata for single-regional CMEKs. + + ## Attributes + + * `kmsKey` (*type:* `String.t`, *default:* `nil`) - Required. Single-regional kms key resource name which will be used to encrypt resources `projects/{project}/locations/{location}/keyRings/{keyRing}/cryptoKeys/{keyId}`. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :kmsKey => String.t() | nil + } + + field(:kmsKey) +end + +defimpl Poison.Decoder, + for: GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1SingleRegionKey do + def decode(value, options) do + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1SingleRegionKey.decode( + value, + options + ) + end +end + +defimpl Poison.Encoder, + for: GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1SingleRegionKey do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1alpha_action_config.ex b/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1alpha_action_config.ex new file mode 100644 index 0000000000..9caaa9c063 --- /dev/null +++ b/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1alpha_action_config.ex @@ -0,0 +1,54 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1alphaActionConfig do + @moduledoc """ + Informations to support actions on the connector. + + ## Attributes + + * `actionParams` (*type:* `map()`, *default:* `nil`) - 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. + * `isActionConfigured` (*type:* `boolean()`, *default:* `nil`) - Output only. The connector contains the necessary parameters and is configured to support actions. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :actionParams => map() | nil, + :isActionConfigured => boolean() | nil + } + + field(:actionParams, type: :map) + field(:isActionConfigured) +end + +defimpl Poison.Decoder, + for: GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1alphaActionConfig do + def decode(value, options) do + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1alphaActionConfig.decode( + value, + options + ) + end +end + +defimpl Poison.Encoder, + for: GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1alphaActionConfig do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1alpha_cmek_config.ex b/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1alpha_cmek_config.ex index 65b3073b3c..d3663a6918 100644 --- a/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1alpha_cmek_config.ex +++ b/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1alpha_cmek_config.ex @@ -26,6 +26,7 @@ defmodule GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1alp * `kmsKeyVersion` (*type:* `String.t`, *default:* `nil`) - Kms key version resource name which will be used to encrypt resources `/cryptoKeyVersions/{keyVersion}`. * `lastRotationTimestampMicros` (*type:* `String.t`, *default:* `nil`) - Output only. The timestamp of the last key rotation. * `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}`. + * `singleRegionKeys` (*type:* `list(GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1alphaSingleRegionKey.t)`, *default:* `nil`) - Optional. Single-regional CMEKs that are required for some VAIS features. * `state` (*type:* `String.t`, *default:* `nil`) - Output only. State of the CmekConfig. """ @@ -37,6 +38,11 @@ defmodule GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1alp :kmsKeyVersion => String.t() | nil, :lastRotationTimestampMicros => String.t() | nil, :name => String.t() | nil, + :singleRegionKeys => + list( + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1alphaSingleRegionKey.t() + ) + | nil, :state => String.t() | nil } @@ -45,6 +51,12 @@ defmodule GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1alp field(:kmsKeyVersion) field(:lastRotationTimestampMicros) field(:name) + + field(:singleRegionKeys, + as: GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1alphaSingleRegionKey, + type: :list + ) + field(:state) end diff --git a/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1alpha_collection.ex b/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1alpha_collection.ex new file mode 100644 index 0000000000..916ad7396d --- /dev/null +++ b/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1alpha_collection.ex @@ -0,0 +1,66 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1alphaCollection do + @moduledoc """ + Collection is a container for configuring resources and access to a set of DataStores. + + ## Attributes + + * `createTime` (*type:* `DateTime.t`, *default:* `nil`) - Output only. Timestamp the Collection was created at. + * `dataConnector` (*type:* `GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1alphaDataConnector.t`, *default:* `nil`) - 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. + * `displayName` (*type:* `String.t`, *default:* `nil`) - 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. + * `name` (*type:* `String.t`, *default:* `nil`) - 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. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :createTime => DateTime.t() | nil, + :dataConnector => + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1alphaDataConnector.t() + | nil, + :displayName => String.t() | nil, + :name => String.t() | nil + } + + field(:createTime, as: DateTime) + + field(:dataConnector, + as: GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1alphaDataConnector + ) + + field(:displayName) + field(:name) +end + +defimpl Poison.Decoder, + for: GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1alphaCollection do + def decode(value, options) do + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1alphaCollection.decode( + value, + options + ) + end +end + +defimpl Poison.Encoder, + for: GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1alphaCollection do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1alpha_connector_run.ex b/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1alpha_connector_run.ex new file mode 100644 index 0000000000..bc3cfd7c64 --- /dev/null +++ b/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1alpha_connector_run.ex @@ -0,0 +1,85 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1alphaConnectorRun do + @moduledoc """ + 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. // + + ## Attributes + + * `endTime` (*type:* `DateTime.t`, *default:* `nil`) - Output only. The time when the connector run ended. + * `entityRuns` (*type:* `list(GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1alphaConnectorRunEntityRun.t)`, *default:* `nil`) - Output only. The details of the entities synced at the ConnectorRun. Each ConnectorRun consists of syncing one or more entities. + * `errors` (*type:* `list(GoogleApi.DiscoveryEngine.V1beta.Model.GoogleRpcStatus.t)`, *default:* `nil`) - 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. + * `latestPauseTime` (*type:* `DateTime.t`, *default:* `nil`) - Output only. The time when the connector run was most recently paused. + * `name` (*type:* `String.t`, *default:* `nil`) - Output only. The full resource name of the Connector Run. Format: `projects/*/locations/*/collections/*/dataConnector/connectorRuns/*`. The `connector_run_id` is system-generated. + * `startTime` (*type:* `DateTime.t`, *default:* `nil`) - Output only. The time when the connector run started. + * `state` (*type:* `String.t`, *default:* `nil`) - Output only. The state of the sync run. + * `stateUpdateTime` (*type:* `DateTime.t`, *default:* `nil`) - Timestamp at which the connector run sync state was last updated. + * `trigger` (*type:* `String.t`, *default:* `nil`) - Output only. The trigger for this ConnectorRun. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :endTime => DateTime.t() | nil, + :entityRuns => + list( + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1alphaConnectorRunEntityRun.t() + ) + | nil, + :errors => list(GoogleApi.DiscoveryEngine.V1beta.Model.GoogleRpcStatus.t()) | nil, + :latestPauseTime => DateTime.t() | nil, + :name => String.t() | nil, + :startTime => DateTime.t() | nil, + :state => String.t() | nil, + :stateUpdateTime => DateTime.t() | nil, + :trigger => String.t() | nil + } + + field(:endTime, as: DateTime) + + field(:entityRuns, + as: + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1alphaConnectorRunEntityRun, + type: :list + ) + + field(:errors, as: GoogleApi.DiscoveryEngine.V1beta.Model.GoogleRpcStatus, type: :list) + field(:latestPauseTime, as: DateTime) + field(:name) + field(:startTime, as: DateTime) + field(:state) + field(:stateUpdateTime, as: DateTime) + field(:trigger) +end + +defimpl Poison.Decoder, + for: GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1alphaConnectorRun do + def decode(value, options) do + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1alphaConnectorRun.decode( + value, + options + ) + end +end + +defimpl Poison.Encoder, + for: GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1alphaConnectorRun do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1alpha_connector_run_entity_run.ex b/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1alpha_connector_run_entity_run.ex new file mode 100644 index 0000000000..fcc1a74c83 --- /dev/null +++ b/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1alpha_connector_run_entity_run.ex @@ -0,0 +1,80 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1alphaConnectorRunEntityRun do + @moduledoc """ + Represents an entity that was synced in this ConnectorRun. + + ## Attributes + + * `entityName` (*type:* `String.t`, *default:* `nil`) - The name of the source entity. + * `errorRecordCount` (*type:* `String.t`, *default:* `nil`) - The total number of documents failed at sync at any stage (extraction, indexing, etc). + * `errors` (*type:* `list(GoogleApi.DiscoveryEngine.V1beta.Model.GoogleRpcStatus.t)`, *default:* `nil`) - The errors from the entity's sync run. Only exist if running into an error state. Contains error code and error message. + * `extractedRecordCount` (*type:* `String.t`, *default:* `nil`) - The number of documents extracted from connector source, ready to be ingested to UCS. + * `indexedRecordCount` (*type:* `String.t`, *default:* `nil`) - The number of documents indexed. + * `sourceApiRequestCount` (*type:* `String.t`, *default:* `nil`) - The number of requests sent to 3p API. + * `state` (*type:* `String.t`, *default:* `nil`) - The state of the entity's sync run. + * `stateUpdateTime` (*type:* `DateTime.t`, *default:* `nil`) - Timestamp at which the entity sync state was last updated. + * `statsUpdateTime` (*type:* `DateTime.t`, *default:* `nil`) - The timestamp for either extracted_documents_count, indexed_documents_count and error_documents_count was last updated. + * `syncType` (*type:* `String.t`, *default:* `nil`) - Sync type of this run. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :entityName => String.t() | nil, + :errorRecordCount => String.t() | nil, + :errors => list(GoogleApi.DiscoveryEngine.V1beta.Model.GoogleRpcStatus.t()) | nil, + :extractedRecordCount => String.t() | nil, + :indexedRecordCount => String.t() | nil, + :sourceApiRequestCount => String.t() | nil, + :state => String.t() | nil, + :stateUpdateTime => DateTime.t() | nil, + :statsUpdateTime => DateTime.t() | nil, + :syncType => String.t() | nil + } + + field(:entityName) + field(:errorRecordCount) + field(:errors, as: GoogleApi.DiscoveryEngine.V1beta.Model.GoogleRpcStatus, type: :list) + field(:extractedRecordCount) + field(:indexedRecordCount) + field(:sourceApiRequestCount) + field(:state) + field(:stateUpdateTime, as: DateTime) + field(:statsUpdateTime, as: DateTime) + field(:syncType) +end + +defimpl Poison.Decoder, + for: + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1alphaConnectorRunEntityRun do + def decode(value, options) do + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1alphaConnectorRunEntityRun.decode( + value, + options + ) + end +end + +defimpl Poison.Encoder, + for: + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1alphaConnectorRunEntityRun do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1alpha_data_connector.ex b/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1alpha_data_connector.ex new file mode 100644 index 0000000000..a8e5b5a278 --- /dev/null +++ b/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1alpha_data_connector.ex @@ -0,0 +1,147 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1alphaDataConnector do + @moduledoc """ + 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. // + + ## Attributes + + * `actionConfig` (*type:* `GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1alphaActionConfig.t`, *default:* `nil`) - Optional. Action configurations to make the connector support actions. + * `autoRunDisabled` (*type:* `boolean()`, *default:* `nil`) - Indicates whether the connector is disabled for auto run. It can be used to pause periodical and real time sync. + * `blockingReasons` (*type:* `list(String.t)`, *default:* `nil`) - Output only. User actions that must be completed before the connector can start syncing data. + * `createTime` (*type:* `DateTime.t`, *default:* `nil`) - Output only. Timestamp the DataConnector was created at. + * `dataSource` (*type:* `String.t`, *default:* `nil`) - Required. The name of the data source. Supported values: `salesforce`, `jira`, `confluence`, `bigquery`. + * `destinationConfigs` (*type:* `list(GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1alphaDestinationConfig.t)`, *default:* `nil`) - Optional. Any target destinations used to connect to third-party services. + * `entities` (*type:* `list(GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1alphaDataConnectorSourceEntity.t)`, *default:* `nil`) - List of entities from the connected data source to ingest. + * `errors` (*type:* `list(GoogleApi.DiscoveryEngine.V1beta.Model.GoogleRpcStatus.t)`, *default:* `nil`) - Output only. The errors from initialization or from the latest connector run. + * `identityRefreshInterval` (*type:* `String.t`, *default:* `nil`) - 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. + * `identityScheduleConfig` (*type:* `GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1alphaIdentityScheduleConfig.t`, *default:* `nil`) - 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` (*type:* `String.t`, *default:* `nil`) - 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. + * `lastSyncTime` (*type:* `DateTime.t`, *default:* `nil`) - Output only. For periodic connectors only, the last time a data sync was completed. + * `latestPauseTime` (*type:* `DateTime.t`, *default:* `nil`) - 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. + * `name` (*type:* `String.t`, *default:* `nil`) - Output only. The full resource name of the Data Connector. Format: `projects/*/locations/*/collections/*/dataConnector`. + * `nextSyncTime` (*type:* `GoogleApi.DiscoveryEngine.V1beta.Model.GoogleTypeDateTime.t`, *default:* `nil`) - 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` (*type:* `map()`, *default:* `nil`) - 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`. + * `privateConnectivityProjectId` (*type:* `String.t`, *default:* `nil`) - Output only. The tenant project ID associated with private connectivity connectors. This project must be allowlisted by in order for the connector to function. + * `refreshInterval` (*type:* `String.t`, *default:* `nil`) - 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. + * `state` (*type:* `String.t`, *default:* `nil`) - Output only. State of the connector. + * `staticIpAddresses` (*type:* `list(String.t)`, *default:* `nil`) - Output only. The static IP addresses used by this connector. + * `staticIpEnabled` (*type:* `boolean()`, *default:* `nil`) - Optional. Whether customer has enabled static IP addresses for this connector. + * `syncMode` (*type:* `String.t`, *default:* `nil`) - The data synchronization mode supported by the data connector. + * `updateTime` (*type:* `DateTime.t`, *default:* `nil`) - Output only. Timestamp the DataConnector was last updated. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :actionConfig => + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1alphaActionConfig.t() + | nil, + :autoRunDisabled => boolean() | nil, + :blockingReasons => list(String.t()) | nil, + :createTime => DateTime.t() | nil, + :dataSource => String.t() | nil, + :destinationConfigs => + list( + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1alphaDestinationConfig.t() + ) + | nil, + :entities => + list( + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1alphaDataConnectorSourceEntity.t() + ) + | nil, + :errors => list(GoogleApi.DiscoveryEngine.V1beta.Model.GoogleRpcStatus.t()) | nil, + :identityRefreshInterval => String.t() | nil, + :identityScheduleConfig => + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1alphaIdentityScheduleConfig.t() + | nil, + :kmsKeyName => String.t() | nil, + :lastSyncTime => DateTime.t() | nil, + :latestPauseTime => DateTime.t() | nil, + :name => String.t() | nil, + :nextSyncTime => GoogleApi.DiscoveryEngine.V1beta.Model.GoogleTypeDateTime.t() | nil, + :params => map() | nil, + :privateConnectivityProjectId => String.t() | nil, + :refreshInterval => String.t() | nil, + :state => String.t() | nil, + :staticIpAddresses => list(String.t()) | nil, + :staticIpEnabled => boolean() | nil, + :syncMode => String.t() | nil, + :updateTime => DateTime.t() | nil + } + + field(:actionConfig, + as: GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1alphaActionConfig + ) + + field(:autoRunDisabled) + field(:blockingReasons, type: :list) + field(:createTime, as: DateTime) + field(:dataSource) + + field(:destinationConfigs, + as: GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1alphaDestinationConfig, + type: :list + ) + + field(:entities, + as: + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1alphaDataConnectorSourceEntity, + type: :list + ) + + field(:errors, as: GoogleApi.DiscoveryEngine.V1beta.Model.GoogleRpcStatus, type: :list) + field(:identityRefreshInterval) + + field(:identityScheduleConfig, + as: + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1alphaIdentityScheduleConfig + ) + + field(:kmsKeyName) + field(:lastSyncTime, as: DateTime) + field(:latestPauseTime, as: DateTime) + field(:name) + field(:nextSyncTime, as: GoogleApi.DiscoveryEngine.V1beta.Model.GoogleTypeDateTime) + field(:params, type: :map) + field(:privateConnectivityProjectId) + field(:refreshInterval) + field(:state) + field(:staticIpAddresses, type: :list) + field(:staticIpEnabled) + field(:syncMode) + field(:updateTime, as: DateTime) +end + +defimpl Poison.Decoder, + for: GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1alphaDataConnector do + def decode(value, options) do + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1alphaDataConnector.decode( + value, + options + ) + end +end + +defimpl Poison.Encoder, + for: GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1alphaDataConnector do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1alpha_data_connector_source_entity.ex b/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1alpha_data_connector_source_entity.ex new file mode 100644 index 0000000000..ef021d63f9 --- /dev/null +++ b/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1alpha_data_connector_source_entity.ex @@ -0,0 +1,62 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1alphaDataConnectorSourceEntity do + @moduledoc """ + Represents an entity in the data source. For example, the `Account` object in Salesforce. + + ## Attributes + + * `dataStore` (*type:* `String.t`, *default:* `nil`) - 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. + * `entityName` (*type:* `String.t`, *default:* `nil`) - The name of the entity. Supported values by data source: * Salesforce: `Lead`, `Opportunity`, `Contact`, `Account`, `Case`, `Contract`, `Campaign` * Jira: `Issue` * Confluence: `Content`, `Space` + * `keyPropertyMappings` (*type:* `map()`, *default:* `nil`) - 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. + * `params` (*type:* `map()`, *default:* `nil`) - 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. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :dataStore => String.t() | nil, + :entityName => String.t() | nil, + :keyPropertyMappings => map() | nil, + :params => map() | nil + } + + field(:dataStore) + field(:entityName) + field(:keyPropertyMappings, type: :map) + field(:params, type: :map) +end + +defimpl Poison.Decoder, + for: + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1alphaDataConnectorSourceEntity do + def decode(value, options) do + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1alphaDataConnectorSourceEntity.decode( + value, + options + ) + end +end + +defimpl Poison.Encoder, + for: + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1alphaDataConnectorSourceEntity do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1alpha_data_store.ex b/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1alpha_data_store.ex index 824298c2ad..b522419e6b 100644 --- a/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1alpha_data_store.ex +++ b/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1alpha_data_store.ex @@ -32,6 +32,7 @@ defmodule GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1alp * `documentProcessingConfig` (*type:* `GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1alphaDocumentProcessingConfig.t`, *default:* `nil`) - Configuration for Document understanding and enrichment. * `idpConfig` (*type:* `GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1alphaIdpConfig.t`, *default:* `nil`) - Output only. Data store level identity provider config. * `industryVertical` (*type:* `String.t`, *default:* `nil`) - Immutable. The industry vertical that the data store registers. + * `isInfobotFaqDataStore` (*type:* `boolean()`, *default:* `nil`) - Optional. If set, this DataStore is an Infobot FAQ DataStore. * `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. * `languageInfo` (*type:* `GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1alphaLanguageInfo.t`, *default:* `nil`) - Language info for DataStore. * `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. @@ -66,6 +67,7 @@ defmodule GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1alp GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1alphaIdpConfig.t() | nil, :industryVertical => String.t() | nil, + :isInfobotFaqDataStore => boolean() | nil, :kmsKeyName => String.t() | nil, :languageInfo => GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1alphaLanguageInfo.t() @@ -117,6 +119,7 @@ defmodule GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1alp ) field(:industryVertical) + field(:isInfobotFaqDataStore) field(:kmsKeyName) field(:languageInfo, diff --git a/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1alpha_delete_collection_metadata.ex b/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1alpha_delete_collection_metadata.ex new file mode 100644 index 0000000000..eab39ca3fe --- /dev/null +++ b/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1alpha_delete_collection_metadata.ex @@ -0,0 +1,56 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1alphaDeleteCollectionMetadata do + @moduledoc """ + Metadata related to the progress of the CollectionService.UpdateCollection operation. This will be returned by the google.longrunning.Operation.metadata field. + + ## Attributes + + * `createTime` (*type:* `DateTime.t`, *default:* `nil`) - Operation create time. + * `updateTime` (*type:* `DateTime.t`, *default:* `nil`) - Operation last update time. If the operation is done, this is also the finish time. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :createTime => DateTime.t() | nil, + :updateTime => DateTime.t() | nil + } + + field(:createTime, as: DateTime) + field(:updateTime, as: DateTime) +end + +defimpl Poison.Decoder, + for: + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1alphaDeleteCollectionMetadata do + def decode(value, options) do + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1alphaDeleteCollectionMetadata.decode( + value, + options + ) + end +end + +defimpl Poison.Encoder, + for: + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1alphaDeleteCollectionMetadata do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1alpha_destination_config.ex b/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1alpha_destination_config.ex new file mode 100644 index 0000000000..635df3c0f4 --- /dev/null +++ b/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1alpha_destination_config.ex @@ -0,0 +1,66 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1alphaDestinationConfig do + @moduledoc """ + Defines target endpoints used to connect to third-party sources. + + ## Attributes + + * `destinations` (*type:* `list(GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1alphaDestinationConfigDestination.t)`, *default:* `nil`) - Optional. The destinations for the corresponding key. + * `key` (*type:* `String.t`, *default:* `nil`) - Optional. Unique destination identifier that is supported by the connector. + * `params` (*type:* `map()`, *default:* `nil`) - Optional. Additional parameters for this destination config. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :destinations => + list( + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1alphaDestinationConfigDestination.t() + ) + | nil, + :key => String.t() | nil, + :params => map() | nil + } + + field(:destinations, + as: + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1alphaDestinationConfigDestination, + type: :list + ) + + field(:key) + field(:params, type: :map) +end + +defimpl Poison.Decoder, + for: GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1alphaDestinationConfig do + def decode(value, options) do + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1alphaDestinationConfig.decode( + value, + options + ) + end +end + +defimpl Poison.Encoder, + for: GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1alphaDestinationConfig do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1alpha_destination_config_destination.ex b/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1alpha_destination_config_destination.ex new file mode 100644 index 0000000000..bbcf936aba --- /dev/null +++ b/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1alpha_destination_config_destination.ex @@ -0,0 +1,56 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1alphaDestinationConfigDestination do + @moduledoc """ + Defines a target endpoint + + ## Attributes + + * `host` (*type:* `String.t`, *default:* `nil`) - Publicly routable host. + * `port` (*type:* `integer()`, *default:* `nil`) - Optional. Target port number accepted by the destination. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :host => String.t() | nil, + :port => integer() | nil + } + + field(:host) + field(:port) +end + +defimpl Poison.Decoder, + for: + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1alphaDestinationConfigDestination do + def decode(value, options) do + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1alphaDestinationConfigDestination.decode( + value, + options + ) + end +end + +defimpl Poison.Encoder, + for: + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1alphaDestinationConfigDestination do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1alpha_identity_schedule_config.ex b/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1alpha_identity_schedule_config.ex new file mode 100644 index 0000000000..418aead631 --- /dev/null +++ b/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1alpha_identity_schedule_config.ex @@ -0,0 +1,53 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1alphaIdentityScheduleConfig do + @moduledoc """ + The configuration for the identity data synchronization runs. + + ## Attributes + + * `refreshInterval` (*type:* `String.t`, *default:* `nil`) - 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. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :refreshInterval => String.t() | nil + } + + field(:refreshInterval) +end + +defimpl Poison.Decoder, + for: + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1alphaIdentityScheduleConfig do + def decode(value, options) do + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1alphaIdentityScheduleConfig.decode( + value, + options + ) + end +end + +defimpl Poison.Encoder, + for: + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1alphaIdentityScheduleConfig do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1alpha_set_up_data_connector_metadata.ex b/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1alpha_set_up_data_connector_metadata.ex new file mode 100644 index 0000000000..9d205c8e54 --- /dev/null +++ b/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1alpha_set_up_data_connector_metadata.ex @@ -0,0 +1,48 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1alphaSetUpDataConnectorMetadata do + @moduledoc """ + Metadata for DataConnectorService.SetUpDataConnector method. + + ## Attributes + + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{} +end + +defimpl Poison.Decoder, + for: + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1alphaSetUpDataConnectorMetadata do + def decode(value, options) do + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1alphaSetUpDataConnectorMetadata.decode( + value, + options + ) + end +end + +defimpl Poison.Encoder, + for: + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1alphaSetUpDataConnectorMetadata do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1alpha_single_region_key.ex b/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1alpha_single_region_key.ex new file mode 100644 index 0000000000..a0d32f30cb --- /dev/null +++ b/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1alpha_single_region_key.ex @@ -0,0 +1,51 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1alphaSingleRegionKey do + @moduledoc """ + Metadata for single-regional CMEKs. + + ## Attributes + + * `kmsKey` (*type:* `String.t`, *default:* `nil`) - Required. Single-regional kms key resource name which will be used to encrypt resources `projects/{project}/locations/{location}/keyRings/{keyRing}/cryptoKeys/{keyId}`. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :kmsKey => String.t() | nil + } + + field(:kmsKey) +end + +defimpl Poison.Decoder, + for: GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1alphaSingleRegionKey do + def decode(value, options) do + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1alphaSingleRegionKey.decode( + value, + options + ) + end +end + +defimpl Poison.Encoder, + for: GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1alphaSingleRegionKey do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1alpha_update_collection_metadata.ex b/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1alpha_update_collection_metadata.ex new file mode 100644 index 0000000000..4c6c590f3a --- /dev/null +++ b/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1alpha_update_collection_metadata.ex @@ -0,0 +1,56 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1alphaUpdateCollectionMetadata do + @moduledoc """ + Metadata related to the progress of the CollectionService.UpdateCollection operation. This will be returned by the google.longrunning.Operation.metadata field. + + ## Attributes + + * `createTime` (*type:* `DateTime.t`, *default:* `nil`) - Operation create time. + * `updateTime` (*type:* `DateTime.t`, *default:* `nil`) - Operation last update time. If the operation is done, this is also the finish time. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :createTime => DateTime.t() | nil, + :updateTime => DateTime.t() | nil + } + + field(:createTime, as: DateTime) + field(:updateTime, as: DateTime) +end + +defimpl Poison.Decoder, + for: + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1alphaUpdateCollectionMetadata do + def decode(value, options) do + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1alphaUpdateCollectionMetadata.decode( + value, + options + ) + end +end + +defimpl Poison.Encoder, + for: + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1alphaUpdateCollectionMetadata do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_cmek_config.ex b/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_cmek_config.ex index 3c98e197ca..6012587961 100644 --- a/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_cmek_config.ex +++ b/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_cmek_config.ex @@ -26,6 +26,7 @@ defmodule GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1bet * `kmsKeyVersion` (*type:* `String.t`, *default:* `nil`) - Kms key version resource name which will be used to encrypt resources `/cryptoKeyVersions/{keyVersion}`. * `lastRotationTimestampMicros` (*type:* `String.t`, *default:* `nil`) - Output only. The timestamp of the last key rotation. * `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}`. + * `singleRegionKeys` (*type:* `list(GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaSingleRegionKey.t)`, *default:* `nil`) - Optional. Single-regional CMEKs that are required for some VAIS features. * `state` (*type:* `String.t`, *default:* `nil`) - Output only. State of the CmekConfig. """ @@ -37,6 +38,11 @@ defmodule GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1bet :kmsKeyVersion => String.t() | nil, :lastRotationTimestampMicros => String.t() | nil, :name => String.t() | nil, + :singleRegionKeys => + list( + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaSingleRegionKey.t() + ) + | nil, :state => String.t() | nil } @@ -45,6 +51,12 @@ defmodule GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1bet field(:kmsKeyVersion) field(:lastRotationTimestampMicros) field(:name) + + field(:singleRegionKeys, + as: GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaSingleRegionKey, + type: :list + ) + field(:state) end diff --git a/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_data_store.ex b/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_data_store.ex index 3b554014c3..2d87ccb38e 100644 --- a/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_data_store.ex +++ b/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_data_store.ex @@ -30,6 +30,7 @@ defmodule GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1bet * `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. * `documentProcessingConfig` (*type:* `GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaDocumentProcessingConfig.t`, *default:* `nil`) - Configuration for Document understanding and enrichment. * `industryVertical` (*type:* `String.t`, *default:* `nil`) - Immutable. The industry vertical that the data store registers. + * `isInfobotFaqDataStore` (*type:* `boolean()`, *default:* `nil`) - Optional. If set, this DataStore is an Infobot FAQ DataStore. * `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. * `languageInfo` (*type:* `GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaLanguageInfo.t`, *default:* `nil`) - Language info for DataStore. * `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. @@ -60,6 +61,7 @@ defmodule GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1bet GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaDocumentProcessingConfig.t() | nil, :industryVertical => String.t() | nil, + :isInfobotFaqDataStore => boolean() | nil, :kmsKeyName => String.t() | nil, :languageInfo => GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaLanguageInfo.t() @@ -105,6 +107,7 @@ defmodule GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1bet ) field(:industryVertical) + field(:isInfobotFaqDataStore) field(:kmsKeyName) field(:languageInfo, diff --git a/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_document.ex b/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_document.ex index af8d46e4cd..d2f4272f8b 100644 --- a/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_document.ex +++ b/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_document.ex @@ -24,7 +24,7 @@ defmodule GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1bet * `content` (*type:* `GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaDocumentContent.t`, *default:* `nil`) - The unstructured data linked to this document. Content must be set if this document is under a `CONTENT_REQUIRED` data store. * `derivedStructData` (*type:* `map()`, *default:* `nil`) - Output only. This field is OUTPUT_ONLY. It contains derived data that are not in the original input document. * `id` (*type:* `String.t`, *default:* `nil`) - Immutable. The identifier of the document. Id should conform to [RFC-1034](https://tools.ietf.org/html/rfc1034) standard with a length limit of 63 characters. - * `indexStatus` (*type:* `GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaDocumentIndexStatus.t`, *default:* `nil`) - Output only. The index status of the document. * If document is indexed successfully, the index_time field is populated. * Otherwise, if document is not indexed due to errors, the error_samples field is populated. * Otherwise, index_status is unset. + * `indexStatus` (*type:* `GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaDocumentIndexStatus.t`, *default:* `nil`) - 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. * `indexTime` (*type:* `DateTime.t`, *default:* `nil`) - Output only. The last time the document was indexed. If this field is set, the document could be returned in search results. This field is OUTPUT_ONLY. If this field is not populated, it means the document has never been indexed. * `jsonData` (*type:* `String.t`, *default:* `nil`) - The JSON string representation of the document. It should conform to the registered Schema or an `INVALID_ARGUMENT` error is thrown. * `name` (*type:* `String.t`, *default:* `nil`) - Immutable. The full resource name of the document. Format: `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/branches/{branch}/documents/{document_id}`. This field must be a UTF-8 encoded string with a length limit of 1024 characters. diff --git a/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_document_index_status.ex b/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_document_index_status.ex index 3210dfc97d..624e25d36d 100644 --- a/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_document_index_status.ex +++ b/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_document_index_status.ex @@ -23,17 +23,20 @@ defmodule GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1bet * `errorSamples` (*type:* `list(GoogleApi.DiscoveryEngine.V1beta.Model.GoogleRpcStatus.t)`, *default:* `nil`) - A sample of errors encountered while indexing the document. If this field is populated, the document is not indexed due to errors. * `indexTime` (*type:* `DateTime.t`, *default:* `nil`) - The time when the document was indexed. If this field is populated, it means the document has been indexed. + * `pendingMessage` (*type:* `String.t`, *default:* `nil`) - Immutable. The message indicates the document index is in progress. If this field is populated, the document index is pending. """ use GoogleApi.Gax.ModelBase @type t :: %__MODULE__{ :errorSamples => list(GoogleApi.DiscoveryEngine.V1beta.Model.GoogleRpcStatus.t()) | nil, - :indexTime => DateTime.t() | nil + :indexTime => DateTime.t() | nil, + :pendingMessage => String.t() | nil } field(:errorSamples, as: GoogleApi.DiscoveryEngine.V1beta.Model.GoogleRpcStatus, type: :list) field(:indexTime, as: DateTime) + field(:pendingMessage) end defimpl Poison.Decoder, diff --git a/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_generate_grounded_content_request.ex b/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_generate_grounded_content_request.ex new file mode 100644 index 0000000000..0fff505e1c --- /dev/null +++ b/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_generate_grounded_content_request.ex @@ -0,0 +1,92 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequest do + @moduledoc """ + Top-level message sent by the client for the `GenerateGroundedContent` method. + + ## Attributes + + * `contents` (*type:* `list(GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGroundedGenerationContent.t)`, *default:* `nil`) - 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. + * `generationSpec` (*type:* `GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestGenerationSpec.t`, *default:* `nil`) - Content generation specification. + * `groundingSpec` (*type:* `GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestGroundingSpec.t`, *default:* `nil`) - Grounding specification. + * `systemInstruction` (*type:* `GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGroundedGenerationContent.t`, *default:* `nil`) - 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` (*type:* `map()`, *default:* `nil`) - 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. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :contents => + list( + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGroundedGenerationContent.t() + ) + | nil, + :generationSpec => + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestGenerationSpec.t() + | nil, + :groundingSpec => + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestGroundingSpec.t() + | nil, + :systemInstruction => + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGroundedGenerationContent.t() + | nil, + :userLabels => map() | nil + } + + field(:contents, + as: + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGroundedGenerationContent, + type: :list + ) + + field(:generationSpec, + as: + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestGenerationSpec + ) + + field(:groundingSpec, + as: + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestGroundingSpec + ) + + field(:systemInstruction, + as: + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGroundedGenerationContent + ) + + field(:userLabels, type: :map) +end + +defimpl Poison.Decoder, + for: + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequest do + def decode(value, options) do + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequest.decode( + value, + options + ) + end +end + +defimpl Poison.Encoder, + for: + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequest do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_generate_grounded_content_request_dynamic_retrieval_configuration.ex b/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_generate_grounded_content_request_dynamic_retrieval_configuration.ex new file mode 100644 index 0000000000..6c07555345 --- /dev/null +++ b/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_generate_grounded_content_request_dynamic_retrieval_configuration.ex @@ -0,0 +1,58 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestDynamicRetrievalConfiguration do + @moduledoc """ + Describes the options to customize dynamic retrieval. + + ## Attributes + + * `predictor` (*type:* `GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestDynamicRetrievalConfigurationDynamicRetrievalPredictor.t`, *default:* `nil`) - Specification for the predictor for dynamic retrieval. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :predictor => + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestDynamicRetrievalConfigurationDynamicRetrievalPredictor.t() + | nil + } + + field(:predictor, + as: + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestDynamicRetrievalConfigurationDynamicRetrievalPredictor + ) +end + +defimpl Poison.Decoder, + for: + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestDynamicRetrievalConfiguration do + def decode(value, options) do + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestDynamicRetrievalConfiguration.decode( + value, + options + ) + end +end + +defimpl Poison.Encoder, + for: + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestDynamicRetrievalConfiguration do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_generate_grounded_content_request_dynamic_retrieval_configuration_dynamic_retrieval_predictor.ex b/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_generate_grounded_content_request_dynamic_retrieval_configuration_dynamic_retrieval_predictor.ex new file mode 100644 index 0000000000..ce98858b0b --- /dev/null +++ b/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_generate_grounded_content_request_dynamic_retrieval_configuration_dynamic_retrieval_predictor.ex @@ -0,0 +1,56 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestDynamicRetrievalConfigurationDynamicRetrievalPredictor do + @moduledoc """ + Describes the predictor settings for dynamic retrieval. + + ## Attributes + + * `threshold` (*type:* `number()`, *default:* `nil`) - The value of the threshold. If the predictor will predict a value smaller than this, it would suppress grounding in the source. + * `version` (*type:* `String.t`, *default:* `nil`) - The version of the predictor to be used in dynamic retrieval. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :threshold => number() | nil, + :version => String.t() | nil + } + + field(:threshold) + field(:version) +end + +defimpl Poison.Decoder, + for: + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestDynamicRetrievalConfigurationDynamicRetrievalPredictor do + def decode(value, options) do + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestDynamicRetrievalConfigurationDynamicRetrievalPredictor.decode( + value, + options + ) + end +end + +defimpl Poison.Encoder, + for: + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestDynamicRetrievalConfigurationDynamicRetrievalPredictor do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_generate_grounded_content_request_generation_spec.ex b/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_generate_grounded_content_request_generation_spec.ex new file mode 100644 index 0000000000..c93aa7c74f --- /dev/null +++ b/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_generate_grounded_content_request_generation_spec.ex @@ -0,0 +1,77 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestGenerationSpec do + @moduledoc """ + Content generation specification. + + ## Attributes + + * `frequencyPenalty` (*type:* `number()`, *default:* `nil`) - If specified, custom value for frequency penalty will be used. + * `languageCode` (*type:* `String.t`, *default:* `nil`) - Language code for content. Use language tags defined by [BCP47](https://www.rfc-editor.org/rfc/bcp/bcp47.txt). + * `maxOutputTokens` (*type:* `integer()`, *default:* `nil`) - If specified, custom value for max output tokens will be used. + * `modelId` (*type:* `String.t`, *default:* `nil`) - Specifies which Vertex model id to use for generation. + * `presencePenalty` (*type:* `number()`, *default:* `nil`) - If specified, custom value for presence penalty will be used. + * `seed` (*type:* `integer()`, *default:* `nil`) - If specified, custom value for the seed will be used. + * `temperature` (*type:* `number()`, *default:* `nil`) - If specified, custom value for the temperature will be used. + * `topK` (*type:* `integer()`, *default:* `nil`) - If specified, custom value for top-k sampling will be used. + * `topP` (*type:* `number()`, *default:* `nil`) - If specified, custom value for nucleus sampling will be used. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :frequencyPenalty => number() | nil, + :languageCode => String.t() | nil, + :maxOutputTokens => integer() | nil, + :modelId => String.t() | nil, + :presencePenalty => number() | nil, + :seed => integer() | nil, + :temperature => number() | nil, + :topK => integer() | nil, + :topP => number() | nil + } + + field(:frequencyPenalty) + field(:languageCode) + field(:maxOutputTokens) + field(:modelId) + field(:presencePenalty) + field(:seed) + field(:temperature) + field(:topK) + field(:topP) +end + +defimpl Poison.Decoder, + for: + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestGenerationSpec do + def decode(value, options) do + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestGenerationSpec.decode( + value, + options + ) + end +end + +defimpl Poison.Encoder, + for: + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestGenerationSpec do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_generate_grounded_content_request_grounding_source.ex b/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_generate_grounded_content_request_grounding_source.ex new file mode 100644 index 0000000000..da01ba1a19 --- /dev/null +++ b/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_generate_grounded_content_request_grounding_source.ex @@ -0,0 +1,76 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestGroundingSource do + @moduledoc """ + Grounding source. + + ## Attributes + + * `googleSearchSource` (*type:* `GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestGroundingSourceGoogleSearchSource.t`, *default:* `nil`) - If set, grounding is performed with Google Search. + * `inlineSource` (*type:* `GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestGroundingSourceInlineSource.t`, *default:* `nil`) - If set, grounding is performed with inline content. + * `searchSource` (*type:* `GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestGroundingSourceSearchSource.t`, *default:* `nil`) - If set, grounding is performed with Vertex AI Search. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :googleSearchSource => + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestGroundingSourceGoogleSearchSource.t() + | nil, + :inlineSource => + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestGroundingSourceInlineSource.t() + | nil, + :searchSource => + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestGroundingSourceSearchSource.t() + | nil + } + + field(:googleSearchSource, + as: + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestGroundingSourceGoogleSearchSource + ) + + field(:inlineSource, + as: + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestGroundingSourceInlineSource + ) + + field(:searchSource, + as: + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestGroundingSourceSearchSource + ) +end + +defimpl Poison.Decoder, + for: + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestGroundingSource do + def decode(value, options) do + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestGroundingSource.decode( + value, + options + ) + end +end + +defimpl Poison.Encoder, + for: + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestGroundingSource do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_generate_grounded_content_request_grounding_source_google_search_source.ex b/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_generate_grounded_content_request_grounding_source_google_search_source.ex new file mode 100644 index 0000000000..5146dd3067 --- /dev/null +++ b/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_generate_grounded_content_request_grounding_source_google_search_source.ex @@ -0,0 +1,58 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestGroundingSourceGoogleSearchSource do + @moduledoc """ + Google Search config parameters. + + ## Attributes + + * `dynamicRetrievalConfig` (*type:* `GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestDynamicRetrievalConfiguration.t`, *default:* `nil`) - Optional. Specifies the dynamic retrieval configuration for the given source. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :dynamicRetrievalConfig => + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestDynamicRetrievalConfiguration.t() + | nil + } + + field(:dynamicRetrievalConfig, + as: + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestDynamicRetrievalConfiguration + ) +end + +defimpl Poison.Decoder, + for: + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestGroundingSourceGoogleSearchSource do + def decode(value, options) do + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestGroundingSourceGoogleSearchSource.decode( + value, + options + ) + end +end + +defimpl Poison.Encoder, + for: + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestGroundingSourceGoogleSearchSource do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_generate_grounded_content_request_grounding_source_inline_source.ex b/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_generate_grounded_content_request_grounding_source_inline_source.ex new file mode 100644 index 0000000000..e152262848 --- /dev/null +++ b/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_generate_grounded_content_request_grounding_source_inline_source.ex @@ -0,0 +1,64 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestGroundingSourceInlineSource do + @moduledoc """ + Message to be used for grounding based on inline content. + + ## Attributes + + * `attributes` (*type:* `map()`, *default:* `nil`) - Attributes associated with the content. Common attributes include `source` (indicating where the content was sourced from) and `author` (indicating the author of the content). + * `groundingFacts` (*type:* `list(GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGroundingFact.t)`, *default:* `nil`) - List of facts to be used for grounding. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :attributes => map() | nil, + :groundingFacts => + list( + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGroundingFact.t() + ) + | nil + } + + field(:attributes, type: :map) + + field(:groundingFacts, + as: GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGroundingFact, + type: :list + ) +end + +defimpl Poison.Decoder, + for: + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestGroundingSourceInlineSource do + def decode(value, options) do + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestGroundingSourceInlineSource.decode( + value, + options + ) + end +end + +defimpl Poison.Encoder, + for: + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestGroundingSourceInlineSource do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_generate_grounded_content_request_grounding_source_search_source.ex b/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_generate_grounded_content_request_grounding_source_search_source.ex new file mode 100644 index 0000000000..5e379fa1c2 --- /dev/null +++ b/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_generate_grounded_content_request_grounding_source_search_source.ex @@ -0,0 +1,62 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestGroundingSourceSearchSource do + @moduledoc """ + Message to be used for grounding with Vertex AI Search. + + ## Attributes + + * `filter` (*type:* `String.t`, *default:* `nil`) - Filter expression to be applied to the search. The syntax is the same as SearchRequest.filter. + * `maxResultCount` (*type:* `integer()`, *default:* `nil`) - Number of search results to return. The default value is 10. The maximumm allowed value is 10. + * `safeSearch` (*type:* `boolean()`, *default:* `nil`) - If set, safe search is enabled in Vertex AI Search requests. + * `servingConfig` (*type:* `String.t`, *default:* `nil`) - The resource name of the Engine to use. Format: `projects/{project}/locations/{location}/collections/{collection_id}/engines/{engine_id}/servingConfigs/{serving_config_id}` + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :filter => String.t() | nil, + :maxResultCount => integer() | nil, + :safeSearch => boolean() | nil, + :servingConfig => String.t() | nil + } + + field(:filter) + field(:maxResultCount) + field(:safeSearch) + field(:servingConfig) +end + +defimpl Poison.Decoder, + for: + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestGroundingSourceSearchSource do + def decode(value, options) do + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestGroundingSourceSearchSource.decode( + value, + options + ) + end +end + +defimpl Poison.Encoder, + for: + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestGroundingSourceSearchSource do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_generate_grounded_content_request_grounding_spec.ex b/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_generate_grounded_content_request_grounding_spec.ex new file mode 100644 index 0000000000..ad25e6c7af --- /dev/null +++ b/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_generate_grounded_content_request_grounding_spec.ex @@ -0,0 +1,61 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestGroundingSpec do + @moduledoc """ + Grounding specification. + + ## Attributes + + * `groundingSources` (*type:* `list(GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestGroundingSource.t)`, *default:* `nil`) - Grounding sources. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :groundingSources => + list( + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestGroundingSource.t() + ) + | nil + } + + field(:groundingSources, + as: + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestGroundingSource, + type: :list + ) +end + +defimpl Poison.Decoder, + for: + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestGroundingSpec do + def decode(value, options) do + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestGroundingSpec.decode( + value, + options + ) + end +end + +defimpl Poison.Encoder, + for: + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentRequestGroundingSpec do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_generate_grounded_content_response.ex b/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_generate_grounded_content_response.ex new file mode 100644 index 0000000000..cccd484975 --- /dev/null +++ b/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_generate_grounded_content_response.ex @@ -0,0 +1,61 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponse do + @moduledoc """ + Response for the `GenerateGroundedContent` method. + + ## Attributes + + * `candidates` (*type:* `list(GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidate.t)`, *default:* `nil`) - Generated candidates. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :candidates => + list( + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidate.t() + ) + | nil + } + + field(:candidates, + as: + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidate, + type: :list + ) +end + +defimpl Poison.Decoder, + for: + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponse do + def decode(value, options) do + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponse.decode( + value, + options + ) + end +end + +defimpl Poison.Encoder, + for: + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponse do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_generate_grounded_content_response_candidate.ex b/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_generate_grounded_content_response_candidate.ex new file mode 100644 index 0000000000..bfca4aeaad --- /dev/null +++ b/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_generate_grounded_content_response_candidate.ex @@ -0,0 +1,74 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidate do + @moduledoc """ + A response candidate generated from the model. + + ## Attributes + + * `content` (*type:* `GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGroundedGenerationContent.t`, *default:* `nil`) - Content of the candidate. + * `groundingMetadata` (*type:* `GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidateGroundingMetadata.t`, *default:* `nil`) - Grounding metadata for the generated content. + * `groundingScore` (*type:* `number()`, *default:* `nil`) - The overall grounding score for the candidate, in the range of [0, 1]. + * `index` (*type:* `integer()`, *default:* `nil`) - Index of the candidate. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :content => + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGroundedGenerationContent.t() + | nil, + :groundingMetadata => + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidateGroundingMetadata.t() + | nil, + :groundingScore => number() | nil, + :index => integer() | nil + } + + field(:content, + as: + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGroundedGenerationContent + ) + + field(:groundingMetadata, + as: + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidateGroundingMetadata + ) + + field(:groundingScore) + field(:index) +end + +defimpl Poison.Decoder, + for: + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidate do + def decode(value, options) do + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidate.decode( + value, + options + ) + end +end + +defimpl Poison.Encoder, + for: + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidate do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_generate_grounded_content_response_candidate_grounding_metadata.ex b/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_generate_grounded_content_response_candidate_grounding_metadata.ex new file mode 100644 index 0000000000..4a4f7709f6 --- /dev/null +++ b/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_generate_grounded_content_response_candidate_grounding_metadata.ex @@ -0,0 +1,97 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidateGroundingMetadata do + @moduledoc """ + Citation for the generated content. + + ## Attributes + + * `groundingSupport` (*type:* `list(GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidateGroundingMetadataGroundingSupport.t)`, *default:* `nil`) - GroundingSupport across all claims in the answer candidate. An support to a fact indicates that the claim is supported by the fact. + * `retrievalMetadata` (*type:* `list(GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidateGroundingMetadataRetrievalMetadata.t)`, *default:* `nil`) - 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. + * `searchEntryPoint` (*type:* `GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidateGroundingMetadataSearchEntryPoint.t`, *default:* `nil`) - Google search entry for the following-up web searches. + * `supportChunks` (*type:* `list(GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaFactChunk.t)`, *default:* `nil`) - List of chunks to be attributed across all claims in the candidate. These are derived from the grounding sources supplied in the request. + * `webSearchQueries` (*type:* `list(String.t)`, *default:* `nil`) - Web search queries for the following-up web search. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :groundingSupport => + list( + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidateGroundingMetadataGroundingSupport.t() + ) + | nil, + :retrievalMetadata => + list( + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidateGroundingMetadataRetrievalMetadata.t() + ) + | nil, + :searchEntryPoint => + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidateGroundingMetadataSearchEntryPoint.t() + | nil, + :supportChunks => + list( + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaFactChunk.t() + ) + | nil, + :webSearchQueries => list(String.t()) | nil + } + + field(:groundingSupport, + as: + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidateGroundingMetadataGroundingSupport, + type: :list + ) + + field(:retrievalMetadata, + as: + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidateGroundingMetadataRetrievalMetadata, + type: :list + ) + + field(:searchEntryPoint, + as: + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidateGroundingMetadataSearchEntryPoint + ) + + field(:supportChunks, + as: GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaFactChunk, + type: :list + ) + + field(:webSearchQueries, type: :list) +end + +defimpl Poison.Decoder, + for: + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidateGroundingMetadata do + def decode(value, options) do + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidateGroundingMetadata.decode( + value, + options + ) + end +end + +defimpl Poison.Encoder, + for: + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidateGroundingMetadata do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_generate_grounded_content_response_candidate_grounding_metadata_dynamic_retrieval_metadata.ex b/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_generate_grounded_content_response_candidate_grounding_metadata_dynamic_retrieval_metadata.ex new file mode 100644 index 0000000000..5f5402a3c8 --- /dev/null +++ b/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_generate_grounded_content_response_candidate_grounding_metadata_dynamic_retrieval_metadata.ex @@ -0,0 +1,58 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidateGroundingMetadataDynamicRetrievalMetadata do + @moduledoc """ + Describes the metadata about dynamic retrieval. + + ## Attributes + + * `predictorMetadata` (*type:* `GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidateGroundingMetadataDynamicRetrievalPredictorMetadata.t`, *default:* `nil`) - Metadata for the dynamic retrieval predictor. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :predictorMetadata => + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidateGroundingMetadataDynamicRetrievalPredictorMetadata.t() + | nil + } + + field(:predictorMetadata, + as: + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidateGroundingMetadataDynamicRetrievalPredictorMetadata + ) +end + +defimpl Poison.Decoder, + for: + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidateGroundingMetadataDynamicRetrievalMetadata do + def decode(value, options) do + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidateGroundingMetadataDynamicRetrievalMetadata.decode( + value, + options + ) + end +end + +defimpl Poison.Encoder, + for: + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidateGroundingMetadataDynamicRetrievalMetadata do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_generate_grounded_content_response_candidate_grounding_metadata_dynamic_retrieval_predictor_metadata.ex b/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_generate_grounded_content_response_candidate_grounding_metadata_dynamic_retrieval_predictor_metadata.ex new file mode 100644 index 0000000000..071aa6c42e --- /dev/null +++ b/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_generate_grounded_content_response_candidate_grounding_metadata_dynamic_retrieval_predictor_metadata.ex @@ -0,0 +1,56 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidateGroundingMetadataDynamicRetrievalPredictorMetadata do + @moduledoc """ + Describes the metadata about the dynamic retrieval predictor. + + ## Attributes + + * `prediction` (*type:* `number()`, *default:* `nil`) - 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. + * `version` (*type:* `String.t`, *default:* `nil`) - The version of the predictor which was used in dynamic retrieval. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :prediction => number() | nil, + :version => String.t() | nil + } + + field(:prediction) + field(:version) +end + +defimpl Poison.Decoder, + for: + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidateGroundingMetadataDynamicRetrievalPredictorMetadata do + def decode(value, options) do + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidateGroundingMetadataDynamicRetrievalPredictorMetadata.decode( + value, + options + ) + end +end + +defimpl Poison.Encoder, + for: + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidateGroundingMetadataDynamicRetrievalPredictorMetadata do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_generate_grounded_content_response_candidate_grounding_metadata_grounding_support.ex b/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_generate_grounded_content_response_candidate_grounding_metadata_grounding_support.ex new file mode 100644 index 0000000000..5d15de3e72 --- /dev/null +++ b/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_generate_grounded_content_response_candidate_grounding_metadata_grounding_support.ex @@ -0,0 +1,59 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidateGroundingMetadataGroundingSupport do + @moduledoc """ + Grounding info for a claim in the candidate and its support. + + ## Attributes + + * `claimText` (*type:* `String.t`, *default:* `nil`) - Text for the claim in the candidate. Always provided when a support is found. + * `supportChunkIndices` (*type:* `list(integer())`, *default:* `nil`) - 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. + * `supportScore` (*type:* `number()`, *default:* `nil`) - 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. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :claimText => String.t() | nil, + :supportChunkIndices => list(integer()) | nil, + :supportScore => number() | nil + } + + field(:claimText) + field(:supportChunkIndices, type: :list) + field(:supportScore) +end + +defimpl Poison.Decoder, + for: + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidateGroundingMetadataGroundingSupport do + def decode(value, options) do + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidateGroundingMetadataGroundingSupport.decode( + value, + options + ) + end +end + +defimpl Poison.Encoder, + for: + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidateGroundingMetadataGroundingSupport do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_generate_grounded_content_response_candidate_grounding_metadata_retrieval_metadata.ex b/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_generate_grounded_content_response_candidate_grounding_metadata_retrieval_metadata.ex new file mode 100644 index 0000000000..fe4de707e0 --- /dev/null +++ b/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_generate_grounded_content_response_candidate_grounding_metadata_retrieval_metadata.ex @@ -0,0 +1,62 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidateGroundingMetadataRetrievalMetadata do + @moduledoc """ + Describes the metadata associated with a retrieval step. + + ## Attributes + + * `dynamicRetrievalMetadata` (*type:* `GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidateGroundingMetadataDynamicRetrievalMetadata.t`, *default:* `nil`) - Metadata for dynamic retrieval. + * `source` (*type:* `String.t`, *default:* `nil`) - Describes the source to which the metadata is referring to. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :dynamicRetrievalMetadata => + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidateGroundingMetadataDynamicRetrievalMetadata.t() + | nil, + :source => String.t() | nil + } + + field(:dynamicRetrievalMetadata, + as: + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidateGroundingMetadataDynamicRetrievalMetadata + ) + + field(:source) +end + +defimpl Poison.Decoder, + for: + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidateGroundingMetadataRetrievalMetadata do + def decode(value, options) do + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidateGroundingMetadataRetrievalMetadata.decode( + value, + options + ) + end +end + +defimpl Poison.Encoder, + for: + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidateGroundingMetadataRetrievalMetadata do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_generate_grounded_content_response_candidate_grounding_metadata_search_entry_point.ex b/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_generate_grounded_content_response_candidate_grounding_metadata_search_entry_point.ex new file mode 100644 index 0000000000..2b4fe6d741 --- /dev/null +++ b/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_generate_grounded_content_response_candidate_grounding_metadata_search_entry_point.ex @@ -0,0 +1,56 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidateGroundingMetadataSearchEntryPoint do + @moduledoc """ + Google search entry point. + + ## Attributes + + * `renderedContent` (*type:* `String.t`, *default:* `nil`) - Web content snippet that can be embedded in a web page or an app webview. + * `sdkBlob` (*type:* `String.t`, *default:* `nil`) - Base64 encoded JSON representing array of tuple. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :renderedContent => String.t() | nil, + :sdkBlob => String.t() | nil + } + + field(:renderedContent) + field(:sdkBlob) +end + +defimpl Poison.Decoder, + for: + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidateGroundingMetadataSearchEntryPoint do + def decode(value, options) do + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidateGroundingMetadataSearchEntryPoint.decode( + value, + options + ) + end +end + +defimpl Poison.Encoder, + for: + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGenerateGroundedContentResponseCandidateGroundingMetadataSearchEntryPoint do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_grounded_generation_content.ex b/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_grounded_generation_content.ex new file mode 100644 index 0000000000..f64a661ba8 --- /dev/null +++ b/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_grounded_generation_content.ex @@ -0,0 +1,65 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGroundedGenerationContent do + @moduledoc """ + Base structured datatype containing multi-part content of a message. + + ## Attributes + + * `parts` (*type:* `list(GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGroundedGenerationContentPart.t)`, *default:* `nil`) - Ordered `Parts` that constitute a single message. + * `role` (*type:* `String.t`, *default:* `nil`) - Producer of the content. Must be either `user` or `model`. Intended to be used for multi-turn conversations. Otherwise, it can be left unset. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :parts => + list( + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGroundedGenerationContentPart.t() + ) + | nil, + :role => String.t() | nil + } + + field(:parts, + as: + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGroundedGenerationContentPart, + type: :list + ) + + field(:role) +end + +defimpl Poison.Decoder, + for: + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGroundedGenerationContent do + def decode(value, options) do + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGroundedGenerationContent.decode( + value, + options + ) + end +end + +defimpl Poison.Encoder, + for: + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGroundedGenerationContent do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_grounded_generation_content_part.ex b/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_grounded_generation_content_part.ex new file mode 100644 index 0000000000..6d3eadbe16 --- /dev/null +++ b/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_grounded_generation_content_part.ex @@ -0,0 +1,53 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGroundedGenerationContentPart do + @moduledoc """ + Single part of content. + + ## Attributes + + * `text` (*type:* `String.t`, *default:* `nil`) - Inline text. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :text => String.t() | nil + } + + field(:text) +end + +defimpl Poison.Decoder, + for: + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGroundedGenerationContentPart do + def decode(value, options) do + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGroundedGenerationContentPart.decode( + value, + options + ) + end +end + +defimpl Poison.Encoder, + for: + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaGroundedGenerationContentPart do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_single_region_key.ex b/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_single_region_key.ex new file mode 100644 index 0000000000..2d5cc821ab --- /dev/null +++ b/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_cloud_discoveryengine_v1beta_single_region_key.ex @@ -0,0 +1,51 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaSingleRegionKey do + @moduledoc """ + Metadata for single-regional CMEKs. + + ## Attributes + + * `kmsKey` (*type:* `String.t`, *default:* `nil`) - Required. Single-regional kms key resource name which will be used to encrypt resources `projects/{project}/locations/{location}/keyRings/{keyRing}/cryptoKeys/{keyId}`. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :kmsKey => String.t() | nil + } + + field(:kmsKey) +end + +defimpl Poison.Decoder, + for: GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaSingleRegionKey do + def decode(value, options) do + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaSingleRegionKey.decode( + value, + options + ) + end +end + +defimpl Poison.Encoder, + for: GoogleApi.DiscoveryEngine.V1beta.Model.GoogleCloudDiscoveryengineV1betaSingleRegionKey do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_type_date_time.ex b/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_type_date_time.ex new file mode 100644 index 0000000000..bde717e6c8 --- /dev/null +++ b/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_type_date_time.ex @@ -0,0 +1,70 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DiscoveryEngine.V1beta.Model.GoogleTypeDateTime do + @moduledoc """ + 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. + + ## Attributes + + * `day` (*type:* `integer()`, *default:* `nil`) - 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. + * `hours` (*type:* `integer()`, *default:* `nil`) - 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. + * `minutes` (*type:* `integer()`, *default:* `nil`) - Optional. Minutes of hour of day. Must be from 0 to 59, defaults to 0. + * `month` (*type:* `integer()`, *default:* `nil`) - Optional. Month of year. Must be from 1 to 12, or 0 if specifying a datetime without a month. + * `nanos` (*type:* `integer()`, *default:* `nil`) - Optional. Fractions of seconds in nanoseconds. Must be from 0 to 999,999,999, defaults to 0. + * `seconds` (*type:* `integer()`, *default:* `nil`) - 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. + * `timeZone` (*type:* `GoogleApi.DiscoveryEngine.V1beta.Model.GoogleTypeTimeZone.t`, *default:* `nil`) - Time zone. + * `utcOffset` (*type:* `String.t`, *default:* `nil`) - 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 }. + * `year` (*type:* `integer()`, *default:* `nil`) - Optional. Year of date. Must be from 1 to 9999, or 0 if specifying a datetime without a year. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :day => integer() | nil, + :hours => integer() | nil, + :minutes => integer() | nil, + :month => integer() | nil, + :nanos => integer() | nil, + :seconds => integer() | nil, + :timeZone => GoogleApi.DiscoveryEngine.V1beta.Model.GoogleTypeTimeZone.t() | nil, + :utcOffset => String.t() | nil, + :year => integer() | nil + } + + field(:day) + field(:hours) + field(:minutes) + field(:month) + field(:nanos) + field(:seconds) + field(:timeZone, as: GoogleApi.DiscoveryEngine.V1beta.Model.GoogleTypeTimeZone) + field(:utcOffset) + field(:year) +end + +defimpl Poison.Decoder, for: GoogleApi.DiscoveryEngine.V1beta.Model.GoogleTypeDateTime do + def decode(value, options) do + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleTypeDateTime.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.DiscoveryEngine.V1beta.Model.GoogleTypeDateTime do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_type_time_zone.ex b/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_type_time_zone.ex new file mode 100644 index 0000000000..9582580fba --- /dev/null +++ b/clients/discovery_engine/lib/google_api/discovery_engine/v1beta/model/google_type_time_zone.ex @@ -0,0 +1,49 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DiscoveryEngine.V1beta.Model.GoogleTypeTimeZone do + @moduledoc """ + Represents a time zone from the [IANA Time Zone Database](https://www.iana.org/time-zones). + + ## Attributes + + * `id` (*type:* `String.t`, *default:* `nil`) - IANA Time Zone Database time zone. For example "America/New_York". + * `version` (*type:* `String.t`, *default:* `nil`) - Optional. IANA Time Zone Database version number. For example "2019a". + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :id => String.t() | nil, + :version => String.t() | nil + } + + field(:id) + field(:version) +end + +defimpl Poison.Decoder, for: GoogleApi.DiscoveryEngine.V1beta.Model.GoogleTypeTimeZone do + def decode(value, options) do + GoogleApi.DiscoveryEngine.V1beta.Model.GoogleTypeTimeZone.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.DiscoveryEngine.V1beta.Model.GoogleTypeTimeZone do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/discovery_engine/mix.exs b/clients/discovery_engine/mix.exs index 25b6039288..ef37b594a1 100644 --- a/clients/discovery_engine/mix.exs +++ b/clients/discovery_engine/mix.exs @@ -18,7 +18,7 @@ defmodule GoogleApi.DiscoveryEngine.Mixfile do use Mix.Project - @version "0.27.0" + @version "0.28.0" def project() do [