Getting an address from Apple Maps

I have the following shortcut for iOS:
https://www.icloud.com/shortcuts/e31aa2bbbcb04ef897439e31f38c07a6

What it should do is, from Apple Maps you share a location, then choose this shortcut from the share sheet. Maps will then pass shortcuts a street address in this format:
121 Main St
You can see with the first Quick Look that the text is being relayed to the shortcut. But then when I attempt to split the text, the shortcut falls flat on it’s face and goes no further.
What I would LIKE to happen is that this street address is split, then combined with URL Spaces “%20” to look like this:
121%20Main%20St
Seems pretty simple, but this does not work for me on my iPhone 14 Pro Max, running iOS 17.6

If someone(s) could please test the shortcut and see if it works on your iPhone and whatever version of iOS that you have.

Thanks!

I think it worked for me. It certainly gave me some URL encoded (spaces only + map URL) output of the name, address and map URL, all as one string.

Two things would be useful here:

  1. To know what you mean exactly when you say it does not work for you.
  2. To get an idea of what you are ultimately trying to do.

Maybe there is an easier approach? Maybe you need to URL encode more than just spaces? Maybe your issue only occurs for addresses in specific formats?

I figured it out. Here is the working shortcut on 17.6 beta 3

https://www.icloud.com/shortcuts/a92b5d6678d14eaab364c673de2e3b85