Next.js Discord

Discord Forum

How can I get total session time for a user?

Unanswered
Transvaal lion posted this in #help-forum
Open in Discord
Transvaal lionOP
I am new to NextJs. I am using Next Auth for authentication, using credentials and an API written with Laravel (Sanctum). For gathering statistics about the user, I want to store the total logged-in time of the user in the database. What is the best approach to this? Is there any easy way of doing so?

2 Replies