Deals API - Search deal using property

Hello

We are new to hubspot and need urgent help on below question:

We have created custom property for deals in hubspot and want to lookup & find deal based on this property value.

Example: we have a property called gp_id for deal and it has unique value for deal. We need API which can be called using gp_id and which would return deal_id.

Is any such API available. We tried below but these do not return the property gp_id:

GET /properties/v1/deals/properties

GET /properties/v2/:deal/properties

Kindly help to find.

Thanks.

Hi @adpaiker ,

You will found the information you aer looking for on The Deal endpoint documentation . Just run a request on

/crm/v3/objects/deals/search

And use filter on your custom field :

{
 "filterGroups":[
 {
 "filters":[
 {
 "value":"<YUR SEARCH VALUE>",
 "propertyName":"<YOUR CUSTOM FIELD>",
 "operator":"EQ"
 }
 ]
 }
 ],
 "sorts":[
 "string"
 ],
 "query":"string",
 "properties":[
 "string"
 ],
 "limit":0,
 "after":0
}

That helped. Thanks Quentin !!