Hi ,
I would like to implement a mechanism of audit for input changes , meaning when a user edits an input (or any component) , I would like to get notified (event?) and send it over to my service (using retool http client)
Is there any built-in mechanism to do so ?
if not, what is the best way to achieve that ?
Hey @Niv! Your not alone, check out this post here.
There are a few ways you could approach this, but my suggestion would be to track the data itself rather than the action of changing a component. You can log those changes when data is submitted back, typically through an API.
Retool or PostgreSQL doesn’t have this built-in by default, but in the past, I’ve handled this by writing a function that runs during inserts/updates, logging the changes and keeping track of the previous and new values to create an audit log.
For a more robust solution, you could consider using a temporal database—this way, you’d have a foolproof audit trail!