<?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: Matching Ticket to Contact in APIs &amp; Integrations</title>
    <link>https://community.hubspot.com/t5/APIs-Integrations/Matching-Ticket-to-Contact/m-p/750261#M61335</link>
    <description>&lt;P&gt;Hi Frank,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;So you are saying that Contacts has multiple hs_object_id's that are associated with one ticket?&lt;/P&gt;</description>
    <pubDate>Wed, 01 Feb 2023 20:18:08 GMT</pubDate>
    <dc:creator>Astroraf</dc:creator>
    <dc:date>2023-02-01T20:18:08Z</dc:date>
    <item>
      <title>Matching Ticket to Contact</title>
      <link>https://community.hubspot.com/t5/APIs-Integrations/Matching-Ticket-to-Contact/m-p/749647#M61333</link>
      <description>&lt;P&gt;I am using Python to extract the data from HubSpot with the Private App API calls. I am using the Ticket and Contacts to load into dataframes within my python environment.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Tickets give me these key attributes:&lt;/P&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;archived&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;archived_at&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;associations&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;created_at&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;id&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;content&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;createdate&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;hs_lastmodifieddate&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;hs_object_id&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;hs_pipeline&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;hs_pipeline_stage&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;hs_ticket_category&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;hs_ticket_priority&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;subject&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;properties_with_history&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;updated_at&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;Contact gives me these key attributes:&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;archived&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;archived_at&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;associations&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;created_at&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;id&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;createdate&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;email&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;firstname&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;hs_object_id&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;lastmodifieddate&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;lastname&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;properties_with_history&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;updated_at&lt;/SPAN&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I am trying to match each ticket created to the contact but there isn't a key attribute in both data frames for me to match. Is this because of the Private Apps and what scopes I am picking or is there something else going on? Any and all help will be much appreciated.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 31 Jan 2023 19:53:03 GMT</pubDate>
      <guid>https://community.hubspot.com/t5/APIs-Integrations/Matching-Ticket-to-Contact/m-p/749647#M61333</guid>
      <dc:creator>Astroraf</dc:creator>
      <dc:date>2023-01-31T19:53:03Z</dc:date>
    </item>
    <item>
      <title>Re: Matching Ticket to Contact</title>
      <link>https://community.hubspot.com/t5/APIs-Integrations/Matching-Ticket-to-Contact/m-p/749920#M61334</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.hubspot.com/t5/user/viewprofilepage/user-id/513212"&gt;@Astroraf&lt;/a&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;My API/dev knowlegde is rudimentary, but I know HubSpot works with&amp;nbsp;&lt;SPAN&gt;hs_object_id to identify individual records, and then associations to link objects together.&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;I would expect that the&amp;nbsp;associations attribute in the ticket object contains a reference to a&amp;nbsp;hs_object_id on a contact. This &lt;A href="https://legacydocs.hubspot.com/docs/methods/crm-associations/get-associations" target="_blank" rel="noopener"&gt;article seems to confirm&lt;/A&gt; my assumption.&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;I hope that helps.&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;Frank&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 01 Feb 2023 09:32:19 GMT</pubDate>
      <guid>https://community.hubspot.com/t5/APIs-Integrations/Matching-Ticket-to-Contact/m-p/749920#M61334</guid>
      <dc:creator>franksteiner79</dc:creator>
      <dc:date>2023-02-01T09:32:19Z</dc:date>
    </item>
    <item>
      <title>Re: Matching Ticket to Contact</title>
      <link>https://community.hubspot.com/t5/APIs-Integrations/Matching-Ticket-to-Contact/m-p/750261#M61335</link>
      <description>&lt;P&gt;Hi Frank,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;So you are saying that Contacts has multiple hs_object_id's that are associated with one ticket?&lt;/P&gt;</description>
      <pubDate>Wed, 01 Feb 2023 20:18:08 GMT</pubDate>
      <guid>https://community.hubspot.com/t5/APIs-Integrations/Matching-Ticket-to-Contact/m-p/750261#M61335</guid>
      <dc:creator>Astroraf</dc:creator>
      <dc:date>2023-02-01T20:18:08Z</dc:date>
    </item>
    <item>
      <title>Re: Matching Ticket to Contact</title>
      <link>https://community.hubspot.com/t5/APIs-Integrations/Matching-Ticket-to-Contact/m-p/750279#M61336</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.hubspot.com/t5/user/viewprofilepage/user-id/513212"&gt;@Astroraf&lt;/a&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Yes and no.&lt;/P&gt;
