A message attachment lets us convey more content to the user, and lets it be displayed with more whistles and bells; but we have to keep an eye on a restriction imposed by Slack: no more than 20 attachments per message. It makes sense, otherwise our messages would be so messy that it would distract the average user.
What we have seen so far is a simple JSON: a one-level object, which is more or less like this example:
{
"text": "This is the first line of a messagen
This is the second line."
}
In a message attachment, though we are going to see more details, more content modifier, and a flat structure like the one we just saw that has not enough complexity to convey all the information. We need structured container, still a JSON; but this time, it will be an array holding several properties, which will resemble this snippet:
{
"...