Register your app to use Microsoft account for authentication
This topic shows you how to register your mobile app to be able to use Microsoft account as an identity provider with Azure Mobile Services. The same steps apply for both service-directed authentication and client-directed authentication using the Live SDK.
Register your Windows Store app at the Windows Dev Center
Windows Store apps must first be registered with the Windows Dev Center.
Windows Phone 8, Windows Phone 8.1 Silverlight, and non-Windows apps can skip this section.
If you have not already registered your app, navigate to the Submit an app page at the Dev Center for Windows Store apps, log on with your Microsoft account, and then click App name.
Select Create a new app by reserving a unique name and click Continue, then type a name for your app in App name, click Reserve app name, and then click Save.
This creates a new Windows Store registration for your app.
In Visual Studio, open the project that you created when you completed the tutorial [Get started with Mobile Services].
In solution explorer, right-click the Windows Store app project, click Store, and then click Associate App with the Store....
This displays the Associate Your App with the Windows Store Wizard.
In the wizard, click Sign in and then login with your Microsoft account, select the app name that you reserved in step 2, click Next, and then click Associate.
This adds the required Windows Store registration information to the application manifest.
(Optional) For a universal Windows app, repeat steps 4 and 5 for the Windows Phone Store project.
Back in the Windows Dev Center page for your new app, click Services.
In the Services page, click Live Services site under Azure Mobile Services.
This displays the Microsoft account page for your app.
Configure your Microsoft account registration and connect to Mobile Services
The first step in this section applies only to Windows Phone 8, Windows Phone 8.1 Silverlight, and non-Windows Store apps. For these apps, you can also ignore the Package security identifier (SID), which is only available for Windows Store apps.
For a non-Windows Store app, navigate to the My Applications page in the Microsoft account Developer Center, log on with your Microsoft account (if required), click Create application, then type an Application name and click I accept.
This reserves you app name with Microsoft account and displays the Microsoft account page for your app.
In the Microsoft account page for your app, click API Settings, select enable Mobile or desktop client app, set the mobile service URL as the Target domain, supply a value of
https://<mobile_service>.azure-mobile.net/login/microsoftaccount/ in Redirect URL, then click Save.
For a .NET backend mobile service published to Azure by using Visual Studio, the redirect URL is the URL of your mobile service appended with the path signin-microsoft your mobile service as a .NET service, such as
The Root domain should be filled-in automatically.
Click App Settings and make a note of the values of the Client ID, Client secret and Package SID.
The client secret is an important security credential. Do not share the client secret with anyone or distribute it with your app. Only Windows Store app registrations will see a Package SID field.
In the Azure Management Portal, click the Identity tab for the mobile service, enter the client ID, client secret and package SID obtained from your identity provider, and click Save.
You do not need to supply a Package SID value for a Windows Phone 8, Windows Phone Store 8.1 Silverlight, or a non-Windows app.
Both your mobile service and your app are now configured to work with Microsoft account.