Next.js 14.2.3 & node-appwrite 12.1.0-rc.4
The [https://appwrite.io/docs/tutorials/nextjs-ssr-auth/] example does not work. The session is empty. So after redirecting to account (profile) page no session. console shows something, but no session.
Submitted with FormData {
'$ACTION_ID_34da0b0f339b64faae9cd17956855b7c6670dbdf': '',
email: 'n*******d@gmail.com',
password: '***********'
}
Signing in with nlaakald@gmail.com **********
Done! Session is {
'$id': '665776d61c9073aae9ae',
'$createdAt': '2024-05-29T18:41:26.131+00:00',
'$updatedAt': '2024-05-29T18:41:26.131+00:00',
userId: '6632b5ae003b1e166738',
expire: '2025-05-29T18:41:26.117+00:00',
provider: 'email',
providerUid: 'n*******d@gmail.com',
providerAccessToken: '',
providerAccessTokenExpiry: '',
providerRefreshToken: '',
ip: '172.*.*.*',
osCode: 'LIN',
osName: 'GNU/Linux',
osVersion: '',
clientType: '',
clientCode: '',
clientName: '',
clientVersion: '',
clientEngine: '',
clientEngineVersion: '',
deviceName: 'desktop',
deviceBrand: '',
deviceModel: '',
countryCode: 'us',
countryName: 'United States',
current: true,
factors: [ 'password' ],
secret: '',
mfaUpdatedAt: ''
}
Cookie is {
name: 'my-app-session',
value: '',
path: '/',
httpOnly: true,
sameSite: 'strict',
secure: true
}
Getting logged in user...
Error getting logged in user Error: No session
at createSessionClient (webpack-internal:///(rsc)/./lib/appwrite.ts:30:15)
at getLoggedInUser (webpack-internal:///(rsc)/./lib/appwrite.ts:58:35)
at Profile (webpack-internal:///(rsc)/./app/auth/profile/page.tsx:30:86)
Console
BROWSER AND DEVICE SESSION LOCATION IP
on GNU/Linux United States 172.*.*.*
Code is @ https://github.com/AndrewDonelson/next-appwrite-starter/tree/convert-node-appwrite
would you please double check the API key is valid and has the session write scope?
Recommended threads
- Invalid document structure: missing requ...
I just pick up my code that's working a week ago, and now I got this error: ``` code: 400, type: 'document_invalid_structure', response: { message: 'Inv...
- Error: User (role: guests) missing scope...
I want to send a verification code to the user and the given phone number and check it and create a session right after the user entered the secret. For me that...
- Apple OAuth Scopes
Hi Hi, I've configured sign in with apple and this is the response i'm getting from apple once i've signed in. I cant find anywhere I set scopes. I remember se...