Are there any examples of using supertokens with N...
# support-questions
a
Are there any examples of using supertokens with NestJS/GraphQL? Thanx!
r
hey @ansont we have examples for using with nest js only. But we have had people in the past who have used it with nestjs + graphql. Maybe search on discord and our github issues for this.
a
I managed to get this to work by writing a session plugin for the NestJS graphql module. However, it's pretty hacky because verifySession takes request and response arguments which are not readily available in the plugin.
r
I see. What would be the ideal interface for verifySession which would work well for your use case?
a
If there's an alternative (lower level) verifySession that just takes cookies and returns the response data and the session instead of applying to response object
r
There isn’t one yet. But in 1 months time, there will be.
Until then, you can hack around by providing a fake req and res object to the getSession function and reading from those.