Running shortcut on multiple lines of a Draft

I created a shortcut called “Add To Book List” to take text (the name and author of a book I want to read) and add it to a Bear note along with some links to local libraries. I use it from the share sheet if I see a book on a website, but I also enter titles of books into Drafts.

Sometimes I have a long list of books in a single draft and I would like to create a Drafts action that goes through the list, line-by-line, and runs the shortcut on each line.

I’m having trouble figuring out how to run the “Add To Book List” shortcut on each line of the Draft. Can anyone help me with this?


This should give you the gist of how to split the content and pass it off to your other shortcut.

You can get the Draft content directly by UUID as here, or you could change to accept via the share sheet, trigger from a Drafts action, etc.

Exactly what I was looking for. Thank you!

1 Like