Error 400 Delete Element of Deal Custom Card

TurchiniAxel
Member

Hello,

 

When i want to delete some element in my custom card, i have in error 400.

 

The error : POST https://api.hubspot.com/sales-objects/execution/v1/actions?portalId=7774557&clienttimeout=14000&hs_s... 400

 

My card action for delete : 

{
          "type": "CONFIRMATION_ACTION_HOOK",
          "confirmationMessage": "Are you sure you want to delete this ticket?",
          "confirmButtonText": "Yes",
          "cancelButtonText": "No",
          "httpMethod": "DELETE",
          "associatedObjectProperties": [
            "protected_account"
          ],
          "uri": `https://api.smart-brand.net/api/deal_cards/${card.id}?associatedObjectId=${req.query.associatedObjectId}&objectType=${req.query.associatedObjectType}&portalId=${req.query.portalId}&userEmail=${req.query.userEmail}`,
          "label": "Delete"
}
 
I try without "protected_account" in properties but same result.
0 Upvotes
1 Reply 1
TurchiniAxel
Member

Update : I resolve the problem by change my httpMethod DELETE by POST (and change my API routes in consequence)

But i dont know why the HTTP DELETE doesnt work.

Someone can help me ? It's work but it's not clean..

0 Upvotes