Spaces:
Runtime error
Runtime error
File size: 663 Bytes
2161081 9cbdeca 2161081 9cbdeca 2161081 9cbdeca 2161081 feb212b 9cbdeca feb212b 2161081 |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 |
var express = require('express');
var router = express.Router();
var textToSpeech = require('../helpers/tts');
/* POST /talk */
router.post('/talk', function(req, res, next) {
// Commenting out the function call for now
// textToSpeech(req.body.text, req.body.voice)
// .then(result => {
// res.json(result);
// })
// .catch(err => {
// res.json({});
// });
// Return a dummy string as output
res.json({ message: "Dummy response: text-to-speech is temporarily disabled." });
});
/* GET home page. */
router.get('/', function(req, res, next) {
res.render('index', { title: 'Express' });
});
module.exports = router;
|