Class SlackFileObject

java.lang.Object
com.slack.api.model.block.composition.SlackFileObject

public class SlackFileObject extends Object
Defines an object containing Slack file information to be used in an image block or image element.

This file must be an image, and you must provide either the URL or ID. In addition, the user posting these blocks must have access to this file. If both are provided then the payload will be rejected. Currently only png, jpg, jpeg, and gif Slack image files are supported.

See Also:
  • Constructor Details

    • SlackFileObject

      public SlackFileObject()
    • SlackFileObject

      public SlackFileObject(String id, String url)
  • Method Details

    • builder

      public static SlackFileObject.SlackFileObjectBuilder builder()
    • getId

      public String getId()
      Slack ID of the file.
    • getUrl

      public String getUrl()
      This URL can be the url_private or the permalink of the Slack file.
    • setId

      public void setId(String id)
      Slack ID of the file.
    • setUrl

      public void setUrl(String url)
      This URL can be the url_private or the permalink of the Slack file.
    • equals

      public boolean equals(Object o)
      Overrides:
      equals in class Object
    • canEqual

      protected boolean canEqual(Object other)
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • toString

      public String toString()
      Overrides:
      toString in class Object