get_placekeys: Get Placekeys using the bulk API

View source: R/get_placekeys.R

get_placekeysR Documentation

Get Placekeys using the bulk API

Description

Fetch placekeys using the bulk API. Automatically paginates.

Usage

get_placekeys(
  location_name = NA,
  street_address = NA,
  city = NA,
  region = NA,
  postal_code = NA,
  iso_country_code = NA,
  latitude = NA,
  longitude = NA,
  strict_address_match = FALSE,
  strict_name_match = FALSE,
  key = Sys.getenv("PLACEKEY_SECRET"),
  ...
)

Arguments

location_name

The name of the place.

street_address

The streed address of the place.

city

The city where the place is located.

region

The second-level administrative region below nation for the place. In the US, this is the state.

postal_code

The postal code for the place.

iso_country_code

The ISO 2-letter Country Code for the place. Currently may only be US.

latitude

Latitude in decimal degrees.

longitude

Longitude in decimal degrees.

strict_address_match

If set to 'TRUE', a Placekey is only returned if all fields identify the place as being at the exact address specified. If set to 'FALSE', the Placekey returned may ignore unit/apartment/floor information. Optional. Default 'FALSE'.

strict_name_match

If set to 'TRUE', a Placekey is only returned if all fields identify the POI as having the exact name specified. Optional. Default 'FALSE'.

...

Unused; allows purrr::pmap_chr to call get_placekey with columns not used in the Placekey call.

Examples

## Not run: 
# include in a mutate statement
boston_bars %>%
 slice(1:100) %>%
 mutate(placekey = get_placekeys(
   location_name,
   street_address,
   city,
   region,
   postal_code,
   iso_country_code
 ))

## End(Not run)

JosiahParry/placekey documentation built on March 17, 2023, 2:41 a.m.