google-cloud-dialogflow-cx-v3 0.1.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/.yardopts +12 -0
- data/AUTHENTICATION.md +169 -0
- data/LICENSE.md +201 -0
- data/README.md +139 -0
- data/lib/google/cloud/dialogflow/cx/v3/advanced_settings_pb.rb +32 -0
- data/lib/google/cloud/dialogflow/cx/v3/agent_pb.rb +122 -0
- data/lib/google/cloud/dialogflow/cx/v3/agent_services_pb.rb +82 -0
- data/lib/google/cloud/dialogflow/cx/v3/agents/client.rb +1051 -0
- data/lib/google/cloud/dialogflow/cx/v3/agents/credentials.rb +54 -0
- data/lib/google/cloud/dialogflow/cx/v3/agents/operations.rb +666 -0
- data/lib/google/cloud/dialogflow/cx/v3/agents/paths.rb +151 -0
- data/lib/google/cloud/dialogflow/cx/v3/agents.rb +52 -0
- data/lib/google/cloud/dialogflow/cx/v3/audio_config_pb.rb +94 -0
- data/lib/google/cloud/dialogflow/cx/v3/entity_type_pb.rb +92 -0
- data/lib/google/cloud/dialogflow/cx/v3/entity_type_services_pb.rb +67 -0
- data/lib/google/cloud/dialogflow/cx/v3/entity_types/client.rb +766 -0
- data/lib/google/cloud/dialogflow/cx/v3/entity_types/credentials.rb +54 -0
- data/lib/google/cloud/dialogflow/cx/v3/entity_types/paths.rb +75 -0
- data/lib/google/cloud/dialogflow/cx/v3/entity_types.rb +51 -0
- data/lib/google/cloud/dialogflow/cx/v3/environment_pb.rb +117 -0
- data/lib/google/cloud/dialogflow/cx/v3/environment_services_pb.rb +61 -0
- data/lib/google/cloud/dialogflow/cx/v3/environments/client.rb +950 -0
- data/lib/google/cloud/dialogflow/cx/v3/environments/credentials.rb +54 -0
- data/lib/google/cloud/dialogflow/cx/v3/environments/operations.rb +666 -0
- data/lib/google/cloud/dialogflow/cx/v3/environments/paths.rb +98 -0
- data/lib/google/cloud/dialogflow/cx/v3/environments.rb +52 -0
- data/lib/google/cloud/dialogflow/cx/v3/experiment_pb.rb +177 -0
- data/lib/google/cloud/dialogflow/cx/v3/experiment_services_pb.rb +61 -0
- data/lib/google/cloud/dialogflow/cx/v3/experiments/client.rb +851 -0
- data/lib/google/cloud/dialogflow/cx/v3/experiments/credentials.rb +54 -0
- data/lib/google/cloud/dialogflow/cx/v3/experiments/paths.rb +102 -0
- data/lib/google/cloud/dialogflow/cx/v3/experiments.rb +51 -0
- data/lib/google/cloud/dialogflow/cx/v3/flow_pb.rb +145 -0
- data/lib/google/cloud/dialogflow/cx/v3/flow_services_pb.rb +88 -0
- data/lib/google/cloud/dialogflow/cx/v3/flows/client.rb +1200 -0
- data/lib/google/cloud/dialogflow/cx/v3/flows/credentials.rb +54 -0
- data/lib/google/cloud/dialogflow/cx/v3/flows/operations.rb +666 -0
- data/lib/google/cloud/dialogflow/cx/v3/flows/paths.rb +184 -0
- data/lib/google/cloud/dialogflow/cx/v3/flows.rb +52 -0
- data/lib/google/cloud/dialogflow/cx/v3/fulfillment_pb.rb +55 -0
- data/lib/google/cloud/dialogflow/cx/v3/intent_pb.rb +97 -0
- data/lib/google/cloud/dialogflow/cx/v3/intent_services_pb.rb +67 -0
- data/lib/google/cloud/dialogflow/cx/v3/intents/client.rb +750 -0
- data/lib/google/cloud/dialogflow/cx/v3/intents/credentials.rb +54 -0
- data/lib/google/cloud/dialogflow/cx/v3/intents/paths.rb +96 -0
- data/lib/google/cloud/dialogflow/cx/v3/intents.rb +51 -0
- data/lib/google/cloud/dialogflow/cx/v3/page_pb.rb +113 -0
- data/lib/google/cloud/dialogflow/cx/v3/page_services_pb.rb +67 -0
- data/lib/google/cloud/dialogflow/cx/v3/pages/client.rb +805 -0
- data/lib/google/cloud/dialogflow/cx/v3/pages/credentials.rb +54 -0
- data/lib/google/cloud/dialogflow/cx/v3/pages/paths.rb +165 -0
- data/lib/google/cloud/dialogflow/cx/v3/pages.rb +51 -0
- data/lib/google/cloud/dialogflow/cx/v3/response_message_pb.rb +77 -0
- data/lib/google/cloud/dialogflow/cx/v3/security_settings_pb.rb +89 -0
- data/lib/google/cloud/dialogflow/cx/v3/security_settings_service/client.rb +696 -0
- data/lib/google/cloud/dialogflow/cx/v3/security_settings_service/credentials.rb +54 -0
- data/lib/google/cloud/dialogflow/cx/v3/security_settings_service/paths.rb +157 -0
- data/lib/google/cloud/dialogflow/cx/v3/security_settings_service.rb +51 -0
- data/lib/google/cloud/dialogflow/cx/v3/security_settings_services_pb.rb +56 -0
- data/lib/google/cloud/dialogflow/cx/v3/session_entity_type_pb.rb +68 -0
- data/lib/google/cloud/dialogflow/cx/v3/session_entity_type_services_pb.rb +55 -0
- data/lib/google/cloud/dialogflow/cx/v3/session_entity_types/client.rb +715 -0
- data/lib/google/cloud/dialogflow/cx/v3/session_entity_types/credentials.rb +54 -0
- data/lib/google/cloud/dialogflow/cx/v3/session_entity_types/paths.rb +137 -0
- data/lib/google/cloud/dialogflow/cx/v3/session_entity_types.rb +51 -0
- data/lib/google/cloud/dialogflow/cx/v3/session_pb.rb +209 -0
- data/lib/google/cloud/dialogflow/cx/v3/session_services_pb.rb +71 -0
- data/lib/google/cloud/dialogflow/cx/v3/sessions/client.rb +654 -0
- data/lib/google/cloud/dialogflow/cx/v3/sessions/credentials.rb +54 -0
- data/lib/google/cloud/dialogflow/cx/v3/sessions/paths.rb +225 -0
- data/lib/google/cloud/dialogflow/cx/v3/sessions.rb +53 -0
- data/lib/google/cloud/dialogflow/cx/v3/test_case_pb.rb +302 -0
- data/lib/google/cloud/dialogflow/cx/v3/test_case_services_pb.rb +73 -0
- data/lib/google/cloud/dialogflow/cx/v3/test_cases/client.rb +1324 -0
- data/lib/google/cloud/dialogflow/cx/v3/test_cases/credentials.rb +54 -0
- data/lib/google/cloud/dialogflow/cx/v3/test_cases/operations.rb +666 -0
- data/lib/google/cloud/dialogflow/cx/v3/test_cases/paths.rb +249 -0
- data/lib/google/cloud/dialogflow/cx/v3/test_cases.rb +53 -0
- data/lib/google/cloud/dialogflow/cx/v3/transition_route_group_pb.rb +67 -0
- data/lib/google/cloud/dialogflow/cx/v3/transition_route_group_services_pb.rb +67 -0
- data/lib/google/cloud/dialogflow/cx/v3/transition_route_groups/client.rb +766 -0
- data/lib/google/cloud/dialogflow/cx/v3/transition_route_groups/credentials.rb +54 -0
- data/lib/google/cloud/dialogflow/cx/v3/transition_route_groups/paths.rb +144 -0
- data/lib/google/cloud/dialogflow/cx/v3/transition_route_groups.rb +51 -0
- data/lib/google/cloud/dialogflow/cx/v3/validation_message_pb.rb +59 -0
- data/lib/google/cloud/dialogflow/cx/v3/version.rb +30 -0
- data/lib/google/cloud/dialogflow/cx/v3/version_pb.rb +88 -0
- data/lib/google/cloud/dialogflow/cx/v3/version_services_pb.rb +57 -0
- data/lib/google/cloud/dialogflow/cx/v3/versions/client.rb +792 -0
- data/lib/google/cloud/dialogflow/cx/v3/versions/credentials.rb +54 -0
- data/lib/google/cloud/dialogflow/cx/v3/versions/operations.rb +666 -0
- data/lib/google/cloud/dialogflow/cx/v3/versions/paths.rb +79 -0
- data/lib/google/cloud/dialogflow/cx/v3/versions.rb +52 -0
- data/lib/google/cloud/dialogflow/cx/v3/webhook_pb.rb +172 -0
- data/lib/google/cloud/dialogflow/cx/v3/webhook_services_pb.rb +55 -0
- data/lib/google/cloud/dialogflow/cx/v3/webhooks/client.rb +704 -0
- data/lib/google/cloud/dialogflow/cx/v3/webhooks/credentials.rb +54 -0
- data/lib/google/cloud/dialogflow/cx/v3/webhooks/paths.rb +96 -0
- data/lib/google/cloud/dialogflow/cx/v3/webhooks.rb +51 -0
- data/lib/google/cloud/dialogflow/cx/v3.rb +53 -0
- data/lib/google-cloud-dialogflow-cx-v3.rb +21 -0
- data/proto_docs/README.md +4 -0
- data/proto_docs/google/api/field_behavior.rb +71 -0
- data/proto_docs/google/api/resource.rb +283 -0
- data/proto_docs/google/cloud/dialogflow/cx/v3/advanced_settings.rb +57 -0
- data/proto_docs/google/cloud/dialogflow/cx/v3/agent.rb +301 -0
- data/proto_docs/google/cloud/dialogflow/cx/v3/audio_config.rb +322 -0
- data/proto_docs/google/cloud/dialogflow/cx/v3/entity_type.rb +306 -0
- data/proto_docs/google/cloud/dialogflow/cx/v3/environment.rb +279 -0
- data/proto_docs/google/cloud/dialogflow/cx/v3/experiment.rb +438 -0
- data/proto_docs/google/cloud/dialogflow/cx/v3/flow.rb +438 -0
- data/proto_docs/google/cloud/dialogflow/cx/v3/fulfillment.rb +126 -0
- data/proto_docs/google/cloud/dialogflow/cx/v3/intent.rb +318 -0
- data/proto_docs/google/cloud/dialogflow/cx/v3/page.rb +478 -0
- data/proto_docs/google/cloud/dialogflow/cx/v3/response_message.rb +220 -0
- data/proto_docs/google/cloud/dialogflow/cx/v3/security_settings.rb +222 -0
- data/proto_docs/google/cloud/dialogflow/cx/v3/session.rb +798 -0
- data/proto_docs/google/cloud/dialogflow/cx/v3/session_entity_type.rb +184 -0
- data/proto_docs/google/cloud/dialogflow/cx/v3/test_case.rb +757 -0
- data/proto_docs/google/cloud/dialogflow/cx/v3/transition_route_group.rb +195 -0
- data/proto_docs/google/cloud/dialogflow/cx/v3/validation_message.rb +121 -0
- data/proto_docs/google/cloud/dialogflow/cx/v3/version.rb +182 -0
- data/proto_docs/google/cloud/dialogflow/cx/v3/webhook.rb +496 -0
- data/proto_docs/google/longrunning/operations.rb +164 -0
- data/proto_docs/google/protobuf/any.rb +141 -0
- data/proto_docs/google/protobuf/duration.rb +98 -0
- data/proto_docs/google/protobuf/empty.rb +36 -0
- data/proto_docs/google/protobuf/field_mask.rb +229 -0
- data/proto_docs/google/protobuf/struct.rb +96 -0
- data/proto_docs/google/protobuf/timestamp.rb +129 -0
- data/proto_docs/google/rpc/status.rb +46 -0
- data/proto_docs/google/type/latlng.rb +38 -0
- metadata +326 -0
@@ -0,0 +1,54 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
# Copyright 2021 Google LLC
|
4
|
+
#
|
5
|
+
# Licensed under the Apache License, Version 2.0 (the "License");
|
6
|
+
# you may not use this file except in compliance with the License.
|
7
|
+
# You may obtain a copy of the License at
|
8
|
+
#
|
9
|
+
# https://www.apache.org/licenses/LICENSE-2.0
|
10
|
+
#
|
11
|
+
# Unless required by applicable law or agreed to in writing, software
|
12
|
+
# distributed under the License is distributed on an "AS IS" BASIS,
|
13
|
+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
14
|
+
# See the License for the specific language governing permissions and
|
15
|
+
# limitations under the License.
|
16
|
+
|
17
|
+
# Auto-generated by gapic-generator-ruby. DO NOT EDIT!
|
18
|
+
|
19
|
+
require "googleauth"
|
20
|
+
|
21
|
+
module Google
|
22
|
+
module Cloud
|
23
|
+
module Dialogflow
|
24
|
+
module CX
|
25
|
+
module V3
|
26
|
+
module Pages
|
27
|
+
# Credentials for the Pages API.
|
28
|
+
class Credentials < ::Google::Auth::Credentials
|
29
|
+
self.scope = [
|
30
|
+
"https://www.googleapis.com/auth/cloud-platform",
|
31
|
+
"https://www.googleapis.com/auth/dialogflow"
|
32
|
+
]
|
33
|
+
self.env_vars = [
|
34
|
+
"DIALOGFLOW_CREDENTIALS",
|
35
|
+
"DIALOGFLOW_KEYFILE",
|
36
|
+
"GOOGLE_CLOUD_CREDENTIALS",
|
37
|
+
"GOOGLE_CLOUD_KEYFILE",
|
38
|
+
"GCLOUD_KEYFILE",
|
39
|
+
"DIALOGFLOW_CREDENTIALS_JSON",
|
40
|
+
"DIALOGFLOW_KEYFILE_JSON",
|
41
|
+
"GOOGLE_CLOUD_CREDENTIALS_JSON",
|
42
|
+
"GOOGLE_CLOUD_KEYFILE_JSON",
|
43
|
+
"GCLOUD_KEYFILE_JSON"
|
44
|
+
]
|
45
|
+
self.paths = [
|
46
|
+
"~/.config/google_cloud/application_default_credentials.json"
|
47
|
+
]
|
48
|
+
end
|
49
|
+
end
|
50
|
+
end
|
51
|
+
end
|
52
|
+
end
|
53
|
+
end
|
54
|
+
end
|
@@ -0,0 +1,165 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
# Copyright 2021 Google LLC
|
4
|
+
#
|
5
|
+
# Licensed under the Apache License, Version 2.0 (the "License");
|
6
|
+
# you may not use this file except in compliance with the License.
|
7
|
+
# You may obtain a copy of the License at
|
8
|
+
#
|
9
|
+
# https://www.apache.org/licenses/LICENSE-2.0
|
10
|
+
#
|
11
|
+
# Unless required by applicable law or agreed to in writing, software
|
12
|
+
# distributed under the License is distributed on an "AS IS" BASIS,
|
13
|
+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
14
|
+
# See the License for the specific language governing permissions and
|
15
|
+
# limitations under the License.
|
16
|
+
|
17
|
+
# Auto-generated by gapic-generator-ruby. DO NOT EDIT!
|
18
|
+
|
19
|
+
|
20
|
+
module Google
|
21
|
+
module Cloud
|
22
|
+
module Dialogflow
|
23
|
+
module CX
|
24
|
+
module V3
|
25
|
+
module Pages
|
26
|
+
# Path helper methods for the Pages API.
|
27
|
+
module Paths
|
28
|
+
##
|
29
|
+
# Create a fully-qualified EntityType resource string.
|
30
|
+
#
|
31
|
+
# The resource will be in the following format:
|
32
|
+
#
|
33
|
+
# `projects/{project}/locations/{location}/agents/{agent}/entityTypes/{entity_type}`
|
34
|
+
#
|
35
|
+
# @param project [String]
|
36
|
+
# @param location [String]
|
37
|
+
# @param agent [String]
|
38
|
+
# @param entity_type [String]
|
39
|
+
#
|
40
|
+
# @return [::String]
|
41
|
+
def entity_type_path project:, location:, agent:, entity_type:
|
42
|
+
raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/"
|
43
|
+
raise ::ArgumentError, "location cannot contain /" if location.to_s.include? "/"
|
44
|
+
raise ::ArgumentError, "agent cannot contain /" if agent.to_s.include? "/"
|
45
|
+
|
46
|
+
"projects/#{project}/locations/#{location}/agents/#{agent}/entityTypes/#{entity_type}"
|
47
|
+
end
|
48
|
+
|
49
|
+
##
|
50
|
+
# Create a fully-qualified Flow resource string.
|
51
|
+
#
|
52
|
+
# The resource will be in the following format:
|
53
|
+
#
|
54
|
+
# `projects/{project}/locations/{location}/agents/{agent}/flows/{flow}`
|
55
|
+
#
|
56
|
+
# @param project [String]
|
57
|
+
# @param location [String]
|
58
|
+
# @param agent [String]
|
59
|
+
# @param flow [String]
|
60
|
+
#
|
61
|
+
# @return [::String]
|
62
|
+
def flow_path project:, location:, agent:, flow:
|
63
|
+
raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/"
|
64
|
+
raise ::ArgumentError, "location cannot contain /" if location.to_s.include? "/"
|
65
|
+
raise ::ArgumentError, "agent cannot contain /" if agent.to_s.include? "/"
|
66
|
+
|
67
|
+
"projects/#{project}/locations/#{location}/agents/#{agent}/flows/#{flow}"
|
68
|
+
end
|
69
|
+
|
70
|
+
##
|
71
|
+
# Create a fully-qualified Intent resource string.
|
72
|
+
#
|
73
|
+
# The resource will be in the following format:
|
74
|
+
#
|
75
|
+
# `projects/{project}/locations/{location}/agents/{agent}/intents/{intent}`
|
76
|
+
#
|
77
|
+
# @param project [String]
|
78
|
+
# @param location [String]
|
79
|
+
# @param agent [String]
|
80
|
+
# @param intent [String]
|
81
|
+
#
|
82
|
+
# @return [::String]
|
83
|
+
def intent_path project:, location:, agent:, intent:
|
84
|
+
raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/"
|
85
|
+
raise ::ArgumentError, "location cannot contain /" if location.to_s.include? "/"
|
86
|
+
raise ::ArgumentError, "agent cannot contain /" if agent.to_s.include? "/"
|
87
|
+
|
88
|
+
"projects/#{project}/locations/#{location}/agents/#{agent}/intents/#{intent}"
|
89
|
+
end
|
90
|
+
|
91
|
+
##
|
92
|
+
# Create a fully-qualified Page resource string.
|
93
|
+
#
|
94
|
+
# The resource will be in the following format:
|
95
|
+
#
|
96
|
+
# `projects/{project}/locations/{location}/agents/{agent}/flows/{flow}/pages/{page}`
|
97
|
+
#
|
98
|
+
# @param project [String]
|
99
|
+
# @param location [String]
|
100
|
+
# @param agent [String]
|
101
|
+
# @param flow [String]
|
102
|
+
# @param page [String]
|
103
|
+
#
|
104
|
+
# @return [::String]
|
105
|
+
def page_path project:, location:, agent:, flow:, page:
|
106
|
+
raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/"
|
107
|
+
raise ::ArgumentError, "location cannot contain /" if location.to_s.include? "/"
|
108
|
+
raise ::ArgumentError, "agent cannot contain /" if agent.to_s.include? "/"
|
109
|
+
raise ::ArgumentError, "flow cannot contain /" if flow.to_s.include? "/"
|
110
|
+
|
111
|
+
"projects/#{project}/locations/#{location}/agents/#{agent}/flows/#{flow}/pages/#{page}"
|
112
|
+
end
|
113
|
+
|
114
|
+
##
|
115
|
+
# Create a fully-qualified TransitionRouteGroup resource string.
|
116
|
+
#
|
117
|
+
# The resource will be in the following format:
|
118
|
+
#
|
119
|
+
# `projects/{project}/locations/{location}/agents/{agent}/flows/{flow}/transitionRouteGroups/{transition_route_group}`
|
120
|
+
#
|
121
|
+
# @param project [String]
|
122
|
+
# @param location [String]
|
123
|
+
# @param agent [String]
|
124
|
+
# @param flow [String]
|
125
|
+
# @param transition_route_group [String]
|
126
|
+
#
|
127
|
+
# @return [::String]
|
128
|
+
def transition_route_group_path project:, location:, agent:, flow:, transition_route_group:
|
129
|
+
raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/"
|
130
|
+
raise ::ArgumentError, "location cannot contain /" if location.to_s.include? "/"
|
131
|
+
raise ::ArgumentError, "agent cannot contain /" if agent.to_s.include? "/"
|
132
|
+
raise ::ArgumentError, "flow cannot contain /" if flow.to_s.include? "/"
|
133
|
+
|
134
|
+
"projects/#{project}/locations/#{location}/agents/#{agent}/flows/#{flow}/transitionRouteGroups/#{transition_route_group}"
|
135
|
+
end
|
136
|
+
|
137
|
+
##
|
138
|
+
# Create a fully-qualified Webhook resource string.
|
139
|
+
#
|
140
|
+
# The resource will be in the following format:
|
141
|
+
#
|
142
|
+
# `projects/{project}/locations/{location}/agents/{agent}/webhooks/{webhook}`
|
143
|
+
#
|
144
|
+
# @param project [String]
|
145
|
+
# @param location [String]
|
146
|
+
# @param agent [String]
|
147
|
+
# @param webhook [String]
|
148
|
+
#
|
149
|
+
# @return [::String]
|
150
|
+
def webhook_path project:, location:, agent:, webhook:
|
151
|
+
raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/"
|
152
|
+
raise ::ArgumentError, "location cannot contain /" if location.to_s.include? "/"
|
153
|
+
raise ::ArgumentError, "agent cannot contain /" if agent.to_s.include? "/"
|
154
|
+
|
155
|
+
"projects/#{project}/locations/#{location}/agents/#{agent}/webhooks/#{webhook}"
|
156
|
+
end
|
157
|
+
|
158
|
+
extend self
|
159
|
+
end
|
160
|
+
end
|
161
|
+
end
|
162
|
+
end
|
163
|
+
end
|
164
|
+
end
|
165
|
+
end
|
@@ -0,0 +1,51 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
# Copyright 2021 Google LLC
|
4
|
+
#
|
5
|
+
# Licensed under the Apache License, Version 2.0 (the "License");
|
6
|
+
# you may not use this file except in compliance with the License.
|
7
|
+
# You may obtain a copy of the License at
|
8
|
+
#
|
9
|
+
# https://www.apache.org/licenses/LICENSE-2.0
|
10
|
+
#
|
11
|
+
# Unless required by applicable law or agreed to in writing, software
|
12
|
+
# distributed under the License is distributed on an "AS IS" BASIS,
|
13
|
+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
14
|
+
# See the License for the specific language governing permissions and
|
15
|
+
# limitations under the License.
|
16
|
+
|
17
|
+
# Auto-generated by gapic-generator-ruby. DO NOT EDIT!
|
18
|
+
|
19
|
+
require "gapic/common"
|
20
|
+
require "gapic/config"
|
21
|
+
require "gapic/config/method"
|
22
|
+
|
23
|
+
require "google/cloud/dialogflow/cx/v3/version"
|
24
|
+
|
25
|
+
require "google/cloud/dialogflow/cx/v3/pages/credentials"
|
26
|
+
require "google/cloud/dialogflow/cx/v3/pages/paths"
|
27
|
+
require "google/cloud/dialogflow/cx/v3/pages/client"
|
28
|
+
|
29
|
+
module Google
|
30
|
+
module Cloud
|
31
|
+
module Dialogflow
|
32
|
+
module CX
|
33
|
+
module V3
|
34
|
+
##
|
35
|
+
# Service for managing {::Google::Cloud::Dialogflow::CX::V3::Page Pages}.
|
36
|
+
#
|
37
|
+
# To load this service and instantiate a client:
|
38
|
+
#
|
39
|
+
# require "google/cloud/dialogflow/cx/v3/pages"
|
40
|
+
# client = ::Google::Cloud::Dialogflow::CX::V3::Pages::Client.new
|
41
|
+
#
|
42
|
+
module Pages
|
43
|
+
end
|
44
|
+
end
|
45
|
+
end
|
46
|
+
end
|
47
|
+
end
|
48
|
+
end
|
49
|
+
|
50
|
+
helper_path = ::File.join __dir__, "pages", "helpers.rb"
|
51
|
+
require "google/cloud/dialogflow/cx/v3/pages/helpers" if ::File.file? helper_path
|
@@ -0,0 +1,77 @@
|
|
1
|
+
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
2
|
+
# source: google/cloud/dialogflow/cx/v3/response_message.proto
|
3
|
+
|
4
|
+
require 'google/protobuf'
|
5
|
+
|
6
|
+
require 'google/api/field_behavior_pb'
|
7
|
+
require 'google/protobuf/struct_pb'
|
8
|
+
require 'google/api/annotations_pb'
|
9
|
+
Google::Protobuf::DescriptorPool.generated_pool.build do
|
10
|
+
add_file("google/cloud/dialogflow/cx/v3/response_message.proto", :syntax => :proto3) do
|
11
|
+
add_message "google.cloud.dialogflow.cx.v3.ResponseMessage" do
|
12
|
+
oneof :message do
|
13
|
+
optional :text, :message, 1, "google.cloud.dialogflow.cx.v3.ResponseMessage.Text"
|
14
|
+
optional :payload, :message, 2, "google.protobuf.Struct"
|
15
|
+
optional :conversation_success, :message, 9, "google.cloud.dialogflow.cx.v3.ResponseMessage.ConversationSuccess"
|
16
|
+
optional :output_audio_text, :message, 8, "google.cloud.dialogflow.cx.v3.ResponseMessage.OutputAudioText"
|
17
|
+
optional :live_agent_handoff, :message, 10, "google.cloud.dialogflow.cx.v3.ResponseMessage.LiveAgentHandoff"
|
18
|
+
optional :end_interaction, :message, 11, "google.cloud.dialogflow.cx.v3.ResponseMessage.EndInteraction"
|
19
|
+
optional :play_audio, :message, 12, "google.cloud.dialogflow.cx.v3.ResponseMessage.PlayAudio"
|
20
|
+
optional :mixed_audio, :message, 13, "google.cloud.dialogflow.cx.v3.ResponseMessage.MixedAudio"
|
21
|
+
end
|
22
|
+
end
|
23
|
+
add_message "google.cloud.dialogflow.cx.v3.ResponseMessage.Text" do
|
24
|
+
repeated :text, :string, 1
|
25
|
+
optional :allow_playback_interruption, :bool, 2
|
26
|
+
end
|
27
|
+
add_message "google.cloud.dialogflow.cx.v3.ResponseMessage.LiveAgentHandoff" do
|
28
|
+
optional :metadata, :message, 1, "google.protobuf.Struct"
|
29
|
+
end
|
30
|
+
add_message "google.cloud.dialogflow.cx.v3.ResponseMessage.ConversationSuccess" do
|
31
|
+
optional :metadata, :message, 1, "google.protobuf.Struct"
|
32
|
+
end
|
33
|
+
add_message "google.cloud.dialogflow.cx.v3.ResponseMessage.OutputAudioText" do
|
34
|
+
optional :allow_playback_interruption, :bool, 3
|
35
|
+
oneof :source do
|
36
|
+
optional :text, :string, 1
|
37
|
+
optional :ssml, :string, 2
|
38
|
+
end
|
39
|
+
end
|
40
|
+
add_message "google.cloud.dialogflow.cx.v3.ResponseMessage.EndInteraction" do
|
41
|
+
end
|
42
|
+
add_message "google.cloud.dialogflow.cx.v3.ResponseMessage.PlayAudio" do
|
43
|
+
optional :audio_uri, :string, 1
|
44
|
+
optional :allow_playback_interruption, :bool, 2
|
45
|
+
end
|
46
|
+
add_message "google.cloud.dialogflow.cx.v3.ResponseMessage.MixedAudio" do
|
47
|
+
repeated :segments, :message, 1, "google.cloud.dialogflow.cx.v3.ResponseMessage.MixedAudio.Segment"
|
48
|
+
end
|
49
|
+
add_message "google.cloud.dialogflow.cx.v3.ResponseMessage.MixedAudio.Segment" do
|
50
|
+
optional :allow_playback_interruption, :bool, 3
|
51
|
+
oneof :content do
|
52
|
+
optional :audio, :bytes, 1
|
53
|
+
optional :uri, :string, 2
|
54
|
+
end
|
55
|
+
end
|
56
|
+
end
|
57
|
+
end
|
58
|
+
|
59
|
+
module Google
|
60
|
+
module Cloud
|
61
|
+
module Dialogflow
|
62
|
+
module CX
|
63
|
+
module V3
|
64
|
+
ResponseMessage = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.dialogflow.cx.v3.ResponseMessage").msgclass
|
65
|
+
ResponseMessage::Text = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.dialogflow.cx.v3.ResponseMessage.Text").msgclass
|
66
|
+
ResponseMessage::LiveAgentHandoff = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.dialogflow.cx.v3.ResponseMessage.LiveAgentHandoff").msgclass
|
67
|
+
ResponseMessage::ConversationSuccess = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.dialogflow.cx.v3.ResponseMessage.ConversationSuccess").msgclass
|
68
|
+
ResponseMessage::OutputAudioText = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.dialogflow.cx.v3.ResponseMessage.OutputAudioText").msgclass
|
69
|
+
ResponseMessage::EndInteraction = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.dialogflow.cx.v3.ResponseMessage.EndInteraction").msgclass
|
70
|
+
ResponseMessage::PlayAudio = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.dialogflow.cx.v3.ResponseMessage.PlayAudio").msgclass
|
71
|
+
ResponseMessage::MixedAudio = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.dialogflow.cx.v3.ResponseMessage.MixedAudio").msgclass
|
72
|
+
ResponseMessage::MixedAudio::Segment = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.dialogflow.cx.v3.ResponseMessage.MixedAudio.Segment").msgclass
|
73
|
+
end
|
74
|
+
end
|
75
|
+
end
|
76
|
+
end
|
77
|
+
end
|
@@ -0,0 +1,89 @@
|
|
1
|
+
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
2
|
+
# source: google/cloud/dialogflow/cx/v3/security_settings.proto
|
3
|
+
|
4
|
+
require 'google/protobuf'
|
5
|
+
|
6
|
+
require 'google/api/annotations_pb'
|
7
|
+
require 'google/api/client_pb'
|
8
|
+
require 'google/api/field_behavior_pb'
|
9
|
+
require 'google/api/resource_pb'
|
10
|
+
require 'google/longrunning/operations_pb'
|
11
|
+
require 'google/protobuf/empty_pb'
|
12
|
+
require 'google/protobuf/field_mask_pb'
|
13
|
+
Google::Protobuf::DescriptorPool.generated_pool.build do
|
14
|
+
add_file("google/cloud/dialogflow/cx/v3/security_settings.proto", :syntax => :proto3) do
|
15
|
+
add_message "google.cloud.dialogflow.cx.v3.GetSecuritySettingsRequest" do
|
16
|
+
optional :name, :string, 1
|
17
|
+
end
|
18
|
+
add_message "google.cloud.dialogflow.cx.v3.UpdateSecuritySettingsRequest" do
|
19
|
+
optional :security_settings, :message, 1, "google.cloud.dialogflow.cx.v3.SecuritySettings"
|
20
|
+
optional :update_mask, :message, 2, "google.protobuf.FieldMask"
|
21
|
+
end
|
22
|
+
add_message "google.cloud.dialogflow.cx.v3.ListSecuritySettingsRequest" do
|
23
|
+
optional :parent, :string, 1
|
24
|
+
optional :page_size, :int32, 2
|
25
|
+
optional :page_token, :string, 3
|
26
|
+
end
|
27
|
+
add_message "google.cloud.dialogflow.cx.v3.ListSecuritySettingsResponse" do
|
28
|
+
repeated :security_settings, :message, 1, "google.cloud.dialogflow.cx.v3.SecuritySettings"
|
29
|
+
optional :next_page_token, :string, 2
|
30
|
+
end
|
31
|
+
add_message "google.cloud.dialogflow.cx.v3.CreateSecuritySettingsRequest" do
|
32
|
+
optional :parent, :string, 1
|
33
|
+
optional :security_settings, :message, 2, "google.cloud.dialogflow.cx.v3.SecuritySettings"
|
34
|
+
end
|
35
|
+
add_message "google.cloud.dialogflow.cx.v3.DeleteSecuritySettingsRequest" do
|
36
|
+
optional :name, :string, 1
|
37
|
+
end
|
38
|
+
add_message "google.cloud.dialogflow.cx.v3.SecuritySettings" do
|
39
|
+
optional :name, :string, 1
|
40
|
+
optional :display_name, :string, 2
|
41
|
+
optional :redaction_strategy, :enum, 3, "google.cloud.dialogflow.cx.v3.SecuritySettings.RedactionStrategy"
|
42
|
+
optional :redaction_scope, :enum, 4, "google.cloud.dialogflow.cx.v3.SecuritySettings.RedactionScope"
|
43
|
+
optional :inspect_template, :string, 9
|
44
|
+
optional :deidentify_template, :string, 17
|
45
|
+
repeated :purge_data_types, :enum, 8, "google.cloud.dialogflow.cx.v3.SecuritySettings.PurgeDataType"
|
46
|
+
optional :insights_export_settings, :message, 13, "google.cloud.dialogflow.cx.v3.SecuritySettings.InsightsExportSettings"
|
47
|
+
oneof :data_retention do
|
48
|
+
optional :retention_window_days, :int32, 6
|
49
|
+
end
|
50
|
+
end
|
51
|
+
add_message "google.cloud.dialogflow.cx.v3.SecuritySettings.InsightsExportSettings" do
|
52
|
+
optional :enable_insights_export, :bool, 1
|
53
|
+
end
|
54
|
+
add_enum "google.cloud.dialogflow.cx.v3.SecuritySettings.RedactionStrategy" do
|
55
|
+
value :REDACTION_STRATEGY_UNSPECIFIED, 0
|
56
|
+
value :REDACT_WITH_SERVICE, 1
|
57
|
+
end
|
58
|
+
add_enum "google.cloud.dialogflow.cx.v3.SecuritySettings.RedactionScope" do
|
59
|
+
value :REDACTION_SCOPE_UNSPECIFIED, 0
|
60
|
+
value :REDACT_DISK_STORAGE, 2
|
61
|
+
end
|
62
|
+
add_enum "google.cloud.dialogflow.cx.v3.SecuritySettings.PurgeDataType" do
|
63
|
+
value :PURGE_DATA_TYPE_UNSPECIFIED, 0
|
64
|
+
value :DIALOGFLOW_HISTORY, 1
|
65
|
+
end
|
66
|
+
end
|
67
|
+
end
|
68
|
+
|
69
|
+
module Google
|
70
|
+
module Cloud
|
71
|
+
module Dialogflow
|
72
|
+
module CX
|
73
|
+
module V3
|
74
|
+
GetSecuritySettingsRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.dialogflow.cx.v3.GetSecuritySettingsRequest").msgclass
|
75
|
+
UpdateSecuritySettingsRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.dialogflow.cx.v3.UpdateSecuritySettingsRequest").msgclass
|
76
|
+
ListSecuritySettingsRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.dialogflow.cx.v3.ListSecuritySettingsRequest").msgclass
|
77
|
+
ListSecuritySettingsResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.dialogflow.cx.v3.ListSecuritySettingsResponse").msgclass
|
78
|
+
CreateSecuritySettingsRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.dialogflow.cx.v3.CreateSecuritySettingsRequest").msgclass
|
79
|
+
DeleteSecuritySettingsRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.dialogflow.cx.v3.DeleteSecuritySettingsRequest").msgclass
|
80
|
+
SecuritySettings = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.dialogflow.cx.v3.SecuritySettings").msgclass
|
81
|
+
SecuritySettings::InsightsExportSettings = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.dialogflow.cx.v3.SecuritySettings.InsightsExportSettings").msgclass
|
82
|
+
SecuritySettings::RedactionStrategy = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.dialogflow.cx.v3.SecuritySettings.RedactionStrategy").enummodule
|
83
|
+
SecuritySettings::RedactionScope = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.dialogflow.cx.v3.SecuritySettings.RedactionScope").enummodule
|
84
|
+
SecuritySettings::PurgeDataType = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.dialogflow.cx.v3.SecuritySettings.PurgeDataType").enummodule
|
85
|
+
end
|
86
|
+
end
|
87
|
+
end
|
88
|
+
end
|
89
|
+
end
|
@@ -0,0 +1,696 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
# Copyright 2021 Google LLC
|
4
|
+
#
|
5
|
+
# Licensed under the Apache License, Version 2.0 (the "License");
|
6
|
+
# you may not use this file except in compliance with the License.
|
7
|
+
# You may obtain a copy of the License at
|
8
|
+
#
|
9
|
+
# https://www.apache.org/licenses/LICENSE-2.0
|
10
|
+
#
|
11
|
+
# Unless required by applicable law or agreed to in writing, software
|
12
|
+
# distributed under the License is distributed on an "AS IS" BASIS,
|
13
|
+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
14
|
+
# See the License for the specific language governing permissions and
|
15
|
+
# limitations under the License.
|
16
|
+
|
17
|
+
# Auto-generated by gapic-generator-ruby. DO NOT EDIT!
|
18
|
+
|
19
|
+
require "google/cloud/errors"
|
20
|
+
require "google/cloud/dialogflow/cx/v3/security_settings_pb"
|
21
|
+
|
22
|
+
module Google
|
23
|
+
module Cloud
|
24
|
+
module Dialogflow
|
25
|
+
module CX
|
26
|
+
module V3
|
27
|
+
module SecuritySettingsService
|
28
|
+
##
|
29
|
+
# Client for the SecuritySettingsService service.
|
30
|
+
#
|
31
|
+
# Service for managing security settings for Dialogflow.
|
32
|
+
#
|
33
|
+
class Client
|
34
|
+
include Paths
|
35
|
+
|
36
|
+
# @private
|
37
|
+
attr_reader :security_settings_service_stub
|
38
|
+
|
39
|
+
##
|
40
|
+
# Configure the SecuritySettingsService Client class.
|
41
|
+
#
|
42
|
+
# See {::Google::Cloud::Dialogflow::CX::V3::SecuritySettingsService::Client::Configuration}
|
43
|
+
# for a description of the configuration fields.
|
44
|
+
#
|
45
|
+
# @example
|
46
|
+
#
|
47
|
+
# # Modify the configuration for all SecuritySettingsService clients
|
48
|
+
# ::Google::Cloud::Dialogflow::CX::V3::SecuritySettingsService::Client.configure do |config|
|
49
|
+
# config.timeout = 10.0
|
50
|
+
# end
|
51
|
+
#
|
52
|
+
# @yield [config] Configure the Client client.
|
53
|
+
# @yieldparam config [Client::Configuration]
|
54
|
+
#
|
55
|
+
# @return [Client::Configuration]
|
56
|
+
#
|
57
|
+
def self.configure
|
58
|
+
@configure ||= begin
|
59
|
+
namespace = ["Google", "Cloud", "Dialogflow", "CX", "V3"]
|
60
|
+
parent_config = while namespace.any?
|
61
|
+
parent_name = namespace.join "::"
|
62
|
+
parent_const = const_get parent_name
|
63
|
+
break parent_const.configure if parent_const.respond_to? :configure
|
64
|
+
namespace.pop
|
65
|
+
end
|
66
|
+
default_config = Client::Configuration.new parent_config
|
67
|
+
|
68
|
+
default_config.timeout = 60.0
|
69
|
+
default_config.retry_policy = {
|
70
|
+
initial_delay: 0.1, max_delay: 60.0, multiplier: 1.3, retry_codes: [14]
|
71
|
+
}
|
72
|
+
|
73
|
+
default_config
|
74
|
+
end
|
75
|
+
yield @configure if block_given?
|
76
|
+
@configure
|
77
|
+
end
|
78
|
+
|
79
|
+
##
|
80
|
+
# Configure the SecuritySettingsService Client instance.
|
81
|
+
#
|
82
|
+
# The configuration is set to the derived mode, meaning that values can be changed,
|
83
|
+
# but structural changes (adding new fields, etc.) are not allowed. Structural changes
|
84
|
+
# should be made on {Client.configure}.
|
85
|
+
#
|
86
|
+
# See {::Google::Cloud::Dialogflow::CX::V3::SecuritySettingsService::Client::Configuration}
|
87
|
+
# for a description of the configuration fields.
|
88
|
+
#
|
89
|
+
# @yield [config] Configure the Client client.
|
90
|
+
# @yieldparam config [Client::Configuration]
|
91
|
+
#
|
92
|
+
# @return [Client::Configuration]
|
93
|
+
#
|
94
|
+
def configure
|
95
|
+
yield @config if block_given?
|
96
|
+
@config
|
97
|
+
end
|
98
|
+
|
99
|
+
##
|
100
|
+
# Create a new SecuritySettingsService client object.
|
101
|
+
#
|
102
|
+
# @example
|
103
|
+
#
|
104
|
+
# # Create a client using the default configuration
|
105
|
+
# client = ::Google::Cloud::Dialogflow::CX::V3::SecuritySettingsService::Client.new
|
106
|
+
#
|
107
|
+
# # Create a client using a custom configuration
|
108
|
+
# client = ::Google::Cloud::Dialogflow::CX::V3::SecuritySettingsService::Client.new do |config|
|
109
|
+
# config.timeout = 10.0
|
110
|
+
# end
|
111
|
+
#
|
112
|
+
# @yield [config] Configure the SecuritySettingsService client.
|
113
|
+
# @yieldparam config [Client::Configuration]
|
114
|
+
#
|
115
|
+
def initialize
|
116
|
+
# These require statements are intentionally placed here to initialize
|
117
|
+
# the gRPC module only when it's required.
|
118
|
+
# See https://github.com/googleapis/toolkit/issues/446
|
119
|
+
require "gapic/grpc"
|
120
|
+
require "google/cloud/dialogflow/cx/v3/security_settings_services_pb"
|
121
|
+
|
122
|
+
# Create the configuration object
|
123
|
+
@config = Configuration.new Client.configure
|
124
|
+
|
125
|
+
# Yield the configuration if needed
|
126
|
+
yield @config if block_given?
|
127
|
+
|
128
|
+
# Create credentials
|
129
|
+
credentials = @config.credentials
|
130
|
+
# Use self-signed JWT if the endpoint is unchanged from default,
|
131
|
+
# but only if the default endpoint does not have a region prefix.
|
132
|
+
enable_self_signed_jwt = @config.endpoint == Client.configure.endpoint &&
|
133
|
+
!@config.endpoint.split(".").first.include?("-")
|
134
|
+
credentials ||= Credentials.default scope: @config.scope,
|
135
|
+
enable_self_signed_jwt: enable_self_signed_jwt
|
136
|
+
if credentials.is_a?(::String) || credentials.is_a?(::Hash)
|
137
|
+
credentials = Credentials.new credentials, scope: @config.scope
|
138
|
+
end
|
139
|
+
@quota_project_id = @config.quota_project
|
140
|
+
@quota_project_id ||= credentials.quota_project_id if credentials.respond_to? :quota_project_id
|
141
|
+
|
142
|
+
@security_settings_service_stub = ::Gapic::ServiceStub.new(
|
143
|
+
::Google::Cloud::Dialogflow::CX::V3::SecuritySettingsService::Stub,
|
144
|
+
credentials: credentials,
|
145
|
+
endpoint: @config.endpoint,
|
146
|
+
channel_args: @config.channel_args,
|
147
|
+
interceptors: @config.interceptors
|
148
|
+
)
|
149
|
+
end
|
150
|
+
|
151
|
+
# Service calls
|
152
|
+
|
153
|
+
##
|
154
|
+
# Create security settings in the specified location.
|
155
|
+
#
|
156
|
+
# @overload create_security_settings(request, options = nil)
|
157
|
+
# Pass arguments to `create_security_settings` via a request object, either of type
|
158
|
+
# {::Google::Cloud::Dialogflow::CX::V3::CreateSecuritySettingsRequest} or an equivalent Hash.
|
159
|
+
#
|
160
|
+
# @param request [::Google::Cloud::Dialogflow::CX::V3::CreateSecuritySettingsRequest, ::Hash]
|
161
|
+
# A request object representing the call parameters. Required. To specify no
|
162
|
+
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
163
|
+
# @param options [::Gapic::CallOptions, ::Hash]
|
164
|
+
# Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
|
165
|
+
#
|
166
|
+
# @overload create_security_settings(parent: nil, security_settings: nil)
|
167
|
+
# Pass arguments to `create_security_settings` via keyword arguments. Note that at
|
168
|
+
# least one keyword argument is required. To specify no parameters, or to keep all
|
169
|
+
# the default parameter values, pass an empty Hash as a request object (see above).
|
170
|
+
#
|
171
|
+
# @param parent [::String]
|
172
|
+
# Required. The location to create an {::Google::Cloud::Dialogflow::CX::V3::SecuritySettings SecuritySettings} for.
|
173
|
+
# Format: `projects/<Project ID>/locations/<Location ID>`.
|
174
|
+
# @param security_settings [::Google::Cloud::Dialogflow::CX::V3::SecuritySettings, ::Hash]
|
175
|
+
# Required. The security settings to create.
|
176
|
+
#
|
177
|
+
# @yield [response, operation] Access the result along with the RPC operation
|
178
|
+
# @yieldparam response [::Google::Cloud::Dialogflow::CX::V3::SecuritySettings]
|
179
|
+
# @yieldparam operation [::GRPC::ActiveCall::Operation]
|
180
|
+
#
|
181
|
+
# @return [::Google::Cloud::Dialogflow::CX::V3::SecuritySettings]
|
182
|
+
#
|
183
|
+
# @raise [::Google::Cloud::Error] if the RPC is aborted.
|
184
|
+
#
|
185
|
+
def create_security_settings request, options = nil
|
186
|
+
raise ::ArgumentError, "request must be provided" if request.nil?
|
187
|
+
|
188
|
+
request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Dialogflow::CX::V3::CreateSecuritySettingsRequest
|
189
|
+
|
190
|
+
# Converts hash and nil to an options object
|
191
|
+
options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
192
|
+
|
193
|
+
# Customize the options with defaults
|
194
|
+
metadata = @config.rpcs.create_security_settings.metadata.to_h
|
195
|
+
|
196
|
+
# Set x-goog-api-client and x-goog-user-project headers
|
197
|
+
metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
198
|
+
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
199
|
+
gapic_version: ::Google::Cloud::Dialogflow::CX::V3::VERSION
|
200
|
+
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
201
|
+
|
202
|
+
header_params = {
|
203
|
+
"parent" => request.parent
|
204
|
+
}
|
205
|
+
request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
|
206
|
+
metadata[:"x-goog-request-params"] ||= request_params_header
|
207
|
+
|
208
|
+
options.apply_defaults timeout: @config.rpcs.create_security_settings.timeout,
|
209
|
+
metadata: metadata,
|
210
|
+
retry_policy: @config.rpcs.create_security_settings.retry_policy
|
211
|
+
|
212
|
+
options.apply_defaults timeout: @config.timeout,
|
213
|
+
metadata: @config.metadata,
|
214
|
+
retry_policy: @config.retry_policy
|
215
|
+
|
216
|
+
@security_settings_service_stub.call_rpc :create_security_settings, request, options: options do |response, operation|
|
217
|
+
yield response, operation if block_given?
|
218
|
+
return response
|
219
|
+
end
|
220
|
+
rescue ::GRPC::BadStatus => e
|
221
|
+
raise ::Google::Cloud::Error.from_error(e)
|
222
|
+
end
|
223
|
+
|
224
|
+
##
|
225
|
+
# Retrieves the specified {::Google::Cloud::Dialogflow::CX::V3::SecuritySettings SecuritySettings}.
|
226
|
+
# The returned settings may be stale by up to 1 minute.
|
227
|
+
#
|
228
|
+
# @overload get_security_settings(request, options = nil)
|
229
|
+
# Pass arguments to `get_security_settings` via a request object, either of type
|
230
|
+
# {::Google::Cloud::Dialogflow::CX::V3::GetSecuritySettingsRequest} or an equivalent Hash.
|
231
|
+
#
|
232
|
+
# @param request [::Google::Cloud::Dialogflow::CX::V3::GetSecuritySettingsRequest, ::Hash]
|
233
|
+
# A request object representing the call parameters. Required. To specify no
|
234
|
+
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
235
|
+
# @param options [::Gapic::CallOptions, ::Hash]
|
236
|
+
# Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
|
237
|
+
#
|
238
|
+
# @overload get_security_settings(name: nil)
|
239
|
+
# Pass arguments to `get_security_settings` via keyword arguments. Note that at
|
240
|
+
# least one keyword argument is required. To specify no parameters, or to keep all
|
241
|
+
# the default parameter values, pass an empty Hash as a request object (see above).
|
242
|
+
#
|
243
|
+
# @param name [::String]
|
244
|
+
# Required. Resource name of the settings.
|
245
|
+
# Format: `projects/<Project ID>/locations/<Location
|
246
|
+
# ID>/securitySettings/<security settings ID>`.
|
247
|
+
#
|
248
|
+
# @yield [response, operation] Access the result along with the RPC operation
|
249
|
+
# @yieldparam response [::Google::Cloud::Dialogflow::CX::V3::SecuritySettings]
|
250
|
+
# @yieldparam operation [::GRPC::ActiveCall::Operation]
|
251
|
+
#
|
252
|
+
# @return [::Google::Cloud::Dialogflow::CX::V3::SecuritySettings]
|
253
|
+
#
|
254
|
+
# @raise [::Google::Cloud::Error] if the RPC is aborted.
|
255
|
+
#
|
256
|
+
def get_security_settings request, options = nil
|
257
|
+
raise ::ArgumentError, "request must be provided" if request.nil?
|
258
|
+
|
259
|
+
request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Dialogflow::CX::V3::GetSecuritySettingsRequest
|
260
|
+
|
261
|
+
# Converts hash and nil to an options object
|
262
|
+
options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
263
|
+
|
264
|
+
# Customize the options with defaults
|
265
|
+
metadata = @config.rpcs.get_security_settings.metadata.to_h
|
266
|
+
|
267
|
+
# Set x-goog-api-client and x-goog-user-project headers
|
268
|
+
metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
269
|
+
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
270
|
+
gapic_version: ::Google::Cloud::Dialogflow::CX::V3::VERSION
|
271
|
+
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
272
|
+
|
273
|
+
header_params = {
|
274
|
+
"name" => request.name
|
275
|
+
}
|
276
|
+
request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
|
277
|
+
metadata[:"x-goog-request-params"] ||= request_params_header
|
278
|
+
|
279
|
+
options.apply_defaults timeout: @config.rpcs.get_security_settings.timeout,
|
280
|
+
metadata: metadata,
|
281
|
+
retry_policy: @config.rpcs.get_security_settings.retry_policy
|
282
|
+
|
283
|
+
options.apply_defaults timeout: @config.timeout,
|
284
|
+
metadata: @config.metadata,
|
285
|
+
retry_policy: @config.retry_policy
|
286
|
+
|
287
|
+
@security_settings_service_stub.call_rpc :get_security_settings, request, options: options do |response, operation|
|
288
|
+
yield response, operation if block_given?
|
289
|
+
return response
|
290
|
+
end
|
291
|
+
rescue ::GRPC::BadStatus => e
|
292
|
+
raise ::Google::Cloud::Error.from_error(e)
|
293
|
+
end
|
294
|
+
|
295
|
+
##
|
296
|
+
# Updates the specified {::Google::Cloud::Dialogflow::CX::V3::SecuritySettings SecuritySettings}.
|
297
|
+
#
|
298
|
+
# @overload update_security_settings(request, options = nil)
|
299
|
+
# Pass arguments to `update_security_settings` via a request object, either of type
|
300
|
+
# {::Google::Cloud::Dialogflow::CX::V3::UpdateSecuritySettingsRequest} or an equivalent Hash.
|
301
|
+
#
|
302
|
+
# @param request [::Google::Cloud::Dialogflow::CX::V3::UpdateSecuritySettingsRequest, ::Hash]
|
303
|
+
# A request object representing the call parameters. Required. To specify no
|
304
|
+
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
305
|
+
# @param options [::Gapic::CallOptions, ::Hash]
|
306
|
+
# Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
|
307
|
+
#
|
308
|
+
# @overload update_security_settings(security_settings: nil, update_mask: nil)
|
309
|
+
# Pass arguments to `update_security_settings` via keyword arguments. Note that at
|
310
|
+
# least one keyword argument is required. To specify no parameters, or to keep all
|
311
|
+
# the default parameter values, pass an empty Hash as a request object (see above).
|
312
|
+
#
|
313
|
+
# @param security_settings [::Google::Cloud::Dialogflow::CX::V3::SecuritySettings, ::Hash]
|
314
|
+
# Required. [SecuritySettings] object that contains values for each of the
|
315
|
+
# fields to update.
|
316
|
+
# @param update_mask [::Google::Protobuf::FieldMask, ::Hash]
|
317
|
+
# Required. The mask to control which fields get updated. If the mask is not present,
|
318
|
+
# all fields will be updated.
|
319
|
+
#
|
320
|
+
# @yield [response, operation] Access the result along with the RPC operation
|
321
|
+
# @yieldparam response [::Google::Cloud::Dialogflow::CX::V3::SecuritySettings]
|
322
|
+
# @yieldparam operation [::GRPC::ActiveCall::Operation]
|
323
|
+
#
|
324
|
+
# @return [::Google::Cloud::Dialogflow::CX::V3::SecuritySettings]
|
325
|
+
#
|
326
|
+
# @raise [::Google::Cloud::Error] if the RPC is aborted.
|
327
|
+
#
|
328
|
+
def update_security_settings request, options = nil
|
329
|
+
raise ::ArgumentError, "request must be provided" if request.nil?
|
330
|
+
|
331
|
+
request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Dialogflow::CX::V3::UpdateSecuritySettingsRequest
|
332
|
+
|
333
|
+
# Converts hash and nil to an options object
|
334
|
+
options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
335
|
+
|
336
|
+
# Customize the options with defaults
|
337
|
+
metadata = @config.rpcs.update_security_settings.metadata.to_h
|
338
|
+
|
339
|
+
# Set x-goog-api-client and x-goog-user-project headers
|
340
|
+
metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
341
|
+
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
342
|
+
gapic_version: ::Google::Cloud::Dialogflow::CX::V3::VERSION
|
343
|
+
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
344
|
+
|
345
|
+
header_params = {
|
346
|
+
"security_settings.name" => request.security_settings.name
|
347
|
+
}
|
348
|
+
request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
|
349
|
+
metadata[:"x-goog-request-params"] ||= request_params_header
|
350
|
+
|
351
|
+
options.apply_defaults timeout: @config.rpcs.update_security_settings.timeout,
|
352
|
+
metadata: metadata,
|
353
|
+
retry_policy: @config.rpcs.update_security_settings.retry_policy
|
354
|
+
|
355
|
+
options.apply_defaults timeout: @config.timeout,
|
356
|
+
metadata: @config.metadata,
|
357
|
+
retry_policy: @config.retry_policy
|
358
|
+
|
359
|
+
@security_settings_service_stub.call_rpc :update_security_settings, request, options: options do |response, operation|
|
360
|
+
yield response, operation if block_given?
|
361
|
+
return response
|
362
|
+
end
|
363
|
+
rescue ::GRPC::BadStatus => e
|
364
|
+
raise ::Google::Cloud::Error.from_error(e)
|
365
|
+
end
|
366
|
+
|
367
|
+
##
|
368
|
+
# Returns the list of all security settings in the specified location.
|
369
|
+
#
|
370
|
+
# @overload list_security_settings(request, options = nil)
|
371
|
+
# Pass arguments to `list_security_settings` via a request object, either of type
|
372
|
+
# {::Google::Cloud::Dialogflow::CX::V3::ListSecuritySettingsRequest} or an equivalent Hash.
|
373
|
+
#
|
374
|
+
# @param request [::Google::Cloud::Dialogflow::CX::V3::ListSecuritySettingsRequest, ::Hash]
|
375
|
+
# A request object representing the call parameters. Required. To specify no
|
376
|
+
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
377
|
+
# @param options [::Gapic::CallOptions, ::Hash]
|
378
|
+
# Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
|
379
|
+
#
|
380
|
+
# @overload list_security_settings(parent: nil, page_size: nil, page_token: nil)
|
381
|
+
# Pass arguments to `list_security_settings` via keyword arguments. Note that at
|
382
|
+
# least one keyword argument is required. To specify no parameters, or to keep all
|
383
|
+
# the default parameter values, pass an empty Hash as a request object (see above).
|
384
|
+
#
|
385
|
+
# @param parent [::String]
|
386
|
+
# Required. The location to list all security settings for.
|
387
|
+
# Format: `projects/<Project ID>/locations/<Location ID>`.
|
388
|
+
# @param page_size [::Integer]
|
389
|
+
# The maximum number of items to return in a single page. By default 20 and
|
390
|
+
# at most 100.
|
391
|
+
# @param page_token [::String]
|
392
|
+
# The next_page_token value returned from a previous list request.
|
393
|
+
#
|
394
|
+
# @yield [response, operation] Access the result along with the RPC operation
|
395
|
+
# @yieldparam response [::Gapic::PagedEnumerable<::Google::Cloud::Dialogflow::CX::V3::SecuritySettings>]
|
396
|
+
# @yieldparam operation [::GRPC::ActiveCall::Operation]
|
397
|
+
#
|
398
|
+
# @return [::Gapic::PagedEnumerable<::Google::Cloud::Dialogflow::CX::V3::SecuritySettings>]
|
399
|
+
#
|
400
|
+
# @raise [::Google::Cloud::Error] if the RPC is aborted.
|
401
|
+
#
|
402
|
+
def list_security_settings request, options = nil
|
403
|
+
raise ::ArgumentError, "request must be provided" if request.nil?
|
404
|
+
|
405
|
+
request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Dialogflow::CX::V3::ListSecuritySettingsRequest
|
406
|
+
|
407
|
+
# Converts hash and nil to an options object
|
408
|
+
options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
409
|
+
|
410
|
+
# Customize the options with defaults
|
411
|
+
metadata = @config.rpcs.list_security_settings.metadata.to_h
|
412
|
+
|
413
|
+
# Set x-goog-api-client and x-goog-user-project headers
|
414
|
+
metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
415
|
+
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
416
|
+
gapic_version: ::Google::Cloud::Dialogflow::CX::V3::VERSION
|
417
|
+
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
418
|
+
|
419
|
+
header_params = {
|
420
|
+
"parent" => request.parent
|
421
|
+
}
|
422
|
+
request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
|
423
|
+
metadata[:"x-goog-request-params"] ||= request_params_header
|
424
|
+
|
425
|
+
options.apply_defaults timeout: @config.rpcs.list_security_settings.timeout,
|
426
|
+
metadata: metadata,
|
427
|
+
retry_policy: @config.rpcs.list_security_settings.retry_policy
|
428
|
+
|
429
|
+
options.apply_defaults timeout: @config.timeout,
|
430
|
+
metadata: @config.metadata,
|
431
|
+
retry_policy: @config.retry_policy
|
432
|
+
|
433
|
+
@security_settings_service_stub.call_rpc :list_security_settings, request, options: options do |response, operation|
|
434
|
+
response = ::Gapic::PagedEnumerable.new @security_settings_service_stub, :list_security_settings, request, response, operation, options
|
435
|
+
yield response, operation if block_given?
|
436
|
+
return response
|
437
|
+
end
|
438
|
+
rescue ::GRPC::BadStatus => e
|
439
|
+
raise ::Google::Cloud::Error.from_error(e)
|
440
|
+
end
|
441
|
+
|
442
|
+
##
|
443
|
+
# Deletes the specified {::Google::Cloud::Dialogflow::CX::V3::SecuritySettings SecuritySettings}.
|
444
|
+
#
|
445
|
+
# @overload delete_security_settings(request, options = nil)
|
446
|
+
# Pass arguments to `delete_security_settings` via a request object, either of type
|
447
|
+
# {::Google::Cloud::Dialogflow::CX::V3::DeleteSecuritySettingsRequest} or an equivalent Hash.
|
448
|
+
#
|
449
|
+
# @param request [::Google::Cloud::Dialogflow::CX::V3::DeleteSecuritySettingsRequest, ::Hash]
|
450
|
+
# A request object representing the call parameters. Required. To specify no
|
451
|
+
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
452
|
+
# @param options [::Gapic::CallOptions, ::Hash]
|
453
|
+
# Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
|
454
|
+
#
|
455
|
+
# @overload delete_security_settings(name: nil)
|
456
|
+
# Pass arguments to `delete_security_settings` via keyword arguments. Note that at
|
457
|
+
# least one keyword argument is required. To specify no parameters, or to keep all
|
458
|
+
# the default parameter values, pass an empty Hash as a request object (see above).
|
459
|
+
#
|
460
|
+
# @param name [::String]
|
461
|
+
# Required. The name of the {::Google::Cloud::Dialogflow::CX::V3::SecuritySettings SecuritySettings} to delete.
|
462
|
+
# Format: `projects/<Project ID>/locations/<Location
|
463
|
+
# ID>/securitySettings/<Security Settings ID>`.
|
464
|
+
#
|
465
|
+
# @yield [response, operation] Access the result along with the RPC operation
|
466
|
+
# @yieldparam response [::Google::Protobuf::Empty]
|
467
|
+
# @yieldparam operation [::GRPC::ActiveCall::Operation]
|
468
|
+
#
|
469
|
+
# @return [::Google::Protobuf::Empty]
|
470
|
+
#
|
471
|
+
# @raise [::Google::Cloud::Error] if the RPC is aborted.
|
472
|
+
#
|
473
|
+
def delete_security_settings request, options = nil
|
474
|
+
raise ::ArgumentError, "request must be provided" if request.nil?
|
475
|
+
|
476
|
+
request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Dialogflow::CX::V3::DeleteSecuritySettingsRequest
|
477
|
+
|
478
|
+
# Converts hash and nil to an options object
|
479
|
+
options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
480
|
+
|
481
|
+
# Customize the options with defaults
|
482
|
+
metadata = @config.rpcs.delete_security_settings.metadata.to_h
|
483
|
+
|
484
|
+
# Set x-goog-api-client and x-goog-user-project headers
|
485
|
+
metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
486
|
+
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
487
|
+
gapic_version: ::Google::Cloud::Dialogflow::CX::V3::VERSION
|
488
|
+
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
489
|
+
|
490
|
+
header_params = {
|
491
|
+
"name" => request.name
|
492
|
+
}
|
493
|
+
request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
|
494
|
+
metadata[:"x-goog-request-params"] ||= request_params_header
|
495
|
+
|
496
|
+
options.apply_defaults timeout: @config.rpcs.delete_security_settings.timeout,
|
497
|
+
metadata: metadata,
|
498
|
+
retry_policy: @config.rpcs.delete_security_settings.retry_policy
|
499
|
+
|
500
|
+
options.apply_defaults timeout: @config.timeout,
|
501
|
+
metadata: @config.metadata,
|
502
|
+
retry_policy: @config.retry_policy
|
503
|
+
|
504
|
+
@security_settings_service_stub.call_rpc :delete_security_settings, request, options: options do |response, operation|
|
505
|
+
yield response, operation if block_given?
|
506
|
+
return response
|
507
|
+
end
|
508
|
+
rescue ::GRPC::BadStatus => e
|
509
|
+
raise ::Google::Cloud::Error.from_error(e)
|
510
|
+
end
|
511
|
+
|
512
|
+
##
|
513
|
+
# Configuration class for the SecuritySettingsService API.
|
514
|
+
#
|
515
|
+
# This class represents the configuration for SecuritySettingsService,
|
516
|
+
# providing control over timeouts, retry behavior, logging, transport
|
517
|
+
# parameters, and other low-level controls. Certain parameters can also be
|
518
|
+
# applied individually to specific RPCs. See
|
519
|
+
# {::Google::Cloud::Dialogflow::CX::V3::SecuritySettingsService::Client::Configuration::Rpcs}
|
520
|
+
# for a list of RPCs that can be configured independently.
|
521
|
+
#
|
522
|
+
# Configuration can be applied globally to all clients, or to a single client
|
523
|
+
# on construction.
|
524
|
+
#
|
525
|
+
# @example
|
526
|
+
#
|
527
|
+
# # Modify the global config, setting the timeout for
|
528
|
+
# # create_security_settings to 20 seconds,
|
529
|
+
# # and all remaining timeouts to 10 seconds.
|
530
|
+
# ::Google::Cloud::Dialogflow::CX::V3::SecuritySettingsService::Client.configure do |config|
|
531
|
+
# config.timeout = 10.0
|
532
|
+
# config.rpcs.create_security_settings.timeout = 20.0
|
533
|
+
# end
|
534
|
+
#
|
535
|
+
# # Apply the above configuration only to a new client.
|
536
|
+
# client = ::Google::Cloud::Dialogflow::CX::V3::SecuritySettingsService::Client.new do |config|
|
537
|
+
# config.timeout = 10.0
|
538
|
+
# config.rpcs.create_security_settings.timeout = 20.0
|
539
|
+
# end
|
540
|
+
#
|
541
|
+
# @!attribute [rw] endpoint
|
542
|
+
# The hostname or hostname:port of the service endpoint.
|
543
|
+
# Defaults to `"dialogflow.googleapis.com"`.
|
544
|
+
# @return [::String]
|
545
|
+
# @!attribute [rw] credentials
|
546
|
+
# Credentials to send with calls. You may provide any of the following types:
|
547
|
+
# * (`String`) The path to a service account key file in JSON format
|
548
|
+
# * (`Hash`) A service account key as a Hash
|
549
|
+
# * (`Google::Auth::Credentials`) A googleauth credentials object
|
550
|
+
# (see the [googleauth docs](https://googleapis.dev/ruby/googleauth/latest/index.html))
|
551
|
+
# * (`Signet::OAuth2::Client`) A signet oauth2 client object
|
552
|
+
# (see the [signet docs](https://googleapis.dev/ruby/signet/latest/Signet/OAuth2/Client.html))
|
553
|
+
# * (`GRPC::Core::Channel`) a gRPC channel with included credentials
|
554
|
+
# * (`GRPC::Core::ChannelCredentials`) a gRPC credentails object
|
555
|
+
# * (`nil`) indicating no credentials
|
556
|
+
# @return [::Object]
|
557
|
+
# @!attribute [rw] scope
|
558
|
+
# The OAuth scopes
|
559
|
+
# @return [::Array<::String>]
|
560
|
+
# @!attribute [rw] lib_name
|
561
|
+
# The library name as recorded in instrumentation and logging
|
562
|
+
# @return [::String]
|
563
|
+
# @!attribute [rw] lib_version
|
564
|
+
# The library version as recorded in instrumentation and logging
|
565
|
+
# @return [::String]
|
566
|
+
# @!attribute [rw] channel_args
|
567
|
+
# Extra parameters passed to the gRPC channel. Note: this is ignored if a
|
568
|
+
# `GRPC::Core::Channel` object is provided as the credential.
|
569
|
+
# @return [::Hash]
|
570
|
+
# @!attribute [rw] interceptors
|
571
|
+
# An array of interceptors that are run before calls are executed.
|
572
|
+
# @return [::Array<::GRPC::ClientInterceptor>]
|
573
|
+
# @!attribute [rw] timeout
|
574
|
+
# The call timeout in seconds.
|
575
|
+
# @return [::Numeric]
|
576
|
+
# @!attribute [rw] metadata
|
577
|
+
# Additional gRPC headers to be sent with the call.
|
578
|
+
# @return [::Hash{::Symbol=>::String}]
|
579
|
+
# @!attribute [rw] retry_policy
|
580
|
+
# The retry policy. The value is a hash with the following keys:
|
581
|
+
# * `:initial_delay` (*type:* `Numeric`) - The initial delay in seconds.
|
582
|
+
# * `:max_delay` (*type:* `Numeric`) - The max delay in seconds.
|
583
|
+
# * `:multiplier` (*type:* `Numeric`) - The incremental backoff multiplier.
|
584
|
+
# * `:retry_codes` (*type:* `Array<String>`) - The error codes that should
|
585
|
+
# trigger a retry.
|
586
|
+
# @return [::Hash]
|
587
|
+
# @!attribute [rw] quota_project
|
588
|
+
# A separate project against which to charge quota.
|
589
|
+
# @return [::String]
|
590
|
+
#
|
591
|
+
class Configuration
|
592
|
+
extend ::Gapic::Config
|
593
|
+
|
594
|
+
config_attr :endpoint, "dialogflow.googleapis.com", ::String
|
595
|
+
config_attr :credentials, nil do |value|
|
596
|
+
allowed = [::String, ::Hash, ::Proc, ::Symbol, ::Google::Auth::Credentials, ::Signet::OAuth2::Client, nil]
|
597
|
+
allowed += [::GRPC::Core::Channel, ::GRPC::Core::ChannelCredentials] if defined? ::GRPC
|
598
|
+
allowed.any? { |klass| klass === value }
|
599
|
+
end
|
600
|
+
config_attr :scope, nil, ::String, ::Array, nil
|
601
|
+
config_attr :lib_name, nil, ::String, nil
|
602
|
+
config_attr :lib_version, nil, ::String, nil
|
603
|
+
config_attr(:channel_args, { "grpc.service_config_disable_resolution" => 1 }, ::Hash, nil)
|
604
|
+
config_attr :interceptors, nil, ::Array, nil
|
605
|
+
config_attr :timeout, nil, ::Numeric, nil
|
606
|
+
config_attr :metadata, nil, ::Hash, nil
|
607
|
+
config_attr :retry_policy, nil, ::Hash, ::Proc, nil
|
608
|
+
config_attr :quota_project, nil, ::String, nil
|
609
|
+
|
610
|
+
# @private
|
611
|
+
def initialize parent_config = nil
|
612
|
+
@parent_config = parent_config unless parent_config.nil?
|
613
|
+
|
614
|
+
yield self if block_given?
|
615
|
+
end
|
616
|
+
|
617
|
+
##
|
618
|
+
# Configurations for individual RPCs
|
619
|
+
# @return [Rpcs]
|
620
|
+
#
|
621
|
+
def rpcs
|
622
|
+
@rpcs ||= begin
|
623
|
+
parent_rpcs = nil
|
624
|
+
parent_rpcs = @parent_config.rpcs if defined?(@parent_config) && @parent_config.respond_to?(:rpcs)
|
625
|
+
Rpcs.new parent_rpcs
|
626
|
+
end
|
627
|
+
end
|
628
|
+
|
629
|
+
##
|
630
|
+
# Configuration RPC class for the SecuritySettingsService API.
|
631
|
+
#
|
632
|
+
# Includes fields providing the configuration for each RPC in this service.
|
633
|
+
# Each configuration object is of type `Gapic::Config::Method` and includes
|
634
|
+
# the following configuration fields:
|
635
|
+
#
|
636
|
+
# * `timeout` (*type:* `Numeric`) - The call timeout in seconds
|
637
|
+
# * `metadata` (*type:* `Hash{Symbol=>String}`) - Additional gRPC headers
|
638
|
+
# * `retry_policy (*type:* `Hash`) - The retry policy. The policy fields
|
639
|
+
# include the following keys:
|
640
|
+
# * `:initial_delay` (*type:* `Numeric`) - The initial delay in seconds.
|
641
|
+
# * `:max_delay` (*type:* `Numeric`) - The max delay in seconds.
|
642
|
+
# * `:multiplier` (*type:* `Numeric`) - The incremental backoff multiplier.
|
643
|
+
# * `:retry_codes` (*type:* `Array<String>`) - The error codes that should
|
644
|
+
# trigger a retry.
|
645
|
+
#
|
646
|
+
class Rpcs
|
647
|
+
##
|
648
|
+
# RPC-specific configuration for `create_security_settings`
|
649
|
+
# @return [::Gapic::Config::Method]
|
650
|
+
#
|
651
|
+
attr_reader :create_security_settings
|
652
|
+
##
|
653
|
+
# RPC-specific configuration for `get_security_settings`
|
654
|
+
# @return [::Gapic::Config::Method]
|
655
|
+
#
|
656
|
+
attr_reader :get_security_settings
|
657
|
+
##
|
658
|
+
# RPC-specific configuration for `update_security_settings`
|
659
|
+
# @return [::Gapic::Config::Method]
|
660
|
+
#
|
661
|
+
attr_reader :update_security_settings
|
662
|
+
##
|
663
|
+
# RPC-specific configuration for `list_security_settings`
|
664
|
+
# @return [::Gapic::Config::Method]
|
665
|
+
#
|
666
|
+
attr_reader :list_security_settings
|
667
|
+
##
|
668
|
+
# RPC-specific configuration for `delete_security_settings`
|
669
|
+
# @return [::Gapic::Config::Method]
|
670
|
+
#
|
671
|
+
attr_reader :delete_security_settings
|
672
|
+
|
673
|
+
# @private
|
674
|
+
def initialize parent_rpcs = nil
|
675
|
+
create_security_settings_config = parent_rpcs.create_security_settings if parent_rpcs.respond_to? :create_security_settings
|
676
|
+
@create_security_settings = ::Gapic::Config::Method.new create_security_settings_config
|
677
|
+
get_security_settings_config = parent_rpcs.get_security_settings if parent_rpcs.respond_to? :get_security_settings
|
678
|
+
@get_security_settings = ::Gapic::Config::Method.new get_security_settings_config
|
679
|
+
update_security_settings_config = parent_rpcs.update_security_settings if parent_rpcs.respond_to? :update_security_settings
|
680
|
+
@update_security_settings = ::Gapic::Config::Method.new update_security_settings_config
|
681
|
+
list_security_settings_config = parent_rpcs.list_security_settings if parent_rpcs.respond_to? :list_security_settings
|
682
|
+
@list_security_settings = ::Gapic::Config::Method.new list_security_settings_config
|
683
|
+
delete_security_settings_config = parent_rpcs.delete_security_settings if parent_rpcs.respond_to? :delete_security_settings
|
684
|
+
@delete_security_settings = ::Gapic::Config::Method.new delete_security_settings_config
|
685
|
+
|
686
|
+
yield self if block_given?
|
687
|
+
end
|
688
|
+
end
|
689
|
+
end
|
690
|
+
end
|
691
|
+
end
|
692
|
+
end
|
693
|
+
end
|
694
|
+
end
|
695
|
+
end
|
696
|
+
end
|