Reputation: 67
I have uploaded an audio file on GCS bucket and then I created a signed URL for the file using this method:
storage.signUrl(
blobInfo,
DURATION,
TimeUnit.DAYS,
Storage.SignUrlOption.httpMethod(HttpMethod.GET),
Storage.SignUrlOption.withContentType()
);
When I pass this URL to Azure cognitive Speech to text service using the batch transcription REST API this is the request body of azure's create transcription API
{
"contentUrls": [
"gcpsignedurl"
],
"properties": {
"diarizationEnabled": false,
"wordLevelTimestampsEnabled": false,
"punctuationMode": "DictatedAndAutomatic",
"profanityFilterMode": "Masked"
},
"locale": "en-US",
"displayName": "Transcription using default model for en-US"
}
the transcription job gets created and I get the location URL of transcription from the header, now when I Am calling the location URL I get this error
"error": {
"code": "InvalidUri",
"message": "Authentication failed for recordings URI."
}
"status": "Failed"
how do I solve this problem?
Upvotes: 0
Views: 189
Reputation: 498
I think you are using Speech to Text API V3.0 - Batch transcription, it can read audio from a public-visible internet URI, and can read audio or write transcriptions using a SAS URI with Azure Blob storage. You need to make sure your GCP url is public and can be read without any authentication.
Upvotes: 0