facebook-chat-api | Unofficial Facebook Chat API for Nodejs | REST library
kandi X-RAY | facebook-chat-api Summary
kandi X-RAY | facebook-chat-api Summary
Facebook now has an official API for chat bots here. This API is the only way to automate chat functionalities on a user account. We do this by emulating the browser. This means doing the exact same GET/POST requests and tricking Facebook into thinking we're accessing the website normally. Because we're doing it this way, this API won't work with an auth token but requires the credentials of a Facebook account. Disclaimer: We are not responsible if your account gets banned for spammy activities such as sending lots of messages to people you don't know, sending messages very quickly, sending spammy looking URLs, logging in and out very quickly... Be responsible Facebook citizens. See below for projects using this API. See the full changelog for release details.
Support
Quality
Security
License
Reuse
Top functions reviewed by kandi - BETA
- Listen on the server
- Formats the attachment for a single attachment .
- handle the delta message
- Formats the messages to be posted to the console .
- generates the login dialog
- Listen for MQTT .
- Formats the attachment of attachment to a message .
- Parse and return a function which parses login and logs out of logged in .
- Format an attachment .
- Login function
facebook-chat-api Key Features
facebook-chat-api Examples and Code Snippets
Community Discussions
Trending Discussions on facebook-chat-api
QUESTION
I have a simple cli node script that I want to pack using pkg
.
I've tried with the following command
ANSWER
Answered 2021-Apr-13 at 14:28Seems like you're missing an s
: use --targets
instead of --target
pkg can generate executables for several target machines at a time. You can specify a comma-separated list of targets via --targets
QUESTION
I'm using Facebook chat api to create a simple cli script that will reply to messages that are sent to my facebook account. I'm trying to assign and get the user name and my name to use them inside the reply but they are always undefined. I think that the object property aren't assigned correctly. Is there a fix for this?
...ANSWER
Answered 2021-Feb-15 at 10:36I think the problem here is that api.getUserInfo
is asynchronous.
So you would need to nest them to get it to work.
Or you can try this, since getUSerInfo allows you to add an array of user ids to get the data for:
QUESTION
I've created a .env
file inside my node cli script folder. I'm trying to load the variables I've defined inside it by using the process.env.MY_VARIABLE
but I've noticed that they are undefined.
at the moment this is the code inside the index.js
file of my cli script
ANSWER
Answered 2021-Feb-14 at 14:48How are you loading the .env file ? This mapping of the .env to the process.env
doesn't happen automatically. You can have a look on https://www.npmjs.com/package/dotenv for loading an .env file to you process.env
.
Another way of doing that is having FB_EMAIL
and FB_PWD
in your environment from where you run that cli tool. You could try on your terminal export FB_EMAIL=****
Community Discussions, Code Snippets contain sources that include Stack Exchange Network
Vulnerabilities
No vulnerabilities reported
Install facebook-chat-api
Support
Reuse Trending Solutions
Find, review, and download reusable Libraries, Code Snippets, Cloud APIs from over 650 million Knowledge Items
Find more librariesStay Updated
Subscribe to our newsletter for trending solutions and developer bootcamps
Share this Page