This GitHub repository provides a GitHub action runs every 10 mins, and pulls remote replies into your instance, using the Mastodon API. It has two parts:
- It gets remote replies to posts that users on your instance have already replied to during the last
REPLY_INTERVAL_IN_HOURShours, and adds them to your own server. - It gets remote replies to the last
HOME_TIMELINE_LENGTHposts from your home timeline, and adds them to your own server.
Either part can be disabled completely, and the values for REPLY_INTERVAL_IN_HOURS and HOME_TIMELINE_LENGTH are configurable (see below).
Be aware, that this script may run for a long time, if these values are too high. Experiment a bit with what works for you, by starting with fairly small numbers (maybe HOME_TIMELINE_LENGTH = 50, REPLY_INTERVAL_IN_HOURS = 12) and increase the numbers as you see fit.
For full context and discussion on why this is needed, read the blog post: Pull missing responses into Mastodon
- In Mastodon go to Preferences > Development > New Application
- give it a nice name
- enable
read:search,read:statusesandadmin:read:accounts - Save
- Copy the value of
Your access token
- Fork this repository
- Add your access token:
- Go to Settings > Secrets and Variables > Actions
- Click New Repository Secret
- Supply the Name
ACCESS_TOKENand provide the Token generated above as Secret
- Provide the required environment variables, to configure your Action:
- Go to Settings > Environments
- Click New Environment
- Provide the name
Mastodon - Add the following Environment Variables:
MASTODON_SERVER: The domain only of your mastodon server (withouthttps://prefix) e.g.mstdn.thms.ukHOME_TIMELINE_LENGTH: An integer number. E.g.200. (See above for explanation.) Set to0to disable this part of the script.REPLY_INTERVAL_IN_HOURS: An integer number. E.g.24. (See above for explanation). Set to0to disable this part of the script.
- Finally go to the Actions tab and enable the action. The action should now automatically run approximately once every 10 min.
This script is mostly taken from Abhinav Sarkar, with just some additions and alterations. Thank you Abhinav!