function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
Andy Kallio 13Andy Kallio 13 

how to handle deletes with platform events

Hello friends. A very beginner question on Platform Events. My org is using Process Builder to send Platform Events that are being consumed by another system. 

The developers of that system are now asking if we can include deletes. Process Builder cannot do that. My first idea is to write a before trigger on the object that would create a new platform event of the same type but with new a field that would indicate the event as 'DELETE'.  However, I don't know if using the Streaming API is the better way to go because I have no experience with that. 

 

So, just looking for a little advice from someone that has that experience. Thanks!

Saranyan V NarayananSaranyan V Narayanan
you can add Change data capture which will publish delete and undelete in another channel.