prevedere_fetch {prevederer}R Documentation

Query the Prevedere API

Description

Send a GET request to the Prevedere API. Most users should calling this function directly and instead use the appropriate wrapper for accessing each part of the API.

Usage

prevedere_fetch(key, path, payload = NULL)

Arguments

key

A Prevedere API key.

path

The path (within the API) to which the request will be sent.

payload

The payload for the request. This should be a named list.

Value

The result of the API request.

See Also

GET, content, response

Examples

## Not run: 
prevedere_fetch(
  key = "1235467abcdefg",
  path = "/indicator/BLS/CES3133231058",
  payload = list(
    Frequency = "Annual",
    Calculation = "None",
    Offset = 0
  )
)

k <- "1235467abcdefg"
prevedere_fetch(
  key = k,
  path = "/indicator/BLS/CES3133231058",
  payload = list(
    Frequency = "Annual",
    Calculation = "None",
    Offset = 0
  )
)

## End(Not run)

[Package prevederer version 0.0.1 Index]