node-facebook
Installation
This is a Node.js module available through the npm registry.
Before installing, download and install Node.js.
Installation is done using npm
or yarn
:
$ npm install node-facebookor$ yarn add node-facebook
Follow node-facebook's wiki for more information.
Feature
This module have function same you use browser.
Usage
-
In first time, you should login with email and password:
-
When you logged in, use
api.getState()
to save cookie with this code:
const fs = ;const Facebook = ; const me = email: 'your username/id' pass: 'your pass';me ;
- Now, you can login with cookie with file
state.json
:
const me = state: JSON;
Example
kiat-bot is sample use node-facebook
Credits
node-facebook
has been inspired by facebook-chat-api
Thanks to Avery Morin for excellent prior art !
Contributors
Thanks goes to these wonderful people (emoji key):
Hongarc 📆 👀 ⚠️ 💻 | Avery Morin 🤔 | Oliver Cristian 📢 |
This project follows the all-contributors specification. Contributions of any kind welcome!