An AddressInputFields is similar to a lookup field. However, they have specific attributes to optimize them for address information.

By default, AddressInputField supports three modes:

  • Google Maps
  • PCAPredict
  • Manual entry

For Google Maps and PCAPredict, the address field displays as a single field. The pick list automatically shows addresses that are close to you based on your location.

Once your address is entered, the address is parsed out into a JSON array.

For example, if you enter "4420 Washington Boulevard, Arlington, VA, USA", the address is parsed into the array below:

	"address": {
		"street_number":  "4420",
		"street_name":  "Washington Boulevard",
		"city":  "Arlington",
		"province":  "VA",
		"country":  "United States",
		"postal_code":  "22201"

Your key attribute is your Aura ID.


Enabling PCAPredict allows you to enter military addresses and select specific countries outside of the US. While the parsed address remains the same, using PCAPredict provides more flexibility with your address lookup.

You can configure PCAPredict in Spark Admin.

To configure PCAPredict from the Spark Admin Page:

  1. [Click] on Spark under the Apps Menu on the sidebar.
  2. [Click] Lightning Address Input Config under Settings Pages.

  3. [Enter] your PCA Key - This is an API key provided by PCAPredict allowing access to your account.
  4. [Enter] your PCA Countries - For example, if you only want addresses from the US and UK displayed, you can enter the specific countries.
  5. [Click] the PCA IP select box if you want addresses displayed based on the user's IP address.
  6. [Click] 

PCAPredict is an outside vendor. To enable this option, you must also set up a PCAPredict account. For more information, see PCAPredict for details.

Manual Entry

Manual Entry allows users to enter an address without using address verification provided by Google or PCAPredict. When your users click the Enter Manually select box, the AddressInputField is disabled by default, and the appropriate fields are displayed. No validation is done when the user submits the address. 

If you load an existing value into an address field, it will not display in your manual entry field. It does display in Google and PCAPrdeict fields.

Configurable Fields

  • value - The destination SObject for the entered address
  • pcaKey - Your PCA Predict API key.
  • pcaCountries - The countries that are displayed in your AddressInputField
  • pcaByIp - Indicates whether addresses shown in the picklist are based on the user's IP address.
  • required - Indicates your AddressInputField required.
  • placeholder - Displays a custom message in your AddressInputField before any entry is made. By default, the text "Enter your address" displays.
  • streetLabel, cityLabel, provinceLabel, countryLabel, postalCodeLabel - Custom labels for each manual entry field displayed.
  • showDependentPickLists - Allows you to enable or disable dependent picklists (e.g., selecting a specific country displays only addresses from that country).
  • allowManualAddress - Allows you to enable or disable manual address entry.