{
  "format": "baxly-survey/1.0",
  "notes": "Example 3: a magazine readership study built on lists. A page loops over an Articles list (one page per article, image on the side, merge tags in the text), a follow-up loop over the articles the reader picked, a question that draws its choices from a list and shows each article's image before its title, and a MaxDiff on topics. The images are placeholders hosted by Baxly; replace them with your own https URLs.",
  "survey": {
    "name": "Readership study: October issue",
    "intro": {
      "headline": "Your October issue",
      "body": "<p>We will show you the articles from this issue and ask what you read. About <b>6 minutes</b>.</p>",
      "minutes": 6
    },
    "show_page_titles": false
  },
  "lists": [
    {
      "name": "Articles",
      "columns": ["Title", "Image", "Section"],
      "items": [
        { "Title": "The case for smaller warehouses", "Image": "https://baxly.brc.com/survey-definition/examples/images/warehouses.png", "Section": "Features" },
        { "Title": "Interview: a year of automation", "Image": "https://baxly.brc.com/survey-definition/examples/images/automation.png", "Section": "Features" },
        { "Title": "Five tools worth a second look", "Image": "https://baxly.brc.com/survey-definition/examples/images/tools.png", "Section": "Products" },
        { "Title": "Regional outlook: the Southeast", "Image": "https://baxly.brc.com/survey-definition/examples/images/southeast.png", "Section": "Markets" },
        { "Title": "Letters to the editor", "Image": "https://baxly.brc.com/survey-definition/examples/images/letters.png", "Section": "Departments" }
      ]
    },
    {
      "name": "Topics",
      "columns": ["Topic"],
      "items": [
        { "Topic": "Pricing and margins" },
        { "Topic": "Hiring and training" },
        { "Topic": "Technology and automation" },
        { "Topic": "Regulation" },
        { "Topic": "Customer trends" },
        { "Topic": "Supply chain" }
      ]
    }
  ],
  "pages": [
    {
      "key": "reader_profile",
      "title": "About you",
      "questions": [
        {
          "key": "role",
          "type": "dropdown",
          "text": "Which best describes your role?",
          "required": true,
          "choices": ["Owner or executive", "Manager", "Buyer", "Sales", { "text": "Other", "is_other": true }]
        },
        {
          "key": "sections_read",
          "type": "multi_select",
          "text": "Which sections do you usually read?",
          "choices": ["Features", "Products", "Markets", "Departments", { "text": "None of these", "exclusive": true }]
        }
      ]
    },
    {
      "key": "article_pages",
      "title": "{{item.Title}}",
      "loop": { "list": "Articles", "sample": { "mode": "all" }, "order": "shuffle", "per_page": 1 },
      "side_media": { "image": "{{item.Image}}", "position": "left", "caption": "{{item.Section}}" },
      "questions": [
        {
          "key": "read_level",
          "type": "select_one",
          "text": "Did you read \"{{item.Title}}\"?",
          "required": true,
          "choices": [
            { "key": "most", "text": "Read most of it" },
            { "key": "some", "text": "Read some of it" },
            { "key": "saw", "text": "Saw it but did not read it" },
            { "key": "no", "text": "Do not recall seeing it" }
          ]
        }
      ]
    },
    {
      "key": "favorites",
      "title": "Favorites",
      "questions": [
        {
          "key": "favorite_articles",
          "type": "multi_select",
          "text": "Which articles were the most useful to you? Pick up to three.",
          "choices_from": { "list": "Articles", "label": "Title", "image": "Image" },
          "settings": { "max_selections": 3, "image_mode": "show", "image_size": "small", "image_position": "before" }
        }
      ]
    },
    {
      "key": "favorite_followup",
      "title": "Why this one",
      "loop": { "from_answers": "favorite_articles", "max": 3 },
      "questions": [
        {
          "key": "why_useful",
          "type": "open_text",
          "text": "What made \"{{item.Title}}\" useful?",
          "settings": { "multiline": true },
          "ai_followup": { "goal": "Get one concrete example of how the article was used", "max": 1 }
        }
      ]
    },
    {
      "key": "topics_page",
      "title": "Topics",
      "questions": [
        {
          "key": "topic_maxdiff",
          "type": "maxdiff",
          "text": "Which topic matters most and least to you right now?",
          "choices_from": { "list": "Topics", "label": "Topic" },
          "settings": { "exposures": 3 }
        }
      ]
    },
    {
      "key": "wrap",
      "title": "Wrap up",
      "questions": [
        {
          "key": "issue_rating",
          "type": "star_rating",
          "text": "Overall, how would you rate this issue?",
          "settings": { "max": 5 }
        }
      ]
    }
  ]
}
