Help Center
  • Welcome
  • Setka Editor
    • Getting started
    • Drag-and-Drop & Multiselect
    • Text editing
    • Grids and Layout
    • Images
      • Image Editor
    • Background images
    • Icons
    • Animations
    • Lists
    • Tables
    • Dividers
    • Footnotes
    • Hotspots
    • Enhance Symbols
    • Post templates
    • Buttons
    • Comments and collaboration
    • Embeds
    • Hyphenation
    • Responsive layout for mobile screens
    • Custom CSS
    • Custom JS plugins
  • Setka Content Design System Manager
    • Creating and editing styles
    • Text formats and fonts
    • Styles display for mobile mevices
    • Text and background colors
    • Dividers
    • Icons
    • Components – reusable design elements
      • Creating Components with HTML and CSS
        • CSS in components
        • Component examples
    • Configuring layout grids
    • Editing default elements with Custom CSS
    • Adding team members
  • Account Settings
    • Account settings basics
    • Access rights
    • Billing and subscription
  • Preserve your Setka Editor content after the service shutdown
  • Integrations
    • Setka and WordPress
      • Installing Setka Editor WordPress plugin
      • Launching Setka Editor on the post creation page
      • Setka Editor and WordPress compatibility
      • Setka Editor compatibility with the most popular WordPress plugins
      • Inserting graphs, charts, or diagrams into a post
      • Setka Editor and Google AMP
      • Inserting adverts into a post
      • srcset — the attribute for image size optimization
      • Page load speed optimization settings
        • Autoptimize plugin configuration
      • WordPress troubleshooting: known Issues and how to fix them
      • Preserve your Setka Editor content after the service shutdown
    • Setka and Drupal
      • Setka for Drupal — compatibility, and features
      • Installing Setka modules for Drupal
      • Setka content on AMP pages in Drupal
    • Setka and Magento
      • Installing Magento 2 extension
        • Setka Editor configuration page
      • Preserve your Setka Editor content after the service shutdown
    • Setka and HubSpot
      • Setka Editor and HubSpot Blogs
      • Setka Editor and HubSpot Landing Pages
      • Semi-gated content with a HubSpot form
      • Preserve your Setka Editor content after the service shutdown
    • Setka and Bitrix
      • Preserve your Setka Editor content after the service shutdown
    • Setka and Ghost
      • Copying and pasting posts from Setka to Ghost
    • Setka and SharePoint Online
      • Installing Setka Editor application into SharePoint Online
    • Setka and Zapier
      • Setka and Webflow
        • Exporting new posts
        • Updating exported posts
      • Setka and Shopify
    • Setka and Integromat
    • Content Cloud
  • API
    • Setka Content Cloud API
    • Webhooks
    • API for Custom CMS Integration
      • Introduction to custom integration
      • Integration with Content Design System Manager (CDSM)
        • Initial sync — receiving Setka Editor files to connect them to your CMS
        • Storing and processing Setka Editor files
        • Connecting Setka Editor files to the pages of your site
        • Receiving style updates from the Style Manager and new editor versions
      • Setka Post Editor initialization (JavaScript)
      • Integration with Style Manager (API v1, previous version)
      • Preserve your Setka Editor content after the service shutdown
    • Custom Components API
  • VIDEO TUTORIALS
    • Setka Editor Video Tutorials
  • Components Library
    • Components Library
    • Guide: Ideas for Using Setka Editor’s Components to Improve Content Design
  • Content Experience Design Best Practices
    • Guide To Designing a Great Content Experience
Powered by GitBook
On this page
  • Introduction
  • Assets that rely on Setka Editor CDN
  • Migrating Setka Editor assets to your CMS's CDN
  • Step 1 — receive the list of posts
  • Step 2 — download assets for every post
  • Step 3 — uploading assets to your CDN
  • Step 4 — replacing asset URLs and updating content

Was this helpful?

  1. API
  2. API for Custom CMS Integration

Preserve your Setka Editor content after the service shutdown

This is a step-by-step guide on ensuring your content created with Setka Editor is safe in your CMS after Setka Editor infrastructure shutdown.

PreviousIntegration with Style Manager (API v1, previous version)NextCustom Components API

