# Google Ad attribution via Forms API submissions

**URL:** <https://community.hubspot.com/t/google-ad-attribution-via-forms-api-submissions/116893>\
**Category:** APIs & Integrations\
**Tags:** professional\
**Created:** [September 23, 2024, 4:58pm UTC](https://community.hubspot.com/t/google-ad-attribution-via-forms-api-submissions/116893 "2024-09-23T16:58:20Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![VGlava](https://avatars.discourse-cdn.com/v4/letter/v/8e8cbc/32.png) [@VGlava](https://community.hubspot.com/u/VGlava)\
**Post date:** [September 23, 2024, 4:58pm UTC](https://community.hubspot.com/t/google-ad-attribution-via-forms-api-submissions/116893/1 "2024-09-23T16:58:20Z")

</div>

Hi,

We have an existing HS landing page with an embedded form which is properly set up as Google Ads target. When leads submit their information via the HS form, the HS contact has proper Google Ad attribution.

We are trying to trigger the submission of this form via the Forms API (per [https://legacydocs.hubspot.com/docs/methods/forms/forms\_overview](https://legacydocs.hubspot.com/docs/methods/forms/forms_overview) and [https://legacydocs.hubspot.com/docs/methods/forms/submit\_form\_v3\_authentication](https://legacydocs.hubspot.com/docs/methods/forms/submit_form_v3_authentication)) to accomplish the same result, but from an application/form outside of HS.

**It is unclear based on the documentation and my search in the forums where we can provide the various Google Ad specific query params (url) within the POST body call to [https://api.hsforms.com/submissions/v3/integration/secure/submit/:portalId/:formGuid.](https://api.hsforms.com/submissions/v3/integration/secure/submit/:portalId/:formGuid.)**

For reference, the Google Ad query params would include:

- utm\_source

- utm\_medium

- utm\_campaign

- utm\_term

- hsa\_mt

- hsa\_net

and others.

Thanks!

---

<div class="post-metadata">

**Author:** ![Teun](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/teun/32/28739_2.png) [@Teun](https://community.hubspot.com/u/Teun)\
**Post date:** [September 23, 2024, 6:23pm UTC](https://community.hubspot.com/t/google-ad-attribution-via-forms-api-submissions/116893/2 "2024-09-23T18:23:50Z")

</div>

Hi @VGlava ,

Great question, I found this [post](https://community.hubspot.com/t5/APIs-Integrations/Sending-UTM-s-programmatically/td-p/799039?profile.language=es) that indicates that you can pass the UTM params through the context object in your API call:

```lia-code-sample
const formData = {
 context: {
 pageUri: 'https://examplepage.com?utm_campaign=my_campaign&utm_source=facebook&utm_medium=test',
 },
};

```

I haven’t tested it, but it might be worth a shot.
