Skip to contents

Read data package Digital Object Identifier

Usage

read_data_package_doi(packageId, as_url = FALSE, env = "production")

Arguments

packageId

(character) Data package identifier

as_url

(logical) Returns the DOI as a URL if TRUE.

env

(character) Repository environment. Can be: "production", "staging", or "development".

Value

(character) The Digital Object Identifier for packageId

Examples

if (FALSE) { # \dontrun{

# Read package DOI
doi <- read_data_package_doi("knb-lter-jrn.210548103.15")
doi
#> [1] "doi:10.6073/pasta/c80c0c03d22791524d4b870d2193c843"

# Read package DOI as URL
doi <- read_data_package_doi("knb-lter-jrn.210548103.15", as_url = TRUE)
doi
#> [1] "https://doi.org/10.6073/pasta/c80c0c03d22791524d4b870d2193c843"
} # }