APIs & Integrations

mdare_usablenet
Member

Forms Api v3 - Captcha Handling

SOLVE

Hello,

I followed the post: https://community.hubspot.com/t5/APIs-Integrations/Forms-Api-Captcha-Handling/m-p/248803/highlight/f... and I tried to upgrade to v3 but I still receive the reCAPTCHA error message by API

errors": [
    {
      "message": "Form '********' can't receive API submissions as Captcha (SPAM prevention) is enabled.",
      "errorType": "FORM_HAS_RECAPTCHA_ENABLED"
    }
  ],

By the previous comments, I understood the v3 works with reCAPTCHA enabled but I don't know what I wrong. Could you help me?

 

URL https://api.hsforms.com/submissions/v3/integration/submit/:***/:***

BODY:

{
  "submittedAt": "1582798776000",
  "skipValidation": true,
  "fields": [
    {
      "name": "firstname",
      "value": "test"
    },
    {
      "name": "lastname",
      "value": "test"
    },
    {
      "name": "company",
      "value": "Test"
    },
    {
      "name": "email",
      "value": "****"
    }
  ],
  "context": {
	"hutk": "***********",
        "pageUri": "test.com",
        "pageName": "test page",
        "ipAddress": "**.**.**.**"
  }
}

Thanks,

Marco

0 Upvotes
1 Accepted solution
Willson
Solution
HubSpot Employee
HubSpot Employee

Forms Api v3 - Captcha Handling

SOLVE

Hi @mdare_usablenet 

 

To confirm, this issue is being encountered due to the fact that Captcha is enabled for the form you're attempting to pass submissions to via the API. 

 

We do not support the use of Captcha when using the v2 or v3 endpoints. However, if you wish to use Captcha services, you can have these embedded on the page itself, not using the HubSpot functionality and this will work fine as we do not process any validation for incoming data. It is only once the data has been received that we process validation and in this case return 400 errors with the following:

{"status":"error","message":"The request is not valid","correlationId":"xxxx","errors":[{"message":"Form 'FORM_GUID' can't receive API submissions as Captcha (SPAM prevention) is enabled.","errorType":"FORM_HAS_RECAPTCHA_ENABLED"}],"requestId":"xxxx"}

Also, to touch on the Forum post you linked, the Solution that is marked there does not confirm that this should work, rather it states that the v3 endpoint is more flexible in it's functionality but it would still require investigation. 

 

I hope this helps!

Product Manager @ HubSpot

View solution in original post

22 Replies 22
JMarx
Participant

Forms Api v3 - Captcha Handling

SOLVE

It would be great if we could bypass recaptcha when using the API. 

0 Upvotes
MSkafte
Member

Forms Api v3 - Captcha Handling

SOLVE

+1 - This is very unfortunate. Please make it work.

0 Upvotes
Tunch
Contributor

Forms Api v3 - Captcha Handling

SOLVE

@DavidVendia No unfortunately there isn't.. I believe that Hubspot is forcing us to not be able to do this because they'd rather have you do a follow up email through their Automation Workflows, which however you can only do if you have their Marketing Professional package ($800/month).

 

That's the only logical thing I can point to because this design is so bad that it makes no sense 

DavidVendia
Member

Forms Api v3 - Captcha Handling

SOLVE

+1 to this.

This is also a problem we are seeing. Spent a great deal of time integrating the Form API into our site setup and when I enable a "follow up" email everything breaks because of the forced captcha.

The form on our site is not an embedded HubSpot form, it's a custom form that pings a backend that uses the hubspot form API to submit the form submission (for conversions) in hubspot.

Is there any way to use follow up email functionality while using the form API? 

 

Thanks

BMarini
Participant

Forms Api v3 - Captcha Handling

SOLVE

+1 — Really there is no way to use the follow-up email from API submission? 😕

Willson
Solution
HubSpot Employee
HubSpot Employee

Forms Api v3 - Captcha Handling

SOLVE

Hi @mdare_usablenet 

 

To confirm, this issue is being encountered due to the fact that Captcha is enabled for the form you're attempting to pass submissions to via the API. 

 

We do not support the use of Captcha when using the v2 or v3 endpoints. However, if you wish to use Captcha services, you can have these embedded on the page itself, not using the HubSpot functionality and this will work fine as we do not process any validation for incoming data. It is only once the data has been received that we process validation and in this case return 400 errors with the following:

{"status":"error","message":"The request is not valid","correlationId":"xxxx","errors":[{"message":"Form 'FORM_GUID' can't receive API submissions as Captcha (SPAM prevention) is enabled.","errorType":"FORM_HAS_RECAPTCHA_ENABLED"}],"requestId":"xxxx"}

Also, to touch on the Forum post you linked, the Solution that is marked there does not confirm that this should work, rather it states that the v3 endpoint is more flexible in it's functionality but it would still require investigation. 

 

