All Projects → YunoHost-Apps → mautrix_whatsapp_ynh

YunoHost-Apps / mautrix_whatsapp_ynh

Licence: AGPL-3.0 License
Matrix Whatsapp pupetting bridge for YunoHost

Programming Languages

shell
77523 projects

Projects that are alternatives of or similar to mautrix whatsapp ynh

grav ynh
Grav, a flat-file CMS packaged for YunoHost
Stars: ✭ 13 (+8.33%)
Mutual labels:  yunohost-apps
funkwhale ynh
A modern, convivial and free music server on YunoHost
Stars: ✭ 59 (+391.67%)
Mutual labels:  yunohost-apps
gitlab ynh
GitLab package for YunoHost
Stars: ✭ 17 (+41.67%)
Mutual labels:  yunohost-apps
element ynh
Element package for YunoHost
Stars: ✭ 16 (+33.33%)
Mutual labels:  yunohost-apps
borg ynh
An experimental Borg implementation for YunoHost
Stars: ✭ 18 (+50%)
Mutual labels:  yunohost-apps
wireguard ynh
WireGuard VPN software with a web UI configuration companion, packaged for YunoHost.
Stars: ✭ 24 (+100%)
Mutual labels:  yunohost-apps
duniter ynh
Duniter package for YunoHost
Stars: ✭ 14 (+16.67%)
Mutual labels:  yunohost-apps
nextcloud ynh
Nextcloud package for YunoHost
Stars: ✭ 120 (+900%)
Mutual labels:  yunohost-apps
syncthing ynh
Syncthing package for YunoHost
Stars: ✭ 27 (+125%)
Mutual labels:  yunohost-apps
wikijs ynh
Modern and powerful wiki app package for YunoHost
Stars: ✭ 19 (+58.33%)
Mutual labels:  yunohost-apps
mastodon ynh
Free, open-source social network for YunoHost
Stars: ✭ 67 (+458.33%)
Mutual labels:  yunohost-apps
redirect ynh
Redirection app for YunoHost
Stars: ✭ 37 (+208.33%)
Mutual labels:  yunohost-apps
ttrss ynh
Tiny Tiny RSS package for YunoHost
Stars: ✭ 17 (+41.67%)
Mutual labels:  yunohost-apps
discourse ynh
Discourse package for YunoHost
Stars: ✭ 23 (+91.67%)
Mutual labels:  yunohost-apps

A Matrix-WhatsApp puppeting bridge for YunoHost

How components fit togeter

Integration level
Install Mautrix-WhatsApp with YunoHost

Lire ce readme en français.

This package allows you to install a Mautrix-WhatsApp bridge quickly and simply on a YunoHost server alongside Matrix-Synapse.
If you don't have YunoHost, please see here to know how to install and enjoy it.

Overview

A puppeting bridge between Matrix and WhatsApp packaged as a YunoHost service. Messages, media and notifications are bridged between a WhatsApp user and a matrix user. With the RelayBot login option, the matrix user can invite other matrix user in a bridged WhatsApp room, such that even people without a WhatsApp account can participate to WhatsApp group conversations. The "Mautrix-WhatsApp" bridge consists in a synapse app service and relies on postgresql (mysql also available). Therefore, Synapse for YunoHost should be installed beforehand.

** Attention: always backup and restore the Yunohost matrix_synapse et mautrix_whatsapp apps together!**

Shipped version: 0.2.3

Screenshots

![](Link to an screenshot for this app)

List of known public services

  • Ask on one of the following rooms: #mautrix_yunohost:matrix.fdn.fr or #whatsapp:maunium.net

Bridging usage

** Note that several WhatsApp and Matrix users can be bridged, each WhatsApp account has its own bot administration room. If they are in a same WhatsApp group, only one matrix room will be created. **

Bridge a WhatsApp user and a Matrix user

  • First your matrix user or server has to be authorized in the bridge configuration (see below)
  • Then, invite the bot (default @whatsappbot:yoursynapse.domain)
  • The room with the Mautrix-WhatsApp bot is called "administration room".
  • Type login
  • Capture the QR code with the camera in the whatsapp of your VM or smartphone (WhatsApp Web)
  • Send help to the bot in the created room to know how to control the bot. See also upstream wiki Authentication page

Bridge an existing room | Bridge Whatsapp to Signal over Matrix

