{
  "info": {
    "name": "Sheilmeier - Segmentation API complete (enriched examples)",
    "schema": "https://schema.getpostman.com/json/collection/v2.1.0/collection.json",
    "description": "Enriched with real working examples from MAPP Segmentation API docs. Secrets are not stored; set apiPassword before running. Create/update examples use safe draft plans. Publish/delete are action/destructive calls and should be run deliberately."
  },
  "auth": {
    "type": "basic",
    "basic": [
      {
        "key": "username",
        "value": "{{apiUsername}}",
        "type": "string"
      },
      {
        "key": "password",
        "value": "{{apiPassword}}",
        "type": "string"
      }
    ]
  },
  "variable": [
    {
      "key": "baseUrl",
      "value": "https://cook.shortest-route.com/td_ims_sheilmeier/api/rest/v19"
    },
    {
      "key": "apiUsername",
      "value": "apiuser_test@sheilmeier.com"
    },
    {
      "key": "apiPassword",
      "value": "PASTE_PASSWORD_HERE"
    },
    {
      "key": "segmentationId",
      "value": "E9BB430E-4B9A-4DA4-A3A4-E0F546B84759"
    },
    {
      "key": "createdSegmentationId",
      "value": "DA7C94B7-6797-4F1B-97DD-9AF6D9F00872"
    },
    {
      "key": "termId",
      "value": "PASTE_PUBLISHED_SEGMENT_TERM_ID"
    }
  ],
  "item": [
    {
      "name": "segmentation/create",
      "request": {
        "method": "POST",
        "header": [
          {
            "key": "Accept",
            "value": "application/json"
          },
          {
            "key": "Content-Type",
            "value": "application/json"
          }
        ],
        "url": {
          "raw": "{{baseUrl}}/segmentation/create",
          "host": [
            "{{baseUrl}}"
          ],
          "path": [
            "segmentation",
            "create"
          ],
          "query": []
        },
        "description": "Creates a new draft segment plan. Body wrapper field json must contain the raw plan JSON as an escaped string. Test script stores response id in {{createdSegmentationId}}.",
        "body": {
          "mode": "raw",
          "raw": "{\n  \"json\": \"{\\\"name\\\": \\\"Postman KI Segment {{$timestamp}}\\\", \\\"description\\\": \\\"Created from Postman using the MAPP Segmentation API.\\\", \\\"timeZone\\\": {\\\"id\\\": \\\"Europe/Berlin\\\"}, \\\"nodes\\\": [{\\\"nodeType\\\": \\\"Group\\\", \\\"groupOperator\\\": \\\"AND\\\", \\\"name\\\": \\\"Postman Beispiel\\\", \\\"nodes\\\": [{\\\"nodeType\\\": \\\"Criterion\\\", \\\"selectorType\\\": \\\"MessageOpenedNew\\\", \\\"opened\\\": \\\"false\\\", \\\"occurrences\\\": {\\\"operator\\\": \\\"equals\\\", \\\"value\\\": \\\"0\\\"}}]}]}\"\n}",
          "options": {
            "raw": {
              "language": "json"
            }
          }
        }
      },
      "response": [
        {
          "name": "200 - created draft id (real sample)",
          "originalRequest": {
            "method": "POST",
            "header": [
              {
                "key": "Accept",
                "value": "application/json"
              },
              {
                "key": "Content-Type",
                "value": "application/json"
              }
            ],
            "url": {
              "raw": "{{baseUrl}}/segmentation/create",
              "host": [
                "{{baseUrl}}"
              ],
              "path": [
                "segmentation",
                "create"
              ],
              "query": []
            },
            "description": "Creates a new draft segment plan. Body wrapper field json must contain the raw plan JSON as an escaped string. Test script stores response id in {{createdSegmentationId}}.",
            "body": {
              "mode": "raw",
              "raw": "{\n  \"json\": \"{\\\"name\\\": \\\"Postman KI Segment {{$timestamp}}\\\", \\\"description\\\": \\\"Created from Postman using the MAPP Segmentation API.\\\", \\\"timeZone\\\": {\\\"id\\\": \\\"Europe/Berlin\\\"}, \\\"nodes\\\": [{\\\"nodeType\\\": \\\"Group\\\", \\\"groupOperator\\\": \\\"AND\\\", \\\"name\\\": \\\"Postman Beispiel\\\", \\\"nodes\\\": [{\\\"nodeType\\\": \\\"Criterion\\\", \\\"selectorType\\\": \\\"MessageOpenedNew\\\", \\\"opened\\\": \\\"false\\\", \\\"occurrences\\\": {\\\"operator\\\": \\\"equals\\\", \\\"value\\\": \\\"0\\\"}}]}]}\"\n}",
              "options": {
                "raw": {
                  "language": "json"
                }
              }
            }
          },
          "status": "OK",
          "code": 200,
          "_postman_previewlanguage": "json",
          "header": [
            {
              "key": "Content-Type",
              "value": "application/json"
            }
          ],
          "body": "{\n  \"id\": \"DA7C94B7-6797-4F1B-97DD-9AF6D9F00872\"\n}"
        }
      ],
      "event": [
        {
          "listen": "test",
          "script": {
            "type": "text/javascript",
            "exec": [
              "const data = pm.response.json();",
              "pm.test(\"MAPP Status 200\", () => pm.response.to.have.status(200));",
              "pm.test(\"created id returned\", () => pm.expect(data.id).to.be.a(\"string\"));",
              "if (data.id) pm.collectionVariables.set(\"createdSegmentationId\", data.id);"
            ]
          }
        }
      ]
    },
    {
      "name": "segmentation/delete",
      "request": {
        "method": "DELETE",
        "header": [
          {
            "key": "Accept",
            "value": "application/json"
          }
        ],
        "url": {
          "raw": "{{baseUrl}}/segmentation/delete?id={{createdSegmentationId}}",
          "host": [
            "{{baseUrl}}"
          ],
          "path": [
            "segmentation",
            "delete"
          ],
          "query": [
            {
              "key": "id",
              "value": "{{createdSegmentationId}}"
            }
          ]
        },
        "description": "Deletes a segment plan by query parameter id. Destructive: run only against a disposable draft created by segmentation/create."
      },
      "response": [
        {
          "name": "200 - expected after deleting disposable draft",
          "originalRequest": {
            "method": "DELETE",
            "header": [
              {
                "key": "Accept",
                "value": "application/json"
              }
            ],
            "url": {
              "raw": "{{baseUrl}}/segmentation/delete?id={{createdSegmentationId}}",
              "host": [
                "{{baseUrl}}"
              ],
              "path": [
                "segmentation",
                "delete"
              ],
              "query": [
                {
                  "key": "id",
                  "value": "{{createdSegmentationId}}"
                }
              ]
            },
            "description": "Deletes a segment plan by query parameter id. Destructive: run only against a disposable draft created by segmentation/create."
          },
          "status": "OK",
          "code": 200,
          "_postman_previewlanguage": "json",
          "header": [
            {
              "key": "Content-Type",
              "value": "application/json"
            }
          ],
          "body": "{\n  \"message\": \"Plan deleted.\"\n}"
        }
      ],
      "event": [
        {
          "listen": "test",
          "script": {
            "type": "text/javascript",
            "exec": [
              "pm.test(\"MAPP Status 200\", () => pm.response.to.have.status(200));"
            ]
          }
        }
      ]
    },
    {
      "name": "segmentation/find",
      "request": {
        "method": "POST",
        "header": [
          {
            "key": "Accept",
            "value": "application/json"
          },
          {
            "key": "Content-Type",
            "value": "application/json"
          }
        ],
        "url": {
          "raw": "{{baseUrl}}/segmentation/find",
          "host": [
            "{{baseUrl}}"
          ],
          "path": [
            "segmentation",
            "find"
          ],
          "query": []
        },
        "description": "Finds segment plans. Supports page, size, sort, name, status, labels, id, selectionTermId, createdByName, createdBefore, updatedBefore, publishedBefore.",
        "body": {
          "mode": "raw",
          "raw": "{\n  \"page\": 0,\n  \"size\": 3,\n  \"sort\": [\n    \"createdOn,desc\"\n  ],\n  \"name\": \"Demo\"\n}",
          "options": {
            "raw": {
              "language": "json"
            }
          }
        }
      },
      "response": [
        {
          "name": "200 - find name Demo (real sample)",
          "originalRequest": {
            "method": "POST",
            "header": [
              {
                "key": "Accept",
                "value": "application/json"
              },
              {
                "key": "Content-Type",
                "value": "application/json"
              }
            ],
            "url": {
              "raw": "{{baseUrl}}/segmentation/find",
              "host": [
                "{{baseUrl}}"
              ],
              "path": [
                "segmentation",
                "find"
              ],
              "query": []
            },
            "description": "Finds segment plans. Supports page, size, sort, name, status, labels, id, selectionTermId, createdByName, createdBefore, updatedBefore, publishedBefore.",
            "body": {
              "mode": "raw",
              "raw": "{\n  \"page\": 0,\n  \"size\": 3,\n  \"sort\": [\n    \"createdOn,desc\"\n  ],\n  \"name\": \"Demo\"\n}",
              "options": {
                "raw": {
                  "language": "json"
                }
              }
            }
          },
          "status": "OK",
          "code": 200,
          "_postman_previewlanguage": "json",
          "header": [
            {
              "key": "Content-Type",
              "value": "application/json"
            }
          ],
          "body": "{\n  \"segmentationSummary\": [\n    {\n      \"id\": \"E9BB430E-4B9A-4DA4-A3A4-E0F546B84759\",\n      \"name\": \"Postman Demo KI Segment 20260917091224\",\n      \"status\": \"draft\",\n      \"timeZoneId\": \"Europe/Berlin\",\n      \"termId\": null,\n      \"labels\": [],\n      \"createdBy\": {\n        \"id\": \"21591310041\",\n        \"name\": \"USER, API\",\n        \"firstName\": \"API\",\n        \"lastName\": \"USER\",\n        \"email\": \"apiuser_test@sheilmeier.com\"\n      },\n      \"createdOn\": \"2026-09-17T09:12:25Z\",\n      \"publishedBy\": null,\n      \"publishedOn\": null,\n      \"updatedBy\": {\n        \"id\": \"21591310041\",\n        \"name\": \"USER, API\",\n        \"firstName\": \"API\",\n        \"lastName\": \"USER\",\n        \"email\": \"apiuser_test@sheilmeier.com\"\n      },\n      \"updatedOn\": \"2026-09-17T09:12:25Z\",\n      \"overviewCount\": null,\n      \"overviewCountStatus\": null,\n      \"overviewCountOn\": null\n    },\n    {\n      \"id\": \"4E137D11-BDAD-4BAF-9307-1B02B81155AE\",\n      \"name\": \"Demo Nie geöffnet nie geklickt 20260916163537\",\n      \"status\": \"draft\",\n      \"timeZoneId\": \"Europe/Berlin\",\n      \"termId\": null,\n      \"labels\": [],\n      \"createdBy\": {\n        \"id\": \"21591310041\",\n        \"name\": \"USER, API\",\n        \"firstName\": \"API\",\n        \"lastName\": \"USER\",\n        \"email\": \"apiuser_test@sheilmeier.com\"\n      },\n      \"createdOn\": \"2026-09-16T16:35:37Z\",\n      \"publishedBy\": null,\n      \"publishedOn\": null,\n      \"updatedBy\": {\n        \"id\": \"21591310041\",\n        \"name\": \"USER, API\",\n        \"firstName\": \"API\",\n        \"lastName\": \"USER\",\n        \"email\": \"apiuser_test@sheilmeier.com\"\n      },\n      \"updatedOn\": \"2026-09-16T16:35:37Z\",\n      \"overviewCount\": null,\n      \"overviewCountStatus\": null,\n      \"overviewCountOn\": null\n    },\n    {\n      \"id\": \"209CC87F-06C9-4E85-94F4-4EB57088FBC2\",\n      \"name\": \"API Demo No Click Open 162219\",\n      \"status\": \"draft\",\n      \"timeZoneId\": \"Europe/Berlin\",\n      \"termId\": null,\n      \"labels\": [],\n      \"createdBy\": {\n        \"id\": \"21591310041\",\n        \"name\": \"USER, API\",\n        \"firstName\": \"API\",\n        \"lastName\": \"USER\",\n        \"email\": \"apiuser_test@sheilmeier.com\"\n      },\n      \"createdOn\": \"2026-09-16T16:22:19Z\",\n      \"publishedBy\": null,\n      \"publishedOn\": null,\n      \"updatedBy\": {\n        \"id\": \"21591310041\",\n        \"name\": \"USER, API\",\n        \"firstName\": \"API\",\n        \"lastName\": \"USER\",\n        \"email\": \"apiuser_test@sheilmeier.com\"\n      },\n      \"updatedOn\": \"2026-09-16T16:22:19Z\",\n      \"overviewCount\": null,\n      \"overviewCountStatus\": null,\n      \"overviewCountOn\": null\n    }\n  ],\n  \"number\": 0,\n  \"size\": 3,\n  \"totalElements\": 12,\n  \"totalPages\": 4\n}"
        }
      ],
      "event": [
        {
          "listen": "test",
          "script": {
            "type": "text/javascript",
            "exec": [
              "pm.test(\"MAPP Status 200\", () => pm.response.to.have.status(200));"
            ]
          }
        }
      ]
    },
    {
      "name": "segmentation/get",
      "request": {
        "method": "GET",
        "header": [
          {
            "key": "Accept",
            "value": "application/json"
          }
        ],
        "url": {
          "raw": "{{baseUrl}}/segmentation/get?id={{segmentationId}}",
          "host": [
            "{{baseUrl}}"
          ],
          "path": [
            "segmentation",
            "get"
          ],
          "query": [
            {
              "key": "id",
              "value": "{{segmentationId}}"
            }
          ]
        },
        "description": "Gets the full segment plan by query parameter id."
      },
      "response": [
        {
          "name": "200 - get existing plan (real sample)",
          "originalRequest": {
            "method": "GET",
            "header": [
              {
                "key": "Accept",
                "value": "application/json"
              }
            ],
            "url": {
              "raw": "{{baseUrl}}/segmentation/get?id={{segmentationId}}",
              "host": [
                "{{baseUrl}}"
              ],
              "path": [
                "segmentation",
                "get"
              ],
              "query": [
                {
                  "key": "id",
                  "value": "{{segmentationId}}"
                }
              ]
            },
            "description": "Gets the full segment plan by query parameter id."
          },
          "status": "OK",
          "code": 200,
          "_postman_previewlanguage": "json",
          "header": [
            {
              "key": "Content-Type",
              "value": "application/json"
            }
          ],
          "body": "{\n  \"_links\": {\n    \"copy\": {\n      \"href\": \"/services/selectionbuilder/api/plan/E9BB430E-4B9A-4DA4-A3A4-E0F546B84759\"\n    },\n    \"delete\": {\n      \"href\": \"/services/selectionbuilder/api/plan/E9BB430E-4B9A-4DA4-A3A4-E0F546B84759\"\n    },\n    \"edit\": {\n      \"href\": \"/services/selectionbuilder/api/plan/E9BB430E-4B9A-4DA4-A3A4-E0F546B84759\"\n    },\n    \"publish\": {\n      \"href\": \"/services/selectionbuilder/api/plan/E9BB430E-4B9A-4DA4-A3A4-E0F546B84759/publish\"\n    },\n    \"self\": {\n      \"href\": \"/services/selectionbuilder/api/plan/E9BB430E-4B9A-4DA4-A3A4-E0F546B84759\"\n    },\n    \"view\": {\n      \"href\": \"/services/selectionbuilder/api/plan/E9BB430E-4B9A-4DA4-A3A4-E0F546B84759\"\n    }\n  },\n  \"createdBy\": {\n    \"email\": \"apiuser_test@sheilmeier.com\",\n    \"firstName\": \"API\",\n    \"id\": \"21591310041\",\n    \"lastName\": \"USER\",\n    \"name\": \"USER, API\"\n  },\n  \"createdOn\": \"2026-09-17T09:12:25.000Z\",\n  \"description\": \"Updated by Postman collection example.\",\n  \"id\": \"E9BB430E-4B9A-4DA4-A3A4-E0F546B84759\",\n  \"labels\": [],\n  \"name\": \"Postman Demo KI Segment 20260917091224\",\n  \"nodes\": \"[omitted in Postman example for readability]\",\n  \"republished\": false,\n  \"status\": \"draft\",\n  \"timeZone\": {\n    \"id\": \"Europe/Berlin\"\n  },\n  \"updatedBy\": {\n    \"email\": \"apiuser_test@sheilmeier.com\",\n    \"firstName\": \"API\",\n    \"id\": \"21591310041\",\n    \"lastName\": \"USER\",\n    \"name\": \"USER, API\"\n  },\n  \"updatedOn\": \"2026-09-17T09:12:25.000Z\"\n}"
        }
      ],
      "event": [
        {
          "listen": "test",
          "script": {
            "type": "text/javascript",
            "exec": [
              "pm.test(\"MAPP Status 200\", () => pm.response.to.have.status(200));"
            ]
          }
        }
      ]
    },
    {
      "name": "segmentation/getCount",
      "request": {
        "method": "GET",
        "header": [
          {
            "key": "Accept",
            "value": "application/json"
          }
        ],
        "url": {
          "raw": "{{baseUrl}}/segmentation/getCount?termId={{termId}}",
          "host": [
            "{{baseUrl}}"
          ],
          "path": [
            "segmentation",
            "getCount"
          ],
          "query": [
            {
              "key": "termId",
              "value": "{{termId}}"
            }
          ]
        },
        "description": "Gets count for a published segment term. Set {{termId}} first; termId is not the draft plan id."
      },
      "response": [
        {
          "name": "200 - expected count result shape",
          "originalRequest": {
            "method": "GET",
            "header": [
              {
                "key": "Accept",
                "value": "application/json"
              }
            ],
            "url": {
              "raw": "{{baseUrl}}/segmentation/getCount?termId={{termId}}",
              "host": [
                "{{baseUrl}}"
              ],
              "path": [
                "segmentation",
                "getCount"
              ],
              "query": [
                {
                  "key": "termId",
                  "value": "{{termId}}"
                }
              ]
            },
            "description": "Gets count for a published segment term. Set {{termId}} first; termId is not the draft plan id."
          },
          "status": "OK",
          "code": 200,
          "_postman_previewlanguage": "json",
          "header": [
            {
              "key": "Content-Type",
              "value": "application/json"
            }
          ],
          "body": "{\n  \"termId\": \"{{termId}}\",\n  \"count\": 1234,\n  \"updatedOn\": \"2026-09-17T00:00:00Z\"\n}"
        }
      ],
      "event": [
        {
          "listen": "test",
          "script": {
            "type": "text/javascript",
            "exec": [
              "pm.test(\"MAPP Status 200\", () => pm.response.to.have.status(200));"
            ]
          }
        }
      ]
    },
    {
      "name": "segmentation/preview",
      "request": {
        "method": "GET",
        "header": [
          {
            "key": "Accept",
            "value": "application/json"
          }
        ],
        "url": {
          "raw": "{{baseUrl}}/segmentation/preview?id={{segmentationId}}",
          "host": [
            "{{baseUrl}}"
          ],
          "path": [
            "segmentation",
            "preview"
          ],
          "query": [
            {
              "key": "id",
              "value": "{{segmentationId}}"
            }
          ]
        },
        "description": "Gets a reduced preview of a segment plan by query parameter id."
      },
      "response": [
        {
          "name": "200 - preview existing plan (real sample)",
          "originalRequest": {
            "method": "GET",
            "header": [
              {
                "key": "Accept",
                "value": "application/json"
              }
            ],
            "url": {
              "raw": "{{baseUrl}}/segmentation/preview?id={{segmentationId}}",
              "host": [
                "{{baseUrl}}"
              ],
              "path": [
                "segmentation",
                "preview"
              ],
              "query": [
                {
                  "key": "id",
                  "value": "{{segmentationId}}"
                }
              ]
            },
            "description": "Gets a reduced preview of a segment plan by query parameter id."
          },
          "status": "OK",
          "code": 200,
          "_postman_previewlanguage": "json",
          "header": [
            {
              "key": "Content-Type",
              "value": "application/json"
            }
          ],
          "body": "{\n  \"id\": \"E9BB430E-4B9A-4DA4-A3A4-E0F546B84759\",\n  \"name\": \"Postman Demo KI Segment 20260917091224\",\n  \"nodes\": \"[omitted in Postman example for readability]\",\n  \"status\": \"draft\",\n  \"timeZoneId\": \"Europe/Berlin\"\n}"
        }
      ],
      "event": [
        {
          "listen": "test",
          "script": {
            "type": "text/javascript",
            "exec": [
              "pm.test(\"MAPP Status 200\", () => pm.response.to.have.status(200));"
            ]
          }
        }
      ]
    },
    {
      "name": "segmentation/publish",
      "request": {
        "method": "POST",
        "header": [
          {
            "key": "Accept",
            "value": "application/json"
          }
        ],
        "url": {
          "raw": "{{baseUrl}}/segmentation/publish?id={{createdSegmentationId}}&isBeta=false&fastCountMode=off",
          "host": [
            "{{baseUrl}}"
          ],
          "path": [
            "segmentation",
            "publish"
          ],
          "query": [
            {
              "key": "id",
              "value": "{{createdSegmentationId}}"
            },
            {
              "key": "isBeta",
              "value": "false"
            },
            {
              "key": "fastCountMode",
              "value": "off"
            }
          ]
        },
        "description": "Publishes a saved segment plan. Action call: run deliberately. Optional query parameters: isBeta, fastCountMode."
      },
      "response": [
        {
          "name": "200 - expected published metadata shape",
          "originalRequest": {
            "method": "POST",
            "header": [
              {
                "key": "Accept",
                "value": "application/json"
              }
            ],
            "url": {
              "raw": "{{baseUrl}}/segmentation/publish?id={{createdSegmentationId}}&isBeta=false&fastCountMode=off",
              "host": [
                "{{baseUrl}}"
              ],
              "path": [
                "segmentation",
                "publish"
              ],
              "query": [
                {
                  "key": "id",
                  "value": "{{createdSegmentationId}}"
                },
                {
                  "key": "isBeta",
                  "value": "false"
                },
                {
                  "key": "fastCountMode",
                  "value": "off"
                }
              ]
            },
            "description": "Publishes a saved segment plan. Action call: run deliberately. Optional query parameters: isBeta, fastCountMode."
          },
          "status": "OK",
          "code": 200,
          "_postman_previewlanguage": "json",
          "header": [
            {
              "key": "Content-Type",
              "value": "application/json"
            }
          ],
          "body": "{\n  \"id\": \"{{createdSegmentationId}}\",\n  \"name\": \"Postman KI Segment example\",\n  \"status\": \"published\",\n  \"createdOn\": \"2026-09-17T00:00:00Z\",\n  \"updatedOn\": \"2026-09-17T00:00:00Z\",\n  \"publishedOn\": \"2026-09-17T00:00:00Z\",\n  \"termId\": \"<returned published segment term id>\"\n}"
        }
      ],
      "event": [
        {
          "listen": "test",
          "script": {
            "type": "text/javascript",
            "exec": [
              "pm.test(\"MAPP Status 200\", () => pm.response.to.have.status(200));"
            ]
          }
        }
      ]
    },
    {
      "name": "segmentation/schema",
      "request": {
        "method": "GET",
        "header": [
          {
            "key": "Accept",
            "value": "application/json"
          }
        ],
        "url": {
          "raw": "{{baseUrl}}/segmentation/schema",
          "host": [
            "{{baseUrl}}"
          ],
          "path": [
            "segmentation",
            "schema"
          ],
          "query": []
        },
        "description": "Returns the JSON schema used to validate/create/update segment plans."
      },
      "response": [
        {
          "name": "200 - schema (compact real sample)",
          "originalRequest": {
            "method": "GET",
            "header": [
              {
                "key": "Accept",
                "value": "application/json"
              }
            ],
            "url": {
              "raw": "{{baseUrl}}/segmentation/schema",
              "host": [
                "{{baseUrl}}"
              ],
              "path": [
                "segmentation",
                "schema"
              ],
              "query": []
            },
            "description": "Returns the JSON schema used to validate/create/update segment plans."
          },
          "status": "OK",
          "code": 200,
          "_postman_previewlanguage": "json",
          "header": [
            {
              "key": "Content-Type",
              "value": "application/json"
            }
          ],
          "body": "{\n  \"$schema\": \"https://json-schema.org/draft/2020-12/schema\",\n  \"$id\": \"https://mapp.com/schemas/selection-builder/selection-plan.schema.json\",\n  \"title\": \"Mapp Selection Builder — Selection Plan\",\n  \"description\": \"JSON contract for creating/updating a Selection Plan. A Plan is a tree of nodes. The root is one or more `Group` nodes that combine child nodes with `AND`/`OR`. Leaves are `Criterion` nodes, each carrying a `selectorType` that selects which selector schema applies. Iteration 1 covers 10 selectors: GroupMembership, BehaviouralAttribute, ContactAttribute, String, Boolean, Number, Date, StringEnumerated, NumberEnumerated, DateEnumerated. Additional selectors will be added in later iterations.\\n\\nIMPORTANT serialization quirks the AI agent MUST respect:\\n  - STRING booleans (Jackson ToStringSerializer): `negated`, `caseSensitive`, `present`, `ignoreYear`. Use \\\"true\\\" / \\\"false\\\" — NOT JSON booleans.\\n  - REAL JSON booleans: `includeEmpty`, `dateOnly`, `fromIgnoreTime`, `toIgnoreTime` (last two also accept strings).\\n  - Numeric values in `Number` / `NumberEnumerated` are STRINGS (e.g. \\\"1\\\", \\\"42.5\\\"), not JSON numbers. Server converts to string at construction.\\n  - In `BehaviouralAttribute`, `value` is also a STRING regardless of the underlying `entityPropertyType` (Double/Long/Date/Boolean).\\n  - Date values in `Date` selectors use a `timeRange` object (not a plain `value`). `DateEnumerated` uses `values[]` of ISO date strings.\\n  - STANDARD profile attributes resolve OFFLINE via the top-level `x-standardAttributes` registry — it lists each built-in attribute's `selectorType`, `attributeType` (always STANDARD), enum value codes, and `dateOnly`. No metadata lookup is needed for these. Example: Gender is `NumberEnumerated` with codes \\\"0\\\"=Unset, \\\"1\\\"=Male, \\\"2\\\"=Female, \\\"3\\\"=Undisclosed; Title is `NumberEnumerated` \\\"1\\\"=Mr, \\\"2\\\"=Mrs, \\\"-1\\\"=Unset. Do NOT use String/StringEnumerated for these. CUSTOM (non-standard) attributes are not in the registry — their selectorType/codes must be supplied by the caller or resolved via attribute metadata.\\n  - The SB UI ALWAYS emits the canonical full shape per selector. In particular `GroupMembership` always emits `timeRange` (defaulting to relativeTimeRange anytimeBefore..onRun), `dateType`, `groupName`, `includeEmpty`. Match the canonical shape to maximize compatibility.\\n  - Polymorphism: `nodeType` (Group | Criterion); for Criterion add `selectorType`. `TimeRange.type` ∈ {relativeTimeRange, specificTimeRange, relativeDate, specificDate}. `Which.filter` ∈ {Any, Specific, Category}.\\n  - Inherited from `ObjectWithAttributes`: every node accepts arbitrary additional properties via @JsonAnySetter — schema uses `additionalProperties: true` to mirror this.\",\n  \"type\": \"object\",\n  \"$ref\": \"#/$defs/PlanCreate\",\n  \"x-standardAttributes\": \"[omitted in Postman example for readability]\",\n  \"$defs\": \"[omitted in Postman example for readability]\"\n}"
        }
      ],
      "event": [
        {
          "listen": "test",
          "script": {
            "type": "text/javascript",
            "exec": [
              "pm.test(\"MAPP Status 200\", () => pm.response.to.have.status(200));"
            ]
          }
        }
      ]
    },
    {
      "name": "segmentation/triggerCount",
      "request": {
        "method": "POST",
        "header": [
          {
            "key": "Accept",
            "value": "application/json"
          }
        ],
        "url": {
          "raw": "{{baseUrl}}/segmentation/triggerCount?termId={{termId}}",
          "host": [
            "{{baseUrl}}"
          ],
          "path": [
            "segmentation",
            "triggerCount"
          ],
          "query": [
            {
              "key": "termId",
              "value": "{{termId}}"
            }
          ]
        },
        "description": "Starts a count calculation for a published segment term. Set {{termId}} first; termId is not the draft plan id."
      },
      "response": [
        {
          "name": "200 - expected trigger result shape",
          "originalRequest": {
            "method": "POST",
            "header": [
              {
                "key": "Accept",
                "value": "application/json"
              }
            ],
            "url": {
              "raw": "{{baseUrl}}/segmentation/triggerCount?termId={{termId}}",
              "host": [
                "{{baseUrl}}"
              ],
              "path": [
                "segmentation",
                "triggerCount"
              ],
              "query": [
                {
                  "key": "termId",
                  "value": "{{termId}}"
                }
              ]
            },
            "description": "Starts a count calculation for a published segment term. Set {{termId}} first; termId is not the draft plan id."
          },
          "status": "OK",
          "code": 200,
          "_postman_previewlanguage": "json",
          "header": [
            {
              "key": "Content-Type",
              "value": "application/json"
            }
          ],
          "body": "{\n  \"termId\": \"{{termId}}\",\n  \"status\": \"triggered\"\n}"
        }
      ],
      "event": [
        {
          "listen": "test",
          "script": {
            "type": "text/javascript",
            "exec": [
              "pm.test(\"MAPP Status 200\", () => pm.response.to.have.status(200));"
            ]
          }
        }
      ]
    },
    {
      "name": "segmentation/update",
      "request": {
        "method": "PUT",
        "header": [
          {
            "key": "Accept",
            "value": "application/json"
          },
          {
            "key": "Content-Type",
            "value": "application/json"
          }
        ],
        "url": {
          "raw": "{{baseUrl}}/segmentation/update?id={{createdSegmentationId}}",
          "host": [
            "{{baseUrl}}"
          ],
          "path": [
            "segmentation",
            "update"
          ],
          "query": [
            {
              "key": "id",
              "value": "{{createdSegmentationId}}"
            }
          ]
        },
        "description": "Overwrites the full segment plan. Correct flow: GET current plan first, modify it, then PUT full plan JSON wrapper. Query id must match body id.",
        "body": {
          "mode": "raw",
          "raw": "{\n  \"json\": \"{\\\"id\\\": \\\"{{createdSegmentationId}}\\\", \\\"name\\\": \\\"Postman KI Segment {{$timestamp}} updated\\\", \\\"description\\\": \\\"Updated through Postman. Update overwrites the whole plan, so normally GET first, modify, then send full plan.\\\", \\\"timeZone\\\": {\\\"id\\\": \\\"Europe/Berlin\\\"}, \\\"nodes\\\": [{\\\"nodeType\\\": \\\"Group\\\", \\\"groupOperator\\\": \\\"AND\\\", \\\"name\\\": \\\"Postman Beispiel\\\", \\\"nodes\\\": [{\\\"nodeType\\\": \\\"Criterion\\\", \\\"selectorType\\\": \\\"MessageOpenedNew\\\", \\\"opened\\\": \\\"false\\\", \\\"occurrences\\\": {\\\"operator\\\": \\\"equals\\\", \\\"value\\\": \\\"0\\\"}}]}]}\"\n}",
          "options": {
            "raw": {
              "language": "json"
            }
          }
        }
      },
      "response": [
        {
          "name": "200 - updated draft plan (real sample)",
          "originalRequest": {
            "method": "PUT",
            "header": [
              {
                "key": "Accept",
                "value": "application/json"
              },
              {
                "key": "Content-Type",
                "value": "application/json"
              }
            ],
            "url": {
              "raw": "{{baseUrl}}/segmentation/update?id={{createdSegmentationId}}",
              "host": [
                "{{baseUrl}}"
              ],
              "path": [
                "segmentation",
                "update"
              ],
              "query": [
                {
                  "key": "id",
                  "value": "{{createdSegmentationId}}"
                }
              ]
            },
            "description": "Overwrites the full segment plan. Correct flow: GET current plan first, modify it, then PUT full plan JSON wrapper. Query id must match body id.",
            "body": {
              "mode": "raw",
              "raw": "{\n  \"json\": \"{\\\"id\\\": \\\"{{createdSegmentationId}}\\\", \\\"name\\\": \\\"Postman KI Segment {{$timestamp}} updated\\\", \\\"description\\\": \\\"Updated through Postman. Update overwrites the whole plan, so normally GET first, modify, then send full plan.\\\", \\\"timeZone\\\": {\\\"id\\\": \\\"Europe/Berlin\\\"}, \\\"nodes\\\": [{\\\"nodeType\\\": \\\"Group\\\", \\\"groupOperator\\\": \\\"AND\\\", \\\"name\\\": \\\"Postman Beispiel\\\", \\\"nodes\\\": [{\\\"nodeType\\\": \\\"Criterion\\\", \\\"selectorType\\\": \\\"MessageOpenedNew\\\", \\\"opened\\\": \\\"false\\\", \\\"occurrences\\\": {\\\"operator\\\": \\\"equals\\\", \\\"value\\\": \\\"0\\\"}}]}]}\"\n}",
              "options": {
                "raw": {
                  "language": "json"
                }
              }
            }
          },
          "status": "OK",
          "code": 200,
          "_postman_previewlanguage": "json",
          "header": [
            {
              "key": "Content-Type",
              "value": "application/json"
            }
          ],
          "body": "{\n  \"_links\": {\n    \"copy\": {\n      \"href\": \"/services/selectionbuilder/api/plan/DA7C94B7-6797-4F1B-97DD-9AF6D9F00872\"\n    },\n    \"delete\": {\n      \"href\": \"/services/selectionbuilder/api/plan/DA7C94B7-6797-4F1B-97DD-9AF6D9F00872\"\n    },\n    \"edit\": {\n      \"href\": \"/services/selectionbuilder/api/plan/DA7C94B7-6797-4F1B-97DD-9AF6D9F00872\"\n    },\n    \"publish\": {\n      \"href\": \"/services/selectionbuilder/api/plan/DA7C94B7-6797-4F1B-97DD-9AF6D9F00872/publish\"\n    },\n    \"self\": {\n      \"href\": \"/services/selectionbuilder/api/plan/DA7C94B7-6797-4F1B-97DD-9AF6D9F00872\"\n    },\n    \"view\": {\n      \"href\": \"/services/selectionbuilder/api/plan/DA7C94B7-6797-4F1B-97DD-9AF6D9F00872\"\n    }\n  },\n  \"createdBy\": {\n    \"email\": \"apiuser_test@sheilmeier.com\",\n    \"firstName\": \"API\",\n    \"id\": \"21591310041\",\n    \"lastName\": \"USER\",\n    \"name\": \"USER, API\"\n  },\n  \"createdOn\": \"2026-09-17T09:13:52.000Z\",\n  \"description\": \"Updated by the enriched Postman collection example.\",\n  \"id\": \"DA7C94B7-6797-4F1B-97DD-9AF6D9F00872\",\n  \"labels\": [],\n  \"name\": \"Postman Demo KI Segment 20260917091351\",\n  \"nodes\": \"[omitted in Postman example for readability]\",\n  \"republished\": false,\n  \"status\": \"draft\",\n  \"timeZone\": {\n    \"id\": \"Europe/Berlin\"\n  },\n  \"updatedBy\": {\n    \"email\": \"apiuser_test@sheilmeier.com\",\n    \"firstName\": \"API\",\n    \"id\": \"21591310041\",\n    \"lastName\": \"USER\",\n    \"name\": \"USER, API\"\n  },\n  \"updatedOn\": \"2026-09-17T09:13:52.000Z\"\n}"
        }
      ],
      "event": [
        {
          "listen": "test",
          "script": {
            "type": "text/javascript",
            "exec": [
              "pm.test(\"MAPP Status 200\", () => pm.response.to.have.status(200));"
            ]
          }
        }
      ]
    }
  ]
}