This page is an extension of the page about the Confluence storage format. This page describes the XML used to define specific Confluence macros – those that are shipped with Confluence. For each macro, we define the macro name, parameter names, and accepted parameter values.

This information is intended for advanced users who need to interpret and edit the underlying markup for a Confluence page.

On this page:

Anchor macro

Allows you to link to a specific part of a page.

Macro name: anchor

Macro body: None.

Parameter nameRequiredDefaultParameter description and accepted values

default-parameter

(Unnamed in wiki markup)

Yes(None)The name of the anchor.

Example:

<ac:structured-macro ac:name="anchor">
  <ac:parameter ac:name="">here</ac:parameter>
</ac:structured-macro>

Attachments macro

Displays a list of attachments on a given page.

Macro name: attachments

Macro body: None.

Parameter nameRequiredDefaultParameter description and accepted values
oldNofalse

Available values:

  • false - Displays only the latest version of each attachment.
  • true – Displays all versions of each attachment, including the old versions.
patternsNo(None)

A comma-separated list of regular expressions, used to filter the attachments by file name. Note that the parameter values must be regular expressions. For example:

  • To match a file suffix of 'jpg', use .*jpg (not *.jpg).
  • To match file names ending in 'jpg' or 'png', use .*jpg,.*png

sortByNodate

Available values:

  • date
  • size
  • name
pageNoThe page on which the macro exists.Page name, used to display attachments from another page.
sortOrderNo

The default sort order is determined by the sortBy type:

  • Reverse chronological for 'date'.
  • Largest to smallest for 'size'.
  • Alphabetical for 'name'.

Available values:

  • ascending
  • descending
labelsNo(None)A comma-separated list of labels. Confluence will show only attachments that have all the labels specified. (The match is an AND, not an OR.)
uploadNofalseDetermines whether the list of attachments will include options allowing users to browse for, and attach, new files.

Example:

<ac:structured-macro ac:name="attachments">
  <ac:parameter ac:name="old">false</ac:parameter>
  <ac:parameter ac:name="patterns">.*png,.*jpg</ac:parameter>
  <ac:parameter ac:name="sortBy">name</ac:parameter>
  <ac:parameter ac:name="page">
    <ac:link>
      <ri:page ri:content-title="My page about chocolate"/>
    </ac:link>
  </ac:parameter>
  <ac:parameter ac:name="sortOrder">descending</ac:parameter>
  <ac:parameter ac:name="labels">chocolate,cookies</ac:parameter>
  <ac:parameter ac:name="upload">false</ac:parameter>
</ac:structured-macro>

Blog Posts macro

Lists the most recent news items in the space.

Macro name: blog-posts

Macro body: None.

Parameter nameRequiredDefaultParameter description and accepted values
contentNoentire

Available values:

  • entire – Display the whole content of each blog post.
  • excerpts – Display a short extract from each blog post. If the post contains an Excerpt macro, the Blog Posts macro will display the content defined in the Excerpt macro. If the post does not contain an Excerpt macro, the Blog Posts macro will display the first few sentences of the post.
  • titles – Display a list of blog posts, showing titles only.
spacesNo@self

One or more space keys, separated by a comma or a space.

  • To exclude content in a specific space, put a minus sign (-) immediately in front of that space key. For example: If you specify a space key of -BADSPACE you will get only content which is not in the BADSPACE.
  • To indicate that the results must come from a specific space, put a plus sign (+) immediately in front of that space key. For example: If you specify a space key of +GOODSPACE you will get only content in GOODSPACE. (Note that this is not particularly useful, because each content item belongs to one space only. If you put a plus sign next to one space key and list other space keys too, the other space keys will be ignored.)

Special values:

  • @self — The current space.
  • @personal — All personal spaces.
  • @global — All site spaces.
  • @favorite — The spaces you have marked as favourite.
  • @favourite — The same as @favorite above.
  • @all — All spaces in your Confluence site.
  • * — The same as @all above.

When specifying a personal space, remember to use the tilde (~) sign in front of the username, such as ~jbloggs or ~jbloggs@example.com.

authorNo(None)One or more usernames, separated by commas.
timeNo(None)Available values:
  • m — Minutes
  • h — Hours
  • d — Days
  • w — Weeks

For example,

  • time=12h – Display blog posts created in the last twelve hours.
  • time=7d  – Display blog posts created in the last seven days.
reverseNofalseA value of true changes the sort order.
sortNocreation

Available values:

  • title — Sort alphabetically by title.
  • creation — Sort by the date on which the content was added.
  • modified — Sort by the date on which the content was last updated.

maxNo15The maximum number of results to be displayed.
labelNo(None)

One or more label values, separated by a comma or a space.

  • To exclude content which matches a given label, put a minus sign (-) immediately in front of that label value. For example: If you specify a label value of -badpage you will get only content which is not labelled with 'badpage'.
  • To indicate that the results must match a given label value, put a plus sign (+) immediately in front of that label value. For example: If you specify a label value of +superpage,+goodpage you will get only content which has at least two labels, being 'superpage' and 'goodpage'.

Example:

<ac:structured-macro ac:name="blog-posts">
  <ac:parameter ac:name="content">titles</ac:parameter>
  <ac:parameter ac:name="spaces">
    <ri:space ri:space-key="ds"/>
  </ac:parameter>
  <ac:parameter ac:name="author">
    <ri:user ri:userkey="12345678912345678912345678912345"/>
  </ac:parameter>
  <ac:parameter ac:name="time">4w</ac:parameter>
  <ac:parameter ac:name="sort">creation</ac:parameter>
  <ac:parameter ac:name="max">10</ac:parameter>
  <ac:parameter ac:name="labels">chocolate,cookies</ac:parameter>
</ac:structured-macro>

Change-History macro

Displays a history of updates made to a page.

Macro name: change-history

Macro body: None.

Parameters: None.

Example:

<ac:structured-macro ac:name="change-history"/>

Chart macro

Displays a chart based on tabular data.

Macro name: chart

Macro body: Accepts rich text, consisting of tables that hold the chart's data.

This macro recognises a large number of parameters, listed here by type for convenience.

Chart type parameters

These parameters determine the type of chart to display and how the chart looks.

ParameterRequiredDefaultDescription
typeNopie

The type of chart to display. XY charts have numerical x- and y-axes. The x values may optionally be time-based. See the timeSeries parameter.

Available values:

  • Standard charts - pie, bar, line, area
  • XY plotsxyArea, xyBar, xyLine, xyStep, xyStepArea, scatter, timeSeries
  • Other chartsgantt (beta)
orientationNovertical

The display orientation. Applies to area, bar and line charts.

Available values:

  • vertical –  y-axis is vertical
  • horizontal –  x-axis is vertical
3DNofalse

Show in three dimensions. Applies to area, bar and line charts.

stackedNofalseStacked values. Applies to area and bar charts.
showShapesNotrueApplies to line charts. Shapes are shown at each data point.
opacityNo
  • 75 percent for 3D charts
  • 50 percent for non-stacked area charts
  • 100 percent for all other charts
A percentage value between 0 (transparent) and 100 (opaque) that determines how opaque the foreground areas and bars are.

Chart display parameters

ParameterRequiredDefaultDescription
widthNo300The width of the chart in pixels.
heightNo300The height of the chart in pixels.
dataDisplayNofalse

Determines whether to display the body of the macro, consisting of the data table. By default, the chart data table is not displayed.

Available values:

  • false – the data is not displayed.
  • true or after –  the data is displayed after the chart.
  • before – the data is displayed before the chart.
imageFormatNopng

The image format to be used for the chart.

Available values:

  • png
  • jpg

Chart title and label parameters

ParameterRequiredDefaultDescription
titleNo(None)The title of the chart.
subTitleNo(None)A subtitle for the chart.
xLabelNo(None)The label for the x-axis (domain).
yLabelNo(None)The label for the y-axis (range).
legendNofalseDetermines whether to show a legend (key) for the chart.

Chart data parameters

The data for the chart is taken from tables found in the macro body. The parameters below control how this data is interpreted. By default, numeric and date values are interpreted according to the Confluence global default language (locale) formats. If conversion fails, other languages defined in Confluence will be tried. You can specify additional conversion options using the parameters below.

ParameterRequiredDefaultDescription
tablesNoAll first level tablesYou can supply a comma-separated list of table IDs and/or table numbers (starting at 1) contained within the body of the macro that will be used as the data for the chart. If data tables are embedded in other tables, then table selection will be required. This occurs when more complex formatting is done (for example using section and column macros).
columnsNoAll columnsYou can supply a comma-separated list of column labels and/or column titles and/or column numbers for tables used for chart data. This applies to all tables processed. Columns are enumerated starting at 1. Column label is the text for the column in the header row. Column title is the HTML title attribute for the column in the header row.
dataOrientation Nohorizontal

The content orientation. By default, the data tables will be interpreted as columns (horizontally) representing domain and x values.

Available values:

  • vertical  –  data table columns will be interpreted as series.
  • horizontal – data tables rows will be interpreted as series.
timeSeries Nofalse

If 'true', the x values in an XY plot will be treated as time series data and so will be converted according date formats.

dateFormat NoConfluence language defined date formatsFor time series data, the date format allows for additional customisation of the conversion of data to date values. If a dateFormat is specified, it will be the first format used to interpret date values. Specify a format that matches the time series data. See simple date format.
timePeriod Noday

The time period for time series data. Defines the granularity of how the data is interpreted.

Available values: millisecond, second, minute, hour, day, week, month, quarter, year

languageNo(None)

Use in combination with the country parameter to form a locale. These additional number and date formats will be used for data conversion before the default languages.

Available values are the two-character ISO 639-1 alpha-2 codes.

countryNo(None)Use in combination with the language parameter to form a locale. Valid values are the two-character ISO 3166 codes.
forgiveNotrue

Determines whether the macro will forgive (allow) some data formatting errors.

Available values:

  • true — the macro tries to convert numeric and date values that do not totally match any of the default or user-specified formats.
  • false — the macro enforces strict data formatting. If there are data format errors, the chart will not be produced.

Chart colour parameters

Colours are specified using hexadecimal notation or HTML colour names.

ParameterRequiredDefaultDescription
bgColor NoWhiteBackground colour of the chart.
borderColor NoNo borderColour of the border around the chart.
colorsNo A comma-separated list of colours used to customise the colours of categories, sections, and series.

Chart axis parameters

Depending on the chart type, the range and domain axis may be customised. These values are automatically generated based on the data but can be overridden by specifying one or more more of these parameters.

ParameterRequiredDefaultDescription
rangeAxisLowerBound No(None)Minimum value for the range axis.
rangeAxisUpperBound No(None)Maximum value for the range axis.
rangeAxisTickUnitNo(None)Range axis units between axis tick marks.
rangeAxisLabelAngleNo(None)Angle for the range axis label in degrees.
domainAxisLowerBoundNo(None)Only applies to XY plots. Domain axis lower bound. For a date axis, this value must be expressed in the date format specified by the dateFormat parameter.
domainAxisUpperBoundNo(None)Only applies to XY plots. Domain axis upper bound. For a date axis, this value must be expressed in the date format specified by the dateFormat parameter.
domainAxisTickUnitNo(None)Only applies to XY plots. Domain axis units between axis tick marks. For a date axis, this value represents a count of the units specified in the timePeriod parameter. The timePeriod unit can be overridden by specifying a trailing character: y (years), M (months), d (days), h (hours), m (minutes), s (seconds), u (milliseconds).
domainAxisLabelAngleNo(None)Only applies to XY plots. The angle for the domain axis label, in degrees. 
categoryLabelPositionNo(None)

Placement of the axis label text for categories.

Available values:

  • up45 — 45 degrees going upward
  • up90 — 90 degrees going upward
  • down45 — 45 degrees going downward
  • down90 — 90 degrees going downward
dateTickMarkPositionNo start

Placement of the date tick mark.

Available values:

  • start — tick mark is at the start of the date period.
  • middle — tick mark is in the middle of the date period.
  • end — tick mark is at the end of the date period.

Pie chart Parameters

ParameterRequiredDefaultDescription
pieSectionLabelNoShow only the pie section key valueFormatof pie section labels. The format uses a string with special replacement variables:
  • %0% is replaced by the pie section key.
  • %1% is replaced by the pie section numeric value.
  • %2% is replaced by the pie section percent value.

Example 1: To display something like 'Independent = 20':

%0% = %1%


Example 2: To display something like 'Independent (20%)':

%0% (%2%)
pieSectionExplodeNoNo exploded sectionsA comma-separated list of pie keys that are to be shown exploded. Note: requires jFreeChart version 1.0.3 or higher.

Chart attachment parameters

These are advanced options that can be used for chart versioning, to enable automation and to improve performance. Use these options carefully! Normally, the chart image is regenerated each time the page is displayed. These options allow for the generated image to be saved as an attachment and have subsequent access to re-use the attachment. This can be useful especially when combined with the Cache plugin to improve performance. Depending on the options chosen, chart images can be versioned for historical purposes.

ParameterRequiredDefaultDescription
attachmentNo(None)

The name and location where the chart image will be saved as an attachment. The user must be authorised to add attachments to the page specified.

Available syntax for this parameter:

  • ^attachmentName.png — the chart is saved as an attachment to the current page.
  • page name^attachmentName.png — the chart is saved as an attachment to the page name provided.
  • spacekey:page name^attachmentName.png — the chart is saved as an attachment to the page name provided in the space indicated.
attachmentVersionNonew

Defines the the versioning mechanism for saved charts.

Available values:

  • new — creates new version of the attachment.
  • replace — replaces all previous versions of the chart. To replace an existing attachment, the user must be authorised to remove attachments for the page specified.
  • keep — only saves a new attachment if an existing export of the same name does not exist. An existing attachment will not be changed or updated.
