Skip to content

Commit 529c07a

Browse files
Google APIscopybara-github
authored andcommitted
feat: ResponseMessage proto contains channel information
docs: updated go library package PiperOrigin-RevId: 501638939
1 parent 914dc31 commit 529c07a

22 files changed

Lines changed: 1153 additions & 753 deletions

google/cloud/dialogflow/cx/v3/BUILD.bazel

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -176,7 +176,7 @@ load(
176176
go_proto_library(
177177
name = "cx_go_proto",
178178
compilers = ["@io_bazel_rules_go//proto:go_grpc"],
179-
importpath = "google.golang.org/genproto/googleapis/cloud/dialogflow/cx/v3",
179+
importpath = "cloud.google.com/go/dialogflow/cx/apiv3/cxpb",
180180
protos = [":cx_proto"],
181181
deps = [
182182
"//google/api:annotations_go_proto",
@@ -192,6 +192,7 @@ go_gapic_library(
192192
grpc_service_config = "dialogflow_grpc_service_config.json",
193193
importpath = "cloud.google.com/go/dialogflow/cx/apiv3;cx",
194194
metadata = True,
195+
release_level = "beta",
195196
rest_numeric_enums = True,
196197
service_yaml = "dialogflow_v3.yaml",
197198
transport = "grpc+rest",

google/cloud/dialogflow/cx/v3/advanced_settings.proto

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ import "google/api/field_behavior.proto";
2020

2121
option cc_enable_arenas = true;
2222
option csharp_namespace = "Google.Cloud.Dialogflow.Cx.V3";
23-
option go_package = "google.golang.org/genproto/googleapis/cloud/dialogflow/cx/v3;cx";
23+
option go_package = "cloud.google.com/go/dialogflow/cx/apiv3/cxpb;cxpb";
2424
option java_multiple_files = true;
2525
option java_outer_classname = "AdvancedSettingsProto";
2626
option java_package = "com.google.cloud.dialogflow.cx.v3";

google/cloud/dialogflow/cx/v3/agent.proto

Lines changed: 63 additions & 39 deletions
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ import "google/protobuf/field_mask.proto";
2828

2929
option cc_enable_arenas = true;
3030
option csharp_namespace = "Google.Cloud.Dialogflow.Cx.V3";
31-
option go_package = "google.golang.org/genproto/googleapis/cloud/dialogflow/cx/v3;cx";
31+
option go_package = "cloud.google.com/go/dialogflow/cx/apiv3/cxpb;cxpb";
3232
option java_multiple_files = true;
3333
option java_outer_classname = "AgentProto";
3434
option java_package = "com.google.cloud.dialogflow.cx.v3";
@@ -100,7 +100,8 @@ service Agents {
100100
//
101101
// - `metadata`: An empty [Struct
102102
// message](https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#struct)
103-
// - `response`: [ExportAgentResponse][google.cloud.dialogflow.cx.v3.ExportAgentResponse]
103+
// - `response`:
104+
// [ExportAgentResponse][google.cloud.dialogflow.cx.v3.ExportAgentResponse]
104105
rpc ExportAgent(ExportAgentRequest) returns (google.longrunning.Operation) {
105106
option (google.api.http) = {
106107
post: "/v3/{name=projects/*/locations/*/agents/*}:export"
@@ -152,7 +153,8 @@ service Agents {
152153

153154
// Gets the latest agent validation result. Agent validation is performed
154155
// when ValidateAgent is called.
155-
rpc GetAgentValidationResult(GetAgentValidationResultRequest) returns (AgentValidationResult) {
156+
rpc GetAgentValidationResult(GetAgentValidationResultRequest)
157+
returns (AgentValidationResult) {
156158
option (google.api.http) = {
157159
get: "/v3/{name=projects/*/locations/*/agents/*/validationResult}"
158160
};
@@ -171,17 +173,24 @@ message SpeechToTextSettings {
171173
// in your app, product, or service to determine user intent and respond to the
172174
// user in a natural way.
173175
//
174-
// After you create an agent, you can add [Intents][google.cloud.dialogflow.cx.v3.Intent],
175-
// [Entity Types][google.cloud.dialogflow.cx.v3.EntityType], [Flows][google.cloud.dialogflow.cx.v3.Flow], [Fulfillments][google.cloud.dialogflow.cx.v3.Fulfillment],
176-
// [Webhooks][google.cloud.dialogflow.cx.v3.Webhook], and so on to manage the conversation flows..
176+
// After you create an agent, you can add
177+
// [Intents][google.cloud.dialogflow.cx.v3.Intent], [Entity
178+
// Types][google.cloud.dialogflow.cx.v3.EntityType],
179+
// [Flows][google.cloud.dialogflow.cx.v3.Flow],
180+
// [Fulfillments][google.cloud.dialogflow.cx.v3.Fulfillment],
181+
// [Webhooks][google.cloud.dialogflow.cx.v3.Webhook], and so on to manage the
182+
// conversation flows..
177183
message Agent {
178184
option (google.api.resource) = {
179185
type: "dialogflow.googleapis.com/Agent"
180186
pattern: "projects/{project}/locations/{location}/agents/{agent}"
181187
};
182188

183189
// The unique identifier of the agent.
184-
// Required for the [Agents.UpdateAgent][google.cloud.dialogflow.cx.v3.Agents.UpdateAgent] method. [Agents.CreateAgent][google.cloud.dialogflow.cx.v3.Agents.CreateAgent]
190+
// Required for the
191+
// [Agents.UpdateAgent][google.cloud.dialogflow.cx.v3.Agents.UpdateAgent]
192+
// method.
193+
// [Agents.CreateAgent][google.cloud.dialogflow.cx.v3.Agents.CreateAgent]
185194
// populates the name automatically.
186195
// Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent ID>`.
187196
string name = 1;
@@ -193,7 +202,9 @@ message Agent {
193202
// See [Language
194203
// Support](https://cloud.google.com/dialogflow/cx/docs/reference/language)
195204
// for a list of the currently supported language codes.
196-
// This field cannot be set by the [Agents.UpdateAgent][google.cloud.dialogflow.cx.v3.Agents.UpdateAgent] method.
205+
// This field cannot be set by the
206+
// [Agents.UpdateAgent][google.cloud.dialogflow.cx.v3.Agents.UpdateAgent]
207+
// method.
197208
string default_language_code = 3 [
198209
(google.api.field_behavior) = REQUIRED,
199210
(google.api.field_behavior) = IMMUTABLE
@@ -221,27 +232,26 @@ message Agent {
221232
// Speech recognition related settings.
222233
SpeechToTextSettings speech_to_text_settings = 13;
223234

224-
// Immutable. Name of the start flow in this agent. A start flow will be automatically
225-
// created when the agent is created, and can only be deleted by deleting the
226-
// agent.
227-
// Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
228-
// ID>/flows/<Flow ID>`.
235+
// Immutable. Name of the start flow in this agent. A start flow will be
236+
// automatically created when the agent is created, and can only be deleted by
237+
// deleting the agent. Format: `projects/<Project ID>/locations/<Location
238+
// ID>/agents/<Agent ID>/flows/<Flow ID>`.
229239
string start_flow = 16 [
230240
(google.api.field_behavior) = IMMUTABLE,
231-
(google.api.resource_reference) = {
232-
type: "dialogflow.googleapis.com/Flow"
233-
}
241+
(google.api.resource_reference) = { type: "dialogflow.googleapis.com/Flow" }
234242
];
235243

236-
// Name of the [SecuritySettings][google.cloud.dialogflow.cx.v3.SecuritySettings] reference for the agent.
237-
// Format: `projects/<Project ID>/locations/<Location
244+
// Name of the
245+
// [SecuritySettings][google.cloud.dialogflow.cx.v3.SecuritySettings]
246+
// reference for the agent. Format: `projects/<Project ID>/locations/<Location
238247
// ID>/securitySettings/<Security Settings ID>`.
239248
string security_settings = 17 [(google.api.resource_reference) = {
240-
type: "dialogflow.googleapis.com/SecuritySettings"
241-
}];
249+
type: "dialogflow.googleapis.com/SecuritySettings"
250+
}];
242251

243252
// Indicates if stackdriver logging is enabled for the agent.
244-
// Please use [agent.advanced_settings][google.cloud.dialogflow.cx.v3.AdvancedSettings.LoggingSettings]
253+
// Please use
254+
// [agent.advanced_settings][google.cloud.dialogflow.cx.v3.AdvancedSettings.LoggingSettings]
245255
// instead.
246256
bool enable_stackdriver_logging = 18 [deprecated = true];
247257

@@ -258,7 +268,8 @@ message Agent {
258268
AdvancedSettings advanced_settings = 22;
259269
}
260270

261-
// The request message for [Agents.ListAgents][google.cloud.dialogflow.cx.v3.Agents.ListAgents].
271+
// The request message for
272+
// [Agents.ListAgents][google.cloud.dialogflow.cx.v3.Agents.ListAgents].
262273
message ListAgentsRequest {
263274
// Required. The location to list all agents for.
264275
// Format: `projects/<Project ID>/locations/<Location ID>`.
@@ -277,7 +288,8 @@ message ListAgentsRequest {
277288
string page_token = 3;
278289
}
279290

280-
// The response message for [Agents.ListAgents][google.cloud.dialogflow.cx.v3.Agents.ListAgents].
291+
// The response message for
292+
// [Agents.ListAgents][google.cloud.dialogflow.cx.v3.Agents.ListAgents].
281293
message ListAgentsResponse {
282294
// The list of agents. There will be a maximum number of items returned based
283295
// on the page_size field in the request.
@@ -288,7 +300,8 @@ message ListAgentsResponse {
288300
string next_page_token = 2;
289301
}
290302

291-
// The request message for [Agents.GetAgent][google.cloud.dialogflow.cx.v3.Agents.GetAgent].
303+
// The request message for
304+
// [Agents.GetAgent][google.cloud.dialogflow.cx.v3.Agents.GetAgent].
292305
message GetAgentRequest {
293306
// Required. The name of the agent.
294307
// Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent ID>`.
@@ -300,7 +313,8 @@ message GetAgentRequest {
300313
];
301314
}
302315

303-
// The request message for [Agents.CreateAgent][google.cloud.dialogflow.cx.v3.Agents.CreateAgent].
316+
// The request message for
317+
// [Agents.CreateAgent][google.cloud.dialogflow.cx.v3.Agents.CreateAgent].
304318
message CreateAgentRequest {
305319
// Required. The location to create a agent for.
306320
// Format: `projects/<Project ID>/locations/<Location ID>`.
@@ -315,7 +329,8 @@ message CreateAgentRequest {
315329
Agent agent = 2 [(google.api.field_behavior) = REQUIRED];
316330
}
317331

318-
// The request message for [Agents.UpdateAgent][google.cloud.dialogflow.cx.v3.Agents.UpdateAgent].
332+
// The request message for
333+
// [Agents.UpdateAgent][google.cloud.dialogflow.cx.v3.Agents.UpdateAgent].
319334
message UpdateAgentRequest {
320335
// Required. The agent to update.
321336
Agent agent = 1 [(google.api.field_behavior) = REQUIRED];
@@ -325,7 +340,8 @@ message UpdateAgentRequest {
325340
google.protobuf.FieldMask update_mask = 2;
326341
}
327342

328-
// The request message for [Agents.DeleteAgent][google.cloud.dialogflow.cx.v3.Agents.DeleteAgent].
343+
// The request message for
344+
// [Agents.DeleteAgent][google.cloud.dialogflow.cx.v3.Agents.DeleteAgent].
329345
message DeleteAgentRequest {
330346
// Required. The name of the agent to delete.
331347
// Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent ID>`.
@@ -337,7 +353,8 @@ message DeleteAgentRequest {
337353
];
338354
}
339355

340-
// The request message for [Agents.ExportAgent][google.cloud.dialogflow.cx.v3.Agents.ExportAgent].
356+
// The request message for
357+
// [Agents.ExportAgent][google.cloud.dialogflow.cx.v3.Agents.ExportAgent].
341358
message ExportAgentRequest {
342359
// Data format of the exported agent.
343360
enum DataFormat {
@@ -357,10 +374,10 @@ message ExportAgentRequest {
357374
}
358375
];
359376

360-
// Optional. The [Google Cloud Storage](https://cloud.google.com/storage/docs/) URI to
361-
// export the agent to. The format of this URI must be
362-
// `gs://<bucket-name>/<object-name>`.
363-
// If left unspecified, the serialized agent is returned inline.
377+
// Optional. The [Google Cloud
378+
// Storage](https://cloud.google.com/storage/docs/) URI to export the agent
379+
// to. The format of this URI must be `gs://<bucket-name>/<object-name>`. If
380+
// left unspecified, the serialized agent is returned inline.
364381
//
365382
// Dialogflow performs a write operation for the Cloud Storage object
366383
// on the caller's behalf, so your request authentication must
@@ -369,7 +386,8 @@ message ExportAgentRequest {
369386
// control](https://cloud.google.com/dialogflow/cx/docs/concept/access-control#storage).
370387
string agent_uri = 2 [(google.api.field_behavior) = OPTIONAL];
371388

372-
// Optional. The data format of the exported agent. If not specified, `BLOB` is assumed.
389+
// Optional. The data format of the exported agent. If not specified, `BLOB`
390+
// is assumed.
373391
DataFormat data_format = 3 [(google.api.field_behavior) = OPTIONAL];
374392

375393
// Optional. Environment name. If not set, draft environment is assumed.
@@ -383,20 +401,23 @@ message ExportAgentRequest {
383401
];
384402
}
385403

386-
// The response message for [Agents.ExportAgent][google.cloud.dialogflow.cx.v3.Agents.ExportAgent].
404+
// The response message for
405+
// [Agents.ExportAgent][google.cloud.dialogflow.cx.v3.Agents.ExportAgent].
387406
message ExportAgentResponse {
388407
// The exported agent.
389408
oneof agent {
390409
// The URI to a file containing the exported agent. This field is populated
391-
// only if `agent_uri` is specified in [ExportAgentRequest][google.cloud.dialogflow.cx.v3.ExportAgentRequest].
410+
// only if `agent_uri` is specified in
411+
// [ExportAgentRequest][google.cloud.dialogflow.cx.v3.ExportAgentRequest].
392412
string agent_uri = 1;
393413

394414
// Uncompressed raw byte content for agent.
395415
bytes agent_content = 2;
396416
}
397417
}
398418

399-
// The request message for [Agents.RestoreAgent][google.cloud.dialogflow.cx.v3.Agents.RestoreAgent].
419+
// The request message for
420+
// [Agents.RestoreAgent][google.cloud.dialogflow.cx.v3.Agents.RestoreAgent].
400421
message RestoreAgentRequest {
401422
// Restore option.
402423
enum RestoreOption {
@@ -443,7 +464,8 @@ message RestoreAgentRequest {
443464
RestoreOption restore_option = 5;
444465
}
445466

446-
// The request message for [Agents.ValidateAgent][google.cloud.dialogflow.cx.v3.Agents.ValidateAgent].
467+
// The request message for
468+
// [Agents.ValidateAgent][google.cloud.dialogflow.cx.v3.Agents.ValidateAgent].
447469
message ValidateAgentRequest {
448470
// Required. The agent to validate.
449471
// Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent ID>`.
@@ -458,7 +480,8 @@ message ValidateAgentRequest {
458480
string language_code = 2;
459481
}
460482

461-
// The request message for [Agents.GetAgentValidationResult][google.cloud.dialogflow.cx.v3.Agents.GetAgentValidationResult].
483+
// The request message for
484+
// [Agents.GetAgentValidationResult][google.cloud.dialogflow.cx.v3.Agents.GetAgentValidationResult].
462485
message GetAgentValidationResultRequest {
463486
// Required. The agent name.
464487
// Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
@@ -474,7 +497,8 @@ message GetAgentValidationResultRequest {
474497
string language_code = 2;
475498
}
476499

477-
// The response message for [Agents.GetAgentValidationResult][google.cloud.dialogflow.cx.v3.Agents.GetAgentValidationResult].
500+
// The response message for
501+
// [Agents.GetAgentValidationResult][google.cloud.dialogflow.cx.v3.Agents.GetAgentValidationResult].
478502
message AgentValidationResult {
479503
option (google.api.resource) = {
480504
type: "dialogflow.googleapis.com/AgentValidationResult"

google/cloud/dialogflow/cx/v3/audio_config.proto

Lines changed: 19 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ import "google/protobuf/duration.proto";
2222

2323
option cc_enable_arenas = true;
2424
option csharp_namespace = "Google.Cloud.Dialogflow.Cx.V3";
25-
option go_package = "google.golang.org/genproto/googleapis/cloud/dialogflow/cx/v3;cx";
25+
option go_package = "cloud.google.com/go/dialogflow/cx/apiv3/cxpb;cxpb";
2626
option java_multiple_files = true;
2727
option java_outer_classname = "AudioConfigProto";
2828
option java_package = "com.google.cloud.dialogflow.cx.v3";
@@ -82,7 +82,8 @@ enum AudioEncoding {
8282
AUDIO_ENCODING_SPEEX_WITH_HEADER_BYTE = 7;
8383
}
8484

85-
// Variant of the specified [Speech model][google.cloud.dialogflow.cx.v3.InputAudioConfig.model] to use.
85+
// Variant of the specified [Speech
86+
// model][google.cloud.dialogflow.cx.v3.InputAudioConfig.model] to use.
8687
//
8788
// See the [Cloud Speech
8889
// documentation](https://cloud.google.com/speech-to-text/docs/enhanced-models)
@@ -111,8 +112,8 @@ enum SpeechModelVariant {
111112
// Use an enhanced model variant:
112113
//
113114
// * If an enhanced variant does not exist for the given
114-
// [model][google.cloud.dialogflow.cx.v3.InputAudioConfig.model] and request language, Dialogflow falls
115-
// back to the standard variant.
115+
// [model][google.cloud.dialogflow.cx.v3.InputAudioConfig.model] and request
116+
// language, Dialogflow falls back to the standard variant.
116117
//
117118
// The [Cloud Speech
118119
// documentation](https://cloud.google.com/speech-to-text/docs/enhanced-models)
@@ -162,10 +163,12 @@ message InputAudioConfig {
162163
// more details.
163164
int32 sample_rate_hertz = 2;
164165

165-
// Optional. If `true`, Dialogflow returns [SpeechWordInfo][google.cloud.dialogflow.cx.v3.SpeechWordInfo] in
166-
// [StreamingRecognitionResult][google.cloud.dialogflow.cx.v3.StreamingRecognitionResult] with information about the recognized speech
167-
// words, e.g. start and end time offsets. If false or unspecified, Speech
168-
// doesn't return any word-level information.
166+
// Optional. If `true`, Dialogflow returns
167+
// [SpeechWordInfo][google.cloud.dialogflow.cx.v3.SpeechWordInfo] in
168+
// [StreamingRecognitionResult][google.cloud.dialogflow.cx.v3.StreamingRecognitionResult]
169+
// with information about the recognized speech words, e.g. start and end time
170+
// offsets. If false or unspecified, Speech doesn't return any word-level
171+
// information.
169172
bool enable_word_info = 13;
170173

171174
// Optional. A list of strings containing words and phrases that the speech
@@ -189,7 +192,8 @@ message InputAudioConfig {
189192
// for more details.
190193
string model = 7;
191194

192-
// Optional. Which variant of the [Speech model][google.cloud.dialogflow.cx.v3.InputAudioConfig.model] to use.
195+
// Optional. Which variant of the [Speech
196+
// model][google.cloud.dialogflow.cx.v3.InputAudioConfig.model] to use.
193197
SpeechModelVariant model_variant = 10;
194198

195199
// Optional. If `false` (default), recognition does not cease until the
@@ -232,10 +236,10 @@ message VoiceSelectionParams {
232236

233237
// Optional. The preferred gender of the voice. If not set, the service will
234238
// choose a voice based on the other parameters such as language_code and
235-
// [name][google.cloud.dialogflow.cx.v3.VoiceSelectionParams.name]. Note that this is only a preference, not requirement. If a
236-
// voice of the appropriate gender is not available, the synthesizer
237-
// substitutes a voice with a different gender rather than failing the
238-
// request.
239+
// [name][google.cloud.dialogflow.cx.v3.VoiceSelectionParams.name]. Note that
240+
// this is only a preference, not requirement. If a voice of the appropriate
241+
// gender is not available, the synthesizer substitutes a voice with a
242+
// different gender rather than failing the request.
239243
SsmlVoiceGender ssml_gender = 2;
240244
}
241245

@@ -299,7 +303,8 @@ enum OutputAudioEncoding {
299303
// Instructs the speech synthesizer how to generate the output audio content.
300304
message OutputAudioConfig {
301305
// Required. Audio encoding of the synthesized audio content.
302-
OutputAudioEncoding audio_encoding = 1 [(google.api.field_behavior) = REQUIRED];
306+
OutputAudioEncoding audio_encoding = 1
307+
[(google.api.field_behavior) = REQUIRED];
303308

304309
// Optional. The synthesis sample rate (in hertz) for this audio. If not
305310
// provided, then the synthesizer will use the default sample rate based on

0 commit comments

Comments
 (0)