support inworld tts (#472)

* support inworld tts

* inworld tts voices
This commit is contained in:
Hoan Luu Huu
2025-06-27 22:12:00 +07:00
committed by GitHub
parent 0842793aea
commit 5421f1421f
7 changed files with 241 additions and 6 deletions

View File

@@ -717,6 +717,28 @@ test('speech credentials tests', async(t) => {
t.ok(result.statusCode === 204, 'successfully deleted speech credential for rimelabs');
result = await request.post(`/Accounts/${account_sid}/SpeechCredentials`, {
resolveWithFullResponse: true,
auth: authUser,
json: true,
body: {
vendor: 'inworld',
use_for_stt: false,
use_for_tts: true,
api_key: 'asdasdasdasddsadasda',
model_id: 'inworld-tts-1',
}
});
t.ok(result.statusCode === 201, 'successfully added speech credential for inworld');
const inworld_sid = result.body.sid;
/* delete the credential */
result = await request.delete(`/Accounts/${account_sid}/SpeechCredentials/${inworld_sid}`, {
auth: authUser,
resolveWithFullResponse: true,
});
t.ok(result.statusCode === 204, 'successfully deleted speech credential for inworld');
/* add a credential for custom voices google */
result = await request.post(`/Accounts/${account_sid}/SpeechCredentials`, {
resolveWithFullResponse: true,