Reputation: 187
I have created a C# app with an MSOL authentication prompt. This auth prompt authenticates the user to my app and to my Asana integration. This works fine.
I now need to give my app permissions to access SQL databases in my Azure App Registration, but I can't find the API listed in the "Request API Permissions" section.
Does anyone know how I am supposed to grant my app access to SQL? Currently I get an error from my app stating that it does not have access to the database. I have already set my AAD account as an admin of the DB but I still cannot access it.
Edit: This is the problem I am facing. Should be an option for SQL server.
Upvotes: 6
Views: 2814
Reputation: 187
Figured it out.
For the Azure SQL Database option to show in the API Permissions you first need to create an Azure SQL Database and add yourself as either an admin or user and then login to that database via SQL Server Management Studio using Azure AD Credentials.
Once you have done that, the API still will not show without manually searching for "Azure SQL Database".
Microsoft should really make this stuff clear in their documentation.
Upvotes: 3