Class Dialog.DialogBuilder

java.lang.Object
com.slack.api.model.dialog.Dialog.DialogBuilder
Enclosing class:
Dialog

public static class Dialog.DialogBuilder
extends java.lang.Object
  • Method Summary

    Modifier and Type Method Description
    Dialog build()  
    Dialog.DialogBuilder callbackId​(java.lang.String callbackId)
    An identifier strictly for you to recognize submissions of this particular instance of a dialog.
    Dialog.DialogBuilder elements​(java.util.List<DialogElement> elements)
    Up to 5 form elements are allowed per dialog.
    Dialog.DialogBuilder notifyOnCancel​(boolean notifyOnCancel)
    Default is false.
    Dialog.DialogBuilder state​(java.lang.String state)
    An optional string that will be echoed back to your app when a user interacts with your dialog.
    Dialog.DialogBuilder submitLabel​(java.lang.String submitLabel)
    User-facing string for whichever button-like thing submits the form, depending on form factor.
    Dialog.DialogBuilder title​(java.lang.String title)
    User-facing title of this entire dialog.
    java.lang.String toString()  

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
  • Method Details

    • title

      public Dialog.DialogBuilder title​(java.lang.String title)
      User-facing title of this entire dialog. 24 characters to work with and it's required.
      Returns:
      this.
    • callbackId

      public Dialog.DialogBuilder callbackId​(java.lang.String callbackId)
      An identifier strictly for you to recognize submissions of this particular instance of a dialog. Use something meaningful to your app. 255 characters maximum. Absolutely required.
      Returns:
      this.
    • elements

      public Dialog.DialogBuilder elements​(java.util.List<DialogElement> elements)
      Up to 5 form elements are allowed per dialog. Required.
      Returns:
      this.
    • submitLabel

      public Dialog.DialogBuilder submitLabel​(java.lang.String submitLabel)
      User-facing string for whichever button-like thing submits the form, depending on form factor. Defaults to Submit, localized in whichever language the end user prefers. 24 characters maximum, and may contain only a single word.
      Returns:
      this.
    • notifyOnCancel

      public Dialog.DialogBuilder notifyOnCancel​(boolean notifyOnCancel)
      Default is false. When set to true, we'll notify your request URL whenever there's a user-induced dialog cancellation.
      Returns:
      this.
    • state

      public Dialog.DialogBuilder state​(java.lang.String state)
      An optional string that will be echoed back to your app when a user interacts with your dialog. Use it as a pointer to reference sensitive data stored elsewhere.
      Returns:
      this.
    • build

      public Dialog build()
    • toString

      public java.lang.String toString()
      Overrides:
      toString in class java.lang.Object