• he/him

Mobile-addicted. Web-dependent. Digital plumber. Nerd. He/him. No-coiner.


Text cross-posting from Twitter to cohost via IFTTT webhook successful for text posts. Going to have to get a little fancier with images, though. Someday.

I'm trying to avoid touching the Twitter API, so I'm using If This Then That to send a webhook to my server, where I'm using cohost.py to post to cohost. IFTTT doesn't handle the images, though, just leaves in a t.co URL that redirects to the original tweet URL. Right now I'm just skipping any tweet that has a link in it, but I have implemented following redirects on links so I can check whether they represent an image or something else. The problem is there's just no good way to scrape the actual image URL without running an ass-load of Twitter's JavaScript in a headless browser.

This is just a stopgap; I'm working on a standalone composer that will let you post the same content directly to Twitter, Mastodon, Cohost, [Whatever], but I just wanted to get some content flowing here until I have the time to finish that thing.


You must log in to comment.