Hey there i have a question i just starded my project, i can register and login, but i don't go to the home page it says:
TypeScript
checkAuth: isAuthenticated - false, error: AppwriteException: User (role: guests) missing scope (account)
at Generator.next (<anonymous>) {
code: 401,
type: 'general_unauthorized_scope',
response: '{"message":"User (role: guests) missing scope (account)","code":401,"type":"general_unauthorized_scope","version":"1.6.2"}'
}
checkAuth: Error message: User (role: guests) missing scope (account)
checkAuth: Error code: 401
checkAuth: Error type: general_unauthorized_scope
My code is: Register.tsx: https://sourceb.in/7tREH6QNRJ Login.tsx: https://sourceb.in/kgONFqXAgm index.tsx/HomePage: https://sourceb.in/wpcQz3L8Sw
TL;DR
Developers encountered a 401 error where the user is missing the 'account' scope. The issue lies in missing authorization in the code provided in Register.tsx, Login.tsx, and index.tsx/HomePage.
To resolve this, you need to implement the 'account' scope for the 'guests' role in your authentication logic.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...
- How to determine if a user is anonymous?
This is probably a silly question, but I have not yet found a good answer. Is there a method to determine if the current session is anonymous aside from seein...
- ACTIVATE DEPLOYMENT PROBLEM...
It's not giving me the option to activate a deployment that says it's ready..