New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

facebook-send-api-sdk

Package Overview
Dependencies
Maintainers
1
Versions
24
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

facebook-send-api-sdk - npm Package Compare versions

Comparing version 0.0.1 to 0.0.2

2

package.json
{
"name": "facebook-send-api-sdk",
"version": "0.0.01",
"version": "0.0.02",
"description": "Facebook SendApi SDK",

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

@@ -12,7 +12,6 @@ 'use strict';

function SendApiSdk(accessToken) {
apiUrl = 'https://graph.facebook.com/v2.11/me/messages?access_token=' + accessToken;
function SendApiSdk() {
apiUrl = 'https://graph.facebook.com/v2.11/me/messages?access_token=';
requestOptions = {
method: 'POST',
uri: apiUrl,
json: true

@@ -22,4 +21,5 @@ };

SendApiSdk.prototype.sendMessage = function (messageRequestOrTemplate, typing) {
SendApiSdk.prototype.sendMessage = function (accessToken, messageRequestOrTemplate, typing) {
const options = JSON.parse(JSON.stringify(requestOptions));
options.uri = apiUrl + accessToken;
options.body = messageRequestOrTemplate;

@@ -49,9 +49,10 @@

SendApiSdk.prototype.sendTypingIndicator = function (recipient) {
return SendApiSdk.prototype.sendAction(recipient, constants.MessageState.TYPING_ON);
SendApiSdk.prototype.sendTypingIndicator = function (accessToken, recipient) {
return SendApiSdk.prototype.sendAction(accessToken, recipient, constants.MessageState.TYPING_ON);
};
SendApiSdk.prototype.sendAction = function (recipient, sender_action) {
SendApiSdk.prototype.sendAction = function (accessToken, recipient, sender_action) {
const options = JSON.parse(JSON.stringify(requestOptions));
options.uri = apiUrl + accessToken;
options.body = {

@@ -58,0 +59,0 @@ recipient: recipient,

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