Purpose
The primary purpose of this workflow action is to search for a folder in HubSpot's "Files" tool (File Manager) by its name and retrieve various details about that folder (such as its Folder ID, Parent Folder ID, etc.).
The retrieved information is returned as "action outputs" in the workflow. This allows you to save the information to a property in a subsequent action or use it as a parameter for another API call.
Use Cases
This feature is useful for automating file management and organization within a workflow.
- Automated File Organization: When uploading files to HubSpot via an API, dynamically search for the target folder ID to specify it as the destination.
- Linking Folder Info to Records: Search for folders created for specific customers or deals (e.g., "CustomerName_Deal_Docs") and save the Folder ID to a custom property on the corresponding contact or deal record.
- Verifying Folder Existence: Check if a specific project folder exists. If it doesn't, automatically create a task to ask a team member to create it.
Setup and Execution Steps (As seen in the video)
The video shows the process of searching for a folder named test1 in the File Manager and retrieving its ID and other information.
Step 1: Check Data Before Execution
- Open HubSpot's "Files and Templates" > "Files" screen.
- Confirm that the folder you intend to search for, named
test1, exists in the File Manager.
Step 2: Check Workflow and Trigger
- Navigate to the workflow editor.
- For demonstration purposes, the trigger (enrollment criteria) is set to activate when the "
Event Date" property value is changed.
Step 3: Add the Custom Action
- Click the "+" icon in the workflow to add a new action.
- From the action selection panel, choose "Custome Workflow Business v2" from the "Integrated apps" section.
Step 4: Select the Action
- From the list of custom actions that appears, select "Folder Search Action."
Step 5: Specify the Folder Name to Search
- The configuration screen for "Folder Search Action" opens.
- Folder name query: Enter the name of the folder you want to search for. You can enter fixed text (like
test1 in the video) or use a property token to dynamically specify the folder name. - After configuring, click "Save."
Step 6: Activate the Workflow and Confirm Execution
- The "1. Folder Search Action" is added to the workflow.
- Activate the workflow ("Workflow is On") and perform the action that meets the trigger criteria.
- Navigate to the "Enrollment history" tab and click on the execution history for the enrolled contact (
Brian Halligan).
Step 7: Verify the Final Result
- The execution "Event details" will appear on the right side.
- The action is shown as "Successful."
- In the "Action outputs" section, you can confirm that information such as
folderId, folderName, and parentFolderId has been successfully retrieved as values. - These output values can then be used, for example, in a subsequent "Set property value" action to save them to a record's property.