Regex Question - sharing URL to create a Reminder

Does anyone have idea why the Regex in this Shortcut does not work here?

I am trying to create a Share Sheet shortcut so I can share a URL to Reminders and populate the title and URL fields separately

https://www.icloud.com/shortcuts/72a27781c1eb47a8827f25670f3c198e

I don’t see why you would need to use Regex at all. I think setting up the share sheet for URLS and using the URL properties is the best approach. I’ve added in the specification to only work with the first URL passed in as technically it can accept multiple URLS - otherwise it is down to a single step rather than two.

https://www.icloud.com/shortcuts/16c29a4649f74044850e657b0957a754

@sylumer - Many thanks. That is exactly what I was trying to do.

I am intrigued however - as much as the Shortcut works, I am unable to reproduce/create it myself. How did you get the scripting variable “Name” to appear? When I try to reproduce the script, only Item from List shows up as an option, not Name.

What book or website would you recommend for more details to learn about advanced Shortcuts beyond Rosemary’s Take Command book (which is outstanding) ?

Look at the second screenshot. See how the type (as URL) is settable?

1 Like

This is a property of a magic variable. He selected the first item from list, and then tapped it again to choose the property.

I’ll make a note to go through and explain this better in the section on variables in the next book update!


You may also want to check out MacSparky’s field guide for Shortcuts:

2 Likes

Got it - that’s a huge help

And your book has been fabulous as well

The short works well now when I pass a URL to it via the Share Sheet - Thanks

One of my main uses for the Shortcut is to save Office 365 email messages as reminders. For this I hope to use Zapier.

Configured as below in Zapier the Shortcut uses the Web Link or URL as both the Name of the shortcut and its URL. Do you know the syntax or expected format so that I can configure Zapier to pass both the Name and the URL?

1 Like