Unauthorize User
Audience:
Low-code EngineersSkill Prerequisites:
Actions,User management
Unauthorizes users, so they can't log in. It's the same as unchecking Authorized for a user in the Users admin page. The user and their data aren't deleted, and Authorize User can undo it.
It works on the current user and on every user in the context's list of users. In a form, the current user is usually the logged-in user. Use Load User or Load Users from SQL to pick other users.
Typical Use Cases
- Suspend a user's account without deleting it
- Let an administrator unauthorize a user picked in a Listing
- Unauthorize users who haven't been active for a while, loaded with Load Users from SQL in a scheduled job
Don't use it to
- Remove a user for good. Use Delete User instead.
- Take away access to one area only. Use Revoke User Role instead.
Related Actions
| Action Name | Description |
|---|---|
| Authorize User | Lets the current user and every user in the list log in again. |
| Load User | Loads users into the list and makes the last one the current user. |
| Load Users from SQL | Adds the users returned by a SQL query to the list. |
| Change User | Changes the current user without adding it to the list. |
| Revoke User Role | Removes roles from users. |
| Delete User | Deletes every user in the list. |
Input Parameter Reference
This action has no parameters of its own. It only has the common parameters of all actions.
Output Parameters Reference
This action has no output parameters.
Considerations
- The current user is unauthorized too. In a form, that's usually the person who clicked. If an administrator runs it without loading another user first, they unauthorize their own account. Load the user to unauthorize with Load User, which also makes it the current user, and check that the right user was found.
- There's no permission check in the action. Anyone who can run it can unauthorize the users in context. Only put it where you control who runs it.
- Check who's in the list. Every loaded user is unauthorized, plus the current user. Users loaded earlier in the same run are still in the list.
- Nothing to do, no error. If there's no current user and the list is empty, for example in a public form, nothing happens.
Examples
To understand how to use the below examples, please see Running Examples.
1. Unauthorize a selected user
These actions load the user whose ID is in the UserId token, then unauthorize that user. The condition makes sure the user was found, so the logged-in user isn't unauthorized by mistake.
{
"Title": "Load User",
"ActionType": "LoadUser",
"Description": "Load the user to unauthorize",
"Parameters": {
"Id": "[UserId]",
"Portal": ""
}
}
{
"Title": "Unauthorize User",
"ActionType": "UnauthorizeUser",
"Description": "Unauthorize the loaded user",
"Condition": "\"[User:UserID]\" == \"[UserId]\"",
"Parameters": {}
}
Revised 09/28/2026