convert_list_to_tibble {hubeau}R Documentation

Convert list provided by the APIs into a tibble

Description

Convert list provided by the APIs into a tibble

Usage

convert_list_to_tibble(l)

Arguments

l

a list provided by the API (See doApiQuery)

Details

This function is used internally by all the retrieving data functions for converting data after the call to doApiQuery.

Value

A tibble::tibble with one row by record and one column by field.

Examples

# To get the available APIs in the package
list_apis()

# To get the available endpoints in an API
list_endpoints("prelevements")

# To get available parameters in endpoint "chroniques" of the API "prelevements"
list_params(api = "prelevements", endpoint = "chroniques")

# To query the endpoint "chroniques" of the API "prelevements"
# on all devices in the commune of Romilly-sur-Seine in 2018
## Not run: 
resp <- doApiQuery(api = "prelevements",
                   endpoint = "chroniques",
                   code_commune_insee = "10323",
                   annee = "2018")
convert_list_to_tibble(resp)

## End(Not run)

[Package hubeau version 0.5.0 Index]