We are in the final days to enter our Data and Analytics - "What's your why?" raffle with SparkED!

Reply with your "why" in text/video format to our forum post by January 28 to be entered! 

Alteryx Designer Discussions

Find answers, ask questions, and share expertise about Alteryx Designer.

Google Polyline Decode

6 - Meteoroid

I've set up the API to Google Maps / Directions and successfully returned an encoded poly line:


JSON_Name: routes.0.overview_polyline.points

JSON_ValueString: ewzhErgmmQaA@BeF@}BbBFhLA\??QAiDDcRB}RBiK?qAR?xVf@@cE@mF|C@GlT


The macro to decode the string was posted here some time ago (Parse Encoded Google Polyline) however upon running it, it's returning coordinates off the east coast of South America when they should be in Plano, TX.  The polyline build in Alyerx actually looks correct, it's just in the wrong location.  I've checked the other returned JSON values and Google is returning correct addresses and route information.


The workflow is following the steps to encode coordinates in reverse order from the documentation provided by Google here: Encoded Polyline Algorithm Format 

Please help me in fixing / updating the workflow to correctly return Lat / Lon for route information!

Alteryx Community Team
Alteryx Community Team

That was kinda fun to reverse engineer!


I think there was a problem in the step 7 to step 6 transition (from https://developers.google.com/maps/documentation/utilities/polylinealgorithm)




Good luck!

6 - Meteoroid

I think I found it at the same time you did!  I'm going to run a few more scenarios to double check, but I will mark your reply as the solution if it all checks out!

8 - Asteroid

This is insanely useful, I can't believe it hasn't had more attention. Thank you!