This allows you to update values on fields on your applicants forms. This is broadly similar to get_info, except that its scope is limited to updating fields and does not include system fields (anything which starts with an underscore, such as _usercart). For adding products see add_product.
string, integer, or array
These are the fields present in your forms. See the section "Fields" for more.
This prevents the user's forms from submitting. This is generally advised if you want to prevent the update from activating triggers that are set in your project. false will prevent the forms from submitting, but true is the default.
It is important to note that there are a number of behind-the-scenes validation actions that are occurring whenever you attempt to update a user via the API. To get an overview of the basic validation options for each type of field make sure to check out the section on fields.
There are three common scenarios in which an update call will be made, but no information will be updated for the user.
- If you attempt to update a user that does not exist in the project, the system will not update any information.
- If you attempt to update a user that does exist but the answer to the field (such as a multiple-choice answer; see more below) or the field itself does not exist, then the system will not update any information.
- Finally, if you attempt to update a user who does exist but they do not have the form that contains the field you are trying to update, then the system will not update any information.
As mentioned in the section on fields, multiple-choice fields should be sent in the API as an array of strings where a single answer update is an array of length one. When a string within this array is parsed, we first test whether the string matches any of the existing values within that field. If no match can be found, then the HTML is stripped from the string, and the entire string is converted to lowercase. If after this the string still doesn't match any of the values within your project, then the system would proceed to not update the value.
If a call is otherwise correct and you set submit_forms to false, then a few specific things happen: The value will save as expected, and the form on which the field exists will not submit for the user. The effect this has in practice is that it prevents subsequent triggers within forms, emails, products, etc. from reacting to the submission of the form. This being said, if there are any fields that are triggered to show within the form itself in response to the value you are updating, then those triggers will still activate. Generally this is not a big deal, and the emails, products, or subsequent forms are the things you're worried about activating.