Available properties to listen to on Line Item webhook
SOLVE
Instead of the back and forth below, you ARE able to do this via the UI, for some reason the various properties will just not populate in the dropdown. However, by putting the correct property name into the search box and pressing "enter" you can successfully create subscriptions to property changes of Line Items. Seems to just be an issue with the property options populating to the dropdown. For example, see "price" below
Available properties to listen to on Line Item webhook
SOLVE
Instead of the back and forth below, you ARE able to do this via the UI, for some reason the various properties will just not populate in the dropdown. However, by putting the correct property name into the search box and pressing "enter" you can successfully create subscriptions to property changes of Line Items. Seems to just be an issue with the property options populating to the dropdown. For example, see "price" below
I've come up against this a few times and the UI is a little misleading... You can create subscriptions to more than the list supplied (both default and custom properties). For instance I've created a webhook for anytime the "term" (hs_recurring_billling_period) is updated for a line item and it works just fine.
See the payload I get when the term is updated via the HubSpot UI:
In short anything you pull from GET /crm/v3/properties/line_items (Properties API) can be used to configure a webhook providing you include the interal name of the property when setting up the webhook via your app settings.
I actually thought of this and attempted to subscribe to other properties not visible in the UI via the api. However, despite my app key having access to every scope possible, I still get a scope error when trying to edit webhooks via api. How were you able to create the subscriptions to other properties? If via api, do you know what scopes are required to access those endpoints?
"message": "The scope needed for this API call isn't available for public use. If you have questions, contact support or post in our developer forum."
I know as per the documentation here the "e-commerce" scope is defined as giving access to "Products and line items endpoints". However it also applies to when you are configuring a webhook for a Line item. For instance when I was creating a webhook via the UI (as opposed to the API) I was prompted to add the e-commerce scope. See the screenshot below. It also specifies that it's a required scope from the scopes listed in this table here .
Once I set the scope up, activated the webhook and re-installed my app I started seeing events coming from HubSpot to my endpoint. (as per screenshot in my original post).
When viewing or editing webhook subscriptions via the Webhook API you just use developer portal API key. You do however need to make sure you've configured your scopes for the app from within the app settings interface (auth tab). See mine below:
Providing you've the appropriate scopes in place dependent on the type of object(s) your subscriptions are going to be configured for you can retrieve webhooks making a GET as per below:
Available properties to listen to on Line Item webhook
SOLVE
Thank @coldrickjack for taking the time to help with this. I think the issue may be that I was attempting to use a private app, and private app webhook subscriptions can not be edited by api currently. There is a little disclaimer here: https://developers.hubspot.com/docs/api/webhooks
"
Please note:
Webhook support for private apps iscurrently in beta. Note that during this beta, webhook settings can only be edited in the in-app settings for your private app, and cannot currently be edited through the API."