Workflow output not present with Go To Workflow call

scspijker
メンバー

I need to know the current date time in my current custom workflow. HubSpot does not offer any step for this, so I decided to create a custom code workflow whose sole purpose is to supply an ISO8601 current date time.

 

I've setup a custom workflow with some code that does this:

exports.main = async (event, callback) => {
  callback({
    outputFields: {
      currentDateTime: new Date().toISOString()
    }
  });
}

I've defined the output in the re-usable workflow, and this all works and returns a datetime (a String containing the ISO8601 formatted datetime).

Output setOutput set

 

 

Workflow working, output workingWorkflow working, output working

 

Now, when I want to use this from my main workflow, I can call it, but the "currentDateTime" output is not shown! Only the success state?

Screenshot 2026-01-19 at 12.08.35.png

 How do I get my output to show up? I've looked through all the settings, but can't find anything else.

 

 

0 いいね!
1件の承認済みベストアンサー
karstenkoehler
解決策
殿堂入り | Solutions Partner
殿堂入り | Solutions Partner

Hi @scspijker,

 

As far as I know, you can't reference the output of an action from another workflow - even if you sent a record there from your current workflow.

 

In other words, if you send a record from workflow1 to workflow2 and workflow2 is the one with the custom code action, you can't access the output of the action in workflow2 within workflow1.

 

You would have to include the custom code action in workflow1 so that you can reference it's output. (Unless you're planning on regularly changing the code - which doesn't seem to be the case - I don't think there's any issue with that.)

 

Best regards

Karsten Köhler
HubSpot Freelancer | RevOps & CRM Consultant | Community Hall of Famer

Beratungstermin mit Karsten vereinbaren

 

Did my post help answer your query? Help the community by marking it as a solution.

元の投稿で解決策を見る

1件の返信 1
karstenkoehler
解決策
殿堂入り | Solutions Partner
殿堂入り | Solutions Partner

Hi @scspijker,

 

As far as I know, you can't reference the output of an action from another workflow - even if you sent a record there from your current workflow.

 

In other words, if you send a record from workflow1 to workflow2 and workflow2 is the one with the custom code action, you can't access the output of the action in workflow2 within workflow1.

 

You would have to include the custom code action in workflow1 so that you can reference it's output. (Unless you're planning on regularly changing the code - which doesn't seem to be the case - I don't think there's any issue with that.)

 

Best regards

Karsten Köhler
HubSpot Freelancer | RevOps & CRM Consultant | Community Hall of Famer

Beratungstermin mit Karsten vereinbaren

 

Did my post help answer your query? Help the community by marking it as a solution.