1. Help Center
  2. HubSpot Micro Apps
  3. Workflow Generate Code Actions

What does the "Generate a UUID' action do?

 

The Generate a UUID action within the Generate Code Actions App by Integration Glue allows you to create a Universally Unique Identifier (UUID). A UUID is a 128-bit value that is used to uniquely identify records, sessions, transactions, or other elements across systems and databases.

This action is particularly useful for generating unique identifiers for various purposes, such as creating unique customer records, transaction IDs, or session keys without risking duplication. The UUID is a globally unique string that ensures no two generated IDs are the same, even across different systems.

This action is particularly useful when:

  • You need to create unique identifiers for each customer, deal, or record in HubSpot.
  • You want to integrate HubSpot with other systems that require UUIDs to track or reference records.
  • You are handling high volumes of data and need a way to generate unique keys without conflicts.

Screenshot 2025-01-15 151040

  • Property to set UUID (must be set as a unique property) refers to the HubSpot property where the generated UUID will be saved. The UUID generated by this action will be stored in a specific property on the record (e.g., contact, deal, ticket) that triggers the workflow.

    The part "must be set as a unique property" means that the property where the UUID will be saved should be configured in HubSpot as a unique property. This ensures that each record will have its own unique UUID without conflicts. If a property is marked as unique, HubSpot will not allow duplicate values to be saved in that property across different records.

 

Step 1: Create a Unique Property in HubSpot

  1. Go to HubSpot and navigate to Settings.
  2. Under Data Management, select Properties.
  3. Click Create Property.
  4. Choose the appropriate object (e.g., Contact, Deal, or Company).
  5. Set the Field Type to Single-line text or another suitable type to store the UUID.
  6. In the property settings, check the box to make this a unique property (this ensures no duplicates are allowed for this property).
  7. Name the property something like UUID (or any name you prefer).

Step 2: Create or Edit a Workflow

  1. Go to the Workflows tab in HubSpot.
  2. Create a new workflow or open an existing one where you want to use the "Generate a UUID" action.
  3. Choose the trigger for the workflow (e.g., when a contact is created or a deal is moved to a specific stage).

Step 3: Add the "Generate a UUID" Action

  1. Click the + button to add a new action to your workflow.
  2. Search for "Generate a UUID" in the action list.
  3. Select the Generate a UUID action.

Step 4: Configure the Action

  1. In the Property to set UUID dropdown, choose the unique property you created earlier (e.g., "UUID").
  2. The UUID will be generated automatically each time the workflow runs and stored in this property.

Step 5: Test the Workflow

  1. Test the workflow by enrolling a record (e.g., create a new contact) to ensure the UUID is generated and stored in the designated property.
  2. Check the record to see if the UUID has been populated in the property you set.

Step 6: Activate the Workflow

  1. After confirming everything works correctly, activate the workflow to run it automatically on future records.