# Deal to Contact association API returns wrong objectIDs

**URL:** <https://community.hubspot.com/t/deal-to-contact-association-api-returns-wrong-objectids/43051>\
**Category:** APIs & Integrations\
**Tags:** object\
**Created:** [August 28, 2021, 9:45pm UTC](https://community.hubspot.com/t/deal-to-contact-association-api-returns-wrong-objectids/43051 "2021-08-28T21:45:56Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![IP8](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/ip8/32/52558_2.png) [@IP8](https://community.hubspot.com/u/IP8)\
**Post date:** [August 28, 2021, 9:45pm UTC](https://community.hubspot.com/t/deal-to-contact-association-api-returns-wrong-objectids/43051/1 "2021-08-28T21:45:56Z")

</div>

I am trying to get contact associations with a given dealID and the API returns wrong contactIDs.

When I send

[https://api.hubapi.com/crm/v3/objects/deal/5771682053/associations/contact](https://api.hubapi.com/crm/v3/objects/deal/5771682053/associations/contact)

I get

{“results”:[{“id”:“1101”,“type”:“deal\_to\_contact”},{“id”:“1755”,“type”:“deal\_to\_contact”},{“id”:“2001”,“type”:“deal\_to\_contact”},{“id”:“2151”,“type”:“deal\_to\_contact”}]}

And thoses IDs are not contacts.

I also tried

/crm/v3/associations/deal/contact/batch/read and even version 1

V1/crm-associations/v1/associations/5771682053/HUBSPOT\_DEFINED/3 with the same result.

Deal to company associations work fine

---

<div class="post-metadata">

**Author:** ![TitiCuisset](https://avatars.discourse-cdn.com/v4/letter/t/8baadc/32.png) [@TitiCuisset](https://community.hubspot.com/u/TitiCuisset)\
**Post date:** [August 31, 2021, 3:02pm UTC](https://community.hubspot.com/t/deal-to-contact-association-api-returns-wrong-objectids/43051/2 "2021-08-31T15:02:48Z")

</div>

Hi @IP8

Thank you for reaching out.

I want to tag some of our experts on this - @JBeatty @himanshurauthan @tjoyce do you have any thoughts on this for @IP8 ?

Thank you!

Best

Tiphaine

---

<div class="post-metadata">

**Author:** ![himanshurauthan](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/himanshurauthan/32/53076_2.png) [@himanshurauthan](https://community.hubspot.com/u/himanshurauthan)\
**Post date:** [September 2, 2021, 11:25am UTC](https://community.hubspot.com/t/deal-to-contact-association-api-returns-wrong-objectids/43051/3 "2021-09-02T11:25:32Z")

</div>

Hello @IP8,

Can you please make sure that you are checking for the correct deal?

Because we are using this API a lot and it works as expected for us.

Regards,

---

<div class="post-metadata">

**Author:** ![JBeatty](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/jbeatty/32/52252_2.png) [@JBeatty](https://community.hubspot.com/u/JBeatty)\
**Post date:** [August 31, 2021, 4:17pm UTC](https://community.hubspot.com/t/deal-to-contact-association-api-returns-wrong-objectids/43051/4 "2021-08-31T16:17:15Z")

</div>

Hi @IP8,

I went ahead and made the same call on a test portal and got this response:

```lia-code-sample
{
 "results": [
 {
 "id": "6901",
 "type": "deal_to_contact"
 }
 ]
}

```

And looking at this response the “6901” is the ID of the assocaited contact. If you take those ID’s that you recieved and tried searching for them directly within the HubSpot search do see any of the contacts show up?

---

<div class="post-metadata">

**Author:** ![IP8](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/ip8/32/52558_2.png) [@IP8](https://community.hubspot.com/u/IP8)\
**Post date:** [September 2, 2021, 11:50am UTC](https://community.hubspot.com/t/deal-to-contact-association-api-returns-wrong-objectids/43051/5 "2021-09-02T11:50:57Z")

</div>

Yes, it all works fine now. It must be just me 🙄

Thanks for your help
