Using different Microsoft Cognitve servers with on

2019-09-21 03:34发布

问题:

FaceAPI services. Using inside ASP.NET MVC web application. Net Framework 4.6

In Apr/2017 I obtained free access key for FaceAPI, however, for some unknown for me reason i could access only "West US" server (westus.api.cognitive.microsoft.com) and general server (api.cognitive.microsoft.com).

Once i am trying to login into "West Europe" server i got error "Access denied due to invalid subscription key. Make sure you are subscribed to an API you are trying to call and provide the right key."

So, my questions are:

1) how can I connect to "West Europe" server ?

2) where I could see to what region belong my subscription key?

回答1:

The West Europe API endpoint is https://westeurope.api.cognitive.microsoft.com/face/v1.0. As you've discovered, a subscription key for one region is not valid in another.

I'm not aware of any subscription key -> location mapping. Since the only two options available to you right now are 'westus' and 'westeuprope', you could determine which through the process of elimination.



回答2:

There are no way to change region. During registration in Microsoft\Azure you indicate your Country, that is it, no more way to change it.