Sites

Replace site route previews

Changed on

Replace the site's complete set of per-route unfurl previews. Each entry maps a route within the site (e.g. a clip page) to its own preview card and hero share, so links to that page unfurl distinctly in Slack instead of with the site-wide hero. An optional startSeconds/endSeconds window makes the unfurled player serve only that segment of the hero (trimmed at the asset’s HLS segment boundaries — see the field descriptions). The set is replaced wholesale — typically written by the same pipeline that publishes the site — and an empty array clears all route previews. Routes are stored in canonical form: hash-router prefixes ('#/'), query strings, and surrounding slashes are stripped, so '/clip/intro', 'clip/intro/', and '#/clip/intro' all name the same route. Links to routes with no registered preview fall back to the site-level preview fields.

put/sites/{site_id}/route-previews

Request

  • Base URL
    https://api.cloudglue.dev/v1
  • Auth
    HTTP bearer

Path parameters

site_idstring uuid required

The ID of the site

Request body

Example request

{
  "previews": [
    {
      "route": "clip/intro-to-x"
    }
  ]
}

Response

The stored route previews (routes in canonical form)

Example response

{
  "previews": [
    {
      "route": "clip/intro-to-x"
    }
  ]
}

Changes