Preview API

API documentation for the required endpoints that the Presentation Preview plugin needs to work.

Presentation Preview plugin depends on a frontend API to render a close to truth and very production-like HTML preview. Each web site (or product) needs to present the API as described in this documentation.

Naviga Web provides this API as part of the product, but with this documentation it should be possible to create a similar API with other Web presentations also.

API docs

Article preview

POST example.com/preview-api/v1/article

Responds with html page representing similar to how that article would look like on this site/product.

Query Parameters

NameTypeDescription

body*

String

Json as example below

Response
{
  "success": true,
  "content": "article page as html here"
}
Request body
{
  "data": {
    "uuid": "article uuid here!" // Optional
    "meta": {
      "imengine" : "https://yes.hello", // The url of the editorial Imengine
      "concepts":  // Related concepts here
      [
        "13e5896f-e9c7-4481-8bb4-bd48bb69943d",
        "90a0891b-2804-4c89-9515-d042c2f23e18"
      ],
      "articles": // Related articles here
      [
        "13e5896f-e9c7-4481-8bb4-bd48bb69943d",
        "90a0891b-2804-4c89-9515-d042c2f23e18"
      ]
    },
    "content" : "NewsML idf xml here! Kan be found on the property 'BodyRaw' in public OC."
  }
}

Hint: Presentation preview API response needs to be HTML, but it's not limited to Web sites only. You could in theory build your own renderer to simulate newsletters, mobile apps or other products if you like, as long as they provide this API.

Last updated