Last modified on September 11, 2023 at 2:02 pm
Overview
To update the required flag on a userfield, you can send an HTTP PUT request to the userfield URL with a JSON object containing a required property with the updated value. This property determines whether the end user must provide a value for this userfield when filling out the user information form. The value for required should be a boolean value, i.e. either true or false. It is a valid property for all userfield types except checkbox and message.
Note that you are not limited to updating one property at a time; all fields that are valid for a particular userfield type may be updated in a single request. All fields not specified will retain their value. See the Userfield Object Reference for a list of all the object’s fields.
Example
This example shows the request-response sequence when updating its required property.
Request
PUT /dc/api/v5/userfields/8da97a97a92efd18dcbc12876a4510e HTTP/1.1 Host: org.digitalchalk.com Content-type: application/json Accept: application/json { "required": true }
Response
HTTP/1.1 204 No Content