for whole code view https://codeshare.io/5XYBMa
//app/store/auth.ts snippet for oauth2
async signInWithGoogle() {
const successUrl = 'http://localhost:3001/success';
const failureUrl = 'http://localhost:3001/login?error=oauth_failed';
try {
await account.createOAuth2Session(
OAuthProvider.Google,
successUrl,
failureUrl,
['profile', 'email'],);
async handleOAuthCallback() {
try {
const session = await account.getSession("current");
const user = await account.get<any>();
const { jwt } = await account.createJWT();
gettting errror result: Object { success: false, error: AppwriteException } ​ error: AppwriteException: User (role: guests) missing scope (account) ​ success: false
Recommended threads
- Google Auth not working in a React App
Authentication with Google has failed. It redirects back to the signin route in React. Attached screenshots for configuration of Google console and Appwrite Go...
- Dokploy docker compose
Hey guys hope y'all doing well, I was wondering if anyone could share a working 1.8.0 docker-compose that works with Dokploy I tried making it but it just does...
- How to display images from storage
I tried the link above, but it returns the error “`Please upgrade to a higher plan.`” I don’t need Transformations at the moment, I just want to display the ima...