Website logo
➡️ purplepublish.com
Overview
Support
Setup
Editorial
Experience
Growth
Developers
Expert
Navigate through spaces
⌘K
Developers Documentation
Catalog-API
Web Hooks
Hub Import API
Entitlement services
Purple Growth – Setup
Custom S3 Buckets
Dynamic Resources
Builder Pipelines Architecture Info
Docs powered by Archbee
Developers Documentation
...
Purple Growth – Setup
Link Optimizer Setup

CMS Integration

5min

Our Link Optimizer (LO) tool provides both the ability to generate links on some manual text selection (preferred in the beginning) or fully automatic on the whole article. 

LO can be used on both existing indexed content, or on draft content, the latter being the main use-case. Therefore, similar to our first data ingestion, we need a way to properly read and save some draft content from our application.

So, the main workflow would be: 

  1. load some content from a given CMS
  2. manually or automatically add links
  3. save the updated content back to a given CMS

Purple DS HUB

In this case, our requirement are already covered by the JSON or GRAPHQL API described in the section Data ingestion and indexing.

Therefore, no additional requirement is needed.

Third Party CMS or application

Similarly to the data ingestion, we need to embed the load/save in a custom connector and would require the availability from a customer perspective of 2 endpoints for that purpose.

The simplest would be a REST API with a GET and POST methods, e.g: https://api.cms.example/articles/<id>, that would be used like:

sequenceDiagram
    participant Client CMS
    participant ACM

    Note over Client CMS, ACM : Load Article
    activate Client CMS

    Client CMS ->>+ ACM : GET https://acm.sprylab.com/link-optimizer/<id>
    ACM ->>+ Client CMS : GET https://api.cms.example/articles/<id>
    Client CMS -->>- ACM : return

    ACM ->> ACM : Links Generation

    Note over Client CMS, ACM : Save action
    ACM ->>+ Client CMS : POST https://api.cms.example/articles/<id>
    Client CMS -->>- ACM : return

    deactivate ACM
    deactivate Client CMS


The load method would be called automatically when loading LO with a given id: https://acm.sprylab.com/link-optimizer/<id>

Note that we offer the possibility to add a custom API token when calling our front-end by adding the following query parameters:

  • api_token_acm: ACM token generated via login
  • api_token_customer: token used for its own load/save API 
  • user_id: ACM internal user ID

The save method would be called automatically when clicking on the save button in the LO interface.

The JSON body returned or written back should comply with the data defined in the Indexer API, as seen in Data ingestion and indexing.

Disabling the ACM Header via URL Query Parameters

Document image


The Header can be disabled via query parameters in the URL, to do that you have to set the following:

  • hideHeader=1

Per default, a close button is visible in iFrames that calls the parent iFrame to close itself. If instead a custom iFrame close button is desired, the ACM close button can be hidden via

  • hideCloseButton=1



Updated 19 Oct 2023
Did this page help you?
PREVIOUS
Link Optimizer Setup
NEXT
Configuration Setup
Docs powered by Archbee
TABLE OF CONTENTS
Third Party CMS or application
Disabling the ACM Header via URL Query Parameters
Docs powered by Archbee
ImprintPrivacy Policy
© Sprylab Technologies GmbH 2023