Class WebhookRequest.Builder (4.38.0)

public static final class WebhookRequest.Builder extends GeneratedMessageV3.Builder<WebhookRequest.Builder> implements WebhookRequestOrBuilder

The request message for a webhook call.

Protobuf type google.cloud.dialogflow.v2beta1.WebhookRequest

Static Methods

getDescriptor()

public static final Descriptors.Descriptor getDescriptor()
Returns
Type Description
Descriptor

Methods

addAllAlternativeQueryResults(Iterable<? extends QueryResult> values)

public WebhookRequest.Builder addAllAlternativeQueryResults(Iterable<? extends QueryResult> values)

Alternative query results from KnowledgeService.

repeated .google.cloud.dialogflow.v2beta1.QueryResult alternative_query_results = 5;

Parameter
Name Description
values Iterable<? extends com.google.cloud.dialogflow.v2beta1.QueryResult>
Returns
Type Description
WebhookRequest.Builder

addAlternativeQueryResults(QueryResult value)

public WebhookRequest.Builder addAlternativeQueryResults(QueryResult value)

Alternative query results from KnowledgeService.

repeated .google.cloud.dialogflow.v2beta1.QueryResult alternative_query_results = 5;

Parameter
Name Description
value QueryResult
Returns
Type Description
WebhookRequest.Builder

addAlternativeQueryResults(QueryResult.Builder builderForValue)

public WebhookRequest.Builder addAlternativeQueryResults(QueryResult.Builder builderForValue)

Alternative query results from KnowledgeService.

repeated .google.cloud.dialogflow.v2beta1.QueryResult alternative_query_results = 5;

Parameter
Name Description
builderForValue QueryResult.Builder
Returns
Type Description
WebhookRequest.Builder

addAlternativeQueryResults(int index, QueryResult value)

public WebhookRequest.Builder addAlternativeQueryResults(int index, QueryResult value)

Alternative query results from KnowledgeService.

repeated .google.cloud.dialogflow.v2beta1.QueryResult alternative_query_results = 5;

Parameters
Name Description
index int
value QueryResult
Returns
Type Description
WebhookRequest.Builder

addAlternativeQueryResults(int index, QueryResult.Builder builderForValue)

public WebhookRequest.Builder addAlternativeQueryResults(int index, QueryResult.Builder builderForValue)

Alternative query results from KnowledgeService.

repeated .google.cloud.dialogflow.v2beta1.QueryResult alternative_query_results = 5;

Parameters
Name Description
index int
builderForValue QueryResult.Builder
Returns
Type Description
WebhookRequest.Builder

addAlternativeQueryResultsBuilder()

public QueryResult.Builder addAlternativeQueryResultsBuilder()

Alternative query results from KnowledgeService.

repeated .google.cloud.dialogflow.v2beta1.QueryResult alternative_query_results = 5;

Returns
Type Description
QueryResult.Builder

addAlternativeQueryResultsBuilder(int index)

public QueryResult.Builder addAlternativeQueryResultsBuilder(int index)

Alternative query results from KnowledgeService.

repeated .google.cloud.dialogflow.v2beta1.QueryResult alternative_query_results = 5;

Parameter
Name Description
index int
Returns
Type Description
QueryResult.Builder

addRepeatedField(Descriptors.FieldDescriptor field, Object value)

public WebhookRequest.Builder addRepeatedField(Descriptors.FieldDescriptor field, Object value)
Parameters
Name Description
field FieldDescriptor
value Object
Returns
Type Description
WebhookRequest.Builder
Overrides

build()

public WebhookRequest build()
Returns
Type Description
WebhookRequest

buildPartial()

public WebhookRequest buildPartial()
Returns
Type Description
WebhookRequest

clear()

public WebhookRequest.Builder clear()
Returns
Type Description
WebhookRequest.Builder
Overrides

clearAlternativeQueryResults()

public WebhookRequest.Builder clearAlternativeQueryResults()

Alternative query results from KnowledgeService.

