From 3d4f15aa0d8ecbc5339826dbcac55b6fc282941d Mon Sep 17 00:00:00 2001 From: "gcf-owl-bot[bot]" <78513119+gcf-owl-bot[bot]@users.noreply.github.com> Date: Tue, 7 Sep 2021 09:46:53 -0700 Subject: [PATCH] docs: clarified some LRO types docs: fixed some wrong update mask descriptions (#173) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * docs: clarified some LRO types docs: fixed some wrong update mask descriptions PiperOrigin-RevId: 394033461 Source-Link: https://github.com/googleapis/googleapis/commit/aa15f328736501d01fac1d599655c392b5b12a3c Source-Link: https://github.com/googleapis/googleapis-gen/commit/09f16b4e96c14341c51bb78fc39ff35bb4ab4766 * 🦉 Updates from OwlBot See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md Co-authored-by: Owl Bot --- .../google/cloud/dialogflow/cx/v3beta1/agent.proto | 7 +++++++ .../cloud/dialogflow/cx/v3beta1/audio_config.proto | 1 + .../protos/google/cloud/dialogflow/cx/v3beta1/flow.proto | 6 +++--- .../google/cloud/dialogflow/cx/v3beta1/test_case.proto | 9 ++++++++- packages/google-cloud-dialogflow-cx/protos/protos.json | 5 +---- .../src/v3beta1/agents_client.ts | 7 +++++++ .../src/v3beta1/flows_client.ts | 4 ++-- .../src/v3beta1/test_cases_client.ts | 6 ++++++ 8 files changed, 35 insertions(+), 10 deletions(-) diff --git a/packages/google-cloud-dialogflow-cx/protos/google/cloud/dialogflow/cx/v3beta1/agent.proto b/packages/google-cloud-dialogflow-cx/protos/google/cloud/dialogflow/cx/v3beta1/agent.proto index 1318115ebfc..d3e30db0241 100644 --- a/packages/google-cloud-dialogflow-cx/protos/google/cloud/dialogflow/cx/v3beta1/agent.proto +++ b/packages/google-cloud-dialogflow-cx/protos/google/cloud/dialogflow/cx/v3beta1/agent.proto @@ -94,6 +94,13 @@ service Agents { } // Exports the specified agent to a binary file. + // This method is a [long-running + // operation](https://cloud.google.com/dialogflow/cx/docs/how/long-running-operation). + // The returned `Operation` type has the following method-specific fields: + // + // - `metadata`: An empty [Struct + // message](https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#struct) + // - `response`: [ExportAgentResponse][google.cloud.dialogflow.cx.v3beta1.ExportAgentResponse] rpc ExportAgent(ExportAgentRequest) returns (google.longrunning.Operation) { option (google.api.http) = { post: "/v3beta1/{name=projects/*/locations/*/agents/*}:export" diff --git a/packages/google-cloud-dialogflow-cx/protos/google/cloud/dialogflow/cx/v3beta1/audio_config.proto b/packages/google-cloud-dialogflow-cx/protos/google/cloud/dialogflow/cx/v3beta1/audio_config.proto index 078cd9193f2..3814693abd0 100644 --- a/packages/google-cloud-dialogflow-cx/protos/google/cloud/dialogflow/cx/v3beta1/audio_config.proto +++ b/packages/google-cloud-dialogflow-cx/protos/google/cloud/dialogflow/cx/v3beta1/audio_config.proto @@ -19,6 +19,7 @@ package google.cloud.dialogflow.cx.v3beta1; import "google/api/field_behavior.proto"; import "google/api/resource.proto"; import "google/protobuf/duration.proto"; +import "google/protobuf/timestamp.proto"; import "google/api/annotations.proto"; option cc_enable_arenas = true; diff --git a/packages/google-cloud-dialogflow-cx/protos/google/cloud/dialogflow/cx/v3beta1/flow.proto b/packages/google-cloud-dialogflow-cx/protos/google/cloud/dialogflow/cx/v3beta1/flow.proto index 7ec9b4eee53..b6a66ca62e7 100644 --- a/packages/google-cloud-dialogflow-cx/protos/google/cloud/dialogflow/cx/v3beta1/flow.proto +++ b/packages/google-cloud-dialogflow-cx/protos/google/cloud/dialogflow/cx/v3beta1/flow.proto @@ -420,9 +420,9 @@ message UpdateFlowRequest { // Required. The flow to update. Flow flow = 1 [(google.api.field_behavior) = REQUIRED]; - // Required. The mask to control which fields get updated. If `update_mask` is not - // specified, an error will be returned. - google.protobuf.FieldMask update_mask = 2 [(google.api.field_behavior) = REQUIRED]; + // The mask to control which fields get updated. If the mask is not present, + // all fields will be updated. + google.protobuf.FieldMask update_mask = 2; // The language of the following fields in `flow`: // diff --git a/packages/google-cloud-dialogflow-cx/protos/google/cloud/dialogflow/cx/v3beta1/test_case.proto b/packages/google-cloud-dialogflow-cx/protos/google/cloud/dialogflow/cx/v3beta1/test_case.proto index b39565d942a..729ea554bf3 100644 --- a/packages/google-cloud-dialogflow-cx/protos/google/cloud/dialogflow/cx/v3beta1/test_case.proto +++ b/packages/google-cloud-dialogflow-cx/protos/google/cloud/dialogflow/cx/v3beta1/test_case.proto @@ -94,6 +94,12 @@ service TestCases { } // Kicks off a test case run. + // This method is a [long-running + // operation](https://cloud.google.com/dialogflow/cx/docs/how/long-running-operation). + // The returned `Operation` type has the following method-specific fields: + // + // - `metadata`: [RunTestCaseMetadata][google.cloud.dialogflow.cx.v3beta1.RunTestCaseMetadata] + // - `response`: [RunTestCaseResponse][google.cloud.dialogflow.cx.v3beta1.RunTestCaseResponse] rpc RunTestCase(RunTestCaseRequest) returns (google.longrunning.Operation) { option (google.api.http) = { post: "/v3beta1/{name=projects/*/locations/*/agents/*/testCases/*}:run" @@ -284,7 +290,7 @@ message ConversationTurn { // Required. Input only. The diagnostic // [info][Session.DetectIntentResponse.QueryResult.diagnostic_info] - // output for the turn. + // output for the turn. Required to calculate the testing coverage. google.protobuf.Struct diagnostic_info = 6 [ (google.api.field_behavior) = REQUIRED, (google.api.field_behavior) = INPUT_ONLY @@ -635,6 +641,7 @@ message RunTestCaseResponse { } // Metadata returned for the [TestCases.RunTestCase][google.cloud.dialogflow.cx.v3beta1.TestCases.RunTestCase] long running operation. +// This message currently has no fields. message RunTestCaseMetadata { } diff --git a/packages/google-cloud-dialogflow-cx/protos/protos.json b/packages/google-cloud-dialogflow-cx/protos/protos.json index cc9cf3fb77a..f15fa3ac9a9 100644 --- a/packages/google-cloud-dialogflow-cx/protos/protos.json +++ b/packages/google-cloud-dialogflow-cx/protos/protos.json @@ -7942,10 +7942,7 @@ }, "updateMask": { "type": "google.protobuf.FieldMask", - "id": 2, - "options": { - "(google.api.field_behavior)": "REQUIRED" - } + "id": 2 }, "languageCode": { "type": "string", diff --git a/packages/google-cloud-dialogflow-cx/src/v3beta1/agents_client.ts b/packages/google-cloud-dialogflow-cx/src/v3beta1/agents_client.ts index 21845e61068..b7a9546afe3 100644 --- a/packages/google-cloud-dialogflow-cx/src/v3beta1/agents_client.ts +++ b/packages/google-cloud-dialogflow-cx/src/v3beta1/agents_client.ts @@ -1053,6 +1053,13 @@ export class AgentsClient { ): void; /** * Exports the specified agent to a binary file. + * This method is a [long-running + * operation](https://cloud.google.com/dialogflow/cx/docs/how/long-running-operation). + * The returned `Operation` type has the following method-specific fields: + * + * - `metadata`: An empty [Struct + * message](https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#struct) + * - `response`: {@link google.cloud.dialogflow.cx.v3beta1.ExportAgentResponse|ExportAgentResponse} * * @param {Object} request * The request object that will be sent. diff --git a/packages/google-cloud-dialogflow-cx/src/v3beta1/flows_client.ts b/packages/google-cloud-dialogflow-cx/src/v3beta1/flows_client.ts index 9835d69f5dd..80a99f643cd 100644 --- a/packages/google-cloud-dialogflow-cx/src/v3beta1/flows_client.ts +++ b/packages/google-cloud-dialogflow-cx/src/v3beta1/flows_client.ts @@ -803,8 +803,8 @@ export class FlowsClient { * @param {google.cloud.dialogflow.cx.v3beta1.Flow} request.flow * Required. The flow to update. * @param {google.protobuf.FieldMask} request.updateMask - * Required. The mask to control which fields get updated. If `update_mask` is not - * specified, an error will be returned. + * The mask to control which fields get updated. If the mask is not present, + * all fields will be updated. * @param {string} request.languageCode * The language of the following fields in `flow`: * diff --git a/packages/google-cloud-dialogflow-cx/src/v3beta1/test_cases_client.ts b/packages/google-cloud-dialogflow-cx/src/v3beta1/test_cases_client.ts index ead3eaa192b..ef72c2a74a6 100644 --- a/packages/google-cloud-dialogflow-cx/src/v3beta1/test_cases_client.ts +++ b/packages/google-cloud-dialogflow-cx/src/v3beta1/test_cases_client.ts @@ -1090,6 +1090,12 @@ export class TestCasesClient { ): void; /** * Kicks off a test case run. + * This method is a [long-running + * operation](https://cloud.google.com/dialogflow/cx/docs/how/long-running-operation). + * The returned `Operation` type has the following method-specific fields: + * + * - `metadata`: {@link google.cloud.dialogflow.cx.v3beta1.RunTestCaseMetadata|RunTestCaseMetadata} + * - `response`: {@link google.cloud.dialogflow.cx.v3beta1.RunTestCaseResponse|RunTestCaseResponse} * * @param {Object} request * The request object that will be sent.