APIs & Integrations

lchandler
Member

Problem Creating Deal via API

SOLVE

Hello Hubspot Community,

 

I'm running into an issue when trying to create a new deal via the Deals API.

 

I'm making a post to https://api.hubapi.com/deals/v1/deal?hapikey=my_key_here containing the following data:

 

{'properties': [{'value': 'description here', 'name': 'description'}, {'value': 'test - New Inquiry', 'name': 'dealname'}, {'value': 'appointmentscheduled', 'name': 'dealstage'}, {'value': None, 'name': 'hubspot_owner_id'}, {'value': None, 'name': 'pipeline'}]}

 

and receiving a 200 response. The response contains a dealId, but when I go to app.hubspot.com to view deals (which I'm accessing via the Sales menu dropdown), the new deal does not show up in the list, and can't be found by searching either deal name or deal ID. 

 

I've made sure the POST content-type is correct; there are no associationCreateFailures being returned in the response. Any help figuring out where this is going wrong would be much appreciated. 

 

Thanks!

0 Upvotes
1 Accepted solution
lchandler
Solution
Member

Problem Creating Deal via API

SOLVE

@WendyGoh 

 

I actually just discovered the problem - our key got changed somehow, ha. Everything's working now; case closed.

 

Thank you for getting back to me, though!

View solution in original post

0 Upvotes
2 Replies 2
WendyGoh
HubSpot Employee
HubSpot Employee

Problem Creating Deal via API

SOLVE

Hey @lchandler,

 

That's strange. In order for me to troubleshoot this, do you mind sharing with me the following:

 

1. The portal ID that you're attempting to create a deal on

2. The 200 response body that you received (which would include the portal Id and the deal Id) 

0 Upvotes
lchandler
Solution
Member

Problem Creating Deal via API

SOLVE

@WendyGoh 

 

I actually just discovered the problem - our key got changed somehow, ha. Everything's working now; case closed.

 

Thank you for getting back to me, though!

0 Upvotes