Function authenticateToken
- authenticateToken(jwtSecret, userCollectionName?): ((req, res, next) => Promise<undefined | Response<any, Record<string, any>>>)[]
-
Parameters
-
jwtSecret: string
-
userCollectionName: string = 'users'
Returns ((req, res, next) => Promise<undefined | Response<any, Record<string, any>>>)[]
Description
this function is used to authenticate the token
Example
Example
if you want to use it in a specific route