Last updated 1 year ago

Was this helpful?

Introduction

To ensure robust content preservation on your CMS after the Setka Editor infrastructure shutdown this guide will do two things:

  1. Explain which assets rely on Setka Editor CDN

  2. Describe the steps needed to migrate mentioned assets to your CMS's CDN

Assets that rely on Setka Editor CDN

  • images

  • JavaScript code for enabling interactive post elements

  • CSS code which enables all the styling of your articles

Migrating Setka Editor assets to your CMS's CDN

Step 1 — receive the list of posts

Make a request to to receive your list of Setka Editor posts. Here is a request example:

https://editor.setka.io/api/v2/posts?token=<token>&filter=state:<state>&include=images&limit=10

state determines the publication status of the post:

  • Set to published to only get published posts.

  • Set to draft to get drafts.

  • Set to all to get both drafts and published posts.

limit determines the number of posts you can receive as a response. Please make sure you don't set the value too low and miss some of the posts.

Step 2 — download assets for every post

If the request is successful, you will receive a response consisting of an array of posts. The response will be paginated if the number of posts is large. Below is an example API request response:

HTTP/1.1 200 OK
{
  posts: [
    {
      "id": 2587,
      "title": "Stylist",
      "style_name": "General",
      "layout_name": "6col_19774",
      "reading_time": 240,
      "preview_link": "https://editor.setka.io/posts/80a44hd5924792",
      "state": "published"
      "author": {
        "id": 44,
        "name": "John Smith"
      },
      "body_html": "Hello!",
      "assets": {
        "plugins": [
          "https://ceditor.setka.io/clients/js_plugins/5ca41dc7f0df3e3d6170901b627d32fc/public.js"
        ],
        "styles": [
          "https://ceditor.setka.io/common_css/common_css_1565603693.css",
          "https://ceditor.setka.io/clients/GP1TwUnF9mFFVzgqnAplHSQs51xdl4WT/css/loM7yyO-6xsVawmBxqej8A.css",
          "https://ceditor.setka.io/clients/GP1TwUnF9mFFVzgqnAplHSQs51xdl4WT/layout_option_builds/19774/gazQpY7j6Cgq9gFsEKYF5A.css"
        ],
        "images": [
          {
            "id": 3310,
            "url": "https://ceditor.setka.io/clients/U8Cr2B1ZnJjyHr6e6xn_Qa7N1oqyj7cB/post_images/-tltJS8D79MI5Yltt37MCA.jpg",
            "alt": "Alt text"
            "sizes": [
              {
                "width": 3654,
                "height": 5473,
                "url": "https://ceditor.setka.io/clients/U8Cr2B1ZnJjyHr6e6xn_Qa7N1oqyj7cB/post_images/-tltJS8D79MI5Yltt37MCA.jpg"
              },
              {
                "width": 500,
                "height": 5473,
                "url": "https://ceditor.setka.io/6xAHRUiLM1NBnWZ9JupZNdugX1UyoQkg9kzIGk9--vk/w:500/q:88/plain/clients/U8Cr2B1ZnJjyHr6e6xn_Qa7N1oqyj7cB/post_images/-tltJS8D79MI5Yltt37MCA.jpg"
              },
              {
                "width": 1000,
                "height": 5473,
                "url": "https://ceditor.setka.io/Ioa24dDnWZ9JupZNdugX1UyoQkg9kzIGk9--vk/w:1000/q:88/plain/clients/U8Cr2B1ZnJjyHr6e6xn_Qa7N1oqyj7cB/post_images/-tltJS8D79MI5Yltt37MCA.jpg"
              }
            ]
          }
        ]
      },
      "hubspot_post": {
        "id": 141,
        "url": "https://hubspotblog.com/1-blog-page/-temporary-slug-bbd6cb8e-afed-4291-8937-c779c9ac2d25?hs_preview=ludkAblF-28956926215",
        "blog_id": 1315
      },
      "created_at": "2019-07-19T10:25:27Z",
      "updated_at": "2019-07-19T10:27:40Z",
      "published_at": "2019-07-22T13:34:11Z"
    }
  ],
  pagination: {
    "page": 1,
    "limit": 20,
    "page_count": 1,
    "total_count": 1
  }
}

