{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://raw.githubusercontent.com/api-evangelist/thomson-reuters/main/json-schema/thomson-reuters-user-schema.json",
  "title": "User",
  "x-generated": "2026-10-20",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/thomson-reuters-onesource-trust-tax-administration-openapi.yml#/components/schemas/User",
  "type": "object",
  "properties": {
    "universal_id": {
      "type": [
        "string",
        "null"
      ],
      "description": "Universal Id"
    },
    "id": {
      "type": [
        "string",
        "null"
      ],
      "description": "User ID"
    },
    "client_id": {
      "type": "integer",
      "description": "Client ID",
      "format": "int32"
    },
    "user_type": {
      "$ref": "#/$defs/UserType"
    },
    "user_access": {
      "$ref": "#/$defs/UserAccess"
    },
    "name": {
      "type": [
        "string",
        "null"
      ],
      "description": "Name"
    },
    "initials": {
      "type": [
        "string",
        "null"
      ],
      "description": "Initials"
    },
    "email_address": {
      "type": [
        "string",
        "null"
      ],
      "description": "Email Address"
    },
    "broadcast_flag": {
      "type": [
        "integer",
        "null"
      ],
      "description": "Send e-Newz",
      "format": "int32"
    },
    "added_ini": {
      "type": [
        "string",
        "null"
      ],
      "description": "Initials of person added User Master"
    },
    "added_date": {
      "type": [
        "string",
        "null"
      ],
      "description": "Date User Master was added",
      "format": "date-time"
    },
    "change_ini": {
      "type": [
        "string",
        "null"
      ],
      "description": "Initials of person making last change to User Master"
    },
    "changed_date": {
      "type": [
        "string",
        "null"
      ],
      "description": "Date of last change to User Master",
      "format": "date-time"
    },
    "userrights": {
      "type": [
        "array",
        "null"
      ],
      "items": {
        "$ref": "#/$defs/UserRight"
      },
      "description": "Rights"
    },
    "change_type": {
      "$ref": "#/$defs/ChangeType"
    },
    "pans": {
      "type": [
        "array",
        "null"
      ],
      "items": {
        "$ref": "#/$defs/Pan"
      },
      "description": "Pans"
    },
    "client": {
      "$ref": "#/$defs/Client"
    }
  },
  "additionalProperties": false,
  "$defs": {
    "ChangeType": {
      "enum": [
        "No_Change",
        "Add",
        "Change",
        "Delete"
      ],
      "type": "integer",
      "format": "int32"
    },
    "Client": {
      "type": "object",
      "properties": {
        "id": {
          "type": "integer",
          "description": "Client ID",
          "format": "int32"
        },
        "key": {
          "type": [
            "string",
            "null"
          ],
          "description": "Client Key"
        }
      },
      "additionalProperties": false
    },
    "Pan": {
      "type": "object",
      "properties": {
        "user_id": {
          "type": [
            "string",
            "null"
          ],
          "description": "User ID"
        },
        "client_id": {
          "type": "integer",
          "description": "Client ID",
          "format": "int32"
        },
        "pan": {
          "type": [
            "string",
            "null"
          ],
          "description": "Product Access Number"
        },
        "added_ini": {
          "type": [
            "string",
            "null"
          ],
          "description": "Initials of person added User Account"
        },
        "added_date": {
          "type": [
            "string",
            "null"
          ],
          "description": "Date User Account was added",
          "format": "date-time"
        },
        "change_ini": {
          "type": [
            "string",
            "null"
          ],
          "description": "Initials of person making last change to User Account"
        },
        "changed_date": {
          "type": [
            "string",
            "null"
          ],
          "description": "Date of last change to User Account",
          "format": "date-time"
        },
        "change_type": {
          "$ref": "#/$defs/ChangeType"
        }
      },
      "additionalProperties": false
    },
    "Right": {
      "type": "object",
      "properties": {
        "id": {
          "type": "integer",
          "description": "Rights ID",
          "format": "int32"
        },
        "description": {
          "type": [
            "string",
            "null"
          ],
          "description": "Rights Description"
        }
      },
      "additionalProperties": false
    },
    "User": {
      "type": "object",
      "properties": {
        "universal_id": {
          "type": [
            "string",
            "null"
          ],
          "description": "Universal Id"
        },
        "id": {
          "type": [
            "string",
            "null"
          ],
          "description": "User ID"
        },
        "client_id": {
          "type": "integer",
          "description": "Client ID",
          "format": "int32"
        },
        "user_type": {
          "$ref": "#/$defs/UserType"
        },
        "user_access": {
          "$ref": "#/$defs/UserAccess"
        },
        "name": {
          "type": [
            "string",
            "null"
          ],
          "description": "Name"
        },
        "initials": {
          "type": [
            "string",
            "null"
          ],
          "description": "Initials"
        },
        "email_address": {
          "type": [
            "string",
            "null"
          ],
          "description": "Email Address"
        },
        "broadcast_flag": {
          "type": [
            "integer",
            "null"
          ],
          "description": "Send e-Newz",
          "format": "int32"
        },
        "added_ini": {
          "type": [
            "string",
            "null"
          ],
          "description": "Initials of person added User Master"
        },
        "added_date": {
          "type": [
            "string",
            "null"
          ],
          "description": "Date User Master was added",
          "format": "date-time"
        },
        "change_ini": {
          "type": [
            "string",
            "null"
          ],
          "description": "Initials of person making last change to User Master"
        },
        "changed_date": {
          "type": [
            "string",
            "null"
          ],
          "description": "Date of last change to User Master",
          "format": "date-time"
        },
        "userrights": {
          "type": [
            "array",
            "null"
          ],
          "items": {
            "$ref": "#/$defs/UserRight"
          },
          "description": "Rights"
        },
        "change_type": {
          "$ref": "#/$defs/ChangeType"
        },
        "pans": {
          "type": [
            "array",
            "null"
          ],
          "items": {
            "$ref": "#/$defs/Pan"
          },
          "description": "Pans"
        },
        "client": {
          "$ref": "#/$defs/Client"
        }
      },
      "additionalProperties": false
    },
    "UserAccess": {
      "enum": [
        "Enabled",
        "Disabled",
        "Deleted"
      ],
      "type": "integer",
      "format": "int32"
    },
    "UserHasAccess": {
      "enum": [
        "No",
        "Yes"
      ],
      "type": "integer",
      "format": "int32"
    },
    "UserRight": {
      "type": "object",
      "properties": {
        "right": {
          "$ref": "#/$defs/Right"
        },
        "user_has_access": {
          "$ref": "#/$defs/UserHasAccess"
        },
        "user": {
          "$ref": "#/$defs/User"
        },
        "added_ini": {
          "type": [
            "string",
            "null"
          ],
          "description": "Initials of person added User Right"
        },
        "added_date": {
          "type": [
            "string",
            "null"
          ],
          "description": "Date User Right was added",
          "format": "date-time"
        },
        "change_ini": {
          "type": [
            "string",
            "null"
          ],
          "description": "Initials of person making last change to User Right"
        },
        "changed_date": {
          "type": [
            "string",
            "null"
          ],
          "description": "Date of last change to User Right",
          "format": "date-time"
        },
        "change_type": {
          "$ref": "#/$defs/ChangeType"
        },
        "user_id": {
          "type": [
            "string",
            "null"
          ],
          "description": "User ID"
        },
        "client_id": {
          "type": "integer",
          "description": "Client ID",
          "format": "int32"
        },
        "right_id": {
          "type": "integer",
          "description": "Rights Code",
          "format": "int32"
        }
      },
      "additionalProperties": false
    },
    "UserType": {
      "enum": [
        "TrustTax",
        "Insight",
        "Developer",
        "Support",
        "Accountmanager",
        "TaxPrep",
        "Compliance",
        "Marketing",
        "WebDelivery",
        "Pseudo"
      ],
      "type": "integer",
      "format": "int32"
    }
  }
}