&lt;UL&gt;
&lt;LI&gt;Each object in HubSpot (contact, company, deal, ticket, etc.) has a hs_object_id&lt;/LI&gt;
&lt;LI&gt;Each object in HubSpot is associated to one or more other HubSpot objects, check out&amp;nbsp;&lt;A href="https://app.hubspot.com/data-model-overview/" target="_blank"&gt;https://app.hubspot.com/data-model-overview/&lt;/A&gt;&lt;STRONG&gt;HubID&lt;/STRONG&gt;/ for an interactive overview. The ticket object can be associated with companies, contacts and deals with a 1-to-many relationship, i.e. 1 ticket is associated with 2 contacts.&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Screenshot 2023-02-01 at 21.36.41.png" style="width: 999px;"&gt;&lt;img src="https://community.hubspot.com/t5/image/serverpage/image-id/84456iF19455F3DDC1576D/image-size/large?v=v2&amp;amp;px=999" role="button" title="Screenshot 2023-02-01 at 21.36.41.png" alt="Screenshot 2023-02-01 at 21.36.41.png" /&gt;&lt;/span&gt;&lt;/LI&gt;
&lt;LI&gt;This would mean, that the ticket in question would show 2 hs_contact_ids under the ticket association.&lt;/LI&gt;
&lt;LI&gt;Similarly, if a contact has multiple tickets (pretty common scenario) you would be able to query the associated ticket objects which would return a series of hs_object_ids for tickets.&lt;/LI&gt;
&lt;/UL&gt;
&lt;P&gt;Does that make sense?&lt;/P&gt;
&lt;P&gt;Frank&lt;/P&gt;</description>
      <pubDate>Wed, 01 Feb 2023 20:48:12 GMT</pubDate>
      <guid>https://community.hubspot.com/t5/APIs-Integrations/Matching-Ticket-to-Contact/m-p/750279#M61336</guid>
      <dc:creator>franksteiner79</dc:creator>
      <dc:date>2023-02-01T20:48:12Z</dc:date>
    </item>
    <item>
      <title>Re: Matching Ticket to Contact</title>
      <link>https://community.hubspot.com/t5/APIs-Integrations/Matching-Ticket-to-Contact/m-p/750293#M61337</link>
      <description>&lt;P&gt;The link you provided, unfortunately, didn't work, but when I tried to match the Hubspot object ID in tickets to the HubSpot in Contacts, nothing matched.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;What I am finding is that the Contact object_id is no longer than 6 characters whereas the HubSpot object_id in the ticket is 10 characters long.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Their object_id's do not match in length.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;As well, with my company's tickets, there is an option to fill an area called affiliate_code but this does not show in the ticket information. Is there a way to change this or get all the information from the ticket even if it's blank?&lt;/P&gt;</description>
      <pubDate>Wed, 01 Feb 2023 21:07:41 GMT</pubDate>
      <guid>https://community.hubspot.com/t5/APIs-Integrations/Matching-Ticket-to-Contact/m-p/750293#M61337</guid>
      <dc:creator>Astroraf</dc:creator>
      <dc:date>2023-02-01T21:07:41Z</dc:date>
    </item>
    <item>
      <title>Re: Matching Ticket to Contact</title>
      <link>https://community.hubspot.com/t5/APIs-Integrations/Matching-Ticket-to-Contact/m-p/751844#M61338</link>
      <description>&lt;P&gt;You should use the &lt;A href="https://developers.hubspot.com/docs/api/crm/associations/v3" target="_blank" rel="noopener"&gt;Associations API&lt;/A&gt;&amp;nbsp;where you specify which object types (Contact and Ticket) you look for, and specific id of one of them (for instance, the contactId you want all connected Tickets for). In javascript/node.js the Hubspot client really simplifies things, so maybe the &lt;A href="https://github.com/HubSpot/hubspot-api-python" target="_blank" rel="noopener"&gt;Python one&lt;/A&gt; does it as well.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sun, 05 Feb 2023 16:59:08 GMT</pubDate>
      <guid>https://community.hubspot.com/t5/APIs-Integrations/Matching-Ticket-to-Contact/m-p/751844#M61338</guid>
      <dc:creator>TShma</dc:creator>
      <dc:date>2023-02-05T16:59:08Z</dc:date>
    </item>
    <item>
      <title>Re: Matching Ticket to Contact</title>
      <link>https://community.hubspot.com/t5/APIs-Integrations/Matching-Ticket-to-Contact/m-p/752903#M61339</link>
      <description>&lt;DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;get_object_id&lt;/SPAN&gt; &lt;SPAN&gt;=&lt;/SPAN&gt; &lt;SPAN&gt;api_client&lt;/SPAN&gt;&lt;SPAN&gt;.crm.tickets.associations_api.get_all(&lt;/SPAN&gt;&lt;SPAN&gt;ticket_id&lt;/SPAN&gt;&lt;SPAN&gt;=&lt;/SPAN&gt;&lt;SPAN&gt;1407233837&lt;/SPAN&gt;&lt;SPAN&gt;, &lt;/SPAN&gt;&lt;SPAN&gt;to_object_type&lt;/SPAN&gt;&lt;SPAN&gt;=&lt;/SPAN&gt;&lt;SPAN&gt;'contacts'&lt;/SPAN&gt;&lt;SPAN&gt;)&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;get_object_id&lt;/SPAN&gt;&lt;SPAN&gt;.results[&lt;/SPAN&gt;&lt;SPAN&gt;0&lt;/SPAN&gt;&lt;SPAN&gt;].to_object_id&lt;/SPAN&gt;&lt;/DIV&gt;&lt;/DIV&gt;</description>
      <pubDate>Tue, 07 Feb 2023 17:29:39 GMT</pubDate>
      <guid>https://community.hubspot.com/t5/APIs-Integrations/Matching-Ticket-to-Contact/m-p/752903#M61339</guid>
      <dc:creator>Astroraf</dc:creator>
      <dc:date>2023-02-07T17:29:39Z</dc:date>
    </item>
  </channel>
</rss>

