diff --git a/voiceai-server.js b/voiceai-server.js index 67d9bb4..e2268f1 100644 --- a/voiceai-server.js +++ b/voiceai-server.js @@ -51,7 +51,7 @@ app.post('/respond',async(req,res)=>{ }); const t=new twilio.twiml.VoiceResponse(); t.say({voice:'Polly.Joanna-Neural'},'One moment please.'); - t.pause({length:2}); + t.pause({length:1}); t.redirect({method:'POST'},'https://voice.onsethost.com/check?sid='+sid+'&attempt=0'); res.type('text/xml');res.send(t.toString()); }); @@ -71,7 +71,7 @@ app.post('/check',async(req,res)=>{ t.say({voice:'Polly.Joanna-Neural'},'Thank you for calling. Goodbye!'); t.hangup(); } else if(attempt<20){ - t.pause({length:2}); + t.pause({length:1}); t.redirect({method:'POST'},'https://voice.onsethost.com/check?sid='+sid+'&attempt='+(attempt+1)); } else { t.say({voice:'Polly.Joanna-Neural'},'I apologize for the delay. Please call back shortly.');