Skip to main content

JSON Page Template files

Overview

This files describes the JSON Page Template files, that are usually got generated by the Prodyflow Block Editor. You don't need do create those type of files to build a template.

This document describes the structure and purpose of the JSON template used to configure dynamic storefront landing pages. The template defines the order of visual sections and the configuration settings for each section type.

The JSON file is composed of two main top-level keys:

  • order: Defines the sequence in which sections appear on the page.
  • sections: Contains the configuration objects for each section referenced in order.

Top-Level Structure

{
"order": ["section-id-1", "section-id-2"],
"sections": {
"section-id-1": { ... },
"section-id-2": { ... }
}
}

order

Type: array[string]

Defines the rendering order of sections on the page. Each value must match a key inside the sections object.

sections

Type: object

Dictionary of section configurations indexed by unique section IDs.


Section Object Structure

Every section follows a common base structure:

{
"type": "section-type",
"settings": { ... },
"block_name": "Human readable name",
"conditions": { ... }
}

Fields

FieldTypeRequiredDescription
typestringYesDefines the component type rendered by the frontend
settingsobjectYesConfiguration specific to the component
block_namestringYesAdmin / CMS display name
conditionsobjectYesVisibility rules

Conditions Object

Controls conditional rendering logic.

{
"type": "group",
"first": true,
"operator": "AND",
"conditions": []
}

Fields

FieldTypeDescription
typestringCondition grouping type
firstbooleanIndicates root condition
operatorstringLogical operator (AND / OR)
conditionsarrayNested condition rules

Section Types

4. Product

Displays products.

Settings Structure

{
"tags": [tagIds],
"characteristics": object,
"featured_category": [categoryIds],
"featured_products": [productIds],
"featured_bundles": [bundleIds],
"discount": [min, max]
}

Filtering Logic

Products can be selected using:

  • Tags
  • Categories
  • Characteristics
  • Discount range
  • Explicit product IDs
  • Explicit bundle IDs


Minimal Example Template

{
"order": [
"video",
"product-slider"
],
"sections": {
"video": {
"type": "video",
"settings": {
"title": {},
"video": {
"id": 1,
"name": "example.mp4",
"path": "https://example.com/video"
}
},
"block_name": "Hero Video",
"conditions": {
"type": "group",
"first": true,
"operator": "AND",
"conditions": []
}
}
}
}