Google Cloud Dialogflow V2 Client - Class WebhookRequest (1.17.0)

Reference documentation and code samples for the Google Cloud Dialogflow V2 Client class WebhookRequest.

The request message for a webhook call.

Generated from protobuf message google.cloud.dialogflow.v2.WebhookRequest

Namespace

Google \ Cloud \ Dialogflow \ V2

Methods

__construct

Constructor.

Parameters
Name Description
data array

Optional. Data for populating the Message object.

↳ session string

The unique identifier of detectIntent request session. Can be used to identify end-user inside webhook implementation. Format: projects/<Project ID>/agent/sessions/<Session ID>, or projects/<Project ID>/agent/environments/<Environment ID>/users/<User ID>/sessions/<Session ID>.

↳ response_id string

The unique identifier of the response. Contains the same value as [Streaming]DetectIntentResponse.response_id.

↳ query_result QueryResult

The result of the conversational query or event processing. Contains the same value as [Streaming]DetectIntentResponse.query_result.

↳ original_detect_intent_request OriginalDetectIntentRequest

Optional. The contents of the original request that was passed to [Streaming]DetectIntent call.

getSession

The unique identifier of detectIntent request session.

Can be used to identify end-user inside webhook implementation. Format: projects/<Project ID>/agent/sessions/<Session ID>, or projects/<Project ID>/agent/environments/<Environment ID>/users/<User ID>/sessions/<Session ID>.

Returns
Type Description
string

setSession

The unique identifier of detectIntent request session.

Can be used to identify end-user inside webhook implementation. Format: projects/<Project ID>/agent/sessions/<Session ID>, or projects/<Project ID>/agent/environments/<Environment ID>/users/<User ID>/sessions/<Session ID>.

Parameter
Name Description
var string
Returns
Type Description
$this

getResponseId

The unique identifier of the response. Contains the same value as [Streaming]DetectIntentResponse.response_id.

Returns
Type Description
string

setResponseId

The unique identifier of the response. Contains the same value as [Streaming]DetectIntentResponse.response_id.

Parameter
Name Description
var string
Returns
Type Description
$this

getQueryResult

The result of the conversational query or event processing. Contains the same value as [Streaming]DetectIntentResponse.query_result.

Returns
Type Description
QueryResult|null

hasQueryResult

clearQueryResult

setQueryResult

The result of the conversational query or event processing. Contains the same value as [Streaming]DetectIntentResponse.query_result.

Parameter
Name Description
var QueryResult
Returns
Type Description
$this

getOriginalDetectIntentRequest

Optional. The contents of the original request that was passed to [Streaming]DetectIntent call.

Returns
Type Description
OriginalDetectIntentRequest|null

hasOriginalDetectIntentRequest

clearOriginalDetectIntentRequest

setOriginalDetectIntentRequest

Optional. The contents of the original request that was passed to [Streaming]DetectIntent call.

Parameter
Name Description
var OriginalDetectIntentRequest
Returns
Type Description
$this