Trying to see If I can add a Google Tag Manager (GTM) to my forms automatically using the API, to avoid missing it when duplicating form.
I tried the following:
1) Retrieve the form JSON object using
GET https://api.typeform.com/forms/:form_id
2) Modify the JSON received to add the "google_tag_manager" parameter with my tag ("GTM-MYTAG") into the "settings" part of the JSON. I saw on other forms that had the integration that this is the parameter that was added, so I figured out I will try to add it through the API.
3) Update the form using and the modified JSON
PUT https://api.typeform.com/forms/:form_id
The API replies with the modified JSON, without error. Furthermore, subsequent attempts to retrieve the form using the GET method show the modified form JSON object.
Yet, when looking at the Typeform in the user interface, it shows no GTM connection, and when visiting the form, no GTM pixel is loaded.
Am I missing something?