mirror of
https://github.com/pocket-id/pocket-id.git
synced 2026-07-16 05:54:01 +03:00
🚀 Feature: Actions or Scripting Engine (Pre-Registration / Pre-Auth Hooks) #592
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @simonliu99 on GitHub (Jan 6, 2026).
Feature description
The current feature set is simple and robust, but having the ability to add more granular logic into registration or authentication would be a great option to have. This would be similar to Auth0 Actions or Zitadel Actions that would allow admins to define small snippets of JavaScript code that execute at specific triggers.
Pitch
This feature would allow for logic to implement checks like whitelisted domains, password/username policies, or trigger webhooks when a new user registers (e.g., to notify Slack/Discord). Currently, these features would require individual PRs and new UI toggles for every single variation.
Pre-registration example: whitelist a domain (#1152)
Post-registration example: Discord webhook notification
Pre-authentication example: parental controls
Pre-authentication example: custom auth errors
@ScrumpyJack commented on GitHub (Jan 29, 2026):
There have been a few requests that this falls under so there is some interest
https://github.com/pocket-id/pocket-id/issues/1282
https://github.com/pocket-id/pocket-id/issues/1152
These would be a killer features IMHO
Another example of post registration hook in particular:
In a private setting (like internal org or self-hosted family/friends groupware) when a user registers, they pick a new email address and a post registration webhook could trigger a workflow, such a creating the new mailbox, setup up storage and evrything needed for said groupware to function without an admin having to set it all up for the new user manually.