How to use the ArcGISOnlineFindAddressCandidate Custom Transformer

Evie Lapalme
Evie Lapalme
  • Updated

FME Version

Introduction

The ArcGISOnlineFindAddressCandidate transformer uses the ArcGIS Online (AGOL) REST API to geocode addresses one location per request; the input address can be combined into a single input field or divided among multiple parameters. Check out some of the other ArcGIS Online custom transformers here: Getting Started with ArcGIS Online Custom Transformers.

 

What is ArcGIS Online?

ArcGIS Online is Esri’s cloud-based mapping software that lets you build interactive web maps. They provide analysis tools, such as the Routing Service, to gain location intelligence. ArcGIS Online enables you to work effectively across your organization by collaboratively building and using maps that you can share within your organization or publicly. 

 

Requirements

  • ArcGIS Online Account with available credits

 

Step-By-Step Instructions

1. Download the Data
Either prepare your own data or download the Addresses.gdb zip file located in the Files section of this article.

2. Create a Workspace
Open FME Workbench and select Blank workspace to begin building your workflow on an empty canvas.

3. Add the Data to the Canvas
After unzipping the Addresses.gdb.zip that you have downloaded, add the Addresses.gdb to the canvas. You can achieve this by either adding a File Geodatabase Open API reader and browsing for the file, or drag and drop the file onto the canvas itself. Select OK.

image.png

Select the PostalAddress Feature Class when adding. Select OK again.

image.png

4. Add a Sampler
Add a Sampler with quick add by typing freely on the canvas. Choose a large number for the Sampling Rate and connect it to the reader.

image.png

This is because the transformer can only take one input at a time, making an individual HTTP request for every input feature which would potentially take up more time. If you would like to input all points to be geocoded, then we suggest using the ArcGISOnlineBatchGeocoder.
image.png
5. Add an ArcGISOnlineFindAddressCandidate transformer
Next, add the ArcGISOnlineFindAddressCandidate custom transformer to the canvas. Connect the ArcGISOnlineFindAddressCandidate to the Sampler. 

6. Using the ArcGIS Online API
In the ArcGISOnlineFindAddressCandidate parameters, select “Add Web Connection” from the drop-down of the AGOL Web Connection highlighted in red. Then give the connection a name and select “Authenticate” at the bottom. This will bring you to the authentication web connection page and prompt you for your username and password. This is needed because this service requires credits to complete the process.

image.png

7. Input Parameters
For this dataset, our address is split up into components instead of a SingleLine. Input the parameters as follows after choosing components:

  • Address Line 1 = PSTLADDRESS
  • City = PSTLCITY
  • Region = PSTLPROV
  • Postal/Zip Code = POSTALCODE
  • Select a Country (optional) = Canada

image.png

8. Run the Workspace and View the Output
Run the workspace with Feature Caching Enabled, then view the output in Visual Preview. You will have four outputs from the ArcGISOnlineFindAddressCandidate transformer: 

  • Output: provides the input address as a SingleLine, the split of each of the attributes based on commas, the X and Y coordinate, and the spatial reference number. 
  • <Rejected>: Input features are output via this port if the API calls fail. Any error message is stored in the fme_rejection_message attribute.

  image.png

 

Final Workspace
2-6.jpg

 

Additional Resources

 

Data Attribution

The data used here originates from data made available by the City of Vancouver, British Columbia. It contains information licensed under the Open Government License - Vancouver.

Was this article helpful?

Comments

0 comments

Please sign in to leave a comment.