GooBook – Access Your Google Contacts From Commandline In Linux

Goobook – Access Your Google Contacts From Commandline

My work relies mostly on Google products. I use Google docs for managing documents, Gmail for sending and receiving mails, Google Drive for storing my personal data, Google play books for reading books, google translate for translation. I was wondering if there is any way to access my google contacts from Commandline. I know how to access to use it from a graphical desktop, but not from Commandline. Here is an useful and handy utility called GooBook that allows you to access your Google contacts from commandline. The main purpose of Goobook is to access google contacts from commandline or a command line Email client like Mutt.

This brief tutorial addresses how to install and use Goobook in Linux.

Install GooBook on Linux

GooBook can be installed using any of the following methods:

  • Using pip
  • From a distribution specific repository
  • Using a source tarball

Install GooBook using PIP

The recommended way to install goobook is using pip.

To install PIP on Arch Linux and its derivatives, run:

sudo pacman -S python-pip

On RHEL, Fedora, CentOS:

sudo yum install epel-release
sudo yum install python-pip


sudo dnf install epel-release
sudo dnf install python-pip

On Debian, Ubuntu, Linux Mint:

sudo apt-get install python-pip

Once PIP installed, run the following command to install Goobook.

pip install goobook

Install GooBook from repository

Goobook is available in some Linux distribution’s repository. Say for example, on Ubuntu and its derivatives, you can install it using command:

sudo apt-get install goobook

For Arch Linux and its derivatives, Goobook is also available in AUR. You can install it using AUR helpers such as Yaourt or Packer.

yaourt -S goobook

Install GooBook from source

You need to install python first. On Ubuntu and its derivatives, the following command will install python.

sudo apt-get install python

Download the Goobook tarball from here.


Extract it using command:

tar -xzvf goobook-*.tar.gz

Go to the extracted folder:

cd goobook-*

Then, run the following command to install it.

sudo python ./ install

Congratulations! Now that you’ve got Goobokk set up, it’s time to give it a test. Before going to use it, you need to authenticate with Gmail.

Authenticate GooBook with Google accounts

Run the following command to authenticate with your gmail account.

goobook authenticate

Your default browser window will open. Select the Gmail account you’d like to authenticate with.

Click ‘Allow’ to authenticate with your google accounts:

Finally you’ll get confirmation message like below.

The authentication flow has completed.

Also, in your Terminal you’ll see a message something below.

/usr/lib/python2.7/site-packages/oauth2client/ UserWarning: Cannot access /home/sk/.goobook_auth.json: No such file or directory

Your browser has been opened to visit:

If your browser is on a different machine then exit and re-run this
 application with the command-line parameter


Created new window in existing browser session.
 Authentication successful.

Congrats! Now, you have configured Goobook with your Google account. Let us go ahead and see how to use it from commandline.

Access Your Google Contacts From Commandline In Linux Using GooBook

To view/query a Google contact, just run the following command:

goobook query senthilkumar

Replace ‘senthilkumar’ with your google contact name.

Sample output would be like:

As you see in the above output, the google contacts will be listed with its group and imported time.

For more details, see:

goobook -h

And, that’s all. As you can see, Goobook is fairly simple and straightforward  in terms of installation and usage. You can view your google contacts easily from your Terminal in any Linux distribution. Hope this helps!



Thanks for stopping by!

How can I benefit from this blog:

Have a Good day!!

You may also like...

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.