The geocoder API query is created using universal "generic" parameters and optional api-specific "custom" parameters. Generic parameters are converted into api parameters using the api_parameter_reference dataset.
The query_api function executes the queries created by this function.
the geocoding service name (ie. 'census')
universal "generic" parameters
custom api-specific parameters
API parameters as a named list
get_api_query("osm", list(address = "Hanoi, Vietnam"))
#> $q
#> [1] "Hanoi, Vietnam"
#>
#> $format
#> [1] "json"
#>
get_api_query(
"census", list(street = "11 Wall St", city = "NY", state = "NY"),
list(benchmark = "Public_AR_Census2010")
)
#> $street
#> [1] "11 Wall St"
#>
#> $city
#> [1] "NY"
#>
#> $state
#> [1] "NY"
#>
#> $benchmark
#> [1] "Public_AR_Census2010"
#>
#> $format
#> [1] "json"
#>
#> $vintage
#> [1] "Current_Current"
#>