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
- general_route_not_found - Auth Guide
If you’ve just added a subdomain to your project, verified your DNS records, and confirmed your SSL certificate is working, but you're still hitting a `general_...
- Can't resume paused project
I have logged in in incognito, done the email verification and still get the invalid fingerprint error. What's the issue.
- Impossible to get USER after createEmail...
Am using provider to deal with functions linked to appwrite. Here is my login. Future<String?> login(String email, String password) async { try { aw...