repeated .google.cloud.dialogflow.v2beta1.QueryResult alternative_query_results = 5;

Returns
Type Description
WebhookRequest.Builder

clearField(Descriptors.FieldDescriptor field)

public WebhookRequest.Builder clearField(Descriptors.FieldDescriptor field)
Parameter
Name Description
field FieldDescriptor
Returns
Type Description
WebhookRequest.Builder
Overrides

clearOneof(Descriptors.OneofDescriptor oneof)

public WebhookRequest.Builder clearOneof(Descriptors.OneofDescriptor oneof)
Parameter
Name Description
oneof OneofDescriptor
Returns
Type Description
WebhookRequest.Builder
Overrides

clearOriginalDetectIntentRequest()

public WebhookRequest.Builder clearOriginalDetectIntentRequest()

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

.google.cloud.dialogflow.v2beta1.OriginalDetectIntentRequest original_detect_intent_request = 3;

Returns
Type Description
WebhookRequest.Builder

clearQueryResult()

public WebhookRequest.Builder clearQueryResult()

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

.google.cloud.dialogflow.v2beta1.QueryResult query_result = 2;

Returns
Type Description
WebhookRequest.Builder

clearResponseId()

public WebhookRequest.Builder clearResponseId()

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

string response_id = 1;

Returns
Type Description
WebhookRequest.Builder

This builder for chaining.

clearSession()

public WebhookRequest.Builder clearSession()

