Confluence message format
Default Message Template
{
"text":"<eventType> in <spaceLink> by <userLink>",
"attachments": [
{
"color": "#205081",
"title": "<contentTitle>",
"title_link": "<contentLink>",
"text": "<contentBody>"
}
]
}Basic Template Keys
These are available on all actions:
Key | Data | Description |
|---|---|---|
<spaceLink> |
| A link to the space, formatted for inclusion in a Slack message. |
<spaceKey> |
| A space key |
<contentTitle> |
| A page, blogpost title, task, question |
<contentLink> |
| A URL to the page, blog, task, or question |
<contentBody> |
| An excerpt of page, blog, task, comment |
<userLink> |
| A link to the user, formatted for a Slack message |
<userName> |
| A username |
<fullName> | Admin | A user full name |
<eventType> |
| Text describing the current action. |
<event> | EventType_CreatedPage | An event code |
Advanced Template Object Attributes
Attribute | Actions | Description | Example Usage |
|---|---|---|---|
isNewPage isNewBlogpost isNewComment | All | Returns a boolean that can be used with StringTemplate if statement expressions. |
|
page | Page Created |
| |
blogpost | Blog post Created |
| |
space | All |
| |
comment | Comment Created |
| |
question | Questions Created |
| |
answer | Questions Created |
| |
task | Task Created |
|
Possible to get user's full name like John Doe instead of jdoe?
Also is it possible to get the changed text from a page update? That stuff is included in the notification emails that confluence sends and is more useful for page updates than the full page text excerpt.
Also, can you include all of the possible ${eventType} texts in this doc? It might be better to keep them simple like "Page created", "Comment updated", etc. If you include too much text, the grammar becomes brittle. For example, "New page has created in Space" is actually not grammatically correct – "New page has been created" would be better. But if you keep it limited to "Page created", then the user can add "in space ${spaceKey}" themselves.