Saved Content in Page Model API/ResourceAPI

I would like to know if there is a way to setup a second resource api that will display the saved content of documents instead of the published content.

For example… If i have Page A with Component A That references Document A.

If all those piece are already published… When i make a change to the document and save i would like that change to be shown in the resourceapi as a non-published but saved change, We are going to use this feature to set up a preview environment for our users.

I noticed in 14.2.1 you all have a solution that comes out of the box for preview pages… Would this worked for saved content or would everything need to be published in order to utilize that feature?

If that solution requires publishing items first, then please suggest an implementation that would work for my given use case.

Please let me know if i have worded anything to be confusing in this post, Thanks!

Hi,
You could very easily setup a specific preview mount of type preview (hst:type = preview) that references a preview mountpoint.

The preview mountpoint can then reference the normal content root and reference the preview configuration path (something like /hst:hst/hst:configurations/yoursite-preview)

The type preview on the mount will make sure unpublished documents are returned. The reference to a preview configuration in the hst:site for the mountpoint will make sure the preview configuration of your site is returned as well.

Hope this helps.

Cheers,
Matthijs

Hi Marke,

I have checked this in our setup which is pretty basic right now.
Suppose you have setup the resource api and it’s availlable here: {host}/site/resourceapi {host}/site/_cmsinternal/resourceapi will return the previewed variant (which you would see in the channelmanager)

I hope this helps you.

greetings,

Brian Gorter

Hello @Marke_l_Spellman,

the saved but un-published changes are exactly what is visible in the Experience manager (what @Brian_Gorter correctly mentioned in his reply). However, you can not access the _cmsinternal host directly, not without a valid CMS session at least.

I guess your requirement is to expose a preview of the site to non-CMS users. In this case, the answer from @Matthijs would be the way to go. You can read more about the setup here.

Kind regards,
Lef