attachmentCommentNo(None) Comment used for a saved chart attachment.
thumbnailNofalse

 If true, the chart image attachment will be shown as a thumbnail (small, expandable) image.

Example:

Below is a simple example of a pie chart. See more examples in Storage Format Examples for Chart Macro.

<ac:structured-macro ac:name="chart">
  <ac:parameter ac:name="title">Fish Sold</ac:parameter>
  <ac:parameter ac:name="type">pie</ac:parameter>
  <ac:rich-text-body>
    <table>
      <tbody>
        <tr>
          <th>
            <p>Fish Type</p>
          </th>
          <th>
            <p>2004</p>
          </th>
          <th>
            <p>2005</p>
          </th>
        </tr>
        <tr>
          <th>
            <p>Herring</p>
          </th>
          <td>
            <p>9,500</p>
          </td>
          <td>
            <p>8,300</p>
          </td>
        </tr>
        <tr>
          <th>
            <p>Salmon</p>
          </th>
          <td>
            <p>2,900</p>
          </td>
          <td>
            <p>4,200</p>
          </td>
        </tr>
        <tr>
          <th>
            <p>Tuna</p>
          </th>
          <td>
            <p>1,500</p>
          </td>
          <td>
            <p>1,500</p>
          </td>
        </tr>
      </tbody>
    </table>
  </ac:rich-text-body>
</ac:structured-macro>

Cheese macro

Displays the words "I like cheese!"

Macro name: cheese

Macro body: None.

Parameters: None

Example:

<ac:structured-macro ac:name="cheese"/>

Children Display macro

Displays the children and descendants of the current page.

Macro name: children

Macro body: None.

Parameter nameRequiredDefaultParameter description and accepted values
reverseNofalseReverses the sort order in the list of child pages. Use this parameter in conjunction with the sort parameter described below. A value of true will change the sort order from ascending to descending.
sortNoManual if the pages have been manually reordered, otherwise alphabeticalby page title

Determines the sort order of the list of child pages.

Available values:

  • creation – Sort by the date on which the page was created.
  • title – Sort alphabetically by page name.
  • modified – Sort by the date on which the page was last updated.
styleNoBullet list

A heading style to be applied to the list of child pages.

Available values: h1 (heading level 1) through to h6 (heading level 6).

pageNoThe page that contains the macro

The name of the parent page. The macro will display the children of the specified page.

To specify a page in a different space, use a space key followed by a colon. For example:
MYSPACE:My page

If the value of this parameter is a forward slash (/) the macro will list the pages at the root of the current space. In other words, the pages without parents.

excerptNofalseIf true, Confluence will display any excerpts that are defined on the child pages. The excerpts must be defined via an Excerpt macro.
firstNo(None)The maximum number of child pages to be displayed (at the top level). For example, if the value of this parameter is 99, the macro will display the first 99 pages at the top level. It will also display their children, as determined by the depth and all parameters
depthNo(None)The number of levels of child pages to display. For example, if the value is 2, the macro will display 2 levels of child pages.
allNofalse

If true, Confluence will display all levels of child pages. This setting will override the depth setting.

Example:

<ac:structured-macro ac:name="children">
  <ac:parameter ac:name="reverse">true</ac:parameter>
  <ac:parameter ac:name="sort">creation</ac:parameter>
  <ac:parameter ac:name="style">h4</ac:parameter>
  <ac:parameter ac:name="page">
    <ac:link>
      <ri:page ri:content-title="Home"/>
    </ac:link>
  </ac:parameter>
  <ac:parameter ac:name="excerpt">true</ac:parameter>
  <ac:parameter ac:name="first">99</ac:parameter>
  <ac:parameter ac:name="depth">2</ac:parameter>
  <ac:parameter ac:name="all">true</ac:parameter>
</ac:structured-macro>

 

Code Block macro

Displays code in your document with the appropriate syntax highlighting.

Macro name: code

Macro body: Accepts plain text.

Parameter nameRequiredDefaultParameter description and accepted values
titleNo(None)Adds a title to the code macro box.
themeNoConfluence

Specifies the colour scheme used for displaying your code. Many of these themes are based on the default colour schemes of popular integrated development environments (IDEs). The default theme is Confluence (also known as Default), which is typically black and coloured text on a blank background.

Available themes:

  • DJango
  • Emacs
  • FadeToGrey
  • Midnight
  • RDark
  • Eclipse
  • Confluence (same as default)
linenumbersNofalse

If true, a line number will be shown to the left of each line of code. Numbering is incremented by 1.

If false, no line numbers are shown.

languageNojava

Specifies the language (or environment) for syntax highlighting.

  • (none) — that is, no syntax highlighting
  • actionscript3
  • bash
  • csharp — that is, C#
  • coldfusion
  • cpp — that is, C++
  • css
  • delphi
  • diff
  • erlang
  • groovy
  • java
  • javafx
  • javascript
  • perl
  • php
  • powershell
  • python
  • ruby
  • scala
  • sql
  • vb — that is, Visual Basic
  • html/xml
firstlineNo1When linenumbers is true, this value defines the number of the first line of code.
collapseNofalse

If true, the code macro's content will be collapsed upon visiting or refreshing the Confluence page. Clicking the 'expand source' link allows you to view the content.

If false, the code macro's content is always displayed in full.

Example:

The following example shows all parameters and a body:

<ac:structured-macro ac:name="code">
  <ac:parameter ac:name="title">This is my title</ac:parameter>
  <ac:parameter ac:name="theme">FadeToGrey</ac:parameter>
  <ac:parameter ac:name="linenumbers">true</ac:parameter>
  <ac:parameter ac:name="language">xml</ac:parameter>
  <ac:parameter ac:name="firstline">0001</ac:parameter>
  <ac:parameter ac:name="collapse">true</ac:parameter>
  <ac:plain-text-body><![CDATA[<b>This is my code</b>]]></ac:plain-text-body>
</ac:structured-macro>

Below are three examples of the Code Block macro with various optional parameters used.

Description

MarkupWhat you will get
Code block macro with a body and no optional parameters
<ac:structured-macro ac:name="code">
  <ac:plain-text-body><![CDATA[this is my code]]></ac:plain-text-body>
</ac:structured-macro>
this is my code
Code block macro with a body and the optional language parameter defined
<ac:structured-macro ac:name="code">
  <ac:parameter ac:name="language">html/xml</ac:parameter>
  <ac:plain-text-body><![CDATA[this is my code]]></ac:plain-text-body>
</ac:structured-macro>
this is my code

Code block macro with a body and optional title, line numbers and language parameters defined

<ac:structured-macro ac:name="code">
  <ac:parameter ac:name="title">This is my title</ac:parameter>
  <ac:parameter ac:name="linenumbers">true</ac:parameter>
  <ac:parameter ac:name="language">html/xml</ac:parameter>
  <ac:plain-text-body><![CDATA[this is my code]]></ac:plain-text-body>
</ac:structured-macro>
This is my title
this is my code

Column macro

Used with the Section macro to define columns on a page. See  Working with page layouts and columns and sections.

Macro name: column

Macro body: Accepts rich text.

Parameter nameRequiredDefaultParameter description and accepted values

width

No100% of the page width, divided equally by the number of columns in the section.The width of the column. Can be specified either in pixels (for example, 400px) or as a percentage of the available page width (for example, 50%).

Example:

<ac:structured-macro ac:name="column">
  <ac:parameter ac:name="width">100px</ac:parameter>
  <ac:rich-text-body>
    <p>This is the content of <strong>column 1</strong>.</p>
  </ac:rich-text-body>
</ac:structured-macro>

Content by Label macro

Displays a list of content associated with specific labels.

Macro name: contentbylabel

Macro body: None.

Parameter nameRequiredDefaultParameter description and accepted values
spacesNo@all

Filters the results by space. The macro will display only the pages and other content types which belong to the space(s) you specify here.

You can specify one or more space keys, separated by a comma or a space.

  • To exclude content in a specific space, put a minus sign (-) immediately in front of that space key. For example: If you specify a space key of -BADSPACE you will get only content which is not in the BADSPACE.
  • To indicate that the results must come from a specific space, put a plus sign (+) immediately in front of that space key. For example: If you specify a space key of +GOODSPACE you will get only content in GOODSPACE. (Note that this is not particularly useful, because each content item belongs to one space only. If you put a plus sign next to one space key and list other space keys too, the other space keys will be ignored.)

Special values:

  • @self — The current space.
  • @personal — All personal spaces.
  • @global — All site spaces.
  • @favorite — The spaces you have marked as favourite.
  • @favourite — The same as @favorite above.
  • @all — All spaces in your Confluence site.
  • * — The same as @all above.

When specifying a personal space, remember to use the tilde (~) sign in front of the username, such as ~jbloggs or ~jbloggs@example.com.

authorNo(None)

Filters the results by author. The macro will display only the pages and other content types which are written or updated by the author(s) you specify here.

You can specify one or more authors, separated by a comma.

For example: jsmith,jbrown

To include content from one user, but exclude from another user: jsmith,!jbrown

titleNo(None)Adds a heading to the list.
showLabelsNotrueDetermines whether to display the matching labels in the list of results.
reverseNofalseUse this parameter in conjunction with the sort parameter. Set reverse=true to change the sort from ascending to descending. This parameter is ignored if the sort parameter is not specified.
sortNomodifiedDetermines how the results are sorted. To change the sort order from ascending to descending, use the reverse parameter described above.

If this parameter is not specified, the sort order defaults to descending order based on the last modification date.

Values:
  • title — Sort alphabetically by title.
  • creation — Sort by the date on which the content was added.
  • modified — Sort by the date on which the content was last updated.
maxNo15Determines the maximum number of results to be displayed. Note that the results are sorted first, and then the maximum parameter is applied.
excerptNofalseIf this parameter is set to true, the macro displays an excerpt from each page listed in the results. Note that you must define the excerpts on each of those pages, by adding the Excerpt macro to each page. If a particular page does not have an excerpt defined, then the Content by Label macro will not attempt to show an excerpt for that page. The Content by Label macro will show only the first few lines of the excerpt for each page.
labelsYes(None)Use this parameter to filter the results by label. The macro will display only the pages and other content types which are tagged with the label(s) you specify here. See also the operator parameter.

You can specify one or more label values, separated by a comma or a space.
  • To exclude content which matches a given label, put a minus sign (-) immediately in front of that label value. For example: If you specify a label value of -badpage you will get only content which is not labelled with 'badpage'.
  • To indicate that the results must match a given label value, put a plus sign (+) immediately in front of that label value. For example: If you specify a label value of +superpage,+goodpage you will get only content which has at least two labels, being 'superpage' and 'goodpage'.
showSpaceNotrueDetermines whether to display the spaces in the list of results.
typeNoAllFilters the restults by content type. The macro will display only the content of the type you specify here.

You can specify one or more types, separated by a comma or a space.

To exclude content of a given content type, put a minus sign (-) immediately in front of that content type. For example: If you specify a content type of -blogpost you will get pages and all other content except for blog posts.

Available values:

  • pageages.
  • blogpost or newsblog posts, also known as news items.
  • attachment – attachments.
operatorNoORThe operator to apply to the supplied lists of labels. By default, a page with any of the non-prefixed labels (that is, labels without a plus (+) or minus (-) sign immediately preceding it) will be listed. If you specify a value of AND, only pages with all of the supplied non-prefixed labels will be listed.

Note that this parameter only modifies the behaviour of the 'Label(s)' parameter and only affects label values without a plus (+) or minus (-) sign prefix. To avoid confusion or unexpected results, we recommend that you do not use the operator parameter in conjunction with any label values prefixed with '+' or '-' signs.

Example:

<ac:structured-macro ac:name="contentbylabel">
  <ac:parameter ac:name="spaces"/>
  <ac:parameter ac:name="author">admin,smaddox</ac:parameter>
  <ac:parameter ac:name="title">My labelled pages</ac:parameter>
  <ac:parameter ac:name="showLabels">false</ac:parameter>
  <ac:parameter ac:name="reverse">true</ac:parameter>
  <ac:parameter ac:name="sort">creation</ac:parameter>
  <ac:parameter ac:name="max">10</ac:parameter>
  <ac:parameter ac:name="excerpt">true</ac:parameter>
  <ac:parameter ac:name="labels">chocolate,cake</ac:parameter>
  <ac:parameter ac:name="showSpace">false</ac:parameter>
  <ac:parameter ac:name="type">page</ac:parameter>
  <ac:parameter ac:name="operator">AND</ac:parameter>
</ac:structured-macro>

Content by User macro

Displays a list of the content items that have been created by a specified Confluence user.

Macro name: content-by-user

Macro body: None.

Parameter nameRequiredDefaultParameter description and accepted values

default-parameter

(Unnamed in wiki markup)

Yes(None)The Confluence username for the person whose content you wish to display

Example:

<ac:structured-macro ac:name="content-by-user">
  <ac:parameter ac:name="">
    <ri:user ri:userkey="12345678912345678912345678912345"/>
  </ac:parameter>
</ac:structured-macro>

Content Report Table macro

Displays a set of pages and blog posts in tabular format, based on the labels specified in the macro parameters.

Macro name: content-report-table

Macro body: None.

Parameter nameRequiredDefaultParameter description and accepted values
spacesNo(None)This parameter is required. Specify one or more labels, separated by a comma. The macro will display only the content tagged with the label(s) specified here.
labelsYes(None)Specify one or more space keys, separated by a comma or a space. The macro will display only the content which belongs to the space(s) specified here.

When specifying a personal space, remember to use the tilde (~) sign in front of the username, such as ~jbloggs or ~jbloggs@example.com.
maxResults
No(None)Define the maximum number of pages that the macro will show in a single set of results. If there are more pages to be shown, the macro will display a link labelled 'Find more results'.

Example:

