To ensure that both the syndicated site and the site relaying the syndicated content are authorized and active participants in the process, Viafoura utilizes a secure key system consisting of two elements:
- A secure key, generated by Viafoura to enable site syndication between sites within the same site group. This secure key will be privately held by Viafoura and not shared publicly. Please ask your Customer Success Manager to enable this component within Viafoura's backend.
- A container signature, generated by the client's backend systems for each specific widget that will be displaying syndicated content.
In order to implement this feature, or to start testing it in a development environment, please work with our Customer Success team to confirm that a Secure key has been generated for your site group; then follow one of the methods below to obtain container signatures and create syndicated widgets.
Once the secure key has been created, there are two different workflows that can be used to syndicate content between two sites:
- Visit the page that will be supplying the syndicated content.
- Log in with administrator permissions.
- In the Viafoura widget open the settings menu and click the "syndicate" button.
- Copy the HTML code snippet generated by the widget.
- Paste that HTML code snippet on the template of the page that will be receiving the syndicated content. This will add a net new widget on the page, with the syndicated content.
- If the secure key has not been created, the "syndicate" button will return the error message "Failed to fetch content syndication signature".
- If the sites relying the syndicated content and receiving it are not in the same site group in Viafoura's system, the syndicated widget will not load.
It's possible to automate the content syndication process to, for example, enable an option in the CMS for users to syndicate content without having to go to Viafoura's widget in the FrontEnd:
- Use your ClientID and ClientSecret to authenticate with Viafoura's API access: Authorization API Endpoint
- Use the Bearer token generated from step 1 for authentication call when calling the API Endpoint to obtain the container signature key for syndication of that specific widget: Get Container Signature API Endpoint
- Save the API response in your database.
- Use the container signature key and the containerID of the content that will be syndicated to create the code snippet that will load the new widget in the page that is receiving the syndicated content.
This is an example of a code snippet that will generate an original (non-syndicated) conversations widget:
<div class="viafoura"> <vf-conversations vf-container-id="unique-article-id"></vf-conversations> </div>
Note that in the example above, container ID is being set directly in the widget. Normally we would recommend setting the container ID in the page meta tags.
Learn more about containerID.
If you need to fetch the content container UUID, you can do so using your container id here.
This is an example of a code snippet that will generate a conversations widget syndicated from the previous example:
<div class="viafoura"> <vf-conversations vf-container-id="unique-article-id" signature="-site-group-secure-signature"></vf-conversations> </div>
Updated about 1 year ago