Enable passwordless sign-in with Microsoft Authenticator

Sukeerthi 21 Reputation points
2024-03-27T10:47:31.0833333+00:00

Hi Team,

I would like to check if its possible to implement passwordless sign-in with Microsoft Authenticator as mentioned in below

https://learn.microsoft.com/en-us/entra/identity/authentication/howto-authentication-passwordless-phone#enable-passwordless-phone-sign-in-authentication-methods

I would like to add push notifications from b2C policy if not possible would it be ok to call RestAPI(c#) and show push notifications(As attached screenshot).

Could you please let me know possible ways to implement Microsoft Authenticator push notifications?

Thanks,

Sukeerthi

Microsoft Authenticator
Microsoft Authenticator
A Microsoft app for iOS and Android devices that enables authentication with two-factor verification, phone sign-in, and code generation.
5,496 questions
Microsoft Entra ID
Microsoft Entra ID
A Microsoft Entra identity service that provides identity management and access control capabilities. Replaces Azure Active Directory.
19,474 questions
{count} votes

Accepted answer
  1. James Hamil 21,696 Reputation points Microsoft Employee
    2024-03-28T21:58:57.11+00:00

    Hi @Sukeerthi , this should be possible. You can follow the steps mentioned in the article you shared to enable passwordless phone sign-in authentication method.

    For adding push notifications from B2C policy, I would like to clarify that Microsoft Authenticator push notifications are only available for Azure AD tenants, not for Azure AD B2C tenants. However, you can use the Microsoft Graph API to send push notifications to the Microsoft Authenticator app.

    To use the Graph API, you need to register your application in Azure AD and obtain an access token. You can then use the access token to call the Microsoft Graph API to send push notifications to the Microsoft Authenticator app.

    Here is an example of how to send a push notification using the Microsoft Graph API in C#:

    GraphServiceClient graphClient = new GraphServiceClient( authProvider );
    
    var notification = new Notification
    {
        Priority = "High",
        TargetPolicy = new TargetPolicy
        {
            Platforms = new List<string> { "ios", "android" },
            ExcludedPlatforms = new List<string> { "windows" },
            IncludeTestVariants = true
        },
        Payload = new Payload
        {
            Notification = new NotificationPayload
            {
                Title = "My Title",
                Body = "My Body"
            }
        }
    };
    
    await graphClient.DeviceAppManagement.MobileApps["{mobileAppId}"].Notifications
        .Request()
        .AddAsync(notification);
    

    Please note that this is just an example and you will need to modify it to fit your specific requirements.

    Please let me know if you have any questions and I can help you further.

    If this answer helps you please mark "Accept Answer" so other users can reference it.

    Thank you,

    James


0 additional answers

Sort by: Most helpful