build_get_request: Build URLs for 'GET' requests

Description Usage Arguments Details Value

View source: R/build_get_request.R

Description

Returns URLs properly formatted for GET requests

Usage

1
2
3
4
5
build_get_request(
  base_url = "https://api.coingecko.com",
  path,
  query_parameters
)

Arguments

base_url

(character): API's base URL (host). Defaults to "https://api.coingecko.com".

path

(character or NULL): vector, whose elements form the path of the respective API endpoint. The order of these elements is important. For example, if the path is api/v3/ping, then this vector must be path = c("api", "v3", "ping").

query_parameters

(named list or NULL): contains parameters of the request.

Details

No validation of the base URL is performed by this function, so users are advised to ensure that the base URL is correctly formatted and encoded.

Value

A URL that is ready to be used in a GET request.


geckor documentation built on Nov. 1, 2021, 5:07 p.m.