Skip to content

A Twitter bot that automatically posts a daily map of the previous day's earthquakes, providing real-time global seismic activity updates.

License

Notifications You must be signed in to change notification settings

titouanlegourrierec/TodayQuakes

Repository files navigation

LinkedIn Mail

Logo

A Twitter bot that automatically posts a daily map of the previous day's earthquakes, providing real-time global seismic activity updates.

LE GOURRIEREC Titouan

Report a bug · Request Feature

Table of Contents
  1. About The Project
  2. License
  3. Contact
  4. Data

About The Project

This project is a Twitter bot that posts daily updates on global seismic activity. Using the USGS (United States Geological Survey) API, it fetches earthquake data from the previous day, including the total number of quakes and their distribution by magnitude. The bot then generates a visual map displaying the locations of the earthquakes and posts it on Twitter (X) via the X API.

Features:

  • Automatic daily data retrieval from the USGS API.
  • Visual map generation of earthquakes worldwide.
  • Summary of key statistics: total earthquakes and magnitude distribution.
  • Automated posting on X (formerly Twitter) using the X API.

The main functions of the bot, including data retrieval, processing, plotting, and posting to Twitter, are defined in DailyQuakes.py. The automation logic is handled by bot.py, while logging configuration is managed by config_logging.py, with log messages saved to log.txt in the log directory. The daily execution of the bot is automated using GitHub Actions, with the workflow defined in .github/workflows/bot.yml. This setup ensures the bot runs daily without manual intervention, fetching data, generating visualizations, and posting updates seamlessly.

(back to top)

Built With

  • Python
  • GitHub_Actions
  • X

(back to top)

License

Distributed under the MIT License. See LICENSE for more information.

(back to top)

Contact

LE GOURRIEREC Titouan - titouanlegourrierec@icloud.com

Project Link: https://github.com/titouanlegourrierec/TodayQuakes

(back to top)

Data

  • USGS : Earthquakes data

(back to top)

About

A Twitter bot that automatically posts a daily map of the previous day's earthquakes, providing real-time global seismic activity updates.

Topics

Resources

License

Stars

Watchers

Forks

Languages