diff --git a/lib/tasks/say.js b/lib/tasks/say.js index 8fa13eaf..99b86a5c 100644 --- a/lib/tasks/say.js +++ b/lib/tasks/say.js @@ -164,6 +164,10 @@ class TaskSay extends Task { 'tts.voice': voice }); try { + if (vendor === 'microsoft' && this.synthesizer.azureServiceEndpoint) { + credentials.use_custom_tts = true; + credentials.custom_tts_endpoint = this.synthesizer.azureServiceEndpoint; + } const {filePath, servedFromCache} = await synthAudio(stats, { text, vendor, diff --git a/lib/tasks/specs.json b/lib/tasks/specs.json index b2d6123c..4cbcd292 100644 --- a/lib/tasks/specs.json +++ b/lib/tasks/specs.json @@ -435,7 +435,8 @@ "gender": { "type": "string", "enum": ["MALE", "FEMALE", "NEUTRAL"] - } + }, + "azureServiceEndpoint": "string" }, "required": [ "vendor"