APIs & Integrations

Víctor
Membro | Parceiro Ouro
Membro | Parceiro Ouro

Send data from external Form to Hubspot

I'm trying to send the data from an external form into a Hubspot form using this endpoint:

 

https://api.hsforms.com/submissions/v3/integration/submit/:portalId/:formGuid

I'm following the documentation from this link but I can't get the JS to work. I'm creating the function formv3() and calling it on submit with my site and form ID's but nothing happens. Looks like there is no need of authentication so I'm not sure if I'm missing any step, I didn't use my API key anywhere.

 

The form on HS and the data I'm trying to POST there as an example:

Vctor_0-1656685108168.png

 

      "fields": [
        {
      "objectTypeId": "0-1",
          "name": "email",
          "value": "example@example.com"
        },
        {
      "objectTypeId": "0-1",
          "name": "firstname",
          "value": "Jeff"
        }
      ],

 

Thank you for your time.

0 Avaliação positiva
2 Respostas 2
Jaycee_Lewis
Gerente da Comunidade
Gerente da Comunidade

Send data from external Form to Hubspot

Hey, @Víctor 👋  Thanks for sharing. The community will need more details to help understand the possible root causes here.

If possible, could you share:

  • A code example of your JavaScript?
  • A link to the form if it is on a live page or page that can be shared? Viewing the code in the inspector may be helpful for the community.

Thanks for the additional details! — Jaycee

 

linkedin

Jaycee Lewis

Developer Community Manager

Community | HubSpot

0 Avaliação positiva
Víctor
Membro | Parceiro Ouro
Membro | Parceiro Ouro

Send data from external Form to Hubspot

Hi Jaycee, thank you very much for your answer. Sure I'll share the code: https://jsfiddle.net/9tz6xbpr/

 

I know we aren't retrieveing the form data yet, we are just trying to make the submit send static data first. I removed our ID's aswell just to share it.

0 Avaliação positiva