signup email from sever
I’m calling 
However, the next
I went through the method flow but didn’t find anything unusual.
auth.api.signupWithEmail, and I’m getting the same response as when I call it from authClient.However, the next
getSession call returns null, whereas when signup is called from the client, it works fine.I went through the method flow but didn’t find anything unusual.
4 Replies
use headers
headers:await headers()
thanks for the reply. where to put this.
Are you making sure that the cookies are getting sent to the client?
We usually recommend using authClient for these types of reasons
const session = await auth.api.getSession({headers:await headers()})
client : 
const session = await authClient.getSession({ headers : await headers() })