--- {"id": "108241726139809495", "in_reply_to_id": "108240869379777025", "in_reply_to_account_id": "108205031958480135", "sensitive": false, "spoiler_text": "", "visibility": "public", "language": "en", "replies_count": 1, "reblogs_count": 0, "favourites_count": 1, "edited_at": null, "reblog": null, "application": null, "account": {"id": "108219415927856966", "username": "brozek", "acct": "brozek", "display_name": "Brandon Rozek", "url": "https://fosstodon.org/@brozek", "uri": "https://fosstodon.org/users/brozek", "avatar": "https://cdn.fosstodon.org/accounts/avatars/108/219/415/927/856/966/original/bae9f46f23936e79.jpg", "avatar_static": "https://cdn.fosstodon.org/accounts/avatars/108/219/415/927/856/966/original/bae9f46f23936e79.jpg", "header": "https://fosstodon.org/headers/original/missing.png", "header_static": "https://fosstodon.org/headers/original/missing.png", "noindex": true, "roles": []}, "media_attachments": [], "mentions": [{"id": "108205031958480135", "username": "den", "url": "https://indieweb.social/@den", "acct": "den@indieweb.social"}], "tags": [], "emojis": [], "card": {"url": "https://github.com/Brandon-Rozek/website/blob/master/refreshtoots.py", "title": "website/refreshtoots.py at master \u00b7 Brandon-Rozek/website", "description": "Github Repo of Personal Website. Contribute to Brandon-Rozek/website development by creating an account on GitHub.", "language": "en", "type": "link", "author_name": "", "author_url": "", "provider_name": "GitHub", "provider_url": "", "html": "", "width": 400, "height": 200, "image": null, "image_description": "", "embed_url": "", "blurhash": "UTSFw=tRMxxuOrt7Rjofrqaet7WB?^RPxuWB", "published_at": null}, "poll": null, "syndication": "https://fosstodon.org/@brozek/108241726139809495", "date": "2022-05-04T04:14:26.931Z"} --- {{< unsafe >}}
@den Earlier today I wrote a Python script that is similar to what you described.
I have a file toots.json that contains all my toots and then a script refreshtoots.py that queries the JSON API and update toots.json to contain the old and new toots.
You're welcome to check it out and adapt/use it if it fits your needs. 😃
https://github.com/Brandon-Rozek/website/blob/master/refreshtoots.py
{{< /unsafe >}}