Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

embulk-input-gmail

Package Overview
Dependencies
Maintainers
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

embulk-input-gmail

  • 0.1.0
  • Rubygems
  • Socket score

Version published
Maintainers
1
Created
Source

Gmail input plugin for Embulk

Gmail API の検索結果を取得します。

Overview

  • Plugin type: input
  • Resume supported: no
  • Cleanup supported: no
  • Guess supported: no

Pre setting

You need get tokens, before embulk run.

java -cp "/PATH/TO/GEM_DIR/classpath/*;/PATH/TO/embulk" org.embulk.input.gmail.GoogleCredentialCreator /PATH/TO/client_secret.json /PATH/TO/tokens

Setclient_secret.json and tokens path, to config.yaml.(See Configuration and Example)

Configuration

  • client_secret: client secret json file of Google APIs. (string, required)
  • tokens_directory: tokens directory of Gmail API Client Library for Java. (string, required)
  • user: search user. (string, default: me)
  • query: search query. (string, default: ``(empty string))
  • after: Gmail search query "after: xxx". Concat this config string, after "query" config string. You use if '-c' option. (string, default: null)

Example

basic

in:
  type: gmail
  client_secret: ./client_secret_xxx.json
  tokens_directory: ./tokens
  query: "\"Google アラート\""
  columns:
    - {name: Subject, type: string}
    - {name: From, type: string}
    - {name: To, type: string}
    - {name: Date, type: timestamp, format: "%a, %d %b %Y %H:%M:%S %Z"}
    - {name: Body, type: string}

Sending query is "Google アラート".

Use -c option.

in:
  type: gmail
  client_secret: ./client_secret_xxx.json
  tokens_directory: ./tokens
  query: "\"Google アラート\""
  after: 2018/10/31 # automatically update.
  # after: 1540929600 # you can use unixtime.
  columns:
    - {name: Subject, type: string}
    - {name: From, type: string}
    - {name: To, type: string}
    - {name: Date, type: timestamp, format: "%a, %d %b %Y %H:%M:%S %Z"}
    - {name: Body, type: string}

Sending query is "Google アラート" before:CURRENT_TIME after:2018/10/31. Next time, CURRENT_TIME to set in after.

TODO

  • : -c option
  • : Use option perser in GoogleCredentialCreator

Build

$ ./gradlew gem  # -t to watch change of files and rebuild continuously

FAQs

Package last updated on 02 Nov 2018

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc