# Magento 2 Integration

**URL:** <https://community.hubspot.com/t/magento-2-integration/69288>\
**Category:** APIs & Integrations\
**Tags:** professional\
**Created:** [November 15, 2022, 2:50pm UTC](https://community.hubspot.com/t/magento-2-integration/69288 "2022-11-15T14:50:40Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![KMeher](https://avatars.discourse-cdn.com/v4/letter/k/ecc23a/32.png) [@KMeher](https://community.hubspot.com/u/KMeher)\
**Post date:** [November 15, 2022, 2:50pm UTC](https://community.hubspot.com/t/magento-2-integration/69288/1 "2022-11-15T14:50:40Z")

</div>

We have created a Magento 2 module for customer sync to Hubspot. Earlier it was working with an API key. Now it was not working with the private app as HubSpot no longer uses the API key.

HubSpot API Base Url - [https://api.hubapi.com/](https://api.hubapi.com/)

Endpoint - contacts/v1/contact

contacts/v1/lists

---

<div class="post-metadata">

**Author:** ![LeeBartelme](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/leebartelme/32/95647_2.png) [@LeeBartelme](https://community.hubspot.com/u/LeeBartelme)\
**Post date:** [November 16, 2022, 11:27pm UTC](https://community.hubspot.com/t/magento-2-integration/69288/2 "2022-11-16T23:27:13Z")

</div>

Can you provide more details when you say “it’s not working”. Are you getting an error? If so what is the error?

---

<div class="post-metadata">

**Author:** ![KMeher](https://avatars.discourse-cdn.com/v4/letter/k/ecc23a/32.png) [@KMeher](https://community.hubspot.com/u/KMeher)\
**Post date:** [November 17, 2022, 2:51pm UTC](https://community.hubspot.com/t/magento-2-integration/69288/3 "2022-11-17T14:51:42Z")

</div>

No error. No API call as well in private app. I think API service changed after private app implementation otherwise scope issue while creating private app. Let me know which scope we should tick for Magento 2 CMS.

---

<div class="post-metadata">

**Author:** ![KMeher](https://avatars.discourse-cdn.com/v4/letter/k/ecc23a/32.png) [@KMeher](https://community.hubspot.com/u/KMeher)\
**Post date:** [December 5, 2022, 6:02am UTC](https://community.hubspot.com/t/magento-2-integration/69288/4 "2022-12-05T06:02:50Z")

</div>

API response

[status] =\> error  
[message] =\> This hapikey doesn’t exist.  
[correlationId] =\> 6501b7f3-3fa0-4d0b-b56e-ee477e1cf309

---

<div class="post-metadata">

**Author:** ![LeeBartelme](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/leebartelme/32/95647_2.png) [@LeeBartelme](https://community.hubspot.com/u/LeeBartelme)\
**Post date:** [December 5, 2022, 1:28pm UTC](https://community.hubspot.com/t/magento-2-integration/69288/5 "2022-12-05T13:28:00Z")

</div>

It sounds like the hapikey you are using doesn’t exist. When you changed to using a private app, did you update the code/integration so that is uses a authorization header using the token? It sounds like maybe you just swapped the hapikey for the token.
