Check whether a page exists
Let's check whether a certain page exists or not in this particular Confluence space.
Ingredients
Apps | Reporting for Confluence Data Center |
|---|---|
Macros | Report Block, Report Body, Report Empty |
Suppliers | Value supplier |
Guide
Create a Report Block macro.
Within the Report Block macro, create a Local Reporter macro with the Key parameter set to
value:contentfollowed by the name of a page available in your space.
In this example, we set the Key parameter tovalue:content Recipes.Within the same Report Block macro, create a Report Body macro, and within its body macro, enter
The page exists!.Within the same Report Block macro, create a Report Empty macro, and within its body macro, enter
The does not page exist!.Click Save and view the results.
Macro structure
Result
Does the page "Recipes" exist on this space?
The page exists!
Notes
You can try changing the Key parameter in the Local Reporter macro to a non-existent page (in this example, the page name Recipes).