Script- append to a different draft


#1

I’m using Drafts 4. Is it possible to run a script on one draft and then append the result to another draft? Here is a simple example.

1st Draft contents:

12
14

A script could add those numbers and then write 26 to another draft with a known UUID.

I don’t care about the calculation part, just how to send the result to the specific draft.

Any ideas?


#2

That can be done with script in Drafts 5, but not Drafts 4. It could be done with the /append URL scheme in Drafts 4, however. An action can call the app’s own URLs with a URL action step, something like:

drafts4://x-callback-url/append?uuid=MY-KNOWN-UUID&text=[[draft]]

#3

Great! Thanks. I’ll give it a try.