APIs & Integrations

Spinks
Member

Form submission v3

I’m working on integrating Umbraco forms with HubSpot to push form submissions into HubSpot forms via the API. I’ve come across the v2 API documentation for form submissions, which seems to provide a way to send form submissions.

 

However, I noticed that the v2 API is marked as old, and I can’t find equivalent documentation or endpoints for form submissions in v3. Does this mean HubSpot is moving away from recommending API-based form submissions? Or have I missed something in the v3 documentation?

 

If v2 is the only way to handle this, is it still safe to use for new projects, or are there alternatives HubSpot suggests?

 

Any guidance or recommendations would be greatly appreciated!

2 Replies 2
Nagarjoon
Member

Form submission v3

HubSpot currently recommends using the v2 Forms API for pushing form submissions, as there is no equivalent v3 endpoint specifically for form submissions. While the v2 API is labeled as older, it remains fully supported and safe to use for new projects. However, ensure you monitor for updates to HubSpot’s APIs, as they may introduce newer methods in the future.

If you're concerned about API longevity or best practices, consider using HubSpot's tracking code API to capture submissions directly on your website or explore third-party middleware options to manage the integration.

Cloudify can help with custom integration solutions to seamlessly connect Umbraco forms with HubSpot, ensuring reliability and alignment with your business need.

https://cloudify.biz/marketplace/products/hubspot-integrations

0 Upvotes
GRajput
Recognized Expert | Platinum Partner
Recognized Expert | Platinum Partner

Form submission v3

Hi @Spinks 

here is the curl that is working fine for me on the form submission

curl -X POST https://api.hsforms.com/submissions/v3/integration/submit/<portalId>/<formId> \
-H "Content-Type: application/json" \
-d '{
  "fields": [
    {
      "name": "email",
      "value": "example@example.com"
    },
    {
      "name": "firstname",
      "value": "John"
    },
    {
      "name": "lastname",
      "value": "Doe"
    }
  ],
  "context": {
    "hutk": "user-tracking-token",
    "pageUri": "https://www.example.com/contact",
    "pageName": "Contact Us"
  },
  "legalConsentOptions": {
    "consent": {
      "consentToProcess": true,
      "text": "I agree to allow Example Company to store and process my personal data.",
      "communications": [
        {
          "value": true,
          "subscriptionTypeId": 999,
          "text": "I agree to receive marketing communications."
        }
      ]
    }
  }
}'

 

I hope this will help you out. Please mark it as Solution Accepted and upvote to help another Community member.
Thanks!




Gaurav Rajput
Director, MarTech( Growth Natives)

Book a meeting


0 Upvotes