---
title: "remoteremove-page macro"
canonical: "https://support.appfire.com/space/CDML/649628704/remoteremove-page%20macro"
format: markdown
---
> Macro (aura-html)


## Overview

> Macro (excerpt)
> 
> Unpublish (remove) a page from a remote Confluence instance

The `remoteremove-page` macro is used as an [action](https://appfire.atlassian.net/wiki/spaces/CDML/pages/649858941) to remove previously published content from a space on a different Confluence Data Center or Cloud instance.

- Content is developed in a space on the source instance
- Published content is pushed to a space on a remote instance

The `remoteremove-page` macro can remove the published content from the remote instance. This is generally only required when content becomes obsolete and should be removed from the remote published content.

For more information, see: [Remote-space publishing](https://appfire.atlassian.net/wiki/spaces/CDML/pages/649728423)

## Requirements

> 📝 This macro requires the installation of the [Comala Remote Publishing app for Comala Document Management](https://appfire.atlassian.net/wiki/spaces/CDML/pages/649955967).

Before using this macro, you must ensure both the source and target Confluence instances are properly configured.

For more information, see [Remote-space publishing](https://appfire.atlassian.net/wiki/spaces/CDML/pages/649728423).

## Where to use it?

Optional.

One or more `remoteremove-page` macros can be put in a [trigger macro](https://appfire.atlassian.net/wiki/spaces/CDML/pages/649859133).

## Parameters

| Parameter | Required | Default | Notes |
| --- | --- | --- | --- |
| `config_name` | :check_mark: |  | The name of the remote publishing configuration to use.<br>- `remoteremove=`<*config_name*><br>Where config_name is the name of the remote publishing profile added to the [source space remote publishing configuration](https://appfire.atlassian.net/wiki/spaces/CDML/pages/649728423).<br>> ℹ️ The configuration defines the remote instance URL and destination space, as well as the username and password for an account on that instance that has **Edit Content **permissions in the target space. |

## Basic example

This example remote publishes to a remote Confluence instance defined by the `MyDestination` publishing configuration.

```
{trigger:statechanged|state=Published}
      {remotepublish-page:MyDestination}
{trigger}
```

Once published, the user has an option to *unpublish* the page. This can be done using the workflow state dialog box on the source space page to transition the content to the **Unpublish** state  `submit=Unpublish`.

The trigger, added to listen for this state transition and action the removal, uses the `remoteremove-page` macro.

```plaintext
{trigger:statechanged|state=Obsolete}
      {remoteremove-page:MyDestination}
{trigger}
```

The published page is removed from the remote Confluence instance. From the **Unpublished** state, they can either republish it or make it obsolete.

Here's the full markup for the example workflow:

```plaintext
{workflow:Remote-space publishing}
   {state:Editing|submit=Review}
   {state}
   {state:Review|approved=Published|rejected=Editing}
      {approval:Review}
   {state}
   {state:Published|updated=Editing|final=true|submit=Unpublish}
   {state}
   {state:Unpublish|approved=Published|rejected=Obsolete|hidefrompath=true|updated=Editing}
      {approval:Page Unpublished|approvelabel=Republish|rejectlabel=Make Obsolete}
   {state}
   {state:Obsolete|submit=Editing|updated=Editing}
   {state}
   {trigger:statechanged|state=Published}
      {remotepublish-page:MyDestination}
   {trigger}
   {trigger:statechanged|state=Obsolete}
      {remoteremove-page:MyDestination}
   {trigger}
{workflow}
```

> 📝 The `final=true` parameter on the **Published** state is not required for remote-space publishing; however, it helps to clarify which versions of a document are published in the source space.

## All examples

> Macro (contentbylabel)

## Related pages

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

**External links:**

- [https://marketplace.atlassian.com/plugins/com.comalatech.remotepublishing/server/overview](https://marketplace.atlassian.com/plugins/com.comalatech.remotepublishing/server/overview)