Use webhook with api_token & id

  • 2 December 2020
  • 1 reply
  • 30 views

Badge

Hi there,
Would like to pass all my form leads to a CRM system using webhook. But I couldn’t make it work. It only works under following custom HTML.

<form action="https://abc.com.my/api/api_case_submit.php"  id="myForm" method="post">
<input name="api_id" type="text" value="idcode">
<input name="api_token" type="text" value="tokenkey">
<input name="name" type="text" value="test12553 asfdsfdsf">
<input name="contact" type="text" value="012356464799">
<input name="email" type="text" value="abc11safdsf@gmail.com">
<input name="address" type="text" value="123212312,123123423123,23213,21321313,gfdgfdg">
<input name="product_name" type="text" value="PRODUCTNAME">
<input name="submit" type="submit" value="submit" />
</form>

I have tried both following method in the webhook still not work for me…

  1. POST URL "https://abc.com.my/api/api_case_submit.php?api_id=xxxx&api_token=xxxx (RESULT:ERROR)
  2. POST URL “https://abc.com.my/api/api_case_submit.php
    place api_id & api_token in the custom fields
    (RESULT:ERROR)

What would be the correct way to work this out?


1 reply

Userlevel 7
Badge +3

Hey @EddiejrWong,

The HTML you’ve shared seems to be from another form on another page. Just because you have an endpoint (api_case_submit.php) that doesn’t automatically mean that end point can accept webhooks.

Further more, even if it can accept webhooks, it would probably need the data in a specific format.

Last but not least, I see a field for an api_token. Tokens are usually generated when they are needed and can expire.

You should contact your CRM vendor and ask for detailed documentation on how to send leads with a webhook.

Based on my experience, in 95% of the cases, you would need to introduce a middle step, that would accept the webhook from Unbounce, authenticate with your CRM and forward the form’s data.

Best,
Hristian

Reply