-
Notifications
You must be signed in to change notification settings - Fork 362
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: added support for custom content types
docs: clarified wording around quota usage PiperOrigin-RevId: 513681148 Source-Link: googleapis/googleapis@3b8869b Source-Link: googleapis/googleapis-gen@c1c7570 Copy-Tag: eyJwIjoiYXBpcy9Hb29nbGUuQ2xvdWQuRGlhbG9nZmxvdy5WMi8uT3dsQm90LnlhbWwiLCJoIjoiYzFjNzU3MGIzMTVmZjJjYzk2NWMxN2EzYzlhODM0YjJhZjE4YWUwYyJ9
- Loading branch information
1 parent
6db57ed
commit 15d6a43
Showing
12 changed files
with
874 additions
and
52 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
63 changes: 63 additions & 0 deletions
63
...neratedSnippets/ConversationProfilesClient.ClearSuggestionFeatureConfig2AsyncSnippet.g.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,63 @@ | ||
// Copyright 2023 Google LLC | ||
// | ||
// Licensed under the Apache License, Version 2.0 (the "License"); | ||
// you may not use this file except in compliance with the License. | ||
// You may obtain a copy of the License at | ||
// | ||
// https://www.apache.org/licenses/LICENSE-2.0 | ||
// | ||
// Unless required by applicable law or agreed to in writing, software | ||
// distributed under the License is distributed on an "AS IS" BASIS, | ||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
// See the License for the specific language governing permissions and | ||
// limitations under the License. | ||
|
||
// Generated code. DO NOT EDIT! | ||
|
||
namespace Google.Cloud.Dialogflow.V2.Snippets | ||
{ | ||
// [START dialogflow_v2_generated_ConversationProfiles_ClearSuggestionFeatureConfig_async_flattened2] | ||
using Google.Cloud.Dialogflow.V2; | ||
using Google.LongRunning; | ||
using System.Threading.Tasks; | ||
|
||
public sealed partial class GeneratedConversationProfilesClientSnippets | ||
{ | ||
/// <summary>Snippet for ClearSuggestionFeatureConfigAsync</summary> | ||
/// <remarks> | ||
/// This snippet has been automatically generated and should be regarded as a code template only. | ||
/// It will require modifications to work: | ||
/// - It may require correct/in-range values for request initialization. | ||
/// - It may require specifying regional endpoints when creating the service client as shown in | ||
/// https://cloud.google.com/dotnet/docs/reference/help/client-configuration#endpoint. | ||
/// </remarks> | ||
public async Task ClearSuggestionFeatureConfig2Async() | ||
{ | ||
// Create client | ||
ConversationProfilesClient conversationProfilesClient = await ConversationProfilesClient.CreateAsync(); | ||
// Initialize request argument(s) | ||
string conversationProfile = ""; | ||
Participant.Types.Role participantRole = Participant.Types.Role.Unspecified; | ||
SuggestionFeature.Types.Type suggestionFeatureType = SuggestionFeature.Types.Type.Unspecified; | ||
// Make the request | ||
Operation<ConversationProfile, ClearSuggestionFeatureConfigOperationMetadata> response = await conversationProfilesClient.ClearSuggestionFeatureConfigAsync(conversationProfile, participantRole, suggestionFeatureType); | ||
|
||
// Poll until the returned long-running operation is complete | ||
Operation<ConversationProfile, ClearSuggestionFeatureConfigOperationMetadata> completedResponse = await response.PollUntilCompletedAsync(); | ||
// Retrieve the operation result | ||
ConversationProfile result = completedResponse.Result; | ||
|
||
// Or get the name of the operation | ||
string operationName = response.Name; | ||
// This name can be stored, then the long-running operation retrieved later by name | ||
Operation<ConversationProfile, ClearSuggestionFeatureConfigOperationMetadata> retrievedResponse = await conversationProfilesClient.PollOnceClearSuggestionFeatureConfigAsync(operationName); | ||
// Check if the retrieved long-running operation has completed | ||
if (retrievedResponse.IsCompleted) | ||
{ | ||
// If it has completed, then access the result | ||
ConversationProfile retrievedResult = retrievedResponse.Result; | ||
} | ||
} | ||
} | ||
// [END dialogflow_v2_generated_ConversationProfiles_ClearSuggestionFeatureConfig_async_flattened2] | ||
} |
62 changes: 62 additions & 0 deletions
62
...V2.GeneratedSnippets/ConversationProfilesClient.ClearSuggestionFeatureConfig2Snippet.g.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,62 @@ | ||
// Copyright 2023 Google LLC | ||
// | ||
// Licensed under the Apache License, Version 2.0 (the "License"); | ||
// you may not use this file except in compliance with the License. | ||
// You may obtain a copy of the License at | ||
// | ||
// https://www.apache.org/licenses/LICENSE-2.0 | ||
// | ||
// Unless required by applicable law or agreed to in writing, software | ||
// distributed under the License is distributed on an "AS IS" BASIS, | ||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
// See the License for the specific language governing permissions and | ||
// limitations under the License. | ||
|
||
// Generated code. DO NOT EDIT! | ||
|
||
namespace Google.Cloud.Dialogflow.V2.Snippets | ||
{ | ||
// [START dialogflow_v2_generated_ConversationProfiles_ClearSuggestionFeatureConfig_sync_flattened2] | ||
using Google.Cloud.Dialogflow.V2; | ||
using Google.LongRunning; | ||
|
||
public sealed partial class GeneratedConversationProfilesClientSnippets | ||
{ | ||
/// <summary>Snippet for ClearSuggestionFeatureConfig</summary> | ||
/// <remarks> | ||
/// This snippet has been automatically generated and should be regarded as a code template only. | ||
/// It will require modifications to work: | ||
/// - It may require correct/in-range values for request initialization. | ||
/// - It may require specifying regional endpoints when creating the service client as shown in | ||
/// https://cloud.google.com/dotnet/docs/reference/help/client-configuration#endpoint. | ||
/// </remarks> | ||
public void ClearSuggestionFeatureConfig2() | ||
{ | ||
// Create client | ||
ConversationProfilesClient conversationProfilesClient = ConversationProfilesClient.Create(); | ||
// Initialize request argument(s) | ||
string conversationProfile = ""; | ||
Participant.Types.Role participantRole = Participant.Types.Role.Unspecified; | ||
SuggestionFeature.Types.Type suggestionFeatureType = SuggestionFeature.Types.Type.Unspecified; | ||
// Make the request | ||
Operation<ConversationProfile, ClearSuggestionFeatureConfigOperationMetadata> response = conversationProfilesClient.ClearSuggestionFeatureConfig(conversationProfile, participantRole, suggestionFeatureType); | ||
|
||
// Poll until the returned long-running operation is complete | ||
Operation<ConversationProfile, ClearSuggestionFeatureConfigOperationMetadata> completedResponse = response.PollUntilCompleted(); | ||
// Retrieve the operation result | ||
ConversationProfile result = completedResponse.Result; | ||
|
||
// Or get the name of the operation | ||
string operationName = response.Name; | ||
// This name can be stored, then the long-running operation retrieved later by name | ||
Operation<ConversationProfile, ClearSuggestionFeatureConfigOperationMetadata> retrievedResponse = conversationProfilesClient.PollOnceClearSuggestionFeatureConfig(operationName); | ||
// Check if the retrieved long-running operation has completed | ||
if (retrievedResponse.IsCompleted) | ||
{ | ||
// If it has completed, then access the result | ||
ConversationProfile retrievedResult = retrievedResponse.Result; | ||
} | ||
} | ||
} | ||
// [END dialogflow_v2_generated_ConversationProfiles_ClearSuggestionFeatureConfig_sync_flattened2] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
63 changes: 63 additions & 0 deletions
63
...GeneratedSnippets/ConversationProfilesClient.SetSuggestionFeatureConfig2AsyncSnippet.g.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,63 @@ | ||
// Copyright 2023 Google LLC | ||
// | ||
// Licensed under the Apache License, Version 2.0 (the "License"); | ||
// you may not use this file except in compliance with the License. | ||
// You may obtain a copy of the License at | ||
// | ||
// https://www.apache.org/licenses/LICENSE-2.0 | ||
// | ||
// Unless required by applicable law or agreed to in writing, software | ||
// distributed under the License is distributed on an "AS IS" BASIS, | ||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
// See the License for the specific language governing permissions and | ||
// limitations under the License. | ||
|
||
// Generated code. DO NOT EDIT! | ||
|
||
namespace Google.Cloud.Dialogflow.V2.Snippets | ||
{ | ||
// [START dialogflow_v2_generated_ConversationProfiles_SetSuggestionFeatureConfig_async_flattened2] | ||
using Google.Cloud.Dialogflow.V2; | ||
using Google.LongRunning; | ||
using System.Threading.Tasks; | ||
|
||
public sealed partial class GeneratedConversationProfilesClientSnippets | ||
{ | ||
/// <summary>Snippet for SetSuggestionFeatureConfigAsync</summary> | ||
/// <remarks> | ||
/// This snippet has been automatically generated and should be regarded as a code template only. | ||
/// It will require modifications to work: | ||
/// - It may require correct/in-range values for request initialization. | ||
/// - It may require specifying regional endpoints when creating the service client as shown in | ||
/// https://cloud.google.com/dotnet/docs/reference/help/client-configuration#endpoint. | ||
/// </remarks> | ||
public async Task SetSuggestionFeatureConfig2Async() | ||
{ | ||
// Create client | ||
ConversationProfilesClient conversationProfilesClient = await ConversationProfilesClient.CreateAsync(); | ||
// Initialize request argument(s) | ||
string conversationProfile = ""; | ||
Participant.Types.Role participantRole = Participant.Types.Role.Unspecified; | ||
HumanAgentAssistantConfig.Types.SuggestionFeatureConfig suggestionFeatureConfig = new HumanAgentAssistantConfig.Types.SuggestionFeatureConfig(); | ||
// Make the request | ||
Operation<ConversationProfile, SetSuggestionFeatureConfigOperationMetadata> response = await conversationProfilesClient.SetSuggestionFeatureConfigAsync(conversationProfile, participantRole, suggestionFeatureConfig); | ||
|
||
// Poll until the returned long-running operation is complete | ||
Operation<ConversationProfile, SetSuggestionFeatureConfigOperationMetadata> completedResponse = await response.PollUntilCompletedAsync(); | ||
// Retrieve the operation result | ||
ConversationProfile result = completedResponse.Result; | ||
|
||
// Or get the name of the operation | ||
string operationName = response.Name; | ||
// This name can be stored, then the long-running operation retrieved later by name | ||
Operation<ConversationProfile, SetSuggestionFeatureConfigOperationMetadata> retrievedResponse = await conversationProfilesClient.PollOnceSetSuggestionFeatureConfigAsync(operationName); | ||
// Check if the retrieved long-running operation has completed | ||
if (retrievedResponse.IsCompleted) | ||
{ | ||
// If it has completed, then access the result | ||
ConversationProfile retrievedResult = retrievedResponse.Result; | ||
} | ||
} | ||
} | ||
// [END dialogflow_v2_generated_ConversationProfiles_SetSuggestionFeatureConfig_async_flattened2] | ||
} |
62 changes: 62 additions & 0 deletions
62
...w.V2.GeneratedSnippets/ConversationProfilesClient.SetSuggestionFeatureConfig2Snippet.g.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,62 @@ | ||
// Copyright 2023 Google LLC | ||
// | ||
// Licensed under the Apache License, Version 2.0 (the "License"); | ||
// you may not use this file except in compliance with the License. | ||
// You may obtain a copy of the License at | ||
// | ||
// https://www.apache.org/licenses/LICENSE-2.0 | ||
// | ||
// Unless required by applicable law or agreed to in writing, software | ||
// distributed under the License is distributed on an "AS IS" BASIS, | ||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
// See the License for the specific language governing permissions and | ||
// limitations under the License. | ||
|
||
// Generated code. DO NOT EDIT! | ||
|
||
namespace Google.Cloud.Dialogflow.V2.Snippets | ||
{ | ||
// [START dialogflow_v2_generated_ConversationProfiles_SetSuggestionFeatureConfig_sync_flattened2] | ||
using Google.Cloud.Dialogflow.V2; | ||
using Google.LongRunning; | ||
|
||
public sealed partial class GeneratedConversationProfilesClientSnippets | ||
{ | ||
/// <summary>Snippet for SetSuggestionFeatureConfig</summary> | ||
/// <remarks> | ||
/// This snippet has been automatically generated and should be regarded as a code template only. | ||
/// It will require modifications to work: | ||
/// - It may require correct/in-range values for request initialization. | ||
/// - It may require specifying regional endpoints when creating the service client as shown in | ||
/// https://cloud.google.com/dotnet/docs/reference/help/client-configuration#endpoint. | ||
/// </remarks> | ||
public void SetSuggestionFeatureConfig2() | ||
{ | ||
// Create client | ||
ConversationProfilesClient conversationProfilesClient = ConversationProfilesClient.Create(); | ||
// Initialize request argument(s) | ||
string conversationProfile = ""; | ||
Participant.Types.Role participantRole = Participant.Types.Role.Unspecified; | ||
HumanAgentAssistantConfig.Types.SuggestionFeatureConfig suggestionFeatureConfig = new HumanAgentAssistantConfig.Types.SuggestionFeatureConfig(); | ||
// Make the request | ||
Operation<ConversationProfile, SetSuggestionFeatureConfigOperationMetadata> response = conversationProfilesClient.SetSuggestionFeatureConfig(conversationProfile, participantRole, suggestionFeatureConfig); | ||
|
||
// Poll until the returned long-running operation is complete | ||
Operation<ConversationProfile, SetSuggestionFeatureConfigOperationMetadata> completedResponse = response.PollUntilCompleted(); | ||
// Retrieve the operation result | ||
ConversationProfile result = completedResponse.Result; | ||
|
||
// Or get the name of the operation | ||
string operationName = response.Name; | ||
// This name can be stored, then the long-running operation retrieved later by name | ||
Operation<ConversationProfile, SetSuggestionFeatureConfigOperationMetadata> retrievedResponse = conversationProfilesClient.PollOnceSetSuggestionFeatureConfig(operationName); | ||
// Check if the retrieved long-running operation has completed | ||
if (retrievedResponse.IsCompleted) | ||
{ | ||
// If it has completed, then access the result | ||
ConversationProfile retrievedResult = retrievedResponse.Result; | ||
} | ||
} | ||
} | ||
// [END dialogflow_v2_generated_ConversationProfiles_SetSuggestionFeatureConfig_sync_flattened2] | ||
} |
Oops, something went wrong.