Hello everyone, I work with nuxt and I have the following issue:
Error checking user status: User (role: guests) missing scope (account)
at Client.<anonymous> (node_modules\.pnpm\appwrite@16.0.2\node_modules\appwrite\src\client.ts:695:19)
at Generator.next (<anonymous>)
at fulfilled (node_modules\.pnpm\appwrite@16.0.2\node_modules\appwrite\node_modules\tslib\tslib.es6.js:73:58)
at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
Here is the code that generate this error:
const checkUser = async () => {
try {
user.value = await account.get()
} catch (error) {
console.log('Error checking user status:', error)
}
}
I have checked my active session in the cookies and I see:
a_session_<userId>: <auth_token>
how are you authenticating?
With:
account.createEmailPasswordSession(email, password)
Are you using SSR?
Yes
You probably need a session created on the server and client depending on how you are fetching data
How can I do that ?
I don't know much about Nuxt, but maybe this Next tutorial is applicable in some way?
Ok thank you, I'll try to see that
Recommended threads
- User columns stuck on processing
Hi — on Appwrite Cloud (Free), Project ID 69d7dd8200098ed8560c, database mylestone-db. Attributes/columns are stuck in "processing" indefinitely across two coll...
- Custom API domain is unreachable
Earlier my custom api domain was working fine. Now it seems to be offline without a trace a few hours later. I didn't change anything, all the relevant DNS reco...
- "Invalid console fingerprint" when unpau...
I've tried logging out and logging back in, still can't figure out why this is happening.