How to create a custom Login?

Hey, guys!

I need to create a custom login with some logic to validate user by email, for that, I want to set username in the login, anyone knows how can I do that?

I saw that the “vtex.login” app internally has a “useAuth” hook that exposes a “setUserEmail” function. However, when I try to use it, receive an error from GraphQL saying: “Component not found: vtex.login@2.59.0/react”.

I think that the error is because not have the provider. However, I tried to add the provider, and no success.

My logic is:
CustomLogin
Login
CustomLogin

Hello there @rafaelfranca, hope you’re doing just fine!

Are you trying to implement a Login authentication from an external identity provider on your store?
You can do it natively in the Admin:

You can find further information regarding the implementation of Custom OAuth here: Webstore (OAuth 2.0).

If I got it wrong, please let me know.
Thank you.