KindeK
Kinde7mo ago
13 replies
Adam Tkaczyk

Redirect URL for multi-tenancy app

Another issue, but I'll start a separate thread for that, because they are unrelated.

Context: I’m building a multi-tenancy, white-label app. It's an education platform, B2B2C model. I have a platform, where creators (mentors, teachers) can prepare a course. One teacher can have multiple courses. Students can have access to just part of them, but across many organisations (tenants). There is also a student portal, where students can login, if they are invited to (like edu.example1.com, med.example2.dev). I'm using NextJS.

The issue is:
1. If we have one tenant under edu.example1.com
2. Second under med.example2.dev
(!) What should be the KINDE_SITE_URL then? I cannot set it for one URL only, because I'll have edu.example1.com, med.example2.dev etc.
And is there an easy way to setup redirect URL to the given tenant after login? So if I started from med.example2.dev, I should land on med.example2.dev after auth process.
Was this page helpful?