Recently I've been helping out with a fork of
mmsd (located here) since MMS is, unfortunately, a crucial thing I need working on a phone in 2021. Anyways, one of the painful things about hacking on
mmsd is that receiving a MMS for testing is a manual process. The simplest way to get an MMS is to ask a friend to send you one. Or perhaps purchase a second SIM to use in a second phone to send yourself one. After a while, your friends, family, people you just met, etc will stop responding to your requests to have them send you a MMS. Before you know it, you're sneaking off with your partner's phone while they are sleeping so you can get some work done. This is rock bottom.
A few days back, some folks in the Librem 5 Matrix channel were recommending jmp.chat, a service that gives you a real phone number that you can tie to an XMPP account. This service supports a few different things, including some voicemail thing when using voice chat over XMPP (which I should look at later on..), but the most interesting feature at the moment is that one can use it to send SMS and MMS to real phone numbers. It automatically converts non-text messages (e.g. photos) into MMS. Perfect!
This setup is still a rather manual process though... I'm using Chatty on my phone (running postmarketOS, of course), and unlocking the screen, opening Chatty, opening the "conversation" between the XMPP account tied to jmp.chat and the XMPP bridge to the number associated with my SIM, add an attachment, and finally hitting "send" each time just to test out
mmsd still sucks. We can do better!
This evening I learned about
sendxmpp, specifically the Golang rewrite of this tool (the original was in Perl).
sendxmpp is a commandline tool for sending messages over XMPP, and the Go version of it has a
--http-upload option that sends arbitrary binary data in the message using, you guessed it, HTTP. Perfect! Now I can fire off MMS to my phone with one simple line in the trusty terminal emulator:
$ go-sendxmpp -t --http-upload photo.jpg "+1XXXXXXXXXX@cheogram.com"
The recipient address is what jmp.chat uses for bridging the XMPP message to my phone number, the expected format is straight from their FAQ.