Skip to main content

adminUserPreferenceCreate

Create a preference for an administrative user.

The preference is created for the authenticated admin user unless the input names another one, which requires a role. A caller with a role that is not an admin user itself must name the admin user. A GLOBAL preference applies in every tenant. A TENANT preference applies only in the tenant of the request and cannot be created from the admin tenant. Type, key and scope together are unique per admin user.

Possible errors:

  • ADMIN_USER_PREFERENCE_ALREADY_EXISTS_ERROR: A preference with this type and key already exists in this scope; the identifier of the existing preference is returned in the error extensions
  • ADMIN_USER_PREFERENCE_SCOPE_ERROR: A TENANT preference was requested from the admin tenant
  • UNAUTHORIZED: The input names another admin user without the role to do so
  • ADMIN_USER_PREFERENCE_AUTH_ERROR: The request neither identifies an admin user nor carries a role
  • ADMIN_USER_PREFERENCE_CREATE_ERROR: Error occurred while creating the preference, including a missing or unknown admin user

AUTH: Role=[user.OWNER] OR (('user is authenticated') AND ('undefined'))

adminUserPreferenceCreate(
input: AdminUserPreferenceCreateInput!
): AdminUserPreference!

Arguments​

adminUserPreferenceCreate.input ● AdminUserPreferenceCreateInput! non-null input​

Input parameters for creating a preference.

Type​

AdminUserPreference object​

A single preference of an administrative user, such as the column layout of one table or the chosen theme. The value is opaque to the platform: its shape is owned by the client that stores it.