The unique identifier of detectIntent request session. Can be used to identify end-user inside webhook implementation. Supported formats:

  • projects/<Project ID>/agent/sessions/<Session ID>,
  • projects/<Project ID>/locations/<Location ID>/agent/sessions/<Session ID>,
  • projects/<Project ID>/agent/environments/<Environment ID>/users/<User ID>/sessions/<Session ID>,
  • projects/<Project ID>/locations/<Location ID>/agent/environments/<Environment ID>/users/<User ID>/sessions/<Session ID>`,

string session = 4;

Returns
Type Description
WebhookRequest.Builder

This builder for chaining.

clone()

public WebhookRequest.Builder clone()
Returns
Type Description
WebhookRequest.Builder
Overrides

getAlternativeQueryResults(int index)

public QueryResult getAlternativeQueryResults(int index)

Alternative query results from KnowledgeService.

repeated .google.cloud.dialogflow.v2beta1.QueryResult alternative_query_results = 5;

Parameter
Name Description
index int
Returns
Type Description
QueryResult

getAlternativeQueryResultsBuilder(int index)

public QueryResult.Builder getAlternativeQueryResultsBuilder(int index)

Alternative query results from KnowledgeService.

repeated .google.cloud.dialogflow.v2beta1.QueryResult alternative_query_results = 5;

Parameter
Name Description
index int
Returns
Type Description
QueryResult.Builder

getAlternativeQueryResultsBuilderList()

public List<QueryResult.Builder> getAlternativeQueryResultsBuilderList()

Alternative query results from KnowledgeService.

repeated .google.cloud.dialogflow.v2beta1.QueryResult alternative_query_results = 5;

Returns
Type Description
List<Builder>

getAlternativeQueryResultsCount()

public int getAlternativeQueryResultsCount()

Alternative query results from KnowledgeService.

repeated .google.cloud.dialogflow.v2beta1.QueryResult alternative_query_results = 5;

Returns
Type Description
int

getAlternativeQueryResultsList()

public List<QueryResult> getAlternativeQueryResultsList()

Alternative query results from KnowledgeService.

repeated .google.cloud.dialogflow.v2beta1.QueryResult alternative_query_results = 5;

Returns
Type Description
List<QueryResult>

getAlternativeQueryResultsOrBuilder(int index)

public QueryResultOrBuilder getAlternativeQueryResultsOrBuilder(int index)

Alternative query results from KnowledgeService.

repeated .google.cloud.dialogflow.v2beta1.QueryResult alternative_query_results = 5;

Parameter
Name Description
index int
Returns
Type Description
QueryResultOrBuilder

getAlternativeQueryResultsOrBuilderList()

public List<? extends QueryResultOrBuilder> getAlternativeQueryResultsOrBuilderList()

Alternative query results from KnowledgeService.

repeated .google.cloud.dialogflow.v2beta1.QueryResult alternative_query_results = 5;

Returns
Type Description
List<? extends com.google.cloud.dialogflow.v2beta1.QueryResultOrBuilder>

getDefaultInstanceForType()

public WebhookRequest getDefaultInstanceForType()
Returns
Type Description
WebhookRequest

getDescriptorForType()

public Descriptors.Descriptor getDescriptorForType()
Returns
Type Description
Descriptor
Overrides

getOriginalDetectIntentRequest()

public OriginalDetectIntentRequest getOriginalDetectIntentRequest()

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

.google.cloud.dialogflow.v2beta1.OriginalDetectIntentRequest original_detect_intent_request = 3;

Returns
Type Description
OriginalDetectIntentRequest

The originalDetectIntentRequest.

getOriginalDetectIntentRequestBuilder()

public OriginalDetectIntentRequest.Builder getOriginalDetectIntentRequestBuilder()

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

.google.cloud.dialogflow.v2beta1.OriginalDetectIntentRequest original_detect_intent_request = 3;

Returns
Type Description
OriginalDetectIntentRequest.Builder

getOriginalDetectIntentRequestOrBuilder()

public OriginalDetectIntentRequestOrBuilder getOriginalDetectIntentRequestOrBuilder()

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

.google.cloud.dialogflow.v2beta1.OriginalDetectIntentRequest original_detect_intent_request = 3;

Returns
Type Description
OriginalDetectIntentRequestOrBuilder

getQueryResult()

public QueryResult getQueryResult()

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

.google.cloud.dialogflow.v2beta1.QueryResult query_result = 2;

Returns
Type Description
QueryResult

The queryResult.

getQueryResultBuilder()

public QueryResult.Builder getQueryResultBuilder()

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

.google.cloud.dialogflow.v2beta1.QueryResult query_result = 2;

Returns
Type Description
QueryResult.Builder

getQueryResultOrBuilder()

public QueryResultOrBuilder getQueryResultOrBuilder()

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

.google.cloud.dialogflow.v2beta1.QueryResult query_result = 2;

Returns
Type Description
QueryResultOrBuilder

getResponseId()

public String getResponseId()

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

string response_id = 1;

Returns
Type Description
String

The responseId.

getResponseIdBytes()

public ByteString getResponseIdBytes()

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

string response_id = 1;

Returns
Type Description
ByteString

The bytes for responseId.

getSession()

public String getSession()

The unique identifier of detectIntent request session. Can be used to identify end-user inside webhook implementation. Supported formats:

  • projects/<Project ID>/agent/sessions/<Session ID>,
  • projects/<Project ID>/locations/<Location ID>/agent/sessions/<Session ID>,
  • projects/<Project ID>/agent/environments/<Environment ID>/users/<User ID>/sessions/<Session ID>,
  • projects/<Project ID>/locations/<Location ID>/agent/environments/<Environment ID>/users/<User ID>/sessions/<Session ID>`,

string session = 4;

Returns
Type Description
String

The session.

getSessionBytes()

public ByteString getSessionBytes()

