---
title: "Update a user attribute"
method: PATCH
path: "/v2/user-attributes/{userAttributeId}"
tags: ["User attributes"]
---

# Update a user attribute

`PATCH /v2/user-attributes/{userAttributeId}`

## Request

- Base URL: `https://api.sigmacomputing.com`
- URL: `https://api.sigmacomputing.com/v2/user-attributes/{userAttributeId}`
- Auth: HTTP bearer

Update the name, description, or default value of a user attribute. Only the fields included in the request are changed.

  ### Usage notes
  - Retrieve the **userAttributeId** by calling the [/v2/user-attributes](https://help.sigmacomputing.com/reference/list-user-attributes) endpoint.
  - Sigma-managed user attributes, such as /`home_page/` cannot be renamed.

## Path parameters

- `userAttributeId` string, required

## Request body

- object
  - `userAttributeName` string: Name of the user attribute.
  - `description` string: Description of the user attribute.
  - `defaultValue` V2UserAttributesUserAttributeIdPatchRequestBodyContentApplicationJsonSchemaDefaultValue: Default value of the user attribute. Pass null to clear the current default value.
    - `type` 'string', required: Type of user attribute.
    - `val` string, required: Value of the user attribute.

## Response `200`

The response body.

- UserAttributesUpdateUserAttributeResponse200
  - `userAttributeId` string, required: Unique identifier of the user attribute.
  - `name` string, required: Name of the user attribute.
  - `createdBy` string, required: The identifier of the user who created this object.
  - `updatedBy` string, required: The identifier of the user or process that last updated this object.
  - `createdAt` string, date-time, required: When the object was created.
  - `updatedAt` string, date-time, required: When the object was last updated.
  - `description` string, nullable: Description of the user attribute.
  - `defaultValue` V2UserAttributesUserAttributeIdPatchResponsesContentApplicationJsonSchemaDefaultValue: Default value of the user attribute.
    - `type` 'string', required: Type of user attribute.
    - `val` string, required: Value of the user attribute.

---

[API](https://skmtc.dev/sigmacomputing/apis/sigma-rest-api.md) - [All operations](https://skmtc.dev/sigmacomputing/apis/sigma-rest-api/llms.txt) - [OpenAPI document](https://skmtc.dev/sigmacomputing/apis/sigma-rest-api/revisions/fb6036208c49?raw)
