google-cloud-dialogflow-v2 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 +24 -0
- data/lib/google-cloud-dialogflow-v2.rb +1 -0
- data/lib/google/cloud/common_resources_pb.rb +15 -0
- data/lib/google/cloud/dialogflow/v2.rb +24 -0
- data/lib/google/cloud/dialogflow/v2/agent_pb.rb +122 -0
- data/lib/google/cloud/dialogflow/v2/agent_services_pb.rb +110 -0
- data/lib/google/cloud/dialogflow/v2/agents.rb +21 -0
- data/lib/google/cloud/dialogflow/v2/agents/client.rb +1047 -0
- data/lib/google/cloud/dialogflow/v2/agents/credentials.rb +53 -0
- data/lib/google/cloud/dialogflow/v2/agents/operations.rb +559 -0
- data/lib/google/cloud/dialogflow/v2/agents/paths.rb +59 -0
- data/lib/google/cloud/dialogflow/v2/audio_config_pb.rb +97 -0
- data/lib/google/cloud/dialogflow/v2/context_pb.rb +64 -0
- data/lib/google/cloud/dialogflow/v2/context_services_pb.rb +74 -0
- data/lib/google/cloud/dialogflow/v2/contexts.rb +20 -0
- data/lib/google/cloud/dialogflow/v2/contexts/client.rb +756 -0
- data/lib/google/cloud/dialogflow/v2/contexts/credentials.rb +53 -0
- data/lib/google/cloud/dialogflow/v2/contexts/paths.rb +50 -0
- data/lib/google/cloud/dialogflow/v2/entity_type_pb.rb +126 -0
- data/lib/google/cloud/dialogflow/v2/entity_type_services_pb.rb +104 -0
- data/lib/google/cloud/dialogflow/v2/entity_types.rb +21 -0
- data/lib/google/cloud/dialogflow/v2/entity_types/client.rb +1150 -0
- data/lib/google/cloud/dialogflow/v2/entity_types/credentials.rb +53 -0
- data/lib/google/cloud/dialogflow/v2/entity_types/operations.rb +559 -0
- data/lib/google/cloud/dialogflow/v2/entity_types/paths.rb +62 -0
- data/lib/google/cloud/dialogflow/v2/intent_pb.rb +368 -0
- data/lib/google/cloud/dialogflow/v2/intent_services_pb.rb +92 -0
- data/lib/google/cloud/dialogflow/v2/intents.rb +21 -0
- data/lib/google/cloud/dialogflow/v2/intents/client.rb +893 -0
- data/lib/google/cloud/dialogflow/v2/intents/credentials.rb +53 -0
- data/lib/google/cloud/dialogflow/v2/intents/operations.rb +559 -0
- data/lib/google/cloud/dialogflow/v2/intents/paths.rb +81 -0
- data/lib/google/cloud/dialogflow/v2/session_entity_type_pb.rb +66 -0
- data/lib/google/cloud/dialogflow/v2/session_entity_type_services_pb.rb +92 -0
- data/lib/google/cloud/dialogflow/v2/session_entity_types.rb +20 -0
- data/lib/google/cloud/dialogflow/v2/session_entity_types/client.rb +727 -0
- data/lib/google/cloud/dialogflow/v2/session_entity_types/credentials.rb +53 -0
- data/lib/google/cloud/dialogflow/v2/session_entity_types/paths.rb +69 -0
- data/lib/google/cloud/dialogflow/v2/session_pb.rb +142 -0
- data/lib/google/cloud/dialogflow/v2/session_services_pb.rb +55 -0
- data/lib/google/cloud/dialogflow/v2/sessions.rb +20 -0
- data/lib/google/cloud/dialogflow/v2/sessions/client.rb +472 -0
- data/lib/google/cloud/dialogflow/v2/sessions/credentials.rb +53 -0
- data/lib/google/cloud/dialogflow/v2/sessions/paths.rb +110 -0
- data/lib/google/cloud/dialogflow/v2/validation_result_pb.rb +37 -0
- data/lib/google/cloud/dialogflow/v2/version.rb +28 -0
- data/lib/google/cloud/dialogflow/v2/webhook_pb.rb +47 -0
- data/proto_docs/README.md +4 -0
- data/proto_docs/google/api/field_behavior.rb +59 -0
- data/proto_docs/google/api/resource.rb +247 -0
- data/proto_docs/google/cloud/dialogflow/v2/agent.rb +287 -0
- data/proto_docs/google/cloud/dialogflow/v2/audio_config.rb +363 -0
- data/proto_docs/google/cloud/dialogflow/v2/context.rb +144 -0
- data/proto_docs/google/cloud/dialogflow/v2/entity_type.rb +354 -0
- data/proto_docs/google/cloud/dialogflow/v2/intent.rb +1070 -0
- data/proto_docs/google/cloud/dialogflow/v2/session.rb +541 -0
- data/proto_docs/google/cloud/dialogflow/v2/session_entity_type.rb +155 -0
- data/proto_docs/google/cloud/dialogflow/v2/validation_result.rb +81 -0
- data/proto_docs/google/cloud/dialogflow/v2/webhook.rb +153 -0
- data/proto_docs/google/longrunning/operations.rb +150 -0
- data/proto_docs/google/protobuf/any.rb +137 -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 +237 -0
- data/proto_docs/google/protobuf/struct.rb +96 -0
- data/proto_docs/google/rpc/status.rb +46 -0
- data/proto_docs/google/type/latlng.rb +38 -0
- metadata +225 -0
@@ -0,0 +1,62 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
# Copyright 2020 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 V2
|
24
|
+
module EntityTypes
|
25
|
+
# Path helper methods for the EntityTypes API.
|
26
|
+
module Paths
|
27
|
+
##
|
28
|
+
# Create a fully-qualified Agent resource string.
|
29
|
+
#
|
30
|
+
# The resource will be in the following format:
|
31
|
+
#
|
32
|
+
# `projects/{project}/agent`
|
33
|
+
#
|
34
|
+
# @param project [String]
|
35
|
+
#
|
36
|
+
# @return [String]
|
37
|
+
def agent_path project:
|
38
|
+
"projects/#{project}/agent"
|
39
|
+
end
|
40
|
+
|
41
|
+
##
|
42
|
+
# Create a fully-qualified EntityType resource string.
|
43
|
+
#
|
44
|
+
# The resource will be in the following format:
|
45
|
+
#
|
46
|
+
# `projects/{project}/agent/entityTypes/{entity_type}`
|
47
|
+
#
|
48
|
+
# @param project [String]
|
49
|
+
# @param entity_type [String]
|
50
|
+
#
|
51
|
+
# @return [String]
|
52
|
+
def entity_type_path project:, entity_type:
|
53
|
+
raise ArgumentError, "project cannot contain /" if project.to_s.include? "/"
|
54
|
+
|
55
|
+
"projects/#{project}/agent/entityTypes/#{entity_type}"
|
56
|
+
end
|
57
|
+
end
|
58
|
+
end
|
59
|
+
end
|
60
|
+
end
|
61
|
+
end
|
62
|
+
end
|
@@ -0,0 +1,368 @@
|
|
1
|
+
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
2
|
+
# source: google/cloud/dialogflow/v2/intent.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/cloud/dialogflow/v2/audio_config_pb'
|
11
|
+
require 'google/cloud/dialogflow/v2/context_pb'
|
12
|
+
require 'google/longrunning/operations_pb'
|
13
|
+
require 'google/protobuf/duration_pb'
|
14
|
+
require 'google/protobuf/empty_pb'
|
15
|
+
require 'google/protobuf/field_mask_pb'
|
16
|
+
require 'google/protobuf/struct_pb'
|
17
|
+
Google::Protobuf::DescriptorPool.generated_pool.build do
|
18
|
+
add_file("google/cloud/dialogflow/v2/intent.proto", :syntax => :proto3) do
|
19
|
+
add_message "google.cloud.dialogflow.v2.Intent" do
|
20
|
+
optional :name, :string, 1
|
21
|
+
optional :display_name, :string, 2
|
22
|
+
optional :webhook_state, :enum, 6, "google.cloud.dialogflow.v2.Intent.WebhookState"
|
23
|
+
optional :priority, :int32, 3
|
24
|
+
optional :is_fallback, :bool, 4
|
25
|
+
optional :ml_disabled, :bool, 19
|
26
|
+
repeated :input_context_names, :string, 7
|
27
|
+
repeated :events, :string, 8
|
28
|
+
repeated :training_phrases, :message, 9, "google.cloud.dialogflow.v2.Intent.TrainingPhrase"
|
29
|
+
optional :action, :string, 10
|
30
|
+
repeated :output_contexts, :message, 11, "google.cloud.dialogflow.v2.Context"
|
31
|
+
optional :reset_contexts, :bool, 12
|
32
|
+
repeated :parameters, :message, 13, "google.cloud.dialogflow.v2.Intent.Parameter"
|
33
|
+
repeated :messages, :message, 14, "google.cloud.dialogflow.v2.Intent.Message"
|
34
|
+
repeated :default_response_platforms, :enum, 15, "google.cloud.dialogflow.v2.Intent.Message.Platform"
|
35
|
+
optional :root_followup_intent_name, :string, 16
|
36
|
+
optional :parent_followup_intent_name, :string, 17
|
37
|
+
repeated :followup_intent_info, :message, 18, "google.cloud.dialogflow.v2.Intent.FollowupIntentInfo"
|
38
|
+
end
|
39
|
+
add_message "google.cloud.dialogflow.v2.Intent.TrainingPhrase" do
|
40
|
+
optional :name, :string, 1
|
41
|
+
optional :type, :enum, 2, "google.cloud.dialogflow.v2.Intent.TrainingPhrase.Type"
|
42
|
+
repeated :parts, :message, 3, "google.cloud.dialogflow.v2.Intent.TrainingPhrase.Part"
|
43
|
+
optional :times_added_count, :int32, 4
|
44
|
+
end
|
45
|
+
add_message "google.cloud.dialogflow.v2.Intent.TrainingPhrase.Part" do
|
46
|
+
optional :text, :string, 1
|
47
|
+
optional :entity_type, :string, 2
|
48
|
+
optional :alias, :string, 3
|
49
|
+
optional :user_defined, :bool, 4
|
50
|
+
end
|
51
|
+
add_enum "google.cloud.dialogflow.v2.Intent.TrainingPhrase.Type" do
|
52
|
+
value :TYPE_UNSPECIFIED, 0
|
53
|
+
value :EXAMPLE, 1
|
54
|
+
value :TEMPLATE, 2
|
55
|
+
end
|
56
|
+
add_message "google.cloud.dialogflow.v2.Intent.Parameter" do
|
57
|
+
optional :name, :string, 1
|
58
|
+
optional :display_name, :string, 2
|
59
|
+
optional :value, :string, 3
|
60
|
+
optional :default_value, :string, 4
|
61
|
+
optional :entity_type_display_name, :string, 5
|
62
|
+
optional :mandatory, :bool, 6
|
63
|
+
repeated :prompts, :string, 7
|
64
|
+
optional :is_list, :bool, 8
|
65
|
+
end
|
66
|
+
add_message "google.cloud.dialogflow.v2.Intent.Message" do
|
67
|
+
optional :platform, :enum, 6, "google.cloud.dialogflow.v2.Intent.Message.Platform"
|
68
|
+
oneof :message do
|
69
|
+
optional :text, :message, 1, "google.cloud.dialogflow.v2.Intent.Message.Text"
|
70
|
+
optional :image, :message, 2, "google.cloud.dialogflow.v2.Intent.Message.Image"
|
71
|
+
optional :quick_replies, :message, 3, "google.cloud.dialogflow.v2.Intent.Message.QuickReplies"
|
72
|
+
optional :card, :message, 4, "google.cloud.dialogflow.v2.Intent.Message.Card"
|
73
|
+
optional :payload, :message, 5, "google.protobuf.Struct"
|
74
|
+
optional :simple_responses, :message, 7, "google.cloud.dialogflow.v2.Intent.Message.SimpleResponses"
|
75
|
+
optional :basic_card, :message, 8, "google.cloud.dialogflow.v2.Intent.Message.BasicCard"
|
76
|
+
optional :suggestions, :message, 9, "google.cloud.dialogflow.v2.Intent.Message.Suggestions"
|
77
|
+
optional :link_out_suggestion, :message, 10, "google.cloud.dialogflow.v2.Intent.Message.LinkOutSuggestion"
|
78
|
+
optional :list_select, :message, 11, "google.cloud.dialogflow.v2.Intent.Message.ListSelect"
|
79
|
+
optional :carousel_select, :message, 12, "google.cloud.dialogflow.v2.Intent.Message.CarouselSelect"
|
80
|
+
optional :browse_carousel_card, :message, 22, "google.cloud.dialogflow.v2.Intent.Message.BrowseCarouselCard"
|
81
|
+
optional :table_card, :message, 23, "google.cloud.dialogflow.v2.Intent.Message.TableCard"
|
82
|
+
optional :media_content, :message, 24, "google.cloud.dialogflow.v2.Intent.Message.MediaContent"
|
83
|
+
end
|
84
|
+
end
|
85
|
+
add_message "google.cloud.dialogflow.v2.Intent.Message.Text" do
|
86
|
+
repeated :text, :string, 1
|
87
|
+
end
|
88
|
+
add_message "google.cloud.dialogflow.v2.Intent.Message.Image" do
|
89
|
+
optional :image_uri, :string, 1
|
90
|
+
optional :accessibility_text, :string, 2
|
91
|
+
end
|
92
|
+
add_message "google.cloud.dialogflow.v2.Intent.Message.QuickReplies" do
|
93
|
+
optional :title, :string, 1
|
94
|
+
repeated :quick_replies, :string, 2
|
95
|
+
end
|
96
|
+
add_message "google.cloud.dialogflow.v2.Intent.Message.Card" do
|
97
|
+
optional :title, :string, 1
|
98
|
+
optional :subtitle, :string, 2
|
99
|
+
optional :image_uri, :string, 3
|
100
|
+
repeated :buttons, :message, 4, "google.cloud.dialogflow.v2.Intent.Message.Card.Button"
|
101
|
+
end
|
102
|
+
add_message "google.cloud.dialogflow.v2.Intent.Message.Card.Button" do
|
103
|
+
optional :text, :string, 1
|
104
|
+
optional :postback, :string, 2
|
105
|
+
end
|
106
|
+
add_message "google.cloud.dialogflow.v2.Intent.Message.SimpleResponse" do
|
107
|
+
optional :text_to_speech, :string, 1
|
108
|
+
optional :ssml, :string, 2
|
109
|
+
optional :display_text, :string, 3
|
110
|
+
end
|
111
|
+
add_message "google.cloud.dialogflow.v2.Intent.Message.SimpleResponses" do
|
112
|
+
repeated :simple_responses, :message, 1, "google.cloud.dialogflow.v2.Intent.Message.SimpleResponse"
|
113
|
+
end
|
114
|
+
add_message "google.cloud.dialogflow.v2.Intent.Message.BasicCard" do
|
115
|
+
optional :title, :string, 1
|
116
|
+
optional :subtitle, :string, 2
|
117
|
+
optional :formatted_text, :string, 3
|
118
|
+
optional :image, :message, 4, "google.cloud.dialogflow.v2.Intent.Message.Image"
|
119
|
+
repeated :buttons, :message, 5, "google.cloud.dialogflow.v2.Intent.Message.BasicCard.Button"
|
120
|
+
end
|
121
|
+
add_message "google.cloud.dialogflow.v2.Intent.Message.BasicCard.Button" do
|
122
|
+
optional :title, :string, 1
|
123
|
+
optional :open_uri_action, :message, 2, "google.cloud.dialogflow.v2.Intent.Message.BasicCard.Button.OpenUriAction"
|
124
|
+
end
|
125
|
+
add_message "google.cloud.dialogflow.v2.Intent.Message.BasicCard.Button.OpenUriAction" do
|
126
|
+
optional :uri, :string, 1
|
127
|
+
end
|
128
|
+
add_message "google.cloud.dialogflow.v2.Intent.Message.Suggestion" do
|
129
|
+
optional :title, :string, 1
|
130
|
+
end
|
131
|
+
add_message "google.cloud.dialogflow.v2.Intent.Message.Suggestions" do
|
132
|
+
repeated :suggestions, :message, 1, "google.cloud.dialogflow.v2.Intent.Message.Suggestion"
|
133
|
+
end
|
134
|
+
add_message "google.cloud.dialogflow.v2.Intent.Message.LinkOutSuggestion" do
|
135
|
+
optional :destination_name, :string, 1
|
136
|
+
optional :uri, :string, 2
|
137
|
+
end
|
138
|
+
add_message "google.cloud.dialogflow.v2.Intent.Message.ListSelect" do
|
139
|
+
optional :title, :string, 1
|
140
|
+
repeated :items, :message, 2, "google.cloud.dialogflow.v2.Intent.Message.ListSelect.Item"
|
141
|
+
optional :subtitle, :string, 3
|
142
|
+
end
|
143
|
+
add_message "google.cloud.dialogflow.v2.Intent.Message.ListSelect.Item" do
|
144
|
+
optional :info, :message, 1, "google.cloud.dialogflow.v2.Intent.Message.SelectItemInfo"
|
145
|
+
optional :title, :string, 2
|
146
|
+
optional :description, :string, 3
|
147
|
+
optional :image, :message, 4, "google.cloud.dialogflow.v2.Intent.Message.Image"
|
148
|
+
end
|
149
|
+
add_message "google.cloud.dialogflow.v2.Intent.Message.CarouselSelect" do
|
150
|
+
repeated :items, :message, 1, "google.cloud.dialogflow.v2.Intent.Message.CarouselSelect.Item"
|
151
|
+
end
|
152
|
+
add_message "google.cloud.dialogflow.v2.Intent.Message.CarouselSelect.Item" do
|
153
|
+
optional :info, :message, 1, "google.cloud.dialogflow.v2.Intent.Message.SelectItemInfo"
|
154
|
+
optional :title, :string, 2
|
155
|
+
optional :description, :string, 3
|
156
|
+
optional :image, :message, 4, "google.cloud.dialogflow.v2.Intent.Message.Image"
|
157
|
+
end
|
158
|
+
add_message "google.cloud.dialogflow.v2.Intent.Message.SelectItemInfo" do
|
159
|
+
optional :key, :string, 1
|
160
|
+
repeated :synonyms, :string, 2
|
161
|
+
end
|
162
|
+
add_message "google.cloud.dialogflow.v2.Intent.Message.MediaContent" do
|
163
|
+
optional :media_type, :enum, 1, "google.cloud.dialogflow.v2.Intent.Message.MediaContent.ResponseMediaType"
|
164
|
+
repeated :media_objects, :message, 2, "google.cloud.dialogflow.v2.Intent.Message.MediaContent.ResponseMediaObject"
|
165
|
+
end
|
166
|
+
add_message "google.cloud.dialogflow.v2.Intent.Message.MediaContent.ResponseMediaObject" do
|
167
|
+
optional :name, :string, 1
|
168
|
+
optional :description, :string, 2
|
169
|
+
optional :content_url, :string, 5
|
170
|
+
oneof :image do
|
171
|
+
optional :large_image, :message, 3, "google.cloud.dialogflow.v2.Intent.Message.Image"
|
172
|
+
optional :icon, :message, 4, "google.cloud.dialogflow.v2.Intent.Message.Image"
|
173
|
+
end
|
174
|
+
end
|
175
|
+
add_enum "google.cloud.dialogflow.v2.Intent.Message.MediaContent.ResponseMediaType" do
|
176
|
+
value :RESPONSE_MEDIA_TYPE_UNSPECIFIED, 0
|
177
|
+
value :AUDIO, 1
|
178
|
+
end
|
179
|
+
add_message "google.cloud.dialogflow.v2.Intent.Message.BrowseCarouselCard" do
|
180
|
+
repeated :items, :message, 1, "google.cloud.dialogflow.v2.Intent.Message.BrowseCarouselCard.BrowseCarouselCardItem"
|
181
|
+
optional :image_display_options, :enum, 2, "google.cloud.dialogflow.v2.Intent.Message.BrowseCarouselCard.ImageDisplayOptions"
|
182
|
+
end
|
183
|
+
add_message "google.cloud.dialogflow.v2.Intent.Message.BrowseCarouselCard.BrowseCarouselCardItem" do
|
184
|
+
optional :open_uri_action, :message, 1, "google.cloud.dialogflow.v2.Intent.Message.BrowseCarouselCard.BrowseCarouselCardItem.OpenUrlAction"
|
185
|
+
optional :title, :string, 2
|
186
|
+
optional :description, :string, 3
|
187
|
+
optional :image, :message, 4, "google.cloud.dialogflow.v2.Intent.Message.Image"
|
188
|
+
optional :footer, :string, 5
|
189
|
+
end
|
190
|
+
add_message "google.cloud.dialogflow.v2.Intent.Message.BrowseCarouselCard.BrowseCarouselCardItem.OpenUrlAction" do
|
191
|
+
optional :url, :string, 1
|
192
|
+
optional :url_type_hint, :enum, 3, "google.cloud.dialogflow.v2.Intent.Message.BrowseCarouselCard.BrowseCarouselCardItem.OpenUrlAction.UrlTypeHint"
|
193
|
+
end
|
194
|
+
add_enum "google.cloud.dialogflow.v2.Intent.Message.BrowseCarouselCard.BrowseCarouselCardItem.OpenUrlAction.UrlTypeHint" do
|
195
|
+
value :URL_TYPE_HINT_UNSPECIFIED, 0
|
196
|
+
value :AMP_ACTION, 1
|
197
|
+
value :AMP_CONTENT, 2
|
198
|
+
end
|
199
|
+
add_enum "google.cloud.dialogflow.v2.Intent.Message.BrowseCarouselCard.ImageDisplayOptions" do
|
200
|
+
value :IMAGE_DISPLAY_OPTIONS_UNSPECIFIED, 0
|
201
|
+
value :GRAY, 1
|
202
|
+
value :WHITE, 2
|
203
|
+
value :CROPPED, 3
|
204
|
+
value :BLURRED_BACKGROUND, 4
|
205
|
+
end
|
206
|
+
add_message "google.cloud.dialogflow.v2.Intent.Message.TableCard" do
|
207
|
+
optional :title, :string, 1
|
208
|
+
optional :subtitle, :string, 2
|
209
|
+
optional :image, :message, 3, "google.cloud.dialogflow.v2.Intent.Message.Image"
|
210
|
+
repeated :column_properties, :message, 4, "google.cloud.dialogflow.v2.Intent.Message.ColumnProperties"
|
211
|
+
repeated :rows, :message, 5, "google.cloud.dialogflow.v2.Intent.Message.TableCardRow"
|
212
|
+
repeated :buttons, :message, 6, "google.cloud.dialogflow.v2.Intent.Message.BasicCard.Button"
|
213
|
+
end
|
214
|
+
add_message "google.cloud.dialogflow.v2.Intent.Message.ColumnProperties" do
|
215
|
+
optional :header, :string, 1
|
216
|
+
optional :horizontal_alignment, :enum, 2, "google.cloud.dialogflow.v2.Intent.Message.ColumnProperties.HorizontalAlignment"
|
217
|
+
end
|
218
|
+
add_enum "google.cloud.dialogflow.v2.Intent.Message.ColumnProperties.HorizontalAlignment" do
|
219
|
+
value :HORIZONTAL_ALIGNMENT_UNSPECIFIED, 0
|
220
|
+
value :LEADING, 1
|
221
|
+
value :CENTER, 2
|
222
|
+
value :TRAILING, 3
|
223
|
+
end
|
224
|
+
add_message "google.cloud.dialogflow.v2.Intent.Message.TableCardRow" do
|
225
|
+
repeated :cells, :message, 1, "google.cloud.dialogflow.v2.Intent.Message.TableCardCell"
|
226
|
+
optional :divider_after, :bool, 2
|
227
|
+
end
|
228
|
+
add_message "google.cloud.dialogflow.v2.Intent.Message.TableCardCell" do
|
229
|
+
optional :text, :string, 1
|
230
|
+
end
|
231
|
+
add_enum "google.cloud.dialogflow.v2.Intent.Message.Platform" do
|
232
|
+
value :PLATFORM_UNSPECIFIED, 0
|
233
|
+
value :FACEBOOK, 1
|
234
|
+
value :SLACK, 2
|
235
|
+
value :TELEGRAM, 3
|
236
|
+
value :KIK, 4
|
237
|
+
value :SKYPE, 5
|
238
|
+
value :LINE, 6
|
239
|
+
value :VIBER, 7
|
240
|
+
value :ACTIONS_ON_GOOGLE, 8
|
241
|
+
value :GOOGLE_HANGOUTS, 11
|
242
|
+
end
|
243
|
+
add_message "google.cloud.dialogflow.v2.Intent.FollowupIntentInfo" do
|
244
|
+
optional :followup_intent_name, :string, 1
|
245
|
+
optional :parent_followup_intent_name, :string, 2
|
246
|
+
end
|
247
|
+
add_enum "google.cloud.dialogflow.v2.Intent.WebhookState" do
|
248
|
+
value :WEBHOOK_STATE_UNSPECIFIED, 0
|
249
|
+
value :WEBHOOK_STATE_ENABLED, 1
|
250
|
+
value :WEBHOOK_STATE_ENABLED_FOR_SLOT_FILLING, 2
|
251
|
+
end
|
252
|
+
add_message "google.cloud.dialogflow.v2.ListIntentsRequest" do
|
253
|
+
optional :parent, :string, 1
|
254
|
+
optional :language_code, :string, 2
|
255
|
+
optional :intent_view, :enum, 3, "google.cloud.dialogflow.v2.IntentView"
|
256
|
+
optional :page_size, :int32, 4
|
257
|
+
optional :page_token, :string, 5
|
258
|
+
end
|
259
|
+
add_message "google.cloud.dialogflow.v2.ListIntentsResponse" do
|
260
|
+
repeated :intents, :message, 1, "google.cloud.dialogflow.v2.Intent"
|
261
|
+
optional :next_page_token, :string, 2
|
262
|
+
end
|
263
|
+
add_message "google.cloud.dialogflow.v2.GetIntentRequest" do
|
264
|
+
optional :name, :string, 1
|
265
|
+
optional :language_code, :string, 2
|
266
|
+
optional :intent_view, :enum, 3, "google.cloud.dialogflow.v2.IntentView"
|
267
|
+
end
|
268
|
+
add_message "google.cloud.dialogflow.v2.CreateIntentRequest" do
|
269
|
+
optional :parent, :string, 1
|
270
|
+
optional :intent, :message, 2, "google.cloud.dialogflow.v2.Intent"
|
271
|
+
optional :language_code, :string, 3
|
272
|
+
optional :intent_view, :enum, 4, "google.cloud.dialogflow.v2.IntentView"
|
273
|
+
end
|
274
|
+
add_message "google.cloud.dialogflow.v2.UpdateIntentRequest" do
|
275
|
+
optional :intent, :message, 1, "google.cloud.dialogflow.v2.Intent"
|
276
|
+
optional :language_code, :string, 2
|
277
|
+
optional :update_mask, :message, 3, "google.protobuf.FieldMask"
|
278
|
+
optional :intent_view, :enum, 4, "google.cloud.dialogflow.v2.IntentView"
|
279
|
+
end
|
280
|
+
add_message "google.cloud.dialogflow.v2.DeleteIntentRequest" do
|
281
|
+
optional :name, :string, 1
|
282
|
+
end
|
283
|
+
add_message "google.cloud.dialogflow.v2.BatchUpdateIntentsRequest" do
|
284
|
+
optional :parent, :string, 1
|
285
|
+
optional :language_code, :string, 4
|
286
|
+
optional :update_mask, :message, 5, "google.protobuf.FieldMask"
|
287
|
+
optional :intent_view, :enum, 6, "google.cloud.dialogflow.v2.IntentView"
|
288
|
+
oneof :intent_batch do
|
289
|
+
optional :intent_batch_uri, :string, 2
|
290
|
+
optional :intent_batch_inline, :message, 3, "google.cloud.dialogflow.v2.IntentBatch"
|
291
|
+
end
|
292
|
+
end
|
293
|
+
add_message "google.cloud.dialogflow.v2.BatchUpdateIntentsResponse" do
|
294
|
+
repeated :intents, :message, 1, "google.cloud.dialogflow.v2.Intent"
|
295
|
+
end
|
296
|
+
add_message "google.cloud.dialogflow.v2.BatchDeleteIntentsRequest" do
|
297
|
+
optional :parent, :string, 1
|
298
|
+
repeated :intents, :message, 2, "google.cloud.dialogflow.v2.Intent"
|
299
|
+
end
|
300
|
+
add_message "google.cloud.dialogflow.v2.IntentBatch" do
|
301
|
+
repeated :intents, :message, 1, "google.cloud.dialogflow.v2.Intent"
|
302
|
+
end
|
303
|
+
add_enum "google.cloud.dialogflow.v2.IntentView" do
|
304
|
+
value :INTENT_VIEW_UNSPECIFIED, 0
|
305
|
+
value :INTENT_VIEW_FULL, 1
|
306
|
+
end
|
307
|
+
end
|
308
|
+
end
|
309
|
+
|
310
|
+
module Google
|
311
|
+
module Cloud
|
312
|
+
module Dialogflow
|
313
|
+
module V2
|
314
|
+
Intent = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.dialogflow.v2.Intent").msgclass
|
315
|
+
Intent::TrainingPhrase = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.dialogflow.v2.Intent.TrainingPhrase").msgclass
|
316
|
+
Intent::TrainingPhrase::Part = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.dialogflow.v2.Intent.TrainingPhrase.Part").msgclass
|
317
|
+
Intent::TrainingPhrase::Type = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.dialogflow.v2.Intent.TrainingPhrase.Type").enummodule
|
318
|
+
Intent::Parameter = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.dialogflow.v2.Intent.Parameter").msgclass
|
319
|
+
Intent::Message = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.dialogflow.v2.Intent.Message").msgclass
|
320
|
+
Intent::Message::Text = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.dialogflow.v2.Intent.Message.Text").msgclass
|
321
|
+
Intent::Message::Image = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.dialogflow.v2.Intent.Message.Image").msgclass
|
322
|
+
Intent::Message::QuickReplies = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.dialogflow.v2.Intent.Message.QuickReplies").msgclass
|
323
|
+
Intent::Message::Card = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.dialogflow.v2.Intent.Message.Card").msgclass
|
324
|
+
Intent::Message::Card::Button = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.dialogflow.v2.Intent.Message.Card.Button").msgclass
|
325
|
+
Intent::Message::SimpleResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.dialogflow.v2.Intent.Message.SimpleResponse").msgclass
|
326
|
+
Intent::Message::SimpleResponses = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.dialogflow.v2.Intent.Message.SimpleResponses").msgclass
|
327
|
+
Intent::Message::BasicCard = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.dialogflow.v2.Intent.Message.BasicCard").msgclass
|
328
|
+
Intent::Message::BasicCard::Button = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.dialogflow.v2.Intent.Message.BasicCard.Button").msgclass
|
329
|
+
Intent::Message::BasicCard::Button::OpenUriAction = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.dialogflow.v2.Intent.Message.BasicCard.Button.OpenUriAction").msgclass
|
330
|
+
Intent::Message::Suggestion = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.dialogflow.v2.Intent.Message.Suggestion").msgclass
|
331
|
+
Intent::Message::Suggestions = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.dialogflow.v2.Intent.Message.Suggestions").msgclass
|
332
|
+
Intent::Message::LinkOutSuggestion = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.dialogflow.v2.Intent.Message.LinkOutSuggestion").msgclass
|
333
|
+
Intent::Message::ListSelect = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.dialogflow.v2.Intent.Message.ListSelect").msgclass
|
334
|
+
Intent::Message::ListSelect::Item = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.dialogflow.v2.Intent.Message.ListSelect.Item").msgclass
|
335
|
+
Intent::Message::CarouselSelect = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.dialogflow.v2.Intent.Message.CarouselSelect").msgclass
|
336
|
+
Intent::Message::CarouselSelect::Item = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.dialogflow.v2.Intent.Message.CarouselSelect.Item").msgclass
|
337
|
+
Intent::Message::SelectItemInfo = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.dialogflow.v2.Intent.Message.SelectItemInfo").msgclass
|
338
|
+
Intent::Message::MediaContent = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.dialogflow.v2.Intent.Message.MediaContent").msgclass
|
339
|
+
Intent::Message::MediaContent::ResponseMediaObject = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.dialogflow.v2.Intent.Message.MediaContent.ResponseMediaObject").msgclass
|
340
|
+
Intent::Message::MediaContent::ResponseMediaType = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.dialogflow.v2.Intent.Message.MediaContent.ResponseMediaType").enummodule
|
341
|
+
Intent::Message::BrowseCarouselCard = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.dialogflow.v2.Intent.Message.BrowseCarouselCard").msgclass
|
342
|
+
Intent::Message::BrowseCarouselCard::BrowseCarouselCardItem = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.dialogflow.v2.Intent.Message.BrowseCarouselCard.BrowseCarouselCardItem").msgclass
|
343
|
+
Intent::Message::BrowseCarouselCard::BrowseCarouselCardItem::OpenUrlAction = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.dialogflow.v2.Intent.Message.BrowseCarouselCard.BrowseCarouselCardItem.OpenUrlAction").msgclass
|
344
|
+
Intent::Message::BrowseCarouselCard::BrowseCarouselCardItem::OpenUrlAction::UrlTypeHint = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.dialogflow.v2.Intent.Message.BrowseCarouselCard.BrowseCarouselCardItem.OpenUrlAction.UrlTypeHint").enummodule
|
345
|
+
Intent::Message::BrowseCarouselCard::ImageDisplayOptions = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.dialogflow.v2.Intent.Message.BrowseCarouselCard.ImageDisplayOptions").enummodule
|
346
|
+
Intent::Message::TableCard = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.dialogflow.v2.Intent.Message.TableCard").msgclass
|
347
|
+
Intent::Message::ColumnProperties = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.dialogflow.v2.Intent.Message.ColumnProperties").msgclass
|
348
|
+
Intent::Message::ColumnProperties::HorizontalAlignment = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.dialogflow.v2.Intent.Message.ColumnProperties.HorizontalAlignment").enummodule
|
349
|
+
Intent::Message::TableCardRow = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.dialogflow.v2.Intent.Message.TableCardRow").msgclass
|
350
|
+
Intent::Message::TableCardCell = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.dialogflow.v2.Intent.Message.TableCardCell").msgclass
|
351
|
+
Intent::Message::Platform = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.dialogflow.v2.Intent.Message.Platform").enummodule
|
352
|
+
Intent::FollowupIntentInfo = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.dialogflow.v2.Intent.FollowupIntentInfo").msgclass
|
353
|
+
Intent::WebhookState = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.dialogflow.v2.Intent.WebhookState").enummodule
|
354
|
+
ListIntentsRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.dialogflow.v2.ListIntentsRequest").msgclass
|
355
|
+
ListIntentsResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.dialogflow.v2.ListIntentsResponse").msgclass
|
356
|
+
GetIntentRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.dialogflow.v2.GetIntentRequest").msgclass
|
357
|
+
CreateIntentRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.dialogflow.v2.CreateIntentRequest").msgclass
|
358
|
+
UpdateIntentRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.dialogflow.v2.UpdateIntentRequest").msgclass
|
359
|
+
DeleteIntentRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.dialogflow.v2.DeleteIntentRequest").msgclass
|
360
|
+
BatchUpdateIntentsRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.dialogflow.v2.BatchUpdateIntentsRequest").msgclass
|
361
|
+
BatchUpdateIntentsResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.dialogflow.v2.BatchUpdateIntentsResponse").msgclass
|
362
|
+
BatchDeleteIntentsRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.dialogflow.v2.BatchDeleteIntentsRequest").msgclass
|
363
|
+
IntentBatch = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.dialogflow.v2.IntentBatch").msgclass
|
364
|
+
IntentView = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.dialogflow.v2.IntentView").enummodule
|
365
|
+
end
|
366
|
+
end
|
367
|
+
end
|
368
|
+
end
|
@@ -0,0 +1,92 @@
|
|
1
|
+
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
2
|
+
# Source: google/cloud/dialogflow/v2/intent.proto for package 'google.cloud.dialogflow.v2'
|
3
|
+
# Original file comments:
|
4
|
+
# Copyright 2020 Google LLC
|
5
|
+
#
|
6
|
+
# Licensed under the Apache License, Version 2.0 (the "License");
|
7
|
+
# you may not use this file except in compliance with the License.
|
8
|
+
# You may obtain a copy of the License at
|
9
|
+
#
|
10
|
+
# http://www.apache.org/licenses/LICENSE-2.0
|
11
|
+
#
|
12
|
+
# Unless required by applicable law or agreed to in writing, software
|
13
|
+
# distributed under the License is distributed on an "AS IS" BASIS,
|
14
|
+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
15
|
+
# See the License for the specific language governing permissions and
|
16
|
+
# limitations under the License.
|
17
|
+
#
|
18
|
+
|
19
|
+
require 'grpc'
|
20
|
+
require 'google/cloud/dialogflow/v2/intent_pb'
|
21
|
+
|
22
|
+
module Google
|
23
|
+
module Cloud
|
24
|
+
module Dialogflow
|
25
|
+
module V2
|
26
|
+
module Intents
|
27
|
+
# An intent represents a mapping between input from a user and an action to
|
28
|
+
# be taken by your application. When you pass user input to the
|
29
|
+
# [DetectIntent][google.cloud.dialogflow.v2.Sessions.DetectIntent] (or
|
30
|
+
# [StreamingDetectIntent][google.cloud.dialogflow.v2.Sessions.StreamingDetectIntent]) method, the
|
31
|
+
# Dialogflow API analyzes the input and searches
|
32
|
+
# for a matching intent. If no match is found, the Dialogflow API returns a
|
33
|
+
# fallback intent (`is_fallback` = true).
|
34
|
+
#
|
35
|
+
# You can provide additional information for the Dialogflow API to use to
|
36
|
+
# match user input to an intent by adding the following to your intent.
|
37
|
+
#
|
38
|
+
# * **Contexts** - provide additional context for intent analysis. For
|
39
|
+
# example, if an intent is related to an object in your application that
|
40
|
+
# plays music, you can provide a context to determine when to match the
|
41
|
+
# intent if the user input is "turn it off". You can include a context
|
42
|
+
# that matches the intent when there is previous user input of
|
43
|
+
# "play music", and not when there is previous user input of
|
44
|
+
# "turn on the light".
|
45
|
+
#
|
46
|
+
# * **Events** - allow for matching an intent by using an event name
|
47
|
+
# instead of user input. Your application can provide an event name and
|
48
|
+
# related parameters to the Dialogflow API to match an intent. For
|
49
|
+
# example, when your application starts, you can send a welcome event
|
50
|
+
# with a user name parameter to the Dialogflow API to match an intent with
|
51
|
+
# a personalized welcome message for the user.
|
52
|
+
#
|
53
|
+
# * **Training phrases** - provide examples of user input to train the
|
54
|
+
# Dialogflow API agent to better match intents.
|
55
|
+
#
|
56
|
+
# For more information about intents, see the
|
57
|
+
# [Dialogflow
|
58
|
+
# documentation](https://cloud.google.com/dialogflow/docs/intents-overview).
|
59
|
+
class Service
|
60
|
+
|
61
|
+
include GRPC::GenericService
|
62
|
+
|
63
|
+
self.marshal_class_method = :encode
|
64
|
+
self.unmarshal_class_method = :decode
|
65
|
+
self.service_name = 'google.cloud.dialogflow.v2.Intents'
|
66
|
+
|
67
|
+
# Returns the list of all intents in the specified agent.
|
68
|
+
rpc :ListIntents, ListIntentsRequest, ListIntentsResponse
|
69
|
+
# Retrieves the specified intent.
|
70
|
+
rpc :GetIntent, GetIntentRequest, Intent
|
71
|
+
# Creates an intent in the specified agent.
|
72
|
+
rpc :CreateIntent, CreateIntentRequest, Intent
|
73
|
+
# Updates the specified intent.
|
74
|
+
rpc :UpdateIntent, UpdateIntentRequest, Intent
|
75
|
+
# Deletes the specified intent and its direct or indirect followup intents.
|
76
|
+
rpc :DeleteIntent, DeleteIntentRequest, Google::Protobuf::Empty
|
77
|
+
# Updates/Creates multiple intents in the specified agent.
|
78
|
+
#
|
79
|
+
# Operation <response: [BatchUpdateIntentsResponse][google.cloud.dialogflow.v2.BatchUpdateIntentsResponse]>
|
80
|
+
rpc :BatchUpdateIntents, BatchUpdateIntentsRequest, Google::Longrunning::Operation
|
81
|
+
# Deletes intents in the specified agent.
|
82
|
+
#
|
83
|
+
# Operation <response: [google.protobuf.Empty][google.protobuf.Empty]>
|
84
|
+
rpc :BatchDeleteIntents, BatchDeleteIntentsRequest, Google::Longrunning::Operation
|
85
|
+
end
|
86
|
+
|
87
|
+
Stub = Service.rpc_stub_class
|
88
|
+
end
|
89
|
+
end
|
90
|
+
end
|
91
|
+
end
|
92
|
+
end
|