Userfield Values

Last modified on September 11, 2023 at 2:13 pm

Resource URL

https://api.digitalchalk.com/dc/api/v5/users/{userId}/userfieldvalues

Overview

Userfield values are user-specific data entered into data fields which have been defined by your organization. Information about these data fields, such as the prompt, data type, category and public/private status, and constraints can be found by making the appropriate request to a userfields resource.

When a request is made for a userfield value for a user, the response is a single object representing all available data as key-value pairs. Each key is an id corresponding to the id of the userfield; the value is the user-specific data for that field. Only fields with a value set will be included. Even if a field is marked as required, the field will not appear in the response if the user has not yet provided a value (users are forced to fill in required userfields on their next login). That is, the value component of a key-value pair will never be null.

Field datatypes

Field typeJSON Data Type
Stringstring
Integernumber
Floatnumber
Datestring
Emailstring
Dropdownstring
Radio buttonsstring
Checkboxboolean (true indicates checked; false or null indicate unchecked)
Checkboxesarray of strings
True/falseboolean
Yes/nostring (the string value will be one of yes or no)

Use Case Examples

GET requests

OperationCallDescription
Retrieve All Userfield ValuesGET /dc/api/v5/users/{id}/userfieldvaluesRetrieve all userfield values for the user with the given id.

PUT requests

OperationCallDescription
Set a Userfield ValuePUT /dc/api/v5/users/{id}/userfieldvaluesAssign a userfield value on a user.
Clear a Userfield ValuePUT /dc/api/v5/users/{id}/userfieldvaluesRemove a userfield value from a user.

Reference