Introducing ReUI:Open-source UI components and apps built with React, Next.js and Tailwind CSS
Browse ReUI

Way to use default Auth API https://preview.keenthemes.com/metronic8/laravel/api


Hello,

I purchased Metronic and has set the React+Vite TypeScript version up for frontend, using ASP.NET Core for backend. While looking through frontend codes, I found out that Metronics use Laravel APIs for authentication. I want to utilize this API to use the authorization tokens. However, while working with it, I found out that the API only processes properly only if the default credentials (admin@demo.com, demo) are given.

I want to ask is there any way to utilize this API so that it generates tokens for our custom user infos? Plus, is there any way to use a non-email username with this API?

Currently I have made the code to work like this:
1) Login.tsx sends email and pw to ASP.NET Core controller.
2) Controller checks if the credentials are in DB.
3) If it is in DB, returns to Login.tsx where it sends to run _requests.login function.

Please let me know if you need any additional information. I greatly appreciate your help in this matter. Thanks!


Text formatting options
Submit
Here's a how to add some HTML formatting to your comment:
  • <pre></pre> for JS codes block
  • <pre lang="html"></pre> for HTML code block
  • <pre lang="scss"></pre> for SCSS code block
  • <pre lang="php"></pre> for PHP code block
  • <code></code> for single line of code
  • <strong></strong> to make things bold
  • <em></em> to emphasize
  • <ul><li></li></ul>  to make list
  • <ol><li></li></ol>  to make ordered list
  • <h3></h3> to make headings
  • <a></a> for links
  • <img> to paste in an image
  • <blockquote></blockquote> to quote somebody
  • happy  :)
  • shocked  :|
  • sad  :(

Replies (1)


Hi,

Sorry for the late reply.

Our Laravel API backend is used as an demo API. You can check the API request/response format and implement your own API for your app. Usually buyers after purchase implement the backend by their own. Please refer to "auth" folder and see how the auth module works and you can fully customize it.

Regards,
Sean


Text formatting options
Submit
Here's a how to add some HTML formatting to your comment:
  • <pre></pre> for JS codes block
  • <pre lang="html"></pre> for HTML code block
  • <pre lang="scss"></pre> for SCSS code block
  • <pre lang="php"></pre> for PHP code block
  • <code></code> for single line of code
  • <strong></strong> to make things bold
  • <em></em> to emphasize
  • <ul><li></li></ul>  to make list
  • <ol><li></li></ol>  to make ordered list
  • <h3></h3> to make headings
  • <a></a> for links
  • <img> to paste in an image
  • <blockquote></blockquote> to quote somebody
  • happy  :)
  • shocked  :|
  • sad  :(
Text formatting options
Submit
Here's a how to add some HTML formatting to your comment:
  • <pre></pre> for JS codes block
  • <pre lang="html"></pre> for HTML code block
  • <pre lang="scss"></pre> for SCSS code block
  • <pre lang="php"></pre> for PHP code block
  • <code></code> for single line of code
  • <strong></strong> to make things bold
  • <em></em> to emphasize
  • <ul><li></li></ul>  to make list
  • <ol><li></li></ol>  to make ordered list
  • <h3></h3> to make headings
  • <a></a> for links
  • <img> to paste in an image
  • <blockquote></blockquote> to quote somebody
  • happy  :)
  • shocked  :|
  • sad  :(