Hi there <:appwritefire:823999000330895380> , I can not wrap my head around the permission differences of Roles guest and any. What exactly is the difference? How does appwrite determine of one is a guest and not anyone? Are there any docs i have missed?
The different is if a collection for example has a permission of any then anyone can access it But if it has the guest permission then only guests can see it and not anyone else So the wrap it
- Any - anyone, guests, logged in and members of them
- Guest - Guests only logged in user won't have access
You can read more about it here https://appwrite.io/docs/permissions#permission-roles
Thank you for your answer! π I still dont quite get it. What exactly differs a user from anyone? How does appwrite determine if one is a guest of my website/app/whatever and not just some rando sending requests to my server?
Ohh Like that A user is anyone that have an active session against your Appwrite endpoint That mean the this user has to be logged in to your endpoint using any one of the methods
- OAuth2
- Magic URL
- Phone
- Anonymous Or is request came with a valid JWT
Otherwise this user will be treated as a guest
Any - is in both cases
P.s. you don't need to worry about the session logic or arranging the user ID in your functions or database fetch, as Appwrite is taking care of those parts for you
Ah okay, so any just includes both users with active sessions and guests π
Exactly
Perfect, thanks!
π
[SOLVED] Difference Role guest vs. any?
Recommended threads
- Upgrade Issue
Am having issue upgrading my appwrite account to pro as my card number is 19 and the required input is 16 digit
- createEmailPasswordSession Error using S...
Did someone succeed using SSR approach for login?
- [Solved] how to get user prefs from serv...
i want to get a specific users preferences from serverside maybe i missunderstood something