node-line-bot-api icon indicating copy to clipboard operation
node-line-bot-api copied to clipboard

No message response

Open nanthanwa opened this issue 8 years ago • 1 comments

in web hook router

const promises = req.body.events.map(event => { return line.client .replyMessage({ replyToken: event.replyToken, messages: [ { type: 'text', text: event.message.text } ] }) }) Promise .all(promises) .then(() => res.json({success: true}))

It should echo the message but nothing and without any error :(

nanthanwa avatar Oct 19 '17 17:10 nanthanwa

you should need signature header. When I try to execute command, I got following errors instead. Error: A signature header is required at D:\Storage\Project\LineBot\node_modules\node-line-bot-api\lib\clients\v2\SignatureValidator.js:25:15 at Layer.handle [as handle_request] (D:\Storage\Project\LineBot\node_modules\express\lib\router\layer.js:95:5) at next (D:\Storage\Project\LineBot\node_modules\express\lib\router\route.js:137:13) at Route.dispatch (D:\Storage\Project\LineBot\node_modules\express\lib\router\route.js:112:3) at Layer.handle [as handle_request] (D:\Storage\Project\LineBot\node_modules\express\lib\router\layer.js:95:5) at D:\Storage\Project\LineBot\node_modules\express\lib\router\index.js:281:22 at Function.process_params (D:\Storage\Project\LineBot\node_modules\express\lib\router\index.js:335:12) at next (D:\Storage\Project\LineBot\node_modules\express\lib\router\index.js:275:10) at jsonParser (D:\Storage\Project\LineBot\node_modules\body-parser\lib\types\json.js:119:7) at Layer.handle [as handle_request] (D:\Storage\Project\LineBot\node_modules\express\lib\router\layer.js:95:5)

jwilyandi19 avatar May 14 '19 02:05 jwilyandi19