<ac:structured-macro ac:name="content-report-table">
  <ac:parameter ac:name="spaces">
    <ri:space ri:space-key="DOC"/>
  </ac:parameter>
  <ac:parameter ac:name="labels">LDAP</ac:parameter>
  <ac:parameter ac:name="analytics-key">meeting-notes</ac:parameter>
  <ac:parameter ac:name="maxResults">5</ac:parameter>
</ac:structured-macro>

Contributors macro

Displays a list of Confluence users who have made a contribution of some type to a page.

Macro name: contributors

Macro body: None.

Parameter name

Required

Default

Parameter description and accepted values

limit

 No

(None)

Limits the number of contributors displayed in the list.

spaces

 No

Current space

Specifies the space key of the Confluence space to search. Space keys are case sensitive.

Special values:

  • @global — All site spaces.
  • @personal — All personal spaces.
  • @all — All spaces in the Confluence site.

You can specify one or more space keys or special values, separated by commas.

If no page and labels are specified, all pages from the specified set of spaces are included.

reverse

No

false

Reverses the order of contributors in the list. Must be used in conjunction with the order parameter.

scope
 No

The specified page only

Specifies additional pages to include when generating the list of contributors.

Available values:

  • children – only the child pages of the specified page.
  • descendants – all descendants of the specified page.

labels

 No

(None)

Limits the list of contributors to those who created the specified labels on a page. You can specify one or more labels, separated by commas.

showPages No

false

If the value is true, the macro will display a list of the pages used to generate the list of contributors.

noneFoundMessage No

"No contributors found for:" (and a summary of selected parameter values)

Any message given here will override the default message that is displayed when no contributors are found.

showCount

 No

false

Determines whether the macro will show the number of times each person made a contribution.

contentType
 No

Both pages and blog posts

Restricts the content type that the macro will use when generating the list of contributors.

Available values:

  • pages – pages

  • blogposts – blog posts.

include
No

authors

Filters by either the type of contribution made to a page (and optionally its descendant pages), or the watches on the page. Contribution types are:

  • authors - includes people who created or have edited the page(s)
  • comments - includes people who have added comments to the page(s)
  • labels - includes people who have added labels to the page(s)
  • watches - includes people who are watching the page(s).

You can specify one or more contribution types, separated by commas.

mode
 No
inline

Determines how the list of contributors is formatted:

  • inline — a comma-separated list
  • list — a bullet list.
showAnonymous
 No
false

Determines whether to include those who contributed anonymously to a page.

order
No
count

Specifies the criteria used to sort contributors. Sort criteria are:

  • count – sorts the names based on the total number of contributions to the page(s)
  • name – sorts the names into alphabetical order
  • update – sorts the names by the date of their last contribution to the page(s).
page
No

The current page

Specifies the page to use when generating the list of contributors. If page and spaces are left blank, the current page is assumed.

showLastTime
No
false

Determines whether to show the last time each person made a contribution.

publishDate
No

(None)e

Specifies the publication date for a blog post. The date format required is: YYYY/MM/DD.

Example:

This example specifies a content type of blog posts:

<ac:macro ac:name="contributors">
    <ac:parameter ac:name="limit">10</ac:parameter>
    <ac:parameter ac:name="spaces">ds,@personal</ac:parameter>
    <ac:parameter ac:name="reverse">true</ac:parameter>
    <ac:parameter ac:name="labels">chocolate,cake</ac:parameter>
    <ac:parameter ac:name="showPages">true</ac:parameter>
    <ac:parameter ac:name="noneFoundMessage">Oh dear, no contributors found</ac:parameter>
    <ac:parameter ac:name="showCount">true</ac:parameter>
    <ac:parameter ac:name="contentType">blogposts</ac:parameter>
    <ac:parameter ac:name="include">authors,comments,labels,watches</ac:parameter>
    <ac:parameter ac:name="mode">list</ac:parameter>
    <ac:parameter ac:name="showAnonymous">true</ac:parameter>
    <ac:parameter ac:name="order">update</ac:parameter>
    <ac:parameter ac:name="showLastTime">true</ac:parameter>
    <ac:parameter ac:name="publishDate">2012/06/30</ac:parameter>
  </ac:macro>

This example specifies a content type of pages:

<ac:macro ac:name="contributors">
    <ac:parameter ac:name="limit">10</ac:parameter>
    <ac:parameter ac:name="spaces">ds,@personal</ac:parameter>
    <ac:parameter ac:name="reverse">true</ac:parameter>
    <ac:parameter ac:name="scope">descendants</ac:parameter>
    <ac:parameter ac:name="labels">chocolate,cake</ac:parameter>
    <ac:parameter ac:name="showPages">true</ac:parameter>
    <ac:parameter ac:name="noneFoundMessage">Oh dear, no contributors found</ac:parameter>
    <ac:parameter ac:name="showCount">true</ac:parameter>
    <ac:parameter ac:name="contentType">pages</ac:parameter>
    <ac:parameter ac:name="include">authors,comments,labels,watches</ac:parameter>
    <ac:parameter ac:name="mode">list</ac:parameter>
    <ac:parameter ac:name="showAnonymous">true</ac:parameter>
    <ac:parameter ac:name="order">update</ac:parameter>
    <ac:parameter ac:name="page">ds:Advanced Topics</ac:parameter>
    <ac:parameter ac:name="showLastTime">true</ac:parameter>
  </ac:macro>

Contributors Summary macro

Displays a table of contribution-based statistics for a set of pages.

Macro name: contributors-summary

Macro body: None.

Parameter name

Required

Default

Parameter description and accepted values

limit

 No

(None)

Limits the number of contributors or pages displayed in the table.

spaces

 No

Current space

Specifies the space key of the Confluence space to search. Space keys are case sensitive.

Special values:

  • @global — All site spaces.
  • @personal — All personal spaces.
  • @all — All spaces in the Confluence site.

You can specify one or more space keys or special values, separated by commas.

If no page and labels are specified, all pages from the specified set of spaces are included.

reverse

No

false

Reverses the order of items in the table. Must be used in conjunction with the order parameter.

showAnonymous
 No
false

Determines whether to include those who contributed anonymously to a page.

scope
 No

The specified page only

Specifies additional pages to include when generating the list of contributors.

Available values:

  • children – only the child pages of the specified page.
  • descendants – all descendants of the specified page.
order
No
edits

Sets the criterion used for sorting items in the table.

Available values:

  • edits sorts items in the table based on the total number of edits made, either by a contributor or to a page.
  • name sorts items in the table in alphabetical order, either by contributor or page name.
  • editTime sorts items in the table based on when the contributor last edited a page (or a specified set of pages) or when the page was lasted edited.
  • update sorts items in the table based on when the contributor last made any contribution to a page (or a specified set of pages) or when the page last had any contribution made to it.
page
No

The current page

A page title. Specifies the page to use when generating the list of contributors. If page and spaces are left blank, the current page is assumed.

labels

 No

(None)

Limits contribution-based statistics to the specified labels only. You can specify one or more labels, separated by commas.

columns
No

edits,comments,labels

Determines the columns that should appear in the table. The statistics or type of information presented depends on the groupby parameter.

Available values:

  • edits – the number of times each contributor has edited the page(s) or the number of edits made to each page.
  • edited – a list of the pages edited by each contributor or a list of contributors who have edited each page.
  • comments – the number of times each contributor has added comments to the page(s) or the number of comments on each page.
  • commented – a list of pages to which each contributor has added comments or a list of contributors who have commented on each page.
  • labels – the number of times each contributor has added labels to the page(s) or the number of labels on each page.
  • labeled – a list of pages to which each contributor has added labels or a list of contributors who have added a label to each page.
  • labellist – a list of labels either added by each contributor or on each page.
  • watches – the number of pages being watched by each contributor/person or the number of contributors/people watching each page.
  • watching – a list of pages being watched by each contributor/person or a list of contributors/people watching each page.
  • lastupdate – the last time each contributor made an update or when each page was last updated. Valid updates can include edits, comments or label modifications to a page.

You can specify one or more columns, separated by commas.

groupby
Nocontributors

Specifies the basis for grouping contribution-based statistics:

  • contributors – group by the people who have contributed.
  • pages – group by the pages used to find the contributors.
contentType
 No

Both pages and blog posts

Restricts the content type that the macro will use when generating the list of contributors.

Available values:

  • pages – pages

  • blogposts – blog posts.

showZeroCountsNofalseDetermines whether contributors or pages are included for which the calculated statistic is zero.
publishDate
No

(None)

Specifies the publication date for a blog post. The date format required is: YYYY/MM/DD.

Example:

This example specifies a content type of blog posts:

<ac:structured-macro ac:name="contributors-summary">
  <ac:parameter ac:name="limit">10</ac:parameter>
  <ac:parameter ac:name="spaces">
    <ri:space ri:space-key="ds"/>
    <ri:space ri:space-key="@personal"/>
  </ac:parameter>
  <ac:parameter ac:name="reverse">true</ac:parameter>
  <ac:parameter ac:name="showAnonymous">true</ac:parameter>
  <ac:parameter ac:name="order">update</ac:parameter>
  <ac:parameter ac:name="labels">chocolate,cake</ac:parameter>
  <ac:parameter ac:name="columns">edits,comments,labels,lastupdate</ac:parameter>
  <ac:parameter ac:name="groupby">pages</ac:parameter>
  <ac:parameter ac:name="contentType">blogposts</ac:parameter>
  <ac:parameter ac:name="showZeroCounts">true</ac:parameter>
  <ac:parameter ac:name="publishDate">2012/06/07</ac:parameter>
</ac:structured-macro>

This example specifies a content type of pages:

<ac:structured-macro ac:name="contributors-summary">
  <ac:parameter ac:name="limit">10</ac:parameter>
  <ac:parameter ac:name="spaces">
    <ri:space ri:space-key="ds"/>
    <ri:space ri:space-key="@personal"/>
  </ac:parameter>
  <ac:parameter ac:name="reverse">true</ac:parameter>
  <ac:parameter ac:name="showAnonymous">true</ac:parameter>
  <ac:parameter ac:name="scope">descendants</ac:parameter>
  <ac:parameter ac:name="order">update</ac:parameter>
  <ac:parameter ac:name="page">
    <ac:link>
      <ri:page ri:content-title="Advanced Topics" ri:space-key="ds"/>
    </ac:link>
  </ac:parameter>
  <ac:parameter ac:name="labels">chocolate,cake</ac:parameter>
  <ac:parameter ac:name="columns">edits,comments,labels,lastupdate</ac:parameter>
  <ac:parameter ac:name="groupby">pages</ac:parameter>
  <ac:parameter ac:name="contentType">pages</ac:parameter>
  <ac:parameter ac:name="showZeroCounts">true</ac:parameter>
</ac:structured-macro>

Create from Template macro

Creates a page from a given template.

Macro name: create-from-template

Macro body: None.

Parameter nameRequiredDefaultParameter description and accepted values

templateId

Required for user-created templates(None)The ID of a user-created template. This is the unique identifier that Confluence assigns when you create a template. For example, 299630593. To find the ID of a template, edit the template and look at the URL in your browser. The template ID is given in the URL parameter named entityId.
blueprintModuleCompleteKeyRequired for blueprints(None)The qualified name of the add-on that defines the blueprint (for example, com.atlassian.confluence.plugins.confluence-shared-files-plugin:file-list-blueprint ).

templateName

Yes(None)The ID of a user-created template (for example, 299630593) or the qualified name of the add-on that defines the blueprint (for example, com.atlassian.confluence.plugins.confluence-shared-files-plugin:file-list-blueprint).
buttonLabelYes'Create from Template'The description that people will seeing when viewing this macro on the page.
spaceKeyYesThe space where the current page is locatedThe unique space identifier, to determine where the new page will be created when someone uses this macro to create a page.
TitleNo(None)The title for pages created using this macro. You can include @currentDate, @spaceName and @spaceKey variables in the title. This title will override any title specified in a blueprint template.

Example:

This example specifies a user-created template:

<ac:structured-macro ac:name="create-from-template">
  <ac:parameter ac:name="templateId">299630593</ac:parameter>
  <ac:parameter ac:name="buttonLabel">Blitz test</ac:parameter>
  <ac:parameter ac:name="spaceKey">
    <ri:space ri:space-key="DOCTHEME"/>
  </ac:parameter>
  <ac:parameter ac:name="templateName">299630593</ac:parameter>
</ac:structured-macro>

 

This example uses a blueprint:

<ac:structured-macro ac:name="create-from-template">
  <ac:parameter ac:name="blueprintModuleCompleteKey">com.atlassian.confluence.plugins.confluence-shared-files-plugin:file-list-blueprint</ac:parameter>
  <ac:parameter ac:name="buttonLabel">Shared files</ac:parameter>
  <ac:parameter ac:name="spaceKey">
    <ri:space ri:space-key="DOCTHEME"/>
  </ac:parameter>
  <ac:parameter ac:name="templateName">com.atlassian.confluence.plugins.confluence-shared-files-plugin:file-list-blueprint</ac:parameter>
</ac:structured-macro>

Create Space Button macro

Displays a create space button linked to the create space page.

Macro name: create-space-button

Macro body: None.

Parameter nameRequiredDefaultParameter description and accepted values
sizeNolarge

Determines the size of the 'create space' icon displayed. Available values:

  • large
  • small
widthNo

Natural size of icon

(1:1 pixel ratio)

The width of the icon to be displayed, specified in pixels. Confluence will stretch or shrink the width of the icon to the number of pixels specified.

Note: This parameter is not available via the macro browser.

heightNo

Natural size of icon

(1:1 pixel ratio)

The height of the icon to be displayed, specified in pixels. Confluence will stretch or shrink the height of the icon to the number of pixels specified.

Note: This parameter is not available via the macro browser.

Example:

<ac:structured-macro ac:name="create-space-button">
  <ac:parameter ac:name="size">small</ac:parameter>
