Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/matt-dray/londonmapbot
:round_pushpin::robot: Mastodon (ex-Twitter) bot: random London coordinates fed to the Mapbox API and posted with {rtoot} via a GitHub Action
https://github.com/matt-dray/londonmapbot
github-actions mapbox mapbox-api mastodon mastodon-bot rstats rtoot
Last synced: 18 days ago
JSON representation
:round_pushpin::robot: Mastodon (ex-Twitter) bot: random London coordinates fed to the Mapbox API and posted with {rtoot} via a GitHub Action
- Host: GitHub
- URL: https://github.com/matt-dray/londonmapbot
- Owner: matt-dray
- License: mit
- Created: 2020-09-18T13:34:46.000Z (about 4 years ago)
- Default Branch: main
- Last Pushed: 2023-11-17T09:31:25.000Z (12 months ago)
- Last Synced: 2024-04-13T13:50:35.294Z (7 months ago)
- Topics: github-actions, mapbox, mapbox-api, mastodon, mastodon-bot, rstats, rtoot
- Language: R
- Homepage: https://botsin.space/@londonmapbot
- Size: 33.2 KB
- Stars: 28
- Watchers: 5
- Forks: 15
- Open Issues: 6
-
Metadata Files:
- Readme: README.md
- License: LICENSE.md
Awesome Lists containing this project
README
# londonmapbot
[![Project Status: Inactive – The project has reached a stable, usable state but is no longer being actively developed; support/maintenance will be provided as time allows.](https://www.repostatus.org/badges/latest/inactive.svg)](https://www.repostatus.org/#inactive)
[![](https://img.shields.io/badge/@[email protected]?style=flat&labelColor=purple&logo=Mastodon&logoColor=white)](https://botsin.space/@londonmapbot)
[![](https://img.shields.io/badge/@londonmapbot-white?style=flat&labelColor=blue&logo=Twitter&logoColor=white)](https://twitter.com/londonmapbot)
[![rostrum.blog post](https://img.shields.io/badge/rostrum.blog-posts-008900?style=flat&labelColor=black&logo=data:image/gif;base64,R0lGODlhEAAQAPEAAAAAABWCBAAAAAAAACH5BAlkAAIAIf8LTkVUU0NBUEUyLjADAQAAACwAAAAAEAAQAAAC55QkISIiEoQQQgghRBBCiCAIgiAIgiAIQiAIgSAIgiAIQiAIgRAEQiAQBAQCgUAQEAQEgYAgIAgIBAKBQBAQCAKBQEAgCAgEAoFAIAgEBAKBIBAQCAQCgUAgEAgCgUBAICAgICAgIBAgEBAgEBAgEBAgECAgICAgECAQIBAQIBAgECAgICAgICAgECAQECAQICAgICAgICAgEBAgEBAgEBAgICAgICAgECAQIBAQIBAgECAgICAgIBAgECAQECAQIBAgICAgIBAgIBAgEBAgECAgECAgICAgICAgECAgECAgQIAAAQIKAAAh+QQJZAACACwAAAAAEAAQAAAC55QkIiESIoQQQgghhAhCBCEIgiAIgiAIQiAIgSAIgiAIQiAIgRAEQiAQBAQCgUAQEAQEgYAgIAgIBAKBQBAQCAKBQEAgCAgEAoFAIAgEBAKBIBAQCAQCgUAgEAgCgUBAICAgICAgIBAgEBAgEBAgEBAgECAgICAgECAQIBAQIBAgECAgICAgICAgECAQECAQICAgICAgICAgEBAgEBAgEBAgICAgICAgECAQIBAQIBAgECAgICAgIBAgECAQECAQIBAgICAgIBAgIBAgEBAgECAgECAgICAgICAgECAgECAgQIAAAQIKAAA7)]([https://www.rostrum.blog/tags/londonmapbot/](https://www.rostrum.blog/index.html#category=londonmapbot))## What
Source for the Mastodon bot [@[email protected]](https://botsin.space/@londonmapbot) built by [Matt Dray](https://www.matt-dray.com). The repo contains a [GitHub Action](https://github.com/features/actions) that executes R code on schedule to:
1. Choose a random spot in a bounding box that encloses Greater London.
2. Query [the Mapbox API](https://docs.mapbox.com/api/maps/#static-images) for a satellite image of that location.
3. Generate an [OpenStreetMap](https://www.openstreetmap.org/) URL for that location.
4. Post the image and URL to Mastodon using [{rtoot}](https://schochastics.github.io/rtoot).The bot was built originally for Twitter as [@londonmapbot](https://www.twitter.com/londonmapbot) using the [{rtweet}](https://docs.ropensci.org/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](https://github.com/matt-dray/londonmapbot/tree/65aa64722c475fc9bda274c49674cd66ff695b4b) from before the Twitter-related code was removed.
## How
For detail on the original Twitter bot see:
* my talk at LondonR in Feb 2022 (see the [blog](https://www.rostrum.blog/posts/2022-02-12-mapbot-londonr/), [slides](https://matt-dray.github.io/mapbot-londonr/#1), [video](https://player.vimeo.com/video/683004567))
* my [original blog post](https://www.rostrum.blog/2020/09/21/londonmapbot/) that introduces the bot
* my [blog post](https://www.rostrum.blog/posts/2023-02-09-londmapbotstodon/) about porting the bot to Mastodon, following [Matt Kerlogue's advice](https://lapsedgeographer.london/2022-11/mastodon-switch/)