Hi! Im attempting to get the users session using serversideprops to speed up the page load, how do i get the session using the req and res/serversideprops in Next.js?
You can see a good example of Appwrite auth with nextjs in Meldiron project Almost SSR https://next-js.ssr.almostapps.eu/ https://github.com/Meldiron/appwrite-ssr-next-js
I've looked at this code but it seems to be for anonymous login only, as the anonymous session is created server-side. How can i do this for oauth?
Yes in this type of login it can be a bit tricky, check Meldiron advice here. https://discord.com/channels/564160730845151244/564160731327758347/1110645396620988436
and are there any plans to make this process easier in the near future?
I think. but not in the very near future. You can see this feature request is related to the core logic of the issue, you can upvote this. https://github.com/appwrite/appwrite/issues/3891
Because as of now there is no way to execute Client SDK actions with a Server side SDK.
Recommended threads
- Invalid document structure: missing requ...
I just pick up my code that's working a week ago, and now I got this error: ``` code: 400, type: 'document_invalid_structure', response: { message: 'Inv...
- custom domain with CloudFlare
Hi all, it seems that CloudFlare has blocked cross-domain CNAME link which made my app hostname which is in CloudFlare, unable to create a CNAME pointing to clo...
- Custom emails
What happen if I use a third party email provider to customize my emails and my plan run out of emails/month? Appwrite emails are used as fallback sending emai...