</ac:structured-macro>

Excerpt Include macro

Allows you to display an excerpt from another page within the current page.

Macro name: excerpt-include

Macro body: None.

Parameter nameRequiredDefaultParameter description and accepted values

default-parameter

(Unnamed in wiki markup)

Yes(None.)

The name of the page that contains the excerpt to be displayed.

To include an excerpt from a page in another space, type the space key followed by a colon (:) and the page name, like this:

SPACEKEY:My page name

Note: The ability to include excerpts from other spaces is available only in Confluence 4.3.2 and later. In earlier versions of Confluence, the Excerpt Include macro does not work across spaces. Use the Include Page macro instead.

nopanelNoFalseDetermines whether Confluence will display a panal around the excerpted content. The panel includes the title of the page containing the excerpt, and the border of the panel. By default, the panel and title are shown.

Example:

<ac:macro ac:name="excerpt-include">
  <ac:parameter ac:name="nopanel">true</ac:parameter>
  <ac:default-parameter>My page name</ac:default-parameter>
</ac:macro>

Excerpt macro

Define a part of a page as the page's 'excerpt' which can then be displayed in another page.

Macro name: excerpt

Macro body: Accepts rich text.

Parameter nameRequiredDefaultParameter description and accepted values
hiddenNoFalse

Determines whether the content of the Excerpt macro body is displayed on the page that contains the Excerpt macro.

Note that this option affects only the page that contains the Excerpt macro. It does not affect any pages where the content is reused.

atlassian-macro-output-typeNoBLOCK

Determines whether the content of the Excerpt macro body is displayed on a new line or inline.

Available values:

  • BLOCK – Displays the content of the macro on a new line.
  • INLINE – Displays the the content of the macro as part of the same paragraph as the text preceding and following it.

Note that this option affects only the page that contains the Excerpt macro. It does not affect any pages where the content is reused.

Example:

<ac:structured-macro ac:name="excerpt">
  <ac:parameter ac:name="hidden">true</ac:parameter>
  <ac:parameter ac:name="atlassian-macro-output-type">BLOCK</ac:parameter>
  <ac:rich-text-body>
    <p>This is the <strong>text</strong> I want to reuse in other pages. This text is inside an Excerpt macro.</p>
  </ac:rich-text-body>
</ac:structured-macro>

Expand macro

Displays an expandable/collapsible section of text.

Macro name: expand

Macro body: Accepts rich text.

Parameter nameRequiredDefaultParameter description and accepted values

default-parameter

(Unnamed in wiki markup)

NoClick here to expand...Text that will be displayed on the line that people can click to expand the hidden text.

Example:

<ac:structured-macro ac:name="expand">
  <ac:parameter ac:name="">This is my message</ac:parameter>
  <ac:rich-text-body>
    <p>This text is <em>hidden</em> until you expand it.</p>
  </ac:rich-text-body>
</ac:structured-macro>

Favourite Pages macro

Displays a list of your favourite pages.

Macro name: favpages

Macro body: None.

Parameters: None.

Example:

<ac:structured-macro ac:name="favpages"/>

Gadget macro

Allows you to add Confluence gadgets to pages or blog posts.

Macro name: gadget

Macro body: None.

Parameter nameRequiredDefaultParameter description and accepted values

width

No450 pixelsThe width of the gadget, using one of the following conventions:
  • Width in pixesl, using px or plain numbers. For example, 500px or 500
  • A percentage of the page width, using %. For example, 50%
  • Automatic resizing of the gadget to fit 100% of the page width: auto
borderNotrueDetermines whether Confluence will draw a border around the gadget.
urlYes(none.)This is the location of the gadget specification (XML file).
preferencesNo(Gadget-dependent.)Specific property settings that are particular to each gadget.

A note about editing a gadget's properties (preferences) in markup: It is possible to edit the values of these properties directly in the wiki markup or storage format. However, this will allow the entry of invalid values. If a gadget property supports a certain set of values, the macro browser will restrict the user to selecting only valid values for that property. For that reason, we recommend that you use the macro browser to edit a gadget's properties.

Example:

This example shows the Confluence Page gadget:

<ac:structured-macro ac:name="gadget">
  <ac:parameter ac:name="width">500</ac:parameter>
  <ac:parameter ac:name="border">false</ac:parameter>
  <ac:parameter ac:name="url">rest/gadgets/1.0/g/com.atlassian.confluence.plugins.gadgets:confluence-page-gadget/gadgets/confluence-page-gadget.xml</ac:parameter>
  <ac:parameter ac:name="preferences">spaceName=Documentation&amp;spaceKey=DOC&amp;quickfind-space=Documentation&amp;pageId=753666&amp;pageName=Documentation%20Home&amp;quickfind-page=Documentation%20Home&amp;isEditable=true&amp;isConfigured=true&amp;refresh=15&amp;showLink=false</ac:parameter>
</ac:structured-macro>

This example shows the Confluence News gadget:

<ac:structured-macro ac:name="gadget">
  <ac:parameter ac:name="url">rest/gadgets/1.0/g/com.atlassian.confluence.plugins.gadgets:confluence-news-gadget/gadgets/confluence-news-gadget.xml</ac:parameter>
  <ac:parameter ac:name="preferences"/>
</ac:structured-macro>

Gallery macro

Forms a thumbnail gallery of all images attached to a page.

Macro name: gallery

Macro body: None.

Parameter name

Required

Default

Parameter description and accepted values

title
No

(None)

Specify a title to be displayed above your gallery of pictures.

reverse
No

Not specified. Sort order is ascending.

Used in combination with the sort parameter, to change the sort order from ascending to descending.

Available values:

  • true – Sort order is descending.
  • false – Sort order is ascending.
sort
 No

None. The sort order is unspecified and therefore unpredictable.

Specify an attribute to sort the images by. Sort order is ascending, unless you specify the reverse parameter.

Available values:

  • name – file name.
  • comment – comment linked to the attached file.
  • date – date/time last modified.
  • size – size of the attached file.
page
 No

If no page is specified, the gallery macro displays the images attached to the page on which the macro is used.

Specify the title of the page which contains the images you want displayed. You can specify more than one page name, separated by commas. To specify a page in a different space, use the following syntax: SPACEKEY:Page title.
includeLabel NoNone. The images are not filtered by label.The gallery will include only those pictures that have the specified label. If you wish to enter more than one label, separate the labels with commas. Confluence will show only images that have all the labels specified. (The match is an AND, not an OR.) For information on labelling the attachments, see Adding Labels.
excludeLabel No

No exclusions. The gallery will include all the pictures on the page.

The gallery will ignore any pictures that have the specified label. You can specify more than one label, separated by commas. For information on labelling the attachments, see Adding Labels.
columns
No

4

Specify the number of columns for the table that forms the gallery.

exclude

No

No exclusions. Include all the pictures on the page.

Specify images by file name. The gallery will ignore any images specified. You can specify more than one image, separated by commas.
Note: The file name and file type for this parameter are case sensitive. For example, 'my picture.PNG' will not be recognised as 'my picture.png'.

include

No

Include all the pictures on the page.

If you specifically include one or more pictures, the gallery will show only those pictures. You can specify more than one picture, separated by commas.
Note: The file name and file type for this parameter are case-sensitive. For example, 'my picture.PNG' will not be recognised as 'my picture.png'.

Example:

<ac:structured-macro ac:name="gallery">
  <ac:parameter ac:name="title">My holiday pictures</ac:parameter>
  <ac:parameter ac:name="reverse">true</ac:parameter>
  <ac:parameter ac:name="sort">size</ac:parameter>
  <ac:parameter ac:name="page">My page1, ds:Welcome to Confluence</ac:parameter>
  <ac:parameter ac:name="excludeLabel">badlabel1, badlabel2</ac:parameter>
  <ac:parameter ac:name="columns">3</ac:parameter>
  <ac:parameter ac:name="exclude">badpicture.png</ac:parameter>
</ac:structured-macro>

Global Reports macro

Displays a list of links to global reports within a table.

Macro name: global-reports

Macro body: None.

Parameter name

Required

Default

Parameter description and accepted values

width
No

99%

Specify the width of the table in which the links are displayed, as a percentage of the window width.

Example:

<ac:structured-macro ac:name="global-reports">
  <ac:parameter ac:name="width">50%</ac:parameter>
</ac:structured-macro>

HTML Include macro

Includes the content of an external HTML file into a Confluence page.

Macro name: html-include

Macro body: None.

Parameter name

Required

Default

Parameter description and accepted values

url
Yes

(None)

Specify a URL of the content to be included into your Confluence page.

Example:

<ac:structured-macro ac:name="html-include">
  <ac:parameter ac:name="url">
    <ri:url ri:value="http://www.example.com"/>
  </ac:parameter>
</ac:structured-macro>

HTML macro

Renders your specified HTML code within the current page.

Macro name: html

Macro body: Text, consisting of HTML code.

Parameters: None.

Example:

<ac:structured-macro ac:name="html">
  <ac:plain-text-body><![CDATA[<a href="http://www.atlassian.com">Click here</a> to see the <b>Atlassian</b> website.]]></ac:plain-text-body>
</ac:structured-macro>

IM Presence macro

Displays graphically when a contact is online.

Macro name: im

Macro body: None.

Parameter name

Required

Default

Parameter description and accepted values

showid
No

true

Determines whether the macro shows or hides the user ID of the contact.

Available values:

  • true – User ID is shown on the page.
  • false – User ID is not shown on the page.
service
Yes

Not specified.

The web service that Confluence should query.

Available values:

default-parameter

(Unnamed in wiki markup)

YesNot specified.User ID. Identifies the IM contact by their ID, account name or screen name.

Example:

<ac:structured-macro ac:name="im">
  <ac:parameter ac:name="showid">false</ac:parameter>
  <ac:parameter ac:name="service">skype</ac:parameter>
  <ac:parameter ac:name="">MySkypeName</ac:parameter>
</ac:structured-macro>

Include Page macro

Inserts the contents of the specified page into the current one.

Macro name: include

Macro body: None.

Parameter nameRequiredDefaultParameter description and accepted values

default-parameter

(Unnamed in wiki markup)

Yes(None.)

The name of the page whose content should be included on the current page

To includecontent from a page in another space, type the space key followed by a colon (:) and the page name, like this:

SPACEKEY:My page name

To include a blog post, specify the date as well as the title of the blog post. For example: /2010/12/01/My blog post.

You can include pages from personal spaces using ~username as the space key, where 'username' is the person's username. For example, ~jsmith:My page name.

Example:

<ac:structured-macro ac:name="include">
  <ac:parameter ac:name="">
    <ac:link>
      <ri:page ri:content-title="My chocolate page" ri:space-key="DOC"/>
    </ac:link>
  </ac:parameter>
</ac:structured-macro>

Info macro

Displays a block of text in a blue highlight box.

Macro name: info

Macro body: Accepts rich text.

Parameter nameRequiredDefaultParameter description and accepted values
iconNotrueDetermines whether to display the (info) icon in the title bar of the information box.
titleNo(None)The title of the information box. If specified, the title text will be displayed in bold next to the icon.

Example:

The following example shows all parameters and a body:

<ac:structured-macro ac:name="info">
  <ac:parameter ac:name="icon">false</ac:parameter>
  <ac:parameter ac:name="title">This is my title</ac:parameter>
  <ac:rich-text-body>
    <p>
      <span>This is </span> <em>important</em> <span> information.</span>
    </p>
  </ac:rich-text-body>
</ac:structured-macro>

Below are some examples of the Info macro with various optional parameters used.

Description

MarkupWhat you will get

Info macro with a body defined and no optional parameters

<ac:structured-macro ac:name="info">
  <ac:rich-text-body>
    <p>This is <em>important</em> information.</p>
  </ac:rich-text-body>
</ac:structured-macro>

 This is important information.

Info macro with with a body and an optional Title parameter defined

<ac:structured-macro ac:name="info">
  <ac:parameter ac:name="title">This is my title</ac:parameter>
  <ac:rich-text-body>
    <p>This is <em>important</em> information.</p>
  </ac:rich-text-body>
</ac:structured-macro>

This is my title

 This is important information.

Info macro with a body and optional Title and Icon parameters defined

<ac:structured-macro ac:name="info">
  <ac:parameter ac:name="icon">false</ac:parameter>
  <ac:parameter ac:name="title">This is my title</ac:parameter>
  <ac:rich-text-body>
    <p>
      <span>This is </span> <em>important</em> <span> information.</span>
    </p>
  </ac:rich-text-body>
</ac:structured-macro>

This is my title

 This is important information.

JIRA Issues macro

Displays one or more JIRA issues, and offers the option to create an issue in JIRA.

Macro name: jiraissues

Macro body: None.

Parameter name

Required

Default

Parameter description and accepted values

anonymous

No

false

If this parameter is set to 'true', JIRA will return only the issues which allow unrestricted viewing. That is, the issues which are visible to anonymous viewers, as determined by JIRA's viewing restrictions. If this parameter is omitted or set to 'false', then the results depend on how your administrator has configured the communication between JIRA and Confluence. By default, Confluence will show only the JIRA issues which the user is authorised to view.

Note: This parameter is available only if you insert the macro via wiki markup or by editing the storage format of the page. The graphic user interface (macro browser) for the JIRA Issues macro does not offer this parameter.

baseurl

No

The value of the 'url' parameter

If you specify a 'baseurl', then the link in the header, pointing to your JIRA site, will use this base URL instead of the value of the 'url' parameter. This is useful when Confluence connects to JIRA with a different URL from the one used by other users.

columns

No

By default, the following columns are shown:

  • type
  • key
  • summary
  • assignee
  • reporter
  • priority
  • status
  • resolution
  • created
  • updated
  • due

