Blocking Users in Bulk
Last Updated:
Overview
Applies To
- Authentication
- Post-Login Action
- Blocked
Solution
For example, to block all users who have `blocked` set to `true` in their `app_metadata` the following example should be reviewed:
exports.onExecutePostLogin = async (event, api) => {
if (event.user.app_metadata.blocked) {
api.access.deny("Blocked");
}
}