Hey there abenton! You find a solution? I'm thinking 2 options... both of which are backend/data engineering heavy:
1) Use your code to make an API call that sends ONLY to your segment - maybe resource intense
2) Cloud Data ingestion - Delay prone
1 - We have several messages that are "triggered from the code". Our engineering team builds in logic that will make the API call triggering a message from our backend. We make these calls real time for certain transaction messages, or based on different algo. type criteria (e.g. 14 days after last event, to this audience). I would think with engineering, you could set it up like this. - IF event occurs - make API call... -
2 - Use CDI (Cloud Data ingestion) to create/update a custom attribute which is the trigger for the message - you set entry criteria as ACTION - When custom attribute is any new value - CDI_attribute. We use a CDI sync from Snowflake that creates/updates an engagement attributes which let's us know which users are active.
CAUTION - I don't know if this will work realtime. We only update at 9am. If you need an immediate trigger - this probably won't be so precise. all depends on your infrastructure.
3) I am looking into how you might use a Webhook to trigger the subsequent canvas/send - but doesn't seem promising. I think at a minimum you'd need to create a user that represents your custom event and then have some sort of forloop that cycles through each userID in the segment (triggering the canvas for each)... I may follow up... this is probably not gonna work.
Happy to clarify! sorry for the lengthy response 😅
-Joseph