Skip to content
/ Ameyadar Public

☔SNSの名前に京大上空の予想降水量に応じた絵文字を貼付する

License

Notifications You must be signed in to change notification settings

h3y6e/Ameyadar

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

38 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Ameyadar

各種SNSアカウント名に,京都大学上空の予想降水量に応じた絵文字を貼付する。

Yahoo! Open Local Platform(YOLP)の気象情報APIを使ってます。
こういう無料の気象系APIは,精度が悪かったり(海外産),二次利用不可だったり(日本産)するのだが,これは非商用目的なら使える(商用目的でも問い合わせれば使えるかも)ので有難い。1時間先までの降水量しか分からないけど日常生活ではそれで充分。

Dependents

必須

  • python
  • pip
  • 利用するクライアントのAPI Key各種
  • Yahoo API

推奨

  • virtualenv or venv

Usage

前準備

  $ cp .env.example .env
  # edit `.env` file
  $ pip install -r requirements.txt

動作確認

  $ python ameyadar.py -h
  $ python ameyadar.py no_service

twitterで使う場合

  $ python ameyadar.py

mastodon

  # APIのKeyの取得を行う
  $ python scripts/initialize_mastodon.py # 初回だけ実行して下さい
  # data/mastodon/ フォルダが出来ていれば成功です
  $ python ameyadar.py mastodon

License

MIT

About

☔SNSの名前に京大上空の予想降水量に応じた絵文字を貼付する

Topics

Resources

License

Stars

Watchers

Forks