How to use pidgin-whatsapp in Ubuntu?

Solution 1:

You need to add its repository before you try to install the plugin.

Execute the following:

sudo add-apt-repository ppa:whatsapp-purple/ppa
sudo apt-get update
sudo apt-get install pidgin-whatsapp

Solution 2:

How To: Use WhatsApp under Ubuntu

There are many ways to get WhatsApp Messenger to work on Ubuntu, some I have tried, such as a native WhatsApp replacement called WhosThere (Now Discontinued), or via emulator. You can read more about all that here: "WhatsApp and Viber in Ubuntu 13.04". But, we will now get WhatsApp to work using Pidgin, the universal chat client, with a third party plugin called whatsapp-purple. Do note that WhatsApp cannot be activated on your Desktop and phone at the same time.

Yowsup

Yowsup is - simply put - A library to use WhatsApp from Python. Not so simply put:

Yowsup allows you to login and use the Whatsapp service and provides you with all capabilities of an official Whatsapp client, allowing you to create a full-fledged custom Whatsapp client. - About Yowsup, github.com/tgalal/yowsup/

Yowsup depends on some packages, install them as follows:

sudo apt-get install python python-dateutil python-argparse

The commands below will download, unpack, and open the Yowsup config file.

wget https://github.com/tgalal/yowsup/archive/master.zip
unzip master.zip
cd yowsup-master/src
cp config.example yowsup-cli.config
nano yowsup-cli.config

You don't have to use nano, use an editor that you are most comfortable with. As you are editing the yowsup config file: yowsup-cli.config, find the line phone=XXXXXXXXXX, type in you phone number with country code (For example: +31612345678).

When you have done that, we'll have to make the file executable: chmod +x yowsup-cli. When we are able to execute the file, we will request an authorization code:

./yowsup-cli --requestcode sms --config yowsup-cli.config

After you received the code - usually in the following format: "XXX-XXX" - we will register it:

./yowsup-cli --register XXX-XXX --config yowsup-cli.config

It should display the information you need. In my case it displayed it immediately after running the command:

./yowsup-cli --register 503-417 --config yowsup-cli.config
Detected cc: 31
status: ok
kind: paid
pw: EDITED OUT
price: € 0,89
price_expiration: EDITED OUT
currency: EUR
cost: 0.89
expiration: 4444444444.0
login: EDITED OUT
type: existing 

Don't close that terminal window. I could not find the outputted information anywhere. Copy the information from the terminal using Cntrl + Shift + C. Save it somewhere, for example in yosup.txt.

Pidgin

Now, we will install pidgin, and the pidgin-whatsapp plugin:

sudo add-apt-repository ppa:whatsapp-purple/ppa
sudo apt-get update
sudo apt-get install pidgin pidgin-whatsapp

Select the WhatsApp protocol from the drop down menu:

Your user name is your phone number, with country code, and password is in the file you previously copied and saved. pw: longpassword. Copy them both in, click add, then you should get all the groups you're in. Again, remember, this cannot work when you also have it activated on your phone. Either desktop, or phone, but not both at the same time.

Pidgin Account Window

That was it. Hopefully in the future they will change the infrastructure so that both can be activated at the same time. Or even better, follow in the footsteps of Viber, and release a desktop client for Linux.

References:

  • askubuntu.com: Whatsapp Help for Ubuntu 14.04! [duplicate]
  • pidgin.im: Pidgin, the universal chat client
  • developer.pidgin.im: ThirdPartyPlugins – Pidgin
  • github.com: davidgfnet/whatsapp-purple
  • launchpad.net: whatsapp-purple : “whatsapp-purple Packagers” team

Source:

Excerpt from:

  • How To: Use WhatsApp under Ubuntu - EuroBytes

Which I am the author of.