I hope this helps!

Product Manager @ HubSpot
kennethbrenes
Contributor

Forms Api v3 - Captcha Handling

SOLVE

Hi @Willson 

Is there a way to add more security in those forms? I mean, to avoid bots submissions what is the best practice around?

Thanks!

cellomanpierce
Member

Forms Api v3 - Captcha Handling

SOLVE

+1, I was using the api to handle custom form submissions, and also want to be able to use the follow-up email functionality and this is obviously blocking that currently

babajee911
Participant

Forms Api v3 - Captcha Handling

SOLVE

+1. This is weird not able to use the follow up email feature with API option. 

Mubanga
Participant

Forms Api v3 - Captcha Handling

SOLVE

+1 we would like to do follow-up emails via API submissions too

mdare_usablenet
Member

Forms Api v3 - Captcha Handling

SOLVE

Hi @Willson


Thanks for the feedback, unfortunately, we cannot use the form embedded because we had to create a custom field validation to support the accessibility.

We disabled the Captcha and we will migrate the embedded form to API.


Thanks,

Marco Da Re

0 Upvotes
Willson
HubSpot Employee
HubSpot Employee

Forms Api v3 - Captcha Handling

SOLVE

Thanks for the update @mdare_usablenet - I'll go ahead and flag this thread as resolved for now but feel free to get back to me should you have any issues in relation to migrating to the API.

Product Manager @ HubSpot
0 Upvotes
joaobelo
Member

Forms Api v3 - Captcha Handling

SOLVE

Hi @Willson 
I'm having an issue that's related to this.

My issue is that I need my form to use the form API instead of the embeded one, and be able to use the follow-up email functionality. The problem is that to use the follow-up email functionality, it's required that we have reCaptcha enabled.

 

Is there a way I can use the follow-up email functionality and (not embeded) API forms?

Tunch
Contributor

Forms Api v3 - Captcha Handling

SOLVE

@Willson We're having this same issue where we want to be able to use the follow up email function but we have it setup through the Forms API, which doesn't work when reCaptcha is enabled. We don't need to have reCaptcha enabled on the Hubspot Forms side because we have it already going on our website so it's redundant to do it twice. Why is Hubspot forcing us to use reCaptcha when we don't even need it and not allowing us to use the forms api?

Willson
HubSpot Employee
HubSpot Employee

Forms Api v3 - Captcha Handling

SOLVE

Hi @Tunch 

 

In order to assist here, I'd need more information on the page, where you're seeing the error and what the error is specifically pointing to. Could you provide this so we can take a look?


Thanks

Product Manager @ HubSpot
0 Upvotes
joaobelo
Member

Forms Api v3 - Captcha Handling

SOLVE

Hi again @Willson 

 

So the steps to replicate are:

- create a form on hubspot.

- use something like Postman to test the API (so you don't have to make an actual form to submit).

- if you insert the information correctly, the POST will work and a new entry will show up on the form submissions.

- when you have everything working, edit the form, and add a follow up email.

This will trigger the form to require the captcha (that can not be disabled while you have any follow up email).

- back to Postman, try submiting again. This will fail with an error message saying:

 

{"status":"error","message":"The request is not valid","correlationId":"xxxxxxx-xxxxx-xxxxxxx","errors":[{"message":"Form 'xxxxxxx-xxxxxx-xxxx-xxxxxxx' can't receive API submissions as Captcha (SPAM prevention) is enabled.","errorType":"FORM_HAS_RECAPTCHA_ENABLED"}],"requestId":"xxxxxx-xxxxx-xxxxx-xxxxxx"}

This is clearly a blocker on hubspot's end. Would it be possible to make the captcha optional for API forms?

davidsfreunde
Participant

Forms Api v3 - Captcha Handling

SOLVE

We would also like to have this feature enabled. We want to use the HubSpot Form Submission API including Captcha + Follow Up Mails without having to embed the HubSpot form. +1

Tunch
Contributor

Forms Api v3 - Captcha Handling

SOLVE

^Exactly what @joaobelo  said above. I would be more than happy to jump on a Zoom call and show you what is going on if you need more clarification as well @Willson 

Willson
HubSpot Employee
HubSpot Employee

Forms Api v3 - Captcha Handling

SOLVE

Hi @Tunch@joaobelo,

 

Thanks for the clarification with that, I am on the same page now. 

However, this issue goes back to my original point. The Forms API does not support Captcha and this is a required step in order to use our Follow-up tool for Forms within HubSpot. 

 

In this case, it means we cannot use our Follow-up tool with the Forms API and an alternative/external option is required. 

 

I hope this helps!

Product Manager @ HubSpot
0 Upvotes
groves
Participant

Forms Api v3 - Captcha Handling

SOLVE

Hi @Willson, what alternatives could we use for this? We need to submit forms using the Forms API and send a follow-up email afterwards.

0 Upvotes