Kasszz
Kasszz
BABetter Auth
Created by Kasszz on 4/13/2025 in #help
Adding custom properties to Organization members
Hey, I'm trying to get it to work but when adding a "test" column on the members table that is non NULL. The code breaks when I'm trying to make an organisation with:
const organization = await auth.api.createOrganization({
headers: nextHeaders,
body: {
name: data.name,
slug,
},
})
const organization = await auth.api.createOrganization({
headers: nextHeaders,
body: {
name: data.name,
slug,
},
})
Is there an example that I could use because I feel like I'm just being a noob 😛
10 replies
BABetter Auth
Created by Kasszz on 4/13/2025 in #help
Adding custom properties to Organization members
Hey, not gotten any further yet ( busy at work ^^ ). But yea like @Megamind said, you can add them to your Prisma or in my case Drizzle schemas. But better-auth then has no idea about it and doesn't retrieve it on getActiveMember()
10 replies
BABetter Auth
Created by Kasszz on 3/22/2025 in #help
The organization plugin only a select number of server versions of the sdk?
Hey, thanks for responding, after a bit of snooping around. I indeed found more "endpoints" available through the auth.api object. I still feel it's a nicer architecture to do it on the server just because you can do more stuff around it that are not native to better auth.
3 replies