Hook <> Spark Email Integration

Hi All

Just thought I’d contribute to this wonderful forum

If anyone is interested, you can add “Spark” to hook preferences > scripts, and then…

on Get Name tab


On Get Address tab


If you were to invoke hook to copy a message in Spark, you’d get this


Found the basis for this Applescript in one of the Macsparky forums and repurposed it. Can’t recall it where exactly… but thanks to whoever it was


I’ve entered the scripts as you recommended, but I get “No Linkable item found” when invoking Hook with a message selected in the Spark Inbox. Hook 2.0.3

btw, I tried executing the AppleScript in the script editor, but neither returned anything useful. I’m on Big Sur, Spark v2.9.10.755. On which versions did this work for you?

Hi Chris. I’m using Spark and I’m on Catalina 10.15.7 and also on Hook 2.0.3. I don’t know why it’s not working for you. Maybe someone else who tried and got it to work can comment

Ok I’m not sure why this is working for me, but this is what I’m currently using and it appears to work. I’m on Big Sur with Spark v2.9.11 and Hook 2.0.3.

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

This works beautifully! Thanks.

Must a Big Sur thing.

super! Last time we checked Spark didn’t have AppleScript support. Great they’ve added it.

The URLs would only work with other Spark clients (i.e., if you send it to someone who does that Spark, it wouldn’t work). If GetSelectedMessageBacklink is RFC5322 (email) compatible, we could construct a hook://email client URL that is compatible with other mail clients. However, the advantage of this link format is that it can already be used on iOS.

I haven’t it tried it yet. If someone could send us a few sample spark URLs we would have a look before digging into Spark itself and its documentation.

This is absolutely brilliant!
Thank you, getting Spark to work with Hook has been on my wish list for a while.

This is amazing! I found out about Hook when I posted a question on the Roam Research forums about how to get emails into Roam. Someone recommended Hook, I came here and found that there is an integration with Spark but it lacks automation. Then I saw this thread!

I added the script code to Hook. I invoked Hook on an email, copied the link, then tried pasting the link in the URL window of Safari. That prompted me to open Spark and I did see the email. I also tried pasting the link in TextEdit. That worked fine too.

But, when I paste the link into Roam Research, it doesn’t work. If I just paste the link directly into a Roam note, I see this syntax: Day V: Inline Calculator, where “Day V: Inline Calculator” is the subject line of the email. If I use “Command-k” to turn some text in Roam into this link, Roam does create a hyperlink. But when I click on the hyperlink, I get this error message:

ID: sfo1::rfzp5-1606743779321-5a5ff6ae1ee5”

Anyone know why this is happening?

I’ve been discussing this on the Roam forum as well. One of the mods there downloaded Hook app, installed the Spark script, and tried copying and pasting a link. It worked just fine for him. He asked if this might be a Big Sur issue? (He’s not running Big Sur.)

Here is the Roam forum thread.

If you read further back in this thread, you can see there are two versions of the scripts. One seems to work with pre-big sur, and the second with big sur. At least, that’s worked for me.

This isn’t working for me, I wonder if Spark stopped supporting it? Or did I enter something wrong?
CleanShot 2020-12-29 at 18.46.17@2x

Hi @josh. That looks different from the script we recently added in Hook integration scripts v.146 now available — Spark by Readdle and Mailplane - Releases - Hook Productivity Forum

Yes, you’re correct sorry! I must’ve accidentally unchecked auto-updates, because I was running an older version on both my macs. After updating, everything works as expected. Thank you!

1 Like

Neither are working for me. Is anyone else having issues? I have the most updated Spark and Hook and Mac OS.

I just installed Hook. Running latest version of Big Sur, when I link an email from Spark into Omnifocus it appears to work but if I click on the link, instead of getting the linked email I get an error message: “Spark couldn’t open the message because a back link is corrupted.”

Is this fixable? I’d REALLY like to get Spark and Hook working together. I can just use the native functionality of Spark to move it into Omnifocus but the way it navigates through Hook into Spark is just a little cleaner.

Welcome to the Hook Productivity Forum , @Conejo23 . As noted elsewhere, Spark is not a reliably linkable mail app. At best, Hook gets the link from Spark. Have you compared the link returned by Hook with the link returned by Spark through its user interface?

If Readle one day decides to add automation to get links to their software objects, we will gladly use it. Until then we recommend using a different email app, or manually copying links through Readle apps’ UI, and feeding into Hook (Or any other workflow) from there.

Once you’ve copied any URL, you can ‘hook it’ Hook to Copied Link. You can edit the name from there. We will add bells and whistles to the Hook UI, and additional goodies ( AppleScript and helper apps), to facilitate processing of arbitrary URLs and links. Hook is a link processing virtual machine.

thank you for this reply!

Do you guys have any videos or articles showing some common use cases? I’ve heard about using it to connect to Roam (which I’m just learning) but I don’t see the advantage beyond just copying the link the regular way.

So far I’m using Hook to turn websites into tasks in OmniFocus where I have that link in the notes. OF used to do that itself but that stopped working awhile back and this helps me connect Brave Browser to OF beautifully, but it feels like there’s so much more here and I don’t know how to get my arms around it. Any tutorial videos?

Rick Mathes | Owner, Egoscue of Austin
THE EGOSCUE METHOD® | Relieve Chronic Pain + Increase Functional Mobility
phone 512-527-0030 www.egoscue.com/austin-tx

Follow us on Facebook Follow us on Twitter


correct. there’s lots more to it than that.

here are Hook App Videos – Hook, and Benefits of Using Hook – Hook.

A recent addition to Hook (Hook 2.0) is automatic bookmarking and search of Hook bookmarks, which is shown in one of the videos and described in help pages, but is worthy of more attention on the web.

There’s also How to Turn a TaskPaper File into a Project Information Hub – Hook, which is also pertinent to OmniFocus. I think the video shows OmniFocus, and in any event you can use OmniFocus as a project hub without using TaskPaper.

The Hook to New feature is super helpful for taking notes about any item (PDF, web page, etc.) in the app of your choice.

A slogan of Hook is “One app, infinite applications” because its commands open up a huge number of new types of workflows.