# Source for deals created via the API

**URL:** <https://community.hubspot.com/t/source-for-deals-created-via-the-api/35384>\
**Category:** APIs & Integrations\
**Tags:** companies, object, contacts\
**Created:** [April 12, 2021, 9:13pm UTC](https://community.hubspot.com/t/source-for-deals-created-via-the-api/35384 "2021-04-12T21:13:26Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![jonsakas](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/jonsakas/32/31184_2.png) [@jonsakas](https://community.hubspot.com/u/jonsakas)\
**Post date:** [April 12, 2021, 9:13pm UTC](https://community.hubspot.com/t/source-for-deals-created-via-the-api/35384/1 "2021-04-12T21:13:26Z")

</div>

We have a server API integration that creates deals, contacts, and companies based on some actions happening on our website. When this happens, these objects are created with an original source type of “Offline sources”. My CRM team is hoping we can populate these object source with the proper data.

After some research, it seems like some users have been able to resolve this issue for contacts specifically by using the Forms API and passing context.hutk with the hubspotutk cookie.

Because we’re using the contacts, companies, and deals APIs using the hubspot/api-client package, and have no other issues except the object source, we’d prefer to not use the forms API and try to hack a solution together from that.

Does anyone know if it is possible to use the hubspotutk cookie manually with these other APIs? Either directly (in the create/update requests), or indirectly using an association?

---

<div class="post-metadata">

**Author:** ![dennisedson](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/dennisedson/32/28044_2.png) [@dennisedson](https://community.hubspot.com/u/dennisedson)\
**Post date:** [April 13, 2021, 6:19pm UTC](https://community.hubspot.com/t/source-for-deals-created-via-the-api/35384/2 "2021-04-13T18:19:37Z")

</div>

@tjoyce , dear sir, how would you tackle this question?

---

<div class="post-metadata">

**Author:** ![tjoyce](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/tjoyce/32/88832_2.png) [@tjoyce](https://community.hubspot.com/u/tjoyce)\
**Post date:** [April 14, 2021, 12:21pm UTC](https://community.hubspot.com/t/source-for-deals-created-via-the-api/35384/3 "2021-04-14T12:21:59Z")

</div>

If I’m not mistaken @jonsakas - You can use the forms API just to pass the email address to HS and get the contact ready to recieve more data… You don’t need to pass anything else, but I’m hoping that at least pushing the email address into the portal first and then you should be able to sync the contact instead of create the contact.
