I'm currently using Azure AD B2C as my IAM and need to implement a feature that allows users to log in through magic links. The desired flow is as follows:
A user requests a magic link. A link containing a magic token is sent to the user's email. The user clicks the link and is logged into the application. Current architecture involves:
UI-->Azure Ad b2c-->get AccessToken
UI-->API Gateway(Validates the access tokens)-->Backend Services
Could someone guide me on how to implement this feature? Any detailed steps or suggestions would be greatly appreciated.
I have reviewed several custom policies, but they don't fit my use case because the authentication must be handled entirely through the API. The UI should not redirect to Azure AD B2C's login pages(user flows/custom policies), as we have our own login and account creation pages. We use Microsoft Graph API to create and authenticate(ROPC) users.