Next.js Discord

Discord Forum

Multiple Tokens - JWT

Unanswered
Florida White posted this in #help-forum
Open in Discord
Florida WhiteOP
Hey guys. I need to have a server action for validating jwt for external service in .net. I have two route.ts files where I'm requesting external api with these tokens. Problem is that for one file I need to have let's say v1Token and for second v2Token. How to handle it properly? Currently single server action with parameter for api v1 and v2 so it requesting two endpoints at the end but in different files so I want to avoid overriding cached tokens. What you would suggest?

5 Replies

Florida WhiteOP
Code :
Florida WhiteOP
bump
Florida WhiteOP
bump
Trigg Hound
I’m having a hard time understanding the problem here and your code file didn’t really help much, if anything it confused me more