APIs & Integrations

Not applicable

Redundant properties on recently updated request

Hello. I’m making a request to get recently updated companies, stating all the properties I want. In the response, I get unexpected properties, which I didn’t request, like “hs_analytics_first_touch_converting_campaign”.

When I request all properties existing for a company, I can’t find them on the list. Finding property by name also doesn’t work.
Requesting ALL companies (chunk by chunk) works well and doesn’t give unexpected results, but increases the number of API calls.

So, the first question: is it a regular behavior or some kind of issue? In case if it is normal, how should I exclude redundant properties from the response?

0 Upvotes
6 Replies 6
Not applicable

Redundant properties on recently updated request

Thank you. Answered PM.

0 Upvotes
Derek_Gervais
HubSpot Alumni
HubSpot Alumni

Redundant properties on recently updated request

Hi @Konstantin,

I understand now; thank you for helping to clear that up for me. I did some testing in my own portal, and I wasn’t able to see any properties returned from the ‘Get Recently Modified Companies’ endpoint (companies/v2/companies/recent/modified) that weren’t also returned by the ‘Get All Company Properties’ endpoint (properties/v1/companies/properties/).

Can you send me your Hub ID and the name of a specific property that appears in the ‘Get Recently Modified Companies’ endpoint’s response, but not in the ‘Get All Company Properties’ endpoint’s response?

0 Upvotes
Derek_Gervais
HubSpot Alumni
HubSpot Alumni

Redundant properties on recently updated request

Hi @Konstantin,

I’m not sure I understand. The recently modified endpoint will return a number of recently modified companies and include a predefined set of properties. You could also request these properties from the all companies endpoint, but you don’t need to (unless you expect them to change between your call to the recently modified companies endpoint and your call to the all companies endpoint).

0 Upvotes
Not applicable

Redundant properties on recently updated request

Ok, let’s try again.

Let’s suppose that “Get all Company Properties” endpoint returns 3 properties to me: property1, property2 and property3.
I request “Get all companies” with these 3 properties and save response to my DB.

Then I request “Get Recently Modified Companies” endpoint and expect the result to contain some properties, which are included in the list of 3 properties, described above. But suddenly, I receive a company, which includes property4! If I request “Get a Company Property” endpoint for a property4, the result will be “not found”. Also “Get all Company Properties” won’t include property4 in the response.

So, again, the questions are: why the “Get Recently Modified Companies” endpoint returns me the result with the properties, which are not included in the list of all properties? And should I suppose that these properties must be included in the dataset as the real data or should I ignore them and include only the properties, contained in all properties list.

P.S. It’s not about choosing between “Get all companies” and “Get recently modified” endpoints. It’s about understanding why “Get all Company Properties” doesn’t include some properties.

0 Upvotes
Derek_Gervais
HubSpot Alumni
HubSpot Alumni

Redundant properties on recently updated request

Hi @Konstantin,

The ‘recently modified companies’ endpoint doesn’t accept a properties parameter, but the ‘get all companies’ endpoint does. If you need to request a specific set of properties, you should use the get all companies endpoint.

0 Upvotes
Not applicable

Redundant properties on recently updated request

Ok, I see.
But still, why the recently modified companies contain the properties, which are not specified in the “all company properties” list?
Should I suppose, that they are newly created and the list of properties will be updated later so that I’ll add them to my dataset? Or they are redundant and I can ignore them?

0 Upvotes