This is the long-lasting hiccup for using Spark: direct deep linking to individual messages. It’s now possible through AppleScript – see original post on the Hook forum:
Get Name
tell application "Spark"
if HasSelectedMessage then
set theResult to GetSelectedMessageTitle
return theResult
end if
end tell
Get Address
tell application "Spark"
if HasSelectedMessage then
set theResult to GetSelectedMessageBacklink
return theResult
end if
end tell
Tested through Keyboard Maestro, works perfectly. Opens the door for a true task-based email workflow on macOS with Spark, and erodes further the tiny lead Airmail still kept in functionality. I’m very happy as Spark is a lot more reliable.
@anon85228692 I’ve been going back-and-forth with Spark for sometime. I’ve always wanted to use Spark but I continue to have two issues. One of which you just addressed. I don’t like going to the website for a link. This, however, does not solve the problem when using Spark on iOS. I tend to use it quite a bit on the iPad. The other issue is that Spark does not integrate with DEVONthink. Obviously, I can copy an email link and put it in DEVONthink, but Apple Mail can be sent directly to Devonthink through drag and drop or through import. This functionality is important to me because I connect specific emails with specific project notes in DEVONthink.
Those are the two main reasons right now why I’m still defaulting to Apple Mail. I would love to hear if you have any workarounds for those two remaining issues in my workflow.
For iOS, still no luck I’m afraid. (I just tried drag and drop to OmniFocus, just in case… no joy.)
For DEVONthink, on Mac, since we can now freely access the Spark internal URL scheme, you can link to those messages from anywhere, including from your DT notes. That should also work on iOS – I haven’t tested it, but those links work cross-platform from task managers, so there’s no reason why they shouldn’t work for elsewhere. You need to create them on a Mac, though.
I have been following very closely Spark’s development and, unless I’ve missed it, I’ve seen no announcement whatsoever of this AppleScript support, which seems weird because it’s quite carefully implemented and I only ever found mention of it in the depths of the Hook forum. I want to see in that silence the sign that Readdle is quietly building Spark to a v.3.0 supporting lots of new automation features, including deep linking.
Here’s the Keyboard Maestro Macro on an old thread, btw:
@Bmosbacker, main problem there is that Spark reserves its spark:// scheme to its native integrations and will not allow for copying directly (it favor the https links for that).
That said, there are a few integrations that will export spark:// links if used. I use it to push links to Things. Devonthink doesn’t appear to be supported as per this screenshot:
Damn, I COMPLETELY missed the first macro posting. My apologies. I don’t even know how I could miss that as I’ve been literally looking for this for years…
@anon85228692, @ldebritto Thanks for the good information. It looks like I will have to continue using Apple Mail. I don’t want to mess with Scripts and keyboard Maestro. I just want to send the email to DT and other apps and have a link directly back to the email without going to a website. One last question on this, do you know if Airmail handles this better and even if so, is the client stable and reliable? I’ve run into issues with AM in the past. It would need to work perfectly and do wha I want for me to justify paying a subscription for an email client.
In my experience, only Mail.app, Spark and Outlook should be trusted with email. Airmail and many others I’ve tried failed me miserably previously.
While I can’t speak from present experience with Airmail, I can report that Spark has never failed me in the las t two years I’ve been using it as my primary email app on iOS and macOS.
My only gripe is that those spark:// links are way more hard to get than they should be. But that doesn’t offset their Smart Inbox and Send Later features that are just lacking on Mail.App.
Airmail is… Airmail. It’s finicky. It does not work perfectly, it works if you know its quirks and want the most powerful app there is. So in your case, I’d say: stay away from it. I know it very well, but I’ll still be staying with Spark (even more now that there’s URL links we can access). I know I can trust Spark, while Airmail has to be monitored and really feels rough on the edges.
Are these spark:// links completely proprietary, or, if you examine them closely, is there some similarity to the link for the same message generated from a Mail app link? I’mve recently started using Spark on iOS again, but miss other apps where, although they generate their own links, those links could be easily modified to call up messages in the default apps.
If this can be useful to anyone, I have replicated the OmniFocus “clip-o-tron” feature from Apple Mail in Spark using Keyboard Maestro, just combining the aforementioned scripts. You will have to change the first hotkey to your OmniFocus quick entry keyboard shortcut (mine being control-option-command-space).
While this is a workaround that may not be worth it for many users, I have found it worthwhile to use the built-in Reminders integration in spark as a way to send the spark:// links to Drafts, which can then be sent anywhere else. That is, Drafts can be set to auto-import from a reminders list, so on iOS, you can send a Spark mail message to that Reminders list, then Drafts will import it, and you have the link to be manipulated or sent elsewhere.
Thank you so much for sharing this. This is something I’ve been looking for for a while now. I left Spark to Apple Mail but even those links don’t work well.
I’ve modified the script to copy the readdle-spark:// URL to the clipboard so that I could paste it anywhere (Drafts and Obsidian in my case). I trigger it via Keyboard Maestro and a hotkey trigger, which validates that the app is actually at the front.
For those interested:
tell application "Spark"
if HasSelectedMessage then
set the clipboard to (GetSelectedMessageBacklink)
end if
end tell
Now, as others have mentioned, we need a solution for iOS, and one that doesn’t require a Mac running in the background.