Source for the Mastodon bot @londonmapbot@botsin.space built by Matt Dray. The repo contains a GitHub Action that executes R code on schedule to:
- Choose a random spot in a bounding box that encloses Greater London.
- Query the Mapbox API for a satellite image of that location.
- Generate an OpenStreetMap URL for that location.
- Post the image and URL to Mastodon using {rtoot}.
The bot was built originally for Twitter as @londonmapbot using the {rtweet} package. Posts to Twitter stopped in May 2023 due to changes in the API terms of service. You can see an older version of the repo from before the Twitter-related code was removed.
For detail on the original Twitter bot see:
- my talk at LondonR in Feb 2022 (see the blog, slides, video)
- my original blog post that introduces the bot
- my blog post about porting the bot to Mastodon, following Matt Kerlogue's advice