public sealed class ConversationsClientImpl : ConversationsClient
Reference documentation and code samples for the Google Cloud Dialogflow v2beta1 API class ConversationsClientImpl.
Conversations client wrapper implementation, for convenient use.
Namespace
Google.Cloud.Dialogflow.V2Beta1Assembly
Google.Cloud.Dialogflow.V2Beta1.dll
Remarks
Service for managing [Conversations][google.cloud.dialogflow.v2beta1.Conversation].
Constructors
ConversationsClientImpl(ConversationsClient, ConversationsSettings, ILogger)
public ConversationsClientImpl(Conversations.ConversationsClient grpcClient, ConversationsSettings settings, ILogger logger)
Constructs a client wrapper for the Conversations service, with the specified gRPC client and settings.
Parameters | |
---|---|
Name | Description |
grpcClient | ConversationsConversationsClient The underlying gRPC client. |
settings | ConversationsSettings The base ConversationsSettings used within this client. |
logger | ILogger Optional ILogger to use within this client. |
Properties
GrpcClient
public override Conversations.ConversationsClient GrpcClient { get; }
The underlying gRPC Conversations client
Property Value | |
---|---|
Type | Description |
ConversationsConversationsClient |
LocationsClient
public override LocationsClient LocationsClient { get; }
The LocationsClient associated with this client.
Property Value | |
---|---|
Type | Description |
LocationsClient |
Methods
BatchCreateMessages(BatchCreateMessagesRequest, CallSettings)
public override BatchCreateMessagesResponse BatchCreateMessages(BatchCreateMessagesRequest request, CallSettings callSettings = null)
Batch ingests messages to conversation. Customers can use this RPC to ingest historical messages to conversation.
Parameters | |
---|---|
Name | Description |
request | BatchCreateMessagesRequest The request object containing all of the parameters for the API call. |
callSettings | CallSettings If not null, applies overrides to this RPC call. |
Returns | |
---|---|
Type | Description |
BatchCreateMessagesResponse | The RPC response. |
BatchCreateMessagesAsync(BatchCreateMessagesRequest, CallSettings)
public override Task<BatchCreateMessagesResponse> BatchCreateMessagesAsync(BatchCreateMessagesRequest request, CallSettings callSettings = null)
Batch ingests messages to conversation. Customers can use this RPC to ingest historical messages to conversation.
Parameters | |
---|---|
Name | Description |
request | BatchCreateMessagesRequest The request object containing all of the parameters for the API call. |
callSettings | CallSettings If not null, applies overrides to this RPC call. |
Returns | |
---|---|
Type | Description |
TaskBatchCreateMessagesResponse | A Task containing the RPC response. |
CompleteConversation(CompleteConversationRequest, CallSettings)
public override Conversation CompleteConversation(CompleteConversationRequest request, CallSettings callSettings = null)
Completes the specified conversation. Finished conversations are purged from the database after 30 days.
Parameters | |
---|---|
Name | Description |
request | CompleteConversationRequest The request object containing all of the parameters for the API call. |
callSettings | CallSettings If not null, applies overrides to this RPC call. |
Returns | |
---|---|
Type | Description |
Conversation | The RPC response. |
CompleteConversationAsync(CompleteConversationRequest, CallSettings)
public override Task<Conversation> CompleteConversationAsync(CompleteConversationRequest request, CallSettings callSettings = null)
Completes the specified conversation. Finished conversations are purged from the database after 30 days.
Parameters | |
---|---|
Name | Description |
request | CompleteConversationRequest The request object containing all of the parameters for the API call. |
callSettings | CallSettings If not null, applies overrides to this RPC call. |
Returns | |
---|---|
Type | Description |
TaskConversation | A Task containing the RPC response. |
CreateConversation(CreateConversationRequest, CallSettings)
public override Conversation CreateConversation(CreateConversationRequest request, CallSettings callSettings = null)
Creates a new conversation. Conversations are auto-completed after 24 hours.
Conversation Lifecycle: There are two stages during a conversation: Automated Agent Stage and Assist Stage.
For Automated Agent Stage, there will be a dialogflow agent responding to user queries.
For Assist Stage, there's no dialogflow agent responding to user queries. But we will provide suggestions which are generated from conversation.
If
[Conversation.conversation_profile][google.cloud.dialogflow.v2beta1.Conversation.conversation_profile]
is configured for a dialogflow agent, conversation will start from
Automated Agent Stage
, otherwise, it will start from Assist Stage
. And
during Automated Agent Stage
, once an
[Intent][google.cloud.dialogflow.v2beta1.Intent] with
[Intent.live_agent_handoff][google.cloud.dialogflow.v2beta1.Intent.live_agent_handoff]
is triggered, conversation will transfer to Assist Stage.
Parameters | |
---|---|
Name | Description |
request | CreateConversationRequest The request object containing all of the parameters for the API call. |
callSettings | CallSettings If not null, applies overrides to this RPC call. |
Returns | |
---|---|
Type | Description |
Conversation | The RPC response. |
CreateConversationAsync(CreateConversationRequest, CallSettings)
public override Task<Conversation> CreateConversationAsync(CreateConversationRequest request, CallSettings callSettings = null)
Creates a new conversation. Conversations are auto-completed after 24 hours.
Conversation Lifecycle: There are two stages during a conversation: Automated Agent Stage and Assist Stage.
For Automated Agent Stage, there will be a dialogflow agent responding to user queries.
For Assist Stage, there's no dialogflow agent responding to user queries. But we will provide suggestions which are generated from conversation.
If
[Conversation.conversation_profile][google.cloud.dialogflow.v2beta1.Conversation.conversation_profile]
is configured for a dialogflow agent, conversation will start from
Automated Agent Stage
, otherwise, it will start from Assist Stage
. And
during Automated Agent Stage
, once an
[Intent][google.cloud.dialogflow.v2beta1.Intent] with
[Intent.live_agent_handoff][google.cloud.dialogflow.v2beta1.Intent.live_agent_handoff]
is triggered, conversation will transfer to Assist Stage.
Parameters | |
---|---|
Name | Description |
request | CreateConversationRequest The request object containing all of the parameters for the API call. |
callSettings | CallSettings If not null, applies overrides to this RPC call. |
Returns | |
---|---|
Type | Description |
TaskConversation | A Task containing the RPC response. |
GenerateStatelessSummary(GenerateStatelessSummaryRequest, CallSettings)
public override GenerateStatelessSummaryResponse GenerateStatelessSummary(GenerateStatelessSummaryRequest request, CallSettings callSettings = null)
Generates and returns a summary for a conversation that does not have a resource created for it.
Parameters | |
---|---|
Name | Description |
request | GenerateStatelessSummaryRequest The request object containing all of the parameters for the API call. |
callSettings | CallSettings If not null, applies overrides to this RPC call. |
Returns | |
---|---|
Type | Description |
GenerateStatelessSummaryResponse | The RPC response. |
GenerateStatelessSummaryAsync(GenerateStatelessSummaryRequest, CallSettings)
public override Task<GenerateStatelessSummaryResponse> GenerateStatelessSummaryAsync(GenerateStatelessSummaryRequest request, CallSettings callSettings = null)
Generates and returns a summary for a conversation that does not have a resource created for it.
Parameters | |
---|---|
Name | Description |
request | GenerateStatelessSummaryRequest The request object containing all of the parameters for the API call. |
callSettings | CallSettings If not null, applies overrides to this RPC call. |
Returns | |
---|---|
Type | Description |
TaskGenerateStatelessSummaryResponse | A Task containing the RPC response. |
GetConversation(GetConversationRequest, CallSettings)
public override Conversation GetConversation(GetConversationRequest request, CallSettings callSettings = null)
Retrieves the specific conversation.
Parameters | |
---|---|
Name | Description |
request | GetConversationRequest The request object containing all of the parameters for the API call. |
callSettings | CallSettings If not null, applies overrides to this RPC call. |
Returns | |
---|---|
Type | Description |
Conversation | The RPC response. |
GetConversationAsync(GetConversationRequest, CallSettings)
public override Task<Conversation> GetConversationAsync(GetConversationRequest request, CallSettings callSettings = null)
Retrieves the specific conversation.
Parameters | |
---|---|
Name | Description |
request | GetConversationRequest The request object containing all of the parameters for the API call. |
callSettings | CallSettings If not null, applies overrides to this RPC call. |
Returns | |
---|---|
Type | Description |
TaskConversation | A Task containing the RPC response. |
ListConversations(ListConversationsRequest, CallSettings)
public override PagedEnumerable<ListConversationsResponse, Conversation> ListConversations(ListConversationsRequest request, CallSettings callSettings = null)
Returns the list of all conversations in the specified project.
Parameters | |
---|---|
Name | Description |
request | ListConversationsRequest The request object containing all of the parameters for the API call. |
callSettings | CallSettings If not null, applies overrides to this RPC call. |
Returns | |
---|---|
Type | Description |
PagedEnumerableListConversationsResponseConversation | A pageable sequence of Conversation resources. |
ListConversationsAsync(ListConversationsRequest, CallSettings)
public override PagedAsyncEnumerable<ListConversationsResponse, Conversation> ListConversationsAsync(ListConversationsRequest request, CallSettings callSettings = null)
Returns the list of all conversations in the specified project.
Parameters | |
---|---|
Name | Description |
request | ListConversationsRequest The request object containing all of the parameters for the API call. |
callSettings | CallSettings If not null, applies overrides to this RPC call. |
Returns | |
---|---|
Type | Description |
PagedAsyncEnumerableListConversationsResponseConversation | A pageable asynchronous sequence of Conversation resources. |
ListMessages(ListMessagesRequest, CallSettings)
public override PagedEnumerable<ListMessagesResponse, Message> ListMessages(ListMessagesRequest request, CallSettings callSettings = null)
Lists messages that belong to a given conversation.
messages
are ordered by create_time
in descending order. To fetch
updates without duplication, send request with filter
create_time_epoch_microseconds >
[first item's create_time of previous request]
and empty page_token.
Parameters | |
---|---|
Name | Description |
request | ListMessagesRequest The request object containing all of the parameters for the API call. |
callSettings | CallSettings If not null, applies overrides to this RPC call. |
Returns | |
---|---|
Type | Description |
PagedEnumerableListMessagesResponseMessage | A pageable sequence of Message resources. |
ListMessagesAsync(ListMessagesRequest, CallSettings)
public override PagedAsyncEnumerable<ListMessagesResponse, Message> ListMessagesAsync(ListMessagesRequest request, CallSettings callSettings = null)
Lists messages that belong to a given conversation.
messages
are ordered by create_time
in descending order. To fetch
updates without duplication, send request with filter
create_time_epoch_microseconds >
[first item's create_time of previous request]
and empty page_token.
Parameters | |
---|---|
Name | Description |
request | ListMessagesRequest The request object containing all of the parameters for the API call. |
callSettings | CallSettings If not null, applies overrides to this RPC call. |
Returns | |
---|---|
Type | Description |
PagedAsyncEnumerableListMessagesResponseMessage | A pageable asynchronous sequence of Message resources. |
SearchKnowledge(SearchKnowledgeRequest, CallSettings)
public override SearchKnowledgeResponse SearchKnowledge(SearchKnowledgeRequest request, CallSettings callSettings = null)
Get answers for the given query based on knowledge documents.
Parameters | |
---|---|
Name | Description |
request | SearchKnowledgeRequest The request object containing all of the parameters for the API call. |
callSettings | CallSettings If not null, applies overrides to this RPC call. |
Returns | |
---|---|
Type | Description |
SearchKnowledgeResponse | The RPC response. |
SearchKnowledgeAsync(SearchKnowledgeRequest, CallSettings)
public override Task<SearchKnowledgeResponse> SearchKnowledgeAsync(SearchKnowledgeRequest request, CallSettings callSettings = null)
Get answers for the given query based on knowledge documents.
Parameters | |
---|---|
Name | Description |
request | SearchKnowledgeRequest The request object containing all of the parameters for the API call. |
callSettings | CallSettings If not null, applies overrides to this RPC call. |
Returns | |
---|---|
Type | Description |
TaskSearchKnowledgeResponse | A Task containing the RPC response. |
SuggestConversationSummary(SuggestConversationSummaryRequest, CallSettings)
public override SuggestConversationSummaryResponse SuggestConversationSummary(SuggestConversationSummaryRequest request, CallSettings callSettings = null)
Suggest summary for a conversation based on specific historical messages. The range of the messages to be used for summary can be specified in the request.
Parameters | |
---|---|
Name | Description |
request | SuggestConversationSummaryRequest The request object containing all of the parameters for the API call. |
callSettings | CallSettings If not null, applies overrides to this RPC call. |
Returns | |
---|---|
Type | Description |
SuggestConversationSummaryResponse | The RPC response. |
SuggestConversationSummaryAsync(SuggestConversationSummaryRequest, CallSettings)
public override Task<SuggestConversationSummaryResponse> SuggestConversationSummaryAsync(SuggestConversationSummaryRequest request, CallSettings callSettings = null)
Suggest summary for a conversation based on specific historical messages. The range of the messages to be used for summary can be specified in the request.
Parameters | |
---|---|
Name | Description |
request | SuggestConversationSummaryRequest The request object containing all of the parameters for the API call. |
callSettings | CallSettings If not null, applies overrides to this RPC call. |
Returns | |
---|---|
Type | Description |
TaskSuggestConversationSummaryResponse | A Task containing the RPC response. |