"notifications" Macro
Reference
Description
The notifications Macro displays wiki events in the content of any page. In the macro list of the editors it appears as "Notifications".
Written without parameters it shows the most recent events of the current wiki, minus the reader's own. Its parameters move it in two directions: useUserPreferences turns it into the reader's own notifications, the ones the notifications menu shows, while wikis, spaces, pages, users and tags turn it into an activity stream for one part of the wiki.
The events are fetched after the page is displayed, so they appear a moment later. The macro shows count of them and ends with a "Load older notifications" button that fetches the next ones.
Usage
Write the macro on a line of its own. It takes no content, and every parameter is optional:
{{notifications /}}It is a block macro, so it cannot sit inside a sentence. In an editor it is inserted like any other macro, under the name "Notifications".

Parameters
| Name | Optional | Allowed values | Default value | Description |
|---|---|---|---|---|
| count | yes | a positive number | 10 | How many events are displayed at once. |
| useUserPreferences | yes | true or false | false | Whether the reader's own notification settings decide what is displayed. With true, wikis, spaces, pages, users, displayWatchedUsersOnly and tags are ignored. |
| displayOwnEvents | yes | true or false | false | Whether the reader's own actions are displayed. They are hidden by default. |
| displayMinorEvents | yes | true or false | false | Whether edits saved as minor are displayed. They are hidden by default. |
| displaySystemEvents | yes | true or false | false | Whether the events XWiki itself triggers are displayed. They are hidden by default. |
| displayReadEvents | yes | true or false | true | Whether the events the reader has already marked as read are displayed. |
| displayReadStatus | yes | true or false | true | Whether each event shows its read or unread status. That marker is also what carries the control marking an event as read. |
| wikis | yes | wiki names, comma-separated | The wikis whose events are displayed. | |
| spaces | yes | space references, comma-separated | The spaces whose events are displayed. | |
| pages | yes | full page references, comma-separated | The pages whose events are displayed. | |
| users | yes | user references, comma-separated | The users whose events are displayed. | |
| displayWatchedUsersOnly | yes | true or false | false | Whether only the events of the people the reader follows are displayed. With true the macro replaces whatever users holds with that list, and a reader who follows nobody sees the message "You are not following anybody." instead of events. |
| displayRSSLink | yes | true or false | true | Whether a link to the RSS feed of the same events is added below them. |
| tags | yes | tags, comma-separated | Only the events of pages carrying one of these tags are displayed. It works on the current wiki only. |
Examples
Displaying the Recent Activity of the Wiki
{{notifications count="5" /}}
Displaying the Activity of One Space
{{notifications spaces="Blog" count="5" displayOwnEvents="true" /}}Displaying the Reader's Own Notifications
{{notifications useUserPreferences="true" /}}Each reader then sees the events their own notification settings select, so the page shows something different to everyone.
FAQ
Can the macro display page creations only?
No parameter filters by event type. Set useUserPreferences to true, and each reader gets the event types they chose to receive.
The macro displays no event. Why?
Nothing matched its parameters. The macro hides the reader's own actions, minor edits and the events XWiki triggers itself unless displayOwnEvents, displayMinorEvents or displaySystemEvents says otherwise. A reader also never sees an event about a page they cannot view, so the same macro legitimately shows fewer events to some people than to others.