I have cloned the convex-auth-example chat app
There is one problem, while running locally, I can't sign in with a password, at first it shows there is no JWT_PRIVATE_KEY but the data is stored in the database. Then I added
JWT_PRIVATE_KEY
in .env
at convex. Now if I sign in with a password, it shows this error,
What is the problem?5 Replies
Thanks for posting in <#1088161997662724167>.
Reminder: If you have a Convex Pro account, use the Convex Dashboard to file support tickets.
- Provide context: What are you trying to achieve, what is the end-user interaction, what are you seeing? (full error message, command output, etc.)
- Use search.convex.dev to search Docs, Stack, and Discord all at once.
- Additionally, you can post your questions in the Convex Community's <#1228095053885476985> channel to receive a response from AI.
- Avoid tagging staff unless specifically instructed.
Thank you!
What does the output of
npx convex env list
look like? Do you see a JWT_PRIVATE_KEY
? Convex environment variables are configured via npx convex env set
or in the dashboard, not via .env
filesI have actually configured the env at convex. When I run
but I am getting this error
npx convex env list
the below is the output
JWT_PRIVATE_KEY=asdfadgdfbut I am getting this error
The key should have a specific format (as an example, here's the beginning of mine
JWT_PRIVATE_KEY=-----BEGIN PRIVATE KEY----- MIIEvg...
). This is usually set by running npx @convex-dev/auth
or manually generating them with a script (https://labs.convex.dev/auth/setup/manual#configure-private-and-public-key). Have you done this set up?Manual Setup - Convex Auth
Authentication library for your Convex backend
thank you! it works