Mass update marketo forms using Postman | Community
Skip to main content
New Participant
July 4, 2023
Solved

Mass update marketo forms using Postman

  • July 4, 2023
  • 2 replies
  • 4755 views

Hi,

 

We want to update our all marketo forms at once. We have come across this article​ about making this update in bulk via the API. For that we are using the Postman API platform. We connected Postman and our marketo instance, but the form is not getting updated. Please anybody who knows the process or step-by-step process please help us. 

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.
Best answer by Darshil_Shah1

Cool- you can use the values parameter and pass the array of JSON objects that contain field attributes. This would of course only work for the Select type fields. Make sure you pass the Content as application/x-www-form-urlencoded

 

values=[{"label":"Select...","value":"","isDefault":true,"selected":true}, {"label":"MR","value":"MR"}, {"label":"MS","value":"MS"}, {"label":"MRS","value":"MRS"}, {"label":"DR","value":"DR"}, {"label":"PROF","value":"PROF"}]

 

Make sure to get the field's id by this GET fields endpoint, and use this id as the path parameter in your original update fields endpoint. Please share your complete request format along with the error message you're seeing in the response if you're not able to update the field.

2 replies

SanfordWhiteman
New Participant
July 4, 2023

Like Darshil says, we don’t have enough info to help you yet.

  • What exactly are you trying to update on every form?
  • How are you getting all the form IDs?
  • What JSON payload are you sending?
  • What HTTP endopint are you contacting?
  • What’s the JSON response look like for Get Form By ID before you make the update vs. after you make the update?
  • Are you properly distinguishing between the Draft and Approved versions?
Darshil_Shah1
Community Manager
July 4, 2023

Using create/update form endpoints you can modify the form meta-data only. To modify the form fields, you should use the Form Fields endpoints. You can automate form updates in mass by writing a script that successively calls this endpoint for each form to make the corresponding form updates. Additionally, to make API requests to Marketo, you'd need an access_token, which you'd have to generate via the identity endpoint. The complete guide on generating the access_token using the identity endpoint and using it in the API calls is documented here. Also, it'd help if you could share more details on any specific errors/issues you're facing along with the endpoint/parameters/payload (if applicable)/response, etc. so we can provide more to-the-point assistance in troubleshooting the issue.

 

NihalAuthor
New Participant
July 7, 2023

We are trying to use Form-Fields endpoint : "/rest/asset/v1/form/{id}/field/{fieldId}.json".
We want to update the values list for a form field. This is a Country field and we want to add a new and update few country to the list.

Darshil_Shah1
Darshil_Shah1Accepted solution
Community Manager
July 7, 2023

Cool- you can use the values parameter and pass the array of JSON objects that contain field attributes. This would of course only work for the Select type fields. Make sure you pass the Content as application/x-www-form-urlencoded

 

values=[{"label":"Select...","value":"","isDefault":true,"selected":true}, {"label":"MR","value":"MR"}, {"label":"MS","value":"MS"}, {"label":"MRS","value":"MRS"}, {"label":"DR","value":"DR"}, {"label":"PROF","value":"PROF"}]

 

Make sure to get the field's id by this GET fields endpoint, and use this id as the path parameter in your original update fields endpoint. Please share your complete request format along with the error message you're seeing in the response if you're not able to update the field.