Google Cloud Discovery Engine V1 Client - Class AnswerQueryResponse (0.11.3)

Reference documentation and code samples for the Google Cloud Discovery Engine V1 Client class AnswerQueryResponse.

Response message for ConversationalSearchService.AnswerQuery method.

Generated from protobuf message google.cloud.discoveryengine.v1.AnswerQueryResponse

Namespace

Google \ Cloud \ DiscoveryEngine \ V1

Methods

__construct

Constructor.

Parameters
Name Description
data array

Optional. Data for populating the Message object.

↳ answer Google\Cloud\DiscoveryEngine\V1\Answer

Answer resource object. If AnswerQueryRequest.StepSpec.max_step_count is greater than 1, use Answer.name to fetch answer information using ConversationalSearchService.GetAnswer API.

↳ session Google\Cloud\DiscoveryEngine\V1\Session

Session resource object. It will be only available when session field is set and valid in the AnswerQueryRequest request.

↳ answer_query_token string

A global unique ID used for logging.

getAnswer

Answer resource object.

If AnswerQueryRequest.StepSpec.max_step_count is greater than 1, use Answer.name to fetch answer information using ConversationalSearchService.GetAnswer API.

Returns
Type Description
Google\Cloud\DiscoveryEngine\V1\Answer|null

hasAnswer

clearAnswer

setAnswer

Answer resource object.

If AnswerQueryRequest.StepSpec.max_step_count is greater than 1, use Answer.name to fetch answer information using ConversationalSearchService.GetAnswer API.

Parameter
Name Description
var Google\Cloud\DiscoveryEngine\V1\Answer
Returns
Type Description
$this

getSession

Session resource object.

It will be only available when session field is set and valid in the AnswerQueryRequest request.

Returns
Type Description
Google\Cloud\DiscoveryEngine\V1\Session|null

hasSession

clearSession

setSession

Session resource object.

It will be only available when session field is set and valid in the AnswerQueryRequest request.

Parameter
Name Description
var Google\Cloud\DiscoveryEngine\V1\Session
Returns
Type Description
$this

getAnswerQueryToken

A global unique ID used for logging.

Returns
Type Description
string

setAnswerQueryToken

A global unique ID used for logging.

Parameter
Name Description
var string
Returns
Type Description
$this