Learn R Programming

eodhd (version 1.0.4)

rest_get_method: Generic REST GET method

Description

This function performs a generic REST GET request to the specified API endpoint. It takes an API key, endpoint, URI, and querystring as input and returns the response data in JSON format.

Usage

rest_get_method(api_key, endpoint = "", uri = "", querystring = list())

Value

The response data in JSON format.

Arguments

api_key

A character string representing the API key for authentication.

endpoint

A character string representing the API endpoint to request.

uri

A character string representing the URI for the request.

querystring

A list of key-value pairs representing the query parameters for the request.

Examples

Run this code
api_key <- "demo"
endpoint <- "bond-fundamentals"
uri <- "DE000CB83CF0"
querystring <- list()
result <- rest_get_method(api_key, endpoint, uri, querystring)
print(result)

Run the code above in your browser using DataLab