Skip to content
This repository has been archived by the owner on Nov 9, 2023. It is now read-only.

ISTIC-DevSpace/miscord

 
 

Repository files navigation

banner

Built on facebook-chat-api and discord.js

code style: Standard.js Travis NPM downloads NPM version GitHub release Requires.io

Website   Donate   FAQ   Support Server


Setup

Discord Bot

  • Create new Discord application here
  • Click "new app", choose a name for your application, confirm by clicking "create app"
  • Create a Bot User on your app's page
  • Open "OAuth URL Generator", choose scope bot
  • Add permissions: Manage Channels and whole Text Permissions group, then copy link to your browser
  • Add your bot to chosen guild(s)

Installation

Try not to create channels in bots category. If you really need, make sure the channel hasn't got only numbers in its topic.
Make sure you have "Show website preview info from links pasted into chat" enabled in "Text & Images" Discord settings

Configuration

Configuration file:

  • Windows: %appdata%/Miscord/config.json
  • Mac: ~/Library/Application Support/Miscord/config.json
  • Linux: ~/.config/Miscord/config.json
  • Other: ~/.miscord/config.json
Category Config variable Environmental variable Description Optional Default value
Miscord
*
MISCORD_*
logLevel LOG_LEVEL Log level (see here) ✔️ "info"
checkUpdates CHECK_UPDATES Checking updates ✔️ true
custom CUSTOM Custom channel map (see here) ✔️ {}
Messenger
messenger.*
MESSENGER_*
username USERNAME Messenger username ✖️ ✖️
password PASSWORD Messenger password ✖️ ✖️
forceLogin FORCE_LOGIN Forces logging in to Facebook ✔️ false
showUsername SHOW_USERNAME Shows Discord usernames on Facebook ✔️ true
boldUsername BOLD_USERNAME Makes Discord usernames on Facebook bold (see #88) ✔️ false
filter.whitelist FILTER_WHITELIST Messenger chat filtering (see here) ✔️ []
filter.blacklist FILTER_BLACKLIST Messenger chat filtering (see here) ✔️ []
Discord
discord.*
DISCORD_*
token TOKEN Discord token ✖️ ✖️
guild GUILD Discord guild (server) ✔️ (first guild available)
category CATEGORY Discord category on server ✔️ new category named messenger
sendNotifications SEND_NOTIFICATIONS Sends notifications when appending to existing embeds (see #71) ✔️ true
noEmbeds NO_EMBEDS Sends plaintext messages without embeds ✔️ false
renameChannels RENAME_CHANNELS Renames channels according to Messenger ✔️ true
showEvents SHOW_EVENTS Shows Facebook events on Discord ✔️ false

Running

Binaries/NPM install

Run miscord in the console.
If you store your config somewhere else, you can run it with miscord --config {path}

Local install

Enter the Miscord directory where you cloned it (cd miscord)
Run it using npm start.
If you store your config somewhere else, you can run it with npm start -- --config {path} (note the -- before --config)
(Note: you can enable developing environment with NODE_ENV=development. Miscord will read config.json from your current directory)

Module usage

You can use Miscord as a module in your script
Example:

const miscord = require('miscord')
const config = // ...

miscord(config).then(config => {
  // there are Discord and Messenger clients added to config variable
  // config.messenger.client
  // config.discord.client
}

Donate

Donate

BTC: 36tci1gptNyPhvSJkrHg2EdVmH82cwW56R
ETH: 0xe841ef23e1b94ed2122d248377e9fbeffebaad35
ZEC: t1ULEWqCCmVxmaxsRn5KGRXnDmeBY68uMWL

About

Facebook Messenger to Discord bridge

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • JavaScript 100.0%