The unique identifier of detectIntent request session. Can be used to identify end-user inside webhook implementation. Supported formats:

  • projects/<Project ID>/agent/sessions/<Session ID>,
  • projects/<Project ID>/locations/<Location ID>/agent/sessions/<Session ID>,
  • projects/<Project ID>/agent/environments/<Environment ID>/users/<User ID>/sessions/<Session ID>,
  • projects/<Project ID>/locations/<Location ID>/agent/environments/<Environment ID>/users/<User ID>/sessions/<Session ID>`,

string session = 4;

Returns
Type Description
ByteString

The bytes for session.

hasOriginalDetectIntentRequest()

public boolean hasOriginalDetectIntentRequest()

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

.google.cloud.dialogflow.v2beta1.OriginalDetectIntentRequest original_detect_intent_request = 3;

Returns
Type Description
boolean

Whether the originalDetectIntentRequest field is set.

hasQueryResult()

public boolean hasQueryResult()

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

.google.cloud.dialogflow.v2beta1.QueryResult query_result = 2;

Returns
Type Description
boolean

Whether the queryResult field is set.

internalGetFieldAccessorTable()

protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
Type Description
FieldAccessorTable
Overrides

isInitialized()

public final boolean isInitialized()
Returns
Type Description
boolean
Overrides

mergeFrom(WebhookRequest other)

public WebhookRequest.Builder mergeFrom(WebhookRequest other)
Parameter
Name Description
other WebhookRequest
Returns
Type Description
WebhookRequest.Builder

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

public WebhookRequest.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
Name Description
input CodedInputStream
extensionRegistry ExtensionRegistryLite
Returns
Type Description
WebhookRequest.Builder
Overrides
Exceptions
Type Description
IOException

mergeFrom(Message other)

public WebhookRequest.Builder mergeFrom(Message other)
Parameter
Name Description
other Message
Returns
Type Description
WebhookRequest.Builder
Overrides

mergeOriginalDetectIntentRequest(OriginalDetectIntentRequest value)

public WebhookRequest.Builder mergeOriginalDetectIntentRequest(OriginalDetectIntentRequest value)

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

.google.cloud.dialogflow.v2beta1.OriginalDetectIntentRequest original_detect_intent_request = 3;

Parameter
Name Description
value OriginalDetectIntentRequest
Returns
Type Description
WebhookRequest.Builder

mergeQueryResult(QueryResult value)

public WebhookRequest.Builder mergeQueryResult(QueryResult value)

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

.google.cloud.dialogflow.v2beta1.QueryResult query_result = 2;

Parameter
Name Description
value QueryResult
Returns
Type Description
WebhookRequest.Builder

mergeUnknownFields(UnknownFieldSet unknownFields)

public final WebhookRequest.Builder mergeUnknownFields(UnknownFieldSet unknownFields)
Parameter
Name Description
unknownFields UnknownFieldSet
Returns
Type Description
WebhookRequest.Builder
Overrides

removeAlternativeQueryResults(int index)

public WebhookRequest.Builder removeAlternativeQueryResults(int index)

Alternative query results from KnowledgeService.

repeated .google.cloud.dialogflow.v2beta1.QueryResult alternative_query_results = 5;

Parameter
Name Description
index int
Returns
Type Description
WebhookRequest.Builder

setAlternativeQueryResults(int index, QueryResult value)

public WebhookRequest.Builder setAlternativeQueryResults(int index, QueryResult value)

Alternative query results from KnowledgeService.

repeated .google.cloud.dialogflow.v2beta1.QueryResult alternative_query_results = 5;

Parameters
Name Description
index int
value QueryResult
Returns
Type Description
WebhookRequest.Builder

setAlternativeQueryResults(int index, QueryResult.Builder builderForValue)

public WebhookRequest.Builder setAlternativeQueryResults(int index, QueryResult.Builder builderForValue)

Alternative query results from KnowledgeService.

repeated .google.cloud.dialogflow.v2beta1.QueryResult alternative_query_results = 5;

Parameters
Name Description
index int
builderForValue QueryResult.Builder
Returns
Type Description
WebhookRequest.Builder

setField(Descriptors.FieldDescriptor field, Object value)

public WebhookRequest.Builder setField(Descriptors.FieldDescriptor field, Object value)
Parameters
Name Description
field FieldDescriptor
value Object
Returns
Type Description
WebhookRequest.Builder
Overrides

setOriginalDetectIntentRequest(OriginalDetectIntentRequest value)

public WebhookRequest.Builder setOriginalDetectIntentRequest(OriginalDetectIntentRequest value)

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

.google.cloud.dialogflow.v2beta1.OriginalDetectIntentRequest original_detect_intent_request = 3;

Parameter
Name Description
value OriginalDetectIntentRequest
Returns
Type Description
WebhookRequest.Builder

setOriginalDetectIntentRequest(OriginalDetectIntentRequest.Builder builderForValue)

public WebhookRequest.Builder setOriginalDetectIntentRequest(OriginalDetectIntentRequest.Builder builderForValue)

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

.google.cloud.dialogflow.v2beta1.OriginalDetectIntentRequest original_detect_intent_request = 3;

Parameter
Name Description
builderForValue OriginalDetectIntentRequest.Builder
Returns
Type Description
WebhookRequest.Builder

setQueryResult(QueryResult value)

public WebhookRequest.Builder setQueryResult(QueryResult value)

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

.google.cloud.dialogflow.v2beta1.QueryResult query_result = 2;

Parameter
Name Description
value QueryResult
Returns
Type Description
WebhookRequest.Builder

setQueryResult(QueryResult.Builder builderForValue)

public WebhookRequest.Builder setQueryResult(QueryResult.Builder builderForValue)

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

.google.cloud.dialogflow.v2beta1.QueryResult query_result = 2;

Parameter
Name Description
builderForValue QueryResult.Builder
Returns
Type Description
WebhookRequest.Builder

setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)

public WebhookRequest.Builder setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
Parameters
Name Description
field FieldDescriptor
index int
value Object
Returns
Type Description
WebhookRequest.Builder
Overrides

setResponseId(String value)

public WebhookRequest.Builder setResponseId(String value)

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

string response_id = 1;

Parameter
Name Description
value String

The responseId to set.

Returns
Type Description
WebhookRequest.Builder

This builder for chaining.

setResponseIdBytes(ByteString value)

public WebhookRequest.Builder setResponseIdBytes(ByteString value)

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

string response_id = 1;

Parameter
Name Description
value ByteString

The bytes for responseId to set.

Returns
Type Description
WebhookRequest.Builder

This builder for chaining.

setSession(String value)

public WebhookRequest.Builder setSession(String value)

The unique identifier of detectIntent request session. Can be used to identify end-user inside webhook implementation. Supported formats:

  • projects/<Project ID>/agent/sessions/<Session ID>,
  • projects/<Project ID>/locations/<Location ID>/agent/sessions/<Session ID>,
  • projects/<Project ID>/agent/environments/<Environment ID>/users/<User ID>/sessions/<Session ID>,
  • projects/<Project ID>/locations/<Location ID>/agent/environments/<Environment ID>/users/<User ID>/sessions/<Session ID>`,

string session = 4;

Parameter
Name Description
value String

The session to set.

Returns
Type Description
WebhookRequest.Builder

This builder for chaining.

setSessionBytes(ByteString value)

public WebhookRequest.Builder setSessionBytes(ByteString value)

The unique identifier of detectIntent request session. Can be used to identify end-user inside webhook implementation. Supported formats:

  • projects/<Project ID>/agent/sessions/<Session ID>,
  • projects/<Project ID>/locations/<Location ID>/agent/sessions/<Session ID>,
  • projects/<Project ID>/agent/environments/<Environment ID>/users/<User ID>/sessions/<Session ID>,
  • projects/<Project ID>/locations/<Location ID>/agent/environments/<Environment ID>/users/<User ID>/sessions/<Session ID>`,

string session = 4;

Parameter
Name Description
value ByteString

The bytes for session to set.

Returns
Type Description
WebhookRequest.Builder

This builder for chaining.

setUnknownFields(UnknownFieldSet unknownFields)

public final WebhookRequest.Builder setUnknownFields(UnknownFieldSet unknownFields)
Parameter
Name Description
unknownFields UnknownFieldSet
Returns
Type Description
WebhookRequest.Builder
Overrides