ots_read_from_api: Reads data from the API (internal function)

View source: R/ots_read_from_api.R

ots_read_from_apiR Documentation

Reads data from the API (internal function)

Description

Accesses api.tradestatistics.io and performs different API calls to return data.frames by reading JSON data. The parameters here are passed from ots_create_tidy_data.

Usage

ots_read_from_api(
  year = NULL,
  reporter_iso = NULL,
  partner_iso = NULL,
  commodity_code = "all",
  section_code = "all",
  table = "yr",
  max_attempts = 5
)

tradestatistics/tradestatistics documentation built on July 8, 2023, 12:26 a.m.