get_placekey: Query the Placekey API

View source: R/get_placekey.R

get_placekeyR Documentation

Query the Placekey API

Description

Queries the Placekey API and, if successful, returns a placekey. See https://docs.placekey.io/ for more information.

Usage

get_placekey(
  location_name = NULL,
  street_address = NULL,
  city = NULL,
  region = NULL,
  postal_code = NULL,
  iso_country_code = NULL,
  strict_address_match = FALSE,
  strict_name_match = FALSE,
  key = Sys.getenv("PLACEKEY_SECRET"),
  ...
)

## S3 method for class 'data.frame'
get_placekey(.data, strict_name_match, strict_address_match)

## S3 method for class 'list'
get_placekey(.list, strict_name_match, strict_address_match)

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.

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.

.data

A dataframe containing the columns 'street_address', 'city', 'region', 'postal_code', and 'iso_country_code'.

.list

A named list elements named 'street_address', 'city', 'region', 'postal_code', and 'iso_country_code'.


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