Hi Directus team
,
I’m using Directus as a Backend-as-a-Service with Next.js as the frontend.
In my application, I have a Support / Ticket system where users raise issues or bugs. For discussions on a ticket, I am using Directus’ default directus_comments collection, since the functionality matches my use case well.
The problem
When a user mentions another user in a comment, Directus sends the default email notification like:
“XYZ has mentioned you in a comment”
Click here to view.
The “Click here” link redirects to the Directus Admin App (backend).
This is not desired behavior for us:
-
End users should never land in the Directus backend
-
They should be redirected to the specific ticket page in the frontend (Next.js) where they were mentioned
What we already know
Directus allows overriding some email templates:
-
password-reset.liquid -
user-invitation.liquid -
user-registration.liquid
However, there is no template available for mention comment notifications, so we currently have no way to customize:
-
The email content
-
The redirection URL
-
Or inject a frontend URL with item context (collection + item ID)
Workaround consideration (not ideal)
One option is to:
-
Create a new custom collection (e.g.,
activityorsupport_comments) -
Rebuild comment logic, mentions, and notifications manually
But this feels like duplicating existing core functionality, which is:
-
Inefficient
-
Error-prone
-
Against the purpose of using Directus’ built-in comments system
My questions
-
Is there a recommended way to override or customize mention email notifications in Directus?
-
Is there any plan to expose a comment-mention email template similar to other templates?
-
Is using a separate custom collection really the expected approach for frontend-only comment systems, or is there a cleaner solution?
I’d appreciate guidance on the correct architectural approach here, because the current behavior makes the default comments system hard to use for real end-user applications.