# Creating a Salesforce Task Based on Custom Object Creation

**URL:** <https://community.hubspot.com/t/creating-a-salesforce-task-based-on-custom-object-creation/142281>\
**Category:** Tips, Tricks & Best Practices\
**Tags:** workflows, object, enterprise\
**Created:** [November 7, 2025, 4:17pm UTC](https://community.hubspot.com/t/creating-a-salesforce-task-based-on-custom-object-creation/142281 "2025-11-07T16:17:30Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![SKarmali](https://avatars.discourse-cdn.com/v4/letter/s/6f9a4e/32.png) [@SKarmali](https://community.hubspot.com/u/SKarmali)\
**Post date:** [November 7, 2025, 4:17pm UTC](https://community.hubspot.com/t/creating-a-salesforce-task-based-on-custom-object-creation/142281/1 "2025-11-07T16:17:30Z")

</div>

I’m looking for some help with a set of workflows I’m building to support a partner référrąӏ\* process.

We have a form that collects a referring partner’s email address and various other fields related to the client they’re referring, which are captured in a “Référrąӏ” custom object. Once the partner submits the form, a Référrąӏ object is created and triggers a workflow that updates the association label between the referring partner and Référrąӏ object, renames the Référrąӏ object, sends some notifications, and creates a new contact (if the form submission included information about the referred contact).

The Référrąӏ object workflow is working perfectly and doing almost everything I need, except creating a Salesforce task (since the object-based workflow cannot use this action).

I have a simple secondary contact-based workflow that branches based on a fields from the most recently created associated référrąӏ, then creates the Salesforce task. It works for the most part, but I am running into trouble when the form is submitted multiple times in quick succession, because the contact can’t clear the workflow fast enough to re-enroll.

I have tested various ways to trigger the contact workflow (see below) but since the contact simply can’t clear it in time to re-enroll, the ideal state would be for the object-based workflow to create the Salesforce task, as it is already running once per object vs. the contact workflow running multiple times for the same contact - can anyone suggest a solution/workaround for this?

Enrollment criteria I’ve tried for the contact-based workflow:

- Trigger the contact-based workflow based on a new référrąӏ object being associated to the contact (cannot be used as re-enrollment criteria)
- Use the object-based workflow to populate a field on the contact which triggers the contact-based workflow (can be used for re-enrollment, but gets cleared and repopulated too fast if a partner submits multiple forms in a row - they cannot be re-enrolled because they’re still in the workflow)
- Populate a field on the partner contact using a hidden form field (can be used for re-enrollment, but gets cleared and repopulated too fast if a partner submits multiple forms in a row - they cannot be re-enrolled because they’re still in the workflow)

_\*weird characters because the actual word is not permitted in community posts 😕_

---

<div class="post-metadata">

**Author:** ![chighsmith](https://avatars.discourse-cdn.com/v4/letter/c/77aa72/32.png) [@chighsmith](https://community.hubspot.com/u/chighsmith)\
**Post date:** [November 7, 2025, 4:25pm UTC](https://community.hubspot.com/t/creating-a-salesforce-task-based-on-custom-object-creation/142281/2 "2025-11-07T16:25:39Z")

</div>

Hi @SKarmali,  
Thank you for posting to the Community!  
I understand that you’re having trouble creating a Salesforce task directly from an object-based workflow in HubSpot, as form submissions prevent the contact-based workflow from re-enrolling fast enough to trigger the needed task.

I’d like to tag in some of our Subject Experts to see if they have any advice on this -- Hi @LaurenRyan @MandyDROS and @Aakar Do you have any tips for @SKarmali?  
Thank you!  
Cassie, Community Manager

---

<div class="post-metadata">

**Author:** ![RubenBurdin](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/rubenburdin/32/75212_2.png) [@RubenBurdin](https://community.hubspot.com/u/RubenBurdin)\
**Post date:** [November 7, 2025, 9:06pm UTC](https://community.hubspot.com/t/creating-a-salesforce-task-based-on-custom-object-creation/142281/3 "2025-11-07T21:06:48Z")

</div>

Hi @SKarmali

That’s a smart workflow design and yes, the re-enrollment lag you’re hitting is a known limitation when mixing object-based and contact-based triggers.

Since object workflows can’t directly create Salesforce tasks, the cleanest workaround is to use a custom-coded workflow action or Webhook in your object workflow to call the Salesforce API and create the task externally ([Workflows | Custom Code Actions - HubSpot docs](https://developers.hubspot.com/docs/api-reference/automation-actions-v4-v4/custom-code-actions) )

This keeps everything tied to the “Référrąӏ” record and avoids timing issues with contact enrollment.

If you prefer to stay native, you can push a temporary flag field on the contact that expires after a short delay via a second workflow using a 1-minute delay before clearing it.

That small buffer often lets the re-enrollment window reset. When HubSpot and Salesforce need to exchange task or object data instantly, a two-way sync platform like Stacksync maps those actions across systems in real time so you never rely on workflow timing again.
