Hello RevOps community,
I am trying to create a workflow that sends email notifications to customers that have a failed payment on our platform.
We are currently receiving the notice in Hubspot through a custom integration with our application in the Company activity feed (See below screenshot)
Stripe Sync Failure Notice
What we would like to do is create a workflow trigger that enrolls companies when the âproduction airbrake appâ posts an activity for âstripe plan syncing failedâ notice on the company activity log.
Can I do this out of the box within Hubspot or do I require custom developer assistance?
Hello @nthatcher-airbr!
You can create a workflow based on the associated activity in your screenshot (as Iâll describe below) - however itâs not ideal, since re-enrollment will not function based on activity property values. At the time of this writing, you cannot make an activity-based workflow, so all workflows that use activities will inherently be cross-object.
What would work better is if some property was updated in HubSpot on payment failure instead of only an activity being associated to the record⌠so I strongly recommend first going through the property history to see if any property exists denoting a failed payment.
If such a property exists, it would be a much better solution, as it would allow for re-enrollment in your notification workflow, allowing multiple failed payment notifications over time.
Also, just as an FYI: since the activities coming from the app are working correctly - it should be a pretty trivial task for any dev to flip a property in the same function that posts a payment failed activity to HubSpot. Not ideal per your request - but if you go that route, make a enumeration property called âFailed Paymentâ with values âYesâ and âPreviously Failedâ. Iâll include instructions for this alternate workflow below as well.
Creating a Workflow Based on Associated Activities:
Before we start, you should know that triggering workflows based on activities is tricky. This is because âactivitiesâ are housed in the âActivityâ object, and technically a record of their own. The activity is then associated to a standard company/contact/deal record. (More info on HubSpot Activities)
So, when you trigger a workflow based on activities, it will work - but re-enrollment will not work for activity properties. You could re-enroll based on non-activity properties though. (More Info Here)
Creating the Activity-Based Workflow:
- Create a Workflow from scratch, and choose your object: likely Company/Contact (Whichever is record type is being updated with the activity in screenshot above).
- Trigger should be âwhen filter criteria is metâ.
- In the filter criteria at the top of the filter criteria menu, change your object from your starting object to âActivityâ.
- Create filters that include identifying info from the activity - so something like:
- âActivity Nameâ Contains âStripe Plan Syncing Failedâ. "
- Depending on the kind of activity, you may need to use âNote Bodyâ or some other activity property instead of âActivity nameâ. (Default Activity Properties Here)
- Keep in mind, this trigger will look for (company/contact/etc) records associated to ANY activity that matches your filters. So be sure to include a few other filters too, such as âActivity Date is after [date of workflow creation]â, to make sure youâre only enrolling records with fresh failed payment activities. I donât know your portal, but other âjust in caseâ filters here may help too.
- Final Note: I donât think you can use the âDelay Until an Eventâ action to wait until an additional activity happens, since the activity is cross-object. This may change in the future - and if it does, you can just use a whole string of delay functions copy-pasted, and then you donât need to worry about re-enrollment.
If you do manage to find a property to trigger the workflow instead of an activity:
- Create a workflow, trigger on that property.
- For example, Company based workflow, âFailed Paymentâ is any of âYesâ.
- Enable re-enrollment when âFailed Paymentâ is any of âYesâ.
- Perform your actions
- Set âFailed Paymentâ to âPreviously Failedâ or Clear âFailed Paymentâ.
- This method should work with pretty much any property type, though you may need to change it up a bit and re-enroll on âis knownâ if itâs not an enumeration property. Clearing the value at the end will not re-trigger enrollment on âis knownâ.
I hope all that info helps! Cheers!