google-cloud-discovery_engine-v1 2.13.0 → 2.14.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/AUTHENTICATION.md +4 -4
- data/README.md +8 -10
- data/lib/google/cloud/discovery_engine/v1/acl_config_service/client.rb +591 -0
- data/lib/google/cloud/discovery_engine/v1/acl_config_service/credentials.rb +49 -0
- data/lib/google/cloud/discovery_engine/v1/acl_config_service/paths.rb +50 -0
- data/lib/google/cloud/discovery_engine/v1/acl_config_service/rest/client.rb +534 -0
- data/lib/google/cloud/discovery_engine/v1/acl_config_service/rest/service_stub.rb +204 -0
- data/lib/google/cloud/discovery_engine/v1/acl_config_service/rest.rb +52 -0
- data/lib/google/cloud/discovery_engine/v1/acl_config_service.rb +55 -0
- data/lib/google/cloud/discovery_engine/v1/assistant_service/client.rb +528 -0
- data/lib/google/cloud/discovery_engine/v1/assistant_service/credentials.rb +4 -1
- data/lib/google/cloud/discovery_engine/v1/assistant_service/paths.rb +104 -0
- data/lib/google/cloud/discovery_engine/v1/assistant_service/rest/client.rb +493 -0
- data/lib/google/cloud/discovery_engine/v1/assistant_service/rest/service_stub.rb +307 -0
- data/lib/google/cloud/discovery_engine/v1/cmek_config_service/credentials.rb +3 -1
- data/lib/google/cloud/discovery_engine/v1/cmek_config_service/rest/operations.rb +7 -0
- data/lib/google/cloud/discovery_engine/v1/collection_service/client.rb +732 -0
- data/lib/google/cloud/discovery_engine/v1/collection_service/credentials.rb +49 -0
- data/lib/google/cloud/discovery_engine/v1/collection_service/operations.rb +843 -0
- data/lib/google/cloud/discovery_engine/v1/collection_service/paths.rb +52 -0
- data/lib/google/cloud/discovery_engine/v1/collection_service/rest/client.rb +668 -0
- data/lib/google/cloud/discovery_engine/v1/collection_service/rest/operations.rb +1168 -0
- data/lib/google/cloud/discovery_engine/v1/collection_service/rest/service_stub.rb +265 -0
- data/lib/google/cloud/discovery_engine/v1/collection_service/rest.rb +54 -0
- data/lib/google/cloud/discovery_engine/v1/collection_service.rb +57 -0
- data/lib/google/cloud/discovery_engine/v1/completion_service/client.rb +162 -4
- data/lib/google/cloud/discovery_engine/v1/completion_service/credentials.rb +5 -1
- data/lib/google/cloud/discovery_engine/v1/completion_service/paths.rb +62 -0
- data/lib/google/cloud/discovery_engine/v1/completion_service/rest/client.rb +155 -4
- data/lib/google/cloud/discovery_engine/v1/completion_service/rest/operations.rb +7 -0
- data/lib/google/cloud/discovery_engine/v1/completion_service/rest/service_stub.rb +78 -0
- data/lib/google/cloud/discovery_engine/v1/control_service/credentials.rb +3 -1
- data/lib/google/cloud/discovery_engine/v1/conversational_search_service/client.rb +37 -9
- data/lib/google/cloud/discovery_engine/v1/conversational_search_service/credentials.rb +3 -1
- data/lib/google/cloud/discovery_engine/v1/conversational_search_service/paths.rb +21 -0
- data/lib/google/cloud/discovery_engine/v1/conversational_search_service/rest/client.rb +37 -9
- data/lib/google/cloud/discovery_engine/v1/data_connector_service/client.rb +779 -0
- data/lib/google/cloud/discovery_engine/v1/data_connector_service/credentials.rb +50 -0
- data/lib/google/cloud/discovery_engine/v1/data_connector_service/operations.rb +843 -0
- data/lib/google/cloud/discovery_engine/v1/data_connector_service/paths.rb +227 -0
- data/lib/google/cloud/discovery_engine/v1/data_connector_service/rest/client.rb +715 -0
- data/lib/google/cloud/discovery_engine/v1/data_connector_service/rest/operations.rb +1168 -0
- data/lib/google/cloud/discovery_engine/v1/data_connector_service/rest/service_stub.rb +274 -0
- data/lib/google/cloud/discovery_engine/v1/data_connector_service/rest.rb +53 -0
- data/lib/google/cloud/discovery_engine/v1/data_connector_service.rb +56 -0
- data/lib/google/cloud/discovery_engine/v1/data_store_service/client.rb +215 -0
- data/lib/google/cloud/discovery_engine/v1/data_store_service/credentials.rb +3 -1
- data/lib/google/cloud/discovery_engine/v1/data_store_service/paths.rb +62 -0
- data/lib/google/cloud/discovery_engine/v1/data_store_service/rest/client.rb +201 -0
- data/lib/google/cloud/discovery_engine/v1/data_store_service/rest/operations.rb +7 -0
- data/lib/google/cloud/discovery_engine/v1/data_store_service/rest/service_stub.rb +138 -0
- data/lib/google/cloud/discovery_engine/v1/document_service/client.rb +0 -1
- data/lib/google/cloud/discovery_engine/v1/document_service/credentials.rb +3 -1
- data/lib/google/cloud/discovery_engine/v1/document_service/rest/client.rb +0 -1
- data/lib/google/cloud/discovery_engine/v1/document_service/rest/operations.rb +7 -0
- data/lib/google/cloud/discovery_engine/v1/engine_service/client.rb +218 -3
- data/lib/google/cloud/discovery_engine/v1/engine_service/credentials.rb +3 -1
- data/lib/google/cloud/discovery_engine/v1/engine_service/paths.rb +104 -0
- data/lib/google/cloud/discovery_engine/v1/engine_service/rest/client.rb +204 -3
- data/lib/google/cloud/discovery_engine/v1/engine_service/rest/operations.rb +7 -0
- data/lib/google/cloud/discovery_engine/v1/engine_service/rest/service_stub.rb +123 -0
- data/lib/google/cloud/discovery_engine/v1/grounded_generation_service/credentials.rb +3 -1
- data/lib/google/cloud/discovery_engine/v1/identity_mapping_store_service/client.rb +1 -0
- data/lib/google/cloud/discovery_engine/v1/identity_mapping_store_service/credentials.rb +3 -1
- data/lib/google/cloud/discovery_engine/v1/identity_mapping_store_service/rest/client.rb +1 -0
- data/lib/google/cloud/discovery_engine/v1/identity_mapping_store_service/rest/operations.rb +7 -0
- data/lib/google/cloud/discovery_engine/v1/license_config_service/client.rb +1044 -0
- data/lib/google/cloud/discovery_engine/v1/license_config_service/credentials.rb +49 -0
- data/lib/google/cloud/discovery_engine/v1/license_config_service/paths.rb +86 -0
- data/lib/google/cloud/discovery_engine/v1/license_config_service/rest/client.rb +959 -0
- data/lib/google/cloud/discovery_engine/v1/license_config_service/rest/service_stub.rb +451 -0
- data/lib/google/cloud/discovery_engine/v1/license_config_service/rest.rb +52 -0
- data/lib/google/cloud/discovery_engine/v1/license_config_service.rb +55 -0
- data/lib/google/cloud/discovery_engine/v1/project_service/client.rb +3 -1
- data/lib/google/cloud/discovery_engine/v1/project_service/credentials.rb +3 -1
- data/lib/google/cloud/discovery_engine/v1/project_service/rest/client.rb +3 -1
- data/lib/google/cloud/discovery_engine/v1/project_service/rest/operations.rb +7 -0
- data/lib/google/cloud/discovery_engine/v1/project_service/rest/service_stub.rb +8 -0
- data/lib/google/cloud/discovery_engine/v1/rank_service/client.rb +1 -1
- data/lib/google/cloud/discovery_engine/v1/rank_service/credentials.rb +3 -1
- data/lib/google/cloud/discovery_engine/v1/rank_service/rest/client.rb +1 -1
- data/lib/google/cloud/discovery_engine/v1/recommendation_service/credentials.rb +3 -1
- data/lib/google/cloud/discovery_engine/v1/rest.rb +8 -2
- data/lib/google/cloud/discovery_engine/v1/schema_service/credentials.rb +3 -1
- data/lib/google/cloud/discovery_engine/v1/schema_service/rest/operations.rb +7 -0
- data/lib/google/cloud/discovery_engine/v1/search_service/client.rb +14 -2
- data/lib/google/cloud/discovery_engine/v1/search_service/paths.rb +21 -0
- data/lib/google/cloud/discovery_engine/v1/search_service/rest/client.rb +14 -2
- data/lib/google/cloud/discovery_engine/v1/search_tuning_service/credentials.rb +3 -1
- data/lib/google/cloud/discovery_engine/v1/search_tuning_service/rest/operations.rb +7 -0
- data/lib/google/cloud/discovery_engine/v1/serving_config_service/client.rb +408 -3
- data/lib/google/cloud/discovery_engine/v1/serving_config_service/credentials.rb +3 -1
- data/lib/google/cloud/discovery_engine/v1/serving_config_service/paths.rb +66 -0
- data/lib/google/cloud/discovery_engine/v1/serving_config_service/rest/client.rb +380 -3
- data/lib/google/cloud/discovery_engine/v1/serving_config_service/rest/service_stub.rb +303 -0
- data/lib/google/cloud/discovery_engine/v1/session_service/client.rb +25 -9
- data/lib/google/cloud/discovery_engine/v1/session_service/credentials.rb +4 -1
- data/lib/google/cloud/discovery_engine/v1/session_service/paths.rb +21 -0
- data/lib/google/cloud/discovery_engine/v1/session_service/rest/client.rb +25 -9
- data/lib/google/cloud/discovery_engine/v1/site_search_engine_service/credentials.rb +3 -1
- data/lib/google/cloud/discovery_engine/v1/site_search_engine_service/rest/operations.rb +7 -0
- data/lib/google/cloud/discovery_engine/v1/user_event_service/credentials.rb +4 -1
- data/lib/google/cloud/discovery_engine/v1/user_event_service/rest/operations.rb +7 -0
- data/lib/google/cloud/discovery_engine/v1/user_license_service/client.rb +124 -7
- data/lib/google/cloud/discovery_engine/v1/user_license_service/credentials.rb +3 -1
- data/lib/google/cloud/discovery_engine/v1/user_license_service/rest/client.rb +117 -7
- data/lib/google/cloud/discovery_engine/v1/user_license_service/rest/operations.rb +7 -0
- data/lib/google/cloud/discovery_engine/v1/user_license_service/rest/service_stub.rb +61 -0
- data/lib/google/cloud/discovery_engine/v1/user_store_service/client.rb +590 -0
- data/lib/google/cloud/discovery_engine/v1/user_store_service/credentials.rb +49 -0
- data/lib/google/cloud/discovery_engine/v1/user_store_service/paths.rb +71 -0
- data/lib/google/cloud/discovery_engine/v1/user_store_service/rest/client.rb +533 -0
- data/lib/google/cloud/discovery_engine/v1/user_store_service/rest/service_stub.rb +204 -0
- data/lib/google/cloud/discovery_engine/v1/user_store_service/rest.rb +52 -0
- data/lib/google/cloud/discovery_engine/v1/user_store_service.rb +55 -0
- data/lib/google/cloud/discovery_engine/v1/version.rb +1 -1
- data/lib/google/cloud/discovery_engine/v1/widget_config_service/client.rb +624 -0
- data/lib/google/cloud/discovery_engine/v1/widget_config_service/credentials.rb +50 -0
- data/lib/google/cloud/discovery_engine/v1/widget_config_service/paths.rb +101 -0
- data/lib/google/cloud/discovery_engine/v1/widget_config_service/rest/client.rb +567 -0
- data/lib/google/cloud/discovery_engine/v1/widget_config_service/rest/service_stub.rb +234 -0
- data/lib/google/cloud/discovery_engine/v1/widget_config_service/rest.rb +53 -0
- data/lib/google/cloud/discovery_engine/v1/widget_config_service.rb +56 -0
- data/lib/google/cloud/discovery_engine/v1.rb +9 -3
- data/lib/google/cloud/discoveryengine/v1/acl_config_pb.rb +25 -0
- data/lib/google/cloud/discoveryengine/v1/acl_config_service_pb.rb +28 -0
- data/lib/google/cloud/discoveryengine/v1/acl_config_service_services_pb.rb +49 -0
- data/lib/google/cloud/discoveryengine/v1/agent_gateway_setting_pb.rb +25 -0
- data/lib/google/cloud/discoveryengine/v1/assist_answer_pb.rb +13 -1
- data/lib/google/cloud/discoveryengine/v1/assistant_pb.rb +13 -1
- data/lib/google/cloud/discoveryengine/v1/assistant_service_pb.rb +12 -1
- data/lib/google/cloud/discoveryengine/v1/assistant_service_services_pb.rb +12 -1
- data/lib/google/cloud/discoveryengine/v1/chunk_pb.rb +1 -1
- data/lib/google/cloud/discoveryengine/v1/cmek_config_service_pb.rb +1 -1
- data/lib/google/cloud/discoveryengine/v1/cmek_config_service_services_pb.rb +1 -1
- data/lib/google/cloud/discoveryengine/v1/collection_pb.rb +25 -0
- data/lib/google/cloud/discoveryengine/v1/collection_service_pb.rb +32 -0
- data/lib/google/cloud/discoveryengine/v1/collection_service_services_pb.rb +65 -0
- data/lib/google/cloud/discoveryengine/v1/common_pb.rb +13 -1
- data/lib/google/cloud/discoveryengine/v1/completion_service_pb.rb +16 -1
- data/lib/google/cloud/discoveryengine/v1/completion_service_services_pb.rb +3 -1
- data/lib/google/cloud/discoveryengine/v1/control_service_pb.rb +1 -1
- data/lib/google/cloud/discoveryengine/v1/control_service_services_pb.rb +1 -1
- data/lib/google/cloud/discoveryengine/v1/conversational_search_service_pb.rb +1 -1
- data/lib/google/cloud/discoveryengine/v1/conversational_search_service_services_pb.rb +1 -1
- data/lib/google/cloud/discoveryengine/v1/data_connector_pb.rb +57 -0
- data/lib/google/cloud/discoveryengine/v1/data_connector_service_pb.rb +32 -0
- data/lib/google/cloud/discoveryengine/v1/data_connector_service_services_pb.rb +58 -0
- data/lib/google/cloud/discoveryengine/v1/data_store_pb.rb +10 -1
- data/lib/google/cloud/discoveryengine/v1/data_store_service_pb.rb +3 -1
- data/lib/google/cloud/discoveryengine/v1/data_store_service_services_pb.rb +20 -1
- data/lib/google/cloud/discoveryengine/v1/document_processing_config_pb.rb +1 -1
- data/lib/google/cloud/discoveryengine/v1/document_service_pb.rb +1 -1
- data/lib/google/cloud/discoveryengine/v1/document_service_services_pb.rb +1 -1
- data/lib/google/cloud/discoveryengine/v1/engine_pb.rb +11 -1
- data/lib/google/cloud/discoveryengine/v1/engine_service_pb.rb +3 -1
- data/lib/google/cloud/discoveryengine/v1/engine_service_services_pb.rb +23 -4
- data/lib/google/cloud/discoveryengine/v1/feedback_pb.rb +28 -0
- data/lib/google/cloud/discoveryengine/v1/grounded_generation_service_pb.rb +7 -1
- data/lib/google/cloud/discoveryengine/v1/grounded_generation_service_services_pb.rb +1 -1
- data/lib/google/cloud/discoveryengine/v1/identity_mapping_store_pb.rb +1 -1
- data/lib/google/cloud/discoveryengine/v1/identity_mapping_store_service_pb.rb +1 -1
- data/lib/google/cloud/discoveryengine/v1/identity_mapping_store_service_services_pb.rb +1 -1
- data/lib/google/cloud/discoveryengine/v1/import_config_pb.rb +1 -1
- data/lib/google/cloud/discoveryengine/v1/license_config_pb.rb +28 -0
- data/lib/google/cloud/discoveryengine/v1/license_config_service_pb.rb +36 -0
- data/lib/google/cloud/discoveryengine/v1/license_config_service_services_pb.rb +63 -0
- data/lib/google/cloud/discoveryengine/v1/logging_pb.rb +24 -0
- data/lib/google/cloud/discoveryengine/v1/project_pb.rb +11 -1
- data/lib/google/cloud/discoveryengine/v1/project_service_pb.rb +2 -1
- data/lib/google/cloud/discoveryengine/v1/project_service_services_pb.rb +1 -1
- data/lib/google/cloud/discoveryengine/v1/rank_service_pb.rb +1 -1
- data/lib/google/cloud/discoveryengine/v1/rank_service_services_pb.rb +1 -1
- data/lib/google/cloud/discoveryengine/v1/recommendation_service_pb.rb +1 -1
- data/lib/google/cloud/discoveryengine/v1/recommendation_service_services_pb.rb +1 -1
- data/lib/google/cloud/discoveryengine/v1/schema_service_pb.rb +1 -1
- data/lib/google/cloud/discoveryengine/v1/schema_service_services_pb.rb +1 -1
- data/lib/google/cloud/discoveryengine/v1/search_tuning_service_pb.rb +1 -1
- data/lib/google/cloud/discoveryengine/v1/search_tuning_service_services_pb.rb +1 -1
- data/lib/google/cloud/discoveryengine/v1/serving_config_pb.rb +3 -1
- data/lib/google/cloud/discoveryengine/v1/serving_config_service_pb.rb +7 -1
- data/lib/google/cloud/discoveryengine/v1/serving_config_service_services_pb.rb +21 -1
- data/lib/google/cloud/discoveryengine/v1/session_pb.rb +1 -1
- data/lib/google/cloud/discoveryengine/v1/session_service_pb.rb +1 -1
- data/lib/google/cloud/discoveryengine/v1/session_service_services_pb.rb +1 -1
- data/lib/google/cloud/discoveryengine/v1/site_search_engine_service_pb.rb +1 -1
- data/lib/google/cloud/discoveryengine/v1/site_search_engine_service_services_pb.rb +1 -1
- data/lib/google/cloud/discoveryengine/v1/user_event_pb.rb +2 -1
- data/lib/google/cloud/discoveryengine/v1/user_event_service_pb.rb +1 -1
- data/lib/google/cloud/discoveryengine/v1/user_event_service_services_pb.rb +1 -1
- data/lib/google/cloud/discoveryengine/v1/user_license_pb.rb +2 -1
- data/lib/google/cloud/discoveryengine/v1/user_license_service_pb.rb +3 -1
- data/lib/google/cloud/discoveryengine/v1/user_license_service_services_pb.rb +5 -1
- data/lib/google/cloud/discoveryengine/v1/user_store_pb.rb +24 -0
- data/lib/google/cloud/discoveryengine/v1/user_store_service_pb.rb +29 -0
- data/lib/google/cloud/discoveryengine/v1/user_store_service_services_pb.rb +47 -0
- data/lib/google/cloud/discoveryengine/v1/widget_config_pb.rb +63 -0
- data/lib/google/cloud/discoveryengine/v1/widget_config_service_pb.rb +30 -0
- data/lib/google/cloud/discoveryengine/v1/widget_config_service_services_pb.rb +48 -0
- data/proto_docs/google/cloud/discoveryengine/v1/acl_config.rb +43 -0
- data/proto_docs/google/cloud/discoveryengine/v1/acl_config_service.rb +49 -0
- data/proto_docs/google/cloud/discoveryengine/v1/agent_gateway_setting.rb +53 -0
- data/proto_docs/google/cloud/discoveryengine/v1/assist_answer.rb +164 -1
- data/proto_docs/google/cloud/discoveryengine/v1/assistant.rb +217 -0
- data/proto_docs/google/cloud/discoveryengine/v1/assistant_service.rb +179 -6
- data/proto_docs/google/cloud/discoveryengine/v1/chunk.rb +4 -0
- data/proto_docs/google/cloud/discoveryengine/v1/cmek_config_service.rb +7 -2
- data/proto_docs/google/cloud/discoveryengine/v1/collection.rb +51 -0
- data/proto_docs/google/cloud/discoveryengine/v1/collection_service.rb +53 -0
- data/proto_docs/google/cloud/discoveryengine/v1/common.rb +201 -0
- data/proto_docs/google/cloud/discoveryengine/v1/completion_service.rb +320 -4
- data/proto_docs/google/cloud/discoveryengine/v1/conversational_search_service.rb +31 -8
- data/proto_docs/google/cloud/discoveryengine/v1/data_connector.rb +875 -0
- data/proto_docs/google/cloud/discoveryengine/v1/data_connector_service.rb +142 -0
- data/proto_docs/google/cloud/discoveryengine/v1/data_store.rb +179 -2
- data/proto_docs/google/cloud/discoveryengine/v1/document.rb +9 -4
- data/proto_docs/google/cloud/discoveryengine/v1/document_processing_config.rb +7 -0
- data/proto_docs/google/cloud/discoveryengine/v1/engine.rb +251 -1
- data/proto_docs/google/cloud/discoveryengine/v1/feedback.rb +165 -0
- data/proto_docs/google/cloud/discoveryengine/v1/grounded_generation_service.rb +107 -0
- data/proto_docs/google/cloud/discoveryengine/v1/identity_mapping_store.rb +3 -0
- data/proto_docs/google/cloud/discoveryengine/v1/identity_mapping_store_service.rb +1 -0
- data/proto_docs/google/cloud/discoveryengine/v1/import_config.rb +6 -4
- data/proto_docs/google/cloud/discoveryengine/v1/license_config.rb +107 -0
- data/proto_docs/google/cloud/discoveryengine/v1/license_config_service.rb +220 -0
- data/proto_docs/google/cloud/discoveryengine/v1/logging.rb +40 -0
- data/proto_docs/google/cloud/discoveryengine/v1/project.rb +229 -0
- data/proto_docs/google/cloud/discoveryengine/v1/project_service.rb +18 -0
- data/proto_docs/google/cloud/discoveryengine/v1/purge_config.rb +2 -1
- data/proto_docs/google/cloud/discoveryengine/v1/rank_service.rb +3 -3
- data/proto_docs/google/cloud/discoveryengine/v1/search_service.rb +7 -1
- data/proto_docs/google/cloud/discoveryengine/v1/serving_config.rb +43 -0
- data/proto_docs/google/cloud/discoveryengine/v1/serving_config_service.rb +71 -0
- data/proto_docs/google/cloud/discoveryengine/v1/session.rb +9 -0
- data/proto_docs/google/cloud/discoveryengine/v1/user_event.rb +16 -6
- data/proto_docs/google/cloud/discoveryengine/v1/user_license.rb +16 -1
- data/proto_docs/google/cloud/discoveryengine/v1/user_license_service.rb +53 -6
- data/proto_docs/google/cloud/discoveryengine/v1/user_store.rb +66 -0
- data/proto_docs/google/cloud/discoveryengine/v1/user_store_service.rb +54 -0
- data/proto_docs/google/cloud/discoveryengine/v1/widget_config.rb +1082 -0
- data/proto_docs/google/cloud/discoveryengine/v1/widget_config_service.rb +102 -0
- data/proto_docs/google/iam/v1/iam_policy.rb +87 -0
- data/proto_docs/google/iam/v1/options.rb +50 -0
- data/proto_docs/google/iam/v1/policy.rb +426 -0
- data/proto_docs/google/type/date.rb +1 -1
- data/proto_docs/google/type/datetime.rb +104 -0
- data/proto_docs/google/type/expr.rb +75 -0
- data/proto_docs/google/type/latlng.rb +38 -0
- metadata +103 -1
|
@@ -47,6 +47,49 @@ module Google
|
|
|
47
47
|
"projects/#{project}/locations/#{location}/collections/#{collection}/engines/#{engine}/assistants/#{assistant}"
|
|
48
48
|
end
|
|
49
49
|
|
|
50
|
+
##
|
|
51
|
+
# Create a fully-qualified ContentPolicy resource string.
|
|
52
|
+
#
|
|
53
|
+
# @overload content_policy_path(organization:, location:, content_policy:)
|
|
54
|
+
# The resource will be in the following format:
|
|
55
|
+
#
|
|
56
|
+
# `organizations/{organization}/locations/{location}/contentPolicies/{content_policy}`
|
|
57
|
+
#
|
|
58
|
+
# @param organization [String]
|
|
59
|
+
# @param location [String]
|
|
60
|
+
# @param content_policy [String]
|
|
61
|
+
#
|
|
62
|
+
# @overload content_policy_path(project:, location:, content_policy:)
|
|
63
|
+
# The resource will be in the following format:
|
|
64
|
+
#
|
|
65
|
+
# `projects/{project}/locations/{location}/contentPolicies/{content_policy}`
|
|
66
|
+
#
|
|
67
|
+
# @param project [String]
|
|
68
|
+
# @param location [String]
|
|
69
|
+
# @param content_policy [String]
|
|
70
|
+
#
|
|
71
|
+
# @return [::String]
|
|
72
|
+
def content_policy_path **args
|
|
73
|
+
resources = {
|
|
74
|
+
"content_policy:location:organization" => (proc do |organization:, location:, content_policy:|
|
|
75
|
+
raise ::ArgumentError, "organization cannot contain /" if organization.to_s.include? "/"
|
|
76
|
+
raise ::ArgumentError, "location cannot contain /" if location.to_s.include? "/"
|
|
77
|
+
|
|
78
|
+
"organizations/#{organization}/locations/#{location}/contentPolicies/#{content_policy}"
|
|
79
|
+
end),
|
|
80
|
+
"content_policy:location:project" => (proc do |project:, location:, content_policy:|
|
|
81
|
+
raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/"
|
|
82
|
+
raise ::ArgumentError, "location cannot contain /" if location.to_s.include? "/"
|
|
83
|
+
|
|
84
|
+
"projects/#{project}/locations/#{location}/contentPolicies/#{content_policy}"
|
|
85
|
+
end)
|
|
86
|
+
}
|
|
87
|
+
|
|
88
|
+
resource = resources[args.keys.sort.join(":")]
|
|
89
|
+
raise ::ArgumentError, "no resource found for values #{args.keys}" if resource.nil?
|
|
90
|
+
resource.call(**args)
|
|
91
|
+
end
|
|
92
|
+
|
|
50
93
|
##
|
|
51
94
|
# Create a fully-qualified DataStore resource string.
|
|
52
95
|
#
|
|
@@ -92,6 +135,27 @@ module Google
|
|
|
92
135
|
resource.call(**args)
|
|
93
136
|
end
|
|
94
137
|
|
|
138
|
+
##
|
|
139
|
+
# Create a fully-qualified Engine resource string.
|
|
140
|
+
#
|
|
141
|
+
# The resource will be in the following format:
|
|
142
|
+
#
|
|
143
|
+
# `projects/{project}/locations/{location}/collections/{collection}/engines/{engine}`
|
|
144
|
+
#
|
|
145
|
+
# @param project [String]
|
|
146
|
+
# @param location [String]
|
|
147
|
+
# @param collection [String]
|
|
148
|
+
# @param engine [String]
|
|
149
|
+
#
|
|
150
|
+
# @return [::String]
|
|
151
|
+
def engine_path project:, location:, collection:, engine:
|
|
152
|
+
raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/"
|
|
153
|
+
raise ::ArgumentError, "location cannot contain /" if location.to_s.include? "/"
|
|
154
|
+
raise ::ArgumentError, "collection cannot contain /" if collection.to_s.include? "/"
|
|
155
|
+
|
|
156
|
+
"projects/#{project}/locations/#{location}/collections/#{collection}/engines/#{engine}"
|
|
157
|
+
end
|
|
158
|
+
|
|
95
159
|
##
|
|
96
160
|
# Create a fully-qualified Session resource string.
|
|
97
161
|
#
|
|
@@ -127,6 +191,18 @@ module Google
|
|
|
127
191
|
# @param engine [String]
|
|
128
192
|
# @param session [String]
|
|
129
193
|
#
|
|
194
|
+
# @overload session_path(project:, location:, collection:, engine:, collaborative_project:, session:)
|
|
195
|
+
# The resource will be in the following format:
|
|
196
|
+
#
|
|
197
|
+
# `projects/{project}/locations/{location}/collections/{collection}/engines/{engine}/collaborativeProjects/{collaborative_project}/sessions/{session}`
|
|
198
|
+
#
|
|
199
|
+
# @param project [String]
|
|
200
|
+
# @param location [String]
|
|
201
|
+
# @param collection [String]
|
|
202
|
+
# @param engine [String]
|
|
203
|
+
# @param collaborative_project [String]
|
|
204
|
+
# @param session [String]
|
|
205
|
+
#
|
|
130
206
|
# @return [::String]
|
|
131
207
|
def session_path **args
|
|
132
208
|
resources = {
|
|
@@ -152,6 +228,15 @@ module Google
|
|
|
152
228
|
raise ::ArgumentError, "engine cannot contain /" if engine.to_s.include? "/"
|
|
153
229
|
|
|
154
230
|
"projects/#{project}/locations/#{location}/collections/#{collection}/engines/#{engine}/sessions/#{session}"
|
|
231
|
+
end),
|
|
232
|
+
"collaborative_project:collection:engine:location:project:session" => (proc do |project:, location:, collection:, engine:, collaborative_project:, session:|
|
|
233
|
+
raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/"
|
|
234
|
+
raise ::ArgumentError, "location cannot contain /" if location.to_s.include? "/"
|
|
235
|
+
raise ::ArgumentError, "collection cannot contain /" if collection.to_s.include? "/"
|
|
236
|
+
raise ::ArgumentError, "engine cannot contain /" if engine.to_s.include? "/"
|
|
237
|
+
raise ::ArgumentError, "collaborative_project cannot contain /" if collaborative_project.to_s.include? "/"
|
|
238
|
+
|
|
239
|
+
"projects/#{project}/locations/#{location}/collections/#{collection}/engines/#{engine}/collaborativeProjects/#{collaborative_project}/sessions/#{session}"
|
|
155
240
|
end)
|
|
156
241
|
}
|
|
157
242
|
|
|
@@ -160,6 +245,25 @@ module Google
|
|
|
160
245
|
resource.call(**args)
|
|
161
246
|
end
|
|
162
247
|
|
|
248
|
+
##
|
|
249
|
+
# Create a fully-qualified Template resource string.
|
|
250
|
+
#
|
|
251
|
+
# The resource will be in the following format:
|
|
252
|
+
#
|
|
253
|
+
# `projects/{project}/locations/{location}/templates/{template}`
|
|
254
|
+
#
|
|
255
|
+
# @param project [String]
|
|
256
|
+
# @param location [String]
|
|
257
|
+
# @param template [String]
|
|
258
|
+
#
|
|
259
|
+
# @return [::String]
|
|
260
|
+
def template_path project:, location:, template:
|
|
261
|
+
raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/"
|
|
262
|
+
raise ::ArgumentError, "location cannot contain /" if location.to_s.include? "/"
|
|
263
|
+
|
|
264
|
+
"projects/#{project}/locations/#{location}/templates/#{template}"
|
|
265
|
+
end
|
|
266
|
+
|
|
163
267
|
extend self
|
|
164
268
|
end
|
|
165
269
|
end
|
|
@@ -83,6 +83,12 @@ module Google
|
|
|
83
83
|
initial_delay: 1.0, max_delay: 30.0, multiplier: 1.3, retry_codes: [14]
|
|
84
84
|
}
|
|
85
85
|
|
|
86
|
+
default_config.rpcs.create_assistant.timeout = 30.0
|
|
87
|
+
|
|
88
|
+
default_config.rpcs.delete_assistant.timeout = 30.0
|
|
89
|
+
|
|
90
|
+
default_config.rpcs.update_assistant.timeout = 30.0
|
|
91
|
+
|
|
86
92
|
default_config
|
|
87
93
|
end
|
|
88
94
|
yield @configure if block_given?
|
|
@@ -310,6 +316,458 @@ module Google
|
|
|
310
316
|
raise ::Google::Cloud::Error.from_error(e)
|
|
311
317
|
end
|
|
312
318
|
|
|
319
|
+
##
|
|
320
|
+
# Creates an {::Google::Cloud::DiscoveryEngine::V1::Assistant Assistant}.
|
|
321
|
+
#
|
|
322
|
+
# @overload create_assistant(request, options = nil)
|
|
323
|
+
# Pass arguments to `create_assistant` via a request object, either of type
|
|
324
|
+
# {::Google::Cloud::DiscoveryEngine::V1::CreateAssistantRequest} or an equivalent Hash.
|
|
325
|
+
#
|
|
326
|
+
# @param request [::Google::Cloud::DiscoveryEngine::V1::CreateAssistantRequest, ::Hash]
|
|
327
|
+
# A request object representing the call parameters. Required. To specify no
|
|
328
|
+
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
|
329
|
+
# @param options [::Gapic::CallOptions, ::Hash]
|
|
330
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
|
331
|
+
#
|
|
332
|
+
# @overload create_assistant(parent: nil, assistant: nil, assistant_id: nil)
|
|
333
|
+
# Pass arguments to `create_assistant` via keyword arguments. Note that at
|
|
334
|
+
# least one keyword argument is required. To specify no parameters, or to keep all
|
|
335
|
+
# the default parameter values, pass an empty Hash as a request object (see above).
|
|
336
|
+
#
|
|
337
|
+
# @param parent [::String]
|
|
338
|
+
# Required. The parent resource name.
|
|
339
|
+
# Format:
|
|
340
|
+
# `projects/{project}/locations/{location}/collections/{collection}/engines/{engine}`
|
|
341
|
+
# @param assistant [::Google::Cloud::DiscoveryEngine::V1::Assistant, ::Hash]
|
|
342
|
+
# Required. The {::Google::Cloud::DiscoveryEngine::V1::Assistant Assistant} to
|
|
343
|
+
# create.
|
|
344
|
+
# @param assistant_id [::String]
|
|
345
|
+
# Required. The ID to use for the
|
|
346
|
+
# {::Google::Cloud::DiscoveryEngine::V1::Assistant Assistant}, which will become
|
|
347
|
+
# the final component of the
|
|
348
|
+
# {::Google::Cloud::DiscoveryEngine::V1::Assistant Assistant}'s resource name.
|
|
349
|
+
#
|
|
350
|
+
# This field must conform to [RFC-1034](https://tools.ietf.org/html/rfc1034)
|
|
351
|
+
# with a length limit of 63 characters.
|
|
352
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
|
353
|
+
# @yieldparam result [::Google::Cloud::DiscoveryEngine::V1::Assistant]
|
|
354
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
|
355
|
+
#
|
|
356
|
+
# @return [::Google::Cloud::DiscoveryEngine::V1::Assistant]
|
|
357
|
+
#
|
|
358
|
+
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
|
359
|
+
#
|
|
360
|
+
# @example Basic example
|
|
361
|
+
# require "google/cloud/discovery_engine/v1"
|
|
362
|
+
#
|
|
363
|
+
# # Create a client object. The client can be reused for multiple calls.
|
|
364
|
+
# client = Google::Cloud::DiscoveryEngine::V1::AssistantService::Rest::Client.new
|
|
365
|
+
#
|
|
366
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
|
367
|
+
# request = Google::Cloud::DiscoveryEngine::V1::CreateAssistantRequest.new
|
|
368
|
+
#
|
|
369
|
+
# # Call the create_assistant method.
|
|
370
|
+
# result = client.create_assistant request
|
|
371
|
+
#
|
|
372
|
+
# # The returned object is of type Google::Cloud::DiscoveryEngine::V1::Assistant.
|
|
373
|
+
# p result
|
|
374
|
+
#
|
|
375
|
+
def create_assistant request, options = nil
|
|
376
|
+
raise ::ArgumentError, "request must be provided" if request.nil?
|
|
377
|
+
|
|
378
|
+
request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::DiscoveryEngine::V1::CreateAssistantRequest
|
|
379
|
+
|
|
380
|
+
# Converts hash and nil to an options object
|
|
381
|
+
options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
|
382
|
+
|
|
383
|
+
# Customize the options with defaults
|
|
384
|
+
call_metadata = @config.rpcs.create_assistant.metadata.to_h
|
|
385
|
+
|
|
386
|
+
# Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
|
|
387
|
+
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
|
388
|
+
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
|
389
|
+
gapic_version: ::Google::Cloud::DiscoveryEngine::V1::VERSION,
|
|
390
|
+
transports_version_send: [:rest]
|
|
391
|
+
|
|
392
|
+
call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
|
|
393
|
+
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
|
394
|
+
|
|
395
|
+
options.apply_defaults timeout: @config.rpcs.create_assistant.timeout,
|
|
396
|
+
metadata: call_metadata,
|
|
397
|
+
retry_policy: @config.rpcs.create_assistant.retry_policy
|
|
398
|
+
|
|
399
|
+
options.apply_defaults timeout: @config.timeout,
|
|
400
|
+
metadata: @config.metadata,
|
|
401
|
+
retry_policy: @config.retry_policy
|
|
402
|
+
|
|
403
|
+
@assistant_service_stub.create_assistant request, options do |result, operation|
|
|
404
|
+
yield result, operation if block_given?
|
|
405
|
+
end
|
|
406
|
+
rescue ::Gapic::Rest::Error => e
|
|
407
|
+
raise ::Google::Cloud::Error.from_error(e)
|
|
408
|
+
end
|
|
409
|
+
|
|
410
|
+
##
|
|
411
|
+
# Deletes an {::Google::Cloud::DiscoveryEngine::V1::Assistant Assistant}.
|
|
412
|
+
#
|
|
413
|
+
# @overload delete_assistant(request, options = nil)
|
|
414
|
+
# Pass arguments to `delete_assistant` via a request object, either of type
|
|
415
|
+
# {::Google::Cloud::DiscoveryEngine::V1::DeleteAssistantRequest} or an equivalent Hash.
|
|
416
|
+
#
|
|
417
|
+
# @param request [::Google::Cloud::DiscoveryEngine::V1::DeleteAssistantRequest, ::Hash]
|
|
418
|
+
# A request object representing the call parameters. Required. To specify no
|
|
419
|
+
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
|
420
|
+
# @param options [::Gapic::CallOptions, ::Hash]
|
|
421
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
|
422
|
+
#
|
|
423
|
+
# @overload delete_assistant(name: nil)
|
|
424
|
+
# Pass arguments to `delete_assistant` via keyword arguments. Note that at
|
|
425
|
+
# least one keyword argument is required. To specify no parameters, or to keep all
|
|
426
|
+
# the default parameter values, pass an empty Hash as a request object (see above).
|
|
427
|
+
#
|
|
428
|
+
# @param name [::String]
|
|
429
|
+
# Required. Resource name of
|
|
430
|
+
# {::Google::Cloud::DiscoveryEngine::V1::Assistant Assistant}. Format:
|
|
431
|
+
# `projects/{project}/locations/{location}/collections/{collection}/engines/{engine}/assistants/{assistant}`
|
|
432
|
+
#
|
|
433
|
+
# If the caller does not have permission to delete the
|
|
434
|
+
# {::Google::Cloud::DiscoveryEngine::V1::Assistant Assistant}, regardless of
|
|
435
|
+
# whether or not it exists, a PERMISSION_DENIED error is returned.
|
|
436
|
+
#
|
|
437
|
+
# If the {::Google::Cloud::DiscoveryEngine::V1::Assistant Assistant} to delete
|
|
438
|
+
# does not exist, a NOT_FOUND error is returned.
|
|
439
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
|
440
|
+
# @yieldparam result [::Google::Protobuf::Empty]
|
|
441
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
|
442
|
+
#
|
|
443
|
+
# @return [::Google::Protobuf::Empty]
|
|
444
|
+
#
|
|
445
|
+
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
|
446
|
+
#
|
|
447
|
+
# @example Basic example
|
|
448
|
+
# require "google/cloud/discovery_engine/v1"
|
|
449
|
+
#
|
|
450
|
+
# # Create a client object. The client can be reused for multiple calls.
|
|
451
|
+
# client = Google::Cloud::DiscoveryEngine::V1::AssistantService::Rest::Client.new
|
|
452
|
+
#
|
|
453
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
|
454
|
+
# request = Google::Cloud::DiscoveryEngine::V1::DeleteAssistantRequest.new
|
|
455
|
+
#
|
|
456
|
+
# # Call the delete_assistant method.
|
|
457
|
+
# result = client.delete_assistant request
|
|
458
|
+
#
|
|
459
|
+
# # The returned object is of type Google::Protobuf::Empty.
|
|
460
|
+
# p result
|
|
461
|
+
#
|
|
462
|
+
def delete_assistant request, options = nil
|
|
463
|
+
raise ::ArgumentError, "request must be provided" if request.nil?
|
|
464
|
+
|
|
465
|
+
request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::DiscoveryEngine::V1::DeleteAssistantRequest
|
|
466
|
+
|
|
467
|
+
# Converts hash and nil to an options object
|
|
468
|
+
options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
|
469
|
+
|
|
470
|
+
# Customize the options with defaults
|
|
471
|
+
call_metadata = @config.rpcs.delete_assistant.metadata.to_h
|
|
472
|
+
|
|
473
|
+
# Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
|
|
474
|
+
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
|
475
|
+
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
|
476
|
+
gapic_version: ::Google::Cloud::DiscoveryEngine::V1::VERSION,
|
|
477
|
+
transports_version_send: [:rest]
|
|
478
|
+
|
|
479
|
+
call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
|
|
480
|
+
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
|
481
|
+
|
|
482
|
+
options.apply_defaults timeout: @config.rpcs.delete_assistant.timeout,
|
|
483
|
+
metadata: call_metadata,
|
|
484
|
+
retry_policy: @config.rpcs.delete_assistant.retry_policy
|
|
485
|
+
|
|
486
|
+
options.apply_defaults timeout: @config.timeout,
|
|
487
|
+
metadata: @config.metadata,
|
|
488
|
+
retry_policy: @config.retry_policy
|
|
489
|
+
|
|
490
|
+
@assistant_service_stub.delete_assistant request, options do |result, operation|
|
|
491
|
+
yield result, operation if block_given?
|
|
492
|
+
end
|
|
493
|
+
rescue ::Gapic::Rest::Error => e
|
|
494
|
+
raise ::Google::Cloud::Error.from_error(e)
|
|
495
|
+
end
|
|
496
|
+
|
|
497
|
+
##
|
|
498
|
+
# Updates an {::Google::Cloud::DiscoveryEngine::V1::Assistant Assistant}
|
|
499
|
+
#
|
|
500
|
+
# @overload update_assistant(request, options = nil)
|
|
501
|
+
# Pass arguments to `update_assistant` via a request object, either of type
|
|
502
|
+
# {::Google::Cloud::DiscoveryEngine::V1::UpdateAssistantRequest} or an equivalent Hash.
|
|
503
|
+
#
|
|
504
|
+
# @param request [::Google::Cloud::DiscoveryEngine::V1::UpdateAssistantRequest, ::Hash]
|
|
505
|
+
# A request object representing the call parameters. Required. To specify no
|
|
506
|
+
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
|
507
|
+
# @param options [::Gapic::CallOptions, ::Hash]
|
|
508
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
|
509
|
+
#
|
|
510
|
+
# @overload update_assistant(assistant: nil, update_mask: nil)
|
|
511
|
+
# Pass arguments to `update_assistant` via keyword arguments. Note that at
|
|
512
|
+
# least one keyword argument is required. To specify no parameters, or to keep all
|
|
513
|
+
# the default parameter values, pass an empty Hash as a request object (see above).
|
|
514
|
+
#
|
|
515
|
+
# @param assistant [::Google::Cloud::DiscoveryEngine::V1::Assistant, ::Hash]
|
|
516
|
+
# Required. The {::Google::Cloud::DiscoveryEngine::V1::Assistant Assistant} to
|
|
517
|
+
# update.
|
|
518
|
+
#
|
|
519
|
+
# The {::Google::Cloud::DiscoveryEngine::V1::Assistant Assistant}'s `name` field
|
|
520
|
+
# is used to identify the
|
|
521
|
+
# {::Google::Cloud::DiscoveryEngine::V1::Assistant Assistant} to update. Format:
|
|
522
|
+
# `projects/{project}/locations/{location}/collections/{collection}/engines/{engine}/assistants/{assistant}`
|
|
523
|
+
#
|
|
524
|
+
# If the caller does not have permission to update the
|
|
525
|
+
# {::Google::Cloud::DiscoveryEngine::V1::Assistant Assistant}, regardless of
|
|
526
|
+
# whether or not it exists, a PERMISSION_DENIED error is returned.
|
|
527
|
+
#
|
|
528
|
+
# If the {::Google::Cloud::DiscoveryEngine::V1::Assistant Assistant} to update
|
|
529
|
+
# does not exist, a NOT_FOUND error is returned.
|
|
530
|
+
# @param update_mask [::Google::Protobuf::FieldMask, ::Hash]
|
|
531
|
+
# The list of fields to update.
|
|
532
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
|
533
|
+
# @yieldparam result [::Google::Cloud::DiscoveryEngine::V1::Assistant]
|
|
534
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
|
535
|
+
#
|
|
536
|
+
# @return [::Google::Cloud::DiscoveryEngine::V1::Assistant]
|
|
537
|
+
#
|
|
538
|
+
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
|
539
|
+
#
|
|
540
|
+
# @example Basic example
|
|
541
|
+
# require "google/cloud/discovery_engine/v1"
|
|
542
|
+
#
|
|
543
|
+
# # Create a client object. The client can be reused for multiple calls.
|
|
544
|
+
# client = Google::Cloud::DiscoveryEngine::V1::AssistantService::Rest::Client.new
|
|
545
|
+
#
|
|
546
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
|
547
|
+
# request = Google::Cloud::DiscoveryEngine::V1::UpdateAssistantRequest.new
|
|
548
|
+
#
|
|
549
|
+
# # Call the update_assistant method.
|
|
550
|
+
# result = client.update_assistant request
|
|
551
|
+
#
|
|
552
|
+
# # The returned object is of type Google::Cloud::DiscoveryEngine::V1::Assistant.
|
|
553
|
+
# p result
|
|
554
|
+
#
|
|
555
|
+
def update_assistant request, options = nil
|
|
556
|
+
raise ::ArgumentError, "request must be provided" if request.nil?
|
|
557
|
+
|
|
558
|
+
request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::DiscoveryEngine::V1::UpdateAssistantRequest
|
|
559
|
+
|
|
560
|
+
# Converts hash and nil to an options object
|
|
561
|
+
options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
|
562
|
+
|
|
563
|
+
# Customize the options with defaults
|
|
564
|
+
call_metadata = @config.rpcs.update_assistant.metadata.to_h
|
|
565
|
+
|
|
566
|
+
# Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
|
|
567
|
+
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
|
568
|
+
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
|
569
|
+
gapic_version: ::Google::Cloud::DiscoveryEngine::V1::VERSION,
|
|
570
|
+
transports_version_send: [:rest]
|
|
571
|
+
|
|
572
|
+
call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
|
|
573
|
+
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
|
574
|
+
|
|
575
|
+
options.apply_defaults timeout: @config.rpcs.update_assistant.timeout,
|
|
576
|
+
metadata: call_metadata,
|
|
577
|
+
retry_policy: @config.rpcs.update_assistant.retry_policy
|
|
578
|
+
|
|
579
|
+
options.apply_defaults timeout: @config.timeout,
|
|
580
|
+
metadata: @config.metadata,
|
|
581
|
+
retry_policy: @config.retry_policy
|
|
582
|
+
|
|
583
|
+
@assistant_service_stub.update_assistant request, options do |result, operation|
|
|
584
|
+
yield result, operation if block_given?
|
|
585
|
+
end
|
|
586
|
+
rescue ::Gapic::Rest::Error => e
|
|
587
|
+
raise ::Google::Cloud::Error.from_error(e)
|
|
588
|
+
end
|
|
589
|
+
|
|
590
|
+
##
|
|
591
|
+
# Gets an {::Google::Cloud::DiscoveryEngine::V1::Assistant Assistant}.
|
|
592
|
+
#
|
|
593
|
+
# @overload get_assistant(request, options = nil)
|
|
594
|
+
# Pass arguments to `get_assistant` via a request object, either of type
|
|
595
|
+
# {::Google::Cloud::DiscoveryEngine::V1::GetAssistantRequest} or an equivalent Hash.
|
|
596
|
+
#
|
|
597
|
+
# @param request [::Google::Cloud::DiscoveryEngine::V1::GetAssistantRequest, ::Hash]
|
|
598
|
+
# A request object representing the call parameters. Required. To specify no
|
|
599
|
+
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
|
600
|
+
# @param options [::Gapic::CallOptions, ::Hash]
|
|
601
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
|
602
|
+
#
|
|
603
|
+
# @overload get_assistant(name: nil)
|
|
604
|
+
# Pass arguments to `get_assistant` via keyword arguments. Note that at
|
|
605
|
+
# least one keyword argument is required. To specify no parameters, or to keep all
|
|
606
|
+
# the default parameter values, pass an empty Hash as a request object (see above).
|
|
607
|
+
#
|
|
608
|
+
# @param name [::String]
|
|
609
|
+
# Required. Resource name of
|
|
610
|
+
# {::Google::Cloud::DiscoveryEngine::V1::Assistant Assistant}. Format:
|
|
611
|
+
# `projects/{project}/locations/{location}/collections/{collection}/engines/{engine}/assistants/{assistant}`
|
|
612
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
|
613
|
+
# @yieldparam result [::Google::Cloud::DiscoveryEngine::V1::Assistant]
|
|
614
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
|
615
|
+
#
|
|
616
|
+
# @return [::Google::Cloud::DiscoveryEngine::V1::Assistant]
|
|
617
|
+
#
|
|
618
|
+
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
|
619
|
+
#
|
|
620
|
+
# @example Basic example
|
|
621
|
+
# require "google/cloud/discovery_engine/v1"
|
|
622
|
+
#
|
|
623
|
+
# # Create a client object. The client can be reused for multiple calls.
|
|
624
|
+
# client = Google::Cloud::DiscoveryEngine::V1::AssistantService::Rest::Client.new
|
|
625
|
+
#
|
|
626
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
|
627
|
+
# request = Google::Cloud::DiscoveryEngine::V1::GetAssistantRequest.new
|
|
628
|
+
#
|
|
629
|
+
# # Call the get_assistant method.
|
|
630
|
+
# result = client.get_assistant request
|
|
631
|
+
#
|
|
632
|
+
# # The returned object is of type Google::Cloud::DiscoveryEngine::V1::Assistant.
|
|
633
|
+
# p result
|
|
634
|
+
#
|
|
635
|
+
def get_assistant request, options = nil
|
|
636
|
+
raise ::ArgumentError, "request must be provided" if request.nil?
|
|
637
|
+
|
|
638
|
+
request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::DiscoveryEngine::V1::GetAssistantRequest
|
|
639
|
+
|
|
640
|
+
# Converts hash and nil to an options object
|
|
641
|
+
options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
|
642
|
+
|
|
643
|
+
# Customize the options with defaults
|
|
644
|
+
call_metadata = @config.rpcs.get_assistant.metadata.to_h
|
|
645
|
+
|
|
646
|
+
# Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
|
|
647
|
+
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
|
648
|
+
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
|
649
|
+
gapic_version: ::Google::Cloud::DiscoveryEngine::V1::VERSION,
|
|
650
|
+
transports_version_send: [:rest]
|
|
651
|
+
|
|
652
|
+
call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
|
|
653
|
+
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
|
654
|
+
|
|
655
|
+
options.apply_defaults timeout: @config.rpcs.get_assistant.timeout,
|
|
656
|
+
metadata: call_metadata,
|
|
657
|
+
retry_policy: @config.rpcs.get_assistant.retry_policy
|
|
658
|
+
|
|
659
|
+
options.apply_defaults timeout: @config.timeout,
|
|
660
|
+
metadata: @config.metadata,
|
|
661
|
+
retry_policy: @config.retry_policy
|
|
662
|
+
|
|
663
|
+
@assistant_service_stub.get_assistant request, options do |result, operation|
|
|
664
|
+
yield result, operation if block_given?
|
|
665
|
+
end
|
|
666
|
+
rescue ::Gapic::Rest::Error => e
|
|
667
|
+
raise ::Google::Cloud::Error.from_error(e)
|
|
668
|
+
end
|
|
669
|
+
|
|
670
|
+
##
|
|
671
|
+
# Lists all {::Google::Cloud::DiscoveryEngine::V1::Assistant Assistant}s under an
|
|
672
|
+
# {::Google::Cloud::DiscoveryEngine::V1::Engine Engine}.
|
|
673
|
+
#
|
|
674
|
+
# @overload list_assistants(request, options = nil)
|
|
675
|
+
# Pass arguments to `list_assistants` via a request object, either of type
|
|
676
|
+
# {::Google::Cloud::DiscoveryEngine::V1::ListAssistantsRequest} or an equivalent Hash.
|
|
677
|
+
#
|
|
678
|
+
# @param request [::Google::Cloud::DiscoveryEngine::V1::ListAssistantsRequest, ::Hash]
|
|
679
|
+
# A request object representing the call parameters. Required. To specify no
|
|
680
|
+
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
|
681
|
+
# @param options [::Gapic::CallOptions, ::Hash]
|
|
682
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
|
683
|
+
#
|
|
684
|
+
# @overload list_assistants(parent: nil, page_size: nil, page_token: nil)
|
|
685
|
+
# Pass arguments to `list_assistants` via keyword arguments. Note that at
|
|
686
|
+
# least one keyword argument is required. To specify no parameters, or to keep all
|
|
687
|
+
# the default parameter values, pass an empty Hash as a request object (see above).
|
|
688
|
+
#
|
|
689
|
+
# @param parent [::String]
|
|
690
|
+
# Required. The parent resource name.
|
|
691
|
+
# Format:
|
|
692
|
+
# `projects/{project}/locations/{location}/collections/{collection}/engines/{engine}`
|
|
693
|
+
# @param page_size [::Integer]
|
|
694
|
+
# Maximum number of {::Google::Cloud::DiscoveryEngine::V1::Assistant Assistant}s
|
|
695
|
+
# to return. If unspecified, defaults to 100. The maximum allowed value is
|
|
696
|
+
# 1000; anything above that will be coerced down to 1000.
|
|
697
|
+
# @param page_token [::String]
|
|
698
|
+
# A page token
|
|
699
|
+
# {::Google::Cloud::DiscoveryEngine::V1::ListAssistantsResponse#next_page_token ListAssistantsResponse.next_page_token},
|
|
700
|
+
# received from a previous
|
|
701
|
+
# {::Google::Cloud::DiscoveryEngine::V1::AssistantService::Rest::Client#list_assistants AssistantService.ListAssistants}
|
|
702
|
+
# call. Provide this to retrieve the subsequent page.
|
|
703
|
+
#
|
|
704
|
+
# When paginating, all other parameters provided to
|
|
705
|
+
# {::Google::Cloud::DiscoveryEngine::V1::AssistantService::Rest::Client#list_assistants ListAssistants}
|
|
706
|
+
# must match the call that provided the page token.
|
|
707
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
|
708
|
+
# @yieldparam result [::Gapic::Rest::PagedEnumerable<::Google::Cloud::DiscoveryEngine::V1::Assistant>]
|
|
709
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
|
710
|
+
#
|
|
711
|
+
# @return [::Gapic::Rest::PagedEnumerable<::Google::Cloud::DiscoveryEngine::V1::Assistant>]
|
|
712
|
+
#
|
|
713
|
+
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
|
714
|
+
#
|
|
715
|
+
# @example Basic example
|
|
716
|
+
# require "google/cloud/discovery_engine/v1"
|
|
717
|
+
#
|
|
718
|
+
# # Create a client object. The client can be reused for multiple calls.
|
|
719
|
+
# client = Google::Cloud::DiscoveryEngine::V1::AssistantService::Rest::Client.new
|
|
720
|
+
#
|
|
721
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
|
722
|
+
# request = Google::Cloud::DiscoveryEngine::V1::ListAssistantsRequest.new
|
|
723
|
+
#
|
|
724
|
+
# # Call the list_assistants method.
|
|
725
|
+
# result = client.list_assistants request
|
|
726
|
+
#
|
|
727
|
+
# # The returned object is of type Gapic::PagedEnumerable. You can iterate
|
|
728
|
+
# # over elements, and API calls will be issued to fetch pages as needed.
|
|
729
|
+
# result.each do |item|
|
|
730
|
+
# # Each element is of type ::Google::Cloud::DiscoveryEngine::V1::Assistant.
|
|
731
|
+
# p item
|
|
732
|
+
# end
|
|
733
|
+
#
|
|
734
|
+
def list_assistants request, options = nil
|
|
735
|
+
raise ::ArgumentError, "request must be provided" if request.nil?
|
|
736
|
+
|
|
737
|
+
request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::DiscoveryEngine::V1::ListAssistantsRequest
|
|
738
|
+
|
|
739
|
+
# Converts hash and nil to an options object
|
|
740
|
+
options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
|
741
|
+
|
|
742
|
+
# Customize the options with defaults
|
|
743
|
+
call_metadata = @config.rpcs.list_assistants.metadata.to_h
|
|
744
|
+
|
|
745
|
+
# Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
|
|
746
|
+
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
|
747
|
+
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
|
748
|
+
gapic_version: ::Google::Cloud::DiscoveryEngine::V1::VERSION,
|
|
749
|
+
transports_version_send: [:rest]
|
|
750
|
+
|
|
751
|
+
call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
|
|
752
|
+
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
|
753
|
+
|
|
754
|
+
options.apply_defaults timeout: @config.rpcs.list_assistants.timeout,
|
|
755
|
+
metadata: call_metadata,
|
|
756
|
+
retry_policy: @config.rpcs.list_assistants.retry_policy
|
|
757
|
+
|
|
758
|
+
options.apply_defaults timeout: @config.timeout,
|
|
759
|
+
metadata: @config.metadata,
|
|
760
|
+
retry_policy: @config.retry_policy
|
|
761
|
+
|
|
762
|
+
@assistant_service_stub.list_assistants request, options do |result, operation|
|
|
763
|
+
result = ::Gapic::Rest::PagedEnumerable.new @assistant_service_stub, :list_assistants, "assistants", request, result, options
|
|
764
|
+
yield result, operation if block_given?
|
|
765
|
+
throw :response, result
|
|
766
|
+
end
|
|
767
|
+
rescue ::Gapic::Rest::Error => e
|
|
768
|
+
raise ::Google::Cloud::Error.from_error(e)
|
|
769
|
+
end
|
|
770
|
+
|
|
313
771
|
##
|
|
314
772
|
# Configuration class for the AssistantService REST API.
|
|
315
773
|
#
|
|
@@ -463,11 +921,46 @@ module Google
|
|
|
463
921
|
# @return [::Gapic::Config::Method]
|
|
464
922
|
#
|
|
465
923
|
attr_reader :stream_assist
|
|
924
|
+
##
|
|
925
|
+
# RPC-specific configuration for `create_assistant`
|
|
926
|
+
# @return [::Gapic::Config::Method]
|
|
927
|
+
#
|
|
928
|
+
attr_reader :create_assistant
|
|
929
|
+
##
|
|
930
|
+
# RPC-specific configuration for `delete_assistant`
|
|
931
|
+
# @return [::Gapic::Config::Method]
|
|
932
|
+
#
|
|
933
|
+
attr_reader :delete_assistant
|
|
934
|
+
##
|
|
935
|
+
# RPC-specific configuration for `update_assistant`
|
|
936
|
+
# @return [::Gapic::Config::Method]
|
|
937
|
+
#
|
|
938
|
+
attr_reader :update_assistant
|
|
939
|
+
##
|
|
940
|
+
# RPC-specific configuration for `get_assistant`
|
|
941
|
+
# @return [::Gapic::Config::Method]
|
|
942
|
+
#
|
|
943
|
+
attr_reader :get_assistant
|
|
944
|
+
##
|
|
945
|
+
# RPC-specific configuration for `list_assistants`
|
|
946
|
+
# @return [::Gapic::Config::Method]
|
|
947
|
+
#
|
|
948
|
+
attr_reader :list_assistants
|
|
466
949
|
|
|
467
950
|
# @private
|
|
468
951
|
def initialize parent_rpcs = nil
|
|
469
952
|
stream_assist_config = parent_rpcs.stream_assist if parent_rpcs.respond_to? :stream_assist
|
|
470
953
|
@stream_assist = ::Gapic::Config::Method.new stream_assist_config
|
|
954
|
+
create_assistant_config = parent_rpcs.create_assistant if parent_rpcs.respond_to? :create_assistant
|
|
955
|
+
@create_assistant = ::Gapic::Config::Method.new create_assistant_config
|
|
956
|
+
delete_assistant_config = parent_rpcs.delete_assistant if parent_rpcs.respond_to? :delete_assistant
|
|
957
|
+
@delete_assistant = ::Gapic::Config::Method.new delete_assistant_config
|
|
958
|
+
update_assistant_config = parent_rpcs.update_assistant if parent_rpcs.respond_to? :update_assistant
|
|
959
|
+
@update_assistant = ::Gapic::Config::Method.new update_assistant_config
|
|
960
|
+
get_assistant_config = parent_rpcs.get_assistant if parent_rpcs.respond_to? :get_assistant
|
|
961
|
+
@get_assistant = ::Gapic::Config::Method.new get_assistant_config
|
|
962
|
+
list_assistants_config = parent_rpcs.list_assistants if parent_rpcs.respond_to? :list_assistants
|
|
963
|
+
@list_assistants = ::Gapic::Config::Method.new list_assistants_config
|
|
471
964
|
|
|
472
965
|
yield self if block_given?
|
|
473
966
|
end
|