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

# PUT /api/admin/user-properties/

> Create or update a user property.



## OpenAPI

````yaml put /api/admin/user-properties/
openapi: 3.1.0
info:
  title: Tranthor API
  description: Tranthor API Swagger Documentation
  version: 0.0.1
servers: []
security: []
paths:
  /api/admin/user-properties/:
    put:
      tags:
        - User Properties
      description: Create or update a user property.
      requestBody:
        content:
          application/json:
            schema:
              type: object
              allOf:
                - type: object
                  properties:
                    id:
                      type: string
                    workspaceId:
                      type: string
                    definition:
                      anyOf:
                        - type: object
                          properties:
                            type:
                              type: string
                              enum:
                                - Id
                          required:
                            - type
                        - type: object
                          properties:
                            type:
                              type: string
                              enum:
                                - AnonymousId
                          required:
                            - type
                        - type: object
                          properties:
                            type:
                              type: string
                              enum:
                                - Group
                            entry:
                              type: string
                            nodes:
                              type: array
                              items:
                                anyOf:
                                  - type: object
                                    properties:
                                      id:
                                        type: string
                                      type:
                                        type: string
                                        enum:
                                          - AnyOf
                                      children:
                                        type: array
                                        items:
                                          type: string
                                    required:
                                      - id
                                      - type
                                      - children
                                  - anyOf:
                                      - type: object
                                        properties:
                                          id:
                                            type: string
                                          type:
                                            type: string
                                            enum:
                                              - Trait
                                          path:
                                            type: string
                                        required:
                                          - type
                                          - path
                                      - type: object
                                        properties:
                                          id:
                                            type: string
                                          type:
                                            type: string
                                            enum:
                                              - Performed
                                          event:
                                            type: string
                                          path:
                                            type: string
                                          properties:
                                            type: array
                                            items:
                                              type: object
                                              properties:
                                                path:
                                                  type: string
                                                operator:
                                                  type: object
                                                  properties:
                                                    type:
                                                      type: string
                                                      enum:
                                                        - Equals
                                                    value:
                                                      type: string
                                                  required:
                                                    - type
                                                    - value
                                              required:
                                                - path
                                                - operator
                                        required:
                                          - type
                                          - event
                                          - path
                                      - type: object
                                        properties:
                                          id:
                                            type: string
                                          type:
                                            type: string
                                            enum:
                                              - File
                                          name:
                                            type: string
                                        required:
                                          - type
                                          - name
                                      - type: object
                                        properties:
                                          id:
                                            type: string
                                          type:
                                            type: string
                                            enum:
                                              - KeyedPerformed
                                          event:
                                            type: string
                                          path:
                                            type: string
                                          key:
                                            type: string
                                          properties:
                                            type: array
                                            items:
                                              type: object
                                              properties:
                                                path:
                                                  type: string
                                                operator:
                                                  type: object
                                                  properties:
                                                    type:
                                                      type: string
                                                      enum:
                                                        - Equals
                                                    value:
                                                      type: string
                                                  required:
                                                    - type
                                                    - value
                                              required:
                                                - path
                                                - operator
                                        required:
                                          - type
                                          - event
                                          - path
                                          - key
                          required:
                            - type
                            - entry
                            - nodes
                        - anyOf:
                            - type: object
                              properties:
                                id:
                                  type: string
                                type:
                                  type: string
                                  enum:
                                    - Trait
                                path:
                                  type: string
                              required:
                                - type
                                - path
                            - type: object
                              properties:
                                id:
                                  type: string
                                type:
                                  type: string
                                  enum:
                                    - Performed
                                event:
                                  type: string
                                path:
                                  type: string
                                properties:
                                  type: array
                                  items:
                                    type: object
                                    properties:
                                      path:
                                        type: string
                                      operator:
                                        type: object
                                        properties:
                                          type:
                                            type: string
                                            enum:
                                              - Equals
                                          value:
                                            type: string
                                        required:
                                          - type
                                          - value
                                    required:
                                      - path
                                      - operator
                              required:
                                - type
                                - event
                                - path
                            - type: object
                              properties:
                                id:
                                  type: string
                                type:
                                  type: string
                                  enum:
                                    - File
                                name:
                                  type: string
                              required:
                                - type
                                - name
                            - type: object
                              properties:
                                id:
                                  type: string
                                type:
                                  type: string
                                  enum:
                                    - KeyedPerformed
                                event:
                                  type: string
                                path:
                                  type: string
                                key:
                                  type: string
                                properties:
                                  type: array
                                  items:
                                    type: object
                                    properties:
                                      path:
                                        type: string
                                      operator:
                                        type: object
                                        properties:
                                          type:
                                            type: string
                                            enum:
                                              - Equals
                                          value:
                                            type: string
                                        required:
                                          - type
                                          - value
                                    required:
                                      - path
                                      - operator
                              required:
                                - type
                                - event
                                - path
                                - key
                        - type: object
                          properties:
                            id:
                              type: string
                            type:
                              type: string
                              enum:
                                - PerformedMany
                            or:
                              type: array
                              items:
                                type: object
                                properties:
                                  event:
                                    type: string
                                required:
                                  - event
                          required:
                            - type
                            - or
                    exampleValue:
                      type: string
                    updatedAt:
                      type: number
                    lastRecomputed:
                      type: number
                - type: object
                  properties:
                    name:
                      type: string
                    workspaceId:
                      type: string
                  required:
                    - name
                    - workspaceId
      responses:
        '200':
          description: Default Response
          content:
            application/json:
              schema:
                type: object
                properties:
                  id:
                    type: string
                  workspaceId:
                    type: string
                  name:
                    type: string
                  definition:
                    anyOf:
                      - type: object
                        properties:
                          type:
                            type: string
                            enum:
                              - Id
                        required:
                          - type
                      - type: object
                        properties:
                          type:
                            type: string
                            enum:
                              - AnonymousId
                        required:
                          - type
                      - type: object
                        properties:
                          type:
                            type: string
                            enum:
                              - Group
                          entry:
                            type: string
                          nodes:
                            type: array
                            items:
                              anyOf:
                                - type: object
                                  properties:
                                    id:
                                      type: string
                                    type:
                                      type: string
                                      enum:
                                        - AnyOf
                                    children:
                                      type: array
                                      items:
                                        type: string
                                  required:
                                    - id
                                    - type
                                    - children
                                - anyOf:
                                    - type: object
                                      properties:
                                        id:
                                          type: string
                                        type:
                                          type: string
                                          enum:
                                            - Trait
                                        path:
                                          type: string
                                      required:
                                        - type
                                        - path
                                    - type: object
                                      properties:
                                        id:
                                          type: string
                                        type:
                                          type: string
                                          enum:
                                            - Performed
                                        event:
                                          type: string
                                        path:
                                          type: string
                                        properties:
                                          type: array
                                          items:
                                            type: object
                                            properties:
                                              path:
                                                type: string
                                              operator:
                                                type: object
                                                properties:
                                                  type:
                                                    type: string
                                                    enum:
                                                      - Equals
                                                  value:
                                                    type: string
                                                required:
                                                  - type
                                                  - value
                                            required:
                                              - path
                                              - operator
                                      required:
                                        - type
                                        - event
                                        - path
                                    - type: object
                                      properties:
                                        id:
                                          type: string
                                        type:
                                          type: string
                                          enum:
                                            - File
                                        name:
                                          type: string
                                      required:
                                        - type
                                        - name
                                    - type: object
                                      properties:
                                        id:
                                          type: string
                                        type:
                                          type: string
                                          enum:
                                            - KeyedPerformed
                                        event:
                                          type: string
                                        path:
                                          type: string
                                        key:
                                          type: string
                                        properties:
                                          type: array
                                          items:
                                            type: object
                                            properties:
                                              path:
                                                type: string
                                              operator:
                                                type: object
                                                properties:
                                                  type:
                                                    type: string
                                                    enum:
                                                      - Equals
                                                  value:
                                                    type: string
                                                required:
                                                  - type
                                                  - value
                                            required:
                                              - path
                                              - operator
                                      required:
                                        - type
                                        - event
                                        - path
                                        - key
                        required:
                          - type
                          - entry
                          - nodes
                      - anyOf:
                          - type: object
                            properties:
                              id:
                                type: string
                              type:
                                type: string
                                enum:
                                  - Trait
                              path:
                                type: string
                            required:
                              - type
                              - path
                          - type: object
                            properties:
                              id:
                                type: string
                              type:
                                type: string
                                enum:
                                  - Performed
                              event:
                                type: string
                              path:
                                type: string
                              properties:
                                type: array
                                items:
                                  type: object
                                  properties:
                                    path:
                                      type: string
                                    operator:
                                      type: object
                                      properties:
                                        type:
                                          type: string
                                          enum:
                                            - Equals
                                        value:
                                          type: string
                                      required:
                                        - type
                                        - value
                                  required:
                                    - path
                                    - operator
                            required:
                              - type
                              - event
                              - path
                          - type: object
                            properties:
                              id:
                                type: string
                              type:
                                type: string
                                enum:
                                  - File
                              name:
                                type: string
                            required:
                              - type
                              - name
                          - type: object
                            properties:
                              id:
                                type: string
                              type:
                                type: string
                                enum:
                                  - KeyedPerformed
                              event:
                                type: string
                              path:
                                type: string
                              key:
                                type: string
                              properties:
                                type: array
                                items:
                                  type: object
                                  properties:
                                    path:
                                      type: string
                                    operator:
                                      type: object
                                      properties:
                                        type:
                                          type: string
                                          enum:
                                            - Equals
                                        value:
                                          type: string
                                      required:
                                        - type
                                        - value
                                  required:
                                    - path
                                    - operator
                            required:
                              - type
                              - event
                              - path
                              - key
                      - type: object
                        properties:
                          id:
                            type: string
                          type:
                            type: string
                            enum:
                              - PerformedMany
                          or:
                            type: array
                            items:
                              type: object
                              properties:
                                event:
                                  type: string
                              required:
                                - event
                        required:
                          - type
                          - or
                  exampleValue:
                    type: string
                  updatedAt:
                    type: number
                  lastRecomputed:
                    type: number
                required:
                  - id
                  - workspaceId
                  - name
                  - definition
                  - updatedAt

````