jwt icon indicating copy to clipboard operation
jwt copied to clipboard

Accept token from url search query param

Open lallenfrancisl opened this issue 3 years ago • 2 comments

Support plan

Community

  • is this issue currently blocking your project? (yes/no): yes
  • is this issue affecting a production system? (yes/no): yes

Context

Some apps need the ability to parse token from url. A usecase would be to implement reset password links.

  • node version: 16.0.0
  • module version: 3.0.0
  • environment (e.g. node, browser, native): node
  • used with (e.g. hapi application, another framework, standalone, ...): hapi application
  • any other relevant information:

What problem are you trying to solve?

Allow the plugin to read token from url search query param. Something like https://api.test.com?token=sdfsdfsdfsf would be read and parsed

Implementing this opens up the plugin to a wide variety of usecases, like email reset password links, token based file access etc

Do you have a new or modified API suggestion to solve the problem?

Yes, this can be done similar to what we did with cookieName

lallenfrancisl avatar Aug 30 '22 14:08 lallenfrancisl

Any chance that this gets fixed soon? Reading tokens from query parameters is useful in certain scenarios and I was surprised that the library doesn't support it.

pelov avatar Mar 20 '23 13:03 pelov

@pelov see #50

mautematico avatar May 13 '23 04:05 mautematico