elements icon indicating copy to clipboard operation
elements copied to clipboard

Add Ory Hydra login and consent features to Next.js examples and Next.js package

Open Jorgagu opened this issue 11 months ago • 1 comments

Preflight checklist

Ory Network Project

No response

Describe your problem

Hello Ory team,

I would like to request the addition of the Ory Hydra login and consent features to the following Next.js projects in the Ory Elements monorepo:

Next.js App Router example Next.js Pages Router example Next.js package

Describe your ideal solution

Ory Hydra is a powerful OAuth2 and OpenID Connect provider, and integrating its login and consent flow into these Next.js examples and package would:

  • Provide developers with a ready-to-use implementation for managing user authentication and consent.
  • Simplify OAuth2/OIDC workflows in Next.js applications.
  • Ensure better security and compliance with best practices.

This implementation has already been done in the Ory Kratos Self-Service UI Node project. Having the same functionality in the Next.js examples and package would improve consistency across Ory’s ecosystem and provide a better developer experience.

Workarounds or alternatives

The feature should include:

  • A login and consent flow example in both the App Router and Pages Router examples.
  • Documentation and guidance on how to customize the login and consent flows.
  • Integration with the Next.js package for easier adoption.

This enhancement would make it easier for developers using Ory Elements to implement Ory Hydra in their Next.js projects.

Version

@ory/nextjs: v1.0.0

Additional Context

No response

Jorgagu avatar Jan 13 '25 21:01 Jorgagu

Yes, this is planned

aeneasr avatar Jan 18 '25 12:01 aeneasr

This is done now

aeneasr avatar Apr 17 '25 10:04 aeneasr

Well, not fully, because the example don't have it yet.

aeneasr avatar Apr 17 '25 10:04 aeneasr

Would also love to see an example of how this is done, is this going to happen any time soon? Thank you!

harleyharl avatar May 12 '25 22:05 harleyharl

@aeneasr any updates about this one ?

Jorgagu avatar Jun 23 '25 07:06 Jorgagu