APIs & Integrations

dpiret
Member

How to get all stage a Deal has been through?

Hi there. How can get all stages that a particular Deal has been through? This would help understand, for instance, the path for lost deals. I can see that in the interface, but I have to go one by one, which is not what I am looking for. I need an aggregate analysis.
thanks
daniel

0 Upvotes
10 Replies 10
Derek_Gervais
HubSpot Alumni
HubSpot Alumni

How to get all stage a Deal has been through?

Hi @Jasdeep_Garcha,

Could you send me a direct message with the exact request URL you’re using, and the full response you get?

0 Upvotes
Jasdeep_Garcha
Member

How to get all stage a Deal has been through?

Hi @Derek_Gervais - that’s a typo. It’s part of my actual API key.

0 Upvotes
Derek_Gervais
HubSpot Alumni
HubSpot Alumni

How to get all stage a Deal has been through?

Hi @Jasdeep_Garcha,

Looks like there’s an f in between the api key and the &includeAssociations parameter. Can you post the response you’re getting with that request?

0 Upvotes
Jasdeep_Garcha
Member

How to get all stage a Deal has been through?

Hmmm – is anyone there?

0 Upvotes
Jasdeep_Garcha
Member

How to get all stage a Deal has been through?

@dadams do you have any insight here? or is there any additional context i can provide? still not able to use these query parameters using my api key as described.

0 Upvotes
Jasdeep_Garcha
Member

How to get all stage a Deal has been through?

Hi - I’ve given this a try with the following request curl https://api.hubapi.com/deals/v1/deal/paged?hapikey={{ api key }}f&includeAssociations=true&properties=dealname

I’m not seeing any properties in the response … manually verified a dealid for a dealname

The API documentation seems to be consistent with the thread here … but I wanted to verify whether there’s something I may be missing.

0 Upvotes
dpiret
Member

How to get all stage a Deal has been through?

I got it!. Thank you very much!

0 Upvotes
dpiret
Member

How to get all stage a Deal has been through?

Hello dadams,
Thank you very much for your reply. It looks like it doesn’t work or we are not understanding the results:

0 Upvotes
Dadams
HubSpot Employee
HubSpot Employee

How to get all stage a Deal has been through?

The propertiesWithHistory must use a deal property name. It can’t be used to filter records with specific values, so you’d need to pull all of your deals, include the propertiesWithHistory=dealstage to make sure that the returned deals have the data for the dealstage property, and then do any analysis or filtering on your side.

0 Upvotes
Dadams
HubSpot Employee
HubSpot Employee

How to get all stage a Deal has been through?

Hi @Daniel_Piret_ITM_Pla

If you’re pulling all of your deals using the API, you can use the propertiesWithHistory= parameter to get the data for a property and include all of the previous versions of that property.

https://api.hubapi.com/deals/v1/deal/paged?hapikey=demo&includeAssociations=true&limit=2&propertiesW...

0 Upvotes