Class WebhookResponse.Builder

  • All Implemented Interfaces:
    WebhookResponseOrBuilder, com.google.protobuf.Message.Builder, com.google.protobuf.MessageLite.Builder, com.google.protobuf.MessageLiteOrBuilder, com.google.protobuf.MessageOrBuilder, Cloneable
    Enclosing class:
    WebhookResponse

    public static final class WebhookResponse.Builder
    extends com.google.protobuf.GeneratedMessageV3.Builder<WebhookResponse.Builder>
    implements WebhookResponseOrBuilder
     The response message for a webhook call.
    
     This response is validated by the Dialogflow server. If validation fails,
     an error will be returned in the
     [QueryResult.diagnostic_info][google.cloud.dialogflow.v2.QueryResult.diagnostic_info]
     field. Setting JSON fields to an empty value with the wrong type is a common
     error. To avoid this error:
    
     - Use `""` for empty strings
     - Use `{}` or `null` for empty objects
     - Use `[]` or `null` for empty arrays
    
     For more information, see the
     [Protocol Buffers Language
     Guide](https://developers.google.com/protocol-buffers/docs/proto3#json).
     
    Protobuf type google.cloud.dialogflow.v2.WebhookResponse
    • Method Detail

      • getDescriptor

        public static final com.google.protobuf.Descriptors.Descriptor getDescriptor()
      • internalGetFieldAccessorTable

        protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
        Specified by:
        internalGetFieldAccessorTable in class com.google.protobuf.GeneratedMessageV3.Builder<WebhookResponse.Builder>
      • clear

        public WebhookResponse.Builder clear()
        Specified by:
        clear in interface com.google.protobuf.Message.Builder
        Specified by:
        clear in interface com.google.protobuf.MessageLite.Builder
        Overrides:
        clear in class com.google.protobuf.GeneratedMessageV3.Builder<WebhookResponse.Builder>
      • getDescriptorForType

        public com.google.protobuf.Descriptors.Descriptor getDescriptorForType()
        Specified by:
        getDescriptorForType in interface com.google.protobuf.Message.Builder
        Specified by:
        getDescriptorForType in interface com.google.protobuf.MessageOrBuilder
        Overrides:
        getDescriptorForType in class com.google.protobuf.GeneratedMessageV3.Builder<WebhookResponse.Builder>
      • getDefaultInstanceForType

        public WebhookResponse getDefaultInstanceForType()
        Specified by:
        getDefaultInstanceForType in interface com.google.protobuf.MessageLiteOrBuilder
        Specified by:
        getDefaultInstanceForType in interface com.google.protobuf.MessageOrBuilder
      • build

        public WebhookResponse build()
        Specified by:
        build in interface com.google.protobuf.Message.Builder
        Specified by:
        build in interface com.google.protobuf.MessageLite.Builder
      • buildPartial

        public WebhookResponse buildPartial()
        Specified by:
        buildPartial in interface com.google.protobuf.Message.Builder
        Specified by:
        buildPartial in interface com.google.protobuf.MessageLite.Builder
      • clone

        public WebhookResponse.Builder clone()
        Specified by:
        clone in interface com.google.protobuf.Message.Builder
        Specified by:
        clone in interface com.google.protobuf.MessageLite.Builder
        Overrides:
        clone in class com.google.protobuf.GeneratedMessageV3.Builder<WebhookResponse.Builder>
      • setField

        public WebhookResponse.Builder setField​(com.google.protobuf.Descriptors.FieldDescriptor field,
                                                Object value)
        Specified by:
        setField in interface com.google.protobuf.Message.Builder
        Overrides:
        setField in class com.google.protobuf.GeneratedMessageV3.Builder<WebhookResponse.Builder>
      • clearField

        public WebhookResponse.Builder clearField​(com.google.protobuf.Descriptors.FieldDescriptor field)
        Specified by:
        clearField in interface com.google.protobuf.Message.Builder
        Overrides:
        clearField in class com.google.protobuf.GeneratedMessageV3.Builder<WebhookResponse.Builder>
      • clearOneof

        public WebhookResponse.Builder clearOneof​(com.google.protobuf.Descriptors.OneofDescriptor oneof)
        Specified by:
        clearOneof in interface com.google.protobuf.Message.Builder
        Overrides:
        clearOneof in class com.google.protobuf.GeneratedMessageV3.Builder<WebhookResponse.Builder>
      • setRepeatedField

        public WebhookResponse.Builder setRepeatedField​(com.google.protobuf.Descriptors.FieldDescriptor field,
                                                        int index,
                                                        Object value)
        Specified by:
        setRepeatedField in interface com.google.protobuf.Message.Builder
        Overrides:
        setRepeatedField in class com.google.protobuf.GeneratedMessageV3.Builder<WebhookResponse.Builder>
      • addRepeatedField

        public WebhookResponse.Builder addRepeatedField​(com.google.protobuf.Descriptors.FieldDescriptor field,
                                                        Object value)
        Specified by:
        addRepeatedField in interface com.google.protobuf.Message.Builder
        Overrides:
        addRepeatedField in class com.google.protobuf.GeneratedMessageV3.Builder<WebhookResponse.Builder>
      • mergeFrom

        public WebhookResponse.Builder mergeFrom​(com.google.protobuf.Message other)
        Specified by:
        mergeFrom in interface com.google.protobuf.Message.Builder
        Overrides:
        mergeFrom in class com.google.protobuf.AbstractMessage.Builder<WebhookResponse.Builder>
      • isInitialized

        public final boolean isInitialized()
        Specified by:
        isInitialized in interface com.google.protobuf.MessageLiteOrBuilder
        Overrides:
        isInitialized in class com.google.protobuf.GeneratedMessageV3.Builder<WebhookResponse.Builder>
      • mergeFrom

        public WebhookResponse.Builder mergeFrom​(com.google.protobuf.CodedInputStream input,
                                                 com.google.protobuf.ExtensionRegistryLite extensionRegistry)
                                          throws IOException
        Specified by:
        mergeFrom in interface com.google.protobuf.Message.Builder
        Specified by:
        mergeFrom in interface com.google.protobuf.MessageLite.Builder
        Overrides:
        mergeFrom in class com.google.protobuf.AbstractMessage.Builder<WebhookResponse.Builder>
        Throws:
        IOException
      • getFulfillmentText

        public String getFulfillmentText()
         Optional. The text response message intended for the end-user.
         It is recommended to use `fulfillment_messages.text.text[0]` instead.
         When provided, Dialogflow uses this field to populate
         [QueryResult.fulfillment_text][google.cloud.dialogflow.v2.QueryResult.fulfillment_text]
         sent to the integration or API caller.
         
        string fulfillment_text = 1;
        Specified by:
        getFulfillmentText in interface WebhookResponseOrBuilder
        Returns:
        The fulfillmentText.
      • getFulfillmentTextBytes

        public com.google.protobuf.ByteString getFulfillmentTextBytes()
         Optional. The text response message intended for the end-user.
         It is recommended to use `fulfillment_messages.text.text[0]` instead.
         When provided, Dialogflow uses this field to populate
         [QueryResult.fulfillment_text][google.cloud.dialogflow.v2.QueryResult.fulfillment_text]
         sent to the integration or API caller.
         
        string fulfillment_text = 1;
        Specified by:
        getFulfillmentTextBytes in interface WebhookResponseOrBuilder
        Returns:
        The bytes for fulfillmentText.
      • setFulfillmentText

        public WebhookResponse.Builder setFulfillmentText​(String value)
         Optional. The text response message intended for the end-user.
         It is recommended to use `fulfillment_messages.text.text[0]` instead.
         When provided, Dialogflow uses this field to populate
         [QueryResult.fulfillment_text][google.cloud.dialogflow.v2.QueryResult.fulfillment_text]
         sent to the integration or API caller.
         
        string fulfillment_text = 1;
        Parameters:
        value - The fulfillmentText to set.
        Returns:
        This builder for chaining.
      • clearFulfillmentText

        public WebhookResponse.Builder clearFulfillmentText()
         Optional. The text response message intended for the end-user.
         It is recommended to use `fulfillment_messages.text.text[0]` instead.
         When provided, Dialogflow uses this field to populate
         [QueryResult.fulfillment_text][google.cloud.dialogflow.v2.QueryResult.fulfillment_text]
         sent to the integration or API caller.
         
        string fulfillment_text = 1;
        Returns:
        This builder for chaining.
      • setFulfillmentTextBytes

        public WebhookResponse.Builder setFulfillmentTextBytes​(com.google.protobuf.ByteString value)
         Optional. The text response message intended for the end-user.
         It is recommended to use `fulfillment_messages.text.text[0]` instead.
         When provided, Dialogflow uses this field to populate
         [QueryResult.fulfillment_text][google.cloud.dialogflow.v2.QueryResult.fulfillment_text]
         sent to the integration or API caller.
         
        string fulfillment_text = 1;
        Parameters:
        value - The bytes for fulfillmentText to set.
        Returns:
        This builder for chaining.
      • getFulfillmentMessagesList

        public List<Intent.Message> getFulfillmentMessagesList()
         Optional. The rich response messages intended for the end-user.
         When provided, Dialogflow uses this field to populate
         [QueryResult.fulfillment_messages][google.cloud.dialogflow.v2.QueryResult.fulfillment_messages]
         sent to the integration or API caller.
         
        repeated .google.cloud.dialogflow.v2.Intent.Message fulfillment_messages = 2;
        Specified by:
        getFulfillmentMessagesList in interface WebhookResponseOrBuilder
      • getFulfillmentMessagesCount

        public int getFulfillmentMessagesCount()
         Optional. The rich response messages intended for the end-user.
         When provided, Dialogflow uses this field to populate
         [QueryResult.fulfillment_messages][google.cloud.dialogflow.v2.QueryResult.fulfillment_messages]
         sent to the integration or API caller.
         
        repeated .google.cloud.dialogflow.v2.Intent.Message fulfillment_messages = 2;
        Specified by:
        getFulfillmentMessagesCount in interface WebhookResponseOrBuilder
      • getFulfillmentMessages

        public Intent.Message getFulfillmentMessages​(int index)
         Optional. The rich response messages intended for the end-user.
         When provided, Dialogflow uses this field to populate
         [QueryResult.fulfillment_messages][google.cloud.dialogflow.v2.QueryResult.fulfillment_messages]
         sent to the integration or API caller.
         
        repeated .google.cloud.dialogflow.v2.Intent.Message fulfillment_messages = 2;
        Specified by:
        getFulfillmentMessages in interface WebhookResponseOrBuilder
      • setFulfillmentMessages

        public WebhookResponse.Builder setFulfillmentMessages​(int index,
                                                              Intent.Message value)
         Optional. The rich response messages intended for the end-user.
         When provided, Dialogflow uses this field to populate
         [QueryResult.fulfillment_messages][google.cloud.dialogflow.v2.QueryResult.fulfillment_messages]
         sent to the integration or API caller.
         
        repeated .google.cloud.dialogflow.v2.Intent.Message fulfillment_messages = 2;
      • setFulfillmentMessages

        public WebhookResponse.Builder setFulfillmentMessages​(int index,
                                                              Intent.Message.Builder builderForValue)
         Optional. The rich response messages intended for the end-user.
         When provided, Dialogflow uses this field to populate
         [QueryResult.fulfillment_messages][google.cloud.dialogflow.v2.QueryResult.fulfillment_messages]
         sent to the integration or API caller.
         
        repeated .google.cloud.dialogflow.v2.Intent.Message fulfillment_messages = 2;
      • addFulfillmentMessages

        public WebhookResponse.Builder addFulfillmentMessages​(Intent.Message value)
         Optional. The rich response messages intended for the end-user.
         When provided, Dialogflow uses this field to populate
         [QueryResult.fulfillment_messages][google.cloud.dialogflow.v2.QueryResult.fulfillment_messages]
         sent to the integration or API caller.
         
        repeated .google.cloud.dialogflow.v2.Intent.Message fulfillment_messages = 2;
      • addFulfillmentMessages

        public WebhookResponse.Builder addFulfillmentMessages​(int index,
                                                              Intent.Message value)
         Optional. The rich response messages intended for the end-user.
         When provided, Dialogflow uses this field to populate
         [QueryResult.fulfillment_messages][google.cloud.dialogflow.v2.QueryResult.fulfillment_messages]
         sent to the integration or API caller.
         
        repeated .google.cloud.dialogflow.v2.Intent.Message fulfillment_messages = 2;
      • addFulfillmentMessages

        public WebhookResponse.Builder addFulfillmentMessages​(Intent.Message.Builder builderForValue)
         Optional. The rich response messages intended for the end-user.
         When provided, Dialogflow uses this field to populate
         [QueryResult.fulfillment_messages][google.cloud.dialogflow.v2.QueryResult.fulfillment_messages]
         sent to the integration or API caller.
         
        repeated .google.cloud.dialogflow.v2.Intent.Message fulfillment_messages = 2;
      • addFulfillmentMessages

        public WebhookResponse.Builder addFulfillmentMessages​(int index,
                                                              Intent.Message.Builder builderForValue)
         Optional. The rich response messages intended for the end-user.
         When provided, Dialogflow uses this field to populate
         [QueryResult.fulfillment_messages][google.cloud.dialogflow.v2.QueryResult.fulfillment_messages]
         sent to the integration or API caller.
         
        repeated .google.cloud.dialogflow.v2.Intent.Message fulfillment_messages = 2;
      • addAllFulfillmentMessages

        public WebhookResponse.Builder addAllFulfillmentMessages​(Iterable<? extends Intent.Message> values)
         Optional. The rich response messages intended for the end-user.
         When provided, Dialogflow uses this field to populate
         [QueryResult.fulfillment_messages][google.cloud.dialogflow.v2.QueryResult.fulfillment_messages]
         sent to the integration or API caller.
         
        repeated .google.cloud.dialogflow.v2.Intent.Message fulfillment_messages = 2;
      • clearFulfillmentMessages

        public WebhookResponse.Builder clearFulfillmentMessages()
         Optional. The rich response messages intended for the end-user.
         When provided, Dialogflow uses this field to populate
         [QueryResult.fulfillment_messages][google.cloud.dialogflow.v2.QueryResult.fulfillment_messages]
         sent to the integration or API caller.
         
        repeated .google.cloud.dialogflow.v2.Intent.Message fulfillment_messages = 2;
      • removeFulfillmentMessages

        public WebhookResponse.Builder removeFulfillmentMessages​(int index)
         Optional. The rich response messages intended for the end-user.
         When provided, Dialogflow uses this field to populate
         [QueryResult.fulfillment_messages][google.cloud.dialogflow.v2.QueryResult.fulfillment_messages]
         sent to the integration or API caller.
         
        repeated .google.cloud.dialogflow.v2.Intent.Message fulfillment_messages = 2;
      • getFulfillmentMessagesBuilder

        public Intent.Message.Builder getFulfillmentMessagesBuilder​(int index)
         Optional. The rich response messages intended for the end-user.
         When provided, Dialogflow uses this field to populate
         [QueryResult.fulfillment_messages][google.cloud.dialogflow.v2.QueryResult.fulfillment_messages]
         sent to the integration or API caller.
         
        repeated .google.cloud.dialogflow.v2.Intent.Message fulfillment_messages = 2;
      • getFulfillmentMessagesOrBuilder

        public Intent.MessageOrBuilder getFulfillmentMessagesOrBuilder​(int index)
         Optional. The rich response messages intended for the end-user.
         When provided, Dialogflow uses this field to populate
         [QueryResult.fulfillment_messages][google.cloud.dialogflow.v2.QueryResult.fulfillment_messages]
         sent to the integration or API caller.
         
        repeated .google.cloud.dialogflow.v2.Intent.Message fulfillment_messages = 2;
        Specified by:
        getFulfillmentMessagesOrBuilder in interface WebhookResponseOrBuilder
      • getFulfillmentMessagesOrBuilderList

        public List<? extends Intent.MessageOrBuilder> getFulfillmentMessagesOrBuilderList()
         Optional. The rich response messages intended for the end-user.
         When provided, Dialogflow uses this field to populate
         [QueryResult.fulfillment_messages][google.cloud.dialogflow.v2.QueryResult.fulfillment_messages]
         sent to the integration or API caller.
         
        repeated .google.cloud.dialogflow.v2.Intent.Message fulfillment_messages = 2;
        Specified by:
        getFulfillmentMessagesOrBuilderList in interface WebhookResponseOrBuilder
      • addFulfillmentMessagesBuilder

        public Intent.Message.Builder addFulfillmentMessagesBuilder()
         Optional. The rich response messages intended for the end-user.
         When provided, Dialogflow uses this field to populate
         [QueryResult.fulfillment_messages][google.cloud.dialogflow.v2.QueryResult.fulfillment_messages]
         sent to the integration or API caller.
         
        repeated .google.cloud.dialogflow.v2.Intent.Message fulfillment_messages = 2;
      • addFulfillmentMessagesBuilder

        public Intent.Message.Builder addFulfillmentMessagesBuilder​(int index)
         Optional. The rich response messages intended for the end-user.
         When provided, Dialogflow uses this field to populate
         [QueryResult.fulfillment_messages][google.cloud.dialogflow.v2.QueryResult.fulfillment_messages]
         sent to the integration or API caller.
         
        repeated .google.cloud.dialogflow.v2.Intent.Message fulfillment_messages = 2;
      • getFulfillmentMessagesBuilderList

        public List<Intent.Message.Builder> getFulfillmentMessagesBuilderList()
         Optional. The rich response messages intended for the end-user.
         When provided, Dialogflow uses this field to populate
         [QueryResult.fulfillment_messages][google.cloud.dialogflow.v2.QueryResult.fulfillment_messages]
         sent to the integration or API caller.
         
        repeated .google.cloud.dialogflow.v2.Intent.Message fulfillment_messages = 2;
      • getSource

        public String getSource()
         Optional. A custom field used to identify the webhook source.
         Arbitrary strings are supported.
         When provided, Dialogflow uses this field to populate
         [QueryResult.webhook_source][google.cloud.dialogflow.v2.QueryResult.webhook_source]
         sent to the integration or API caller.
         
        string source = 3;
        Specified by:
        getSource in interface WebhookResponseOrBuilder
        Returns:
        The source.
      • getSourceBytes

        public com.google.protobuf.ByteString getSourceBytes()
         Optional. A custom field used to identify the webhook source.
         Arbitrary strings are supported.
         When provided, Dialogflow uses this field to populate
         [QueryResult.webhook_source][google.cloud.dialogflow.v2.QueryResult.webhook_source]
         sent to the integration or API caller.
         
        string source = 3;
        Specified by:
        getSourceBytes in interface WebhookResponseOrBuilder
        Returns:
        The bytes for source.
      • setSource

        public WebhookResponse.Builder setSource​(String value)
         Optional. A custom field used to identify the webhook source.
         Arbitrary strings are supported.
         When provided, Dialogflow uses this field to populate
         [QueryResult.webhook_source][google.cloud.dialogflow.v2.QueryResult.webhook_source]
         sent to the integration or API caller.
         
        string source = 3;
        Parameters:
        value - The source to set.
        Returns:
        This builder for chaining.
      • clearSource

        public WebhookResponse.Builder clearSource()
         Optional. A custom field used to identify the webhook source.
         Arbitrary strings are supported.
         When provided, Dialogflow uses this field to populate
         [QueryResult.webhook_source][google.cloud.dialogflow.v2.QueryResult.webhook_source]
         sent to the integration or API caller.
         
        string source = 3;
        Returns:
        This builder for chaining.
      • setSourceBytes

        public WebhookResponse.Builder setSourceBytes​(com.google.protobuf.ByteString value)
         Optional. A custom field used to identify the webhook source.
         Arbitrary strings are supported.
         When provided, Dialogflow uses this field to populate
         [QueryResult.webhook_source][google.cloud.dialogflow.v2.QueryResult.webhook_source]
         sent to the integration or API caller.
         
        string source = 3;
        Parameters:
        value - The bytes for source to set.
        Returns:
        This builder for chaining.
      • hasPayload

        public boolean hasPayload()
         Optional. This field can be used to pass custom data from your webhook to
         the integration or API caller. Arbitrary JSON objects are supported. When
         provided, Dialogflow uses this field to populate
         [QueryResult.webhook_payload][google.cloud.dialogflow.v2.QueryResult.webhook_payload]
         sent to the integration or API caller. This field is also used by the
         [Google Assistant
         integration](https://cloud.google.com/dialogflow/docs/integrations/aog)
         for rich response messages.
         See the format definition at [Google Assistant Dialogflow webhook
         format](https://developers.google.com/assistant/actions/build/json/dialogflow-webhook-json)
         
        .google.protobuf.Struct payload = 4;
        Specified by:
        hasPayload in interface WebhookResponseOrBuilder
        Returns:
        Whether the payload field is set.
      • getPayload

        public com.google.protobuf.Struct getPayload()
         Optional. This field can be used to pass custom data from your webhook to
         the integration or API caller. Arbitrary JSON objects are supported. When
         provided, Dialogflow uses this field to populate
         [QueryResult.webhook_payload][google.cloud.dialogflow.v2.QueryResult.webhook_payload]
         sent to the integration or API caller. This field is also used by the
         [Google Assistant
         integration](https://cloud.google.com/dialogflow/docs/integrations/aog)
         for rich response messages.
         See the format definition at [Google Assistant Dialogflow webhook
         format](https://developers.google.com/assistant/actions/build/json/dialogflow-webhook-json)
         
        .google.protobuf.Struct payload = 4;
        Specified by:
        getPayload in interface WebhookResponseOrBuilder
        Returns:
        The payload.
      • setPayload

        public WebhookResponse.Builder setPayload​(com.google.protobuf.Struct value)
         Optional. This field can be used to pass custom data from your webhook to
         the integration or API caller. Arbitrary JSON objects are supported. When
         provided, Dialogflow uses this field to populate
         [QueryResult.webhook_payload][google.cloud.dialogflow.v2.QueryResult.webhook_payload]
         sent to the integration or API caller. This field is also used by the
         [Google Assistant
         integration](https://cloud.google.com/dialogflow/docs/integrations/aog)
         for rich response messages.
         See the format definition at [Google Assistant Dialogflow webhook
         format](https://developers.google.com/assistant/actions/build/json/dialogflow-webhook-json)
         
        .google.protobuf.Struct payload = 4;
      • setPayload

        public WebhookResponse.Builder setPayload​(com.google.protobuf.Struct.Builder builderForValue)
         Optional. This field can be used to pass custom data from your webhook to
         the integration or API caller. Arbitrary JSON objects are supported. When
         provided, Dialogflow uses this field to populate
         [QueryResult.webhook_payload][google.cloud.dialogflow.v2.QueryResult.webhook_payload]
         sent to the integration or API caller. This field is also used by the
         [Google Assistant
         integration](https://cloud.google.com/dialogflow/docs/integrations/aog)
         for rich response messages.
         See the format definition at [Google Assistant Dialogflow webhook
         format](https://developers.google.com/assistant/actions/build/json/dialogflow-webhook-json)
         
        .google.protobuf.Struct payload = 4;
      • mergePayload

        public WebhookResponse.Builder mergePayload​(com.google.protobuf.Struct value)
         Optional. This field can be used to pass custom data from your webhook to
         the integration or API caller. Arbitrary JSON objects are supported. When
         provided, Dialogflow uses this field to populate
         [QueryResult.webhook_payload][google.cloud.dialogflow.v2.QueryResult.webhook_payload]
         sent to the integration or API caller. This field is also used by the
         [Google Assistant
         integration](https://cloud.google.com/dialogflow/docs/integrations/aog)
         for rich response messages.
         See the format definition at [Google Assistant Dialogflow webhook
         format](https://developers.google.com/assistant/actions/build/json/dialogflow-webhook-json)
         
        .google.protobuf.Struct payload = 4;
      • clearPayload

        public WebhookResponse.Builder clearPayload()
         Optional. This field can be used to pass custom data from your webhook to
         the integration or API caller. Arbitrary JSON objects are supported. When
         provided, Dialogflow uses this field to populate
         [QueryResult.webhook_payload][google.cloud.dialogflow.v2.QueryResult.webhook_payload]
         sent to the integration or API caller. This field is also used by the
         [Google Assistant
         integration](https://cloud.google.com/dialogflow/docs/integrations/aog)
         for rich response messages.
         See the format definition at [Google Assistant Dialogflow webhook
         format](https://developers.google.com/assistant/actions/build/json/dialogflow-webhook-json)
         
        .google.protobuf.Struct payload = 4;
      • getPayloadBuilder

        public com.google.protobuf.Struct.Builder getPayloadBuilder()
         Optional. This field can be used to pass custom data from your webhook to
         the integration or API caller. Arbitrary JSON objects are supported. When
         provided, Dialogflow uses this field to populate
         [QueryResult.webhook_payload][google.cloud.dialogflow.v2.QueryResult.webhook_payload]
         sent to the integration or API caller. This field is also used by the
         [Google Assistant
         integration](https://cloud.google.com/dialogflow/docs/integrations/aog)
         for rich response messages.
         See the format definition at [Google Assistant Dialogflow webhook
         format](https://developers.google.com/assistant/actions/build/json/dialogflow-webhook-json)
         
        .google.protobuf.Struct payload = 4;
      • getPayloadOrBuilder

        public com.google.protobuf.StructOrBuilder getPayloadOrBuilder()
         Optional. This field can be used to pass custom data from your webhook to
         the integration or API caller. Arbitrary JSON objects are supported. When
         provided, Dialogflow uses this field to populate
         [QueryResult.webhook_payload][google.cloud.dialogflow.v2.QueryResult.webhook_payload]
         sent to the integration or API caller. This field is also used by the
         [Google Assistant
         integration](https://cloud.google.com/dialogflow/docs/integrations/aog)
         for rich response messages.
         See the format definition at [Google Assistant Dialogflow webhook
         format](https://developers.google.com/assistant/actions/build/json/dialogflow-webhook-json)
         
        .google.protobuf.Struct payload = 4;
        Specified by:
        getPayloadOrBuilder in interface WebhookResponseOrBuilder
      • getOutputContextsList

        public List<Context> getOutputContextsList()
         Optional. The collection of output contexts that will overwrite currently
         active contexts for the session and reset their lifespans.
         When provided, Dialogflow uses this field to populate
         [QueryResult.output_contexts][google.cloud.dialogflow.v2.QueryResult.output_contexts]
         sent to the integration or API caller.
         
        repeated .google.cloud.dialogflow.v2.Context output_contexts = 5;
        Specified by:
        getOutputContextsList in interface WebhookResponseOrBuilder
      • getOutputContextsCount

        public int getOutputContextsCount()
         Optional. The collection of output contexts that will overwrite currently
         active contexts for the session and reset their lifespans.
         When provided, Dialogflow uses this field to populate
         [QueryResult.output_contexts][google.cloud.dialogflow.v2.QueryResult.output_contexts]
         sent to the integration or API caller.
         
        repeated .google.cloud.dialogflow.v2.Context output_contexts = 5;
        Specified by:
        getOutputContextsCount in interface WebhookResponseOrBuilder
      • getOutputContexts

        public Context getOutputContexts​(int index)
         Optional. The collection of output contexts that will overwrite currently
         active contexts for the session and reset their lifespans.
         When provided, Dialogflow uses this field to populate
         [QueryResult.output_contexts][google.cloud.dialogflow.v2.QueryResult.output_contexts]
         sent to the integration or API caller.
         
        repeated .google.cloud.dialogflow.v2.Context output_contexts = 5;
        Specified by:
        getOutputContexts in interface WebhookResponseOrBuilder
      • setOutputContexts

        public WebhookResponse.Builder setOutputContexts​(int index,
                                                         Context value)
         Optional. The collection of output contexts that will overwrite currently
         active contexts for the session and reset their lifespans.
         When provided, Dialogflow uses this field to populate
         [QueryResult.output_contexts][google.cloud.dialogflow.v2.QueryResult.output_contexts]
         sent to the integration or API caller.
         
        repeated .google.cloud.dialogflow.v2.Context output_contexts = 5;
      • setOutputContexts

        public WebhookResponse.Builder setOutputContexts​(int index,
                                                         Context.Builder builderForValue)
         Optional. The collection of output contexts that will overwrite currently
         active contexts for the session and reset their lifespans.
         When provided, Dialogflow uses this field to populate
         [QueryResult.output_contexts][google.cloud.dialogflow.v2.QueryResult.output_contexts]
         sent to the integration or API caller.
         
        repeated .google.cloud.dialogflow.v2.Context output_contexts = 5;
      • addOutputContexts

        public WebhookResponse.Builder addOutputContexts​(Context value)
         Optional. The collection of output contexts that will overwrite currently
         active contexts for the session and reset their lifespans.
         When provided, Dialogflow uses this field to populate
         [QueryResult.output_contexts][google.cloud.dialogflow.v2.QueryResult.output_contexts]
         sent to the integration or API caller.
         
        repeated .google.cloud.dialogflow.v2.Context output_contexts = 5;
      • addOutputContexts

        public WebhookResponse.Builder addOutputContexts​(int index,
                                                         Context value)
         Optional. The collection of output contexts that will overwrite currently
         active contexts for the session and reset their lifespans.
         When provided, Dialogflow uses this field to populate
         [QueryResult.output_contexts][google.cloud.dialogflow.v2.QueryResult.output_contexts]
         sent to the integration or API caller.
         
        repeated .google.cloud.dialogflow.v2.Context output_contexts = 5;
      • addOutputContexts

        public WebhookResponse.Builder addOutputContexts​(Context.Builder builderForValue)
         Optional. The collection of output contexts that will overwrite currently
         active contexts for the session and reset their lifespans.
         When provided, Dialogflow uses this field to populate
         [QueryResult.output_contexts][google.cloud.dialogflow.v2.QueryResult.output_contexts]
         sent to the integration or API caller.
         
        repeated .google.cloud.dialogflow.v2.Context output_contexts = 5;
      • addOutputContexts

        public WebhookResponse.Builder addOutputContexts​(int index,
                                                         Context.Builder builderForValue)
         Optional. The collection of output contexts that will overwrite currently
         active contexts for the session and reset their lifespans.
         When provided, Dialogflow uses this field to populate
         [QueryResult.output_contexts][google.cloud.dialogflow.v2.QueryResult.output_contexts]
         sent to the integration or API caller.
         
        repeated .google.cloud.dialogflow.v2.Context output_contexts = 5;
      • addAllOutputContexts

        public WebhookResponse.Builder addAllOutputContexts​(Iterable<? extends Context> values)
         Optional. The collection of output contexts that will overwrite currently
         active contexts for the session and reset their lifespans.
         When provided, Dialogflow uses this field to populate
         [QueryResult.output_contexts][google.cloud.dialogflow.v2.QueryResult.output_contexts]
         sent to the integration or API caller.
         
        repeated .google.cloud.dialogflow.v2.Context output_contexts = 5;
      • clearOutputContexts

        public WebhookResponse.Builder clearOutputContexts()
         Optional. The collection of output contexts that will overwrite currently
         active contexts for the session and reset their lifespans.
         When provided, Dialogflow uses this field to populate
         [QueryResult.output_contexts][google.cloud.dialogflow.v2.QueryResult.output_contexts]
         sent to the integration or API caller.
         
        repeated .google.cloud.dialogflow.v2.Context output_contexts = 5;
      • removeOutputContexts

        public WebhookResponse.Builder removeOutputContexts​(int index)
         Optional. The collection of output contexts that will overwrite currently
         active contexts for the session and reset their lifespans.
         When provided, Dialogflow uses this field to populate
         [QueryResult.output_contexts][google.cloud.dialogflow.v2.QueryResult.output_contexts]
         sent to the integration or API caller.
         
        repeated .google.cloud.dialogflow.v2.Context output_contexts = 5;
      • getOutputContextsBuilder

        public Context.Builder getOutputContextsBuilder​(int index)
         Optional. The collection of output contexts that will overwrite currently
         active contexts for the session and reset their lifespans.
         When provided, Dialogflow uses this field to populate
         [QueryResult.output_contexts][google.cloud.dialogflow.v2.QueryResult.output_contexts]
         sent to the integration or API caller.
         
        repeated .google.cloud.dialogflow.v2.Context output_contexts = 5;
      • getOutputContextsOrBuilder

        public ContextOrBuilder getOutputContextsOrBuilder​(int index)
         Optional. The collection of output contexts that will overwrite currently
         active contexts for the session and reset their lifespans.
         When provided, Dialogflow uses this field to populate
         [QueryResult.output_contexts][google.cloud.dialogflow.v2.QueryResult.output_contexts]
         sent to the integration or API caller.
         
        repeated .google.cloud.dialogflow.v2.Context output_contexts = 5;
        Specified by:
        getOutputContextsOrBuilder in interface WebhookResponseOrBuilder
      • getOutputContextsOrBuilderList

        public List<? extends ContextOrBuilder> getOutputContextsOrBuilderList()
         Optional. The collection of output contexts that will overwrite currently
         active contexts for the session and reset their lifespans.
         When provided, Dialogflow uses this field to populate
         [QueryResult.output_contexts][google.cloud.dialogflow.v2.QueryResult.output_contexts]
         sent to the integration or API caller.
         
        repeated .google.cloud.dialogflow.v2.Context output_contexts = 5;
        Specified by:
        getOutputContextsOrBuilderList in interface WebhookResponseOrBuilder
      • addOutputContextsBuilder

        public Context.Builder addOutputContextsBuilder()
         Optional. The collection of output contexts that will overwrite currently
         active contexts for the session and reset their lifespans.
         When provided, Dialogflow uses this field to populate
         [QueryResult.output_contexts][google.cloud.dialogflow.v2.QueryResult.output_contexts]
         sent to the integration or API caller.
         
        repeated .google.cloud.dialogflow.v2.Context output_contexts = 5;
      • addOutputContextsBuilder

        public Context.Builder addOutputContextsBuilder​(int index)
         Optional. The collection of output contexts that will overwrite currently
         active contexts for the session and reset their lifespans.
         When provided, Dialogflow uses this field to populate
         [QueryResult.output_contexts][google.cloud.dialogflow.v2.QueryResult.output_contexts]
         sent to the integration or API caller.
         
        repeated .google.cloud.dialogflow.v2.Context output_contexts = 5;
      • getOutputContextsBuilderList

        public List<Context.Builder> getOutputContextsBuilderList()
         Optional. The collection of output contexts that will overwrite currently
         active contexts for the session and reset their lifespans.
         When provided, Dialogflow uses this field to populate
         [QueryResult.output_contexts][google.cloud.dialogflow.v2.QueryResult.output_contexts]
         sent to the integration or API caller.
         
        repeated .google.cloud.dialogflow.v2.Context output_contexts = 5;
      • hasFollowupEventInput

        public boolean hasFollowupEventInput()
         Optional. Invokes the supplied events.
         When this field is set, Dialogflow ignores the `fulfillment_text`,
         `fulfillment_messages`, and `payload` fields.
         
        .google.cloud.dialogflow.v2.EventInput followup_event_input = 6;
        Specified by:
        hasFollowupEventInput in interface WebhookResponseOrBuilder
        Returns:
        Whether the followupEventInput field is set.
      • getFollowupEventInput

        public EventInput getFollowupEventInput()
         Optional. Invokes the supplied events.
         When this field is set, Dialogflow ignores the `fulfillment_text`,
         `fulfillment_messages`, and `payload` fields.
         
        .google.cloud.dialogflow.v2.EventInput followup_event_input = 6;
        Specified by:
        getFollowupEventInput in interface WebhookResponseOrBuilder
        Returns:
        The followupEventInput.
      • setFollowupEventInput

        public WebhookResponse.Builder setFollowupEventInput​(EventInput value)
         Optional. Invokes the supplied events.
         When this field is set, Dialogflow ignores the `fulfillment_text`,
         `fulfillment_messages`, and `payload` fields.
         
        .google.cloud.dialogflow.v2.EventInput followup_event_input = 6;
      • setFollowupEventInput

        public WebhookResponse.Builder setFollowupEventInput​(EventInput.Builder builderForValue)
         Optional. Invokes the supplied events.
         When this field is set, Dialogflow ignores the `fulfillment_text`,
         `fulfillment_messages`, and `payload` fields.
         
        .google.cloud.dialogflow.v2.EventInput followup_event_input = 6;
      • mergeFollowupEventInput

        public WebhookResponse.Builder mergeFollowupEventInput​(EventInput value)
         Optional. Invokes the supplied events.
         When this field is set, Dialogflow ignores the `fulfillment_text`,
         `fulfillment_messages`, and `payload` fields.
         
        .google.cloud.dialogflow.v2.EventInput followup_event_input = 6;
      • clearFollowupEventInput

        public WebhookResponse.Builder clearFollowupEventInput()
         Optional. Invokes the supplied events.
         When this field is set, Dialogflow ignores the `fulfillment_text`,
         `fulfillment_messages`, and `payload` fields.
         
        .google.cloud.dialogflow.v2.EventInput followup_event_input = 6;
      • getFollowupEventInputBuilder

        public EventInput.Builder getFollowupEventInputBuilder()
         Optional. Invokes the supplied events.
         When this field is set, Dialogflow ignores the `fulfillment_text`,
         `fulfillment_messages`, and `payload` fields.
         
        .google.cloud.dialogflow.v2.EventInput followup_event_input = 6;
      • getFollowupEventInputOrBuilder

        public EventInputOrBuilder getFollowupEventInputOrBuilder()
         Optional. Invokes the supplied events.
         When this field is set, Dialogflow ignores the `fulfillment_text`,
         `fulfillment_messages`, and `payload` fields.
         
        .google.cloud.dialogflow.v2.EventInput followup_event_input = 6;
        Specified by:
        getFollowupEventInputOrBuilder in interface WebhookResponseOrBuilder
      • getSessionEntityTypesList

        public List<SessionEntityType> getSessionEntityTypesList()
         Optional. Additional session entity types to replace or extend developer
         entity types with. The entity synonyms apply to all languages and persist
         for the session. Setting this data from a webhook overwrites
         the session entity types that have been set using `detectIntent`,
         `streamingDetectIntent` or
         [SessionEntityType][google.cloud.dialogflow.v2.SessionEntityType]
         management methods.
         
        repeated .google.cloud.dialogflow.v2.SessionEntityType session_entity_types = 10;
        Specified by:
        getSessionEntityTypesList in interface WebhookResponseOrBuilder
      • getSessionEntityTypesCount

        public int getSessionEntityTypesCount()
         Optional. Additional session entity types to replace or extend developer
         entity types with. The entity synonyms apply to all languages and persist
         for the session. Setting this data from a webhook overwrites
         the session entity types that have been set using `detectIntent`,
         `streamingDetectIntent` or
         [SessionEntityType][google.cloud.dialogflow.v2.SessionEntityType]
         management methods.
         
        repeated .google.cloud.dialogflow.v2.SessionEntityType session_entity_types = 10;
        Specified by:
        getSessionEntityTypesCount in interface WebhookResponseOrBuilder
      • getSessionEntityTypes

        public SessionEntityType getSessionEntityTypes​(int index)
         Optional. Additional session entity types to replace or extend developer
         entity types with. The entity synonyms apply to all languages and persist
         for the session. Setting this data from a webhook overwrites
         the session entity types that have been set using `detectIntent`,
         `streamingDetectIntent` or
         [SessionEntityType][google.cloud.dialogflow.v2.SessionEntityType]
         management methods.
         
        repeated .google.cloud.dialogflow.v2.SessionEntityType session_entity_types = 10;
        Specified by:
        getSessionEntityTypes in interface WebhookResponseOrBuilder
      • setSessionEntityTypes

        public WebhookResponse.Builder setSessionEntityTypes​(int index,
                                                             SessionEntityType value)
         Optional. Additional session entity types to replace or extend developer
         entity types with. The entity synonyms apply to all languages and persist
         for the session. Setting this data from a webhook overwrites
         the session entity types that have been set using `detectIntent`,
         `streamingDetectIntent` or
         [SessionEntityType][google.cloud.dialogflow.v2.SessionEntityType]
         management methods.
         
        repeated .google.cloud.dialogflow.v2.SessionEntityType session_entity_types = 10;
      • setSessionEntityTypes

        public WebhookResponse.Builder setSessionEntityTypes​(int index,
                                                             SessionEntityType.Builder builderForValue)
         Optional. Additional session entity types to replace or extend developer
         entity types with. The entity synonyms apply to all languages and persist
         for the session. Setting this data from a webhook overwrites
         the session entity types that have been set using `detectIntent`,
         `streamingDetectIntent` or
         [SessionEntityType][google.cloud.dialogflow.v2.SessionEntityType]
         management methods.
         
        repeated .google.cloud.dialogflow.v2.SessionEntityType session_entity_types = 10;
      • addSessionEntityTypes

        public WebhookResponse.Builder addSessionEntityTypes​(SessionEntityType value)
         Optional. Additional session entity types to replace or extend developer
         entity types with. The entity synonyms apply to all languages and persist
         for the session. Setting this data from a webhook overwrites
         the session entity types that have been set using `detectIntent`,
         `streamingDetectIntent` or
         [SessionEntityType][google.cloud.dialogflow.v2.SessionEntityType]
         management methods.
         
        repeated .google.cloud.dialogflow.v2.SessionEntityType session_entity_types = 10;
      • addSessionEntityTypes

        public WebhookResponse.Builder addSessionEntityTypes​(int index,
                                                             SessionEntityType value)
         Optional. Additional session entity types to replace or extend developer
         entity types with. The entity synonyms apply to all languages and persist
         for the session. Setting this data from a webhook overwrites
         the session entity types that have been set using `detectIntent`,
         `streamingDetectIntent` or
         [SessionEntityType][google.cloud.dialogflow.v2.SessionEntityType]
         management methods.
         
        repeated .google.cloud.dialogflow.v2.SessionEntityType session_entity_types = 10;
      • addSessionEntityTypes

        public WebhookResponse.Builder addSessionEntityTypes​(SessionEntityType.Builder builderForValue)
         Optional. Additional session entity types to replace or extend developer
         entity types with. The entity synonyms apply to all languages and persist
         for the session. Setting this data from a webhook overwrites
         the session entity types that have been set using `detectIntent`,
         `streamingDetectIntent` or
         [SessionEntityType][google.cloud.dialogflow.v2.SessionEntityType]
         management methods.
         
        repeated .google.cloud.dialogflow.v2.SessionEntityType session_entity_types = 10;
      • addSessionEntityTypes

        public WebhookResponse.Builder addSessionEntityTypes​(int index,
                                                             SessionEntityType.Builder builderForValue)
         Optional. Additional session entity types to replace or extend developer
         entity types with. The entity synonyms apply to all languages and persist
         for the session. Setting this data from a webhook overwrites
         the session entity types that have been set using `detectIntent`,
         `streamingDetectIntent` or
         [SessionEntityType][google.cloud.dialogflow.v2.SessionEntityType]
         management methods.
         
        repeated .google.cloud.dialogflow.v2.SessionEntityType session_entity_types = 10;
      • addAllSessionEntityTypes

        public WebhookResponse.Builder addAllSessionEntityTypes​(Iterable<? extends SessionEntityType> values)
         Optional. Additional session entity types to replace or extend developer
         entity types with. The entity synonyms apply to all languages and persist
         for the session. Setting this data from a webhook overwrites
         the session entity types that have been set using `detectIntent`,
         `streamingDetectIntent` or
         [SessionEntityType][google.cloud.dialogflow.v2.SessionEntityType]
         management methods.
         
        repeated .google.cloud.dialogflow.v2.SessionEntityType session_entity_types = 10;
      • clearSessionEntityTypes

        public WebhookResponse.Builder clearSessionEntityTypes()
         Optional. Additional session entity types to replace or extend developer
         entity types with. The entity synonyms apply to all languages and persist
         for the session. Setting this data from a webhook overwrites
         the session entity types that have been set using `detectIntent`,
         `streamingDetectIntent` or
         [SessionEntityType][google.cloud.dialogflow.v2.SessionEntityType]
         management methods.
         
        repeated .google.cloud.dialogflow.v2.SessionEntityType session_entity_types = 10;
      • removeSessionEntityTypes

        public WebhookResponse.Builder removeSessionEntityTypes​(int index)
         Optional. Additional session entity types to replace or extend developer
         entity types with. The entity synonyms apply to all languages and persist
         for the session. Setting this data from a webhook overwrites
         the session entity types that have been set using `detectIntent`,
         `streamingDetectIntent` or
         [SessionEntityType][google.cloud.dialogflow.v2.SessionEntityType]
         management methods.
         
        repeated .google.cloud.dialogflow.v2.SessionEntityType session_entity_types = 10;
      • getSessionEntityTypesBuilder

        public SessionEntityType.Builder getSessionEntityTypesBuilder​(int index)
         Optional. Additional session entity types to replace or extend developer
         entity types with. The entity synonyms apply to all languages and persist
         for the session. Setting this data from a webhook overwrites
         the session entity types that have been set using `detectIntent`,
         `streamingDetectIntent` or
         [SessionEntityType][google.cloud.dialogflow.v2.SessionEntityType]
         management methods.
         
        repeated .google.cloud.dialogflow.v2.SessionEntityType session_entity_types = 10;
      • getSessionEntityTypesOrBuilder

        public SessionEntityTypeOrBuilder getSessionEntityTypesOrBuilder​(int index)
         Optional. Additional session entity types to replace or extend developer
         entity types with. The entity synonyms apply to all languages and persist
         for the session. Setting this data from a webhook overwrites
         the session entity types that have been set using `detectIntent`,
         `streamingDetectIntent` or
         [SessionEntityType][google.cloud.dialogflow.v2.SessionEntityType]
         management methods.
         
        repeated .google.cloud.dialogflow.v2.SessionEntityType session_entity_types = 10;
        Specified by:
        getSessionEntityTypesOrBuilder in interface WebhookResponseOrBuilder
      • getSessionEntityTypesOrBuilderList

        public List<? extends SessionEntityTypeOrBuilder> getSessionEntityTypesOrBuilderList()
         Optional. Additional session entity types to replace or extend developer
         entity types with. The entity synonyms apply to all languages and persist
         for the session. Setting this data from a webhook overwrites
         the session entity types that have been set using `detectIntent`,
         `streamingDetectIntent` or
         [SessionEntityType][google.cloud.dialogflow.v2.SessionEntityType]
         management methods.
         
        repeated .google.cloud.dialogflow.v2.SessionEntityType session_entity_types = 10;
        Specified by:
        getSessionEntityTypesOrBuilderList in interface WebhookResponseOrBuilder
      • addSessionEntityTypesBuilder

        public SessionEntityType.Builder addSessionEntityTypesBuilder()
         Optional. Additional session entity types to replace or extend developer
         entity types with. The entity synonyms apply to all languages and persist
         for the session. Setting this data from a webhook overwrites
         the session entity types that have been set using `detectIntent`,
         `streamingDetectIntent` or
         [SessionEntityType][google.cloud.dialogflow.v2.SessionEntityType]
         management methods.
         
        repeated .google.cloud.dialogflow.v2.SessionEntityType session_entity_types = 10;
      • addSessionEntityTypesBuilder

        public SessionEntityType.Builder addSessionEntityTypesBuilder​(int index)
         Optional. Additional session entity types to replace or extend developer
         entity types with. The entity synonyms apply to all languages and persist
         for the session. Setting this data from a webhook overwrites
         the session entity types that have been set using `detectIntent`,
         `streamingDetectIntent` or
         [SessionEntityType][google.cloud.dialogflow.v2.SessionEntityType]
         management methods.
         
        repeated .google.cloud.dialogflow.v2.SessionEntityType session_entity_types = 10;
      • getSessionEntityTypesBuilderList

        public List<SessionEntityType.Builder> getSessionEntityTypesBuilderList()
         Optional. Additional session entity types to replace or extend developer
         entity types with. The entity synonyms apply to all languages and persist
         for the session. Setting this data from a webhook overwrites
         the session entity types that have been set using `detectIntent`,
         `streamingDetectIntent` or
         [SessionEntityType][google.cloud.dialogflow.v2.SessionEntityType]
         management methods.
         
        repeated .google.cloud.dialogflow.v2.SessionEntityType session_entity_types = 10;
      • setUnknownFields

        public final WebhookResponse.Builder setUnknownFields​(com.google.protobuf.UnknownFieldSet unknownFields)
        Specified by:
        setUnknownFields in interface com.google.protobuf.Message.Builder
        Overrides:
        setUnknownFields in class com.google.protobuf.GeneratedMessageV3.Builder<WebhookResponse.Builder>
      • mergeUnknownFields

        public final WebhookResponse.Builder mergeUnknownFields​(com.google.protobuf.UnknownFieldSet unknownFields)
        Specified by:
        mergeUnknownFields in interface com.google.protobuf.Message.Builder
        Overrides:
        mergeUnknownFields in class com.google.protobuf.GeneratedMessageV3.Builder<WebhookResponse.Builder>