mirror of
https://github.com/jambonz/jambonz-api-server.git
synced 2026-02-09 02:29:59 +00:00
fix fetch eleven voice and language (#241)
This commit is contained in:
@@ -797,7 +797,7 @@ router.post('/languages', async(req, res) => {
|
|||||||
});
|
});
|
||||||
|
|
||||||
const getTtsVoices = async(vendor, label, service_provider_sid, account_sid) => {
|
const getTtsVoices = async(vendor, label, service_provider_sid, account_sid) => {
|
||||||
const credentials = await SpeechCredential.isAvailableVendorAndLabel(
|
const credentials = await SpeechCredential.getSpeechCredentialsByVendorAndLabel(
|
||||||
service_provider_sid, account_sid, vendor, label);
|
service_provider_sid, account_sid, vendor, label);
|
||||||
const cred = credentials && credentials.length > 0 ? credentials[0] : null;
|
const cred = credentials && credentials.length > 0 ? credentials[0] : null;
|
||||||
if (vendor === 'elevenlabs') {
|
if (vendor === 'elevenlabs') {
|
||||||
@@ -819,7 +819,7 @@ const getTtsVoices = async(vendor, label, service_provider_sid, account_sid) =>
|
|||||||
};
|
};
|
||||||
|
|
||||||
const getTtsLanguages = async(vendor, label, service_provider_sid, account_sid) => {
|
const getTtsLanguages = async(vendor, label, service_provider_sid, account_sid) => {
|
||||||
const credentials = await SpeechCredential.isAvailableVendorAndLabel(
|
const credentials = await SpeechCredential.getSpeechCredentialsByVendorAndLabel(
|
||||||
service_provider_sid, account_sid, vendor, label);
|
service_provider_sid, account_sid, vendor, label);
|
||||||
const cred = credentials && credentials.length > 0 ? credentials[0] : null;
|
const cred = credentials && credentials.length > 0 ? credentials[0] : null;
|
||||||
if (vendor === 'elevenlabs') {
|
if (vendor === 'elevenlabs') {
|
||||||
|
|||||||
Reference in New Issue
Block a user