Reputation: 932
Steps Followed:
(Content-Type and Ocp-Apim-Subscription-Key)
{
"recordingsUrl": "https://transcribehm97c1.blob.core.windows.net/audio-files/2019-04-04_Blockchain%20explained%20with%20TruStory%27s%20Preethi%20Kasireddy.mp3?st=2019-05-27T12%3A19%3A27Z&se=2019-12-31T12%3A19%3A00Z&sp=rl&sv=2018-03-28&sr=b&sig=HFBvGl1pmCM95MNU9U3yniMNXrUMT6RmPb36F32cxrY%3D",
"models": [],
"locale": "en-US",
"name": "I dont know why this is not working",
"description": "Someone please send help",
"properties": {
"ProfanityFilterMode": "Masked",
"PunctuationMode": "DictatedAndAutomatic"
}
}
location: https://westus.cris.ai/api/speechtotext/v2.0/transcriptions/69b7abf4-6383-4490-88a9-9fd42a77e470
{
"recordingsUrl": "https://transcribehm97c1.blob.core.windows.net/audio-files/2019-04-04_Blockchain explained with TruStory's Preethi Kasireddy.mp3?st=2019-05-27T12:19:27Z&se=2019-12-31T12:19:00Z&sp=rl&sv=2018-03-28&sr=b&sig=HFBvGl1pmCM95MNU9U3yniMNXrUMT6RmPb36F32cxrY%3D",
"resultsUrls": {},
"models": [“I have removed this for brevity”],
"statusMessage": "The recordings URI is invalid.",
"id": "69b7abf4-6383-4490-88a9-9fd42a77e470",
"createdDateTime": "2019-05-27T12:43:39Z",
"lastActionDateTime": "2019-05-27T12:43:50Z",
"status": "Failed",
"locale": "en-US",
"name": "I dont know why this is not working",
"description": "Someone please send help",
"properties": {
"ProfanityFilterMode": "Masked",
"PunctuationMode": "DictatedAndAutomatic"
}
}
Link to Swagger Page : https://westus.cris.ai/swagger/ui/index
Upvotes: 2
Views: 1712
Reputation: 37
Here are two things that helped me create a SAS URL to feed into the Azure Speech Batch transcription service. I was frustratingly getting the "Authentication failed for recordings URI." message.
Weekly standup.mp4
(two spaces) but in the storage interface it appeared as Weekly standup.mp4
(one space). It is best to fetch your blob name programmatically to then feed it to your downstream task rather than to copy it from the interface. from azure.storage.blob import generate_blob_sas, BlobSasPermissions
from datetime import datetime, timezone, timedelta
sas_token = generate_blob_sas(
account_name=account_name,
account_key=account_key,
container_name = container_name,
blob_name = blob_name,
permission=BlobSasPermissions(read=True),
start=datetime.now(timezone.utc) - timedelta(hours=8),
expiry=datetime.now(timezone.utc) + timedelta(hours=8)
)
Upvotes: 0