Unknown error in sending http request with Azure Cognitive Services

fabsese 5 Reputation points
2023-07-07T01:42:10.1433333+00:00

On my testing machine (Github codespace) everything works, but when I publish my changes and update my main project (Server located in Brazil), I get the following:

Error reason: ImageAnalysisErrorReason.CONNECTION_FAILURE
Error code: -1
Error message: Unknown error in sending http request

Additionally, if I make a Postman request to the same endpoint or I navigate to the endpoint in my browser, I get:

{
    "error": {
        "code": "404",
        "message": "Resource not found"
    }
}

I would expect the response to be something along the lines of "Invalid authentication" instead of "Not found"

Some searching online led me to a stackoverflow issue suggesting my endpoint formatting was incorrect, my endpoint shown on the Azure dashboard is https://[resourceName].cognitiveservices.azure.com/

whereas my speech endpoint is

https://eastus.api.cognitive.microsoft.com/sts/v1.0/issuetoken

I'm wondering if its incorrect?? Each endpoint is formatted differently, and on the stackoverflow issue I notice the solution was to use an endpoint similar to my speech endpoint, but this has not worked either.

I am using Python with the azure-ai-vision sdk version 0.13.0b1

Azure IoT SDK
Azure IoT SDK
An Azure software development kit that facilitates building applications that connect to Azure IoT services.
219 questions
Azure AI services
Azure AI services
A group of Azure services, SDKs, and APIs designed to make apps more intelligent, engaging, and discoverable.
2,824 questions
{count} votes

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.