<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: API Search - Return association field in APIs &amp; Integrations</title>
    <link>https://community.hubspot.com/t5/APIs-Integrations/API-Search-Return-association-field/m-p/788288#M63584</link>
    <description>&lt;P&gt;Hello&amp;nbsp;&lt;a href="https://community.hubspot.com/t5/user/viewprofilepage/user-id/561283"&gt;@TGrandey&lt;/a&gt;&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;use the Search API to return the associated company property when searching for custom objects in HubSpot. To achieve this, you'll need to specify the "properties" parameter in your API request and include the name of the association property, followed by the name of the company property you wish to return.&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;Here's an example of what the API request might look like:&lt;BR /&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;LI-CODE lang="ruby"&gt;https://api.hubapi.com/crm/v3/objects/custom-objects/search?hapikey=&amp;lt;your_api_key&amp;gt;&amp;amp;properties=first_name,last_name,company.association_property_name.company_property_name&amp;amp;q=last_name:Smith
&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;In this example, replace &lt;CODE&gt;&amp;lt;your_api_key&amp;gt;&lt;/CODE&gt; with your HubSpot API key, &lt;CODE&gt;custom-objects&lt;/CODE&gt; with the name of your custom object, &lt;CODE&gt;association_property_name&lt;/CODE&gt; with the name of the association property that links the custom object to the company object, and &lt;CODE&gt;company_property_name&lt;/CODE&gt; with the name of the company property you want to return.&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;
&lt;P&gt;With this API request, you should be able to retrieve custom objects with the last name of "Smith" and include the associated company's name in the response. Note that you may need to adjust the parameter names and values to match your specific use case.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Mon, 01 May 2023 09:06:16 GMT</pubDate>
    <dc:creator>himanshurauthan</dc:creator>
    <dc:date>2023-05-01T09:06:16Z</dc:date>
    <item>
      <title>API Search - Return association field</title>
      <link>https://community.hubspot.com/t5/APIs-Integrations/API-Search-Return-association-field/m-p/788076#M63579</link>
      <description>&lt;P&gt;I have a custom object that has an association to HubSpot's company object. I'm wondering if there is a way to have the search api return a property of the company when searching the custom object.&lt;BR /&gt;&lt;BR /&gt;For example, I'm searching for all custom objects with the last name of "Smith" and I would like to return some of the properties of the custom object as well as the name of the company that the custom object is associated with.&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;Search: last_name EQ Smith&lt;BR /&gt;Return:&lt;BR /&gt;&amp;nbsp; &amp;nbsp; first_name: Joe&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; last_name: Smith&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; company.company_name: Acme, Inc.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks for any help!&lt;/P&gt;</description>
      <pubDate>Sat, 29 Apr 2023 23:26:57 GMT</pubDate>
      <guid>https://community.hubspot.com/t5/APIs-Integrations/API-Search-Return-association-field/m-p/788076#M63579</guid>
      <dc:creator>TGrandey</dc:creator>
      <dc:date>2023-04-29T23:26:57Z</dc:date>
    </item>
    <item>
      <title>Re: API Search - Return association field</title>
      <link>https://community.hubspot.com/t5/APIs-Integrations/API-Search-Return-association-field/m-p/788288#M63584</link>
      <description>&lt;P&gt;Hello&amp;nbsp;&lt;a href="https://community.hubspot.com/t5/user/viewprofilepage/user-id/561283"&gt;@TGrandey&lt;/a&gt;&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;use the Search API to return the associated company property when searching for custom objects in HubSpot. To achieve this, you'll need to specify the "properties" parameter in your API request and include the name of the association property, followed by the name of the company property you wish to return.&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;Here's an example of what the API request might look like:&lt;BR /&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;LI-CODE lang="ruby"&gt;https://api.hubapi.com/crm/v3/objects/custom-objects/search?hapikey=&amp;lt;your_api_key&amp;gt;&amp;amp;properties=first_name,last_name,company.association_property_name.company_property_name&amp;amp;q=last_name:Smith
&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;In this example, replace &lt;CODE&gt;&amp;lt;your_api_key&amp;gt;&lt;/CODE&gt; with your HubSpot API key, &lt;CODE&gt;custom-objects&lt;/CODE&gt; with the name of your custom object, &lt;CODE&gt;association_property_name&lt;/CODE&gt; with the name of the association property that links the custom object to the company object, and &lt;CODE&gt;company_property_name&lt;/CODE&gt; with the name of the company property you want to return.&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;
&lt;P&gt;With this API request, you should be able to retrieve custom objects with the last name of "Smith" and include the associated company's name in the response. Note that you may need to adjust the parameter names and values to match your specific use case.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 01 May 2023 09:06:16 GMT</pubDate>
      <guid>https://community.hubspot.com/t5/APIs-Integrations/API-Search-Return-association-field/m-p/788288#M63584</guid>
      <dc:creator>himanshurauthan</dc:creator>
      <dc:date>2023-05-01T09:06:16Z</dc:date>
    </item>
    <item>
      <title>Re: API Search - Return association field</title>
      <link>https://community.hubspot.com/t5/APIs-Integrations/API-Search-Return-association-field/m-p/870876#M68596</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;Could you simplify this to explain how I can get the associated company name when the custom object is a deal ?&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thank you&lt;/P&gt;</description>
      <pubDate>Fri, 27 Oct 2023 02:22:18 GMT</pubDate>
      <guid>https://community.hubspot.com/t5/APIs-Integrations/API-Search-Return-association-field/m-p/870876#M68596</guid>
      <dc:creator>dca123</dc:creator>
      <dc:date>2023-10-27T02:22:18Z</dc:date>
    </item>
    <item>
      <title>Re: API Search - Return association field</title>
      <link>https://community.hubspot.com/t5/APIs-Integrations/API-Search-Return-association-field/m-p/882337#M69195</link>
      <description>&lt;P&gt;Where would one find the '&lt;SPAN&gt;association_property_name'?&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 20 Nov 2023 20:51:13 GMT</pubDate>
      <guid>https://community.hubspot.com/t5/APIs-Integrations/API-Search-Return-association-field/m-p/882337#M69195</guid>
      <dc:creator>SLane1</dc:creator>
      <dc:date>2023-11-20T20:51:13Z</dc:date>
    </item>
  </channel>
</rss>

