Back

appwrite oauth session doesnot work with NEXT 12.3

  • 1
  • Accounts
  • Web
calipher
26 May, 2023, 09:47

i tried multipled times but the user doesnot get saved in db

TL;DR
User is experiencing issues with their appwrite oauth session not working with NEXT 12.3. They provided code for the Signin component but the user is unable to save the user in the database. They are asking for help and requesting code and more information. Solution: It is recommended to continue the discussion in the same thread to avoid duplicate posts. The user can also format their code using backticks for better readability.
Christy Jacob
26 May, 2023, 09:59

can you share your code and more information on what you're trying to achieve ?

calipher
26 May, 2023, 10:16

import { account } from "../appwrites";

`export const Signin = () => {

TypeScript
const  googleAuth= async(e)=>{
  

await account.createOAuth2Session('google','http://localhost:3000/home',"http://localhost:3000/login")

TypeScript
}`
calipher
26 May, 2023, 10:17

when the login completes and user gets redirected to home and when i use account.get it dosenot work

Drake
26 May, 2023, 15:32

FYI, it's best to wrap code in backticks to format a bit nicer. You can use 1 backtick for inline code (https://www.markdownguide.org/basic-syntax/#code) and 3 backticks for multiline code (https://www.markdownguide.org/extended-syntax/#syntax-highlighting.

calipher
26 May, 2023, 15:33
TypeScript

export const Signin = () => {



    const  googleAuth= async(e)=>{
      


 await account.createOAuth2Session('google','http://localhost:3000/home',"http://localhost:3000/login")
        
 
    } ```
Drake
26 May, 2023, 15:37

Isn't this the same as https://discord.com/channels/564160730845151244/1111201523058364456? if so, please don't create duplicate posts. It's best to just continue in the same thread

calipher
27 May, 2023, 07:24

ossry

calipher
27 May, 2023, 07:24

sorry

Reply

Reply to this thread by joining our Discord

Reply on Discord

Need support?

Join our Discord

Get community support by joining our Discord server.

Join Discord

Get premium support

Join Appwrite Pro and get email support from our team.

Learn more