Export a single property's sub-values (e.g. dropdowns, checkboxes)

Status: Idea Submitted

Status history

Hi all, I saw this thread working on a similar problem. The solution was to make a new field (for multiple checkboxes) and import values from my original text field. Key is to use the export feature to manage data in excel externally, then reimport. Here are the basic steps:

  1. Export the data you want to change with the original (text) field, you will use this to create the list options. Best to create a hubspot list first and export from there with only the columns you want
  2. Open the exported spreadsheet In excel or another spreadsheet editor,. Create a list of unique values from the original field with an advanced filter or other technique (google it if you need to)
  3. Create a new field with dropdown or checkboxes in HubSpot, copy this unique values list from excel into the new field options
  4. Create a list in hubspot with your companies or contacts, an ID column (company domain name or contact name), old file, new (blank) field
  5. Export list to excel
  6. In excel, copy the old field values to the new field
  7. Save the file and import back into hubspot. Clean up errrors as you go, the error checking functionality of HubSpot is awesome! You have to manipulate and re-save the spredhseet you are updating from. I had to delete the ID field that appeared. Add values to existing companies, only overwrite the new field JIC.

This takes a bit to learn, but it is very powerful. Thanks hubspot!

I would need it to.

Can we get an update on this?

YES!

This would be great

Salesforce has this as a print view which is easily assessible. It’s 2023, almost 2024 Hubspot. Please make this happen asap.

It would be great to have an easier way to achieve this than doing an API call. A solution where we can click a “Export Property Label” button would be ideal.

Absurd that this has been on since 2020, with a comment almost from every week asking for it, yet no reply. This seems to be a basic function, being able to export property selection lists, I am surprised that it is not even picked up by Hubspot Developers.

Hello everyone, I too have faced the challenge of obtaining the list of subvalues. I’ve developed a fast and scalable method that makes it accessible for virtually anyone to use without much difficulty. I’m pleased to share it with you.

Here’s the procedure to use the Google Apps Script to retrieve subvalues of a property from HubSpot’s API and write them to a specific sheet named “Script” in Google Sheets:

  1. Open Google Sheets:

    • Go to Google Sheets and open a new or existing spreadsheet.
  2. Access Google Apps Script Editor:

    • In your Google Sheets, click on “Extensions” in the menu bar.
    • Choose “Apps Script” from the dropdown menu. This opens the Google Apps Script editor in a new tab.
  3. Paste the Script:

    • In the Google Apps Script editor, paste the provided script into the script editor window.
  4. Update API Token:

    • Replace ‘YOUR_HUBSPOT_API_TOKEN’ in the script with your actual HubSpot API token.
  5. Save the Script:

    • Click the disk icon or select “File” → “Save” to save your script. You can give it a relevant name, like “HubSpotAPI”.
  6. Run the Script:

    • To run the script, click the play button (triangle icon) in the toolbar of the script editor.
    • If this is your first time running the script, you will be prompted to authorize the script to access your Google Sheets data. Follow the on-screen instructions to grant the necessary permissions.
  7. Check the “Script” Sheet:

    • Go back to your Google Sheets document.
    • If the script runs successfully, it will either find or create a sheet named “Script” and write the retrieved data from HubSpot into this sheet.
  8. Debugging (if needed):

    • If the script doesn’t work as expected, you can view the logs by clicking on “View” → “Logs” in the script editor. This can help you identify any issues or errors in the script.
  9. Automate the Script (Optional):

    • If you wish to run this script automatically at set intervals, you can use Triggers in Google Apps Script.
    • Go to the script editor, click on the clock icon (current project’s triggers), and set a new trigger for the function you want to automate.

This procedure allows you to interact with HubSpot’s API directly from Google Sheets, automating the data retrieval and making it accessible for further analysis or reporting within your spreadsheet.
Here’s the complete Google Apps Script code with comments to retrieve subvalues of a “property_name” property from a ‘products’ object in HubSpot’s API and write them to a sheet named “Script” in Google Sheets:

