var lookup = {},
    result = [];

JSON.parse(value).forEach(function (event) {
    var filter = event.EventCategories+event.SourceIdentifier+event.SourceType;
    if (!(lookup[filter])) {
        lookup[filter] = 1;
   result.push({
  '{#EVENT_CATEGORY}': event.EventCategories,
  '{#EVENT_SOURCE_ID}': event.SourceIdentifier,
  '{#EVENT_SOURCE_TYPE}': event.SourceType
    });
    }
})

return JSON.stringify(result);