A list of JIRA column names, separated by semi-colons (;). You can include any columns recognised by your JIRA site, including custom columns. See the JIRA documentation for a list of names.

count

No

false

If this parameter is set to 'true', the issue list will show the number of issues in JIRA. The count will be linked to your JIRA site.

cache

No

on

The macro maintains a cache of the issues which result from the JIRA query. If the 'cache' parameter is set to 'off', the relevant part of the cache is cleared each time the macro is reloaded. (The value 'false' also works and has the same effect as 'off'.)

Note: This parameter is available only if you insert the macro via wiki markup or by editing the storage format of the page. The graphic user interface (macro browser) for the JIRA Issues macro does not offer this parameter.

height

No

480 (if render mode is dynamic)

The height in pixels of the table displaying the JIRA issues.
Note that this height specification is ignored in the following situations:

  • If the 'renderMode' parameter (see below) is set to 'static'.
  • When the JIRA issues are displayed in a PDF or Word document, in an email message or in an RSS feed.

Note: This parameter is available only if you insert the macro via wiki markup or by editing the storage format of the page. The graphic user interface (macro browser) for the JIRA Issues macro does not offer this parameter.

renderMode

No

static

If the value is 'dynamic', the JIRA Issues macro offers an interactive display which people can manipulate as follows:

  • Click the column headers to sort the output.
  • Drag and drop the columns into a different order.
  • Temporarily remove a column from the display.
  • View a page of issues at a time, for faster response times.

A value of 'static' will disable the dynamic display features.

Note: This parameter is available only if you insert the macro via wiki markup or by editing the storage format of the page. The graphic user interface (macro browser) for the JIRA Issues macro does not offer this parameter.

url

Yes

none

The URL of the XML view of your selected issues in JIRA Issue Navigator.

Note: If the URL in the 'url' parameter does not contain a tempMax argument, then the value of tempMax will default to 500. If your JIRA server is version 3.12 or earlier, this means that the JIRA Issues macro will return a maximum of 500 issues. If your JIRA server is version 3.13 or later, a value of 500 means that the JIRA Issues macro will return a maximum of 500 issues per page.

width

No

100%

The width of the table displaying the JIRA issues. Can be indicated either as a percentage (%) or in pixels (px).

Note: This parameter is available only if you insert the macro via wiki markup or by editing the storage format of the page. The graphic user interface (macro browser) for the JIRA Issues macro does not offer this parameter.

Example:

Example using a URL that points to the XML view of a JIRA search:

<ac:structured-macro ac:name="jiraissues">
  <ac:parameter ac:name="anonymous">true</ac:parameter>
  <ac:parameter ac:name="columns">type;key;summary</ac:parameter>
  <ac:parameter ac:name="url">
    <ri:url ri:value="http://jira.atlassian.com/sr/jira.issueviews:searchrequest-xml/temp/SearchRequest.xml?jqlQuery=project+%3D+CONF+AND+%28summary+%7E+jiraissues+OR+description+%7E+jiraissues+OR+comment+%7E+jiraissues%29&amp;tempMax=10"/>
  </ac:parameter>
</ac:structured-macro>

Example using JQL – note that Confluence will insert the server and serverId parameters, based on settings in Application Links:

<ac:structured-macro ac:name="jira">
  <ac:parameter ac:name="columns">key,summary,type,created,assignee,status</ac:parameter>
  <ac:parameter ac:name="server">Atlassian JIRA</ac:parameter>
  <ac:parameter ac:name="serverId">144880e9-a1111-333f-9412-ed999a9999fa</ac:parameter>
    <ac:parameter ac:name="jqlQuery">project = CONF AND component = documentation AND resolution = unresolved</ac:parameter>
  </ac:structured-macro>

JUnit Report macro

Display a summary of JUnit test results.

Macro name: junitreport

Macro body: None.

Parameter name

Required

Default

Parameter description and accepted values

directory

Must include either the directory or the url parameter

(None)

URL of a directory containing your test result files. This must be a directory name and not the XML file itself. Overrides the url parameter if you use both.

Note: When using a local drive, you must use a directory name and not the XML file itself.

reportdetail

No

all

Level of detail required in the report.

Available values:

  • all
  • fixture
  • summary
  • failuresonly

url

Must include either the directory or the url parameter

(None)

URL of a particular test result XML file.

This parameter is overridden by the directory parameter if you use both.

For Confluence installations that require authentication, you can specify login credentials as part of this parameter, in the form of URL parameters:

  • os_username — The username of a Confluence user with permission to access the JUnit test results.
  • os_password — The password of the Confluence user specified in the os_username parameter.

debug

No

false

If the value of this parameter is true, the report will show the content of failures, as well as the error messages.

Example:

<ac:structured-macro ac:name="junitreport">
  <ac:parameter ac:name="reportdetail">summary</ac:parameter>
  <ac:parameter ac:name="directory">
    <ri:url ri:value="http://confluence.com/download/attachments/123/"/>
  </ac:parameter>
  <ac:parameter ac:name="debug">true</ac:parameter>
  <ac:parameter ac:name="url">
    <ri:url ri:value="http://confluence.com/download/attachments/123/file.xml"/>
  </ac:parameter>
</ac:structured-macro>

Labels List macro

Displays a hyperlinked alphabetical index of all labels within the current space.

Macro name: listlabels

Macro body: None.

Parameter name

Required

Default

Parameter description and accepted values

spaceKey

No

Current space

The key of the space whose labels you want to display.

Example:

  <ac:structured-macro ac:name="listlabels">
    <ac:parameter ac:name="spaceKey">
      <ri:space ri:space-key="DOC"/>
    </ac:parameter>
    <ac:parameter ac:name="excludedLabels">not-this-label</ac:parameter>
  </ac:structured-macro>

Livesearch macro

Add a dynamic search box to a wiki page.

Macro name: livesearch

Macro body: None.

Parameter name

Required

Default

Parameter description and accepted values

placeholder

No

(None)

Specify the placeholder text to appear in the search field.
labelsNo(None)Specify labels to limit the search to content with that label.

spaceKey

No

All spaces

Specify a space key to limit the search to the given space.
typeNoAllSpecify the content types to be included in the search - pages, blogs, comments, space descriptions, or all content types.
sizeNoMediumSpecify the size of the search field - medium or large.
additionalNoSpace NameDisplay the space name, a page excerpt or none under the search result.

Example:

<ac:structured-macro ac:name="livesearch">
  <ac:parameter ac:name="additional">page excerpt</ac:parameter>
  <ac:parameter ac:name="placeholder">Search this space</ac:parameter>
  <ac:parameter ac:name="labels">myLabel</ac:parameter>
  <ac:parameter ac:name="spaceKey">
    <ri:space ri:space-key="SS"/>
  </ac:parameter>
  <ac:parameter ac:name="type">page</ac:parameter>
  <ac:parameter ac:name="size">large</ac:parameter>
</ac:structured-macro>

Loremipsum macro

Display a few paragraphs of pseudo-Latin text.

Macro name: loremipsum

Macro body: None.

Parameter name

Required

Default

Parameter description and accepted values

default-parameter

(No name in wiki markup)

No

3

Number of paragraphs. Determines the amount of pseudo-Latin (space-filler) text to display. The macro will display a maximum number of 30 paragraphs.

Example:

<ac:structured-macro ac:name="loremipsum">
  <ac:parameter ac:name="">2</ac:parameter>
</ac:structured-macro>

Multimedia macro

Displays videos, animations and more, sourced from a file attached to a Confluence page and displayed on your page.

Macro name: multimedia

Macro body: None.

Parameter name

Required

Default

Parameter description and accepted values

page

No

Current page

Name of the page to which the multimedia file is attached.

space

No

Current space

Space key of the page that has the multimedia file attached.

name

Yes

None

File name of the multimedia file, which is attached to a Confluence page.

width

No

If not specified, the browser will determine the width based on the file type.

Width of the movie window to be displayed on the page. By default, this value is specified in pixels. You can also choose to specify a percentage of the window's width, or any other value accepted by HTML.

height

No

If not specified, the browser will determine the height based on the file type.

Height of the movie window to be displayed on the page. By default, this value is specified in pixels. You can also choose to specify a percentage of the window's height, or any other value accepted by HTML.

autostart

No

false

If the parameter is set to true then the video or audio file will start playing as soon as the page is loaded. If this option is set to false then the file will not play until the user clicks the icon or image on the page.

Example:

<ac:structured-macro ac:name="multimedia">
  <ac:parameter ac:name="width">500</ac:parameter>
  <ac:parameter ac:name="name">
    <ri:attachment ri:filename="Ninjas.MOV"/>
  </ac:parameter>
</ac:structured-macro>

Navigation Map macro

Displays a navigable map of the pages tagged with a given label.

Macro name: navmap

Macro body: None.

Parameter name

Required

Default

Parameter description and accepted values

default-parameter

(Unnamed in wiki markup)

Yes(None)The label that pages must contain to be included in the navigation map.

wrapAfter

No

5

The number of cells in a row.

title

No

(None)

A title for the navigation map.

cellHeight

No

60

Height of the cells, in pixels.

cellWidth

No

90

Width of the cells, in pixels.

theme

No

(None)

Not applicable to Confluence OnDemand.

The name of a Velocity template that defines a theme for the navigation map.

The name of your theme file must have the following format: navmap-mytheme.vm,  where mytheme is the name of your theme. That is also the value to use for the theme parameter of the macro. For example, if your theme file is navmap-roundededges.vm, use the value roundededges for this parameter.

Put your theme file in the confluence/WEB-INF/classes/templates/macros directory, in your Confluence installation. (Create the directory if it does not exist.)

Example:

<ac:structured-macro ac:name="navmap">
  <ac:parameter ac:name="wrapAfter">4</ac:parameter>
  <ac:parameter ac:name="title">My map name</ac:parameter>
  <ac:parameter ac:name="cellHeight">50px</ac:parameter>
  <ac:parameter ac:name="theme">navmap-mytheme.vm</ac:parameter>
  <ac:parameter ac:name="cellWidth">80px</ac:parameter>
  <ac:parameter ac:name="">mylabel</ac:parameter>
</ac:structured-macro>

Network macro

Displays a list of Network activity for users on your Confluence site.

Macro name: network

Macro body: None.

Parameter name

Required

Default

Parameter description and accepted values

default-parameter

(Unnamed in wiki markup)

Yesfollowing

The display mode, which determines the set of users to be listed, based on their relationship to the specified user:

  • following – those whom the user is following.
  • followers – those who are following the user.

username

No

Current user's username

The username of the Confluence user whose network interactions you wish to show.

max

No

30

The maximum number of users to show. If the number of users exceeds the specified maximum, then the macro provides a 'Show All' link. This link leads to the specified user's network view, showing the complete list of network interactions.

theme

No

full

Determines how the user's network is displayed:

  • full – Shows a large version of user's profile pictures. If the display mode is set to  'following', the macro offers the option to follow more users.
  • tiny – Shows only the small version of user's profile pictures.

Example:

<ac:structured-macro ac:name="network">
  <ac:parameter ac:name="username">
    <ri:user ri:userkey="12345678912345678912345"/>
  </ac:parameter>
  <ac:parameter ac:name="max">10</ac:parameter>
  <ac:parameter ac:name="theme">full</ac:parameter>
  <ac:parameter ac:name="">followers</ac:parameter>
</ac:structured-macro>

Noformat macro

Displays a block of text in monospace font.

Macro name: noformat

Macro body: Accepts plain text.

Parameter nameRequiredDefaultParameter description and accepted values
nopanelNofalse

Determines whether the macro draws a box around the content.

Available values:

  • true – Box is removed. In other words, there is no panel.
  • false – Box is drawn. In other words, there is a panel.

Example:

