Stay organized with collections
Save and categorize content based on your preferences.
Version 4.0.25.14 (latest)
Create a new user attribute
Permission information for a user attribute is conveyed through the can and user_can_edit fields.
The user_can_edit field indicates whether an attribute is user-editable anywhere in the application.
The can field gives more granular access information, with the set_value child field indicating whether
an attribute's value can be set by Setting the User Attribute User Value.
Note: name and label fields must be unique across all user attributes in the Looker instance.
Attempting to create a new user attribute with a name or label that duplicates an existing
user attribute will fail with a 422 error.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Hard to understand","hardToUnderstand","thumb-down"],["Incorrect information or sample code","incorrectInformationOrSampleCode","thumb-down"],["Missing the information/samples I need","missingTheInformationSamplesINeed","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-08-20 UTC."],[],[],null,["# Create User Attribute\n\nVersion 4.0.25.14 (latest)\n\n### Create a new user attribute\n\nPermission information for a user attribute is conveyed through the `can` and `user_can_edit` fields.\nThe `user_can_edit` field indicates whether an attribute is user-editable *anywhere* in the application.\nThe `can` field gives more granular access information, with the `set_value` child field indicating whether\nan attribute's value can be set by [Setting the User Attribute User Value](/looker/docs/reference/looker-api/latest/methods/User/set_user_attribute_user_value).\n\nNote: `name` and `label` fields must be unique across all user attributes in the Looker instance.\nAttempting to create a new user attribute with a name or label that duplicates an existing\nuser attribute will fail with a 422 error.\n\nRequest\n-------\n\nPOST /user_attributes \nDatatype \nDescription \nRequest \nHTTP Request \nbody \nHTTP Body \nExpand HTTP Body definition... \nbody \n[UserAttribute](/looker/docs/reference/looker-api/latest/types/UserAttribute) \nUser Attribute\nExpand UserAttribute definition... \ncan \n*lock* \nobject \nOperations the current user is able to perform on this object \nid \n*lock* \nstring \nUnique Id \nname \nstring \nName of user attribute \nlabel \nstring \nHuman-friendly label for user attribute \ntype \nstring \nType of user attribute (\"string\", \"number\", \"datetime\", \"yesno\", \"zipcode\", \"advanced_filter_string\", \"advanced_filter_number\") \ndefault_value \nstring \nDefault value for when no value is set on the user \nis_system \n*lock* \nboolean \nAttribute is a system default \nis_permanent \n*lock* \nboolean \nAttribute is permanent and cannot be deleted \nvalue_is_hidden \nboolean \nIf true, users will not be able to view values of this attribute \nuser_can_view \nboolean \nNon-admin users can see the values of their attributes and use them in filters \nuser_can_edit \nboolean \nUsers can change the value of this attribute for themselves \nhidden_value_domain_whitelist \nstring \nDestinations to which a hidden attribute may be sent. Once set, cannot be edited. \nquery \nHTTP Query \nExpand HTTP Query definition... \nfields \nstring \nRequested fields.\n\nResponse\n--------\n\n### 200: User Attribute\n\nDatatype \nDescription \n(object) \n[UserAttribute](/looker/docs/reference/looker-api/latest/types/UserAttribute) \ncan \n*lock* \nobject \nOperations the current user is able to perform on this object \nid \n*lock* \nstring \nUnique Id \nname \nstring \nName of user attribute \nlabel \nstring \nHuman-friendly label for user attribute \ntype \nstring \nType of user attribute (\"string\", \"number\", \"datetime\", \"yesno\", \"zipcode\", \"advanced_filter_string\", \"advanced_filter_number\") \ndefault_value \nstring \nDefault value for when no value is set on the user \nis_system \n*lock* \nboolean \nAttribute is a system default \nis_permanent \n*lock* \nboolean \nAttribute is permanent and cannot be deleted \nvalue_is_hidden \nboolean \nIf true, users will not be able to view values of this attribute \nuser_can_view \nboolean \nNon-admin users can see the values of their attributes and use them in filters \nuser_can_edit \nboolean \nUsers can change the value of this attribute for themselves \nhidden_value_domain_whitelist \nstring \nDestinations to which a hidden attribute may be sent. Once set, cannot be edited.\n\n### 400: Bad Request\n\nDatatype \nDescription \n(object) \n[Error](/looker/docs/reference/looker-api/latest/types/Error) \nmessage \n*lock* \nstring \nError details \ndocumentation_url \n*lock* \nstring \nDocumentation link\n\n### 404: Not Found\n\nDatatype \nDescription \n(object) \n[Error](/looker/docs/reference/looker-api/latest/types/Error) \nmessage \n*lock* \nstring \nError details \ndocumentation_url \n*lock* \nstring \nDocumentation link\n\n### 409: Resource Already Exists\n\nDatatype \nDescription \n(object) \n[Error](/looker/docs/reference/looker-api/latest/types/Error) \nmessage \n*lock* \nstring \nError details \ndocumentation_url \n*lock* \nstring \nDocumentation link\n\n### 422: Validation Error\n\nDatatype \nDescription \n(object) \n[ValidationError](/looker/docs/reference/looker-api/latest/types/ValidationError) \nmessage \n*lock* \nstring \nError details \nerrors \n[ValidationErrorDetail](/looker/docs/reference/looker-api/latest/types/ValidationErrorDetail)\\[\\] \nExpand ValidationErrorDetail definition... \nfield \n*lock* \nstring \nField with error \ncode \n*lock* \nstring \nError code \nmessage \n*lock* \nstring \nError info message \ndocumentation_url \n*lock* \nstring \nDocumentation link \ndocumentation_url \n*lock* \nstring \nDocumentation link\n\n### 429: Too Many Requests\n\nDatatype \nDescription \n(object) \n[Error](/looker/docs/reference/looker-api/latest/types/Error) \nmessage \n*lock* \nstring \nError details \ndocumentation_url \n*lock* \nstring \nDocumentation link\n\nExamples\n--------\n\n### Kotlin\n\n\n### TypeScript"]]