Update a User
PATCH/sight/Users/:id
Supported paths: active, roles — only these produce observable changes. Operations on non-persisted attributes (displayName, externalId) return a silent 200 no-op; an operation changing userName fails the whole request with 400 invalidValue (including any other operations batched in it); unknown or miscased paths (e.g. Roles) fail 400 invalidPath. Send active changes and roles changes as separate PATCH requests — combined in one request, the deactivation wins and the role change is silently discarded (the 200 response echoes the old roles). Email addresses (userName) are immutable post-creation — to change a user's email, delete and re-create. Setting active to false deactivates the user (status becomes INACTIVE); the user remains queryable for reactivation. Session invalidation on deactivation follows the product's own behavior — to guarantee immediate session revocation, use HTTP DELETE, which revokes the user's active sessions. Setting active to true on a deactivated user reactivates them; reactivation may return 409 if the organization user quota is exceeded. PATCHing only roles on an INACTIVE user updates the roles but does not reactivate. Azure AD add operations on the roles path are automatically rewritten to replace for Entra ID compatibility. Role IDs are integers but must be sent as JSON strings (e.g. { "value": "4" }, not { "value": 4 }).
Request
Responses
- 200
- 400
- 401
- 403
- 404
- 409
- 500
User updated
Invalid patch (malformed PatchOp body, invalid role value, or empty roles array — at least one role is required)
Missing or invalid Bearer token
Tenant is not configured for this product
User not found
Conflict — user quota exceeded; cannot reactivate
Internal server error — if this persists, contact your Inspectorio representative.