By default, the bridge creates a portal room for each WA group that the WA user actively uses. Your can also create a portal for an existing Matrix room. Note that this can be a room created by another bridge, e.g. a Signal portal room

  1. Invite the bridge bot to the room (with an authorized user)
  2. type !wa create
  3. Your logged in WA user creates a new corresponding group.
  4. Get the WA invite link !wa invite-link and share it with friends. Or invite Whatsapp puppets to room.
  5. Optional: Activate relaybot, see next section.

Relaybot: Bridge a group for several Matrix and several WhatsApp users to chat together

When upgrading from <v0.2.0, the relaybot system changed. There is no relaybot administration room anymore. Relay must be re-activated in all rooms.

To be able to bridge not only your logged in Matrix account but also Matrix friends you invite to a portal room, you need to:

  1. enable relaybot setting in the bridge configuration relay: enabled: true
  2. login to your WhatsApp account in the (main) administration room
  3. write !wa set-relay in each of the rooms you want to relay to (re-)activate the relaybot function. By default, only bridge admin can do this, see setting admin_only: true
  • In WhatsApp: all messages will be seen as received from the account who is logged in with a prefix for the source matrix user.
  • On the matrix side: the bridge will create matrix puppets corresponding to the WhatsApp users when they send a message. See also upstream wiki Relaybot page

Configuration of the bridge

The bridge is roughly configured at installation, e.g. allowed admin and user of the bot. Finer configuration can be done by modifying the following configuration file with SSH: /opt/yunohost/mautrix_whatsapp/config.yaml and then restarting the mautrix_whatsapp service.

Documentation

  • Official "Mautrix-WhatsApp" documentation: https://docs.mau.fi/bridges/go/whatsapp/index.html
  • Matrix room (matrix bridges in Yunohost): #mautrix_yunohost:matrix.fdn.fr
  • Matrix room (upstream app): #whatsapp:maunium.net In case you need to upload your logs somewhere, be aware that they contain your contacts' and your phone numbers. Strip them out with | sed -r 's/[0-9]{10,}/📞/g'
  • "Mautrix-WhatsApp" bridge is based on the Rhymen/go-whatsapp implementation of the sigalor/whatsapp-web-reveng project.
  • YunoHost documentation: If more specific documentation is needed, feel free to contribute.

YunoHost specific features

Multi-users support

  • Bot users are not related to Yunohost users. Any Matrix account or Synapse server autorized in the configuration of the bridge can invite/use the bot.
  • The WhatsApp bot is a local Matrix-Synapse user, but accessible through federation (synapse public or private).
  • Several Signal and Matrix users can be bridged with one bridge, each user has its own bot administration room.
  • If several bot users are in a same WhatsApp group, only one Matrix room will be created by the bridge.
  • See https://github.com/YunoHost-Apps/synapse_ynh#multi-users-support

Multi-instance support

  • Multi-instance installation should work. Several bridge instances could be installed for one Matrix-Synapse instance so that one Matrix user can bridge several WhatsApp accounts.
  • Several bridge instances could be installed for each Matrix-Synapse instance to benefit from it. But one bridge can be used by users from several Matrix-Synapse instances.

Supported architectures

  • Tested on ARMv7 in April 2020
  • x86-64b - Build Status
  • ARMv8-A - Build Status

Limitations

  • Audio/Video calls are not bridged yet.
  • If WhatsApp loses connection, e.g. the phone is set in flight mode or push notifications are deactivated, the bot has sometimes to be restarted manually by sending a reconnnect message in the matrix administration room.

Additional information

More information on the documentation page:
https://docs.mau.fi/bridges/go/whatsapp/index.html

Links


Developer info

Please do your pull request to the testing branch. To try the testing branch, please proceed like that:

sudo yunohost app install https://github.com/YunoHost-Apps/mautrix_whatsapp_ynh/tree/testing --debug
or
sudo yunohost app upgrade mautrix_whatsapp -u https://github.com/YunoHost-Apps/mautrix_whatsapp_ynh/tree/testing --debug

To test communication between the App Service and Matrix-Synapse on a VM (e.g. with domain name: synapse.vm), you must install a certificate:

echo | openssl s_client -showcerts -servername synapse.vm -connect synapse.vm:443 2>/dev/null | awk '/-----BEGIN CERTIFICATE-----/, /-----END CERTIFICATE-----/' >> /usr/local/share/ca-certificates/synapse.vm.crt
update-ca-certificates
Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].