You can read more about modeling preferences and preferences in general in the Modeling Preferences guide.
In the following examples you'll see how to integrate preferences into your backend codebase:
You can retrieve the users preferences using the
preferences.get method. Please note,
that even if the preferences are not set for the user you will receive a
PreferenceSet back (which will be empty).
You can update a users entire preference set using the
preferences.set method. This will
overwrite any existing preferences set for the user:
The preference API can also be invoked from the front-end, providing you have authenticated a user first and have a valid API token. Please note: only the current users preferences can be set from the client.
Preferences can also be updated from the client: