getSession is not returning userAgent
I've been trying to set up a multisession feature so users can revoke access on other devices session. But getSession it not returning userAgent nor ipAddress. I even followed the Better Auth report example.
Solution:Jump to solution
Yeah, I create a server action and passed the headers when calling the function.
```export const getSessionData = async () => {
try {
const headersList = await headers();
...
5 Replies
Hey @Emi have u been able to fix this?
Hi @Emi could you provide some insights and some code of where you are using getSession() ? getSession is meant to be used on the client side. I suspect that you might be using the getSession the server

Solution
Yeah, I create a server action and passed the headers when calling the function.
I wanted to use the server side instead
Nice 🙂