Forum Discussion

govindarajan_d's avatar
govindarajan_d
Super User
1 year ago
Solved

SSL Verification failed when trying to use OpenAI library

I am using an Azure OpenAI model with Python notebook in Fabric.      client = openai.AzureOpenAI( api_key=AZURE_OPENAI_API_KEY, azure_endpoint=AZURE_OPENAI_ENDPOINT, api_version=API_...
  • nilendraFabric's avatar
    1 year ago

    Hello govindarajan_d 

     

    give it a try

     

    import httpx

    client = openai.AzureOpenAI(
    api_key=AZURE_OPENAI_API_KEY,
    azure_endpoint=AZURE_OPENAI_ENDPOINT,
    api_version=API_VERSION,
    http_client=httpx.Client(verify="/path/to/your/custom_certificate.pem")
    )

     

    not recommended for prod, but lets see if this works