When you use APIs, you may need to handle rich content. Rich content is a block of content that incorporates multiple content types. For example, you may have a block of rich content made up of a heading, a paragraph, an image, and a caption.
A block of rich content is represented in the data as an object with nodes (sections) and decorations (styles), where each one can be a distinct type. Define rich content with a Ricos Document, which is a strictly defined JSON object structure. Learn more about Ricos.
Rich content is displayed in parts of the Wix interface that include different media types and text formatting, such as blog posts. APIs associated with these parts of the interface can receive and return rich content.
Some of Ricos' types are universally supported, but the ones that aren't need a specific plugin to be enabled for the type to be rendered. Wix APIs that consume rich content specify which plugins are enabled in their rich content field description. In the Ricos playground, you can enable and disable plugins to match the plugins enabled by the API that's consuming your rich content.
You can either convert existing content into a Ricos document, or create a Ricos document from scratch using the Ricos Playground. Here's a mini version of the playground:
Learn more about creating Ricos documents.
When developing sites or building an app with Blocks, you can display rich content using the RichContentViewer element.