{% extends "base.html" %} {% block title %}{% if user %}Edit User{% else %}Create User{% endif %} - NanoIDP{% endblock %} {% block content %}

{% if user %}Edit User: {{ user.username }}{% else %}Create New User{% endif %}

Basic Information
Unique identifier for the user
{% if user %}
Leave empty to keep current password
{% elif persona_mode %}
Leave empty for a persona-mode-only user (cannot log in with a password)
{% endif %}
Display-only note shown in the persona picker (max 200 chars)
Tenant/organization identifier
Identity & Classification

Custom Attributes
{% if user and user.attributes %} {% for key, value in user.attributes.items() %}
{# Non-string values (a list/dict attribute set via YAML or MCP) render as JSON so an untouched edit round-trip preserves them; the route parses a value starting with [ or { back as JSON (#291). Plain strings stay verbatim. #} {# |forceescape after |tojson: tojson marks its output safe and does NOT escape double quotes, which would break this double-quoted attribute. #} {# attr_encoding[] (#294 review): the value box has no way to distinguish the STRING '["a"]' from the LIST ["a"] once both are rendered as text, so each row states how its value is encoded. 'auto' (rows typed fresh in the browser) keeps the [/{ JSON heuristic for operator convenience. #}
{% endfor %} {% endif %}
Custom key/value pairs included in JWT and SAML tokens
Roles & Groups
Comma-separated list of roles
Comma-separated list of groups
Entitlements
One entitlement per line
Source ACL (Access Control Lists)
One ACL entry per line. Used for data source access control.
Cancel
{% if user %} {% endif %}
{% if user %} {% endif %} {% endblock %} {% block extra_js %} {% endblock %}