When integrating tracking code functionality then contact form property creating a so many duplicates on every form submission



I have implemented Contact API with contact form 7 plugin in WordPress. Below are the request param and API which I used to create a contact.

$arr = array('properties' => array(
array('property' => 'email','value' => 'apitest12345@hubspot.com'),
array('property' => 'firstname','value' => 'Second Test'),
array('property' => 'lastname','value' => 'user'),
array('property' => 'message','value' => 'This is for test..!!!'),
array('property' => 'country','value' => 'Hungery'),
array('property' => 'phone','value' => '0123456789')
) );
$post_json = json_encode($arr);
$hapikey = "MY HASH API KEY";
$endpoint = 'https://api.hubapi.com/contacts/v1/contact?hapikey=' . $hapikey;

Without integrating tracking code functionality then this above contact API is working properly.

But, When I integrate tracking code functionality, then create a new property every time when I submit the contact form. I gave an example below for exactly what's the problem.

For example, we currently have "Dashboard: Message" in our system, but I want it to be "Message" with the internal name "message" but it's not possible. HubSpot created one for Message based on a form leadin is reading, but the internal name is showing as "leadin_message_rrr_test_4a873e4df14f2af7287f111c7b8671ee". It also reads forms with the same field name and creates new properties for them, so I have so many duplicates in there and can't delete or modify.

Another thing that makes this challenging is when I'm building workflows based on a contact property, it's impossible for me to know which field is the correct one.

I would also really like to see the option to turn off specific forms rather than the whole tool itself. This works for things like contact forms, but with all of the duplications, it makes it frustrating to use on other forms on our site.

SO please help me out to resolve this issue.


Hi @hirenbhuva30,

I'm not sure I'm understanding the issue here. The behavior you're describing sounds like you're using the Collected Forms tool to track submissions to some external forms? Is that what you're referring to when you mention "tracking code functionality?"

A lot of what you're describing is typical of Collected Forms implementations; it's not a tool designed for heavy customizability. Collected Forms is intended to allow you to capture submissions on existing forms on your site very easily; if you need more customization or flexibility, I'd recommend using custom forms with the Forms API and/or embedded HubSpot forms.


Thanks for your reply.

I know how to use collected form, but in this case my issue is whenever I'm submitting the form the properties of the form gets duplicated in hubspot dashboard.

For example: If I have two fields in the collected form, Lets say Name and Message both properties are getting duplicated on every form submission from our website.



Hi @hirenbhuva30,

When you say they're getting duplicated, do you mean they already exists in your portal, and the collected forms tool is creating new versions of those properties? This is actually expected; the collected forms tool can match up Email, First Name, Last Name, and Phone Number, but not other default/custom fields. These other fields included on your forms will be created as new HubSpot properties. This is one of the limitations of the collected forms tool, in contrast to traditional HubSpot forms or custom HTML forms using the Forms API.