// Function to retrieve subvalues of a specified property from HubSpot API

function getHubSpotPropertySubValues() {

// Define the object type and property name

var objectType = ‘products’; // The object type (e.g., ‘contacts’, ‘deals’, ‘products’, etc.)

var propertyName = ‘property_name’; // The name of the property

// Your HubSpot API token

var token = ‘YOUR_HUBSPOT_API_TOKEN’; // Replace with your actual HubSpot API token Authentication overview - HubSpot docs

// Construct the URL for the HubSpot API request

var url = ‘https://api.hubapi.com/crm/v3/properties/’ + objectType + ‘/’ + propertyName;

// Set up the headers for the API request, including the authorization token

var headers = {

‘Authorization’: 'Bearer ’ + token,

‘Content-Type’: ‘application/json’

};

// Define the options for the API request

var options = {

‘method’ : ‘get’,

‘headers’ : headers,

};

try {

// Make the API request

var response = UrlFetchApp.fetch(url, options);

var json = response.getContentText();

var data = JSON.parse(json);

// Get or create the ‘Script’ sheet in the current spreadsheet

var spreadsheet = SpreadsheetApp.getActiveSpreadsheet();

var sheet = spreadsheet.getSheetByName(“Script”);

// If the ‘Script’ sheet does not exist, create it

if (!sheet) {

sheet = spreadsheet.insertSheet(“Script”);

}

// Check if the property data has options (subvalues) and write them to the sheet

if (data && data.options) {

sheet.clear(); // Clear the sheet before writing new data

// Loop through each option and write its label and value to the sheet

data.options.forEach(function(option) {

sheet.appendRow([option.label, option.value]);

});

} else {

Logger.log(“No subvalues found for the specified property.”);

}

} catch (error) {

// Log any errors encountered during the API request

Logger.log("Error when querying HubSpot API: " + error.toString());

}

}

To use this script, you need to replace ‘YOUR_HUBSPOT_API_TOKEN’ with your actual HubSpot API token. The script will create a new sheet named “Script” if it doesn’t exist and write the subvalues of the specified property into this sheet. Remember that the specific structure of the data may vary depending on the property you are querying, so you might need to adjust the script accordingly.

If you need any help or professional consultation, please feel free to contact me.

This seems like fairly basic functionality. Come on HubSpot, let’s make this happen!

Hi Hubspot, I’m hoping to flag this issue again. It might not feel like a priority for your product team, but it doesn’t appear to be too complex, even if you just give us the option after clicking “export all properties” to select the properties we want to export (similar to how you determine which columns you want to export when exporting lists) this would be great!

Thank you!

Emily

Absolutely, it streamlines data collection and analysis by eliminating manual copying, saving time and reducing errors.

We also desparately need this to be able to update dropdowns.

Any idea when is this going to be developed? :thinking:

having just exported the full PROPERTIES list just to be able to see contents of a drop down menu and to discover it is no where near a neat list, would definitely want a better feature

Does anyone know how to retrieve the internal value for the hubspot_owner_id? Since the UserId and the internal value in the property hubspot_owner_id aren’t the same values. I tried to request to /crm/v3/properties/contacts/hubspot_owner_id but it didn’t work.

A HubSpot support rep shared this article as one way to bulk-copy values. It works, but ofcourse this is far from ideal or a good user experience.
That work-around also does not provide any way to bulk-edit any values.

This lack of basic functionality is not sufficient for a CRM that wants to make a legitimate challenge to become the 1 CRM.

We need this

Please add this funtionality it is much needed!!

We’ve completed an internal assessment of properties, and one requirement was to view the options in dropdowns/checkboxes. Unfortunately, the only method available was to manually extract the values. It would be beneficial to have the option to export these values instead.

Additionally, do you require a specific category for the concept of “properties”? I’m having difficulty determining the most suitable category for this idea.