Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

fb-messenger-bot-chat

Package Overview
Dependencies
Maintainers
1
Versions
17
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

fb-messenger-bot-chat - npm Package Compare versions

Comparing version 0.0.7 to 0.0.8

2

package.json
{
"name": "fb-messenger-bot-chat",
"version": "0.0.7",
"version": "0.0.8",
"description": "Facebook Messenger Bot Send API implementation and chat simulator",

@@ -5,0 +5,0 @@ "main": "index.js",

@@ -76,2 +76,18 @@ module.exports = (config) => {

var mappedCards = cards.map(function(card) {
if (_.isArray(card.buttons)) {
card.buttons = card.buttons.map(function(btn) {
if (_.isObject(btn.payload)) {
btn.payload = JSON.stringify(btn.payload);
}
return btn;
});
}
return card;
});
var message = {

@@ -82,3 +98,3 @@ attachment: {

template_type: "generic",
elements: cards
elements: mappedCards
}

@@ -100,3 +116,3 @@ }

}
if (!message || !message.sender || !message.sender.id) { return recognizedMessage; }

@@ -103,0 +119,0 @@

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc