Select to view content in your preferred language

Geocode Addresses not working in flow

4867
10
Jump to solution
09-10-2023 12:50 PM
Rob_Hughes_32Alpha
Regular Contributor

Hello all,

I am trying to develop a flow to pull data from a client's Salesforce into Dataverse, transform it in Power Query, geocode the addresses and finally add them to a feature layer. We are currently stuck on the prototype phase where we are trying to get the geocode addresses action to work. The flow says it has completed successfully, and the records are added to the table in the feature layer, however the geocoding does not work. We get the following error message:

{"statusCode":200,"headers":{"ETag":"W/\"b6-7KYDAKFLNQPidja/ILX7vS1s/M8\"","X-Powered-By":"Express","Timing-Allow-Origin":"*","x-ms-apihub-cached-response":"true","x-ms-apihub-obo":"false","Date":"Sun, 10 Sep 2023 18:18:08 GMT","Content-Length":"182","Content-Type":"application/json; charset=utf-8"},"body":{"message":"Requested addresses are not valid. Check the input: 56 Horseshoes Way, Brampton, Huntingdon, Cambridgeshire, PE28 4TN and try again.","success":false}}

 The address geocodes perfectly well in this format using AGOL. I don't understand why it is not accepting the address!

Does anybody have any ideas? Or can somebody from Esri please let me know if this is a known bug, or whether there are any particulars I have to do with the data format to get it working?

Thanks!

0 Kudos
10 Replies
SeanKMcGinnis
Esri Contributor

@Rob_Hughes_32Alpha - thank you for the call today, I am glad we were able to get it sorted out.

For others who may be encountering a similar issue, the issue was the projection of the data was not defined.

The way we resolved it was by including the spatial reference details as part of the geometry JSON. The result looked like:

{"x": [Longitude (X)], "y": [Latitude (Y)], "spatialReference": {"wkid":4326}}

 

[Longitude (X)] & [Latitude (Y)] representing the dynamic content  returned from the geocode address action and the WKID value representing the correct projection.

-sean
Sean McGinnis - Principal Product Manager, ArcGIS for Microsoft