I want to get user id that invoked the function, so how can i get the same?
You'll have it inside the APPWRITE_FUNCTION_USER_ID
variable.
const userId = res.variables['APPWRITE_FUNCTION_USER_ID']
Thanks a lot
[Solved] How can i get user id in function
Hey @Binyamin, I am working on an Appwrite App in the apwrite cloud and wanted to lookup this information in the docs but it seems like the docs only describe the newest for version 1.4. Is there a plan to provide documentation for older appwrite versions?
In the API docs you can select version Otherwise you'll need to search for it in GitHub
Yes in the reference part, but not in the Guides section...
Yep For that you can check here https://github.com/appwrite/docs/tree/main/app/views/docs and here https://github.com/appwrite/appwrite/tree/master/docs
Alright, thanks 👍
Recommended threads
- HTTP POST to function returning "No Appw...
Hi everyone, I’m running into an issue with my self-hosted Appwrite instance. I’ve set up my environment variables (APPWRITE_FUNCTION_PROJECT_ID, APPWRITE_FUNC...
- Can't add dart 3.5 runtime
Modified the `.env` to enable dart 3.5 runtime on my self-hosted instance but still can't find the runtime when creating a new function. I manually pulled the i...
- How to verify an user using AppWrite Fun...
I have seen similar questions but none whose solutions serve me. I have a function to verify a user with their secret and their id: https://blahblah.appwrite.gl...