Giter Site home page Giter Site logo

gmail-scraper-go's Introduction

Gmail-scraper-go

This app downloads attachments sent by a specific email. I had a couple of attachments sent to me over a long period of time. So I decided to create this app to download them at once.

Installation

You need to turn on the Gmail API. You can turn on the Gmail API by doing step 1 in this documentation. You can also sign up for and create an API instance from the Google Developers Console.

  • Have Go installed on your machine
  • Clone the repo with git clone https://github.com/collinewait/gmail-scraper-go.git and navigate to the project with cd gmail-scraper-go
  • Install the following dependencies:
go get -u google.golang.org/api/gmail/v1
go get -u golang.org/x/oauth2/google
go get -u golang.org/x/net

Run the app.

To run the application, use the following command go run exec.go

For the first time, it will prompt you to authorize access. Authorization code is based off code provided by Google to interact with the API. The steps below are also provided (here):

  • Browse to the provided URL in your web browser. If you are not already logged into your Google account, you will be prompted to log in. If you are logged into multiple Google accounts, you will be asked to select one account to use for the authorization.
  • Click the Accept button.
  • Copy the code you're given, paste it into the command-line prompt, and press Enter.

Your attachments will be downloaded to a folder called attachments at the root of the project.

A web version can be found here: Frontend and a backend

gmail-scraper-go's People

Contributors

collinewait avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.