public sealed class SessionsClientImpl : SessionsClient
Sessions client wrapper implementation, for convenient use.
Namespace
Google.Cloud.Dialogflow.Cx.V3Assembly
Google.Cloud.Dialogflow.Cx.V3.dll
Remarks
A session represents an interaction with a user. You retrieve user input and pass it to the [DetectIntent][google.cloud.dialogflow.cx.v3.Sessions.DetectIntent] method to determine user intent and respond.
Constructors
SessionsClientImpl(Sessions.SessionsClient, SessionsSettings)
public SessionsClientImpl(Sessions.SessionsClient grpcClient, SessionsSettings settings)
Constructs a client wrapper for the Sessions service, with the specified gRPC client and settings.
Parameters | |
---|---|
Name | Description |
grpcClient | Sessions.SessionsClient The underlying gRPC client. |
settings | SessionsSettings The base SessionsSettings used within this client. |
Properties
GrpcClient
public override Sessions.SessionsClient GrpcClient { get; }
The underlying gRPC Sessions client
Property Value | |
---|---|
Type | Description |
Sessions.SessionsClient |
Methods
DetectIntent(DetectIntentRequest, CallSettings)
public override DetectIntentResponse DetectIntent(DetectIntentRequest request, CallSettings callSettings = null)
Processes a natural language query and returns structured, actionable data as a result. This method is not idempotent, because it may cause session entity types to be updated, which in turn might affect results of future queries.
Note: Always use agent versions for production traffic. See Versions and environments.
Parameters | |
---|---|
Name | Description |
request | DetectIntentRequest The request object containing all of the parameters for the API call. |
callSettings | Google.Api.Gax.Grpc.CallSettings If not null, applies overrides to this RPC call. |
Returns | |
---|---|
Type | Description |
DetectIntentResponse | The RPC response. |
DetectIntentAsync(DetectIntentRequest, CallSettings)
public override Task<DetectIntentResponse> DetectIntentAsync(DetectIntentRequest request, CallSettings callSettings = null)
Processes a natural language query and returns structured, actionable data as a result. This method is not idempotent, because it may cause session entity types to be updated, which in turn might affect results of future queries.
Note: Always use agent versions for production traffic. See Versions and environments.
Parameters | |
---|---|
Name | Description |
request | DetectIntentRequest The request object containing all of the parameters for the API call. |
callSettings | Google.Api.Gax.Grpc.CallSettings If not null, applies overrides to this RPC call. |
Returns | |
---|---|
Type | Description |
System.Threading.Tasks.Task<DetectIntentResponse> | A Task containing the RPC response. |
FulfillIntent(FulfillIntentRequest, CallSettings)
public override FulfillIntentResponse FulfillIntent(FulfillIntentRequest request, CallSettings callSettings = null)
Fulfills a matched intent returned by [MatchIntent][google.cloud.dialogflow.cx.v3.Sessions.MatchIntent]. Must be called after [MatchIntent][google.cloud.dialogflow.cx.v3.Sessions.MatchIntent], with input from [MatchIntentResponse][google.cloud.dialogflow.cx.v3.MatchIntentResponse]. Otherwise, the behavior is undefined.
Parameters | |
---|---|
Name | Description |
request | FulfillIntentRequest The request object containing all of the parameters for the API call. |
callSettings | Google.Api.Gax.Grpc.CallSettings If not null, applies overrides to this RPC call. |
Returns | |
---|---|
Type | Description |
FulfillIntentResponse | The RPC response. |
FulfillIntentAsync(FulfillIntentRequest, CallSettings)
public override Task<FulfillIntentResponse> FulfillIntentAsync(FulfillIntentRequest request, CallSettings callSettings = null)
Fulfills a matched intent returned by [MatchIntent][google.cloud.dialogflow.cx.v3.Sessions.MatchIntent]. Must be called after [MatchIntent][google.cloud.dialogflow.cx.v3.Sessions.MatchIntent], with input from [MatchIntentResponse][google.cloud.dialogflow.cx.v3.MatchIntentResponse]. Otherwise, the behavior is undefined.
Parameters | |
---|---|
Name | Description |
request | FulfillIntentRequest The request object containing all of the parameters for the API call. |
callSettings | Google.Api.Gax.Grpc.CallSettings If not null, applies overrides to this RPC call. |
Returns | |
---|---|
Type | Description |
System.Threading.Tasks.Task<FulfillIntentResponse> | A Task containing the RPC response. |
MatchIntent(MatchIntentRequest, CallSettings)
public override MatchIntentResponse MatchIntent(MatchIntentRequest request, CallSettings callSettings = null)
Returns preliminary intent match results, doesn't change the session status.
Parameters | |
---|---|
Name | Description |
request | MatchIntentRequest The request object containing all of the parameters for the API call. |
callSettings | Google.Api.Gax.Grpc.CallSettings If not null, applies overrides to this RPC call. |
Returns | |
---|---|
Type | Description |
MatchIntentResponse | The RPC response. |
MatchIntentAsync(MatchIntentRequest, CallSettings)
public override Task<MatchIntentResponse> MatchIntentAsync(MatchIntentRequest request, CallSettings callSettings = null)
Returns preliminary intent match results, doesn't change the session status.
Parameters | |
---|---|
Name | Description |
request | MatchIntentRequest The request object containing all of the parameters for the API call. |
callSettings | Google.Api.Gax.Grpc.CallSettings If not null, applies overrides to this RPC call. |
Returns | |
---|---|
Type | Description |
System.Threading.Tasks.Task<MatchIntentResponse> | A Task containing the RPC response. |
StreamingDetectIntent(CallSettings, BidirectionalStreamingSettings)
public override SessionsClient.StreamingDetectIntentStream StreamingDetectIntent(CallSettings callSettings = null, BidirectionalStreamingSettings streamingSettings = null)
Processes a natural language query in audio format in a streaming fashion and returns structured, actionable data as a result. This method is only available via the gRPC API (not REST).
Note: Always use agent versions for production traffic. See Versions and environments.
Parameters | |
---|---|
Name | Description |
callSettings | Google.Api.Gax.Grpc.CallSettings If not null, applies overrides to this RPC call. |
streamingSettings | Google.Api.Gax.Grpc.BidirectionalStreamingSettings If not null, applies streaming overrides to this RPC call. |
Returns | |
---|---|
Type | Description |
SessionsClient.StreamingDetectIntentStream | The client-server stream. |