Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我正在使用 nodejs 作为后端。我能够从 Gupshup api 接收 webhook。收到 webhook 后,我的响应状态为 200。
res.sendStatus(200);
Gupshup whatsApp api 在自动接收 webhook 后返回 200 时向用户发送“ok”消息。
这里好的不是出站api的消息。而是由 Gupshup api 自动响应。
代替,
res.sendStatus(200) // equivalent to res.status(200).send('OK')
您应该发送一个 nil 响应。
res.end()
OK 由 gupshup 作为消息转发给用户