i have an apple script, which I used to add E-Mails to todoist.
I created an “message-id” link to the original message and the subject as displayed text e.g. “subject”.
I triggered this manually. Now I adapted the script, to create a link to the DEVONthink item. creating the link works and I verified it using a display dialoge action, copied the “todoist://addtask?..” link to safari and the task was added like i expected.
The problem I have is, that I can’t automate this within the script. In the Mail script, I simply called an “open location” step with the link as parameter, but when I execute this script in devonthink, I just hear this warning sound from macOS and nothing happens. When I comment out the open location step, and insert the display dialoge step, it works…
Second part of the question: I’d like to automate this based on a tag. Every Item, which receives the tag “#todo” should be added to todoist. I’m not sure, which trigger to use - so when to execute this script, because I dont want to add the same item five times I just want to add it if the tag was assigned newly to this item.
I could create a shortcut on iOS to do this, too but i think thats more complicated than on the mac…