Reputation: 113
I have already tried with free trial keys associated with two different email addresses and a "Pay as you go" billing. They all returned this same message:
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.
I am using this FACE API getting started tutorial
private readonly IFaceServiceClient faceServiceClient = new FaceServiceClient("39a8b...0fd1");
var faces = await faceServiceClient.DetectAsync(imageFileStream);
Upvotes: 2
Views: 1236
Reputation: 11
I have changed the URL to "https://westcentralus.api.cognitive.microsoft.com/face/v1.0" and it works
It seems that the KEYs are not replicated to all locations
Upvotes: 1
Reputation: 8491
I have an endpoint defined in the Portal "eastus2.api.cognitive.microsoft.com/face/v1.0"; but I don't know how to associated this endpoint with my service calls. What am I missing, please?
If you got the endpoint, you could put it in the constructor of FaceServiceClient. Code below is for your reference.
private readonly IFaceServiceClient faceServiceClient =
new FaceServiceClient("your_key", "https://eastus2.api.cognitive.microsoft.com/face/v1.0");
Upvotes: 3