Currently segment rule definitions can only be run against Identity traits. Users often expect the rules to operate on Identity ids as well.
We should introduce a reserved trait name, suggest id, which evaluates to the Identity unique identifier when the rules are being evaluated.
Technical Implementation
We can add the id transiently to the segment list with a special name e.g. id or similar before processing the rules.
Issues
It would mean that SDKs could not set a trait with id which would be a breaking change. What would happen to existing traits that have an ID set? Suggest that if they do, this overrides the coercion of the id.
Currently segment rule definitions can only be run against Identity traits. Users often expect the rules to operate on Identity
idsas well.We should introduce a reserved trait name, suggest
id, which evaluates to the Identity unique identifier when the rules are being evaluated.Technical Implementation
We can add the
idtransiently to the segment list with a special name e.g.idor similar before processing the rules.Issues
It would mean that SDKs could not set a trait with
idwhich would be a breaking change. What would happen to existing traits that have an ID set? Suggest that if they do, this overrides the coercion of the id.