public sealed class EventHandler : IMessage<EventHandler>, IEquatable<EventHandler>, IDeepCloneable<EventHandler>, IBufferMessage, IMessage
Reference documentation and code samples for the Dialogflow v3 API class EventHandler.
An event handler specifies an [event][google.cloud.dialogflow.cx.v3.EventHandler.event] that can be handled during a session. When the specified event happens, the following actions are taken in order:
- If there is a
[
trigger_fulfillment
][google.cloud.dialogflow.cx.v3.EventHandler.trigger_fulfillment] associated with the event, it will be called. - If there is a
[
target_page
][google.cloud.dialogflow.cx.v3.EventHandler.target_page] associated with the event, the session will transition into the specified page. - If there is a
[
target_flow
][google.cloud.dialogflow.cx.v3.EventHandler.target_flow] associated with the event, the session will transition into the specified flow.
Implements
IMessageEventHandler, IEquatableEventHandler, IDeepCloneableEventHandler, IBufferMessage, IMessageNamespace
Google.Cloud.Dialogflow.Cx.V3Assembly
Google.Cloud.Dialogflow.Cx.V3.dll
Constructors
EventHandler()
public EventHandler()
EventHandler(EventHandler)
public EventHandler(EventHandler other)
Parameter | |
---|---|
Name | Description |
other |
EventHandler |
Properties
Event
public string Event { get; set; }
Required. The name of the event to handle.
Property Value | |
---|---|
Type | Description |
string |
HasTargetFlow
public bool HasTargetFlow { get; }
Gets whether the "target_flow" field is set
Property Value | |
---|---|
Type | Description |
bool |
HasTargetPage
public bool HasTargetPage { get; }
Gets whether the "target_page" field is set
Property Value | |
---|---|
Type | Description |
bool |
Name
public string Name { get; set; }
Output only. The unique identifier of this event handler.
Property Value | |
---|---|
Type | Description |
string |
TargetCase
public EventHandler.TargetOneofCase TargetCase { get; }
Property Value | |
---|---|
Type | Description |
EventHandlerTargetOneofCase |
TargetFlow
public string TargetFlow { get; set; }
The target flow to transition to.
Format:
projects/<ProjectID>/locations/<LocationID>/agents/<AgentID>/flows/<FlowID>
.
Property Value | |
---|---|
Type | Description |
string |
TargetFlowAsFlowName
public FlowName TargetFlowAsFlowName { get; set; }
FlowName-typed view over the TargetFlow resource name property.
Property Value | |
---|---|
Type | Description |
FlowName |
TargetPage
public string TargetPage { get; set; }
The target page to transition to.
Format:
projects/<ProjectID>/locations/<LocationID>/agents/<AgentID>/flows/<FlowID>/pages/<PageID>
.
Property Value | |
---|---|
Type | Description |
string |
TargetPageAsPageName
public PageName TargetPageAsPageName { get; set; }
PageName-typed view over the TargetPage resource name property.
Property Value | |
---|---|
Type | Description |
PageName |
TriggerFulfillment
public Fulfillment TriggerFulfillment { get; set; }
The fulfillment to call when the event occurs. Handling webhook errors with a fulfillment enabled with webhook could cause infinite loop. It is invalid to specify such fulfillment for a handler handling webhooks.
Property Value | |
---|---|
Type | Description |
Fulfillment |