How to provide more info on ctx.session.user in the routers?

I gave my users a role and would like to have access to it with the context when I do a protectedProcedure.
3 Replies
Neto
Neto2y ago
you have to augment the next auth model
Neto
Neto2y ago
TypeScript | NextAuth.js
NextAuth.js has its own type definitions to use in your TypeScript projects safely. Even if you don't use TypeScript, IDEs like VSCode will pick this up to provide you with a better developer experience. While you are typing, you will get suggestions about what certain objects/functions look like, and sometimes links to documentation, examples, ...
Johnson
JohnsonOP2y ago
thx!
Want results from more Discord servers?
Add your server