(for @Kenny) hello, so I created this login function:
export async function logIn(email: string, password: string) {
const account = new Account(client);
try {
const session = await account.createEmailPasswordSession(email, password);
console.log("Login successful:", session);
(await cookies()).set(COOKIE_KEY, session.secret, {
path: "/",
httpOnly: true,
sameSite: "strict",
secure: true,
});
return session;
} catch (error) {
console.error("Login failed:", error);
throw error;
}
}
problem is, session is created successfully, but the cookie is not being created (ss of application tab of devtools sent)
huh???
Windows 95 π
nevermind, I know whyy. secret isnt given on client side session creation.
now I am going try what happens if I uninstalled appwrite and used node-appwrite
still same result.
it created an empty cookie
@Kenny how do I get the session key π
Recommended threads
- GB Hours IS NOT resetting
Hi, I was checking my usage and noticed that all of my usage quotas were reset on August 20, 2026, when my billing cycle renewed. Everything else appears to ha...
- Confused about Appwrite Pro pricing
Hi. I've been subscribed to the $25 Appwrite Pro plan, but I've been getting charged $40. I have two projects on my account. I was wondering where exactly the e...
- How can I disable client-side account re...
Hi everyone! Iβm currently building a game backend using Appwrite, and Iβd like to prevent users from creating new accounts directly through the client. My go...