<ac:structured-macro ac:name="noformat">
  <ac:parameter ac:name="nopanel">true</ac:parameter>
  <ac:plain-text-body><![CDATA[http://www.example.com]]></ac:plain-text-body>
</ac:structured-macro>

Note macro

Displays a block of text in a yellow highlighted box.

Macro name: note

Macro body: Accepts rich text.

Parameter nameRequiredDefaultParameter description and accepted values
titleNo(None)The words that will appear in the header of the note block.
iconNotrue

Determines whether an icon appears next to the title. The icon is an exclamation mark inside a yellow triangle.

Available values:

  • true – the icon appears
  • false – the icon does not appear

Example:

<ac:structured-macro ac:name="note">
  <ac:parameter ac:name="icon">false</ac:parameter>
  <ac:parameter ac:name="title">My title</ac:parameter>
  <ac:rich-text-body>
    <p>This is the content of my note.</p>
  </ac:rich-text-body>
</ac:structured-macro>

Office Excel macro

Displays the content of an Excel spreadsheet on a wiki page.

Macro name: viewxls

Macro body: None.

Parameter nameRequiredDefaultParameter description and accepted values
nameYes(None.)

The file name of the Excel spreadsheet to be displayed. The document must be attached to a page on your Confluence site.

pageNoThe page containing the macroThe name of a Confluence page to which the Excel spreadsheet is attached.
colNoLast column with content

The number of the last column you want displayed, starting from '0' as the first column.

Hint for reducing the size of the spreadsheet: Use the col and row parameters to reduce the size of the spreadsheet displayed on the wiki page. This is especially useful to prevent the display from showing empty cells. This will also help to prevent 'out of memory' errors.

rowNoLast row with contentThe number of the last row you want displayed, starting from '0' as the first row.
gridNotrue

Determines whether the macro will show borders around the cells in the spreadsheet.

Accepted values:

  • true – Shows borders.
  • false – Does not show borders.
sheetNoThe most-recently viewed worksheetThe name of the worksheet that you want displayed.

Example:

<ac:structured-macro ac:name="viewxls">
  <ac:parameter ac:name="col">E</ac:parameter>
  <ac:parameter ac:name="name">
    <ri:attachment ri:filename="Spreadsheet.xls"/>
  </ac:parameter>
  <ac:parameter ac:name="sheet">Sheet1</ac:parameter>
  <ac:parameter ac:name="row">5</ac:parameter>
</ac:structured-macro>

Office PowerPoint macro

Displays the content of a PowerPoint presentation on a wiki page.

Macro name: viewppt

Macro body: None.

Parameter nameRequiredDefaultParameter description and accepted values
nameYes(None.)

The file name of the PowerPoint presentation to be displayed. The document must be attached to a page on your Confluence site.

pageNoThe page containing the macroThe name of a Confluence page to which the PowerPoint presentation is attached.
heightNo The height of the macro display, specified in pixels (for example: 10px, or just 10) or as a percentage (for example: 20%) of the window's height.
widthNo The width of the macro display, specified in pixels (for example: 10px, or just 10) or as a percentage (for example: 20%) of the window's height.
slideNoAll slides, starting with the first, as a slide showThe number of the slide that you want displayed on the Confluence page, where the first slide is numbered zero. Instead of a slide show, the page will display just the single slide, represented as a JPEG image.

Example:

<ac:structured-macro ac:name="viewppt">
  <ac:parameter ac:name="height">250</ac:parameter>
  <ac:parameter ac:name="width">250</ac:parameter>
  <ac:parameter ac:name="name">
    <ri:attachment ri:filename="101_samplepresentation.pptx"/>
  </ac:parameter>
</ac:structured-macro>

Office Word macro

Displays the content of a Word document on a wiki page.

Macro name: viewdoc

Macro body: None.

Parameter nameRequiredDefaultParameter description and accepted values
nameYes(None.)

The file name of the Word document to be displayed. The document must be attached to a page on your Confluence site.

pageNoThe page containing the macroThe name of a Confluence page to which the Word document is attached.

Example:

<ac:structured-macro ac:name="viewdoc">
  <ac:parameter ac:name="name">
    <ri:attachment ri:filename="Chocolate.doc"/>
  </ac:parameter>
</ac:structured-macro>

Page Index macro

Creates a hyperlinked alphabetical index of all page titles within the current space.

Macro name: index

Macro body: None.

Parameters: None.

Example:

<ac:structured-macro ac:name="index"/>

Page Properties macro

Allows you to embed metadata into a page and then display that data in tabular form using the Page Properties Report macro .Previously known as the Metadata Details macro.

Macro name: details

Macro body: Accepts rich text.

Parameter nameRequiredDefaultParameter description and accepted values
hiddenNofalseDetermines whether the data in the Page Properties macro will be displayed on the current page. This setting does not affect the display of the detail in the Page Properties Report macro.
labelNo(None)The label used to identify the metadata on this page. Confluence will add this label to the page.

Example:

<ac:structured-macro ac:name="details">
  <ac:parameter ac:name="hidden">true</ac:parameter>
  <ac:parameter ac:name="label">status</ac:parameter>
  <ac:rich-text-body>
    <table>
      <tbody>
        <tr>
          <td style="text-align: left;">Project Status</td>
          <td style="text-align: left;">Complete</td>
        </tr>
        <tr>
          <td colspan="1" style="text-align: left;">Team</td>
          <td colspan="1" style="text-align: left;">Green Parrots</td>
        </tr>
        <tr>
          <td colspan="1" style="text-align: left;">Deadline</td>
          <td colspan="1" style="text-align: left;">2012-09</td>
        </tr>
      </tbody>
    </table>
  </ac:rich-text-body>
</ac:structured-macro>

Page Properties Report macro

Presents a tabulated summary of selected metadata, which has been embedded on pages using the Page Properties macro. Previously known as the Details Summary macro.

Macro name: detailssummary

Macro body: None.

Parameter nameRequiredDefaultParameter description and accepted values
labelNo(None)Identifies the metadata to be included in the Page Properties Report. The report will show data from the Page Properties macros on the pages in the current space that have this label on the page.

Example:

<ac:structured-macro ac:name="detailssummary">
  <ac:parameter ac:name="label">status</ac:parameter>
</ac:structured-macro>

Page Tree macro

Displays a dynamic, hierarchical list of pages starting from a specified parent (root) page.

Macro name: pagetree

Macro body: None.

Parameter name

Required

Default

Parameter description and accepted values

excerptNofalse

Determines whether the page tree will show excerpts from each page. The excerpts must be defined on the individual pages by the Excerpt macro.

Available values:

  • true – Show excerpts.
  • false – Do not show excerpts.
expandCollapseAllNofalse

Determines whether the macro will offer the 'expand all' and 'collapse all' options at the top of the page tree. Your readers can click these links to open or close all branches of the tree at once.

Available values:

  • true – Show the 'expand all' and 'collapse all' options.
  • false – Do not show the options.
reverseNofalse

Used in combination with the sort parameter. Determines the order of pages displayed in the tree, by reversing the default (ascending) order.

Available values:

  • true – Pages will be displayed in descending order by title.
  • false – Pages will be displayed in ascending order by title.
rootNoThe home page of the space

Specifies the parent page for the page tree. The tree will include all children of the given page, plus their children and grand-children, and so on. The tree will not include the root page itself.

Available values:

  • A page title – to specify a page name for the parent or root of the tree. The tree will include all children and grand-children of the specified root. The tree will not include the specified root page itself.
  • @home – will include all pages under the home page of the space (default).
  • @self – will include all pages under the current page.
  • @parent – will include all pages under the parent of the current page, including the current page.
  • @none – will include all pages in the space, including orphaned pages and the home page.
searchBoxNofalse

Determines whether the macro will offer a search box above the page tree. The search box allows your readers to enter a search term, and then searches within the page tree for the specified value.

Available values:

  • true – Include the search box.
  • false – Do not include the search box.
sortNoposition

Determines the order in which pages are displayed in the tree. This sort order is for display purposes only. It does not permanently re-arrange the page order.

Available values:

  • bitwise – sort alphabetically, for example: title1, title10, title2.
  • creation – sort by date of creation.
  • modified – sort by order of date last modified.
  • natural – sort in 'natural' alphabetical order, for example: title1, title2, title10.
  • position – sort by the default Confluence sorting rules. If your pages have been ordered manually, this sort will respect the defined order. Otherwise the pages will be displayed in the 'natural' alphabetical order, such as: title1, title2, title10.
startDepthNo1

Indicates how many levels of children the tree should show when it opens for the first time.

Available values: Any number greater than 0.

Example:

<ac:structured-macro ac:name="pagetree">
  <ac:parameter ac:name="reverse">false</ac:parameter>
  <ac:parameter ac:name="sort">natural</ac:parameter>
  <ac:parameter ac:name="root">
    <ac:link>
      <ri:page ri:content-title="Page Name"/>
    </ac:link>
  </ac:parameter>
  <ac:parameter ac:name="startDepth">3</ac:parameter>
  <ac:parameter ac:name="excerpt">true</ac:parameter>
  <ac:parameter ac:name="searchBox">true</ac:parameter>
  <ac:parameter ac:name="expandCollapseAll">true</ac:parameter>
</ac:structured-macro>

Page Tree Search macro

Adds a search box to your Confluence page and searches a hierarchy of pages starting from a specified parent (root) page.

Macro name: pagetreesearch

Macro body: None.

Parameter name

Required

Default

Parameter description and accepted values

rootNoThe home page of the space

Specifies the parent page for the page tree. The tree will include all children of the given page, plus their children and grand-children, and so on. The tree will not include the root page itself.

Note: Unlike the Page Tree macro, the Page Tree Search macro does not accept the special values that start with an @ sign, such as @home or @self.

Example:

<ac:structured-macro ac:name="pagetreesearch">
  <ac:parameter ac:name="root">My page name</ac:parameter>
</ac:structured-macro>

Panel macro

Displays a block of text within a customisable panel.

Macro name: panel

Macro body: Accepts rich text.

Parameter nameRequiredDefaultParameter description and accepted values
titleNo(None)The words that will appear in the header of the panel.
borderStyleNosolid

The style of the panel's border.

Accepted values:

  • solid
  • dashed
  • Other valid CSS border styles.
borderColorNo The colour of the panel's border. Colours can be specified as HTML colour names or hexadecimal codes.
borderWidthNo The width of the panel's border, in pixels.
bgColorNo The background colour of the panel. Colours can be specified as HTML colour names or hexidecimal codes.
titleBGColorNo The background colour of the title row of the panel. Colours can be specified as HTML colour names or hexadecimal codes.
titleColorNo The colour of the text in the title row of the panel. Colours can be specified as HTML colour names or hexadecimal codes.

Example:

<ac:structured-macro ac:name="panel">
  <ac:parameter ac:name="bgColor">#72bc72</ac:parameter>
  <ac:parameter ac:name="titleBGColor">#00a400</ac:parameter>
  <ac:parameter ac:name="title">My title</ac:parameter>
  <ac:parameter ac:name="borderStyle">dashed</ac:parameter>
  <ac:parameter ac:name="borderColor">blue</ac:parameter>
  <ac:parameter ac:name="titleColor">white</ac:parameter>
  <ac:rich-text-body>
    <p>A formatted panel</p>
  </ac:rich-text-body>
</ac:structured-macro>

PDF macro

Displays the content of a PDF document on a wiki page.

Macro name: viewpdf

Macro body: None.

Parameter nameRequiredDefaultParameter description and accepted values
nameYes(None.)

The file name of the PDF document to be displayed. The document must be attached to a page on your Confluence site.

pageNoThe page containing the macroThe name of a Confluence page to which the PDF document is attached.

Example:

  <ac:structured-macro ac:name="viewpdf">
    <ac:parameter ac:name="name">
      <ri:attachment ri:filename="My_document.pdf"/>
    </ac:parameter>
  </ac:structured-macro>

Popular Labels macro

Displays the most popular labels used throughout your Confluence site or within a space.

Macro name: popular-labels

Macro body: None.

Parameter nameRequiredDefaultParameter description and accepted values
styleNolist

Determines how the macro displays the labels.

Accepted values:

  • list – displays the labels as a bullet list, ordered by popularity (highest first).
  • heatmap – displays the labels using different font sizes for each label depending on the label's popularity, ordered alphabetically by label name.
countNo100The number of labels to display.
spaceKeyNoNo restriction – include labels from all spaces in the siteIf a space key is given, the macro will include only labels in that space.

Example:

  <ac:structured-macro ac:name="popular-labels">
    <ac:parameter ac:name="count">20</ac:parameter>
    <ac:parameter ac:name="spaceKey">
      <ri:space ri:space-key="ds"/>
    </ac:parameter>
  </ac:structured-macro>

Profile Picture macro

Displays a user's profile picture on a page.

Macro name: profile-picture

Macro body: None.

Parameter nameRequiredDefaultParameter description and accepted values
UserYes(None)The username of a Confluence user.

Example:

<ac:structured-macro ac:name="profile-picture">
  <ac:parameter ac:name="User">
    <ri:user ri:userkey="12345678912345678912345"/>
  </ac:parameter>
</ac:structured-macro>

Recently Updated Dashboard macro

Displays a list of the most recently changed content within Confluence and is intended for use on the Confluence dashboard.

Macro name: recently-updated-dashboard

Macro body: None.

Parameter nameRequiredDefaultParameter description and accepted values
spacesNoThe space that contains the page on which the macro is added.

Filters content by space. The macro will display only the pages and other content which belong to the space(s) you specify here.

Accepted values:

  • One or more space keys, separated by commas.
  • An asterisk (*) means all spaces.
usersNoAll users.

Filters by username of the user who updated the content. The macro will only display content created and updated by the user(s) you specify here.

You can specify one or more usernames separated by commas.

widthNo100%The width of the macro display, specified as a percentage of the window width.
showProfilePicNofalse

Determines whether the macro displays profile pictures of the users who updated the content.

Accepted values:

  • true – the macro will show profile pictures.
  • false – the macro will not show profile pictures.
labelsNoNone. Labels are not used to filter the content.

Filters content by label. The macro will display only the pages and other content which are tagged with the label(s) you specify here. You can specify one or more labels, separated by commas.

Note: If there are no pages matching any of the specified labels, then Confluence will ignore the labels and will list all recently updated pages, as well as showing a message, "These labels don't exist and were ignored: xxx ".

typesNoAll content types.

Filters content by type. You can specify one or more types, separated by commas.

Accepted values:

  • page
  • blogpost or news
  • spacedesc
  • attachment
  • comment
  • mail
  • userinfo

Example:

<ac:structured-macro ac:name="recently-updated-dashboard">
  <ac:parameter ac:name="spaces">
    <ri:space ri:space-key="ss"/>
  </ac:parameter>
  <ac:parameter ac:name="users">
    <ri:user ri:userkey="12345678912345678912345"/>
  </ac:parameter>
  <ac:parameter ac:name="width">50%</ac:parameter>
  <ac:parameter ac:name="labels">choc</ac:parameter>
  <ac:parameter ac:name="types">page</ac:parameter>
</ac:structured-macro>

Recently Updated macro

Displays a list of recently changed content (pages, news items, comments, etc).

Macro name: recently-updated

Macro body: None.

Parameter nameRequiredDefaultParameter description and accepted values
spacesNoThe space that contains the page on which the macro is added.

Filters content by space. The macro will display only the pages and other content which belong to the space(s) you specify here.

You can specify one or more space keys, separated by a comma or a space.
  • To exclude content in a specific space, put a minus sign (-) immediately in front of that space key. For example: If you specify a space key of -BADSPACE you will get only content which is not in the BADSPACE.
  • To indicate that the results must come from a specific space, put a plus sign (+) immediately in front of that space key. For example: If you specify a space key of +GOODSPACE you will get only content in GOODSPACE. (Note that this is not particularly useful, because each content item belongs to one space only. If you put a plus sign next to one space key and list other space keys too, the other space keys will be ignored.)

Special values:

  • @self — The current space.
  • @personal — All personal spaces.
  • @global — All site spaces.
  • @favorite — The spaces you have marked as favourite.
  • @favourite — The same as @favorite above.
  • @all — All spaces in your Confluence site.
  • * — The same as @all above.

When specifying a personal space, remember to use the tilde (~) sign in front of the username, such as ~jbloggs or ~jbloggs@example.com.

authorNoAll users.

Filters by the username of the user who updated the content. The macro will only display content created and updated by the user(s) you specify here.

You can specify one or more authors, separated by a comma or a space.For example: jsmith,jbrown

To include content from one user, but exclude from another user: jsmith,!jbrown

maxNo15

The maximum number of results to be displayed.

The theoretical maximum value that this parameter can accept is 2 to the power of 31, minus 1 (or 2147483647). But this maximum is limited to 200 in the code, for performance reasons. More details are in this issue:  CONF-19096

hideHeadingNofalse

Determines whether the macro hides or displays the text 'Recently Updated' as a title above the list of content.

Accepted values:

  • true – Title is hidden.
  • false – Title is shown.
widthNo100%The width of the macro display, specified as a percentage of the window width.
themeNoconcise

Choose the appearance of the macro.

Accepted values:

  • concise – The default list, showing the names of pages which were updated or commented on, the users who made the page modifications, and time when the modifications occurred.
  • social – Shows recent modifications in reverse chronological order, grouped by user in short time segments. A sub list appears within each user's time segment, showing the names of pages which they updated or commented on and the time when these modifications occurred.
  • sidebar – Lists recent updates in reverse chronological order, showing the names of pages which were updated or commented on and time when the page modifications occurred. This theme does not show authorship.
showProfilePicNofalse

Determines whether the macro displays profile pictures of the users who updated the content.

Accepted values:

  • true – the macro will show profile pictures.
  • false – the macro will not show profile pictures.
labelsNoNone. Labels are not used to filter the content.

Filters content by label. The macro will display only the pages and other content which are tagged with the label(s) you specify here. You can specify one or more labels, separated by commas.

Note: If there are no pages matching any of the specified labels, then Confluence will ignore the labels and will list all recently updated pages, as well as showing a message, "These labels don't exist and were ignored: xxx ".

Filter the results by label. The macro will display only the pages etc which are tagged with the label(s) you specify here.

You can specify one or more label values, separated by a comma or a space.

  • To exclude content which matches a given label, put a minus sign (-) immediately in front of that label value. For example: If you specify a label value of -badpage you will get only content which is not labelled with 'badpage'.
  • To indicate that the results must match a given label value, put a plus sign (+) immediately in front of that label value. For example: If you specify a label value of +superpage,+goodpage you will get only content which has at least two labels, being 'superpage' and 'goodpage'.

typesNoAll content types.

Filters content by type. You can specify one or more types, separated by commas.

You can specify one or more types, separated by a comma or a space.

To exclude content of a given content type, put a minus sign (-) immediately in front of that content type. For example: If you specify a content type of -blogpost you will get pages and all other content except for blog posts.

Available values:

Example:

<ac:structured-macro ac:name="recently-updated">
  <ac:parameter ac:name="spaces">
    <ri:space ri:space-key="ss"/>
  </ac:parameter>
  <ac:parameter ac:name="author">
    <ri:user ri:userkey="12345678912345678912345"/>
  </ac:parameter>
  <ac:parameter ac:name="users"/>
  <ac:parameter ac:name="max">10</ac:parameter>
  <ac:parameter ac:name="width">50%</ac:parameter>
  <ac:parameter ac:name="theme">sidebar</ac:parameter>
  <ac:parameter ac:name="labels">choc</ac:parameter>
  <ac:parameter ac:name="types">page</ac:parameter>
</ac:structured-macro>

Recently Used Labels macro

Lists labels most recently used in a specified scope (global, space, or personal)

Macro name: recently-used-labels

Macro body: None.

Parameter nameRequiredDefaultParameter description and accepted values
titleNoNone.Adds a title to the top of the list in table style. Titles are only visible when the style parameter is set to table.
scopeNoglobal

The scope of labels to be displayed in the list.

Accepted values:

  • global – All spaces (non-personal) in the Confluence installation.
  • space – The current space.
  • personal – Your own personal space.
styleNolist

The style of the list of labels:

  • list – Displays the list of labels horizontally.
  • table – Includes additional information such as the page to which the label was added and the user who added it.
countNo10The maximum number of labels to display in the list.

Example:

  <ac:structured-macro ac:name="recently-used-labels">
    <ac:parameter ac:name="title">My title</ac:parameter>
    <ac:parameter ac:name="scope">space</ac:parameter>
    <ac:parameter ac:name="style">table</ac:parameter>
    <ac:parameter ac:name="count">20</ac:parameter>
  </ac:structured-macro>

Related Labels macro

Lists labels frequently appearing on the same pages as the current page's labels.

Macro name: related-labels

Macro body: None.

Parameter nameRequiredDefaultParameter description and accepted values
labelsNoNoneThe label(s) for which you want to view related labels. If you include more than one label, separate them with commas.

Example:

  <ac:structured-macro ac:name="related-labels">
    <ac:parameter ac:name="labels">choc,cake</ac:parameter>
  </ac:structured-macro>

RSS Feed macro

Displays the contents of an RSS feed.

Macro name: rss

Macro body: None.

Parameter nameRequiredDefaultParameter description and accepted values
maxNo15The maximum number of news items to display.
showTitlesOnlyNofalse

Determines whether the macro will show only the titles of the news items, or the titles plus content.

Accepted values:

  • true – Displays titles only.
  • false – Displays titles and content.
urlYes(None)The URL of the RSS feed.
titleBarNotrue

Determines whether the macro will show a title above the list of news items.

Accepted values:

  • true – Displays the title.
  • false – Does not display a title.

Example:

  <ac:structured-macro ac:name="rss">
    <ac:parameter ac:name="max">10</ac:parameter>
    <ac:parameter ac:name="showTitlesOnly">true</ac:parameter>
    <ac:parameter ac:name="url">
      <ri:url ri:value="http://myblog.com/feed"/>
    </ac:parameter>
    <ac:parameter ac:name="titleBar">false</ac:parameter>
  </ac:structured-macro>

Search Results macro

Searches Confluence, and includes the results in the page.

Macro name: search

Macro body: None.

Parameter nameRequiredDefaultParameter description and accepted values
lastModifiedNo(None.)

Defines a period of time in weeks, days, hours and/or minutes. The macro will display the content modified within that time frame.

These are the values you can use:
  • w = weeks
  • d = days
  • h = hours
  • m = minutes

For example:

  • 2h 35m
  • 3d 30m

Notes:

  • If no time category is specified, Confluence assumes minutes.
  • If you specify more than one time period (for example, weeks and days), you must separate the periods with a space. You can put them in any order.
  • The time categories are not case sensitive. For example, '4d' is the same as '4D'.

queryYes(None.)

The search terms which this macro will use to generate its results.

You can refine your search query by using operators such as 'AND' and 'OR'. For example: my_term1 AND my_term2

For more information, take a look at the documentation on the Confluence search syntax.

contributorNo(None.)The username of a Confluence user. If this parameter is present, the macro will show only content created or updated by the given user.
maxLimitNo10The maximum number of search results to display.
typeNo(None.)

The type of content to include in the search results.

Accepted values:

  • page
  • comment
  • blogpost
  • attachment
  • userinfo – the content of user profiles
  • spacedesc – the content of space descriptions

Example:

<ac:structured-macro ac:name="search">
  <ac:parameter ac:name="lastModified">3w</ac:parameter>
  <ac:parameter ac:name="query">choc</ac:parameter>
  <ac:parameter ac:name="contributor">
    <ri:user ri:userkey="1235678912345678912345678912345"/>
  </ac:parameter>
  <ac:parameter ac:name="maxLimit">10</ac:parameter>
  <ac:parameter ac:name="type">page</ac:parameter>
  <ac:parameter ac:name="spacekey">
    <ri:space ri:space-key="ss"/>
  </ac:parameter>
</ac:structured-macro>

Section macro

Used with the Column macro to define columns on a page. See  Working with page layouts and columns and sections.

Macro name: section

Macro body: Rich text, consisting of one or more Column macros.

Parameter nameRequiredDefaultParameter description and accepted values

border

NoFalseIf the value is true, the columns in this section will have a dashed border.

Example:

<ac:structured-macro ac:name="section">
  <ac:parameter ac:name="border">true</ac:parameter>
  <ac:rich-text-body>
    <ac:structured-macro ac:name="column">
      <ac:parameter ac:name="width">100px</ac:parameter>
      <ac:rich-text-body>
        <p>This is the content of <strong>column 1</strong>.</p>
      </ac:rich-text-body>
    </ac:structured-macro>
    <ac:structured-macro ac:name="column">
      <ac:rich-text-body>
        <p>This is the content of <strong>column 2</strong>.</p>
      </ac:rich-text-body>
    </ac:structured-macro>
  </ac:rich-text-body>
</ac:structured-macro>

Space Attachments macro

Displays a list of attachments belonging to the current space.

Macro name: space-attachments

Macro body: None.

Parameter nameRequiredDefaultParameter description and accepted values
showFilterNotrue

Determines whether or not the filter panel is shown. If you select this option, people viewing the page will be able to filter the list of attachments by file type (extension) and by label.

Accepted values:

  • true – Macro displays the filter panel.
  • false – Macro does not display the filter panel.
spaceNoCurrent space.Determines the Confluence space containing the attachments that the macro will display.

Example:

  <ac:structured-macro ac:name="space-attachments">
    <ac:parameter ac:name="showFilter">false</ac:parameter>
    <ac:parameter ac:name="space">
      <ri:space ri:space-key="ds"/>
    </ac:parameter>
  </ac:structured-macro>

Space Details macro

Displays the details of a Confluence space, including the space name, description, and more.

Macro name: space-details

Macro body: None.

Parameter nameRequiredDefaultParameter description and accepted values
widthNo100%The width of the space details table, specified as a percentage of the page width.

Example:

  <ac:structured-macro ac:name="space-details">
    <ac:parameter ac:name="width">50%</ac:parameter>
  </ac:structured-macro>

Space Jump macro

Allows you to link from a page in one space to a page with the same name in another space, without knowing the name of the page when you create the link.

Macro name: spacejump

Macro body: None.

Parameter nameRequiredDefaultParameter description and accepted values
aliasNoThe name of the current pageThe text to display as the hyperlinked text.
spaceYes(None.)The key of the space that contains a page with the same name as the current page. Space keys are case sensitive.

Example:

  <ac:structured-macro ac:name="spacejump">
    <ac:parameter ac:name="alias">My Space</ac:parameter>
    <ac:parameter ac:name="space">
      <ri:space ri:space-key="SS"/>
    </ac:parameter>
  </ac:structured-macro>

Spaces List macro

Displays a list of the spaces visible to the user.

Macro name: spaces

Macro body: None.

Parameter nameRequiredDefaultParameter description and accepted values

default-parameter

(Unnamed in wiki markup)

NoAll spaces

Specify the view from which spaces are listed.

Accepted values:

  • all – All spaces in the Confluence site.
  • category – Spaces grouped according to space categories.
  • favourite – Spaces in the reader's list of favourites.
  • new – Spaces created within the last 7 days.
widthNo100%The width of the list of spaces, specified as a percentage (%) of the window.

Example:

  <ac:structured-macro ac:name="spaces">
    <ac:parameter ac:name="width">80%</ac:parameter>
    <ac:parameter ac:name="">favourite</ac:parameter>
  </ac:structured-macro>

Status macro

Displays a coloured lozenge, useful for reporting project status.

Macro name: status

Macro body: None.

Parameter nameRequiredDefaultParameter description and accepted values
colourNoGrey

The colour of the lozenge.

Accepted values: Grey, Red, Yellow, Green, Blue

titleNoThe value of the colour parameterThe text that will appear inside the lozenge. If you do not specify any text, the title will be the colour of the lozenge, that is 'Grey', 'Red', 'Yellow', 'Green' or 'Blue'.
subtleNofalse

The style of the lozenge and its border.

Accepted values:

  • false – The lozenge will have the default style: a solid coloured background with white text.
  • true – The lozenge will have the outline, or subtle, style: a white background with a coloured border and coloured text.

Example:

  <ac:structured-macro ac:name="status">
    <ac:parameter ac:name="colour">Green</ac:parameter>
    <ac:parameter ac:name="title">On track</ac:parameter>
    <ac:parameter ac:name="subtle">true</ac:parameter>
  </ac:structured-macro>

Table of Contents macro

Displays a table of contents based on the headings on the page.

Macro name: toc

Macro body: None.

Parameter nameRequiredDefaultParameter description and accepted values
printableNotrueIf you set this parameter to false, the table of contents will not be visible when you print the page.
styleNononeThe style of bullet point for each list item. You can use any valid CSS style. For example:
  • none – No list style is displayed.
  • circle –  The list style is a circle.
  • disc – The list style is a filled circle. This is the typical bullet list, and is the one we are using in this example list.
  • square — The list style is a square.
  • decimal — The list is numbered (1, 2, 3, 4, 5).
  • lower-alpha — The list style is lower case, alphabetised (a, b, c, d, e).
  • lower-roman — The list style is lower-case roman numerals (i, ii, iii, iv, v, vi).
  • upper-roman — The list style is upper-case roman numerals (I, II, III, IV, V, VI).
maxLevelNo7Maximum heading level. Use this parameter to select the highest heading level to include.  For example, a value of 2 will list h1 and h2 levels, but will not include h3 and below.
indentNo(None)

This parameter applies to vertical lists only (type = list). 

Use this parameter to indent the list items according to CSS quantities. For example, a value of 10px will successively indent list heading groups by 10 pixels. Level 1 headings will be indented 10px, and level 2 headings by an additional 10px, and so on.

minLevelNo1Minimum heading level. The heading level at which the table of contents will start.  For example, a value of 2 will list h2, h3, and h4 headings, but will not include h1 headings.
classNo(None)A CSS class name. If you have a custom style sheet, you can use this parameter to output the table of contents with the specified class attribute.
excludeNo(None)

Specifies the headings to exclude by pattern matching. The value must be a regular expression. If this parameter is specified, the table of contents will include only the headings that match the regular expression. Example: .*\.[1//2]

 See Sun's Regex documentation for examples of constructing regular expression strings.
typeNolist

Defines the overall format of the table of contents.

Available values:

  • list – displays the table of contents in a vertical list.
  • flat – displays a horizontal series of links. For example: [Heading 1] [Heading 2] [Heading 3].
outlineNofalseA value of true will apply outline numbering to the headings as displayed in the table of contents. For example: 1.1, 1.2, 1.3.
separatorNobrackets

This parameter applies to flat lists only (type = flat).  Use this parameter to style the display of a flat list. 

Available values:

  • brackets – Each item is enclosed by square brackets: [ ].
  • braces  – Each item is enclosed by braces: { }.
  • parens – Each item is enclosed by parentheses: ( ).
  • pipe – The items are separated by a pipe: |
  • anything – The items are separated by the value you enter. You can enter any text as a separator, for example ***. If using a custom separator, be aware that text displays exactly as entered, with no additional white space to further separate the characters.
includeNo(None)

Specifies the headings to include by pattern matching. The value must be a regular expression. If this parameter is specified, the table of contents will ignore any headings that do not match the regular expression. Example: .*\.[1//2]

 See Sun's Regex documentation for examples of constructing regular expression strings.

Example:

This example shows a list-type table of contents.

  <ac:structured-macro ac:name="toc">
    <ac:parameter ac:name="printable">true</ac:parameter>
    <ac:parameter ac:name="style">square</ac:parameter>
    <ac:parameter ac:name="maxLevel">2</ac:parameter>
    <ac:parameter ac:name="indent">5px</ac:parameter>
    <ac:parameter ac:name="minLevel">2</ac:parameter>
    <ac:parameter ac:name="class">bigpink</ac:parameter>
    <ac:parameter ac:name="exclude">[1//2]</ac:parameter>
    <ac:parameter ac:name="type">list</ac:parameter>
    <ac:parameter ac:name="outline">true</ac:parameter>
    <ac:parameter ac:name="include">.*</ac:parameter>
  </ac:structured-macro>

This example shows a flat table of contents.

  <ac:structured-macro ac:name="toc">
    <ac:parameter ac:name="maxLevel">2</ac:parameter>
    <ac:parameter ac:name="minLevel">2</ac:parameter>
    <ac:parameter ac:name="class">bigpink</ac:parameter>
    <ac:parameter ac:name="exclude">[1//2]</ac:parameter>
    <ac:parameter ac:name="type">flat</ac:parameter>
    <ac:parameter ac:name="outline">true</ac:parameter>
    <ac:parameter ac:name="separator">pipe</ac:parameter>
    <ac:parameter ac:name="include">.*</ac:parameter>
  </ac:structured-macro>

 

 

Table of Content Zone macro

Displays a table of contents from a defined page 'zone'.

Macro name: toc-zone

Macro body: Accepts rich text.

Parameter nameRequiredDefaultParameter description and accepted values
locationYesboth

Determines where the macro will display the table of contents, relative to the zone delineated by the macro.

Accepted values:

  • top – The table of contents appears at the start of the zone.
  • bottom – The table of contents appears at the end of the zone.
  • both – The table of contents appears at the start and end of the zone.
printableNotrueIf you set this parameter to false, the table of contents will not be visible when you print the page.
styleNononeThe style of bullet point for each list item. You can use any valid CSS style. For example:
  • none – No list style is displayed.
  • circle –  The list style is a circle.
  • disc – The list style is a filled circle. This is the typical bullet list, and is the one we are using in this example list.
  • square — The list style is a square.
  • decimal — The list is numbered (1, 2, 3, 4, 5).
  • lower-alpha — The list style is lower case, alphabetised (a, b, c, d, e).
  • lower-roman — The list style is lower-case roman numerals (i, ii, iii, iv, v, vi).
  • upper-roman — The list style is upper-case roman numerals (I, II, III, IV, V, VI).
maxLevelNo7Maximum heading level. Use this parameter to select the highest heading level to include.  For example, a value of 2 will list h1 and h2 levels, but will not include h3 and below.
indentNo(None)

This parameter applies to vertical lists only (type = list). 

Use this parameter to indent the list items according to CSS quantities. For example, a value of 10px will successively indent list heading groups by 10 pixels. Level 1 headings will be indented 10px, and level 2 headings by an additional 10px, and so on.

minLevelNo1Minimum heading level. The heading level at which the table of contents will start.  For example, a value of 2 will list h2, h3, and h4 headings, but will not include h1 headings.
classNo(None)A CSS class name. If you have a custom style sheet, you can use this parameter to output the table of contents with the specified class attribute.
excludeNo(None)

Specifies the headings to exclude by pattern matching. The value must be a regular expression. If this parameter is specified, the table of contents will include only the headings that match the regular expression. Example: .*\.[1//2]

 See Sun's Regex documentation for examples of constructing regular expression strings.
typeNolist

Defines the overall format of the table of contents.

Available values:

  • list – displays the table of contents in a vertical list.
  • flat – displays a horizontal series of links. For example: [Heading 1] [Heading 2] [Heading 3].
outlineNofalseA value of true will apply outline numbering to the headings as displayed in the table of contents. For example: 1.1, 1.2, 1.3.
separatorNobrackets

This parameter applies to flat lists only (type = flat).  Use this parameter to style the display of a flat list. 

Available values:

  • brackets – Each item is enclosed by square brackets: [ ].
  • braces  – Each item is enclosed by braces: { }.
  • parens – Each item is enclosed by parentheses: ( ).
  • pipe – The items are separated by a pipe: |
  • anything – The items are separated by the value you enter. You can enter any text as a separator, for example ***. If using a custom separator, be aware that text displays exactly as entered, with no additional white space to further separate the characters.
includeNo(None)

Specifies the headings to include by pattern matching. The value must be a regular expression. If this parameter is specified, the table of contents will ignore any headings that do not match the regular expression. Example: .*\.[1//2]

 See Sun's Regex documentation for examples of constructing regular expression strings.

Example:

<ac:structured-macro ac:name="toc-zone">
  <ac:parameter ac:name="printable">false</ac:parameter>
  <ac:parameter ac:name="maxLevel">2</ac:parameter>
  <ac:parameter ac:name="minLevel">2</ac:parameter>
  <ac:parameter ac:name="location">top</ac:parameter>
  <ac:parameter ac:name="type">flat</ac:parameter>
  <ac:parameter ac:name="outline">true</ac:parameter>
  <ac:parameter ac:name="separator">pipe</ac:parameter>
  <ac:rich-text-body>
    <p>Only headings within this block are included in the table of contents.</p>
  </ac:rich-text-body>
</ac:structured-macro>

Tasklist macro

Displays a dynamic task list which can be modified in view mode.

Macro name: tasklist

Macro body: Accepts wiki markup, for defining the tasks.

Parameter nameRequiredDefaultParameter description and accepted values

title

NoTask ListThe title to be displayed above the list of tasks.
enableLockingNofalse

Determines whether the macro allows users to lock individual tasks so that they cannot be changed.

Accepted values:

  • true – The task list offers the option to lock tasks.
  • false – There is no option to lock a task.
widthNo530pxThe width of the task list, specified in pixels (for example: 200px) or as a percentage of page width (for example: 20%).
promptOnDeleteNofalse

Determines whether Confluence will ask the user to confirm the deletion of a task.

Accepted values:

  • true – Asks for confirmation before deleting a task.
  • false – Deletes the task without asking for confirmation.

Example:

Note: The CDATA content inside the macro body defines the tasks in the list. This content is coded in wiki markup, as a table.The first row in the table defines the column headings for the task list. Each subsequent row defines a task.

<ac:structured-macro ac:name="tasklist">
  <ac:parameter ac:name="title">My title</ac:parameter>
  <ac:parameter ac:name="enableLocking">true</ac:parameter>
  <ac:parameter ac:name="width">20%</ac:parameter>
  <ac:parameter ac:name="promptOnDelete">true</ac:parameter>
  <ac:plain-text-body><![CDATA[||Completed||Priority||Locked||CreatedDate||CompletedDate||Assignee||Name||
|F|M|F|1371784117215|          |admin|Book tickets|
|F|M|F|1371784127222|          |admin|Check passport expiry|
]]></ac:plain-text-body>
</ac:structured-macro>

Tip macro

Displays a block of text in a green box.

Macro name: tip

Macro body: Accepts rich text.

Parameter nameRequiredDefaultParameter description and accepted values
iconNotrueDetermines whether to display the standard Confluence tip icon in the title bar of the tip box.
titleNo(None)The title of the tip box. If specified, the title text will be displayed in bold next to the icon.

Example:

<ac:structured-macro ac:name="tip">
  <ac:parameter ac:name="icon">false</ac:parameter>
  <ac:parameter ac:name="title">My title</ac:parameter>
  <ac:rich-text-body>
    <p>This is my hint.</p>
  </ac:rich-text-body>
</ac:structured-macro>

User List macro

Displays a list of Confluence users in a given group.

Macro name: userlister

Macro body: None.

Parameter nameRequiredDefaultParameter description and accepted values
groupsYes(None.)

One or more groups containing the Confluence users that the macro will list.

Accepted values:

  • A comma-separated list of group names.
  • * (an asterisk – The macro will list all users registered on the Confluence site.

onlineNoAll users

Instructs the macro to differentiate between online and offline users.

Accepted values:

  • Unspecified – The macro will show all registered users.
  • true – The macro will show only online users.
  • false – The macro will show only offline users.

Note: In order to make this parameter functional, a System Administrator needs to enable the User Log In Listener for your Confluence site. Not applicable to Confluence OnDemand.

Example:

  <ac:structured-macro ac:name="userlister">
    <ac:parameter ac:name="groups">confluence-users</ac:parameter>
    <ac:parameter ac:name="online">false</ac:parameter>
  </ac:structured-macro>

User Profile macro

Displays a summary of a given Confluence user's profile.

Macro name: profile

Macro body: None.

Parameter nameRequiredDefaultParameter description and accepted values
userYes(None.)

The username of the Confluence user whose profile summary you wish to show.

Example:

<ac:structured-macro ac:name="profile">
  <ac:parameter ac:name="user">
    <ri:user ri:userkey="12345678912345678912345678912345"/>
  </ac:parameter>
</ac:structured-macro>

User Status List macro

Displays a history of a given Confluence user's status updates.

Macro name: status-list

Macro body: None.

Parameter nameRequiredDefaultParameter description and accepted values
usernameYes(None.)

The username of the Confluence user whose status updates you wish to show.

Example:

<ac:structured-macro ac:name="status-list">
  <ac:parameter ac:name="username">
    <ri:user ri:userkey="12345678912345678912345678912345"/>
  </ac:parameter>
</ac:structured-macro>

Warning macro

Displays a block of text in a red highlight box.

Macro name: warning

Macro body: Accepts rich text.

Parameter nameRequiredDefaultParameter description and accepted values
iconNotrueDetermines whether to display a warning icon in the title bar of the text box.
titleNo(None.)The title of the warning box. If specified, the title text will be displayed in bold next to the icon.

Example:

<ac:structured-macro ac:name="warning">
  <ac:parameter ac:name="icon">false</ac:parameter>
  <ac:parameter ac:name="title">This is my title</ac:parameter>
  <ac:rich-text-body>
    <p>This is <em>important</em> information.</p>
  </ac:rich-text-body>
</ac:structured-macro>

Widget Connector macro

Displays videos, slide shows, twitter chats, documents and more, sourced from other web sites and displayed on your Confluence page.

Macro name: widget

Macro body: None.

Parameter nameRequiredDefaultParameter description and accepted values
heightNo The height of the display, in pixels. Specify the number of pixels only.
widthNo The width of the display, in pixels. Specify the number of pixels only.
urlYes(None.)The URL provided by the external website for embedding content from that website onto another web page.

Example:

  <ac:structured-macro ac:name="widget">
    <ac:parameter ac:name="height">480</ac:parameter>
    <ac:parameter ac:name="width">640</ac:parameter>
    <ac:parameter ac:name="url">
      <ri:url ri:value="http://youtube.com/watch?v=23pLByj_q5U"/>
    </ac:parameter>
  </ac:structured-macro>

Macro format notes

Macro bodies

Some macros accept a body as well as parameters.

Plain text bodies

The body of a plain text macro must be inside a CDATA block. So the following is not sufficient:

<ac:plain-text-body>text</ac:plain-text-body>

The correct usage is:

<ac:plain-text-body><![CDATA[text]]></ac:plain-text-body>

Other notes  

  • The 'Required' column indicates whether the parameter is required on data entry. If the parameter is not supplied, Confluence will insert default values as indicated in the 'Default' column.
  • A request from the Atlassian technical writers about comments and feedback: When adding comments to this page, please restrict your comments to constructive feedback on the documentation itself: Things we've missed in the documentation, and things that will be useful to other readers. If you have other feedback about the editor, wiki markup, the XML storage format, and Confluence 4 in general, please add your comments in the section titled Confluence 4 Editor - Customer Feedback, and its child pages. Our reason for this request: When a page attracts a large number of comments, it makes it difficult for everyone to read the page, and to add or respond to comments about the documentation. Thanks. (smile)

  • No labels