[Segment_v2.0]: Returns 500 when creating a new segment without Query property

Fixed in

EPiServer.Profiles.Client 1.24.0

(Or a related package)

Created

Nov 10, 2020

Updated

Mar 05, 2021

State

Closed, Fixed and tested


Description

Steps to reproduce:

  1. Create a new segment with event/profile filter definition without Query property in Filters:
{
  "Scope": "default",
  "SegmentManager": "Franklin Cummings",
  "AvailableForPersonalization": false,
  "Archived": false,
  "FavoredBy": null,
  "Name": "Testing Segment",
  "Description": "Testing Segment",
  "Filters": {
    "Items": [
      {
        "Type": "Events",
        "Parameters": {   
          "value": "home"
        }
      }
    ]
  }
}

Expected result:

Returns 400 Bad Request with Validation Error.

Actual result:

Returns 500 Internal Server Error.