Sessions

google.cloud.dialogflow.cx.v3beta1. Sessions

Represents a Sessions

Constructor

new Sessions(rpcImpl, requestDelimitedopt, responseDelimitedopt)

Constructs a new Sessions service.

Parameters:
Name Type Attributes Default Description
rpcImpl $protobuf.RPCImpl

RPC implementation

requestDelimited boolean <optional>
false

Whether requests are length-delimited

responseDelimited boolean <optional>
false

Whether responses are length-delimited

Extends

  • $protobuf.rpc.Service

Methods

detectIntent(request, callback) → {undefined}

Calls DetectIntent.

Parameters:
Name Type Description
request google.cloud.dialogflow.cx.v3beta1.IDetectIntentRequest

DetectIntentRequest message or plain object

callback google.cloud.dialogflow.cx.v3beta1.Sessions.DetectIntentCallback

Node-style callback called with the error, if any, and DetectIntentResponse

Returns:
Type Description
undefined

detectIntent(request) → {Promise.<google.cloud.dialogflow.cx.v3beta1.DetectIntentResponse>}

Calls DetectIntent.

Parameters:
Name Type Description
request google.cloud.dialogflow.cx.v3beta1.IDetectIntentRequest

DetectIntentRequest message or plain object

Returns:
Type Description
Promise.<google.cloud.dialogflow.cx.v3beta1.DetectIntentResponse>

Promise

fulfillIntent(request, callback) → {undefined}

Calls FulfillIntent.

Parameters:
Name Type Description
request google.cloud.dialogflow.cx.v3beta1.IFulfillIntentRequest

FulfillIntentRequest message or plain object

callback google.cloud.dialogflow.cx.v3beta1.Sessions.FulfillIntentCallback

Node-style callback called with the error, if any, and FulfillIntentResponse

Returns:
Type Description
undefined

fulfillIntent(request) → {Promise.<google.cloud.dialogflow.cx.v3beta1.FulfillIntentResponse>}

Calls FulfillIntent.

Parameters:
Name Type Description
request google.cloud.dialogflow.cx.v3beta1.IFulfillIntentRequest

FulfillIntentRequest message or plain object

Returns:
Type Description
Promise.<google.cloud.dialogflow.cx.v3beta1.FulfillIntentResponse>

Promise

matchIntent(request, callback) → {undefined}

Calls MatchIntent.

Parameters:
Name Type Description
request google.cloud.dialogflow.cx.v3beta1.IMatchIntentRequest

MatchIntentRequest message or plain object

callback google.cloud.dialogflow.cx.v3beta1.Sessions.MatchIntentCallback

Node-style callback called with the error, if any, and MatchIntentResponse

Returns:
Type Description
undefined

matchIntent(request) → {Promise.<google.cloud.dialogflow.cx.v3beta1.MatchIntentResponse>}

Calls MatchIntent.

Parameters:
Name Type Description
request google.cloud.dialogflow.cx.v3beta1.IMatchIntentRequest

MatchIntentRequest message or plain object

Returns:
Type Description
Promise.<google.cloud.dialogflow.cx.v3beta1.MatchIntentResponse>

Promise

serverStreamingDetectIntent(request, callback) → {undefined}

Calls ServerStreamingDetectIntent.

Parameters:
Name Type Description
request google.cloud.dialogflow.cx.v3beta1.IDetectIntentRequest

DetectIntentRequest message or plain object

callback google.cloud.dialogflow.cx.v3beta1.Sessions.ServerStreamingDetectIntentCallback

Node-style callback called with the error, if any, and DetectIntentResponse

Returns:
Type Description
undefined

serverStreamingDetectIntent(request) → {Promise.<google.cloud.dialogflow.cx.v3beta1.DetectIntentResponse>}

Calls ServerStreamingDetectIntent.

Parameters:
Name Type Description
request google.cloud.dialogflow.cx.v3beta1.IDetectIntentRequest

DetectIntentRequest message or plain object

Returns:
Type Description
Promise.<google.cloud.dialogflow.cx.v3beta1.DetectIntentResponse>

Promise

streamingDetectIntent(request, callback) → {undefined}

