2

Ireland are using a post code system called "Eircode" which is valid layer in google maps and searching an Eircode e.g D03E5Y8 will result in the correct address on the Google map - much like UK / US zips. https://www.google.ie/maps/place/Drumcondra,+Dublin,+D03+E5Y8/@53.3608019,-6.2560623,17z/data=!3m1!4b1!4m5!3m4!1s0x48670e639f49ad8d:0xfe32bee99c51f2ee!8m2!3d53.3607987!4d-6.2538683?hl=en

I was using an api call like below with a valid Eircode in the origins value. The lookup was working perfectly up to 1-2 days ago (Feb 19th /20th, 2018) - however it now returns a null value (please replace the key with your own API key)

https://maps.googleapis.com/maps/api/distancematrix/json?origins=D03+E5Y8&destinations=dublin&language=en-EN&key=xxxxxxxxxxxxxxxxxxxxxxxxxx&sensor=false

Previously the distance matrix worked with Google maps and you could enter 2 eircodes into origins= and destinations=

To illustrate further entering a valid UK post code into the origins value

https://maps.googleapis.com/maps/api/distancematrix/json?origins=ll652ez&destinations=dublin&language=en-EN&key=xxxxxxxxxxxxxxxxxxx&sensor=false results in a correct call.

Have Eircode or Google maps now disabled this functionality for Eircode lookups? This would seem like a major step backwards!

Appreciate any help on this before I go back to the drawing board!

SOLUTION Add +ire to the Eircode value origins=T12KC86+ire&destinations=V92YP93+ire

geocodezip
  • 158,664
  • 13
  • 220
  • 245
OnTarget
  • 61
  • 8
  • Have tried `https://maps.googleapis.com/maps/api/distancematrix/json?origins=D03+E5Y8&destinations=dublin&language=en-EN&key=xxxxxxxxxxxxxxxxxxxxxxxxxx&sensor=false` with my standard plan api key and it worked fine for me. Maybe you went over quota? Distance Matrix is heavier than a normal request because multiple origin/destinations multiply the request usage, ie 10 origins / 10 destinations is equivalent to 100 single requests. – Franco Vizcarra Feb 22 '18 at 10:20
  • Hi Franzo -thanks for the comment - can you output the results of your distancematrix here - I am getting { "destination_addresses" : [ "Dublin, Ireland" ], "origin_addresses" : [ "" ], "rows" : [ { "elements" : [ { "status" : "NOT_FOUND" } ] } ], "status" : "OK" } note that my origin_addresses is null – OnTarget Feb 22 '18 at 10:53
  • { "destination_addresses": [ "Dublin, Ireland" ], "origin_addresses": [ "Drumcondra, Dublin, Co. Dublin, D03 E5Y8, Ireland" ], "rows": [ { "elements": [ { "distance": { "text": "2.7 km", "value": 2680 }, "duration": { "text": "12 mins", "value": 725 }, "status": "OK" } ] } ], "status": "OK" } – Franco Vizcarra Feb 22 '18 at 10:56
  • Maybe it's a problem with your connection, ie the server or computer you are using to connect to the outside world. – Franco Vizcarra Feb 22 '18 at 10:57
  • 1
    Hi Franzo its a strange one - I got it working by adding +ire to the url - **origins=T12KC86+ire&destinations=V92YP93+ire** I wonder if its something to do with my IP - anyway problem solved for now! Thanks for your help [link](https://maps.googleapis.com/maps/api/distancematrix/json?origins=T12KC86+ire&destinations=V92YP93+ire&language=en-EN&key=xxxxxxxxxxxxxxxxxxxxxxxx&sensor=false) – OnTarget Feb 22 '18 at 11:24
  • Hi can you vote my original post up - I had hundreds of people complaining the eircode didn't work on my system so the solution is a valid one – OnTarget Feb 23 '18 at 12:05
  • It looks like there was an issue with postal codes on Google side: https://issuetracker.google.com/issues/73747115 – xomena Feb 25 '18 at 14:57
  • This stopped working again - the fix is now to add 'ireland+MYEIRCODE' – OnTarget Mar 05 '18 at 16:13

0 Answers0