I have a function that inserts a document to a collection, but I also need to get the user id of the one who invoked the function. I use client side SDK for executing the function.
I tried the following:
`const { Client, Databases, Account } = require('node-appwrite');
const appwriteClient = new Client(); const databases = new Databases(appwriteClient); const account = new Account(appwriteClient);`
but the account variable produces an error.
(role: applications) missing scope (account)
nvm, i just found out about the req.headers x-appwrite-user-id
[SOLVED] How to get user id from the executed function?
Recommended threads
- Session not found. Please run appwrite l...
I have encounter an issue with appwrite CLI They asking for a login session but in the doc, it’s mention that only setup client with endpoint / api key is enou...
- SELF HOSTING ISSUE, DATA NOT MIGRATING T...
Hey, devs, I recently tried to migrate my cloud instance to a self hosted version but my data is not transferred fully only the table structure is transferred ...
- unlike any other provider, your sites DN...
your nameservers dont work with a funny little CNAME error, which is a weird bug but thats what you get when you try to be the kitchen sink, funny errors.