Download the assets for each post from the array. The possible types of assets are:

File
URL
Description

plugins

https://ceditor.setka.io/clients

/js_plugins/5ca41dc7f0df3e3d6170901b627d32fc/public.js

The scripts to run interactive post elements (e.g., animations, galleries, or notes).

styles

https://ceditor.setka.io/common_css

/common_css_1565603693.css

images

https://ceditor.setka.io/clients

/U8Cr2B1ZnJjyHr6e6xn_Qa7N1oqyj7cB/post_images/-tltJS8D79MI5Yltt37MCA.jpg

The images used in the post, where:

— id — the image’s unique ID.

— url — the link to the file.

— alt — the alternative text.

Step 3 — uploading assets to your CDN

When all assets are downloaded, store them in your infrastructure.

Advice – store files with the same path, that will simplify the update script.

Step 4 — replacing asset URLs and updating content

When all assets are downloaded and stored in your infrastructure, you need to replace all links used in the Post body and include CSS files in the Post Page. You will need a custom script tailored to your case.

Inside the Post body there might be images. If you created Posts inside Setka Cloud you’ll find srcset generated for multiple image sizes. It’s a feature provided by Setka Cloud. Links to image variations are not provided. We suggest that you remove everything inside the srcsetHTML attribute for in <img tag> and store the original image in your infrastructure.

Example:

You have the following piece of code:

<img src="https://img.setka.io/clients/AutWJxVDaz_R9_xWagHPL9nT4WVLIRNp/post_images/mufasa_headshot-2023012401152726.png" data-image-id="248663" data-image-name="Mufasa_headshot.png" class="stk-image stk-reset" srcset="https://img.setka.io/clients/AutWJxVDaz_R9_xWagHPL9nT4WVLIRNp/post_images/mufasa_headshot-2023012401152726.png 1044w, https://img.setka.io/rk1GAk6jbdIj4L5shxsSoWdU8vdWLXBx3AcTkiOmKec/w:500/q:88/plain/clients/AutWJxVDaz_R9_xWagHPL9nT4WVLIRNp/post_images/mufasa_headshot-2023012401152726.png 500w, https://img.setka.io/2g0DHW1QRePXqTjfSSAAuLYU4TPFisvQlQZF_jEez_8/w:750/q:88/plain/clients/AutWJxVDaz_R9_xWagHPL9nT4WVLIRNp/post_images/mufasa_headshot-2023012401152726.png 750w, https://img.setka.io/2G2xzHJHv4XawjrRFaa6V76e7G3ZltwPorAYSmLH0zU/w:1000/q:88/plain/clients/AutWJxVDaz_R9_xWagHPL9nT4WVLIRNp/post_images/mufasa_headshot-2023012401152726.png 1000w" width="1044" height="1302" loading="lazy">

Then change the link inside Setka Post body and remove the srcset. The result will look like this:

<img src="https://your-domain.com/clients/AutWJxVDaz_R9_xWagHPL9nT4WVLIRNp/post_images/mufasa_headshot-2023012401152726.png" data-image-id="248663" data-image-name="Mufasa_headshot.png" class="stk-image stk-reset" width="1044" height="1302" loading="lazy">

Check the for more filters.

The of post styles, including the common style file, the standalone style, and the layout grid file.

— sizes — several options for the image size, depending on the device’s screen size. Note: Getting the images field in your response will require using .

For example: If CSS URL looks like: you should store it in your infrastructure and make it accessible via the URL on your domain, for example like this: .

You should pick the original size – in src attribute (you can find the same link inside Post API response) and make it accessible on the URL like

https://ceditor.setka.io/clients/123/example.css
https://you-domain.com/clients/123/example.css
https://img.setka.io/clients/AutWJxVDaz_R9_xWagHPL9nT4WVLIRNp/post_images/mufasa_headshot-2023012401152726.png
https://your-domain.com/clients/AutWJxVDaz_R9_xWagHPL9nT4WVLIRNp/post_images/mufasa_headshot-2023012401152726.png
CSS files
additional parameters
Setka Content Cloud API
Content Aloud API documentation