/
Geocoding

Geocoding

If you want to use the Map view, you need the coordinates of an address (Latitude & Longitude). Most of the time, this is not available in your existing business data. To makes things easier, Portrait has a geocoding feature integrated, that will create the coordinates for you.

The feature is integrated as a Field Processor and needs minimal setup.

Prerequisites

Portrait uses Mapbox for geocoding. Mapbox is a third-party service, that will be paid per usage. You need to set up an account and generate an access token for Portrait. The access token does not need a specific scope, just give it a name, leave it the URL’s unrestricted and copy the token. It should look like this:

pk.eyJ1IjoidG9rb6ImNsYnV4aTZ4djF4JRc49m12aTRtdG16bWIifQ.v1irJPERjwkxsSXpK_sJlyw

Setup

Set the following in the application YAML file on highest level - not under “application”):

mapbox: token: 'pk.eyJ1IjoidG9rb6ImNsYnV4aTZ4djF4JRc49m12aTRtdG16bWIifQ.v1irJPERjwkxsSXpK_sJlyw' url: 'https://api.mapbox.com/geocoding/v5/mapbox.places/'

Source Configuration

After you’ve set up Mapbox in the YAML file, and reloaded the backend, you can use Field Processors | Geo Coding.

 

Related content

Geocoding
More like this
Map view
More like this
Map view
More like this
Portrait 3.0.0
Portrait 3.0.0
More like this
Portrait 3.0.0
Portrait 3.0.0
More like this
Create and Update API Source Entries
Create and Update API Source Entries
More like this