I’m attempting to send a ‘contact updated’ webhook event, but only when a specific field is updated in the contact
OR
I just need a way to check to see which specific field has been updated when I receive the contact data at the endpoint.
My use case is that if a specific boolean field is set from ‘false’ to ‘true’, I want to do some stuff at the receiving end. Right now, any time any field is updated, the data is sent to the endpoint, so I’m not able to tell if this field has specifically been updated.
When I’m subscribing to the LEAD_POST_SAVE event, do I get the lead before and after the save? as I want to check if a specific field changed, it’s not enough just to check its value.
I have a boolean field, and I want to know when that boolean changed from false to true (for example, if it is true and remain true, I don’t care about this case).
LEAD_POST_SAVE is after contact has been persisted. LEAD_PRE_SAVE is before.
When you are hooked to LEAD_POST_SAVE you can get updated lead and you can see what has been changed by calling getChanges() method I think its a member of Lead class.
From those changes and current state of $lead you should be able to achieve what you want.
Has this been resolved? I sort of have the same question: Is it possible to fire a webhook from a campaign with the value of a certain contact’s field? It would be great if there was an automatic drop-down list that I could choose the available field types from inside the ‘send a webhook’ function. Thank you.