The remotepublish-page macro is used within a trigger macro to publish (copy) the current page to another Confluence server. This macro requires that the access to the remoter server has been previously configured via the Remote Publishing configuration tab under the Space Admin tab. Also, API access must be enabled on the remote server. See Remote Publishing Workflow for details.
Remote publishing requires the Remote Publishing Plugin
Used to reference a remote publishing configuration. The configuration defines the remote server URL, destination space, user name and password with edit rights on the remote server.
The following code snippet publishes the current page to the remote server (using the configuration name RemotePublish) when a page reaches the Published state and defines a custom event, pagepublished, for use with other triggers.
The custom event can be used to fire additional triggers to improve messaging, send notifications and handle error conditions. The first section sets a message on the page that publishing succeeded, sending an email to the user defined by TechWriter if publishing succeeds. The second section preforms similar tasks if publishing fails and sends the page back to an earlier state, To Publish.