Documentation update
Hello, I'm trying to use the Kinde express SDK to verify a jwt, following the example given here https://docs.kinde.com/developer-tools/sdks/backend/express-sdk/#verify-jwt
However typescript is complaining the
options
arg is missing. Also the type for options is Record<string, string>
, which is very generic. Is there an example where I can reference to get this to work?
I keep getting the error 'bE [Error]: Issuer not allowed: xxxxxxxx, Expected: undefined"
Thank you!4 Replies
found answer in the source code https://github.com/kinde-oss/kinde-node-express/blob/main/src/helpers/kindeMiddlewareHelpers.ts
GitHub
kinde-node-express/src/helpers/kindeMiddlewareHelpers.ts at main · ...
Kinde SDK for ExpressJS apps that run on the server - kinde-oss/kinde-node-express
now the error is
'ExpressMiddleware<Promise<void | Response<any, Record<string, any>>>>' is not assignable to parameter of type 'RequestHandlerParams<ParamsDictionary, any, any, ParsedQs, Record<string, any>>'
Hi @loremipsum1 , Sorry you're getting this issue.
May I suggest instead of using the validator exposed by the SDK, you switch to using our dedicated validator?
https://github.com/kinde-oss/jwt-validator The ExpressSDK exported one will be migrated to use this in the near future. Let me know how you get on
https://github.com/kinde-oss/jwt-validator The ExpressSDK exported one will be migrated to use this in the near future. Let me know how you get on
GitHub
GitHub - kinde-oss/jwt-validator: JavaScript JWT validator with sup...
JavaScript JWT validator with support for mobile and edge - kinde-oss/jwt-validator
Thanks @Daniel_Kinde ! I'll check it out.
What's the advantage of this validator when compared to
aws-jwt-verify
or some other existing libs? what's the suggested best practice if I want to verify feature flags and org ID as well?