Thanks for posting your question in the Microsoft Q&A forum.
These issues are common and can be resolved with a few adjustments.
The error message you're receiving indicates a mismatch between the hostname in the SSL certificate and the private link URL, this error occurs because the SSL certificate is still associated with the public endpoint, not the private one. To resolve this :
- Use the public endpoint URL in your code, not the private link URL
- Azure will automatically route the traffic through the private endpoint if it's configured correctly
To resolve the error message you're seeing with Entra ID authentication suggests a permissions:
- You need to provision an App Registration and use Managed Identity with the appropriate role assigned to access the OpenAI API
- Ensure that the managed identity has the
Cognitive Services OpenAI User
role assigned to it for the Azure OpenAI resource
Please don't forget to close up the thread here by upvoting and accept it as an answer if it is helpful