> ## Documentation Index
> Fetch the complete documentation index at: https://docs.tembo.io/llms.txt
> Use this file to discover all available pages before exploring further.

# Update user settings

> Merge user preference updates while preserving unrelated settings.



## OpenAPI

````yaml https://api.tembo.io/public-api/openapi/public patch /v1/users/{userId}/settings
openapi: 3.1.0
info:
  title: Tembo Public API
  description: >-
    Manage agents, sessions, repositories, and organization resources with the
    Tembo API.
  version: 1.0.0
servers:
  - url: https://api.tembo.io
    description: Tembo API
  - url: https://{deployment-origin}/api/public-api
    description: Self-hosted Tembo
    variables:
      deployment-origin:
        default: tembo.example.com
        description: Hostname of your self-hosted Tembo deployment
security: []
paths:
  /v1/users/{userId}/settings:
    patch:
      tags:
        - Users
      summary: Update user settings
      description: Merge user preference updates while preserving unrelated settings.
      operationId: updateUserSettings
      parameters:
        - in: path
          name: userId
          schema:
            type: string
            minLength: 1
            maxLength: 255
          required: true
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                autoRestartVm:
                  type: boolean
                defaultProjectId:
                  type:
                    - string
                    - 'null'
                  minLength: 1
                  maxLength: 255
                gpgKey:
                  type: string
                  maxLength: 32768
                includeTemboCommitAttribution:
                  type: boolean
                desktopNotificationsEnabled:
                  type: boolean
                desktopNotificationPreferences:
                  type: object
                  properties:
                    awaitingApproval:
                      type: boolean
                    pullRequestOpened:
                      type: boolean
                    pullRequestReviewRequested:
                      type: boolean
                  additionalProperties: false
                appearancePreferences:
                  type: object
                  properties:
                    appTheme:
                      type: string
                      enum:
                        - light
                        - dark
                        - system
                    accentTheme:
                      type: object
                      properties:
                        themeId:
                          type: string
                          maxLength: 255
                        customSurface:
                          type:
                            - string
                            - 'null'
                          maxLength: 4096
                        customAccent:
                          type:
                            - string
                            - 'null'
                          maxLength: 4096
                        customIntensity:
                          type: number
                          minimum: 0.25
                          maximum: 2
                        systemLight:
                          type: string
                          maxLength: 255
                        systemDark:
                          type: string
                          maxLength: 255
                      additionalProperties: false
                  additionalProperties: false
                appSidebarPreferences:
                  type: object
                  properties:
                    open:
                      type: boolean
                    sessionOwnerScope:
                      type: string
                      enum:
                        - mine
                        - team
                    sessionSortBy:
                      type: string
                      enum:
                        - createdAt
                        - updatedAt
                    sessionOrganization:
                      type: string
                      enum:
                        - list
                        - project
                    showArchivedSessions:
                      type: boolean
                    width:
                      type: number
                      minimum: 0
                      maximum: 10000
                    rightSidebar:
                      type: object
                      propertyNames:
                        type: string
                        minLength: 1
                        maxLength: 255
                      additionalProperties:
                        type: object
                        properties:
                          open:
                            type: boolean
                          width:
                            type: string
                            maxLength: 255
                        additionalProperties: false
                  additionalProperties: false
                diffPreferences:
                  type: object
                  properties:
                    style:
                      type: string
                      enum:
                        - unified
                        - split
                    indicators:
                      type: string
                      enum:
                        - classic
                        - bars
                        - none
                    overflow:
                      type: string
                      enum:
                        - scroll
                        - wrap
                    showLineNumbers:
                      type: boolean
                    expandUnchanged:
                      type: boolean
                    showFileTree:
                      type: boolean
                    fileTreePosition:
                      type: string
                      enum:
                        - left
                        - right
                    fileTreeView:
                      type: string
                      enum:
                        - list
                        - tree
                    lightTheme:
                      type: string
                      maxLength: 255
                    darkTheme:
                      type: string
                      maxLength: 255
                  additionalProperties: false
                dashboardPreferences:
                  type: object
                  properties:
                    taskFilters:
                      type: object
                      properties:
                        statusFilter:
                          type: array
                          items:
                            type: string
                            maxLength: 4096
                          maxItems: 100
                        sortBy:
                          type: string
                          enum:
                            - createdAt
                            - updatedAt
                        searchQuery:
                          type: string
                          maxLength: 4096
                        integrationType:
                          type: array
                          items:
                            type: string
                            maxLength: 4096
                          maxItems: 100
                        externalId:
                          type: string
                          maxLength: 4096
                        projectFilter:
                          type: array
                          items:
                            type: string
                            maxLength: 4096
                          maxItems: 100
                        authorFilter:
                          type: array
                          items:
                            type: string
                            maxLength: 4096
                          maxItems: 100
                        prStatusFilter:
                          type: array
                          items:
                            type: string
                            maxLength: 4096
                          maxItems: 100
                        automationFilter:
                          type: array
                          items:
                            type: string
                            maxLength: 4096
                          maxItems: 100
                      additionalProperties: false
                  additionalProperties: false
                composerPreferences:
                  type: object
                  properties:
                    lastSelectedRepositories:
                      type: array
                      items:
                        type: object
                        properties:
                          id:
                            type: string
                            maxLength: 4096
                          name:
                            type: string
                            maxLength: 4096
                          type:
                            type: string
                            maxLength: 255
                        required:
                          - id
                        additionalProperties: false
                      maxItems: 100
                  additionalProperties: false
                reviewPreferences:
                  type: object
                  properties:
                    fileSortMode:
                      type: string
                      enum:
                        - tree
                        - path-asc
                        - path-desc
                        - largest
                        - smallest
                    excludedFilePatterns:
                      type: array
                      items:
                        type: string
                        minLength: 1
                        maxLength: 255
                      maxItems: 100
                    sections:
                      type: object
                      propertyNames:
                        type: string
                        minLength: 1
                        maxLength: 255
                      additionalProperties:
                        type: boolean
                    hideBotComments:
                      type: boolean
                    layout:
                      type: object
                      properties:
                        focusChatHeight:
                          type: number
                          exclusiveMinimum: 0
                          maximum: 10000
                        activeTab:
                          type: string
                          maxLength: 255
                        activeViewMode:
                          type: string
                          maxLength: 255
                        focusChatOpen:
                          type: boolean
                        focusMode:
                          type: boolean
                        leftDesktopSidebarOpen:
                          type: boolean
                        leftDesktopSidebarWidth:
                          type: number
                          minimum: 0
                          maximum: 10000
                        rightDesktopSidebarOpen:
                          type: boolean
                        rightDesktopSidebarWidth:
                          type: number
                          minimum: 0
                          maximum: 10000
                      additionalProperties: false
                  additionalProperties: false
                diffLightTheme:
                  type: string
                  maxLength: 255
                diffDarkTheme:
                  type: string
                  maxLength: 255
                defaultAgent:
                  type:
                    - string
                    - 'null'
                  pattern: ^[^:]+:[^:]+(?::[^:]+)?$
                  maxLength: 255
                followUpBehavior:
                  type: string
                  enum:
                    - queue
                    - steer
              additionalProperties: false
      responses:
        '200':
          description: Update user settings
          content:
            application/json:
              schema:
                type: object
                properties:
                  autoRestartVm:
                    type: boolean
                  defaultProjectId:
                    type:
                      - string
                      - 'null'
                  gpgKey:
                    type: string
                  includeTemboCommitAttribution:
                    type: boolean
                  desktopNotificationsEnabled:
                    type: boolean
                  desktopNotificationPreferences:
                    type: object
                    properties:
                      awaitingApproval:
                        type: boolean
                      pullRequestOpened:
                        type: boolean
                      pullRequestReviewRequested:
                        type: boolean
                    additionalProperties: false
                  appearancePreferences:
                    type: object
                    properties:
                      appTheme:
                        type: string
                        enum:
                          - light
                          - dark
                          - system
                      accentTheme:
                        type: object
                        properties:
                          themeId:
                            type: string
                          customSurface:
                            type:
                              - string
                              - 'null'
                          customAccent:
                            type:
                              - string
                              - 'null'
                          customIntensity:
                            type: number
                          systemLight:
                            type: string
                          systemDark:
                            type: string
                        additionalProperties: false
                    additionalProperties: false
                  appSidebarPreferences:
                    type: object
                    properties:
                      open:
                        type: boolean
                      sessionOwnerScope:
                        type: string
                        enum:
                          - mine
                          - team
                      sessionSortBy:
                        type: string
                        enum:
                          - createdAt
                          - updatedAt
                      sessionOrganization:
                        type: string
                        enum:
                          - list
                          - project
                      showArchivedSessions:
                        type: boolean
                      width:
                        type: number
                      rightSidebar:
                        type: object
                        additionalProperties:
                          type: object
                          properties:
                            open:
                              type: boolean
                            width:
                              type: string
                          additionalProperties: false
                    additionalProperties: false
                  diffPreferences:
                    type: object
                    properties:
                      style:
                        type: string
                        enum:
                          - unified
                          - split
                      indicators:
                        type: string
                        enum:
                          - classic
                          - bars
                          - none
                      overflow:
                        type: string
                        enum:
                          - scroll
                          - wrap
                      showLineNumbers:
                        type: boolean
                      expandUnchanged:
                        type: boolean
                      showFileTree:
                        type: boolean
                      fileTreePosition:
                        type: string
                        enum:
                          - left
                          - right
                      fileTreeView:
                        type: string
                        enum:
                          - list
                          - tree
                      lightTheme:
                        type: string
                      darkTheme:
                        type: string
                    additionalProperties: false
                  dashboardPreferences:
                    type: object
                    properties:
                      taskFilters:
                        type: object
                        properties:
                          statusFilter:
                            type: array
                            items:
                              type: string
                          sortBy:
                            type: string
                            enum:
                              - createdAt
                              - updatedAt
                          searchQuery:
                            type: string
                          integrationType:
                            type: array
                            items:
                              type: string
                          externalId:
                            type: string
                          projectFilter:
                            type: array
                            items:
                              type: string
                          authorFilter:
                            type: array
                            items:
                              type: string
                          prStatusFilter:
                            type: array
                            items:
                              type: string
                          automationFilter:
                            type: array
                            items:
                              type: string
                        additionalProperties: false
                    additionalProperties: false
                  composerPreferences:
                    type: object
                    properties:
                      lastSelectedRepositories:
                        type: array
                        items:
                          type: object
                          properties:
                            id:
                              type: string
                            name:
                              type: string
                            type:
                              type: string
                          required:
                            - id
                          additionalProperties: false
                    additionalProperties: false
                  reviewPreferences:
                    type: object
                    properties:
                      fileSortMode:
                        type: string
                        enum:
                          - tree
                          - path-asc
                          - path-desc
                          - largest
                          - smallest
                      excludedFilePatterns:
                        type: array
                        items:
                          type: string
                      sections:
                        type: object
                        additionalProperties:
                          type: boolean
                      hideBotComments:
                        type: boolean
                      layout:
                        type: object
                        properties:
                          focusChatHeight:
                            type: number
                          activeTab:
                            type: string
                          activeViewMode:
                            type: string
                          focusChatOpen:
                            type: boolean
                          focusMode:
                            type: boolean
                          leftDesktopSidebarOpen:
                            type: boolean
                          leftDesktopSidebarWidth:
                            type: number
                          rightDesktopSidebarOpen:
                            type: boolean
                          rightDesktopSidebarWidth:
                            type: number
                        additionalProperties: false
                    additionalProperties: false
                  diffLightTheme:
                    type: string
                  diffDarkTheme:
                    type: string
                  defaultAgent:
                    type: string
                    pattern: ^[^:]+:[^:]+(?::[^:]+)?$
                  followUpBehavior:
                    type: string
                    enum:
                      - queue
                      - steer
                  codexConnected:
                    type: boolean
                  superGrokConnected:
                    type: boolean
                additionalProperties: false
        '400':
          description: >-
            Invalid request or missing required organization or user
            information.
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
                required:
                  - error
                additionalProperties: false
        '403':
          description: Forbidden
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
                required:
                  - error
                additionalProperties: false
        '404':
          description: User or connected account not found
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
                required:
                  - error
                additionalProperties: false
        '500':
          description: User operation failed
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
                required:
                  - error
                additionalProperties: false
      security:
        - apiKey: []
      x-codeSamples:
        - lang: typescript
          label: TypeScript SDK
          source: |
            import Tembo from '@tembo-io/sdk';

            const client = new Tembo();

            const setting = await client.users.settings.update('userId', {});
components:
  securitySchemes:
    apiKey:
      type: http
      scheme: bearer

````