{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/novumos-app/json-schema/novumos-app-update-preferences-request-schema.json",
  "title": "UpdatePreferencesRequest",
  "description": "PATCH /v1/me/preferences. Only the keys the caller wants to change.\n\nSending ``default_card_view: null`` explicitly clears it so the user\nfalls back to the client-side first-time default (NOV-81).\n\nNOV-579: an UNDECLARED key is rejected (422), not accepted-and-dropped.\nThis is the REST mirror of the MCP rule in ``app/mcp/strict_args.py``, and\nthe two must not disagree about what happens to a field the server does not\nunderstand: a write that silently no-ops teaches an agent it landed.\n\nParity is about UNDECLARED fields, not identical field lists. ``surveys``\nbelow is declared HERE and deliberately absent from the MCP tool — a\nlast-shown stamp records that a human was interrupted by a modal in a\nbrowser, so an agent writing one would suppress a survey nobody ever saw\n(§25.9). Sending ``surveys`` over REST is a supported write; sending it\nover MCP is now an error rather than a no-op.",
  "x-generated": "2026-11-19",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/novumos-app-openapi.json#/components/schemas/UpdatePreferencesRequest",
  "properties": {
    "theme": {
      "anyOf": [
        {
          "type": "string",
          "enum": [
            "dark",
            "light",
            "system"
          ]
        },
        {
          "type": "null"
        }
      ],
      "title": "Theme"
    },
    "palette": {
      "anyOf": [
        {
          "type": "string",
          "pattern": "^[a-z][a-z0-9-]{0,23}$"
        },
        {
          "type": "null"
        }
      ],
      "title": "Palette"
    },
    "default_card_view": {
      "anyOf": [
        {
          "type": "string",
          "enum": [
            "side_panel",
            "center_peek",
            "focused_overlay",
            "full_page"
          ]
        },
        {
          "type": "null"
        }
      ],
      "title": "Default Card View"
    },
    "board_card_view": {
      "anyOf": [
        {
          "additionalProperties": {
            "anyOf": [
              {
                "type": "string",
                "enum": [
                  "side_panel",
                  "center_peek",
                  "focused_overlay",
                  "full_page"
                ]
              },
              {
                "type": "null"
              }
            ]
          },
          "type": "object"
        },
        {
          "type": "null"
        }
      ],
      "title": "Board Card View"
    },
    "notifications": {
      "anyOf": [
        {
          "$ref": "#/$defs/UpdateNotificationPreferencesRequest"
        },
        {
          "type": "null"
        }
      ]
    },
    "dismissed_hints": {
      "anyOf": [
        {
          "additionalProperties": {
            "anyOf": [
              {
                "type": "boolean"
              },
              {
                "type": "null"
              }
            ]
          },
          "propertyNames": {
            "const": "connect_agent"
          },
          "type": "object"
        },
        {
          "type": "null"
        }
      ],
      "title": "Dismissed Hints"
    },
    "surveys": {
      "anyOf": [
        {
          "additionalProperties": {
            "anyOf": [
              {
                "type": "boolean"
              },
              {
                "type": "null"
              }
            ]
          },
          "propertyNames": {
            "enum": [
              "nps",
              "upgrade_exit"
            ]
          },
          "type": "object"
        },
        {
          "type": "null"
        }
      ],
      "title": "Surveys"
    }
  },
  "additionalProperties": false,
  "type": "object",
  "$defs": {
    "UpdateNotificationPreferencesRequest": {
      "properties": {
        "email": {
          "anyOf": [
            {
              "additionalProperties": {
                "anyOf": [
                  {
                    "type": "boolean"
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "propertyNames": {
                "enum": [
                  "card_assigned",
                  "automation_notify",
                  "lifecycle"
                ]
              },
              "type": "object"
            },
            {
              "type": "null"
            }
          ],
          "title": "Email"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "title": "UpdateNotificationPreferencesRequest",
      "description": "Partial per-type notification write (NOV-364).\n\n``email`` is a partial MERGE map: each key sets that type's email flag and\ntypes absent from the map are left untouched; an explicit ``None`` value\nCLEARS that type's stored override so it follows the default again (the\nsame tri-state as the ``board_card_view`` merge idiom). An unknown type is\nrejected by the ``NotificationType`` Literal (422), the same way an unknown\n``theme`` value is; ``StrictBool`` pins non-bool values (\"yes\", 1, …) to a\n422 as well — no lax coercion on a consent field. Omitting ``email`` (or\nthe whole ``notifications`` block) is a no-op."
    }
  }
}