---
title: "Snapshot document publishing"
canonical: "https://support.appfire.com/space/CDML/649925672/Snapshot%20document%20publishing"
format: markdown
---
> Macro (aura-html)


## Overview

Snapshot publishing lets you create static versioned documents from your dynamic Confluence content, freezing content from Confluence macros that display live content in the snapshot document.

> ℹ️ Snapshot Publishing is a feature of the [Comala Publishing app](/wiki/spaces/AHP/pages/615025181) that is used to create a snapshot of a document and manage snapshots as a collection. Comala Document Management integration with Comala Publishing lets you automatically create a snapshot document of a Confluence page using a workflow trigger.

Once a snapshot is created, it is organized and managed in one or more themed groupings of snapshot documents, called **collections**, to create manuals and static records for audit.

![graphic_integartionpublishing_documentmanagement_snapshot.png](media://5fa143df-c161-4c34-a0a6-2b15c53b1e0a)

Each snapshot document is versioned and can be added to one or more collections. Collections can contain snapshot documents from one or more spaces. View permissions for each collection are managed outside space permissions. 

A global collections viewer in the Confluence header allows users to view snapshots in PDF or HTML format.

|  |  |
| --- | --- |
| ![image-20250808-134456.png](media://1dad6174-70fc-44eb-9810-400d88254298) | The **[Comala Publishing (Snapshot Publishing) app v3.0+](https://marketplace.atlassian.com/plugins/com.comalatech.publishing/server/overview)** must be installed to enable snapshot publishing. |

> Macro (excerpt)
> 
> ## Activating snapshot publishing
> 
> There are three steps to setting up snapshot publishing to take place on a Comala workflow event:
> 
> 1. [Install Comala Publishing ](/wiki/spaces/AHP/pages/615022741)[in](/wiki/spaces/AHP/pages/615025629)[ your instance](/wiki/spaces/AHP/pages/615022741) and [enable snapshot publishing](/wiki/spaces/AHP/pages/615025629) for a space
> 2. Set up [Snapshot publishing](/wiki/spaces/AHP/pages/615025487) in your space snapshot publishing dashboard
> 3. Update your workflow to add a trigger with the snapshot publishing process and apply the updated workflow to your document (see below)
> 
> ### Publishing a snapshot using a workflow trigger
> 
> A snapshot can be published using either:
> 
> - A [snapshot-page macro](https://appfire.atlassian.net/wiki/spaces/CDML/pages/649694908) to create a snapshot that is added to a specified snapshot collection
> - A [pdf-export macro](https://appfire.atlassian.net/wiki/spaces/CDML/pages/649955790) to create a snapshot that is added to the page as an attachment
> 
> > 📝 Both action macros can be used in the same trigger.
> 
> #### Snapshot-page action trigger workflow markup
> 
> The publishing is triggered by an action macro, [snapshot-page](https://appfire.atlassian.net/wiki/spaces/CDML/pages/649694908), which must be used in a [trigger](https://appfire.atlassian.net/wiki/spaces/CDML/pages/649563178).
> 
> ```plaintext
> {workflow:name=Snapshot Publishing}
>    {state:Editing|submit=Review}
>    {state}
>    {state:Review|approved=Published|rejected=Editing}
>       {approval:Review|assignable=true}
>    {state}
>    {state:Published|final=true|updated=Editing}
>    {state}
>    {trigger:statechanged|state=Published}
>       {set-metadata:lastapprover}
>       @user@
>       {set-metadata}
>       {snapshot-page:collection=mycollection|editor=@lastapprover@}
>    {trigger}
> {workflow}
> ```
> 
> The example markup above is based on an example from [same-space publishing](https://appfire.atlassian.net/wiki/spaces/CDML/pages/649794062), but we've added the [trigger](https://appfire.atlassian.net/wiki/spaces/CDML/pages/649859133) at the bottom.
> 
> When the state changes to **Published**, the trigger is activated and the `snapshot-page` macro instructs the Comala Publishing app to create a snapshot document from the Confluence document.
> 
> - The **collection parameter** value is required to add the snapshot to a named collection
> - The **editor parameter** value is the user who is set as the creator of the snapshot document
> 
> In the example above:
> 
> - The **collection** **paramete**r value must be the name of a snapshot collection that has been linked to or created in the space by the space administrator
> - The **editor** **parameter** value is a metadata value set in the workflow trigger prior to the snapshot-page macro action
> 
> > 📝 The user who is added as the value for the editor parameter must have been added as a **collection contributor** to the collection permissions by the collection owner/creator.
> 
> > ℹ️ For snapshot publishing, the [snapshot-page macro](https://appfire.atlassian.net/wiki/spaces/CDML/pages/649694908) does all the work. The macro can be used to publish documents from any state using an appropriate trigger event.
> 
> ### pdf-export action trigger workflow markup
> 
> With Comala Publishing installed, the [pdf-export macro](https://appfire.atlassian.net/wiki/spaces/CDML/pages/649955790) can be used in a trigger to export a snapshot of a page or blog post in PDF format and add the file to the page as an attachment. 
> 
> The PDF is added with a filename in the following format:
> 
> - <*confluence_filename*>_<*document_version*>_<*date_pdf_file_created*>_<*time_pdf_created*>.pdf
> 
> ```
> {trigger:statechanged|state=Published}
>       {pdf-export}
> {trigger}
> ```
> 
> There are no macro parameters to configure.
> 
> > 📝 The [pdf-export macro](https://appfire.atlassian.net/wiki/spaces/CDML/pages/649955790) can also be used with Scroll PDF Exporter** 4.10.11** or higher.

## Macros

> Macro (contentbylabel)

## Related pages

- [https://appfire.atlassian.net/wiki/spaces/CDML/pages/649794062](https://appfire.atlassian.net/wiki/spaces/CDML/pages/649794062)
- [https://appfire.atlassian.net/wiki/spaces/CDML/pages/649957805](https://appfire.atlassian.net/wiki/spaces/CDML/pages/649957805)
- [https://appfire.atlassian.net/wiki/spaces/CDML/pages/649728423](https://appfire.atlassian.net/wiki/spaces/CDML/pages/649728423)

**Comala Publishing**

- [https://appfire.atlassian.net/wiki/spaces/AHP/pages/650215885](https://appfire.atlassian.net/wiki/spaces/AHP/pages/650215885)