Calls StreamingDetectIntent.

Parameters:
Name Type Description
request google.cloud.dialogflow.cx.v3beta1.IStreamingDetectIntentRequest

StreamingDetectIntentRequest message or plain object

callback google.cloud.dialogflow.cx.v3beta1.Sessions.StreamingDetectIntentCallback

Node-style callback called with the error, if any, and StreamingDetectIntentResponse

Returns:
Type Description
undefined

streamingDetectIntent(request) → {Promise.<google.cloud.dialogflow.cx.v3beta1.StreamingDetectIntentResponse>}

Calls StreamingDetectIntent.

Parameters:
Name Type Description
request google.cloud.dialogflow.cx.v3beta1.IStreamingDetectIntentRequest

StreamingDetectIntentRequest message or plain object

Returns:
Type Description
Promise.<google.cloud.dialogflow.cx.v3beta1.StreamingDetectIntentResponse>

Promise

submitAnswerFeedback(request, callback) → {undefined}

Calls SubmitAnswerFeedback.

Parameters:
Name Type Description
request google.cloud.dialogflow.cx.v3beta1.ISubmitAnswerFeedbackRequest

SubmitAnswerFeedbackRequest message or plain object

callback google.cloud.dialogflow.cx.v3beta1.Sessions.SubmitAnswerFeedbackCallback

Node-style callback called with the error, if any, and AnswerFeedback

Returns:
Type Description
undefined

submitAnswerFeedback(request) → {Promise.<google.cloud.dialogflow.cx.v3beta1.AnswerFeedback>}

Calls SubmitAnswerFeedback.

Parameters:
Name Type Description
request google.cloud.dialogflow.cx.v3beta1.ISubmitAnswerFeedbackRequest

SubmitAnswerFeedbackRequest message or plain object

Returns:
Type Description
Promise.<google.cloud.dialogflow.cx.v3beta1.AnswerFeedback>

Promise

(static) create(rpcImpl, requestDelimitedopt, responseDelimitedopt) → {Sessions}

Creates new Sessions service using the specified rpc implementation.

Parameters:
Name Type Attributes Default Description
rpcImpl $protobuf.RPCImpl

RPC implementation

requestDelimited boolean <optional>
false

Whether requests are length-delimited

responseDelimited boolean <optional>
false

Whether responses are length-delimited

Returns:
Type Description
Sessions

RPC service. Useful where requests and/or responses are streamed.

Type Definitions

DetectIntentCallback(error, responseopt)

Callback as used by detectIntent.

Parameters:
Name Type Attributes Description
error Error | null

Error, if any

response google.cloud.dialogflow.cx.v3beta1.DetectIntentResponse <optional>

DetectIntentResponse

FulfillIntentCallback(error, responseopt)

Callback as used by fulfillIntent.

Parameters:
Name Type Attributes Description
error Error | null

Error, if any

response google.cloud.dialogflow.cx.v3beta1.FulfillIntentResponse <optional>

FulfillIntentResponse

MatchIntentCallback(error, responseopt)

Callback as used by matchIntent.

Parameters:
Name Type Attributes Description
error Error | null

Error, if any

response google.cloud.dialogflow.cx.v3beta1.MatchIntentResponse <optional>

MatchIntentResponse

ServerStreamingDetectIntentCallback(error, responseopt)

Callback as used by serverStreamingDetectIntent.

Parameters:
Name Type Attributes Description
error Error | null

Error, if any

response google.cloud.dialogflow.cx.v3beta1.DetectIntentResponse <optional>

DetectIntentResponse

StreamingDetectIntentCallback(error, responseopt)

Callback as used by streamingDetectIntent.

Parameters:
Name Type Attributes Description
error Error | null

Error, if any

response google.cloud.dialogflow.cx.v3beta1.StreamingDetectIntentResponse <optional>

StreamingDetectIntentResponse

SubmitAnswerFeedbackCallback(error, responseopt)

Callback as used by submitAnswerFeedback.

Parameters:
Name Type Attributes Description
error Error | null

Error, if any

response google.cloud.dialogflow.cx.v3beta1.AnswerFeedback <optional>

AnswerFeedback