node-oauth2-jwt-bearer icon indicating copy to clipboard operation
node-oauth2-jwt-bearer copied to clipboard

Expose access-token-jwt library, so this package could be used without express

Open stajkowski opened this issue 10 months ago • 2 comments

Checklist

  • [X] I have looked into the Readme and Examples, and have not found a suitable solution or answer.
  • [X] I have searched the issues and have not found a suitable solution or answer.
  • [X] I have searched the Auth0 Community forums and have not found a suitable solution or answer.
  • [X] I agree to the terms within the Auth0 Code of Conduct.

Describe the problem you'd like to have solved

Publish access-token-jwt as a separate package. This allows customers to create their own middleware in various frameworks.

Describe the ideal solution

Publish access-token-jwt as a separate package.

Alternatives and current workarounds

No alternatives that are ideal and clean solutions.

Additional context

No additional context required, self-explanatory.

stajkowski avatar Jan 02 '25 18:01 stajkowski

Additionally, ugly solution detailed in https://github.com/auth0/node-oauth2-jwt-bearer/issues/75 does not work for Cloudflare Workers due to unsupported packages being installed with express-oauth2-jwt-bearer

stajkowski avatar Jan 02 '25 20:01 stajkowski

+1 would be extremely handy for aws lambdas and other non-express situations

chris-ux avatar Apr 25 '25 19:04 chris-ux

That would be awesome, also for nestJS applications. Users have been asking for this for years:

  • https://github.com/auth0/node-oauth2-jwt-bearer/issues/63
  • #75

Duske avatar Apr 29 '25 13:04 Duske

Hello @stajkowski, @chris-ux, @Duske,

For Auth0 applications in non-Express environments, we recommend using auth0/auth0-api-js. For non-Auth0 scenarios, you can use jose directly, as access-token-jwt is essentially a wrapper around it.

nandan-bhat avatar Aug 08 '25 06:08 nandan-bhat

I’ll go ahead and close this issue. If you have any further questions, please don’t hesitate to open a new ticket.

Thanks!

nandan-bhat avatar Aug 21 '25 06:08 nandan-bhat