<?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: Missing OAuth scope to subscribe to webhook events in APIs &amp; Integrations</title>
    <link>https://community.hubspot.com/t5/APIs-Integrations/Missing-OAuth-scope-to-subscribe-to-webhook-events/m-p/360945#M35495</link>
    <description>&lt;P&gt;Hey&amp;nbsp;&lt;a href="https://community.hubspot.com/t5/user/viewprofilepage/user-id/138325"&gt;@ChrisNY&lt;/a&gt;,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I believe this is because you're using the portal hapikey key instead of the developer API key.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Since you're managing settings of your dev app webhook, could you try using your developer API keys and see if it works?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;For more details on how to access your developer API keys, you can reference this documentation:&amp;nbsp;&lt;A href="https://legacydocs.hubspot.com/docs/faq/developer-api-keys" target="_blank" rel="noopener"&gt;Developer API keys&lt;/A&gt;.&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Tue, 11 Aug 2020 03:48:59 GMT</pubDate>
    <dc:creator>WendyGoh</dc:creator>
    <dc:date>2020-08-11T03:48:59Z</dc:date>
    <item>
      <title>Missing OAuth scope to subscribe to webhook events</title>
      <link>https://community.hubspot.com/t5/APIs-Integrations/Missing-OAuth-scope-to-subscribe-to-webhook-events/m-p/360822#M35465</link>
      <description>&lt;P&gt;I'm backend developer integrating my company's website to our HubSpot account. I'm using the HS API to update our HS contacts &amp;amp; companies with changes from our website, no problem.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I also want to update our website data with changes made directly by our support staff on our HubSpot account. I use webhooks for that, with the OAUTH flow, etc, and that works when I manually subscribe to events through the HubSpot page for our account.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;However, I need to be able to create event subscriptions programmatically through the API. I think my code is good, but I get the scopes exception error:&lt;/P&gt;&lt;PRE&gt;"HubSpot\Client\Webhooks\ApiException: [403] Client error: `POST https://api.hubapi.com/webhooks/v3/xxx/subscriptions?hapikey=xxx` resulted in a `403 Forbidden` response:
{"status":"error","message":"This app hasn't been granted all required scopes to make this call. Read more about required scopes here: https://developers.hubspot.com/scopes."&lt;/PRE&gt;&lt;P&gt;I initially had just the "contacts" scope in my OAUTH configuration for the app, I deleted &amp;amp; re-created the URL &amp;amp; request in the application page with the additional scopes 'integration-sync', 'crm.import' &amp;amp; 'oauth' as well as 'contacts', regenerated the access &amp;amp; refresh tokens, but I still get the same error.&lt;/P&gt;&lt;P&gt;Am I missing a required scope, or am I missing a required step?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 10 Aug 2020 17:05:08 GMT</pubDate>
      <guid>https://community.hubspot.com/t5/APIs-Integrations/Missing-OAuth-scope-to-subscribe-to-webhook-events/m-p/360822#M35465</guid>
      <dc:creator>ChrisNY</dc:creator>
      <dc:date>2020-08-10T17:05:08Z</dc:date>
    </item>
    <item>
      <title>Re: Missing OAuth scope to subscribe to webhook events</title>
      <link>https://community.hubspot.com/t5/APIs-Integrations/Missing-OAuth-scope-to-subscribe-to-webhook-events/m-p/360945#M35495</link>
      <description>&lt;P&gt;Hey&amp;nbsp;&lt;a href="https://community.hubspot.com/t5/user/viewprofilepage/user-id/138325"&gt;@ChrisNY&lt;/a&gt;,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I believe this is because you're using the portal hapikey key instead of the developer API key.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Since you're managing settings of your dev app webhook, could you try using your developer API keys and see if it works?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;For more details on how to access your developer API keys, you can reference this documentation:&amp;nbsp;&lt;A href="https://legacydocs.hubspot.com/docs/faq/developer-api-keys" target="_blank" rel="noopener"&gt;Developer API keys&lt;/A&gt;.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 11 Aug 2020 03:48:59 GMT</pubDate>
      <guid>https://community.hubspot.com/t5/APIs-Integrations/Missing-OAuth-scope-to-subscribe-to-webhook-events/m-p/360945#M35495</guid>
      <dc:creator>WendyGoh</dc:creator>
      <dc:date>2020-08-11T03:48:59Z</dc:date>
    </item>
    <item>
      <title>Re: Missing OAuth scope to subscribe to webhook events</title>
      <link>https://community.hubspot.com/t5/APIs-Integrations/Missing-OAuth-scope-to-subscribe-to-webhook-events/m-p/361180#M35518</link>
      <description>&lt;P&gt;First, gotta say you guys set a high standard for great customer support. I submitted the same question to the hubspot community forum, and a support request ticket.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I got answers from the HubSpot team on both of them - two different answers, but together they solved my problem.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Ivan noted I needed to add the 'timeline' scope to my OAuth permissions. Wendy cleverly surmised I was using the portal API key (which I use to modify contacts &amp;amp; companies), instead of the developer API key, which I need to modify the WebHook event subscriptions.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;So now all works, thanks!&lt;/P&gt;</description>
      <pubDate>Tue, 11 Aug 2020 17:34:52 GMT</pubDate>
      <guid>https://community.hubspot.com/t5/APIs-Integrations/Missing-OAuth-scope-to-subscribe-to-webhook-events/m-p/361180#M35518</guid>
      <dc:creator>ChrisNY</dc:creator>
      <dc:date>2020-08-11T17:34:52Z</dc:date>
    </item>
  </channel>
</rss>

