Aug 25 2023 04:09 PM - edited Aug 25 2023 05:40 PM
Azure OpenAI provides integration with a Web App, and you can have your own Conversational Web Bot up and running in minutes!
We are going to provide access to this Web App , for another Entra ID Directory so customers or collaborators in general can authenticate and use the App.
Reference Architecture
Steps:
We have seen that we can create a new Web App directly from the Playground :
Just select the Subscription and the plan and sit and relax while your App is being deployed!
While we can use our Directory's (tenant) credentials to open the Web UI we want to provide access to another Microsoft Entra ID directory.
From the Azure portal, select the newly created Web App and go to Settings-Authentication:
Add a new Identity Provider of type Customer :
Now, go to the actual Directory where your users want to utilize the Web App.
Create a new App Registration and a Secret, proceed to add a Web URI with this value and register your App :
https://<yourapp>.azurewebsites.net/.auth/login/aad/callback
Add also the base URI being https://<appname>.azurewebsites.net
Create a new secret and add the option to request a token from the Authorization Endpoint with ID Tokens:
Now that you have the App Registration details, return to the Web App and enter the required details, Application ID, Secret from the previous Directory App Registration and the issuer URL which should be as follows:
https://sts.windows.net/<OTHER-TENANT-ID>/v2.0
Proceed without any changes and we are done !
We may have to wait up to 10 minutes, but i have seen it working in a couple of minutes !
It is better to start from the Azure OpenAI Studio , sometimes i have seen better response for the first time rather from the Browse button, but eventually it will work from both selections :
You will be presented with the familiar Azure AD\Entra ID directory login, and the first time you will have to accept consent for the Application.
That’s it ! Ready to provide Azure OpenAI Web App to a secondary Azure Tenant via the Identity Configurations we applied !
OpenAI is a powerful tool that can be used to improve the functionality and user experience of web applications. By integrating OpenAI APIs and models into a web app, developers can add advanced natural language processing capabilities, language generation, and more. This can enhance the app’s ability to understand and respond to user inputs, leading to a more personalized and intuitive experience. Additionally, OpenAI can help streamline backend processes, such as data analysis and prediction, ultimately leading to more efficient and effective web applications. Overall, the use of OpenAI in a web app can improve both user experience and business outcomes.
Links - References